AI 代理节点常见问题(AI Agent node common issues)#
这里是一些关于 AI Agent 节点 的常见错误和问题,以及解决或排查它们的步骤。
🌐 Here are some common errors and issues with the AI Agent node and steps to resolve or troubleshoot them.
内部错误:400 'content' 的值无效(Internal error: 400 Invalid value for 'content')#
完整的错误信息可能如下所示:
🌐 A full error message might look like this:
1 2 3 | |
如果 Prompt 输入包含空值,则可能会发生此错误。
🌐 This error can occur if the Prompt input contains a null value.
你可能会在以下两种情况下看到此错误:
🌐 You might see this in one of two scenarios:
- 当你将提示设置为在下面定义,并且你的文本中的表达式没有生成值时。
- 要解决此问题,请确保你的表达式引用有效的字段,并且解析为有效的输入而不是 null。
- 当你将 提示 设置为 连接的聊天触发节点 并且传入的数据包含空值时。
- 为了解决此问题,请从输入节点的
chatInput字段中移除所有空值。
- 为了解决此问题,请从输入节点的
子节点“简单内存”中的错误(Error in sub-node Simple Memory)#
当 n8n 在处理 Simple Memory 子节点时遇到问题时,会显示此错误。
🌐 This error displays when n8n runs into an issue with the Simple Memory sub-node.
它最常发生在你的工作流或你复制的工作流模板使用了旧版本的 Simple 内存节点(以前称为“窗口缓冲内存”)时。
🌐 It most often occurs when your workflow or the workflow template you copied uses an older version of the Simple memory node (previously known as "Window Buffer Memory").
尝试从工作流中移除“简单内存”节点,然后再重新添加,这样可以确保你使用的是该节点的最新版本。
🌐 Try removing the Simple Memory node from your workflow and re-adding it, which will guarantee you're using the latest version of the node.
聊天模型子节点未连接错误(A Chat Model sub-node must be connected error)#
当 n8n 尝试在未连接聊天模型的情况下执行节点时,会显示此错误。
🌐 This error displays when n8n tries to execute the node without having a Chat Model connected.
要解决此问题,当节点打开时,请点击屏幕底部的 + 聊天模型 按钮;当节点关闭时,请点击 聊天模型 + 连接器。n8n 将会打开一个可供选择的聊天模型列表供你选择。
🌐 To resolve this, click the + Chat Model button at the bottom of your screen when the node is open, or click the Chat Model + connector when the node is closed. n8n will then open a selection of possible Chat Models to pick from.
未指定错误提示(No prompt specified error)#
当代理期望自动从前一个节点获取提示时,就会出现此错误。通常,这种情况发生在你使用 聊天触发节点 时。
🌐 This error occurs when the agent expects to get the prompt from the previous node automatically. Typically, this happens when you're using the Chat Trigger Node.
要解决此问题,请找到 AI Agent 节点的 Prompt 参数,并将其从 Connected Chat Trigger Node 更改为 Define below。这样,你可以通过引用其他节点的输出数据或添加静态文本来手动构建提示。
🌐 To resolve this issue, find the Prompt parameter of the AI Agent node and change it from Connected Chat Trigger Node to Define below. This allows you to manually build your prompt by referencing output data from other nodes or by adding static text.