Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add mahmoud20138/Tradecraft --skill git-phase-restoregit clone --depth 1 https://github.com/mahmoud20138/TradecraftWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/mahmoud20138/tradecraft/git-phase-restore)<a href="https://agentmods.dev/skills/mahmoud20138/tradecraft/git-phase-restore"><img src="https://agentmods.dev/badge/skills/mahmoud20138/tradecraft/git-phase-restore/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/mahmoud20138/tradecraft/git-phase-restore"><img src="https://agentmods.dev/badge/skills/mahmoud20138/tradecraft/git-phase-restore.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00165 | $0.03019 |
| Opus 5 | $0.00082 | $0.01510 |
| Sonnet 5 | $0.00033 | $0.00604 |
| Haiku 4.5 | $0.00016 | $0.00302 |
Grade A, and why
git-phase-restore scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 368 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Git Phase Restore — Autonomous Development Phase Recovery
Leverage Git's full history to identify development phases and restore any project state automatically. No manual snapshots needed — Git already has everything.
Core Philosophy
Every Git repository already contains a complete record of every development phase. This skill teaches Claude to read that record intelligently and act on it:
- Commits with conventional messages → semantic phase boundaries
- Tags → explicit version milestones
- Branches → parallel development tracks
- Timestamps → temporal navigation
- Diffs → understanding what each phase changed
Instead of maintaining separate snapshot systems, this skill mines Git itself as the single source of truth.
When to Trigger
Always trigger this skill when the user wants to:
| Intent | Example phrases |
|---|---|
| Restore a phase | "go back to when auth worked", "restore to v1.2", "undo last feature" |
| Explore history | "show project phases", "what was the state on March 1st", "git timeline" |
| Find a regression | "when did this bug appear", "find when X broke", "bisect this issue" |
| Compare phases | "diff between auth and current", "what changed since last week" |
| Inspect a past state | "show me the code before the refactor", "what did file X look like in phase Y" |
| Undo / rollback | "roll back", "undo", "revert", "go back" (in any Git project context) |
Phase Detection Strategy
Development phases are identified by analyzing Git history through multiple lenses.
Run scripts/detect_phases.sh in the project root to get a structured phase map,
or follow the manual steps below.
1. Tag-Based Phases (highest confidence)
Tags are explicit developer-placed milestones. Always check these first.
# List all tags with dates and messages
git tag -l --sort=-creatordate --format='%(creatordate:short) %(refname:short) %(subject)'
2. Semantic Commit Phases (high confidence)
Parse conventional commit messages to detect phase boundaries. A new phase starts when:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 368 lines · 165 tokens per session scan A 93e99ca4555d
git-phase-restore is a skill published in the GitHub repository mahmoud20138/Tradecraft (15 stars, last pushed 4mo ago), licensed MIT. It adds 165 tokens to every session and 3,019 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
resolve-pr-comments
Evaluate, fix, answer, and reply to GitHub pull request review comments and conversation comments. Handles both change requests (fix or skip) and reviewer questions (explain using reasoning recalled from past Claude Code transcripts). Use when the user asks to "resolve PR comments", "fix review comments", "address PR…
create-pr
Create a GitHub pull request with a drafted title and description. Use when the user asks to "create a PR", "create a pull request", "open a PR", or "submit a PR".
changelog-rules
Shared changelog conventions and formatting rules referenced by /create-changelog and /update-changelog. Not typically invoked directly.
update-pr
Update an existing GitHub pull request's title and description to reflect the current state of the branch. Use when the user asks to "update the PR", "update PR description", "update PR title", "refresh PR description", or "sync PR with changes".
fetch-pr-comments
Fetch and summarize review feedback and conversation from a GitHub PR (unresolved review threads, review bodies, and PR conversation comments) without making changes. Use when the user asks to "fetch PR comments", "show PR comments", "check PR for unresolved comments", "list review comments", "what comments are on the…
reply-to-pr-threads
Draft, confirm, and post replies to GitHub PR review threads. Handles per-category reply formatting, re-fetches thread resolution state so auto-resolved threads are skipped, and posts via GraphQL. Use when the user asks to "reply to PR threads", "post PR thread replies", or "draft PR reply messages".