跳到主要内容

ChatGPT 插件检索器

危险

此模块已弃用,不再受支持。以下文档在 0.2.0 或更高版本中将无法使用。

此示例展示了如何在 LangChain 中使用 ChatGPT 检索器插件。

要设置 ChatGPT 检索器插件,请按照此处的说明进行操作。

用法

import { ChatGPTPluginRetriever } from "langchain/retrievers/remote";

const retriever = new ChatGPTPluginRetriever({
url: "http://0.0.0.0:8000",
auth: {
bearer: "super-secret-jwt-token-with-at-least-32-characters-long",
},
});

const docs = await retriever.invoke("hello world");

console.log(docs);

此页内容对您有帮助吗?


您也可以留下详细的反馈 在 GitHub 上.

© . This site is unofficial and not affiliated with LangChain, Inc.
这些文档随着 LangChain v1.0 在 2025 年 10 月的发布而弃用,并且不再维护。 请访问 v1.0 文档