Cant use ai agent with Hugging Face Inference Model

Describe the problem/error/question

Connection not possible

The node “Hugging Face Inference Model” can’t be connected to the node “AI Agent” because they are not compatible.

What is the error message (if any)?

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 1.81.0
  • Database (default: SQLite): Postgres
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Docker
  • Operating system: Linux

Hey, try connecting the Hugging Face Inference Model node to the Basic LLM Chain node instead. Here’s a template example: Use an open-source LLM (via HuggingFace) | n8n workflow template

And here is a list of models that you can connect to the Tool Agent node. The Hugging Face Inference Model node is not listed here: Tools AI Agent node documentation | n8n Docs

If you’re wondering why the Tool Agent node can’t be connected to the Hugging Face models, you might want to check the LangChain documentation. It might not have to do with n8n, but with how LangChain interacts with the Hugging Face models:

This link is from an older doc page:

1 Like

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