n8n AI Agent Tutorial (2026): The New Agents Feature vs the AI Agent Node, on Free Self-Hosted n8n
Описание и применение
В статье описывается создание небольшого чат‑агента на бесплатном, самохостедном n8n, используя как узел AI Agent, так и новую функцию Agents в режиме предварительного просмотра. Оба подхода работают, но требуют разных конфигураций и имеют ограничения, связанные с малым локальным LLM.
Задача
Build a small chat agent on a free, self‑hosted n8n instance using either the AI Agent node or the newer Agents feature, and compare their requirements, execution, and limitations.
Результат
Both approaches ran successfully on a free, self‑hosted n8n instance. The AI Agent node requires a workflow canvas, at least one tool sub‑node, and a memory node. The Agents preview feature is built in the Agent Builder, supports built‑in integrations, workflows, and custom tools, and has session memory by default. The local 1.5B model performed poorly on arithmetic tasks, revealing limitations of small models.
Рабочий процесс
- Install n8n 2.43.8 via npm on Node 24
- Create owner account and verify Community plan
- Enable Agents via Settings API
- Set up local Ollama model (Qwen2.5‑1.5B‑Instruct)
- Build workflow 1: Chat Trigger → AI Agent node → Ollama Chat Model → Simple Memory → Calculator tool
- Build workflow 2: Agent Builder → define model, instructions, tools, memory, knowledge base
- Expose chat trigger publicly via HTTP
- Test both agents by sending chat messages and observing tool usage
Доказательства
Both builds used a local model through Ollama: Qwen2.5-1.5B-Instruct, a small model that runs on a CPU.
The test machine had no Docker, so n8n was installed from npm. The npm package for n8n 2.43.8 declares "node": ">=24.0.0"
The workflow has five nodes: Chat Trigger, AI Agent, Ollama Chat Model, Simple Memory, Calculator tool
- Дата записи: 2026-10-19T23:41:38.041Z