connector.json
Declarative specification for AI-to-AI orchestration. Where MCP defines how AI connects to tools, connector.json defines how AI coordinates with other AI.What It Solves
- Route tasks to different LLMs based on cost or capability
- Run multiple AI sessions in parallel with isolated environments
- Define multi-phase workflows across heterogeneous AI tools
- Fail over to a different provider when one goes down
Spec Overview
Core Sections
session — Environment
How to set up each AI session. Maps to daemon-external plugins that transform PTY session configuration without modifying the terminal engine.
models — Routing
Which AI to use for which role. Named aliases that pipeline phases reference.
primary is unavailable, the runtime falls back to fallback automatically.
Cost-aware routing: cheap models for research, expensive models for implementation.
pipeline — Orchestration
Multi-phase workflow with parallel workers.
workers accepts either a number (N identical workers sharing the phase’s model) or an array of worker objects (each with its own model, prompt, machine).
Beyond Pipeline — Communication Topologies
Pipeline is one topology. connector.json supports all:
See: Bidirectional Communication, Meeting Protocol, N-to-N Topology, Recursive Teams, Dimensional Growth.
Relationship to MCP
MCP is a field inside connector.json, not a competing spec.Relationship to OpenCLIs
connector.json unifies these into a single declarative file.
Runtime
connector.json is a spec. The runtime that executes it is the NIIA daemon + headless PTY infrastructure.niia run connector.json.
Design Principles
- Declarative — describe what, not how
- LLM-agnostic — any AI CLI that runs in a terminal
- Infrastructure-level — orchestration in daemon, not in prompts
- MCP-complementary — MCP for tools, connector.json for workflows
- File is the plugin — new JSON = new workflow, no code changes