| name | nw-ab-validate-spec |
| description | PROCEDURE — validate an EXISTING agent spec against the 19-item checklist. Trigger: checking a spec for compliance (also the shared composition target create/migrate/merge invoke). One job: run the checklist, report pass/fail. |
| user-invocable | false |
nw-ab-validate-spec (PROCEDURE)
Kind: PROCEDURE | One job: validate an agent spec | One trigger: an existing agent spec must be checked for compliance (standalone, or composed by create/migrate/merge after a write).
This is the SHARED composition target. nw-ab-create-agent, nw-ab-migrate-monolith, and nw-ab-merge-agents all invoke this skill after writing — never re-inline the checklist.
Deterministic step-sequence (run every time, in order)
At execution start create these as TaskCreate items and run in order:
- Frontmatter — name, description, model, tools, maxTurns, skills present. Gate: all required fields present.
- Line Count —
wc -l total under 400; domain knowledge in skills. Gate: count reported, under threshold.
- Divergence Only — flag any instruction restating Claude defaults. Gate: zero redundant instructions.
- Language Tone — scan for CRITICAL/MANDATORY/ABSOLUTE (exception: skill-loading MUST). Gate: zero violations outside skill loading.
- Examples — count
### Example sections. Gate: 3-5 present.
- Least Privilege — tools list contains only what the agent needs; no Write/Edit for reviewers. Gate: no unnecessary tools.
- Safety by construction (GDP-0) — which producer makes the unsafe action unrepresentable? Tool-surface frontmatter fields and typed grammar first; a hook only with a recorded reason, never prose. Gate: zero prose security sections; any hook cites its construction-can't-cover reason.
- Affirmative Phrasing — convert "Don't do Y" to "Do X". Gate: zero negative phrasings.
- Terminology — one term per concept. Gate: consistent terminology.
- Description Quality — description states WHEN to delegate. Gate: trigger condition present.
- Skill Loading — mandatory section with imperative language + explicit
~/.claude/skills/nw-{name}/SKILL.md paths. Gate: present, paths explicit.
- Load Directives — every workflow phase has
Load: matching frontmatter skills. Gate: no phases missing loads.
- No Orphan Skills — every frontmatter skill appears in a phase. Gate: zero orphans.
- Workflow Format — workflow is numbered task list (
N. **Name** — action. Gate: condition.), not prose. Gate: all phases numbered.
- Success Criteria Format — criteria are numbered/checkbox list, not prose. Gate: structured.
- Caveman House Style — dry/declarative, tables + compact lists, lean body, deep knowledge in skills. Gate: confirmed.
- Reasoning Mandate Present —
## Reasoning Mandate section present. Gate: present.
- A05/A06 Literal Anchors — verbatim
You MUST load your skill files OR Your FIRST action before any other work AND token ~/.claude/skills/nw-. Gate: both present.
- One Job, One Trigger — one job + one trigger per asset; KNOWLEDGE vs PROCEDURE classified; PROCEDURE states trigger + deterministic sequence + composition; zero multi-job parameterized switches; existing command + agent NAMES preserved (no rename/proliferation; new command is the rare
/nw-* exception). Gate: confirmed.
Then run the anti-pattern scan (nw-ab-anti-patterns). Gate: zero anti-patterns.
Composition
- COMPOSES (KNOWLEDGE):
nw-ab-validation-checklist (the 19-item data), nw-ab-anti-patterns, nw-ab-critique-dimensions, nw-agent-testing.
- Note: the validator script
scripts/validation/validate_framework_templates.py (A05/A06 literal checks) is run by the orchestrator/reviewer, not inside this skill.
Success Criteria