narrow-patch-authoring

Generate minimal code patches addressing root causes from forensic debugging evidence.

Updated Mar 22, 2026
One-click install
npx skills add https://github.com/Sanchez-78/crypto-trading-bot --skill narrow-patch-authoring
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: narrow-patch-authoring
Source: https://github.com/Sanchez-78/crypto-trading-bot/tree/main/.claude/skills/narrow-patch-authoring
Command: npx skills add https://github.com/Sanchez-78/crypto-trading-bot --skill narrow-patch-authoring

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

When fixing production bugs, developers often add unnecessary refactoring, tech debt cleanup, or address symptoms instead of root causes, leading to larger, riskier changes that introduce new issues and slow down code reviews.

Core Features & Use Cases

  • Root Cause-Only Fixes: Enforces changes that exclusively address the identified root cause from forensic evidence, with no unrelated modifications.
  • Invariant Preservation Checks: Includes a self-review checklist to ensure existing system behavior, position entry/exit, and dashboard metrics remain intact after the patch.
  • Evidence-Backed Commits: Requires commit messages that cite concrete forensic evidence (logs, code paths, state) for full traceability.
  • Use Case: For a developer debugging a timeout bug in a crypto trading bot's paper trade executor, use this skill to create a 2-line patch that fixes the wrong variable reference, without cleaning up unused functions or renaming variables for clarity.

Quick Start

Use the narrow-patch-authoring skill to create a minimal patch that fixes the root cause of the timeout bug identified in the latest forensic report, without adding any unrelated changes or refactoring.

Frequently Asked Questions about narrow-patch-authoring

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a minimal git commit that fixes a bug without unrelated refactoring?

To create a minimal git commit, you must restrict code changes exclusively to the root cause identified during forensic debugging. This patch authoring approach eliminates unnecessary refactoring, preserving system invariants and reducing regression risk in production maintenance workflows.

What is forensic debugging and how does it support evidence-backed patch authoring?

Forensic debugging is the process of tracing system failures using concrete evidence like logs and state paths. It supports evidence-backed patch authoring by pinpointing exact root causes, allowing developers to generate minimal code changes that fix bugs without altering unrelated system behavior.

How do I write an evidence-backed git commit message for a production bug fix?

Writing an evidence-backed git commit message requires citing concrete forensic evidence, such as specific logs, code paths, or system states. This practice ensures full traceability for the minimal patch and accelerates code review cycles by proving the root cause was exclusively addressed.

Can I use minimal patch authoring for critical systems like a crypto trading platform?

Yes, minimal patch authoring is designed for critical systems like trading platforms where preserving existing invariants and minimizing change risk are mandatory. It enforces invariant preservation checks to ensure position entry, exit, and dashboard metrics remain completely intact after bug resolution.

Why do my production bug fixes introduce new regressions during code review?

Production bug fixes introduce regressions when developers add unnecessary modifications or address symptoms instead of root causes. By enforcing strict adherence to minimal change principles and invariant preservation validation, you can eliminate unrelated modifications and significantly reduce regression risk.

When should I not use minimal code changes for bug fixing?

You should not use minimal code changes when a bug requires broader architectural refactoring or when addressing technical debt. This approach mandates that patches exclusively address the identified root cause, meaning any necessary cleanup or unrelated variable renaming must be handled in separate commits.