Skip to content

Paiml MCP Agent Toolkit

Pragmatic AI Labs MCP Agent Toolkit - An MCP Server designed to make code with agents more deterministic

Install: claude mcp add --scope user pmat -- pmat --mode mcp

Works with Claude Code · 165 GitHub stars

Install

$claude mcp add --scope user pmat -- pmat --mode mcp

Install command taken from the project's README or registry entry. Always review code before running it.

PMAT

Zero-configuration AI context generation for any codebase

Installation | MCP Server | Usage | Features | Examples | Documentation


Table of Contents

What is PMAT?

PMAT (Pragmatic Multi-language Agent Toolkit) provides everything needed to analyze code quality and generate AI-ready context:

  • Context Generation - Deep analysis for Claude, GPT, and other LLMs
  • Technical Debt Grading - A+ through F scoring with 6 orthogonal metrics
  • Mutation Testing - Test suite quality validation (85%+ kill rate)
  • Repository Scoring - Quantitative health assessment (0-289 scale, 11 categories)
  • Git History RAG - Semantic search across commit history with RRF fusion
  • Semantic Search - Natural language code discovery
  • Compliance Governance - 157 checks across code quality, best practices, and reproducibility
  • Design by Contract - Toyota Way contract profiles with checkpoint validation and rescue protocols
  • Autonomous Kaizen - Toyota Way continuous improvement with auto-fix and commit
  • MCP Integration - 20 tools for Claude Code, Cline, and AI agents over stdio and HTTP (identical surfaces), validated end-to-end for concurrent multi-agent (ultracode) workflows — see MCP Server
  • Quality Gates - Pre-commit hooks, CI/CD integration, .pmat-gates.toml config
  • 20+ Languages - Rust, TypeScript, Python, Go, Java, C/C++, Lua, Lean, and more

Part of the PAIML Stack, following Toyota Way quality principles (Jidoka, Genchi Genbutsu, Kaizen).

Annotated Code Search

pmat query "cache invalidation" --churn --duplicates --entropy --faults

Every result includes TDG grade, Big-O complexity, git churn, code clones, pattern diversity, fault annotations, call graph, and syntax-highlighted source.

Installation

# Install from crates.io
cargo install pmat

Note for macOS Users: If you experience issues installing via rustup, we recommend installing/updating Rust using Homebrew: brew install rust before running cargo install pmat.

# Or from source (latest)
git clone https://github.com/paiml/paiml-mcp-agent-toolkit
cd paiml-mcp-agent-toolkit && cargo install --path .

MCP Server

PMAT is an MCP server first and a CLI second. One binary serves three surfaces, and they share one tool registry — you pick a surface, not a feature set.

Surface Start it with Use it when
CLI pmat analyze complexity --path . A human or a shell script reads the output.
MCP over stdio pmat --mode mcp An MCP client launches pmat itself as a subprocess — Claude Code, Claude Desktop, Cline. One client, one process, no port, no token.
MCP over HTTP pmat serve --transport http --port 8765 One long-lived server that several clients — or another machine — talk to. Streamable HTTP, bearer auth.

Similar plugs

The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype…

A cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Grok Build & Hermes Agent. Only official website: ccswitch.io

Explore related