> ## Documentation Index
> Fetch the complete documentation index at: https://langchain-docs-zh.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 安装 LangGraph

> 要安装基础 LangGraph 包：

要安装基础 LangGraph 包：

:::python

```bash pip theme={null}
pip install -U langgraph
```

```bash uv theme={null}
uv add langgraph
```

:::

:::js

```bash npm theme={null}
npm install @langchain/langgraph @langchain/core
```

```bash pnpm theme={null}
pnpm add @langchain/langgraph @langchain/core
```

```bash yarn theme={null}
yarn add @langchain/langgraph @langchain/core
```

```bash bun theme={null}
bun add @langchain/langgraph @langchain/core
```

:::

要使用 LangGraph，通常需要访问大语言模型（LLMs）并定义工具。
您可以通过任何您认为合适的方式实现。

一种方法（我们将在文档中使用）是通过 [LangChain](https://langchain-docs-zh.mintlify.site/langchain/oss/langchain/overview.md) 实现。

安装 LangChain 的命令如下：

:::python

```bash pip theme={null}
pip install -U langchain
# Requires Python 3.10+
```

```bash uv theme={null}
uv add langchain
# Requires Python 3.10+
```

:::

:::js

```bash npm theme={null}
npm install langchain
```

```bash pnpm theme={null}
pnpm add langchain
```

```bash yarn theme={null}
yarn add langchain
```

```bash bun theme={null}
bun add langchain
```

:::

要使用特定的大语言模型（LLM）供应商包，您需要单独安装它们。

请参考 [integrations](https://langchain-docs-zh.mintlify.site/langchain/oss/python/integrations/providers/overview.md) 页面获取供应商特定的安装说明。

***

> 官方原文：[src/oss/langgraph/install.mdx](https://github.com/langchain-ai/docs/blob/main/src/oss/langgraph/install.mdx) · 非官方翻译，译文由 AI 生成，以英文原文为准。


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.