Skip to content

Commit

Permalink
docs[patch]: Point OpenAI LLM docs at chat models (#5718)
Browse files Browse the repository at this point in the history
* Point OpenAI LLM docs at chat models

* Use caution

* Remove deprecated package link
  • Loading branch information
jacoblee93 authored Jun 10, 2024
1 parent 3531c74 commit 8d24df4
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 21 deletions.
6 changes: 6 additions & 0 deletions docs/core_docs/docs/integrations/llms/azure.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@ import CodeBlock from "@theme/CodeBlock";

# Azure OpenAI

:::caution
You are currently on a page documenting the use of Azure OpenAI [text completion models](/docs/concepts/#llms). The latest and most popular Azure OpenAI models are [chat completion models](/docs/concepts/#chat-models).

Unless you are specifically using `gpt-3.5-turbo-instruct`, you are probably looking for [this page instead](/docs/integrations/chat/azure/).
:::

[Azure OpenAI](https://azure.microsoft.com/products/ai-services/openai-service/) is a cloud service to help you quickly develop generative AI experiences with a diverse set of prebuilt and curated models from OpenAI, Meta and beyond.

LangChain.js supports integration with [Azure OpenAI](https://azure.microsoft.com/products/ai-services/openai-service/) using the new Azure integration in the [OpenAI SDK](https://github.com/openai/openai-node).
Expand Down
6 changes: 6 additions & 0 deletions docs/core_docs/docs/integrations/llms/openai.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# OpenAI

:::caution
You are currently on a page documenting the use of OpenAI [text completion models](/docs/concepts/#llms). The latest and most popular OpenAI models are [chat completion models](/docs/concepts/#chat-models).

Unless you are specifically using `gpt-3.5-turbo-instruct`, you are probably looking for [this page instead](/docs/integrations/chat/openai/).
:::

Here's how you can initialize an `OpenAI` LLM instance:

import IntegrationInstallTooltip from "@mdx_components/integration_install_tooltip.mdx";
Expand Down
1 change: 0 additions & 1 deletion docs/core_docs/docs/integrations/platforms/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ LangChain integrates with many providers.
These providers have standalone `@langchain/{provider}` packages for improved versioning, dependency management and testing.

- [Anthropic](https://www.npmjs.com/package/@langchain/anthropic)
- [Azure OpenAI](https://www.npmjs.com/package/@langchain/azure-openai)
- [Cloudflare](https://www.npmjs.com/package/@langchain/cloudflare)
- [Cohere](https://www.npmjs.com/package/@langchain/cohere)
- [Exa](https://www.npmjs.com/package/@langchain/exa)
Expand Down
24 changes: 12 additions & 12 deletions docs/core_docs/docs/integrations/platforms/microsoft.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,18 @@ import CodeBlock from "@theme/CodeBlock";

All functionality related to `Microsoft Azure` and other `Microsoft` products.

## Chat Models

### Azure OpenAI

See a [usage example](/docs/integrations/chat/azure)

import AzureChatOpenAI from "@examples/models/chat/integration_azure_openai.ts";

<UnifiedModelParamsTooltip></UnifiedModelParamsTooltip>

<CodeBlock language="typescript">{AzureChatOpenAI}</CodeBlock>

## LLM

### Azure OpenAI
Expand Down Expand Up @@ -70,18 +82,6 @@ import AzureOpenAIEmbeddings from "@examples/models/embeddings/azure_openai.ts";

<CodeBlock language="typescript">{AzureOpenAIEmbeddings}</CodeBlock>

## Chat Models

### Azure OpenAI

See a [usage example](/docs/integrations/chat/azure)

import AzureChatOpenAI from "@examples/models/chat/integration_azure_openai.ts";

<UnifiedModelParamsTooltip></UnifiedModelParamsTooltip>

<CodeBlock language="typescript">{AzureChatOpenAI}</CodeBlock>

## Vector stores

### Azure AI Search
Expand Down
16 changes: 8 additions & 8 deletions docs/core_docs/docs/integrations/platforms/openai.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@ All functionality related to OpenAI

- Get an OpenAI api key and set it as an environment variable (`OPENAI_API_KEY`)

## Chat model

See a [usage example](/docs/integrations/chat/openai).

```typescript
import { ChatOpenAI } from "@langchain/openai";
```

## LLM

See a [usage example](/docs/integrations/llms/openai).
Expand All @@ -36,14 +44,6 @@ npm install @langchain/openai
import { OpenAI } from "@langchain/openai";
```

## Chat model

See a [usage example](/docs/integrations/chat/openai).

```typescript
import { ChatOpenAI } from "@langchain/openai";
```

## Text Embedding Model

See a [usage example](/docs/integrations/text_embedding/openai)
Expand Down

0 comments on commit 8d24df4

Please sign in to comment.