heimdall-agent 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/README.md +13 -13
  2. package/README.pt-BR.md +36 -22
  3. package/agents/code-sentinel.md +7 -1
  4. package/agents/modernizer.md +4 -2
  5. package/agents/orchestrator.md +20 -7
  6. package/agents/reviewer.md +2 -0
  7. package/config/agents.json +11 -1
  8. package/config/mcp.json +1 -1
  9. package/config/profiles.json +1 -1
  10. package/config/skills.json +762 -683
  11. package/docs/SKILLS.md +96 -74
  12. package/docs/runs/skill-audit/2026-11-12-compare-report.json +1028 -0
  13. package/docs/runs/skill-audit/2026-11-12-upstream-audit.json +275 -0
  14. package/doctrine/AGENTS.md +4 -1
  15. package/lib/catalog-sync.cjs +8 -3
  16. package/package.json +1 -1
  17. package/playbooks/01-interactive-grilling-gate.md +14 -10
  18. package/playbooks/03-adversarial-code-review.md +12 -4
  19. package/playbooks/05-canonical-plan-template.md +3 -1
  20. package/setup.mjs +2 -2
  21. package/skills/antislop-copywriting/SKILL.md +36 -1
  22. package/skills/brainstorming/SKILL.md +60 -38
  23. package/skills/codebase-design/DEEPENING.md +37 -0
  24. package/skills/codebase-design/DESIGN-IT-TWICE.md +44 -0
  25. package/skills/codebase-design/SKILL.md +114 -0
  26. package/skills/domain-modeling/ADR-FORMAT.md +47 -0
  27. package/skills/domain-modeling/GLOSSARY-FORMAT.md +60 -0
  28. package/skills/domain-modeling/SKILL.md +74 -0
  29. package/skills/executing-plans/SKILL.md +6 -4
  30. package/skills/grill-me/SKILL.md +65 -0
  31. package/skills/handoff/SKILL.md +64 -0
  32. package/skills/improve-codebase-architecture/HTML-REPORT.md +123 -0
  33. package/skills/improve-codebase-architecture/SKILL.md +71 -0
  34. package/skills/owasp-security/reference/config-and-supply-chain.md +346 -344
  35. package/skills/owasp-security/reference/languages.md +378 -372
  36. package/skills/owasp-security/reference/owasp-report.md +1144 -1140
  37. package/skills/owasp-security/reference/review-checklist.md +134 -132
  38. package/skills/subagent-driven-development/SKILL.md +7 -4
  39. package/skills/to-spec/SKILL.md +75 -0
  40. package/skills/to-tickets/SKILL.md +105 -0
  41. package/skills/wayfinder/SKILL.md +128 -0
@@ -1,132 +1,134 @@
1
- # Security Review Checklist
2
-
3
- Coverage list for step 3 of the review workflow in `SKILL.md`. Skip sections the change does not
4
- touch. A checked-off gap is a lead to trace, not a finding: run it through the triage rubric in
5
- `SKILL.md` before reporting it.
6
-
7
- ## Contents
8
- - Input Handling (A05)
9
- - Authentication & Sessions (A07)
10
- - Access Control (A01)
11
- - Server-Side Request Forgery (A01)
12
- - File Handling (A01)
13
- - Insecure Design (A06)
14
- - Configuration & Hardening (A02)
15
- - Dependencies & Supply Chain (A03)
16
- - Serialization & Data Integrity (A08)
17
- - Data Protection (A04)
18
- - Error Handling & Logging (A09/A10)
19
- - LLM and Agent Features (LLM Top 10 2026, Agentic 2026)
20
-
21
- ## Input Handling (A05)
22
- - [ ] All user input validated server-side
23
- - [ ] Using parameterized queries (not string concatenation)
24
- - [ ] Input length limits enforced
25
- - [ ] Allowlist validation preferred over denylist
26
- - [ ] Output encoded for its context: HTML body, attribute, URL, JS, CSS are different rules
27
- - [ ] No raw HTML sinks fed by user data (`innerHTML`, `dangerouslySetInnerHTML`, `|safe`, `v-html`)
28
- - [ ] OS commands invoked with an argv array, never a shell string
29
- - [ ] XML parsers configured with external entity resolution disabled (XXE, filed under A02 in 2025)
30
- - [ ] Templates never built from user input (SSTI)
31
-
32
- ## Authentication & Sessions (A07)
33
- - [ ] Passwords hashed with Argon2/bcrypt (not MD5/SHA1)
34
- - [ ] Session tokens have sufficient entropy (128+ bits)
35
- - [ ] New session token issued on login (no session fixation)
36
- - [ ] Sessions invalidated on logout, password change, and account disable
37
- - [ ] Cookies set `HttpOnly`, `Secure`, and `SameSite=Lax` or stricter
38
- - [ ] MFA available for sensitive operations
39
- - [ ] JWTs: algorithm pinned server-side (`alg: none` and algorithm confusion rejected),
40
- signature verified, `exp`/`aud`/`iss` checked
41
-
42
- ## Access Control (A01)
43
- - [ ] Authorization checked on every request
44
- - [ ] Using object references user cannot manipulate
45
- - [ ] Deny by default policy
46
- - [ ] Privilege escalation paths reviewed
47
- - [ ] Object-level checks verify ownership/tenancy, not just "is authenticated" (IDOR/BOLA)
48
- - [ ] State-changing requests protected against CSRF (token or `SameSite` + origin check)
49
- - [ ] Redirect targets validated against an allowlist (no open redirect)
50
- - [ ] CORS: no `Access-Control-Allow-Origin: *` combined with credentials, no origin reflection
51
-
52
- ## Server-Side Request Forgery (A01)
53
- - [ ] User-supplied URLs resolved and validated against an allowlist of hosts/schemes
54
- - [ ] Private, loopback, and link-local ranges blocked, including after DNS resolution
55
- - [ ] Redirects not followed blindly to a new host (re-validate each hop)
56
- - [ ] Cloud metadata endpoints (`169.254.169.254`) unreachable from the app
57
-
58
- ## File Handling (A01)
59
- - [ ] Upload type validated by content, not just extension or `Content-Type`
60
- - [ ] Uploads stored outside the web root, served with a non-executable content type
61
- - [ ] File size limits and quota enforced
62
- - [ ] Paths built from user input canonicalized and confined to a base directory (no `../`)
63
- - [ ] Archive extraction guards against path traversal and zip bombs
64
-
65
- ## Insecure Design (A06)
66
- - [ ] Prices, quantities, roles, and state transitions decided server-side, never taken from the client
67
- - [ ] Rate limits on login, password reset, OTP, signup, and expensive operations
68
- - [ ] Multi-step flows can't be skipped, reordered, or replayed (one-time tokens, idempotency keys)
69
- - [ ] Balance, inventory, and coupon updates are atomic (no check-then-write race)
70
-
71
- ## Configuration & Hardening (A02)
72
- - [ ] Debug mode, verbose errors, and dev tooling disabled in production
73
- - [ ] Default credentials and sample/admin accounts removed
74
- - [ ] Unused features, ports, endpoints, and HTTP methods disabled
75
- - [ ] Security headers set: CSP without `unsafe-inline`/`unsafe-eval`, HSTS,
76
- `X-Content-Type-Options: nosniff`, `Referrer-Policy`
77
- - [ ] Cloud storage and object buckets are not publicly readable/writable
78
- - [ ] Container/infra config reviewed (non-root user, no privileged mode, no secrets in image layers)
79
-
80
- ## Dependencies & Supply Chain (A03)
81
- - [ ] Lockfile committed and versions pinned (no floating ranges in production builds)
82
- - [ ] Dependencies scanned for known vulnerabilities and unmaintained packages
83
- - [ ] Package names checked against typosquats and dependency confusion (internal names claimed publicly)
84
- - [ ] Third-party scripts loaded with Subresource Integrity, or self-hosted
85
- - [ ] Build and CI scripts reviewed: install hooks and pipeline steps run with repo write access
86
- - [ ] Artifacts and releases signed; signatures verified before deploy
87
-
88
- ## Serialization & Data Integrity (A08)
89
- - [ ] No deserialization of untrusted data with a native format (`pickle`, `Marshal`,
90
- `ObjectInputStream`, `BinaryFormatter`, `yaml.load`)
91
- - [ ] JSON/schema-validated formats used instead, with a type allowlist
92
- - [ ] Auto-update and plugin loading verify signatures before execution
93
-
94
- ## Data Protection (A04)
95
- - [ ] Sensitive data encrypted at rest
96
- - [ ] TLS for all data in transit
97
- - [ ] No sensitive data in URLs/logs
98
- - [ ] Secrets in environment/vault (not code), and not in git history or container layers
99
- - [ ] Authenticated encryption (AES-GCM/ChaCha20-Poly1305); no ECB, no unauthenticated CBC
100
- - [ ] IVs/nonces unique per encryption; randomness from a CSPRNG, not `Math.random`/`rand()`
101
- - [ ] Secrets and tokens compared in constant time
102
-
103
- ## Error Handling & Logging (A09/A10)
104
- - [ ] No stack traces exposed to users
105
- - [ ] Fail-closed on errors (deny, not allow)
106
- - [ ] All exceptions logged with context
107
- - [ ] Consistent error responses (no user/account enumeration via message or timing)
108
- - [ ] Auth events, authorization failures, and security-control failures logged
109
- - [ ] Logs exclude credentials, tokens, and PII; user input encoded to prevent log injection
110
- - [ ] Empty `catch` blocks and swallowed errors reviewed: silent failure hides attacks
111
-
112
- ## LLM and Agent Features (LLM Top 10 2026, Agentic 2026)
113
- - [ ] Untrusted text (user input, web pages, email, RAG chunks, tool output) can't steer a model
114
- that holds privileged tools (LLM01, ASI01)
115
- - [ ] Model output validated or escaped before any SQL, shell, HTML, code, or tool argument (LLM10)
116
- - [ ] Tools minimal and scoped; no general shell or HTTP tool unless required; destructive
117
- actions need human approval (LLM03, ASI02)
118
- - [ ] Agent credentials short-lived and scoped to the task, never an admin or the user's full session (ASI03)
119
- - [ ] Retrieval enforces the caller's tenant and permissions at query time (LLM02, LLM09)
120
- - [ ] No secrets or authorization logic in the system prompt, tool schemas, or other hidden context (LLM08)
121
- - [ ] MCP servers, plugins, and models pinned and from trusted sources (LLM04, ASI04)
122
- - [ ] Generated code runs in a sandbox (ASI05)
123
- - [ ] Writes to agent memory or the vector store validated, so untrusted content can't persist
124
- instructions (ASI06)
125
- - [ ] Per-user caps on requests, tokens, tool calls, and cost, plus hard timeouts (LLM06)
126
- - [ ] Messages between agents authenticated and integrity-checked; a receiving agent doesn't
127
- trust the sender's claims about identity or authority (ASI07)
128
- - [ ] One agent's failure or bad output can't cascade: step, retry, and fan-out limits, plus
129
- circuit breakers between components (ASI08)
130
- - [ ] AI-generated content labelled; approval prompts show the real action, so an agent can't
131
- talk a user into approving something else (ASI09)
132
- - [ ] Tool calls logged, with a way to stop a running agent (ASI10)
1
+ # Security Review Checklist
2
+
3
+ Coverage list for step 3 of the review workflow in `SKILL.md`. Skip sections the change does not
4
+ touch. A checked-off gap is a lead to trace, not a finding: run it through the triage rubric in
5
+ `SKILL.md` before reporting it.
6
+
7
+ ## Contents
8
+ - Input Handling (A05)
9
+ - Authentication & Sessions (A07)
10
+ - Access Control (A01)
11
+ - Server-Side Request Forgery (A01)
12
+ - File Handling (A01)
13
+ - Insecure Design (A06)
14
+ - Configuration & Hardening (A02)
15
+ - Dependencies & Supply Chain (A03)
16
+ - Serialization & Data Integrity (A08)
17
+ - Data Protection (A04)
18
+ - Error Handling & Logging (A09/A10)
19
+ - LLM and Agent Features (LLM Top 10 2026, Agentic 2026)
20
+
21
+ ## Input Handling (A05)
22
+ - [ ] All user input validated server-side
23
+ - [ ] Using parameterized queries (not string concatenation)
24
+ - [ ] Input length limits enforced
25
+ - [ ] Allowlist validation preferred over denylist
26
+ - [ ] Output encoded for its context: HTML body, attribute, URL, JS, CSS are different rules
27
+ - [ ] No raw HTML sinks fed by user data (`innerHTML`, `dangerouslySetInnerHTML`, `|safe`, `v-html`)
28
+ - [ ] OS commands invoked with an argv array, never a shell string
29
+ - [ ] XML parsers configured with external entity resolution disabled (XXE, filed under A02 in 2025)
30
+ - [ ] Templates never built from user input (SSTI)
31
+
32
+ ## Authentication & Sessions (A07)
33
+ - [ ] Passwords hashed with Argon2/bcrypt (not MD5/SHA1)
34
+ - [ ] Session tokens have sufficient entropy (128+ bits)
35
+ - [ ] New session token issued on login (no session fixation)
36
+ - [ ] Sessions invalidated on logout, password change, and account disable
37
+ - [ ] Cookies set `HttpOnly`, `Secure`, and `SameSite=Lax` or stricter
38
+ - [ ] MFA available for sensitive operations
39
+ - [ ] JWTs: algorithm pinned server-side (`alg: none` and algorithm confusion rejected),
40
+ signature verified, `exp`/`aud`/`iss` checked
41
+
42
+ ## Access Control (A01)
43
+ - [ ] Authorization checked on every request
44
+ - [ ] Using object references user cannot manipulate
45
+ - [ ] Deny by default policy
46
+ - [ ] Privilege escalation paths reviewed
47
+ - [ ] Object-level checks verify ownership/tenancy, not just "is authenticated" (IDOR/BOLA)
48
+ - [ ] State-changing requests protected against CSRF (token or `SameSite` + origin check)
49
+ - [ ] Redirect targets validated against an allowlist (no open redirect)
50
+ - [ ] CORS: no `Access-Control-Allow-Origin: *` combined with credentials, no origin reflection
51
+
52
+ ## Server-Side Request Forgery (A01)
53
+ - [ ] User-supplied URLs resolved and validated against an allowlist of hosts/schemes
54
+ - [ ] Private, loopback, and link-local ranges blocked, including after DNS resolution
55
+ - [ ] The connection goes to the IP that was validated: pin it, or validate inside a custom dialer
56
+ or agent at connect time. Resolve, check, then fetch by hostname is open to DNS rebinding
57
+ - [ ] Redirects not followed blindly to a new host (re-validate each hop)
58
+ - [ ] Cloud metadata endpoints (`169.254.169.254`) unreachable from the app
59
+
60
+ ## File Handling (A01)
61
+ - [ ] Upload type validated by content, not just extension or `Content-Type`
62
+ - [ ] Uploads stored outside the web root, served with a non-executable content type
63
+ - [ ] File size limits and quota enforced
64
+ - [ ] Paths built from user input canonicalized and confined to a base directory (no `../`)
65
+ - [ ] Archive extraction guards against path traversal and zip bombs
66
+
67
+ ## Insecure Design (A06)
68
+ - [ ] Prices, quantities, roles, and state transitions decided server-side, never taken from the client
69
+ - [ ] Rate limits on login, password reset, OTP, signup, and expensive operations
70
+ - [ ] Multi-step flows can't be skipped, reordered, or replayed (one-time tokens, idempotency keys)
71
+ - [ ] Balance, inventory, and coupon updates are atomic (no check-then-write race)
72
+
73
+ ## Configuration & Hardening (A02)
74
+ - [ ] Debug mode, verbose errors, and dev tooling disabled in production
75
+ - [ ] Default credentials and sample/admin accounts removed
76
+ - [ ] Unused features, ports, endpoints, and HTTP methods disabled
77
+ - [ ] Security headers set: CSP without `unsafe-inline`/`unsafe-eval`, HSTS,
78
+ `X-Content-Type-Options: nosniff`, `Referrer-Policy`
79
+ - [ ] Cloud storage and object buckets are not publicly readable/writable
80
+ - [ ] Container/infra config reviewed (non-root user, no privileged mode, no secrets in image layers)
81
+
82
+ ## Dependencies & Supply Chain (A03)
83
+ - [ ] Lockfile committed and versions pinned (no floating ranges in production builds)
84
+ - [ ] Dependencies scanned for known vulnerabilities and unmaintained packages
85
+ - [ ] Package names checked against typosquats and dependency confusion (internal names claimed publicly)
86
+ - [ ] Third-party scripts loaded with Subresource Integrity, or self-hosted
87
+ - [ ] Build and CI scripts reviewed: install hooks and pipeline steps run with repo write access
88
+ - [ ] Artifacts and releases signed; signatures verified before deploy
89
+
90
+ ## Serialization & Data Integrity (A08)
91
+ - [ ] No deserialization of untrusted data with a native format (`pickle`, `Marshal`,
92
+ `ObjectInputStream`, `BinaryFormatter`, `yaml.load`)
93
+ - [ ] JSON/schema-validated formats used instead, with a type allowlist
94
+ - [ ] Auto-update and plugin loading verify signatures before execution
95
+
96
+ ## Data Protection (A04)
97
+ - [ ] Sensitive data encrypted at rest
98
+ - [ ] TLS for all data in transit
99
+ - [ ] No sensitive data in URLs/logs
100
+ - [ ] Secrets in environment/vault (not code), and not in git history or container layers
101
+ - [ ] Authenticated encryption (AES-GCM/ChaCha20-Poly1305); no ECB, no unauthenticated CBC
102
+ - [ ] IVs/nonces unique per encryption; randomness from a CSPRNG, not `Math.random`/`rand()`
103
+ - [ ] Secrets and tokens compared in constant time
104
+
105
+ ## Error Handling & Logging (A09/A10)
106
+ - [ ] No stack traces exposed to users
107
+ - [ ] Fail-closed on errors (deny, not allow)
108
+ - [ ] All exceptions logged with context
109
+ - [ ] Consistent error responses (no user/account enumeration via message or timing)
110
+ - [ ] Auth events, authorization failures, and security-control failures logged
111
+ - [ ] Logs exclude credentials, tokens, and PII; user input encoded to prevent log injection
112
+ - [ ] Empty `catch` blocks and swallowed errors reviewed: silent failure hides attacks
113
+
114
+ ## LLM and Agent Features (LLM Top 10 2026, Agentic 2026)
115
+ - [ ] Untrusted text (user input, web pages, email, RAG chunks, tool output) can't steer a model
116
+ that holds privileged tools (LLM01, ASI01)
117
+ - [ ] Model output validated or escaped before any SQL, shell, HTML, code, or tool argument (LLM10)
118
+ - [ ] Tools minimal and scoped; no general shell or HTTP tool unless required; destructive
119
+ actions need human approval (LLM03, ASI02)
120
+ - [ ] Agent credentials short-lived and scoped to the task, never an admin or the user's full session (ASI03)
121
+ - [ ] Retrieval enforces the caller's tenant and permissions at query time (LLM02, LLM09)
122
+ - [ ] No secrets or authorization logic in the system prompt, tool schemas, or other hidden context (LLM08)
123
+ - [ ] MCP servers, plugins, and models pinned and from trusted sources (LLM04, ASI04)
124
+ - [ ] Generated code runs in a sandbox (ASI05)
125
+ - [ ] Writes to agent memory or the vector store validated, so untrusted content can't persist
126
+ instructions (ASI06)
127
+ - [ ] Per-user caps on requests, tokens, tool calls, and cost, plus hard timeouts (LLM06)
128
+ - [ ] Messages between agents authenticated and integrity-checked; a receiving agent doesn't
129
+ trust the sender's claims about identity or authority (ASI07)
130
+ - [ ] One agent's failure or bad output can't cascade: step, retry, and fan-out limits, plus
131
+ circuit breakers between components (ASI08)
132
+ - [ ] AI-generated content labelled; approval prompts show the real action, so an agent can't
133
+ talk a user into approving something else (ASI09)
134
+ - [ ] Tool calls logged, with a way to stop a running agent (ASI10)
@@ -111,7 +111,8 @@ sequences — the single most expensive failure observed. Track progress in
111
111
  a ledger file, not only in todos.
112
112
 
113
113
  - Each plan owns a workspace: at skill start, run this skill's
114
- `bash scripts/sdd-workspace PLAN_FILE` — it prints the plan's git-ignored
114
+ `bash scripts/sdd-workspace PLAN_FILE` by its absolute path, from the
115
+ working tree you're executing in — it prints the plan's git-ignored
115
116
  directory (under `<repo-root>/.superpowers/sdd/`), home to
116
117
  every artifact for THIS plan: ledger, briefs, reports, review packages.
117
118
  Another plan's directory is never yours to read or write.
@@ -200,7 +201,8 @@ Record BASE (`git rev-parse HEAD`) before dispatching — the review package
200
201
  and fix-round diffs need it.
201
202
 
202
203
  - **Task brief:** before dispatching an implementer, run this skill's
203
- `bash scripts/task-brief PLAN_FILE N` — it extracts the task's full text to a
204
+ `bash scripts/task-brief PLAN_FILE N` by its absolute path, from the
205
+ working tree you're executing in — it extracts the task's full text to a
204
206
  uniquely named file and prints the path. Compose the dispatch so the
205
207
  brief stays the single source of
206
208
  requirements. Your dispatch should contain: (1) one line on where this
@@ -238,7 +240,7 @@ Template: [implementer-prompt.md](implementer-prompt.md)
238
240
 
239
241
  Implementer subagents report one of four statuses. Handle each appropriately:
240
242
 
241
- **DONE:** Generate the review package (`bash scripts/review-package PLAN_FILE BASE HEAD`, from this skill's directory — it prints the unique file path it wrote; BASE is the commit you recorded before dispatching the implementer — never `HEAD~1`, which silently drops all but the last commit of a multi-commit task), then dispatch the task reviewer with the printed path.
243
+ **DONE:** Generate the review package (`bash scripts/review-package PLAN_FILE BASE HEAD` by its absolute path, from the working tree you're executing in — it prints the unique file path it wrote; BASE is the commit you recorded before dispatching the implementer — never `HEAD~1`, which silently drops all but the last commit of a multi-commit task), then dispatch the task reviewer with the printed path.
242
244
 
243
245
  **Any other status** (DONE_WITH_CONCERNS, NEEDS_CONTEXT, BLOCKED): read
244
246
  [references/handling-reports.md](references/handling-reports.md) and follow
@@ -257,7 +259,8 @@ required. Implementer self-review never replaces the task review; both are
257
259
  needed.
258
260
 
259
261
  - Hand the reviewer its diff as a file: run this skill's
260
- `bash scripts/review-package PLAN_FILE BASE HEAD` and pass the reviewer the file path
262
+ `bash scripts/review-package PLAN_FILE BASE HEAD` by its absolute path, from
263
+ the working tree you're executing in, and pass the reviewer the file path
261
264
  it prints (or, without bash: `git log --oneline`, `git diff --stat`,
262
265
  and `git diff -U10` for the range, redirected to one uniquely named
263
266
  file). The output never enters your own context, and the reviewer sees
@@ -0,0 +1,75 @@
1
+ ---
2
+ name: to-spec
3
+ description: "Turn the current conversation into a spec and publish it to the project issue tracker: no interview, just synthesis of what you've already discussed."
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ This skill takes the current conversation context and codebase understanding and produces a spec. Do NOT interview the user; just synthesize what you already know.
8
+
9
+ The issue tracker and triage label vocabulary should have been provided to you. If not, tell the user to run `/setup-matt-pocock-skills`.
10
+
11
+ ## Process
12
+
13
+ 1. Explore the repo to understand the current state of the codebase, if you haven't already. Use the project's domain glossary vocabulary throughout the spec, and respect any ADRs in the area you're touching.
14
+
15
+ 2. Sketch out the seams at which you're going to test the feature. Existing seams should be preferred to new ones. Use the highest seam possible. If new seams are needed, propose them at the highest point you can. The fewer seams across the codebase, the better - the ideal number is one.
16
+
17
+ Check with the user that these seams match their expectations.
18
+
19
+ 3. Write the spec using the template below, then publish it to the project issue tracker. Apply the `ready-for-agent` triage label - no need for additional triage.
20
+
21
+ <spec-template>
22
+
23
+ ## Problem Statement
24
+
25
+ The problem that the user is facing, from the user's perspective.
26
+
27
+ ## Solution
28
+
29
+ The solution to the problem, from the user's perspective.
30
+
31
+ ## User Stories
32
+
33
+ A LONG, numbered list of user stories. Each user story should be in the format of:
34
+
35
+ 1. As an <actor>, I want a <feature>, so that <benefit>
36
+
37
+ <user-story-example>
38
+ 1. As a mobile bank customer, I want to see balance on my accounts, so that I can make better informed decisions about my spending
39
+ </user-story-example>
40
+
41
+ This list of user stories should be extremely extensive and cover all aspects of the feature.
42
+
43
+ ## Implementation Decisions
44
+
45
+ A list of implementation decisions that were made. This can include:
46
+
47
+ - The modules that will be built/modified
48
+ - The interfaces of those modules that will be modified
49
+ - Technical clarifications from the developer
50
+ - Architectural decisions
51
+ - Schema changes
52
+ - API contracts
53
+ - Specific interactions
54
+
55
+ Do NOT include specific file paths or code snippets. They may end up being outdated very quickly.
56
+
57
+ Exception: if a prototype produced a snippet that encodes a decision more precisely than prose can (state machine, reducer, schema, type shape), inline it within the relevant decision and note briefly that it came from a prototype. Trim to the decision-rich parts, not a working demo, just the important bits.
58
+
59
+ ## Testing Decisions
60
+
61
+ A list of testing decisions that were made. Include:
62
+
63
+ - A description of what makes a good test (only test external behavior, not implementation details)
64
+ - Which modules will be tested
65
+ - Prior art for the tests (i.e. similar types of tests in the codebase)
66
+
67
+ ## Out of Scope
68
+
69
+ A description of the things that are out of scope for this spec.
70
+
71
+ ## Further Notes
72
+
73
+ Any further notes about the feature.
74
+
75
+ </spec-template>
@@ -0,0 +1,105 @@
1
+ ---
2
+ name: to-tickets
3
+ description: Break a plan, spec, or the current conversation into a set of tracer-bullet tickets, each declaring its blocking edges, published to the configured tracker (edges as text in one file per ticket locally, or native blocking links on a real tracker).
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ # To Tickets
8
+
9
+ Break a plan, spec, or conversation into a set of **tickets**: tracer-bullet vertical slices, each declaring the tickets that **block** it.
10
+
11
+ The issue tracker and triage label vocabulary should have been provided to you. If not, tell the user to run `/setup-matt-pocock-skills`.
12
+
13
+ ## Process
14
+
15
+ ### 1. Gather context
16
+
17
+ Work from whatever is already in the conversation context. If the user passes a reference (a spec path, an issue number or URL) as an argument, fetch it and read its full body and comments.
18
+
19
+ ### 2. Explore the codebase (optional)
20
+
21
+ If you have not already explored the codebase, do so to understand the current state of the code. Ticket titles and descriptions should use the project's domain glossary vocabulary, and respect ADRs in the area you're touching.
22
+
23
+ Look for opportunities to prefactor the code to make the implementation easier. "Make the change easy, then make the easy change."
24
+
25
+ ### 3. Draft vertical slices
26
+
27
+ Break the work into **tracer bullet** tickets.
28
+
29
+ <vertical-slice-rules>
30
+
31
+ - Each slice cuts a narrow but COMPLETE path through every layer (schema, API, UI, tests): vertical, NOT a horizontal slice of one layer
32
+ - A completed slice is demoable or verifiable on its own
33
+ - Each slice is sized to fit in a single fresh context window
34
+ - Any prefactoring should be done first
35
+
36
+ </vertical-slice-rules>
37
+
38
+ Give each ticket its **blocking edges**: the other tickets that must complete before it can start. A ticket with no blockers can start immediately.
39
+
40
+ **Wide refactors are the exception to vertical slicing.** A **wide refactor** is one mechanical change (rename a column, retype a shared symbol) whose **blast radius** fans across the whole codebase, so a single edit breaks thousands of call sites at once and no vertical slice can land green. Don't force it into a tracer bullet; sequence it as **expand–contract**. First expand: add the new form beside the old so nothing breaks. Then migrate the call sites over in batches sized by blast radius (per package, per directory), each batch its own ticket blocked by the expand, keeping CI green batch to batch because the old form still exists. Finally contract: delete the old form once no caller remains, in a ticket blocked by every migrate batch. When even the batches can't stay green alone, keep the sequence but let them share an integration branch that all block a final integrate-and-verify ticket; green is promised only there.
41
+
42
+ ### 4. Quiz the user
43
+
44
+ Present the proposed breakdown as a numbered list. For each ticket, show:
45
+
46
+ - **Title**: short descriptive name
47
+ - **Blocked by**: which other tickets (if any) must complete first
48
+ - **What it delivers**: the end-to-end behaviour this ticket makes work
49
+
50
+ Ask the user:
51
+
52
+ - Does the granularity feel right? (too coarse / too fine)
53
+ - Are the blocking edges correct: does each ticket only depend on tickets that genuinely gate it?
54
+ - Should any tickets be merged or split further?
55
+
56
+ Iterate until the user approves the breakdown.
57
+
58
+ ### 5. Publish the tickets to the configured tracker
59
+
60
+ Publish the approved tickets. **How** depends on the tracker `/setup-matt-pocock-skills` configured; the tickets are the same either way, only the shape of the blocking edges changes:
61
+
62
+ - **Local files** → write one file per ticket under `.scratch/<feature-slug>/issues/<NN>-<slug>.md`, numbered from `01` in dependency order (blockers first). Each file's "Blocked by" lists the numbers/titles it depends on. Use the per-ticket file template below: one ticket per file, never a single combined file.
63
+ - **A real issue tracker (GitHub, Linear, …)** → publish one issue per ticket in dependency order (blockers first) so each ticket's blocking edges can reference real identifiers. Use the platform's native blocking relationship where it has one; otherwise set each ticket's "Blocked by" to the blocking issues. If the source was an existing issue, make each ticket its sub-issue (tracker doc's operation). Apply the `ready-for-agent` triage label unless instructed otherwise; the tickets are agent-grabbable by construction.
64
+
65
+ Work the **frontier**: any ticket whose blockers are all done. For a purely linear chain that means top to bottom.
66
+
67
+ Do NOT close or modify any parent issue.
68
+
69
+ <local-ticket-template>
70
+
71
+ # <NN>: <Ticket title>
72
+
73
+ **What to build:** the end-to-end behaviour this ticket makes work, from the user's perspective, not a layer-by-layer implementation list.
74
+
75
+ **Blocked by:** the numbers/titles of the tickets that gate this one, or "None (can start immediately)".
76
+
77
+ **Status:** ready-for-agent
78
+
79
+ - [ ] Acceptance criterion 1
80
+ - [ ] Acceptance criterion 2
81
+
82
+ </local-ticket-template>
83
+
84
+ <issue-template>
85
+
86
+ ## Parent
87
+
88
+ A reference to the parent issue on the tracker (if the source was an existing issue, otherwise omit this section).
89
+
90
+ ## What to build
91
+
92
+ The end-to-end behaviour this ticket makes work, from the user's perspective, not layer-by-layer implementation.
93
+
94
+ ## Acceptance criteria
95
+
96
+ - [ ] Criterion 1
97
+ - [ ] Criterion 2
98
+
99
+ ## Blocked by
100
+
101
+ - A reference to each blocking ticket, or "None (can start immediately)". Omit this section when blockers were set as native edges.
102
+
103
+ </issue-template>
104
+
105
+ In either form, avoid specific file paths or code snippets: they go stale fast. Exception: if a prototype produced a snippet that encodes a decision more precisely than prose can (state machine, reducer, schema, type shape), inline it and note briefly that it came from a prototype. Trim to the decision-rich parts, not a working demo, just the important bits.