Skip to content

How to configure the custom endpoint for azure openai service? (APIM endpoint with key) #7316

Answered by dosubot bot
ronakshirolawala asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @ronakshirolawala! I'm here to help you with any bugs, questions, or contributions you have. Let me know how I can assist you!

I found a similar closed issue that might be relevant to your question: How to provide custom endpoint for Azure OpenAi service? (gateway URL). This issue was resolved by a pull request that added support for custom endpoints for Azure OpenAI [1].

To configure a custom endpoint for Azure OpenAI in LangChainJS, you can use the getEndpoint function with the appropriate configuration parameters. Here's an example of how you can set it up:

import { AzureChatOpenAI } from "@langchain/openai";

const model = new AzureChatOpenAI({
  azureOpenAIBasePath: "your-APIM…

Replies: 1 comment 9 replies

Comment options

You must be logged in to vote
9 replies
@dosubot
Comment options

@ronakshirolawala
Comment options

@dosubot
Comment options

@ronakshirolawala
Comment options

@dosubot
Comment options

Answer selected by ronakshirolawala
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant