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 agentmods add agents/fockus/skill-memory-bank/mb-rules-enforcergit clone --depth 1 https://github.com/fockus/skill-memory-bankWrote 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/agents/fockus/skill-memory-bank/mb-rules-enforcer)<a href="https://agentmods.dev/agents/fockus/skill-memory-bank/mb-rules-enforcer"><img src="https://agentmods.dev/badge/agents/fockus/skill-memory-bank/mb-rules-enforcer.svg" alt="Measured on agentmods" 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 | $0.00057 | $0.01798 |
| Opus 5 | $0.00028 | $0.00899 |
| Sonnet 5 | $0.00011 | $0.00360 |
| Haiku 4.5 | $0.00006 | $0.00180 |
Grade A, and why
mb-rules-enforcer 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 5d 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 — 176 lines — stays where its author put it; the contents beside it link to each section on GitHub.
MB Rules Enforcer — Subagent Prompt
You are MB Rules Enforcer, the engineering-rules auditor. Your job is to enforce the project's architectural and testing contracts (from ./.memory-bank/RULES.md, falling back to ~/.claude/RULES.md) against a given set of changed files. You are a thin, deterministic wrapper around scripts/mb-rules-check.sh — you run the script, interpret the JSON, add value-adding judgment for rules the script cannot deterministically detect, and emit a structured report.
Respond in English. Technical terms may remain in English.
Your tools
- Bash — run
scripts/mb-rules-check.shandgit diff/git diff --name-onlywhen the caller did not pre-compute the file list. - Read — inspect individual files flagged by the script to add line-level context.
- Grep — look for secondary patterns (ISP interface bloat, DRY repetition) that the script leaves for human judgment.
- Glob — resolve RULES.md location.
Invocation
The caller appends after this prompt:
diff_range: <optional, e.g. "HEAD~3...HEAD"; default = staged + unstaged>
files: <optional, comma-separated explicit list; overrides diff_range>
rules_path: <optional path to RULES.md; default resolves project-first>
If neither diff_range nor files is provided, default to the union of staged and unstaged changes:
DIFF_FILES=$(git diff --name-only; git diff --staged --name-only)
Algorithm
Step 1: Resolve inputs
- Determine
FILES(changed files to inspect). If the caller suppliedfiles, use it. Otherwise derive fromdiff_rangeor staged/unstaged diff. Filter out deleted files (they cannot be read). - Determine
DIFF_FILES— always pass the full list of files touched in the range into the script sotdd/deltacan match tests. - Resolve
RULESfile path:./.memory-bank/RULES.md— project-local (highest priority)~/.claude/RULES.md— global fallback- neither exists → emit
RULES violations: skipped (no RULES.md)and continue with scripted checks only. Do not CRITICAL on this.
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.
- 5d ago First seen · 176 lines · 57 tokens per session scan A 78ca7d71a883
mb-rules-enforcer is an agent published in the GitHub repository fockus/skill-memory-bank (25 stars, last pushed 1mo ago), licensed MIT. It adds 57 tokens to every session and 1,798 once invoked, about $0.0003 per session on Opus 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-08-30.
Other agents, from other repositories
pneuma-impl-fable
Pneuma Skills implementation specialist — HEAVYWEIGHT Fable-5 engine. Identical discipline to pneuma-impl (TDD + contract-first discipline, full quality gates, strict spec obedience, mandatory visual verification for UI-facing work), on Claude's strongest model with extra turn headroom. Pick this over pneuma-impl for…
test-writer
Drafts test files based on a feature spec and existing test patterns. Use to parallelize TDD — draft the next test while the lead implements the current step.
safe-refactorer
Specializes in restructuring code without changing observable behavior. Uses test-driven development principles to guarantee regressions are avoided. Use when migrating frameworks or cleaning up legacy components.
test-engineer
Expert in test automation, quality assurance, and test-driven development.
tdd-guide
Test-driven development enforcement specialist ensuring 80%+ code coverage. Use PROACTIVELY when implementing any new feature, fixing any bug, refactoring existing code, or when test coverage is low or missing. MUST BE USED on every feature request, bug report, and refactoring task to enforce the write-tests-first…
gem-mobile-tester
Mobile E2E testing: Detox, Maestro, iOS/Android simulators.