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 babyworm/rtl-agent-team --skill rtl-p4s-refactor-policygit clone --depth 1 https://github.com/babyworm/rtl-agent-teamWrote 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/babyworm/rtl-agent-team/rtl-p4s-refactor-policy)<a href="https://agentmods.dev/skills/babyworm/rtl-agent-team/rtl-p4s-refactor-policy"><img src="https://agentmods.dev/badge/skills/babyworm/rtl-agent-team/rtl-p4s-refactor-policy/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/babyworm/rtl-agent-team/rtl-p4s-refactor-policy"><img src="https://agentmods.dev/badge/skills/babyworm/rtl-agent-team/rtl-p4s-refactor-policy.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.00026 | $0.00874 |
| Opus 5.5 | $0.00010 | $0.00350 |
| Sonnet 5.5 | $0.00005 | $0.00175 |
| Haiku 4.5 | $0.00003 | $0.00087 |
Grade A, and why
rtl-p4s-refactor-policy 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 14d 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 — 73 lines — stays where its author put it; the contents beside it link to each section on GitHub.
RTL Refactoring Policy
Refactoring Decision Criteria
- Module >500 lines: consider splitting
- 3+ modules share similar code: extract common module
- Naming inconsistency flagged by rtl-critic: rename pass
- Missing parameterization: add parameters for magic numbers
- Refactoring is selective — not all modules need it
Naming Convention Audit Rules
Refactoring plans MUST include naming convention audit:
- Ports:
i_/o_/io_prefix (NOT suffix_i/_o) — flag violations for correction - Clocks:
clk(single domain) or{domain}_clk(multiple domains) — flagclk_i,clk_sys - Resets:
rst_n(single domain) or{domain}_rst_n(multiple domains) — flagrst_ni - Instances:
u_prefix — flag missing prefix - Generates:
gen_prefix — flag missing prefix logiconly — flag anyreg/wireusage
Common refactoring patterns:
data_i->i_data,valid_o->o_valid(suffix to prefix)clk_i->clkorsys_clk(suffix clock to conformant name)rst_ni->rst_norsys_rst_n(suffix reset to conformant name)fifo_inst->u_fifo(missing instance prefix)reg [7:0] data->logic [7:0] data(reg to logic)
When renaming ports, prefer sv-renamer (https://github.com/babyworm/sv-renamer) when installed:
# Dry-run preview
sv_renamer.py --dir rtl/ --recursive --prefix i_ --dry-run --report json
# Apply + verify equivalence
sv_renamer.py --dir rtl/ --recursive --prefix i_
sv_semantic_diff.py --before original/ --after rtl/ # formal equivalence check
If sv-renamer is not installed, use Grep to find ALL instantiation sites across the codebase and update them in the same task.
Equivalence Proof Policy
- Cosmetic/style-only cleanup: lint + smoke simulation sufficient
- Any change touching combinational/sequential logic, reset, clock enable, or constraints intent: invoke equivalence-checker (RTL-vs-RTL) before completion
- Formal equivalence via SymbiYosys (requires sv2v conversion first):
sv2v rtl/{module}/*.sv -o rtl/{module}/{module}_v2v.v cd formal/ && sby -f {module}.sby # .sby must reference _v2v.v, not .sv
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.
- 14d ago First seen · 73 lines · 26 tokens per session scan A 2a8f6ecde16c
rtl-p4s-refactor-policy is a skill published in the GitHub repository babyworm/rtl-agent-team (60 stars, last pushed 15d ago), licensed MIT. It adds 26 tokens to every session and 874 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-10-08.
Other skills, from other repositories
aster-review-ci
Run aster code reviews non-interactively in CI, GitHub Actions, or from another agent. Covers aster review --pr, --json, --stream, --comment, diff-from-stdin, token handling, and filtering findings. Use when wiring aster into a pipeline, posting PR comments, or parsing review output programmatically.
qa-review
QA review for code changes — test coverage analysis, edge case identification, test plan generation, regression detection, test health tracking over time.
kicad-pcb-review
Use this skill when reviewing, fixing, validating, or preparing KiCad PCB projects with the kicad MCP server.
module-no-new-exports-all
Populate no-new-exports entries in module descriptors so their module surface area cannot be increased.
refactor-safely
Renaming, moving, and restructuring code without breaking behavior. Use when the task is a rename, a file move, an extract, or any restructuring the user expects to be behavior-neutral.
apex-review
Reviews a technical proposal from the perspective of organizational decision-makers (CTO, technical lead, QA lead, conference reviewers, etc.) and generates an HTML presentation deck. Outputs approval gate results per persona and connects to sim-conductor for improvement suggestions.