Skip to content

Commit 033011c

Browse files
author
AI Agent
committed
docs(skills): condense skill docs for better agent context efficiency
Reduce redundancy across all four SKILL.md files while keeping all critical content inline (worked examples, anti-patterns, reference tables). Agents only read SKILL.md at runtime, so splitting content into companion files would make it invisible during execution. Changes: - Merge "Story Ordering" into "Dependencies" section (was redundant) - Condense verbose ralph-tui behavior lists to single sentences - Tighten acceptance criteria guidance (keep good/bad, drop repetition) - Trim checklists to essentials (remove items that repeat body content) - Keep all worked examples, anti-patterns, and br/bd comparison inline Inspired by PR #339 (popey) which identified the redundancy issues.
1 parent fcea670 commit 033011c

4 files changed

Lines changed: 43 additions & 201 deletions

File tree

skills/ralph-tui-create-beads-rust/SKILL.md

Lines changed: 16 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -76,44 +76,19 @@ EOF
7676

7777
## Story Size: The #1 Rule
7878

79-
**Each story must be completable in ONE ralph-tui iteration (~one agent context window).**
79+
Each story must be completable in ONE ralph-tui iteration (~one agent context window). ralph-tui spawns a fresh agent per iteration with no memory of previous work.
8080

81-
ralph-tui spawns a fresh agent instance per iteration with no memory of previous work. If a story is too big, the agent runs out of context before finishing.
81+
**Right-sized:** Add a database column + migration. Add a UI component. Update a server action. Add a filter dropdown.
8282

83-
### Right-sized stories:
84-
- Add a database column + migration
85-
- Add a UI component to an existing page
86-
- Update a server action with new logic
87-
- Add a filter dropdown to a list
88-
89-
### Too big (split these):
90-
- "Build the entire dashboard" → Split into: schema, queries, UI components, filters
91-
- "Add authentication" → Split into: schema, middleware, login UI, session handling
92-
- "Refactor the API" → Split into one story per endpoint or pattern
83+
**Too big (split these):** "Build the entire dashboard" → schema, queries, UI, filters. "Add authentication" → schema, middleware, login UI, sessions.
9384

9485
**Rule of thumb:** If you can't describe the change in 2-3 sentences, it's too big.
9586

9687
---
9788

98-
## Story Ordering: Dependencies First
99-
100-
Stories execute in dependency order. Earlier stories must not depend on later ones.
101-
102-
**Correct order:**
103-
1. Schema/database changes (migrations)
104-
2. Server actions / backend logic
105-
3. UI components that use the backend
106-
4. Dashboard/summary views that aggregate data
107-
108-
**Wrong order:**
109-
1. ❌ UI component (depends on schema that doesn't exist yet)
110-
2. ❌ Schema change
111-
112-
---
113-
11489
## Dependencies with `br dep add`
11590

116-
Use the `br dep add` command to specify which beads must complete first:
91+
Stories execute in dependency order (schema → backend → UI → integration). Use `br dep add` to specify which beads must complete first:
11792

11893
```bash
11994
# Create the beads first
@@ -128,48 +103,27 @@ br dep add ralph-tui-003 ralph-tui-002 # US-003 depends on US-002
128103

129104
**Syntax:** `br dep add <issue> <depends-on>` — the issue depends on (is blocked by) depends-on.
130105

131-
ralph-tui will:
132-
- Show blocked beads as "blocked" until dependencies complete
133-
- Never select a bead for execution while its dependencies are open
134-
- Include dependency context in the prompt when working on a bead
135-
136-
**Correct dependency order:**
137-
1. Schema/database changes (no dependencies)
138-
2. Backend logic (depends on schema)
139-
3. UI components (depends on backend)
140-
4. Integration/polish (depends on UI)
106+
ralph-tui will show blocked beads as "blocked" until dependencies complete, and include dependency context in the prompt when working on a bead.
141107

142108
---
143109

144110
## Acceptance Criteria: Quality Gates + Story-Specific
145111

146-
Each bead's description should include acceptance criteria with:
147-
1. **Story-specific criteria** from the PRD (what this story accomplishes)
148-
2. **Quality gates** from the PRD's Quality Gates section (appended at the end)
149-
150-
### Good criteria (verifiable):
151-
- "Add `investorType` column to investor table with default 'cold'"
152-
- "Filter dropdown has options: All, Cold, Friend"
153-
- "Clicking toggle shows confirmation dialog"
112+
Each bead's description should include story-specific acceptance criteria from the PRD, plus quality gates appended from the Quality Gates section.
154113

155-
### Bad criteria (vague):
156-
- ❌ "Works correctly"
157-
- ❌ "User can do X easily"
158-
- ❌ "Good UX"
159-
- ❌ "Handles edge cases"
114+
Criteria must be verifiable: "Add `investorType` column with default 'cold'" is good. "Works correctly" or "Good UX" is bad.
160115

161116
---
162117

163118
## Conversion Rules
164119

165120
1. **Extract Quality Gates** from PRD first
166121
2. **Each user story → one bead**
167-
3. **First story**: No dependencies (creates foundation)
168-
4. **Subsequent stories**: Depend on their predecessors (UI depends on backend, etc.)
169-
5. **Priority**: Based on dependency order, then document order (0=critical, 2=medium, 4=backlog)
170-
6. **All stories**: `status: "open"`
171-
7. **Acceptance criteria**: Story criteria + quality gates appended
172-
8. **UI stories**: Also append UI-specific gates (browser verification)
122+
3. **Dependencies**: Schema/database → backend → UI → integration (use `br dep add` after creating beads)
123+
4. **Priority**: Based on dependency order, then document order (0=critical, 2=medium, 4=backlog)
124+
5. **All stories**: `status: "open"`
125+
6. **Acceptance criteria**: Story criteria + quality gates appended
126+
7. **UI stories**: Also append UI-specific gates (browser verification)
173127

174128
---
175129

@@ -329,23 +283,16 @@ ralph-tui run --tracker beads-rust --epic ralph-tui-abc
329283
ralph-tui run --tracker beads-rust
330284
```
331285

332-
ralph-tui will:
333-
1. Work on beads within the specified epic (or select the best available task)
334-
2. Close each bead when complete
335-
3. Close the epic when all children are done
336-
4. Output `<promise>COMPLETE</promise>` when epic is done
286+
ralph-tui will work on beads, close each when complete, and output `<promise>COMPLETE</promise>` when the epic is done.
337287

338288
---
339289

340290
## Checklist Before Creating Beads
341291

342-
- [ ] Extracted Quality Gates from PRD (or asked user if missing)
343-
- [ ] Each story is completable in one iteration (small enough)
344-
- [ ] Stories are ordered by dependency (schema → backend → UI)
292+
- [ ] Extracted Quality Gates from PRD
293+
- [ ] Each story is completable in one iteration
294+
- [ ] Stories ordered by dependency (schema → backend → UI)
345295
- [ ] Quality gates appended to every bead's acceptance criteria
346-
- [ ] UI stories have browser verification (if specified in Quality Gates)
347-
- [ ] Acceptance criteria are verifiable (not vague)
348-
- [ ] No story depends on a later story (only earlier stories)
349296
- [ ] Dependencies added with `br dep add` after creating beads
350297
- [ ] Ran `br sync --flush-only` to export for git tracking
351298

skills/ralph-tui-create-beads/SKILL.md

Lines changed: 16 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -76,44 +76,19 @@ EOF
7676

7777
## Story Size: The #1 Rule
7878

79-
**Each story must be completable in ONE ralph-tui iteration (~one agent context window).**
79+
Each story must be completable in ONE ralph-tui iteration (~one agent context window). ralph-tui spawns a fresh agent per iteration with no memory of previous work.
8080

81-
ralph-tui spawns a fresh agent instance per iteration with no memory of previous work. If a story is too big, the agent runs out of context before finishing.
81+
**Right-sized:** Add a database column + migration. Add a UI component. Update a server action. Add a filter dropdown.
8282

83-
### Right-sized stories:
84-
- Add a database column + migration
85-
- Add a UI component to an existing page
86-
- Update a server action with new logic
87-
- Add a filter dropdown to a list
88-
89-
### Too big (split these):
90-
- "Build the entire dashboard" → Split into: schema, queries, UI components, filters
91-
- "Add authentication" → Split into: schema, middleware, login UI, session handling
92-
- "Refactor the API" → Split into one story per endpoint or pattern
83+
**Too big (split these):** "Build the entire dashboard" → schema, queries, UI, filters. "Add authentication" → schema, middleware, login UI, sessions.
9384

9485
**Rule of thumb:** If you can't describe the change in 2-3 sentences, it's too big.
9586

9687
---
9788

98-
## Story Ordering: Dependencies First
99-
100-
Stories execute in dependency order. Earlier stories must not depend on later ones.
101-
102-
**Correct order:**
103-
1. Schema/database changes (migrations)
104-
2. Server actions / backend logic
105-
3. UI components that use the backend
106-
4. Dashboard/summary views that aggregate data
107-
108-
**Wrong order:**
109-
1. ❌ UI component (depends on schema that doesn't exist yet)
110-
2. ❌ Schema change
111-
112-
---
113-
11489
## Dependencies with `bd dep add`
11590

116-
Use the `bd dep add` command to specify which beads must complete first:
91+
Stories execute in dependency order (schema → backend → UI → integration). Use `bd dep add` to specify which beads must complete first:
11792

11893
```bash
11994
# Create the beads first
@@ -128,48 +103,27 @@ bd dep add ralph-tui-003 ralph-tui-002 # US-003 depends on US-002
128103

129104
**Syntax:** `bd dep add <issue> <depends-on>` — the issue depends on (is blocked by) depends-on.
130105

131-
ralph-tui will:
132-
- Show blocked beads as "blocked" until dependencies complete
133-
- Never select a bead for execution while its dependencies are open
134-
- Include dependency context in the prompt when working on a bead
135-
136-
**Correct dependency order:**
137-
1. Schema/database changes (no dependencies)
138-
2. Backend logic (depends on schema)
139-
3. UI components (depends on backend)
140-
4. Integration/polish (depends on UI)
106+
ralph-tui will show blocked beads as "blocked" until dependencies complete, and include dependency context in the prompt when working on a bead.
141107

142108
---
143109

144110
## Acceptance Criteria: Quality Gates + Story-Specific
145111

146-
Each bead's description should include acceptance criteria with:
147-
1. **Story-specific criteria** from the PRD (what this story accomplishes)
148-
2. **Quality gates** from the PRD's Quality Gates section (appended at the end)
149-
150-
### Good criteria (verifiable):
151-
- "Add `investorType` column to investor table with default 'cold'"
152-
- "Filter dropdown has options: All, Cold, Friend"
153-
- "Clicking toggle shows confirmation dialog"
112+
Each bead's description should include story-specific acceptance criteria from the PRD, plus quality gates appended from the Quality Gates section.
154113

155-
### Bad criteria (vague):
156-
- ❌ "Works correctly"
157-
- ❌ "User can do X easily"
158-
- ❌ "Good UX"
159-
- ❌ "Handles edge cases"
114+
Criteria must be verifiable: "Add `investorType` column with default 'cold'" is good. "Works correctly" or "Good UX" is bad.
160115

161116
---
162117

163118
## Conversion Rules
164119

165120
1. **Extract Quality Gates** from PRD first
166121
2. **Each user story → one bead**
167-
3. **First story**: No dependencies (creates foundation)
168-
4. **Subsequent stories**: Depend on their predecessors (UI depends on backend, etc.)
169-
5. **Priority**: Based on dependency order, then document order (0=critical, 2=medium, 4=backlog)
170-
6. **All stories**: `status: "open"`
171-
7. **Acceptance criteria**: Story criteria + quality gates appended
172-
8. **UI stories**: Also append UI-specific gates (browser verification)
122+
3. **Dependencies**: Schema/database → backend → UI → integration (use `bd dep add` after creating beads)
123+
4. **Priority**: Based on dependency order, then document order (0=critical, 2=medium, 4=backlog)
124+
5. **All stories**: `status: "open"`
125+
6. **Acceptance criteria**: Story criteria + quality gates appended
126+
7. **UI stories**: Also append UI-specific gates (browser verification)
173127

174128
---
175129

@@ -317,21 +271,14 @@ ralph-tui run --tracker beads --epic ralph-tui-abc
317271
ralph-tui run --tracker beads
318272
```
319273

320-
ralph-tui will:
321-
1. Work on beads within the specified epic (or select the best available task)
322-
2. Close each bead when complete
323-
3. Close the epic when all children are done
324-
4. Output `<promise>COMPLETE</promise>` when epic is done
274+
ralph-tui will work on beads, close each when complete, and output `<promise>COMPLETE</promise>` when the epic is done.
325275

326276
---
327277

328278
## Checklist Before Creating Beads
329279

330-
- [ ] Extracted Quality Gates from PRD (or asked user if missing)
331-
- [ ] Each story is completable in one iteration (small enough)
332-
- [ ] Stories are ordered by dependency (schema → backend → UI)
280+
- [ ] Extracted Quality Gates from PRD
281+
- [ ] Each story is completable in one iteration
282+
- [ ] Stories ordered by dependency (schema → backend → UI)
333283
- [ ] Quality gates appended to every bead's acceptance criteria
334-
- [ ] UI stories have browser verification (if specified in Quality Gates)
335-
- [ ] Acceptance criteria are verifiable (not vague)
336-
- [ ] No story depends on a later story (only earlier stories)
337284
- [ ] Dependencies added with `bd dep add` after creating beads

skills/ralph-tui-create-json/SKILL.md

Lines changed: 9 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -165,67 +165,38 @@ Use `"passes": false` for incomplete stories, `"passes": true` for completed.
165165

166166
## Story Size: The #1 Rule
167167

168-
**Each story must be completable in ONE ralph-tui iteration (~one agent context window).**
168+
Each story must be completable in ONE ralph-tui iteration (~one agent context window). Ralph-tui spawns a fresh agent per iteration with no memory of previous work.
169169

170-
Ralph-tui spawns a fresh agent instance per iteration with no memory of previous work. If a story is too big, the agent runs out of context before finishing.
170+
**Right-sized:** Add a database column + migration. Add a UI component. Update a server action. Add a filter dropdown.
171171

172-
### Right-sized stories:
173-
- Add a database column + migration
174-
- Add a UI component to an existing page
175-
- Update a server action with new logic
176-
- Add a filter dropdown to a list
177-
178-
### Too big (split these):
179-
- "Build the entire dashboard" → Split into: schema, queries, UI components, filters
180-
- "Add authentication" → Split into: schema, middleware, login UI, session handling
181-
- "Refactor the API" → Split into one story per endpoint or pattern
172+
**Too big (split these):** "Build the entire dashboard" → schema, queries, UI, filters. "Add authentication" → schema, middleware, login UI, sessions.
182173

183174
**Rule of thumb:** If you can't describe the change in 2-3 sentences, it's too big.
184175

185176
---
186177

187178
## Dependencies with `dependsOn`
188179

189-
Use the `dependsOn` array to specify which stories must complete first:
180+
Use the `dependsOn` array to specify which stories must complete first. Ralph-tui will show stories as "blocked" until dependencies complete.
190181

191182
```json
192183
{
193184
"id": "US-002",
194185
"title": "Create API endpoints",
195-
"dependsOn": ["US-001"], // Won't be selected until US-001 passes
186+
"dependsOn": ["US-001"],
196187
...
197188
}
198189
```
199190

200-
Ralph-tui will:
201-
- Show US-002 as "blocked" until US-001 completes
202-
- Never select US-002 for execution while US-001 is open
203-
- Include "Prerequisites: US-001" in the prompt when working on US-002
204-
205-
**Correct dependency order:**
206-
1. Schema/database changes (no dependencies)
207-
2. Backend logic (depends on schema)
208-
3. UI components (depends on backend)
209-
4. Integration/polish (depends on UI)
191+
**Correct dependency order:** Schema/database → backend → UI → integration.
210192

211193
---
212194

213195
## Acceptance Criteria: Quality Gates + Story-Specific
214196

215-
Each story's acceptance criteria should include:
216-
1. **Story-specific criteria** from the PRD (what this story accomplishes)
217-
2. **Quality gates** from the PRD's Quality Gates section (appended at the end)
197+
Each story's acceptance criteria should include story-specific criteria from the PRD, plus quality gates appended from the Quality Gates section.
218198

219-
### Good criteria (verifiable):
220-
- "Add `status` column to tasks table with default 'open'"
221-
- "Filter dropdown has options: All, Open, Closed"
222-
- "Clicking delete shows confirmation dialog"
223-
224-
### Bad criteria (vague):
225-
- ❌ "Works correctly"
226-
- ❌ "User can do X easily"
227-
- ❌ "Good UX"
228-
- ❌ "Handles edge cases"
199+
Criteria must be verifiable: "Add `status` column with default 'open'" is good. "Works correctly" or "Good UX" is bad.
229200

230201
---
231202

@@ -364,23 +335,13 @@ After creating prd.json:
364335
ralph-tui run --prd ./tasks/prd.json
365336
```
366337

367-
Ralph-tui will:
368-
1. Load stories from prd.json
369-
2. Select the highest-priority story with `passes: false` and no blocking dependencies
370-
3. Generate a prompt with story details + acceptance criteria
371-
4. Run the agent to implement the story
372-
5. Mark `passes: true` on completion
373-
6. Repeat until all stories pass
374-
375338
---
376339

377340
## Checklist Before Saving
378341

379-
- [ ] Extracted Quality Gates from PRD (or asked user if missing)
342+
- [ ] Extracted Quality Gates from PRD
380343
- [ ] Each story completable in one iteration
381344
- [ ] Stories ordered by dependency (schema → backend → UI)
382345
- [ ] `dependsOn` correctly set for each story
383346
- [ ] Quality gates appended to every story's acceptance criteria
384-
- [ ] UI stories have browser verification (if specified in Quality Gates)
385-
- [ ] Acceptance criteria are verifiable (not vague)
386347
- [ ] No circular dependencies

0 commit comments

Comments
 (0)