Skip to main content

Puppetmaster

PyPI CI License: MIT Python

Puppetmaster runs multi-step engineering work through the agent tools you already use: Cursor, Claude Code, Codex, Hermes, or a provider API. It starts independent workers, routes tasks to an available model, and stores their typed results in SQLite so jobs can be inspected and resumed. It is aimed at developers who want durable state and reviewable output for repository investigations, audits, refactors, and implementations.

Measured results

  • SWE-bench Lite: 29% lower actual spend with cost routing and durable retries; 47–48% token-matched savings. This is a single-seed study and does not establish quality parity. Study.
  • NL2Repo-Bench: 91.1% mean pass rate, about 2.28× the published ~40% baseline. Benchmark and methodology.
Puppetmaster demo showing routing, worker fan-out, and a stitched summary

Contents

Install

pipx install puppetmaster-ai     # or: pip install puppetmaster-ai
puppetmaster setup               # installs MCP tools, rules, and hooks

setup is idempotent, skips platforms that are not installed, and prints each change. It asks you to enable at least one adapter; for example:

puppetmaster setup --platforms cursor

Restart Cursor, Codex, Claude, or Hermes after setup. The host then has the puppetmaster_* MCP tools and, where supported, hooks that suggest delegation for larger tasks. Disable those hooks with PUPPETMASTER_AUTO_INVOKE_DISABLED=1. For CI, use --platforms <comma-list> or --platforms all. Add another adapter later with puppetmaster platform enable <name>.

The built-in agentic adapter needs only a provider API key, so it can run without an external CLI. See adapter setup for provider and Hermes details.

Quickstart

Inside Cursor Agent or Codex:

Use Puppetmaster to run doctor in this repo and summarize what is missing.

For a supervised change:

Use Puppetmaster to start a cursor swarm for this repo and return the job id immediately.
Problem: users get logged out after refresh and token-refresh tests are flaky.
Constraints: keep the patch focused, preserve public API behavior, run relevant tests.
Do review/plan first. Poll status/logs by job id. Do not edit until you summarize findings and ask for approval.

From the shell:

puppetmaster doctor
puppetmaster route "Security audit every endpoint" --role audit
puppetmaster cursor "Review this repo for release blockers" --review --dry-run
puppetmaster claude "Implement the approved change and run focused tests" --permission-mode acceptEdits
puppetmaster show "$(puppetmaster last)"

More recipes are in DAILY_DRIVER.md and MODEL_ROUTING.md.

How it works

Puppetmaster is a supervisor and job store for agent CLIs and provider adapters:

Cursor / Claude Code / Codex / Hermes / agentic
        |
        v
supervisor -> model router -> independent workers -> SQLite artifacts
                                                   |
                                                   v
                                            stitched summary

Workers claim tasks, write artifacts containing payloads and evidence, and do not share one growing transcript. The parent agent receives the stitched result and can inspect the stored artifacts with:

puppetmaster artifacts <job_id>
python -m puppetmaster dashboard

CodeGraph is an optional structural code index. When installed, Puppetmaster adds task-relevant CodeGraph context before worker calls; otherwise workers use ordinary repository inspection. See CODEGRAPH.md.

Puppetmaster sits above libraries such as LangGraph and CrewAI: those libraries help you build an agent, while Puppetmaster coordinates existing agent CLIs and adapters. See WHY.md and COMPARISON.md.

Evidence

The repository includes reproducible benchmark scripts and their scope and caveats in CLAIMS.md. The receipts cover:

  • routing fixture results and follow-up reads from completed SQLite artifacts;
  • typed artifacts, evidence fields, and content hashes;
  • CodeGraph context injection and adapter failure classification.

These are measurements of the included workflows, not guarantees for every repository or model. An independent durable-state benchmark is documented here.

More documentation

The docs index covers:

Uninstall

puppetmaster uninstall
pip uninstall puppetmaster-ai   # or: pipx uninstall puppetmaster-ai

uninstall removes Puppetmaster-owned MCP entries, hooks, and rules. It keeps ~/.puppetmaster/ and workspace .codegraph/ unless you pass --purge-state; use --dry-run to preview.

Status

Puppetmaster is a daily-driver beta at v1.22.3, suitable for supervised local engineering rather than hosted multi-user use. The current release includes SQLite-backed jobs, Cursor Agent MCP support, Grok Bot remote MCP (streamable HTTP pilot path), full-edit adapters, constrained model routing (with Grok 4.6 as the Cursor workhorse for ambitious and agentic work), shared verified context (admitted gists + dashboard Frontier), passive provider rate-limit harvest, AWS Bedrock, OpenCode Go, and Marionette-keyed Z.AI / MiniMax / NVIDIA NIM providers through the agentic adapter. See the feature matrix, Grok Bot harness, and CHANGELOG.md for the current details.

PyPI uses the package name puppetmaster-ai; the import name, CLI, and repository use puppetmaster.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

puppetmaster_ai-1.22.3.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

puppetmaster_ai-1.22.3-py3-none-any.whl (802.7 kB view details)

Uploaded Python 3

File details

Details for the file puppetmaster_ai-1.22.3.tar.gz.

File metadata

  • Download URL: puppetmaster_ai-1.22.3.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.6

File hashes

Hashes for puppetmaster_ai-1.22.3.tar.gz
Algorithm Hash digest
SHA256 beb8baea4b7ebf8efe8fe4d1792967d37088cdc110047aa805ee8a043261d087
MD5 497109eb1629a5f9a91d1b6f00413d5a
BLAKE2b-256 f6572cb7869ad4aafd4c4f697869765ff0f99a91f71b9fe0ef9dfc85b67bfbed

See more details on using hashes here.

File details

Details for the file puppetmaster_ai-1.22.3-py3-none-any.whl.

File metadata

File hashes

Hashes for puppetmaster_ai-1.22.3-py3-none-any.whl
Algorithm Hash digest
SHA256 4925db2cba93c02f60f1e711b6f045e2b3a443dff3545bc42692a3f9ea0023d0
MD5 4a2394b011e8c45794011e00bc05d35f
BLAKE2b-256 801e114c1ce616223e8ec0c91d6c6ed08f8ed0e8ae74243e85558e605a2033a2

See more details on using hashes here.

Release history Release notifications | RSS feed

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page