Cookiecutter-based bootstrap CLI for new multi-agent Claude Code projects (companion to governance-core; P-0059).
Project description
multi-agent-template
Cookiecutter template + bootstrap CLI for new multi-agent Claude Code projects.
Generates a fresh multi-agent project pre-wired with the governance-core package — safety hooks, proposal workflow, wrap-up discipline, constitution iteration, cross-clone sync.
One-line bootstrap
# One-time setup (per machine)
pip install cookiecutter
pip install governance-core
pip install multi-agent-bootstrap
# Bootstrap a new project
multi-agent-bootstrap new my-project \
--agents core,data \
--ritual-phrase "Acknowledged"
# Open in Claude Code
cd ~/workshop-claude/my-project/agent-core
claude
Output:
~/workshop-claude/my-project/
├── agent-core/ (master branch; governance role)
│ ├── .claude/ (50+ hooks/skills/commands/agents)
│ ├── .governance/ (config.json + 17 clauses + keywords)
│ ├── CLAUDE.md (project constitution — business clauses
│ inherit governance clauses)
│ ├── constitution/ (total.md + per-agent agent.md)
│ ├── contracts/ (proposal/knowledge schemas)
│ ├── knowledge/ (governance docs + your project docs)
│ ├── tools/ (31 generic governance tools)
│ └── agent_rules/ (scope allow/deny)
├── agent-data/ (feature/data branch)
├── shared_state/ (per-project; outside all clones)
│ └── proposals/ (cross-clone shared runtime state)
└── ...
See docs/getting-started.md for the complete walkthrough.
Adopt an existing project (expand)
Already have a single-repo project with governance-core installed, and want
to add the multi-agent N-clone layer without losing its content? Use
expand (P-0068) — it overlays the multi-agent layout onto an existing
GC-installed project, complementing the greenfield new:
multi-agent-bootstrap expand ~/workshop-claude/auto-tax --agents core,filing
It works on either input:
- An existing git repo — git history is preserved; a clean working tree is required.
- A pure folder (just
governance-core install-ed, not yetgit init-ed) — a freshmaster-branch repo is created during the sink.
What happens:
- The whole project is backed up to a sibling
….expand-backup-<ts>/. - Phase 1 — existing content (and git history, if any) is sunk into
<project>/agent-<core>/;shared_state/is initialized alongside. - Phase 2 — one
git cloneper business agent →agent-<role>/onfeature/<role>. - Phase 3 —
governance-core installis re-run per clone (reusing the existing project's authorization — same consumer, no new code), migrating the topology single → multi agent.
If any step fails the project is rolled back from the backup to its pre-expand state. The backup is retained on success — delete it once verified.
CLI reference
multi-agent-bootstrap new <project_name> [options]
Options:
--agents=NAMES Comma-separated agent list (default: core,data)
--ritual-phrase=PHRASE First-line session ritual (default: Acknowledged)
--install-root=DIR Output parent dir (default: ~/workshop-claude)
--core-agent-name=NAME Governance agent name (default: core)
--no-bootstrap Skip bootstrap script + governance-core install
--force Overwrite if project_name already exists
multi-agent-bootstrap expand <project-path> --agents core,<role> [options]
Options:
--agents=NAMES Comma-separated agent list (core auto-included)
--project-name=NAME Project name (default: project directory name)
--core-agent-name=NAME Governance agent name (default: from config)
--no-backup Skip the pre-expand backup copy (not recommended)
--no-reinstall Restructure + fan-out only; skip Phase 3
How it works
- cookiecutter render: The
{{cookiecutter.project_name}}/directory contains a skeleton with{{ cookiecutter.* }}placeholders.mab/cli.pycalls cookiecutter's Python API to substitute your inputs. - bootstrap script: After rendering,
mab/cli.pyrunsgit initin the new project + callsgovernance-core install(directly via Python subprocess; avoids historical PowerShell JSON quoting issues). - governance-core install: Renders 17 constitution clauses with your
ritual phrase substituted, copies 14 hooks + 7 commands + 22 skills + 2
agents to
.claude/, writes 31 tools, sets up.gitattributesmerge=oursfor per-branchconstitution/agent.mdisolation. - Initial commit:
mab/cli.pydoesgit add -A+ commits.
Result: a complete multi-agent governance scaffold in ~5 seconds.
Customization
After bootstrap, your project's .governance/config.json controls:
project_name,install_root,shared_state_root,claude_dircore_agent_name,core_branches,ritual_phraseagents[]with name/branch/clone_dir per agentupstream_branch,constitution_layout
To add a new business agent later, edit agents[] + run
governance-core upgrade --project-root . to refresh.
Project status
v0.3.0 (2026-05). API may break between minor versions.
License
MIT — see LICENSE.
Related
- governance-core — the governance package this template installs
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file multi_agent_bootstrap-0.3.0.tar.gz.
File metadata
- Download URL: multi_agent_bootstrap-0.3.0.tar.gz
- Upload date:
- Size: 19.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eb281dd7fa07de1910b1e08db0239b671f9948782799f4d7ba169bcacf2b5cbc
|
|
| MD5 |
e114f0d10ae0a225db12e31ad07e4b3f
|
|
| BLAKE2b-256 |
b9dd3248924c6e67d4b13e3ff20e63d8efcd85ba4291daeab888e453dfff6a76
|
Provenance
The following attestation bundles were made for multi_agent_bootstrap-0.3.0.tar.gz:
Publisher:
release.yml on napheir/multi-agent-template
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
multi_agent_bootstrap-0.3.0.tar.gz -
Subject digest:
eb281dd7fa07de1910b1e08db0239b671f9948782799f4d7ba169bcacf2b5cbc - Sigstore transparency entry: 1573072885
- Sigstore integration time:
-
Permalink:
napheir/multi-agent-template@ba10251c2b716e65d1983e3254b0c6d65fcb9ec8 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/napheir
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ba10251c2b716e65d1983e3254b0c6d65fcb9ec8 -
Trigger Event:
release
-
Statement type:
File details
Details for the file multi_agent_bootstrap-0.3.0-py3-none-any.whl.
File metadata
- Download URL: multi_agent_bootstrap-0.3.0-py3-none-any.whl
- Upload date:
- Size: 12.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45cea771eb5dc2ed3bbc05575ea8ec73756e703b6a79c9f206ff9b1830a22b06
|
|
| MD5 |
81e69a3030c50be79b43a6d3f5d3f4bb
|
|
| BLAKE2b-256 |
2581d975bc228bee1980f273ddc09f9fb0a8b6f8af495c636e18a7be8881e80b
|
Provenance
The following attestation bundles were made for multi_agent_bootstrap-0.3.0-py3-none-any.whl:
Publisher:
release.yml on napheir/multi-agent-template
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
multi_agent_bootstrap-0.3.0-py3-none-any.whl -
Subject digest:
45cea771eb5dc2ed3bbc05575ea8ec73756e703b6a79c9f206ff9b1830a22b06 - Sigstore transparency entry: 1573072908
- Sigstore integration time:
-
Permalink:
napheir/multi-agent-template@ba10251c2b716e65d1983e3254b0c6d65fcb9ec8 -
Branch / Tag:
refs/tags/v0.3.0 - Owner: https://github.com/napheir
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@ba10251c2b716e65d1983e3254b0c6d65fcb9ec8 -
Trigger Event:
release
-
Statement type: