L2M logo
L2M MCP-native agent runtime
GitHub
Open source · MIT

The MCP-native agent runtime.

Visual workflow builder, multi-agent Swarm, and a first-party VS Code surface — for developers composing AI agents that do real work in real systems via the Model Context Protocol.

Why L2M

Three things other workflow tools don't do.

n8n has a basic MCP client node. Langflow and Flowise have none. Most "agent platforms" treat tool calls as glorified HTTP. L2M treats MCP, multi-agent topology, and IDE composition as first-class primitives.

MCP-native, end to end

stdio, http_streamable, and mock transports ship in-box. The MCP Tool node probes any server, lists its tools, and dry-runs them inline. Expose your own workflows back out as MCP tools that other agents — IDE, CLI, anything MCP-compatible — call by URL.

MCP integration docs →

Multi-agent Swarm

Compose Supervisor → Worker hierarchies via dedicated attachment ports — not chained prompts. Workers become synthetic tools to the parent, recursively. Each worker gets its own model, its own tool set, its own memory.

Agent loop docs →

VS Code surface

First-party extension turns any L2M workflow into a coding agent inside the editor — streaming responses, patch previews with workspace-path safety, and command approval. Bring your own backend agent topology.

VS Code extension →
Workflow JSON

A stable, importable contract.

Every workflow you build in Studio serializes to a versioned JSON document. Check it into git. Diff it. Code-review it. Import it anywhere. The agent runtime, MCP attachments, branching, retries, memory — all of it round-trips through this format.

  • schemaVersion: "1.0.0" — breaking-change boundary, never silently shifts.
  • Attachment ports (chat_model, memory, tool, worker) live alongside DAG edges.
  • Every adapter (LLM, MCP, connector) registers through a single SDK seam.
samples/mcp-agent.json
"nodes": [
  {
    "id": "trigger",
    "type": "webhook_input",
    "config": { "path": "agent", "authMode": "hmac_sha256" }
  },
  {
    "id": "agent",
    "type": "agent_orchestrator",
    "config": {
      "systemPromptTemplate": "{{system_prompt}}",
      "toolCallingEnabled": true,
      "maxIterations": 6
    }
  },
  // + chat_model, memory, mcp_tool nodes...
],
"edges": [
  { "source": "agent", "sourceHandle": "chat_model", "target": "llm" },
  { "source": "agent", "sourceHandle": "tool", "target": "mcp_fs" }
]
Studio

The actual editor, not a marketing render.

L2M Studio editor showing a multi-node SDLC workflow with DeveloperAgent, QAAgent, and Output nodes on canvas.
Get running

Five minutes from clone to a working MCP agent.

No API keys, no Ollama, no setup beyond a 32-byte master key. The bundled echo provider and in-process mock-mcp adapter let you verify the agent runtime end-to-end before swapping in real models and real MCP servers.

Read the 5-minute tutorial →
  1. 1
    git clone · pnpm install
  2. 2
    Generate a master key, set SECRET_MASTER_KEY_BASE64
  3. 3
    pnpm dev · open localhost:5173
  4. 4
    Templates → MCP Agent Quickstart → Run
  5. 5
    See the agent call MCP tools in execution history
Capabilities

Production-ready foundations.

The boring stuff that decides whether you can actually ship.

Branching DAG executor

Topological execution with if, switch, try/catch. Template interpolation across nodes via {{key}} from the merged scope.

Auth, RBAC, MFA, SSO

Session cookies, API keys, TOTP, SAML, LDAP. Project-scoped roles plus custom roles with fine-grained permissions.

Encrypted secrets at rest

AES-256-GCM with master-key rotation via db:export / db:import. External providers: Vault, AWS, GCP, Azure.

Webhooks, signed and idempotent

HMAC-SHA256, bearer, Stripe, Discord Ed25519, Telegram. Replay window + idempotency keyed on any header.

Observability

Prometheus metrics, OTEL tracing, request-ID propagation through logs, dedicated webhook replicas.

Multi-main HA

Postgres-backed leader election: scheduler + triggers run on the leader, replicas autoscale webhook ingestion, lease handoff tested.

Patterns + Samples

Battle-tested topologies, runnable on day one.

Ten documented topologies — zero-key MCP agent, supervisor swarm, workflow-as-MCP-tool, RAG with citation, structured-output triage, multi-turn artifacts — each with a runnable sample workflow.

  • Pattern library lives in the docs site.
  • Three full reference projects in l2m-samples: helpdesk agent, support triage, VS Code repo reviewer.
  • Every sample runs zero-key first; the swap-to-real-models path is documented.

Pattern at a glance

helpdesk-agentSlack/Teams + MCP KB + memory
support-triageAgent → JSON → switch routing
swarmSupervisor + multiple workers
workflow-as-mcpExpose flow as MCP tool
vscode-reviewerDiff + filesystem MCP
rag-with-citationRetriever + cited answer
Stack

Practical architecture for fast iteration.

FrontendVite + React 19 + React Flow
APIFastify v5 + zod-validated config
RuntimePure-TS DAG executor + agent loop
StorageSQLite (better-sqlite3) or Postgres
SDKsprovider · mcp · connector · agent
DeployDocker · Helm · GHCR multi-arch
Open source · MIT

From local prototype to production agents.

L2M is a pure OSS project — no closed-source enterprise SKU, no SaaS lock-in. Self-host it, fork it, build community nodes, run it as the MCP-native runtime your stack actually needs.