| name | inspequte-rule-spec |
| description | Author or refine an inspequte rule spec from a rule idea, optional plan.md, and target rule-id. Use when writing src/rules/<rule-id>/spec.md from a fixed template while avoiding implementation details. |
inspequte rule spec
Inputs
- Target
rule-id.
- Rule idea text.
- Optional
src/rules/<rule-id>/plan.md.
Outputs
- Create or update
src/rules/<rule-id>/spec.md.
- Keep scope contractual; avoid implementation details beyond constraints.
Fixed Template
Use this exact section order:
## Summary
## Motivation
## What it detects
## What it does NOT detect
## Examples (TP/TN/Edge)
## Output
## Performance considerations
## Acceptance criteria
Minimal Context Loading
- Read
src/rules/AGENTS.md.
- Read existing
src/rules/<rule-id>/spec.md if present.
- Read
src/rules/<rule-id>/plan.md if present.
- Read at most one related rule spec for style alignment.
- Do not perform repo-wide scans.
Guardrails
- Treat
spec.md as a behavior contract, not a design doc.
- Do not include Rust APIs, struct names, function names, or algorithm internals.
- Keep messages user-facing and actionable.
- In
## Summary, define intended rule metadata (id, name, description) clearly so implementation can map it directly.
- State annotation scope explicitly:
@Suppress-style suppression is unsupported, and only JSpecify annotations are supported for annotation-driven semantics.
Definition of Done
spec.md exists under the target rule directory.
- All template sections are present and non-empty.
- Examples include true positive, true negative, and edge cases.
- Implementation-specific details are excluded.