npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

mmcp-core

v2.1.0

Published

MMCP — Multi-Model Collaboration Pipeline. Orchestrate AI models as a DAG with RL routing, multi-verifier voting, distributed agent mesh, and self-improving feedback loops.

Downloads

107

Readme

🔀 MMCP — Multiple Model Context Protocol

Orchestrate AI models as a coordinated DAG. One CLI. Every model. Smart routing.

PyPI Downloads npm License Railway GitHub stars


MCP standardizes tool use for a single model. MMCP standardizes context flow between models.


⚡ 30-Second Quick Start

pip install mmcp-core
mmcp login
mmcp run

That's it. Type a task, MMCP picks the best model + pattern automatically.

🧠 Smart Routing — The Right Model for Every Task

MMCP analyzes your task and auto-selects the optimal model from 8+ providers:

| Your Task | Model Selected | Why | |-----------|---------------|-----| | "Write a Python API with auth" | Gemini 2.5 Pro | Top-tier for coding | | "Debug this React component" | GPT-4o | Strong at code generation | | "Prove this calculus theorem" | DeepSeek R1 | Best for math & reasoning | | "Write a blog post about AI" | Claude Sonnet | Excellent creative writing | | "Analyze market strategy" | Claude Sonnet | Deep reasoning & analysis | | "Summarize this in one line" | Llama 4 Maverick | Fast & free |

You don't pick the model. You describe the task. MMCP figures out the rest.

🏗️ How It Works

User: "Build a REST API for a todo app"

MMCP Smart Router:
  ├── Task type:   Coding (2 keywords matched)
  ├── Complexity:  High
  ├── Pattern:     Deep dive (shard → merge)
  └── Model:       Gemini 2.5 Pro

DAG Execution:
  [root] orchestrator (gemini-2.5-pro)
    ├── [shard] analyst-1 ──┐
    ├── [shard] analyst-2 ──┤
    └── [shard] analyst-3 ──┤
                            ▼
                   [merge] editor
                       │
                   Final Output

Every node produces a Context Envelope — an inspectable, serializable record. The full DAG is your audit trail.

🔄 The 5 Protocol Operations

| Operation | Flow | Use Case | |-----------|------|----------| | Chain | A → B → C | Sequential review pipeline | | Fork/Merge | A → [B,C,D] → E | Parallel analysis, brainstorming | | Verify | Producer → Challenger → Judge | Adversarial fact-checking | | Shard | A → [A₁,A₂,A₃] → Merge | Long document processing | | Handoff | A → B | Transfer between specialists |

💰 MMCP Cloud — Use Without API Keys

Don't have API keys? Use MMCP Cloud — we handle the infrastructure:

mmcp login      # create free account
mmcp run        # just type your task
mmcp account    # check usage

| Plan | Price | Runs/mo | Best For | |------|-------|---------|----------| | Free | $0 | 50 | Try it out | | Pro | $19/mo | 500 | Daily use | | Team | $49/mo | Unlimited | Teams |

BYOK mode: Already have API keys? Use mmcp setup instead — it's free forever.

📦 Installation

Python (CLI + SDK)

pip install mmcp-core

# BYOK mode (bring your own key)
mmcp setup

# OR Cloud mode (no keys needed)
mmcp login

TypeScript/Node.js

npm install @mmcp/core

🛠️ CLI Commands

mmcp run                                    # Interactive smart mode
mmcp chain   "task" -r writer,reviewer      # Sequential pipeline
mmcp parallel "task" -f coder,analyst -m summarizer  # Parallel
mmcp verify  "task" -p expert -c critic -s judge     # Adversarial
mmcp shard   "task" -r analyst -n 3 -M editor        # Deep dive
mmcp audit   output.json                    # View audit trail
mmcp account                                # Usage & billing
mmcp version                                # Version info

🔧 Python SDK

from mmcp_core import MMCPOrchestrator, RoleBasedRouter

orc = MMCPOrchestrator(config={
    "router": RoleBasedRouter(),
    "adapter": call_openrouter,  # or call_anthropic
})

# Chain: writer → reviewer → editor
result = await orc.run_chain(
    "Write a blog post about quantum computing",
    ["writer", "reviewer", "editor"]
)

print(result.output)       # final text
print(result.total_tokens) # cost tracking
print(result.dag)          # full audit trail

📊 TypeScript SDK

import { MMCPOrchestrator, RoleBasedRouter } from "@mmcp/core";

const orc = new MMCPOrchestrator({
  router: new RoleBasedRouter({
    architect: { model_id: "claude-opus-4-20250514" },
    coder:     { model_id: "claude-sonnet-4-20250514" },
    verifier:  { model_id: "claude-sonnet-4-20250514" },
  }),
});

const result = await orc.runChain(
  "Build a REST API for a todo app",
  ["architect", "coder", "verifier"]
);

🆚 Why MMCP?

| Feature | MMCP | LangChain | CrewAI | AutoGen | |---------|------|-----------|--------|---------| | Multi-model DAG | ✅ | ❌ | ❌ | ⚠️ | | Smart model routing | ✅ | ❌ | ❌ | ❌ | | 8+ providers | ✅ | ✅ | ⚠️ | ⚠️ | | Audit trail | ✅ Built-in | ❌ | ❌ | ❌ | | CLI (no code needed) | ✅ | ❌ | ❌ | ❌ | | Cloud hosted | ✅ | ❌ | ❌ | ❌ | | Protocol-level spec | ✅ | ❌ | ❌ | ❌ | | Setup time | 30 sec | Hours | Hours | Hours |

🧪 Context Envelope (Protocol Primitive)

Every model invocation produces a Context Envelope:

{
  "mmcp_version": "0.1",
  "id": "ctx_a1b2c3",
  "parent_ids": ["ctx_root"],
  "task": "Review the code for security issues",
  "role": "security_auditor",
  "model": "anthropic/claude-sonnet-4",
  "branch_type": "fork",
  "status": "done",
  "output": "Found 3 potential vulnerabilities...",
  "tokens_used": 1847,
  "cost_usd": 0.003
}

🛣️ Roadmap

  • [x] Core DAG schema + 5 protocol operations
  • [x] TypeScript SDK + Python SDK
  • [x] CLI with smart routing (8+ models)
  • [x] MMCP Cloud (hosted proxy with billing)
  • [x] Multi-provider: Anthropic, OpenAI, Google, Meta, DeepSeek, Mistral
  • [ ] Streaming outputs
  • [ ] Web dashboard + playground
  • [x] PyPI package (pip install mmcp-core) ✅
  • [ ] Confidence scoring + auto-retry
  • [ ] MMCP Registry (share pipeline configs)
  • [ ] Enterprise: SSO, audit export, compliance

🤝 Contributing

git clone https://github.com/RagavRida/mmcp.git
cd mmcp/python
pip install -e ".[all]"
pytest

Or install from PyPI to use:

pip install mmcp-core

📄 License

MIT — use it for anything.


⭐ Star this repo if MMCP saves you from model selection headaches

Report Bug · Request Feature · MMCP Cloud