Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs[minor]: Update ChatAzureOpenAI integration docs #6285

Merged
merged 5 commits into from
Aug 1, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix npm2yarn
  • Loading branch information
bracesproul committed Jul 31, 2024
commit 65658aced694e40468b9d997167e56590e40e4e3
48 changes: 16 additions & 32 deletions docs/core_docs/docs/integrations/chat/azure.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -51,49 +51,34 @@
"\n",
"Once you have your instance running, make sure you have the name of your instance and key. You can find the key in the Azure Portal, under the \"Keys and Endpoint\" section of your instance. Then, if using Node.js, you can set your credentials as environment variables:\n",
"\n",
"```{=mdx}\n",
"\n",
"```bash\n",
"AZURE_OPENAI_API_INSTANCE_NAME=<YOUR_INSTANCE_NAME>\n",
"AZURE_OPENAI_API_DEPLOYMENT_NAME=<YOUR_DEPLOYMENT_NAME>\n",
"AZURE_OPENAI_API_KEY=<YOUR_KEY>\n",
"AZURE_OPENAI_API_VERSION=\"2024-02-01\"\n",
"```\n",
"\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "72ee0c4b-9764-423a-9dbf-95129e185210",
"metadata": {},
"source": [
"If you want to get automated tracing of your model calls you can also set your [LangSmith](https://docs.smith.langchain.com/) API key by uncommenting below:\n",
"\n",
"```{=mdx}\n",
"\n",
"```bash\n",
"# export LANGCHAIN_TRACING_V2=\"true\"\n",
"# export LANGCHAIN_API_KEY=\"your-api-key\"\n",
"```\n",
"\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "0730d6a1-c893-4840-9817-5e5251676d5d",
"metadata": {},
"source": [
"### Installation\n",
"\n",
"The LangChain AzureChatOpenAI integration lives in the `@langchain/openai` package:\n",
"\n",
"```{=mdx}\n",
"\n",
"```bash npm2yarn\n",
"npm i @langchain/openai\n",
"```\n",
"import IntegrationInstallTooltip from \"@mdx_components/integration_install_tooltip.mdx\";\n",
"import Npm2Yarn from \"@theme/Npm2Yarn\";\n",
"\n",
"<IntegrationInstallTooltip></IntegrationInstallTooltip>\n",
"\n",
"<Npm2Yarn>\n",
" @langchain/openai\n",
"</Npm2Yarn>\n",
"\n",
"```"
]
Expand All @@ -105,9 +90,7 @@
"source": [
"## Instantiation\n",
"\n",
"Now we can instantiate our model object and generate chat completions:\n",
"\n",
"- TODO: Update model instantiation with relevant params."
"Now we can instantiate our model object and generate chat completions:"
]
},
{
Expand Down Expand Up @@ -210,9 +193,7 @@
"source": [
"## Chaining\n",
"\n",
"We can [chain](/docs/how_to/sequence/) our model with a prompt template like so:\n",
"\n",
"- TODO: Run cells so output can be seen."
"We can [chain](/docs/how_to/sequence/) our model with a prompt template like so:"
]
},
{
Expand Down Expand Up @@ -351,11 +332,14 @@
"\n",
"```{=mdx}\n",
"\n",
"```bash npm2yarn\n",
"npm install @langchain/openai\n",
"npm uninstall @langchain/azure-openai\n",
"<Npm2Yarn>\n",
" @langchain/openai\n",
"</Npm2Yarn>\n",
"\n",
"```\n",
"\n",
"```bash\n",
"npm uninstall @langchain/azure-openai\n",
"```\n",
"\n",
" \n",
Expand Down
Loading