@cesarus777/opencode-cgp 0.1.0 → 0.2.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/README.md +6 -2
- package/dist/cli.js +1411 -0
- package/dist/core.js +424 -3
- package/dist/index.js +1087 -29
- package/dist/rpc.js +159 -0
- package/dist/tui.js +461 -49
- package/dist/types/adapter.d.ts +2 -0
- package/dist/types/chartreport.d.ts +14 -0
- package/dist/types/charts.d.ts +54 -0
- package/dist/types/core.d.ts +2 -0
- package/dist/types/family.d.ts +1 -1
- package/dist/types/history.d.ts +59 -0
- package/dist/types/historycharts.d.ts +17 -0
- package/dist/types/historyserver.d.ts +7 -0
- package/dist/types/performance.d.ts +57 -0
- package/dist/types/rpc.d.ts +78 -0
- package/dist/types/snapshot.d.ts +4 -1
- package/dist/types/snapshotserver.d.ts +3 -3
- package/dist/types/tui/chartformat.d.ts +11 -0
- package/dist/types/tui/charts.d.ts +10 -0
- package/dist/types/tui/format.d.ts +1 -0
- package/dist/types/tui/state.d.ts +1 -0
- package/dist/types/types.d.ts +11 -0
- package/package.json +9 -3
package/README.md
CHANGED
|
@@ -41,10 +41,10 @@ Global configuration is `~/.config/opencode/opencode.jsonc` (or the OpenCode con
|
|
|
41
41
|
|
|
42
42
|
Restart/reload OpenCode and look for `context-guard: observe; diagnostics ...`. Observe mode records policy decisions and never requests compaction; OpenCode's own automatic compaction remains active. Inspect diagnostics first, then set `mode` to `enforce` to admit native compaction at runtime step boundaries. The complete [example](examples/opencode.jsonc) includes model, role, and agent policies. **Last matching rule wins**; selectors within a rule are ANDed.
|
|
43
43
|
|
|
44
|
-
|
|
44
|
+
Pin the exact published version in the existing entry's `package` field or use the manager. Version `0.2.1` includes performance metrics, history charts, and CLI reports.
|
|
45
45
|
|
|
46
46
|
```sh
|
|
47
|
-
opencode plugin add @cesarus777/opencode-cgp@0.1
|
|
47
|
+
opencode plugin add @cesarus777/opencode-cgp@0.2.1
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
Manage the configured target with the [official V2 CLI](https://dev.opencode.ai/v2/docs/plugins):
|
|
@@ -100,6 +100,10 @@ Open `/context-guard` or **Open Context Guard** in the command palette for curre
|
|
|
100
100
|
|
|
101
101
|
The TUI reads bounded snapshots over public OpenCode RPC, including when telemetry is disabled. Remote clients also need a client-side package registration in `cli.json`; see [the example](examples/cli.jsonc) and [controls, installation and bounds](docs/configuration.md#native-context-guard-view). It targets the inspected 2.0.29 API. The actual local host passes wide root, child and narrow grandchild panel checks. Use **Context Guard: open panel** above a child composer, where the host hides its usual prompt and palette shortcut. tmux, Neovim and cross-machine remote validation remain open.
|
|
102
102
|
|
|
103
|
+
Per-session live TPS, average model throughput, average session throughput and observed TTFT appear in the selected session and child rows. Live TPS and TTFT use `~` to mark estimates; completed rates use provider totals. Configurable local history defaults to seven days with a 64 MiB total cap, independently of diagnostic telemetry. See [metric definitions and history exports](docs/configuration.md#live-performance-and-retained-history).
|
|
104
|
+
|
|
105
|
+
Press **c** in the Context Guard panel for retained-history terminal charts; use **[ / ]** to change the time window and **Up / Down** to select an agent instance. Generate a self-contained interactive browser report with `bun run charts /absolute/history-directory --output report.html`. It includes filters, UTC timestamp tooltips, request statistics and SVG export. Installed packages expose the same command as `context-guard charts ...` (Bun required). See [chart controls and limits](docs/configuration.md#performance-charts).
|
|
106
|
+
|
|
103
107
|
## Inspect
|
|
104
108
|
|
|
105
109
|
The startup message reports a location-specific JSONL file under `$XDG_STATE_HOME/opencode-context-guard/` (default `~/.local/state/opencode-context-guard/`). A custom absolute `telemetry.path` is supported. Use a distinct file per plugin location/process.
|