Error Writer for Openclaw

Error Writer automatically rewrites bad error messages and exception strings into clear, actionable variants tailored perfectly for end-users, APIs, and system logs.

phy041
v1.0.3
Mar 23, 2026
0
682
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install phy-error-writer

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install phy-error-writer using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Error Writer?

Error Writer is an indispensable addition to the Openclaw Skills ecosystem designed to optimize developer experience, UX writing, and application logging. The skill eliminates the top cause of unnecessary support tickets and debugging dead ends by systematically transforming vague or cryptic error strings into highly clear, informative messages. Operating entirely with zero external API dependencies and requiring no initial configuration, it instantly audits codebases for critical anti-patterns.

By processing your raw error inputs, constants files, or entire source directories, the skill breaks down every notification along audience and category dimensions. It then outputs a comprehensive rewrite report using a proven three-part formula: explaining exactly what happened, why it happened, and providing clear, actionable steps for what to do next.

Error Writer Use Cases

  • Refactoring Legacy Codebases: Auditing and updating old, vague error messages like "Something went wrong" across an entire repository.
  • Designing Developer-Friendly APIs: Converting internal system exceptions into structured, secure JSON response bodies utilizing strict SCREAMING_SNAKE_CASE error codes.
  • Polishing User Interfaces: Cleaning up end-user-facing text to strip away leaked technical details, internal file paths, or scary engineering jargon.
  • Standardizing System Logs: Structuring Ops and SRE alerts into clean JSON formats that preserve essential trace IDs, user contexts, and debugging parameters.

How Error Writer Works

  1. Input Ingestion: The developer triggers the skill via /error-writer or specific phrases, passing raw strings, snippet files, or a localized directory path.
  2. Classification: The engine classifies each discovered error message by targeted audience (End user, Developer, Ops/SRE, Internal dev) and error category (Validation, Auth, Timeout, etc.).
  3. Anti-Pattern Audit: It scans messages for critical vulnerabilities and poor styling, such as leaked internals, vague semantics, blame language, or missing recovery paths.
  4. 3-Part Formula Rewrite: It applies a standard architectural pattern summarizing [What happened] + [Why it happened] + [What to do next] to generate context-specific alternatives.
  5. Multi-Channel Delivery: The skill constructs distinct variations for UI display, API responses, and server logging infrastructure.
  6. Report and Constants Generation: It prints a structured Markdown report summary alongside a drop-in constants file and a tailored project style guide.

Error Writer Setup

To leverage this tool within your active Openclaw Skills workflow, use the designated command prefix in your terminal environment or chat interface:

# Run a single error rewrite or audit a file path directly
/error-writer src/errors.ts

# Scan your entire project repository for anti-patterns
/error-writer --audit src/

# Target a distinct user base segment directly
/error-writer --audience end-user "User not found in database"

Error Writer Data Schema & Taxonomy

The output report generated by the system details strict classifications and multi-channel code schemas:

Report Metrics Schema

Section Contents Purpose
Audit Summary Table matching severity counts (Critical, High, Medium) to observed anti-patterns. Evaluates code health metrics at a glance.
Rewrites Matrix side-by-side comparison of the legacy string against optimized UI, API, and log alternatives. Provides immediate drop-in text upgrades.
Constants File Generated codebase constants (errors.ts) utilizing structured key-value maps. Accelerates direct implementation.
Style Guide Project-specific formatting conventions (e.g., casing, active voice constraints). Maintains continuous team alignment.

Error Writer Advanced Features

  • Automated Anti-Pattern Sweeper: Automatically targets and flags high-risk issues like database leakage or fear-inducing system language.
  • Multi-Channel Generation: Evaluates a single input string to generate decoupled variants for UI modals, API response payloads, and SRE monitoring environments simultaneously.
  • Direct Constants Exporting: Compiles all restructured errors directly into clean, TypeScript/JavaScript exportable objects for rapid implementation.
  • Project-Specific Style Synthesis: Dynamically writes a tailor-made error message style guide deduced directly from your codebase's unique context.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*