AzureOpenAI()What sampling temperature to use.
Build extra kwargs from additional params that were passed in.
Get the sub prompts for llm call.
Create the LLMResult from the choices and prompts.
Get the tokens present in the text with tiktoken package.
Calculate the maximum number of tokens possible to generate for a model.
Calculate the maximum number of tokens possible to generate for a prompt.
Azure-specific OpenAI large language models.
To use, you should have the openai python package installed, and the
environment variable OPENAI_API_KEY set with your API key.
Any parameters that are valid to be passed to the openai.create call can be passed in, even if not explicitly saved on this class.
Example:
from langchain_openai import AzureOpenAI
openai = AzureOpenAI(model_name="gpt-3.5-turbo-instruct")