跳到主要内容
Ascend 是华为提供的人工智能处理器
本页面介绍如何将 Ascend NPU 与 LangChain 结合使用。

安装

使用 torch-npu 安装
pip install torch-npu
请按照以下指定的安装说明操作
  • 按照此处所示安装 CANN。

嵌入模型

请参阅使用示例
from langchain_community.embeddings import AscendEmbeddings

以编程方式连接这些文档到 Claude、VSCode 等,通过 MCP 获取实时答案。
© . This site is unofficial and not affiliated with LangChain, Inc.