agentleFS
Siddharth00Siddharth00/agent-revamp-skills/CLAUDE.md

agent-revamp-skills

CLAUDE.md1 starsChanged 7 months agoMITView on GitHub

This file is loaded automatically by Claude Code at the start of every session in this repo. It defines the project's purpose, operating rules, and constraints that all agents and skills must follow. agent-revamp-skills is a library of Claude Code skills (prompt-driven slash commands) and sub-agent definitions for driving large-scale, incremental codebase migrations — the kind that take weeks or months, cross team boundaries, and carry real production risk. The skills are organized into eight ordered phases that mirror a…

The file

We split this CLAUDE.md into the rules it gives an agent

12 rules. About 0 are common, 7 are distinctive, and 5 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈7

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every skill in skills/ must contain all nine required sections in order.

    line 31
  2. Very specific:

    Never run a migration step against a production system without an explicit --env prod flag confirmed by the user in the current session.

    line 58
  3. Distinctive:

    Never delete source code that is still referenced.

    line 60
  4. Distinctive:

    All destructive operations (schema drops, service deletions, traffic cuts) require a dry-run output reviewed by the user before execution.

    line 61
  5. Distinctive:

    Do not add features, documentation, or refactors that weren't asked for.

    line 66
  6. Distinctive:

    Do not create files outside the repo structure without asking.

    line 67
  7. Distinctive:

    If an agent cannot find evidence for an assumption, it must say so rather than guess.

    line 72
  8. Distinctive:

    All generated artifacts (specs, plans, diffs) must be written to a file, not only printed to stdout.

    line 75
  9. Very specific:

    Check for AUDIT.md at the repo root: If it exists, read it fully before proceeding.

    line 85
  10. Very specific:

    Check for MIGRATION-PLAN.md at the repo root: If it exists, read it fully before proceeding.

    line 91
  11. Very specific:

    Check for stale artifacts: If AUDIT.md exists and its audit date (the Audit date field in the header table) is more than 90 days before …

    line 96
  12. Distinctive:

    If neither file exists: proceed normally.

    line 105

≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
CLAUDE.md

CLAUDE.md — agent-revamp-skills

This file is loaded automatically by Claude Code at the start of every session in this repo. It defines the project's purpose, operating rules, and constraints that all agents and skills must follow.


Project Context

agent-revamp-skills is a library of Claude Code skills (prompt-driven slash commands) and sub-agent definitions for driving large-scale, incremental codebase migrations — the kind that take weeks or months, cross team boundaries, and carry real production risk.

The skills are organized into eight ordered phases that mirror a typical strangler-fig migration:

PhaseDirPurpose
0skills/00-metaRepo hygiene, skill authoring, template maintenance
1skills/01-auditUnderstand the current system — inventory, deps, risk
2skills/02-strategizeDecide the migration approach and sequence
3skills/03-prepareScaffolding, CI gates, feature flags, dual-write infra
4skills/04-migrateThe actual migration, split by layer
5skills/05-validateBehavioral equivalence, load tests, diff checks
6skills/06-cut-overTraffic shifting, DNS, kill-switch
7skills/07-stabilizePost-cut-over hardening, cleanup, retro

Skill Anatomy Rules

Every skill in skills/ must contain all nine required sections in order. See skills/_template/SKILL.md for the canonical template.

Required sections (in order):

  1. # Metadata — name, phase, version, owner
  2. # Purpose — one-paragraph plain-English summary
  3. # Trigger Conditions — when to use this skill (and when NOT to)
  4. # Inputs — required and optional context the skill needs
  5. # Steps — numbered, ordered, imperative instructions to Claude
  6. # Agent Handoffs — which sub-agents to spawn, and with what prompts
  7. # Outputs — artifacts produced (files, reports, PRs, etc.)
  8. # Validation Gates — criteria that must pass before declaring the skill done
  9. # References — links to patterns, anti-patterns, or related skills

Rules:

  • A skill must be self-contained enough that a cold Claude session can execute it.
  • Steps must be imperative ("Read X", "Search for Y") — not descriptive ("X should be read").
  • Agent Handoffs must name the agent file in agents/ and pass a complete prompt template.
  • Validation Gates are non-negotiable checklists — do not mark a skill complete unless every gate passes.

Core Constraints

These constraints apply to all sessions, agents, and skills in this repo:

Safety

  • Never run a migration step against a production system without an explicit --env prod flag confirmed by the user in the current session.
  • Never delete source code that is still referenced. Run equivalence validation first.
  • All destructive operations (schema drops, service deletions, traffic cuts) require a dry-run output reviewed by the user before execution.

Scope

  • Skills must focus on their declared phase. Cross-phase work belongs in a new skill.
  • Do not add features, documentation, or refactors that weren't asked for.
  • Do not create files outside the repo structure without asking.

Agent Behavior

  • Sub-agents operate in read-only mode by default unless the parent skill explicitly grants write access.
  • Agents must cite the file path and line number for every claim about existing code.
  • If an agent cannot find evidence for an assumption, it must say so rather than guess.

Output Quality

  • All generated artifacts (specs, plans, diffs) must be written to a file, not only printed to stdout.
  • Reports must include a confidence level (High / Medium / Low) and a list of assumptions made.

Session Startup

At the start of every session in this repo, before taking any action or responding to any request, Claude Code must:

  1. Check for AUDIT.md at the repo root. If it exists, read it fully before proceeding. AUDIT.md is the ground truth about the codebase being migrated. Any recommendation made without reading it may contradict findings already established. If AUDIT.md is present but its Sign-off status is PENDING, note this to the user before running any Phase 2 or later skill — Phase 2 requires sign-off.
  2. Check for MIGRATION-PLAN.md at the repo root. If it exists, read it fully before proceeding. MIGRATION-PLAN.md defines the agreed sequencing, blocked units, and phase-gate criteria for this project. Any Phase 4 action that contradicts the plan's dependency ordering or skips a phase gate must be flagged to the user before executing.
  3. Check for stale artifacts. If AUDIT.md exists and its audit date (the Audit date field in the header table) is more than 90 days before today's date, warn the user: "AUDIT.md is N days old. Dependency health, CVE status, and coverage data may have changed. Consider re-running codebase-audit before continuing."
  4. Do not re-read these files on every tool call — read them once at session start and hold the findings in context. If the user explicitly updates AUDIT.md or MIGRATION-PLAN.md during the session, re-read the updated file before continuing.

If neither file exists: proceed normally. Their absence means the project is in Phase 0–1 and no prior audit or plan has been committed yet.


Quick Reference

# Run a skill as a slash command
/audit                  # Phase 1 — inventory and risk map
/revamp-spec            # Phase 2 — migration strategy doc
/migrate                # Phase 4 — execute a migration unit
/validate               # Phase 5 — equivalence check

See docs/claude-code-setup.md for first-time setup instructions. See docs/how-to-pick-a-skill.md to choose the right skill for your task. See CONTRIBUTING.md to add a new skill to the library.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.