From patchy-bot
Forensic-grade change analysis. Use after any Claude Code session to build a complete, precise inventory of every file created, modified, or deleted — with intent-vs-reality comparison and unexpected change detection. Trigger phrases: "what exactly changed", "change forensics", "show me everything that was touched", "full change inventory", "what files were affected", "trace the changes", "what did the session modify", "forensic analysis", "change map", "what got changed and why", "list all changes", "show me the diff breakdown". Goes deeper than git diff — traces the complete blast path of changes including hidden side effects, auto-generated files, config mutations, and lock file churn. Use before post-changes-audit, diff-review, or any time you need a precise accounting of a session's work. Feeds its file list and UNEXPECTED items directly into impact-radar, scope-guard, and regression-guard.
npx claudepluginhub kman182401/patchy-operationalThis skill uses the workspace's default tool permissions.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Compares coding agents like Claude Code and Aider on custom YAML-defined codebase tasks using git worktrees, measuring pass rate, cost, time, and consistency.
Forensic-grade inventory of every change made in a session. Answers three questions precisely: What changed? What was expected to change? What was NOT expected to change?
Execute every step. Do not skip steps because you think results will be empty — absence of findings is itself a valid finding.
# Full working tree status
git status --porcelain=v2 --branch
# Staged diff with stats
git diff --cached --stat
git diff --cached
# Unstaged diff
git diff --stat
git diff
# Recent commit history (last 10)
git log --oneline -10
# Stash state
git stash list
# Files modified in last 30 minutes (captures what git may not show)
find . \
-not -path './.git/*' \
-not -path './node_modules/*' \
-not -path './__pycache__/*' \
-not -path './dist/*' \
-not -path './build/*' \
-newer .git/index \
-type f \
-printf '%T@ %p\n' 2>/dev/null | sort -rn | head -50
# New untracked files
git ls-files --others --exclude-standard
# Recently deleted files
git diff --name-status --diff-filter=D HEAD 2>/dev/null
For each file found in Steps 1–2, assign exactly one classification:
| Class | Meaning |
|---|---|
PRIMARY | Direct target of the stated task |
COLLATERAL | Changed as a known side effect of primary work |
LOCKFILE | Package lock / dependency manifest updated |
GENERATED | Auto-generated (migrations, compiled output, snapshots, mocks) |
CONFIG | Config, environment, or settings file |
TEST | Test or spec file |
UNEXPECTED | Changed with no clear link to the stated task — flag for scope review |
For each PRIMARY and UNEXPECTED file, extract:
# Line counts
git diff --numstat HEAD -- "$FILE" 2>/dev/null
# Function/class diffs (added or removed definitions)
git diff HEAD -- "$FILE" 2>/dev/null | grep "^[+-]" | \
grep -E "^[+-](def |async def |class |function |async function |export (function|class|const|default)|pub fn |func )[A-Za-z]"
# Import changes
git diff HEAD -- "$FILE" 2>/dev/null | grep "^[+-]" | \
grep -E "^[+-](import |from |require\(|#include)"
# Config key changes (for .json, .yaml, .toml, .env)
git diff HEAD -- "$FILE" 2>/dev/null | grep "^[+-]" | \
grep -vE "^[+-]{3}" | head -20
Extract the stated task intent from these sources (priority order):
.claude/plan.md, PLAN.md, TODO.mdgit log -1 --format=%BCompare:
# Lock file changes without explicit dependency update in context
git diff --name-only | grep -E "(package-lock\.json|yarn\.lock|poetry\.lock|Cargo\.lock|go\.sum|pnpm-lock\.yaml)"
# Secrets or sensitive files touched
git diff --name-only | grep -iE "(\.env|\.pem$|\.key$|credentials|secret|token)"
# Config files outside stated scope
git diff --name-only | grep -E "\.(json|yaml|yml|toml|ini|conf)$"
# Binary files modified (cannot scan content)
git diff --name-only | xargs file 2>/dev/null | grep -iv "text" | head -10
## Change Forensics Report
**Session scope (inferred):** [task description]
**Collection window:** git diff + filesystem last 30min
**Total changed:** N files (+X added / -Y removed / Z modified)
### Primary Changes (expected, task-related)
| File | Class | +/- Lines | Summary |
|------|-------|-----------|---------|
| path/to/file.py | PRIMARY | +42 / -8 | Added validation fn, updated error handling |
### Collateral Changes (side effects)
| File | Class | +/- Lines | Summary |
|------|-------|-----------|---------|
### Infrastructure Changes (lock files, generated, config)
| File | Class | +/- Lines | Summary |
|------|-------|-----------|---------|
### Tests Changed
| File | Class | +/- Lines | Summary |
|------|-------|-----------|---------|
### ⚠️ UNEXPECTED Changes (not explained by stated task)
| File | Class | +/- Lines | Why Flagged |
|------|-------|-----------|-------------|
### Intent vs. Reality
- **Expected but NOT changed:** [files implied by task but untouched]
- **Changed but NOT explained:** [files changed with no clear task link]
- **Gap assessment:** ALIGNED | MINOR DRIFT | SIGNIFICANT DRIFT
### Side Effects Detected
[List with severity, or "None detected"]
### Raw File List (pipe to other tools)
[newline-separated list of all changed files]
Feed the output of this skill into:
impact-radar — pass the raw file list as the trace targetscope-guard — pass the UNEXPECTED items for scope reviewregression-guard — pass the PRIMARY files as regression targetspost-changes-audit — this skill runs as Stage 1 of the full audit chain