一键导入
design-log
Plan non-trivial features, fixes, refactors, UI/workflow changes before coding — clarify, research, get approval (Stop & Think protocol).
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Plan non-trivial features, fixes, refactors, UI/workflow changes before coding — clarify, research, get approval (Stop & Think protocol).
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Read or write Airtable records — bases, tbl/rec/fld IDs, filterByFormula, pyairtable. Not for n8n workflows or Google Sheets/Excel.
Find a past Claude Code session to resume — I closed my session, find the session where we…, which session discussed X, which session talked to the other agent.
Commit and optionally push. MANDATORY before any git write — commit, push, merge, rebase, reset, branch -d. Triggers: ship it, commit, push.
Review or improve an existing agent skill (SKILL.md structure, triggers, permissions, splitting). Not for new skills — use skills-build.
Build a NEW agent skill from a real repeated workflow. Use when the user asks to create a skill, scaffold `SKILL.md`, convert a recurring task into a skill, or decide whether a process deserves a skill. Do NOT use to review or audit an existing skill — use `skill-improver` for that.
Edit Tally forms via MCP tools — add/remove/reorder blocks and questions, change text, configure visibility/required state, and build conditional logic (apply_logic DSL). Use when the user mentions Tally, questionnaires, form building, form blocks, or a Tally form ID/URL, or asks to add a question, hide/show a field, sync Hebrew/English forms, or add logic to a Tally form. Does NOT trigger for writing the actual wording/persuasive copy of form questions or intro text (route that to `microcopy` or `copywriting`) — this skill is for structural/tool-mechanics edits via the Tally MCP, not for drafting prose.
| name | design-log |
| description | Plan non-trivial features, fixes, refactors, UI/workflow changes before coding — clarify, research, get approval (Stop & Think protocol). |
| model | opus |
| allowed-tools | Read, Write, Edit, Glob, Grep, Bash, mcp__claude_ai_Tavily__tavily_search, mcp__claude_ai_Tavily__tavily_extract, mcp__claude_ai_Tavily__tavily_crawl, mcp__claude_ai_Tavily__tavily_map, mcp__exa__web_search_exa, mcp__exa__web_fetch_exa, mcp__exa__web_search_advanced_exa, mcp__firecrawl__firecrawl_search, mcp__firecrawl__firecrawl_scrape, mcp__firecrawl__firecrawl_crawl, mcp__firecrawl__firecrawl_extract, Agent, Skill, EnterPlanMode, ExitPlanMode, AskUserQuestion |
Generic "Stop & Think" protocol that combines research-driven design with Claude Code's plan mode. Research first, then code. One workflow, one approval gate, persistent documentation. Project-specific rules belong in repo docs or in clearly labeled adaptation notes inside this skill.
Research (domain knowledge) comes BEFORE plan-mode codebase exploration; the design log file persists what plan mode would lose; both share a single approval gate via ExitPlanMode — no double-approval.
Use when the user explicitly invokes /design-log, asks for stop-and-think planning, or asks for documented design before a non-trivial feature, fix, refactor, workflow/UI change, automation, or architecture decision. Implicit use only when the task clearly needs persistent design documentation.
Skip for: single-line fixes and small tweaks; fully-specified unambiguous tasks where the user didn't invoke /design-log; pure research questions (use tech-researcher or consult); work already covered by an existing [APPROVED] log (extend that log instead). For these, just do the work — though a quick 2-minute research check is still wise for non-trivial domains.
Before writing the design log, identify: project root + branch/worktree state; the requested change and success criteria; relevant prior logs and prior research (research index); the domain(s) needing research; reusable code paths/helpers/tests/docs/diagrams; whether to implement after approval or stop at the plan. If an input is missing, ask via AskUserQuestion unless logs, instructions, or pre-scan findings already answer it.
Stop and wait when:
EnterPlanMode has not been called before Phase C exploration.[DRAFT] status.ExitPlanMode approval has not been granted.main, delete a branch, change secrets, perform destructive operations, or run an undocumented production-impacting command.Continue without another approval only after ExitPlanMode approval, and only for routine implementation decisions inside the approved plan.
The protocol runs in five phases. Each phase summary below is enough to know what to do; the full step-by-step procedure for every phase lives in references/protocol-detail.md — load it when you actually enter the phase.
/design-logIf the user explicitly typed /design-log (or otherwise invoked this skill by name), Phase A clarifying questions are mandatory — Auto Mode, "specific instructions", and "seems simple" are NOT valid reasons to skip. The user asked for the Stop & Think protocol; give them the Stop & Think protocol. Silently jumping to implementation is a protocol violation.
The "When this does not trigger" section above applies to deciding whether to invoke the skill in the first place — NOT to partially running it. If you run the skill, you run Phase A. If you believe the task genuinely doesn't warrant Phase A, say so out loud before proceeding: "Skipping Phase A questions because [specific reason] — proceed or ask questions anyway?" and wait for the user.
Auto Mode's "prefer action over planning / minimize interruptions" directive applies only to Phases D–E — after ExitPlanMode approval. During Phases A–C it is effectively suspended: ask the Phase A questions and wait; do the Phase B research even if the task "seems simple"; exit plan mode and wait for approval — never self-approve. After approval, Auto Mode resumes: execute the plan end-to-end, stopping only at the hard gates (merge to main, destructive ops, etc.).
This skill is pinned to Opus (frontmatter model: opus) for judgment work (clarifying questions, design synthesis, the plan). Mechanical gathering must NOT run on Opus — delegate it. This obeys the global model-routing rule and cuts ~50%+ of run cost with no loss of plan quality:
explore or model="haiku", reason over the summary. The dispatched prompt must include the task-derived search terms (incl. Hebrew UI labels) and must return a "Related prior DLs" list (number + title + status + 1-line relevance). Do NOT request a "highest number + last N logs" shortcut — that misses the relevant logs.explore or model="haiku" subagent to read INDEX.md (+ any archive index), grep log bodies, and pre-scan the codebase. Cap: return ≤500 words, read at most ~15 files, conclusions only.model="sonnet" research subagent (or tech-researcher). Cap: 3–5 sources, return ≤700 words of distilled principles/patterns/anti-patterns — do NOT pull full pages into the Opus context.explore / model="haiku" subagents for read-only file discovery. Cap: return file paths + 1-line relevance each, not file contents. Keep the design synthesis itself on Opus.Fable 5 note (since 2026-06-09): Fable 5 burns subscription quota ~2× faster than Opus 4.8 for the same tokens ($10/$50 vs $5/$25 per MTok weighting). The model: opus pin above is deliberate — it keeps this skill on Opus 4.8 even when the session model is Fable 5. Do NOT remove the pin or escalate to Fable 5 by default. When dispatching subagents while the session runs on Fable 5, an explicit model= is mandatory (haiku/sonnet per the rules above) — an unpinned dispatch would inherit Fable 5 and pay 2× for gathering. Reserve Fable 5 for the rare design problem where the user explicitly asks for it.
/design-log lite)When the user types /design-log lite (or asks for a "light/quick design log"), run the same protocol with reduced volume: Phase A asks 2–3 clarifying questions (not 5+); Phase B needs 1 source minimum — a fresh research-index hit (<90 days) satisfies it with zero new searches; template Sections 3–5 may be compressed to a few bullets each. All hard gates still apply: branch setup (A0), EnterPlanMode before exploration, the DL file saved with [DRAFT] status, ExitPlanMode single approval, Phase E handoff. Per-phase deltas table in references/protocol-detail.md § Lite Mode.
STOP. Do not implement anything. Steps: A0 Branch Setup → A1 Check Existing Logs → A2 Light Codebase Pre-Scan → A3 Ask Clarifying Questions via AskUserQuestion (usually 5+) → A4 Wait for answers. Full procedure in references/protocol-detail.md § Phase A.
A0 DL-number reservation (if your repo uses it): some repos reserve the design-log number with a script that lives outside the repo (so it survives repo cleanups) — e.g.
~/.claude/scripts/reserve-dl-number.sh. If your setup has one, run it from the repo root and do NOT improvise rawgit pushclaims. Configure the script path and per-repo rules (branch rename vsslice/*, default branch) inreferences/protocol-detail.md§ Phase A A0 — load it before reserving. If no script exists, fall back to the manual numbering in that reference.
Mandatory. B0 Fetch current date via Bash (date +%Y-%m-%d) BEFORE any MCP call → B0.5 Check .agent/design-logs/research-index.md — a domain entry <90 days old means delta research only → B1 Identify domain → B2 Read 3+ sources via a research MCP — Tavily / Exa / Firecrawl (NOT WebSearch/WebFetch) → B3 Extract principles, patterns, anti-patterns, deviations into Section 3 of the log + upsert the research index. Time-box 5–10 min. Optional: delegate to tech-researcher for fast-moving technical domains. Full procedure + research rules + domain table in references/protocol-detail.md § Phase B.
HARD GATE — DATE FIRST: Before calling Tavily (or any other MCP/research tool —
tech-researcher, etc.), runBashwithdate +%Y-%m-%dto anchor "current" in real time. The session'scurrentDatecontext can be stale or absent. Do NOT rely on training-data dates or assumed year. Then use the anchored date BOTH ways:
- Set Tavily's structured filter parameters —
start_date(and/orend_date/time_range) computed from the anchored date. This is the lever that actually filters out stale pages. Putting a date in the query text alone only nudges ranking; it does NOT filter.- And mention recency in the query text where useful ("as of YYYY-MM-DD", "latest stable", "deprecated in YYYY") and pick correct year filters (current year + prior year, not years recalled from memory).
Pick the research MCP by job (NOT
WebSearch/WebFetch): Exa = semantic source discovery + deep research · Tavily = ranked web search + extraction · Firecrawl = full-page/JS-heavy/site crawls. Per-tool breakdown inreferences/protocol-detail.md§ Phase B B2.
HARD GATE: If you invoked
tech-researcher, you MUST wait for its result before callingEnterPlanMode. Do NOT enter Phase C while tech-researcher is still running.
HARD GATE — READ BEFORE ANY TOOL CALL IN THIS PHASE: The FIRST tool call in Phase C must be
EnterPlanMode. Do NOT run Glob/Grep/Read for codebase exploration, and do NOT callWrite/Editon the design log file, until plan mode is active. The design log file must be created INSIDE plan mode. Phase C ends withExitPlanMode— a plain-text "approve to proceed?" message is NOT a substitute approval gate. If you catch yourself mid-exploration without having calledEnterPlanMode, stop immediately, call it, and resume — do NOT rationalize continuing outside plan mode because "exploration already started."
Steps: enter plan mode → explore codebase + load architecture diagrams → create the design log file at .agent/design-logs/NNN-kebab-case-description.md from assets/design-log-template.md with status [DRAFT] → ExitPlanMode for the single approval. Full procedure in references/protocol-detail.md § Phase C.
Recommended: Use /subagent-driven-development for implementation when the plan has independent tasks that can run in parallel.
Steps: status → [BEING IMPLEMENTED — DL-NNN] → build per Proposed Solution → update Implementation Notes on deviations → status → [IMPLEMENTED — NEED TESTING] → housekeeping (INDEX, current-status.md, architecture diagrams, git-ship skill, deploy if applicable). Full housekeeping checklist (NO auto-merge, frontend release path, do-not-delete-branch, do-not-edit-after-merge) in references/protocol-detail.md § Phase D.
Collect unchecked Section 7 items → write to current-status.md Active TODOs in the documented format → mark log [COMPLETED] only when all Section 7 items pass. To close: run bash .claude/workflows/close-design-log.sh <NNN> — it patches status in both the DL file and INDEX.md, runs the PII guard, and stages the files. Once [COMPLETED], merged, and (if deployed) live-verified, delete the feature branch via git-ship: verify-merged → detach-if-checked-out → git branch -D + git push origin --delete (Phase E step 5). Full procedure + format template in references/protocol-detail.md § Phase E.
Classify feedback (clarification / bug / missed constraint / scope expansion / refinement) and respond accordingly. Full table in references/protocol-detail.md § Handling Mid-Implementation Feedback. When uncertain: state your assumptions, propose options (quick fix vs. proper solution), ask for preference. Don't guess.
The persistent artifact this skill produces is a design log file at .agent/design-logs/NNN-kebab-case-description.md, filled in from the canonical template at assets/design-log-template.md. Read that file when you need the structure; do not paste it into chat.
Sections in order: 1. Context & Problem · 2. User Requirements (Q&A) · 3. Research (Domain, Sources, Principles, Patterns, Anti-Patterns, Verdict) · 4. Codebase Analysis · 5. Constraints & Risks · 6. Proposed Solution · 7. Validation Plan · 8. Implementation Notes.
Two subsections are conditional — fill them when the change warrants, else mark them omitted/None: §6 Boundary Contracts (define the validated schema crossing each module/service/agent boundary — prevents cascading shape-drift errors on multi-module changes) and §7 Trajectory / Acceptance Criteria (verify the path, not just the final answer — for non-deterministic or high-stakes output like LLM text or recommendations).
Status values ([DRAFT] / [APPROVED] / [BEING IMPLEMENTED — DL-NNN] / [IMPLEMENTED — NEED TESTING] / [COMPLETED] / [DEPRECATED]) and naming convention (NNN-description.md, sequential, lowercase-hyphens, English) are documented in references/protocol-detail.md.
Do not leave template placeholders such as [Question], [Key takeaway], or Test Case 1 in a real design log. Replace every placeholder with concrete project-specific content before calling ExitPlanMode.
[DRAFT] means no coding./design-log explicitly, Auto Mode does NOT override this. To skip, state the reason out loud and wait for confirmation.ExitPlanMode is the single approval for both plan and design log.current-status.md and mark [COMPLETED] only once all tests pass.This skill does NOT run automatically at session start. It runs when the user types /design-log, invokes it by name, or (rarely) when the task clearly needs persistent design documentation per "When this triggers". When invoked, before Phase A:
INDEX.md + ARCHIVE-INDEX.md + all DL bodies (not just titles). Read in full any DL on the same feature / symptom / files and list them (number + title + status + 1-line relevance). This is how duplicates and prior decisions are found.[APPROVED] / [BEING IMPLEMENTED] logs not marked [COMPLETED] (conflict guard).research-index.md (for the Phase B cache rule).Recency is NOT a discovery method. "Summarize the last N logs" does NOT satisfy step 1 — the most recent logs are rarely the relevant ones. The relevance grep is required; do not substitute a recency summary for it.
This check is gathering — per § Model Routing, dispatch it to explore/model="haiku" and reason over the summary.
Full list in references/protocol-detail.md § Gotchas — read when closing out a phase or when something feels off. The ones that bite most often:
EnterPlanMode — the first Phase C tool call must be EnterPlanMode.Bash date +%Y-%m-%d, or putting the date only in query text instead of Tavily's structured filters.Run after the skill completes — any "no" means a skipped phase (full version: references/protocol-detail.md § Evaluation Checklist):
EnterPlanMode the first Phase C tool call, and the DL file saved as [DRAFT] inside plan mode?ExitPlanMode the single approval gate — no coding before it, no second approval after it?current-status.md before any [COMPLETED] mark?references/protocol-detail.md — load when entering a phase and you need the full step-by-step procedure (Phase A0–A4, B0.5–B3 incl. research-index cache, C, D housekeeping, E test handoff + cost line, mid-implementation feedback table, status values, naming convention, Lite Mode deltas, Gotchas, Evaluation Checklist).references/research-sources.md — load in Phase B (B2) when picking book recommendations and source tiers for the identified domain.assets/design-log-template.md — fill this out as the persistent design log file in Phase C; read it for the canonical Section 1–8 structure rather than reproducing it inline.assets/research-index-template.md — seed for .agent/design-logs/research-index.md (per-project research cache); create from this in Phase B3 if the project doesn't have one yet.