Writing Error Messages
Quick start
Collect or infer:
- •Error type (validation, system, network, permission, not-found)
- •Severity (blocking, degraded, informational)
- •User action that triggered error
- •Available recovery actions
Then produce output using TEMPLATES.md. Validate with RUBRIC.md.
Workflow
- •Classify error using reference/error-categories.md
- •Identify what the user was trying to do
- •Write the error title (what happened)
- •Write the body (why it happened, if helpful)
- •Write the action (how to fix it)
- •Run the rubric check. Revise until it passes.
Degrees of freedom
- •Low: Error structure (title + body + action) is fixed
- •Medium: Tone adjusts by severity per reference/error-categories.md
- •Allowed variation: Body can be omitted if cause is obvious and action is clear
Constraints
- •Title: max 60 characters
- •Body: max 150 characters
- •Action label: max 25 characters
- •Never blame the user
- •Never expose technical details (stack traces, error codes) in user-facing copy
References
- •Templates: TEMPLATES.md
- •Rubric: RUBRIC.md
- •Examples: EXAMPLES.md
- •Error categories: reference/error-categories.md