Multi-Agent Conversation
This workflow enables simultaneous conversations between users and multiple AI agents, supporting personalized configurations for each agent's name, instructions, and language model. Users can mention specific agents using @, allowing the system to dynamically invoke multiple agents, avoiding the creation of duplicate nodes, and supporting multi-turn dialogue memory to enhance the coherence of interactions. It is suitable for scenarios such as intelligent Q&A, decision support, and education and training, meeting complex and diverse interaction needs.

Workflow Name
Multi-Agent Conversation
Key Features and Highlights
This workflow enables users to engage in conversations simultaneously with multiple AI agents, each configurable with unique names, instructions, and distinct language models. Users can invoke one or more specific AI agents by mentioning @agent_name in their messages; if no @mention is present, all agents are called randomly by default. The workflow automatically extracts @mentions and dynamically cycles through the respective agents, avoiding the need to create multiple separate nodes. It also supports multi-turn conversation memory to enhance interaction coherence.
Core Problems Addressed
Traditional single AI assistants struggle to meet the demands for multi-dimensional and multi-style intelligent interactions. This workflow leverages multi-agent collaboration to overcome the limitations of single-model coverage, delivering a richer and more flexible intelligent dialogue experience. Additionally, dynamic invocation and unified management reduce complexity and improve scalability.
Application Scenarios
- Intelligent Q&A requiring multi-perspective and multi-style responses
- Collaborative multi-role AI assistance for decision-making in complex business scenarios
- Simulated multi-mentor style dialogues in education and training
- Customer service systems integrating multiple intelligent assistants to enhance service quality
- Experimental environments for comparing responses from different AI models in research and development
Main Process Steps
- Receive User Chat Messages: Triggered by Webhook to capture input messages.
- Define User and Global System Settings: Configure user information and global system prompts.
- Configure Multiple AI Agents: Define agent names, corresponding models, and personalized system messages.
- Extract @Mentions from Messages: Parse message text to identify and prioritize specified agents for invocation.
- Iteratively Invoke Agents: For each called agent, dynamically generate dialogue context based on its configuration and invoke the corresponding model.
- Manage Multi-Turn Conversation Memory: Use shared memory nodes to maintain session context, supporting continuous dialogue.
- Aggregate Agent Responses: Collect and format all agents’ replies into a unified output for the user.
Involved Systems or Services
- n8n Automation Platform: Core workflow design and execution environment.
- LangChain Nodes: Facilitate chat triggers, agent invocation, and multi-turn memory management.
- OpenRouter API: Supports calling multiple large language models such as OpenAI GPT-4o, Anthropic Claude, and Google Gemini.
- Code Nodes (JavaScript): Implement key logic including @mention parsing and response aggregation.
Target Users and Value
- AI product developers and automation engineers: Quickly prototype multi-agent conversational systems.
- Enterprise users and customer service teams: Build multi-role intelligent customer support or advisory assistants.
- Educational and training institutions: Simulate multi-mentor, multi-style teaching environments.
- Researchers: Compare performance across different language models and conduct multi-agent interaction studies.
- Any individuals or teams seeking to enhance the diversity and depth of AI-driven conversations.
By offering flexible configuration and high scalability, this workflow empowers users to achieve efficient and enriched multi-agent conversational experiences, fulfilling diverse intelligent interaction needs in complex scenarios.