retrofit

Reconciles unreviewed code changes against intent and drafts missing tests, docs, and review findings.

Updated May 26, 2026
One-click install
npx skills add https://github.com/robot-denny/ai-sketchlab --skill retrofit-robot-denny
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: retrofit
Source: https://github.com/robot-denny/ai-sketchlab/tree/main/.agents/skills/retrofit
Command: npx skills add https://github.com/robot-denny/ai-sketchlab --skill retrofit-robot-denny

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Changes made outside a spec → plan → implement workflow skip tests, code review, and documentation, leaving the codebase undocumented and unverified. Retrofit closes that gap after the fact by analyzing the actual diff, running reviewers, and proposing the missing artifacts before the change leaves your machine. ## Core Features & Use Cases - Intent-vs-diff reconciliation: Compares your description of a change against the actual git diff (committed, uncommitted, and untracked files) and surfaces discrepancies as findings. - Parallel review orchestration: Dispatches accessibility, code-quality, and performance reviewers against the computed retrofit diff, collecting findings by severity. - Test and documentation gap analysis: Classifies the work type (new-capability, change-to, fix-infra) and drafts the appropriate tests, feature docs, or runbooks. - Confirm-before-write workflow: Presents a two-bucket proposal (auto-applicable vs. human decision) and applies only what you explicitly approve. - Use Case: You made a quick front-end tweak directly and are about to commit. Run retrofit to get a review of the diff, edge cases you missed, and drafted tests and doc updates — then approve only what you want applied. ## Quick Start Ask the AI to run the retrofit skill with a short description of what you changed before committing your work.

Frequently Asked Questions about retrofit

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

FAQPage Schema
How do I review code changes that were already committed?

Retrofit computes the full change set using git merge-base against the upstream tracking branch, covering committed, uncommitted, and untracked files. It then runs code reviewers against that combined diff rather than relying on a plain staged diff, which would miss committed work.

How to add tests and docs after making a quick code change?

Retrofit drafts tests and documentation based on the actual diff and the classified work type, then presents them as a reviewable checklist. Nothing is written until you explicitly approve which items to apply.

Does retrofit work if I already pushed my changes?

Retrofit is designed to run before committing or before pushing, computing scope from the merge-base with the upstream branch. If changes are already pushed, you can pass an explicit git range or ref to define the scope manually.

What happens if the code reviewers are not available?

If a reviewer agent is not found, retrofit suggests restarting the session since agents load at session start. If a role has no reviewer under any name, it runs that review pass inline under the same severity scale so no dimension is silently dropped.

Will retrofit modify my files automatically?

No. Retrofit follows a strict propose-then-confirm rule: it drafts all tests, doc edits, and cleanups, presents them in two buckets (auto-applicable vs. human decision), and writes nothing until you explicitly approve specific items.