AI Agent Not Passing chatInput Despite Being Present in Merge Node Output - Need Help!

Hey n8n community! I’ve searched the forum but couldn’t find a solution, so I’m posting here for help.

The “AI Agent” node isn’t passing the chatInput value to the prompt, even though it’s present in the “Merge” node’s output. This causes the “Simple Memory” node to fail as well.

The error

“AI Agent” Prompt (User Message) shows: no message provided (indicating chatInput is undefined).

“Simple Memory” error: Error in sub-node ‘Simple Memory’ (because it relies on “AI Agent” output).

The output

The “Edit Fields” node (last node) doesn’t produce output because “Simple Memory” fails due to the “AI Agent” not passing data correctly.
Expected Output:

{
“text”: “AI response”,
“sessionId”: “session-1743115817206”
}

Information on your n8n setup
n8n version: 1.83.2 (Cloud)

Database: Default (SQLite)

n8n EXECUTIONS_PROCESS setting: Default (own, main)

Running n8n via: n8n cloud

Operating system: N/A (cloud)

Any suggestions on how to ensure chatInput is passed correctly to the “AI Agent”? Thanks!


That is because you are running it from 2 different branches:

It will run with the branch above and after it will run with the branch below.

You have to merge everything into a single branch. You can use the Merge node for that too. But from what I can see you could simply use a single straight branch for everything.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.