@cratis/pi 7.9.3 → 7.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package/corpus/agents/backend-developer.md +1 -1
- package/package/corpus/agents/code-reviewer.md +2 -2
- package/package/corpus/agents/coordinator.md +1 -1
- package/package/corpus/agents/frontend-developer.md +1 -1
- package/package/corpus/agents/orchestrator.md +1 -1
- package/package/corpus/agents/planner.md +2 -2
- package/package/corpus/agents/screenplay-modeler.md +1 -1
- package/package/corpus/agents/slice-implementer.md +1 -1
- package/package/corpus/agents/spec-writer.md +1 -1
- package/package/corpus/harnesses/pi/extensions/cratis-mcp/configuration.ts +4 -3
- package/package/corpus/harnesses/pi/extensions/cratis-mcp/index.ts +1 -1
- package/package/corpus/mcp-servers.json +0 -1
- package/package/corpus/prompts/add-reactor.prompt.md +1 -1
- package/package/corpus/prompts/new-vertical-slice.prompt.md +2 -2
- package/package/corpus/prompts/write-specs.prompt.md +2 -2
- package/package/corpus/rules/ai-distribution.md +2 -1
- package/package/corpus/rules/application-profile.md +1 -1
- package/package/corpus/rules/cratis-folder-is-configuration.md +28 -0
- package/package/corpus/rules/general.md +6 -1
- package/package/corpus/rules/profiles.md +5 -4
- package/package/corpus/rules/reactors.md +1 -1
- package/package/corpus/rules/vertical-slices.md +1 -1
- package/package/corpus/skills/cratis-application-react-specifications/SKILL.md +1 -1
- package/package/corpus/skills/cratis-application-slice-conformance/SKILL.md +2 -2
- package/package/corpus/skills/cratis-application-slice-conformance/references/contract-and-precedence.md +1 -1
- package/package/corpus/skills/cratis-application-slice-specifications/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-command/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-command-execution/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-command-validation/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-observable-query-http/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-query-paging/SKILL.md +1 -1
- package/package/corpus/skills/cratis-arc-react-page/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-event-constraints/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-event-modeling/SKILL.md +2 -2
- package/package/corpus/skills/cratis-chronicle-event-type-migration/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-projection/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-reactor/SKILL.md +2 -2
- package/package/corpus/skills/cratis-chronicle-read-model/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-read-model-specifications/SKILL.md +1 -1
- package/package/corpus/skills/cratis-chronicle-reducer/SKILL.md +1 -1
- package/package/corpus/skills/cratis-components-stepper-command-dialog/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-captures-and-reactions/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-command-surface/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-command-surface/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-discovery/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-event-modeling/SKILL.md +9 -6
- package/package/corpus/skills/cratis-screenplay-event-modeling/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-model-authoring/SKILL.md +12 -10
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-loop.md +3 -4
- package/package/corpus/skills/cratis-screenplay-model-authoring/references/mcp-tools.md +3 -3
- package/package/corpus/skills/cratis-screenplay-model-authoring/verification.json +3 -3
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/SKILL.md +5 -5
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/opt-in.md +4 -4
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/phases.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md +1 -1
- package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/verification.json +1 -1
- package/package/corpus/skills/cratis-screenplay-projections/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-projections/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-read-surface/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-read-surface/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-specifications/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-specifications/verification.json +2 -2
- package/package/corpus/skills/cratis-screenplay-toolchain/SKILL.md +1 -1
- package/package/corpus/skills/cratis-screenplay-toolchain/references/versions.md +1 -1
- package/package/corpus/skills/cratis-screenplay-ui-composition/SKILL.md +5 -2
- package/package/corpus/skills/cratis-screenplay-ui-composition/verification.json +2 -2
- package/package/corpus/skills/cratis-specification-by-example/SKILL.md +1 -1
- package/package/corpus/skills/cratis-specifications-csharp/SKILL.md +1 -1
- package/package.json +1 -1
|
@@ -199,7 +199,7 @@ children.
|
|
|
199
199
|
## Route near misses
|
|
200
200
|
|
|
201
201
|
- An accepted `.play` model under the model root covers the behavior, or the
|
|
202
|
-
repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD
|
|
202
|
+
repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or the project set
|
|
203
203
|
`mcpServers.screenplay.root` in `.cratis/ai.json`; an empty directory, install
|
|
204
204
|
output, an uncommitted `.play` draft or a `.play` file outside the root does not count; master definition:
|
|
205
205
|
`cratis-screenplay-modeling-lifecycle`): change the model first with
|
|
@@ -12,11 +12,14 @@ slice runs when something happens.
|
|
|
12
12
|
|
|
13
13
|
## Locate the model
|
|
14
14
|
|
|
15
|
-
Look first
|
|
15
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
16
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
17
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
18
|
+
configuration and the shared AI corpus only. This is the
|
|
16
19
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
17
20
|
location or search the whole repository before checking it.
|
|
18
21
|
|
|
19
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
20
23
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
21
24
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
22
25
|
source is the single flow model.
|
|
@@ -17,11 +17,11 @@
|
|
|
17
17
|
},
|
|
18
18
|
{
|
|
19
19
|
"kind": "skill-contains",
|
|
20
|
-
"value": "
|
|
20
|
+
"value": "Look first for the project's existing `.play` files"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"kind": "skill-contains",
|
|
24
|
-
"value": "`cratis ai install` manages `.cratis/ai/`,
|
|
24
|
+
"value": "`cratis ai install` manages `.cratis/ai/`, never model files"
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
"kind": "skill-contains",
|
|
@@ -12,11 +12,14 @@ they are all built from.
|
|
|
12
12
|
|
|
13
13
|
## Locate the model
|
|
14
14
|
|
|
15
|
-
Look first
|
|
15
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
16
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
17
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
18
|
+
configuration and the shared AI corpus only. This is the
|
|
16
19
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
17
20
|
location or search the whole repository before checking it.
|
|
18
21
|
|
|
19
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
20
23
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
21
24
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
22
25
|
source is the single flow model.
|
|
@@ -15,11 +15,11 @@
|
|
|
15
15
|
{ "kind": "skill-contains", "value": "`reads X optional` is not supported yet" },
|
|
16
16
|
{
|
|
17
17
|
"kind": "skill-contains",
|
|
18
|
-
"value": "
|
|
18
|
+
"value": "Look first for the project's existing `.play` files"
|
|
19
19
|
},
|
|
20
20
|
{
|
|
21
21
|
"kind": "skill-contains",
|
|
22
|
-
"value": "`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
"value": "`cratis ai install` manages `.cratis/ai/`, never model files"
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
25
|
"kind": "skill-contains",
|
|
@@ -28,7 +28,7 @@ syntax and tool commands in `cratis-screenplay-toolchain`.
|
|
|
28
28
|
existing code or a database as the source (`cratis-screenplay-legacy-extraction`).
|
|
29
29
|
- Small change to an existing model (one or two events): enter at step 5.
|
|
30
30
|
- Model-first: work in `.play` where an accepted model under the model root covers the scope or
|
|
31
|
-
the repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD
|
|
31
|
+
the repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or the project explicitly set
|
|
32
32
|
`mcpServers.screenplay.root` in `.cratis/ai.json`). Otherwise stay code-first; only the
|
|
33
33
|
entry-point session proposes a model, at most once per session; the master definition is in
|
|
34
34
|
`cratis-screenplay-modeling-lifecycle`. A direct request to model this scope is itself consent.
|
|
@@ -37,7 +37,7 @@ into the work that acts on them. Flag a real trade-off to the user instead of re
|
|
|
37
37
|
**1. Decide the level (short form; master copy in `cratis-screenplay-modeling-lifecycle`).**
|
|
38
38
|
Check first that the method skills are installed; installing them never opts a
|
|
39
39
|
repository in. The work is **model-first** only in an opted-in repository: the model
|
|
40
|
-
root (
|
|
40
|
+
root (the folder holding the project's `.play` files) holds a committed `.play` file (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or the project explicitly set
|
|
41
41
|
`mcpServers.screenplay.root` in `.cratis/ai.json`. An empty directory, install output,
|
|
42
42
|
an installed skill, a `.play` file outside the root or an untracked or uncommitted draft is not
|
|
43
43
|
opt-in; staged or untracked files under the root are drafts. A committed file with uncommitted
|
|
@@ -87,11 +87,14 @@ keeps the activities, Screenplay output and facilitation questions of each step:
|
|
|
87
87
|
|
|
88
88
|
## Locate the model
|
|
89
89
|
|
|
90
|
-
Look first
|
|
90
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
91
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
92
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
93
|
+
configuration and the shared AI corpus only. This is the
|
|
91
94
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
92
95
|
location or search the whole repository before checking it.
|
|
93
96
|
|
|
94
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
97
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
95
98
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
96
99
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
97
100
|
source is the single flow model.
|
|
@@ -232,7 +235,7 @@ The full critic pass (evidence, severity, business-question review) is
|
|
|
232
235
|
|
|
233
236
|
## Choose a file layout
|
|
234
237
|
|
|
235
|
-
Treat
|
|
238
|
+
Treat the model folder as one application and choose the coarsest layout
|
|
236
239
|
that keeps both the source and its diffs readable:
|
|
237
240
|
|
|
238
241
|
- Keep one `application.play` while it stays readable top to bottom.
|
|
@@ -323,10 +326,10 @@ order of modules, features or slices.
|
|
|
323
326
|
## Verify
|
|
324
327
|
|
|
325
328
|
```shell
|
|
326
|
-
screenplay
|
|
329
|
+
screenplay <model-folder> --warnaserror
|
|
327
330
|
```
|
|
328
331
|
|
|
329
|
-
(The standalone tool; `cratis screenplay validate
|
|
332
|
+
(The standalone tool; `cratis screenplay validate <model-folder> --warnings-as-errors`
|
|
330
333
|
is the fallback, and neither names the other's verdict. Versions and commands:
|
|
331
334
|
`cratis-screenplay-toolchain`.)
|
|
332
335
|
|
|
@@ -17,11 +17,11 @@
|
|
|
17
17
|
},
|
|
18
18
|
{
|
|
19
19
|
"kind": "skill-contains",
|
|
20
|
-
"value": "
|
|
20
|
+
"value": "Look first for the project's existing `.play` files"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"kind": "skill-contains",
|
|
24
|
-
"value": "`cratis ai install` manages `.cratis/ai/`,
|
|
24
|
+
"value": "`cratis ai install` manages `.cratis/ai/`, never model files"
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
"kind": "skill-contains",
|
|
@@ -42,27 +42,29 @@ Never ask the user which folder to use before trying. Call `open-workspace` with
|
|
|
42
42
|
arguments first: a server started without a fixed root binds the folder the host or
|
|
43
43
|
launch directory offers (the client's single workspace root, else the working
|
|
44
44
|
directory when it holds `.play` files). Only when it answers that no root was given,
|
|
45
|
-
or that several roots are offered, pass `path`: `.
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
and carry a model between sessions with `workspaceJson`. A root fixed at launch
|
|
45
|
+
or that several roots are offered, pass `path`: the folder holding the project's `.play` files, otherwise the
|
|
46
|
+
folder the user names. Without a project, the server works in `Documents/Screenplay`
|
|
47
|
+
in the user's home folder, so do not invent a location. A root fixed at launch
|
|
49
48
|
cannot be switched: another `path` returns `RootChangeRefused`.
|
|
50
49
|
|
|
51
50
|
**Prefer a fixed root.** Screenplay up to 4.63.1 (so Cratis CLI 3.27.1) fails a
|
|
52
51
|
dynamic-root server right after `notifications/initialized` when the client
|
|
53
52
|
advertises roots; real hosts then drop the connection, and `open-workspace.path`
|
|
54
53
|
cannot prevent it. Start `screenplay mcp <model-folder>` or `cratis screenplay mcp`
|
|
55
|
-
in a project
|
|
54
|
+
in a project (it locates the model: the project's `.play` files, else `Source/` or `src/`, else `Screenplay/`).
|
|
56
55
|
Send `initialize` and `notifications/initialized` before any tool call;
|
|
57
56
|
`tools/list` returns 29 tools (30 on MCP-Apps hosts). Details:
|
|
58
57
|
[MCP loop](references/mcp-loop.md).
|
|
59
58
|
|
|
60
59
|
|
|
61
|
-
Look first
|
|
60
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
61
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
62
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
63
|
+
configuration and the shared AI corpus only. This is the
|
|
62
64
|
conventional home for consumer-owned `.play` source. The source is the single flow model;
|
|
63
65
|
keep explanatory Markdown in the owning repository's documentation.
|
|
64
66
|
|
|
65
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
67
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Select the
|
|
66
68
|
`cratis/screenplay` profile in the project's AI configuration. The corpus-owned
|
|
67
69
|
`mcp-servers.json` declares the Screenplay server; supported client registration
|
|
68
70
|
is owned by the Cratis CLI, which preserves other servers and user configuration.
|
|
@@ -70,7 +72,7 @@ is owned by the Cratis CLI, which preserves other servers and user configuration
|
|
|
70
72
|
The CLI entry point is:
|
|
71
73
|
|
|
72
74
|
```shell
|
|
73
|
-
cratis screenplay mcp
|
|
75
|
+
cratis screenplay mcp <model-folder>
|
|
74
76
|
```
|
|
75
77
|
|
|
76
78
|
It runs the bundled server. Do not ask the user to install a second global .NET
|
|
@@ -196,7 +198,7 @@ imports afterwards. See the
|
|
|
196
198
|
[language reference](references/language-reference.md) for placement rules.
|
|
197
199
|
|
|
198
200
|
Parent scaffolding carries no duplicated module forms or contributions. Compile
|
|
199
|
-
and validate the whole
|
|
201
|
+
and validate the whole model folder, or its root file, not just
|
|
200
202
|
the edited fragment.
|
|
201
203
|
|
|
202
204
|
## Preserve state and recover explicitly
|
|
@@ -254,7 +256,7 @@ that the code compiles or behaves. Path resolution and `PLAY0430`-`PLAY0434`:
|
|
|
254
256
|
The ordinary CLI remains useful for whole-folder validation:
|
|
255
257
|
|
|
256
258
|
```shell
|
|
257
|
-
cratis screenplay validate
|
|
259
|
+
cratis screenplay validate <model-folder> --warnings-as-errors
|
|
258
260
|
```
|
|
259
261
|
|
|
260
262
|
Repair and refactoring guidance follows Screenplay main `fd18129`. The Cratis
|
|
@@ -16,8 +16,8 @@ differ: read `tools/list`.
|
|
|
16
16
|
|
|
17
17
|
1. Launch with a **fixed root**: `screenplay mcp <model-folder>`, or
|
|
18
18
|
`cratis screenplay mcp <model-folder>`, or `cratis screenplay mcp` inside a
|
|
19
|
-
project
|
|
20
|
-
|
|
19
|
+
project, where the CLI locates the model (the project's `.play` files, else `Source/`
|
|
20
|
+
or `src/`, else a new `Screenplay/` folder; what the `cratis/screenplay` profile registers). Stdio, newline-delimited
|
|
21
21
|
JSON-RPC, one sequential connection.
|
|
22
22
|
2. Send `initialize`, then the `notifications/initialized` notification, **before
|
|
23
23
|
any tool call**. Earlier calls fail with `-32600` "Initialize and send
|
|
@@ -41,8 +41,7 @@ treat that as fatal and drop the connection. Passing `open-workspace.path` does
|
|
|
41
41
|
**not** avoid it, because the error is sent before `open-workspace` runs.
|
|
42
42
|
|
|
43
43
|
Avoid it by fixing the root at launch (the forms in step 1). The `cratis/screenplay`
|
|
44
|
-
profile registration is not affected in an installed project,
|
|
45
|
-
`.cratis/screenplay/` does not exist. Cratis CLI 3.27.1 bundles 4.60.1: for a
|
|
44
|
+
profile registration is not affected in an installed project, and the CLI now locates the model itself, so no model directory has to exist. Cratis CLI 3.27.1 bundles 4.60.1: for a
|
|
46
45
|
dynamic root there, fix the root.
|
|
47
46
|
|
|
48
47
|
## Who owns the connection
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
# Working with the Screenplay MCP
|
|
5
5
|
|
|
6
6
|
The supported CLI launch is `cratis screenplay mcp <model-root>`, or `cratis screenplay mcp`
|
|
7
|
-
alone inside a project
|
|
8
|
-
|
|
7
|
+
alone inside a project, where the CLI locates the model (the project's `.play` files, else
|
|
8
|
+
`Source/` or `src/`, else a new `Screenplay/` folder). The standalone form is `screenplay mcp <model-folder>`. A
|
|
9
9
|
server started with no root at all binds one on first use from `open-workspace`'s
|
|
10
10
|
`path`, the client's roots, or the working directory; that dynamic form hit the
|
|
11
11
|
roots bug in Screenplay up to 4.63.1 (see the [MCP loop](mcp-loop.md#roots-bug-and-the-workaround)),
|
|
12
|
-
so prefer a fixed root.
|
|
12
|
+
so prefer a fixed root. Without a project the server works in `Documents/Screenplay`. Model files never go under `.cratis/`. AI distribution provides the
|
|
13
13
|
profile-selected declaration and guidance; the CLI owns executable hosting and
|
|
14
14
|
client registration. Installation must preserve user-owned MCP servers and
|
|
15
15
|
report unsupported adapters or drift.
|
|
@@ -45,11 +45,11 @@
|
|
|
45
45
|
},
|
|
46
46
|
{
|
|
47
47
|
"kind": "skill-contains",
|
|
48
|
-
"value": "
|
|
48
|
+
"value": "Look first for the project's existing `.play` files"
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
51
|
"kind": "skill-contains",
|
|
52
|
-
"value": "`cratis ai install` manages `.cratis/ai/`,
|
|
52
|
+
"value": "`cratis ai install` manages `.cratis/ai/`, never model files"
|
|
53
53
|
},
|
|
54
54
|
{
|
|
55
55
|
"kind": "skill-contains",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
},
|
|
70
70
|
{
|
|
71
71
|
"kind": "skill-contains",
|
|
72
|
-
"value": "cratis screenplay mcp
|
|
72
|
+
"value": "cratis screenplay mcp <model-folder>"
|
|
73
73
|
},
|
|
74
74
|
{
|
|
75
75
|
"kind": "skill-contains",
|
|
@@ -3,7 +3,7 @@ name: cratis-screenplay-modeling-lifecycle
|
|
|
3
3
|
description: "Model first: load before any Cratis application work where a Screenplay `.play` model is, or should become, the source of truth. Holds the model-first decision rule, modes, independent verdicts V1-V5, the P0-P9 phases with Input / Carry-forward / Gate, stop-or-assume, identity ownership, approvals, untrusted content, session state and handoffs, then routes to ONE phase skill. Not for: Screenplay syntax or the compiler (use `cratis-screenplay-toolchain`), a single construct (use the `cratis-screenplay-*` construct skills), or Chronicle runtime diagnosis (use `cratis-chronicle-cli-operations`)."
|
|
4
4
|
license: MIT
|
|
5
5
|
metadata:
|
|
6
|
-
cratis-hint-paths: "
|
|
6
|
+
cratis-hint-paths: "**/*.play"
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Screenplay modeling lifecycle
|
|
@@ -18,10 +18,10 @@ an unproven pass.
|
|
|
18
18
|
|
|
19
19
|
## Decide the level first (master copy; run once per request, from any entry point)
|
|
20
20
|
|
|
21
|
-
1. **Opted in?** Only when (a) the model root (
|
|
22
|
-
configured root) holds a `.play` file **in the committed tree** (`git ls-tree -r --name-only HEAD
|
|
21
|
+
1. **Opted in?** Only when (a) the model root (the folder holding the project's `.play` files, or the project's
|
|
22
|
+
configured root) holds a `.play` file **in the committed tree** (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or (b)
|
|
23
23
|
the project explicitly set `mcpServers.screenplay.root` in `.cratis/ai.json` (an empty configured
|
|
24
|
-
root counts). **Not opt-in:** an empty
|
|
24
|
+
root counts). **Not opt-in:** an empty model folder or the MCP entry that `cratis ai
|
|
25
25
|
install`/`update` creates; an installed profile or skill; a `.play` file outside the root; a
|
|
26
26
|
staged or untracked `.play` file under the root (a draft). Committing a model under the root
|
|
27
27
|
is the team's act of acceptance and opts the repository in.
|
|
@@ -221,7 +221,7 @@ Stage `v4.24.0` (admits ESM v1-v3); opt-in key `mcpServers.screenplay.root` in c
|
|
|
221
221
|
`Documentation/reference/screenplay-mcp.md`. The worked example compiles with both tools.
|
|
222
222
|
## Verify
|
|
223
223
|
```shell
|
|
224
|
-
screenplay
|
|
224
|
+
screenplay <model-folder> --warnaserror --no-color
|
|
225
225
|
```
|
|
226
226
|
- [ ] The first output line states the mode; the last block opens with `Outcome:`; five verdict lines, each a result or "not run: <reason>".
|
|
227
227
|
- [ ] One phase skill per step; STATE.md names the next phase; no code for modeled behavior, no managed output edited.
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
The decision rule is in `SKILL.md` ("Decide the level first"). This file holds the evidence.
|
|
4
4
|
|
|
5
5
|
## Why an empty directory or an MCP entry is not opt-in
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
Through cratis CLI `v3.27.1` the `cratis/screenplay` profile (and composed profiles such as Stage)
|
|
7
|
+
made `cratis ai install`/`update` create the selected model directory, normally `.cratis/screenplay`
|
|
8
|
+
(`Documentation/ai/index.md`: "Install/update creates the selected
|
|
9
9
|
empty model directory ... but does not start the server or create source files"), and register
|
|
10
10
|
a Screenplay MCP entry for it. Uninstall keeps the directory. Both therefore appear in every
|
|
11
11
|
repository that merely installed the language skills, so neither can signal consent.
|
|
@@ -21,7 +21,7 @@ disables registration"; `AiConfiguration.McpServers`, read by `AiMcpDescriptor`
|
|
|
21
21
|
## Edge cases
|
|
22
22
|
- `.play` files only under `.ai-work/`, a docs folder or a sample: not under the root, so not opt-in.
|
|
23
23
|
- Acceptance is visible in the repository: the model root holds at least one `.play` file in
|
|
24
|
-
the committed tree (`git ls-tree -r --name-only HEAD
|
|
24
|
+
the committed tree (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured). Committing a model
|
|
25
25
|
under the root is the team's act of acceptance and opts the repository in. P6 commits the
|
|
26
26
|
accepted `.play` files and `.screenplay/identities.json` when present.
|
|
27
27
|
- Staged or untracked files under the root are drafts: they do not opt the repository in and
|
|
@@ -31,7 +31,7 @@ phase, a decision important enough that a later reader could misread the model (
|
|
|
31
31
|
`reasoning-notes.md` for when it belongs in a `description`).
|
|
32
32
|
|
|
33
33
|
## P0 Intake
|
|
34
|
-
- **Input**: the request, the repository,
|
|
34
|
+
- **Input**: the request, the repository, the project's model folder or the configured root.
|
|
35
35
|
- **Carry-forward**: mode; model root; tool check (versions per `cratis-screenplay-toolchain`);
|
|
36
36
|
the decision-rule outcome (model or code-first); STATE.md.
|
|
37
37
|
- **Gate**: mode stated; STATE.md exists; the five intake points (domain, source, goal, constraints,
|
package/package/corpus/skills/cratis-screenplay-modeling-lifecycle/references/verdicts-and-modes.md
CHANGED
|
@@ -149,7 +149,7 @@ LC_ALL=C sort -u "$tmp/manifest" > "$tmp/sorted" || fail "sort failed"
|
|
|
149
149
|
d=$(shasum -a 256 < "$tmp/sorted") || fail "digest failed"
|
|
150
150
|
echo "$commit+${d:0:12}"
|
|
151
151
|
```
|
|
152
|
-
Example: `ident.sh
|
|
152
|
+
Example: `ident.sh Source/Screenplay Source/Screenplay/.screenplay/identities.json src/Billing/Rule.cs`
|
|
153
153
|
(the identity catalog sits inside the root, so list it only if it lives elsewhere; duplicates are
|
|
154
154
|
merged). Record the output as the source identity; a changed digest invalidates acceptance. After the P6
|
|
155
155
|
commit, recompute it: the digest must equal the one reviewed at P5 (only the commit part may differ). Add the
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"skill": "cratis-screenplay-modeling-lifecycle",
|
|
3
|
-
"input": "Add a berth allocation feature to this Cratis application that already has a
|
|
3
|
+
"input": "Add a berth allocation feature to this Cratis application that already has a Screenplay model. How should the work be done and verified?",
|
|
4
4
|
"fixtures": [],
|
|
5
5
|
"assertions": [
|
|
6
6
|
{ "kind": "skill-contains", "value": "Model first" },
|
|
@@ -12,11 +12,14 @@ text. This is half of every event model, and the half most easily got wrong.
|
|
|
12
12
|
|
|
13
13
|
## Locate the model
|
|
14
14
|
|
|
15
|
-
Look first
|
|
15
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
16
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
17
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
18
|
+
configuration and the shared AI corpus only. This is the
|
|
16
19
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
17
20
|
location or search the whole repository before checking it.
|
|
18
21
|
|
|
19
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
20
23
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
21
24
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
22
25
|
source is the single flow model.
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
{ "kind": "skill-contains", "value": "main `fd18129`" },
|
|
7
7
|
{ "kind": "skill-contains", "value": "it changes no projection contract" },
|
|
8
8
|
{ "kind": "skill-contains", "value": "map the read-model identity from `$eventSourceId`" },
|
|
9
|
-
{ "kind": "skill-contains", "value": "
|
|
10
|
-
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`,
|
|
9
|
+
{ "kind": "skill-contains", "value": "Look first for the project's existing `.play` files" },
|
|
10
|
+
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`, never model files" },
|
|
11
11
|
{ "kind": "skill-contains", "value": "AutoMap is on by default" },
|
|
12
12
|
{ "kind": "skill-contains", "value": "PLAY0191" },
|
|
13
13
|
{ "kind": "skill-contains", "value": "every event type in the system" },
|
|
@@ -11,11 +11,14 @@ shape, the `query` is the entry point, and the `screen` renders it.
|
|
|
11
11
|
|
|
12
12
|
## Locate the model
|
|
13
13
|
|
|
14
|
-
Look first
|
|
14
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
15
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
16
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
17
|
+
configuration and the shared AI corpus only. This is the
|
|
15
18
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
16
19
|
location or search the whole repository before checking it.
|
|
17
20
|
|
|
18
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
21
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
19
22
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
20
23
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
21
24
|
source is the single flow model.
|
|
@@ -7,8 +7,8 @@
|
|
|
7
7
|
{ "kind": "skill-contains", "value": "filter status InvoiceStatus optional" },
|
|
8
8
|
{ "kind": "skill-contains", "value": "query Q => observable?" },
|
|
9
9
|
{ "kind": "skill-contains", "value": "information `PLAY0479`" },
|
|
10
|
-
{ "kind": "skill-contains", "value": "
|
|
11
|
-
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`,
|
|
10
|
+
{ "kind": "skill-contains", "value": "Look first for the project's existing `.play` files" },
|
|
11
|
+
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`, never model files" },
|
|
12
12
|
{ "kind": "skill-contains", "value": "The tenant is the default and stays unstated" },
|
|
13
13
|
{ "kind": "skill-contains", "value": "belongs on a `from` parameter, never on a `filter`" },
|
|
14
14
|
{ "kind": "skill-contains", "value": "warnings, not errors" },
|
|
@@ -12,11 +12,14 @@ concrete data.
|
|
|
12
12
|
|
|
13
13
|
## Locate the model
|
|
14
14
|
|
|
15
|
-
Look first
|
|
15
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
16
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
17
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
18
|
+
configuration and the shared AI corpus only. This is the
|
|
16
19
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
17
20
|
location or search the whole repository before checking it.
|
|
18
21
|
|
|
19
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
20
23
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
21
24
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
22
25
|
source is the single flow model.
|
|
@@ -21,11 +21,11 @@
|
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
"kind": "skill-contains",
|
|
24
|
-
"value": "
|
|
24
|
+
"value": "Look first for the project's existing `.play` files"
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
"kind": "skill-contains",
|
|
28
|
-
"value": "`cratis ai install` manages `.cratis/ai/`,
|
|
28
|
+
"value": "`cratis ai install` manages `.cratis/ai/`, never model files"
|
|
29
29
|
},
|
|
30
30
|
{
|
|
31
31
|
"kind": "skill-contains",
|
|
@@ -15,7 +15,7 @@ skill answers "does it compile, bind, render, and which compiler said so". The m
|
|
|
15
15
|
|
|
16
16
|
## Locate the model
|
|
17
17
|
|
|
18
|
-
Look first in the model root: `.
|
|
18
|
+
Look first in the model root: the folder holding the project's `.play` files (else `Source/` or `src/`, else `Screenplay/`), or the root the project set with `mcpServers.screenplay.root` in `.cratis/ai.json`. A folder of `.play`
|
|
19
19
|
files is one application: always check the folder, never one file of it.
|
|
20
20
|
|
|
21
21
|
## Verified product sources
|
|
@@ -79,7 +79,7 @@ not prove the older compiler: read the construct it names.
|
|
|
79
79
|
| Exit codes | 0 pass; 5 errors (or warnings with `--warnings-as-errors`); 1 path missing **or no `.play` files**. Information never fails | probed |
|
|
80
80
|
| Output | JSON lines: a `diagnostics` array with `severity`, `code`, `message`, `location`, then either `{"path","files","diagnostics":0}` or an error object. A passing folder run prints the file count | probed on 3.27.1 |
|
|
81
81
|
| File versus folder | file mode compiles one document and **ignores imports** (cli#244). Validate the folder | probed |
|
|
82
|
-
| MCP | `cratis screenplay mcp <root>`, or no argument inside a project
|
|
82
|
+
| MCP | `cratis screenplay mcp <root>`, or no argument inside a project: the server locates the model itself (existing `.play` files, else `Source/`/`src/`, else a new `Screenplay/` folder) unless `.cratis/ai.json` sets `mcpServers.screenplay.root`; 29 tools, no event-source, stream or route views. Fails fast only when an explicitly configured root does not exist | source `ScreenplayMcpRoot.cs:20-37` |
|
|
83
83
|
| Render | `cratis render` binds with the bundled compiler first, then Stage 4.24.0 admits. See `renderable-subset.md` | source |
|
|
84
84
|
| `prologue interpret` | no `--no-llm` flag; LLM resolution and `screenplay generate` flags were checked on 3.27.0 | source |
|
|
85
85
|
|
|
@@ -12,11 +12,14 @@ entries other modules contribute are all declared in the `.play` model.
|
|
|
12
12
|
|
|
13
13
|
## Locate the model
|
|
14
14
|
|
|
15
|
-
Look first
|
|
15
|
+
Look first for the project's existing `.play` files: the folder holding them is the
|
|
16
|
+
model. A new model goes under the repository's `Source/` or `src/` folder, else in a
|
|
17
|
+
`Screenplay/` folder at the repository root; never under `.cratis/`, which holds
|
|
18
|
+
configuration and the shared AI corpus only. This is the
|
|
16
19
|
conventional home for consumer-owned `.play` source; do not invent another
|
|
17
20
|
location or search the whole repository before checking it.
|
|
18
21
|
|
|
19
|
-
`cratis ai install` manages `.cratis/ai/`,
|
|
22
|
+
`cratis ai install` manages `.cratis/ai/`, never model files. Never
|
|
20
23
|
hand-copy Screenplay source between repositories. Keep Markdown that explains,
|
|
21
24
|
questions or navigates the model in the repository's documentation; the `.play`
|
|
22
25
|
source is the single flow model.
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
{ "kind": "skill-contains", "value": "invoiceId = $eventSourceId" },
|
|
9
9
|
{ "kind": "skill-contains", "value": "InvoiceStatusView optional" },
|
|
10
10
|
{ "kind": "skill-contains", "value": "An existing success continuation does not imply a response contract" },
|
|
11
|
-
{ "kind": "skill-contains", "value": "
|
|
12
|
-
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`,
|
|
11
|
+
{ "kind": "skill-contains", "value": "Look first for the project's existing `.play` files" },
|
|
12
|
+
{ "kind": "skill-contains", "value": "`cratis ai install` manages `.cratis/ai/`, never model files" },
|
|
13
13
|
{ "kind": "skill-contains", "value": "A form is discovered, not referenced" },
|
|
14
14
|
{ "kind": "skill-contains", "value": "declares no\n`fits slot`" },
|
|
15
15
|
{ "kind": "skill-contains", "value": "override-priority order" },
|
|
@@ -54,7 +54,7 @@ before claiming behavior for another version.
|
|
|
54
54
|
model). Decide this with the decision rule in
|
|
55
55
|
`cratis-screenplay-modeling-lifecycle`: model-first only when an accepted
|
|
56
56
|
model under the model root covers this scope, or the repository is opted in
|
|
57
|
-
(the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD
|
|
57
|
+
(the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or the project set `mcpServers.screenplay.root`
|
|
58
58
|
in `.cratis/ai.json`); an empty directory, install output, a `.play` file
|
|
59
59
|
outside the root or an uncommitted draft does not count, and framework, infrastructure, client, adapter and not-opted-in
|
|
60
60
|
brownfield work stays code-first. Opted in but no model for this scope: model
|
|
@@ -36,7 +36,7 @@ another version. Never translate an assertion or helper name from memory.
|
|
|
36
36
|
plain `Specification` base in this file and do not reach for the scenario
|
|
37
37
|
family except to test the very engine that repository provides.
|
|
38
38
|
- An accepted `.play` model under the model root covers the behavior, or the
|
|
39
|
-
repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD
|
|
39
|
+
repository is opted in (the root holds a committed `.play` file (`git ls-tree -r --name-only HEAD` lists a `.play` file there, narrowed to `-- <root>` when a root is configured), or the project set
|
|
40
40
|
`mcpServers.screenplay.root` in `.cratis/ai.json`; an empty directory, install
|
|
41
41
|
output, an uncommitted `.play` draft or a `.play` file outside the root does not count; master definition:
|
|
42
42
|
`cratis-screenplay-modeling-lifecycle`): change the model first with
|