@cratis/pi 7.48.0 → 7.48.3

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 (97) hide show
  1. package/package/corpus/harnesses/copilot/instructions/local-work-artifacts.instructions.md +6 -2
  2. package/package/corpus/harnesses/copilot/instructions/profiles.instructions.md +1 -1
  3. package/package/corpus/hooks/README.md +11 -5
  4. package/package/corpus/hooks/scripts/cratis-cleanup-worktrees.sh +44 -4
  5. package/package/corpus/prompts/ship-changes.prompt.md +4 -1
  6. package/package/corpus/rules/local-work-artifacts.md +6 -2
  7. package/package/corpus/rules/profiles.md +1 -1
  8. package/package/corpus/skills/cratis-application-slice-conformance/SKILL.md +2 -2
  9. package/package/corpus/skills/cratis-chronicle-event-modeling/SKILL.md +1 -1
  10. package/package/corpus/skills/cratis-event-model-diagram/SKILL.md +1 -1
  11. package/package/corpus/skills/cratis-screenplay-automations-and-translations/SKILL.md +4 -4
  12. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/audit-format.md +1 -1
  13. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/automation-patterns.md +3 -3
  14. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/cases-to-specify.md +1 -1
  15. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/provenance.md +2 -2
  16. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/public-events-and-direction.md +2 -2
  17. package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/todo-list-example.md +1 -1
  18. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/SKILL.md +6 -6
  19. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/invocation-identity.md +3 -3
  20. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/product-sources.md +1 -1
  21. package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/specifying-triggers-and-clock.md +1 -1
  22. package/package/corpus/skills/cratis-screenplay-command-surface/SKILL.md +3 -3
  23. package/package/corpus/skills/cratis-screenplay-command-surface/references/compliance.md +1 -1
  24. package/package/corpus/skills/cratis-screenplay-command-surface/references/context.md +1 -1
  25. package/package/corpus/skills/cratis-screenplay-command-surface/references/enum-numbers.md +1 -1
  26. package/package/corpus/skills/cratis-screenplay-delivery-planning/SKILL.md +1 -1
  27. package/package/corpus/skills/cratis-screenplay-delivery-planning/references/slice-counting.md +1 -1
  28. package/package/corpus/skills/cratis-screenplay-discovery/SKILL.md +1 -1
  29. package/package/corpus/skills/cratis-screenplay-event-modeling/SKILL.md +3 -3
  30. package/package/corpus/skills/cratis-screenplay-event-modeling/references/parsed-not-runnable.md +2 -2
  31. package/package/corpus/skills/cratis-screenplay-legacy-extraction/SKILL.md +1 -1
  32. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/chronicle-observations.md +1 -1
  33. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generate-notes.md +4 -5
  34. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generated-recovery.md +1 -1
  35. package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/prologue-safety.md +1 -1
  36. package/package/corpus/skills/cratis-screenplay-model-authoring/SKILL.md +1 -1
  37. package/package/corpus/skills/cratis-screenplay-model-authoring/references/language-reference.md +4 -4
  38. package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-tools.md +3 -3
  39. package/package/corpus/skills/cratis-screenplay-model-authoring/references/model-notes.md +1 -1
  40. package/package/corpus/skills/cratis-screenplay-model-authoring/references/screen-authoring-workflow.md +1 -1
  41. package/package/corpus/skills/cratis-screenplay-model-review/SKILL.md +1 -1
  42. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/SKILL.md +1 -1
  43. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/stop-or-assume.md +1 -1
  44. package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md +1 -1
  45. package/package/corpus/skills/cratis-screenplay-projections/SKILL.md +1 -1
  46. package/package/corpus/skills/cratis-screenplay-read-surface/SKILL.md +1 -1
  47. package/package/corpus/skills/cratis-screenplay-read-surface/references/provenance.md +2 -2
  48. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/SKILL.md +3 -3
  49. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/drift-and-ledger.md +1 -1
  50. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/gap-fill-handoff.md +2 -2
  51. package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/renderability-gate.md +2 -2
  52. package/package/corpus/skills/cratis-screenplay-scenario-coverage/SKILL.md +2 -2
  53. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/provenance.md +2 -2
  54. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-catalogue.md +1 -1
  55. package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/spec-forms-by-mode.md +5 -5
  56. package/package/corpus/skills/cratis-screenplay-slice-design/SKILL.md +2 -2
  57. package/package/corpus/skills/cratis-screenplay-slice-design/references/worked-example.md +1 -1
  58. package/package/corpus/skills/cratis-screenplay-specifications/SKILL.md +3 -3
  59. package/package/corpus/skills/cratis-screenplay-specifications/references/examples-and-routes.md +2 -2
  60. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/SKILL.md +4 -4
  61. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/boundaries.md +1 -1
  62. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/chronicle-boundaries.md +1 -1
  63. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/consistency-and-concurrency.md +2 -2
  64. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution.md +1 -1
  65. package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/stream-patterns.md +2 -2
  66. package/package/corpus/skills/cratis-screenplay-toolchain/SKILL.md +42 -61
  67. package/package/corpus/skills/cratis-screenplay-toolchain/references/automation-translate-example.md +1 -1
  68. package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet-example.md +7 -9
  69. package/package/corpus/skills/cratis-screenplay-toolchain/references/cheat-sheet.md +15 -18
  70. package/package/corpus/skills/cratis-screenplay-toolchain/references/diagnostics.md +33 -53
  71. package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-example.md +1 -1
  72. package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-subset.md +82 -93
  73. package/package/corpus/skills/cratis-screenplay-toolchain/references/generated-responses-example.md +4 -5
  74. package/package/corpus/skills/cratis-screenplay-toolchain/references/generation-strategies-example.md +1 -2
  75. package/package/corpus/skills/cratis-screenplay-toolchain/references/preferred-syntax.md +5 -9
  76. package/package/corpus/skills/cratis-screenplay-toolchain/references/production-routes-and-filters.md +7 -16
  77. package/package/corpus/skills/cratis-screenplay-toolchain/references/renderable-subset.md +38 -92
  78. package/package/corpus/skills/cratis-screenplay-toolchain/references/screenplay-contract-exceptions.json +4 -11
  79. package/package/corpus/skills/cratis-screenplay-toolchain/references/sources-and-streams.md +14 -19
  80. package/package/corpus/skills/cratis-screenplay-toolchain/references/traps.md +32 -35
  81. package/package/corpus/skills/cratis-screenplay-toolchain/references/verdicts.md +119 -52
  82. package/package/corpus/skills/cratis-screenplay-toolchain/verification.json +18 -24
  83. package/package/corpus/skills/cratis-screenplay-ui-composition/SKILL.md +3 -3
  84. package/package/corpus/skills/cratis-screenplay-ui-composition/references/screen-composition-contract.md +2 -2
  85. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/SKILL.md +110 -167
  86. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/admission.md +74 -170
  87. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/case-tables-and-whole-numbers.md +15 -35
  88. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/choosing-generation.md +4 -6
  89. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/render-example.md +23 -27
  90. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/rendered-application.md +21 -33
  91. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/sandbox-and-specrunner.md +61 -92
  92. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/references/scene-runtime.md +4 -12
  93. package/package/corpus/skills/cratis-stage-rendering-and-sandbox/verification.json +10 -14
  94. package/package.json +1 -1
  95. package/package/corpus/skills/cratis-screenplay-toolchain/references/doc-contradictions.md +0 -72
  96. package/package/corpus/skills/cratis-screenplay-toolchain/references/provenance.md +0 -81
  97. package/package/corpus/skills/cratis-screenplay-toolchain/references/versions.md +0 -341
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: cratis-stage-rendering-and-sandbox
3
- description: "What Cratis Stage and `cratis render` actually do with a Screenplay `.play` model today: the model shape the current Stage admits and refuses (`STAGE-ESM-*`, `PLAY0268` render refusals), what it emits (C# Arc/Chronicle backend, React/Vite scaffold with Arc `CommandForm` shell emission over Scene typed bindings, Debug specifications), managed publication, `--force`, recovery, scoped renders (`--scope`) and `--check`, authored-UI omission/parity checks, the unmanaged `Customizations/` seam, and the `cratis/stage` sandbox and `cratis/stage-specrunner` job. Use when deciding whether Stage can render a model, reading a blocked render, re-rendering safely, checking generated/runtime screen parity, or running the sandbox. Not for: authoring the model (use `cratis-screenplay-model-authoring`) or the render and gap-fill workflow (use `cratis-screenplay-render-and-gap-fill`)."
3
+ description: "What Cratis Stage and `cratis render` do with a Screenplay `.play` model: the model shape Stage admits and refuses (`STAGE-ESM-*`, `PLAY0268` render refusals), what it emits (C# Arc/Chronicle backend, React/Vite scaffold with Arc `CommandForm` shell emission over Scene typed bindings, Debug specifications), managed publication, `--force`, recovery, scoped renders (`--scope`) and `--check`, authored-UI omission/parity checks, the unmanaged `Customizations/` seam, and the `cratis/stage` sandbox and `cratis/stage-specrunner` job. Use when deciding whether Stage can render a model, reading a blocked render, re-rendering safely, checking generated/runtime screen parity, or running the sandbox. Not for: authoring the model (use `cratis-screenplay-model-authoring`) or the render and gap-fill workflow (use `cratis-screenplay-render-and-gap-fill`)."
4
4
  license: MIT
5
5
  ---
6
6
 
@@ -11,62 +11,22 @@ ships a **renderer** (a .NET library, driven from a terminal by `cratis render`)
11
11
  disposable **sandbox** container (`cratis/stage`, started by `cratis run`) and a
12
12
  **specification runner** container (`cratis/stage-specrunner`).
13
13
 
14
- Stage is experimental and its admitted model shape is small. A model it cannot render
15
- exactly produces **no artifacts at all**, never thinner ones. Read the admission rules
16
- before promising that a model can be rendered, and render it to find out: the source
17
- reading in this skill is not a render result.
18
-
19
- Stage 4.92.0 / CLI 3.59.0 do not render ESM v16 stored names. Keep pins;
20
- evidence: toolchain `references/versions.md`.
21
-
22
- Authored UI has its own parity hazard. Historically (Stage 4.24) Stage rendered a default React/Vite
23
- scaffold and did not prove that modeled screens, templates, forms, toolbars,
24
- components, outlets, package icons or routes were implemented. The first fully
25
- passing public browser vector was CLI 3.40.7 with `cratis/stage:4.51.1`: 51
26
- browser assertions passed, none blocked or pending (Cratis/Screenplay#605).
27
- Native command forms, required fields, scoped comments, deep links,
28
- stale-response handling and theme all pass there. On public CLI 3.43.0 (default
29
- `cratis/stage:4.52.0`) an agent-edited table column was rendered, run and seen in
30
- the browser. Guarded Close and guarded double-click run since
31
- Stage 4.65: on CLI 3.53.1 with `cratis/stage:4.73.1` Close shows only while the item is
32
- open and a double click navigates or notifies by row (Cratis/Screenplay#671). `STAGE-SCENE-ACTION-001` and `STAGE-SCENE-INTERACTION-001` still
33
- refuse a guard Stage cannot evaluate: no artifacts. Require a generated plan or artifact entry for every
34
- authored UI construct, and report every unsupported UI directive as a diagnostic.
35
- Silent fallback to a default screen is a failure, not a partial render.
36
-
37
- ## Specification runner exit codes
38
-
39
- `cratis/stage-specrunner` exit `0` means the run completed and the results file was written **even when a specification
40
- failed**: read the outcomes. `1` is a missing or uncompilable input, `2` a missing required
41
- argument or an invalid semantic option.
42
-
14
+ The admitted model shape is deliberately small. A model Stage cannot render exactly
15
+ produces **no artifacts at all**, never thinner ones. Render the model to find out
16
+ whether it is admitted; reading the admission rules is not a render result.
43
17
 
44
- ## Verified product sources
18
+ Requires cratis CLI ≥ 3.57 (`cratis --version`) to render ESM v14 and v15 models; an older CLI refuses newer ESM versions with `CLI-RENDER-004` (or `STAGE-ESM-016` from Stage directly).
45
19
 
46
- Pins/tool split: toolchain `references/versions.md`; CLI 3.57.0 bundle and scaffold
47
- source evidence: `references/admission.md`, `references/rendered-application.md`.
48
- Historical reads: Stage `v4.73.1` (`Source/Rendering.Cratis/**`,
49
- `Documentation/guides/build-renderer-target.md`, `Documentation/reference/render-plans.md`,
50
- `Documentation/docker/**`) and cli `v3.53.1` (`Documentation/reference/screenplay.md`,
51
- `Source/Cli/Commands/Render/**`), not render runs unless labeled *observed*.
52
- The bundled binder trails standalone (toolchain `references/versions.md`).
53
- Stage's scaffold pins Arc, Chronicle, Components, Scene and Fundamentals
54
- ([rendered application](references/rendered-application.md)), not latest releases; never bump managed files.
55
- Scene was re-read at that scaffold tag: `README.md`,
56
- `Source/JavaScript/{model,engine,react,components}/**`.
20
+ ## When to use
57
21
 
58
- Historical executed baselines (history, not current claims): Stage `v4.24.2` and cli
59
- `v3.28.2`/`v3.28.3` (Cratis/cli#253; the example in [render-example.md](references/render-example.md)),
60
- cli 3.40.7 with Stage 4.51.1 (first fully passing browser vector, Cratis/Screenplay#605) and
61
- CLI 3.43.0 (bundled Screenplay 4.127.0) with Stage 4.52.0. UI-profile refusal and rendered recovery
62
- shipped in Cratis/cli#301. Case tables (Stage 4.59.0+) and whole numbers as `long` from ESM v8
63
- (4.61.0+) apply to the current default; the pinned Stage default applies both rules. The Stage
64
- 4.52.0 renderer applies neither new rule.
22
+ - Deciding whether a model can be rendered, or reading a blocked render.
23
+ - Re-rendering safely after the model or a managed file changed.
24
+ - Checking what the generated UI does and does not prove.
25
+ - Running the sandbox or the specification runner.
65
26
 
66
- `[ProtectedDecision]` and `DecisionRead<T>` are available to gap-fill code, not automatically
67
- emitted or protected by Stage; admission and unit-of-work enrollment still matter. Studio 0.144.4 is
68
- released, but production answers every unauthenticated request with 401 and the production UI
69
- automation needs a test-account decision, so Studio production Play proof is not claimed.
27
+ Not for authoring the model (`cratis-screenplay-model-authoring`), the end-to-end
28
+ render and gap-fill workflow (`cratis-screenplay-render-and-gap-fill`), or the C# of a
29
+ generated command or read model (`cratis-arc-command`, `cratis-chronicle-read-model`).
70
30
 
71
31
  ## Model-first rule
72
32
 
@@ -80,28 +40,7 @@ The `.play` model is the source of truth; Stage-managed output is derived from i
80
40
  authorization, validation or personal-data and secret markers to get past a refusal.
81
41
  - Never claim a whole-application result from a subset of the model.
82
42
 
83
- ## Publication and recovery
84
-
85
- Ownership is the destination's **`.cratis-render.json`** manifest (semantic revision,
86
- identity, path and SHA-256 per artifact); there are no in-file markers. Interrupted
87
- commits are journaled in the **`.cratis-render/`** control directory (journal, staging,
88
- backups). Never stage `.cratis-render/` in git; commit the manifest with the output.
89
-
90
- - An unmanaged file at a planned path is refused, even with `--force`.
91
- - A user-modified managed file is refused unless it is still active **and** `--force` is
92
- given; `--force` replaces it. It never overwrites unmanaged files and never deletes a
93
- modified stale file. A stale managed file is removed only if its bytes still match.
94
- - Recovery runs before planning, even when planning then fails. **`recovered: true` in the
95
- result means stop and reconcile**: the receipt does not describe what recovery changed.
96
- - An unchanged re-render writes nothing (`unchanged` equals the artifact count).
97
- - Use exclusive access to the destination; a receipt is a filesystem result, not a Git
98
- commit, and the command creates no branch, commit or PR.
99
- - Drift: `cratis render ... --check` (CLI 3.44.0 or later) is the first probe; exit `6` means
100
- pending changes. Otherwise compare successive manifests' `semanticRevision` for renders with the
101
- same `--name` and inputs. Do not compare the MCP `modelRevision` with the manifest: their
102
- application identities can differ.
103
-
104
- ## Rendering with `cratis render`
43
+ ## Render
105
44
 
106
45
  ```bash
107
46
  cratis render ./model --name Marina --destination ./out
@@ -121,32 +60,17 @@ cratis render --workspace ./application.workspace.json --destination ./out
121
60
  | `--package-set <FILE>` | Approved package set (JSON) of custom runtime packages the `ui profile` may use; the frontend installs exactly these |
122
61
  | `--force` | See "Publication and recovery" |
123
62
 
124
- ### Scoped renders
125
-
126
- `--scope` (CLI 3.49.0 or later) renders an admitted part while other slices wait for hand-written
127
- code or renderer support. The whole model must still compile and bind, so a `PLAY0268`, protected identity/enum,
128
- handler or ESM newer-than-v15 problem anywhere blocks even a scoped render. `PLAN-*` problems in unselected
129
- slices become warnings and `STAGE-ESM-*` refusals in unselected slices do not block. A scoped plan
130
- has no application scaffold or default Scene (with no manifest in the destination the plain scaffold
131
- is added). A dependency in another slice must be rendered first or listed too (`CLI-RENDER-014`);
132
- unknown scope `-011`, ambiguous `-012`, aggregate policy layout `-013` (render the whole application
133
- once first). Unselected managed files are preserved. A scoped result is evidence for that scope only.
134
-
135
63
  Order of events: recover any interrupted earlier publication, compile, bind, build the
136
64
  execution plan, plan the target (Stage admission), validate artifacts, then publish.
137
65
  Exit `0` is a published render, `5` is a refusal with nothing published (diagnostics are
138
- printed), `1` is a missing input. Add `-o json` for the counts and the publication
139
- receipt.
66
+ printed), `1` is a missing input. Add `-o json` for the counts and the publication receipt.
140
67
 
141
68
  Facts that surprise:
142
69
 
143
- - **Binding uses the CLI's bundled Screenplay** (the version listed in `cratis-screenplay-toolchain` `references/versions.md`; the versions differ). A model that binds is not necessarily renderable: CLI 3.57.0 / Stage
144
- 4.89.1 admit ESM v1 to v15, then check each construct. Newer versions report
145
- `CLI-RENDER-004` (direct Stage: `STAGE-ESM-016`). Supported generation strategies,
146
- freshness scopes, responses, equality filters, enum numbers and concept compliance render.
70
+ - **Binding uses the CLI's bundled Screenplay compiler**, which differs from a standalone one. A model that binds is not necessarily renderable: Stage admits ESM v1 to v15, then checks each construct. A newer model reports `CLI-RENDER-004` (direct Stage: `STAGE-ESM-016`). Supported generation strategies, freshness scopes, responses, equality filters, enum numbers and concept compliance render.
147
71
  - **Render never builds, tests or runs** the output. A published render is admission and
148
72
  publication only; build and tests are separate results (see "Verify"). Admission can be
149
- green while a rendered Debug test fails (the example hit this with a query assertion).
73
+ green while a rendered Debug test fails (for example a query assertion on the key).
150
74
  - **Implementation attachments are read from the model root**: the folder, or the single
151
75
  file's parent directory. Use a dedicated model folder. A required body that is missing
152
76
  or changed blocks the render with `STAGE-ESM-020`. A workspace envelope has no
@@ -154,10 +78,46 @@ Facts that surprise:
154
78
  - `cratis render` and `cratis screenplay validate` are different gates: a model can
155
79
  validate and still refuse here.
156
80
 
157
- ## Current admission (Stage 4.89.1)
81
+ ### Scoped renders
82
+
83
+ `--scope` renders an admitted part while other slices wait for hand-written code or
84
+ renderer support. The whole model must still compile and bind, so a `PLAY0268`, protected
85
+ identity/enum, handler or newer-than-v15 problem anywhere blocks even a scoped render.
86
+ `PLAN-*` problems in unselected slices become warnings and `STAGE-ESM-*` refusals in
87
+ unselected slices do not block. A scoped plan has no application scaffold or default Scene
88
+ (with no manifest in the destination the plain scaffold is added). A dependency in another
89
+ slice must be rendered first or listed too (`CLI-RENDER-014`); unknown scope is `-011`,
90
+ ambiguous `-012`, aggregate policy layout `-013` (render the whole application once
91
+ first). Unselected managed files are preserved. A scoped result is evidence for that scope only.
92
+
93
+ ## Publication and recovery
94
+
95
+ Ownership is the destination's **`.cratis-render.json`** manifest (semantic revision,
96
+ identity, path and SHA-256 per artifact); there are no in-file markers. Interrupted
97
+ commits are journaled in the **`.cratis-render/`** control directory (journal, staging,
98
+ backups). Never stage `.cratis-render/` in git; commit the manifest with the output.
99
+
100
+ - An unmanaged file at a planned path is refused, even with `--force`.
101
+ - A user-modified managed file is refused unless it is still active **and** `--force` is
102
+ given; `--force` replaces it. It never overwrites unmanaged files and never deletes a
103
+ modified stale file. A stale managed file is removed only if its bytes still match.
104
+ - Recovery runs before planning, even when planning then fails. **`recovered: true` in the
105
+ result means stop and reconcile**: the receipt does not describe what recovery changed.
106
+ - An unchanged re-render writes nothing (`unchanged` equals the artifact count).
107
+ - Use exclusive access to the destination; a receipt is a filesystem result, not a Git
108
+ commit, and the command creates no branch, commit or PR.
109
+ - Drift: `cratis render ... --check` is the first probe; exit `6` means pending changes.
110
+ Otherwise compare successive manifests' `semanticRevision` for renders with the same
111
+ `--name` and inputs. Do not compare the MCP `modelRevision` with the manifest: their
112
+ application identities can differ.
113
+
114
+ A modified managed file reports `Managed artifact 'Program.cs' was modified by the user; pass --force to replace it.`
115
+ Find out why it was edited, move the intent into the model or `Customizations/`, then
116
+ re-render; use `--force` only to discard the edit on purpose.
158
117
 
159
- Source reading, not a render run. One blocker publishes nothing. Codes/limits/sources: [references/admission.md](references/admission.md);
160
- ledger: `cratis-screenplay-toolchain/references/renderable-subset.md`.
118
+ ## Admission
119
+
120
+ One blocker publishes nothing. Codes, limits and fixes: [references/admission.md](references/admission.md).
161
121
 
162
122
  - **Renders:** concepts/types/collections/optionals; portable StateChange and StateView slices,
163
123
  flat/scoped projections, pure reducers and reducer `from` filters; keyed optional snapshots,
@@ -169,7 +129,7 @@ ledger: `cratis-screenplay-toolchain/references/renderable-subset.md`.
169
129
  - **Refused:** Translate/captures, non-event triggers, opaque bodies and clock specs (`STAGE-ESM-024`);
170
130
  mixed effects (`STAGE-ESM-037`, redelivery duplicates events); unsupported reaction mappings (`-039`),
171
131
  protected identities/enums (`-040`), non-text secrets (`-041`); generated types/results (`-028`/`-038`);
172
- appends beyond single-hop/cascade specs (`-011`), absence (`-027`), evolution (`-026`), public/foreign events
132
+ appends beyond single-hop/cascade specs (`-011`), absence (`-027`), evolution (`STAGE-ESM-026`), public/foreign events
173
133
  (`-032`/`-033`), claim-reading/opaque `runs as` gates (`-034`), legacy filters (`-035`), production
174
134
  overrides (`-036`), code validation (`-005`), snapshot lists/DateTime filters (`-010`), conditional
175
135
  productions, composite projection keys and `all`. Through v15 is construct admission.
@@ -178,61 +138,49 @@ ledger: `cratis-screenplay-toolchain/references/renderable-subset.md`.
178
138
  compliance and subject lineage. Never drop protection.
179
139
 
180
140
  A refusal is not a licence to weaken the model: drop no specification, event generation or
181
- protection to get a render; keep the model, record the capability gap and gap-fill. The 4.24-era
182
- admission (ESM v1 to v4, keyed optional queries only) is kept as history in `references/admission.md`.
141
+ protection to get a render; keep the model, record the capability gap and gap-fill.
183
142
 
184
143
  **Descriptions and documentation render only as XML documentation comments** (`<summary>`,
185
- `<remarks>`; Stage#178 closed), never as validation, authorization or behavior, so a rule that exists
186
- only in prose is not enforced. A documentation edit changes managed-file hashes (a `--check` exit
144
+ `<remarks>`), never as validation, authorization or behavior, so a rule that exists only in
145
+ prose is not enforced. A documentation edit changes managed-file hashes (a `--check` exit
187
146
  `6`), and characters invalid in XML block rendering with `CLI-RENDER-005`.
188
147
 
189
- ## Choosing a strategy
190
-
191
- Read [shop strategy choices](references/choosing-generation.md) before rendering.
192
-
193
- ## When not to
194
-
195
- That reference separates v15 scopes from future Arc freshness and unshipped context/secrets.
148
+ Generated identities: read [shop strategy choices](references/choosing-generation.md) before
149
+ rendering a model with generated values. Case tables and whole numbers:
150
+ [case tables and whole numbers](references/case-tables-and-whole-numbers.md).
151
+ `[ProtectedDecision]` and `DecisionRead<T>` are available to gap-fill code, not
152
+ automatically emitted or protected by Stage; admission and unit-of-work enrollment still matter.
196
153
 
197
154
  ## What it emits
198
155
 
199
- At application scope the plan holds the scaffold plus the modeled artifacts, for the
200
- example 30 files on cratis 3.28.2 (56 observed on 3.53.1): a `.csproj` and `.slnx`, `Program.cs`, `appsettings.json`,
201
- `docker-compose.yml`, the Directory props files, a policy registration and generated
202
- policies, `Common/<Concept>.cs`, one `<Module>/<Feature>/<Slice>/` folder per slice with
203
- the `[Command]` record and `Handle()`, the `[EventType]` event, the validator and the
204
- `[ReadModel]` with its query, `scene.json`, and a React/Vite frontend scaffold
205
- (`.frontend/`, `package.json`, `tsconfig.json`, `.gitignore`). Per-file detail, the
206
- scaffold pins and the `Customizations/` contract are in
207
- [references/rendered-application.md](references/rendered-application.md).
208
- Read `references/rendered-application.md` when inspecting scaffold pins, managed-file ownership, or implementing a `Customizations/` extension.
209
- Read [Scene runtime](references/scene-runtime.md) when identifying the generated UI's
210
- package ids, host capabilities or the boundary from hand-built Components pages.
156
+ At application scope the plan holds the scaffold plus the modeled artifacts: a `.csproj`
157
+ and `.slnx`, `Program.cs`, `appsettings.json`, `docker-compose.yml`, the Directory props
158
+ files, a policy registration and generated policies, `Common/<Concept>.cs`, one
159
+ `<Module>/<Feature>/<Slice>/` folder per slice with the `[Command]` record and `Handle()`,
160
+ the `[EventType]` event, the validator and the `[ReadModel]` with its query, `scene.json`,
161
+ and a React/Vite frontend scaffold (`.frontend/`, `package.json`, `tsconfig.json`,
162
+ `.gitignore`). Per-file detail, the scaffold's dependency set and the `Customizations/`
163
+ contract: [references/rendered-application.md](references/rendered-application.md). Scene
164
+ package ids, host capabilities and the boundary from hand-built Components pages:
165
+ [references/scene-runtime.md](references/scene-runtime.md). A complete renderable model:
166
+ [references/render-example.md](references/render-example.md).
211
167
 
212
168
  Modeled specifications become xunit classes compiled in **Debug only**
213
169
  (`IsTestProject` when Debug): a command spec `when_<snake>` in namespace
214
170
  `<slice namespace>.when_<snake>` (so `when_x.when_x`), queries `when_<snake>_is_queried`,
215
- read models `when_<snake>_is_projected`.
216
-
217
- Stage 4.59.0+ expands a case table to effective `<Specification>_<Case>` names
218
- and one generated class per case; normalized path collisions refuse the plan
219
- with `STAGE-CRATIS-004`. Failed case results include the case and effective fixtures.
220
- Stage 4.61.0+ renders whole numbers as `long` from ESM v8, retains `int` below
221
- v8 and refuses out-of-`int` literals there with `STAGE-ESM-031`. The pinned Stage default applies both rules;
222
- pins: toolchain `references/versions.md`. Previous CLI 3.46.1's
223
- Stage 4.52.0 renderer applies neither new rule. Read
224
- [case tables and whole numbers](references/case-tables-and-whole-numbers.md)
225
- for complete examples, stored-schema consequences and the sandbox-only `--tag` override.
226
-
227
- For UI, record what the generated output claims separately from what the model
228
- authored. Before CLI 3.40.7 the generated scaffold was not screen parity evidence.
229
- On public CLI 3.43.0 / `cratis/stage:4.52.0` the canonical corpus publishes,
230
- `scene.json` contains Arc `commandForm` components, `src/bindings.ts` registers
231
- the modeled commands and queries, and the browser acceptance run passes. That is
232
- not Studio production proof. Require an explicit plan, manifest entry or
233
- generated artifact for each
234
- screen/template/form/toolbar/component/outlet/route/package-icon use, or a
235
- blocking diagnostic explaining why it was not generated.
171
+ read models `when_<snake>_is_projected`. A case table expands to one class per case
172
+ (`<Specification>_<Case>`).
173
+
174
+ ### UI parity
175
+
176
+ The scaffold emits Arc `CommandForm` shells over Scene typed bindings, with `scene.json`
177
+ and `src/bindings.ts` registering the modeled commands and queries. Record what the
178
+ generated output claims separately from what the model authored, and claim UI fidelity
179
+ only from a browser run. Require a generated plan entry, manifest entry or artifact for
180
+ each screen, template, form, toolbar, component, outlet, route and package-icon use, or a
181
+ blocking diagnostic explaining why it was not generated. `STAGE-SCENE-ACTION-001` and
182
+ `STAGE-SCENE-INTERACTION-001` refuse a guard Stage cannot evaluate: no artifacts.
183
+ Silent fallback to a default screen is a failure, not a partial render.
236
184
 
237
185
  ## Sandbox and specification runner
238
186
 
@@ -241,17 +189,27 @@ API on `9090`, Chronicle Workbench on `https://localhost:35000`. It is a **parti
241
189
  disposable runtime**, not a generated application. The default engine appends modeled
242
190
  `produces` facts and echoes the payload but enforces no modeled validation or
243
191
  authorization and no query authorization; `Stage__Runtime__Engine=semantic` opts in to
244
- an engine that does, and refuses what it cannot execute (HTTP 501). At Stage 4.73.1 the default
245
- engine also refuses routed models (`STAGE-ESM-030`) and the structural runner is deprecated (details:
246
- the sandbox reference). Callers are built
247
- from unsigned headers, so authorization there is not a security boundary.
192
+ an engine that does, and refuses what it cannot execute (HTTP 501). The default engine
193
+ also refuses routed models (`STAGE-ESM-030`). Callers are built from unsigned headers, so
194
+ authorization there is not a security boundary.
248
195
 
249
196
  `cratis/stage-specrunner` checks modeled specifications and writes a results file. The
250
197
  default `structural` engine is deprecated and model-level only; `--engine semantic`
251
198
  executes admitted specs through Arc's in-memory pipeline and reports `Passed`, `Failed`,
252
- `Unsupported` or `Cancelled`. A green result is Stage semantic-engine evidence: not V4 and not a rendered Debug test run. Commands,
253
- the semantic report schema and limits: [references/sandbox-and-specrunner.md](references/sandbox-and-specrunner.md).
254
- Read `references/sandbox-and-specrunner.md` before launching either container or interpreting specification-runner outcomes.
199
+ `Unsupported` or `Cancelled`. A green result is Stage semantic-engine evidence: not V4 and
200
+ not a rendered Debug test run. Commands, the report schema and limits:
201
+ [references/sandbox-and-specrunner.md](references/sandbox-and-specrunner.md).
202
+
203
+ Specification runner exit codes: `0` means the run completed and the results file was
204
+ written **even when a specification failed**, so read the outcomes; `1` is a missing or
205
+ uncompilable input; `2` a missing required argument or an invalid semantic option.
206
+
207
+ ## Legacy direct-write rendering
208
+
209
+ The syntax-based `IRenderer` and the optional `Cratis.Stage.Rendering.Cratis.Scaffolding`
210
+ package write directly to disk, with no managed staging and no safe stale-file removal; a
211
+ failure can leave the target unsafe and incomplete. Use `cratis render` (journaled,
212
+ recoverable publication) instead.
255
213
 
256
214
  ## Verify
257
215
 
@@ -266,8 +224,8 @@ Read `references/sandbox-and-specrunner.md` before launching either container or
266
224
  file. The fix is an intent-preserving model change or a recorded gap, never an edit of
267
225
  managed output and never a weakened model.
268
226
  - No file under `.cratis-render/` is staged; managed files carry no local edits.
269
- - No claim that Stage reviewed, staged or approved anything; its plan is deterministic
270
- (same input, same bytes and hashes), which is not a review.
227
+ - Stage's plan is deterministic (same input, same bytes and hashes); that is not a review,
228
+ and Stage never reviews, stages or approves anything.
271
229
  - Sandbox expectations account for unenforced validation, authorization and query
272
230
  authorization on the default engine.
273
231
  - Runtime screen smoke coverage uses the same model root or workspace export as
@@ -279,25 +237,10 @@ Read `references/sandbox-and-specrunner.md` before launching either container or
279
237
  - Writing or checking the `.play` model: `cratis-screenplay-model-authoring` (compiler and
280
238
  MCP), `cratis-screenplay-event-modeling` (method), and the per-surface
281
239
  `cratis-screenplay-*` skills.
282
- - Which tool says what, versions and diagnostics: `cratis-screenplay-toolchain`.
283
- - Running the render workflow end to end, gap-fill and the field ledger:
284
- `cratis-screenplay-render-and-gap-fill`.
240
+ - Which tool says what, and diagnostics: `cratis-screenplay-toolchain`.
241
+ - Running the render workflow end to end and gap-fill: `cratis-screenplay-render-and-gap-fill`.
285
242
  - Understanding the generated command, validator or read model as C#: `cratis-arc-command`
286
243
  and `cratis-chronicle-read-model`; checking hand-written code against its slice:
287
244
  `cratis-application-slice-conformance`.
288
245
  - Inspecting the Chronicle store the sandbox writes into: `cratis-chronicle-cli-operations`
289
246
  and `cratis-chronicle-web-workbench`.
290
-
291
- ## Legacy direct-write rendering
292
-
293
- The syntax-based `IRenderer` and the optional `Cratis.Stage.Rendering.Cratis.Scaffolding`
294
- package write directly to disk, with no managed staging and no safe stale-file removal; a
295
- failure can leave the target unsafe and incomplete. They are legacy compatibility only.
296
- Use `cratis render` (journaled, recoverable publication) instead.
297
-
298
- ## Lineage
299
-
300
- Rewritten for #493. The earlier version described Stage 3.15.1 (no CLI, eight-file
301
- backend scaffold, `not empty`-only validation, no frontend, Arc 22.3.0); each claim was
302
- re-verified at Stage 4.24.0 and cli 3.27.1 and replaced, then re-run on Stage 4.24.1 and cli 3.28.2 and on Stage 4.24.2 and cli 3.28.3 (an evolved event reports `STAGE-ESM-026`). See
303
- [references/admission.md](references/admission.md) for source disagreements.