1fpf
Decompose a sprawling module into orchestrator + helpers in one pass. Applies four agent-readable-code disciplines: orchestrator/helper structure, one default export per file (1fpf), schema-derived types, and cascading verb-first folder names. Gates code mutations on a single approval at Phase 3.
Install
curl -fsSL -L https://tetsukod.ai/api/skills/1fpf/download | tar -xz -C ~/.claude/skills/Drops the `1fpf/` skill folder into `~/.claude/skills/`. Once it lands, `/1fpf <module-path>` is available in any Claude Code session — no further wiring required.
What it does
/1fpf audits a target module against four agent-readable-code disciplines, drafts a refactor plan with the target folder tree and per-helper signatures, then pauses for explicit approval before mutating any code. Structural only — behavior changes and bug fixes stay out of scope.
The four disciplines it enforces:
- Orchestrator/helper pattern — the parent
index.tsreads as a thin recipe of imports and sequenced calls. Helpers live in their own subfolders. - One default export per file — file size is a downstream symptom of correct decomposition, not the rule itself.
- Schema-derived types —
Pick,GetPayload, indexed access, intersection variants. Never inline ad-hoc shapes. - Cascading domain structure — folder names are verb-first domain concepts (
crawlWebsite,scoreLeads,handleBounce). Noutils/,helpers/, orlib/at the leaf level.
What's inside
Four files, organized as orchestrator + reference. SKILL.md is the thin orchestrator (boot, five-phase workflow, hard constraints, args contract). Three sibling notes under reference/ carry the catalog: disciplines.md (the four disciplines with what / why / check / worked examples, including the schema-derived-type derivation toolkit), supporting-rules.md (JSDoc, step comments, colocated tests, vertical imports, escalation, naming, ordering, early returns, three-tier progressive disclosure), and violations.md (the audit hit list). The skill follows the disciplines it enforces — orchestrator at the root, one concern per reference file.
# 1fpf — orchestrator/helperify a module
A self-contained refactor skill that decomposes a god-file or sprawling module into orchestrator + helpers, applying all four agent-readable-code disciplines in one pass. Audits, plans, gates on approval, then mutates code with `Edit` / `Write` — never bulk-rewrites.
When to reach for it
An agent shipped a PR that's too sprawling to skim. An existing module has accreted into a god-file bundling parsing, validation, persistence, and notification with types invented inline. Before landing a new feature in a messy module — restructure first, then ship the feature into the clean shape. Do not reach for it for behavior changes, bug fixes, or reuse/quality review — /1fpf is structural only.
Related skills
instant-observability
Stand up Loki + Grafana for a Node project, wire a Pino logger to ship structured logs, install the Grafana MCP for in-conversation log queries, and refactor scattered console.* calls onto the new logger — all in one interactive run.
instant-mobile-notifications
Wire your Grafana alerts to your phone via ntfy push notifications — provisions a webhook contact point, default policy, and starter LogQL rules, with a phone-side smoke test before touching Grafana so dead push channels can't leak through to production.
design-handoff
Implement a Claude Design handoff zip — the HTML/CSS/JS prototype Anthropic's Claude Design tool exports — by wrapping /aide with handoff-specific context and binding the QA phase to a Playwright MCP visual-diff pass. Treats the handoff as a byte-exact, read-only source of truth while decomposing the production code via the 1fpf agent-readable-code disciplines.
Every new skill,
in subscribers' hands first.
Subscribers get the field notes behind each skill, early drops, and the system notes from the audits these skills came out of — every other Tuesday.