change-evolution
Reviews PR diffs for CD readiness, reversibility, and design-quality risks such as YAGNI, deep modules, and complexity budget. Use when a PR is large, mixes refactor with behavior, or introduces flags/migrations/stranglers.
- License 许可
- MIT
- 最近更新
- 2026-11-14
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- change-evolution
- description
- Reviews PR diffs for CD readiness, reversibility, and design-quality risks such as YAGNI, deep modules, and complexity budget. Use when a PR is large, mixes refactor with behavior, or introduces flags/migrations/stranglers.
- allowed-tools
- Bash Read Grep Glob
02 资源文件 2
- 参考文档references/anti-patterns.md1.2 KB
- 参考文档references/checklist.md4.1 KB
03 SKILL.md 正文
Change & Evolution Review
Quality Review pass covering taxonomy categories 5 Change & evolution (CD) and 4 Design quality. Emits Conventional Comment findings in the bug-finder schema.
Inputs
- PR URL: Full GitHub/Enterprise PR URL
- OUTPUT_DIR (optional): Defaults to private
mktemp -d - Analysis JSON (optional):
$OUTPUT_DIR/pr-analysis-<PR_NUMBER>.json
Outputs
Writes $OUTPUT_DIR/change-evolution-<PR_NUMBER>.json:
{
"pr_number": 123,
"pass": "change-evolution",
"findings": [
{
"severity": "critical|high|medium",
"label": "issue|suggestion|nitpick|question|thought|praise",
"decoration": "blocking|non-blocking|if-minor",
"path": "exact/path",
"line": 42,
"title": "5-10 words",
"body": "explanation",
"suggestion": "concrete fix",
"suggested_change": "exact replacement for lines start_line..line, or omit"
}
]
}
suggested_change posts as a committable GitHub suggestion. Emit it only
when the fix is confined to the commented lines, you can reproduce the range
verbatim from the diff, and it runs under ~10 lines; otherwise leave the prose
suggestion alone. Most findings in this pass are design-level and will not
qualify.
Step 0: Parse arguments
PR_URL="$1"
OUTPUT_DIR="${2:-$(mktemp -d -t pr-review-XXXXXX)}"
mkdir -p "$OUTPUT_DIR"
PR_NUMBER=$(echo "$PR_URL" | grep -oE 'pull/[0-9]+' | grep -oE '[0-9]+')
Step 1: Load context (progressive disclosure)
- Read
references/anti-patterns.md. - Read this skill's
references/checklist.md. - Optionally skim
shared/severity-rubric.md. - If present, read analysis JSON for impact and
risk_class.
Step 2: Load the PR diff
/review:review captures the PR once into $OUTPUT_DIR and every pass shares
it. Read $OUTPUT_DIR/pr.diff and $OUTPUT_DIR/pr-view.json; never write to
either — the other passes are reading them. Fetch only when run standalone:
if [ ! -s "$OUTPUT_DIR/pr.diff" ]; then
gh pr diff "$PR_URL" > "$OUTPUT_DIR/pr.diff"
gh pr view "$PR_URL" --json title,body,files,additions,deletions,commits \
> "$OUTPUT_DIR/pr-view.json"
fi
Step 3: Review
Walk checklist: CD readiness / reversibility first, then design quality (YAGNI, deep modules, complexity). Category 4 design-quality and Clean Code findings are blocking regardless of module reach — blast radius sets severity, not whether to block. Name the resolving refactoring in suggestion.
Prioritize:
- Releasability of each merge; feature-flag defaults; rollback
- Expand/contract and deploy ordering
- Refactor mixed with behavior; PR size / one concern
- Speculative generality and complexity budget on shared modules
Step 4: Emit JSON
jq -n \
--argjson pr_number "$PR_NUMBER" \
--arg pass "change-evolution" \
--argjson findings "$FINDINGS_JSON" \
'{pr_number: $pr_number, pass: $pass, findings: $findings}' \
> "$OUTPUT_DIR/change-evolution-${PR_NUMBER}.json"
Notes
- Standalone:
/review:change-evolution <PR_URL> [OUTPUT_DIR] - Orchestrator runs on large/mixed/CD/design signals (see
shared/risk-class-routing.md)
Paths like references/... are relative to the review plugin root.
04 同仓库更多 Skills
writing-design-docs
Use when the user wants to write a problem-statement design doc, says "let's plan a feature properly" / "write a design doc" / "I'm thinking about how to do X" for a non-trivial X, or before committing to a non-obvious technical direction
write-doc
Use when the user asks to write or draft a README, ADR, runbook, tutorial, how-to, explanation, or reference doc, or a caller passes "type ADR" or "type README". Picks the type, fills a template, adds diagrams. RFCs and design docs belong to writing-design-docs.
review-doc
Use when the user asks to review, critique, score, grade, or "how good is this doc" for a Markdown doc or pasted text. Read-only. Scores it on the 20 Practical Prose dimensions and emits a findings table. Does not edit; fix-doc applies the findings next.
fix-doc
Use when the user asks to fix, edit for prose quality, polish, tighten, humanize, or de-slop a Markdown doc or pasted text, or says "make this read less AI". Applies review-doc findings, generates flagged diagrams, lists substantive issues for the author, then runs the AI-tell pass last. Modifies the target.
create-slides
Use when the user asks for a slide deck, presentation, talk, or slides from a document, report, PR, notes, or topic. Builds one self-contained Machinify-branded HTML deck in a minimalist style, with headline-plus-visual slides, speaker notes, and every diagram drawn by architecture-design:create-diagram.
start-session
Open a Claude Code working session in a fresh, isolated git worktree, so the user can start a task with a single /start-session <name>. Use at the START of a session when the user says "start session", "start a worktree", "spin up a worktree for ABC-123", "begin work on <ticket>", or passes a name/ticket to work under. Creates and ENTERS a worktree via the EnterWorktree tool (never `git worktree add`) under .claude/worktrees/, named exactly after the argument, on a local branch `worktree-<argument>`. Reports what the worktree inherited (`.worktreeinclude` copies, symlinked node_modules) and whether its `.env` still points at the main checkout's stack. If the argument is a JIRA key (e.g. ABC-123, PROJ-1505), also loads that story with the Atlassian CLI (`acli`) when available and summarizes the implementation ask. Also renames the session to the argument (the same effect as `/rename <NAME>`) so it's easy to find in `/resume`. Then stops and waits — it sets up the workspace and context, it does not implement.