Coordinate AI Agentsinto Production Workflows.
Compose specialized agents into pipelines, parallel fan-outs, routers, and supervisor hierarchies. Each agent reasons independently while the orchestrator manages handoffs, aggregation, and convergence. All inference runs entirely on-device with full data privacy.
Pipeline
Chain agents in sequence. Each output becomes the next input.
Parallel
Run agents concurrently, then merge all results.
Router
Classify intent and dispatch to the best specialist.
Supervisor
Lead agent delegates, aggregates, and decides next steps.
Four Patterns. Every Workflow.
Each pattern solves a different coordination challenge. Pick the one that matches your task shape, or combine them for complex multi-step workflows.
PipelineOrchestrator
Chain agents in strict sequence. Each agent's output automatically becomes the next agent's input. Ideal for tasks where each step builds on the previous result.
- Content creation: research, write, then edit
- Data pipelines: extract, transform, load
- Document processing: parse, summarize, translate
// Chain 3 agents: research -> write -> edit var researcher = Agent.CreateBuilder(model) .WithName("Researcher") .WithSystemPrompt("Find key facts and data.") .Build(); var writer = Agent.CreateBuilder(model) .WithName("Writer") .WithSystemPrompt("Draft content from research.") .Build(); var editor = Agent.CreateBuilder(model) .WithName("Editor") .WithSystemPrompt("Polish and finalize.") .Build(); var pipeline = new PipelineOrchestrator( researcher, writer, editor ); var result = await pipeline.ProcessAsync( "Write a blog post about AI agents" );
ParallelOrchestrator
Run multiple agents concurrently and merge their results. Every agent sees the same input and works in parallel, reducing total latency to the slowest agent.
- Multi-perspective document review
- Ensemble analysis for higher accuracy
- Concurrent data extraction from multiple sources
// 3 reviewers analyze concurrently var techReviewer = Agent.CreateBuilder(model) .WithName("TechReviewer") .WithSystemPrompt("Evaluate technical accuracy.") .Build(); var bizReviewer = Agent.CreateBuilder(model) .WithName("BusinessReviewer") .WithSystemPrompt("Assess business impact.") .Build(); var secReviewer = Agent.CreateBuilder(model) .WithName("SecurityReviewer") .WithSystemPrompt("Check for security risks.") .Build(); var parallel = new ParallelOrchestrator( techReviewer, bizReviewer, secReviewer ); var results = await parallel.ProcessAsync( "Review this architecture proposal" );
RouterOrchestrator
Classify the user's intent and dispatch to the most appropriate specialist agent. Only one agent handles each request, keeping responses focused and efficient.
- Helpdesk triage across specialist domains
- Multi-model routing by task complexity
- Cost optimization: small model for simple tasks, large model for complex
// Route to the best specialist var codeHelper = Agent.CreateBuilder(model) .WithName("CodeHelper") .WithDescription("Handles coding questions.") .WithSystemPrompt("You are a coding expert.") .Build(); var dataAnalyst = Agent.CreateBuilder(model) .WithName("DataAnalyst") .WithDescription("Handles data analysis.") .WithSystemPrompt("You are a data analyst.") .Build(); var docWriter = Agent.CreateBuilder(model) .WithName("DocWriter") .WithDescription("Handles documentation.") .WithSystemPrompt("You are a technical writer.") .Build(); var router = new RouterOrchestrator( codeHelper, dataAnalyst, docWriter ); var result = await router.ProcessAsync( "Fix the null reference in line 42" );
SupervisorOrchestrator
A lead agent dynamically delegates tasks to workers, aggregates responses, and decides next steps. The supervisor reasons about which worker to call and when the task is complete.
- Complex research with iterative sub-tasks
- Project management with dynamic task allocation
- Multi-step reasoning that adapts based on intermediate results
// Supervisor delegates dynamically var supervisor = new SupervisorOrchestrator(model); supervisor.RegisterWorker( Agent.CreateBuilder(model) .WithName("Researcher") .WithDescription("Finds information.") .WithTools(t => t.Register( BuiltInTools.WebSearch)) .Build() ); supervisor.RegisterWorker( Agent.CreateBuilder(model) .WithName("Analyst") .WithDescription("Analyzes data.") .Build() ); supervisor.RegisterWorker( Agent.CreateBuilder(model) .WithName("Writer") .WithDescription("Writes reports.") .Build() ); var result = await supervisor.ProcessAsync( "Research and summarize AI trends" );
Choose the Right Orchestration Pattern
Match your task shape to the correct pattern. When in doubt, start with Pipeline for sequential work or Parallel for independent analysis.
| If your task needs... | Use | Example | Agents Run |
|---|---|---|---|
| Steps executed in strict order, each building on the last | Pipeline | Research → Draft → Edit → Publish | Sequentially |
| Multiple independent perspectives on the same input | Parallel | Tech review + Legal review + Security audit | Concurrently |
| Intent classification to dispatch to the right specialist | Router | Helpdesk: billing vs. tech support vs. sales | One at a time |
| Dynamic delegation with a lead agent deciding next steps | Supervisor | Research project: gather, analyze, then write report | On demand |
Key API Classes
The core classes that power multi-agent workflows. Every orchestrator builds on the Agent class and its builder pattern.
Run Multi-Agent Demos Locally
Each demo is a standalone console app you can run on your machine. Clone the repo, pick a model, and see orchestration in action.
Step-by-Step Guides
Hands-on tutorials that walk you through building, deploying, and monitoring multi-agent systems.
Key Concepts
Core terminology for understanding multi-agent architectures. Each term links to a detailed explanation.
Build Your First Multi-Agent Workflow
Install LM-Kit.NET, pick an orchestration pattern, and have agents collaborating in minutes. No cloud keys, no API costs, no data leaving your machine.