Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/btspoony/mstar-harnessWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/btspoony/mstar-harness/codebase-arch-governance)<a href="https://agentmods.dev/commands/btspoony/mstar-harness/codebase-arch-governance"><img src="https://agentmods.dev/badge/commands/btspoony/mstar-harness/codebase-arch-governance/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/btspoony/mstar-harness/codebase-arch-governance"><img src="https://agentmods.dev/badge/commands/btspoony/mstar-harness/codebase-arch-governance.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00058 | $0.01259 |
| Opus 5.5 | $0.00023 | $0.00504 |
| Sonnet 5.5 | $0.00012 | $0.00252 |
| Haiku 4.5 | $0.00006 | $0.00126 |
Grade A, and why
codebase-arch-governance scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 33 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Architecture Governance
Entry
- Work mode:
direct · writable - View:
fullstack-dev - Boot:
drt→mstar-harness-core→references/entry-contract.md→mstar-roles→references/fullstack-dev-shared.md→mstar-coding-behavior→references/architecture-governance.md·mstar-conventions(path symbols) ·mstar-audit→references/codebase-audit.md§ scope variants (simplify) as the ranking rubric ·mstar-doc-corpus→references/adr.mdwhen a structural decision is promoted - Exit: AC evidence report
Governance, not a rewrite: the codebase is converged batch by batch, and every batch leaves the product working with one path per semantic. A batch that adds an abstraction, directory or interface without migrating its callers, or that leaves the replaced implementation alive beside the new one, is not progress and is rejected.
Procedure SSOT → mstar-coding-behavior → references/architecture-governance.md (target state, the seven properties and their owners, closed-batch conditions, batch selection by total complexity, rejected moves, stop conditions).
Execute
- Discover. Resolve the round's budget once before any batch:
rounds N(a positive integer) when the invocation states it, one batch when it does not; a value that is not a positive integer is refused with the offending value and both retries (omit the token, or pass a positive integer such asrounds 1). Then perform the recon ofmstar-coding-behavior→references/architecture-governance.md§ Recon in this session, over the whole codebase or over thepath|subsystemscope when that token is given; a recon that cannot be completed stops here, names the missing evidence and the read that would close it, and selects no batch — reported in the response with nothing written whendry-runwas given. Then rank candidate moves from that recon by thesimplifyrubric (mstar-audit→references/codebase-audit.md), keeping only evidence the reads produced and only candidates inside thepath|subsystemscope when that token is given.dry-runreturns the six inventories with the ranked candidates and the already-observed baseline in the response, then exits, writing nothing — no audit run directory, report or evidence file, scout dispatch, issue capture, ADR write, edit, or claimed net-complexity figure. Otherwise run the same pass as a read-only audit, keep its evidence, and record the six inventories in the response or a reused audit report. - Select one batch. Take the candidate with the lowest total complexity per
mstar-coding-behavior→references/architecture-governance.md§ Choosing the batch, and drop every candidate its § Not a finding list rejects. One batch per round. - Publish the AC list. Before the first edit, publish the batch's AC from the closed-batch conditions — every live caller accounted for, the replaced path absent, the behaviour baseline observed, the rule landed on a constraint or recorded as an authorized residual — plus the behaviour-preservation gates of
mstar-audit/references/codebase-audit.md§ Write the report. A caller the batch cannot migrate rejects the whole move; the old path is never kept alive beside the new one. - Execute and lock. Land the settled rule on the strongest available constraint (
constraint-ladder.md) or record an authorized residual. A batch that is not a complete move is not progress and is not reported as one. - Next batch. Record the batch's net complexity, then check the round's budget — the only stop that needs no fresh candidate list; spent, the round ends. If it remains, re-run discovery over the current tree and only then apply the candidate stops (no eligible move, or the next move needs a decision), so an accepted batch can make a move eligible that the previous ranking could not see. Invoking this command opts into the batches its budget allows without a confirmation prompt between them; it is never approval for a merge (that authorization belongs to the delivery path), a destructive migration, or a product or architecture decision. A destructive migration or a required product or architecture decision captures an issue and ends the round per that reference's § Stop conditions.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago Changed · +2 lines e2bfbe21e3f9
- 6d ago First seen · 31 lines · 58 tokens per session scan A c13a4f04bb70
codebase-arch-governance is a command published in the GitHub repository btspoony/mstar-harness (74 stars, last pushed today), licensed MIT. It adds 58 tokens to every session and 1,259 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-29.
codebase-arch-governance compared with commands from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| codebase-arch-governancebtspoony/mstar-harness | Command | 74 | today | MIT | A | 58 | Claude Code |
| auditopenplanr/planr-pipeline | Command | 2 | 2mo ago | MIT | A | 0 | Claude Code |
| check-filedavepoon/buildwithclaude | Command | 3.8k | today | MIT | A | 21 | Claude Code |
| refactor-codecentminmod/my-claude-code-setup | Command | 2.8k | 12d ago | MIT | C | 0 | Claude Code |
| branch-reviewhamr0/liteagents | Command | 28 | 8d ago | Apache-2.0 | A | 0 | Claude Code |
| review-specZts0hg/codexspec | Command | 7 | 2d ago | MIT | A | 19 | Claude Code |
| mainframe-review-branchCATWILLgh/MAINFRAME | Command | 2 | 2d ago | MIT | A | 0 | Claude Code |