Skip to content

Workflow Retriever 节点#

使用 Workflow Retriever 节点可以从 n8n 工作流中检索数据,用于 Retrieval QA Chain 或其他 Retriever 节点。

本页将介绍 Workflow Retriever 节点的参数配置,并提供更多资源链接。

/// 注意 | 子节点中的参数解析 子节点在使用表达式处理多个项目时的行为与其他节点不同。

大多数节点(包括根节点)会接收任意数量的输入项,处理这些项目,然后输出结果。您可以使用表达式来引用输入项,节点会依次为每个项目解析表达式。例如,给定五个 name 值作为输入,表达式 {{ $json.name }} 会依次解析为每个名称。

而在子节点中,表达式总是解析为第一个项目。例如,给定五个 name 值作为输入,表达式 {{ $json.name }} 总是解析为第一个名称。 ///

节点参数#

数据源#

指定 n8n 要调用的工作流。您可以选择:

  • 数据库 并输入工作流 ID
  • 参数 并粘贴完整的 工作流 JSON

工作流值#

设置要传递给被调用工作流的值。

这些值会出现在被调用工作流的触发器节点输出数据中。您可以在工作流的表达式中访问这些值。例如,如果您有以下配置:

  • 工作流值中的名称myCustomValue
  • 被调用工作流使用 Execute Sub-workflow Trigger 节点作为触发器

访问 myCustomValue 值的表达式为 {{ $('Execute Sub-workflow Trigger').item.json.myCustomValue }}

模板与示例#

Browse 工作流检索器 integration templates, or search all templates

相关资源#

更多关于该服务的详细信息,请参考 LangChain 通用检索器文档

查看 n8n 的高级 AI 文档。

AI glossary#

  • completion: Completions are the responses generated by a model like GPT.
  • hallucinations: Hallucination in AI is when an LLM (large language model) mistakenly perceives patterns or objects that don't exist.
  • vector database: A vector database stores mathematical representations of information. Use with embeddings and retrievers to create a database that your AI can access when answering questions.
  • vector store: A vector store, or vector database, stores mathematical representations of information. Use with embeddings and retrievers to create a database that your AI can access when answering questions.