@testmuai/rook-skill 0.1.11 → 0.1.14

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.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@testmuai/rook-skill",
3
- "version": "0.1.11",
3
+ "version": "0.1.14",
4
4
  "description": "Install the Rook agent-testing skill for Claude Code, Codex and Gemini CLI",
5
5
  "type": "module",
6
6
  "bin": {
package/skills/SKILL.md CHANGED
@@ -76,6 +76,12 @@ and `run|report --rca`. `profile test` invokes the target without Rook model cre
76
76
  Use paid RCA only with user authorization. Track the user's budget across
77
77
  commands; do not assume the CLI enforces an aggregate task cap. Check its help
78
78
  for available limits. A null balance means unknown.
79
+ Rook checks the organisation's Agent Assurance plan before any model call or
80
+ credit spend, whatever the balance. A `plan_required` or `upgrade_plan` refusal
81
+ names the page that lifts it (billing, or onboarding to start a free trial); pass that link to the user instead of
82
+ retrying. A plan without Rook cloud runs locally: when sync or cloud status is
83
+ refused, use `rook run --test` for a local result. See
84
+ [troubleshooting](references/troubleshooting.md).
79
85
  Prefer scoped `--allow` grants; use `--yes` only within the authorized scope.
80
86
  See [headless contracts](references/headless-contract.md) for output, grants and
81
87
  credit accounting.
@@ -67,6 +67,9 @@ required for the gate.
67
67
  `rook sync --yes` records the scenarios/profile upstream. If the requested CI
68
68
  result should remain local instead, omit sync and use `rook run --test` with the
69
69
  same flags and result checks. Do not silently switch between these policies.
70
+ Since 0.1.13, a plan without Rook cloud, such as Starter, refuses `sync` with
71
+ `upgrade_plan`, so the job fails at that step. Switch to the local policy only
72
+ if the user chooses it; otherwise pass on the upgrade link the refusal names.
70
73
 
71
74
  Cache the project `.testmuai/rook/` for history and comparisons. Never cache or
72
75
  commit `~/.testmuai/rook/`. `--yes` supplies broad command-scoped tool consent;
@@ -27,6 +27,7 @@ Commands that emit JSON write one document to stdout and prose to stderr.
27
27
  | Other `mcp` operations | `{ ok, lines: string[] }`, with configuration inside `lines` |
28
28
  | `ask` | `{ answer, command?, blocked_by?, summary? }`; the suggested command is not executed |
29
29
  | `update auto` | `{ ok, pinned }`; changes the update-notice preference |
30
+ | `doctor` (0.1.12+) | `{ version, diagnostic_session, diagnostic_log, upstream_session, session_logs, registration, log_level, node, os, workspace, environment, controller, api, identity, auth, project, mode, tty, env }`; `os` is `{ name, version, arch }`, `controller` and `api` are `{ url, status }`, `env` holds the terminal facts, and unreadable parts are null |
30
31
 
31
32
  `status.agents[].tree` is `unsynced`, `clean`, `ahead`, `diverged`, `behind` or
32
33
  `unknown`. Unknown means offline, not clean.
@@ -35,7 +36,9 @@ Some releases emit text despite accepting `--json` on `explore`, `generate`,
35
36
  `sync`, `profile add/fix/test`, `report --rca` and `update` without `auto`.
36
37
  Check for a JSON document before parsing; otherwise inspect exit status and
37
38
  saved files. After authorized RCA, use `rook report <run-id> --json` to read the result.
38
- `rook update` may replace the CLI; check its version afterward.
39
+ `rook update` may replace the CLI; check its version afterward. Since 0.1.12 a
40
+ Homebrew install runs `brew upgrade` itself and exits 1 when Homebrew installs
41
+ nothing new, for example while the tap trails a new npm release.
39
42
 
40
43
  ## Errors and partial runs
41
44
 
@@ -51,6 +54,13 @@ Use `error`, or `reason` when present. Translate remedy tokens with
51
54
  - A command that calls the model controller or opens an upstream job refuses
52
55
  before anything runs or is charged when its session could not be registered.
53
56
  Report it as no run and no spend, using the diagnostic it returns.
57
+ - Since 0.1.12, `sync` exits 1 when the service leaves any agent it was sent
58
+ unanswered, even after recording others; the summary adds `N not returned` or
59
+ `N malformed`. Those agents keep their previous local state. Sync again
60
+ before a run that depends on them.
61
+ - A `run` whose evidence uploads to the project failed keeps its exit code and
62
+ JSON; stderr adds `N evidence upload(s) failed — see <log path>`. Report the
63
+ project's copy of that evidence as incomplete.
54
64
 
55
65
  ## Grants and accounting
56
66
 
@@ -90,6 +100,13 @@ assuming either form. Under its `agents/<agent-id>/` directory:
90
100
  | `runs/<run-id>/scenarios/<scenario-id>/` | `snapshot.yaml`, `request.json`, `response.json`, artifacts and `verdict.yaml` |
91
101
 
92
102
  Home state at `~/.testmuai/rook/` includes credentials, grants and session
93
- transcripts. Each session's `transcript.jsonl` records the raw input and output
94
- of every role call, including refused, failed and interrupted calls. Keep it
103
+ transcripts. Each session's `transcript.jsonl` records the input and output of
104
+ every role call, including refused, failed and interrupted calls. Since 0.1.12
105
+ it also records tool calls, each message sent to the target and its reply,
106
+ jobs, per-agent sync results, run phases and scenario outcomes, so a killed run
107
+ keeps the turns it exchanged. Lines carry `v: 2`: object keys starting with `$`
108
+ gain one extra `$`, and strings of 4 KiB or more move to a `blobs/` folder
109
+ beside the transcript, replaced by `{"$blob": "sha256:<hex>", "bytes": n}`.
110
+ Check `v` on each line; a resumed session can mix v1 and v2 lines. Credential
111
+ masking is best effort and older transcripts are unmasked, so keep transcripts
95
112
  outside commits and shared evidence.
@@ -25,3 +25,13 @@ declared, with no approval step.
25
25
  When `explore` finds `.mcp.json` in the target, those servers appear with
26
26
  origin `discovered` and need `approve` before a scenario can exercise them.
27
27
  Values stay `${VAR}` references in `get` output.
28
+
29
+ Since 0.1.14 an `http` server connects over Streamable HTTP. A `project` or
30
+ `discovered` one waits for `approve` like a stdio server, and a changed host
31
+ needs approval again. `get` and `approve` print `sends the value of VAR to
32
+ <host>` for each variable an http server receives, and values of 8 or more
33
+ characters expanded from `${VAR}` are removed from what it sends back. Each
34
+ request has a 20 s deadline and an 8 MiB limit, and redirects are refused.
35
+ `sse` and `ws` servers stay `unsupported-transport`. On every transport, a
36
+ tool list without `tools`, a result without `content` or a text block with no
37
+ text is a malformed response, not an empty success.
@@ -23,7 +23,7 @@ references.
23
23
  ## Generating
24
24
 
25
25
  ```bash
26
- rook generate --json # functional + adversarial, rook picks the count
26
+ rook generate --json # functional + adversarial planned, rook picks the count
27
27
  rook generate --total 20 --class functional --json
28
28
  rook generate --category prompt_injection,jailbreak --json
29
29
  rook generate -- focus on the refund limits and the identity check
@@ -64,10 +64,17 @@ grading without reported usage, is skipped by `run` and counts toward the
64
64
  assurance gap, not toward Fail. File and image requirements are not rejected
65
65
  solely by their input kind: inspect what the profile script can actually send.
66
66
  `generate` keeps a scenario it cannot make runnable instead of dropping it:
67
- `executable: false` with a `skip_reason` starting `coverage gap:`,
68
- `invalid scenario:` or `invalid red-team scenario:`. Attack patterns with no
69
- scenario for a feature are listed in the agent's `coverage-gaps.yaml`. Report
70
- both as gaps, not as failures.
67
+ `executable: false` with a `skip_reason`. Reasons from rook's own validation
68
+ start with `coverage gap:`, `invalid scenario:` or `invalid red-team
69
+ scenario:`; the scenario checker writes plain sentences, often a precondition
70
+ the profile cannot establish. Do not match on the prefix to find them; read
71
+ `executable`. Attack patterns with no scenario for a feature are listed in the
72
+ agent's `coverage-gaps.yaml` and the report's coverage gaps. Report both as
73
+ gaps, not as failures.
74
+
75
+ A plain `generate` can plan no attacks for a small agent. When the user asked
76
+ for red-team coverage and none was written, run
77
+ `rook generate --class adversarial --json` and say so.
71
78
 
72
79
  Some attack patterns are skipped until the profile has the hook they need,
73
80
  and the skip reason names it: an `open` hook that seeds the fixture in
@@ -9,9 +9,11 @@ rook plan --json
9
9
  rook status --json
10
10
  ```
11
11
 
12
- `doctor` prints version, node, workspace, environment, controller and api
13
- reachability, identity, auth state, project, mode (`cli`, `tui` or `headless`)
14
- and tty.
12
+ `doctor` prints version, node, OS, workspace, environment, controller and api
13
+ reachability, identity, auth state, project, mode (`cli`, `tui` or `headless`),
14
+ tty and the terminal (shell, privilege, color level, size); a field it cannot
15
+ detect reads `unknown`. Since 0.1.12, `rook doctor --json` prints the same
16
+ report as one JSON object; see [headless contracts](headless-contract.md).
15
17
 
16
18
  ## Failure documents
17
19
 
@@ -36,6 +38,8 @@ from `ok: true` or from an old report on disk.
36
38
  | `remedy: explore_agents` | no agents registered — `rook explore` |
37
39
  | `remedy: pick_agent` | no agent selected — `rook agent use <id>` |
38
40
  | `remedy: topup` | you are out of credits — check `rook plan` and add credits |
41
+ | `remedy: plan_required` | the org has no active Agent Assurance plan (none, an ended free trial or an expired subscription), whatever its credit balance — nothing ran or was charged; give the user the link the refusal names: since 0.1.14, the onboarding page to start the free trial when the org never had a plan, otherwise billing |
42
+ | `remedy: upgrade_plan` | the plan has no Rook cloud (such as Starter) — sync, cloud project status and recording runs on Rook cloud are refused; keep work local with `rook run --test`, or give the user the upgrade link the refusal names |
39
43
  | `remedy: reconcile` | this agent has diverged from upstream — `rook sync` |
40
44
  | `remedy: update` | this version is too old to be served — announce that `rook update` may install a newer version, then recheck skill compatibility |
41
45
  | `remedy: report` | a client bug — file an issue with `rook export logs` attached |
@@ -43,6 +47,10 @@ from `ok: true` or from an old report on disk.
43
47
  | no project selected | `rook project use <id>` or `rook project create <name>` |
44
48
  | could not reach the service | check the network; `doctor` shows both endpoints |
45
49
 
50
+ A plan refusal shows the billing page that lifts it as the next step; Rook uses
51
+ only https links on LambdaTest or TestMu AI hosts. Do not retry the refused
52
+ command until the plan changes.
53
+
46
54
  ## Discovery succeeds but registers no agents
47
55
 
48
56
  An exit-zero `explore` with `0 analysed` does not establish that the target is
@@ -90,4 +98,8 @@ rook export logs --out ./rook-logs.zip --all-sessions
90
98
  ```
91
99
 
92
100
  Include `rook --version`, the OS, and the scenario and run ids. Never paste a
93
- transcript, a credential, or the contents of `~/.testmuai/rook/`.
101
+ transcript, a credential, or the contents of `~/.testmuai/rook/`. The bundle
102
+ carries session transcripts and their `blobs/` folders. Since 0.1.12 Rook masks
103
+ the credentials it holds or recognises before writing a transcript line, best
104
+ effort; transcripts from older versions are not masked. Let the user review the
105
+ bundle before it is shared.
@@ -22,6 +22,12 @@ can add `coverage_gaps`, `redteam_coverage` (OWASP coverage of the scenario
22
22
  inventory) and `summary_claims`; an unmapped control is unverified, not passed.
23
23
  A **Partial** stored by an older run reads as Unable to Verify.
24
24
 
25
+ Since 0.1.12, a regex check that misses is graded by the judge on the
26
+ criterion's meaning, so a correct answer in another format can pass. A match
27
+ still passes at once, and a regex asserting that text is absent still fails
28
+ when the text appears. The judge call can add credits; if it fails, the
29
+ criterion is Unable to Verify, not Fail.
30
+
25
31
  ## Pass rate
26
32
 
27
33
  Since 0.1.6, `totals.pass_rate` is `Pass / (Pass + Fail + Unable to Verify)`.