@cratis/pi 7.6.4 → 7.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/package/corpus/agents/backend-developer.md +14 -0
  2. package/package/corpus/agents/code-reviewer.md +16 -0
  3. package/package/corpus/agents/coordinator.md +17 -0
  4. package/package/corpus/agents/frontend-developer.md +17 -0
  5. package/package/corpus/agents/orchestrator.md +18 -0
  6. package/package/corpus/agents/planner.md +24 -0
  7. package/package/corpus/agents/screenplay-modeler.md +57 -0
  8. package/package/corpus/agents/screenplay-renderer.md +42 -0
  9. package/package/corpus/agents/screenplay-reviewer.md +45 -0
  10. package/package/corpus/agents/slice-implementer.md +32 -5
  11. package/package/corpus/agents/spec-writer.md +16 -3
  12. package/package/corpus/prompts/add-reactor.prompt.md +5 -3
  13. package/package/corpus/prompts/new-vertical-slice.prompt.md +16 -5
  14. package/package/corpus/prompts/write-specs.prompt.md +12 -6
  15. package/package/corpus/rules/application-profile.md +7 -3
  16. package/package/corpus/rules/general.md +8 -3
  17. package/package/corpus/rules/glossary.md +1 -1
  18. package/package/corpus/rules/profiles.md +42 -4
  19. package/package/corpus/rules/reactors.md +30 -22
  20. package/package/corpus/rules/vertical-slices.md +3 -1
  21. package/package/corpus/skills/cratis-application-react-specifications/SKILL.md +13 -0
  22. package/package/corpus/skills/cratis-application-slice-conformance/LICENSE +2 -0
  23. package/package/corpus/skills/cratis-application-slice-conformance/SKILL.md +173 -0
  24. package/package/corpus/skills/cratis-application-slice-conformance/references/checklists.md +66 -0
  25. package/package/corpus/skills/cratis-application-slice-conformance/references/contract-and-precedence.md +49 -0
  26. package/package/corpus/skills/cratis-application-slice-conformance/references/provenance.md +23 -0
  27. package/package/corpus/skills/cratis-application-slice-conformance/references/worked-example.md +91 -0
  28. package/package/corpus/skills/cratis-application-slice-conformance/verification.json +14 -0
  29. package/package/corpus/skills/cratis-application-slice-specifications/SKILL.md +57 -1
  30. package/package/corpus/skills/cratis-application-slice-specifications/references/provenance.md +16 -0
  31. package/package/corpus/skills/cratis-arc-command/SKILL.md +10 -0
  32. package/package/corpus/skills/cratis-arc-command-execution/SKILL.md +10 -0
  33. package/package/corpus/skills/cratis-arc-command-validation/SKILL.md +10 -0
  34. package/package/corpus/skills/cratis-arc-observable-query-http/SKILL.md +10 -0
  35. package/package/corpus/skills/cratis-arc-query-paging/SKILL.md +10 -0
  36. package/package/corpus/skills/cratis-arc-react-page/SKILL.md +68 -8
  37. package/package/corpus/skills/cratis-arc-react-page/references/from-screenplay.md +199 -0
  38. package/package/corpus/skills/cratis-arc-react-page/references/provenance.md +13 -0
  39. package/package/corpus/skills/cratis-chronicle-event-constraints/SKILL.md +10 -0
  40. package/package/corpus/skills/cratis-chronicle-event-modeling/SKILL.md +38 -10
  41. package/package/corpus/skills/cratis-chronicle-event-type-migration/SKILL.md +13 -0
  42. package/package/corpus/skills/cratis-chronicle-projection/SKILL.md +13 -0
  43. package/package/corpus/skills/cratis-chronicle-reactor/SKILL.md +58 -6
  44. package/package/corpus/skills/cratis-chronicle-reactor/references/provenance.md +9 -0
  45. package/package/corpus/skills/cratis-chronicle-read-model/SKILL.md +13 -0
  46. package/package/corpus/skills/cratis-chronicle-read-model-specifications/SKILL.md +47 -0
  47. package/package/corpus/skills/cratis-chronicle-read-model-specifications/references/provenance.md +11 -0
  48. package/package/corpus/skills/cratis-chronicle-reducer/SKILL.md +13 -0
  49. package/package/corpus/skills/cratis-components-stepper-command-dialog/SKILL.md +13 -0
  50. package/package/corpus/skills/cratis-event-model-diagram/SKILL.md +35 -16
  51. package/package/corpus/skills/cratis-screenplay-automations-and-translations/LICENSE +28 -0
  52. package/package/corpus/skills/cratis-screenplay-automations-and-translations/SKILL.md +166 -0
  53. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/audit-format.md +31 -0
  54. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/automation-patterns.md +139 -0
  55. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/cases-to-specify.md +69 -0
  56. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/effects-and-idempotency.md +88 -0
  57. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/integration-contracts.md +64 -0
  58. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/provenance.md +37 -0
  59. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/realization-and-gap-fill.md +34 -0
  60. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/todo-list-example.md +208 -0
  61. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/translate-example.md +126 -0
  62. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/translation-patterns.md +93 -0
  63. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/worked-integration.md +98 -0
  64. package/package/corpus/skills/cratis-screenplay-automations-and-translations/verification.json +15 -0
  65. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/SKILL.md +267 -50
  66. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/complete-examples.md +185 -0
  67. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/verification.json +60 -12
  68. package/package/corpus/skills/cratis-screenplay-command-surface/SKILL.md +42 -12
  69. package/package/corpus/skills/cratis-screenplay-discovery/LICENSE +30 -0
  70. package/package/corpus/skills/cratis-screenplay-discovery/SKILL.md +229 -0
  71. package/package/corpus/skills/cratis-screenplay-discovery/references/divergent-sweep.md +37 -0
  72. package/package/corpus/skills/cratis-screenplay-discovery/references/event-naming.md +64 -0
  73. package/package/corpus/skills/cratis-screenplay-discovery/references/facilitation.md +62 -0
  74. package/package/corpus/skills/cratis-screenplay-discovery/references/human-workshop.md +222 -0
  75. package/package/corpus/skills/cratis-screenplay-discovery/references/interview-questions.md +66 -0
  76. package/package/corpus/skills/cratis-screenplay-discovery/references/personas-and-causes.md +152 -0
  77. package/package/corpus/skills/cratis-screenplay-discovery/references/plotting-and-handoff.md +111 -0
  78. package/package/corpus/skills/cratis-screenplay-discovery/references/provenance.md +37 -0
  79. package/package/corpus/skills/cratis-screenplay-discovery/references/storming-loop.md +119 -0
  80. package/package/corpus/skills/cratis-screenplay-discovery/references/worked-session.md +87 -0
  81. package/package/corpus/skills/cratis-screenplay-discovery/verification.json +15 -0
  82. package/package/corpus/skills/cratis-screenplay-event-modeling/SKILL.md +140 -77
  83. package/package/corpus/skills/cratis-screenplay-event-modeling/references/invoicing-example.md +51 -0
  84. package/package/corpus/skills/cratis-screenplay-event-modeling/references/nine-steps.md +114 -28
  85. package/package/corpus/skills/cratis-screenplay-event-modeling/references/parsed-not-runnable.md +50 -0
  86. package/package/corpus/skills/cratis-screenplay-event-modeling/verification.json +28 -3
  87. package/package/corpus/skills/cratis-screenplay-legacy-extraction/LICENSE +31 -0
  88. package/package/corpus/skills/cratis-screenplay-legacy-extraction/SKILL.md +239 -0
  89. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/chronicle-observations.md +25 -0
  90. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/evidence-table-template.md +79 -0
  91. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/expert-verification.md +48 -0
  92. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generate-notes.md +75 -0
  93. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/intent-example.md +164 -0
  94. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/interview-findings.md +88 -0
  95. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/loss-report-template.md +47 -0
  96. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/prologue-safety.md +147 -0
  97. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/provenance.md +10 -0
  98. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/rule-modeling.md +36 -0
  99. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/side-car-migration.md +126 -0
  100. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/signal-to-intent.md +57 -0
  101. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/ui-observation.md +52 -0
  102. package/package/corpus/skills/cratis-screenplay-legacy-extraction/verification.json +17 -0
  103. package/package/corpus/skills/cratis-screenplay-model-authoring/SKILL.md +95 -54
  104. package/package/corpus/skills/cratis-screenplay-model-authoring/references/language-reference.md +50 -20
  105. package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-loop.md +211 -0
  106. package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-tools.md +45 -5
  107. package/package/corpus/skills/cratis-screenplay-model-authoring/references/provenance.md +13 -0
  108. package/package/corpus/skills/cratis-screenplay-model-authoring/verification.json +64 -7
  109. package/package/corpus/skills/cratis-screenplay-model-review/LICENSE +34 -0
  110. package/package/corpus/skills/cratis-screenplay-model-review/SKILL.md +209 -0
  111. package/package/corpus/skills/cratis-screenplay-model-review/references/anti-patterns.md +89 -0
  112. package/package/corpus/skills/cratis-screenplay-model-review/references/business-questions.md +128 -0
  113. package/package/corpus/skills/cratis-screenplay-model-review/references/checklist.md +176 -0
  114. package/package/corpus/skills/cratis-screenplay-model-review/references/provenance.md +36 -0
  115. package/package/corpus/skills/cratis-screenplay-model-review/references/report-template.md +149 -0
  116. package/package/corpus/skills/cratis-screenplay-model-review/references/review-questions.md +59 -0
  117. package/package/corpus/skills/cratis-screenplay-model-review/references/worked-example.md +255 -0
  118. package/package/corpus/skills/cratis-screenplay-model-review/verification.json +13 -0
  119. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/LICENSE +32 -0
  120. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/SKILL.md +239 -0
  121. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/code-reading-and-tokens.md +55 -0
  122. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/handoff-template.md +124 -0
  123. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/identity-and-edits.md +84 -0
  124. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/opt-in.md +48 -0
  125. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/phase-report-inventories.md +25 -0
  126. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/phases.md +162 -0
  127. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/principles.md +53 -0
  128. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/provenance.md +63 -0
  129. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/reasoning-notes.md +31 -0
  130. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/safety.md +31 -0
  131. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/stop-or-assume.md +46 -0
  132. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md +204 -0
  133. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/vocabulary-map.md +55 -0
  134. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/worked-example.md +86 -0
  135. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/verification.json +16 -0
  136. package/package/corpus/skills/cratis-screenplay-projections/SKILL.md +14 -3
  137. package/package/corpus/skills/cratis-screenplay-read-surface/SKILL.md +15 -1
  138. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/LICENSE +2 -0
  139. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/SKILL.md +179 -0
  140. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/delivery-protocol.md +99 -0
  141. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/drift-and-ledger.md +67 -0
  142. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/gap-fill-handoff.md +72 -0
  143. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/provenance.md +27 -0
  144. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/renderability-gate.md +56 -0
  145. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/worked-example.md +124 -0
  146. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/verification.json +14 -0
  147. package/package/corpus/skills/cratis-screenplay-scenario-coverage/LICENSE +31 -0
  148. package/package/corpus/skills/cratis-screenplay-scenario-coverage/SKILL.md +200 -0
  149. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/berth-reservations.md +579 -0
  150. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/chronicle-verification.md +24 -0
  151. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/coverage-matrix.md +102 -0
  152. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/provenance.md +41 -0
  153. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-catalogue.md +196 -0
  154. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-workshop.md +102 -0
  155. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/spec-forms-by-mode.md +71 -0
  156. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/view-and-story-specs.md +91 -0
  157. package/package/corpus/skills/cratis-screenplay-scenario-coverage/verification.json +13 -0
  158. package/package/corpus/skills/cratis-screenplay-slice-design/LICENSE +30 -0
  159. package/package/corpus/skills/cratis-screenplay-slice-design/SKILL.md +236 -0
  160. package/package/corpus/skills/cratis-screenplay-slice-design/references/command-inventory.md +107 -0
  161. package/package/corpus/skills/cratis-screenplay-slice-design/references/field-lineage.md +130 -0
  162. package/package/corpus/skills/cratis-screenplay-slice-design/references/provenance.md +20 -0
  163. package/package/corpus/skills/cratis-screenplay-slice-design/references/read-model-design.md +201 -0
  164. package/package/corpus/skills/cratis-screenplay-slice-design/references/review-questions.md +23 -0
  165. package/package/corpus/skills/cratis-screenplay-slice-design/references/rule-layers.md +41 -0
  166. package/package/corpus/skills/cratis-screenplay-slice-design/references/slicing.md +122 -0
  167. package/package/corpus/skills/cratis-screenplay-slice-design/references/worked-example.md +305 -0
  168. package/package/corpus/skills/cratis-screenplay-slice-design/verification.json +43 -0
  169. package/package/corpus/skills/cratis-screenplay-specifications/SKILL.md +217 -36
  170. package/package/corpus/skills/cratis-screenplay-specifications/verification.json +28 -4
  171. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/LICENSE +33 -0
  172. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/SKILL.md +191 -0
  173. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/boundaries.md +154 -0
  174. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/chronicle-boundaries.md +54 -0
  175. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/consistency-and-concurrency.md +191 -0
  176. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution-example.md +70 -0
  177. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution.md +65 -0
  178. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/provenance.md +13 -0
  179. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/stream-patterns.md +128 -0
  180. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/streams-example.md +378 -0
  181. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/verification.json +14 -0
  182. package/package/corpus/skills/cratis-screenplay-toolchain/LICENSE +2 -0
  183. package/package/corpus/skills/cratis-screenplay-toolchain/SKILL.md +177 -0
  184. package/package/corpus/skills/cratis-screenplay-toolchain/references/automation-translate-example.md +121 -0
  185. package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet-example.md +319 -0
  186. package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet.md +96 -0
  187. package/package/corpus/skills/cratis-screenplay-toolchain/references/diagnostics.md +107 -0
  188. package/package/corpus/skills/cratis-screenplay-toolchain/references/doc-contradictions.md +48 -0
  189. package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-example.md +113 -0
  190. package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-subset.md +148 -0
  191. package/package/corpus/skills/cratis-screenplay-toolchain/references/pdl-example.md +267 -0
  192. package/package/corpus/skills/cratis-screenplay-toolchain/references/provenance.md +51 -0
  193. package/package/corpus/skills/cratis-screenplay-toolchain/references/renderable-subset.md +88 -0
  194. package/package/corpus/skills/cratis-screenplay-toolchain/references/traps.md +51 -0
  195. package/package/corpus/skills/cratis-screenplay-toolchain/references/verdicts.md +134 -0
  196. package/package/corpus/skills/cratis-screenplay-toolchain/references/versions.md +134 -0
  197. package/package/corpus/skills/cratis-screenplay-toolchain/verification.json +15 -0
  198. package/package/corpus/skills/cratis-screenplay-ui-composition/SKILL.md +53 -5
  199. package/package/corpus/skills/cratis-screenplay-ui-composition/references/flow-review.md +56 -0
  200. package/package/corpus/skills/cratis-screenplay-ui-composition/references/provenance.md +13 -0
  201. package/package/corpus/skills/cratis-screenplay-ui-composition/references/worked-flow.md +65 -0
  202. package/package/corpus/skills/cratis-screenplay-ui-composition/verification.json +4 -1
  203. package/package/corpus/skills/cratis-specification-by-example/SKILL.md +44 -1
  204. package/package/corpus/skills/cratis-specifications-csharp/SKILL.md +10 -0
  205. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/SKILL.md +186 -219
  206. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/admission.md +177 -0
  207. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/render-example.md +150 -0
  208. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/rendered-application.md +87 -0
  209. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/sandbox-and-specrunner.md +98 -0
  210. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/verification.json +19 -0
  211. package/package/profile-catalog.json +11 -0
  212. package/package.json +1 -1
@@ -0,0 +1,111 @@
1
+ # Plotting the story and handing it on
2
+
3
+ Plotting arranges the discovered events as a narrative: what happens first, what depends on
4
+ what, what can happen instead, where it ends. In Screenplay the plot is written into the
5
+ model (slice and feature `description` text) and into STATE.md; files sort by name, so story
6
+ order is never carried by structure.
7
+
8
+ ## 1. Sequence
9
+
10
+ Walk one workflow at a time, from its first trigger to every end. Ask, at each event:
11
+ what came before it, what made it happen, what is it only allowed under?
12
+
13
+ ## 2. Record after / caused by / only if
14
+
15
+ Write these three into the `description` of the `StateChange` slice that produces the event:
16
+
17
+ ```text
18
+ After: BerthRequested
19
+ Caused by: Harbourmaster (decides)
20
+ Only if: a free berth is at least as long as the boat (intent, not enforced in the model today)
21
+ ```
22
+
23
+ - **After** is the story predecessor. A predecessor is not the same as a cause; record both.
24
+ - **Caused by** is a persona's action, a schedule, an outside party or another fact.
25
+ - **Only if** is intent. Later phases turn it into a rule layer, `reads` + `require`, a
26
+ constraint, or a recorded target requirement (`cratis-screenplay-slice-design`,
27
+ `cratis-screenplay-streams-and-consistency`), and into state-violation specs
28
+ (`cratis-screenplay-scenario-coverage`). A rule that depends on stored state is stated
29
+ intent and is marked not enforced in the model today; never copy state into a command input
30
+ to make it look enforced.
31
+
32
+ A starting event has no *after*; it still has a cause.
33
+
34
+ ## 3. Ask what can happen instead
35
+
36
+ At every event, not only at forks someone mentions:
37
+
38
+ - What can happen next *instead*, including nothing? Does "nothing" expire, or wait forever?
39
+ - Which next steps may happen in any order, and which must wait for each other? Unordered
40
+ successors become automations or ordering specs later; say so in the feature description.
41
+ - On failure or refusal, what compensates, and is the refusal itself a fact the business must
42
+ remember (a decision) or just a rejection (a scenario later)?
43
+
44
+ Classify each fork: *outcome branch* (one decision, mutually exclusive results: same feature,
45
+ sibling events) or *separate story* (the choice is made before the process starts and
46
+ everything after differs: its own feature).
47
+
48
+ Name every terminal state (completed, cancelled, expired, withdrawn) and every undo or
49
+ correction path. Each path with a way out feeds removal specs later (an ending removes the
50
+ thing from the views that listed it).
51
+
52
+ ## 4. Plot output format
53
+
54
+ Put a compact story line in the feature `description` and report the plot per workflow:
55
+
56
+ ```text
57
+ The plot: SeasonalBerths
58
+
59
+ 1. BerthRequested start; caused by BoatOwner
60
+ 2. BerthAssigned after 1; caused by Harbourmaster; only if a free berth fits
61
+ BerthRequestDeclined after 1; caused by Harbourmaster (instead of 2)
62
+ 3. BoatArrived after 2; caused by Harbourmaster
63
+ 4. BoatDeparted after 3; caused by schedule (season end) terminal
64
+ BerthAssignmentWithdrawn after 2, before 3; caused by Harbourmaster terminal
65
+
66
+ Critical path: 1 -> 2 -> 3 -> 4
67
+ Decision points: after 1 (assign or decline); after 2 (arrive or withdraw)
68
+ Terminal facts: BerthRequestDeclined, BoatDeparted, BerthAssignmentWithdrawn
69
+ Wait states: after 2, until the boat arrives (what if it never does? open question)
70
+ Compensation: withdrawal frees the berth for the waiting list (open question)
71
+ ```
72
+
73
+ For a diagram use `cratis-event-model-diagram`.
74
+
75
+ ## 5. Plot checks
76
+
77
+ - Every event except a starting one has a predecessor *and* a cause.
78
+ - Dependencies and alternative paths are written down, not implied.
79
+ - Terminal states are clear; compensation and cancellation flows are complete.
80
+ - Every brainstormed event appears in the plot or in the set-aside list with the reason.
81
+ - The plot makes business sense when read aloud in order.
82
+
83
+ ## Handoff packet to `cratis-screenplay-slice-design`
84
+
85
+ The structure and section order of the packet are in `cratis-screenplay-modeling-lifecycle`.
86
+ What discovery contributes:
87
+
88
+ | Section | Content |
89
+ |---|---|
90
+ | Workflows covered | per feature: goal, happy path, decision points, terminal facts |
91
+ | Subjects | what each event story is about and what tells two apart (for later `for`/streams) |
92
+ | Rules register | each rule, the slice it constrains, intent text, target enforcement if state-dependent |
93
+ | Denial candidates | every Cannot line with its pending resolution |
94
+ | Competition candidates | scarce things two parties may want at once; who wins |
95
+ | Duplicate candidates | requests that may arrive twice |
96
+ | Non-human causes | schedules, outside parties, own follow-up |
97
+ | Hotspots | where it goes wrong today |
98
+ | Set aside | non-events kept as view needs |
99
+ | Open questions | the blocking one first |
100
+ | Decisions and assumptions | kept apart; each assumption with its reason |
101
+ | Verdicts | V1 result with tool and version; V2 to V5 "not run: discovery phase" |
102
+
103
+ Seeds for later skills:
104
+
105
+ | Discovery item | Becomes (not decided here) |
106
+ |---|---|
107
+ | Cannot line | a gate and `then denied` spec, or a recorded gap |
108
+ | "Only if" | a rule layer / `require` / constraint, or a recorded target requirement |
109
+ | Competition candidate | a competing-claim spec; consistency design |
110
+ | Duplicate candidate | a duplicate or retry spec |
111
+ | Ending | removal from affected views |
@@ -0,0 +1,37 @@
1
+ # Provenance
2
+
3
+ ## Adapted closely (MIT, TrogonStack/agentskills)
4
+
5
+ Source: https://github.com/TrogonStack/agentskills at commit `7b249d3ee42d8b7e11fa564141ebd5fbc37aadf1`,
6
+ Copyright (c) 2025 Straw Hat, LLC. The full notice is in this skill's `LICENSE`.
7
+
8
+ | Source file (under `plugins/trogonstack-eventmodeling/skills/`) | Used in | How |
9
+ |---|---|---|
10
+ | `eventmodeling-brainstorming-events/SKILL.md`: Interview Phase (when to interview, critical questions with impact, why it matters and follow-up triggers, conditional entry, two-pass flow) | `SKILL.md` "Interview phase", `references/interview-questions.md` "Interview flow" | structure and four questions adapted; results land in STATE.md instead of a trail file |
11
+ | same: Workshop Facilitation Guide (goals, free brainstorm, gentle filtering dialogue, key points, tips for facilitators) | `references/human-workshop.md`, `references/facilitation.md` | adapted to marina examples and Screenplay; the agent scribes |
12
+ | same: Role Catalog (mandatory; description, key actions, permissions boundary; system actors with triggers) | `references/personas-and-causes.md`, `SKILL.md` step 2 | adapted to `persona` Does / Reads / Cannot and non-human causes; Cannot resolved to executable gates |
13
+ | same: Best practices and Quality Checklist | `SKILL.md` Gate, `references/event-naming.md` | adapted; absolute "all error conditions have events" not adopted |
14
+ | `eventmodeling-brainstorming-events/references/facilitating-event-modeling-workshops.md`: participants, invitation, workspace, templates, pacing, personalities, disagreement, remote, post-workshop, multi-day, checklists, success indicators | `references/human-workshop.md` | structure adapted closely; mapped to Screenplay constructs and Cratis phases |
15
+ | `eventmodeling-plotting-events/SKILL.md`: sequence, dependencies (can only happen after / triggered by / precondition), alternative paths, output format, quality checklist, principles | `references/plotting-and-handoff.md`, `SKILL.md` step 5 | adapted: after / caused by / only if in the slice `description`; plot format and checks |
16
+
17
+ Not adopted from the same sources, and why: the "never use an aggregate" rule and per-command state
18
+ examples (stream and state design belong to `cratis-screenplay-streams-and-consistency`);
19
+ the `.trogonai/interviews/` trail file (replaced by bounded STATE.md); e-commerce examples and
20
+ Gherkin forms; the `total (calculated)` field example (contradicts the calculated-value rule);
21
+ "capture every error condition as an event" (most failures are rejections).
22
+
23
+ ## Ideas only (written independently)
24
+
25
+ - Idea from Nebulit-GmbH/agentic-engineer@07b0f30:`.claude/skills/timeline/SKILL.md`, written independently:
26
+ a fixed opening question when there is no input, the build-first-then-summarise turn and explicit
27
+ stop conditions (`SKILL.md` "Interview phase", `references/storming-loop.md`,
28
+ `references/interview-questions.md`).
29
+ - Idea from Nebulit-GmbH/agentic-engineer@07b0f30:`.claude/skills/eventmodeling-interview-protocol/SKILL.md`,
30
+ written independently: skip what is already known; assume visibly when told not to ask; keep what
31
+ was decided apart from what was assumed (`SKILL.md` "Interview phase").
32
+
33
+ ## Original to this corpus
34
+
35
+ The divergent sweep lenses, the not-an-event filter and its exceptions, the edit kinds, the
36
+ compiled discovery skeleton, persona Cannot resolution to gates and denial specs (S6), the
37
+ compiler-contract notes and identity-affecting edit routing.
@@ -0,0 +1,119 @@
1
+ # The storming loop on `.play`
2
+
3
+ The model is the whiteboard. Every piece of input is turned into model edits first; the chat
4
+ then reports what changed and asks one question. The user should always be able to look at the
5
+ `.play` source and see the conversation so far.
6
+
7
+ ## One turn
8
+
9
+ 1. **Read the input.** Any form works: a sentence, a pasted ticket, meeting notes, a process
10
+ description, a spreadsheet header row.
11
+ 2. **Pull out candidates.** Look for things that became true and stay true: decisions with an
12
+ outcome (approved, declined, waived), hand-overs between parties, milestones, deadlines that
13
+ passed, corrections. Ignore how screens or systems work.
14
+ 3. **Filter and name.** Run each candidate through `event-naming.md`. Rename quietly to a good
15
+ business name; do not lecture. Put non-events aside (they often become views later) and,
16
+ if they look important, ask what changed when that happened.
17
+ 4. **Classify each edit against the current model:**
18
+
19
+ | Edit | Meaning | Note |
20
+ |---|---|---|
21
+ | add | a new fact | new `StateChange` slice named after the probable command, event only |
22
+ | rename | better business name for an existing fact | identity-affecting once persisted: see SKILL.md |
23
+ | split | one name was covering two facts | keep the original if it is persisted; add the second |
24
+ | merge | two names for one fact | only when they truly mean the same thing |
25
+ | reorder | the story order changed | update the feature `description`/STATE.md; files sort by name |
26
+ | drop | not a fact after all | record why in STATE.md |
27
+ | none | already modeled | say so briefly |
28
+
29
+ 5. **Write the edits** with essential fields (identity is implicit; one to three facts).
30
+ 6. **Validate after a coherent batch** (`--warnings-as-errors`), not after every sentence.
31
+ 7. **Report the change** in a few lines, then ask **one** question.
32
+
33
+ Report shape:
34
+
35
+ ```text
36
+ Added: BerthRequested, BerthAssigned (SeasonalBerths)
37
+ Renamed: BoatArrivedInHarbour -> BoatArrived
38
+ Set aside: "harbourmaster checks the waiting list" (a view, not a fact)
39
+ Question: When the season ends, does the boat have to leave, or can the berth roll over?
40
+ ```
41
+
42
+ ## Choosing the next question
43
+
44
+ Prefer, in this order: the missing start trigger; a missing ending; a failure that has no
45
+ fact; who causes an event nobody has claimed; a rule that would change the shape of an event.
46
+ Do not ask for detail (field formats, screen layouts) during storming. When none of these is
47
+ open, start the sweep (`divergent-sweep.md`).
48
+
49
+ ## When to stop
50
+
51
+ - Attended: the user says the workflow is complete, or the two closing questions ("Is there
52
+ anything that happens here that we have not written down?" and "Which open question blocks
53
+ the next step?") return nothing new.
54
+ - Unattended: every sweep lens has an outcome and the Gate in SKILL.md holds. Do not keep
55
+ inventing facts to fill a lens.
56
+ - Never stop on a failing compile; fix or report it first.
57
+
58
+ ## A discovery skeleton
59
+
60
+ What a model looks like after the first workflow has been stormed: no commands, read models
61
+ or screens yet. Slices are named after the command expected to produce each event and are
62
+ sorted by name when a folder layout is written back (a single document keeps authored order
63
+ at v4.64.0), so the order of the story lives in the feature `description`, not in position. Persona
64
+ `description` text holds Does / Reads / Cannot on one quoted line here; the multi-line fenced
65
+ form is in `personas-and-causes.md`.
66
+
67
+ ```screenplay
68
+ domain Harbour.Moorings
69
+
70
+ concept BoatName : String
71
+ concept LengthInMetres : Decimal
72
+ validate
73
+ min 1 message "A boat is at least one metre long"
74
+ concept SeasonYear : Int
75
+
76
+ policy IsAuthenticated
77
+ require authenticated
78
+ policy IsHarbourmaster
79
+ require role "Harbourmaster"
80
+
81
+ persona BoatOwner
82
+ description "Asks for a berth for the season and keeps track of the answer. Does: requests a berth; withdraws a request before it is answered. Reads: the state of own requests. Cannot: choose a berth; see other owners' requests."
83
+ policy IsAuthenticated
84
+ persona Harbourmaster
85
+ description "Decides who gets which berth and records arrivals and departures. Does: assigns or declines berth requests; withdraws an assignment before arrival. Reads: open requests by season; free berths by length. Cannot: set or waive season fees."
86
+ policy IsAuthenticated
87
+ policy IsHarbourmaster
88
+ persona FeeAuditor
89
+ description "Reads berth occupancy each quarter to check fees; never changes anything. Does: nothing. Reads: occupancy by season. Cannot: change any berth or fee."
90
+ policy IsAuthenticated
91
+
92
+ module Moorings
93
+ description "Seasonal berths in one marina"
94
+ feature SeasonalBerths
95
+ description "Story: BerthRequested, then BerthAssigned or BerthRequestDeclined; BoatArrived; BoatDeparted at season end, or BerthAssignmentWithdrawn before arrival"
96
+ slice StateChange RequestBerth
97
+ event BerthRequested
98
+ boatName BoatName
99
+ length LengthInMetres
100
+ season SeasonYear
101
+ slice StateChange AssignBerth
102
+ description "After BerthRequested; the Harbourmaster decides. Only if a free berth is at least as long as the boat (intent, not enforced in the model today)"
103
+ event BerthAssigned
104
+ berthNumber String
105
+ slice StateChange DeclineBerthRequest
106
+ event BerthRequestDeclined
107
+ reason String
108
+ slice StateChange RecordArrival
109
+ event BoatArrived
110
+ slice StateChange RecordDeparture
111
+ event BoatDeparted
112
+ slice StateChange WithdrawBerthAssignment
113
+ event BerthAssignmentWithdrawn
114
+ reason String
115
+ ```
116
+
117
+ Open questions that would sit in STATE.md next to it: is a declined request final or can it be
118
+ put on a waiting list; who may withdraw an assignment; must the season fee be remembered as
119
+ set at assignment time (a decision, so a fact) or recalculated (a view)?
@@ -0,0 +1,87 @@
1
+ # A short discovery session, end to end
2
+
3
+ Marina berths, attended, with a thin input (a three-line brief). It shows the opening, two
4
+ storming turns, the sweep, plotting, the report and the resulting model.
5
+
6
+ ## Opening
7
+
8
+ Brief: "Boat owners ask for a seasonal berth. The harbourmaster gives out berths. Fees are
9
+ checked every quarter."
10
+
11
+ Agent (restates, confirms):
12
+ > So we are modeling how seasonal berths are requested and given out in one marina, and the goal
13
+ > is that every owner gets an answer and every berth is used. Is that right? And who has the
14
+ > final word on what these steps mean?
15
+
16
+ User: "Yes. I do, I am the harbourmaster."
17
+
18
+ Decisions: scope = seasonal berths; meaning decided by the harbourmaster. Assumption: one
19
+ marina, one season at a time.
20
+
21
+ ## Turn 1: storming
22
+
23
+ User: "An owner asks for a berth with the boat's name and length. I check the waiting list,
24
+ then either give a berth or say no."
25
+
26
+ The agent writes into the model, then reports:
27
+
28
+ ```text
29
+ Added: BerthRequested, BerthAssigned, BerthRequestDeclined (SeasonalBerths)
30
+ Personas: BoatOwner, Harbourmaster
31
+ Set aside: "check the waiting list" (a view, not a fact)
32
+ Question: When you say no, does the owner get told why, and must the marina remember why?
33
+ ```
34
+
35
+ User: "Yes, we keep the reason." (so `BerthRequestDeclined` carries `reason`).
36
+
37
+ ## Turn 2: the story
38
+
39
+ User: "Once a berth is given, the boat arrives some day, and leaves at season end. Sometimes
40
+ the owner cancels before arriving."
41
+
42
+ ```text
43
+ Added: BoatArrived, BoatDeparted, BerthAssignmentWithdrawn
44
+ Caused by: BoatDeparted <- schedule (season end)
45
+ Question: If a boat never arrives, does the berth stay assigned? Until when?
46
+ ```
47
+
48
+ User: "Ten days after the start date, then I free it." The agent records an open question: is
49
+ that a fact (`BerthForfeited`) caused by a deadline? Assumption (not confirmed): yes, treated as
50
+ a clock-driven fact for the automations phase; noted in STATE.md.
51
+
52
+ ## Sweep (lenses answered)
53
+
54
+ | Lens | Outcome |
55
+ |---|---|
56
+ | Change of mind | modeled: `BerthAssignmentWithdrawn` before arrival |
57
+ | Waiting | open question: forfeit after ten days (clock cause) |
58
+ | Competition | candidate: two owners want the last berth; the harbourmaster decides (no race modeled) |
59
+ | Hand-over failure | does not apply: no outside party in scope |
60
+ | Endings | modeled: departure; declined; withdrawn |
61
+ | Proof later | modeled: the decline `reason`; the fee is calculated (a view), unless the season fee is fixed at assignment (open question) |
62
+ | On behalf | Cannot: owner may not assign; office staff cannot request for an owner (open question) |
63
+ | Hotspots | the waiting list order: a view need |
64
+
65
+ ## Plot and handoff
66
+
67
+ The plot, the packet and the Cannot resolution table follow `plotting-and-handoff.md` and
68
+ `personas-and-causes.md`.
69
+
70
+ STATE.md:
71
+
72
+ ```text
73
+ Decisions: scope seasonal berths; harbourmaster decides meaning; decline reason is kept
74
+ Assumptions: one marina; forfeiture after ten days is a clock-driven fact (to confirm)
75
+ Rules: AssignBerth only if a free berth is at least as long as the boat (intent)
76
+ Denial candidates: BoatOwner cannot assign berths -> gate IsHarbourmaster + denial spec
77
+ Competition: last free berth wanted by two owners
78
+ Open: forfeit rule; season fee fixed or recalculated; office staff on behalf
79
+ Verdicts: V1 passed (screenplay 4.64.0, --warnaserror, exit 0); V2 to V5 not run (discovery)
80
+ ```
81
+
82
+ ## Resulting model
83
+
84
+ The discovery skeleton in `storming-loop.md` is this model before the open questions are
85
+ resolved (there is no `BerthForfeited` until the forfeit rule is confirmed); the denial gate in
86
+ `personas-and-causes.md` is the first resolution. The Gate in SKILL.md is then checked one
87
+ bullet at a time before handing over to `cratis-screenplay-slice-design`.
@@ -0,0 +1,15 @@
1
+ {
2
+ "skill": "cratis-screenplay-discovery",
3
+ "input": "We are starting a new model for a marina that hands out seasonal berths. Here are rough notes from the harbourmaster. Find the events, the roles and the story, and put them straight into the .play model.",
4
+ "fixtures": [],
5
+ "assertions": [
6
+ { "kind": "skill-contains", "value": "## Interview phase" },
7
+ { "kind": "skill-contains", "value": "Unattended: assume visibly" },
8
+ { "kind": "skill-contains", "value": "Does / Reads / Cannot" },
9
+ { "kind": "skill-contains", "value": "divergent-sweep.md" },
10
+ { "kind": "skill-contains", "value": "what can happen next *instead*" },
11
+ { "kind": "skill-contains", "value": "No generic edit event or command name" },
12
+ { "kind": "skill-contains", "value": "V2 to V5 are not run in discovery" },
13
+ { "kind": "skill-contains", "value": "`description` text is never rendered" }
14
+ ]
15
+ }