Skills juliusbrussee caveman Caveman

surgical-patch

Use it when:
You're fixing a bug or making a small behavior change, and nothing else in the code should move.
It does:
Reproduces the failure when that's cheap, traces it to its cause, and changes only the smallest part of the code responsible.
You get:
A minimal fix with a regression test, and no cleanup, renaming or new abstractions.
Unlike investigate-first:
That one stops at a diagnosis; this one makes the fix and proves it.
Runs:
On its own, whenever the agent sees a task that fits; it's a short list of rules, not a step-by-step guide.

Skill 13 of 16 in the Caveman bundle, after lean-build and before safe-refactor.

TL;DR

The agent reproduces the failure first if that's cheap, otherwise gathers the strongest evidence it can. It traces the symptom to what actually causes it and fixes the code there, as narrowly as possible, rather than patching wherever the symptom shows up. It leaves unrelated behavior and your own edits alone, skips any cleanup, renaming or abstraction beyond the fix, and adds only the regression test the task needs. It then runs that test plus the nearest wider check the change affects, and stops once the failure is fixed and the test passes.

Summarizes the skill at bad48a0.

npx skills add https://github.com/juliusbrussee/caveman --skill surgical-patch
Total Downloads
118,599 on skills.sh, Nov 9, 2026
Repo stars
118,416 juliusbrussee/caveman
First seen
Aug 11, 2026 on skills.sh
Weekly Downloads
6.9K
-48% over the 8 weeks to Nov 9
Weekly values
Week toInstalls
Sep 2113,066
Sep 2810,850
Oct 510,087
Oct 128,239
Oct 197,093
Oct 267,564
Nov 27,185
Nov 96,852
Category

Test-first work, implementation from specs, git hygiene and scope control.

Everything for building software: planning, coding, debugging, design, frameworks, cloud, agents and skills.

Type

A multi-step process the agent follows: interview, debug, run a TDD loop, review.

Effect

Its own steps create or change files, git state or local tools.

Needs

Instructions only. Works in any agent that supports skills.

Publisher

Everyone else. Unverified vendor claims default to community.

Topics

SKILL.md

From juliusbrussee/caveman at bad48a0. Checked daily, last changed Oct 20, 2026.

Frontmatter
name: surgical-patch
description: Fix bugs and small behavior changes at the narrowest responsible layer. Use when regression proof, preserved surrounding behavior, and task-relevant tests matter.

Surgical patch

Reproduce failure first when economical; otherwise capture strongest available evidence.

  • Trace symptom to responsible mechanism.
  • Change narrowest layer that owns incorrect behavior.
  • Preserve unrelated behavior and user changes.
  • Avoid cleanup, renaming, and abstraction outside fix.
  • Add only regression proof relevant to task.

Run focused proof plus nearest affected gate. Stop when failure is fixed and regression proof passes.