OpenAI
features and configuration options, please refer to the API reference.
Class | Package | Local | Serializable | PY support | Package downloads | Package latest |
---|---|---|---|---|---|---|
OpenAI | @langchain/openai | ❌ | ✅ | ✅ |
@langchain/openai
integration package.
OPENAI_API_KEY
environment variable:
@langchain/openai
package:
process.env.OPENAI_ORGANIZATION
to your OpenAI organization id, or pass it in as organization
when
initializing the model.
configuration
parameter like this:
ClientOptions
parameters accepted by the official SDK.
If you are hosting on Azure OpenAI, see the dedicated page instead.