Skip to main content

Multi-Agent Planning (MAP)

Multi-Agent Planning (MAP) is AxonFlow's orchestration layer for coordinating multiple AI agents to accomplish complex tasks. MAP breaks down user requests into subtasks, assigns them to specialized agents, and aggregates results—all while enforcing governance policies at every step.

How It Works

User Request: "Plan a business trip to Mumbai"


┌─────────────────┐
│ Planning Engine │ ← Analyzes intent, selects agents
└─────────────────┘

┌───────────┼───────────┐
▼ ▼ ▼
┌─────────┐ ┌─────────┐ ┌─────────┐
│ Flight │ │ Hotel │ │ Policy │ ← Specialist agents
│ Agent │ │ Agent │ │ Checker │
└─────────┘ └─────────┘ └─────────┘
│ │ │
└───────────┴───────────┘


┌─────────────────┐
│ Workflow Engine │ ← Executes steps, aggregates results
└─────────────────┘


Aggregated Response

Key Components

Planning Engine

The Planning Engine analyzes incoming requests and generates execution plans:

  • Query Analysis: Detects intent and required capabilities
  • Agent Selection: Chooses appropriate agents based on capabilities
  • Step Generation: Creates execution steps with dependencies
  • Domain Templates: Uses domain-specific templates (travel, healthcare, finance)

Agent Registry

The Agent Registry manages available agents:

ModeDescriptionEdition
File-basedAgents defined in YAML configuration filesCommunity
Database-backedAgents stored in PostgreSQL with CRUD APIEnterprise
HybridBoth file-based and database agents (DB takes priority)Enterprise

Workflow Engine

The Workflow Engine executes plans:

  • Step Execution: Runs each step type (llm-call, connector-call, etc.)
  • Dependency Management: Ensures steps run in correct order
  • Parallel Execution: Runs independent steps simultaneously
  • Template Variables: Passes data between steps via {{input.key}} and {{steps.name.output}}

Step Types

MAP supports five step types for different operations:

Step TypeDescriptionUse Case
llm-callInvoke an LLM provider for inferenceText generation, analysis
connector-callQuery an MCP connectorDatabase queries, API calls
conditionalBranch based on conditionsDecision logic
function-callExecute a custom functionData transformation
api-callCall an external HTTP APIThird-party integrations

See Step Types for detailed configuration.

Agent Types

TypeDescriptionExample
SpecialistSingle-domain expertiseFlight search, data analysis
CoordinatorOrchestrates other agentsTrip planner, workflow manager

Execution Modes

ModeDescriptionWhen to Use
SequentialSteps run in order, each receiving previous outputDependent tasks
ParallelIndependent steps run simultaneouslyMultiple data sources
ConditionalSteps run based on conditionsDecision trees

Community vs Enterprise

FeatureCommunityEnterprise
File-based agent registry
Plan generation
Sequential execution
Parallel execution
All 5 step types
Database-backed agents
Agent CRUD API
Agent versioning
Multi-tenant isolation (RLS)
Execution analytics
Visual workflow builder

Quick Example

1. Define an Agent

# agents/research-agent.yaml
apiVersion: axonflow.io/v1
kind: AgentConfig
metadata:
name: research-agent
domain: generic
spec:
type: specialist
description: Research and summarize information
capabilities:
- research
- summarization
llm:
provider: openai
model: gpt-4

2. Generate a Plan

curl -X POST http://localhost:8081/api/v1/plan/generate \
-H "Content-Type: application/json" \
-d '{
"query": "Research the benefits of remote work",
"domain": "generic"
}'

3. Execute the Plan

curl -X POST http://localhost:8081/api/v1/plan/execute \
-H "Content-Type: application/json" \
-d '{
"plan_id": "plan_abc123",
"step_index": 0,
"input": {
"query": "Research the benefits of remote work"
}
}'

Next Steps

Enterprise Features

For database-backed agents, CRUD APIs, versioning, and analytics: