learnship 2.3.2 → 2.3.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 (35) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/.cursor-plugin/plugin.json +1 -1
  3. package/README.md +17 -6
  4. package/agents/learnship-plan-checker.md +6 -1
  5. package/agents/learnship-planner.md +21 -11
  6. package/bin/install.js +1 -1
  7. package/cursor-rules/learnship.mdc +3 -1
  8. package/gemini-extension.json +1 -1
  9. package/learnship/agents/plan-checker.md +5 -0
  10. package/learnship/agents/planner.md +14 -1
  11. package/learnship/references/planning-config.md +1 -1
  12. package/learnship/templates/plan.md +8 -0
  13. package/learnship/workflows/audit-milestone.md +5 -0
  14. package/learnship/workflows/challenge.md +10 -0
  15. package/learnship/workflows/compound.md +5 -0
  16. package/learnship/workflows/debug.md +10 -0
  17. package/learnship/workflows/diagnose-issues.md +5 -0
  18. package/learnship/workflows/discuss-phase.md +38 -3
  19. package/learnship/workflows/docs-update.md +92 -0
  20. package/learnship/workflows/execute-phase.md +10 -0
  21. package/learnship/workflows/execute-plan.md +5 -0
  22. package/learnship/workflows/ideate.md +10 -0
  23. package/learnship/workflows/map-codebase.md +5 -0
  24. package/learnship/workflows/new-milestone.md +10 -0
  25. package/learnship/workflows/new-project.md +127 -20
  26. package/learnship/workflows/plan-phase.md +44 -16
  27. package/learnship/workflows/quick.md +25 -0
  28. package/learnship/workflows/research-phase.md +11 -4
  29. package/learnship/workflows/review.md +5 -0
  30. package/learnship/workflows/secure-phase.md +5 -0
  31. package/learnship/workflows/settings.md +1 -1
  32. package/learnship/workflows/validate-phase.md +5 -0
  33. package/learnship/workflows/verify-work.md +15 -0
  34. package/package.json +1 -1
  35. package/templates/plan.md +8 -0
@@ -52,6 +52,11 @@ You are now the **learnship researcher** in codebase mapping mode. Explore the c
52
52
  Document what exists: architecture, dependencies, patterns, and concerns. Be specific — cite file paths.
53
53
  </persona_context>
54
54
 
55
+ > **Announce persona** — print this before proceeding:
56
+ > ```bash
57
+ > printf "\n \033[36m learnship-researcher(In codebase mapping mode)\033[0m\n\n"
58
+ > ```
59
+
55
60
  Read `@./agents/researcher.md` for the full persona definition. For each dimension below, explore the codebase thoroughly and write the document directly.
56
61
 
57
62
  ```
@@ -226,6 +226,11 @@ Use WebSearch for ecosystem discovery (always include current year), WebFetch fo
226
226
  Tag confidence: HIGH/MEDIUM/LOW. Be comprehensive but opinionated.
227
227
  </persona_context>
228
228
 
229
+ > **Announce persona** — print this before proceeding:
230
+ > ```bash
231
+ > printf "\n \033[36m learnship-project-researcher(Your training data is stale — verify before asserting)\033[0m\n\n"
232
+ > ```
233
+
229
234
  Read `@./agents/project-researcher.md` for the full persona definition. In project research mode, investigate the new feature domain:
230
235
  - Focus ONLY on the new capabilities — not the existing codebase
231
236
  - Write STACK.md, FEATURES.md, ARCHITECTURE.md, PITFALLS.md to `.planning/research/`
@@ -257,6 +262,11 @@ Every v1 requirement maps to exactly one phase. Every phase has observable succe
257
262
  Dependencies drive order. Phases should be deliverable.
258
263
  </persona_context>
259
264
 
265
+ > **Announce persona** — print this before proceeding:
266
+ > ```bash
267
+ > printf "\n \033[35m learnship-roadmapper(Transform requirements into a phased roadmap)\033[0m\n\n"
268
+ > ```
269
+
260
270
  Read `@./agents/roadmapper.md` for the full persona definition. Read PROJECT.md, REQUIREMENTS.md, research (if exists).
261
271
 
262
272
  Create a new `.planning/ROADMAP.md` with phases for this milestone only. Map every v1 requirement to exactly one phase.
@@ -125,9 +125,9 @@ Note the tech stack, key directories, and any README content internally. Use thi
125
125
  >
126
126
  > **🛑 FORBIDDEN:** Do NOT present all questions at once as a text wall. Do NOT skip any question. Do NOT invent answers. Do NOT proceed to the config.json write step until ALL 4 rounds have been answered by the user.
127
127
 
128
- **Round 1 — Core settings (4 questions):**
128
+ **Round 1 — Core settings (6 questions):**
129
129
 
130
- > Present these 4 questions as a SINGLE blocking `AskUserQuestion` call. STOP and wait for the user's reply before proceeding to Round 2.
130
+ > Present these 6 questions as a SINGLE blocking `AskUserQuestion` call. STOP and wait for the user's reply before proceeding to Round 2.
131
131
 
132
132
  ```
133
133
  AskUserQuestion([
@@ -168,6 +168,25 @@ AskUserQuestion([
168
168
  { label: "Quality", description: "Large-tier models for all agents (highest cost, best results)" },
169
169
  { label: "Budget", description: "Medium for code, small for research/verification (lowest cost)" }
170
170
  ]
171
+ },
172
+ {
173
+ header: "Questioning Depth",
174
+ question: "How deep should discuss-phase and new-project question you?",
175
+ multiSelect: false,
176
+ options: [
177
+ { label: "Standard (Recommended)", description: "4 focused exchanges per area — fast and sufficient for most projects" },
178
+ { label: "Deep", description: "Extended questioning: walks every decision branch until shared understanding is reached. Produces richer CONTEXT.md and PROJECT.md. Good for complex or unfamiliar domains." }
179
+ ]
180
+ },
181
+ {
182
+ header: "Output Profile",
183
+ question: "How verbose should agent responses be?",
184
+ multiSelect: false,
185
+ options: [
186
+ { label: "Dev (Recommended)", description: "Concise, action-oriented — code first, brief rationale. Low verbosity." },
187
+ { label: "Research", description: "Detailed explanations, alternatives, and context. High verbosity." },
188
+ { label: "Review", description: "Audit-focused — findings, severity, recommendations. Medium verbosity." }
189
+ ]
171
190
  }
172
191
  ])
173
192
  ```
@@ -289,6 +308,8 @@ AskUserQuestion([
289
308
  - Granularity → `"granularity"`: `"coarse"`, `"standard"`, or `"fine"`
290
309
  - Learning Partner → `"learning_mode"`: `"auto"` or `"manual"`
291
310
  - AI Models → `"model_profile"`: `"balanced"`, `"quality"`, or `"budget"`
311
+ - Questioning Depth → `"workflow.discuss_mode"`: `"discuss"` (Standard) or `"deep"` (Deep)
312
+ - Output Profile → `"context"`: `"dev"` (Dev), `"research"` (Research), or `"review"` (Review)
292
313
  - Research → `"workflow.research"`: `true` or `false`
293
314
  - Plan Check → `"workflow.plan_check"`: `true` or `false`
294
315
  - Verifier → `"workflow.verifier"`: `true` or `false`
@@ -308,6 +329,7 @@ Create `.planning/config.json` with all settings:
308
329
  "granularity": "coarse|standard|fine",
309
330
  "model_profile": "quality|balanced|budget",
310
331
  "learning_mode": "auto|manual",
332
+ "context": "dev|research|review",
311
333
  "test_first": false|true,
312
334
  "planning": {
313
335
  "commit_docs": true|false,
@@ -322,7 +344,7 @@ Create `.planning/config.json` with all settings:
322
344
  "review": true|false,
323
345
  "solutions_search": true|false,
324
346
  "security_enforcement": true|false,
325
- "discuss_mode": "discuss",
347
+ "discuss_mode": "discuss|deep",
326
348
  "tdd_mode": false|true
327
349
  },
328
350
  "parallelization": {
@@ -380,6 +402,8 @@ try{
380
402
  if(!['auto','manual'].includes(c.learning_mode)) errs.push('learning_mode must be auto|manual');
381
403
  if(typeof c.test_first!=='boolean') errs.push('test_first must be boolean');
382
404
  if(!c.planning||!['auto','manual'].includes(c.planning.commit_mode)) errs.push('planning.commit_mode must be auto|manual');
405
+ if(c.context&&!['dev','research','review'].includes(c.context)) errs.push('context must be dev|research|review');
406
+ if(c.workflow&&c.workflow.discuss_mode&&!['discuss','deep'].includes(c.workflow.discuss_mode)) errs.push('workflow.discuss_mode must be discuss|deep');
383
407
  if(!c.workflow||typeof c.workflow.research!=='boolean') errs.push('workflow.research must be boolean');
384
408
  if(!c.workflow||typeof c.workflow.plan_check!=='boolean') errs.push('workflow.plan_check must be boolean');
385
409
  if(!c.workflow||typeof c.workflow.verifier!=='boolean') errs.push('workflow.verifier must be boolean');
@@ -424,7 +448,25 @@ Display:
424
448
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
425
449
  ```
426
450
 
427
- This step is **strictly sequential**. You must complete each numbered exchange fully before moving to the next. Do not batch questions. Do not skip exchanges. Do not proceed to Step 4 until Exchange 4 is complete.
451
+ **Detect questioning mode:** Check for `--deep` flag in the `/new-project` command. If not present, ask the user:
452
+
453
+ ```
454
+ AskUserQuestion([
455
+ {
456
+ header: "Questioning Depth",
457
+ question: "How deep do you want me to go with questions before writing PROJECT.md?",
458
+ multiSelect: false,
459
+ options: [
460
+ { label: "Standard (Recommended)", description: "4 focused exchanges — enough for a sharp PROJECT.md" },
461
+ { label: "Deep", description: "Grill-me style — I walk every open branch until we reach shared understanding. Takes longer, produces a richer PROJECT.md" }
462
+ ]
463
+ }
464
+ ])
465
+ ```
466
+
467
+ > 🛑 STOP. Wait for the user's reply. Record mode as `QUESTIONING_MODE = standard | deep`.
468
+
469
+ This step is **strictly sequential**. You must complete each numbered exchange fully before moving to the next. Do not batch questions. Do not skip exchanges. Do not proceed to Step 4 until the gate check passes.
428
470
 
429
471
  **Exchange 1 — Opening question:**
430
472
 
@@ -465,6 +507,8 @@ Based on all previous answers, ask a third follow-up that clarifies scope, edge
465
507
  >
466
508
  > If any count is wrong, go back and complete the missing exchanges. Do NOT proceed with fewer than 4 exchanges under any circumstances — even if the user's first answer was extremely detailed.
467
509
 
510
+ **If `QUESTIONING_MODE = standard`:**
511
+
468
512
  Verify internally: do you have `ANSWER_1`, `ANSWER_2`, `ANSWER_3`, and `ANSWER_4` recorded? If any is missing, go back and ask it. Only after all four answers are in hand may you ask:
469
513
 
470
514
  "I think I have a solid picture of what you're building. Ready for me to write PROJECT.md, or is there more you want to cover first?"
@@ -472,6 +516,31 @@ Verify internally: do you have `ANSWER_1`, `ANSWER_2`, `ANSWER_3`, and `ANSWER_4
472
516
  - **Write PROJECT.md** → proceed to Step 4
473
517
  - **More to cover** → continue asking follow-ups, then re-ask this gate question
474
518
 
519
+ **If `QUESTIONING_MODE = deep`:**
520
+
521
+ After Exchange 4, continue with the extended deep questioning loop:
522
+ - Identify the single biggest remaining unknown that would change the direction, scope, or architecture of PROJECT.md. Ask it. Provide your recommended answer with each question.
523
+ - If an answer opens a new branch (a sub-decision), follow that branch before moving on.
524
+ - If you can explore the codebase to resolve a question yourself, do so instead of asking.
525
+ - Continue until you judge that all major branches are resolved. Then ask:
526
+
527
+ ```
528
+ AskUserQuestion([
529
+ {
530
+ header: "Shared Understanding Check",
531
+ question: "I've walked through every major open question I can identify. Do you feel we have a complete shared picture of what you want to build?",
532
+ multiSelect: false,
533
+ options: [
534
+ { label: "Yes — write PROJECT.md", description: "All key decisions and scope are clear" },
535
+ { label: "There's still something open", description: "Keep going on a specific area" },
536
+ { label: "Let me add context", description: "I have something to add before you write" }
537
+ ]
538
+ }
539
+ ])
540
+ ```
541
+
542
+ > 🛑 STOP. Wait for user reply. If "Yes" → proceed to Step 4. Otherwise continue drilling.
543
+
475
544
  Use the questioning techniques from `@./references/questioning.md` and domain-aware probes from `@./references/domain-probes.md` to shape the follow-up questions. When the user mentions a known domain (auth, real-time, dashboard, API, database, search, file uploads, caching, testing, deployment, AI/ML), use the relevant probes to ask sharper questions.
476
545
 
477
546
  ## Step 4: Write PROJECT.md
@@ -586,13 +655,15 @@ Spawn 4 parallel researcher agents — one per research dimension. Each agent wr
586
655
 
587
656
  ```
588
657
  Task(
589
- subagent_type="learnship-researcher",
658
+ subagent_type="learnship-project-researcher",
590
659
  description="Stack research",
591
660
  prompt="
592
661
  <agent_definition>
593
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
594
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
662
+ You are a learnship project researcher. You answer 'What does this domain ecosystem look like?' and produce research files that inform roadmap creation.
663
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
664
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
595
665
  Tool priority: 1. WebSearch (ecosystem discovery — always include current year), 2. WebFetch (official docs), 3. Codebase scan.
666
+ Investigation, not confirmation — gather evidence first, recommend second.
596
667
  </agent_definition>
597
668
 
598
669
  <objective>
@@ -632,13 +703,15 @@ Task(
632
703
  )
633
704
 
634
705
  Task(
635
- subagent_type="learnship-researcher",
706
+ subagent_type="learnship-project-researcher",
636
707
  description="Features research",
637
708
  prompt="
638
709
  <agent_definition>
639
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
640
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
710
+ You are a learnship project researcher. You answer 'What does this domain ecosystem look like?' and produce research files that inform roadmap creation.
711
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
712
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
641
713
  Tool priority: 1. WebSearch (ecosystem discovery — always include current year), 2. WebFetch (official docs), 3. Codebase scan.
714
+ Investigation, not confirmation — gather evidence first, recommend second.
642
715
  </agent_definition>
643
716
 
644
717
  <objective>
@@ -678,13 +751,15 @@ Task(
678
751
  )
679
752
 
680
753
  Task(
681
- subagent_type="learnship-researcher",
754
+ subagent_type="learnship-project-researcher",
682
755
  description="Architecture research",
683
756
  prompt="
684
757
  <agent_definition>
685
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
686
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
758
+ You are a learnship project researcher. You answer 'What does this domain ecosystem look like?' and produce research files that inform roadmap creation.
759
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
760
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
687
761
  Tool priority: 1. WebSearch (ecosystem discovery — always include current year), 2. WebFetch (official docs), 3. Codebase scan.
762
+ Investigation, not confirmation — gather evidence first, recommend second.
688
763
  </agent_definition>
689
764
 
690
765
  <objective>
@@ -724,13 +799,15 @@ Task(
724
799
  )
725
800
 
726
801
  Task(
727
- subagent_type="learnship-researcher",
802
+ subagent_type="learnship-project-researcher",
728
803
  description="Pitfalls research",
729
804
  prompt="
730
805
  <agent_definition>
731
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
732
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
806
+ You are a learnship project researcher. You answer 'What does this domain ecosystem look like?' and produce research files that inform roadmap creation.
807
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
808
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
733
809
  Tool priority: 1. WebSearch (ecosystem discovery — always include current year), 2. WebFetch (official docs), 3. Codebase scan.
810
+ Investigation, not confirmation — gather evidence first, recommend second.
734
811
  </agent_definition>
735
812
 
736
813
  <objective>
@@ -774,12 +851,19 @@ After all 4 agents complete, spawn a synthesizer to create SUMMARY.md from the o
774
851
 
775
852
  ```
776
853
  Task(
777
- subagent_type="learnship-researcher",
778
- description="Synthesize research",
854
+ subagent_type="learnship-research-synthesizer",
855
+ description="Synthesize research into SUMMARY.md",
779
856
  prompt="
857
+ <agent_definition>
858
+ You are a learnship research synthesizer. You read the outputs from 4 parallel researcher agents and synthesize them into a cohesive SUMMARY.md.
859
+ Synthesize, don't concatenate — integrate findings across all 4 files into a unified narrative.
860
+ Be opinionated: the roadmapper needs clear recommendations, not wishy-washy summaries.
861
+ Derive roadmap implications from combined research. Identify confidence levels and gaps.
862
+ </agent_definition>
863
+
780
864
  <objective>
781
865
  Synthesize the 4 research files into a single SUMMARY.md.
782
- Read all 4 files, extract the key findings, and write a cohesive summary.
866
+ Read all 4 files, extract the key findings, and write a cohesive summary that informs roadmap creation.
783
867
  </objective>
784
868
 
785
869
  <files_to_read>
@@ -789,10 +873,23 @@ Task(
789
873
  - .planning/research/PITFALLS.md
790
874
  </files_to_read>
791
875
 
876
+ <downstream_consumer>
877
+ Your SUMMARY.md is consumed by the roadmapper which uses it to structure phases.
878
+ Executive Summary → quick understanding. Key Findings → tech decisions. Implications → phase structure.
879
+ Research Flags → which phases need deeper research. Gaps → what to flag for validation.
880
+ </downstream_consumer>
881
+
792
882
  <output>
793
883
  Write to: .planning/research/SUMMARY.md
794
- Required sections: ## Recommended Stack, ## Table Stakes Features, ## Key Architecture Decisions, ## Top Pitfalls
884
+ Required sections: ## Executive Summary, ## Recommended Stack, ## Table Stakes Features, ## Key Architecture Decisions, ## Top Pitfalls, ## Implications for Roadmap, ## Confidence Assessment, ## Gaps
795
885
  </output>
886
+
887
+ <quality_gate>
888
+ - [ ] Synthesized, not concatenated — findings are integrated
889
+ - [ ] Opinionated — clear recommendations emerge
890
+ - [ ] Actionable — roadmapper can structure phases from implications
891
+ - [ ] Honest — confidence levels reflect actual source quality
892
+ </quality_gate>
796
893
  "
797
894
  )
798
895
  ```
@@ -810,6 +907,11 @@ Investigation, not confirmation — gather evidence first, recommend second.
810
907
  Your research feeds the roadmapper: STACK.md → tech decisions, FEATURES.md → what to build, ARCHITECTURE.md → system structure, PITFALLS.md → risk flags.
811
908
  </persona_context>
812
909
 
910
+ > **Announce persona** — print this before proceeding:
911
+ > ```bash
912
+ > printf "\n \033[36m learnship-project-researcher(Your training data is 6–18 months stale — verify before asserting)\033[0m\n\n"
913
+ > ```
914
+
813
915
  Read `@./agents/project-researcher.md` for the full persona definition.
814
916
 
815
917
  **Step 5b-pre — Online research (BEFORE writing any files).**
@@ -985,6 +1087,11 @@ Goal-backward: start from what the user needs, work backward to what must be bui
985
1087
  Dependencies drive order. Phases should be deliverable — each produces something testable.
986
1088
  </persona_context>
987
1089
 
1090
+ > **Announce persona** — print this before proceeding:
1091
+ > ```bash
1092
+ > printf "\n \033[35m learnship-roadmapper(Transform requirements into a phased roadmap)\033[0m\n\n"
1093
+ > ```
1094
+
988
1095
  Read `@./agents/roadmapper.md` for the full persona definition.
989
1096
 
990
1097
  1. Derive phases from requirements (don't impose structure — let requirements drive phases)
@@ -107,13 +107,15 @@ Display:
107
107
  Spawn a dedicated researcher agent:
108
108
  ```
109
109
  Task(
110
- subagent_type="learnship-researcher",
110
+ subagent_type="learnship-phase-researcher",
111
111
  description="Phase [phase_number] research",
112
112
  prompt="
113
113
  <agent_definition>
114
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
115
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
116
- Tool priority: 1. WebSearch (ecosystem discovery always include current year), 2. WebFetch (official docs), 3. Codebase scan.
114
+ You are a learnship phase researcher. You answer 'What do I need to know to PLAN this phase well?' and produce a single RESEARCH.md that the planner consumes.
115
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
116
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
117
+ Tool priority: 1. WebSearch (implementation patterns — always include current year), 2. WebFetch (official docs), 3. Codebase scan (existing patterns to reuse).
118
+ Investigation, not confirmation — gather evidence first, recommend second.
117
119
  </agent_definition>
118
120
 
119
121
  <objective>
@@ -154,6 +156,11 @@ Tag every claim: [VERIFIED: source], [CITED: url], or [ASSUMED]. Never present a
154
156
  Use WebSearch for implementation patterns, WebFetch for official docs, codebase scan for existing patterns to reuse.
155
157
  </persona_context>
156
158
 
159
+ > **Announce persona** — print this before proceeding:
160
+ > ```bash
161
+ > printf "\n \033[34m learnship-phase-researcher(Your training data is stale — verify before asserting)\033[0m\n\n"
162
+ > ```
163
+
157
164
  Read `@./agents/phase-researcher.md` for the full persona definition. Investigate how to implement this phase.
158
165
 
159
166
  **Online research first.** Before writing anything, run at least 3 WebSearch queries relevant to this phase's domain. Use WebFetch to read official docs for any libraries discovered. Then read:
@@ -196,14 +203,16 @@ Task(
196
203
  prompt="
197
204
  <agent_definition>
198
205
  You are a learnship planner. Create executable PLAN.md files that an AI agent can follow step-by-step.
199
- Each plan covers a single logical unit of work. Tasks use XML format with file, action, verify, done fields.
200
- Plans have YAML frontmatter: wave, depends_on, files_modified, autonomous.
206
+ Each plan is a VERTICAL SLICE (tracer bullet) — a thin end-to-end path through all layers for one user-facing behavior. A completed plan must be demoable or verifiable on its own.
207
+ DO NOT create plans that cover a single layer across the whole feature (all-schema plan, all-API plan, all-UI plan). Each plan delivers one complete behavior: data + logic + API + UI + test.
208
+ Exception: add `single_layer_justified: true` to frontmatter only if the phase is legitimately single-layer (e.g., DB migration, style pass).
209
+ Tasks use XML format with file, action, verify, done fields. Plans have YAML frontmatter: wave, depends_on, files_modified, autonomous, single_layer_justified, objective.
201
210
  Be specific — task actions should be concrete instructions, not vague guidance.
202
211
  </agent_definition>
203
212
 
204
213
  <objective>
205
214
  Create 2-4 executable PLAN.md files for Phase [phase_number]: [phase_name].
206
- Write plans to [phase_dir]/[padded_phase]-NN-PLAN.md.
215
+ Each plan = one tracer bullet (demoable end-to-end slice). Write plans to [phase_dir]/[padded_phase]-NN-PLAN.md.
207
216
  </objective>
208
217
 
209
218
  <files_to_read>
@@ -229,10 +238,18 @@ Wait for agent to complete, then verify PLAN.md files were written.
229
238
 
230
239
  <persona_context>
231
240
  You are now the **learnship planner**. Create implementation plans that are executable in a single context window.
232
- Each plan covers one logical unit of work. Tasks use XML format. Include YAML frontmatter with wave, depends_on, files_modified.
241
+ Each plan is a VERTICAL SLICE (tracer bullet) a thin end-to-end path through all layers for one user-facing behavior. A completed plan must be demoable or verifiable on its own.
242
+ DO NOT create plans that cover a single layer across the whole feature (all-schema plan, all-API plan, all-UI plan). Each plan delivers one complete behavior: data + logic + API + UI + test.
243
+ Exception: add `single_layer_justified: true` to frontmatter only if the phase is legitimately single-layer (e.g., DB migration, style pass).
244
+ Tasks use XML format. Include YAML frontmatter with wave, depends_on, files_modified, autonomous, single_layer_justified, objective.
233
245
  Right-size plans: too small = overhead, too large = risk. Aim for plans completable in one focused session.
234
246
  </persona_context>
235
247
 
248
+ > **Announce persona** — print this before proceeding:
249
+ > ```bash
250
+ > printf "\n \033[32m learnship-planner(Create implementation plans that are executable in a single context window)\033[0m\n\n"
251
+ > ```
252
+
236
253
  Read `@./agents/planner.md` for the full persona definition. Read all available context:
237
254
  - `.planning/STATE.md`
238
255
  - `.planning/ROADMAP.md`
@@ -241,11 +258,13 @@ Read `@./agents/planner.md` for the full persona definition. Read all available
241
258
  - RESEARCH.md (if exists)
242
259
 
243
260
  Create 2-4 PLAN.md files in the phase directory. Each plan:
244
- - Covers a single logical unit of work executable in one context window
245
- - Has YAML frontmatter: `wave`, `depends_on`, `files_modified`, `autonomous`
261
+ - Is a **vertical slice (tracer bullet)** delivers one demoable user-facing behavior end-to-end (data → logic → API → UI → test). NOT a horizontal layer.
262
+ - Has YAML frontmatter: `wave`, `depends_on`, `files_modified`, `autonomous`, `single_layer_justified`, `objective`
246
263
  - Contains tasks in XML format (see `$LEARNSHIP_DIR/templates/plan.md`)
247
264
  - Has `must_haves` section with observable verification criteria
248
265
 
266
+ **Vertical slice check before writing:** For each plan you draft, ask: "Can someone demo this plan's deliverable after it completes, without completing other plans?" If the answer is no, restructure into proper vertical slices.
267
+
249
268
  **Wave assignment:**
250
269
  - Plans with no dependencies → Wave 1 (independent, execute in any order)
251
270
  - Plans depending on Wave 1 → Wave 2
@@ -274,13 +293,14 @@ Task(
274
293
  prompt="
275
294
  <agent_definition>
276
295
  You are a learnship plan checker. Verify plans are complete, correct, and executable.
277
- Check: phase goal coverage, requirement IDs, CONTEXT.md decisions honored, task completeness, wave/dependency correctness.
278
- Be strict flag missing requirement IDs, vague task actions, incorrect wave assignments.
296
+ Check: phase goal coverage, requirement IDs, CONTEXT.md decisions honored, task completeness, wave/dependency correctness, AND vertical slice integrity.
297
+ Vertical slice check: each plan's objective must describe a demoable user-facing behavior delivered end-to-end. Flag any plan that covers only a single layer (all schema, all API, all UI) unless single_layer_justified: true is set in its frontmatter.
298
+ Be strict — flag missing requirement IDs, vague task actions, incorrect wave assignments, and horizontal slices.
279
299
  </agent_definition>
280
300
 
281
301
  <objective>
282
302
  Verify all PLAN.md files in [phase_dir] for Phase [phase_number]: [phase_name].
283
- Check: phase goal coverage, requirement IDs, CONTEXT.md decisions, task completeness, wave correctness.
303
+ Check: phase goal coverage, requirement IDs, CONTEXT.md decisions, task completeness, wave correctness, vertical slice integrity.
284
304
  Return: PASS or list of specific issues per plan.
285
305
  </objective>
286
306
 
@@ -300,17 +320,25 @@ If still failing after 3 iterations: present issues and ask — **Force proceed*
300
320
  **If `parallelization` is `false` (sequential mode):**
301
321
 
302
322
  <persona_context>
303
- You are now the **learnship verifier**. Check plans against requirements and roadmap.
323
+ You are now the **learnship plan checker**. Verify plans are complete, correct, and executable.
304
324
  Every v1 requirement must map to at least one plan task. Success criteria must be observable and testable.
305
- Flag gaps, missing coverage, unrealistic estimates, and circular dependencies.
325
+ Flag gaps, missing coverage, unrealistic estimates, circular dependencies, AND horizontal slices.
326
+ Vertical slice check: each plan's objective must describe a demoable user-facing behavior delivered end-to-end. Flag any plan that covers only a single layer (all schema, all API, all UI) unless `single_layer_justified: true` is in the frontmatter.
327
+ Check: phase goal coverage, requirement IDs, CONTEXT.md decisions honored, task completeness, wave/dependency correctness, vertical slice integrity.
306
328
  </persona_context>
307
329
 
308
- Read `@./agents/verifier.md` for the full persona definition. Check the plans against:
330
+ > **Announce persona** print this before proceeding:
331
+ > ```bash
332
+ > printf "\n \033[36m learnship-plan-checker(Verify plans are complete, correct, and executable)\033[0m\n\n"
333
+ > ```
334
+
335
+ Read `@./agents/plan-checker.md` for the full persona definition. Check the plans against:
309
336
  - The phase goal from ROADMAP.md
310
337
  - All requirement IDs assigned to this phase
311
338
  - CONTEXT.md decisions (are they honored?)
312
339
  - Task completeness (files, action, verify, done fields)
313
340
  - Wave/dependency correctness
341
+ - Vertical slice integrity (is each plan's objective a demoable user-facing behavior? flag horizontal-only plans)
314
342
 
315
343
  **Verification loop (max 3 iterations):**
316
344
 
@@ -147,6 +147,11 @@ Use WebSearch for current best practices, WebFetch for official docs, codebase s
147
147
  Tag confidence: HIGH/MEDIUM/LOW. Investigation, not confirmation.
148
148
  </persona_context>
149
149
 
150
+ > **Announce persona** — print this before proceeding:
151
+ > ```bash
152
+ > printf "\n \033[36m learnship-researcher(Your training data is stale — verify before asserting)\033[0m\n\n"
153
+ > ```
154
+
150
155
  Read `@./agents/researcher.md` for the full persona definition. Do a focused research pass on the task:
151
156
  - What libraries or approaches are relevant?
152
157
  - What pitfalls should the implementation avoid?
@@ -161,6 +166,11 @@ You are now the **learnship planner**. Create a focused implementation plan.
161
166
  Single plan with 1-3 tasks. Each task must be completable in one context window. Include must_haves.
162
167
  </persona_context>
163
168
 
169
+ > **Announce persona** — print this before proceeding:
170
+ > ```bash
171
+ > printf "\n \033[32m learnship-planner(Create a focused implementation plan)\033[0m\n\n"
172
+ > ```
173
+
164
174
  Read `@./agents/planner.md` for the full persona definition. Read:
165
175
  - `.planning/STATE.md`
166
176
  - CONTEXT.md if it exists (from `--discuss`)
@@ -197,6 +207,11 @@ You are now the **learnship verifier**. Check the plan against the task descript
197
207
  Flag gaps, missing coverage, and unrealistic scope.
198
208
  </persona_context>
199
209
 
210
+ > **Announce persona** — print this before proceeding:
211
+ > ```bash
212
+ > printf "\n \033[35m learnship-verifier(Check the plan against the task description)\033[0m\n\n"
213
+ > ```
214
+
200
215
  Read `@./agents/verifier.md` for the full persona definition. Verify the plan against the task description:
201
216
  - Does the plan address the task description?
202
217
  - Do tasks have files, action, verify, done fields?
@@ -214,6 +229,11 @@ You are now the **learnship executor**. Implement code from the plan, one task a
214
229
  Read task files, action, verify, and done fields. Commit atomically after each task.
215
230
  </persona_context>
216
231
 
232
+ > **Announce persona** — print this before proceeding:
233
+ > ```bash
234
+ > printf "\n \033[33m learnship-executor(Implement code from the plan, one task at a time)\033[0m\n\n"
235
+ > ```
236
+
217
237
  Read `@./agents/executor.md` for the full persona definition. Read the PLAN.md and execute each task:
218
238
 
219
239
  1. Read the task's `<files>`, `<action>`, `<verify>`, `<done>` fields
@@ -258,6 +278,11 @@ After all tasks complete, write `${NEXT_NUM}-SUMMARY.md`:
258
278
  You are now the **learnship verifier**. Check must_haves from the plan against the actual codebase.
259
279
  </persona_context>
260
280
 
281
+ > **Announce persona** — print this before proceeding:
282
+ > ```bash
283
+ > printf "\n \033[35m learnship-verifier(Check must_haves from the plan against the actual codebase)\033[0m\n\n"
284
+ > ```
285
+
261
286
  Read `@./agents/verifier.md` for the full persona definition. Check `must_haves` from the plan against the actual codebase.
262
287
 
263
288
  Write `${NEXT_NUM}-VERIFICATION.md`. Store status as `VERIFICATION_STATUS`.
@@ -77,13 +77,15 @@ Read `parallelization` from `.planning/config.json` (defaults to `false`).
77
77
  Spawn a dedicated researcher agent:
78
78
  ```
79
79
  Task(
80
- subagent_type="learnship-researcher",
80
+ subagent_type="learnship-phase-researcher",
81
81
  description="Phase [N] research",
82
82
  prompt="
83
83
  <agent_definition>
84
- You are a learnship researcher. Your training data is 6-18 months stale treat it as hypothesis, not fact.
85
- Verify before asserting. Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
86
- Tool priority: 1. WebSearch (ecosystem discovery always include current year), 2. WebFetch (official docs), 3. Codebase scan.
84
+ You are a learnship phase researcher. You answer 'What do I need to know to PLAN this phase well?' and produce a single RESEARCH.md that the planner consumes.
85
+ Your training data is 6-18 months stale treat it as hypothesis, not fact. Verify before asserting.
86
+ Flag uncertainty with confidence levels (HIGH/MEDIUM/LOW). Be prescriptive: 'Use X because Y' not 'Options are X, Y, Z.'
87
+ Tool priority: 1. WebSearch (implementation patterns — always include current year), 2. WebFetch (official docs), 3. Codebase scan (existing patterns to reuse).
88
+ Investigation, not confirmation — gather evidence first, recommend second.
87
89
  </agent_definition>
88
90
 
89
91
  <objective>
@@ -122,6 +124,11 @@ Tag every claim: [VERIFIED: source], [CITED: url], or [ASSUMED]. Never present a
122
124
  Use WebSearch for implementation patterns, WebFetch for official docs, codebase scan for existing patterns to reuse.
123
125
  </persona_context>
124
126
 
127
+ > **Announce persona** — print this before proceeding:
128
+ > ```bash
129
+ > printf "\n \033[34m learnship-phase-researcher(Your training data is stale — verify before asserting)\033[0m\n\n"
130
+ > ```
131
+
125
132
  Read `@./agents/phase-researcher.md` for the full persona definition. In **phase research mode**:
126
133
 
127
134
  **Online research first.** Before writing anything, run at least 3 WebSearch queries relevant to this phase's domain:
@@ -127,6 +127,11 @@ You are now the **learnship code reviewer**. Review code for correctness, testin
127
127
  Be specific — cite file:line, explain the issue, propose the fix. Severity: critical/major/minor/nit.
128
128
  </persona_context>
129
129
 
130
+ > **Announce persona** — print this before proceeding:
131
+ > ```bash
132
+ > printf "\n \033[31m learnship-code-reviewer(Review code for correctness, testing, security, and performance)\033[0m\n\n"
133
+ > ```
134
+
130
135
  Read `@./agents/code-reviewer.md` for the full persona definition. Run each selected persona sequentially. For each persona:
131
136
 
132
137
  1. Adopt the persona's focus lens
@@ -133,6 +133,11 @@ You are now the **learnship security auditor**. Run STRIDE threat analysis again
133
133
  Check each open threat. Verify mitigations are implemented correctly. Update status based on findings.
134
134
  </persona_context>
135
135
 
136
+ > **Announce persona** — print this before proceeding:
137
+ > ```bash
138
+ > printf "\n \033[31m learnship-security-auditor(Run STRIDE threat analysis against the codebase)\033[0m\n\n"
139
+ > ```
140
+
136
141
  Read `@./agents/security-auditor.md` for the full persona definition. Check each open threat against the codebase. Update status based on findings.
137
142
 
138
143
  **For "Accept all":** Add each to the Accepted Risks Log with user's rationale.
@@ -36,7 +36,7 @@ cp templates/config.json .planning/config.json 2>/dev/null || cat > .planning/co
36
36
  "review": true,
37
37
  "solutions_search": true,
38
38
  "security_enforcement": true,
39
- "discuss_mode": "discuss",
39
+ "discuss_mode": "discuss", // "discuss" (standard 4-exchange) or "deep" (extended questioning, walks every branch until shared understanding)
40
40
  "tdd_mode": false
41
41
  },
42
42
  "parallelization": {
@@ -137,6 +137,11 @@ You are now the **learnship verifier**. Write missing test files to close valida
137
137
  Tests must be observable and runnable. Cover the must_haves from each plan. Don't weaken existing tests.
138
138
  </persona_context>
139
139
 
140
+ > **Announce persona** — print this before proceeding:
141
+ > ```bash
142
+ > printf "\n \033[35m learnship-verifier(Write missing test files to close validation gaps)\033[0m\n\n"
143
+ > ```
144
+
140
145
  Read `@./agents/verifier.md` for the full persona definition. Write the missing test files. Rules:
141
146
  - Never touch implementation files
142
147
  - Match the existing test framework and style
@@ -282,6 +282,11 @@ You are now the **learnship debugger**. Diagnose the root cause of each gap.
282
282
  One variable at a time. Reproduce before diagnosing. Trace from symptom to root cause.
283
283
  </persona_context>
284
284
 
285
+ > **Announce persona** — print this before proceeding:
286
+ > ```bash
287
+ > printf "\n \033[38;5;208m learnship-debugger(Diagnose the root cause of each gap)\033[0m\n\n"
288
+ > ```
289
+
285
290
  Read `@./agents/debugger.md` for the full persona definition. For each issue in the Gaps section, investigate:
286
291
  - Read the relevant source files
287
292
  - Trace the issue to its root cause
@@ -311,12 +316,22 @@ You are now the **learnship planner**. Create fix plans for diagnosed gaps.
311
316
  Each plan covers one logical unit of work. Include gap_closure: true in frontmatter.
312
317
  </persona_context>
313
318
 
319
+ > **Announce persona** — print this before proceeding:
320
+ > ```bash
321
+ > printf "\n \033[32m learnship-planner(Create fix plans for diagnosed gaps)\033[0m\n\n"
322
+ > ```
323
+
314
324
  Read `@./agents/planner.md` for the full persona definition. Read the UAT.md file with diagnosed gaps. Create fix plans in the phase directory with `gap_closure: true` in frontmatter.
315
325
 
316
326
  <persona_context>
317
327
  You are now the **learnship verifier**. Verify fix plans close the diagnosed gaps.
318
328
  </persona_context>
319
329
 
330
+ > **Announce persona** — print this before proceeding:
331
+ > ```bash
332
+ > printf "\n \033[35m learnship-verifier(Verify fix plans close the diagnosed gaps)\033[0m\n\n"
333
+ > ```
334
+
320
335
  Verify fix plans (max 3 iterations — read `@./agents/verifier.md` for the full persona definition) — same loop as `plan-phase`.
321
336
 
322
337
  Present when ready: