function-signature-and-parameter-guidancelisted
Design and review caller-facing names and contracts: functions, tools, commands, CLI flags, parameters, config keys, env vars, profiles, event types, and node/edge identifiers. Check names, descriptions, help, docstrings, schemas, defaults, bounds, units, errors, outputs, mutation, and whether values reach behavior. Use when asked to "name a parameter", "parameter naming", "name this tool or command", "choose a flag, option, or config key", "design an options object", "one tool or two", "bool or enum here", "name a profile, field, event, node, or edge", "make names clear and unambiguous", "check ISO, platform, or language naming", "audit CLI/MCP/JSON-Schema help", "define accepted values or defaults", "what should this return on failure", "rename this without breaking callers", "improve an error message", "why did the caller pass the wrong argument", "why did this parameter do nothing", or "red-team these descriptions". Not for local variables, general prose, README copy, release notes, or commits.
ahundt/autorun · ★ 14 · Web & Frontend · score 67
Install: claude install-skill ahundt/autorun
# Function Signature and Parameter Guidance
<purpose>
A tool or parameter has four visible parts: its **name**, the **description** that teaches it,
the **error** when a caller gets it wrong, and the **behavior** matching all three. Callers are
increasingly AI agents reading a schema once and guessing, so merely *not wrong* still produces
wrong calls. Aim for text that makes the wrong call hard to write, and behavior that fails
loudly when it happens anyway.
**The failures that matter most return success** — a parameter validated, clamped, echoed, and
never used looks correct at every observable layer. So verify behavior matches the text (Group
B passes) before checking the text is right (Group A).
**An example gets read as the whole universe rather than as one case of a general principle.**
That is true of the caller reading your description and of you reading these checks, so the
words must state the concept explicitly — examples alone are not enough. Make the concept
behind the concept explicit, or it is missed entirely. **Apply this to this document too:**
every case named below is one instance of its rule, never the rule's limit.
</purpose>
<workflow>
## The Process
Correctness before brevity, always — trimming a wrong sentence produces a shorter wrong
sentence.
1. **Survey the codebase's existing vocabulary, then applicable standards.** Grep the
schema and CLI (a code-graph tool such as `search_graph` or `kit symbols` does the same
faster when the session