@mohammadhprp/system-prompt 0.12.2 → 0.12.4

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 (162) hide show
  1. package/framework/commands/README.md +1 -1
  2. package/framework/commands/review.md +1 -1
  3. package/framework/mcps/README.md +0 -1
  4. package/framework/plugins/ponytail/README.md +0 -1
  5. package/framework/plugins/ponytail/capabilities.md +1 -1
  6. package/framework/references/standards/api.md +0 -1
  7. package/framework/references/standards/architecture.md +0 -1
  8. package/framework/references/standards/database.md +0 -1
  9. package/framework/references/standards/debugging.md +0 -1
  10. package/framework/references/standards/documentation.md +0 -1
  11. package/framework/references/standards/logging.md +0 -1
  12. package/framework/references/standards/naming.md +0 -1
  13. package/framework/references/standards/observability.md +0 -1
  14. package/framework/references/standards/performance.md +0 -1
  15. package/framework/references/standards/pull-requests.md +0 -1
  16. package/framework/references/standards/security.md +0 -1
  17. package/framework/references/standards/testing.md +0 -1
  18. package/framework/skills/README.md +16 -12
  19. package/framework/skills/architect/SKILL.md +83 -0
  20. package/framework/skills/architect/examples.md +5 -0
  21. package/framework/skills/architect/references/design-red-flags.md +33 -0
  22. package/framework/skills/architect/references/rationale-template.md +35 -0
  23. package/framework/skills/architect/references/runner-prompt.md +20 -0
  24. package/framework/skills/arena/SKILL.md +71 -0
  25. package/framework/skills/arena/examples.md +5 -0
  26. package/framework/skills/bro/SKILL.md +7 -0
  27. package/framework/skills/bro/examples.md +5 -0
  28. package/framework/skills/changelog/SKILL.md +41 -0
  29. package/framework/skills/changelog/examples.md +5 -0
  30. package/framework/skills/commit/SKILL.md +28 -0
  31. package/framework/skills/commit/examples.md +5 -0
  32. package/framework/skills/how/SKILL.md +135 -0
  33. package/framework/skills/how/examples.md +5 -0
  34. package/framework/skills/how/references/critic-prompt.md +59 -0
  35. package/framework/skills/how/references/critique-rubric.md +58 -0
  36. package/framework/skills/how/references/explainer-prompt.md +55 -0
  37. package/framework/skills/how/references/explorer-prompt.md +52 -0
  38. package/framework/skills/improve/SKILL.md +1 -3
  39. package/framework/skills/improve/examples.md +1 -1
  40. package/framework/skills/laravel-best-practices/SKILL.md +56 -216
  41. package/framework/skills/laravel-best-practices/references/architecture.md +1 -1
  42. package/framework/skills/laravel-best-practices/references/checklist.md +139 -0
  43. package/framework/skills/laravel-best-practices/references/eloquent.md +4 -2
  44. package/framework/skills/laravel-best-practices/references/infer-conventions.md +97 -0
  45. package/framework/skills/laravel-best-practices/references/pest-testing.md +47 -18
  46. package/framework/skills/laravel-best-practices/references/security.md +1 -1
  47. package/framework/skills/laravel-best-practices/references/style.md +1 -1
  48. package/framework/skills/laravel-best-practices/references/tailwindcss.md +0 -1
  49. package/framework/skills/merge-request/SKILL.md +40 -0
  50. package/framework/skills/merge-request/examples.md +5 -0
  51. package/framework/skills/pull-request/SKILL.md +31 -0
  52. package/framework/skills/pull-request/examples.md +5 -0
  53. package/framework/skills/release/SKILL.md +30 -0
  54. package/framework/skills/release/examples.md +5 -0
  55. package/framework/skills/review/SKILL.md +18 -0
  56. package/framework/skills/review/examples.md +5 -0
  57. package/framework/skills/tdd/SKILL.md +44 -0
  58. package/framework/skills/tdd/examples.md +5 -0
  59. package/framework/skills/unslop/SKILL.md +81 -0
  60. package/framework/skills/unslop/examples.md +5 -0
  61. package/framework/skills/why/SKILL.md +230 -0
  62. package/framework/skills/why/examples.md +5 -0
  63. package/framework/skills/why/references/epistemics.md +144 -0
  64. package/framework/skills/why/references/investigator-prompt.md +103 -0
  65. package/framework/skills/why/references/source-playbook.md +17 -0
  66. package/framework/skills/why/references/sources/code-archaeology.md +88 -0
  67. package/framework/skills/why/references/sources/databricks.md +70 -0
  68. package/framework/skills/why/references/sources/datadog.md +99 -0
  69. package/framework/skills/why/references/sources/incident-postmortem.md +15 -0
  70. package/framework/skills/why/references/sources/linear.md +48 -0
  71. package/framework/skills/why/references/sources/notion.md +55 -0
  72. package/framework/skills/why/references/sources/sentry.md +100 -0
  73. package/framework/skills/why/references/sources/slack.md +54 -0
  74. package/framework/skills/why/references/synthesizer-prompt.md +135 -0
  75. package/package.json +1 -1
  76. package/src/catalog.js +13 -12
  77. package/framework/mcps/notion-mcp/README.md +0 -57
  78. package/framework/mcps/notion-mcp/capabilities.md +0 -118
  79. package/framework/mcps/notion-mcp/configs/opencode.json +0 -9
  80. package/framework/mcps/notion-mcp/install.md +0 -70
  81. package/framework/mcps/notion-mcp/troubleshooting.md +0 -95
  82. package/framework/skills/brainstorming/SKILL.md +0 -159
  83. package/framework/skills/brainstorming/examples.md +0 -49
  84. package/framework/skills/brainstorming/scripts/frame-template.html +0 -213
  85. package/framework/skills/brainstorming/scripts/helper.js +0 -167
  86. package/framework/skills/brainstorming/scripts/server.cjs +0 -723
  87. package/framework/skills/brainstorming/scripts/start-server.sh +0 -209
  88. package/framework/skills/brainstorming/scripts/stop-server.sh +0 -120
  89. package/framework/skills/brainstorming/visual-companion.md +0 -291
  90. package/framework/skills/code-review/SKILL.md +0 -72
  91. package/framework/skills/code-review/examples.md +0 -31
  92. package/framework/skills/codenavi/SKILL.md +0 -306
  93. package/framework/skills/codenavi/examples.md +0 -33
  94. package/framework/skills/codenavi/references/coding-principles.md +0 -143
  95. package/framework/skills/codenavi/references/notebook-spec.md +0 -171
  96. package/framework/skills/create-adr/SKILL.md +0 -429
  97. package/framework/skills/create-adr/examples.md +0 -35
  98. package/framework/skills/design/SKILL.md +0 -399
  99. package/framework/skills/design/examples.md +0 -34
  100. package/framework/skills/great-interface/SKILL.md +0 -43
  101. package/framework/skills/great-interface/references/animations.md +0 -205
  102. package/framework/skills/great-interface/references/better-accessibility.md +0 -106
  103. package/framework/skills/great-interface/references/better-colors.md +0 -100
  104. package/framework/skills/great-interface/references/better-interface.md +0 -132
  105. package/framework/skills/great-interface/references/better-layout.md +0 -76
  106. package/framework/skills/great-interface/references/better-typography.md +0 -157
  107. package/framework/skills/great-interface/references/better-ui.md +0 -107
  108. package/framework/skills/great-interface/references/better-writing.md +0 -109
  109. package/framework/skills/great-interface/references/choosing-fonts.md +0 -64
  110. package/framework/skills/great-interface/references/color-formats.md +0 -90
  111. package/framework/skills/great-interface/references/color-usage.md +0 -118
  112. package/framework/skills/great-interface/references/contrast.md +0 -79
  113. package/framework/skills/great-interface/references/css-cheat-sheet.md +0 -65
  114. package/framework/skills/great-interface/references/details-and-accessibility.md +0 -119
  115. package/framework/skills/great-interface/references/enter-exit.md +0 -147
  116. package/framework/skills/great-interface/references/explain-interface.md +0 -126
  117. package/framework/skills/great-interface/references/find-the-effect.md +0 -94
  118. package/framework/skills/great-interface/references/focus-and-keyboard.md +0 -131
  119. package/framework/skills/great-interface/references/forms.md +0 -84
  120. package/framework/skills/great-interface/references/from-an-image.md +0 -55
  121. package/framework/skills/great-interface/references/grouping-and-alignment.md +0 -123
  122. package/framework/skills/great-interface/references/hit-areas.md +0 -94
  123. package/framework/skills/great-interface/references/icon-transitions.md +0 -102
  124. package/framework/skills/great-interface/references/icons.md +0 -110
  125. package/framework/skills/great-interface/references/interface-review.md +0 -148
  126. package/framework/skills/great-interface/references/motion-and-zoom.md +0 -79
  127. package/framework/skills/great-interface/references/no-browser.md +0 -73
  128. package/framework/skills/great-interface/references/palette-generation.md +0 -104
  129. package/framework/skills/great-interface/references/palette-structure.md +0 -76
  130. package/framework/skills/great-interface/references/performance.md +0 -88
  131. package/framework/skills/great-interface/references/picker.md +0 -76
  132. package/framework/skills/great-interface/references/read-the-system.md +0 -178
  133. package/framework/skills/great-interface/references/removed-signals.md +0 -38
  134. package/framework/skills/great-interface/references/review-format.md +0 -46
  135. package/framework/skills/great-interface/references/scope-resolution.md +0 -88
  136. package/framework/skills/great-interface/references/screen-readers.md +0 -101
  137. package/framework/skills/great-interface/references/semantics-and-aria.md +0 -84
  138. package/framework/skills/great-interface/references/spacing-and-adaptivity.md +0 -159
  139. package/framework/skills/great-interface/references/spacing-and-sizing.md +0 -121
  140. package/framework/skills/great-interface/references/surfaces.md +0 -219
  141. package/framework/skills/great-interface/references/token-naming.md +0 -97
  142. package/framework/skills/great-interface/references/variable-fonts-and-opentype.md +0 -105
  143. package/framework/skills/great-interface/references/variant.md +0 -104
  144. package/framework/skills/great-interface/references/wrapping-and-punctuation.md +0 -55
  145. package/framework/skills/learning-opportunities/SKILL.md +0 -140
  146. package/framework/skills/learning-opportunities/examples.md +0 -34
  147. package/framework/skills/learning-opportunities/references/PRINCIPLES.md +0 -42
  148. package/framework/skills/notion-mcp/SKILL.md +0 -57
  149. package/framework/skills/notion-mcp/examples.md +0 -31
  150. package/framework/skills/notion-mcp/references/comments.md +0 -112
  151. package/framework/skills/notion-mcp/references/databases.md +0 -193
  152. package/framework/skills/notion-mcp/references/pages.md +0 -235
  153. package/framework/skills/spec-driven-eval/SKILL.md +0 -341
  154. package/framework/skills/spec-driven-eval/examples.md +0 -35
  155. package/framework/skills/spec-driven-eval/references/quickstart.md +0 -118
  156. package/framework/skills/spec-driven-eval/references/reference.md +0 -295
  157. package/framework/skills/technical-design-doc-creator/README.md +0 -411
  158. package/framework/skills/technical-design-doc-creator/SKILL.md +0 -1484
  159. package/framework/skills/technical-design-doc-creator/examples.md +0 -35
  160. package/framework/skills/web-design-guidelines/SKILL.md +0 -65
  161. package/framework/skills/web-design-guidelines/examples.md +0 -32
  162. package/framework/skills/web-design-guidelines/references/guideline.md +0 -174
@@ -0,0 +1,135 @@
1
+ ---
2
+ name: how
3
+ description: "Use for \"how does X work\", code walkthroughs before changing something, and placement / ownership / layering questions (\"where should this live\", \"which package owns this\", \"is this the right layer\"). Explains subsystem architecture, runtime flow, onboarding mental models. Can critique architecture. Use why for motivation."
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ # How
8
+
9
+ Explore the codebase to answer "how does X work?" questions. Produce clear architectural explanations at the level of a senior engineer onboarding onto a subsystem. Enough to build a working mental model, not annotated source code.
10
+
11
+ Two modes:
12
+
13
+ 1. **Explain** (default). Explore the codebase and produce a clear explanation
14
+ 2. **Critique.** Explain first, then spawn multiple models to independently identify architectural issues
15
+
16
+ ## Explain Mode
17
+
18
+ ### Step 1. Understand the Question and Assess Complexity
19
+
20
+ Parse what the user is asking about:
21
+
22
+ - "How does the rate limiter work?", a subsystem
23
+ - "How do we handle billing for on-demand usage?", a feature flow
24
+ - "How is the auth service structured?", an architectural overview
25
+ - "Walk me through what happens when a user submits a form", a runtime trace
26
+
27
+ Identify the scope. If ambiguous, state your best-guess interpretation before exploring. Don't ask. Let the user redirect if you're off.
28
+
29
+ **Assess complexity to decide the approach:**
30
+
31
+ - **Simple** (a single module, a small utility, a narrow question like "how does function X work"): skip explorer agents; the explainer explores and explains in a single pass. Go to Step 2b.
32
+ - **Complex** (a subsystem spanning multiple files/services, a cross-cutting feature, a full architectural overview): spawn parallel explorer agents first, then hand off to the explainer. Go to Step 2a.
33
+
34
+ When in doubt, lean simple. You can always spawn explorers if the explainer hits a wall.
35
+
36
+ ### Step 2a. Explore (complex questions only)
37
+
38
+ Decompose the question into 2-4 parallel exploration angles, each a distinct slice of the subsystem so explorers don't duplicate work. Example split for "how does the rate limiter work?":
39
+
40
+ - Explorer 1: data model and state management
41
+ - Explorer 2: request path and enforcement
42
+ - Explorer 3: configuration and metrics infrastructure
43
+
44
+ The right decomposition depends on the question. Use your judgment. Narrow questions: 2 explorers is fine. Broad subsystems: up to 4.
45
+
46
+ Spawn all explorers in a single message:
47
+
48
+ - `subagent_type`: `generalPurpose`
49
+ - `model`: your configured how-explorer model (default `grok-4.6-fast-xhigh`)
50
+ - `readonly`: `true`
51
+
52
+ Each explorer gets the same base prompt from `references/explorer-prompt.md` plus a specific exploration angle naming its slice. Each explorer should:
53
+ - Start broad: Glob for relevant directories, Grep for key types/interfaces/class names
54
+ - Follow the thread: from an entry point, trace the call chain (callers, callees, data flow, type definitions)
55
+ - Read the actual code, don't guess from file names
56
+ - Stop when it can describe the full path from input to output (or trigger to effect) without hand-waving any step
57
+ - Note things that are surprising, non-obvious, or that a newcomer would get wrong
58
+
59
+ Each explorer returns structured findings: components found, flow traced, files read, anything non-obvious. Overlap between explorers is fine; the explainer reconciles.
60
+
61
+ Then proceed to Step 3.
62
+
63
+ ### Step 2b. Direct Explain (simple questions)
64
+
65
+ Spawn a single Task subagent that explores and explains in one pass:
66
+
67
+ - `subagent_type`: `generalPurpose`
68
+ - `model`: your configured how-explainer model (default `claude-fable-5-1-thinking-max`)
69
+ - `readonly`: `true`
70
+
71
+ The agent does its own exploration (Glob, Grep, Read) and writes the explanation directly. Read `references/explainer-prompt.md` for the communication style and output format. Same structure, just no explorer findings as input.
72
+
73
+ Proceed to Step 4.
74
+
75
+ ### Step 3. Synthesize (complex questions only)
76
+
77
+ Once all explorers return, spawn a single Task subagent to synthesize their findings into one coherent explanation:
78
+
79
+ - `subagent_type`: `generalPurpose`
80
+ - `model`: your configured how-explainer model (default `claude-fable-5-1-thinking-max`)
81
+ - `readonly`: `true`
82
+
83
+ The explainer gets all explorers' findings and writes the human-facing explanation (output format below). Read `references/explainer-prompt.md` for the full prompt template. The explainer reconciles overlapping findings, resolves contradictions, and weaves the slices into a unified picture.
84
+
85
+ ### Step 4. Present
86
+
87
+ Present the explainer's output to the user. You may lightly edit for clarity or add context from the conversation, but don't substantially rewrite. The explainer's communication is the product.
88
+
89
+ ### Output Format
90
+
91
+ Follow this structure, adapted to the question. Not every section is needed for every question.
92
+
93
+ **Overview.** 1-2 paragraphs. What it is, what it does, why it exists. Enough to decide whether to keep reading.
94
+
95
+ **Key Concepts.** The important types, services, or abstractions. Brief definition of each. Not exhaustive, just the ones needed to understand the rest.
96
+
97
+ **How It Works.** The core of the explanation. Walk through the flow: what triggers it, what happens step by step, where data goes, the decision points. Prose, not pseudocode. Reference specific files and functions so the reader can go look, but don't dump code blocks unless a snippet is genuinely necessary.
98
+
99
+ **Where Things Live.** A brief map of the relevant files/directories. Not every file, just the ones needed to start working in this area.
100
+
101
+ **Gotchas.** Non-obvious or surprising things that would trip someone up. Historical context that explains why something looks weird. Known sharp edges.
102
+
103
+ ## Critique Mode
104
+
105
+ Triggered when the user asks for architectural issues, problems, or improvements, not just understanding.
106
+
107
+ ### Step 1. Explain First
108
+
109
+ Run the full explain flow above (Steps 1-4). You must understand the architecture before critiquing it.
110
+
111
+ ### Step 2. Spawn Critics
112
+
113
+ After the explanation is complete, spawn one architectural critic per model in your configured how-critics list (defaults `claude-fable-5-1-thinking-max`, `gpt-5.6-sol-max`, `grok-4.6-fast-xhigh`, `claude-opus-5-thinking-xhigh`), all in a single message.
114
+
115
+ For each critic:
116
+ - `subagent_type`: `generalPurpose`
117
+ - `model`: one model from the configured how-critics list. These are minimum reasoning levels. The lead should escalate any model when the architecture warrants deeper analysis.
118
+ - `readonly`: `true`
119
+
120
+ Read `references/critic-prompt.md` for the prompt template. Each critic gets:
121
+ 1. The explanation from Step 1 (so they don't re-explore)
122
+ 2. The relevant file paths (so they can read the actual code)
123
+ 3. The architectural critique rubric from `references/critique-rubric.md`
124
+
125
+ ### Step 3. Lead Judgment
126
+
127
+ Same framework as the interrogate skill. You're a pragmatic lead, not an aggregator.
128
+
129
+ Categorize findings:
130
+ - **Act on.** Architectural problems worth fixing now
131
+ - **Consider.** Real concerns, but the cost/benefit is unclear
132
+ - **Noted.** Valid observations, low priority
133
+ - **Dismissed.** Wrong, missing context, or style preference
134
+
135
+ Present the explanation first (from Step 1), then the critique verdict below it. The explanation should stand on its own; someone who just wants to understand the system shouldn't wade through critique.
@@ -0,0 +1,5 @@
1
+ # Examples
2
+
3
+ - Trace how a request moves through a subsystem and identify the key files, symbols, and decision points.
4
+ - Explain where a new piece of logic belongs and which layer should own it.
5
+ - Walk a new engineer through a complex feature, including important gotchas and runtime flow.
@@ -0,0 +1,59 @@
1
+ # Critic Prompt Template
2
+
3
+ Build each critic subagent's prompt from this template. Fill in the placeholders.
4
+
5
+ ---
6
+
7
+ You are reviewing the architecture of a codebase subsystem. An explanation of how it works has already been written. Read it to orient yourself, then read the actual code to form your own judgment.
8
+
9
+ ## Architectural Explanation
10
+
11
+ {EXPLANATION}
12
+
13
+ ## Relevant Files
14
+
15
+ {FILE_PATHS}
16
+
17
+ ## Critique Rubric
18
+
19
+ {CRITIQUE_RUBRIC_CONTENTS}
20
+
21
+ ## Instructions
22
+
23
+ Read the files listed above. Use the explanation as a map, but form your own opinions from the code itself. The explanation might miss things or frame them charitably.
24
+
25
+ Find architectural problems, not line-level bugs or style issues. Ask whether this subsystem is built well for what it needs to do and how it will need to evolve.
26
+
27
+ For each finding:
28
+
29
+ 1. **Severity**: `structural` | `concern` | `observation`
30
+ - `structural`: a fundamental architectural problem. Wrong abstraction boundary, broken data model, coupling that will block future work
31
+ - `concern`: a real issue that makes the system harder to work with or reason about, but not fundamentally broken
32
+ - `observation`: worth noting. A tradeoff that might not age well, a pattern inconsistent with the rest of the codebase, technical debt
33
+ 2. **Finding**: the architectural issue. Be specific. Name the components, the boundary, the coupling.
34
+ 3. **Evidence**: concrete code that demonstrates the problem. Don't just assert that "this is too coupled". Show the dependency chain.
35
+ 4. **Impact**: what the issue costs. Harder to test? Harder to change? Performance cliff at scale? Be concrete about the consequence.
36
+
37
+ ## What to Avoid
38
+
39
+ - Line-level code review (not your job here)
40
+ - Suggesting rewrites without demonstrating a problem with the current approach
41
+ - "This could use more abstraction" without showing what the abstraction would actually solve
42
+ - Flagging intentional tradeoffs with clear benefits as issues
43
+
44
+ If the architecture is sound, say so. An empty critique is a valid outcome.
45
+
46
+ ## Output
47
+
48
+ ```
49
+ ## Findings
50
+
51
+ ### 1. [Severity] Short title
52
+ **Components**: Which parts of the system are involved
53
+ **Finding**: What's wrong architecturally
54
+ **Evidence**: Concrete code references
55
+ **Impact**: What this costs in practice
56
+
57
+ ### 2. [Severity] Short title
58
+ ...
59
+ ```
@@ -0,0 +1,58 @@
1
+ # Architectural Critique Rubric
2
+
3
+ Review through whichever of these lenses are relevant. Not every lens applies to every subsystem.
4
+
5
+ ## Abstraction Fit
6
+
7
+ Are the abstractions pulling their weight?
8
+
9
+ - Does each abstraction represent a real concept, or is it an indirection layer "in case we need it"?
10
+ - Are the boundaries in the right place? Do they separate things that change independently?
11
+ - Is there accidental coupling where components share implementation details they shouldn't need to know about?
12
+ - Is business logic entangled with framework wiring, or cleanly separated?
13
+
14
+ Over-abstraction is as much a problem as under-abstraction. A flat, simple design is fine when the domain is simple.
15
+
16
+ ## Data Model
17
+
18
+ Do the data structures fit the actual usage patterns?
19
+
20
+ - Are the data models designed for how data is actually accessed, or for how it was conceptually modeled?
21
+ - Are there impedance mismatches, places where code constantly reshapes data because the model doesn't match the access pattern?
22
+ - Are types honest? Do they represent what data actually looks like at runtime, or claim more structure than exists?
23
+
24
+ ## Boundary Discipline
25
+
26
+ Are system boundaries clean and well-placed?
27
+
28
+ - Is validation concentrated at entry points, or scattered through internal code?
29
+ - Are errors handled at boundaries and propagated cleanly, or caught and re-thrown at every layer?
30
+ - Does data cross boundaries in well-typed shapes, or as bags of optional fields?
31
+ - Could this subsystem be tested in isolation, or does it require the entire system to be running?
32
+
33
+ ## Evolution Readiness
34
+
35
+ How well will this architecture handle likely changes?
36
+
37
+ - If the most probable next requirement landed tomorrow, how much would change? "One file" or "everything"?
38
+ - Are there hardcoded assumptions that would need to be relaxed?
39
+ - Is the design bolted-on (integrated as an afterthought) or integrated (looks like it was always part of the plan)?
40
+ - Are legacy paths preserved for compatibility that no one depends on?
41
+
42
+ Don't penalize for not handling hypothetical changes. Focus on changes plausible given the codebase's trajectory.
43
+
44
+ ## Complexity vs. Value
45
+
46
+ Is the complexity budget spent wisely?
47
+
48
+ - Is complexity concentrated in the parts that need it (core logic, tricky invariants) or in accidental places (boilerplate, unnecessary indirection, configuration)?
49
+ - Are there simpler ways to achieve the same behavior?
50
+ - Does every component earn its existence, or are there vestigial pieces from an earlier design?
51
+
52
+ ## Consistency
53
+
54
+ Does this subsystem follow the patterns established elsewhere in the codebase?
55
+
56
+ - Are similar problems solved the same way here as elsewhere, or does this area invent its own patterns?
57
+ - If the patterns differ, is there a good reason, or did it just evolve independently?
58
+ - Inconsistency isn't automatically bad. But unexplained inconsistency is a maintenance burden.
@@ -0,0 +1,55 @@
1
+ # Explainer Prompt Template
2
+
3
+ Build the explainer subagent's prompt from this template. Fill in the placeholders.
4
+
5
+ ---
6
+
7
+ You are writing an architectural explanation for a senior engineer. Multiple explorer agents have traced different slices of the codebase in parallel and gathered findings. Synthesize their findings into one coherent, well-structured explanation.
8
+
9
+ ## Original Question
10
+
11
+ > {QUESTION}
12
+
13
+ ## Explorer Findings
14
+
15
+ {EXPLORER_FINDINGS_ALL}
16
+
17
+ ## Instructions
18
+
19
+ The explorers each investigated a different angle of the same subsystem. Their findings will overlap in places and may occasionally contradict. Reconcile them. Merge overlapping descriptions, resolve contradictions by checking the code yourself, and weave the separate slices into a unified picture.
20
+
21
+ Write an explanation a senior engineer unfamiliar with this area could read and walk away with a solid mental model, understanding the architecture well enough to start working in it confidently.
22
+
23
+ You have read-only access to the codebase to check anything, clarify a detail, or fill a gap. Use Read, Grep, and Glob as needed. The explorers did the heavy lifting, so you shouldn't need to re-explore from scratch.
24
+
25
+ ## Output Format
26
+
27
+ Use this structure, adapted to what makes sense for the question. Not every section is needed for every question.
28
+
29
+ ### Overview
30
+ 1-2 paragraphs. What is this thing, what does it do, why does it exist. Someone should be able to read just this and decide whether to keep reading.
31
+
32
+ ### Key Concepts
33
+ The important types, services, or abstractions needed to follow the rest. Brief definitions, not exhaustive.
34
+
35
+ ### How It Works
36
+ The core of the explanation, and the longest section. Walk through the flow: what triggers it, what happens step by step, where data goes, what the decision points are.
37
+
38
+ Use prose, not pseudocode. Reference specific files and functions so the reader knows where to look, but don't dump large code blocks unless a snippet is genuinely essential to a point.
39
+
40
+ When the flow involves multiple components talking to each other, or data transforming through stages, include a diagram. Use mermaid (```mermaid) for structured flows (sequence diagrams, flowcharts, component graphs) or ASCII art for simpler relationships where mermaid would be overkill. Use your judgment. A diagram should clarify, not decorate. If prose covers the flow, skip the diagram.
41
+
42
+ ### Where Things Live
43
+ A brief file/directory map. Just the ones someone would need to start working here.
44
+
45
+ ### Gotchas
46
+ Non-obvious things, surprising behavior, historical context, sharp edges. Skip this section if there's nothing worth calling out.
47
+
48
+ ## Communication Style
49
+
50
+ - Use concrete language, not abstractions-about-abstractions
51
+ - Say "the `UserService` calls `AuthClient.refresh()`" not "the service delegates to the client"
52
+ - When something is complex, explain why it's complex. Don't just describe the complexity
53
+ - When something is simple, don't pad it out
54
+ - If there's a helpful analogy, use it; if there isn't, don't force one
55
+ - If the explorers flagged open questions or gaps, acknowledge them honestly rather than papering over them
@@ -0,0 +1,52 @@
1
+ # Explorer Prompt Template
2
+
3
+ Build each explorer subagent's prompt from this template. Fill in the placeholders.
4
+
5
+ ---
6
+
7
+ You are exploring a codebase to understand how something works. Gather facts: trace code paths, read implementations, map components. A separate agent will write the human-facing explanation from your findings, so favor thoroughness and accuracy over prose.
8
+
9
+ Other explorers are investigating different slices of the same subsystem in parallel. Don't try to cover everything. Focus on your assigned angle and go deep.
10
+
11
+ ## Question
12
+
13
+ > {QUESTION}
14
+
15
+ ## Your Exploration Angle
16
+
17
+ {EXPLORATION_ANGLE}
18
+
19
+ ## Exploration Instructions
20
+
21
+ Start by finding the relevant code. Use Glob to find directories and files, Grep to find key symbols, Read to understand the actual implementation. Don't guess from names. Read the code.
22
+
23
+ Follow this pattern:
24
+ 1. **Find the entry point.** What triggers this behavior? A user action, an API call, a scheduled job? Find where it starts.
25
+ 2. **Trace the flow.** Follow the call chain from the entry point. Read each function. Understand what data flows through and how it transforms.
26
+ 3. **Map the key abstractions.** What types, interfaces, services, or classes are central? Read their definitions. Understand what they represent and why they exist.
27
+ 4. **Find the boundaries.** Where does this subsystem interface with others? What goes in, what comes out?
28
+ 5. **Look for the non-obvious.** Anything surprising? Anything that looks like a historical artifact? Anything a newcomer would misunderstand?
29
+
30
+ Keep exploring until you can describe the full picture without hand-waving. If you hit a part you can't trace, say so explicitly. "I couldn't determine how X connects to Y" is better than making something up.
31
+
32
+ ## Output
33
+
34
+ Return your findings in this structure. Be factual and specific. Reference exact file paths, function names, type names, and line numbers where relevant.
35
+
36
+ ### Components Found
37
+ The key types, services, classes, and abstractions. For each: name, file path, and a one-sentence description of what it does.
38
+
39
+ ### Flow
40
+ The execution flow step by step. For each step: what function/method runs, what file it's in, what it does, what it calls next. Include the data that flows between steps.
41
+
42
+ ### Files Read
43
+ Every file you read during exploration, so the explainer can reference them.
44
+
45
+ ### Boundaries
46
+ Where this subsystem connects to other parts of the codebase. The inputs and outputs.
47
+
48
+ ### Non-Obvious Things
49
+ Anything surprising, historically motivated, or easy to get wrong. Things that look like they should work one way but actually work another.
50
+
51
+ ### Open Questions
52
+ Anything you couldn't fully trace or understand. Be honest about gaps.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: improve
3
- description: Audit an entire repository as a read-only senior advisor, identify evidence-backed bugs, security risks, performance issues, test gaps, technical debt, DX/docs problems, and grounded roadmap opportunities, then produce prioritized handoff plans for another agent. Use for repository-wide audits, improvement roadmaps, and implementation planning from existing code. Do not use for reviewing a specific diff or pull request (use code-review), security-only audits (use security-best-practices), documentation-only edits (use docs-writer), greenfield feature design or implementation (use brainstorming or tlc-spec-driven), or creating and evaluating agent skills (use skill-creator).
3
+ description: Audit an entire repository as a read-only senior advisor, identify evidence-backed bugs, security risks, performance issues, test gaps, technical debt, DX/docs problems, and grounded roadmap opportunities, then produce prioritized handoff plans for another agent. Use for repository-wide audits, improvement roadmaps, and implementation planning from existing code. Do not use for reviewing a specific diff or pull request, security-only audits (use security-best-practices), documentation-only edits (use docs-writer), greenfield feature design or implementation (use tlc-spec-driven), or creating and evaluating agent skills (use skill-creator).
4
4
  license: MIT
5
5
  metadata:
6
6
  author: shadcn
@@ -28,10 +28,8 @@ The economics of this skill: an expensive, high-ceiling model does the part wher
28
28
 
29
29
  Use this skill when the user wants a broad assessment of an existing repository or wants possible improvements prioritized across multiple engineering concerns. Keep the audit advisory and read-only; implementation belongs to a separate executor or to the skill that owns the narrower task.
30
30
 
31
- - Review a specific diff, branch, or pull request with `code-review`.
32
31
  - Perform a security-only assessment with `security-best-practices`.
33
32
  - Edit or restructure documentation with `docs-writer`.
34
- - Explore an unresolved product or UI direction with `brainstorming`.
35
33
  - Specify or implement an approved feature with `tlc-spec-driven`.
36
34
  - Create, evaluate, or optimize an agent skill with `skill-creator`.
37
35
 
@@ -16,4 +16,4 @@
16
16
 
17
17
  **User:** Review the changes in my pull request for authorization bugs and missing tests.
18
18
 
19
- **Expected behavior:** Do not use `improve` for this narrow diff review. Route the request to `code-review`, optionally combining it with `security-best-practices` when a security-only review is explicitly requested.
19
+ **Expected behavior:** Do not use `improve` for this narrow diff review. Decline the broad audit and review the pull request directly, combining it with `security-best-practices` when a security-only review is explicitly requested.