@cratis/pi 7.50.0 → 7.51.1
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.
- package/package/corpus/harnesses/copilot/instructions/authoring-skills.instructions.md +93 -0
- package/package/corpus/harnesses/copilot/instructions/profiles.instructions.md +4 -0
- package/package/corpus/prompts/review-skill.prompt.md +6 -8
- package/package/corpus/rules/authoring-skills.md +92 -0
- package/package/corpus/rules/general.md +1 -0
- package/package/corpus/rules/profiles.md +4 -0
- package/package/corpus/skills/cratis-application-react-specifications/SKILL.md +1 -1
- package/package/corpus/skills/cratis-application-slice-conformance/SKILL.md +8 -7
- package/package/corpus/skills/cratis-application-slice-conformance/references/checklists.md +1 -1
- package/package/corpus/skills/cratis-application-slice-conformance/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-application-slice-specifications/SKILL.md +15 -19
- package/package/corpus/skills/cratis-application-slice-specifications/references/provenance.md +1 -1
- package/package/corpus/skills/cratis-application-slice-specifications/references/query-and-decision-scenarios.md +8 -6
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/SKILL.md +23 -29
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/authentication.md +7 -7
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/authorization.md +34 -32
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/authproxy.md +1 -1
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/frontend.md +2 -2
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/local-development.md +3 -3
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/observable-emission-guards.md +8 -6
- package/package/corpus/skills/cratis-arc-authentication-authorization-and-identity/references/tenancy.md +3 -3
- package/package/corpus/skills/cratis-arc-command/SKILL.md +23 -25
- package/package/corpus/skills/cratis-arc-command/references/command-result.md +1 -1
- package/package/corpus/skills/cratis-arc-command/references/decisions-and-routing.md +9 -9
- package/package/corpus/skills/cratis-arc-command/references/generated-values.md +11 -12
- package/package/corpus/skills/cratis-arc-command/references/handler-shapes.md +4 -4
- package/package/corpus/skills/cratis-arc-command/references/proxy-generation.md +3 -3
- package/package/corpus/skills/cratis-arc-command/references/read-model-injection.md +1 -3
- package/package/corpus/skills/cratis-arc-command/references/shop-generation.md +11 -14
- package/package/corpus/skills/cratis-arc-command-execution/LICENSE +6 -0
- package/package/corpus/skills/cratis-arc-command-execution/SKILL.md +17 -19
- package/package/corpus/skills/cratis-arc-command-kotlin/SKILL.md +8 -7
- package/package/corpus/skills/cratis-arc-command-kotlin/references/read-model-naming.md +2 -2
- package/package/corpus/skills/cratis-arc-command-operation/SKILL.md +14 -15
- package/package/corpus/skills/cratis-arc-command-operation/references/execution-and-recovery.md +2 -2
- package/package/corpus/skills/cratis-arc-command-operation/references/testing.md +7 -8
- package/package/corpus/skills/cratis-arc-command-typescript/SKILL.md +14 -11
- package/package/corpus/skills/cratis-arc-command-typescript/references/chronicle-events.md +7 -7
- package/package/corpus/skills/cratis-arc-command-typescript/references/command-operations.md +4 -4
- package/package/corpus/skills/cratis-arc-command-typescript/references/hosting-and-storage.md +11 -7
- package/package/corpus/skills/cratis-arc-command-typescript/references/identity-and-introspection.md +4 -2
- package/package/corpus/skills/cratis-arc-command-typescript/references/observability-and-host-scopes.md +2 -2
- package/package/corpus/skills/cratis-arc-command-typescript/references/proxy-generation.md +3 -3
- package/package/corpus/skills/cratis-arc-command-typescript/references/slice-layout.md +1 -1
- package/package/corpus/skills/cratis-arc-command-typescript/verification.json +2 -2
- package/package/corpus/skills/cratis-arc-command-validation/SKILL.md +10 -14
- package/package/corpus/skills/cratis-arc-ef-core-migration/LICENSE +6 -0
- package/package/corpus/skills/cratis-arc-ef-core-migration/SKILL.md +9 -10
- package/package/corpus/skills/cratis-arc-go/SKILL.md +14 -15
- package/package/corpus/skills/cratis-arc-go/references/queries.md +2 -2
- package/package/corpus/skills/cratis-arc-hosting/SKILL.md +8 -8
- package/package/corpus/skills/cratis-arc-hosting/references/integrations-and-publish.md +11 -11
- package/package/corpus/skills/cratis-arc-identity-and-tenancy-kotlin/SKILL.md +3 -3
- package/package/corpus/skills/cratis-arc-observable-query-http/SKILL.md +13 -13
- package/package/corpus/skills/cratis-arc-observable-query-http/verification.json +1 -1
- package/package/corpus/skills/cratis-arc-query-kotlin/SKILL.md +2 -3
- package/package/corpus/skills/cratis-arc-query-paging/SKILL.md +11 -14
- package/package/corpus/skills/cratis-arc-query-typescript/SKILL.md +3 -3
- package/package/corpus/skills/cratis-arc-query-typescript/references/storage-observation-and-compliance.md +2 -2
- package/package/corpus/skills/cratis-arc-react-page/SKILL.md +10 -14
- package/package/corpus/skills/cratis-arc-react-page/references/dialogs.md +4 -2
- package/package/corpus/skills/cratis-arc-react-page/references/from-screenplay.md +7 -7
- package/package/corpus/skills/cratis-arc-react-page/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-arc-react-page/references/queries-and-commands.md +1 -1
- package/package/corpus/skills/cratis-arc-react-page/verification.json +0 -2
- package/package/corpus/skills/cratis-arc-spring-data-kotlin/SKILL.md +3 -3
- package/package/corpus/skills/cratis-arc-testing-kotlin/SKILL.md +3 -3
- package/package/corpus/skills/cratis-arc-validation-kotlin/SKILL.md +1 -2
- package/package/corpus/skills/cratis-arc-validation-typescript/SKILL.md +4 -4
- package/package/corpus/skills/cratis-chronicle-cli-operations/SKILL.md +19 -22
- package/package/corpus/skills/cratis-chronicle-cli-operations/references/command-effects.md +10 -10
- package/package/corpus/skills/cratis-chronicle-client-dotnet/SKILL.md +36 -36
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/additional-surfaces.md +4 -2
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/client-construction.md +1 -1
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/compatibility-check.md +13 -13
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/discovery.md +10 -10
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/hosting.md +10 -10
- package/package/corpus/skills/cratis-chronicle-client-dotnet/references/pinned-generation-delivery.md +7 -5
- package/package/corpus/skills/cratis-chronicle-client-elixir/SKILL.md +59 -64
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/append-api.md +17 -17
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/compliance.md +5 -3
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/connections.md +15 -11
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/event-sources.md +3 -1
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/pitfalls.md +4 -4
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/projections.md +8 -4
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/upgrading.md +19 -19
- package/package/corpus/skills/cratis-chronicle-client-elixir/references/variants.md +3 -8
- package/package/corpus/skills/cratis-chronicle-client-elixir/verification.json +2 -2
- package/package/corpus/skills/cratis-chronicle-client-go/SKILL.md +16 -18
- package/package/corpus/skills/cratis-chronicle-client-go/references/projections.md +2 -2
- package/package/corpus/skills/cratis-chronicle-client-kotlin/SKILL.md +61 -58
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/connection-lifecycle.md +9 -10
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/discovery-and-registration.md +6 -6
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/event-sources.md +4 -2
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/java-api.md +4 -4
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/options.md +1 -1
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/spring-boot.md +24 -24
- package/package/corpus/skills/cratis-chronicle-client-kotlin/references/variants.md +6 -5
- package/package/corpus/skills/cratis-chronicle-client-typescript/SKILL.md +26 -20
- package/package/corpus/skills/cratis-chronicle-client-typescript/references/read-models-and-projections.md +4 -4
- package/package/corpus/skills/cratis-chronicle-client-typescript/references/testing.md +1 -1
- package/package/corpus/skills/cratis-chronicle-client-typescript/references/variants.md +4 -3
- package/package/corpus/skills/cratis-chronicle-client-typescript/verification.json +2 -2
- package/package/corpus/skills/cratis-chronicle-compliance/SKILL.md +9 -9
- package/package/corpus/skills/cratis-chronicle-decision-reads/SKILL.md +11 -10
- package/package/corpus/skills/cratis-chronicle-decision-reads/references/admission-and-ownership.md +1 -1
- package/package/corpus/skills/cratis-chronicle-decision-reads/references/choosing-how-a-rule-holds.md +5 -6
- package/package/corpus/skills/cratis-chronicle-event-constraints/SKILL.md +7 -7
- package/package/corpus/skills/cratis-chronicle-event-constraints/references/closing-streams.md +1 -1
- package/package/corpus/skills/cratis-chronicle-event-specifications/SKILL.md +6 -6
- package/package/corpus/skills/cratis-chronicle-event-type-migration/SKILL.md +12 -10
- package/package/corpus/skills/cratis-chronicle-event-type-migration/references/pinned-generations.md +2 -3
- package/package/corpus/skills/cratis-chronicle-hosting/SKILL.md +7 -7
- package/package/corpus/skills/cratis-chronicle-hosting/references/operations.md +5 -5
- package/package/corpus/skills/cratis-chronicle-mcp-inspection/SKILL.md +6 -6
- package/package/corpus/skills/cratis-chronicle-mcp-inspection/references/blocked-tools.md +5 -5
- package/package/corpus/skills/cratis-chronicle-mcp-inspection/references/deployment.md +9 -10
- package/package/corpus/skills/cratis-chronicle-mcp-inspection/references/observational-tools.md +29 -29
- package/package/corpus/skills/cratis-chronicle-multi-tenancy/SKILL.md +9 -9
- package/package/corpus/skills/cratis-chronicle-projection/SKILL.md +13 -14
- package/package/corpus/skills/cratis-chronicle-projection/references/fluent-builder.md +3 -5
- package/package/corpus/skills/cratis-chronicle-projection/references/model-bound-attributes.md +2 -4
- package/package/corpus/skills/cratis-chronicle-projection/references/variants.md +1 -3
- package/package/corpus/skills/cratis-chronicle-reactor/SKILL.md +15 -19
- package/package/corpus/skills/cratis-chronicle-reactor/references/provenance.md +1 -1
- package/package/corpus/skills/cratis-chronicle-reactor/references/specifications.md +10 -8
- package/package/corpus/skills/cratis-chronicle-read-model/SKILL.md +16 -15
- package/package/corpus/skills/cratis-chronicle-read-model/references/queries.md +8 -8
- package/package/corpus/skills/cratis-chronicle-read-model-specifications/SKILL.md +7 -7
- package/package/corpus/skills/cratis-chronicle-read-model-specifications/references/provenance.md +3 -3
- package/package/corpus/skills/cratis-chronicle-reducer/SKILL.md +14 -13
- package/package/corpus/skills/cratis-chronicle-web-workbench/SKILL.md +11 -12
- package/package/corpus/skills/cratis-cli-terminal-workbench/SKILL.md +6 -6
- package/package/corpus/skills/cratis-code-review/SKILL.md +13 -17
- package/package/corpus/skills/cratis-components-accessibility/SKILL.md +3 -3
- package/package/corpus/skills/cratis-components-common-controls/SKILL.md +15 -15
- package/package/corpus/skills/cratis-components-data-surfaces/SKILL.md +29 -29
- package/package/corpus/skills/cratis-components-schema-editor/SKILL.md +4 -4
- package/package/corpus/skills/cratis-components-schema-editor/references/tree-layout.md +1 -1
- package/package/corpus/skills/cratis-components-stepper-command-dialog/SKILL.md +6 -6
- package/package/corpus/skills/cratis-components-styling/LICENSE +6 -0
- package/package/corpus/skills/cratis-components-styling/SKILL.md +5 -4
- package/package/corpus/skills/cratis-components-toolbar/SKILL.md +5 -5
- package/package/corpus/skills/cratis-developer-marketing/SKILL.md +2 -2
- package/package/corpus/skills/cratis-engineering-csharp-conventions/SKILL.md +3 -3
- package/package/corpus/skills/cratis-engineering-csharp-conventions/references/exceptions-logging-and-di.md +1 -1
- package/package/corpus/skills/cratis-engineering-effect-boundaries/references/failure-archetypes.md +4 -4
- package/package/corpus/skills/cratis-fundamentals-concept/SKILL.md +19 -24
- package/package/corpus/skills/cratis-fundamentals-concept/references/shop-generation.md +10 -10
- package/package/corpus/skills/cratis-fundamentals-concept/references/typescript-concepts.md +8 -8
- package/package/corpus/skills/cratis-fundamentals-concept-go/SKILL.md +10 -11
- package/package/corpus/skills/cratis-fundamentals-telemetry/SKILL.md +18 -18
- package/package/corpus/skills/cratis-fundamentals-telemetry/verification.json +1 -1
- package/package/corpus/skills/cratis-fundamentals-type-discovery/SKILL.md +4 -4
- package/package/corpus/skills/cratis-lens-browser-extension/SKILL.md +19 -19
- package/package/corpus/skills/cratis-orleans-jobs/SKILL.md +27 -27
- package/package/corpus/skills/cratis-orleans-jobs/references/state-machines.md +12 -12
- package/package/corpus/skills/cratis-performance-review/SKILL.md +8 -10
- package/package/corpus/skills/cratis-release-notes/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/SKILL.md +30 -28
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/automation-patterns.md +8 -8
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/cases-to-specify.md +4 -4
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/effects-and-idempotency.md +3 -1
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/provenance.md +1 -14
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/public-events-and-direction.md +6 -4
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/realization-and-gap-fill.md +5 -6
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/todo-list-example.md +11 -12
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/translate-example.md +3 -3
- package/package/corpus/skills/cratis-screenplay-automations-and-translations/references/translation-patterns.md +2 -2
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/SKILL.md +22 -20
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/complete-examples.md +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/invocation-identity.md +9 -10
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/refusals-and-redelivery.md +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/specifying-triggers-and-clock.md +3 -4
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/verification.json +0 -4
- package/package/corpus/skills/cratis-screenplay-command-surface/SKILL.md +16 -15
- package/package/corpus/skills/cratis-screenplay-command-surface/references/compliance.md +17 -17
- package/package/corpus/skills/cratis-screenplay-command-surface/references/context.md +8 -8
- package/package/corpus/skills/cratis-screenplay-command-surface/references/enum-numbers.md +8 -12
- package/package/corpus/skills/cratis-screenplay-command-surface/references/generated-values-and-responses.md +31 -29
- package/package/corpus/skills/cratis-screenplay-command-surface/references/inline-events.md +5 -5
- package/package/corpus/skills/cratis-screenplay-command-surface/references/operations.md +2 -2
- package/package/corpus/skills/cratis-screenplay-command-surface/references/policy-persona-seed.md +3 -3
- package/package/corpus/skills/cratis-screenplay-command-surface/references/shop-generation.md +10 -10
- package/package/corpus/skills/cratis-screenplay-command-surface/references/validate-rules.md +9 -7
- package/package/corpus/skills/cratis-screenplay-command-surface/verification.json +2 -5
- package/package/corpus/skills/cratis-screenplay-discovery/SKILL.md +14 -15
- package/package/corpus/skills/cratis-screenplay-discovery/references/facilitation.md +1 -1
- package/package/corpus/skills/cratis-screenplay-discovery/references/personas-and-causes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-discovery/references/plotting-and-handoff.md +2 -2
- package/package/corpus/skills/cratis-screenplay-discovery/references/provenance.md +3 -3
- package/package/corpus/skills/cratis-screenplay-event-modeling/SKILL.md +13 -17
- package/package/corpus/skills/cratis-screenplay-event-modeling/references/naming-primitives.md +2 -2
- package/package/corpus/skills/cratis-screenplay-event-modeling/references/nine-steps.md +2 -2
- package/package/corpus/skills/cratis-screenplay-event-modeling/references/parsed-not-runnable.md +11 -12
- package/package/corpus/skills/cratis-screenplay-event-modeling/references/provenance.md +2 -2
- package/package/corpus/skills/cratis-screenplay-event-modeling/verification.json +0 -4
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/evidence-table-template.md +4 -4
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generate-notes.md +34 -21
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/generated-recovery.md +18 -12
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/prologue-safety.md +7 -7
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/provenance.md +1 -1
- package/package/corpus/skills/cratis-screenplay-legacy-extraction/references/rule-modeling.md +4 -4
- package/package/corpus/skills/cratis-screenplay-model-authoring/SKILL.md +24 -29
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/choosing-generation.md +1 -2
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/language-reference.md +44 -51
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-loop.md +31 -36
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-tools.md +56 -63
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/model-notes.md +11 -10
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/property-links.md +15 -15
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/release-baseline.md +25 -21
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/screen-authoring-workflow.md +16 -31
- package/package/corpus/skills/cratis-screenplay-model-authoring/verification.json +5 -4
- package/package/corpus/skills/cratis-screenplay-model-review/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-review/references/checklist.md +3 -3
- package/package/corpus/skills/cratis-screenplay-model-review/references/provenance.md +3 -4
- package/package/corpus/skills/cratis-screenplay-model-review/references/public-keys-and-routes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-model-review/references/report-template.md +7 -5
- package/package/corpus/skills/cratis-screenplay-model-review/references/worked-example.md +2 -2
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/SKILL.md +11 -12
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/code-reading-and-tokens.md +2 -2
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/identity-and-edits.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/opt-in.md +8 -10
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/provenance.md +6 -6
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/stop-or-assume.md +2 -2
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/vocabulary-map.md +3 -3
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/worked-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-projections/SKILL.md +11 -22
- package/package/corpus/skills/cratis-screenplay-projections/references/pdl-grammar.md +1 -1
- package/package/corpus/skills/cratis-screenplay-projections/verification.json +0 -1
- package/package/corpus/skills/cratis-screenplay-read-surface/SKILL.md +16 -29
- package/package/corpus/skills/cratis-screenplay-read-surface/references/equality-filters.md +14 -18
- package/package/corpus/skills/cratis-screenplay-read-surface/references/guarded-actions.md +5 -7
- package/package/corpus/skills/cratis-screenplay-read-surface/references/named-keys.md +6 -6
- package/package/corpus/skills/cratis-screenplay-read-surface/references/provenance.md +1 -1
- package/package/corpus/skills/cratis-screenplay-read-surface/verification.json +1 -2
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/SKILL.md +18 -19
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/delivery-protocol.md +2 -2
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/gap-fill-handoff.md +6 -6
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/provenance.md +4 -4
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/renderability-gate.md +5 -6
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/references/worked-example.md +2 -3
- package/package/corpus/skills/cratis-screenplay-render-and-gap-fill/verification.json +1 -1
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/SKILL.md +13 -15
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/invoicing-dues-design.md +1 -1
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/invoicing-dues-example.md +2 -2
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/provenance.md +4 -6
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-catalogue.md +4 -4
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/scenario-examples.md +3 -3
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/spec-forms-by-mode.md +11 -9
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/references/view-and-story-specs.md +5 -5
- package/package/corpus/skills/cratis-screenplay-scenario-coverage/verification.json +0 -1
- package/package/corpus/skills/cratis-screenplay-slice-design/SKILL.md +12 -14
- package/package/corpus/skills/cratis-screenplay-slice-design/references/read-model-design.md +4 -4
- package/package/corpus/skills/cratis-screenplay-slice-design/references/rule-layers.md +6 -4
- package/package/corpus/skills/cratis-screenplay-slice-design/references/slicing.md +4 -2
- package/package/corpus/skills/cratis-screenplay-slice-design/references/worked-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-specifications/SKILL.md +37 -40
- package/package/corpus/skills/cratis-screenplay-specifications/references/actions-beyond-commands.md +10 -15
- package/package/corpus/skills/cratis-screenplay-specifications/references/child-ordering.md +14 -12
- package/package/corpus/skills/cratis-screenplay-specifications/references/concept-rules.md +1 -1
- package/package/corpus/skills/cratis-screenplay-specifications/references/examples-and-routes.md +9 -10
- package/package/corpus/skills/cratis-screenplay-specifications/references/generated-fixtures.md +5 -6
- package/package/corpus/skills/cratis-screenplay-specifications/references/reactions-and-cascades.md +8 -9
- package/package/corpus/skills/cratis-screenplay-specifications/references/source-notes.md +13 -16
- package/package/corpus/skills/cratis-screenplay-specifications/references/whitespace-rules.md +15 -13
- package/package/corpus/skills/cratis-screenplay-specifications/verification.json +4 -9
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/SKILL.md +29 -29
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/chronicle-boundaries.md +18 -15
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/consistency-and-concurrency.md +16 -15
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/evolution.md +19 -17
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/provenance.md +3 -3
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/stream-patterns.md +1 -1
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/references/streams-example.md +2 -2
- package/package/corpus/skills/cratis-screenplay-streams-and-consistency/verification.json +2 -3
- package/package/corpus/skills/cratis-screenplay-toolchain/references/executable-subset.md +2 -0
- package/package/corpus/skills/cratis-screenplay-toolchain/references/pdl-example.md +1 -1
- package/package/corpus/skills/cratis-screenplay-toolchain/references/screenplay-contract-exceptions.json +0 -28
- package/package/corpus/skills/cratis-screenplay-ui-composition/SKILL.md +21 -26
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/guarded-interactions.md +3 -3
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/provenance.md +1 -1
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/response-continuations.md +10 -10
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/screen-composition-contract.md +23 -30
- package/package/corpus/skills/cratis-screenplay-ui-composition/references/worked-flow.md +4 -5
- package/package/corpus/skills/cratis-screenplay-ui-composition/verification.json +1 -5
- package/package/corpus/skills/cratis-security-review/SKILL.md +8 -10
- package/package/corpus/skills/cratis-security-review/references/arc-boundaries.md +18 -16
- package/package/corpus/skills/cratis-specification-by-example/SKILL.md +1 -1
- package/package/corpus/skills/cratis-specifications-csharp/SKILL.md +26 -29
- package/package/corpus/skills/cratis-specifications-csharp/references/application-scenarios.md +8 -8
- package/package/corpus/skills/cratis-specifications-csharp/references/csharp-patterns.md +2 -2
- package/package/corpus/skills/cratis-specifications-csharp/references/integration-specs.md +6 -4
- package/package/corpus/skills/cratis-specifications-csharp/references/shared-lifecycle.md +6 -2
- package/package/corpus/skills/cratis-specifications-typescript/SKILL.md +2 -2
- package/package/corpus/skills/cratis-studio-mcp-safety-guidance/SKILL.md +4 -4
- package/package/corpus/skills/cratis-writing-voice-and-cadence/SKILL.md +1 -1
- package/package/corpus/skills/guiding-refactoring-with-code-health/SKILL.md +1 -1
- package/package/corpus/skills/prioritizing-technical-debt/SKILL.md +1 -1
- package/package/corpus/skills/risk-based-testing-with-code-health/SKILL.md +3 -3
- package/package/corpus/skills/safeguarding-ai-generated-code/SKILL.md +1 -1
- package/package.json +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/references/product-sources.md +0 -15
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/provenance.md +0 -13
|
@@ -13,30 +13,30 @@ For services and kernel contributors using Orleans. This is library-consumer gui
|
|
|
13
13
|
|
|
14
14
|
## Verified product sources
|
|
15
15
|
|
|
16
|
-
All Orleans claims below
|
|
16
|
+
All Orleans claims below come from `Cratis/Orleans` source.
|
|
17
17
|
|
|
18
|
-
| Packages |
|
|
19
|
-
| --- | --- |
|
|
20
|
-
| `Cratis.Orleans`, `Cratis.Orleans.Storage` | `
|
|
21
|
-
| `Cratis.Orleans.Storage.MongoDB`, `Cratis.Orleans.Storage.Sql` | `
|
|
22
|
-
| `Cratis.Orleans.Chronicle` | `
|
|
18
|
+
| Packages | Sources |
|
|
19
|
+
| --- | --- |
|
|
20
|
+
| `Cratis.Orleans`, `Cratis.Orleans.Storage` | `Source/Orleans/Jobs/{Job.cs,Job.Steps.cs,Job.Stages.cs,JobStep.cs,IJobsManager.cs,JobsOptions.cs}`; `Source/Orleans.Storage/Jobs/*` |
|
|
21
|
+
| `Cratis.Orleans.Storage.MongoDB`, `Cratis.Orleans.Storage.Sql` | `Source/Orleans.Storage.MongoDB/{MongoDBJobsStorageOptions.cs,DatabaseNames.cs}`; `Source/Orleans.Storage.Sql/{SqlJobsStorage.cs,SqlJobsStorageOptions.cs,Jobs/Migrations/v1_0_0.cs}` |
|
|
22
|
+
| `Cratis.Orleans.Chronicle` | `Source/Orleans.Chronicle/StateMachines/EventSourcedStateMachine.cs`; [state-machine reference](references/state-machines.md) |
|
|
23
23
|
|
|
24
24
|
The API snippets cite their exact files and lines below. Product docs `Documentation/concepts/{jobs,storage-scopes,state-machines,event-sourced-state-machines}.md` supply the task vocabulary; source resolves contradictions.
|
|
25
25
|
|
|
26
26
|
## 1. Choose a job, not a detached task
|
|
27
27
|
|
|
28
|
-
A job plans recoverable work; each step is a grain and does the work. Use it for work that must outlive a request. It is **at-least-once**, not exactly-once: a step interrupted before a durable checkpoint can perform the same work again. Protect external effects with receiver-owned idempotency/deduplication; a checkpoint does not atomically commit an external write (`JobStep.cs
|
|
28
|
+
A job plans recoverable work; each step is a grain and does the work. Use it for work that must outlive a request. It is **at-least-once**, not exactly-once: a step interrupted before a durable checkpoint can perform the same work again. Protect external effects with receiver-owned idempotency/deduplication; a checkpoint does not atomically commit an external write (`JobStep.cs`, `JobsOptions.cs`).
|
|
29
29
|
|
|
30
|
-
- Job: derive `Job<TRequest, TJobState>`; the request is a class implementing `IJobRequest`, the state derives `JobState` (`Job.cs
|
|
31
|
-
- Step: derive `JobStep<TRequest, TResult, TState>`; state derives `JobStepState`. Its constructor receives `[PersistentState(nameof(JobStepState), WellKnownGrainStorageProviders.JobSteps)] IPersistentState<TState>`, `IJobStepThrottle`, and `ILogger<JobStep<TRequest, TResult, TState>>` (`JobStep.cs
|
|
32
|
-
- Implement `PrepareStep(TRequest)` → `Task<Result<PrepareJobStepError>>`; `InitializeState(TRequest)` → `ValueTask`, called after preparation succeeds; and `PerformStep(TState, CancellationToken)` → `Task<Catch<JobStepResult>>` (`JobStep.cs
|
|
33
|
-
- Give the concrete job and step unique `[GrainType("product-specific-name")]` names. Use serializable request/state/result types. Do not reuse a class-derived grain name across assemblies (`Jobs/JobsManager.cs
|
|
30
|
+
- Job: derive `Job<TRequest, TJobState>`; the request is a class implementing `IJobRequest`, the state derives `JobState` (`Job.cs`). Implement `PrepareSteps(TRequest)` returning `Task<IImmutableList<JobStepDetails>>` (`Job.Steps.cs`).
|
|
31
|
+
- Step: derive `JobStep<TRequest, TResult, TState>`; state derives `JobStepState`. Its constructor receives `[PersistentState(nameof(JobStepState), WellKnownGrainStorageProviders.JobSteps)] IPersistentState<TState>`, `IJobStepThrottle`, and `ILogger<JobStep<TRequest, TResult, TState>>` (`JobStep.cs`).
|
|
32
|
+
- Implement `PrepareStep(TRequest)` → `Task<Result<PrepareJobStepError>>`; `InitializeState(TRequest)` → `ValueTask`, called after preparation succeeds; and `PerformStep(TState, CancellationToken)` → `Task<Catch<JobStepResult>>` (`JobStep.cs`). `TResult` is the step's result type; the work method returns the framework's `JobStepResult` envelope, not `TResult` directly.
|
|
33
|
+
- Give the concrete job and step unique `[GrainType("product-specific-name")]` names. Use serializable request/state/result types. Do not reuse a class-derived grain name across assemblies (`Jobs/JobsManager.cs`, `Documentation/how-to/host-the-silo.md`, and `orleans.md`).
|
|
34
34
|
|
|
35
|
-
`PerformStep` runs **outside the activation context** with a state snapshot obtained through the grain reference. Mutating that snapshot does not persist it; do not access/write grain `State` directly from background work (`JobStep.cs
|
|
35
|
+
`PerformStep` runs **outside the activation context** with a state snapshot obtained through the grain reference. Mutating that snapshot does not persist it; do not access/write grain `State` directly from background work (`JobStep.cs`). Keep progress/state coordination on grain calls. Requires Cratis.Orleans 1.16.2 for framework-owned stop reporting; there, do not report cancellation again from a `PerformWork` override (`Documentation/concepts/jobs.md`).
|
|
36
36
|
|
|
37
37
|
## 2. Plan dependencies as stages
|
|
38
38
|
|
|
39
|
-
Default steps all use `JobStepStage.First`. Prefer independent fan-out. Use stages only when correctness requires earlier work to finish (`Job.Stages.cs
|
|
39
|
+
Default steps all use `JobStepStage.First`. Prefer independent fan-out. Use stages only when correctness requires earlier work to finish (`Job.Stages.cs`).
|
|
40
40
|
|
|
41
41
|
Planning excerpt inside an existing `Job<RecoveryRequest, RecoveryState>`. It assumes `RecoveryRequest : IJobRequest`, `RecoveryState : JobState`, and the two existing grain interfaces `IRepairIndex` and `IRebuildCatalog`, each deriving a typed `IJobStep<,,>`:
|
|
42
42
|
|
|
@@ -52,31 +52,31 @@ protected override Task<IImmutableList<JobStepDetails>> PrepareSteps(RecoveryReq
|
|
|
52
52
|
]);
|
|
53
53
|
```
|
|
54
54
|
|
|
55
|
-
Import `System.Collections.Immutable` and `Cratis.Orleans.Jobs` in that job file. `CreateStep<TStep>` takes the **grain interface**, not the implementation (`Job.Steps.cs
|
|
55
|
+
Import `System.Collections.Immutable` and `Cratis.Orleans.Jobs` in that job file. `CreateStep<TStep>` takes the **grain interface**, not the implementation (`Job.Steps.cs`). Its stage overload accepts `JobStepStage`, with implicit integer conversion (`Source/Orleans.Storage/Jobs/Stages/JobStepStage.cs`).
|
|
56
56
|
|
|
57
|
-
Every step in a stage reaches an outcome before later stages start; steps within a stage run in parallel. All steps are prepared up front, so later-stage preparation cannot read the effects of earlier-stage execution. Read such dependencies in `PerformStep` (`Job.Stages.cs
|
|
57
|
+
Every step in a stage reaches an outcome before later stages start; steps within a stage run in parallel. All steps are prepared up front, so later-stage preparation cannot read the effects of earlier-stage execution. Read such dependencies in `PerformStep` (`Job.Stages.cs`).
|
|
58
58
|
|
|
59
|
-
A failed stage stops the pipeline by default: later steps become `Unreachable`, and the job completes with failures. A best-effort stage may override `GetFailureBehaviorFor(JobStepStage)` to return `JobStageFailureBehavior.ContinueWithNextStage` (`Job.Stages.cs
|
|
59
|
+
A failed stage stops the pipeline by default: later steps become `Unreachable`, and the job completes with failures. A best-effort stage may override `GetFailureBehaviorFor(JobStepStage)` to return `JobStageFailureBehavior.ContinueWithNextStage` (`Job.Stages.cs`, namespace `Cratis.Orleans.Jobs.Stages`). Do not silently continue when a later stage relies on the failed output.
|
|
60
60
|
|
|
61
61
|
## 3. Start and resume through the scoped manager
|
|
62
62
|
|
|
63
|
-
`IGrainFactory.GetJobsManager(scope, namespace)` resolves the manager (`JobsManagerExtensions.cs
|
|
63
|
+
`IGrainFactory.GetJobsManager(scope, namespace)` resolves the manager (`JobsManagerExtensions.cs`). `IJobsManager.Start<TJob,TRequest>(request)` returns `Result<JobId, StartJobError>`; inspect its error before telling a caller that a job started (`IJobsManager.cs`). Start success is not completed work; observe the job's status/outcomes.
|
|
64
64
|
|
|
65
|
-
`IJobsManager.Resume(JobId)` returns **`Task<bool>`**. False means nothing took the job; do not wait for a completion callback as though resumption succeeded. True can mean resumed, already running, or finalized as completed (`IJobsManager.cs
|
|
65
|
+
`IJobsManager.Resume(JobId)` returns **`Task<bool>`**. False means nothing took the job; do not wait for a completion callback as though resumption succeeded. True can mean resumed, already running, or finalized as completed (`IJobsManager.cs`). `Rehydrate()` completes after loading/preparing interrupted jobs, **before** its bounded background drain has resumed them all.
|
|
66
66
|
|
|
67
|
-
`StartStepsInBackground` defaults to false. Overriding it to true makes Start return once the job is durable, moving step preparation/start to the grain's next turn. Later startup errors belong to the job, not the Start response (`Job.cs
|
|
67
|
+
`StartStepsInBackground` defaults to false. Overriding it to true makes Start return once the job is durable, moving step preparation/start to the grain's next turn. Later startup errors belong to the job, not the Start response (`Job.cs`).
|
|
68
68
|
|
|
69
69
|
## 4. Know what storage retains
|
|
70
70
|
|
|
71
|
-
Successful jobs clear themselves by default; override `KeepAfterCompleted` to retain job state. Jobs completed with failures default to `KeepAfterCompletedWithFailures = true`, but retention cleanup still applies (`Job.cs
|
|
71
|
+
Successful jobs clear themselves by default; override `KeepAfterCompleted` to retain job state. Jobs completed with failures default to `KeepAfterCompletedWithFailures = true`, but retention cleanup still applies (`Job.cs`, `JobsOptions.cs`).
|
|
72
72
|
|
|
73
|
-
**Keeping a job does not keep successful step state.** The step provider deletes successful/removing state, moves failed state to failed-step storage, and saves stopped/scheduled/running/unreachable state (`JobStepGrainStorageProvider.cs
|
|
73
|
+
**Keeping a job does not keep successful step state.** The step provider deletes successful/removing state, moves failed state to failed-step storage, and saves stopped/scheduled/running/unreachable state (`JobStepGrainStorageProvider.cs`). SQL keeps failed step rows with a failure status rather than a separate collection (`Source/Orleans.Storage.Sql/Jobs/JobStepStorage.cs`, `MoveToFailed`). Copy results the job must retain through `OnStepCompletedOrStopped(JobStepId, JobStepResult)` into job state (`Job.Steps.cs`); do not read deleted successful step state later.
|
|
74
74
|
|
|
75
|
-
Deliver external callbacks to a method on the **job's grain interface**, update job state there and persist it with `WriteState()`. Preserve the returned `Catch` failure; do not acknowledge input whose write failed (`Job.State.cs
|
|
75
|
+
Deliver external callbacks to a method on the **job's grain interface**, update job state there and persist it with `WriteState()`. Preserve the returned `Catch` failure; do not acknowledge input whose write failed (`Job.State.cs`, `WriteState`; `Documentation/concepts/jobs.md`). Step state is not a callback inbox: a concurrent callback can race the final write, and successful completion deletes it. A running step's snapshot will not see later job/step writes automatically.
|
|
76
76
|
|
|
77
77
|
## 5. Register storage and budget concurrency
|
|
78
78
|
|
|
79
|
-
`IJobsStorage.GetFor(scope, namespace)` returns `JobsStorage`. Scope and namespace are opaque engine coordinates carried in grain keys; the host/provider owns their mapping (`Source/Orleans.Storage/Jobs/IJobsStorage.cs`, `Job.cs
|
|
79
|
+
`IJobsStorage.GetFor(scope, namespace)` returns `JobsStorage`. Scope and namespace are opaque engine coordinates carried in grain keys; the host/provider owns their mapping (`Source/Orleans.Storage/Jobs/IJobsStorage.cs`, `Job.cs`). They are storage boundaries, not authorization checks.
|
|
80
80
|
|
|
81
81
|
Choose one storage registration alongside `AddCratisOrleans`:
|
|
82
82
|
|
|
@@ -86,11 +86,11 @@ Choose one storage registration alongside `AddCratisOrleans`:
|
|
|
86
86
|
| `AddCratisOrleansSqlJobsStorage` | `.Storage.Sql` / `Cratis.Orleans.Setup` | Durable EF Core; `OptionsResolver(scope, namespace)` selects typed `DbContextOptions<JobsDbContext>` |
|
|
87
87
|
| `AddCratisOrleansInMemoryJobsStorage` | `.Storage` / `Cratis.Orleans.Storage` | Specs/development only; process restart loses state |
|
|
88
88
|
|
|
89
|
-
Evidence: each package's `*JobsStorageServiceCollectionExtensions.cs`; MongoDB `DatabaseNames.cs` and `MongoDBJobsStorageOptions.cs`; SQL `SqlJobsStorageOptions.cs
|
|
89
|
+
Evidence: each package's `*JobsStorageServiceCollectionExtensions.cs`; MongoDB `DatabaseNames.cs` and `MongoDBJobsStorageOptions.cs`; SQL `SqlJobsStorageOptions.cs`; in-memory `InMemory/InMemoryJobsStorage.cs`.
|
|
90
90
|
|
|
91
|
-
### SQL schema
|
|
91
|
+
### SQL schema creation
|
|
92
92
|
|
|
93
|
-
The product's SQL setup docs say to create the schema yourself. **
|
|
93
|
+
The product's SQL setup docs say to create the schema yourself. **the provider applies migrations automatically**: `SqlJobsStorage.GetFor` calls `EnsureSchema`, which calls `dbContext.Database.Migrate()` before constructing storage (`Source/Orleans.Storage.Sql/SqlJobsStorage.cs`). The migration is `Jobs/Migrations/v1_0_0.cs`; do not substitute `EnsureCreated` or hand-create those tables. The connection needs permissions to apply the migration, and scope-to-database mapping must be deliberate. Storage is cached per scope/namespace; `IJobsStorage.Reset()` clears the cache and the next resolution migrates again (`SqlJobsStorage.cs`). This resolves the documentation conflict from source, not from a release-note inference.
|
|
94
94
|
|
|
95
95
|
Configure `JobsOptions` through the host's options registration. Its properties are **init-only**: supply a constructed instance via the options mechanism rather than assigning them in a `Configure(options => options.Property = …)` callback (`JobsOptions.cs`).
|
|
96
96
|
|
|
@@ -106,7 +106,7 @@ Configure `JobsOptions` through the host's options registration. Its properties
|
|
|
106
106
|
| `TerminalJobRetention` | `7 days` | Terminal history retention; `Timeout.InfiniteTimeSpan` retains indefinitely |
|
|
107
107
|
| `MaxTerminalJobsPerCleanup` | `100` | Bounded oldest-first cleanup page |
|
|
108
108
|
|
|
109
|
-
Source: `JobsOptions.cs
|
|
109
|
+
Source: `JobsOptions.cs`. The three concurrency options for starts/rehydration/cleanup treat values below one as one. Retention does not delete preparing/running/stopped/removing jobs. Larger checkpoint intervals mean more post-crash redelivery, not higher delivery guarantees.
|
|
110
110
|
|
|
111
111
|
## State machines and verification
|
|
112
112
|
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
|
|
4
4
|
# Grain lifecycle state machines
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
Source: `Cratis/Orleans`. Use explicit states when entering/leaving a status has behavior; an enum is enough for a status with no behavior. Do not put long-running work on a grain turn just because `OnEnter` is available.
|
|
7
7
|
|
|
8
8
|
## Stored lifecycle
|
|
9
9
|
|
|
10
|
-
`StateMachine<TStoredState>` derives from a stateful grain. Override `InitialState` and `CreateStates()`; states derive `State<TStoredState>`. `AllowedTransitions` is an immutable list of target types, or override `CanTransitionTo<TTargetState>(storedState)` for a guard (`Source/Orleans/StateMachines/StateMachine.cs
|
|
10
|
+
`StateMachine<TStoredState>` derives from a stateful grain. Override `InitialState` and `CreateStates()`; states derive `State<TStoredState>`. `AllowedTransitions` is an immutable list of target types, or override `CanTransitionTo<TTargetState>(storedState)` for a guard (`Source/Orleans/StateMachines/StateMachine.cs`; `State.cs`).
|
|
11
11
|
|
|
12
12
|
Declaration excerpt for an existing grain file with `ProcessState : StateMachineState`, the existing `IProcess` grain interface, and a registered `processes` grain storage provider:
|
|
13
13
|
|
|
@@ -44,21 +44,21 @@ public class Finished : State<ProcessState>;
|
|
|
44
44
|
|
|
45
45
|
Split types into their house-style files in the consumer; the block collects declarations to show the API. Do not copy the `processes` provider name into Chronicle's kernel; use its registered constants.
|
|
46
46
|
|
|
47
|
-
A refused transition is a **no-op**, not an exception or a successful change. An unknown target throws `UnknownStateTypeInStateMachine`. The machine runs leaving hooks, `OnLeave`, entering hooks, `OnEnter`, then persistence (`StateMachine.cs
|
|
47
|
+
A refused transition is a **no-op**, not an exception or a successful change. An unknown target throws `UnknownStateTypeInStateMachine`. The machine runs leaving hooks, `OnLeave`, entering hooks, `OnEnter`, then persistence (`StateMachine.cs`). Transitions requested while entering are scheduled; transitions while leaving throw `TransitioningDuringOnLeaveIsNotSupported`.
|
|
48
48
|
|
|
49
|
-
When stored state derives `StateMachineState`, `CurrentState` stores the state's full type name; activation resolves it, enters it again, and can repeat enter effects. Renames need a stored-value migration; an unknown recorded name throws `UnknownCurrentState` (`StateMachine.cs
|
|
49
|
+
When stored state derives `StateMachineState`, `CurrentState` stores the state's full type name; activation resolves it, enters it again, and can repeat enter effects. Renames need a stored-value migration; an unknown recorded name throws `UnknownCurrentState` (`StateMachine.cs`). A self-transition with the **same state instance** skips persistence: return a new stored-state instance when a self-transition must write.
|
|
50
50
|
|
|
51
|
-
For externally owned storage, the protected constructor accepts `Orleans.Core.IStorage<TStoredState>` and reads it on activation before the activation hook. Override `ResolveActivationState()` to derive lifecycle from authoritative state instead of persisting a second status
|
|
51
|
+
For externally owned storage, the protected constructor accepts `Orleans.Core.IStorage<TStoredState>` and reads it on activation before the activation hook. Override `ResolveActivationState()` to derive lifecycle from authoritative state instead of persisting a second status.
|
|
52
52
|
|
|
53
53
|
## Lifecycle following Chronicle facts
|
|
54
54
|
|
|
55
|
-
`EventSourcedStateMachine<TModel>` from `Cratis.Orleans.Chronicle.StateMachines` uses a Chronicle read model as authoritative state. Its interface derives `IEventSourcedStateMachine` (string-keyed). There is **no grain storage provider** to configure and writes are no-ops: `ReadModelStorage<TModel>` reads Chronicle; `ResolveState(TModel?)` derives activation state (`Source/Orleans.Chronicle/StateMachines/EventSourcedStateMachine.cs
|
|
55
|
+
`EventSourcedStateMachine<TModel>` from `Cratis.Orleans.Chronicle.StateMachines` uses a Chronicle read model as authoritative state. Its interface derives `IEventSourcedStateMachine` (string-keyed). There is **no grain storage provider** to configure and writes are no-ops: `ReadModelStorage<TModel>` reads Chronicle; `ResolveState(TModel?)` derives activation state (`Source/Orleans.Chronicle/StateMachines/EventSourcedStateMachine.cs`; `ReadModelStorage.cs`).
|
|
56
56
|
|
|
57
57
|
- Define states with `CreateStates()` as above, over `TModel`.
|
|
58
|
-
- Define event transitions in `DefineTransitions(IStateMachineTransitions<TModel>)`, using `.On<TEvent>().When(model => predicate).TransitionTo<TState>()`. First applicable allowed transition wins. Make `ResolveState` agree with these transitions after restart (`EventSourcedStateMachine.cs
|
|
59
|
-
- Use model-bound projection attributes, an already-discovered projection, or `DefineProjection(IProjectionBuilderFor<TModel>)`, not competing projections. `DefineProjection` and `DefineTransitions` run at startup **without a constructor**: use only the builder, never injected services or fields (`EventSourcedStateMachine.cs
|
|
60
|
-
- Register `AddEventSourcedStateMachines()` on `ISiloBuilder` or `IServiceCollection`, beside the application's Chronicle client registration; namespace `Cratis.Orleans.Chronicle.Hosting` (`Hosting/EventSourcedStateMachinesServiceCollectionExtensions.cs
|
|
61
|
-
- Grain keys include event store, namespace and event-source ID. Use `IGrainFactory.GetEventSourcedStateMachine<TInterface>(eventStore, eventSourceId)` from `Cratis.Orleans.Chronicle.StateMachines` so tenant coordinates come from the supplied event store (`StateMachines/EventSourcedStateMachineGrainFactoryExtensions.cs
|
|
62
|
-
- Prefer passive models. For events consumed by a materialized projection, the reactor waits for its sequence position before refreshing; `ModelCatchUpTimeout` defaults to 30 seconds and expiry fails with `ModelDidNotCatchUp` (`EventSourcedStateMachineReactor.cs
|
|
58
|
+
- Define event transitions in `DefineTransitions(IStateMachineTransitions<TModel>)`, using `.On<TEvent>().When(model => predicate).TransitionTo<TState>()`. First applicable allowed transition wins. Make `ResolveState` agree with these transitions after restart (`EventSourcedStateMachine.cs`, `StateMachineTransitions.cs`).
|
|
59
|
+
- Use model-bound projection attributes, an already-discovered projection, or `DefineProjection(IProjectionBuilderFor<TModel>)`, not competing projections. `DefineProjection` and `DefineTransitions` run at startup **without a constructor**: use only the builder, never injected services or fields (`EventSourcedStateMachine.cs`).
|
|
60
|
+
- Register `AddEventSourcedStateMachines()` on `ISiloBuilder` or `IServiceCollection`, beside the application's Chronicle client registration; namespace `Cratis.Orleans.Chronicle.Hosting` (`Hosting/EventSourcedStateMachinesServiceCollectionExtensions.cs`).
|
|
61
|
+
- Grain keys include event store, namespace and event-source ID. Use `IGrainFactory.GetEventSourcedStateMachine<TInterface>(eventStore, eventSourceId)` from `Cratis.Orleans.Chronicle.StateMachines` so tenant coordinates come from the supplied event store (`StateMachines/EventSourcedStateMachineGrainFactoryExtensions.cs`).
|
|
62
|
+
- Prefer passive models. For events consumed by a materialized projection, the reactor waits for its sequence position before refreshing; `ModelCatchUpTimeout` defaults to 30 seconds and expiry fails with `ModelDidNotCatchUp` (`EventSourcedStateMachineReactor.cs`; `EventSourcedStateMachinesOptions.cs`).
|
|
63
63
|
|
|
64
|
-
This machine **follows facts**, it does not arbitrate whether a command may append one. Keep command rejection and append-time invariants at their owning boundary. Enter/model-change effects may repeat on activation, redelivery or replay: design them idempotently (`Documentation/concepts/event-sourced-state-machines.md
|
|
64
|
+
This machine **follows facts**, it does not arbitrate whether a command may append one. Keep command rejection and append-time invariants at their owning boundary. Enter/model-change effects may repeat on activation, redelivery or replay: design them idempotently (`Documentation/concepts/event-sourced-state-machines.md`). Test guards, no-op refusals, reactivation and persistence failures separately from job recovery.
|
|
@@ -18,16 +18,14 @@ storage and replay cost that never goes away.
|
|
|
18
18
|
|
|
19
19
|
## Verified product sources
|
|
20
20
|
|
|
21
|
-
| Package |
|
|
22
|
-
| --- | --- |
|
|
23
|
-
| `Cratis.Chronicle` |
|
|
24
|
-
| `Cratis.Arc.Core` |
|
|
25
|
-
| `@cratis/components` | `
|
|
21
|
+
| Package | Purpose |
|
|
22
|
+
| --- | --- |
|
|
23
|
+
| `Cratis.Chronicle` | Observers, projections, reducers, reactors, replay |
|
|
24
|
+
| `Cratis.Arc.Core` | Query return shapes and server-side paging |
|
|
25
|
+
| `@cratis/components` | `DataTable` paging surface |
|
|
26
26
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
> MongoDB observations now re-read page and total on each change; see the
|
|
30
|
-
> read-model query reference for the distinction from unpaged retained sets.
|
|
27
|
+
Paged MongoDB observations re-read page and total on each change; see the
|
|
28
|
+
read-model query reference for the distinction from unpaged retained sets.
|
|
31
29
|
|
|
32
30
|
Reverify against the owning product repository before asserting a framework
|
|
33
31
|
behavior this file does not already state.
|
|
@@ -52,7 +50,7 @@ behavior this file does not already state.
|
|
|
52
50
|
received already carries what it needs. (Reactor dispatch is by the handler's
|
|
53
51
|
first parameter type — the method name is free, so look for the event-typed
|
|
54
52
|
parameter, not for a method called `On`.)
|
|
55
|
-
- **A new projection can replay all
|
|
53
|
+
- **A new projection can replay all earlier events without failing.** Ask it
|
|
56
54
|
explicitly: at production volume, does this projection complete a full replay?
|
|
57
55
|
- **Events are small.** No large blob and no base64 payload embedded in an
|
|
58
56
|
event; put the content elsewhere and carry a reference.
|
|
@@ -23,7 +23,7 @@ observable changes from the diff, specs, linked issues/PRs, and authoritative
|
|
|
23
23
|
product source at that revision. A PR description is published verbatim as
|
|
24
24
|
release notes in a Cratis repository; follow its current template and the
|
|
25
25
|
pull-request contract, and confirm that behavior before drafting. Do not turn
|
|
26
|
-
|
|
26
|
+
a draft into a claim about shipped behavior.
|
|
27
27
|
|
|
28
28
|
For each change, ask: who uses this path, what happened before, what happens
|
|
29
29
|
now, is action required, and how would they notice? Check changed defaults,
|
|
@@ -15,7 +15,7 @@ protected, what is only recorded, and who acts. Grammar depth is in
|
|
|
15
15
|
**Translation crosses an application boundary:** inbound turns outside data or foreign
|
|
16
16
|
public events into private local facts; outbound publishes private facts as one local public
|
|
17
17
|
event type. Declare `direction inbound|outbound` when public metadata is used; omission
|
|
18
|
-
preserves
|
|
18
|
+
preserves inbound for translations without a declared direction. Private-to-private follow-up is an
|
|
19
19
|
Automation (`produces` or `invokes`), even when a Chronicle reactor realizes it.
|
|
20
20
|
Read [public events and direction](references/public-events-and-direction.md) for released
|
|
21
21
|
ESM v9 forms, event-target folds, publication specifications and the Unsupported capture limit.
|
|
@@ -28,19 +28,17 @@ identity, effect and pending-work contract at that point; do not postpone it to
|
|
|
28
28
|
|
|
29
29
|
## Tool and realization facts (read before promising anything)
|
|
30
30
|
- Reactions, clocks, triggers, captures and Automation/Translate slices compile (V1) and bind (V3)
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
(4.60.1) reported PLAY0268 at binding: report "V3 blocked: PLAY0268 (ESM v6)" and
|
|
31
|
+
as ESM v6: the standalone tool and a CLI whose bundled compiler admits v6. A compiler that
|
|
32
|
+
stops before v6 reports PLAY0268 at binding: report "V3 blocked: PLAY0268 (ESM v6)" and
|
|
34
33
|
name the tool, never remove them.
|
|
35
34
|
- The pinned standalone tool runs admitted scenarios through `screenplay test` or MCP
|
|
36
35
|
`run-specifications`; source validation and render publication do not run V4.
|
|
37
|
-
-
|
|
38
|
-
|
|
36
|
+
- A renderer can refuse Automation/Translate members (STAGE-ESM-024) it does not realize.
|
|
37
|
+
Deliver that scope as authorized gap-fill
|
|
39
38
|
(`references/realization-and-gap-fill.md`).
|
|
40
39
|
- Reaction `runs as system role "<Role>"` declares an invocation actor (ESM v10).
|
|
41
|
-
Without it the invoke has no caller.
|
|
42
|
-
|
|
43
|
-
at render admission (CLI-RENDER-004). The CLI/Stage pair (toolchain
|
|
40
|
+
Without it the invoke has no caller. A compiler or renderer that stops before v10
|
|
41
|
+
rejects the syntax (PLAY0137) or refuses it at render admission (CLI-RENDER-004). The CLI/Stage pair (toolchain
|
|
44
42
|
`references/renderable-subset.md`) renders role/authenticated reaction identity; claim-reading/opaque gates retain STAGE-ESM-034. Checked model/diagnostics: captures-and-reactions
|
|
45
43
|
`references/invocation-identity.md`.
|
|
46
44
|
|
|
@@ -71,20 +69,24 @@ Personal data kept in events needs bare `pii` on its concept and a declared purp
|
|
|
71
69
|
even when it blocks binding. Never record bearer tokens, magic links or signed URLs as facts
|
|
72
70
|
(a keyed hash or reference at most), and never put PII on the event-source id.
|
|
73
71
|
|
|
74
|
-
##
|
|
75
|
-
Tool versions: toolchain `SKILL.md`. Language claims
|
|
76
|
-
|
|
77
|
-
`
|
|
78
|
-
event-triggered Automation renders; Translate/captures and refused reactions stay gap-fill.
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
72
|
+
## Product sources
|
|
73
|
+
Tool versions: toolchain `SKILL.md`. Language claims come from Screenplay
|
|
74
|
+
`Documentation/screenplay/{reactions,captures,triggers,specifications,diagnostics}.md`;
|
|
75
|
+
renderer claims from Stage `Documentation/reference/reaction-rendering.md`: supported
|
|
76
|
+
event-triggered Automation renders; Translate/captures and refused reactions stay gap-fill.
|
|
77
|
+
Runtime facts: Arc `ExecuteCommandsAsSystemAttribute` and mixed events-and-commands reactor
|
|
78
|
+
returns; Chronicle `OnceOnlyAttribute`, `ReactorDelivery`, `Documentation/code-analysis/CHR0022.mdx`
|
|
79
|
+
and `Documentation/reactors/delivery-identity.mdx`.
|
|
80
|
+
|
|
81
|
+
Requires Screenplay 4.125.0 or later (`screenplay --version`) for reaction `runs as system role` (ESM v10).
|
|
82
|
+
|
|
83
|
+
Requires Arc 20.56.0 or later for `[ExecuteCommandsAsSystem]`.
|
|
84
|
+
|
|
85
|
+
Requires Arc 22.72.0 or later for a reactor that returns events and commands together; before it, a mixed return is not handled. Stage still refuses a reaction that both `produces` and `invokes` (`STAGE-ESM-037`), so a mixed reaction stays authorized gap-fill whatever the Arc release.
|
|
86
|
+
|
|
87
|
+
Requires Screenplay 4.105.0 or later (`screenplay --version`) for list queries (`=> Item[]`); before it a list query is refused with PLAY0268.
|
|
88
|
+
|
|
89
|
+
Requires Screenplay 4.124.0 or later (`screenplay --version`) for `--check privilege` (PLAY0652).
|
|
88
90
|
|
|
89
91
|
Read `SKILL.md` in `cratis-screenplay-toolchain` when selecting a tool; read the installed versions with `screenplay --version` and `cratis --version`. Reverify before claiming
|
|
90
92
|
another version behaves the same.
|
|
@@ -141,7 +143,7 @@ or actor that nobody confirmed. Read `references/worked-integration.md` when you
|
|
|
141
143
|
system principal only to reactors marked `[ExecuteCommandsAsSystem]`; without
|
|
142
144
|
it there is no principal and `[Authorize]`/`[Roles]` deny. `runs as` covers returned
|
|
143
145
|
or invoked commands, not imperative pipeline calls, reads, productions or causation.
|
|
144
|
-
|
|
146
|
+
Run `--check privilege --warnaserror` (PLAY0652) for
|
|
145
147
|
confused-deputy paths: every trigger-event producer must require **all** declared
|
|
146
148
|
system roles. Ungated commands/captures/reaction productions warn; opaque gates
|
|
147
149
|
are information, not proven safe. An OR alternative does not require a role.
|
|
@@ -160,7 +162,7 @@ or actor that nobody confirmed. Read `references/worked-integration.md` when you
|
|
|
160
162
|
named cases to `cratis-screenplay-scenario-coverage`. Produce the audit in `references/audit-format.md`.
|
|
161
163
|
|
|
162
164
|
## Rules
|
|
163
|
-
**Compiler contracts** (diagnostics
|
|
165
|
+
**Compiler contracts** (diagnostics)
|
|
164
166
|
- No inline `produces event` in a reaction (PLAY0474); declare reaction-produced events in the slice.
|
|
165
167
|
- Effects sit under a trigger; `description`, `where` and current `runs as` are reaction-level; one `where` per
|
|
166
168
|
reaction (PLAY0252); a trigger may not repeat (PLAY0253).
|
|
@@ -171,7 +173,7 @@ or actor that nobody confirmed. Read `references/worked-integration.md` when you
|
|
|
171
173
|
separate binder check.
|
|
172
174
|
- A trigger with `reads` that `produces` directly fails binding: decide in a command. `reads` never protects.
|
|
173
175
|
- An authorized command exercised in a spec without `given caller` is PLAY0389 at binding.
|
|
174
|
-
- A list query (`=> Item[]`) binds (
|
|
176
|
+
- A list query (`=> Item[]`) binds (a snapshot list is not rendered, `STAGE-ESM-010`);
|
|
175
177
|
a clock sweep that iterates items needs a code body the reference does not run
|
|
176
178
|
(`references/todo-list-example.md`).
|
|
177
179
|
|
|
@@ -203,8 +205,8 @@ direct effect states "not applicable: no queue" with its reason (per-chain quest
|
|
|
203
205
|
Never report a verdict without the tool and version that produced it.
|
|
204
206
|
|
|
205
207
|
## Verify
|
|
206
|
-
- V1 and V3 per `cratis-screenplay-toolchain`, each with tool and version.
|
|
207
|
-
|
|
208
|
+
- V1 and V3 per `cratis-screenplay-toolchain`, each with tool and version. When the bundled compiler stops before v6,
|
|
209
|
+
report "V3 blocked: PLAY0268 (ESM v6)". Current admitted scenarios use
|
|
208
210
|
standalone `screenplay test`/MCP for V4; unsupported or unbound is not passed.
|
|
209
211
|
- For each external source and type: its translation, or an explicit out-of-scope reason; check
|
|
210
212
|
target-field completeness as well as source-field dispositions.
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
- 9. Fan-out
|
|
14
14
|
- 10. Long-running process shapes
|
|
15
15
|
|
|
16
|
-
Complete compiled example: `todo-list-example.md` (binds
|
|
16
|
+
Complete compiled example: `todo-list-example.md` (binds as ESM v6; the list query
|
|
17
17
|
excerpt binds too, and the retry sweep that needs code is shown as a marked excerpt).
|
|
18
18
|
|
|
19
19
|
## 1. Deciding whether it is an automation
|
|
@@ -45,11 +45,11 @@ Outcomes:
|
|
|
45
45
|
- A projection that adds an item `from <OpeningFact>` and removes it with
|
|
46
46
|
`remove with <ClosingFact>`. Several facts may open or close; they need not match one to one.
|
|
47
47
|
- A keyed query (`…ById => Item optional` + `by itemId`) for specs and executable scope; a
|
|
48
|
-
list query for the visible queue (`=> Item[]` binds
|
|
48
|
+
list query for the visible queue (`=> Item[]` binds on Screenplay 4.105.0 or later; a snapshot list is refused by Stage, `STAGE-ESM-010`).
|
|
49
49
|
- A reaction `when <OpeningFact>` that invokes the command producing the closing fact.
|
|
50
50
|
The trigger may `reads` the item view to document its input; that is not protection.
|
|
51
51
|
- A retry sweep on a clock reads the whole view (no `by` on clock reads). Iterating its items
|
|
52
|
-
declaratively (`for each <View>`) is reserved syntax;
|
|
52
|
+
declaratively (`for each <View>`) is reserved syntax; the sweep needs a code body,
|
|
53
53
|
which the reference never runs. Durable fan-out is outside the language (Screenplay#286).
|
|
54
54
|
- Specify the list as a small story: empty -> item present (`then query …ById`) -> closed
|
|
55
55
|
(`when append <Closing>` + `then no readmodel … for`), plus "not opened" for facts that
|
|
@@ -69,13 +69,13 @@ When a todo list is not needed: the effect is immediate, internal and cannot fai
|
|
|
69
69
|
| caller | n/a | declared reaction `runs as` actor (ESM v10), otherwise none |
|
|
70
70
|
|
|
71
71
|
## 4. The actor behind an invoke
|
|
72
|
-
|
|
72
|
+
The actor is declared with reaction-level `runs as system role
|
|
73
73
|
"<Role>"` (ESM v10); without it a gated invocation has no caller and denies.
|
|
74
74
|
`given caller` is not an invocation actor. Role requirements remain enforced;
|
|
75
|
-
claim conditions for this system principal remain unknown.
|
|
76
|
-
|
|
75
|
+
claim conditions for this system principal remain unknown. A compiler that stops before v10
|
|
76
|
+
rejects the syntax (PLAY0137). The CLI/Stage pair (toolchain
|
|
77
77
|
`references/renderable-subset.md`) renders role/authenticated reaction identity; claim-reading/opaque gates retain STAGE-ESM-034.
|
|
78
|
-
|
|
78
|
+
A renderer that stops before v10 refuses it at its version gate.
|
|
79
79
|
Use the checked model in captures-and-reactions `references/invocation-identity.md`.
|
|
80
80
|
Arc gap-fill uses `[ExecuteCommandsAsSystem("<role>")]` for returned commands,
|
|
81
81
|
not identity inferred from prose or an imperative pipeline call.
|
|
@@ -90,7 +90,7 @@ Decide and record one of:
|
|
|
90
90
|
should refuse it.
|
|
91
91
|
3. **Gated command + declared trusted actor** - keep the service-role policy and
|
|
92
92
|
declare matching `runs as system role` on the reaction. Reference-test the
|
|
93
|
-
scenario with standalone
|
|
93
|
+
scenario with a standalone compiler that admits v10; separately record CLI/Stage target refusal.
|
|
94
94
|
A missing actor must not be excused by removing the gate or inventing a caller.
|
|
95
95
|
Never remove an existing gate only to make a reaction spec pass.
|
|
96
96
|
Omitting an HTTP route is not an authorization proof: the exposure requirement stays a target
|
|
@@ -16,7 +16,7 @@ One spec in the slice does not cover the others.
|
|
|
16
16
|
| queue opens / closes | item appears, item disappears | `then query …ById`; `when append <Closing>` + `then no readmodel … for` |
|
|
17
17
|
| already done | trigger re-delivered after the result exists | `given <Result>` + `when <Command>` -> `then error "<fixed constraint message>"` |
|
|
18
18
|
| invoked command rejects | validation or constraint refuses | command spec in its StateChange slice; record what the queue shows afterwards |
|
|
19
|
-
| no declared actor | invoked command is gated | specify its denial; for the trusted path declare reaction `runs as system role` and reference-test with standalone
|
|
19
|
+
| no declared actor | invoked command is gated | specify its denial; for the trusted path declare reaction `runs as system role` and reference-test with a standalone compiler that admits v10 |
|
|
20
20
|
| clock boundary | due exactly at the instant, just before, just after | `given clock` + `when clock`; boundary semantics are contested in the docs, mark the expectation as an assumption |
|
|
21
21
|
| each branch | does every filter and conditional production have both outcomes? | concrete triggering and non-triggering values; assert the resulting facts or view |
|
|
22
22
|
| denied actor | every command and query under an inherited module/feature `authorize` needs its own denial; also, can an unauthorized caller reach a gated invoked command by another origin? | command spec with otherwise-valid inputs, `given caller` carrying the wrong role/claim (or no caller) and `then denied`; separate from the caller-less reaction gap |
|
|
@@ -61,9 +61,9 @@ One spec in the slice does not cover the others.
|
|
|
61
61
|
- Current admitted Automation/Translate specifications run through standalone
|
|
62
62
|
`screenplay test` or MCP `run-specifications`. Validate/render alone is not V4;
|
|
63
63
|
report unsupported/unbound separately from passing scenarios.
|
|
64
|
-
-
|
|
65
|
-
`when <Command>`, `then` lists every new fact, including reaction appends). Only when
|
|
66
|
-
|
|
64
|
+
- A command spec lists the cascade (v6 semantics: after
|
|
65
|
+
`when <Command>`, `then` lists every new fact, including reaction appends). Only when the V1
|
|
66
|
+
tool's compiler stops before v6 does it report a false PLAY0285 on a cascade:
|
|
67
67
|
then keep the cascade out of the command spec, specify it in the Automation slice
|
|
68
68
|
(`when append <Trigger>`) and record the expectation. See `cratis-screenplay-scenario-coverage`.
|
|
69
69
|
- `given capture` never persists between specs: state the baseline in each spec that needs it.
|
|
@@ -27,13 +27,15 @@ key; write a reconciliation case.
|
|
|
27
27
|
|
|
28
28
|
## Refusal disposition and redelivery
|
|
29
29
|
|
|
30
|
-
|
|
30
|
+
An invocation can state ordered `on refused` selectors for
|
|
31
31
|
validation, constraint (optionally named) or explicit authorization denial.
|
|
32
32
|
Bare refusal does not include authorization. A matching branch declares a fact
|
|
33
33
|
or leaf `acknowledge`; `$refusal.reason`/`.message` are String details and
|
|
34
34
|
`.constraint` belongs only to constraint selectors. This is **authoring-only**
|
|
35
35
|
(PLAY0268), not evidence that a duplicate was safely acknowledged at runtime.
|
|
36
36
|
|
|
37
|
+
Requires Screenplay 4.81.0 or later (`screenplay --version`) for `on refused` selectors and `$refusal` values.
|
|
38
|
+
|
|
37
39
|
Recovery syntax `when redelivered <Event> to <Reaction>` selects exactly one
|
|
38
40
|
existing given occurrence; it is not append or replay. `then no events` makes a
|
|
39
41
|
no-new-facts contract explicit but remains unadmitted too. Full selectors,
|
|
@@ -22,7 +22,7 @@ by Martin Dilger and Nebulit GmbH (https://nebulit.de), used with the explicit c
|
|
|
22
22
|
|
|
23
23
|
| Source file | Used in | How |
|
|
24
24
|
|---|---|---|
|
|
25
|
-
| `.claude/skills/eventmodeling-designing-automation-chains/SKILL.md`: resolve the chain when introduced; exhaustive per-automation verification | `SKILL.md` intro and "Gate", `references/audit-format.md` |
|
|
25
|
+
| `.claude/skills/eventmodeling-designing-automation-chains/SKILL.md`: resolve the chain when introduced; exhaustive per-automation verification | `SKILL.md` intro and "Gate", `references/audit-format.md` | the six verification questions adapted closely as "Per-chain questions", translated to Screenplay (no board, no `validate_model`) |
|
|
26
26
|
| same: pending membership not status; opening and closing events | `references/automation-patterns.md` section 2, `references/audit-format.md` question 6 | adapted closely; our todo-list example kept |
|
|
27
27
|
| same: worker only for a new decision; redundant second stage and the `Synced` tell | `references/automation-patterns.md` section 7 "Redundant second stage" | adapted closely, marina berth example in place of Martin Dilger and Nebulit GmbH's |
|
|
28
28
|
| same: silently skipping a missing target | `SKILL.md` "Gate", `references/audit-format.md` | idea inverted: an absent target is an unresolved dependency |
|
|
@@ -35,19 +35,6 @@ by Martin Dilger and Nebulit GmbH (https://nebulit.de), used with the explicit c
|
|
|
35
35
|
## Carried forward
|
|
36
36
|
`references/automation-patterns.md`, `translation-patterns.md`, `effects-and-idempotency.md`,
|
|
37
37
|
`cases-to-specify.md` and both examples come from the earlier Cratis drafts of this skill.
|
|
38
|
-
Changes in this version: the examples are complete fenced documents that compile (the translate
|
|
39
|
-
example's anonymous-booking spec gained the `given caller` PLAY0389 requires; the todo-list
|
|
40
|
-
example's list query, `reads` and retry sweep moved to marked design-only excerpts so the core
|
|
41
|
-
binds); tool-qualified verdict text; the trusted-actor text now names `[ExecuteCommandsAsSystem]`
|
|
42
|
-
(Arc v20.56.0). Actor syntax was reverified at Screenplay v4.125.0
|
|
43
|
-
`reactions.md`, `ReactionIdentityParser.cs`, `ReactionRefusalValidator.cs` and the
|
|
44
|
-
binder's v10 selection; the checked scenario passed reference execution. CLI
|
|
45
|
-
3.41.0's older parser and Stage 4.51.3's v7 planner were historical target limits.
|
|
46
|
-
Previous CLI 3.46.1 refused v10 at its version gate. The CLI/Stage pair
|
|
47
|
-
(toolchain `references/renderable-subset.md`) renders role/authenticated reaction identity; claim-reading/opaque gates retain
|
|
48
|
-
STAGE-ESM-034 (Stage `v4.89.1:Documentation/reference/reaction-rendering.md:57-59`).
|
|
49
|
-
Public/direction forms and routes/filters follow Screenplay v4.135.0 decisions
|
|
50
|
-
0049–0051 and 0060–0066, not the older inbound-only translation scope.
|
|
51
38
|
|
|
52
39
|
## Eventmodelers Build-Kits
|
|
53
40
|
|
|
@@ -117,17 +117,19 @@ Keep correlation and resulting private events in the model and report the runtim
|
|
|
117
117
|
|
|
118
118
|
## Admission and evidence
|
|
119
119
|
|
|
120
|
-
ESM v9 shipped
|
|
120
|
+
ESM v9 shipped and is selected only by use of public events,
|
|
121
121
|
origins, direction, event-target builders or events-source captures. At 4.135.0,
|
|
122
122
|
publication reference scenarios execute; imported shapes still refuse binding.
|
|
123
123
|
Stage 4.52.0 (previous CLI 3.46.1, history) audited only through v7. The CLI/Stage pair (toolchain `references/renderable-subset.md`)
|
|
124
124
|
reaches construct admission through v15 but still refuses publication (STAGE-ESM-032), foreign
|
|
125
125
|
events/events-source captures (STAGE-ESM-033); source admission is not rendering.
|
|
126
126
|
|
|
127
|
-
|
|
127
|
+
Requires Screenplay 4.117.0 or later (`screenplay --version`) for public events (ESM v9).
|
|
128
|
+
|
|
129
|
+
Source: Screenplay `Documentation/screenplay/fixtures/public-events.play`,
|
|
128
130
|
`events.md`, `slices.md`, `captures.md`, decisions 0049–0051 and
|
|
129
131
|
`Source/DotNET/Screenplay.CanonicalCorpus/PublicEventsCorpus.cs`.
|
|
130
|
-
Renderer source: Stage `
|
|
131
|
-
and `
|
|
132
|
+
Renderer source: Stage `Source/Rendering.Cratis/Semantics/SemanticCratisAdmission.cs`
|
|
133
|
+
and `Source/Rendering.Cratis/Semantics/SemanticVersionFeatures.cs`.
|
|
132
134
|
Diagnostics and repairs: toolchain `references/diagnostics.md`; version allocation:
|
|
133
135
|
toolchain `references/executable-subset.md`.
|
|
@@ -5,15 +5,14 @@ the automation-and-translation addendum to `cratis-screenplay-render-and-gap-fil
|
|
|
5
5
|
skill for the admission, publication and ownership rules.
|
|
6
6
|
|
|
7
7
|
## Stage rendering versus gap-fill
|
|
8
|
-
CLI
|
|
8
|
+
The CLI and Stage render supported event-triggered Automation slices as Chronicle
|
|
9
9
|
reactors. Translate/captures, non-event triggers and opaque bodies remain `STAGE-ESM-024`;
|
|
10
10
|
Claim-reading/opaque `runs as` gates (`-034`), legacy `from` (`-035`), mixed effects (`-037`), unsupported mappings (`-039`)
|
|
11
11
|
and protected destinations (`-040`) also remain refused. Command specs that cascade into
|
|
12
12
|
reactions remain `-011`; supported single-hop append specs now render, as do semantic
|
|
13
13
|
reaction `from` and role/authenticated system identities. Only refused scope is hand-written delivery with the model as
|
|
14
|
-
its contract. Source: Stage `
|
|
15
|
-
full admission: `cratis-stage-rendering-and-sandbox` `references/admission.md`.
|
|
16
|
-
3.28.2 and 3.28.3 refused such a model whole with `STAGE-ESM-016`, and 3.27.1 stopped earlier with PLAY0268.)
|
|
14
|
+
its contract. Source: Stage `Documentation/reference/reaction-rendering.md`;
|
|
15
|
+
full admission: `cratis-stage-rendering-and-sandbox` `references/admission.md`.
|
|
17
16
|
|
|
18
17
|
A reaction that both `produces` events and `invokes` commands stays one modeled reaction. Hand-write one
|
|
19
18
|
retry-safe reactor: the scaffold already includes Arc's mixed-result handler, but it appends
|
|
@@ -27,13 +26,13 @@ with `cratis-screenplay-render-and-gap-fill`.
|
|
|
27
26
|
| Model element | Realization | Skill |
|
|
28
27
|
|---|---|---|
|
|
29
28
|
| reaction `when <Event>` with `invokes` or `produces` | Chronicle reactor returning commands or events | `cratis-chronicle-reactor` |
|
|
30
|
-
| trusted actor for `invokes` | `[ExecuteCommandsAsSystem("<role>")]` on the reactor plus a policy requiring the role (Arc
|
|
29
|
+
| trusted actor for `invokes` | `[ExecuteCommandsAsSystem("<role>")]` on the reactor plus a policy requiring the role (Arc; see the Requires line below) | `cratis-chronicle-reactor` |
|
|
31
30
|
| clock trigger, application trigger | scheduler or host signal that raises the occurrence | `cratis-engineering-effect-boundaries` |
|
|
32
31
|
| call to an outside system | adapter behind an effect boundary, keyed by the idempotency key in the model | `cratis-engineering-effect-boundaries` |
|
|
33
32
|
| capture source (webhook, poll, topic) | adapter that authenticates (the provider's signature or shared secret, never an application user token, because the provider cannot obtain one), parses and appends, keeping the provider's retry identity | `cratis-engineering-effect-boundaries` |
|
|
34
33
|
| replay versus recovery redelivery | `[OnceOnly]` for replay; a receipt keyed by `ReactorDelivery.Id` for recovery | `cratis-chronicle-reactor` |
|
|
35
34
|
|
|
36
|
-
|
|
35
|
+
Rendered apps pin their own Arc and Chronicle releases, so
|
|
37
36
|
`[ProtectedDecision]` and `DecisionRead<T>` are available to gap-fill, not
|
|
38
37
|
Stage-emitted enforcement. Admit the projection/key and enroll the read in the
|
|
39
38
|
active unit of work; never edit managed `Directory.Packages.props`.
|
|
@@ -5,17 +5,15 @@
|
|
|
5
5
|
- Design-only additions
|
|
6
6
|
|
|
7
7
|
A complete model: a result opens a work item, a reaction invokes a command, the command's fact
|
|
8
|
-
closes the item. It binds
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
rejected the Automation slice at binding with PLAY0268. Versions: `cratis-screenplay-toolchain` `SKILL.md`.
|
|
8
|
+
closes the item. It binds as ESM v6 (`executableReady: true`), standalone and through `cratis screenplay mcp`.
|
|
9
|
+
Stage renders supported event reactions, but this model's clock/cascade specs remain
|
|
10
|
+
refused (`-024`/`-011`); keep them intact. A compiler that stops before v6 rejects the
|
|
11
|
+
Automation slice at binding with PLAY0285 or PLAY0268. Versions: `cratis-screenplay-toolchain` `SKILL.md`.
|
|
13
12
|
|
|
14
13
|
The first spec lists the whole cascade (`then` names every new fact: `CoursePassed`, and
|
|
15
14
|
`CertificateSent` through the reaction), and `given clock` supplies the instant that
|
|
16
|
-
`$context.occurred` needs. Both
|
|
17
|
-
|
|
18
|
-
run in that historical probe; current admitted scenarios can be run with
|
|
15
|
+
`$context.occurred` needs. Both tools accept that cascade when they admit v6; an older compiler reports a false PLAY0285 on it.
|
|
16
|
+
Current admitted scenarios can be run with
|
|
19
17
|
standalone `screenplay test` or MCP `run-specifications`.
|
|
20
18
|
|
|
21
19
|
What the model proves and what it does not:
|
|
@@ -27,7 +25,7 @@ What the model proves and what it does not:
|
|
|
27
25
|
- The actor behind `SendCertificate` is a recorded security decision in the `Certification`
|
|
28
26
|
module `description`: this example declares no reaction identity, so its
|
|
29
27
|
invocations remain caller-less. A gated trusted path can instead declare
|
|
30
|
-
`runs as system role`
|
|
28
|
+
`runs as system role` (ESM v10), with separate CLI/Stage refusal.
|
|
31
29
|
- Report reference outcomes only after executing the selected scenarios.
|
|
32
30
|
|
|
33
31
|
```screenplay expect PLAY0469,PLAY0516
|
|
@@ -190,11 +188,12 @@ module Certification
|
|
|
190
188
|
## Design-only additions
|
|
191
189
|
|
|
192
190
|
Two things a real queue often wants stay out of the complete model above: a list query (the
|
|
193
|
-
visible queue) and a retry sweep that reads the whole view. The list query binds (
|
|
194
|
-
|
|
195
|
-
reference does not run, and durable per-item fan-out is outside the language (Screenplay#286). Say so
|
|
191
|
+
visible queue) and a retry sweep that reads the whole view. The list query binds (Stage refuses a snapshot list); the sweep needs a code body the
|
|
192
|
+
reference does not run, and durable per-item fan-out is outside the language. Say so
|
|
196
193
|
in the verdict.
|
|
197
194
|
|
|
195
|
+
Requires Screenplay 4.105.0 or later (`screenplay --version`) for the list query; before it the list query is refused with PLAY0268.
|
|
196
|
+
|
|
198
197
|
```screenplay excerpt parent=assets/pending-certificates.play
|
|
199
198
|
// Parent: the complete document above, slice StateView CertificatesToSend.
|
|
200
199
|
query PendingCertificates => PendingCertificate[]
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
A complete model: a webhook record from an outside proctoring service is captured, kept as an
|
|
4
4
|
external fact in the provider's vocabulary, then translated by reactions into our facts. It
|
|
5
|
-
binds
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
binds as ESM v6 (`executableReady: true`), standalone and through `cratis screenplay mcp`; a
|
|
6
|
+
compiler that stops before v6 compiles it (V1) but rejects the Translate slice at binding
|
|
7
|
+
(PLAY0268). `cratis render` refuses it (`STAGE-ESM-016` or `STAGE-ESM-024`, by renderer).
|
|
8
8
|
|
|
9
9
|
Read the slice `description`: it is the per-field disposition (map, translate, ignore) and it
|
|
10
10
|
states what this example does not do. Examples never show the whole integration contract; use
|