scope
Skill138 starsChanged 5 months agoMITView on GitHub
Scope definition before implementation — two modes. Quick mode (default): IN/OUT/exit criteria brief → BRIEF.md. Full mode (/scope full): L0→L4 layered spec chain → spec.md. Trigger: '/scope', '/brief', '/specify', 'scope this', '스펙 잡아줘', '범위 잡아줘', 'spec 만들어', '스펙 만들어', '기획 정리해줘', 'plan this'. Do NOT trigger for: bug fixes, single-file changes, existing spec, brainstorming.
25 other projects use a version of this.
Adopted by
Most recently taken up by
- thekinv21/NotificationServicetheir own version, first seen Oct 3, 2026
- klmiing1229-a11y/scopetheir own version, first seen Oct 2, 2026
- thekinv21/RBAC_Authenticationtheir own version, first seen Oct 1, 2026
- eliphazbouye/skillstheir own version, first seen Sep 30, 2026
- Nagacash/naga-codex-skillstheir own version, first seen Sep 25, 2026
- shammlo/zoth-skillstheir own version, first seen Sep 24, 2026
Used with
Projects with it also use develop, document and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
bamechoSkilldevelop
开发实施阶段详细规则;进入开发实施时读取;包含执行流程、代码规范、一致性审计、方案包迁移
Also in 6 projects that use this
nicolasestremSkilldocument
Create focused documentation for specific components or features
Also in 5 projects that use this
MicrosoftSkillsync
Sync the current session branch with its upstream branch, or publish the current session branch to a remote. Use when the user asks to sync a branch, pull latest changes, rebase onto upstream, push current branch, publish branch, or set upstream.
Also in 6 projects that use this
kt057Skillcheck
lint, typecheck, test を一括実行して結果をサマリーする
Also in 5 projects that use this
jdonohooSkillarchitect
Architect Vern - Systems design, scalable architecture, production-grade thinking. The blueprints before the build.
Also in 8 projects that use this
AnthropicSkilldebug
Structured debugging session — reproduce, isolate, diagnose, and fix. Trigger with an error message or stack trace, "this works in staging but not prod", "something broke after the deploy", or when behavior diverges from expected and the cause isn't obvious.
Also in 9 projects that use this
Other versions25 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 25
- jsmastery-pro/skills★ 1.4ksame name
- suboss87/FDEOps★ 950same name
- crisandrews/ClawCode★ 63same name
- Dan-Cleary/fdestack★ 46same name
- ConnorGriffin/skills★ 22same name
- chrisallenlane/claude-swe-workflows★ 18same name
- jsmastery-pro/pilot★ 8same name
- WhorideChicken/first-playable★ 3same name
- envisioning/skills★ 2same name
- kanoniv/auth-action★ 2same name
15 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository19 other files it gives its agents.
- clean-roomSkill
- code-autopsySkill
- collab-auditSkill
- doc-driftSkill
- eval-leakage-auditSkill
- freezeSkill
- full-auditSkill
- goal-lockSkill
- integration-intakeSkill
- next-actionSkill
- pre-pushSkill
- project-checkSkill
- project-initSkill
- project-overviewSkill
- session-checkpointSkill
- session-startSkill
- setupSkill
- skill-opsSkill
- stepbackSkill
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 2 are distinctive, and 0 are very specific to this project.
0
Common
Most of the 24 edited versions we read keep these.
2
Distinctive
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 211
No implementation during scope: no code changes during/after scope writing.
- Distinctive: line 244
no mock deception: never save without approval.
“Common” is measured: kept by at least 6 in 10 of the 24 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/scope — Scope Definition Engine v1.0
Unified brief + specify. Lock down "what you will do and what you will NOT do" before implementation. Quick (default) = IN/OUT lock + BRIEF.md. Full = L0→L4 layer chain + spec.md.
Dominant Variable
Is the Scope OUT section explicitly written? — IN alone causes scope creep during implementation. OUT must be explicit to lock it. In Full mode, additionally L2 decision clarity is the dominant variable.
Trigger
/scope(Quick default)/scope full(Full mode)/brief(Quick backward compat)/specify(Full backward compat)- "scope this", "스펙 잡아줘", "범위 잡아줘", "기획 정리해줘"
- "spec 만들어", "스펙 만들어", "plan this"
Discard If
- Bug fix, 1-file edit → implement directly
- BRIEF.md/spec.md already exists → use Edit
- Exploration only → delegate to brainstorming
Key Assumptions
- Project CLAUDE.md exists (existing projects) — if broken: can't auto-scan constraints, write from user input only.
- User provides idea/requirement in ≥1 sentence — if broken: ask "Tell me in one sentence what to build" once.
Mode Selection
| Mode | Trigger | Output | Best For |
| Quick (default) | /scope, /brief | BRIEF.md | Feature add, clear change |
| Full | /scope full, /specify | specs/{name}/spec.md | Architecture change, multi-module, complex design |
Unsure? Start Quick → if user wants more detail: "Shall we switch to full mode?"
Quick Mode — IN/OUT Brief
Step 1: Detect project
- Existing project: CLAUDE.md, package.json etc. exist → 2-level Glob + keyword Grep (10-file cap)
- New project: skip
Step 2: Ambiguity score gating
Score clarity across 4 dimensions (0-10 each), by judgment.
| Dimension | Check |
| Function | What behavior is being added/changed — are inputs/outputs concrete? |
| Boundary | What is explicitly excluded — is IN/OUT clear? |
| Verification | How is "done" verified — is there a measurable criterion? |
| Assumptions | Any hidden assumptions — dependencies on existing system/data/environment? |
Gating (deterministic): hand the 4 scores to the gate script and read its stdout — don't average them by eye. Resolve the script from the skill's own directory rather than a path relative to the invocation cwd — python scope/scripts/... only works when the shell happens to be sitting one level above scope/, and breaks in every other cwd:
GATE_SCRIPT=$(find ~/.claude -name "ambiguity_gate.py" -path "*/scope/scripts/*" -type f 2>/dev/null | head -1)
python "$GATE_SCRIPT" quick --scores '{"function":8,"boundary":7,"verification":6,"assumptions":9}'
# -> {"ok": true, "avg": 7.5, "weakest": "verification"}ok: false → target the dimension the script names as weakest with clarifying questions (max 3).
Exceeds question limit → conservative minimum scope + [assumed] tag.
Step 3: Generate Brief
## Brief: [feature name — verb phrase]
**Goal**: [1-2 sentences. Start with verb.]
**Scope IN**
- [concrete items]
**Scope OUT** ← Required, min 2 items
- [natural extension but excluded]
**Constraints**
- [file/action/integration constraints — min 1 if existing project]
**Exit Criteria**
- [ ] [who/what] [action] → [measurable result]
**Risk Flags**
- [min 1]
**Contraindication**
- [condition where this approach doesn't fit — min 1]
- Example: "If data > 100K rows, this design has performance issues", "If team > 2 people, API contract first"Step 4: Min-item validation → Approval → Save BRIEF.md
The gate script takes --file, not stdin, so it needs something on disk to read — but Invariant 5 says the deliverable (BRIEF.md) isn't saved until after approval, and approval isn't requested until the script says ok: true. Break that cycle by writing the drafted brief to a scratch file (e.g. .scope-draft.md) first: the scratch write is not the Invariant-5-gated save, it exists purely so the deterministic script has a path to read. Draft freely, re-run the gate as many times as needed, all before any approval exists.
Validate the scratch draft against the minimum-item requirements — don't count bullets by eye. A bolded aside inside a section (e.g. **Note**: ...) can look like a new section header on a human skim and silently truncate a manual count; a regression test locks this exact failure mode closed in the script.
GATE_SCRIPT=$(find ~/.claude -name "ambiguity_gate.py" -path "*/scope/scripts/*" -type f 2>/dev/null | head -1)
python "$GATE_SCRIPT" min-items --file .scope-draft.md
# -> {"scope_out": 2, "risk_flags": 1, "contraindication": 1, "constraints": 1, "ok": true}Pass --new-project for new projects (Invariant 6 waives the Constraints requirement). ok: false → the per-field counts in the JSON show which section is short; revise .scope-draft.md, add items there, and re-run before moving to approval.
Request approval only once the script reports ok: true. On approval: write the same content to BRIEF.md (Invariant 5 — this is the actual gated save) and delete the scratch file. On rejection: keep revising the scratch file and re-gating; it is never shown to the user as the deliverable, only BRIEF.md is.
Full Mode — L0→L4 Spec Chain
Layer Flow
| Layer | What | Gate |
| L0 | Mirror → Goal, Non-goals, Confirmed Goal | User confirmation |
| L1 | Codebase research → Research section | Automatic |
| L2 | Interview → Decisions + Constraints | doubt-reviewer + user approval |
| L3 | Requirements (GWT sub-requirements) | User approval |
| L4 | Tasks (Fulfills links) + Plan Summary | User approval |
Core Rules
- Layer order is immutable — no skipping, no backward traversal
- Append, don't overwrite — Read existing spec.md first
- doubt-reviewer independent validation required (if skipped: mark
Reviewer: SKIPPED) - Tasks must link to Requirements (
Fulfills: R{n}.{m})
L2 Self-Validation
Each Decision gets clarity score (0-5):
- 5: Implementer can state in 1 sentence what to build
- 3: Needs 1-2 clarifying questions
- 1: Completely ambiguous
Gating (deterministic): hand the per-Decision scores to the gate script — don't average them by eye. Resolve the script from the skill's own directory, not a cwd-relative path (see Quick Mode Step 2 for why):
GATE_SCRIPT=$(find ~/.claude -name "ambiguity_gate.py" -path "*/scope/scripts/*" -type f 2>/dev/null | head -1)
python "$GATE_SCRIPT" full --scores "5,3,4,5"
# -> {"ok": true, "avg": 4.25}ok: false → warn "Decisions are ambiguous" + suggest rewrite.
Deliverable
specs/{kebab-name}/spec.md — required sections:
Meta / Goal / Non-goals / Confirmed Goal / Research / Decisions / Constraints / Known Gaps / Requirements / Tasks / Plan Summary
Mid-Task Scope Drift — 10x-Discovery Rule
Quick and Full modes both lock IN/OUT only at write time — neither covers what to do when scope explodes mid-execution.
Even for scope locked in BRIEF.md/spec.md, if evidence found during implementation (hidden coupling, a required migration, a stopgap carrying far more load than expected) shows the work is a multiple of what was originally understood, stop immediately and surface it:
- What was discovered
- The honest new scale
- 2-3 costed options (full fix / narrow workaround / defer)
- A recommendation
Two things are forbidden: (a) silently absorbing the explosion (the user ends up waiting 5x longer than promised) (b) quietly shrinking the deliverable to fit the original budget (the user only discovers later they got less than expected). Both are worse than a plain "here's what I found."
Scope Boundary
| Does | Does NOT |
| [READ] Idea → structured brief/spec | Write or modify code |
| [READ] IN/OUT explicit + exit criteria | Decide implementation method (how is implementer's job) |
| [WRITE] Save BRIEF.md or spec.md | Analyze existing code (quick scan only) |
| [AGENT] doubt-reviewer independent validation (Full) | Make design decisions (brainstorming's role) |
Safety Layers
| Risky Action | Reversibility | Applied Layers |
| Save BRIEF.md / spec.md | high (git) | L1+L3 (Invariant 5: user approval gate) |
| Overwrite existing spec | medium | L1 (Invariant 9: append/edit only) |
Invariants (never violate)
- No implementation during scope: no code changes during/after scope writing. Violation → scope becomes a post-hoc rationalization for code already written instead of a constraint that shapes it, and the OUT section stops meaning anything.
- Scope OUT mandatory: baseline min 2 items — unless the scope is self-evidently a single item, in which case 1 item plus a stated reason is acceptable. Violation → only IN is recorded, so anything not explicitly listed becomes fair game during implementation — scope creep with no written boundary to point back to.
- Exit Criteria = observable + measurable: auto-reject vague items like "works correctly". Violation → "done" becomes a matter of opinion at handoff time, and disagreement about completion surfaces only after the work is finished.
- Question limit 3 (Quick): exceed → conservative minimum scope — unless there is clear evidence a 4th question would change the direction, in which case one additional question is allowed once, with the reason stated. Violation → interrogation replaces scoping and the user abandons the flow instead of getting a usable brief.
- Approval gate required: save file only after explicit user approval. Violation → an unreviewed draft becomes the working spec, and errors in it propagate into implementation before anyone caught them.
- Constraints mandatory (existing project): 0 items → rescan. Violation → the brief looks complete but omits the existing system's real limits, so implementation collides with constraints nobody wrote down.
- Risk Flags min 1 — unless there is truly no risk, in which case "no risk:
<reason>" may be substituted. Violation → a known failure mode goes unrecorded, so the same risk resurfaces later as a surprise instead of a tracked flag. - Layer order immutable (Full): L0→L1→L2→L3→L4. Violation → decisions (L2) get made on a foundation (L0/L1) that was never confirmed, so the spec inherits an unvalidated goal.
- No spec overwrite (Full): append or edit only. Violation → prior layers' history is destroyed, so a later reviewer can't tell what changed or why.
- Tasks→Requirements link required (Full). Violation → a task exists with no requirement behind it — untraceable work that can't be checked against the spec it supposedly fulfills.
- No silent absorption or quiet shrinking on 10x discovery: if implementation reveals scope that is a multiple of what was originally understood, surface it immediately — don't absorb it silently and don't quietly shrink the deliverable to fit the original budget. Violation → the user only discovers the delay or the missing scope later, after the fact.
Error Recovery
| Failure Type | Recovery |
tool_failure | Print to chat → user manual save |
input_error | Ask 1 clarifying question. No guessing |
missing_data | Note "no context" + write from user input only |
logic_inconsistency | Present conflicting items to user for selection |
Rationalization Table
| Rationalization | Rebuttal |
| "Skip OUT" | Invariant 2. Explicit even when clear prevents scope creep — the single-item exception still requires a written item plus a stated reason, not silence |
| "Clear enough, no questions" | Need immediate 1-sentence answer to 3 questions for Sufficient |
| "L0-L1 obvious, skip" (Full) | L2 decisions have no foundation without them |
| "Write spec in one go" (Full) | Mid-gates allow course correction |
| "Tasks before Requirements" (Full) | No Fulfills link = untraceable |
| "Just quietly do a bit more to make it fit" | Invariant 11. Silent absorption means the user only finds out about the delay or shrinkage later, without warning |
Truthful Reporting
- no mock deception: never save without approval.
- no test façade: missing OUT =
⚠️ Scope OUT not written. - no silent brokenness: unmeasurable Exit Criteria = PARTIAL.
Output
Before approval: the brief (Quick) or the current layer's draft (Full) is emitted into the conversation only — no deliverable file (BRIEF.md / spec.md) is written yet. Quick mode's Step 4 gate needs a file to read, so a .scope-draft.md scratch file may exist at this stage — it is not the deliverable and is deleted once BRIEF.md is saved (or once the flow is abandoned). This is the review surface; catch problems here, not after the deliverable exists.
After approval:
- Quick →
BRIEF.mdwritten to disk (Step 4, gated by the min-items script above), scratch file deleted. - Full →
specs/{kebab-name}/spec.mdwritten/appended per layer (L0→L4), each layer gated by its own user-approval checkpoint.
Final status label (required on completion): WORKING (brief/spec saved, all gates passed) / PARTIAL (saved with a documented gap — e.g. [assumed] tags from a question-limit exit, or a section marked ⚠️) / BROKEN (an approved draft turns out structurally contradictory or unusable after saving) / BLOCKED (waiting on user approval or another unresolved external dependency). Conditions per label are the same as Truthful Reporting above.
Principles
- OUT matters more than IN — people say what to do but skip what NOT to do.
- Fewer questions better — 4+ and users say "just build it".
- Brief is not an implementation spec — what and done only. How is implementer's.
- Full extends Quick — detect complexity in Quick → offer Full switch.
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
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.

