@serene-pub/core-catalog 0.6.0-pr-7 → 0.6.0-pr-9

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 (276) hide show
  1. package/README.md +1 -1
  2. package/components/genres/story/authors-note/AuthorsNote.svelte +2 -1
  3. package/components/genres/story/authors-note/AuthorsNoteWidget.svelte +177 -58
  4. package/components/shared/WidgetBoundary.svelte +37 -0
  5. package/components/shared/actions/Actions.svelte +2 -1
  6. package/components/shared/actions/ActionsWidget.svelte +31 -38
  7. package/components/shared/album/Album.svelte +2 -1
  8. package/components/shared/album/AlbumWidget.svelte +1 -7
  9. package/components/shared/annex/Annex.svelte +2 -1
  10. package/components/shared/annex/AnnexWidget.svelte +1 -1
  11. package/components/shared/attendance/Attendance.svelte +2 -1
  12. package/components/shared/attendance/AttendanceWidget.svelte +5 -8
  13. package/components/shared/backdrop/Backdrop.svelte +2 -1
  14. package/components/shared/backdrop/BackdropWidget.svelte +28 -22
  15. package/components/shared/chronicle/Chronicle.svelte +2 -1
  16. package/components/shared/chronicle/ChronicleWidget.svelte +211 -99
  17. package/components/shared/composer/Composer.svelte +25 -0
  18. package/components/shared/composer/ComposerWidget.svelte +146 -0
  19. package/components/shared/composer/composer.ts +10 -0
  20. package/components/shared/composer/settings.ts +59 -0
  21. package/components/shared/composer/target.ts +79 -0
  22. package/components/shared/dialogue-box/DialogueBoxMount.svelte +25 -0
  23. package/components/shared/dialogue-box/DialogueBoxWidget.svelte +207 -0
  24. package/components/shared/dialogue-box/dialogue-box.ts +10 -0
  25. package/components/shared/dialogue-box/settings.ts +25 -0
  26. package/components/shared/lore-entries/LoreEntries.svelte +2 -1
  27. package/components/shared/lore-entries/LoreEntriesWidget.svelte +44 -41
  28. package/components/shared/messages/MessageBlocksView.svelte +1 -1
  29. package/components/shared/messages/MessageControls.svelte +23 -5
  30. package/components/shared/messages/Messages.svelte +2 -1
  31. package/components/shared/messages/MessagesWidget.svelte +82 -191
  32. package/components/shared/messages/NextCharacterBlock.svelte +35 -20
  33. package/components/shared/messages/SceneDivider.svelte +40 -14
  34. package/components/shared/messages/SessionComposer.svelte +178 -123
  35. package/components/shared/messages/SessionContainer.svelte +89 -38
  36. package/components/shared/messages/SessionMessage.svelte +157 -54
  37. package/components/shared/messages/SpokenLine.svelte +57 -16
  38. package/components/shared/messages/StateProposalList.svelte +30 -20
  39. package/components/shared/messages/TurnLine.svelte +258 -66
  40. package/components/shared/messages/conversation.svelte.ts +83 -5
  41. package/components/shared/messages/readingPace.ts +101 -0
  42. package/components/shared/messages/rowFacts.ts +44 -0
  43. package/components/shared/messages/sceneMarks.ts +54 -0
  44. package/components/shared/messages/spokenLine.ts +63 -14
  45. package/components/shared/places/Places.svelte +2 -1
  46. package/components/shared/places/PlacesWidget.svelte +42 -33
  47. package/components/shared/routine-log/RoutineLog.svelte +2 -1
  48. package/components/shared/routine-log/RoutineLogWidget.svelte +0 -4
  49. package/components/shared/routine-log/routineLog.ts +5 -21
  50. package/components/shared/scene-portraits/ScenePortraits.svelte +2 -1
  51. package/components/shared/scene-portraits/ScenePortraitsWidget.svelte +54 -32
  52. package/components/shared/session-runs/SessionRuns.svelte +26 -0
  53. package/components/shared/session-runs/SessionRunsWidget.svelte +270 -0
  54. package/components/shared/session-runs/session-runs.ts +11 -0
  55. package/components/shared/state/PieceCard.svelte +36 -25
  56. package/components/shared/state/SlotControl.svelte +18 -5
  57. package/components/shared/stats/Stats.svelte +2 -1
  58. package/components/shared/stats/StatsWidget.svelte +104 -72
  59. package/components/shared/turn-line/TurnLineMount.svelte +25 -0
  60. package/components/shared/turn-line/TurnLineWidget.svelte +25 -0
  61. package/components/shared/turn-line/settings.ts +31 -0
  62. package/components/shared/turn-line/turn-line.ts +10 -0
  63. package/components/shared/turn-order/TurnOrder.svelte +2 -1
  64. package/components/shared/turn-order/TurnOrderWidget.svelte +1 -6
  65. package/dist/components/actions.js +71 -88
  66. package/dist/components/actions.source.json +1 -1
  67. package/dist/components/album.js +39 -44
  68. package/dist/components/album.source.json +1 -1
  69. package/dist/components/annex.js +17 -8
  70. package/dist/components/annex.source.json +1 -1
  71. package/dist/components/attendance.js +39 -48
  72. package/dist/components/attendance.source.json +1 -1
  73. package/dist/components/authors-note.js +329 -162
  74. package/dist/components/authors-note.source.json +1 -1
  75. package/dist/components/backdrop.js +52 -55
  76. package/dist/components/backdrop.source.json +1 -1
  77. package/dist/components/chronicle.js +798 -559
  78. package/dist/components/chronicle.source.json +1 -1
  79. package/dist/components/composer.js +1639 -0
  80. package/dist/components/composer.source.json +1 -0
  81. package/dist/components/core-ui.json +1 -1
  82. package/dist/components/dialogue-box.js +373 -0
  83. package/dist/components/dialogue-box.source.json +1 -0
  84. package/dist/components/lore-entries.js +134 -122
  85. package/dist/components/lore-entries.source.json +1 -1
  86. package/dist/components/messages.js +1517 -8930
  87. package/dist/components/messages.source.json +1 -1
  88. package/dist/components/places.js +267 -244
  89. package/dist/components/places.source.json +1 -1
  90. package/dist/components/routine-log.js +35 -51
  91. package/dist/components/routine-log.source.json +1 -1
  92. package/dist/components/scene-portraits.js +118 -59
  93. package/dist/components/scene-portraits.source.json +1 -1
  94. package/dist/components/session-runs.js +488 -0
  95. package/dist/components/session-runs.source.json +1 -0
  96. package/dist/components/{shared-7VDIXYAL.js → shared-47J4TNSF.js} +1 -1
  97. package/dist/components/{shared-W3XS5FEL.js → shared-5E4RQYRX.js} +3 -2
  98. package/dist/components/{shared-YDS7HYL6.js → shared-EFMMT76D.js} +57 -4
  99. package/dist/components/{shared-BIWKZFUU.js → shared-FOVKPMSK.js} +3 -3
  100. package/dist/components/{shared-JPG5DQO7.js → shared-HEAKNNZB.js} +92 -17
  101. package/dist/components/shared-JXP6SHKF.js +159 -0
  102. package/dist/components/{shared-XBDUENRA.js → shared-JXYPKSTQ.js} +1 -1
  103. package/dist/components/shared-KJIOSSE3.js +257 -0
  104. package/dist/components/{shared-WV3QTKZT.js → shared-KLURQFWI.js} +13 -9
  105. package/dist/components/shared-MHCNUDUT.js +1680 -0
  106. package/dist/components/{shared-QXF5CJVN.js → shared-NICRJ4Z2.js} +1 -1
  107. package/dist/components/{shared-BBF64YGL.js → shared-W2BBJCNE.js} +22 -16
  108. package/dist/components/shared-YYYXFDZU.js +4354 -0
  109. package/dist/components/stats.js +828 -678
  110. package/dist/components/stats.source.json +1 -1
  111. package/dist/components/turn-line.js +856 -0
  112. package/dist/components/turn-line.source.json +1 -0
  113. package/dist/components/turn-order.js +62 -67
  114. package/dist/components/turn-order.source.json +1 -1
  115. package/dist/factories/answerForm.d.ts +6 -0
  116. package/dist/factories/answerForm.js +104 -96
  117. package/dist/factories/turnOrder.d.ts +98 -105
  118. package/dist/factories/turnOrder.js +120 -136
  119. package/dist/functions/pieces.js +1 -0
  120. package/dist/functions/time.js +2 -0
  121. package/dist/genres/chat/create.js +2 -0
  122. package/dist/genres/chat/memory.js +64 -43
  123. package/dist/genres/chat/respond.d.ts +7 -6
  124. package/dist/genres/chat/respond.js +13 -4
  125. package/dist/genres/chat/turnOrder.d.ts +2 -2
  126. package/dist/genres/chat/turnOrder.js +28 -12
  127. package/dist/genres/defaults.d.ts +28 -6
  128. package/dist/genres/defaults.js +84 -26
  129. package/dist/genres/dungeon-crawler/calls.d.ts +3 -1
  130. package/dist/genres/dungeon-crawler/calls.js +5 -0
  131. package/dist/genres/dungeon-crawler/create.d.ts +9 -6
  132. package/dist/genres/dungeon-crawler/create.js +18 -8
  133. package/dist/genres/dungeon-crawler/death.d.ts +13 -6
  134. package/dist/genres/dungeon-crawler/death.js +26 -12
  135. package/dist/genres/dungeon-crawler/index.d.ts +1 -0
  136. package/dist/genres/dungeon-crawler/index.js +1 -0
  137. package/dist/genres/dungeon-crawler/journal.d.ts +1 -1
  138. package/dist/genres/dungeon-crawler/journal.js +1 -1
  139. package/dist/genres/dungeon-crawler/lore.d.ts +13 -12
  140. package/dist/genres/dungeon-crawler/lore.js +16 -25
  141. package/dist/genres/dungeon-crawler/names.d.ts +10 -3
  142. package/dist/genres/dungeon-crawler/names.js +10 -3
  143. package/dist/genres/dungeon-crawler/preamble.d.ts +5 -4
  144. package/dist/genres/dungeon-crawler/preamble.js +75 -33
  145. package/dist/genres/dungeon-crawler/respond.js +4 -2
  146. package/dist/genres/dungeon-crawler/rest.d.ts +8 -7
  147. package/dist/genres/dungeon-crawler/rest.js +39 -15
  148. package/dist/genres/dungeon-crawler/reveal.js +2 -2
  149. package/dist/genres/dungeon-crawler/roundScript.d.ts +2 -1
  150. package/dist/genres/dungeon-crawler/roundScript.js +23 -5
  151. package/dist/genres/dungeon-crawler/scripts.js +4 -5
  152. package/dist/genres/dungeon-crawler/shape.d.ts +16 -0
  153. package/dist/genres/dungeon-crawler/shape.js +5 -1
  154. package/dist/genres/dungeon-crawler/sheet.d.ts +20 -20
  155. package/dist/genres/dungeon-crawler/story.d.ts +27 -16
  156. package/dist/genres/dungeon-crawler/story.js +175 -46
  157. package/dist/genres/dungeon-crawler/storyScripts.d.ts +2 -2
  158. package/dist/genres/dungeon-crawler/storyScripts.js +109 -14
  159. package/dist/genres/dungeon-crawler/summarizeScene.d.ts +13 -0
  160. package/dist/genres/dungeon-crawler/summarizeScene.js +21 -0
  161. package/dist/genres/dungeon-crawler/turnOrder.d.ts +8 -9
  162. package/dist/genres/dungeon-crawler/turnOrder.js +33 -23
  163. package/dist/genres/guide/create.js +2 -0
  164. package/dist/genres/guide/turnOrder.d.ts +3 -3
  165. package/dist/genres/guide/turnOrder.js +29 -13
  166. package/dist/genres/lair/answerForm.js +4 -1
  167. package/dist/genres/lair/buildRoom.js +4 -3
  168. package/dist/genres/lair/castellanAction.js +160 -154
  169. package/dist/genres/lair/create.js +2 -0
  170. package/dist/genres/lair/fileCurrentRoom.js +13 -10
  171. package/dist/genres/lair/fileRoom.js +4 -3
  172. package/dist/genres/lair/keeper.js +6 -2
  173. package/dist/genres/lair/names.d.ts +2 -0
  174. package/dist/genres/lair/names.js +2 -0
  175. package/dist/genres/lair/reply.js +16 -6
  176. package/dist/genres/lair/roomAnswer.js +4 -3
  177. package/dist/genres/lair/scratchpad.js +9 -7
  178. package/dist/genres/lair/scripts.js +8 -6
  179. package/dist/genres/lair/turnOrder.d.ts +3 -2
  180. package/dist/genres/lair/turnOrder.js +45 -16
  181. package/dist/genres/story/ask.d.ts +4 -0
  182. package/dist/genres/story/ask.js +4 -0
  183. package/dist/genres/story/create.js +15 -0
  184. package/dist/genres/story/index.d.ts +1 -1
  185. package/dist/genres/story/index.js +1 -1
  186. package/dist/genres/story/narrate.js +8 -0
  187. package/dist/genres/story/narrateCharacter.js +8 -0
  188. package/dist/genres/story/reckon.d.ts +5 -19
  189. package/dist/genres/story/reckon.js +53 -40
  190. package/dist/genres/story/reckoning.js +3 -0
  191. package/dist/genres/story/respond.js +17 -28
  192. package/dist/genres/story/sweep.d.ts +1 -1
  193. package/dist/genres/story/sweep.js +1 -1
  194. package/dist/genres/story/turnOrder.d.ts +21 -3
  195. package/dist/genres/story/turnOrder.js +87 -21
  196. package/dist/index.d.ts +3 -0
  197. package/dist/index.js +23 -9
  198. package/dist/loadouts.d.ts +1 -0
  199. package/dist/loadouts.js +17 -1
  200. package/dist/primers/ninth-mile.d.ts +3 -4
  201. package/dist/registry/entries.d.ts +2 -0
  202. package/dist/registry/entries.js +18 -5
  203. package/dist/registry/genres.d.ts +146 -40
  204. package/dist/registry/genres.js +373 -101
  205. package/dist/registry/hostState.d.ts +1 -2
  206. package/dist/registry/hostState.js +2 -4
  207. package/dist/registry/layouts.d.ts +141 -111
  208. package/dist/registry/layouts.js +302 -141
  209. package/dist/registry/slots.d.ts +4 -3
  210. package/dist/registry/slots.js +4 -3
  211. package/dist/registry/widgets.d.ts +12 -2
  212. package/dist/registry/widgets.js +259 -106
  213. package/dist/rulesets/vis-itineris/ruleset.js +8 -5
  214. package/dist/rulesets/wherewithal/ruleset.js +2 -1
  215. package/dist/seed/presets.js +15 -9
  216. package/dist/seed/prompts.js +24 -5
  217. package/dist/seed/scripts.js +3 -0
  218. package/dist/shared/annexField.js +23 -3
  219. package/dist/shared/illustrateScene.d.ts +1 -0
  220. package/dist/shared/illustrateScene.js +29 -1
  221. package/dist/shared/lore.d.ts +13 -0
  222. package/dist/shared/lore.js +37 -1
  223. package/dist/shared/portrait.js +13 -4
  224. package/dist/shared/reckoning.d.ts +8 -2
  225. package/dist/shared/reckoning.js +47 -30
  226. package/dist/shared/roundTick.d.ts +20 -0
  227. package/dist/shared/roundTick.js +76 -0
  228. package/dist/shared/sceneBoundaries.d.ts +7 -0
  229. package/dist/shared/sceneBoundaries.js +62 -0
  230. package/dist/shared/sceneSummaries.d.ts +7 -0
  231. package/dist/shared/sceneSummaries.js +49 -0
  232. package/dist/shared/speakMessage.d.ts +9 -2
  233. package/dist/shared/speakMessage.js +32 -9
  234. package/dist/shared/speechFields.js +4 -0
  235. package/dist/shared/summarize/character.d.ts +1 -1
  236. package/dist/shared/summarize/history.d.ts +1 -1
  237. package/dist/shared/summarize/scene.d.ts +1 -1
  238. package/dist/shared/summarize/summarizeScene.js +1 -0
  239. package/dist/shared/summarize/summarizeSpec.d.ts +1 -1
  240. package/dist/shared/summarize/world.d.ts +1 -1
  241. package/dist/shared/ui/attendance/index.d.ts +3 -2
  242. package/dist/shared/ui/attendance/index.js +3 -7
  243. package/dist/shared/ui/chronicle/index.d.ts +24 -2
  244. package/dist/shared/ui/chronicle/index.js +58 -29
  245. package/dist/shared/ui/conversation/formAnswer.d.ts +16 -2
  246. package/dist/shared/ui/conversation/formAnswer.js +23 -9
  247. package/dist/shared/ui/conversation/index.d.ts +2 -0
  248. package/dist/shared/ui/conversation/index.js +4 -0
  249. package/dist/shared/ui/conversation/itemValues.d.ts +16 -3
  250. package/dist/shared/ui/conversation/itemValues.js +15 -5
  251. package/dist/shared/ui/conversation/messageVerbState.d.ts +17 -2
  252. package/dist/shared/ui/conversation/messageVerbState.js +5 -4
  253. package/dist/shared/ui/conversation/readingPlace.d.ts +40 -0
  254. package/dist/shared/ui/conversation/readingPlace.js +119 -0
  255. package/dist/shared/ui/conversation/rewindStrip.d.ts +13 -4
  256. package/dist/shared/ui/conversation/rewindStrip.js +29 -7
  257. package/dist/shared/ui/conversation/runsInProgress.d.ts +30 -0
  258. package/dist/shared/ui/conversation/runsInProgress.js +47 -0
  259. package/dist/shared/ui/conversation/storyDays.d.ts +7 -1
  260. package/dist/shared/ui/conversation/storyDays.js +8 -0
  261. package/dist/shared/ui/conversation/tableChannel.d.ts +8 -11
  262. package/dist/shared/ui/conversation/tableChannel.js +8 -9
  263. package/dist/shared/ui/places/index.d.ts +3 -2
  264. package/dist/shared/ui/places/index.js +4 -5
  265. package/dist/shared/ui/routine-log/index.d.ts +3 -0
  266. package/dist/shared/ui/routine-log/index.js +22 -0
  267. package/dist/shared/ui/scene-portraits/portraits.d.ts +50 -16
  268. package/dist/shared/ui/scene-portraits/portraits.js +84 -21
  269. package/dist/shared/ui/session-runs/index.d.ts +90 -0
  270. package/dist/shared/ui/session-runs/index.js +143 -0
  271. package/dist/shared/ui/session-state/stateView.d.ts +18 -5
  272. package/dist/shared/ui/session-state/stateView.js +29 -8
  273. package/dist/shared/ui/turn-order/index.d.ts +0 -9
  274. package/dist/shared/ui/turn-order/index.js +1 -2
  275. package/package.json +12 -8
  276. /package/dist/components/{shared-4ME6NFDK.js → shared-LUIF6DW7.js} +0 -0
@@ -0,0 +1,21 @@
1
+ /**
2
+ * 🚧 The Dungeon Crawler's **summarize-scene** (live scenes §13), scenes first
3
+ * (owner ruling 2026-11-10): the crawl turns scenes on, and a day's scenes
4
+ * compile into its one history entry. One story channel, `main`, no asides,
5
+ * and no transcript template of its own (the builder's default is used). A
6
+ * death reaches the scene through the Narrator's own sentence.
7
+ *
8
+ * Registered in the Dungeon Crawler's defaults as its summarize-scene
9
+ * (`summaries(dungeonCrawlerSummarizeSceneSpec())`).
10
+ */
11
+ import { summarizeScene } from '../../shared/summarize/summarizeScene.js';
12
+ import { GENRE_SUMMARIZE_SCENE_VERSION } from '../../shared/summarize/sceneIds.js';
13
+ import { dungeonCrawlerGenre } from '../../registry/genres.js';
14
+ import { DUNGEON_CRAWLER_STORY_CHANNEL, DUNGEON_CRAWLER_SUMMARIZE_SCENE_SPEC_ID } from './names.js';
15
+ /** @experimental */
16
+ export const dungeonCrawlerSummarizeSceneSpec = () => summarizeScene(DUNGEON_CRAWLER_SUMMARIZE_SCENE_SPEC_ID, {
17
+ version: GENRE_SUMMARIZE_SCENE_VERSION,
18
+ genre: dungeonCrawlerGenre,
19
+ channels: { story: DUNGEON_CRAWLER_STORY_CHANNEL },
20
+ });
21
+ //# sourceMappingURL=summarizeScene.js.map
@@ -1,8 +1,8 @@
1
1
  /**
2
- * 🚧 Dungeon Crawler's turn order: `turnOrderSpec` (`factories/turnOrder.ts`)
3
- * with the **scripted** strategy, whose `select` point runs the round script
4
- * (`roundScript.ts`) — the story turn waits until everyone has declared, or
5
- * until Continue (feature 17).
2
+ * 🚧 Dungeon Crawler's turn order: one option on Turn order asked,
3
+ * `turnOrderSpec` (`factories/turnOrder.ts`) with the **scripted** strategy,
4
+ * whose `select` point runs the round script (`roundScript.ts`) — the story
5
+ * turn waits until everyone has declared, or until Continue (feature 17).
6
6
  *
7
7
  * The round script is attached by seed key (`scripts.select`), and the
8
8
  * history reads every channel (`*`) so the selection's `voiceEntries` name
@@ -13,16 +13,15 @@ import { type TurnOrderHandle } from '../../factories/turnOrder.js';
13
13
  /** @experimental */
14
14
  export declare const DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID = "core:spec/dungeon-crawler-turn-order";
15
15
  /**
16
- * The narrator four, plus a seat leaving (the round's "everyone") and the
16
+ * The six causes: a row landing, leaving (deleted, or hidden and shown
17
+ * again), a branch's birth, a seat leaving (the round's "everyone") and the
17
18
  * annex moving (a declaration, a skip, a resolved round — and a lane
18
19
  * opening).
19
20
  *
20
21
  * ⚠ Not `member-added`: the welcome answers it (`create.ts`) by opening the
21
22
  * newcomer's lane — an annex write — so the order is recomputed on
22
- * `annex-changed` all the same. (A preset once bound one spec per event;
23
- * registrations allow several since R24, and this list needs none.) A seat
24
- * a pipeline names (the interview) is no member event either; the annex
25
- * writes beside it recompute the order.
23
+ * `annex-changed` all the same. A seat a pipeline names (the interview) is no
24
+ * member event either; the annex writes beside it recompute the order.
26
25
  * @experimental
27
26
  */
28
27
  export declare const DUNGEON_CRAWLER_TURN_ORDER_EVENTS: readonly ["core:event/message-completed@1", "core:event/message-deleted@1", "core:event/message-hidden@1", "core:event/session-branched@1", "core:event/member-removed@1", "core:event/annex-changed@1"];
@@ -1,8 +1,8 @@
1
1
  /**
2
- * 🚧 Dungeon Crawler's turn order: `turnOrderSpec` (`factories/turnOrder.ts`)
3
- * with the **scripted** strategy, whose `select` point runs the round script
4
- * (`roundScript.ts`) — the story turn waits until everyone has declared, or
5
- * until Continue (feature 17).
2
+ * 🚧 Dungeon Crawler's turn order: one option on Turn order asked,
3
+ * `turnOrderSpec` (`factories/turnOrder.ts`) with the **scripted** strategy,
4
+ * whose `select` point runs the round script (`roundScript.ts`) — the story
5
+ * turn waits until everyone has declared, or until Continue (feature 17).
6
6
  *
7
7
  * The round script is attached by seed key (`scripts.select`), and the
8
8
  * history reads every channel (`*`) so the selection's `voiceEntries` name
@@ -10,9 +10,9 @@
10
10
  * Planner's reply there.
11
11
  */
12
12
  import * as C from '@serene-pub/contracts';
13
- import { sessionEvents } from '@serene-pub/sdk';
13
+ import { eventIdOf, sessionEvents } from '@serene-pub/sdk';
14
14
  import { dungeonCrawlerGenre } from '../../registry/genres.js';
15
- import { TURN_ORDER_NARRATOR_EVENTS, turnOrderSpec, turnStrategyNode, } from '../../factories/turnOrder.js';
15
+ import { turnOrderSpec } from '../../factories/turnOrder.js';
16
16
  import { once } from '../../factories/once.js';
17
17
  import { DUNGEON_CRAWLER_ROUND_SCRIPT } from './roundScript.js';
18
18
  /** @experimental */
@@ -23,37 +23,47 @@ export const DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID = 'core:spec/dungeon-crawler-tur
23
23
  */
24
24
  const NOBODY = { characters: 'none', personas: 'none', envoys: 'none' };
25
25
  /**
26
- * The narrator four, plus a seat leaving (the round's "everyone") and the
26
+ * The six causes: a row landing, leaving (deleted, or hidden and shown
27
+ * again), a branch's birth, a seat leaving (the round's "everyone") and the
27
28
  * annex moving (a declaration, a skip, a resolved round — and a lane
28
29
  * opening).
29
30
  *
30
31
  * ⚠ Not `member-added`: the welcome answers it (`create.ts`) by opening the
31
32
  * newcomer's lane — an annex write — so the order is recomputed on
32
- * `annex-changed` all the same. (A preset once bound one spec per event;
33
- * registrations allow several since R24, and this list needs none.) A seat
34
- * a pipeline names (the interview) is no member event either; the annex
35
- * writes beside it recompute the order.
33
+ * `annex-changed` all the same. A seat a pipeline names (the interview) is no
34
+ * member event either; the annex writes beside it recompute the order.
36
35
  * @experimental
37
36
  */
38
37
  export const DUNGEON_CRAWLER_TURN_ORDER_EVENTS = [
39
- ...TURN_ORDER_NARRATOR_EVENTS,
38
+ sessionEvents.messageCompleted,
39
+ sessionEvents.messageDeleted,
40
+ sessionEvents.messageHidden,
41
+ sessionEvents.sessionBranched,
40
42
  sessionEvents.memberRemoved,
41
43
  sessionEvents.annexChanged,
42
44
  ];
45
+ const build = once(() => turnOrderSpec({
46
+ id: DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID,
47
+ genre: dungeonCrawlerGenre,
48
+ strategy: C.turnScripted,
49
+ scripts: { select: [{ seedKey: DUNGEON_CRAWLER_ROUND_SCRIPT.seedKey }] },
50
+ pool: NOBODY,
51
+ historyChannel: '*',
52
+ }));
43
53
  /** Dungeon Crawler's turn order, by value. @experimental */
44
54
  export const dungeonCrawlerTurnOrder = {
45
55
  genre: dungeonCrawlerGenre,
46
56
  spec: DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID,
47
- events: DUNGEON_CRAWLER_TURN_ORDER_EVENTS,
48
- build: once(() => turnOrderSpec({
49
- id: DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID,
50
- genre: dungeonCrawlerGenre,
51
- events: DUNGEON_CRAWLER_TURN_ORDER_EVENTS,
52
- strategy: C.turnScripted,
53
- pool: NOBODY,
54
- historyChannel: '*',
55
- scripts: { select: [{ seedKey: DUNGEON_CRAWLER_ROUND_SCRIPT.seedKey }] },
56
- })),
57
- strategyNode: turnStrategyNode({}),
57
+ build,
58
+ options: [
59
+ {
60
+ spec: DUNGEON_CRAWLER_TURN_ORDER_SPEC_ID,
61
+ build,
62
+ label: 'Round by round',
63
+ strategy: C.turnScripted.id,
64
+ when: { on: 'event.asked', in: DUNGEON_CRAWLER_TURN_ORDER_EVENTS.map(eventIdOf) },
65
+ default: true,
66
+ },
67
+ ],
58
68
  };
59
69
  //# sourceMappingURL=turnOrder.js.map
@@ -33,6 +33,8 @@ export const createGuideSpec = () => compile(spec(GUIDE_CREATE_SPEC_ID, {
33
33
  family: guideGenre.family,
34
34
  description: guideGenre.description,
35
35
  shape: guideGenre.shape,
36
+ // The genre's pinned settings ride the row (how far Auto-advance runs).
37
+ settings: guideGenre.settings,
36
38
  events: guideGenre.events,
37
39
  envoys: guideGenre.envoys,
38
40
  },
@@ -1,10 +1,10 @@
1
1
  /**
2
- * The guide's turn order: `turnOrderSpec` (`factories/turnOrder.ts`) for the
3
- * guide genre.
2
+ * The guide's turn order: one round robin option on Turn order asked
3
+ * (`factories/turnOrder.ts`) for the guide genre.
4
4
  */
5
5
  import { type TurnOrderHandle } from '../../factories/turnOrder.js';
6
6
  /** @experimental */
7
7
  export declare const GUIDE_TURN_ORDER_SPEC_ID = "core:spec/guide-turn-order";
8
- /** Guide's turn order, by value — hand `build()` and `strategyNode` to `swaps` (R26). @experimental */
8
+ /** Guide's turn order, by value (R26). @experimental */
9
9
  export declare const guideTurnOrder: TurnOrderHandle;
10
10
  //# sourceMappingURL=turnOrder.d.ts.map
@@ -1,27 +1,43 @@
1
1
  /**
2
- * The guide's turn order: `turnOrderSpec` (`factories/turnOrder.ts`) for the
3
- * guide genre.
2
+ * The guide's turn order: one round robin option on Turn order asked
3
+ * (`factories/turnOrder.ts`) for the guide genre.
4
4
  */
5
5
  import * as C from '@serene-pub/contracts';
6
+ import { eventIdOf, sessionEvents } from '@serene-pub/sdk';
6
7
  import { guideGenre } from '../../registry/genres.js';
7
- import { TURN_ORDER_EVENTS, turnOrderSpec, turnStrategyNode } from '../../factories/turnOrder.js';
8
+ import { roundRobinTurnOrder } from '../../factories/turnOrder.js';
8
9
  import { once } from '../../factories/once.js';
9
10
  /** @experimental */
10
11
  export const GUIDE_TURN_ORDER_SPEC_ID = 'core:spec/guide-turn-order';
11
12
  /** Guide: its one in-turn envoy is the whole order. */
12
13
  const ENVOY_ONLY = { characters: 'none', envoys: 'in-turn' };
13
- /** Guide's turn order, by value — hand `build()` and `strategyNode` to `swaps` (R26). @experimental */
14
+ /** The nine causes: a row landing, leaving or changing, the cast, the settings, a branch's birth. */
15
+ const CAUSES = [
16
+ sessionEvents.messageCompleted,
17
+ sessionEvents.messageEdited,
18
+ sessionEvents.messageDeleted,
19
+ sessionEvents.messageHidden,
20
+ sessionEvents.memberAdded,
21
+ sessionEvents.memberRemoved,
22
+ sessionEvents.castChanged,
23
+ sessionEvents.sessionUpdated,
24
+ sessionEvents.sessionBranched,
25
+ ].map(eventIdOf);
26
+ const build = once(() => roundRobinTurnOrder(guideGenre, { id: GUIDE_TURN_ORDER_SPEC_ID, pool: ENVOY_ONLY }));
27
+ /** Guide's turn order, by value (R26). @experimental */
14
28
  export const guideTurnOrder = {
15
29
  genre: guideGenre,
16
30
  spec: GUIDE_TURN_ORDER_SPEC_ID,
17
- events: TURN_ORDER_EVENTS,
18
- build: once(() => turnOrderSpec({
19
- id: GUIDE_TURN_ORDER_SPEC_ID,
20
- genre: guideGenre,
21
- events: TURN_ORDER_EVENTS,
22
- strategy: C.turnRoundRobin,
23
- pool: ENVOY_ONLY,
24
- })),
25
- strategyNode: turnStrategyNode({}),
31
+ build,
32
+ options: [
33
+ {
34
+ spec: GUIDE_TURN_ORDER_SPEC_ID,
35
+ build,
36
+ label: 'Round robin',
37
+ strategy: C.turnRoundRobin.id,
38
+ when: { on: 'event.asked', in: CAUSES },
39
+ default: true,
40
+ },
41
+ ],
26
42
  };
27
43
  //# sourceMappingURL=turnOrder.js.map
@@ -4,6 +4,7 @@
4
4
  */
5
5
  import { lairGenre } from '../../registry/genres.js';
6
6
  import { answerFormSpec } from '../../factories/answerForm.js';
7
+ import { LAIR_SHOW_OUTCOMES_KEY } from './names.js';
7
8
  /** @internal */
8
9
  export const LAIR_ANSWER_FORM_SPEC_ID = 'core:spec/lair-answer-form';
9
10
  /**
@@ -15,5 +16,7 @@ export const LAIR_ANSWER_FORM_SPEC_ID = 'core:spec/lair-answer-form';
15
16
  * the AI portrays the addressee, and `owner` never resolves that way.
16
17
  * @internal
17
18
  */
18
- export const answerFormLairSpec = () => answerFormSpec(LAIR_ANSWER_FORM_SPEC_ID, lairGenre);
19
+ export const answerFormLairSpec = () => answerFormSpec(LAIR_ANSWER_FORM_SPEC_ID, lairGenre, {
20
+ outcomeNumbersFrom: LAIR_SHOW_OUTCOMES_KEY,
21
+ });
19
22
  //# sourceMappingURL=answerForm.js.map
@@ -6,7 +6,7 @@ import { compile, slot, spec } from '@serene-pub/sdk';
6
6
  import * as C from '@serene-pub/contracts';
7
7
  import { bareEntryTypeId, locationEntryType } from '../../registry/entries.js';
8
8
  import { applyWiring, jsonPart, scriptStep, textPart, wiring } from '../../shared/calls.js';
9
- import { LAIR_ROOM_DRAFT_SCHEMA } from './names.js';
9
+ import { LAIR_ROOM_DRAFT_SCHEMA, LAIR_SHOW_OUTCOMES_KEY } from './names.js';
10
10
  import { LAIR_ROOM_SCRIPT } from './scripts.js';
11
11
  /* ── Build room ─────────────────────────────────────────────────────────── */
12
12
  /** @internal */
@@ -46,7 +46,7 @@ export const LAIR_BUILD_ROOM_VERSION = '1.0.0';
46
46
  */
47
47
  export const lairBuildRoomSpec = () => {
48
48
  const w = wiring();
49
- const drafted = spec(LAIR_BUILD_ROOM_SPEC_ID, {
49
+ const drafted = jsonPart(spec(LAIR_BUILD_ROOM_SPEC_ID, {
50
50
  version: LAIR_BUILD_ROOM_VERSION,
51
51
  taxonomy: { role: 'action' },
52
52
  contributes: {
@@ -69,10 +69,11 @@ export const lairBuildRoomSpec = () => {
69
69
  ],
70
70
  },
71
71
  })
72
- .inlet('input', C.userMessage.v1(), { suits: [] })
72
+ .inlet('input', C.userMessage.v1(), { suits: [] }), w, 'showOutcomes', ($) => $.input.fields, LAIR_SHOW_OUTCOMES_KEY, 'Show outcomes')
73
73
  .gather('gather', { mode: 'parallel' }, (b) => b
74
74
  .chain('history', (c) => c.query('read', ($) => C.sessionHistory.v1({
75
75
  scope: $.input.sessionScope,
76
+ outcomeNumbers: $.showOutcomes.main,
76
77
  params: slot.params(),
77
78
  })))
78
79
  /** The world as the lore tells it, ranked against the conversation. */
@@ -5,6 +5,8 @@
5
5
  import { compile, slot, spec } from '@serene-pub/sdk';
6
6
  import * as C from '@serene-pub/contracts';
7
7
  import { LAIR_CASTELLAN_KEY, POST_HISTORY_TOKEN_TRIGGER } from '../../registry/genres.js';
8
+ import { applyWiring, jsonPart, wiring } from '../../shared/calls.js';
9
+ import { LAIR_SHOW_OUTCOMES_KEY } from './names.js';
8
10
  /* ── The Castellan's two turns ──────────────────────────────────────────── */
9
11
  /**
10
12
  * Trigger trap and Reveal are one graph with two sets of instructions, and
@@ -18,159 +20,163 @@ import { LAIR_CASTELLAN_KEY, POST_HISTORY_TOKEN_TRIGGER } from '../../registry/g
18
20
  * own instructions and the reveal its own, in the same pool, each editable
19
21
  * without touching the other.
20
22
  */
21
- export const castellanAction = (id, version, trigger) => compile(spec(id, {
22
- version,
23
- taxonomy: { role: 'action' },
24
- contributes: {
25
- actions: [
26
- {
27
- key: trigger.key,
28
- venue: { kind: 'composer' },
29
- quick: true,
30
- icon: trigger.icon,
31
- /** What the master says rides as the turn's instructions — or nothing, and the room decides (R3). */
32
- collects: {
33
- text: { need: 'optional', label: { en: trigger.ask }, ifEmpty: { en: 'The room decides.' } },
23
+ export const castellanAction = (id, version, trigger) => {
24
+ const w = wiring();
25
+ return compile(jsonPart(spec(id, {
26
+ version,
27
+ taxonomy: { role: 'action' },
28
+ contributes: {
29
+ actions: [
30
+ {
31
+ key: trigger.key,
32
+ venue: { kind: 'composer' },
33
+ quick: true,
34
+ icon: trigger.icon,
35
+ /** What the master says rides as the turn's instructions — or nothing, and the room decides (R3). */
36
+ collects: {
37
+ text: { need: 'optional', label: { en: trigger.ask }, ifEmpty: { en: 'The room decides.' } },
38
+ },
39
+ label: { en: trigger.label },
40
+ description: { en: trigger.description },
34
41
  },
35
- label: { en: trigger.label },
36
- description: { en: trigger.description },
37
- },
38
- ],
39
- },
40
- })
41
- .inlet('input', C.userMessage.v1(), { suits: [] })
42
- /**
43
- * The row, opened before anything is read — the Castellan's, by
44
- * name (R8, owner F2 2026-09-28: Trap and Reveal are the
45
- * Castellan's). Not `narration`: a trap is the Castellan taking a
46
- * turn, not a side note beside one. It streams while `write` runs
47
- * (`expose.stream`) and `save` finishes it. What the master typed
48
- * is stored beside it as the turn's instructions — never as its
49
- * text.
50
- */
51
- .outlet('placeholder', ($) => C.createMessage.v1({
52
- generating: true,
53
- speaker: `envoy:${LAIR_CASTELLAN_KEY}`,
54
- instructions: $.input.text,
55
- }))
56
- // Before the reads (history window, 2026-10-03): the history read
57
- // is sized by this budget, so it is computed first. It reads only
58
- // config, never a step, so moving it changes no value.
59
- .task('contextBudget', ($) => C.contextBudget.v1({
60
- sampling: slot.samplingOf('write'),
61
- connection: slot.connectionOf('write'),
62
- params: slot.params(),
63
- }))
64
- .gather('gather', { mode: 'parallel' }, (b) => b
65
- .chain('history', (c) => c.query('read', ($) => C.sessionHistory.v1({
66
- scope: $.input.sessionScope,
67
- // Sized by the window (history window, 2026-10-03).
68
- budget: $.contextBudget.available,
69
- params: slot.params(),
70
- })))
71
- .chain('lore', (c) => c.query('read', ($) => C.lorebookTriggers.v1({
72
- scope: $.input.sessionScope,
73
- params: slot.params(),
74
- })))
75
- .chain('cast', (c) => c.query('read', ($) => C.sessionCast.v1({ scope: $.input.sessionScope })))
76
- .chain('state', (c) => c.query('read', ($) => C.sessionState.v1({ scope: $.input.sessionScope }))))
77
- .task('lore', ($) => C.concatCandidates.v1({
78
- sources: [$.gather.history.read.band, $.gather.lore.read.main],
79
- }))
80
- // Who is in the world at the session's moment (R4), for `eligible`.
81
- .query('presences', ($) => C.castPresences.v1({ scope: $.input.sessionScope }))
82
- // The hard gates before the ranker (C2; R2, R4): selective-logic
83
- // exclusions from the keyword lanes, and the presence gate.
84
- .task('eligible', ($) => C.eligibility.v1({
85
- candidates: $.lore.candidates,
86
- exclusions: $.gather.lore.read.exclusions,
87
- presences: $.presences.main,
88
- at: $.presences.at,
89
- }))
90
- .task('rank', ($) => C.rankHybrid.v1({
91
- candidates: $.eligible.candidates,
92
- budget: $.contextBudget.available,
93
- params: slot.params(),
94
- }))
95
- /**
96
- * `build-template-context@1` rather than the narrator builder,
97
- * builder, for the one port that decides it: `state`. A trap that
98
- * did not know which floor the party is on, and a reveal that did
99
- * not know where they are standing, would be describing a dungeon
100
- * in general.
101
- */
102
- .task('context', ($) => C.buildTemplateContext.v1({
103
- cast: $.gather.cast.read.cast,
104
- state: $.gather.state.read.state,
105
- /**
106
- * What the master typed — *"the floor gives way"* — as
107
- * what to spring or reveal (B17). The prompt renders it as
108
- * `{{turnDirection}}`; blank, the room decides.
109
- */
110
- turnDirection: $.input.text,
111
- prompts: slot.prompts(),
112
- variables: slot.variables(),
113
- }))
114
- .task('lines', ($) => C.processMessages.v1({
115
- messages: $.gather.history.read.messages,
116
- cast: $.gather.cast.read.cast,
117
- templateContext: $.context.templateContext,
118
- seedName: $.context.seedName,
119
- }))
120
- /**
121
- * 🚧 **The transcript's files, placed** (attachments follow-ups, owner
122
- * ruling 2026-10-03) — `respond`'s two steps: the files the rows show,
123
- * then per line what `write` receives (an image it can read rides its
124
- * own turn; otherwise its name). A transcript with no files passes
125
- * through untouched, so the prompt is byte for byte what it was.
126
- */
127
- .query('attachments', ($) => C.historyAttachments.v1({
128
- messages: $.gather.history.read.messages,
129
- params: slot.params(),
130
- }))
131
- .task('attached', ($) => C.placeAttachments.v1({
132
- messages: $.lines.messages,
133
- attachments: $.attachments.attachments,
134
- connection: slot.connectionOf('write'),
135
- params: slot.params(),
136
- }))
137
- .task('prompt', ($) => C.assemble.v2({
138
- candidates: $.rank.candidates,
139
- decisions: $.rank.decisions,
140
- groups: $.rank.groups,
141
- budget: $.contextBudget.available,
142
- messages: $.attached.messages,
143
- templateContext: $.context.templateContext,
144
- template: slot.template(),
145
- prompts: slot.prompts($.context),
146
- variables: slot.variables(),
147
- params: slot.params(),
148
- connection: slot.connectionOf('write'),
149
- }))
150
- .oracle('write', ($) => C.generateText.v1({
151
- context: $.prompt.context,
152
- connection: slot.connection(),
153
- sampling: slot.sampling(),
154
- params: slot.params(),
155
- // 🚧 O7: the voice a spoken reply speaks in, when `outputs` ask for audio.
156
- speechSampling: slot.speechSampling(),
157
- }), { expose: { stream: true, status: trigger.status } })
158
- /**
159
- * The placeholder, finished: the prose, and the Castellan's
160
- * reasoning folded as the row's Reasoning (the B5 pattern — absent
161
- * when the model gave none, and the port is skipped).
162
- */
163
- .outlet('save', ($) => C.updateMessage.v1({
164
- target: $.placeholder.messageId,
165
- text: $.write.text,
166
- reasoning: $.write.reasoning,
167
- }))
168
- /**
169
- * What this step ships with: the post-history reminder's trigger
170
- * (`POST_HISTORY_TOKEN_TRIGGER`), because the prompt renders the
171
- * session's growing history and the reminder only earns its place
172
- * once there is enough of it to drift from.
173
- */
174
- .defaults((p) => p.params('prompt', { postHistoryTokenTrigger: POST_HISTORY_TOKEN_TRIGGER }))
175
- .build());
42
+ ],
43
+ },
44
+ })
45
+ .inlet('input', C.userMessage.v1(), { suits: [] }), w, 'showOutcomes', ($) => $.input.fields, LAIR_SHOW_OUTCOMES_KEY, 'Show outcomes')
46
+ /**
47
+ * The row, opened before anything is read — the Castellan's, by
48
+ * name (R8, owner F2 2026-09-28: Trap and Reveal are the
49
+ * Castellan's). Not `narration`: a trap is the Castellan taking a
50
+ * turn, not a side note beside one. It streams while `write` runs
51
+ * (`expose.stream`) and `save` finishes it. What the master typed
52
+ * is stored beside it as the turn's instructions — never as its
53
+ * text.
54
+ */
55
+ .outlet('placeholder', ($) => C.createMessage.v1({
56
+ generating: true,
57
+ speaker: `envoy:${LAIR_CASTELLAN_KEY}`,
58
+ instructions: $.input.text,
59
+ }))
60
+ // Before the reads (history window, 2026-10-03): the history read
61
+ // is sized by this budget, so it is computed first. It reads only
62
+ // config, never a step, so moving it changes no value.
63
+ .task('contextBudget', ($) => C.contextBudget.v1({
64
+ sampling: slot.samplingOf('write'),
65
+ connection: slot.connectionOf('write'),
66
+ params: slot.params(),
67
+ }))
68
+ .gather('gather', { mode: 'parallel' }, (b) => b
69
+ .chain('history', (c) => c.query('read', ($) => C.sessionHistory.v1({
70
+ scope: $.input.sessionScope,
71
+ // Sized by the window (history window, 2026-10-03).
72
+ budget: $.contextBudget.available,
73
+ outcomeNumbers: $.showOutcomes.main,
74
+ params: slot.params(),
75
+ })))
76
+ .chain('lore', (c) => c.query('read', ($) => C.lorebookTriggers.v1({
77
+ scope: $.input.sessionScope,
78
+ params: slot.params(),
79
+ })))
80
+ .chain('cast', (c) => c.query('read', ($) => C.sessionCast.v1({ scope: $.input.sessionScope })))
81
+ .chain('state', (c) => c.query('read', ($) => C.sessionState.v1({ scope: $.input.sessionScope }))))
82
+ .task('lore', ($) => C.concatCandidates.v1({
83
+ sources: [$.gather.history.read.band, $.gather.lore.read.main],
84
+ }))
85
+ // Who is in the world at the session's moment (R4), for `eligible`.
86
+ .query('presences', ($) => C.castPresences.v1({ scope: $.input.sessionScope }))
87
+ // The hard gates before the ranker (C2; R2, R4): selective-logic
88
+ // exclusions from the keyword lanes, and the presence gate.
89
+ .task('eligible', ($) => C.eligibility.v1({
90
+ candidates: $.lore.candidates,
91
+ exclusions: $.gather.lore.read.exclusions,
92
+ presences: $.presences.main,
93
+ at: $.presences.at,
94
+ }))
95
+ .task('rank', ($) => C.rankHybrid.v1({
96
+ candidates: $.eligible.candidates,
97
+ budget: $.contextBudget.available,
98
+ params: slot.params(),
99
+ }))
100
+ /**
101
+ * `build-template-context@1` rather than the narrator builder,
102
+ * builder, for the one port that decides it: `state`. A trap that
103
+ * did not know which floor the party is on, and a reveal that did
104
+ * not know where they are standing, would be describing a dungeon
105
+ * in general.
106
+ */
107
+ .task('context', ($) => C.buildTemplateContext.v1({
108
+ cast: $.gather.cast.read.cast,
109
+ state: $.gather.state.read.state,
110
+ /**
111
+ * What the master typed — *"the floor gives way"* — as
112
+ * what to spring or reveal (B17). The prompt renders it as
113
+ * `{{turnDirection}}`; blank, the room decides.
114
+ */
115
+ turnDirection: $.input.text,
116
+ prompts: slot.prompts(),
117
+ variables: slot.variables(),
118
+ }))
119
+ .task('lines', ($) => C.processMessages.v1({
120
+ messages: $.gather.history.read.messages,
121
+ cast: $.gather.cast.read.cast,
122
+ templateContext: $.context.templateContext,
123
+ seedName: $.context.seedName,
124
+ }))
125
+ /**
126
+ * 🚧 **The transcript's files, placed** (attachments follow-ups, owner
127
+ * ruling 2026-10-03) — `respond`'s two steps: the files the rows show,
128
+ * then per line what `write` receives (an image it can read rides its
129
+ * own turn; otherwise its name). A transcript with no files passes
130
+ * through untouched, so the prompt is byte for byte what it was.
131
+ */
132
+ .query('attachments', ($) => C.historyAttachments.v1({
133
+ messages: $.gather.history.read.messages,
134
+ params: slot.params(),
135
+ }))
136
+ .task('attached', ($) => C.placeAttachments.v1({
137
+ messages: $.lines.messages,
138
+ attachments: $.attachments.attachments,
139
+ connection: slot.connectionOf('write'),
140
+ params: slot.params(),
141
+ }))
142
+ .task('prompt', ($) => C.assemble.v2({
143
+ candidates: $.rank.candidates,
144
+ decisions: $.rank.decisions,
145
+ groups: $.rank.groups,
146
+ budget: $.contextBudget.available,
147
+ messages: $.attached.messages,
148
+ templateContext: $.context.templateContext,
149
+ template: slot.template(),
150
+ prompts: slot.prompts($.context),
151
+ variables: slot.variables(),
152
+ params: slot.params(),
153
+ connection: slot.connectionOf('write'),
154
+ }))
155
+ .oracle('write', ($) => C.generateText.v1({
156
+ context: $.prompt.context,
157
+ connection: slot.connection(),
158
+ sampling: slot.sampling(),
159
+ params: slot.params(),
160
+ // 🚧 O7: the voice a spoken reply speaks in, when `outputs` ask for audio.
161
+ speechSampling: slot.speechSampling(),
162
+ }), { expose: { stream: true, status: trigger.status } })
163
+ /**
164
+ * The placeholder, finished: the prose, and the Castellan's
165
+ * reasoning folded as the row's Reasoning (the B5 pattern — absent
166
+ * when the model gave none, and the port is skipped).
167
+ */
168
+ .outlet('save', ($) => C.updateMessage.v1({
169
+ target: $.placeholder.messageId,
170
+ text: $.write.text,
171
+ reasoning: $.write.reasoning,
172
+ }))
173
+ /**
174
+ * What this step ships with: the post-history reminder's trigger
175
+ * (`POST_HISTORY_TOKEN_TRIGGER`), because the prompt renders the
176
+ * session's growing history and the reminder only earns its place
177
+ * once there is enough of it to drift from.
178
+ */
179
+ .defaults((p) => applyWiring(p.params('prompt', { postHistoryTokenTrigger: POST_HISTORY_TOKEN_TRIGGER }), w))
180
+ .build());
181
+ };
176
182
  //# sourceMappingURL=castellanAction.js.map
@@ -40,6 +40,8 @@ export const lairCreateSpec = () => compile(spec(LAIR_CREATE_SPEC_ID, {
40
40
  family: lairGenre.family,
41
41
  description: lairGenre.description,
42
42
  shape: lairGenre.shape,
43
+ // 🚧 ed B1 (2026-11-05): the genre's pinned settings ride the row (sheet latitude pins).
44
+ settings: lairGenre.settings,
43
45
  events: lairGenre.events,
44
46
  // R4: the host names the person's lines off this row.
45
47
  playerLabel: lairGenre.playerLabel,