@patterkit/cli 0.5.5 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -0
- package/dist/cli.js +7653 -605
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -128,6 +128,34 @@ patter play --scene scn_tavern --choices opt_work,opt_secret
|
|
|
128
128
|
patter play --seed 42
|
|
129
129
|
```
|
|
130
130
|
|
|
131
|
+
### `patter coverage [path]`
|
|
132
|
+
|
|
133
|
+
Play the story many times with random choices and count how often each beat comes
|
|
134
|
+
up, to find content no player can reach. The summary counts beats reached, never
|
|
135
|
+
reached, and rarely reached (in fewer than 5% of runs), and says how the runs
|
|
136
|
+
ended: reached the end, stalled at a choice with nothing to pick, or hit the step
|
|
137
|
+
limit. The table gives each beat's **reached** (the share of runs that played it)
|
|
138
|
+
and **played** (times it played in all runs), least reached first. Marks: `‼`
|
|
139
|
+
never reached, `?` never reached but may just need an input driver, `~` rarely
|
|
140
|
+
reached. Choices that ran dry (nothing to take and no fallback) are listed too.
|
|
141
|
+
|
|
142
|
+
| Option | Values | Meaning |
|
|
143
|
+
|--------|--------|---------|
|
|
144
|
+
| `--runs <n>` | integer | How many playthroughs (default 5000). |
|
|
145
|
+
| `--max-steps <n>` | integer | Steps before a run is stopped (default 200). |
|
|
146
|
+
| `--seed <n>` | integer | The same seed gives the same result. |
|
|
147
|
+
| `--scene <id>` / `--block <id>` | id | Start here instead of the project's start. |
|
|
148
|
+
| `--order <o>` | `least` / `script` | Least reached first (default), or the script's order, scene by scene. |
|
|
149
|
+
| `--fail-on-gap` | | Exit 1 if any beat is never reached (a CI gate). |
|
|
150
|
+
| `--propose` | | Print suggested `@world` input drivers instead of running. |
|
|
151
|
+
| `--json` | | The full report as JSON. |
|
|
152
|
+
|
|
153
|
+
```sh
|
|
154
|
+
patter coverage
|
|
155
|
+
patter coverage --runs 10000 --seed 7 --order script
|
|
156
|
+
patter coverage --fail-on-gap
|
|
157
|
+
```
|
|
158
|
+
|
|
131
159
|
### `patter resolve <query> [path]`
|
|
132
160
|
|
|
133
161
|
Look up an **id**, **handle**, or **name** and report what it is and where it
|