ostacky 0.7.2 → 0.7.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.
- package/README.md +25 -14
- package/assets/agents/ostacky.md +548 -501
- package/assets/commands/install-stack.md +2 -2
- package/assets/mcp/ostacky-controller/index.js +1277 -127
- package/assets/mcp/ostacky-controller/package.json +1 -1
- package/assets/mcp/ostacky-controller/security.js +87 -0
- package/assets/plugins/engram.ts +41 -5
- package/assets/plugins/ostacky-guard.ts +212 -0
- package/assets/skills/brainstorming/SKILL.md +198 -197
- package/assets/skills/execution-mode-evaluation/SKILL.md +9 -1
- package/assets/skills/graceful-degradation/SKILL.md +251 -239
- package/assets/skills/using-git-worktrees/SKILL.md +8 -0
- package/dist/cli.js +417 -90
- package/manifest.json +32 -32
- package/package.json +1 -1
|
@@ -1,197 +1,198 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: brainstorming
|
|
3
|
-
description: "Thinking partner for exploring ideas, investigating problems, and designing solutions. Two modes: creative-design (structured, produces design doc) and open-explore (unstructured, no mandatory output). Use when the user wants to think through something, brainstorm, explore an idea, or design a solution before or during a change."
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Brainstorming
|
|
7
|
-
|
|
8
|
-
A thinking partner that adapts to what the user needs: structured design when they're building something, open exploration when they're investigating or clarifying.
|
|
9
|
-
|
|
10
|
-
**Follow Core Instructions** — `ostacky.md` Core Instructions section for CodeGraph and Engram usage patterns.
|
|
11
|
-
|
|
12
|
-
**IMPORTANT:** Engram is an **MCP server**, not a skill. Tools `engram_mem_save`, `engram_mem_search`, `engram_mem_context` are MCP tools. Do NOT use `skill("engram")` — it doesn't exist.
|
|
13
|
-
|
|
14
|
-
---
|
|
15
|
-
|
|
16
|
-
## Mode Detection
|
|
17
|
-
|
|
18
|
-
| Signal | Mode |
|
|
19
|
-
|--------|------|
|
|
20
|
-
| "design", "build", "create", "add feature", "implement" | **creative-design** |
|
|
21
|
-
| "explore", "investigate", "think through", "what if", "how does" | **open-explore** |
|
|
22
|
-
| "brainstorm", "ideate", "propose approach" | **creative-design** |
|
|
23
|
-
| "
|
|
24
|
-
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
| **
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
- **
|
|
66
|
-
- **
|
|
67
|
-
- **
|
|
68
|
-
- **
|
|
69
|
-
- **
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
-
|
|
75
|
-
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
-
|
|
102
|
-
-
|
|
103
|
-
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
109
|
-
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
-
|
|
114
|
-
-
|
|
115
|
-
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
-
|
|
128
|
-
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
|
146
|
-
|
|
|
147
|
-
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
-
|
|
153
|
-
-
|
|
154
|
-
-
|
|
155
|
-
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
- **
|
|
162
|
-
- **
|
|
163
|
-
- **
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
**The
|
|
170
|
-
**
|
|
171
|
-
**
|
|
172
|
-
|
|
173
|
-
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
- **Don't
|
|
182
|
-
- **Don't
|
|
183
|
-
- **Don't
|
|
184
|
-
- **Don't
|
|
185
|
-
- **
|
|
186
|
-
- **Do
|
|
187
|
-
- **Do
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
-
|
|
197
|
-
-
|
|
1
|
+
---
|
|
2
|
+
name: brainstorming
|
|
3
|
+
description: "Thinking partner for exploring ideas, investigating problems, and designing solutions. Two modes: creative-design (structured, produces design doc) and open-explore (unstructured, no mandatory output). Use when the user wants to think through something, brainstorm, explore an idea, or design a solution before or during a change."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Brainstorming
|
|
7
|
+
|
|
8
|
+
A thinking partner that adapts to what the user needs: structured design when they're building something, open exploration when they're investigating or clarifying.
|
|
9
|
+
|
|
10
|
+
**Follow Core Instructions** — `ostacky.md` Core Instructions section for CodeGraph and Engram usage patterns.
|
|
11
|
+
|
|
12
|
+
**IMPORTANT:** Engram is an **MCP server**, not a skill. Tools `engram_mem_save`, `engram_mem_search`, `engram_mem_context` are MCP tools. Do NOT use `skill("engram")` — it doesn't exist.
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## Mode Detection
|
|
17
|
+
|
|
18
|
+
| Signal | Mode |
|
|
19
|
+
|--------|------|
|
|
20
|
+
| "design", "build", "create", "add feature", "implement" | **creative-design** |
|
|
21
|
+
| "explore", "investigate", "think through", "what if", "how does" | **open-explore** |
|
|
22
|
+
| "brainstorm", "ideate", "propose approach" | **creative-design** |
|
|
23
|
+
| "mejor forma", "qué conviene", "tradeoff", "comparar", "diseñar", "arquitectura", "alternativas", "evaluar opciones" | **creative-design** — **hardening-v2**: SHALL invocar skill con CodeGraph+Engram, 2-3 approaches con tabla trade-offs y recomendación |
|
|
24
|
+
| "check", "understand", "review existing" | **open-explore** |
|
|
25
|
+
| Unclear | Ask in natural language: "¿Querés diseñar algo nuevo o explorar/entender algo existente?" |
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
## Mode 1: creative-design
|
|
30
|
+
|
|
31
|
+
Turn ideas into fully formed designs through collaborative dialogue.
|
|
32
|
+
|
|
33
|
+
### HARD-GATE
|
|
34
|
+
|
|
35
|
+
Do NOT invoke any implementation skill, write any code, or scaffold any project until you have presented a design and the user has approved it. This applies to EVERY project regardless of perceived simplicity.
|
|
36
|
+
|
|
37
|
+
### Process
|
|
38
|
+
|
|
39
|
+
1. **Check Engram** — `engram_mem_search` with keywords from the user's idea. Surface any prior design decisions or similar proposals.
|
|
40
|
+
2. **Explore via CodeGraph** — `codegraph_codegraph_explore` on the affected area. Only `Read` files CodeGraph didn't cover.
|
|
41
|
+
3. **Ask clarifying questions** — one at a time, understand purpose/constraints/success criteria
|
|
42
|
+
4. **Propose 2-3 approaches (hardening-v2 — SHALL)** — con tabla trade-offs (coste|riesgo|complejidad) + evidencia CodeGraph+Engram (+Context7 si librería) sin alucinar, YAGNI, y recomendación con razón; cada approach cita symbols existentes y mem_search hits verificables
|
|
43
|
+
5. **Present design** — in sections scaled to complexity, get user approval after each section. **Gate post-brainstorming (hardening-v2):** tras presentar diseño, preguntar "¿Procedo con este diseño o querés ajustar algo?" y esperar confirmación explícita antes de `record_discovery`, `openspec-propose` o implementación directa
|
|
44
|
+
6. **Write design doc** — save to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` and commit
|
|
45
|
+
7. **Spec self-review** — check for placeholders, contradictions, ambiguity, scope
|
|
46
|
+
8. **User reviews spec** — ask user to review before proceeding
|
|
47
|
+
9. **Save to Engram** — `engram_mem_save` with the design decision and tradeoffs
|
|
48
|
+
10. **Transition** — based on routing decision (see Transition Rules below)
|
|
49
|
+
|
|
50
|
+
### Transition Rules
|
|
51
|
+
|
|
52
|
+
The next step depends on how the change was routed by Ostacky:
|
|
53
|
+
|
|
54
|
+
| Routing | Next Step | When |
|
|
55
|
+
|---------|-----------|------|
|
|
56
|
+
| **DIRECT** (Level 0/0+1) | **Implementación directa** (con gate de confirmación del usuario) | Small changes, no OpenSpec |
|
|
57
|
+
| **SPEC** (Level 1+) | `openspec-propose` | Complex changes requiring OpenSpec artifacts |
|
|
58
|
+
|
|
59
|
+
If you're unsure about routing, ask Ostacky or check the controller state.
|
|
60
|
+
|
|
61
|
+
**Terminal state:** For DIRECT, present the design and get user approval before proceeding to implementation. For SPEC, invoke `openspec-propose`. Do NOT invoke implementation skills directly.
|
|
62
|
+
|
|
63
|
+
### Design Principles
|
|
64
|
+
|
|
65
|
+
- **One question at a time** — Don't overwhelm
|
|
66
|
+
- **Multiple choice preferred** — Easier to answer
|
|
67
|
+
- **YAGNI ruthlessly** — Remove unnecessary features
|
|
68
|
+
- **Explore alternatives** — Always propose 2-3 approaches
|
|
69
|
+
- **Incremental validation** — Present design, get approval before moving on
|
|
70
|
+
- **Design for isolation** — Break into smaller units with clear purposes
|
|
71
|
+
|
|
72
|
+
### Working in Existing Codebases
|
|
73
|
+
|
|
74
|
+
- Explore current structure before proposing changes. Follow existing patterns.
|
|
75
|
+
- Include targeted improvements where existing code affects the work.
|
|
76
|
+
- Don't propose unrelated refactoring. Stay focused on the goal.
|
|
77
|
+
|
|
78
|
+
### Spec Self-Review
|
|
79
|
+
|
|
80
|
+
After writing the spec:
|
|
81
|
+
1. **Placeholder scan:** Any "TBD", "TODO", incomplete sections? Fix them.
|
|
82
|
+
2. **Internal consistency:** Do sections contradict each other?
|
|
83
|
+
3. **Scope check:** Focused enough for a single implementation plan?
|
|
84
|
+
4. **Ambiguity check:** Any requirement interpretable two ways? Pick one.
|
|
85
|
+
|
|
86
|
+
### User Review Gate
|
|
87
|
+
|
|
88
|
+
> "Spec written and committed to `<path>`. Please review it and let me know if you want to make any changes before we start writing out the implementation plan."
|
|
89
|
+
|
|
90
|
+
Wait for response. If changes requested, make them and re-review. Only proceed once approved.
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
## Mode 2: open-explore
|
|
95
|
+
|
|
96
|
+
A stance, not a workflow. Think deeply. Visualize freely. Follow the conversation wherever it goes.
|
|
97
|
+
|
|
98
|
+
### What You Might Do
|
|
99
|
+
|
|
100
|
+
**Explore the problem space**
|
|
101
|
+
- Ask clarifying questions that emerge from what they said
|
|
102
|
+
- Challenge assumptions
|
|
103
|
+
- Reframe the problem
|
|
104
|
+
- Find analogies
|
|
105
|
+
|
|
106
|
+
**Investigate the codebase**
|
|
107
|
+
- Map existing architecture relevant to the discussion
|
|
108
|
+
- Find integration points
|
|
109
|
+
- Identify patterns already in use
|
|
110
|
+
- Surface hidden complexity
|
|
111
|
+
|
|
112
|
+
**Compare options**
|
|
113
|
+
- Brainstorm multiple approaches
|
|
114
|
+
- Build comparison tables
|
|
115
|
+
- Sketch tradeoffs
|
|
116
|
+
- Recommend a path (if asked)
|
|
117
|
+
|
|
118
|
+
**Visualize**
|
|
119
|
+
```
|
|
120
|
+
Use ASCII diagrams liberally:
|
|
121
|
+
System diagrams, state machines, data flows,
|
|
122
|
+
architecture sketches, dependency graphs,
|
|
123
|
+
comparison tables
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
**Surface risks and unknowns**
|
|
127
|
+
- Identify what could go wrong
|
|
128
|
+
- Find gaps in understanding
|
|
129
|
+
- Suggest spikes or investigations
|
|
130
|
+
|
|
131
|
+
### OpenSpec Awareness
|
|
132
|
+
|
|
133
|
+
Check for active changes at start:
|
|
134
|
+
```bash
|
|
135
|
+
openspec list --json
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
If a change exists and the user mentions it:
|
|
139
|
+
1. Read existing artifacts (`proposal.md`, `design.md`, `tasks.md`)
|
|
140
|
+
2. Reference them naturally in conversation
|
|
141
|
+
3. Offer to capture when decisions are made — don't auto-capture
|
|
142
|
+
|
|
143
|
+
| Insight Type | Where to Capture |
|
|
144
|
+
|---|---|
|
|
145
|
+
| New requirement | `specs/<capability>/spec.md` |
|
|
146
|
+
| Design decision | `design.md` |
|
|
147
|
+
| Scope change | `proposal.md` |
|
|
148
|
+
| New work | `tasks.md` |
|
|
149
|
+
|
|
150
|
+
### What You Don't Have To Do
|
|
151
|
+
|
|
152
|
+
- Follow a script
|
|
153
|
+
- Produce a specific artifact
|
|
154
|
+
- Reach a conclusion
|
|
155
|
+
- Stay on topic if a tangent is valuable
|
|
156
|
+
- Be brief (this is thinking time)
|
|
157
|
+
|
|
158
|
+
### Ending Discovery
|
|
159
|
+
|
|
160
|
+
No required ending. Discovery might:
|
|
161
|
+
- **Flow into a proposal:** "Ready to start? I can create a change proposal." → invoke `openspec-propose`
|
|
162
|
+
- **Result in artifact updates:** "Updated design.md with these decisions"
|
|
163
|
+
- **Just provide clarity:** User has what they need, moves on
|
|
164
|
+
- **Continue later:** "We can pick this up anytime"
|
|
165
|
+
|
|
166
|
+
When things crystallize, summarize:
|
|
167
|
+
```
|
|
168
|
+
## What We Figured Out
|
|
169
|
+
**The problem**: [understanding]
|
|
170
|
+
**The approach**: [if one emerged]
|
|
171
|
+
**Open questions**: [if any]
|
|
172
|
+
**Next steps** (if ready):
|
|
173
|
+
- Create a change proposal (invoke openspec-propose)
|
|
174
|
+
- Keep exploring
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
But the summary is optional. Sometimes the thinking IS the value.
|
|
178
|
+
|
|
179
|
+
### Guardrails
|
|
180
|
+
|
|
181
|
+
- **Don't implement** — Never write code. Creating OpenSpec artifacts is fine.
|
|
182
|
+
- **Don't fake understanding** — Dig deeper if unclear
|
|
183
|
+
- **Don't rush** — Discovery is thinking time, not task time
|
|
184
|
+
- **Don't force structure** — Let patterns emerge naturally
|
|
185
|
+
- **Don't auto-capture** — Offer to save insights, don't just do it
|
|
186
|
+
- **Do visualize** — A good diagram is worth many paragraphs
|
|
187
|
+
- **Do explore the codebase** — Ground discussions in reality
|
|
188
|
+
- **Do question assumptions** — Including your own
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
## Visual Companion
|
|
193
|
+
|
|
194
|
+
Browser use is text-only by default.
|
|
195
|
+
|
|
196
|
+
- Only use the browser when the user explicitly asks for browser/visual help.
|
|
197
|
+
- Do not suggest the browser just because it might explain something more clearly.
|
|
198
|
+
- If the user asks for browser/visual help, use illustrations and diagrams in the conversation to explain concepts.
|
|
@@ -112,6 +112,7 @@ Para cada fase de `tasks.md`, evaluar intra-fase:
|
|
|
112
112
|
"reasons": ["razón principal", "razón secundaria"],
|
|
113
113
|
"codegraphUsed": ["codegraph_codegraph_explore"],
|
|
114
114
|
"taskCount": <N>,
|
|
115
|
+
"expectedTaskIds": ["T1", "T2", "T3"],
|
|
115
116
|
"sharedFiles": { "src/archivo.ts": ["task1", "task2"] },
|
|
116
117
|
"fileClusters": [["task1", "task2"], ["task3"]],
|
|
117
118
|
"clusterCount": <N>,
|
|
@@ -124,6 +125,9 @@ Para cada fase de `tasks.md`, evaluar intra-fase:
|
|
|
124
125
|
}
|
|
125
126
|
```
|
|
126
127
|
|
|
128
|
+
> **Nota 6.1:** `expectedTaskIds` es **obligatorio** cuando `taskCount>0` — el controller lo exige y rechaza snapshot sin él (excepto `early-exit` con `taskCount<=2` y `codegraphUsed:[]` que es válido sin WARN).
|
|
129
|
+
> Ejemplo early-exit válido: `{"recommendation":"INLINE","reasons":["Cambio pequeño"],"codegraphUsed":[],"taskCount":2,"expectedTaskIds":["T1","T2"],"globalRuleTriggered":"early-exit"}`
|
|
130
|
+
|
|
127
131
|
**Output para el usuario (mostrar en lenguaje natural):**
|
|
128
132
|
|
|
129
133
|
```markdown
|
|
@@ -167,6 +171,8 @@ Para cada fase de `tasks.md`, evaluar intra-fase:
|
|
|
167
171
|
| `sequentialDeps` | Dependencias secuenciales entre tasks |
|
|
168
172
|
| `estLines` | Estimación conservadora |
|
|
169
173
|
| `hasExplicitContract` | `true` si design.md explicita contratos |
|
|
174
|
+
| `expectedTaskIds` | **Obligatorio** cuando `taskCount>0` — gate del controller |
|
|
175
|
+
| `taskCount` | Total tasks, debe coincidir con `expectedTaskIds.length` |
|
|
170
176
|
|
|
171
177
|
**⚠️ Este skill provee ANÁLISIS, no autorización.** El coordinador muestra el snapshot al usuario y pide confirmación en lenguaje natural, luego espera la respuesta.
|
|
172
178
|
|
|
@@ -184,6 +190,8 @@ Para cada fase de `tasks.md`, evaluar intra-fase:
|
|
|
184
190
|
- [ ] Verifiqué deps ENTRE clusters (no solo intra)?
|
|
185
191
|
- [ ] Apliqué reglas en orden (1→2a/2b→3a/3b/3c)?
|
|
186
192
|
- [ ] Anoté `globalRuleTriggered`?
|
|
193
|
+
- [ ] Incluí `expectedTaskIds` (obligatorio cuando `taskCount>0`) y verifiqué que `taskCount == expectedTaskIds.length`?
|
|
187
194
|
- [ ] Si global es inline, ejecuté Paso 3b por fase?
|
|
188
|
-
- [ ] Si global es subagent por clusters (Rule 2b), documenté dispatch?
|
|
195
|
+
- [ ] Si global es subagent por clusters (Rule 2b), documenté dispatch por clusters (máx 3 subagentes, advertir si `clusterCount>3` → oleadas)?
|
|
189
196
|
- [ ] Output es JSON válido con todos los campos del contrato?
|
|
197
|
+
- [ ] Early-exit con `codegraphUsed:[]` y `taskCount<=2` solo cuando realmente es cambio trivial (no genera WARN)?
|