parameter-design
Skill0 starsChanged 4 days agoMITView on GitHub
Use when designing or reviewing a function, method, or constructor signature. Make calls unambiguous and misuse-resistant by splitting nullable/optional control switches, removing overload ladders, and keeping defaults behavior-neutral.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- dylanroscover/Embodytheir own version, first seen Sep 5, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- dylanroscover/Embody★ 213same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository108 other files it gives its agents.
- adaptive-estimationSkill
- adaptive-loop-budgetingSkill
- adopt-and-deleteSkill
- adversarial-reviewSkill
- agent-drives-uiSkill
- agentic-coding-loopSkill
- agent-otel-trajectorySkill
- agents-as-iac-modulesSkill
- ascii-ui-mockupsSkill
- authoring-html-emailSkill
- authoring-skills-vs-mcpSkill
- batched-ssh-enumerationSkill
- c4-architectureSkill
- challenge-the-premiseSkill
- codegraph-bootstrapSkill
- codegraph-worktree-startupSkill
- colocated-pod-tolerationsSkill
- command-creatorSkill
- complexity-budgetsSkill
- connector-readinessSkill
- context-anchored-patchingSkill
- continuous-issue-resolutionSkill
- credential-proxySkill
- criticality-tiered-reportingSkill
- data-connector-buildingSkill
- declarative-firstSkill
- disk-pressure-forensicsSkill
- early-return-over-elseSkill
- email-triageSkill
- enums-codify-behaviorSkill
- ephemeral-workspace-lifecycleSkill
- event-sourcingSkill
- evidence-claim-boundariesSkill
- exhaustive-matchSkill
- feature-coverage-not-just-line-coverageSkill
- full-disk-forensicsSkill
- gate-before-pushSkill
- github-pr-shepherdingSkill
- graceful-shutdown-stateful-agentsSkill
- grounded-generationSkill
- iac-incident-responseSkill
- iac-not-ad-hocSkill
- instrumented-service-scaffoldSkill
- interface-over-conditionalsSkill
- knowledge-routingSkill
- lean-on-oss-standardsSkill
- live-money-disciplineSkill
- live-state-verificationSkill
- loop-governance-and-learningSkill
- low-level-executor-task-specSkill
- map-dispatch-over-conditionalsSkill
- merge-conflict-disciplineSkill
- mermaid-diagramsSkill
- oke-arc-runners-opentofuSkill
- orchestrate-agySkill
- orchestrate-claudeSkill
- orchestrate-codexSkill
- orchestrate-geminiSkill
- otel-emit-at-willSkill
- parse-dont-validateSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Use this skill when defining or reviewing the signature of a function, method, or constructor.
- Very specific: line 87
Do not manufacture a config object for a one-or-two-parameter call.
- Distinctive: line 103
No parameter's presence/absence switches the operation's behavior.
- Distinctive: line 105
Every required input is required in the signature.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Parameter Design
Use this skill when defining or reviewing the signature of a function, method, or constructor. The signature is the contract: a caller should not be able to build an invalid or ambiguous call, and the parameter list should document what the operation needs. Push the cost of clarity onto the design, not onto every reader.
Rules
- No nullable/optional parameter used as a control-flow switch. A parameter whose presence or absence changes what the operation does is two functions hiding in one. Split it into distinct, well-named entry points instead of a nullable flag that the body branches on.
- No chained overloads or grab-bag of optionals. A long overload ladder, or a signature with many optional parameters, is a smell. Give each meaningful combination its own clearly-named entry point, or accept one explicit options/config object whose required fields are required.
- Disciplined defaults. A default is only for genuinely optional, behavior-neutral tuning (a timeout, a buffer size, a page limit). Never default a value that changes the meaning of the operation. Required things stay required — make illegal states unrepresentable.
- Self-documenting call sites. Required parameters are explicit; types carry
meaning (an enum instead of a boolean or a bare string — see
enums-codify-behavior); avoid positional-boolean traps wheref(x, true, false)tells the reader nothing.
The smell and the fix
A nullable parameter that gates behavior:
# smell: passing a key encrypts; passing nothing does not.
def save(data, key=None):
if key is None:
write_plaintext(data)
else:
write_encrypted(data, key)
# fix: two operations, each with exactly the inputs it needs.
def save_plaintext(data): ...
def save_encrypted(data, key): ... # key is required here, not optionalAn overload ladder / optional grab-bag:
# smell: which combination is valid? the reader cannot tell.
def fetch(url, retries=None, timeout=None, cache=None, auth=None, stream=None): ...
# fix: required inputs explicit; optional tuning in one config object.
def fetch(request: Request, options: FetchOptions = FetchOptions()): ...
# Request carries the required url + auth; FetchOptions carries
# behavior-neutral tuning (retries, timeout, cache) with safe defaults.A positional-boolean trap:
# smell: render(doc, true, false) — unreadable at the call site.
def render(doc, minify, inline_styles): ...
# fix: an explicit mode and named options.
def render(doc, mode: RenderMode, options: RenderOptions): ...When to use
- Adding or reviewing any public function, method, or constructor signature.
- A signature is growing optional parameters, or you are about to add the second or third overload.
- You catch yourself writing
if param is None:(orif not param:) at the top of a function to pick between behaviors.
When not to / keep it simple
- A genuinely optional, behavior-neutral tuning value (timeout, limit, seed) is fine as a defaulted parameter — that is exactly what defaults are for.
- A single optional value that is absence of data, not a behavior switch (an optional middle name, an optional cursor for pagination), is fine. The test is: does presence change what the operation does, or only which data it has?
- Do not manufacture a config object for a one-or-two-parameter call. Respect the
complexity budget (
complexity-budgets).
Anti-patterns
- A "do everything" function whose first lines branch on which optional arguments were supplied.
- Boolean parameters that select behavior (
f(x, recursive=True)) where the name at the call site is invisible — prefer an enum or a separate function. - Defaulting a destination, a mode, an account, or any other meaning-bearing value so that an under-specified call silently does something.
- Adding overload number four instead of asking whether these are really different operations that deserve different names.
Review checks
- No parameter's presence/absence switches the operation's behavior; such cases are split into named functions.
- Every required input is required in the signature; no meaning-bearing default.
- Defaults are behavior-neutral tuning only.
- Behavioral variants are distinct named entry points or carry an enum, not a
boolean or string flag (
enums-codify-behavior). - The call site reads clearly without the reader opening the definition.
Cross-link: composes with enums-codify-behavior (types over flags),
interface-over-conditionals (behavioral variants behind one interface), and
complexity-budgets (cap parameter count before a signature sprawls).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

