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.
npx skills add ngocsangyem/MeowKit --skill improve-codebase-architecturegit clone --depth 1 https://github.com/ngocsangyem/MeowKitWrote 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/skills/ngocsangyem/meowkit/improve-codebase-architecture)<a href="https://agentmods.dev/skills/ngocsangyem/meowkit/improve-codebase-architecture"><img src="https://agentmods.dev/badge/skills/ngocsangyem/meowkit/improve-codebase-architecture/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/skills/ngocsangyem/meowkit/improve-codebase-architecture"><img src="https://agentmods.dev/badge/skills/ngocsangyem/meowkit/improve-codebase-architecture.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.00024 | $0.01822 |
| Opus 5.5 | $0.00010 | $0.00729 |
| Sonnet 5.5 | $0.00005 | $0.00364 |
| Haiku 4.5 | $0.00002 | $0.00182 |
Grade A, and why
mk:improve-codebase-architecture 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 10d 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 — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.
mk:improve-codebase-architecture
Find where existing code is shallow and propose deepening refactors: turn shallow modules into deep ones so the code is easier to test and for an agent to navigate.
Use it for analysis of code that exists. For the ADR lifecycle (recording a decision) use mk:arch. For a system with no code yet, use the consultation in references/system-design-consultation.md (see the end of this file). It emits analysis and a type-safe patch; it writes no presentation markup, so any diagram goes to mk:preview.
Vocabulary
Use these nouns exactly: module, interface, depth (deep = small interface, large implementation; shallow = the reverse), seam, adapter, leverage, locality, deletion test (would deleting this module concentrate its complexity, so it was shallow, or merely move it, so it was load-bearing?). Do not substitute "component", "service", "layer", "wrapper", "API" or "boundary". The full definitions, the forbidden-synonym list and the dependency_category taxonomy are in references/deep-module-design.md, which owns the vocabulary.
Outcome
A run ends with, in order:
- Candidates with deletion-test evidence. Read
docs/project-context.md(it may be absent; note that) and the ADRs underdocs/architecture/adr/that touch the area; they record decisions you do not re-argue. Usemk:scout(or search inline) and look for friction: one concept needing many small modules, shallow modules, pure functions extracted only for testability while the bugs hide in how they are called, tightly coupled modules leaking across a seam, code hard to test through its interface. Apply the deletion test to each suspect. Write candidates in the findings schema below totasks/architecture-review/<run-id>-candidates.json. Keep prose sparse; do not propose concrete interfaces yet. If no candidate passes the deletion test, report that and stop: finding nothing is a result. - One user choice. Offer the candidate titles plus "None" (ask the user). To see the candidates drawn, pass the findings file path or a one-line summary as the topic to
mk:preview --html --diagram; that skill accepts a topic, so it draws what the topic describes, not a fixed card layout. This is the only mid-run decision. - A grilled design.
mk:grillinterviews the chosen candidate's design (constraints, dependencies, what sits behind the seam, which tests survive). To compare alternative interfaces ("design it twice"), usemk:party. - A patch that type-checks. Emit the refactor as exact multi-line
Editoperations against the live files; never regenerate whole files. Do not introduceany, generic casts (as T,as unknown as T) or new suppressions (@ts-ignore,eslint-disable);.claude/rules/security-rules.mdblocks them, because they hide the very type error the refactor must fix. After each patch run the project's type-check or build. A failing check means fix the type, not suppress it; after 3 failed attempts, stop and report BLOCKED with the error. - Records kept current. A new domain term goes into
docs/project-context.mdby editing that file (mk:project-contextgenerates whole files and has no add-term action). A rejection with a reason a future explorer needs becomes an ADR throughmk:arch new; skip "not now" and self-evident reasons. A candidate that contradicts an ADR is surfaced only when the friction warrants reopening it, marked inadr_conflict.
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 10d ago Changed · -112 lines df476950fdc9
- 12d ago Changed · -2 tokens per session f047a5131b22
- 14d ago Changed c96daf81b958
- 15d ago Changed 350a20ed913b
- 17d ago Changed · -2 tokens per session 118bb264e9b4
- 24d ago Changed · -96 tokens per session 8a6e9a061c6b
- 3mo ago First seen · 221 lines · 124 tokens per session scan A e71382dec3a4
mk:improve-codebase-architecture is a skill published in the GitHub repository ngocsangyem/MeowKit (18 stars, last pushed 2d ago), licensed MIT. It adds 24 tokens to every session and 1,822 once invoked, about $0.0001 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-09-03.
mk:improve-codebase-architecture compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| mk:improve-codebase-architecturengocsangyem/MeowKit | Skill | 18 | 2d ago | MIT | A | 24 | Claude Code |
| brooks-harnesshyhmrright/brooks-lint | Skill | 1.6k | today | MIT | A | 271 | Claude Code |
| releasehyhmrright/brooks-lint | Skill | 1.6k | today | MIT | A | 135 | Claude Code, Codex |
| code-review-qualityproffesor-for-testing/agentic-qe | Skill | 539 | today | MIT | A | 33 | Claude Code |
| new-skillhyhmrright/brooks-lint | Skill | 1.6k | today | MIT | A | 145 | Claude Code, Codex |
| brooks-audithyhmrright/brooks-lint | Skill | 1.6k | today | MIT | A | 143 | Claude Code |
| brooks-sweephyhmrright/brooks-lint | Skill | 1.6k | today | MIT | A | 178 | Claude Code |