AGENT SKILL

extract-errors

Use when extracting, auditing, or standardizing error codes and messages across a codebase. Triggers on "error codes", "error messages", "unknown error", "extract errors", "error registry".

License 许可
Apache-2.0
最近更新
2026-11-14
Stars
★ 13
Forks
2

01 前言 Front Matter

name
extract-errors
version
1.4.20
description
Use when extracting, auditing, or standardizing error codes and messages across a codebase. Triggers on "error codes", "error messages", "unknown error", "extract errors", "error registry".
compatibility
Claude 4.5+, Sonnet 4.6, Haiku 4.5

03 SKILL.md 正文

Extract & Audit Error Codes

Cross-language skill for finding, cataloguing, and standardizing error codes and messages in any codebase.

When to use

  • "unknown error code" warning appears at runtime
  • New error messages need codes assigned
  • Error messages are inconsistent or duplicated across modules
  • Building or auditing an error registry

Instructions

1. Discover all error definitions

# JavaScript / TypeScript
grep -rn "throw new Error\|createError\|ErrorCode\.\|ERROR_" src/ --include="*.ts" --include="*.js"

# Python
grep -rn "raise \|class.*Error\|class.*Exception" . --include="*.py"

# Go
grep -rn "errors.New\|fmt.Errorf\|var Err" . --include="*.go"

# Rust
grep -rn "Err(\|thiserror\|anyhow" . --include="*.rs"

2. Check for unregistered errors

Compare discovered errors against the error registry file (e.g. errors.json, error_codes.py, errors.go). Flag any error string not present in the registry.

3. Assign codes to new errors

  • Use sequential numeric codes within the module's range (e.g. AUTH_001–AUTH_099)
  • Format: <MODULE>_<NNN> (e.g. GATE_001, HOOK_042)
  • Add to the registry with: code, message template, severity (info/warn/error/fatal), owner module

4. Report

Output a table:

Code Message Module Status
GATE_001 Identity verification failed identity-gate registered
HOOK_042 Circuit breaker open token-budget-guard NEW — needs code

5. Verify

Re-run discovery grep after updating the registry to confirm 0 unregistered errors remain.

04 同仓库更多 Skills

Horonomos-laps
Horonomos-laps/Yana-AI

openai--sentry--sentry

Use when the user asks to inspect Sentry issues or events, summarize recent production errors, or pull basic Sentry health data via the Sentry API; perform read-only queries with the bundled script and require `SENTRY_AUTH_TOKEN`.

★ 13
Horonomos-laps
Horonomos-laps/Yana-AI

ito-basket-compare

Compare Itô prediction-market baskets against a user's knowledge base, portfolio notes, financial context, watchlist, or research thesis. Use for read-only basket comparison and gap analysis without investment advice or live trading.

★ 13
Horonomos-laps
Horonomos-laps/Yana-AI

implementing-network-traffic-baselining

Build network traffic baselines from NetFlow/IPFIX data using Python pandas for statistical analysis, z-score anomaly detection, and hourly/daily traffic pattern profiling

★ 13
Horonomos-laps
Horonomos-laps/Yana-AI

detecting-evasion-techniques-in-endpoint-logs

Detects defense evasion techniques used by adversaries in endpoint logs including log tampering, timestomping, process injection, and security tool disabling. Use when investigating suspicious endpoint behavior, building detection rules for evasion tactics, or conducting threat hunting for stealthy adversary activity. Activates for requests involving evasion detection, defense evasion analysis, log tampering detection, or MITRE ATT&CK TA0005.

★ 13
Horonomos-laps
Horonomos-laps/Yana-AI

implementing-microsegmentation-with-guardicore

Implementing microsegmentation using Akamai Guardicore Segmentation to map application dependencies, create granular network policies, visualize east-west traffic flows, and enforce least-privilege communication between workloads across data centers and cloud.

★ 13
Horonomos-laps
Horonomos-laps/Yana-AI

ramdisk-tmpfs-patterns

暂无简介

★ 13