diff --git a/.agents/triage-backlog.md b/.agents/triage-backlog.md index 9f3fb75a..aebcaf6b 100644 --- a/.agents/triage-backlog.md +++ b/.agents/triage-backlog.md @@ -30,7 +30,7 @@ cd - && git worktree remove --force /port `upstream-merge.py` has no dry-run mode and writes files, so this second throwaway worktree is the dry run. Report its verbatim, clean-merge and needs-review counts. Exit 1 means review is needed. Exit 2 means the script refused its input. Report the two apart. -Tag each item port-only or Cursor-derived, by the paths it edits (a PR's files) or names, as `UPSTREAM.md` and `NOTICE.md` map them; an item that names none is tagged from its subject, and the tag says so. Before a local fix to a Cursor-derived file is scheduled, check the source that `UPSTREAM.md` or `NOTICE.md` names for that path for an existing fix, such as `git log cursor/main -- pstack/` for the pstack tree. An "upstream first" disposition is finished only when the authorized upstream action exists and its link is in the plan. For an issue already closed upstream-first, record whether the upstream PR exists, and act only when its reopen condition fired. Distinguish model providers from parent harnesses; T3 Code is a supported parent harness. Done when the counts, the exit code and a tag for each item are in the plan. +Tag each item port-only or Cursor-derived, by the paths it edits (a PR's files) or names, as `UPSTREAM.md` and `NOTICE.md` map them; an item that names none is tagged from its subject, and the tag says so. Before a local fix to a Cursor-derived file is scheduled, check the source that `UPSTREAM.md` or `NOTICE.md` names for that path for an existing fix, such as `git log cursor/main -- pstack/` for the pstack tree. An "upstream first" disposition is finished only when the authorized upstream action exists and its link is in the plan. For an issue already closed upstream-first, record whether the upstream PR exists, and act only when its reopen condition fired. Distinguish model providers from parent harnesses; T3 Code, Grok and OpenCode are supported parent harnesses. Done when the counts, the exit code and a tag for each item are in the plan. ### Steps 2 (Collect) and 5 (Release lag): model snapshot, release procedure and model lag diff --git a/.claude-plugin/marketplace.json b/.claude-plugin/marketplace.json index f526c3fb..31c218ea 100644 --- a/.claude-plugin/marketplace.json +++ b/.claude-plugin/marketplace.json @@ -3,13 +3,13 @@ "owner": { "name": "Eric Litman" }, - "description": "Pstack for Claude Code and Codex, tracking Cursor's upstream pstack.", + "description": "Pstack for Claude Code, Codex, Grok and OpenCode, tracking Cursor's upstream pstack.", "plugins": [ { "name": "pstack", "source": "./plugins/pstack", "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence.", - "version": "1.21.0", + "version": "1.22.0", "author": { "name": "Lauren Tan (original)" }, diff --git a/.claude/skills/verify-open-pstack/features/registry.json b/.claude/skills/verify-open-pstack/features/registry.json index 4e13683e..44274242 100644 --- a/.claude/skills/verify-open-pstack/features/registry.json +++ b/.claude/skills/verify-open-pstack/features/registry.json @@ -21,6 +21,7 @@ ], "shared": [ "plugins/pstack/.claude-plugin/plugin.json", "plugins/pstack/.codex-plugin/plugin.json", "plugins/pstack/.grok-plugin/plugin.json", + "plugins/pstack/package.json", "plugins/pstack/bun.lock", "plugins/pstack/opencode/**", ".claude-plugin/marketplace.json", ".agents/plugins/marketplace.json", "plugins/pstack/agents/poteto-agent.md", "plugins/pstack/agents/comment-sicko.md", "plugins/pstack/grok-agents/poteto-agent.md", "plugins/pstack/grok-agents/comment-sicko.md", "plugins/pstack/hooks/**", diff --git a/.gitignore b/.gitignore index c5bafef5..15bcac7f 100644 --- a/.gitignore +++ b/.gitignore @@ -12,4 +12,6 @@ plugins/pstack/skills/poteto-mode/scripts/node_modules/ plugins/pstack/skills/statechart/scripts/node_modules/ +plugins/pstack/node_modules/ + __pycache__/ diff --git a/AGENTS.md b/AGENTS.md index 940aa189..c3318837 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -2,7 +2,7 @@ Track all durable work in this repository's GitHub Issues. Do not create a parallel Linear queue. Build a ticket that comes from a waived review finding only after that failure has been seen in real use; until then the ticket records the finding and stays unscheduled. Read `UPSTREAM.md` before changing upstream-derived content. -Cursor's `cursor/plugins/pstack` tree is the content upstream. Keep one shared skill tree for Claude Code, Codex, Grok and T3 Code. Grok is a parent harness and owns its own configuration and skill installation. T3 Code owns orchestration, and the app it runs, Claude Code or Codex, owns configuration and skill installation. Adapt harness primitives at the existing mapping boundaries instead of forking skills or adding compatibility layers. The parent harness resolves provider routing once. Children do not detect or reroute themselves. +Cursor's `cursor/plugins/pstack` tree is the content upstream. Keep one shared skill tree for Claude Code, Codex, Grok, OpenCode and T3 Code. Grok and OpenCode are parent harnesses and own their own configuration and skill installation. T3 Code owns orchestration, and the app it runs, Claude Code, Codex or OpenCode, owns configuration and skill installation. Adapt harness primitives at the existing mapping boundaries instead of forking skills or adding compatibility layers. The parent harness resolves provider routing once. Children do not detect or reroute themselves. Code this repository owns explains itself. `UPSTREAM.md`, `CHANGES.md` and `NOTICE.md` say which files are local adaptations or additions. Upstream-derived files keep upstream's comments, so later syncs stay clean. In owned code, a comment stays only if it is a legal or license header, an explanation of behaviour forced by a vendor, platform or protocol we cannot change, a formatter directive, a doc comment that defines a public API contract, or an issue or RFC link for a constraint that code cannot express. When owned code would surprise a reader, reshape it (rename, extract, add a type) instead of explaining it. Encode a "must not change" constraint as a type, test or lint, then delete its comment. Suppress a lint or type error only when its rule is wrong, pedantic or style-only; otherwise fix the cause. pstack's `no-comments` skill applies this rule. diff --git a/CHANGES.md b/CHANGES.md index 4fb27e08..f8f667d3 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,6 +3,22 @@ Open Pstack lands on green: Mergify merges a ready PR to main once verify and exact-head live-gate pass and no review thread is unresolved, and a workflow resolves Unfret's own threads. A PR that touches `.github/` or the Mergify config also waits for Unfret, and workflow changes require operator queueing. This port applies the Cursor → Claude Code substitutions in skill bodies. Earlier drafts left them flagged; this revision resolves them. A later pass added a Codex build that shares the same skills; see [Codex port](#codex-port) below. +## 1.22.0 adds OpenCode as a parent harness + +Open Pstack 1.22.0 keeps the Cursor pstack 0.15.36 sync. Default roles and panels are unchanged. + +**OpenCode is a parent harness.** The port adds `opencode` to `PARENTS` with `native: "subagent"` and `explicitLaneRoute: "runner"`. A native `inherit-parent` or `auto` lane calls OpenCode's `subagent` tool with `agent: "poteto-agent"` and inherits the parent session's model. Every explicit descriptor, including every `opencode:*` descriptor, uses the runner with `--parent opencode`, whose receipt proves the served model. The runner's route table now has an OpenCode parent column, and `pstack-runner` accepts `--parent opencode`. + +**One package, two OpenCode lines.** `plugins/pstack/package.json` exposes the OpenCode server plugin at `opencode/index.ts`, and one default export serves both versions: OpenCode 2.4 calls `setup`, which imports the v2 client inside the call, and OpenCode 1.19 calls `server`, which returns v1 hooks. On 2.x the plugin reads the shared `skills/` tree and registers each `SKILL.md` by its directory ID, maps `disable-model-invocation: true` and `user-invocable: false` to `opencode/autoinvoke: false`, registers `poteto-agent` and `comment-sicko` as model-free subagents, adds `/pstack/poteto-mode` and `/pstack/setup-pstack`, appends the OpenCode startup context to a session's first model call, and appends `/pstack-models.md` to each model call. On 1.x the same plugin appends the skill root to `skills.paths`, where 1.x exposes each skill as a slash command and has no skill tool, registers the same two subagents, and pushes a 1.x brief plus the model sheet through `experimental.chat.system.transform`. The skill bodies are not forked. Install 2.x with an `opencode.jsonc` `plugins` entry or `opencode plugin add 'github:/open-pstack#main::path:plugins/pstack'`; install 1.x by pointing the singular `plugin` array at the package directory, because its `plugin add` installs npm modules only. + +**OpenCode provider updated to V2.** OpenCode 2.4.0 dropped `--pure` and `--variant`, takes the effort as the model's `#variant`, and lists every configured model with `opencode models`. The adapter now passes `--auto`, `-m #`, and matches the exact model line without a provider argument. The run-owned config uses V2's ordered `permissions` rules. The 1.19.1 provider notes remain for the sandbox measurements. + +**Docs and setup.** `codex-tools.md` gains an OpenCode column, an OpenCode config home (`OPENCODE_CONFIG_DIR`, then `XDG_CONFIG_HOME/opencode`, then `$HOME/.config/opencode`), a transcript fallback, reflect copy paths, and a Waits on OpenCode section. `provider-dispatch.md` gains the OpenCode parent route, T3 runtime sentence, native lane, external lane, and read-only/writer mapping. `setup-pstack` writes the OpenCode sheet and probes native and external lanes through the same steps. Skill bodies that named Claude-only transcript, `loop`, MCP, driver, or project-skill paths now name the OpenCode path or tool beside them. The README, `docs/reference.md`, `AGENTS.md`, `UPSTREAM.md` and `NOTICE.md` name OpenCode. + +**Bugbot is detection-only.** pstack never launches, requests, or waits for Bugbot, and setup never calls it. `watch-pr` only annotates Bugbot comments that already exist, and a PR with no Bugbot comments is zero Bugbot passes. A regression test fails if plugin code, setup, or a playbook names a Bugbot command. + +**Not applied.** No Cursor content changes in this release. The Slack and GitHub triage surfaces this repository uses are unchanged; `.agents/triage-backlog.md` records GitHub Issues as the tracker, and pstack has no Slack integration to port. + ## 1.21.0 adds Grok as a parent harness Open Pstack 1.21.0 keeps the Cursor pstack 0.15.36 sync. Default roles and panels are unchanged. diff --git a/NOTICE.md b/NOTICE.md index c6f7b90f..4031d51c 100644 --- a/NOTICE.md +++ b/NOTICE.md @@ -44,6 +44,7 @@ Summary of structural changes: - Claude-native lanes are port-authored agent definitions. Fable, Opus and Sonnet select their rolling family alias, and the Opus 5.5 and Haiku 5.5 pins select their exact model, each with the requested effort, for every selectable Claude-native pair in the model catalog. `registry/render.ts` generates them from the runner registry. - A Codex build shares the same `skills/` tree. It adds `plugins/pstack/.codex-plugin/plugin.json`, a root `.agents/plugins/marketplace.json`, and `plugins/pstack/skills/poteto-mode/references/codex-tools.md` (the Claude-to-Codex tool, model, and built-in map), plus a one-line Platform note in the skills that name a Claude primitive. The skill content itself is unchanged. See [CHANGES.md](CHANGES.md#codex-port). - A Grok build shares the same `skills/` tree. It adds `plugins/pstack/.grok-plugin/plugin.json`, the generated `plugins/pstack/grok-agents/` copies of `poteto-agent` and `comment-sicko`, and Grok rows in `codex-tools.md`, `provider-dispatch.md` and `setup-pstack/SKILL.md` (#281, started from max-metaplanet's PR #282). +- An OpenCode build shares the same `skills/` tree. It adds `plugins/pstack/package.json`, `plugins/pstack/opencode/index.ts` (the server plugin that registers the skills, `poteto-agent`, `comment-sicko`, the `/pstack/` commands, and the model sheet), `plugins/pstack/opencode/session-start-context.md`, and OpenCode rows in `codex-tools.md`, `provider-dispatch.md` and `setup-pstack/SKILL.md`. ## Modifications @@ -55,6 +56,7 @@ Files authored for this port (not derived from upstream): - `.claude-plugin/marketplace.json` (repo root) - `plugins/pstack/.codex-plugin/plugin.json` - `plugins/pstack/.grok-plugin/plugin.json` +- `plugins/pstack/package.json`, `plugins/pstack/opencode/index.ts`, `plugins/pstack/opencode/session-start-context.md` (the OpenCode server plugin, commands, subagents and startup context) - `.agents/plugins/marketplace.json` (repo root) - `plugins/pstack/skills/poteto-mode/references/codex-tools.md` - `plugins/pstack/skills/poteto-mode/scripts/bootstrap.test.ts` diff --git a/README.md b/README.md index ac51439c..be9475ee 100644 --- a/README.md +++ b/README.md @@ -4,21 +4,21 @@ [![Latest release](https://img.shields.io/github/v/release/ericlitman/open-pstack)](https://github.com/ericlitman/open-pstack/releases/latest) [![MIT license](https://img.shields.io/github/license/ericlitman/open-pstack)](LICENSE) -**Open Pstack brings [Lauren Tan (@poteto)](https://x.com/poteto)'s [pstack](https://github.com/cursor/plugins/tree/main/pstack) to Claude Code, Codex and Grok, and to T3 Code running Claude Code or Codex.** Its job is to stay as close to her original work as possible while translating the parts that depend on Cursor. +**Open Pstack brings [Lauren Tan (@poteto)](https://x.com/poteto)'s [pstack](https://github.com/cursor/plugins/tree/main/pstack) to Claude Code, Codex, Grok and OpenCode, and to T3 Code running Claude Code, Codex or OpenCode.** Its job is to stay as close to her original work as possible while translating the parts that depend on Cursor. Lauren built pstack from the skills she uses to ship code at Cursor. In a [55-minute interview with Denis Labelle](https://x.com/DenisLabelle/status/2091337807939706928), she says that she shipped 1,000 pull requests in one month after steadily improving how her agents work and verify their results. > If you want to go fast, go deep first. -Open Pstack is an unofficial community project. In Cursor, use [Lauren's original pstack](https://github.com/cursor/plugins/tree/main/pstack). In Codex, use Open Pstack. In Claude Code, you have two choices. Lauren's `pstack@cursor-plugins` has Claude models only and runs the Grok and GPT roles on the session's Claude model. Open Pstack also runs in Codex, and runs other providers' models through their own command-line tools. Install only one of the two in Claude Code, because both use the `pstack:` prefix. +Open Pstack is an unofficial community project. In Cursor, use [Lauren's original pstack](https://github.com/cursor/plugins/tree/main/pstack). In Codex, use Open Pstack. In Claude Code, you have two choices. Lauren's `pstack@cursor-plugins` has Claude models only and runs the Grok and GPT roles on the session's Claude model. Open Pstack also runs in Codex, Grok and OpenCode, and runs other providers' models through their own command-line tools. Install only one of the two in Claude Code, because both use the `pstack:` prefix. ## What Open Pstack adds Compared with Lauren's pstack, Open Pstack adds: - **A model and provider registry.** Models, efforts and providers live in one typed [registry](plugins/pstack/skills/poteto-mode/scripts/runner/registry/). The [model catalog](plugins/pstack/skills/poteto-mode/references/model-catalog.md) and the Claude-native agent files are generated from it, and the skills point at the catalog's role defaults instead of naming models. A new model is one registry entry. A new command-line provider is one adapter module and one line in the provider list. See the [design](docs/plans/2026-10-11-model-provider-registry.md). -- **One skill tree for Claude Code and Codex.** Both apps read the same skills, and one [reference](plugins/pstack/skills/poteto-mode/references/codex-tools.md) maps how each app starts them. Lauren's pstack does not run in Codex. See [Claude Code, Codex and Grok](#claude-code-codex-and-grok) below. -- **Models from other providers.** Claude Code and Codex hand work to other providers' models through each provider's own command-line tool, started by one [runner](plugins/pstack/skills/poteto-mode/references/provider-dispatch.md). The runner supports nine providers. Claude, Codex and Grok run lanes that read or write files. Devin, DeepSeek Harness, Antigravity, OpenCode, Amp and Cursor CLI run read-only lanes. The model catalog's [routes table](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes) lists how each one starts. A Grok parent runs `inherit-parent` and `auto` with `spawn_subagent`, and every explicit descriptor, including Grok models, through the runner with `--parent grok`. Each run leaves a receipt with the exact model flags and, where the provider reports it, the model that answered. Every provider except Claude and Codex gets only an allowlisted environment. A Claude lane that writes files runs in Claude Code's Bash sandbox, with writes to the shared Git directory denied. A model that cannot run fails visibly; the runner never switches to a weaker model. +- **One skill tree for Claude Code, Codex, Grok and OpenCode.** All four apps read the same skills, and one [reference](plugins/pstack/skills/poteto-mode/references/codex-tools.md) maps how each app starts them. Lauren's pstack does not run in Codex or OpenCode. See [Claude Code, Codex, Grok and OpenCode](#claude-code-codex-grok-and-opencode) below. +- **Models from other providers.** Claude Code, Codex, Grok and OpenCode hand work to other providers' models through each provider's own command-line tool, started by one [runner](plugins/pstack/skills/poteto-mode/references/provider-dispatch.md). The runner supports ten providers. Claude, Codex and Grok run lanes that read or write files. Devin, DeepSeek Harness, Antigravity, OpenCode, Amp and Cursor CLI run read-only lanes. The model catalog's [routes table](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes) lists how each one starts. A Grok parent runs `inherit-parent` and `auto` with `spawn_subagent`, and every explicit descriptor, including Grok models, through the runner with `--parent grok`. An OpenCode parent runs `inherit-parent` and `auto` with `subagent`, and every explicit descriptor, including OpenCode models, through the runner with `--parent opencode`. Each run leaves a receipt with the exact model flags and, where the provider reports it, the model that answered. Every provider except Claude and Codex gets only an allowlisted environment. A Claude lane that writes files runs in Claude Code's Bash sandbox, with writes to the shared Git directory denied. A model that cannot run fails visibly; the runner never switches to a weaker model. - **Runs inside T3 Code.** In [T3 Code](plugins/pstack/skills/poteto-mode/references/provider-dispatch.md#t3-host), pstack keeps each role's model and effort. T3 starts each lane whose provider it offers, and the runner starts the rest. - **A checked model sheet.** [`setup-pstack`](plugins/pstack/skills/setup-pstack/SKILL.md) records each role as `provider:model@effort`, asks for one effort per model family, and probes each chosen model before it saves anything. A rerun that changes nothing keeps the sheet without asking again. - **Three-model panels.** `arena`, `architect` and `interrogate` default to Opus, Sol and Grok. Lauren's pstack defaults to Opus 5.5 and Grok; Open Pstack keeps three ([UPSTREAM.md](UPSTREAM.md)). @@ -44,7 +44,7 @@ pstack does not ask you to trust an agent on day one. It helps the agent leave e ## Install -You need a current Claude Code or Codex installation. For the default three-model review, install and authenticate the Claude Code, Codex, and Grok command-line tools. [Bun](https://bun.sh) runs the small local tool that starts models outside the app you are using. You can still use the core workflows with fewer models. You need another provider's command-line tool only when your model sheet assigns that provider. +You need a current Claude Code, Codex or OpenCode installation. For the default three-model review, install and authenticate the Claude Code, Codex, and Grok command-line tools. [Bun](https://bun.sh) runs the small local tool that starts models outside the app you are using. You can still use the core workflows with fewer models. You need another provider's command-line tool only when your model sheet assigns that provider. ### Claude Code @@ -76,6 +76,51 @@ multi_agent = true Start a new Codex task after installation so it can discover the new skills and setting. +### OpenCode + +pstack supports OpenCode 2.x and the 1.19 line from the same package. OpenCode calls the entry point its version knows: 2.x calls `setup`, 1.x calls `server`. + +**OpenCode 2.x.** Install the package from the repository's main branch: + +```shell +opencode plugin add 'github:/open-pstack#main::path:plugins/pstack' +``` + +On this fork, use: + +```shell +opencode plugin add 'github:Rawknee-69/opencode-pstack#main::path:plugins/pstack' +``` + +**OpenCode 1.x.** `opencode plugin add` installs npm modules, so add the package path to the `plugin` array (singular) in `~/.config/opencode/opencode.json`. The path is a clone of this repository, and 1.x loads it with no install step: + +```jsonc +{ + "$schema": "https://opencode.ai/config.json", + "plugin": ["/absolute/path/to/open-pstack/plugins/pstack"] +} +``` + +#### Install with a prompt + +Paste this prompt into OpenCode 2.x: + +> Install pstack support into OpenCode 2. Run `opencode plugin add 'github:Rawknee-69/opencode-pstack#main::path:plugins/pstack'`, confirm the command exits 0, and tell me to restart OpenCode. Do not edit project files. After I restart, remind me to run `/pstack/setup-pstack`. + +Paste this prompt into OpenCode 1.x, after cloning this repository: + +> Add `/absolute/path/to/open-pstack/plugins/pstack` to the `plugin` array in my global `opencode.json`, leave every other setting alone, and tell me to restart OpenCode. Do not run `opencode plugin add`; it installs npm modules only. After I restart, remind me to run `/setup-pstack`. + +#### What loads + +On 2.x, the plugin registers every pstack skill with OpenCode's skill registry, registers `poteto-agent` and `comment-sicko` as subagents, adds `/pstack/poteto-mode` and `/pstack/setup-pstack`, and appends the startup context and `/pstack-models.md` to model calls. Load a skill with the `skill` tool or `@poteto-mode`. + +On 1.x, the plugin adds the same skill tree through `skills.paths`, so OpenCode exposes each skill as a slash command (`/poteto-mode`, `/setup-pstack`, `/babysit`, and so on) and has no `skill` tool. It registers the same two subagents and appends a 1.x routing brief plus the model sheet to each model call. + +**Check it loaded.** 2.x lists config-declared plugins with `opencode plugin list` and the installed commit with `opencode plugin check`. Both read the global config home (`OPENCODE_CONFIG_DIR`, then `XDG_CONFIG_HOME/opencode`, then `~/.config/opencode`), so a project-level install, a `--pure` session, or a different home explains `No plugins found`; a running server also keeps the list it loaded at startup until you restart. 1.x has no plugin list: `opencode debug skill` shows pstack skills located inside the package, and `opencode debug agent poteto-agent` shows the subagent. + +Restart OpenCode after installing. It loads plugins at server startup, so the session that ran the install keeps its old registries. Then run `/pstack/setup-pstack` on 2.x or `/setup-pstack` on 1.x. Either writes `/pstack-models.md`, which the plugin loads on later model calls. + ## Get started Lauren's original setup has two steps. Open Pstack keeps the same flow. @@ -138,7 +183,7 @@ That is the main workflow. The other skills are there when poteto-mode needs the | `in-your-own-words` | You want the agent to restate your goal and the problem before it starts. | | `sharpen` | You want a prompt rewritten deeper, not bigger, before you send it. It returns the rewritten prompt and does not do the task. | -Plugin skills include `pstack:` in their name. In Claude Code, invoke a native skill such as `/pstack:architect`. In Codex, ask for the skill, such as `Use pstack:architect for this design.` See the [technical reference](docs/reference.md) for the full list. +Plugin skills include `pstack:` in their name in Claude Code and Codex. In Claude Code, invoke a native skill such as `/pstack:architect`. In Codex, ask for the skill, such as `Use pstack:architect for this design.` In OpenCode 2.x, use the plain ID, such as `@architect` or the `skill` tool; on 1.x, run `/architect`. See the [technical reference](docs/reference.md) for the full list. ## Models and token use @@ -146,18 +191,18 @@ Some pstack workflows use one model. Skills such as `architect`, `arena`, and `i `setup-pstack` lets you choose the models, one requested effort per model family you assign, and how many run in parallel. A model from the app you are using runs inside that app. Other models run through their own command-line tools, as the [routes table](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes) shows. Open Pstack does not quietly replace a failed model with a weaker one. -## Claude Code, Codex and Grok +## Claude Code, Codex, Grok and OpenCode -Both apps read the same pstack skills. Only the way they start those skills and models is different. +All four apps read the same pstack skills. Only the way they start those skills and models is different. -| | Claude Code | Codex | Grok | -| --- | --- | --- | --- | -| Start poteto-mode | Claude loads a small startup instruction that can route non-trivial work into it. You can also run `/pstack:poteto-mode` yourself. | Ask for `pstack:poteto-mode` by name. Codex does not load the Claude startup instruction. | Run `/pstack:poteto-mode` by name. The Claude startup instruction does not fire in Grok. | -| Runs inside the app | Claude models stay inside Claude Code. | Codex models, such as Sol, stay inside Codex. | `inherit-parent` and `auto` stay inside Grok. | -| Other models | Codex, Grok and the other external providers run through their command-line tools ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | Claude, Grok and the other external providers run through their command-line tools ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | Every explicit model, including Grok models, runs through its command-line tool ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | -| Skills and workflows | Shared with Codex and Grok. | Shared with Claude Code and Grok. | Shared with Claude Code and Codex. | +| | Claude Code | Codex | Grok | OpenCode | +| --- | --- | --- | --- | --- | +| Start poteto-mode | Claude loads a small startup instruction that can route non-trivial work into it. You can also run `/pstack:poteto-mode` yourself. | Ask for `pstack:poteto-mode` by name. Codex does not load the Claude startup instruction. | Run `/pstack:poteto-mode` by name. The Claude startup instruction does not fire in Grok. | Run `/pstack/poteto-mode`, mention `@poteto-mode`, or ask for the `poteto-mode` skill. The plugin injects its own startup instruction. | +| Runs inside the app | Claude models stay inside Claude Code. | Codex models, such as Sol, stay inside Codex. | `inherit-parent` and `auto` stay inside Grok. | `inherit-parent` and `auto` stay inside OpenCode. | +| Other models | Codex, Grok and the other external providers run through their command-line tools ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | Claude, Grok and the other external providers run through their command-line tools ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | Every explicit model, including Grok models, runs through its command-line tool ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | Every explicit model, including OpenCode models, runs through the runner with `--parent opencode` ([routes](plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes)). | +| Skills and workflows | Shared with Codex, Grok and OpenCode. | Shared with Claude Code, Grok and OpenCode. | Shared with Claude Code, Codex and OpenCode. | Shared with Claude Code, Codex and Grok, with plain skill IDs and the `skill` tool on 2.x and slash commands on 1.x. | -The other providers take part only through the runner. Open Pstack itself runs inside Claude Code, Codex or Grok. In T3 Code, the app T3 runs loads the skills and the model sheet, and T3 starts each lane whose provider it offers. +The other providers take part only through the runner. Open Pstack itself runs inside Claude Code, Codex, Grok or OpenCode. In T3 Code, the app T3 runs (Claude Code, Codex or OpenCode) loads the skills and the model sheet, and T3 starts each lane whose provider it offers. ## Learn from the original @@ -173,7 +218,7 @@ This repository also keeps: ## Staying close to Lauren's pstack -Open Pstack 1.21.0 tracks pstack 0.15.36 at Cursor commit [`2776ddd2355d6d6c8747d3964600f28daf62f049`](https://github.com/cursor/plugins/commit/2776ddd2355d6d6c8747d3964600f28daf62f049). +Open Pstack 1.22.0 tracks pstack 0.15.36 at Cursor commit [`2776ddd2355d6d6c8747d3964600f28daf62f049`](https://github.com/cursor/plugins/commit/2776ddd2355d6d6c8747d3964600f28daf62f049). The two projects have separate version numbers. The pstack version identifies Lauren's upstream content. The Open Pstack version identifies the Claude Code and Codex package built from it. @@ -183,7 +228,7 @@ In this repository, “upstream” means Lauren's original pstack. Open Pstack d Fixes for Claude Code or Codex and help bringing over new pstack releases are welcome. Search [GitHub Issues](https://github.com/ericlitman/open-pstack/issues) before opening a new issue. For larger behavior changes, explain why the change belongs in Open Pstack instead of Lauren's original project. -Read [UPSTREAM.md](UPSTREAM.md) before changing content brought over from Lauren's pstack. Pull requests must keep one shared skill tree for Claude Code, Codex, Grok and T3 Code and pass the repository's tests, type checks, plugin validation, and static checks. +Read [UPSTREAM.md](UPSTREAM.md) before changing content brought over from Lauren's pstack. Pull requests must keep one shared skill tree for Claude Code, Codex, Grok, OpenCode and T3 Code and pass the repository's tests, type checks, plugin validation, and static checks. ## License diff --git a/UPSTREAM.md b/UPSTREAM.md index 452a93e1..33c864c8 100644 --- a/UPSTREAM.md +++ b/UPSTREAM.md @@ -10,9 +10,9 @@ open-pstack tracks [Cursor's pstack](https://github.com/cursor/plugins/tree/main | Path | `pstack/` | | Commit | `2776ddd2355d6d6c8747d3964600f28daf62f049` | | Upstream version | `0.15.36` | -| open-pstack version | `1.21.0` | +| open-pstack version | `1.22.0` | -The table above is the current Cursor sync point. Open Pstack 1.17.0 imported this 0.15.36 sync, and 1.18.0 to 1.21.0 keep it. `README-UPSTREAM.md` preserves the upstream pstack README verbatim. `CHANGES.md` and `NOTICE.md` describe the adaptations and provenance. +The table above is the current Cursor sync point. Open Pstack 1.17.0 imported this 0.15.36 sync, and 1.18.0 to 1.22.0 keep it. `README-UPSTREAM.md` preserves the upstream pstack README verbatim. `CHANGES.md` and `NOTICE.md` describe the adaptations and provenance. ## Upstream-only exclusions @@ -73,6 +73,8 @@ The table above is the current Cursor sync point. Open Pstack 1.17.0 imported th - **#281 — Grok parent**: Cursor has no Grok parent. Started from max-metaplanet's PR #282. The port adds `grok` to `PARENTS` with `explicitLaneRoute: "runner"`, so the generated route table has a Grok parent column and the runner accepts `--parent grok`, including a Grok provider. Claude and Codex keep `native` and stay native-only for their own provider. It adds `plugins/pstack/.grok-plugin/plugin.json` and the generated `grok-agents/` directory, a Grok column and a Waits on Grok section in `codex-tools.md`, the Grok rules in `provider-dispatch.md`, and the Grok sheet in `setup-pstack/SKILL.md` at its existing steps. Keep these lines during syncs. +- **OpenCode parent**: Cursor has no OpenCode parent. The port adds `opencode` to `PARENTS` with `native: "subagent"` and `explicitLaneRoute: "runner"`, so the generated route table has an OpenCode parent column and the runner accepts `--parent opencode`, including an OpenCode provider. It adds the `@open-pstack/pstack` package at `plugins/pstack/package.json`, the server plugin `plugins/pstack/opencode/index.ts` that registers the shared skills, `poteto-agent` and `comment-sicko`, `/pstack/poteto-mode`, `/pstack/setup-pstack`, and the model sheet, an OpenCode column and a Waits on OpenCode section in `codex-tools.md`, the OpenCode rules in `provider-dispatch.md`, and the OpenCode sheet in `setup-pstack/SKILL.md`. The plugin's startup context replaces the Claude SessionStart hook, which does not fire in OpenCode. Keep these lines during syncs. + ## Check for changes The repository already names Cursor's repository as the `cursor` remote in the maintainer checkout. A fresh clone can add it once: diff --git a/docs/reference.md b/docs/reference.md index a6af5699..85816e05 100644 --- a/docs/reference.md +++ b/docs/reference.md @@ -2,7 +2,7 @@ This page contains the full skill, dependency, runtime, and porting reference. For the plain-English introduction and quick start, see the [main README](../README.md). -[Poteto](https://x.com/poteto)'s [pstack](https://github.com/cursor/plugins/tree/main/pstack), adapted to run in Claude Code, Codex, T3 Code and Grok without Cursor. One shared skill tree serves all four harnesses, and in T3 Code the Claude Code or Codex runtime loads it; lanes on other providers' models, including Grok and seven more providers, run through the bundled runner. Version 1.21.0 is synced to Cursor pstack v0.15.36 at `2776ddd2355d6d6c8747d3964600f28daf62f049`. See [UPSTREAM.md](../UPSTREAM.md) for the exact sync contract. +[Poteto](https://x.com/poteto)'s [pstack](https://github.com/cursor/plugins/tree/main/pstack), adapted to run in Claude Code, Codex, T3 Code, Grok and OpenCode without Cursor. One shared skill tree serves all five harnesses, and in T3 Code the Claude Code, Codex or OpenCode runtime loads it; lanes on other providers' models, including Grok, OpenCode and six more providers, run through the bundled runner. Version 1.22.0 is synced to Cursor pstack v0.15.36 at `2776ddd2355d6d6c8747d3964600f28daf62f049`. See [UPSTREAM.md](../UPSTREAM.md) for the exact sync contract. Original by Lauren Tan. This distribution builds on Michael Denyer's [pstack-claude](https://github.com/michael-denyer/pstack-claude) port and retains its history and MIT attribution. It imports seven MIT-licensed skills from [cursor-team-kit](https://github.com/cursor/plugins/tree/main/cursor-team-kit): `deslop`, `thermo-nuclear-code-quality-review`, `make-pr-easy-to-review`, `fix-ci`, `fix-merge-conflicts`, `get-pr-comments`, `what-did-i-get-done`. @@ -60,7 +60,9 @@ The marketplace install is the normal user path. Direct links are only for testi │ ├── .claude-plugin/plugin.json # Claude Code manifest │ ├── .codex-plugin/plugin.json # Codex manifest (skills: ./skills/) │ ├── .grok-plugin/plugin.json # Grok manifest (skills: ./skills/, agents: ./grok-agents/) -│ ├── skills/ # 65 skills shared by Claude Code and Codex +│ ├── package.json # OpenCode package: exports ./opencode/index.ts +│ ├── opencode/ # OpenCode server plugin, startup context and package typecheck +│ ├── skills/ # 65 skills shared by Claude Code, Codex, Grok and OpenCode │ │ ├── poteto-mode/references/{codex-tools,provider-dispatch}.md # tool + provider routing │ │ └── poteto-mode/scripts/ # bun/bash/node tooling: watch-pr, runner, resolve-codex-transcript, check-plan.mjs, worktree-audit.sh │ ├── hooks/ # SessionStart auto-fire: injects the poteto-mode mandate (Claude Code only) @@ -88,7 +90,7 @@ The Codex build shares one `skills/` tree with the Claude Code build. Nothing is - **Tool and built-in mapping.** Claude tool names and built-in skills resolve through [`codex-tools.md`](../plugins/pstack/skills/poteto-mode/references/codex-tools.md). Model execution resolves separately through [`provider-dispatch.md`](../plugins/pstack/skills/poteto-mode/references/provider-dispatch.md), so Codex models stay native while other providers run through the external runner. - **Subagents.** The `Agent` tool maps to Codex `spawn_agent` / `wait_agent`, enabled by `multi_agent = true`. Parallel fan-out is multiple `spawn_agent` calls in one turn. If the native Codex lane is unavailable, record that lane as a dropout; the configured external lanes still run, and no provider is silently substituted. There is no `poteto-agent` subagent type on Codex; route ad-hoc subagents by dispatching a `spawn_agent` told to read `poteto-mode` first. - **Auto-fire.** The `hooks/` SessionStart injection is Claude Code-only; Codex has no plugin hook runtime. Enter `pstack:poteto-mode` by name, or add a standing instruction to `~/.codex/AGENTS.md` if you want the same always-on routing. -- **Models.** `/setup-pstack` writes provider-qualified descriptors and asks one requested effort per assigned family (`low`, `medium`, `high`, `xhigh`, `max`, and `ultra` where the model's CLI lists it, today Sol and Astra). The first-run sheet is the model catalog's [role defaults](../plugins/pstack/skills/poteto-mode/references/model-catalog.md#role-defaults), with a panel of Opus, Sol, and Grok; Fable, Sonnet, Luna, Astra, Haiku 5.5 and an exact Opus pin stay selectable. Fable, Opus and Sonnet use Claude's rolling aliases; a registered exact pin keeps its own model. Runtime dispatch normalizes older versioned descriptors in memory, so an installed sheet stops pinning immediately. A setup rerun persists that migration while keeping each role's family and effort. In Codex, Codex families such as Sol use native `spawn_agent`; every other provider uses the deterministic external runner. In Claude Code, Claude families use native agents; every other provider uses the runner. In Grok, `inherit-parent` and `auto` use `spawn_subagent`; every explicit descriptor, including Grok's, uses the runner with `--parent grok`. A Codex writer that the runner launches stays in Codex's `workspace-write` sandbox unless the sheet opts in with the line `codex writer sandbox: full-access`, which setup asks about once. Full access lets the writer launch a browser and write dot-folders such as `.agents/`, and removes every sandbox limit. A provider whose writes no sandbox confines, such as OpenCode, Cursor or Muse, writes only when the sheet holds ` writer sandbox: full-access`, which setup asks about when a writer role uses that provider. Children never detect the parent or reroute themselves. The `bug-fix`, `perf-issue`, and `hillclimb` roles stay on Sol instead of upstream's Grok default. +- **Models.** `/setup-pstack` writes provider-qualified descriptors and asks one requested effort per assigned family (`low`, `medium`, `high`, `xhigh`, `max`, and `ultra` where the model's CLI lists it, today Sol and Astra). The first-run sheet is the model catalog's [role defaults](../plugins/pstack/skills/poteto-mode/references/model-catalog.md#role-defaults), with a panel of Opus, Sol, and Grok; Fable, Sonnet, Luna, Astra, Haiku 5.5 and an exact Opus pin stay selectable. Fable, Opus and Sonnet use Claude's rolling aliases; a registered exact pin keeps its own model. Runtime dispatch normalizes older versioned descriptors in memory, so an installed sheet stops pinning immediately. A setup rerun persists that migration while keeping each role's family and effort. In Codex, Codex families such as Sol use native `spawn_agent`; every other provider uses the deterministic external runner. In Claude Code, Claude families use native agents; every other provider uses the runner. In Grok, `inherit-parent` and `auto` use `spawn_subagent`; every explicit descriptor, including Grok's, uses the runner with `--parent grok`. In OpenCode, `inherit-parent` and `auto` use `subagent`; every explicit descriptor, including OpenCode's, uses the runner with `--parent opencode`. A Codex writer that the runner launches stays in Codex's `workspace-write` sandbox unless the sheet opts in with the line `codex writer sandbox: full-access`, which setup asks about once. Full access lets the writer launch a browser and write dot-folders such as `.agents/`, and removes every sandbox limit. A provider whose writes no sandbox confines, such as OpenCode, Cursor or Muse, writes only when the sheet holds ` writer sandbox: full-access`, which setup asks about when a writer role uses that provider. Children never detect the parent or reroute themselves. The `bug-fix`, `perf-issue`, and `hillclimb` roles stay on Sol instead of upstream's Grok default. Verified in fresh installed Claude Code and Codex sessions: the user-facing skills are discovered and namespaced under `pstack`; both parents fan out the configured panel through the documented native/external route table, retain long-running handles without a default timeout, and cross-judge only after every candidate is terminal. The `principle-*` leaves remain available for `poteto-mode` to read by path. Claude honors their `user-invocable: false` metadata; Codex 0.149.0 does not ([#8](https://github.com/ericlitman/open-pstack/issues/8)). @@ -101,6 +103,28 @@ Grok is a parent harness. It shares the same `skills/` tree and reads `plugins/p - **Auto-fire.** pstack's SessionStart hook does not fire in Grok, whose session sources are `new` and `load`. Run `/pstack:poteto-mode` by name, as on Codex. - **Models.** `inherit-parent` and `auto` use `spawn_subagent` with `pstack:poteto-agent`. A Grok `[subagents.models]`, role or persona override for that agent type changes that lane's model, and the parent records it. Every explicit descriptor, including every `grok:*` descriptor, uses the runner with `--parent grok`, whose receipt proves the served model. `/setup-pstack` writes the sheet to `${GROK_HOME:-$HOME/.grok}/rules/pstack-models.md`, which Grok loads as a home rule with no include line. That sheet takes precedence over model text Grok imports from Claude instructions, and a malformed sheet is a visible stop. +## Running on OpenCode + +OpenCode is a parent harness. The same `skills/` tree ships as the `@open-pstack/pstack` package at `plugins/pstack/`, whose `main` and `exports` point at `opencode/index.ts`. One default export serves both OpenCode lines: `2.x` calls `setup` and registers through the skill, agent, command and session domains; `1.x` calls `server`, requires the `id`, and receives v1 hooks. The v2 client module is imported inside `setup` only, so 1.x loads the package with no dependency install. + +- **Install.** On 2.x, add the package to the `plugins` array, or run `opencode plugin add 'github:/open-pstack#main::path:plugins/pstack'`. On this fork, use `github:Rawknee-69/opencode-pstack#main`. `opencode plugin add` installs npm modules only, so 1.x instead points the singular `plugin` array at the package directory in `~/.config/opencode/opencode.json`: + + ```jsonc + { + "$schema": "https://opencode.ai/config.json", + "plugin": ["/absolute/path/to/open-pstack/plugins/pstack"] + } + ``` + + The README's [OpenCode install prompt](../README.md#install-with-a-prompt) is the paste-able version. Start a new session after the first install so OpenCode reloads its registries. `opencode plugin list` and `opencode plugin check` on 2.x read the global config home only, so a project-level install, a `--pure` session, or a different `OPENCODE_CONFIG_DIR` explains `No plugins found`; `plugin check` reports the installed commit that the cached package actually matches. + +- **Skills.** On 2.x the plugin reads each `skills//SKILL.md`, registers the ID and description, and preserves the body and base directory. `disable-model-invocation: true` and `user-invocable: false` both become `opencode/autoinvoke: false`, so typed-only skills and principle leaves stay registered but out of the advertised list. Load a skill by ID with the `skill` tool, or mention `@`. On 1.x the plugin appends the skill root to `skills.paths` in v1's `{ paths, urls }` shape and preserves whatever sources the user already had. 1.x has no skill tool: it exposes every skill directory as a slash command, so `/poteto-mode`, `/setup-pstack` and `/babysit` work by ID. +- **Agents.** Both lines register `poteto-agent` and `comment-sicko` as `mode: subagent` with no model, so a native lane inherits the parent session's model. `comment-sicko` denies edits, as `permission: { edit: "deny" }` on 1.x and a deny rule on 2.x. The plugin does not register the `pstack--` Claude lane agents. +- **Commands.** 2.x adds `/pstack/poteto-mode` and `/pstack/setup-pstack`, which inject the skill body before the user's text, matching the Claude slash expansion. 1.x needs no extra command because its skill commands already carry the bodies. +- **Auto-fire.** OpenCode has no SessionStart hook. On 2.x the plugin appends `opencode/session-start-context.md` to a session's first model call and `/pstack-models.md` to every call. On 1.x it pushes its own brief through `experimental.chat.system.transform` on every call, because 1.x regenerates the system prompt per request and has no session-scoped context hook; the model sheet rides the same hook. +- **Tool mapping.** [`codex-tools.md`](../plugins/pstack/skills/poteto-mode/references/codex-tools.md) has an OpenCode column and a Waits on OpenCode section. `AGENTS.md` is the instructions file; OpenCode reads `CLAUDE.md` only as a fallback. +- **Models.** `inherit-parent` and `auto` use `subagent` with `agent: "poteto-agent"`. Every explicit descriptor, including every `opencode:*` descriptor, uses the runner with `--parent opencode`, whose receipt proves the served model. `/setup-pstack` writes the sheet to `${OPENCODE_CONFIG_DIR:-${XDG_CONFIG_HOME:-$HOME/.config}/opencode}/pstack-models.md`; the plugin appends it to each model call, so there is no include line or mirror. + ## Dependencies Nothing is declared in `plugin.json`. Install the one companion plugin yourself: @@ -124,7 +148,7 @@ Not declared as deps, but referenced in skill bodies: - **Bash on Windows** — the SessionStart hook runs through `hooks/run-hook.cmd`, which looks for Git for Windows' `bash.exe` in its standard system-wide and per-user locations, then for a `bash` on `PATH` (MSYS2, Cygwin). Without one, the hook exits 0 and skips the pstack startup context, as the superpowers wrapper it comes from does. Install [Git for Windows](https://git-scm.com/download/win) to get the context. In Codex, the hook starts `C:\Windows\System32\cmd.exe` by full path, because one command must work in both PowerShell and cmd. A Windows installed outside `C:\Windows` does not run the hook. - **macOS, Linux or WSL2 for Claude writer lanes** — Claude Code's sandbox does not run on native Windows, so a Claude writer lane needs one of these hosts. - **`node`** — runs `skills/poteto-mode/scripts/check-plan.mjs`. The checker uses only Node built-ins and does not need Bun. -- **Provider CLIs** — the external runner uses the assigned subscribed CLI directly, one per provider in the [model catalog's route table](../plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes). Install and authenticate only the providers present in your model sheet. Some providers run read-only lanes only. The catalog notes for OpenCode, Amp, Cursor, Devin, agy and dsh say what repository and host configuration their CLIs load into a lane. A Claude or Codex provider on its own parent stays native, and the runner refuses that call. A Grok parent may run a Grok provider through the runner. +- **Provider CLIs** — the external runner uses the assigned subscribed CLI directly, one per provider in the [model catalog's route table](../plugins/pstack/skills/poteto-mode/references/model-catalog.md#routes). Install and authenticate only the providers present in your model sheet. Some providers run read-only lanes only. The catalog notes for OpenCode, Amp, Cursor, Devin, agy and dsh say what repository and host configuration their CLIs load into a lane. A Claude or Codex provider on its own parent stays native, and the runner refuses that call. A Grok parent may run a Grok provider through the runner. An OpenCode parent runs every explicit OpenCode descriptor through the runner. - **`jq` and `rg` (ripgrep)** — only for `scripts/worktree-audit.sh` (the Worktree cleanup playbook). Without them the audit still runs but blanks its PR and LAST_CHAT columns, so it warns on stderr rather than returning a table that looks complete. No third-party plugins. The harsher-critique escape hatch lives in the bundled `thermo-nuclear-code-quality-review` skill (imported from cursor-team-kit), not in an external plugin. diff --git a/package.json b/package.json index 8b1e6208..6101dc36 100644 --- a/package.json +++ b/package.json @@ -3,8 +3,10 @@ "private": true, "packageManager": "bun@1.4.0", "scripts": { - "test": "cd plugins/pstack/skills/poteto-mode/scripts && bun install --frozen-lockfile && bun run test", - "typecheck": "cd plugins/pstack/skills/poteto-mode/scripts && bun install --frozen-lockfile && bun run typecheck && cd ../../statechart/scripts && bun install --frozen-lockfile && bun run typecheck", - "static": "bun -e 'for (const path of process.argv.slice(1)) JSON.parse(await Bun.file(path).text())' .claude-plugin/marketplace.json .agents/plugins/marketplace.json plugins/pstack/.claude-plugin/plugin.json plugins/pstack/.codex-plugin/plugin.json plugins/pstack/.grok-plugin/plugin.json && PSTACK_STATIC_ONLY=1 bash tests/skill-collision-repro.sh" + "test": "bun run test:skills && bun run test:opencode", + "test:skills": "cd plugins/pstack/skills/poteto-mode/scripts && bun install --frozen-lockfile && bun run test", + "test:opencode": "cd plugins/pstack && bun install --frozen-lockfile && bun run test", + "typecheck": "(cd plugins/pstack/skills/poteto-mode/scripts && bun install --frozen-lockfile && bun run typecheck) && (cd plugins/pstack/skills/statechart/scripts && bun install --frozen-lockfile && bun run typecheck) && (cd plugins/pstack && bun install --frozen-lockfile && bun run typecheck)", + "static": "bun -e 'for (const path of process.argv.slice(1)) JSON.parse(await Bun.file(path).text())' .claude-plugin/marketplace.json .agents/plugins/marketplace.json plugins/pstack/.claude-plugin/plugin.json plugins/pstack/.codex-plugin/plugin.json plugins/pstack/.grok-plugin/plugin.json plugins/pstack/package.json && PSTACK_STATIC_ONLY=1 bash tests/skill-collision-repro.sh" } } diff --git a/plugins/pstack/.claude-plugin/plugin.json b/plugins/pstack/.claude-plugin/plugin.json index 0bdf329d..5cc6721d 100644 --- a/plugins/pstack/.claude-plugin/plugin.json +++ b/plugins/pstack/.claude-plugin/plugin.json @@ -1,8 +1,8 @@ { "name": "pstack", "displayName": "pstack", - "version": "1.21.0", - "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence. Ported from cursor/plugins/pstack for Claude Code and Codex.", + "version": "1.22.0", + "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence. Ported from cursor/plugins/pstack for Claude Code, Codex, Grok and OpenCode.", "author": { "name": "Lauren Tan" }, diff --git a/plugins/pstack/.codex-plugin/plugin.json b/plugins/pstack/.codex-plugin/plugin.json index 77972f6e..5d8663bc 100644 --- a/plugins/pstack/.codex-plugin/plugin.json +++ b/plugins/pstack/.codex-plugin/plugin.json @@ -1,6 +1,6 @@ { "name": "pstack", - "version": "1.21.0", + "version": "1.22.0", "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence. Codex port of the Claude Code plugin; skills are shared, tool names resolve via skills/poteto-mode/references/codex-tools.md.", "author": { "name": "Lauren Tan" diff --git a/plugins/pstack/.grok-plugin/plugin.json b/plugins/pstack/.grok-plugin/plugin.json index 917675d0..bf0817f3 100644 --- a/plugins/pstack/.grok-plugin/plugin.json +++ b/plugins/pstack/.grok-plugin/plugin.json @@ -1,7 +1,7 @@ { "name": "pstack", "displayName": "pstack", - "version": "1.21.0", + "version": "1.22.0", "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence. Grok build of the Claude Code plugin; skills are shared, tool names resolve via skills/poteto-mode/references/codex-tools.md.", "author": { "name": "Lauren Tan" diff --git a/plugins/pstack/bun.lock b/plugins/pstack/bun.lock new file mode 100644 index 00000000..c7b0dfe2 --- /dev/null +++ b/plugins/pstack/bun.lock @@ -0,0 +1,569 @@ +{ + "lockfileVersion": 2, + "configVersion": 1, + "workspaces": { + "": { + "name": "@open-pstack/pstack", + "dependencies": { + "@opencode/plugin": "2.4.2", + }, + "devDependencies": { + "@types/node": "24.12.2", + "typescript": "5.9.3", + }, + }, + }, + "packages": { + "@ai-sdk/provider": ["@ai-sdk/provider@3.0.8", "", { "dependencies": { "json-schema": "^0.4.0" } }, "sha512-oGMAgGoQdBXbZqNG0Ze56CHjDZ1IDYOwGYxYjO5KLSlz5HiNQ9udIXsPZ61VWaHGZ5XW/jyjmr6t2xz2jGVwbQ=="], + + "@aws-crypto/crc32": ["@aws-crypto/crc32@5.2.0", "", { "dependencies": { "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", "tslib": "^2.6.2" } }, "sha512-nLbCWqQNgUiwwtFsen1AdzAtvuLRsQS8rYgMuxCrdKf9kOssamGLuPwyTY9wyYblNr9+1XM8v6zoDTPPSIeANg=="], + + "@aws-crypto/sha256-browser": ["@aws-crypto/sha256-browser@5.2.0", "", { "dependencies": { "@aws-crypto/sha256-js": "^5.2.0", "@aws-crypto/supports-web-crypto": "^5.2.0", "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", "@aws-sdk/util-locate-window": "^3.0.0", "@smithy/util-utf8": "^2.0.0", "tslib": "^2.6.2" } }, "sha512-AXfN/lGotSQwu6HNcEsIASo7kWXZ5HYWvfOmSNKDsEqC4OashTp8alTmaz+F7TC2L083SFv5RdB+qU3Vs1kZqw=="], + + "@aws-crypto/sha256-js": ["@aws-crypto/sha256-js@5.2.0", "", { "dependencies": { "@aws-crypto/util": "^5.2.0", "@aws-sdk/types": "^3.222.0", "tslib": "^2.6.2" } }, "sha512-FFQQyu7edu4ufvIZ+OadFpHHOt+eSTBaYaki44c+akjg7qZg9oOQeLlk77F6tSYqjDAFClrHJk9tMf0HdVyOvA=="], + + "@aws-crypto/supports-web-crypto": ["@aws-crypto/supports-web-crypto@5.2.0", "", { "dependencies": { "tslib": "^2.6.2" } }, "sha512-iAvUotm021kM33eCdNfwIN//F77/IADDSs58i+MDaOqFrVjZo9bAal0NK7HurRuWLLpF1iLX7gbWrjHjeo+YFg=="], + + "@aws-crypto/util": ["@aws-crypto/util@5.2.0", "", { "dependencies": { "@aws-sdk/types": "^3.222.0", "@smithy/util-utf8": "^2.0.0", "tslib": "^2.6.2" } }, "sha512-4RkU9EsI6ZpBve5fseQlGNUWKMa1RLPQ1dnjnQoe07ldfIzcsGb5hC5W0Dm7u423KWzawlrpbjXBrXCEv9zazQ=="], + + "@aws-sdk/client-cognito-identity": ["@aws-sdk/client-cognito-identity@3.1057.0", "", { "dependencies": { "@aws-crypto/sha256-browser": "5.2.0", "@aws-crypto/sha256-js": "5.2.0", "@aws-sdk/core": "^3.974.15", "@aws-sdk/credential-provider-node": "^3.972.47", "@aws-sdk/types": "^3.973.9", "@smithy/core": "^3.24.5", "@smithy/fetch-http-handler": "^5.4.5", "@smithy/node-http-handler": "^4.7.5", "@smithy/types": "^4.14.2", "tslib": "^2.6.2" } }, "sha512-5MliYkp2u0+2arTp5fZIaxl+xmm90LEKv/VeSxhfNQW4t0fvWJrNO429/jchWQenNoDRrOGE59VfbuZUfwFujg=="], + + "@aws-sdk/core": ["@aws-sdk/core@3.981.2", "", { "dependencies": { "@aws-sdk/types": "^3.975.1", "@aws-sdk/xml-builder": "^3.972.43", "@aws/lambda-invoke-store": "^0.3.0", "@smithy/core": "^3.41.1", "@smithy/signature-v4": "^5.7.5", "@smithy/types": "^4.20.0", "bowser": "^2.11.0", "tslib": "^2.6.2" } }, "sha512-N3XKZdfa+Dcm7Kl8NJnaaHLx860Ts3QYHOraj/wuKOYHqqCApQBIKwzSxrpwZdwrqfbPt7BvJdYVhVMPpsRoGA=="], + + "@aws-sdk/credential-provider-cognito-identity": ["@aws-sdk/credential-provider-cognito-identity@3.972.85", "", { "dependencies": { "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-N5kunNhwKqqKb5xP2i2cWLvwummwjLI6COqYZH3bDHnASh8o8ot8SAA5uko7XZM25Qh9bx9XSMesGkYR5zSjJA=="], + + "@aws-sdk/credential-provider-env": ["@aws-sdk/credential-provider-env@3.972.86", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-ZFIkIzLAiOLOakfrzUuOz938+AF+q4nc/MYINYwFlgBbl8CsI8ofJ8Ueh0/Pp7hXMJfpq10eJdnQ7aaE6kfikQ=="], + + "@aws-sdk/credential-provider-http": ["@aws-sdk/credential-provider-http@3.972.88", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/fetch-http-handler": "^5.8.1", "@smithy/node-http-handler": "^4.14.2", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-92dpM3lwCyDjcDI3R+olUI2IG8R+qfUdnMQgxWZB4XM37P+N+oBaRd5xGc7uOH7FqMQY03XsrVKQeuWbPfIrKg=="], + + "@aws-sdk/credential-provider-ini": ["@aws-sdk/credential-provider-ini@3.973.32", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/credential-provider-env": "^3.972.86", "@aws-sdk/credential-provider-http": "^3.972.88", "@aws-sdk/credential-provider-login": "^3.972.94", "@aws-sdk/credential-provider-process": "^3.972.86", "@aws-sdk/credential-provider-sso": "^3.973.30", "@aws-sdk/credential-provider-web-identity": "^3.972.92", "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/credential-provider-imds": "^4.5.2", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-MdIAf70d701Hj04Yo7AKqI1RfjTW5dFf+tEvUirYFMbs3NRHWiwqQj/C9wGFptZtmX+z/c57H3gQfzTt5Bsn8A=="], + + "@aws-sdk/credential-provider-login": ["@aws-sdk/credential-provider-login@3.972.94", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-sSq1PxdXT1kqR11/dRvE5AC2dEWMbYJCXzRU03Ulu4stu6vv08zju8uUNhVdqiIX+OrMIcEHHT1maLrUZDBGDA=="], + + "@aws-sdk/credential-provider-node": ["@aws-sdk/credential-provider-node@3.972.99", "", { "dependencies": { "@aws-sdk/credential-provider-env": "^3.972.86", "@aws-sdk/credential-provider-http": "^3.972.88", "@aws-sdk/credential-provider-ini": "^3.973.32", "@aws-sdk/credential-provider-process": "^3.972.86", "@aws-sdk/credential-provider-sso": "^3.973.30", "@aws-sdk/credential-provider-web-identity": "^3.972.92", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/credential-provider-imds": "^4.5.2", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-AgS2qV8P9XmT4M44LfGcFtKbbt/yLgBydETKxPvqN9y7gMnKYv8GY+QfH7JsNvu6eQgDl600uAjvzC6K7ilkJQ=="], + + "@aws-sdk/credential-provider-process": ["@aws-sdk/credential-provider-process@3.972.86", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-9x/+gtSDNxMQrRXgwIdwdNCVGxzUZtTZArjEeLfsn9xDvyXdsgs4my1g7JN5wKxT61ZLx4bKPREaDXnO8j7gkg=="], + + "@aws-sdk/credential-provider-sso": ["@aws-sdk/credential-provider-sso@3.973.30", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/token-providers": "3.1177.0", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-sMvwUIaKQEeprbMT5LXrI6nhM1IUEBDRpJAydEkAMrI7brrsRl7pxnOAJ6nweg/Hn5pJOVS7JgieJIv6CvJ7Sw=="], + + "@aws-sdk/credential-provider-web-identity": ["@aws-sdk/credential-provider-web-identity@3.972.92", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-AKaUwpy1wPN3B/byFWuvL6v+Qk8Gm840InZJw/bA1A+ciCL3zkzBUyEgxdeghJPEe79VKLs6BvbME74MQa3YKg=="], + + "@aws-sdk/credential-providers": ["@aws-sdk/credential-providers@3.1057.0", "", { "dependencies": { "@aws-sdk/client-cognito-identity": "3.1057.0", "@aws-sdk/core": "^3.974.15", "@aws-sdk/credential-provider-cognito-identity": "^3.972.38", "@aws-sdk/credential-provider-env": "^3.972.41", "@aws-sdk/credential-provider-http": "^3.972.43", "@aws-sdk/credential-provider-ini": "^3.972.46", "@aws-sdk/credential-provider-login": "^3.972.45", "@aws-sdk/credential-provider-node": "^3.972.47", "@aws-sdk/credential-provider-process": "^3.972.41", "@aws-sdk/credential-provider-sso": "^3.972.45", "@aws-sdk/credential-provider-web-identity": "^3.972.45", "@aws-sdk/nested-clients": "^3.997.13", "@aws-sdk/types": "^3.973.9", "@smithy/core": "^3.24.5", "@smithy/credential-provider-imds": "^4.3.6", "@smithy/types": "^4.14.2", "tslib": "^2.6.2" } }, "sha512-rbrEHtz11g0kxsSkYr3fx2HABNNblp4AhB2MgPvJHgYOWfJ2eBviU7Mvoaef0PW8QH6lbZDfJcnM7eKvtvz3sw=="], + + "@aws-sdk/nested-clients": ["@aws-sdk/nested-clients@3.998.5", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/signature-v4-multi-region": "^3.996.52", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/fetch-http-handler": "^5.8.1", "@smithy/node-http-handler": "^4.14.2", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-9w5mkwVLOuGqlJkPR1uhod6ZP+TOtaxrKtvK2pY9G/+FEx0e8wYRLIDeg30dYQjFDx27jHGSzEA+OaMqxeyTPg=="], + + "@aws-sdk/signature-v4-multi-region": ["@aws-sdk/signature-v4-multi-region@3.996.52", "", { "dependencies": { "@aws-sdk/types": "^3.975.1", "@smithy/signature-v4": "^5.7.5", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-6W6SjGc8OXUhMzNxU1X922ghD+PP1XvzmCk5Scui0jaYsLezycMYR1RaLp5xTIOUrhTXyb4DnAbPr3fBgmdnzg=="], + + "@aws-sdk/token-providers": ["@aws-sdk/token-providers@3.1177.0", "", { "dependencies": { "@aws-sdk/core": "^3.981.2", "@aws-sdk/nested-clients": "^3.998.5", "@aws-sdk/types": "^3.975.1", "@smithy/core": "^3.41.1", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-KFQ/2YqE7OIGNu05hys6y9ZUyoNxxLJVHM7NCvjfyjV0Mki0u0Euwjduj5M/HMurdbZJfBV0NjMNQQkGlJEQqg=="], + + "@aws-sdk/types": ["@aws-sdk/types@3.975.1", "", { "dependencies": { "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-7rGxUkCB2QPoQOeJmonmAICTN2zrH+fpmi1p4Iwu72lnxNaMhOgqcbpyddifnM1DBb19TWQ1u6z/XjkaFNEDWw=="], + + "@aws-sdk/util-locate-window": ["@aws-sdk/util-locate-window@3.965.10", "", { "dependencies": { "tslib": "^2.6.2" } }, "sha512-ycwH6Zd2GhuSqdXX9ihbCjeGTB6xOJs+O3+Jb8/zDG9978XU80qs75dfkPJRMNKe5MvBZPuNeFpd4JZKPoUF4g=="], + + "@aws-sdk/xml-builder": ["@aws-sdk/xml-builder@3.972.43", "", { "dependencies": { "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-rG8QVx4DOrJWptsogu1Aq+CDsnPKaBrAlJpKLxrJrIDXAq1ElnW0yQjjBnlWSXll0cDakCG6UDvaqwz0A9d9Og=="], + + "@aws/lambda-invoke-store": ["@aws/lambda-invoke-store@0.3.0", "", {}, "sha512-sl4Bm6yiMNYrZKkqqDFWN0UfnWhlS8ivKxrYl+6t0gCLrqr8y3B2IqZZbFRkfaVVp7C/baApyh71P+LeE1A2sQ=="], + + "@effect/opentelemetry": ["@effect/opentelemetry@4.1.0", "", { "peerDependencies": { "@opentelemetry/api": ">=1.9.0 <2.0.0", "@opentelemetry/api-logs": ">=0.203.0 <0.300.0", "@opentelemetry/resources": ">=2.0.0 <3.0.0", "@opentelemetry/sdk-logs": ">=0.203.0 <0.300.0", "@opentelemetry/sdk-metrics": ">=2.0.0 <3.0.0", "@opentelemetry/sdk-trace-base": ">=2.0.0 <3.0.0", "@opentelemetry/sdk-trace-node": ">=2.0.0 <3.0.0", "@opentelemetry/sdk-trace-web": ">=2.0.0 <3.0.0", "@opentelemetry/semantic-conventions": ">=1.33.0 <2.0.0", "effect": "^4.1.0" }, "optionalPeers": ["@opentelemetry/api", "@opentelemetry/api-logs", "@opentelemetry/resources", "@opentelemetry/sdk-logs", "@opentelemetry/sdk-metrics", "@opentelemetry/sdk-trace-base", "@opentelemetry/sdk-trace-node", "@opentelemetry/sdk-trace-web"] }, "sha512-j9bNzQaoQvcnimBFMG0i3piEW20E8HjkXAQHTJN/XqG2e4uJ9zCv53/HCNzD7+ooFn5S4nwQy/BOXeNReMIe+A=="], + + "@effect/platform-node": ["@effect/platform-node@4.1.0", "", { "dependencies": { "@effect/platform-node-shared": "^4.1.0", "undici": "^8.12.2" }, "peerDependencies": { "effect": "^4.1.0", "redis": ">=5.0.0 <7.0.0" } }, "sha512-v+X7moGVF9k5oMVvz0slA+NgtEod+W+oygeI285MDJgSlUCW3JcqElj+cD3rlijFZtpKhC7RLkU1GuCxjGHTpA=="], + + "@effect/platform-node-shared": ["@effect/platform-node-shared@4.1.0", "", { "dependencies": { "@types/ws": "^8.18.2", "ws": "^8.22.0" }, "peerDependencies": { "effect": "^4.1.0" } }, "sha512-uYQfFRoxWLo8fIhiSeBcmz/R1ooOfE3HF3cWHFgxz82tZMk2Wn02BGABcdLmaAch9VpDLbtWnuhSxNyBsGMUFg=="], + + "@gar/promise-retry": ["@gar/promise-retry@1.0.3", "", {}, "sha512-GmzA9ckNokPypTg10pgpeHNQe7ph+iIKKmhKu3Ob9ANkswreCx7R3cKmY781K8QK3AqVL3xVh9A42JvIAbkkSA=="], + + "@isaacs/cliui": ["@isaacs/cliui@8.0.2", "", { "dependencies": { "string-width": "^5.1.2", "string-width-cjs": "npm:string-width@^4.2.0", "strip-ansi": "^7.0.1", "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", "wrap-ansi": "^8.1.0", "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" } }, "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA=="], + + "@isaacs/fs-minipass": ["@isaacs/fs-minipass@4.0.1", "", { "dependencies": { "minipass": "^7.0.4" } }, "sha512-wgm9Ehl2jpeqP3zw/7mo3kRHFp5MEDhqAdwy1fTGkHAwnkGOVsgpvQhL8B5n1qlb01jV3n/bI0ZfZp5lWA1k4w=="], + + "@isaacs/string-locale-compare": ["@isaacs/string-locale-compare@1.1.0", "", {}, "sha512-SQ7Kzhh9+D+ZW9MA0zkYv3VXhIDNx+LzM6EJ+/65I3QY+enU6Itte7E5XX7EWrqLW2FN4n06GWzBnPoC3th2aQ=="], + + "@npmcli/agent": ["@npmcli/agent@4.0.2", "", { "dependencies": { "agent-base": "^7.1.0", "http-proxy-agent": "^7.0.0", "https-proxy-agent": "^7.0.1", "lru-cache": "^11.2.1", "socks-proxy-agent": "^8.0.3" } }, "sha512-EUEuWAxnL07Sp5/iC/1X6Xj+XThUvnbei9zfRWZdEXa7lss9RTHMhAHBeg+MZ5To9s/gGaSI+UwZTPdYMvKSeg=="], + + "@npmcli/arborist": ["@npmcli/arborist@9.4.0", "", { "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", "@npmcli/fs": "^5.0.0", "@npmcli/installed-package-contents": "^4.0.0", "@npmcli/map-workspaces": "^5.0.0", "@npmcli/metavuln-calculator": "^9.0.2", "@npmcli/name-from-folder": "^4.0.0", "@npmcli/node-gyp": "^5.0.0", "@npmcli/package-json": "^7.0.0", "@npmcli/query": "^5.0.0", "@npmcli/redact": "^4.0.0", "@npmcli/run-script": "^10.0.0", "bin-links": "^6.0.0", "cacache": "^20.0.1", "common-ancestor-path": "^2.0.0", "hosted-git-info": "^9.0.0", "json-stringify-nice": "^1.1.4", "lru-cache": "^11.2.1", "minimatch": "^10.0.3", "nopt": "^9.0.0", "npm-install-checks": "^8.0.0", "npm-package-arg": "^13.0.0", "npm-pick-manifest": "^11.0.1", "npm-registry-fetch": "^19.0.0", "pacote": "^21.0.2", "parse-conflict-json": "^5.0.1", "proc-log": "^6.0.0", "proggy": "^4.0.0", "promise-all-reject-late": "^1.0.0", "promise-call-limit": "^3.0.1", "semver": "^7.3.7", "ssri": "^13.0.0", "treeverse": "^3.0.0", "walk-up-path": "^4.0.0" }, "bin": { "arborist": "bin/index.js" } }, "sha512-4Bm8hNixJG/sii1PMnag0V9i/sGOX9VRzFrUiZMSBJpGlLR38f+Btl85d07G9GL56xO0l0OZjvrGNYsDYp0xKA=="], + + "@npmcli/config": ["@npmcli/config@10.8.1", "", { "dependencies": { "@npmcli/map-workspaces": "^5.0.0", "@npmcli/package-json": "^7.0.0", "ci-info": "^4.0.0", "ini": "^6.0.0", "nopt": "^9.0.0", "proc-log": "^6.0.0", "semver": "^7.3.5", "walk-up-path": "^4.0.0" } }, "sha512-MAYk9IlIGiyC0c9fnjdBSQfIFPZT0g1MfeSiD1UXTq2zJOLX55jS9/sETJHqw/7LN18JjITrhYfgCfapbmZHiQ=="], + + "@npmcli/fs": ["@npmcli/fs@5.0.0", "", { "dependencies": { "semver": "^7.3.5" } }, "sha512-7OsC1gNORBEawOa5+j2pXN9vsicaIOH5cPXxoR6fJOmH6/EXpJB2CajXOu1fPRFun2m1lktEFX11+P89hqO/og=="], + + "@npmcli/git": ["@npmcli/git@7.0.2", "", { "dependencies": { "@gar/promise-retry": "^1.0.0", "@npmcli/promise-spawn": "^9.0.0", "ini": "^6.0.0", "lru-cache": "^11.2.1", "npm-pick-manifest": "^11.0.1", "proc-log": "^6.0.0", "semver": "^7.3.5", "which": "^6.0.0" } }, "sha512-oeolHDjExNAJAnlYP2qzNjMX/Xi9bmu78C9dIGr4xjobrSKbuMYCph8lTzn4vnW3NjIqVmw/f8BCfouqyJXlRg=="], + + "@npmcli/installed-package-contents": ["@npmcli/installed-package-contents@4.0.0", "", { "dependencies": { "npm-bundled": "^5.0.0", "npm-normalize-package-bin": "^5.0.0" }, "bin": { "installed-package-contents": "bin/index.js" } }, "sha512-yNyAdkBxB72gtZ4GrwXCM0ZUedo9nIbOMKfGjt6Cu6DXf0p8y1PViZAKDC8q8kv/fufx0WTjRBdSlyrvnP7hmA=="], + + "@npmcli/map-workspaces": ["@npmcli/map-workspaces@5.0.3", "", { "dependencies": { "@npmcli/name-from-folder": "^4.0.0", "@npmcli/package-json": "^7.0.0", "glob": "^13.0.0", "minimatch": "^10.0.3" } }, "sha512-o2grssXo1e774E5OtEwwrgoszYRh0lqkJH+Pb9r78UcqdGJRDRfhpM8DvZPjzNLLNYeD/rNbjOKM3Ss5UABROw=="], + + "@npmcli/metavuln-calculator": ["@npmcli/metavuln-calculator@9.0.3", "", { "dependencies": { "cacache": "^20.0.0", "json-parse-even-better-errors": "^5.0.0", "pacote": "^21.0.0", "proc-log": "^6.0.0", "semver": "^7.3.5" } }, "sha512-94GLSYhLXF2t2LAC7pDwLaM4uCARzxShyAQKsirmlNcpidH89VA4/+K1LbJmRMgz5gy65E/QBBWQdUvGLe2Frg=="], + + "@npmcli/name-from-folder": ["@npmcli/name-from-folder@4.0.0", "", {}, "sha512-qfrhVlOSqmKM8i6rkNdZzABj8MKEITGFAY+4teqBziksCQAOLutiAxM1wY2BKEd8KjUSpWmWCYxvXr0y4VTlPg=="], + + "@npmcli/node-gyp": ["@npmcli/node-gyp@5.0.0", "", {}, "sha512-uuG5HZFXLfyFKqg8QypsmgLQW7smiRjVc45bqD/ofZZcR/uxEjgQU8qDPv0s9TEeMUiAAU/GC5bR6++UdTirIQ=="], + + "@npmcli/package-json": ["@npmcli/package-json@7.0.5", "", { "dependencies": { "@npmcli/git": "^7.0.0", "glob": "^13.0.0", "hosted-git-info": "^9.0.0", "json-parse-even-better-errors": "^5.0.0", "proc-log": "^6.0.0", "semver": "^7.5.3", "spdx-expression-parse": "^4.0.0" } }, "sha512-iVuTlG3ORq2iaVa1IWUxAO/jIp77tUKBhoMjuzYW2kL4MLN1bi/ofqkZ7D7OOwh8coAx1/S2ge0rMdGv8sLSOQ=="], + + "@npmcli/promise-spawn": ["@npmcli/promise-spawn@9.0.2", "", { "dependencies": { "which": "^6.0.0" } }, "sha512-h7b1j0egrruBm/32eVA6/zMw5VJxxaB3vT+uVGGQ4SAAMrQVFHNuzL4+EAXn66j+huj0jApINc1fW3fC+kVoeA=="], + + "@npmcli/query": ["@npmcli/query@5.0.0", "", { "dependencies": { "postcss-selector-parser": "^7.0.0" } }, "sha512-8TZWfTQOsODpLqo9SVhVjHovmKXNpevHU0gO9e+y4V4fRIOneiXy0u0sMP9LmS71XivrEWfZWg50ReH4WRT4aQ=="], + + "@npmcli/redact": ["@npmcli/redact@4.0.0", "", {}, "sha512-gOBg5YHMfZy+TfHArfVogwgfBeQnKbbGo3pSUyK/gSI0AVu+pEiDVcKlQb0D8Mg1LNRZILZ6XG8I5dJ4KuAd9Q=="], + + "@npmcli/run-script": ["@npmcli/run-script@10.0.4", "", { "dependencies": { "@npmcli/node-gyp": "^5.0.0", "@npmcli/package-json": "^7.0.0", "@npmcli/promise-spawn": "^9.0.0", "node-gyp": "^12.1.0", "proc-log": "^6.0.0" } }, "sha512-mGUWr1uMnf0le2TwfOZY4SFxZGXGfm4Jtay/nwAa2FLNAKXUoUwaGwBMNH36UHPtinWfTSJ3nqFQr0091CxVGg=="], + + "@opencode/ai": ["@opencode/ai@2.4.2", "", { "dependencies": { "@aws-sdk/credential-providers": "3.1057.0", "@opencode/schema": "2.4.2", "@smithy/eventstream-codec": "4.2.14", "@smithy/util-utf8": "4.2.2", "aws4fetch": "1.0.20", "effect": "4.1.0", "google-auth-library": "10.5.0" } }, "sha512-p3tOtq8jewfxMesBDo2ZSsc77ZqoB5qbTZcuUrNcner4KHoex4iwhsNTw0CWkUhxkBwWH7xJjkv3+eXXzxf4+w=="], + + "@opencode/client": ["@opencode/client@2.4.2", "", { "dependencies": { "@opencode/protocol": "2.4.2", "@opencode/schema": "2.4.2" }, "peerDependencies": { "effect": "4.1.0", "solid-js": ">=1.9.0" }, "optionalPeers": ["effect", "solid-js"] }, "sha512-Wnb/wMl3HzPHu7WR4DYc4TkziFDdB6xUpNoLGGz7SMUIbBWPYhV2wPRenR7UEeMdlHlKgaYcxixTH80H+5YP2g=="], + + "@opencode/plugin": ["@opencode/plugin@2.4.2", "", { "dependencies": { "@ai-sdk/provider": "3.0.8", "@opencode/ai": "2.4.2", "@opencode/client": "2.4.2", "@opencode/protocol": "2.4.2", "@opencode/schema": "2.4.2", "@opencode/util": "2.4.2", "effect": "4.1.0" }, "peerDependencies": { "@opencode/theme": "2.4.2", "@opentui/core": ">=0.8.0", "@opentui/solid": ">=0.8.0", "electron": "*", "solid-js": ">=1.9.0", "vite": ">=6", "vite-plugin-solid": ">=2.11" }, "optionalPeers": ["@opencode/theme", "@opentui/core", "@opentui/solid", "electron", "solid-js", "vite", "vite-plugin-solid"] }, "sha512-8qXTNu3ExZ5ElgWGEmgt0to2sCtiQEzmaV/BlMDiO6ENQTS0JJuOJ7PxZdxIhKZyMUxmL1DIwUCOaqMc9/EDJQ=="], + + "@opencode/protocol": ["@opencode/protocol@2.4.2", "", { "dependencies": { "@opencode/schema": "2.4.2", "effect": "4.1.0" } }, "sha512-w87Ym2Xd449fngSXNNbWE5d5mWl5sxeK8I/yp0TVb0rpQM1+jriwKh6g2Akxrp1Xzdwrz84gfms+ZEtM30R00g=="], + + "@opencode/schema": ["@opencode/schema@2.4.2", "", { "dependencies": { "@standard-schema/spec": "1.1.0", "effect": "4.1.0" } }, "sha512-/qAbNPjIO4uOvaBB9UcxUZUGXtdp8OeR65gUi8HrVrxSJMxocMg7Yky7U2iiZzGiE9mE4NsQQK9F8cN/2vjkoA=="], + + "@opencode/util": ["@opencode/util@2.4.2", "", { "dependencies": { "@effect/opentelemetry": "4.1.0", "@effect/platform-node": "4.1.0", "@effect/platform-node-shared": "4.1.0", "@npmcli/arborist": "9.4.0", "@npmcli/config": "10.8.1", "@opentelemetry/api": "1.9.0", "@opentelemetry/api-logs": "0.219.0", "@opentelemetry/context-async-hooks": "2.8.0", "@opentelemetry/exporter-trace-otlp-http": "0.219.0", "@opentelemetry/resources": "2.8.0", "@opentelemetry/sdk-logs": "0.219.0", "@opentelemetry/sdk-metrics": "2.8.0", "@opentelemetry/sdk-trace-base": "2.8.0", "@opentelemetry/sdk-trace-node": "2.8.0", "cross-spawn": "7.0.6", "effect": "4.1.0", "glob": "13.0.5", "mime-types": "3.0.2", "minimatch": "10.2.5", "npm-package-arg": "13.0.2", "open": "11.0.4", "pacote": "21.5.1" } }, "sha512-anYWKTU+N35MuNL/l0x8uREG4Gb7CvyAfRDJhz6JAg9yQSpGYqPNQUJqaPgPpXA0Zrac1uJCEGXx9Zb4HG+fjA=="], + + "@opentelemetry/api": ["@opentelemetry/api@1.9.0", "", {}, "sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg=="], + + "@opentelemetry/api-logs": ["@opentelemetry/api-logs@0.219.0", "", { "dependencies": { "@opentelemetry/api": "^1.3.0" } }, "sha512-FFx7YnaYJlIjqWW/AG/yAZ0L/NEY724PipXXXQLdtZPbLwBGbUMTGL1i/esI56TWfTUXxhLfpgrnWJCG8aUJyg=="], + + "@opentelemetry/context-async-hooks": ["@opentelemetry/context-async-hooks@2.8.0", "", { "peerDependencies": { "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, "sha512-/3FIraneMcng67SUJCxvyInk/oxzwsxyadufk0wwfOBLf5wqtAGX4MoQASwSbndBPeARzBryUM9Azr5kHIdWLw=="], + + "@opentelemetry/core": ["@opentelemetry/core@2.8.0", "", { "dependencies": { "@opentelemetry/semantic-conventions": "^1.29.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, "sha512-hd1Lfh8p545nNz+jq1Ejfz+Mn1hyLuxYn1YzTfFNrxr8urEWMNQLPf1Th8kjOH+HxwawCrtgBp8JpBUR4ZSgww=="], + + "@opentelemetry/exporter-trace-otlp-http": ["@opentelemetry/exporter-trace-otlp-http@0.219.0", "", { "dependencies": { "@opentelemetry/core": "2.8.0", "@opentelemetry/otlp-exporter-base": "0.219.0", "@opentelemetry/otlp-transformer": "0.219.0", "@opentelemetry/resources": "2.8.0", "@opentelemetry/sdk-trace-base": "2.8.0" }, "peerDependencies": { "@opentelemetry/api": "^1.3.0" } }, "sha512-9t6SvBXXBEjOBcIzgozvBbd3jWrv3Gt3ngGhl1fhdZ/zRc7oZDVOFEqbi2zlBpW9BXhgDMKv422J0DL/3iQWfw=="], + + "@opentelemetry/otlp-exporter-base": ["@opentelemetry/otlp-exporter-base@0.219.0", "", { "dependencies": { "@opentelemetry/core": "2.8.0", "@opentelemetry/otlp-transformer": "0.219.0" }, "peerDependencies": { "@opentelemetry/api": "^1.3.0" } }, "sha512-zvIxQX/AZUVKDU+hCuYx+7UkiP7GRdnk1ZbFQRYzHvYp47cAWR4j3IhoPhV9KaeXEv2xdGq3IA6PnpzDmLcmSA=="], + + "@opentelemetry/otlp-transformer": ["@opentelemetry/otlp-transformer@0.219.0", "", { "dependencies": { "@opentelemetry/api-logs": "0.219.0", "@opentelemetry/core": "2.8.0", "@opentelemetry/resources": "2.8.0", "@opentelemetry/sdk-logs": "0.219.0", "@opentelemetry/sdk-metrics": "2.8.0", "@opentelemetry/sdk-trace-base": "2.8.0" }, "peerDependencies": { "@opentelemetry/api": "^1.3.0" } }, "sha512-aaYKAyXhw9VchKZVGOopD3Gw/kPsyrX2c6IQ0AW32mTjqmZOh5Y6Gf5OYqTNqVktAeBjmFinhyFaCwW6GYK9YQ=="], + + "@opentelemetry/resources": ["@opentelemetry/resources@2.8.0", "", { "dependencies": { "@opentelemetry/core": "2.8.0", "@opentelemetry/semantic-conventions": "^1.29.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.3.0 <1.10.0" } }, "sha512-qmXQ27ilDbUK/vGMqwL8D4/rhn76C+sherM4wTbjlfknR8Nvfc/hCxjRJPhkzZzUsPiNg16SA31NxMabwttRjg=="], + + "@opentelemetry/sdk-logs": ["@opentelemetry/sdk-logs@0.219.0", "", { "dependencies": { "@opentelemetry/api-logs": "0.219.0", "@opentelemetry/core": "2.8.0", "@opentelemetry/resources": "2.8.0", "@opentelemetry/semantic-conventions": "^1.29.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.4.0 <1.10.0" } }, "sha512-s6lTKRakaPClvKoWHRChxnXjDMkM/TQ30ff78jN6EBGf7MI7VzANE5PU3f4z9qDUudWjvZjOLHG0rBnBKYvoXA=="], + + "@opentelemetry/sdk-metrics": ["@opentelemetry/sdk-metrics@2.8.0", "", { "dependencies": { "@opentelemetry/core": "2.8.0", "@opentelemetry/resources": "2.8.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.9.0 <1.10.0" } }, "sha512-UDBGaj6W0Rgy5rTTaoxs8gVGF/aGkAKyjurJv7se6wjRxJu7FoquTLT/vt54DZfo4crbprYfhX/SOK9+BPw1qg=="], + + "@opentelemetry/sdk-trace-base": ["@opentelemetry/sdk-trace-base@2.8.0", "", { "dependencies": { "@opentelemetry/core": "2.8.0", "@opentelemetry/resources": "2.8.0", "@opentelemetry/semantic-conventions": "^1.29.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.3.0 <1.10.0" } }, "sha512-mhU4jp+vW0mGbFRd+GeXHvmfA4aDqWjBjLC3pE5XMpLs0IE2ryYb019Ts2AQrOq67gaTF25D91+fgvEHDZEnuQ=="], + + "@opentelemetry/sdk-trace-node": ["@opentelemetry/sdk-trace-node@2.8.0", "", { "dependencies": { "@opentelemetry/context-async-hooks": "2.8.0", "@opentelemetry/core": "2.8.0", "@opentelemetry/sdk-trace-base": "2.8.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.0.0 <1.10.0" } }, "sha512-nZt9OGufioAc3AfoLTqA9bsAeaMJAictYDdI2VcNQ+PmT+3rfKjAZDZvgPfd8VPX0O5Bw1hdQF6kDK8VSpZiWg=="], + + "@opentelemetry/semantic-conventions": ["@opentelemetry/semantic-conventions@1.45.0", "", {}, "sha512-aOP45mbcOKbQVvFWfQmgoOPT8R2iwbbbgl83k4CujGV9BrJhFr3qG55MFpwFs4YLabpuW3HhzUY9eQxPlDqaZw=="], + + "@pkgjs/parseargs": ["@pkgjs/parseargs@0.11.0", "", {}, "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg=="], + + "@redis/bloom": ["@redis/bloom@6.4.0", "", { "peerDependencies": { "@redis/client": "^6.4.0" } }, "sha512-haBv1OKeJoKxoAxwKEHPDKdoZaLIuWAKNr4VFRF2C3Rjjn7Ese5fijEW6295rMBIyddZfuIOcvH1aZ/yKzy8vQ=="], + + "@redis/client": ["@redis/client@6.4.0", "", { "peerDependencies": { "@node-rs/xxhash": "^1.1.0", "@opentelemetry/api": ">=1 <2" }, "optionalPeers": ["@node-rs/xxhash", "@opentelemetry/api"] }, "sha512-XEFSX0W1BUVFwtWC41vk5P/U5CqvacBWypFbmYHdF1gJeIYWWmEzsM2R5mPb+65SdODFQk7xuuMPFP6s1t9nhw=="], + + "@redis/json": ["@redis/json@6.4.0", "", { "peerDependencies": { "@redis/client": "^6.4.0" } }, "sha512-Dtxn3c2u5H5r3MA6kMrFI6iSOo4BIwibwkep94BMBD5ba1Eik1UYIwInX9lZ10RdUT4+BD7ZS9lAoORBvXUEYg=="], + + "@redis/search": ["@redis/search@6.4.0", "", { "peerDependencies": { "@redis/client": "^6.4.0" } }, "sha512-B4L2OD5BMwbOYewQ9KGJfukLUkRQz1gc91TEOxz76KLeJsLbHB0XXa7sKMNoB3JURPWvhuY0PE04fHQVYZPZKg=="], + + "@redis/time-series": ["@redis/time-series@6.4.0", "", { "peerDependencies": { "@redis/client": "^6.4.0" } }, "sha512-5QpeIlX/r0h0//JfJ8h4/Il9i0SGHhnOkdcocOhFDp0pb8VgVCEkxeCkUx8IR3g3rlq+uiPIf4NCueveHS9Vbw=="], + + "@sigstore/bundle": ["@sigstore/bundle@4.0.0", "", { "dependencies": { "@sigstore/protobuf-specs": "^0.5.0" } }, "sha512-NwCl5Y0V6Di0NexvkTqdoVfmjTaQwoLM236r89KEojGmq/jMls8S+zb7yOwAPdXvbwfKDlP+lmXgAL4vKSQT+A=="], + + "@sigstore/core": ["@sigstore/core@3.2.1", "", {}, "sha512-qRsxPnCrbC/puegGxKuynfnxgLiHqWStrSjxkoB4YKqq3Z3s4cyZyj42ZdWFAEblNP65C+rBH8EuREHIXoi83g=="], + + "@sigstore/protobuf-specs": ["@sigstore/protobuf-specs@0.5.2", "", {}, "sha512-SQqvFMt4V78fdjcDdYX6HbiVSOR4QK3ZgwCa2KOsopAgPIHy1rU5UDUmzLl02r5oyyaYcYHR1hpwDRk/yUe+Mw=="], + + "@sigstore/sign": ["@sigstore/sign@4.1.1", "", { "dependencies": { "@gar/promise-retry": "^1.0.2", "@sigstore/bundle": "^4.0.0", "@sigstore/core": "^3.2.0", "@sigstore/protobuf-specs": "^0.5.0", "make-fetch-happen": "^15.0.4", "proc-log": "^6.1.0" } }, "sha512-Hf4xglukg0XXQ2RiD5vSoLjdPe8OBUPA8XeVjUObheuDcWdYWrnH/BNmxZCzkAy68MzmNCxXLeurJvs6hcP2OQ=="], + + "@sigstore/tuf": ["@sigstore/tuf@4.0.2", "", { "dependencies": { "@sigstore/protobuf-specs": "^0.5.0", "tuf-js": "^4.1.0" } }, "sha512-TCAzTy0xzdP79EnxSjq9KQ3eaR7+FmudLC6eRKknVKZbV7ZNlGLClAAQb/HMNJ5n2OBNk2GT1tEmU0xuPr+SLQ=="], + + "@sigstore/verify": ["@sigstore/verify@3.1.1", "", { "dependencies": { "@sigstore/bundle": "^4.0.0", "@sigstore/core": "^3.2.1", "@sigstore/protobuf-specs": "^0.5.0" } }, "sha512-qv7+G3J2cc6wwFj3yKvXOamzqhMwSk1ogPGmhpS8iXllcPrJaIIBA+4HbttlHVu1pqWTdmaCH/WE7UOC51kdoA=="], + + "@smithy/core": ["@smithy/core@3.41.1", "", { "dependencies": { "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-24LyiHSY0R/MLcbTylurWXU6Uy4lzI6KJgsdzxkNnjT9/OLWc2zGPb/3k5AM1f0vcgCGrExanUG339t+TBiIrA=="], + + "@smithy/credential-provider-imds": ["@smithy/credential-provider-imds@4.5.2", "", { "dependencies": { "@smithy/core": "^3.33.2", "@smithy/types": "^4.17.2", "tslib": "^2.6.2" } }, "sha512-A9uSdn72ozbRUSit0eib0TW7nXuNPlaeM0zcGkJ+nE6tFcSDbnmtwoxbTCFBukVQcszDAyvsd7+rTduPTXpygg=="], + + "@smithy/eventstream-codec": ["@smithy/eventstream-codec@4.2.14", "", { "dependencies": { "@aws-crypto/crc32": "5.2.0", "@smithy/types": "^4.14.1", "@smithy/util-hex-encoding": "^4.2.2", "tslib": "^2.6.2" } }, "sha512-erZq0nOIpzfeZdCyzZjdJb4nVSKLUmSkaQUVkRGQTXs30gyUGeKnrYEg+Xe1W5gE3aReS7IgsvANwVPxSzY6Pw=="], + + "@smithy/fetch-http-handler": ["@smithy/fetch-http-handler@5.8.1", "", { "dependencies": { "@smithy/core": "^3.39.0", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-h8BdMUrUBhMhMaeK7QqAdINRZezCGuYOCpcOZZ1ewxbHST9rdTd09xwNpvLTYfzDRehxQiReK4SKbdYZxBA+ew=="], + + "@smithy/is-array-buffer": ["@smithy/is-array-buffer@2.2.0", "", { "dependencies": { "tslib": "^2.6.2" } }, "sha512-GGP3O9QFD24uGeAXYUjwSTXARoqpZykHadOmA8G5vfJPK0/DC67qa//0qvqrJzL1xc8WQWX7/yc7fwudjPHPhA=="], + + "@smithy/node-http-handler": ["@smithy/node-http-handler@4.14.2", "", { "dependencies": { "@smithy/core": "^3.39.0", "@smithy/types": "^4.20.0", "tslib": "^2.6.2" } }, "sha512-i1uORV1v3qBqP43ayRKzIdm1q5x14tf8N4Dd06/QUX1Szm6VxHMrTsu20X5E63UFsaNZCRjI4SXG0jDmqYa+3w=="], + + "@smithy/signature-v4": ["@smithy/signature-v4@5.7.5", "", { "dependencies": { "@smithy/core": "^3.38.0", "@smithy/types": "^4.19.0", "tslib": "^2.6.2" } }, "sha512-WPjdr5oWOk1LArpI4pavu+fSo+/evi0Re1olxGvqwuZopd4gYR1UGCi+Soyn/IjmafqbWs+ZC+3AKxJS3ZpwUg=="], + + "@smithy/types": ["@smithy/types@4.20.0", "", { "dependencies": { "tslib": "^2.6.2" } }, "sha512-lCA6QG22dPk9ecHbv91jDQZsmtPUjdS1aE2Il6NNPqe7DrYc0dZQi6DhcESk2KYXH2sp5xbAcGdYMZDFnuzA2A=="], + + "@smithy/util-buffer-from": ["@smithy/util-buffer-from@4.5.2", "", { "dependencies": { "@smithy/core": "^3.33.2", "tslib": "^2.6.2" } }, "sha512-nxu3SgmAw9JXT2CtkU0m/XNLWpP9MsaBx1zAGAypCbYj15tIFlmcYwpF+Oh18le83d+IM9PT7ENdXnE4C+d5mA=="], + + "@smithy/util-hex-encoding": ["@smithy/util-hex-encoding@4.5.2", "", { "dependencies": { "@smithy/core": "^3.33.2", "tslib": "^2.6.2" } }, "sha512-iq+cW3mAb7vfcxEEpYi3zXKpDtbrIFyanWjQl4zBq4seWD4OSxXDWSfespZxenX6aEaighn+NR3u1nU1DSvs3w=="], + + "@smithy/util-utf8": ["@smithy/util-utf8@4.2.2", "", { "dependencies": { "@smithy/util-buffer-from": "^4.2.2", "tslib": "^2.6.2" } }, "sha512-75MeYpjdWRe8M5E3AW0O4Cx3UadweS+cwdXjwYGBW5h/gxxnbeZ877sLPX/ZJA9GVTlL/qG0dXP29JWFCD1Ayw=="], + + "@standard-schema/spec": ["@standard-schema/spec@1.1.0", "", {}, "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w=="], + + "@tufjs/canonical-json": ["@tufjs/canonical-json@2.0.0", "", {}, "sha512-yVtV8zsdo8qFHe+/3kw81dSLyF7D576A5cCFCi4X7B39tWT7SekaEFUnvnWJHz+9qO7qJTah1JbrDjWKqFtdWA=="], + + "@tufjs/models": ["@tufjs/models@4.1.0", "", { "dependencies": { "@tufjs/canonical-json": "2.0.0", "minimatch": "^10.1.1" } }, "sha512-Y8cK9aggNRsqJVaKUlEYs4s7CvQ1b1ta2DVPyAimb0I2qhzjNk+A+mxvll/klL0RlfuIUei8BF7YWiua4kQqww=="], + + "@types/node": ["@types/node@24.12.2", "", { "dependencies": { "undici-types": "~7.16.0" } }, "sha512-A1sre26ke7HDIuY/M23nd9gfB+nrmhtYyMINbjI1zHJxYteKR6qSMX56FsmjMcDb3SMcjJg5BiRRgOCC/yBD0g=="], + + "@types/ws": ["@types/ws@8.18.2", "", { "dependencies": { "@types/node": "*" } }, "sha512-67MQl+fpWKVTT1NYdnmo3U4sc/xPo/zQBncVnI74qmQa0z/b+1g6iYqNmGCPbxO+zz2aklb08a0oHfegiVd0/w=="], + + "abbrev": ["abbrev@4.0.0", "", {}, "sha512-a1wflyaL0tHtJSmLSOVybYhy22vRih4eduhhrkcjgrWGnRfrZtovJ2FRjxuTtkkj47O/baf0R86QU5OuYpz8fA=="], + + "agent-base": ["agent-base@7.1.4", "", {}, "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ=="], + + "ansi-regex": ["ansi-regex@6.6.0", "", {}, "sha512-XZ5apbzreCbXSKwPjJstu8R0zOi247w3XYwWxtwBXgpZrCyc1Ka7p9/xY0A9/diMewmHbEKz+FIraWaEWjlN5g=="], + + "ansi-styles": ["ansi-styles@6.2.3", "", {}, "sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg=="], + + "aws4fetch": ["aws4fetch@1.0.20", "", {}, "sha512-/djoAN709iY65ETD6LKCtyyEI04XIBP5xVvfmNxsEP0uJB5tyaGBztSryRr4HqMStr9R06PisQE7m9zDTXKu6g=="], + + "balanced-match": ["balanced-match@4.0.4", "", {}, "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA=="], + + "base64-js": ["base64-js@1.5.1", "", {}, "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA=="], + + "bignumber.js": ["bignumber.js@9.3.1", "", {}, "sha512-Ko0uX15oIUS7wJ3Rb30Fs6SkVbLmPBAKdlm7q9+ak9bbIeFf0MwuBsQV6z7+X768/cHsfg+WlysDWJcmthjsjQ=="], + + "bin-links": ["bin-links@6.0.3", "", { "dependencies": { "cmd-shim": "^8.0.0", "npm-normalize-package-bin": "^5.0.0", "proc-log": "^6.0.0", "read-cmd-shim": "^6.0.0", "write-file-atomic": "^7.0.0" } }, "sha512-Qg5FD7/YSReWJB1zaM8VIi1l4O637JKK/WPaF/JzJGy/9FcMDWtSklF0dOX5S9X2OMrPGhifIHIKuwtHG0IGFg=="], + + "bowser": ["bowser@2.15.1", "", {}, "sha512-ma47ABeUiTsmG4McKDtGCgQSiTCatM97Mlbn13K42N1kPSFE14oN3WFMjtyL4KubhGvQTqYheKl4Qx2bJtMXLQ=="], + + "brace-expansion": ["brace-expansion@5.1.0", "", { "dependencies": { "balanced-match": "^4.0.2" } }, "sha512-aa11Dv491GKnYqxaul3aRJ0szew7yMJMfZPnqD44NjGrZXoj62l41OEDDpdpC4eE2P88vBFfLuSyRhpG91NUvg=="], + + "buffer-equal-constant-time": ["buffer-equal-constant-time@1.0.1", "", {}, "sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA=="], + + "bundle-name": ["bundle-name@4.1.1", "", { "dependencies": { "run-applescript": "^7.0.0" } }, "sha512-DdH81/zPLVS11EUgWq3tEu/xn+EzljlMYooDNdzWEnFha3R3NBMpMV1UqYIpjYHV/SgpFKMIX1Oh7o06SjM/oA=="], + + "cacache": ["cacache@20.0.4", "", { "dependencies": { "@npmcli/fs": "^5.0.0", "fs-minipass": "^3.0.0", "glob": "^13.0.0", "lru-cache": "^11.1.0", "minipass": "^7.0.3", "minipass-collect": "^2.0.1", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", "p-map": "^7.0.2", "ssri": "^13.0.0" } }, "sha512-M3Lab8NPYlZU2exsL3bMVvMrMqgwCnMWfdZbK28bn3pK6APT/Te/I8hjRPNu1uwORY9a1eEQoifXbKPQMfMTOA=="], + + "chownr": ["chownr@3.0.0", "", {}, "sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g=="], + + "ci-info": ["ci-info@4.5.0", "", {}, "sha512-d1uM8k5UZEyPza1n/MG3ko8nKupKN0KJpFsipgPcgaCCvV+IqIfJ+NzTjetlLM+UcXZx3+cLrNr76+eAO7G1Mw=="], + + "cmd-shim": ["cmd-shim@8.0.0", "", {}, "sha512-Jk/BK6NCapZ58BKUxlSI+ouKRbjH1NLZCgJkYoab+vEHUY3f6OzpNBN9u7HFSv9J6TRDGs4PLOHezoKGaFRSCA=="], + + "color-convert": ["color-convert@2.0.1", "", { "dependencies": { "color-name": "~1.1.4" } }, "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ=="], + + "color-name": ["color-name@1.1.4", "", {}, "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="], + + "common-ancestor-path": ["common-ancestor-path@2.0.0", "", {}, "sha512-dnN3ibLeoRf2HNC+OlCiNc5d2zxbLJXOtiZUudNFSXZrNSydxcCsSpRzXwfu7BBWCIfHPw+xTayeBvJCP/D8Ng=="], + + "content-type": ["content-type@2.1.0", "", {}, "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag=="], + + "cross-spawn": ["cross-spawn@7.0.6", "", { "dependencies": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", "which": "^2.0.1" } }, "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA=="], + + "data-uri-to-buffer": ["data-uri-to-buffer@4.0.1", "", {}, "sha512-0R9ikRb668HB7QDxT1vkpuUBtqc53YyAwMwGeUFKRojY/NWKvdZ+9UYtRfGmhqNbRkTSVpMbmyhXipFFv2cb/A=="], + + "debug": ["debug@4.4.3", "", { "dependencies": { "ms": "^2.1.3" }, "peerDependencies": { "supports-color": "*" }, "optionalPeers": ["supports-color"] }, "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA=="], + + "default-browser": ["default-browser@5.5.1", "", { "dependencies": { "bundle-name": "^4.1.0", "default-browser-id": "^5.0.0" } }, "sha512-m1pAzaJgZ/gssEqlOhJkPJp8Xly7QyW6xcrkUa2KKcDeDSEMP7X8xipU3snUcfisTQx0w1AGae+9UtJSfVnXGw=="], + + "default-browser-id": ["default-browser-id@5.0.1", "", {}, "sha512-x1VCxdX4t+8wVfd1so/9w+vQ4vx7lKd2Qp5tDRutErwmR85OgmfX7RlLRMWafRMY7hbEiXIbudNrjOAPa/hL8Q=="], + + "define-lazy-prop": ["define-lazy-prop@3.0.0", "", {}, "sha512-N+MeXYoqr3pOgn8xfyRPREN7gHakLYjhsHhWGT3fWAiL4IkAt0iDw14QiiEm2bE30c5XX5q0FtAA3CK5f9/BUg=="], + + "eastasianwidth": ["eastasianwidth@0.2.0", "", {}, "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA=="], + + "ecdsa-sig-formatter": ["ecdsa-sig-formatter@1.0.11", "", { "dependencies": { "safe-buffer": "^5.0.1" } }, "sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ=="], + + "effect": ["effect@4.1.0", "", {}, "sha512-lGx2MJJyrXA8RZb2UpQ/0Nkb5Utaimby7oD92+18noBxLPE85IFOvptdzau8dvcxAOwfwHo9iqapbKeFzqQM/Q=="], + + "emoji-regex": ["emoji-regex@9.2.2", "", {}, "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg=="], + + "env-paths": ["env-paths@2.2.1", "", {}, "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A=="], + + "exponential-backoff": ["exponential-backoff@3.1.3", "", {}, "sha512-ZgEeZXj30q+I0EN+CbSSpIyPaJ5HVQD18Z1m+u1FXbAeT94mr1zw50q4q6jiiC447Nl/YTcIYSAftiGqetwXCA=="], + + "extend": ["extend@3.0.2", "", {}, "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="], + + "fdir": ["fdir@6.5.0", "", { "peerDependencies": { "picomatch": "^3 || ^4" }, "optionalPeers": ["picomatch"] }, "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg=="], + + "fetch-blob": ["fetch-blob@3.2.0", "", { "dependencies": { "node-domexception": "^1.0.0", "web-streams-polyfill": "^3.0.3" } }, "sha512-7yAQpD2UMJzLi1Dqv7qFYnPbaPx7ZfFK6PiIxQ4PfkGPyNyl2Ugx+a/umUonmKqjhM4DnfbMvdX6otXq83soQQ=="], + + "foreground-child": ["foreground-child@3.3.1", "", { "dependencies": { "cross-spawn": "^7.0.6", "signal-exit": "^4.0.1" } }, "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw=="], + + "formdata-polyfill": ["formdata-polyfill@4.0.10", "", { "dependencies": { "fetch-blob": "^3.1.2" } }, "sha512-buewHzMvYL29jdeQTVILecSaZKnt/RJWjoZCF5OW60Z67/GmSLBkOFM7qh1PI3zFNtJbaZL5eQu1vLfazOwj4g=="], + + "fs-minipass": ["fs-minipass@3.0.3", "", { "dependencies": { "minipass": "^7.0.3" } }, "sha512-XUBA9XClHbnJWSfBzjkm6RvPsyg3sryZt06BEQoXcF7EK/xpGaQYJgQKDJSUH5SGZ76Y7pFx1QBnXz09rU5Fbw=="], + + "gaxios": ["gaxios@7.1.3", "", { "dependencies": { "extend": "^3.0.2", "https-proxy-agent": "^7.0.1", "node-fetch": "^3.3.2", "rimraf": "^5.0.1" } }, "sha512-YGGyuEdVIjqxkxVH1pUTMY/XtmmsApXrCVv5EU25iX6inEPbV+VakJfLealkBtJN69AQmh1eGOdCl9Sm1UP6XQ=="], + + "gcp-metadata": ["gcp-metadata@8.1.4", "", { "dependencies": { "gaxios": "7.1.3", "google-logging-utils": "1.1.3", "json-bigint": "^1.0.0" } }, "sha512-iJ9KMsiu+xKtNRX0PmGLSaIU3bUBAyzWTyqKemKPzNPsmmsBCQYmlNg+brEbES7IHSXtdVwzBPzx1vz3FAaipw=="], + + "glob": ["glob@13.0.5", "", { "dependencies": { "minimatch": "^10.2.1", "minipass": "^7.1.2", "path-scurry": "^2.0.0" } }, "sha512-BzXxZg24Ibra1pbQ/zE7Kys4Ua1ks7Bn6pKLkVPZ9FZe4JQS6/Q7ef3LG1H+k7lUf5l4T3PLSyYyYJVYUvfgTw=="], + + "google-auth-library": ["google-auth-library@10.5.0", "", { "dependencies": { "base64-js": "^1.3.0", "ecdsa-sig-formatter": "^1.0.11", "gaxios": "^7.0.0", "gcp-metadata": "^8.0.0", "google-logging-utils": "^1.0.0", "gtoken": "^8.0.0", "jws": "^4.0.0" } }, "sha512-7ABviyMOlX5hIVD60YOfHw4/CxOfBhyduaYB+wbFWCWoni4N7SLcV46hrVRktuBbZjFC9ONyqamZITN7q3n32w=="], + + "google-logging-utils": ["google-logging-utils@1.1.3", "", {}, "sha512-eAmLkjDjAFCVXg7A1unxHsLf961m6y17QFqXqAXGj/gVkKFrEICfStRfwUlGNfeCEjNRa32JEWOUTlYXPyyKvA=="], + + "graceful-fs": ["graceful-fs@4.2.12", "", {}, "sha512-iuyGF2E4oafQfPsRrG2wtY2ILupMhvtdrhzrxB+0VcjsPpSPttpfYdjnGFGsTi5MaJFjI1jOKHPQ6UTbTj9TAw=="], + + "gtoken": ["gtoken@8.0.0", "", { "dependencies": { "gaxios": "^7.0.0", "jws": "^4.0.0" } }, "sha512-+CqsMbHPiSTdtSO14O51eMNlrp9N79gmeqmXeouJOhfucAedHw9noVe/n5uJk3tbKE6a+6ZCQg3RPhVhHByAIw=="], + + "hosted-git-info": ["hosted-git-info@9.0.3", "", { "dependencies": { "lru-cache": "^11.1.0" } }, "sha512-Hc+ghLoSt6QaYZUv0WBiIvmMDZuZZ7oaDvdH8MbfOO4lOsxdXLEvuC6ePoGs9H1X9oCLyq6+NVN0MKqD+ydxyg=="], + + "http-cache-semantics": ["http-cache-semantics@4.3.0", "", {}, "sha512-M5t5LlJpS1UHMjvwRQVdFHvPISGeLAxNcrWuJkeGh0KxsqCHZ1O3NXZU/8x7cD0BDcGW8kapxMKTvwlqrNkHkA=="], + + "http-proxy-agent": ["http-proxy-agent@7.0.2", "", { "dependencies": { "agent-base": "^7.1.0", "debug": "^4.3.4" } }, "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig=="], + + "https-proxy-agent": ["https-proxy-agent@7.0.6", "", { "dependencies": { "agent-base": "^7.1.2", "debug": "4" } }, "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw=="], + + "iconv-lite": ["iconv-lite@0.7.3", "", { "dependencies": { "safer-buffer": ">= 2.1.2 < 3.0.0" } }, "sha512-IKXpvIzjnC9XTAUbVBcMfGS0EPaIXtW6v+zr+RRp+hqULEpo0owZax6wyRwPOJbWbzjYspQwusTsfVr0ifh4uQ=="], + + "ignore-walk": ["ignore-walk@8.0.0", "", { "dependencies": { "minimatch": "^10.0.3" } }, "sha512-FCeMZT4NiRQGh+YkeKMtWrOmBgWjHjMJ26WQWrRQyoyzqevdaGSakUaJW5xQYmjLlUVk2qUnCjYVBax9EKKg8A=="], + + "ini": ["ini@6.0.0", "", {}, "sha512-IBTdIkzZNOpqm7q3dRqJvMaldXjDHWkEDfrwGEQTs5eaQMWV+djAhR+wahyNNMAa+qpbDUhBMVt4ZKNwpPm7xQ=="], + + "ip-address": ["ip-address@10.7.7", "", {}, "sha512-He15rAs4jip5AEAz7XM9L+S6Y8LBMIDj6YewbYuJfmDnOCKWb+3TLOGnHFBTAIW7wpm5ohtZ+Xyo5PEaG+O2vQ=="], + + "is-docker": ["is-docker@3.0.0", "", { "bin": { "is-docker": "cli.js" } }, "sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ=="], + + "is-fullwidth-code-point": ["is-fullwidth-code-point@3.0.0", "", {}, "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg=="], + + "is-in-ssh": ["is-in-ssh@1.0.0", "", {}, "sha512-jYa6Q9rH90kR1vKB6NM7qqd1mge3Fx4Dhw5TVlK1MUBqhEOuCagrEHMevNuCcbECmXZ0ThXkRm+Ymr51HwEPAw=="], + + "is-inside-container": ["is-inside-container@1.0.0", "", { "dependencies": { "is-docker": "^3.0.0" }, "bin": { "is-inside-container": "cli.js" } }, "sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA=="], + + "is-wsl": ["is-wsl@3.1.1", "", { "dependencies": { "is-inside-container": "^1.0.0" } }, "sha512-e6rvdUCiQCAuumZslxRJWR/Doq4VpPR82kqclvcS0efgt430SlGIk05vdCN58+VrzgtIcfNODjozVielycD4Sw=="], + + "isexe": ["isexe@2.0.0", "", {}, "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw=="], + + "jackspeak": ["jackspeak@3.4.3", "", { "dependencies": { "@isaacs/cliui": "^8.0.2" }, "optionalDependencies": { "@pkgjs/parseargs": "^0.11.0" } }, "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw=="], + + "json-bigint": ["json-bigint@1.0.0", "", { "dependencies": { "bignumber.js": "^9.0.0" } }, "sha512-SiPv/8VpZuWbvLSMtTDU8hEfrZWg/mH/nV/b4o0CYbSxu1UIQPLdwKOCIyLQX+VIPO5vrLX3i8qtqFyhdPSUSQ=="], + + "json-parse-even-better-errors": ["json-parse-even-better-errors@5.0.0", "", {}, "sha512-ZF1nxZ28VhQouRWhUcVlUIN3qwSgPuswK05s/HIaoetAoE/9tngVmCHjSxmSQPav1nd+lPtTL0YZ/2AFdR/iYQ=="], + + "json-schema": ["json-schema@0.4.0", "", {}, "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA=="], + + "json-stringify-nice": ["json-stringify-nice@1.1.4", "", {}, "sha512-5Z5RFW63yxReJ7vANgW6eZFGWaQvnPE3WNmZoOJrSkGju2etKA2L5rrOa1sm877TVTFt57A80BH1bArcmlLfPw=="], + + "jsonparse": ["jsonparse@1.3.1", "", {}, "sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg=="], + + "just-diff": ["just-diff@6.0.2", "", {}, "sha512-S59eriX5u3/QhMNq3v/gm8Kd0w8OS6Tz2FS1NG4blv+z0MuQcBRJyFWjdovM0Rad4/P4aUPFtnkNjMjyMlMSYA=="], + + "just-diff-apply": ["just-diff-apply@5.5.0", "", {}, "sha512-OYTthRfSh55WOItVqwpefPtNt2VdKsq5AnAK6apdtR6yCH8pr0CmSr710J0Mf+WdQy7K/OzMy7K2MgAfdQURDw=="], + + "jwa": ["jwa@2.0.1", "", { "dependencies": { "buffer-equal-constant-time": "^1.0.1", "ecdsa-sig-formatter": "1.0.11", "safe-buffer": "^5.0.1" } }, "sha512-hRF04fqJIP8Abbkq5NKGN0Bbr3JxlQ+qhZufXVr0DvujKy93ZCbXZMHDL4EOtodSbCWxOqR8MS1tXA5hwqCXDg=="], + + "jws": ["jws@4.0.1", "", { "dependencies": { "jwa": "^2.0.1", "safe-buffer": "^5.0.1" } }, "sha512-EKI/M/yqPncGUUh44xz0PxSidXFr/+r0pA70+gIYhjv+et7yxM+s29Y+VGDkovRofQem0fs7Uvf4+YmAdyRduA=="], + + "lru-cache": ["lru-cache@11.5.3", "", {}, "sha512-U4N8FgzmWxc8k1VH8Kr6lQg18U7Fjvby6wXHVRX/ZZ7IwWbRMgrRbP0Wrb5q5NVinryp4SQampHKdvtecItxUg=="], + + "make-fetch-happen": ["make-fetch-happen@15.0.6", "", { "dependencies": { "@gar/promise-retry": "^1.0.0", "@npmcli/agent": "^4.0.0", "@npmcli/redact": "^4.0.0", "cacache": "^20.0.1", "http-cache-semantics": "^4.1.1", "minipass": "^7.0.2", "minipass-fetch": "^5.0.0", "minipass-flush": "^1.0.5", "minipass-pipeline": "^1.2.4", "negotiator": "^1.0.0", "proc-log": "^6.0.0", "ssri": "^13.0.0" } }, "sha512-Je0fLJ0F5atA7F+eIlLzk+Wkcl57JDf4kf+EW8xiP5E31xOQxkIxTbgf1Oi1Lw9tRI9UEMRdI5Vz2xTzoNU1Jw=="], + + "mime-db": ["mime-db@1.54.0", "", {}, "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ=="], + + "mime-types": ["mime-types@3.0.2", "", { "dependencies": { "mime-db": "^1.54.0" } }, "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A=="], + + "minimatch": ["minimatch@10.2.5", "", { "dependencies": { "brace-expansion": "^5.0.5" } }, "sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg=="], + + "minipass": ["minipass@7.1.3", "", {}, "sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A=="], + + "minipass-collect": ["minipass-collect@2.0.1", "", { "dependencies": { "minipass": "^7.0.3" } }, "sha512-D7V8PO9oaz7PWGLbCACuI1qEOsq7UKfLotx/C0Aet43fCUB/wfQ7DYeq2oR/svFJGYDHPr38SHATeaj/ZoKHKw=="], + + "minipass-fetch": ["minipass-fetch@5.0.2", "", { "dependencies": { "minipass": "^7.0.3", "minipass-sized": "^2.0.0", "minizlib": "^3.0.1" }, "optionalDependencies": { "iconv-lite": "^0.7.2" } }, "sha512-2d0q2a8eCi2IRg/IGubCNRJoYbA1+YPXAzQVRFmB45gdGZafyivnZ5YSEfo3JikbjGxOdntGFvBQGqaSMXlAFQ=="], + + "minipass-flush": ["minipass-flush@1.0.7", "", { "dependencies": { "minipass": "^3.0.0" } }, "sha512-TbqTz9cUwWyHS2Dy89P3ocAGUGxKjjLuR9z8w4WUTGAVgEj17/4nhgo2Du56i0Fm3Pm30g4iA8Lcqctc76jCzA=="], + + "minipass-pipeline": ["minipass-pipeline@1.2.4", "", { "dependencies": { "minipass": "^3.0.0" } }, "sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A=="], + + "minipass-sized": ["minipass-sized@2.0.0", "", { "dependencies": { "minipass": "^7.1.2" } }, "sha512-zSsHhto5BcUVM2m1LurnXY6M//cGhVaegT71OfOXoprxT6o780GZd792ea6FfrQkuU4usHZIUczAQMRUE2plzA=="], + + "minizlib": ["minizlib@3.1.0", "", { "dependencies": { "minipass": "^7.1.2" } }, "sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw=="], + + "ms": ["ms@2.1.3", "", {}, "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA=="], + + "negotiator": ["negotiator@1.1.0", "", { "dependencies": { "content-type": "^2.1.0" } }, "sha512-NMPBRMJgiQHjbd8phG3Vebdx4kZ1H121rbl5IkMqeOsahptB9BKo/d7oJ3zTXqTgagn2bWlNSXkh0QUGM31RYg=="], + + "node-domexception": ["node-domexception@1.0.0", "", {}, "sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ=="], + + "node-fetch": ["node-fetch@3.3.2", "", { "dependencies": { "data-uri-to-buffer": "^4.0.0", "fetch-blob": "^3.1.4", "formdata-polyfill": "^4.0.10" } }, "sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA=="], + + "node-gyp": ["node-gyp@12.4.0", "", { "dependencies": { "env-paths": "^2.2.0", "exponential-backoff": "^3.1.1", "graceful-fs": "^4.2.6", "nopt": "^9.0.0", "proc-log": "^6.0.0", "semver": "^7.3.5", "tar": "^7.5.4", "tinyglobby": "^0.2.12", "undici": "^6.25.0", "which": "^6.0.0" }, "bin": { "node-gyp": "bin/node-gyp.js" } }, "sha512-OMcPNvqTCFUnNaBlmdgq+lfNqY7gTiSmNRDjY3uAXRyudeKZEZxu3CLtjMQrx4zZxCX2b/mpNqTtwuCJgXhHkw=="], + + "nopt": ["nopt@9.0.0", "", { "dependencies": { "abbrev": "^4.0.0" }, "bin": { "nopt": "bin/nopt.js" } }, "sha512-Zhq3a+yFKrYwSBluL4H9XP3m3y5uvQkB/09CwDruCiRmR/UJYnn9W4R48ry0uGC70aeTPKLynBtscP9efFFcPw=="], + + "npm-bundled": ["npm-bundled@5.0.0", "", { "dependencies": { "npm-normalize-package-bin": "^5.0.0" } }, "sha512-JLSpbzh6UUXIEoqPsYBvVNVmyrjVZ1fzEFbqxKkTJQkWBO3xFzFT+KDnSKQWwOQNbuWRwt5LSD6HOTLGIWzfrw=="], + + "npm-install-checks": ["npm-install-checks@8.0.0", "", { "dependencies": { "semver": "^7.1.1" } }, "sha512-ScAUdMpyzkbpxoNekQ3tNRdFI8SJ86wgKZSQZdUxT+bj0wVFpsEMWnkXP0twVe1gJyNF5apBWDJhhIbgrIViRA=="], + + "npm-normalize-package-bin": ["npm-normalize-package-bin@5.0.0", "", {}, "sha512-CJi3OS4JLsNMmr2u07OJlhcrPxCeOeP/4xq67aWNai6TNWWbTrlNDgl8NcFKVlcBKp18GPj+EzbNIgrBfZhsag=="], + + "npm-package-arg": ["npm-package-arg@13.0.2", "", { "dependencies": { "hosted-git-info": "^9.0.0", "proc-log": "^6.0.0", "semver": "^7.3.5", "validate-npm-package-name": "^7.0.0" } }, "sha512-IciCE3SY3uE84Ld8WZU23gAPPV9rIYod4F+rc+vJ7h7cwAJt9Vk6TVsK60ry7Uj3SRS3bqRRIGuTp9YVlk6WNA=="], + + "npm-packlist": ["npm-packlist@10.0.4", "", { "dependencies": { "ignore-walk": "^8.0.0", "proc-log": "^6.0.0" } }, "sha512-uMW73iajD8hiH4ZBxEV3HC+eTnppIqwakjOYuvgddnalIw2lJguKviK1pcUJDlIWm1wSJkchpDZDSVVsZEYRng=="], + + "npm-pick-manifest": ["npm-pick-manifest@11.0.3", "", { "dependencies": { "npm-install-checks": "^8.0.0", "npm-normalize-package-bin": "^5.0.0", "npm-package-arg": "^13.0.0", "semver": "^7.3.5" } }, "sha512-buzyCfeoGY/PxKqmBqn1IUJrZnUi1VVJTdSSRPGI60tJdUhUoSQFhs0zycJokDdOznQentgrpf8LayEHyyYlqQ=="], + + "npm-registry-fetch": ["npm-registry-fetch@19.1.1", "", { "dependencies": { "@npmcli/redact": "^4.0.0", "jsonparse": "^1.3.1", "make-fetch-happen": "^15.0.0", "minipass": "^7.0.2", "minipass-fetch": "^5.0.0", "minizlib": "^3.0.1", "npm-package-arg": "^13.0.0", "proc-log": "^6.0.0" } }, "sha512-TakBap6OM1w0H73VZVDf44iFXsOS3h+L4wVMXmbWOQroZgFhMch0juN6XSzBNlD965yIKvWg2dfu7NSiaYLxtw=="], + + "open": ["open@11.0.4", "", { "dependencies": { "default-browser": "^5.5.1", "define-lazy-prop": "^3.0.0", "is-in-ssh": "^1.0.0", "is-inside-container": "^1.0.0", "powershell-utils": "^0.2.1", "wsl-utils": "^1.0.0" } }, "sha512-++Zlftm0kVLPmzC06t6epuWmcRMDbI4z5P3NNX979WA/k23+NtSOynEGzsVfZwguKw2mi5umVgnBlJQMwRz4Pg=="], + + "p-map": ["p-map@7.1.1", "", {}, "sha512-6Lh3jQPLthYujSrlw6ccWXBGZTkoTCz27Hd92g79LH/kjAbgoEu0t442cCCNbegPSJsA0lwDX8z0bcKtkpA32g=="], + + "package-json-from-dist": ["package-json-from-dist@1.0.1", "", {}, "sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw=="], + + "pacote": ["pacote@21.5.1", "", { "dependencies": { "@gar/promise-retry": "^1.0.0", "@npmcli/git": "^7.0.0", "@npmcli/installed-package-contents": "^4.0.0", "@npmcli/package-json": "^7.0.0", "@npmcli/promise-spawn": "^9.0.0", "@npmcli/run-script": "^10.0.0", "cacache": "^20.0.0", "fs-minipass": "^3.0.0", "minipass": "^7.0.2", "npm-package-arg": "^13.0.0", "npm-packlist": "^10.0.1", "npm-pick-manifest": "^11.0.1", "npm-registry-fetch": "^19.0.0", "proc-log": "^6.0.0", "sigstore": "^4.0.0", "ssri": "^13.0.0", "tar": "^7.4.3" }, "bin": { "pacote": "bin/index.js" } }, "sha512-KvcJ9iy3crysCsgqc4+PknH/w6jkrp8JN36mpZBPwNaDRwTfMZD37YzRazNstiZUOhuF5pno9f78n9mEJBavwg=="], + + "parse-conflict-json": ["parse-conflict-json@5.0.1", "", { "dependencies": { "json-parse-even-better-errors": "^5.0.0", "just-diff": "^6.0.0", "just-diff-apply": "^5.2.0" } }, "sha512-ZHEmNKMq1wyJXNwLxyHnluPfRAFSIliBvbK/UiOceROt4Xh9Pz0fq49NytIaeaCUf5VR86hwQ/34FCcNU5/LKQ=="], + + "path-key": ["path-key@3.1.1", "", {}, "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q=="], + + "path-scurry": ["path-scurry@2.0.2", "", { "dependencies": { "lru-cache": "^11.0.0", "minipass": "^7.1.2" } }, "sha512-3O/iVVsJAPsOnpwWIeD+d6z/7PmqApyQePUtCndjatj/9I5LylHvt5qluFaBT3I5h3r1ejfR056c+FCv+NnNXg=="], + + "picomatch": ["picomatch@4.0.7", "", {}, "sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA=="], + + "postcss-selector-parser": ["postcss-selector-parser@7.2.1", "", { "dependencies": { "util-deprecate": "^1.0.2" } }, "sha512-GwxlMgTTXwIom+ebC7an3k6RaJDwklRQQnfiXsLPGicu8FYV/k/+1/9YY2OU2+r938H2t4X0TDxoif+HP2rjzQ=="], + + "powershell-utils": ["powershell-utils@0.2.1", "", {}, "sha512-C+y9x90UElAddDZmV4qOx9W53B61PO7cIqWz2dQsWlwswuq4mr8NEwytdGKboYbQlGZ3awrkTeNvcZiZNHnQ8A=="], + + "proc-log": ["proc-log@6.1.0", "", {}, "sha512-iG+GYldRf2BQ0UDUAd6JQ/RwzaQy6mXmsk/IzlYyal4A4SNFw54MeH4/tLkF4I5WoWG9SQwuqWzS99jaFQHBuQ=="], + + "proggy": ["proggy@4.0.0", "", {}, "sha512-MbA4R+WQT76ZBm/5JUpV9yqcJt92175+Y0Bodg3HgiXzrmKu7Ggq+bpn6y6wHH+gN9NcyKn3yg1+d47VaKwNAQ=="], + + "promise-all-reject-late": ["promise-all-reject-late@1.0.1", "", {}, "sha512-vuf0Lf0lOxyQREH7GDIOUMLS7kz+gs8i6B+Yi8dC68a2sychGrHTJYghMBD6k7eUcH0H5P73EckCA48xijWqXw=="], + + "promise-call-limit": ["promise-call-limit@3.0.2", "", {}, "sha512-mRPQO2T1QQVw11E7+UdCJu7S61eJVWknzml9sC1heAdj1jxl0fWMBypIt9ZOcLFf8FkG995ZD7RnVk7HH72fZw=="], + + "read-cmd-shim": ["read-cmd-shim@6.0.0", "", {}, "sha512-1zM5HuOfagXCBWMN83fuFI/x+T/UhZ7k+KIzhrHXcQoeX5+7gmaDYjELQHmmzIodumBHeByBJT4QYS7ufAgs7A=="], + + "redis": ["redis@6.4.0", "", { "dependencies": { "@redis/bloom": "6.4.0", "@redis/client": "6.4.0", "@redis/json": "6.4.0", "@redis/search": "6.4.0", "@redis/time-series": "6.4.0" } }, "sha512-8Xk9zRovBNDzIO3xRi036QFgijIZKeIPjQJ5VhgxV8nxkxDP5GlE5se71G1I4TnUTojbCtmfKzXpioxlDhHJvg=="], + + "rimraf": ["rimraf@5.0.10", "", { "dependencies": { "glob": "^10.3.7" }, "bin": { "rimraf": "dist/esm/bin.mjs" } }, "sha512-l0OE8wL34P4nJH/H2ffoaniAokM2qSmrtXHmlpvYr5AVVX8msAyW0l8NVJFDxlSK4u3Uh/f41cQheDVdnYijwQ=="], + + "run-applescript": ["run-applescript@7.1.0", "", {}, "sha512-DPe5pVFaAsinSaV6QjQ6gdiedWDcRCbUuiQfQa2wmWV7+xC9bGulGI8+TdRmoFkAPaBXk8CrAbnlY2ISniJ47Q=="], + + "safe-buffer": ["safe-buffer@5.2.1", "", {}, "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="], + + "safer-buffer": ["safer-buffer@2.1.2", "", {}, "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="], + + "semver": ["semver@7.8.6", "", { "bin": { "semver": "bin/semver.js" } }, "sha512-9lpSSU4Mly3mrtruwLs1eLK6+gzbzqeBFwRNjIjE+9LuDpWdYctrQlQ3ej1Ilgi7gknpsTRnPoLP8DpCHqHIJw=="], + + "shebang-command": ["shebang-command@2.0.0", "", { "dependencies": { "shebang-regex": "^3.0.0" } }, "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA=="], + + "shebang-regex": ["shebang-regex@3.0.0", "", {}, "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A=="], + + "signal-exit": ["signal-exit@4.1.0", "", {}, "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw=="], + + "sigstore": ["sigstore@4.1.1", "", { "dependencies": { "@sigstore/bundle": "^4.0.0", "@sigstore/core": "^3.2.1", "@sigstore/protobuf-specs": "^0.5.0", "@sigstore/sign": "^4.1.1", "@sigstore/tuf": "^4.0.2", "@sigstore/verify": "^3.1.1" } }, "sha512-endqECJkfhozrXMK5ngu/UAA0xVcVEFdnHJCElGaExypjW+HK5i6zu3NteLoaX/iFbRUbC3+DjttQs0GARr+5w=="], + + "smart-buffer": ["smart-buffer@4.2.0", "", {}, "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg=="], + + "socks": ["socks@2.8.11", "", { "dependencies": { "ip-address": "^10.1.1", "smart-buffer": "^4.2.0" } }, "sha512-2H/uQ7+SNP0hK16RorTak0mWrFoqo4AnAVGSUl2dT07obgWdWt9grml+VDl1LklgUOPWM4Abo0u86Cvp8vFjYw=="], + + "socks-proxy-agent": ["socks-proxy-agent@8.0.5", "", { "dependencies": { "agent-base": "^7.1.2", "debug": "^4.3.4", "socks": "^2.8.3" } }, "sha512-HehCEsotFqbPW9sJ8WVYB6UbmIMv7kUUORIF2Nncq4VQvBfNBLibW9YZR5dlYCSUhwcD628pRllm7n+E+YTzJw=="], + + "spdx-exceptions": ["spdx-exceptions@2.5.0", "", {}, "sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w=="], + + "spdx-expression-parse": ["spdx-expression-parse@4.0.0", "", { "dependencies": { "spdx-exceptions": "^2.1.0", "spdx-license-ids": "^3.0.0" } }, "sha512-Clya5JIij/7C6bRR22+tnGXbc4VKlibKSVj2iHvVeX5iMW7s1SIQlqu699JkODJJIhh/pUu8L0/VLh8xflD+LQ=="], + + "spdx-license-ids": ["spdx-license-ids@3.0.24", "", {}, "sha512-cLS9TtWkIQFyLkJ3/5aFQAOHOSKTlOs/7WDut/XPSdjom1fJhUdkepeJAKXa9Y05+FabHd0sti+Et559vDtkpQ=="], + + "ssri": ["ssri@13.0.1", "", { "dependencies": { "minipass": "^7.0.3" } }, "sha512-QUiRf1+u9wPTL/76GTYlKttDEBWV1ga9ZXW8BG6kfdeyyM8LGPix9gROyg9V2+P0xNyF3X2Go526xKFdMZrHSQ=="], + + "string-width": ["string-width@5.1.2", "", { "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", "strip-ansi": "^7.0.1" } }, "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA=="], + + "string-width-cjs": ["string-width@4.2.3", "", { "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.1" } }, "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g=="], + + "strip-ansi": ["strip-ansi@7.2.0", "", { "dependencies": { "ansi-regex": "^6.2.2" } }, "sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w=="], + + "strip-ansi-cjs": ["strip-ansi@6.0.1", "", { "dependencies": { "ansi-regex": "^5.0.1" } }, "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A=="], + + "tar": ["tar@7.5.24", "", { "dependencies": { "@isaacs/fs-minipass": "^4.0.0", "chownr": "^3.0.0", "minipass": "^7.1.2", "minizlib": "^3.1.0", "yallist": "^5.0.0" } }, "sha512-to/OxuCk5DeVONcjjODT7aeoRq5NIPPlfPc0tNML+wLlnf6u5BcJz97Uukv3pT3jzorkFhUevylkAiBr+ZmV2w=="], + + "tinyglobby": ["tinyglobby@0.2.17", "", { "dependencies": { "fdir": "^6.5.0", "picomatch": "^4.0.4" } }, "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g=="], + + "treeverse": ["treeverse@3.0.0", "", {}, "sha512-gcANaAnd2QDZFmHFEOF4k7uc1J/6a6z3DJMd/QwEyxLoKGiptJRwid582r7QIsFlFMIZ3SnxfS52S4hm2DHkuQ=="], + + "tslib": ["tslib@2.9.1", "", {}, "sha512-a4Ux9VKuIMHsOS7ENbEq6hK2ZGYIT27Rtl0E4eD9KqwxhKiQeMZE/9xb3IdYwWaSOyIBQLExhQgXDTYoiCxnWA=="], + + "tuf-js": ["tuf-js@4.1.0", "", { "dependencies": { "@tufjs/models": "4.1.0", "debug": "^4.4.3", "make-fetch-happen": "^15.0.1" } }, "sha512-50QV99kCKH5P/Vs4E2Gzp7BopNV+KzTXqWeaxrfu5IQJBOULRsTIS9seSsOVT8ZnGXzCyx55nYWAi4qJzpZKEQ=="], + + "typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="], + + "undici": ["undici@8.14.0", "", {}, "sha512-MqM6wqORYo0jb1WFUwFKZTFWFz6VeBMPj9op5Hq+RvlrQjISQCyLEfx5+/iqOLWC/LL1HliJ5t0NP1BgYpXeVQ=="], + + "undici-types": ["undici-types@7.16.0", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="], + + "util-deprecate": ["util-deprecate@1.0.2", "", {}, "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw=="], + + "validate-npm-package-name": ["validate-npm-package-name@7.0.2", "", {}, "sha512-hVDIBwsRruT73PbK7uP5ebUt+ezEtCmzZz3F59BSr2F6OVFnJ/6h8liuvdLrQ88Xmnk6/+xGGuq+pG9WwTuy3A=="], + + "walk-up-path": ["walk-up-path@4.0.0", "", {}, "sha512-3hu+tD8YzSLGuFYtPRb48vdhKMi0KQV5sn+uWr8+7dMEq/2G/dtLrdDinkLjqq5TIbIBjYJ4Ax/n3YiaW7QM8A=="], + + "web-streams-polyfill": ["web-streams-polyfill@3.3.3", "", {}, "sha512-d2JWLCivmZYTSIoge9MsgFCZrt571BikcWGYkjC1khllbTeDlGqZ2D8vD8E/lJa8WGWbb7Plm8/XJYV7IJHZZw=="], + + "which": ["which@2.0.2", "", { "dependencies": { "isexe": "^2.0.0" }, "bin": { "node-which": "./bin/node-which" } }, "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA=="], + + "wrap-ansi": ["wrap-ansi@8.1.0", "", { "dependencies": { "ansi-styles": "^6.1.0", "string-width": "^5.0.1", "strip-ansi": "^7.0.1" } }, "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ=="], + + "wrap-ansi-cjs": ["wrap-ansi@7.0.0", "", { "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", "strip-ansi": "^6.0.0" } }, "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q=="], + + "write-file-atomic": ["write-file-atomic@7.0.1", "", { "dependencies": { "signal-exit": "^4.0.1" } }, "sha512-OTIk8iR8/aCRWBqvxrzxR0hgxWpnYBblY1S5hDWBQfk/VFmJwzmJgQFN3WsoUKHISv2eAwe+PpbUzyL1CKTLXg=="], + + "ws": ["ws@8.23.1", "", { "peerDependencies": { "bufferutil": "^4.0.1", "utf-8-validate": ">=5.0.2" }, "optionalPeers": ["bufferutil", "utf-8-validate"] }, "sha512-1rzWDSN0NOi3tpwgHsQExjWRoKUGtjCkJ2gZRaaRtzhYLboMytOI9pj9PU7yCgY37auqdd4OyLofZDbkeuZmPA=="], + + "wsl-utils": ["wsl-utils@1.0.1", "", { "dependencies": { "is-wsl": "^3.1.0", "powershell-utils": "^0.2.0" } }, "sha512-c16PKLIRxBYpR3jSWsdS7SFp0COm5SOQdiFjY818dYFHJbMGuLBszpF07LBWmOS1uzrHa9VGdynsEgoeKy0oOQ=="], + + "yallist": ["yallist@5.0.0", "", {}, "sha512-YgvUTfwqyc7UXVMrB+SImsVYSmTS8X/tSrtdNZMImM+n7+QTriRXyXim0mBrTXNeqzVF0KWGgHPeiyViFFrNDw=="], + + "@aws-crypto/sha256-browser/@smithy/util-utf8": ["@smithy/util-utf8@2.3.0", "", { "dependencies": { "@smithy/util-buffer-from": "^2.2.0", "tslib": "^2.6.2" } }, "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A=="], + + "@aws-crypto/util/@smithy/util-utf8": ["@smithy/util-utf8@2.3.0", "", { "dependencies": { "@smithy/util-buffer-from": "^2.2.0", "tslib": "^2.6.2" } }, "sha512-R8Rdn8Hy72KKcebgLiv8jQcQkXoLMOGGv5uI1/k0l+snqkOzQ1R0ChUBCxWMlBsFMekWjq0wRudIweFs7sKT5A=="], + + "@npmcli/git/which": ["which@6.0.1", "", { "dependencies": { "isexe": "^4.0.0" }, "bin": { "node-which": "bin/which.js" } }, "sha512-oGLe46MIrCRqX7ytPUf66EAYvdeMIZYn3WaocqqKZAxrBpkqHfL/qvTyJ/bTk5+AqHCjXmrv3CEWgy368zhRUg=="], + + "@npmcli/promise-spawn/which": ["which@6.0.1", "", { "dependencies": { "isexe": "^4.0.0" }, "bin": { "node-which": "bin/which.js" } }, "sha512-oGLe46MIrCRqX7ytPUf66EAYvdeMIZYn3WaocqqKZAxrBpkqHfL/qvTyJ/bTk5+AqHCjXmrv3CEWgy368zhRUg=="], + + "@types/ws/@types/node": ["@types/node@26.6.11", "", { "dependencies": { "undici-types": "~8.9.0" } }, "sha512-uUyQ2XLEz+EXh34lmS3GhKrkqn/8FU7KUiKRpk347At2bmnMVWss45yz8b4FG/tUtmV1tV/+TVkITItPROyeeQ=="], + + "minipass-flush/minipass": ["minipass@3.3.6", "", { "dependencies": { "yallist": "^4.0.0" } }, "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw=="], + + "minipass-pipeline/minipass": ["minipass@3.3.6", "", { "dependencies": { "yallist": "^4.0.0" } }, "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw=="], + + "node-gyp/undici": ["undici@6.29.1", "", {}, "sha512-EvRlUt/QqAEvXdQeRMYUfwOQsfzpDztykrG2owGEE/rBOBoYv9uF39ZzsNDh4lTFHhTr2XOZjKkYgueD12ZmGA=="], + + "node-gyp/which": ["which@6.0.1", "", { "dependencies": { "isexe": "^4.0.0" }, "bin": { "node-which": "bin/which.js" } }, "sha512-oGLe46MIrCRqX7ytPUf66EAYvdeMIZYn3WaocqqKZAxrBpkqHfL/qvTyJ/bTk5+AqHCjXmrv3CEWgy368zhRUg=="], + + "rimraf/glob": ["glob@10.5.0", "", { "dependencies": { "foreground-child": "^3.1.0", "jackspeak": "^3.1.2", "minimatch": "^9.0.4", "minipass": "^7.1.2", "package-json-from-dist": "^1.0.0", "path-scurry": "^1.11.1" }, "bin": { "glob": "dist/esm/bin.mjs" } }, "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg=="], + + "string-width-cjs/emoji-regex": ["emoji-regex@8.0.0", "", {}, "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A=="], + + "string-width-cjs/strip-ansi": ["strip-ansi@6.0.1", "", { "dependencies": { "ansi-regex": "^5.0.1" } }, "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A=="], + + "strip-ansi-cjs/ansi-regex": ["ansi-regex@5.0.1", "", {}, "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ=="], + + "wrap-ansi-cjs/ansi-styles": ["ansi-styles@4.3.0", "", { "dependencies": { "color-convert": "^2.0.1" } }, "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg=="], + + "wrap-ansi-cjs/string-width": ["string-width@4.2.3", "", { "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", "strip-ansi": "^6.0.1" } }, "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g=="], + + "wrap-ansi-cjs/strip-ansi": ["strip-ansi@6.0.1", "", { "dependencies": { "ansi-regex": "^5.0.1" } }, "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A=="], + + "@aws-crypto/sha256-browser/@smithy/util-utf8/@smithy/util-buffer-from": ["@smithy/util-buffer-from@2.2.0", "", { "dependencies": { "@smithy/is-array-buffer": "^2.2.0", "tslib": "^2.6.2" } }, "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA=="], + + "@aws-crypto/util/@smithy/util-utf8/@smithy/util-buffer-from": ["@smithy/util-buffer-from@2.2.0", "", { "dependencies": { "@smithy/is-array-buffer": "^2.2.0", "tslib": "^2.6.2" } }, "sha512-IJdWBbTcMQ6DA0gdNhh/BwrLkDR+ADW5Kr1aZmd4k3DIF6ezMV4R2NIAmT08wQJ3yUK82thHWmC/TnK/wpMMIA=="], + + "@npmcli/git/which/isexe": ["isexe@4.0.0", "", {}, "sha512-FFUtZMpoZ8RqHS3XeXEmHWLA4thH+ZxCv2lOiPIn1Xc7CxrqhWzNSDzD+/chS/zbYezmiwWLdQC09JdQKmthOw=="], + + "@npmcli/promise-spawn/which/isexe": ["isexe@4.0.0", "", {}, "sha512-FFUtZMpoZ8RqHS3XeXEmHWLA4thH+ZxCv2lOiPIn1Xc7CxrqhWzNSDzD+/chS/zbYezmiwWLdQC09JdQKmthOw=="], + + "@types/ws/@types/node/undici-types": ["undici-types@8.9.0", "", {}, "sha512-KTDyRTYX8sWmKXAikPHHSyc63CRPETMctyjKFupcC6OBLXT3xsN0e9aF7m+mIXutFWpUXuedtowG7iLOzp0kQg=="], + + "minipass-flush/minipass/yallist": ["yallist@4.0.0", "", {}, "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="], + + "minipass-pipeline/minipass/yallist": ["yallist@4.0.0", "", {}, "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="], + + "node-gyp/which/isexe": ["isexe@4.0.0", "", {}, "sha512-FFUtZMpoZ8RqHS3XeXEmHWLA4thH+ZxCv2lOiPIn1Xc7CxrqhWzNSDzD+/chS/zbYezmiwWLdQC09JdQKmthOw=="], + + "rimraf/glob/minimatch": ["minimatch@9.0.9", "", { "dependencies": { "brace-expansion": "^2.0.2" } }, "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg=="], + + "rimraf/glob/path-scurry": ["path-scurry@1.11.1", "", { "dependencies": { "lru-cache": "^10.2.0", "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" } }, "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA=="], + + "string-width-cjs/strip-ansi/ansi-regex": ["ansi-regex@5.0.1", "", {}, "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ=="], + + "wrap-ansi-cjs/string-width/emoji-regex": ["emoji-regex@8.0.0", "", {}, "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A=="], + + "wrap-ansi-cjs/strip-ansi/ansi-regex": ["ansi-regex@5.0.1", "", {}, "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ=="], + + "rimraf/glob/minimatch/brace-expansion": ["brace-expansion@2.1.8", "", { "dependencies": { "balanced-match": "^1.0.0" } }, "sha512-BnlDzDYQoplTsZSvPi86CNzmbcb07X8ufR8fk1zivaiEJlXJkiq1MQyDCVmlWcsWbj6aWXqHnrwwevbrm/Saig=="], + + "rimraf/glob/path-scurry/lru-cache": ["lru-cache@10.4.3", "", {}, "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ=="], + + "rimraf/glob/minimatch/brace-expansion/balanced-match": ["balanced-match@1.0.2", "", {}, "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw=="], + } +} diff --git a/plugins/pstack/opencode/index.ts b/plugins/pstack/opencode/index.ts new file mode 100644 index 00000000..df0417c6 --- /dev/null +++ b/plugins/pstack/opencode/index.ts @@ -0,0 +1,114 @@ +import type { Plugin } from "@opencode/plugin"; +import { join } from "node:path"; +import { + agentsRoot, + modelSheet, + readFrontmatter, + skillDirectoryIds, + skillFile, + skillsRoot, + startupContext, +} from "./shared.ts"; +import { hooks } from "./v1.ts"; + +async function setup(ctx: Plugin.Context): Promise { + const { Skill } = await import("@opencode/plugin"); + const skills = skillDirectoryIds().flatMap((id) => { + const file = skillFile(id); + if (file === null) return []; + const description = file.values.get("description"); + return [{ + id, + name: file.values.get("name") ?? id, + ...(description === undefined ? {} : { description }), + autoinvoke: file.values.get("disable-model-invocation") !== "true" && file.values.get("user-invocable") !== "false", + body: file.body, + }]; + }); + await ctx.skill.transform((editor) => { + for (const skill of skills) { + editor.add({ + id: Skill.ID.make(skill.id), + name: Skill.Name.make(skill.name), + ...(skill.description === undefined ? {} : { description: skill.description }), + autoinvoke: skill.autoinvoke, + path: Skill.Info.fields.path.make(join(skillsRoot, skill.id, "SKILL.md")), + content: skill.body, + }); + } + }); + + await ctx.agent.transform((editor) => { + for (const id of ["poteto-agent", "comment-sicko"]) { + const file = readFrontmatter(join(agentsRoot, `${id}.md`)); + if (file === null) continue; + const description = file.values.get("description"); + editor.update(id, (agent) => { + if (description !== undefined) agent.description = description; + agent.mode = "subagent"; + agent.system = file.body.trim(); + if (id === "comment-sicko") agent.permissions = [ + { action: "*", resource: "*", effect: "allow" }, + { action: "edit", resource: "*", effect: "deny" }, + ]; + }); + } + }); + + await ctx.command.transform((editor) => { + for (const id of ["poteto-mode", "setup-pstack"]) { + const file = skillFile(id); + if (file === null) continue; + const description = file.values.get("description") ?? `pstack ${id}`; + editor.add({ + name: `pstack/${id}`, + description, + execute: async ({ sessionID, prompt, delivery }) => { + const { files: promptFiles, agents: promptAgents, skills: promptSkills, ...rest } = prompt; + const files = promptFiles?.map((file) => ({ + uri: file.uri, + source: file.source ?? { type: "uri" as const, uri: file.uri }, + ...(file.name === undefined ? {} : { name: file.name }), + ...(file.description === undefined ? {} : { description: file.description }), + ...(file.mention === undefined ? {} : { mention: file.mention }), + })); + const agents = promptAgents?.map((agent) => ({ + name: agent.name, + ...(agent.mention === undefined ? {} : { mention: agent.mention }), + })); + const skills = promptSkills?.map((skill) => ({ + id: skill.id, + ...(skill.mention === undefined ? {} : { mention: skill.mention }), + })); + await ctx.session.prompt({ + ...rest, + sessionID, + text: `${file.body}\n\n${prompt.text}`, + delivery, + ...(files === undefined ? {} : { files }), + ...(agents === undefined ? {} : { agents }), + ...(skills === undefined ? {} : { skills }), + }); + }, + }); + } + }); + + const started = new Set(); + await ctx.session.hook("context", (event) => { + if (started.size > 1_000) started.clear(); + if (!started.has(event.sessionID)) { + started.add(event.sessionID); + const startup = startupContext(); + if (startup) event.system.push({ type: "text", text: startup }); + } + const sheet = modelSheet(); + if (sheet) event.system.push({ type: "text", text: `# pstack model configuration\n\n${sheet}` }); + }); +} + +export default { + id: "pstack", + setup, + server: hooks, +}; diff --git a/plugins/pstack/opencode/session-start-context.md b/plugins/pstack/opencode/session-start-context.md new file mode 100644 index 00000000..a4e252c2 --- /dev/null +++ b/plugins/pstack/opencode/session-start-context.md @@ -0,0 +1,16 @@ +--- +name: pstack OpenCode startup +description: OpenCode session-start mandate for pstack +--- + + +You have pstack. + +Before responding to any non-trivial engineering task — a feature, bug fix, refactor, debugging, performance work, or any multi-step code change — load the `poteto-mode` skill with the `skill` tool and follow it. It is the default entry point and routes to the specific pstack skills from there. Pure questions and trivial one-line edits don't need it. + +When the intent is already specific, enter directly: `tdd` (bug with a reproducible failure), `architect` (types and module shape before code that crosses a function boundary), `how` (how a subsystem works), `why` (why it was built this way), `arena` (N parallel attempts at one task), `interrogate` (multi-model diff review). + +If you were dispatched as a subagent to execute a specific task, ignore this block — poteto-mode governs the orchestrating session, and it already shaped your dispatch. + +User instructions (AGENTS.md and direct requests) take precedence over this mandate. + diff --git a/plugins/pstack/opencode/shared.ts b/plugins/pstack/opencode/shared.ts new file mode 100644 index 00000000..d2415bf0 --- /dev/null +++ b/plugins/pstack/opencode/shared.ts @@ -0,0 +1,56 @@ +import { existsSync, readFileSync, readdirSync, statSync } from "node:fs"; +import { homedir } from "node:os"; +import { join } from "node:path"; +import { fileURLToPath } from "node:url"; + +export const pluginRoot = fileURLToPath(new URL("..", import.meta.url)); +export const skillsRoot = join(pluginRoot, "skills"); +export const agentsRoot = join(pluginRoot, "agents"); + +export interface Frontmatter { + readonly values: ReadonlyMap; + readonly body: string; +} + +export function frontmatter(text: string): Frontmatter { + const match = /^---\r?\n([\s\S]*?)\r?\n---\r?\n?/.exec(text); + if (match === null) return { values: new Map(), body: text }; + const values = new Map(); + for (const line of match[1]!.split(/\r?\n/)) { + const at = line.indexOf(":"); + if (at < 1) continue; + values.set(line.slice(0, at).trim(), line.slice(at + 1).trim()); + } + return { values, body: text.slice(match[0].length) }; +} + +export function readFrontmatter(path: string): Frontmatter | null { + return existsSync(path) ? frontmatter(readFileSync(path, "utf8")) : null; +} + +export function skillDirectoryIds(): string[] { + return readdirSync(skillsRoot) + .filter((name) => statSync(join(skillsRoot, name)).isDirectory()) + .filter((name) => existsSync(join(skillsRoot, name, "SKILL.md"))) + .sort(); +} + +export function skillFile(id: string): Frontmatter | null { + return readFrontmatter(join(skillsRoot, id, "SKILL.md")); +} + +export function configHome(): string { + const override = process.env.OPENCODE_CONFIG_DIR?.trim(); + if (override) return override; + const xdg = process.env.XDG_CONFIG_HOME?.trim(); + return join(xdg ? xdg : join(homedir(), ".config"), "opencode"); +} + +export function modelSheet(): string { + const path = join(configHome(), "pstack-models.md"); + return existsSync(path) ? readFileSync(path, "utf8").trim() : ""; +} + +export function startupContext(): string { + return readFrontmatter(join(pluginRoot, "opencode", "session-start-context.md"))?.body.trim() ?? ""; +} diff --git a/plugins/pstack/opencode/tsconfig.json b/plugins/pstack/opencode/tsconfig.json new file mode 100644 index 00000000..f56b53a0 --- /dev/null +++ b/plugins/pstack/opencode/tsconfig.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "allowImportingTsExtensions": true, + "exactOptionalPropertyTypes": true, + "module": "esnext", + "moduleResolution": "bundler", + "noEmit": true, + "noFallthroughCasesInSwitch": true, + "noImplicitOverride": true, + "noImplicitReturns": true, + "noUncheckedIndexedAccess": true, + "skipLibCheck": true, + "strict": true, + "target": "esnext", + "types": ["node"] + }, + "include": ["index.ts", "shared.ts", "v1.ts"] +} diff --git a/plugins/pstack/opencode/v1.test.ts b/plugins/pstack/opencode/v1.test.ts new file mode 100644 index 00000000..dba825d7 --- /dev/null +++ b/plugins/pstack/opencode/v1.test.ts @@ -0,0 +1,84 @@ +/* + Guards the correction: pstack must load natively in OpenCode 1.x and 2.x. + V1 calls `server()`, requires `id`, and reads skills from `skills.paths`. + V2 calls `setup()` and registers through the skill, agent and command domains. +*/ + +import { afterEach, describe, expect, it } from "bun:test"; +import { mkdtempSync, rmSync, writeFileSync } from "node:fs"; +import { tmpdir } from "node:os"; +import { join } from "node:path"; +import plugin from "./index.ts"; +import { hooks, type LegacyConfig } from "./v1.ts"; +import { skillsRoot } from "./shared.ts"; + +const restored: (() => void)[] = []; + +afterEach(() => { + while (restored.length > 0) restored.pop()?.(); +}); + +function configHomeWithSheet(sheet: string): void { + const previous = process.env.OPENCODE_CONFIG_DIR; + const home = mkdtempSync(join(tmpdir(), "pstack-v1-")); + writeFileSync(join(home, "pstack-models.md"), sheet); + process.env.OPENCODE_CONFIG_DIR = home; + restored.push(() => { + if (previous === undefined) delete process.env.OPENCODE_CONFIG_DIR; + else process.env.OPENCODE_CONFIG_DIR = previous; + rmSync(home, { recursive: true, force: true }); + }); +} + +describe("OpenCode version support", () => { + it("exposes the v2 setup entry and the v1 server entry from one default export", () => { + expect(plugin.id).toBe("pstack"); + expect(typeof plugin.setup).toBe("function"); + expect(typeof plugin.server).toBe("function"); + }); + + it("registers the skill tree through v1 skills.paths and keeps existing sources", async () => { + const config: LegacyConfig = { + skills: { paths: ["/existing-skills"], urls: ["https://example.com/skills/"] }, + }; + await hooks().config(config); + expect(config.skills).toEqual({ + paths: ["/existing-skills", skillsRoot], + urls: ["https://example.com/skills/"], + }); + }); + + it("converts a v2-style skills array instead of dropping it", async () => { + const config: LegacyConfig = { skills: ["/existing-skills"] }; + await hooks().config(config); + expect(config.skills).toEqual({ paths: ["/existing-skills", skillsRoot], urls: [] }); + }); + + it("adds the skill root once when the config hook runs twice", async () => { + const config: LegacyConfig = {}; + const hook = hooks(); + await hook.config(config); + await hook.config(config); + expect(config.skills).toEqual({ paths: [skillsRoot], urls: [] }); + }); + + it("registers both pstack subagents with their frontmatter descriptions", async () => { + const config: LegacyConfig = { agent: { "poteto-agent": { model: "kimi/k2" } } }; + await hooks().config(config); + expect(config.agent?.["poteto-agent"]?.mode).toBe("subagent"); + expect(config.agent?.["poteto-agent"]?.model).toBe("kimi/k2"); + expect(config.agent?.["poteto-agent"]?.description).toContain("poteto-mode"); + expect(config.agent?.["poteto-agent"]?.prompt).toContain("Poteto subagent"); + expect(config.agent?.["comment-sicko"]?.mode).toBe("subagent"); + expect(config.agent?.["comment-sicko"]?.permission).toEqual({ edit: "deny" }); + }); + + it("pushes the v1 slash-command brief and the model sheet into the system prompt", async () => { + configHomeWithSheet("primary: kimi/k2"); + const output = { system: [] as string[] }; + await hooks()["experimental.chat.system.transform"]({}, output); + expect(output.system[0]).toContain("/poteto-mode"); + expect(output.system[0]).toContain("no skill tool"); + expect(output.system[1]).toContain("primary: kimi/k2"); + }); +}); diff --git a/plugins/pstack/opencode/v1.ts b/plugins/pstack/opencode/v1.ts new file mode 100644 index 00000000..ba368714 --- /dev/null +++ b/plugins/pstack/opencode/v1.ts @@ -0,0 +1,111 @@ +import { join } from "node:path"; +import { agentsRoot, modelSheet, readFrontmatter, skillsRoot } from "./shared.ts"; + +const SUBAGENTS = ["poteto-agent", "comment-sicko"] as const; + +type Permission = "allow" | "ask" | "deny"; + +interface LegacyAgent { + readonly description?: string; + readonly mode?: "subagent"; + readonly prompt?: string; + readonly permission?: { readonly edit?: Permission }; + readonly [key: string]: unknown; +} + +interface LegacySkillSources { + readonly paths?: readonly string[]; + readonly urls?: readonly string[]; +} + +export interface LegacyConfig { + skills?: LegacySkillSources | readonly string[]; + agent?: Record; +} + +interface SystemTransformInput { + readonly sessionID?: string; +} + +interface SystemTransformOutput { + readonly system: string[]; +} + +function strings(value: unknown): string[] { + return Array.isArray(value) ? value.filter((entry): entry is string => typeof entry === "string") : []; +} + +function skillPaths(existing: unknown): string[] { + if (Array.isArray(existing)) return strings(existing); + if (typeof existing === "object" && existing !== null && "paths" in existing) { + return strings(existing.paths); + } + return []; +} + +function skillUrls(existing: unknown): string[] { + if (typeof existing === "object" && existing !== null && "urls" in existing) { + return strings(existing.urls); + } + return []; +} + +function withSkillsRoot(existing: unknown): LegacySkillSources { + const paths = skillPaths(existing); + return { + paths: paths.includes(skillsRoot) ? paths : [...paths, skillsRoot], + urls: skillUrls(existing), + }; +} + +function withSubagents( + existing: Record +): Record { + const agents: Record = { ...existing }; + for (const id of SUBAGENTS) { + const file = readFrontmatter(join(agentsRoot, `${id}.md`)); + if (file === null) continue; + const current = agents[id] ?? {}; + const description = file.values.get("description"); + agents[id] = { + ...current, + mode: "subagent", + prompt: file.body.trim(), + ...(description === undefined ? {} : { description }), + ...(id === "comment-sicko" + ? { permission: { ...(current.permission ?? {}), edit: "deny" } } + : {}), + }; + } + return agents; +} + +function legacyContext(): string { + return [ + "", + "You have pstack.", + "OpenCode 1.x exposes pstack skills as slash commands and has no skill tool. Run `/poteto-mode` before any non-trivial engineering work; it routes to the specific pstack skills. `/setup-pstack` writes the model sheet.", + `Every skill body is at \`${skillsRoot}//SKILL.md\`. Read the one a task names.`, + "`poteto-agent` and `comment-sicko` are subagents you dispatch with the task tool.", + "If you were dispatched as a subagent to execute a specific task, ignore this block.", + "User instructions (AGENTS.md and direct requests) take precedence over this mandate.", + "", + ].join("\n"); +} + +export function hooks() { + return { + async config(config: LegacyConfig): Promise { + config.skills = withSkillsRoot(config.skills); + config.agent = withSubagents(config.agent ?? {}); + }, + async "experimental.chat.system.transform"( + _input: SystemTransformInput, + output: SystemTransformOutput + ): Promise { + output.system.push(legacyContext()); + const sheet = modelSheet(); + if (sheet) output.system.push(`# pstack model configuration\n\n${sheet}`); + }, + }; +} diff --git a/plugins/pstack/package.json b/plugins/pstack/package.json new file mode 100644 index 00000000..ea8a85f1 --- /dev/null +++ b/plugins/pstack/package.json @@ -0,0 +1,26 @@ +{ + "name": "@open-pstack/pstack", + "version": "1.22.0", + "type": "module", + "main": "./opencode/index.ts", + "description": "pstack for OpenCode. Shares the Claude Code, Codex and Grok skill tree and registers it with OpenCode.", + "exports": { + ".": "./opencode/index.ts" + }, + "files": [ + "opencode", + "agents", + "skills" + ], + "scripts": { + "test": "bun test opencode/v1.test.ts", + "typecheck": "tsc --project opencode/tsconfig.json --noEmit --strict" + }, + "dependencies": { + "@opencode/plugin": "2.4.2" + }, + "devDependencies": { + "@types/node": "24.12.2", + "typescript": "5.9.3" + } +} diff --git a/plugins/pstack/skills/architect/SKILL.md b/plugins/pstack/skills/architect/SKILL.md index bbe403bf..be783843 100644 --- a/plugins/pstack/skills/architect/SKILL.md +++ b/plugins/pstack/skills/architect/SKILL.md @@ -7,7 +7,7 @@ description: "Sketch types, signatures, and module structure before code, then s Sketch types, function signatures, class shapes, and module boundaries with `not implemented` bodies and pseudocode. Synthesize across multiple model perspectives, then fill in code against the chosen sketch. -**Dispatch contract.** Architect's Arena uses the centralized provider routing in [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Configured entries are descriptors, not native model slugs. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Dispatch contract.** Architect's Arena uses the centralized provider routing in [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Configured entries are descriptors, not native model slugs. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). ## Start diff --git a/plugins/pstack/skills/arena/SKILL.md b/plugins/pstack/skills/arena/SKILL.md index 9052bf11..e0cbb01c 100644 --- a/plugins/pstack/skills/arena/SKILL.md +++ b/plugins/pstack/skills/arena/SKILL.md @@ -5,7 +5,7 @@ description: "Spawn N parallel candidates at the same task, pick a base, graft t # Arena -**Dispatch contract.** Read [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md) before fan-out. Configured values are provider-qualified descriptors, not host-native model slugs. The parent starts native and external lanes directly; children never route themselves. On Codex, resolve the remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Dispatch contract.** Read [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md) before fan-out. Configured values are provider-qualified descriptors, not host-native model slugs. The parent starts native and external lanes directly; children never route themselves. On Codex, Grok or OpenCode, resolve the remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Open a todolist with one entry per phase (Frame, Fan out, Cross-judge, Pick, Graft, Verify) before launching anything. diff --git a/plugins/pstack/skills/automate-me/SKILL.md b/plugins/pstack/skills/automate-me/SKILL.md index 005ff102..9eb8222d 100644 --- a/plugins/pstack/skills/automate-me/SKILL.md +++ b/plugins/pstack/skills/automate-me/SKILL.md @@ -9,13 +9,13 @@ A guided flow for turning the user's working conventions into a skill agents wil This skill orchestrates three others: an inline mining pass (see step 1), the `plugin-dev:skill-development` skill (authoring), and the **unslop** skill (prose discipline). It sequences them. It doesn't replace them. -**Platform note.** On Codex or another non-Claude runtime, the Claude tool names, `claude-*` slugs, and Claude built-in skills named below (including `plugin-dev:skill-development`) are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** On Codex, Grok or OpenCode, the Claude tool names, `claude-*` slugs, and Claude built-in skills named below (including `plugin-dev:skill-development`) are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). On OpenCode, mode skills live in `.opencode/skills//-mode/SKILL.md` or `/skills/-mode/SKILL.md`, and there is no JSONL transcript path; use the session digest. ## Flow ### 0. Check for an existing skill -Look recursively for `.claude/skills/**/*-mode/SKILL.md` and `~/.claude/skills/*-mode/SKILL.md` matching the user's handle. Mode skills can live in a personal category directory (`.claude/skills//`), not only at the top level. If one exists, confirm intent with `AskUserQuestion` (unless they already said "update my skill" or similar): +Look recursively for `.claude/skills/**/*-mode/SKILL.md` and `~/.claude/skills/*-mode/SKILL.md` matching the user's handle. Mode skills can live in a personal category directory (`.claude/skills//`), not only at the top level. On OpenCode, the same locations are `.opencode/skills/**/*-mode/SKILL.md`, `/skills/*-mode/SKILL.md`, and the category form `.opencode/skills//`. If one exists, confirm intent with `AskUserQuestion` (unless they already said "update my skill" or similar): - Update the existing skill (default for repeat runs) - Start fresh (rare, ask why before doing it) @@ -27,7 +27,7 @@ Update mode changes the rest of the flow: ### 1. Mine their history -Locate the active workspace's transcripts before fanning out. Claude Code stores them at `~/.claude/projects//*.jsonl`, where `` is the workspace's working directory with each `/` and each `.` → `-`. Use only that path. Don't glob across `~/.claude/projects/`. That crosses workspace boundaries and reads private chats from unrelated projects. +Locate the active workspace's transcripts before fanning out. Claude Code stores them at `~/.claude/projects//*.jsonl`, where `` is the workspace's working directory with each `/` and each `.` → `-`. Use only that path. Don't glob across `~/.claude/projects/`. That crosses workspace boundaries and reads private chats from unrelated projects. On OpenCode, there is no JSONL transcript path; pass a tight session digest instead. Survey recent agent conversations within that scope for recurring patterns. Run multiple parallel subagents across slices of history (e.g. last 2-4 weeks, split into 3 slices so each has enough material). Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. Each slice mining subagent reads transcripts from the workspace-scoped path the parent provides, looks for the signals below, and returns a short structured list of patterns it saw with evidence pointers. Default signals worth hunting: @@ -67,7 +67,7 @@ The **poteto-mode** skill shows the shape. Read it for granularity. Don't copy i Use the **plugin-dev:skill-development** skill to author the skill. Placement: -- Path: preserve an existing mode skill's category. For a new mode, use `.claude/skills//-mode/SKILL.md` when the repo has an established personal category for that handle. Otherwise default to `.claude/skills/-mode/SKILL.md` in the project (or `~/.claude/skills/-mode/` if the user prefers a personal skill). +- Path: preserve an existing mode skill's category. For a new mode, use `.claude/skills//-mode/SKILL.md` when the repo has an established personal category for that handle. Otherwise default to `.claude/skills/-mode/SKILL.md` in the project (or `~/.claude/skills/-mode/` if the user prefers a personal skill). On OpenCode, use the same shape under `.opencode/skills/` or `/skills/`. - Handle: the user's first name or chosen identifier. - Frontmatter `description`: trigger on their name + `/-mode` + "work in their style", not on generic keywords like "write code" or "review PR". - Frontmatter formatting: follow `plugin-dev:skill-development`'s YAML rules. Keep `description` as one YAML scalar. Quote it or use `description: >-` with indented continuation lines when punctuation or wrapping requires it. diff --git a/plugins/pstack/skills/babysit/SKILL.md b/plugins/pstack/skills/babysit/SKILL.md index b816077a..07776222 100644 --- a/plugins/pstack/skills/babysit/SKILL.md +++ b/plugins/pstack/skills/babysit/SKILL.md @@ -7,7 +7,7 @@ description: Watch an open PR — fix failing CI, handle the straightforward rev Claude Code analog of Cursor's built-in `/babysit`. The implementation is a loop over `gh` CLI plus the Claude Code `loop` skill for pacing. -**Platform note.** On Codex or another non-Claude runtime, the Claude tool names and Claude built-in skills named below (`loop`, `AskUserQuestion`) are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** On Codex, Grok or OpenCode, the Claude tool names and Claude built-in skills named below (`loop`, `AskUserQuestion`) are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). On OpenCode, a re-run cadence is a `shell` background task or an OpenCode automation, and fixed choices use `question`. Inside poteto-mode, the **Babysit** playbook ([`../poteto-mode/playbooks/babysit.md`](../poteto-mode/playbooks/babysit.md)) supersedes this skill: it owns mode declaration, the merge frontier, stack safety, and the `watch-pr` watcher. This skill stays the standalone `/babysit` entry point for a single PR outside a poteto-mode run. @@ -31,7 +31,7 @@ Inside poteto-mode, the **Babysit** playbook ([`../poteto-mode/playbooks/babysit - Review comments from human reviewers (`gh pr view --json comments,reviews`): act only on feedback you actually agree with. When a comment has a single mechanical answer — a rename, a guard clause, a formatting nit — make the edit and quote the comment in the commit message. When it hinges on a judgement call, or you can't tell what's being asked, don't guess: leave it and reply with what you would have done. - Review-bot comments (Bugbot and similar automation): classify as fix, dismiss, or ask before acting, per [`../poteto-mode/references/bugbot-triage.md`](../poteto-mode/references/bugbot-triage.md). Follow the rubric's Ask by default categories, including security, data, and high-severity findings. -3. **Loop.** Use the Claude Code `loop` skill to pace re-checks. Pick the interval from what you're watching: +3. **Loop.** Use the Claude Code `loop` skill to pace re-checks. Pick the interval from what you're watching. On OpenCode, use a `shell` background task or an OpenCode automation for the same cadence: - Active CI run: poll `gh pr checks --watch` (it blocks until checks finish, so no separate loop interval needed). - Awaiting reviewer: 20–30 min heartbeat. - Idle but want to catch new comments: hourly. diff --git a/plugins/pstack/skills/create-verification-skill/SKILL.md b/plugins/pstack/skills/create-verification-skill/SKILL.md index 89db4deb..66068353 100644 --- a/plugins/pstack/skills/create-verification-skill/SKILL.md +++ b/plugins/pstack/skills/create-verification-skill/SKILL.md @@ -7,7 +7,7 @@ description: "Generate a project-local verification skill that drives your app t Every serious project needs a scripted way to drive the real app and prove behavior: launch it, exercise a feature the way a user would, and capture evidence. This skill generates that as a project-local skill (`.claude/skills/verify-/`) tailored to the repo. You write the generator's output for the next agent, not for a human: it will be read cold, mid-task, by an agent that has never seen the app. -**Platform note.** The generated skill lands under `.claude/skills/verify-/` on Claude Code. On Codex or another runtime, write it to that runtime's project-skill location instead. The app-driving harness (browser/CDP, PTY/tmux, HTTP) is platform-neutral; resolve any tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** The generated skill lands under `.claude/skills/verify-/` on Claude Code. On Codex use `.agents/skills/verify-/`, on Grok `.grok/skills/verify-/`, and on OpenCode `.opencode/skills/verify-/`. The app-driving harness (browser/CDP, PTY/tmux, HTTP) is platform-neutral; resolve any tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). ## 1. Interview the repo, not the user @@ -23,7 +23,7 @@ If the checkout doesn't build or start as-is, fix that first (or report it preci ## 2. Generate the skill -Write `.claude/skills/verify-/SKILL.md` with YAML frontmatter (`name: verify-` and a `description` that names the app, the surface, and when to reach for it — without frontmatter the skill never registers) and these sections, each grounded in what the interview actually found (no placeholders left): +Write the generated skill's `SKILL.md` at the project-skill path the Platform note gives (`.claude/skills/verify-/` on Claude Code, `.opencode/skills/verify-/` on OpenCode) with YAML frontmatter (`name: verify-` and a `description` that names the app, the surface, and when to reach for it — without frontmatter the skill never registers) and these sections, each grounded in what the interview actually found (no placeholders left): - **Launch:** the exact command that starts the app for verification, and how to tell it's ready (a log line, a prompt). Launch must reach a usable state from an empty data dir, including any migrations and seed data. Ready means usable, not just that a process answers. A database health check can pass while its init scripts are still running. Include teardown. For a short-lived CLI or TUI there is no server to keep alive: launch means build the binary (or install deps) once, then start each drive in its own isolated PTY or tmux session. - **Doctor:** one read-only check that answers "is this instance worth driving?" — process up, right version/build, port owned by us, auth valid. An agent runs this first whenever anything looks off. @@ -34,7 +34,7 @@ Write `.claude/skills/verify-/SKILL.md` with YAML frontmatter (`name: verif ## 3. Seed the feature map -Create `.claude/skills/verify-/features/README.md` plus one file per user-facing feature you can identify (aim for the top 3-5 to start, from routes, commands, menus, or docs). Follow the shape in [`references/feature-map-example/`](references/feature-map-example/), with a README index and one file per feature. Each file answers, from the user's point of view: what the feature is, how to reach it, how to drive it with the harness, and what observable end state proves it works. The four H2s are `Sub-features`, `How to get to it (user POV)`, `Driving it with `, and `Gotchas`. If the seed data lacks a precondition that a journey needs, the journey reports a failure and the reason goes in that feature's `Gotchas`. Never weaken the journey to make it pass. The map is the repo's maintained verification source; a proof that drives one convenient entry point is incomplete when the map lists others. +Create the feature map at the same project-skill root: `features/README.md` plus one file per user-facing feature you can identify (aim for the top 3-5 to start, from routes, commands, menus, or docs). Follow the shape in [`references/feature-map-example/`](references/feature-map-example/), with a README index and one file per feature. Each file answers, from the user's point of view: what the feature is, how to reach it, how to drive it with the harness, and what observable end state proves it works. The four H2s are `Sub-features`, `How to get to it (user POV)`, `Driving it with `, and `Gotchas`. If the seed data lacks a precondition that a journey needs, the journey reports a failure and the reason goes in that feature's `Gotchas`. Never weaken the journey to make it pass. The map is the repo's maintained verification source; a proof that drives one convenient entry point is incomplete when the map lists others. ## 4. Prove the generated skill before handing it over diff --git a/plugins/pstack/skills/how/SKILL.md b/plugins/pstack/skills/how/SKILL.md index 17a39961..9ad4f2ff 100644 --- a/plugins/pstack/skills/how/SKILL.md +++ b/plugins/pstack/skills/how/SKILL.md @@ -7,7 +7,7 @@ description: "Use for \"how does X work\", code walkthroughs before changing som Explore the codebase to answer "how does X work?" questions. Produce architectural explanations at the level of a senior engineer onboarding onto a subsystem, enough to build a working mental model, not so much that it reads like annotated source code. -**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Values are provider-qualified descriptors; the parent chooses native versus external execution. Every lane runs in `read-only` mode. Explorers use the `how explorer` descriptor, and every explainer uses the `how explainer` descriptor. When the sheet lacks either line, use that role's [role default](../poteto-mode/references/model-catalog.md#role-defaults). A native lane uses the parent subagent primitive; an external lane uses the launcher directly. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. +**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Values are provider-qualified descriptors; the parent chooses native versus external execution. Every lane runs in `read-only` mode. Explorers use the `how explorer` descriptor, and every explainer uses the `how explainer` descriptor. When the sheet lacks either line, use that role's [role default](../poteto-mode/references/model-catalog.md#role-defaults). A native lane uses the parent subagent primitive; an external lane uses the launcher directly. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. ## 1. Assess complexity diff --git a/plugins/pstack/skills/interrogate/SKILL.md b/plugins/pstack/skills/interrogate/SKILL.md index d399f4a3..7a7d783e 100644 --- a/plugins/pstack/skills/interrogate/SKILL.md +++ b/plugins/pstack/skills/interrogate/SKILL.md @@ -7,7 +7,7 @@ description: "Use for \"interrogate\", \"adversarial review\", \"multi-model rev Adversaries try to break a change or a design. A finding survives only when a run proves it. Report the findings. Do not apply fixes. -**Dispatch contract.** Read [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md) before launching adversaries. Configured entries are provider-qualified descriptors; the parent starts native and external lanes directly. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Dispatch contract.** Read [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md) before launching adversaries. Configured entries are provider-qualified descriptors; the parent starts native and external lanes directly. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). ## Frame diff --git a/plugins/pstack/skills/maintain-verification-skill/SKILL.md b/plugins/pstack/skills/maintain-verification-skill/SKILL.md index 45ce04ba..c3f2d4e8 100644 --- a/plugins/pstack/skills/maintain-verification-skill/SKILL.md +++ b/plugins/pstack/skills/maintain-verification-skill/SKILL.md @@ -7,7 +7,7 @@ description: "Periodic pass that keeps a project's verification skill and featur A feature map rots the moment the app changes. This skill is the upkeep loop for a skill generated by `/create-verification-skill` (or any project-local verification skill with a feature map). The unit of rigor is the feature, not every sentence: cover every feature file from source and exercise every feature live, without terminalising every bullet. -**Platform note.** On Codex or another non-Claude runtime, the parallel per-feature source readers below map to `spawn_agent` fan-out, and the project-local skill lives under your runtime's skills location, not `.claude/skills/`. See [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** On Codex, Grok or OpenCode, the parallel per-feature source readers below map to `spawn_agent` fan-out, and the project-local skill lives under your runtime's skills location, not `.claude/skills/`. On OpenCode use `subagent` fan-out and `.opencode/skills/verify-*/`. See [`codex-tools.md`](../poteto-mode/references/codex-tools.md). ## Outcomes @@ -23,7 +23,7 @@ Only edit the verification skill's own directory (its SKILL.md, features/, and a ## Pass -0. **Locate the target.** Find the verification skill to maintain: the project-local skill whose body has launch/drive sections and a feature map (usually `.claude/skills/verify-*/`). Several candidates → ask which one; none → stop and point at `/create-verification-skill` instead of inventing a target. +0. **Locate the target.** Find the verification skill to maintain: the project-local skill whose body has launch/drive sections and a feature map (usually `.claude/skills/verify-*/` on Claude Code, `.agents/skills/verify-*/` on Codex, `.grok/skills/verify-*/` on Grok, or `.opencode/skills/verify-*/` on OpenCode). Several candidates → ask which one; none → stop and point at `/create-verification-skill` instead of inventing a target. 1. **Index hygiene.** Read the feature map README and glob its sibling files. Fix missing, extra, duplicate, or dead entries. Lightweight; no generated inventory. diff --git a/plugins/pstack/skills/no-comments/SKILL.md b/plugins/pstack/skills/no-comments/SKILL.md index 3ef7a949..9c917a95 100644 --- a/plugins/pstack/skills/no-comments/SKILL.md +++ b/plugins/pstack/skills/no-comments/SKILL.md @@ -9,7 +9,7 @@ Spawn comment-sicko. Act on accepted findings. Defer to comment-sicko's fresh perspective. -**Platform note.** On Codex or another non-Claude runtime, the `comment-sicko` subagent and the Claude tool names below are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** On Codex, Grok or OpenCode, the `comment-sicko` subagent and the Claude tool names below are Claude defaults. Resolve them via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). On OpenCode call `subagent` with `agent: "comment-sicko"`. ## Scope diff --git a/plugins/pstack/skills/poteto-help/SKILL.md b/plugins/pstack/skills/poteto-help/SKILL.md index d2c3d0a6..2ba6c1de 100644 --- a/plugins/pstack/skills/poteto-help/SKILL.md +++ b/plugins/pstack/skills/poteto-help/SKILL.md @@ -35,15 +35,15 @@ When the model rule is missing and it matters, ask whether the user wants to pic ## Get set up -1. Install. In Claude Code, run `/plugin marketplace add ericlitman/open-pstack`, then `/plugin install pstack@open-pstack`, then `/reload-plugins`. In Codex, run `codex plugin marketplace add ericlitman/open-pstack --ref main`, then `codex plugin add pstack@open-pstack`, and turn on `multi_agent` per [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +1. Install. In Claude Code, run `/plugin marketplace add ericlitman/open-pstack`, then `/plugin install pstack@open-pstack`, then `/reload-plugins`. In Codex, run `codex plugin marketplace add ericlitman/open-pstack --ref main`, then `codex plugin add pstack@open-pstack`, and turn on `multi_agent` per [`codex-tools.md`](../poteto-mode/references/codex-tools.md). In OpenCode, add `/plugins/pstack` to the `plugins` array in `opencode.jsonc`, or run `opencode plugin add 'github:ericlitman/open-pstack#main::path:plugins/pstack'`. 2. Run [`/setup-pstack`](../setup-pstack/SKILL.md). It maps a model to each role, asks one requested effort for each model family it assigns, probes those models, and writes a model sheet. A rerun that keeps a valid sheet and names no change asks none of these questions: it keeps the sheet's roles and efforts, probes them, and writes when every probe passes. The sheet applies to new sessions. Then it offers once each to generate a verification skill and a formal verification skill for the project, unless the project already has one. On a rerun that keeps the sheet, it mentions each offer in one line instead of asking. 3. Start a real task with `/poteto-mode`, a goal, and a check that can pass or fail. -In Claude Code, a typed skill carries the plugin prefix, as in `/pstack:poteto-mode`. In Codex, ask for a skill by name, as in "use pstack:poteto-mode". The [README](https://github.com/ericlitman/open-pstack#readme) and [guide page 1](https://github.com/cursor/plugins/blob/main/pstack/docs/guide/01-setup.md) have the details. Offer to word their first prompt with them, per [`references/prompting.md`](references/prompting.md). +In Claude Code, a typed skill carries the plugin prefix, as in `/pstack:poteto-mode`. In Codex, ask for a skill by name, as in "use pstack:poteto-mode". In OpenCode, use the plain ID, as in `@poteto-mode` or `/pstack/poteto-mode`. The [README](https://github.com/ericlitman/open-pstack#readme) and [guide page 1](https://github.com/cursor/plugins/blob/main/pstack/docs/guide/01-setup.md) have the details. Offer to word their first prompt with them, per [`references/prompting.md`](references/prompting.md). If cost is the worry, say where the tokens go and how to spend fewer. pstack spends extra tokens on subagents and review panels. Rerun `/setup-pstack` and pick lower efforts or cheaper models. A role set to `auto` or `inherit-parent` runs on the session's model, which saves tokens when the session runs on a cheaper model. A shorter panel list runs fewer subagents, one for each entry. Save `/poteto-mode` for work that needs rigor. -Open Pstack runs one shared skill tree in Claude Code and Codex. Workflow skills such as `/poteto-mode`, `/how`, `/why`, and `/teach` start subagents with per-role models. A model from the app you are using runs inside it, and other models run through their signed-in command-line tools. Codex has no `loop` skill and no `poteto-agent` type. [`codex-tools.md`](../poteto-mode/references/codex-tools.md) maps each Claude Code tool to its Codex form. +Open Pstack runs one shared skill tree in Claude Code, Codex, Grok and OpenCode. Workflow skills such as `/poteto-mode`, `/how`, `/why`, and `/teach` start subagents with per-role models. A model from the app you are using runs inside it, and other models run through their signed-in command-line tools. Codex has no `loop` skill and no `poteto-agent` type; OpenCode has no `loop` skill and uses `subagent` with `poteto-agent`. [`codex-tools.md`](../poteto-mode/references/codex-tools.md) maps each Claude Code tool to its harness form. ## Start a task with `/poteto-mode` @@ -53,9 +53,10 @@ Whether `/poteto-mode` stays on depends on the harness: - In Claude Code, a small startup instruction routes non-trivial work into `/poteto-mode`. A typed `/pstack:poteto-mode` attaches the skill to that task, and it can fade as the session moves on. - In Codex, ask for `pstack:poteto-mode` by name at the start of each task. +- In OpenCode, the plugin appends the same startup instruction. Run `/pstack/poteto-mode`, mention `@poteto-mode`, or ask for the `poteto-mode` skill. - In both, start each new task with `/poteto-mode` when it matters. -Mid-session, "new task" makes the mode match a fresh playbook. In Claude Code, `/poteto-mode` already uses `poteto-agent` for the subagents its playbook steps spawn. To get the same style from a subagent of your own, spawn it with `subagent_type: "poteto-agent"`. Codex has no `poteto-agent` type, so dispatch a `spawn_agent` whose instructions say to read the `poteto-mode` skill in full first. +Mid-session, "new task" makes the mode match a fresh playbook. In Claude Code, `/poteto-mode` already uses `poteto-agent` for the subagents its playbook steps spawn. To get the same style from a subagent of your own, spawn it with `subagent_type: "poteto-agent"`. Codex has no `poteto-agent` type, so dispatch a `spawn_agent` whose instructions say to read the `poteto-mode` skill in full first. OpenCode uses `subagent` with `agent: "poteto-agent"`. ## Pick a skill @@ -110,7 +111,7 @@ Close calls: Not in pstack: -- `run` (CLIs and TUIs), `verify` (UIs), and `loop` are Claude Code built-ins. `plugin-dev:skill-development` ships in the separate `plugin-dev` plugin, which skill-authoring routes need. In Claude Code, install it with `/plugin marketplace add anthropics/claude-plugins-official`, then `/plugin install plugin-dev@claude-plugins-official`. [`codex-tools.md`](../poteto-mode/references/codex-tools.md) names the Codex equivalent of each. +- `run` (CLIs and TUIs), `verify` (UIs), and `loop` are Claude Code built-ins. `plugin-dev:skill-development` ships in the separate `plugin-dev` plugin, which skill-authoring routes need. In Claude Code, install it with `/plugin marketplace add anthropics/claude-plugins-official`, then `/plugin install plugin-dev@claude-plugins-official`. [`codex-tools.md`](../poteto-mode/references/codex-tools.md) names the Codex, Grok and OpenCode equivalents. - `/make-bot-ui` is not ported, because it depends on Cursor routines and webhooks. - pstack has no `/orchestrate` skill. Orchestrate is a `/poteto-mode` playbook. If the slash menu shows `/orchestrate`, another plugin provides it. diff --git a/plugins/pstack/skills/poteto-mode/SKILL.md b/plugins/pstack/skills/poteto-mode/SKILL.md index 81564ea4..0d00b0e3 100644 --- a/plugins/pstack/skills/poteto-mode/SKILL.md +++ b/plugins/pstack/skills/poteto-mode/SKILL.md @@ -9,7 +9,7 @@ Bundled skills live at `..//SKILL.md` from this file, so put this file's a ## Platform Adaptation -These skills share one tree across Claude Code, Codex, and Grok. Read [`references/provider-dispatch.md`](references/provider-dispatch.md) whenever a configured role launches. It defines the provider-qualified model descriptors, native/external route table, launcher, isolation, receipts, and dropout policy. Children never choose routes. When a skill names a Claude tool or built-in skill (`run`, `verify`, `plugin-dev:skill-development`), read [`references/codex-tools.md`](references/codex-tools.md) for the Codex equivalent. On Claude Code, read its [Waits on Claude Code](references/codex-tools.md#waits-on-claude-code) section before any wait. +These skills share one tree across Claude Code, Codex, Grok and OpenCode. Read [`references/provider-dispatch.md`](references/provider-dispatch.md) whenever a configured role launches. It defines the provider-qualified model descriptors, native/external route table, launcher, isolation, receipts, and dropout policy. Children never choose routes. When a skill names a Claude tool or built-in skill (`run`, `verify`, `plugin-dev:skill-development`), read [`references/codex-tools.md`](references/codex-tools.md) for the Codex, Grok or OpenCode equivalent. On Claude Code, read its [Waits on Claude Code](references/codex-tools.md#waits-on-claude-code) section before any wait. ## Non-negotiables @@ -29,7 +29,7 @@ Remaining triggers: - Docs, RFCs, readmes, PR descriptions, or commit messages → the **technical-writing** skill (`/technical-writing`). - Before commit → the **deslop** skill (`/deslop`). - Before review → the **no-comments** skill (`/no-comments`). -- Shipping UI / IDE / CLI → the driver skill (`run` for CLIs/TUIs, `verify` for UIs). Both ship as Claude Code built-ins. For bug fixes, reproduce first on the same surface yourself. Hand to the user only under the narrow Bug fix step 1 exception. +- Shipping UI / IDE / CLI → the driver skill (`run` for CLIs/TUIs, `verify` for UIs). Both ship as Claude Code built-ins; on OpenCode use `shell` for CLIs/TUIs and the browser or `webfetch` for UIs. For bug fixes, reproduce first on the same surface yourself. Hand to the user only under the narrow Bug fix step 1 exception. - Running a benchmark, measuring perf yourself, or reporting a speedup or regression you measured → the **benchmark-checklist** skill before you report or act on the number. - Any PR-status request ("babysit this", "get it green", "address the review-bot comments", and most often "check on PR X" or "anything outstanding on X") → the **Babysit** playbook (`playbooks/babysit.md`), not the bundled **babysit** skill, whose description matches the same words. Never triggered by merely opening a PR. Declare its mode before polling. The playbook's step 1 owns the request-to-mode mapping. Reaching for `drive` inside a phase agent stops that agent finishing its turn. - Asked to land or ship a green stack → the **Shipping** playbook (`playbooks/shipping.md`). Green is not safe. Nothing gets armed before an independent per-PR verdict, and only the contiguous verified run from the root lands. @@ -92,9 +92,9 @@ Read the leaf skill in full for any principle you apply. Each entry names when i ## Subagents -For `inherit-parent`, `auto`, or an unconfigured native ad-hoc helper, prefer `poteto-agent`. The chat that receives `/poteto-mode` runs the playbook. Never spawn a `poteto-agent` to run the playbook itself. A provider-qualified role instead follows provider dispatch: Claude's shipped frontier agent definitions select the model alias and requested effort, and Codex passes both to `spawn_agent`. On a Grok parent, `inherit-parent` and `auto` call `spawn_subagent` with `subagent_type: pstack:poteto-agent`, and every explicit descriptor, including every Grok descriptor, runs through the deterministic launcher with `--parent grok`. Every other provider runs through the deterministic launcher. Routed workflow skills set the task and access mode. Do not override their choices. +For `inherit-parent`, `auto`, or an unconfigured native ad-hoc helper, prefer `poteto-agent`. The chat that receives `/poteto-mode` runs the playbook. Never spawn a `poteto-agent` to run the playbook itself. A provider-qualified role instead follows provider dispatch: Claude's shipped frontier agent definitions select the model alias and requested effort, and Codex passes both to `spawn_agent`. On a Grok parent, `inherit-parent` and `auto` call `spawn_subagent` with `subagent_type: pstack:poteto-agent`, and every explicit descriptor, including every Grok descriptor, runs through the deterministic launcher with `--parent grok`. On an OpenCode parent, `inherit-parent` and `auto` call `subagent` with `agent: poteto-agent`, and every explicit descriptor, including every OpenCode descriptor, runs through the deterministic launcher with `--parent opencode`. Every other provider runs through the deterministic launcher. Routed workflow skills set the task and access mode. Do not override their choices. -**Defaults for every delegation.** Start independent lanes together. In the main session, run a steer or resume of a running agent in the background too, because a foreground call holds your turn while other reports wait; a Claude Code subagent waits as [Waits on Claude Code](references/codex-tools.md#waits-on-claude-code) says. Use file pointers rather than inlined dumps, preserve only the tools or MCPs the task needs, and assign every writer a worktree or unique output directory. `/setup-pstack` configures the descriptor per role. A role without a sheet line uses its [role default](references/model-catalog.md#role-defaults); the panel roles default to one model from each of three providers. Each code playbook's configured model comes from its line (`feature, refactoring`, `bug-fix`, `perf-issue`, or `hillclimb`), and the hardest changes read `hardest tasks`. Prose and judgment read `judgment and prose`. `inherit-parent` and `auto` use the parent model natively and reduce provider diversity when used in a panel. +**Defaults for every delegation.** Start independent lanes together. In the main session, run a steer or resume of a running agent in the background too, because a foreground call holds your turn while other reports wait; a Claude Code subagent waits as [Waits on Claude Code](references/codex-tools.md#waits-on-claude-code) says, and an OpenCode subagent follows [Waits on OpenCode](references/codex-tools.md#waits-on-opencode). Use file pointers rather than inlined dumps, preserve only the tools or MCPs the task needs, and assign every writer a worktree or unique output directory. `/setup-pstack` configures the descriptor per role. A role without a sheet line uses its [role default](references/model-catalog.md#role-defaults); the panel roles default to one model from each of three providers. Each code playbook's configured model comes from its line (`feature, refactoring`, `bug-fix`, `perf-issue`, or `hillclimb`), and the hardest changes read `hardest tasks`. Prose and judgment read `judgment and prose`. `inherit-parent` and `auto` use the parent model natively and reduce provider diversity when used in a panel. **Match the model to the job.** Before each spawn, start from the role's line or default and pick the effort the job needs. That descriptor's effort is the starting level. Raise it one step, up to max, for the hardest or subtlest work, and leave a configured `ultra` as it is. Lower it one step for judgment and two or more steps for routine work. Verification is the exception and stays on the `swarm workers` descriptor. Change only the effort level, and keep the family the role names, so a diverse panel stays diverse. If the family's row in the [model matrix](references/model-catalog.md#model-matrix) does not list that effort, use its nearest listed effort. A role on `auto` or `inherit-parent` stays on the parent model, and an unregistered model keeps its configured effort. If the route rejects the adjusted effort, do not try another adjusted effort. Use the role's line or default and say so. Any other failure stays a dropout. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/authoring-a-skill.md b/plugins/pstack/skills/poteto-mode/playbooks/authoring-a-skill.md index 5d336795..9b49d3d8 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/authoring-a-skill.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/authoring-a-skill.md @@ -2,7 +2,7 @@ **You own the skill's voice.** -1. Use the **plugin-dev:skill-development** skill (Claude Code's skill for authoring SKILL.md files). +1. Use the **plugin-dev:skill-development** skill (Claude Code's skill for authoring SKILL.md files). On OpenCode, use the `writing-for-agents` skill if present, or OpenCode's own skill-authoring guidance; keep `name`/`description` frontmatter and relative support files. 2. Validate the skill: frontmatter has `name` and `description`, referenced files exist, cross-skill links resolve. 3. Test cases if structural. Skip if subjective. 4. Run **Opening a PR**. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/autonomous-run.md b/plugins/pstack/skills/poteto-mode/playbooks/autonomous-run.md index 743e1dc9..ae4ad818 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/autonomous-run.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/autonomous-run.md @@ -3,7 +3,7 @@ **You own the exit condition. Define done, then drive to it without stopping.** 1. State the exit condition as a checkable predicate before the first iteration (tests green, repro fixed, all N PRs merged, pixel-diff zero). -2. Pick the wake mechanism using Claude Code's `loop` skill (built-in). An event to watch (CI, a merge, a ref advancing) gets a watcher subagent that wakes you on the event, with a long time-based heartbeat as fallback. No event gets a fixed-interval heartbeat sized to when the result is worth re-checking. Pick each subagent's effort for the job, per the Subagents section. +2. Pick the wake mechanism using Claude Code's `loop` skill (built-in). On OpenCode, use a `shell` background task or an OpenCode automation. An event to watch (CI, a merge, a ref advancing) gets a watcher subagent that wakes you on the event, with a long time-based heartbeat as fallback. No event gets a fixed-interval heartbeat sized to when the result is worth re-checking. Pick each subagent's effort for the job, per the Subagents section. 3. Each iteration makes the smallest change the evidence justifies, verifies it against the predicate, commits if it advanced, discards changes that didn't help. Belt-and-suspenders that "might help" gets reverted, not left to ride. Sequence the work via the **sequence-verifiable-units** principle skill, verifying each unit before the next instead of batching checks at the end. 4. Mid-run discoveries that support the goal are yours. Address broken skills, related bugs, flaky verifiers, review noise, tooling failures, orphaned follow-ups, and fixable drift yourself via poteto-mode. Put out-of-band fixes in their own PR. Do not park reversible work for the human or use `AskUserQuestion`. Surface only irreversible actions, genuine product or preference calls no experiment can settle, or a real dead end. Keep the predicate as the main drive, and return to it after each side fix. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/autopilot-full.md b/plugins/pstack/skills/poteto-mode/playbooks/autopilot-full.md index e9f61ca3..f9cc1109 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/autopilot-full.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/autopilot-full.md @@ -9,7 +9,7 @@ A verdict covers one patch and green CI covers one head. Step 4 runs a full swar Open the PR early so CI and bots run alongside the work. The code is ready only after the slop-strip (the **deslop** skill, `/deslop`) and the `/no-comments` pass (the **no-comments** skill), so the full swarm runs on finished code. Then rebase onto current trunk fetched through `` and report the code-ready head before self-proof, so verification runs on the base the patch lands on. Report every later head, and merge-ready once self-proof, CI, and babysit are done. Fix rounds stay on that base unless trunk conflicts, breaks CI, or lands a known concurrent change to the same files, because each rebase restarts CI. Run the pre-review checks that the repo's instruction files (AGENTS.md, CLAUDE.md) name for the touched paths on the committed head before the code-ready push and before a later push that needs a verifier. A hook pass is not proof. - Assume the owner can die. Soon after starting, push and start an uncommitted `decisions.tsv` trail per the **show-me-your-work** skill, return it with each report, then push each finished unit before you start the next. Whoever spawns a subagent records its retained handle (Agent task, background Bash task, or Codex agent or session ID) and its state in a `children.tsv` kept the same way, so the root can probe it if the parent dies. Force-push only your own branch, and on any push you did not make, stop and report to the root. Before any rebase or other rewrite, apply Shipping step 4's disarm-and-confirm rule to your PR, stopping if the forge cannot confirm every request off. Fetch current trunk through ``. Record the selected exact commit as ``. Record the branch's published SHA as `` with `git ls-remote -- "$head_url" "refs/heads/$branch"` and require it to equal the local pre-rebase tip. Record the branch's current patch base as ``, require `git merge-base --is-ancestor "$current_base_sha" "refs/heads/$branch"` to pass, and use `git rebase --onto "$target_tip" "$current_base_sha" -- "$branch"` when the target changed. Publish with `git push --force-with-lease="refs/heads/$branch:$captured_sha" -- "$head_url" "HEAD:refs/heads/$branch"`, pinned to the SHA you last pushed or took over. + Assume the owner can die. Soon after starting, push and start an uncommitted `decisions.tsv` trail per the **show-me-your-work** skill, return it with each report, then push each finished unit before you start the next. Whoever spawns a subagent records its retained handle (Agent task, background Bash task, Codex agent or session ID, or OpenCode subagent session ID) and its state in a `children.tsv` kept the same way, so the root can probe it if the parent dies. Force-push only your own branch, and on any push you did not make, stop and report to the root. Before any rebase or other rewrite, apply Shipping step 4's disarm-and-confirm rule to your PR, stopping if the forge cannot confirm every request off. Fetch current trunk through ``. Record the selected exact commit as ``. Record the branch's published SHA as `` with `git ls-remote -- "$head_url" "refs/heads/$branch"` and require it to equal the local pre-rebase tip. Record the branch's current patch base as ``, require `git merge-base --is-ancestor "$current_base_sha" "refs/heads/$branch"` to pass, and use `git rebase --onto "$target_tip" "$current_base_sha" -- "$branch"` when the target changed. Publish with `git push --force-with-lease="refs/heads/$branch:$captured_sha" -- "$head_url" "HEAD:refs/heads/$branch"`, pinned to the SHA you last pushed or took over. **Stacked owners.** When Autopilot-stack bases a PR on another PR's branch, the parent PR's branch replaces trunk as that owner's rebase target, and the stack root rebases onto trunk. Fetch another stack branch directly through ``, because `` may have the base repository as its fetch URL and the fork as its push URL. Validate the chosen repository identity through the active forge, and record the fetched parent tip as `` in the flow above, so the rebase moves only the owner's commits. A new head on the parent restacks each PR above it through the same flow, and a PR whose `git patch-id` the restack leaves unchanged keeps its verdict. When the head and base repositories are the same, create or retarget the child PR with the parent branch as its base. Use `origin pr create --status open --base "$parent_branch"`, `gh pr create --base "$parent_branch" --repo "$base_repo"`, `origin pr edit "$pr" --base "$parent_branch"`, or `gh pr edit "$pr" --base "$parent_branch" --repo "$base_repo"` according to the resolved forge and operation. When the head repository is a fork, validate its identity and record its owner and repository name as `` and ``. Keep the local child branch rebased onto its parent's exact tip but create or retarget every PR against `` in the base repository, and never infer stack order from their equal base branches. With GitHub, capture the approved PR title and body as `` and `<body>`, then create it with `gh api --method POST "repos/$base_repo/pulls" -f "title=$title" -f "body=$body" -f "head=$fork_owner:$branch" -f "head_repo=$head_name" -f "base=$trunk" --jq .html_url`; add `-F draft=true` only when Opening a PR's readiness rule requires a draft. Otherwise use the resolved Origin equivalent. Retarget it with `gh pr edit "$pr" --base "$trunk" --repo "$base_repo"` or the resolved Origin equivalent. A forge cannot use a fork-only parent branch as a PR base. 3. **Run owners in parallel off trunk, never stacked,** so each PR lands on its own. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/bug-fix.md b/plugins/pstack/skills/poteto-mode/playbooks/bug-fix.md index 63844d6d..70249b59 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/bug-fix.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/bug-fix.md @@ -5,7 +5,7 @@ Be scientific. Every shipped line traces to runtime evidence. Belt-and-suspenders that "might help" is a hypothesis, not a fix. It does not ship. When evidence refutes a hypothesis, revert what it motivated. The smallest change the evidence justifies ships, nothing more. 1. Reproduce it yourself on the matching surface via the driver skill (`run` for CLIs/TUIs, `verify` for UIs) (Non-negotiables), even when a debug or instrumentation protocol says to ask the user to reproduce. Ask the user only with a stated, specific reason the control surface cannot reach the target, and only after driving it as far as it goes. If it won't reproduce directly, synthesize the trigger, tighten conditions, or instrument until it fires. -2. Binary-search the cause. Form the candidate hypotheses, then rule them out until one survives. Seed them with `how` over the affected subsystem and the **why** skill for regression history. Each pass, take the split that cuts the most remaining problem space, get runtime evidence, eliminate. When program state is unclear, add instrumentation or logging and read it as the code runs. Don't guess. Drive a long or stubborn hunt with Claude Code's `loop` skill. Confirm the surviving *mechanism* with runtime evidence before the step-3 architect/interrogate fan-out. +2. Binary-search the cause. Form the candidate hypotheses, then rule them out until one survives. Seed them with `how` over the affected subsystem and the **why** skill for regression history. Each pass, take the split that cuts the most remaining problem space, get runtime evidence, eliminate. When program state is unclear, add instrumentation or logging and read it as the code runs. Don't guess. Drive a long or stubborn hunt with Claude Code's `loop` skill; on OpenCode, re-run the hunt on a cadence with `shell` background tasks or an OpenCode automation. Confirm the surviving *mechanism* with runtime evidence before the step-3 architect/interrogate fan-out. 3. Plan the fix. If it crosses a function boundary, `architect` first. Delegate implementation through provider dispatch using your configured `bug-fix` descriptor (or its [role default](../references/model-catalog.md#role-defaults)) with `isolated-write`, a dedicated worktree, and a specific scope. 4. Verify on the same surface. The original repro now passes. "Inconclusive" or wrong-surface is not a pass. Flag it. Unit tests show branch behavior, not bug absence. 5. Stage the commits so the failing repro lands before the fix in git history. See the **tdd** skill for the failing-test-first cadence when the bug has a cheap local test path. Skip it when the test would be expensive, integration-heavy, or unclear. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/eval.md b/plugins/pstack/skills/poteto-mode/playbooks/eval.md index b876ede1..14b97cee 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/eval.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/eval.md @@ -19,7 +19,7 @@ 3. **Author one organic prompt.** What a user would type. No leakage of what's being measured. 4. **Spawn N parallel candidates** on different models per the **arena** skill's Phase B. Each works in its own sanitized dir. Same prompt to each. Pick each subagent's effort for the job, per the Subagents section. 5. **Spawn one blinded judge** on a different model family per the **arena** skill's Phase C. Judge sees outputs by sanitized label and the rubric, never a model name. -6. **Verify the chain from transcripts, not self-report.** Read each candidate's local transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/` (one `*.jsonl` per session for this workspace). Do not glob across `~/.claude/projects/`. That crosses workspace boundaries and reads private chats from unrelated projects. Look at which files each candidate actually opened. Grade chain-following from the files it really read plus the shape of the code, never from the candidate's own claims. +6. **Verify the chain from transcripts, not self-report.** Read each candidate's local transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/` (one `*.jsonl` per session for this workspace). Do not glob across `~/.claude/projects/`. That crosses workspace boundaries and reads private chats from unrelated projects. On OpenCode there is no JSONL transcript path; grade from each candidate's report, a session digest, and the files it actually changed. Look at which files each candidate actually opened. Grade chain-following from the files it really read plus the shape of the code, never from the candidate's own claims. 7. **Read every candidate output yourself** end to end. Compare to the judge's verdict. Disagreement means a model is biased or the rubric is ambiguous. Synthesize. **Reply:** variant under test, rubric, per-candidate notes, judge's verdict, your synthesis, and a recommendation for whether to promote the variant. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/multi-phase-plan.md b/plugins/pstack/skills/poteto-mode/playbooks/multi-phase-plan.md index ba466d8a..d2ce53ae 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/multi-phase-plan.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/multi-phase-plan.md @@ -12,9 +12,9 @@ **Verification.** Tests alone are not sufficient verification. A PR is verified only when its unit, live, and perf boxes are all checked (the **prove-it-works** principle skill). That sentence is the verification rule. Every verification block opens with it. The live block is mandatory. Ten lanes on the configured `swarm workers` role at the PR head drive the real surface through the driver skill, per the **swarm** skill. The role resolves once through [`../references/provider-dispatch.md`](../references/provider-dispatch.md) at execution time, and each lane's receipt records the selected provider, model, and effort. Each lane is one box with a concrete scenario, the screenshot it saves, and its pass predicate. One lane is the **Regression lane against trunk.** It runs the same load-bearing scenario on trunk and head. If trunk does not have the feature, the lane records that fact and gates the behavior the diff adds plus the end state the user waits for instead of inventing a trunk result. The perf gate is dual-sided. Trunk and head must both produce the named metric. If trunk lacks the feature, also isolate the work the diff adds and set an absolute budget for that work plus the end-to-end state the user waits for. Do not claim a ratio between unlike scenarios. The perf block names the metric, the interleaved probe, the trunk baseline measured first, and the rule with the number that fails. A PR that changes an interaction is review-gated. The operator reviews it in chat with screenshots and a video before merge. A PR that changes no interaction writes `**Review gate.** None. <PR id> is not review-gated.` and no boxes under it. -**Driver skill.** Pick it by surface. Browser, Electron, and web UIs use Claude Code's **verify** skill. CLIs and TUIs use Claude Code's **run** skill. Native mobile uses whatever simulator-driving skill the repo has. On Codex, substitute per [`../references/codex-tools.md`](../references/codex-tools.md). A PR that touches two surfaces gets lanes on both. A surface with no driver skill is a risk in Appendix C, and its live block still names how each lane drives it. +**Driver skill.** Pick it by surface. Browser, Electron, and web UIs use Claude Code's **verify** skill. CLIs and TUIs use Claude Code's **run** skill. Native mobile uses whatever simulator-driving skill the repo has. On Codex, substitute per [`../references/codex-tools.md`](../references/codex-tools.md). On OpenCode, use the browser or `webfetch` for web UIs and `shell` for CLIs/TUIs. A PR that touches two surfaces gets lanes on both. A surface with no driver skill is a risk in Appendix C, and its live block still names how each lane drives it. -On Claude Code, arm the hourly audit tick as `/loop 1h` with the tick prompt. On Codex, arm the cadence per [`../references/codex-tools.md`](../references/codex-tools.md). Never leave the cadence to memory. Keep skill-relative links in this playbook body. Do not copy them into the plan file. +On Claude Code, arm the hourly audit tick as `/loop 1h` with the tick prompt. On Codex, arm the cadence per [`../references/codex-tools.md`](../references/codex-tools.md). On OpenCode, use a `shell` background task or an OpenCode automation. Never leave the cadence to memory. Keep skill-relative links in this playbook body. Do not copy them into the plan file. ````markdown # <Program> plan diff --git a/plugins/pstack/skills/poteto-mode/playbooks/orchestrate.md b/plugins/pstack/skills/poteto-mode/playbooks/orchestrate.md index a72822de..9785075f 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/orchestrate.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/orchestrate.md @@ -2,12 +2,12 @@ **You run the program, never the code. Decide which agent does each piece of work, then check what each one produces.** For a standing project handed to one coordinator chat: multi-day, many stacked PRs, dozens to hundreds of subagents, few human turns. One task driven to a predicate is Autonomous run. One ambitious run that needs a bespoke workflow is figure-it-out. Work that one agent could finish inside the session's budget is not a program. -Run it with your own tools. Spawn workers through provider dispatch, per the Subagents section. Keep the program's state in `<config-home>/orchestrate/<project-slug>/notes.md`, outside the repo, so it outlives a session restart; `<config-home>` is the [harness config home](../references/codex-tools.md#harness-config-homes). Wait on each PR with `watch-pr`, per `playbooks/babysit.md`; a Claude Code subagent waits as [Waits on Claude Code](../references/codex-tools.md#waits-on-claude-code) says. Call no orchestration-store scripts, run no polling loops of your own, and never relay messages or status between agents. +Run it with your own tools. Spawn workers through provider dispatch, per the Subagents section. Keep the program's state in `<config-home>/orchestrate/<project-slug>/notes.md`, outside the repo, so it outlives a session restart; `<config-home>` is the [harness config home](../references/codex-tools.md#harness-config-homes). Wait on each PR with `watch-pr`, per `playbooks/babysit.md`; a Claude Code subagent waits as [Waits on Claude Code](../references/codex-tools.md#waits-on-claude-code) says, and an OpenCode subagent follows [Waits on OpenCode](../references/codex-tools.md#waits-on-opencode). Call no orchestration-store scripts, run no polling loops of your own, and never relay messages or status between agents. #### Topology - **One owner per PR.** The owner is the only writer of its branch and carries the PR from build to merge. Only the owner pushes, rebases, or retargets it. Closing or retargeting a base PR orphans every PR above it, so the owner does that only on your call. You never author or edit code. Conflicted merges, chain rebases, and fixes go to owners. -- **A fresh worker for each independent task.** Its kickoff carries everything it needs, including each upstream report it depends on, pasted in full. Workers can't see their siblings. Each writer runs in its own dedicated local worktree, because Claude Code and Codex have no remote worker environment. Pick each subagent's effort for the job, per the Subagents section. +- **A fresh worker for each independent task.** Its kickoff carries everything it needs, including each upstream report it depends on, pasted in full. Workers can't see their siblings. Each writer runs in its own dedicated local worktree, because Claude Code, Codex, Grok and OpenCode have no remote worker environment. Pick each subagent's effort for the job, per the Subagents section. - **A sub-coordinator only when one area has many parallel workers.** It owns that area's workers and kickoffs and sends you one rollup, never raw worker reports. Where a subagent cannot start agents, such as a [Claude Code native lane](../references/codex-tools.md#subagent-policy), you start its workers from the kickoffs it writes and hand their results back to it. Stop at three levels: you, sub-coordinators, and workers. Keep about ten workers in flight per coordinator, and start the next one as each finishes instead of waiting on a whole batch. - **Reuse a worker's worktree when new work needs its built state,** such as its checkout, uncommitted changes, or a running process: resume that worker, or start a new worker in that worktree after it stops. Message a worker only for a follow-up on the same work. Never message one to check on it, because a message restarts an idle agent. - **Each PR gets a verifier that isn't its author,** on a different model family. The owner merges only on that verifier's pass at the current head. diff --git a/plugins/pstack/skills/poteto-mode/playbooks/session-pickup.md b/plugins/pstack/skills/poteto-mode/playbooks/session-pickup.md index 60988fb3..300eed6a 100644 --- a/plugins/pstack/skills/poteto-mode/playbooks/session-pickup.md +++ b/plugins/pstack/skills/poteto-mode/playbooks/session-pickup.md @@ -2,7 +2,7 @@ **You own the resume point. Read the prior trail, don't redo it.** -1. Locate the prior trail. A local transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/*.jsonl` (where `<encoded-cwd>` is the workspace cwd with each `/` and each `.` → `-`. Do not glob across other directories under `~/.claude/projects/`, that crosses workspace boundaries and reads private chats from unrelated projects), a cloud-agent URL, or a pushed branch. Read the metadata overview and last messages first, then scan back for the decision points. Parse a long transcript in a subagent and keep the reduced timeline in the main thread (the **principle-guard-the-context-window** skill). Pick each subagent's effort for the job, per the Subagents section. +1. Locate the prior trail. A local transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/*.jsonl` (where `<encoded-cwd>` is the workspace cwd with each `/` and each `.` → `-`. Do not glob across other directories under `~/.claude/projects/`, that crosses workspace boundaries and reads private chats from unrelated projects), a cloud-agent URL, or a pushed branch. On OpenCode, use a session digest, a pushed branch, or the PR trail; there is no JSONL transcript path. Read the metadata overview and last messages first, then scan back for the decision points. Parse a long transcript in a subagent and keep the reduced timeline in the main thread (the **principle-guard-the-context-window** skill). Pick each subagent's effort for the job, per the Subagents section. 2. Reconstruct operational state. The branch and worktree, what already landed (`git log`, `git diff` against the base), the open todos, the decisions made. The prior trail is authoritative input. Resist the bias to re-derive it. 3. Diff done vs pending. Compare what shipped against what was planned, name the resume point, do not re-run the prior repro or redo completed work. A "let me verify from scratch" pass means you're treating the trail as untrustworthy when it's authoritative. 4. Route the remaining work to the matching playbook and pick the verdict: continue the execution, ship a finished recommendation, ratify or override a prior conclusion, or postmortem a failed run. The pickup playbook ends here. The routed playbook owns the rest. diff --git a/plugins/pstack/skills/poteto-mode/references/bugbot-triage.md b/plugins/pstack/skills/poteto-mode/references/bugbot-triage.md index b2fc7d35..b4305312 100644 --- a/plugins/pstack/skills/poteto-mode/references/bugbot-triage.md +++ b/plugins/pstack/skills/poteto-mode/references/bugbot-triage.md @@ -2,6 +2,8 @@ Use this reference when the Babysit playbook (`../playbooks/babysit.md`) handles Bugbot or review-automation comments. The goal is not to ignore Bugbot by default. The goal is to stop treating every comment as a required code change. +pstack does not launch, request, or wait for Bugbot. It only triages comments Bugbot has already left, and setup never invokes Bugbot. + ## Decision rubric Classify each Bugbot thread before acting: diff --git a/plugins/pstack/skills/poteto-mode/references/codex-tools.md b/plugins/pstack/skills/poteto-mode/references/codex-tools.md index 2494d4bf..7e209c3b 100644 --- a/plugins/pstack/skills/poteto-mode/references/codex-tools.md +++ b/plugins/pstack/skills/poteto-mode/references/codex-tools.md @@ -1,15 +1,16 @@ # Codex tool mapping for pstack -pstack skills retain Claude Code tool language (`Skill`, `Agent`, `AskUserQuestion`) in shared prose. On Codex the files are the same; only those tool names resolve differently. Model execution is not translated here. Read [`provider-dispatch.md`](provider-dispatch.md) for the parent-owned Claude/Codex/Grok route table and provider-qualified descriptors. In a T3 Code session under either app, its [T3 host](provider-dispatch.md#t3-host) section routes each lane. This file's subagent, background, and wait mappings apply only to a lane it gives the standalone route. +pstack skills retain Claude Code tool language (`Skill`, `Agent`, `AskUserQuestion`) in shared prose. On Codex, Grok and OpenCode the files are the same; only those tool names resolve differently. Model execution is not translated here. Read [`provider-dispatch.md`](provider-dispatch.md) for the parent-owned Claude Code/Codex/Grok/OpenCode route table and provider-qualified descriptors. In a T3 Code session under any of those runtimes, its [T3 host](provider-dispatch.md#t3-host) section routes each lane. This file's subagent, background, and wait mappings apply only to a lane it gives the standalone route. ## Harness config homes -Resolve the current parent's config home once: Claude Code uses nonempty `CLAUDE_CONFIG_DIR`, otherwise `$HOME/.claude`; Codex uses nonempty `CODEX_HOME`, otherwise `$HOME/.codex`; Grok uses nonempty `GROK_HOME`, otherwise `$HOME/.grok`. The equivalent quoted shell expressions are: +Resolve the current parent's config home once: Claude Code uses nonempty `CLAUDE_CONFIG_DIR`, otherwise `$HOME/.claude`; Codex uses nonempty `CODEX_HOME`, otherwise `$HOME/.codex`; Grok uses nonempty `GROK_HOME`, otherwise `$HOME/.grok`; OpenCode uses nonempty `OPENCODE_CONFIG_DIR`, otherwise nonempty `$XDG_CONFIG_HOME/opencode`, otherwise `$HOME/.config/opencode`. The equivalent quoted shell expressions are: ```bash "${CLAUDE_CONFIG_DIR:-$HOME/.claude}" "${CODEX_HOME:-$HOME/.codex}" "${GROK_HOME:-$HOME/.grok}" +"${OPENCODE_CONFIG_DIR:-${XDG_CONFIG_HOME:-$HOME/.config}/opencode}" ``` Empty and unset variables both select the default. Preserve spaces in the resolved path by quoting shell file operands. In shared instructions, `<config-home>` means this resolved parent-specific directory, not literal text to write. Use that same home for setup's sheet and integration writes, snapshots, restoration, and readback. @@ -22,9 +23,11 @@ The Claude integration is the one `@` import line in `<config-home>/CLAUDE.md` w Only when `CLAUDE_CONFIG_DIR` redirects the home, render exactly `@./pstack-models.md`. This relative import resolves from the importing file's directory, where the sheet also lives, so the import line contains no config-directory characters. On a rerun, replace that one line in place, preserving all unrelated bytes. If zero matching import lines exist, append one. If more than one exists, stop and report inconsistent state before either write; do not append another import or guess which one to replace. +Codex has no `@` include, so mirror the sheet's exact bytes inside one bounded block in `<config-home>/AGENTS.md` and retain the sheet as the editable source of truth. Grok writes `<config-home>/rules/pstack-models.md` and loads every Markdown file in that home rules directory. OpenCode writes `<config-home>/pstack-models.md`; the pstack OpenCode plugin appends that file to each model call's instructions, so it needs no `AGENTS.md` import or mirror. A malformed sheet is a visible stop in every harness, never a reason to use role defaults. + ## Active transcripts -Reflect passes reviewers this conversation's transcript only after the parent verifies it. Metadata records can come before the first user message in either harness, so never assume the first JSONL record is the opening message. +Reflect passes reviewers this conversation's transcript only after the parent verifies it. Metadata records can come before the first user message in every harness, so never assume the first JSONL record is the opening message. **Claude Code.** Look only in the per-project directory that the system prompt names under `<config-home>/projects/<encoded-cwd>/`. Do not glob across `<config-home>/projects/`, because that reads private chats from unrelated workspaces. Three layouts exist in that directory: flat (`<id>.jsonl`), nested (`<id>/<id>.jsonl`), and subagent (`<parent>/subagents/<child>.jsonl`). Inspect at most ten candidates, newest first. Read each with a line limit of at most 500. Stop scanning a candidate at 500 records, 2 MiB in total, or a 256 KiB record. Take the candidate whose first actual user message is this conversation's opening prompt. @@ -36,40 +39,47 @@ Reflect passes reviewers this conversation's transcript only after the parent ve The resolver reads the [Codex config home](#harness-config-homes) and looks up that exact ID in the `threads` table of its `state_*.sqlite` index. It checks that the rollout is inside `<config-home>/sessions/` and belongs to that chat. It then scans at most 500 records, 2 MiB in total, or a 256 KiB record for the first user message, skipping injected AGENTS.md and environment context. On success it exits 0 and prints the chat ID, the rollout path, and the opening message's line, record type, character count, and SHA-256. It never prints message text. If it cannot verify the transcript, it exits 1 and prints an `unresolved` reason. Before passing the path, compare the character count and SHA-256 with this conversation's opening prompt. Do not search by chat title or by time. +**Grok.** Grok keeps `chat_history.jsonl`, `summary.json`, and `tool_definitions.json` under its per-session folder. Reflect may read the current session's `chat_history.jsonl` only after the parent confirms its session ID, cwd and opening message. Use the session's own folder; never scan every Grok session. + +**OpenCode.** OpenCode keeps sessions in its local database, not in a portable per-session JSONL file, and its CLI exposes no transcript export. Do not read another session's database rows. Pass a tight session digest instead. + **Fallback.** If the chat ID, index, ownership, path, or opening prompt cannot be verified within these limits, pass a tight session digest instead. Keep it to at most 2,000 words and include only relevant decisions, corrections, evidence paths, and unresolved work. Do not widen transcript discovery to replace missing evidence. ## Reflect skill copies -Reflect never edits a skill inside the plugin cache, `<config-home>/plugins/cache/` in both harnesses. It copies the skill folder to one of these folders and edits the copy: +Reflect never edits a skill inside the plugin cache, `<config-home>/plugins/cache/` in Claude Code and Codex, or the installed OpenCode package. It copies the skill folder to one of these folders and edits the copy: | Harness | Project | User | | --- | --- | --- | | Claude Code | `.claude/skills/<skill>/` | `<config-home>/skills/<skill>/` | | Codex | `.agents/skills/<skill>/` | `$HOME/.agents/skills/<skill>/` | | Grok | `.grok/skills/<skill>/` | `<config-home>/skills/<skill>/` | +| OpenCode | `.opencode/skills/<skill>/` | `<config-home>/skills/<skill>/` | -The copy registers under its plain name beside the plugin's `pstack:<skill>`, and does not replace it. In the copy, rewrite each relative link that leaves the skill folder, such as `../poteto-mode/`, to the absolute path of that folder in the installed plugin. +The copy registers under its plain ID on OpenCode, where the project or user copy takes precedence over the plugin's registration for that ID, and under its plain name beside the plugin's `pstack:<skill>` on Claude Code and Codex, where it does not replace it. In the copy, rewrite each relative link that leaves the skill folder, such as `../poteto-mode/`, to the absolute path of that folder in the installed plugin. ## Tool actions -| pstack / Claude action | Codex equivalent | Grok equivalent | -|------------------------|------------------|-----------------| -| Read a file | `shell` (`cat`, `head`, `tail`) | `read_file` | -| Create / edit / delete a file | `apply_patch` | `search_replace` | -| Run a shell command | `shell` | `run_terminal_command` | -| Search file contents / find files | `shell` (`rg`, `grep`, `find`, `ls`) | `grep`, `list_dir` | -| Fetch a URL | `shell` with `curl` / `wget` | `web_fetch` | -| Search the web | `web_search` | `web_search` | -| Invoke a skill (the `Skill` tool, `/command`) | Skills load natively. Follow the instructions presented. | Skills load natively. Follow the instructions presented. | -| `paths` frontmatter scopes automatic loading | Claude Code only. On Codex, invoke `pstack:typescript-best-practices` by name. | Invoke `pstack:typescript-best-practices` by name. | -| Dispatch a subagent (the `Agent`/`Task` tool) | `spawn_agent` | `spawn_subagent` with `subagent_type: pstack:poteto-agent` | -| Dispatch N parallel subagents in one turn | N `spawn_agent` calls in one response | N `spawn_subagent` calls in one response | -| Wait for a subagent result | `wait_agent` | `get_command_or_subagent_output`, as [Waits on Grok](#waits-on-grok) says | -| Free a finished subagent slot | `close_agent` | None | -| Track tasks (the todolist / `TodoWrite`) | `update_plan` | `todo_write` | -| Ask the human a fixed-choice question (`AskUserQuestion`) | Ask in plain text and let the user answer. Codex has no structured-choice tool. | `ask_user_question` | - -Subagent dispatch needs `multi_agent` enabled. Add to `<config-home>/config.toml`, using Codex's [config-home rule](#harness-config-homes): +| pstack / Claude action | Codex equivalent | Grok equivalent | OpenCode equivalent | +|------------------------|------------------|-----------------|---------------------| +| Read a file | `shell` (`cat`, `head`, `tail`) | `read_file` | `read` | +| Create / edit / delete a file | `apply_patch` | `search_replace` | `write`, `edit` or `patch` | +| Run a shell command | `shell` | `run_terminal_command` | `shell` | +| Search file contents / find files | `shell` (`rg`, `grep`, `find`, `ls`) | `grep`, `list_dir` | `grep`, `glob` | +| Fetch a URL | `shell` with `curl` / `wget` | `web_fetch` | `webfetch` | +| Search the web | `web_search` | `web_search` | `websearch` | +| Invoke a skill (the `Skill` tool, `/command`) | Skills load natively. Follow the instructions presented. | Skills load natively. Follow the instructions presented. | Load the skill by ID with the `skill` tool, or mention `@<id>`. | +| `paths` frontmatter scopes automatic loading | Claude Code only. On Codex, invoke `pstack:typescript-best-practices` by name. | Invoke `pstack:typescript-best-practices` by name. | Invoke `typescript-best-practices` by ID. | +| Dispatch a subagent (the `Agent`/`Task` tool) | `spawn_agent` | `spawn_subagent` with `subagent_type: pstack:poteto-agent` | `subagent` with `agent: "poteto-agent"` | +| Dispatch N parallel subagents in one turn | N `spawn_agent` calls in one response | N `spawn_subagent` calls in one response | N `subagent` calls in one response, or `execute` with `Promise.allSettled` | +| Wait for a subagent result | `wait_agent` | `get_command_or_subagent_output`, as [Waits on Grok](#waits-on-grok) says | The parent receives a `<background-result>` message when it goes idle. Never poll. | +| Free a finished subagent slot | `close_agent` | None | None; subagents run at the configured depth. | +| Track tasks (the todolist / `TodoWrite`) | `update_plan` | `todo_write` | `todowrite`, when `experimental.todo` is on | +| Ask the human a fixed-choice question (`AskUserQuestion`) | Ask in plain text and let the user answer. Codex has no structured-choice tool. | `ask_user_question` | `question` | + +OpenCode has no user-invocable flag. The pstack plugin maps both `disable-model-invocation: true` and `user-invocable: false` to `opencode/autoinvoke: false`. Hidden skills remain loadable by exact ID, which is how poteto-mode reaches a principle leaf. + +On Codex, subagent dispatch needs `multi_agent` enabled. Add to `<config-home>/config.toml`, using Codex's [config-home rule](#harness-config-homes): ```toml [features] @@ -78,6 +88,8 @@ multi_agent = true Without it, the native Codex lane is a named dropout. Independent external lanes still run, and the parent records the reduced provider count. Never collapse a panel into a sequential single-model pass. +OpenCode registers `poteto-agent` and `comment-sicko` through its pstack plugin. Subagents always run in the background and the parent receives a report when one goes idle, and again after each later round of work. `experimental.subagent_depth` defaults to `1`, so a child cannot start another child. Turn on `experimental.todo` for `todowrite`. + ## Subagent policy poteto-mode's Subagents section sets the Claude-specific default `subagent_type: "poteto-agent"`. Claude Code waits follow [Waits on Claude Code](#waits-on-claude-code). On Codex: @@ -86,8 +98,9 @@ poteto-mode's Subagents section sets the Claude-specific default `subagent_type: - `spawn_agent` calls already run concurrently with your turn, so `run_in_background: true` has no separate flag. Issue the dispatch and continue. - There is no `comment-sicko` subagent type either. The **no-comments** skill spawns it on Claude Code; on Codex dispatch a `spawn_agent` whose instructions tell it to read `agents/comment-sicko.md` in full first. - On Grok, the pstack subagent types are `pstack:poteto-agent` and `pstack:comment-sicko`. The Grok manifest does not offer the `pstack-<family>-<effort>` Claude lane agents. +- On OpenCode, the pstack subagent IDs are `poteto-agent` and `comment-sicko`. The plugin does not register the `pstack-<family>-<effort>` Claude lane agents. - A Claude Code native lane cannot start agents: each `agents/pstack-*.md` lane disallows `Agent` and `Task`. -- Claude Code runs every subagent on this machine, so the **swarm** skill's workers and the fan-out playbooks (`orchestrate`, `autopilot-full`, `autopilot-stack`) isolate writers with worktrees. The same holds on Codex. +- Claude Code runs every subagent on this machine, so the **swarm** skill's workers and the fan-out playbooks (`orchestrate`, `autopilot-full`, `autopilot-stack`) isolate writers with worktrees. The same holds on Codex, Grok and OpenCode. - Keep the rest of the policy unchanged. Pass file pointers not inlined context, give each worker its own worktree or branch when they write, review every subagent's diff yourself. ## Waits on Claude Code @@ -110,25 +123,46 @@ poteto-mode's Subagents section sets the Claude-specific default `subagent_type: - MCP reaches native lanes only. Read-only on a native lane is advisory: add "Do not edit files." to its task and record it as advisory. - Children are depth one and cannot spawn. A child returns any further delegation it needs to the parent. +## Waits on OpenCode + +- Background shell: `shell` with `background: true` returns immediately and notifies the session when it finishes. Start the external launcher this way and keep the notification, not a poll loop. +- Native lanes: `subagent` starts a child session and returns immediately with its `sessionID`. The parent gets a `<background-result kind="subagent">` message when the child goes idle, and again after each later round. Keep working, or end your turn and act on the notice. Do not sleep, poll, or duplicate the child's work. +- A subagent that must have the result before its next step runs the launcher in one foreground `shell` call with an explicit `timeout` in milliseconds, then repeats on `TIMEOUT`. The default foreground shell timeout is two minutes. These windows bound one observation call; they are never a lane or runner deadline. +- Continue or redirect a running child by calling `subagent` again with its `sessionID`. Never kill a healthy lane. +- Writers: give the child a prepared checkout or worktree path. A native lane's read-only access is advisory; use the runner when read-only must be enforced. +- Children are depth one by default and cannot spawn. The pstack plugin registers `poteto-agent` and `comment-sicko`; the `/pstack/poteto-mode` and `/pstack/setup-pstack` commands inject the skill body before the user's text. + +## Waits on OpenCode + +- Background shell: `shell` with `background: true` returns immediately and notifies the session when the command finishes. Start the external launcher this way and retain nothing to poll. +- Native lanes: `subagent` starts a child session and returns its `sessionID` immediately. The parent receives a `<background-result kind="subagent">` message when the child goes idle, and again after each later round. Keep working, or end your turn and act on the notice. Do not sleep, poll, or duplicate the child's work. +- Blocking a subagent: when a subagent must have the result before its next step, it runs the lane in one foreground `shell` call with an explicit `timeout` in milliseconds, then repeats on `TIMEOUT`. The default foreground shell timeout is two minutes; larger values are allowed. This is one observation window, never a lane deadline. +- Cancelling: `subagent` again with the same `sessionID` continues or redirects the child. Stop a `shell` task through the session's background-task controls; do not kill a healthy lane. +- Writers: OpenCode's `subagent` child runs in the parent's location and permission policy. Give it a prepared checkout or worktree path, and use `isolation: worktree` only where the calling skill allows a child checkout. A native lane's read-only access is advisory; use the runner when read-only must be enforced. +- MCP reaches native lanes. Children are depth one by default and cannot spawn. +- The pstack plugin also registers `/pstack/poteto-mode` and `/pstack/setup-pstack`; both inject the skill body and then the user's text. `@poteto-mode` attaches the skill without the command. + ## Models and providers -Do not replace every configured entry with a Codex model. `/setup-pstack` writes portable descriptors, such as the [role defaults](model-catalog.md#role-defaults). In a Codex parent, only `codex:*` is native. Route Claude and Grok descriptors through the external launcher exactly as `provider-dispatch.md` specifies. In a Grok parent, only `inherit-parent` and `auto` use `spawn_subagent`. Every explicit descriptor, including every `grok:*` descriptor, uses the runner with `--parent grok`. The runner still rejects a Claude provider from a Claude parent and a Codex provider from a Codex parent. The default panel runs one model from each of three providers and contains no older GPT or Claude substitute. +Do not replace every configured entry with a Codex or OpenCode model. `/setup-pstack` writes portable descriptors, such as the [role defaults](model-catalog.md#role-defaults). In a Codex parent, only `codex:*` is native. Route Claude, Grok and the other external providers through the external launcher exactly as `provider-dispatch.md` specifies. In a Grok parent, only `inherit-parent` and `auto` use `spawn_subagent`. Every explicit descriptor, including every `grok:*` descriptor, uses the runner with `--parent grok`. In an OpenCode parent, only `inherit-parent` and `auto` use `subagent`. Every explicit descriptor, including every `opencode:*` descriptor, uses the runner with `--parent opencode`. The runner still rejects a Claude provider from a Claude parent and a Codex provider from a Codex parent. The default panel runs one model from each of three providers and contains no older GPT or Claude substitute. ## Claude built-in skills pstack references -Some triggers name skills that ship with Claude Code, not pstack. They do not exist on Codex. Substitute the behavior: +Some triggers name skills that ship with Claude Code, not pstack. They do not exist on Codex, Grok or OpenCode. Substitute the behavior: -| Claude built-in named in pstack | On Codex | -|---------------------------------|----------| -| `run` (drive a CLI/TUI to see a change work) | Run the app yourself via `shell` and observe the real output. | -| `verify` (drive a UI to confirm a fix) | Drive the UI with whatever automation you have, or hand the user a concrete manual check. Do not claim done without observing the artifact. | -| `plugin-dev:skill-development` (Claude's SKILL.md authoring guidance) | Follow your platform's skill-authoring guidance; the `writing-skills` skill if present. Keep `name` + `description` frontmatter and progressive disclosure. | -| `loop` (recurring/self-paced re-invocation, used by `babysit`) | Codex has no `loop` skill. Re-run the step yourself on a cadence, or use a Codex scheduled task if available. | +| Claude built-in named in pstack | On Codex | On OpenCode | +|---------------------------------|----------|-------------| +| `run` (drive a CLI/TUI to see a change work) | Run the app yourself via `shell` and observe the real output. | Run the app yourself with `shell` and observe the real output. | +| `verify` (drive a UI to confirm a fix) | Drive the UI with whatever automation you have, or hand the user a concrete manual check. Do not claim done without observing the artifact. | Drive the UI with the browser, a script, or a concrete manual check. Do not claim done without observing the artifact. | +| `plugin-dev:skill-development` (Claude's SKILL.md authoring guidance) | Follow your platform's skill-authoring guidance; the `writing-skills` skill if present. Keep `name` + `description` frontmatter and progressive disclosure. | Follow the `writing-for-agents` or platform guidance you have. Keep `name` + `description` frontmatter and progressive disclosure. | +| `loop` (recurring/self-paced re-invocation, used by `babysit`) | Codex has no `loop` skill. Re-run the step yourself on a cadence, or use a Codex scheduled task if available. | OpenCode has no `loop` skill. Re-run the step yourself on a cadence, or use an OpenCode automation if available. | ## Vendored scripts -`skills/poteto-mode/scripts/` ships the `watch-pr` PR watcher, `worktree-audit.sh`, and `runner/pstack-runner`. They are plain bun and bash, so they run the same on Codex; invoke them through `shell`. The external runner additionally needs the assigned `claude`, `codex`, or `grok` executable already authenticated. It rejects a Codex provider when Codex is the parent because that lane belongs on native `spawn_agent`. It rejects a Claude provider when Claude Code is the parent for the same reason. A Grok parent runs every explicit Grok descriptor through the runner. The other scripts need `bun`, `gh` (or Origin's `origin` CLI where the playbook resolves it), and (for `worktree-audit.sh`) `jq` and `rg`. `worktree-audit.sh` reads Claude Code transcripts under `~/.claude/projects/`; point it at your runtime's transcript directory instead when you run it elsewhere. +`skills/poteto-mode/scripts/` ships the `watch-pr` PR watcher, `worktree-audit.sh`, and `runner/pstack-runner`. They are plain bun and bash, so they run the same on Codex, Grok and OpenCode; invoke them through `shell`. The external runner additionally needs the assigned `claude`, `codex`, `grok`, or `opencode` executable already authenticated. It rejects a Codex provider when Codex is the parent because that lane belongs on native `spawn_agent`. It rejects a Claude provider when Claude Code is the parent for the same reason. A Grok parent runs every explicit Grok descriptor through the runner; an OpenCode parent runs every explicit OpenCode descriptor through it. The other scripts need `bun`, `gh` (or Origin's `origin` CLI where the playbook resolves it), and (for `worktree-audit.sh`) `jq` and `rg`. `worktree-audit.sh` reads Claude Code transcripts under `~/.claude/projects/`; point it at your runtime's transcript directory instead when you run it elsewhere. + +GitHub CLI (`gh`) runs through `shell` on Codex, Grok and OpenCode. The PR, issue and commit playbooks are shared, so an OpenCode session gets the same GitHub surface as Codex. pstack never invokes Bugbot; it only triages comments that already exist, and setup never calls it. pstack has no Slack integration; `.agents/triage-backlog.md` records GitHub Issues as this repository's tracker. ## Instructions file -Where a pstack skill says "your instructions file", on Codex that is `AGENTS.md` (project root, plus `<config-home>/AGENTS.md` global). On Claude Code it is `CLAUDE.md` (project root, plus `<config-home>/CLAUDE.md` global). Resolve the global directory with the [config-home rule](#harness-config-homes). +Where a pstack skill says "your instructions file", on Codex and OpenCode that is `AGENTS.md` (project root, plus `<config-home>/AGENTS.md` global). On Claude Code it is `CLAUDE.md` (project root, plus `<config-home>/CLAUDE.md` global). OpenCode reads `CLAUDE.md` only in a directory with no `AGENTS.md`, and reads the global `~/.claude/CLAUDE.md` only when the global OpenCode `AGENTS.md` is absent. Resolve the global directory with the [config-home rule](#harness-config-homes). diff --git a/plugins/pstack/skills/poteto-mode/references/model-catalog.md b/plugins/pstack/skills/poteto-mode/references/model-catalog.md index 5857bcaf..17df1922 100644 --- a/plugins/pstack/skills/poteto-mode/references/model-catalog.md +++ b/plugins/pstack/skills/poteto-mode/references/model-catalog.md @@ -63,18 +63,18 @@ Rolling aliases: ## Routes -| Provider | Claude Code parent | Codex parent | Grok parent | Access modes | Prompt | Model proof | Child environment | Host prerequisites | -| --- | --- | --- | --- | --- | --- | --- | --- | --- | -| claude | native `Agent` | external runner | external runner | `read-only`, `isolated-write` | stdin | provider report | read-only: inherited; isolated-write: inherited without `GIT_*` | - | -| codex | external runner | native `spawn_agent` | external runner | `read-only`, `isolated-write`, `isolated-write-full-access` | stdin | pinned argv | inherited | - | -| grok | external runner | external runner | explicit descriptor: external runner; `inherit-parent`, `auto`: native `spawn_subagent` | `read-only`, `isolated-write` | file | provider report | allowlist | Linux: Landlock and `bwrap`; macOS: any `/var/run/docker.sock` symlink points inside Grok's runtime-socket list | -| devin | external runner | external runner | external runner | `read-only`, `isolated-write`, `isolated-write-full-access` | file | provider report | allowlist | - | -| opencode | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | -| dsh | external runner | external runner | external runner | `read-only`, `isolated-write` | stdin | pinned argv | allowlist | dsh 0.2.1-rc.2 exactly | -| amp | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | -| agy | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | -| cursor | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | -| muse | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | file | pinned argv | allowlist | - | +| Provider | Claude Code parent | Codex parent | Grok parent | OpenCode parent | Access modes | Prompt | Model proof | Child environment | Host prerequisites | +| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | +| claude | native `Agent` | external runner | external runner | external runner | `read-only`, `isolated-write` | stdin | provider report | read-only: inherited; isolated-write: inherited without `GIT_*` | - | +| codex | external runner | native `spawn_agent` | external runner | external runner | `read-only`, `isolated-write`, `isolated-write-full-access` | stdin | pinned argv | inherited | - | +| grok | external runner | external runner | explicit descriptor: external runner; `inherit-parent`, `auto`: native `spawn_subagent` | external runner | `read-only`, `isolated-write` | file | provider report | allowlist | Linux: Landlock and `bwrap`; macOS: any `/var/run/docker.sock` symlink points inside Grok's runtime-socket list | +| devin | external runner | external runner | external runner | external runner | `read-only`, `isolated-write`, `isolated-write-full-access` | file | provider report | allowlist | - | +| opencode | external runner | external runner | external runner | explicit descriptor: external runner; `inherit-parent`, `auto`: native `subagent` | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | +| dsh | external runner | external runner | external runner | external runner | `read-only`, `isolated-write` | stdin | pinned argv | allowlist | dsh 0.2.1-rc.2 exactly | +| amp | external runner | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | +| agy | external runner | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | +| cursor | external runner | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | stdin | pinned argv | allowlist | - | +| muse | external runner | external runner | external runner | external runner | `read-only`, `isolated-write-full-access` | file | pinned argv | allowlist | - | The runner refuses an access mode outside a provider's Access modes cell before launch. `isolated-write-full-access` is a writer capability, not a `--mode` value: the runner takes it as `--mode isolated-write --writer-sandbox full-access`, which a parent passes only when the model sheet opts in, as [`provider-dispatch.md`](provider-dispatch.md#writer-sandbox) says. A provider whose cell lists `isolated-write-full-access` without `isolated-write` has no confined writer and writes only with that opt-in. @@ -126,17 +126,17 @@ The runner refuses an access mode outside a provider's Access modes cell before - Host prerequisites: none. - State paths: `~/.local/share/opencode/` (`auth.json`, the stored logins, which the CLI reads; the session database, logs and tool output it writes); `~/.local/state/opencode/`, `$XDG_CACHE_HOME/opencode/` and `$TMPDIR/opencode/`, which it writes. - Child environment: only `PATH` `HOME` `USER` `LOGNAME` `SHELL` `TMPDIR` `LANG` `TERM` `COLORTERM` `TZ` `HTTP_PROXY` `HTTPS_PROXY` `NO_PROXY` `ALL_PROXY` `http_proxy` `https_proxy` `no_proxy` `all_proxy` `SSL_CERT_FILE` `SSL_CERT_DIR` `NODE_EXTRA_CA_CERTS`, and variables starting with `LC_`, `XDG_`; sets `XDG_CONFIG_HOME=<receipt>.provider`, `OPENCODE_TEST_HOME=<receipt>.provider`, `OPENCODE_CONFIG=<receipt>.provider/opencode.json`, `OPENCODE_DISABLE_PROJECT_CONFIG=1`, `OPENCODE_DISABLE_CLAUDE_CODE=1`, `OPENCODE_DISABLE_EXTERNAL_SKILLS=1`, `OPENCODE_DISABLE_AUTOUPDATE=1`. -- The model is `provider/model`, such as `opencode/deepseek-v4.1-flash-free`. The effort is `--variant <effort>`, omitted for `default`. OpenCode accepts an unknown variant silently, so only a registered family's efforts are checked. -- Each lane runs the `build` agent (`--agent build`, because a config's `default_agent` would otherwise pick another agent) with a run-owned config whose `"*": "deny"` permission removes every tool the config does not allow from the model's tool list. A read-only lane allows `read`, `glob`, `grep`, `list` and `todowrite`. OpenCode's permission policy enforces this, not an OS sandbox. -- No OpenCode writer is confined, so a writer needs the model sheet's opt-in (`isolated-write-full-access`); the runner refuses a bounded `isolated-write` lane before launch. An opted-in writer's config also allows `bash`, `edit` and `write`. Measured with OpenCode 1.19.1 on macOS in a linked worktree under the home directory, whose main repository and a sibling directory sat beside it: edits, shell writes and a Python run inside the worktree succeeded. The `external_directory` rule stopped the edit tool outside the worktree except through a symlinked directory, and the shell wrote into the sibling, the main checkout, the main repository's shared `.git`, a home directory, `/tmp` and `$TMPDIR`. -- The runner writes that config to `<receipt>.provider/opencode.json` (0600, in a 0700 directory), points `OPENCODE_CONFIG` at it, and sets `XDG_CONFIG_HOME` and `OPENCODE_TEST_HOME` to the directory, so OpenCode reads the run-owned directory in place of the host's `~/.config/opencode/` and `~/.opencode/`. OpenCode 1.19.1 merges `~/.opencode/opencode.json` after `OPENCODE_CONFIG` and imports `~/.opencode/plugins/*.js` even with `--pure`, and it finds that home `.opencode/` through `OPENCODE_TEST_HOME` when set. Measured with a fresh `HOME` whose `.opencode/opencode.json` allowed `bash`, `edit` and `write` and whose `.opencode/plugins/` held a canary plugin: without `OPENCODE_TEST_HOME`, `opencode debug agent build` listed those tools and the canary ran, and neither `OPENCODE_CONFIG_CONTENT` nor `OPENCODE_CONFIG_DIR` changed that; with it, `debug agent build` and `debug config` showed only the lockdown, the canary did not run, and a lane asked to write and edit files changed nothing. Stored logins still come from the real home. `OPENCODE_DISABLE_PROJECT_CONFIG=1` stops the repository's `opencode.json`, `opencode.jsonc`, `.opencode/` agents and commands, and `AGENTS.md` from loading. `OPENCODE_DISABLE_CLAUDE_CODE=1` stops `~/.claude/CLAUDE.md` and `~/.claude/skills`, and `OPENCODE_DISABLE_EXTERNAL_SKILLS=1` stops `~/.agents/skills`. `OPENCODE_DISABLE_AUTOUPDATE=1` and `--pure` turn off updates and external plugins. The built-in `customize-opencode` skill remains, but the `skill` tool is denied. +- The model is `provider/model`, such as `opencode/deepseek-v4.1-flash-free`. The effort is the model's `#variant`, such as `provider/model#high`, and `default` adds no variant. Measured with OpenCode 2.4.0. Only a registered family's efforts are checked. +- Each lane runs the `build` agent (`--agent build`, because a config's `default_agent` would otherwise pick another agent) with a run-owned config whose ordered `permissions` deny `*` and then allow only the lane's tools. A read-only lane allows `read`, `glob`, `grep`, `list` and `todowrite`. OpenCode's permission policy enforces this, not an OS sandbox. +- No OpenCode writer is confined, so a writer needs the model sheet's opt-in (`isolated-write-full-access`); the runner refuses a bounded `isolated-write` lane before launch. An opted-in writer's config also allows `shell`, `edit`, `write` and `patch`. Measured with OpenCode 1.19.1 on macOS in a linked worktree under the home directory, whose main repository and a sibling directory sat beside it: edits, shell writes and a Python run inside the worktree succeeded. The `external_directory` rule stopped the edit tool outside the worktree except through a symlinked directory, and the shell wrote into the sibling, the main checkout, the main repository's shared `.git`, a home directory, `/tmp` and `$TMPDIR`. +- The runner writes that config to `<receipt>.provider/opencode.json` (0600, in a 0700 directory), points `OPENCODE_CONFIG` at it, and sets `XDG_CONFIG_HOME` and `OPENCODE_TEST_HOME` to the directory, so OpenCode reads the run-owned directory in place of the host's `~/.config/opencode/` and `~/.opencode/`. The 2.4.0 argv adds `--auto`, because headless OpenCode otherwise rejects a permission prompt. The config and isolation behavior below was measured with OpenCode 1.19.1. - A managed config (`/Library/Application Support/opencode/` on macOS, `/etc/opencode/` on Linux) merges after the run-owned config and overrides it. Measured on OpenCode 1.19.1 with layers planted through the binary's `OPENCODE_TEST_MANAGED_CONFIG_DIR` redirect: a managed `mcp` server started in a real lane, a managed `lsp` command ran when the model called `read`, a managed `provider` `baseURL` rerouted the lane, and a managed `agent.build` prompt replaced the build agent's prompt. `--agent build` and `-m` took precedence over a managed `default_agent` and `agent.build.model`, and `--pure` kept a managed `plugin` from loading. On macOS, `/Library/Managed Preferences/<user>/ai.opencode.managed.plist` and `/Library/Managed Preferences/ai.opencode.managed.plist` merge last. The plist layer is from OpenCode's source and was not measured. - A stored `wellknown` login (from `opencode providers login <url>`) or an active console organization (from `opencode console login`) makes every OpenCode process, including each lane, fetch remote config and merge it into the lane's configuration. Measured with a fake well-known login and a local server, whose config added an MCP server and a `default_agent`. The console organization fetch is from OpenCode's source and was not measured. - OpenCode 1.19.1 imports a repository's `.opencode/plugins/*.js` from the cwd or a parent up to the git root, even with `--pure` and `OPENCODE_DISABLE_PROJECT_CONFIG=1`. The import runs each module's top-level code; only the plugin's initialization is skipped. - The child environment drops every other `OPENCODE_*` variable, because `OPENCODE_PERMISSION` turns `bash` and `edit` back on and others replace the config or the model catalog. It also drops provider keys such as `OPENROUTER_API_KEY`. A lane authenticates through OpenCode's stored logins (`opencode auth login`, kept in `~/.local/share/opencode/auth.json`), or uses a free OpenCode Zen model, which needs no login. -- The preflight runs `opencode models <provider>`, where `<provider>` is the model's part before the first `/`. It passes when it exits 0 and one line equals the model. `Error: Provider not found:` with a nonzero exit is `unauthenticated`/77. Exit 0 without the model line is `unavailable-model`/69, and so is a model with no `/`. Any other output is `child-failed`/70. -- The lane passes `--title pstack-lane`, because without a title OpenCode calls a second model to name the session. The prompt goes on stdin. -- The reply, session ID, token usage and cost come from the `--format json` event stream on stdout. A lane is complete only when the last `step_finish` has reason `stop` and a `text` event follows the last `step_start`; the reply is those texts in order. Usage and cost are summed over every `step_finish`. An `error` event is `child-failed`/70. For an unknown model that event says only `UnknownError`, and `--print-logs --log-level ERROR` puts its `ProviderModelNotFoundError` cause on stderr, which the receipt keeps. A final `step_finish` with reason `tool-calls` is a permission prompt that headless OpenCode auto-rejected at exit 0, and is `child-failed`/70. Exit 130 or 143 after a signal is `cancelled`/130. +- The preflight runs `opencode models`, which lists every model under the configured providers and every free OpenCode Zen model. It passes when it exits 0 and one line equals the model without its `#variant`. `Error: Provider not found:` with a nonzero exit is `unauthenticated`/77. Exit 0 without the model line is `unavailable-model`/69, and so is a model with no `/`. Any other output is `child-failed`/70. +- The lane passes `--title pstack-lane`, because without a title OpenCode calls a second model to name the session. `--auto` approves only calls the run-owned config allows; every other tool is denied. The prompt goes on stdin. +- The reply, session ID, token usage and cost come from the `--format json` event stream on stdout. A lane is complete only when the last `step_finish` has reason `stop` and a `text` event follows the last `step_start`; the reply is those texts in order. Usage and cost are summed over every `step_finish`. An `error` event is `child-failed`/70. For an unknown model that event says only `UnknownError`, and `--print-logs --log-level error` puts its `ProviderModelNotFoundError` cause on stderr, which the receipt keeps. A final `step_finish` with reason `tool-calls` is a permission prompt that headless OpenCode auto-rejected at exit 0, and is `child-failed`/70. Exit 130 or 143 after a signal is `cancelled`/130. - No event names the served model, so the model proof is the pinned argv (`pinned-argv`). - Sessions stay in the local session database. The config turns sharing off, and OpenCode 1.19.1 keeps no server-side session record. diff --git a/plugins/pstack/skills/poteto-mode/references/provider-dispatch.md b/plugins/pstack/skills/poteto-mode/references/provider-dispatch.md index 1685fd6e..7afdad39 100644 --- a/plugins/pstack/skills/poteto-mode/references/provider-dispatch.md +++ b/plugins/pstack/skills/poteto-mode/references/provider-dispatch.md @@ -14,7 +14,7 @@ The allowed effort universe is exactly `low`, `medium`, `high`, `xhigh`, `max`, A rolling alias, such as `opus`, names a family whose CLI resolves it to the latest available family revision. A runner receipt keeps the requested alias in `model` and the concrete provider-reported revision in `reportedModel`; verification accepts only a revision of the matching family, as the catalog's rolling-alias table gives it. -A descriptor whose `(provider, model)` matches no matrix row, kept predecessor, or rolling-alias revision is an unregistered pair. It runs unchanged on an external route and on Codex's native route. A Claude-native route needs a generated agent, so an unregistered Claude model on a Claude Code parent is a dropout. An unregistered Grok model on a Grok parent uses the runner like every explicit Grok descriptor. Never guess a replacement. +A descriptor whose `(provider, model)` matches no matrix row, kept predecessor, or rolling-alias revision is an unregistered pair. It runs unchanged on an external route and on Codex's native route. A Claude-native route needs a generated agent, so an unregistered Claude model on a Claude Code parent is a dropout. An unregistered Grok model on a Grok parent uses the runner like every explicit Grok descriptor. An unregistered OpenCode model on an OpenCode parent uses the runner like every explicit OpenCode descriptor. Never guess a replacement. ## Read-time normalization @@ -28,15 +28,15 @@ A kept predecessor in the catalog matches its family. Dispatch it with the sheet The top-level harness resolves the route once. A child receives an assigned provider, model, effort, access mode, prompt, working directory, and output path. A child never detects the harness, chooses a provider, or launches another model. Environment markers may corroborate the top-level harness before fan-out, but nested processes inherit parent markers and must not use them for routing. -The catalog's [route table](model-catalog.md#routes) gives each provider's route from each parent. Outside [T3](#t3-host), a Claude or Codex provider on its own parent uses that parent's subagent primitive, and every other provider from those parents uses the external runner. A Grok parent uses `spawn_subagent` for `inherit-parent` and `auto` only. Every explicit descriptor from a Grok parent, including every `grok:*` descriptor, registered or not, uses the external runner with `--parent grok`. +The catalog's [route table](model-catalog.md#routes) gives each provider's route from each parent. Outside [T3](#t3-host), a Claude or Codex provider on its own parent uses that parent's subagent primitive, and every other provider from those parents uses the external runner. A Grok parent uses `spawn_subagent` for `inherit-parent` and `auto` only. Every explicit descriptor from a Grok parent, including every `grok:*` descriptor, registered or not, uses the external runner with `--parent grok`. An OpenCode parent uses `subagent` for `inherit-parent` and `auto` only. Every explicit descriptor from an OpenCode parent, including every `opencode:*` descriptor, registered or not, uses the external runner with `--parent opencode`. -A Grok parent reads its model sheet from `<config-home>/rules/pstack-models.md`, with `<config-home>` resolved by the [config-home rule](codex-tools.md#harness-config-homes). Grok loads that file as a home rule. It takes precedence over any model text Grok imports from Claude instructions. A malformed Grok sheet is a visible stop, never a reason to use the imported text or the role defaults. +A Grok parent reads its model sheet from `<config-home>/rules/pstack-models.md`, with `<config-home>` resolved by the [config-home rule](codex-tools.md#harness-config-homes). Grok loads that file as a home rule. It takes precedence over any model text Grok imports from Claude instructions. A malformed Grok sheet is a visible stop, never a reason to use the imported text or the role defaults. An OpenCode parent reads `<config-home>/pstack-models.md`; the pstack OpenCode plugin appends that file to each model call's instructions, so it needs no `AGENTS.md` import. A malformed OpenCode sheet is a visible stop, never a reason to use the role defaults. `inherit-parent` and `auto` remain aliases. Outside [T3](#t3-host), they use the parent's current model and effort through its native subagent primitive. In a panel they still consume one lane, but they reduce provider diversity; say so in the synthesis record. ## T3 host -A T3 Code parent records two facts once, before fan-out: the orchestration harness is T3, and the model runtime is the app running the session, Claude Code or Codex. The parent is on T3 when its own instructions name T3 Code and T3's orchestration tools respond. `T3CODE_THREAD_ID` only corroborates; a marker without working tools is a visible failure, not a T3 parent. T3 owns delegation, worktrees, and lifecycle. The runtime owns skill loading, the config home, and the model sheet. Pstack still chooses each role's provider, model, and effort, and T3's instructions govern waiting, cancellation, and re-review. +A T3 Code parent records two facts once, before fan-out: the orchestration harness is T3, and the model runtime is the app running the session, Claude Code, Codex or OpenCode. The parent is on T3 when its own instructions name T3 Code and T3's orchestration tools respond. `T3CODE_THREAD_ID` only corroborates; a marker without working tools is a visible failure, not a T3 parent. T3 owns delegation, worktrees, and lifecycle. The runtime owns skill loading, the config home, and the model sheet. Pstack still chooses each role's provider, model, and effort, and T3's instructions govern waiting, cancellation, and re-review. Read `orchestrator_capabilities` once per parent run and keep the snapshot. Route each normalized descriptor in this order: @@ -81,8 +81,9 @@ Native dispatch avoids a second CLI startup and its base context. - Claude Code: match the descriptor's `(provider, model)` to one model-matrix row, then dispatch it through `pstack-<family>-<effort>` using that row's family and the descriptor's effort. Those definitions select the row's model and requested effort. `pstack-fable-max` and `pstack-opus-xhigh` remain in that set. Pass the complete task, grounding paths, access mode, and unique output location in the `Agent` prompt. Dispatch and wait as [Waits on Claude Code](codex-tools.md#waits-on-claude-code) says. - Codex: call `spawn_agent` with the descriptor's model and `reasoning_effort`, the complete task, grounding paths, access mode, and unique output location. Use an isolated worktree for a writer. Codex subagents already run concurrently. - Grok: for `inherit-parent` and `auto` only, call `spawn_subagent` with `subagent_type: pstack:poteto-agent` and the complete task, grounding paths, access mode, and unique output location in the prompt. Pass no `model`. A Grok `[subagents.models]`, role, or persona override for that agent type changes this lane's model; the parent records the override with the lane. Dispatch, isolate, and wait as [Grok tools](codex-tools.md#waits-on-grok) says. A native child inherits the parent session's permission mode. A headless Grok parent uses auto mode, because headless Grok cancels the turn on a permission prompt and auto mode reports the blocked call to the model instead. +- OpenCode: for `inherit-parent` and `auto` only, call `subagent` with `agent: "poteto-agent"` and the complete task, grounding paths, access mode, and unique output location in the prompt. Pass no `model`; a native subagent inherits the parent session's model. Subagents always run in the background and report when they go idle. Dispatch, isolate, and wait as [Waits on OpenCode](codex-tools.md#waits-on-opencode) says. A read-only lane is advisory: add "Do not edit files." to its task and record it as advisory. A caller that needs enforced read-only access uses the runner. -Do not send a Claude or Codex descriptor to the external runner from that same parent. The runner rejects that call because the native route is available. A Grok parent sends every explicit `grok:*` descriptor to the runner with `--parent grok --provider grok`, because a Grok agent file that names a model Grok cannot serve runs the parent's model without an error, and the runner's receipt proves the served model. That launch sets `--permission-mode auto`, the model, and the effort. A failed native lane is never retried through the runner. +Do not send a Claude or Codex descriptor to the external runner from that same parent. The runner rejects that call because the native route is available. A Grok parent sends every explicit `grok:*` descriptor to the runner with `--parent grok --provider grok`, because a Grok agent file that names a model Grok cannot serve runs the parent's model without an error, and the runner's receipt proves the served model. That launch sets `--permission-mode auto`, the model, and the effort. An OpenCode parent sends every explicit `opencode:*` descriptor to the runner with `--parent opencode --provider opencode`, because a native `subagent` inherits the parent's model and cannot prove a pinned one. A failed native lane is never retried through the runner. ## External lanes @@ -90,7 +91,7 @@ The launcher lives at `skills/poteto-mode/scripts/runner/pstack-runner` under th ```text pstack-runner \ - --parent <claude|codex|grok> \ + --parent <claude|codex|grok|opencode> \ --provider <provider in the route table> \ --model <real CLI model> \ --effort <low|medium|high|xhigh|max|ultra|default> \ @@ -126,12 +127,13 @@ The parent invocation must itself be resumable background work: - Claude Code: call the launcher through a Bash tool invocation with `run_in_background: true` and retain its task ID. A foreground Bash tool call has an automatic ten-minute ceiling even when the runner's own timeout is longer. Shelling out with `&` and losing the task handle is not equivalent. A subagent that must wait on the launcher follows [Waits on Claude Code](codex-tools.md#waits-on-claude-code). - Codex: run the launcher in a persistent exec session that returns a session ID, then wait or poll that handle. Do not hold one foreground tool call open for the model's full runtime. - Grok: start the launcher as background work and wait on its task ID as [Waits on Grok](codex-tools.md#waits-on-grok) says. Do not hold one foreground tool call open for the model's full runtime. +- OpenCode: start the launcher with `shell` and `background: true`, retain the session's background-task notice, and do not poll. A subagent that needs the report before its next step runs the launcher in one foreground `shell` call with a bounded `timeout`, then repeats on `TIMEOUT` as [Waits on OpenCode](codex-tools.md#waits-on-opencode) says. Start the background process, continue launching the other lanes, then drain their handles. Native and external lanes belong in the same fan-out phase. The runner and its preflight have no implicit timeout. Do not invent a duration from role, mode, or a convenient round number; real implementation lanes can run for 90 minutes or much longer. Pass `--timeout` only when the user, an external service deadline, or a measured task contract supplies a real bound. That value starts at wrapper entry, before module loading and argument parsing, and remains one absolute deadline across setup, preflight, model execution, and output capture. It is never a fresh allowance per child, and long waits are armed in runtime-safe chunks without shortening the supplied deadline. Otherwise supervise liveness through the retained background task/session handle and cancel manually only on evidence that the run is dead. Cancel through that retained handle so the runner receives SIGINT or SIGTERM, sends it to an active child when one remains, stops waiting on inherited output pipes, removes the empty output reservation, and writes a `cancelled` receipt. Preserve that receipt; a retry is a new attempt with new unique output and receipt paths. Unchanged running state is not a dropout, and Claude's ten-minute foreground ceiling is never a reason to terminate a healthy lane. -Read-only mode maps to Claude plan mode with project-only settings and an explicit tool list, Codex's read-only sandbox, and Grok auto mode plus its `read-only` sandbox and read-oriented tool list. Headless Grok cancels the whole turn on a permission prompt, which its `plan` mode raises for any shell command outside its built-in read-only list; auto mode reports a blocked call to the model instead. Grok's built-in read-only profile deliberately keeps its own state and system temporary directories writable, so point a read-only Grok lane at the actual checkout rather than a worktree under `/tmp`, `/var/tmp`, or the host's temporary directory. `isolated-write` maps to Claude `acceptEdits` with project-only settings plus the Claude Code Bash sandbox, Codex `workspace-write` (or `danger-full-access` for a writer the sheet opts in, as [Writer sandbox](#writer-sandbox) says), and Grok auto mode plus its `workspace` sandbox and write-capable tool list. The Claude writer's Bash runs without prompts in that sandbox, and in a linked worktree the runner denies writes to the main repository's shared `.git`. The runner refuses the writer before launch when it cannot resolve that shared `.git` exactly or express its path literally. Grok uses auto mode in both access modes because `acceptEdits` raises the same turn-cancelling prompt for a shell command outside Grok's built-in list. Every other provider's mapping is in its [provider notes](model-catalog.md#provider-notes). The route table's Access modes cell lists each provider's modes. Give every writer only a dedicated worktree or output directory. Never route a writer into the primary checkout. +Read-only mode maps to Claude plan mode with project-only settings and an explicit tool list, Codex's read-only sandbox, and Grok auto mode plus its `read-only` sandbox and read-oriented tool list. Headless Grok cancels the whole turn on a permission prompt, which its `plan` mode raises for any shell command outside its built-in read-only list; auto mode reports a blocked call to the model instead. Grok's built-in read-only profile deliberately keeps its own state and system temporary directories writable, so point a read-only Grok lane at the actual checkout rather than a worktree under `/tmp`, `/var/tmp`, or the host's temporary directory. `isolated-write` maps to Claude `acceptEdits` with project-only settings plus the Claude Code Bash sandbox, Codex `workspace-write` (or `danger-full-access` for a writer the sheet opts in, as [Writer sandbox](#writer-sandbox) says), and Grok auto mode plus its `workspace` sandbox and write-capable tool list. An OpenCode lane runs the `build` agent with a run-owned config whose ordered permissions deny every tool and then allow the lane's read tools, or its shell and edit tools for an opted-in writer; nothing confines an OpenCode writer, so the full-access setting line is the only gate. The Claude writer's Bash runs without prompts in that sandbox, and in a linked worktree the runner denies writes to the main repository's shared `.git`. The runner refuses the writer before launch when it cannot resolve that shared `.git` exactly or express its path literally. Grok uses auto mode in both access modes because `acceptEdits` raises the same turn-cancelling prompt for a shell command outside Grok's built-in list. Every other provider's mapping is in its [provider notes](model-catalog.md#provider-notes). The route table's Access modes cell lists each provider's modes. Give every writer only a dedicated worktree or output directory. Never route a writer into the primary checkout. Every concurrent external lane needs distinct prompt, output, and receipt paths. The launcher exclusively reserves the output, receipt, and `<receipt>.stdout` / `<receipt>.stderr` sidecars with private (`0600`) permissions and refuses to overwrite existing files. For a provider whose notes name one, it also creates the private `<receipt>.provider/` directory (`0700`) that holds the provider's run-owned config and the file the CLI exports. All these paths must be distinct from each other and the prompt; a failed reservation rolls back only files created by that attempt. Schema-version-1 receipts add nullable `stdoutPath` and `stderrPath` fields identifying reserved artifacts. Sidecars retain the model process's raw stdout/stderr bytes, including on dropouts; they do not include authentication-preflight output. Cancellation and timeout retain every byte captured before the drain stops. Keep these private local files with the receipt; quote only operator-selected excerpts in public evidence. diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/cli.test.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/cli.test.ts index 1a651669..63dd26d4 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/cli.test.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/cli.test.ts @@ -79,10 +79,10 @@ describe("runner CLI parsing", () => { let stdout = ""; expect(await main(["--help"], Date.now(), { stdout: (value) => { stdout += value; }, stderr: () => {} })).toBe(0); expect(stdout).toStartWith( - "Usage: pstack-runner --parent <claude|codex|grok> --provider <claude|codex|grok|devin|opencode|dsh|amp|agy|cursor|muse> \\\n" + "Usage: pstack-runner --parent <claude|codex|grok|opencode> --provider <claude|codex|grok|devin|opencode|dsh|amp|agy|cursor|muse> \\\n" ); const help = stdout.replaceAll("\n", " "); - expect(help).toContain("A Grok parent runs every explicit Grok descriptor here"); + expect(help).toContain("A Grok or OpenCode parent runs every explicit descriptor of its own provider here"); expect(help).toContain("A Claude or Codex parent rejects its own provider"); }); diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/cli.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/cli.ts index 23fbdbbd..9429cd15 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/cli.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/cli.ts @@ -10,8 +10,9 @@ const HELP = `Usage: pstack-runner --parent <${Object.keys(PARENTS).join("|")}> --prompt <file> --cwd <dir> --output <file> --receipt <file> [--timeout <seconds>] Runs exactly one external model lane. A Claude or Codex parent rejects its own -provider; use that parent's native subagent primitive. A Grok parent runs every -explicit Grok descriptor here. Output and receipt paths must not already exist. +provider; use that parent's native subagent primitive. A Grok or OpenCode parent +runs every explicit descriptor of its own provider here, including Grok and +OpenCode models. Output and receipt paths must not already exist. There is no implicit timeout. Pass --timeout only when the user or task supplies a real deadline; it is one end-to-end launcher deadline shared by setup, preflight, and model execution. --writer-sandbox diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/adapter-suite.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/adapter-suite.ts index 9c3c7e71..43086155 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/adapter-suite.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/adapter-suite.ts @@ -55,7 +55,7 @@ export function adapterSuite(adapter: ProviderAdapter): void { const config = (request: Partial<LaneRequest> = {}) => adapter.launch.sidecar?.config?.content(lane(request)) ?? ""; it("passes the requested model to the CLI unchanged", () => { - expect(argv().includes("suite-model") || config().includes("suite-model")).toBe(true); + expect(argv().some((token) => token === "suite-model" || token.startsWith("suite-model#")) || config().includes("suite-model")).toBe(true); }); if (adapter.effortIn === "config") { @@ -66,6 +66,12 @@ export function adapterSuite(adapter: ProviderAdapter): void { expect(base.filter((line) => !high.includes(line))).toEqual([]); expect(argv({ effort: "high" })).toEqual(argv({ effort: "default" })); }); + } else if (adapter.effortIn === "model-variant") { + it("carries the effort in the model variant and omits it for the default effort", () => { + expect(argv({ effort: "high" })).toContain("suite-model#high"); + expect(argv({ effort: "default" })).toContain("suite-model"); + expect(argv({ effort: "default" }).some((token) => token.includes("#"))).toBe(false); + }); } else if (adapter.effortIn === "flag") { it("omits exactly the effort flag and value for the default effort", () => { const high = argv({ effort: "high" }); diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.test.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.test.ts index 9a7e8714..00c6687d 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.test.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.test.ts @@ -18,20 +18,22 @@ const preflight = (exitCode: number, stdout: string, stderr = "", request: Parti const event = (type: string, part: Record<string, unknown> = {}) => JSON.stringify({ type, timestamp: 1, sessionID: "ses_x", part }); describe("opencode launch", () => { - it("runs the pinned model and variant with a fixed title and the ERROR log on stderr", () => { + it("runs the pinned model and variant with a fixed title and the error log on stderr", () => { expect(opencode.launch.argv(lane(), testFacts(opencode))).toEqual([ - "run", "--pure", "--agent", "build", "--format", "json", "--title", "pstack-lane", "--print-logs", "--log-level", "ERROR", - "-m", MODEL, "--variant", "high", + "run", "--auto", "--agent", "build", "--format", "json", "--title", "pstack-lane", "--print-logs", "--log-level", "error", + "-m", `${MODEL}#high`, ]); expect(opencode.launch.argv(lane({ effort: "default", model: "openrouter/deepseek/deepseek-v4-pro" }), testFacts(opencode))) - .toEqual(["run", "--pure", "--agent", "build", "--format", "json", "--title", "pstack-lane", "--print-logs", "--log-level", "ERROR", "-m", "openrouter/deepseek/deepseek-v4-pro"]); + .toEqual(["run", "--auto", "--agent", "build", "--format", "json", "--title", "pstack-lane", "--print-logs", "--log-level", "error", "-m", "openrouter/deepseek/deepseek-v4-pro"]); }); - it("allows bash, edit and write only for an opted-in writer, and refuses a bounded writer and efforts the family does not list", () => { + it("allows shell and edit only for an opted-in writer, and refuses a bounded writer and efforts the family does not list", () => { const writer = lane({ mode: "isolated-write", writerSandbox: "full-access" }); - expect(JSON.parse(opencode.launch.sidecar!.config!.content(writer)).permission).toEqual({ - "*": "deny", read: "allow", glob: "allow", grep: "allow", list: "allow", todowrite: "allow", bash: "allow", edit: "allow", write: "allow", - }); + expect(JSON.parse(opencode.launch.sidecar!.config!.content(writer)).permissions).toEqual([ + { action: "*", resource: "*", effect: "deny" }, + ...["read", "glob", "grep", "list", "todowrite", "shell", "bash", "edit", "write", "patch"] + .map((action) => ({ action, resource: "*", effect: "allow" })), + ]); expect(opencode.launch.argv(writer, testFacts(opencode))).toEqual(opencode.launch.argv(lane(), testFacts(opencode))); expect(() => lane({ mode: "isolated-write" })) .toThrow("provider opencode does not support isolated-write; it supports only: read-only, isolated-write-full-access"); @@ -47,7 +49,10 @@ describe("opencode launch", () => { autoupdate: false, snapshot: false, instructions: [], - permission: { "*": "deny", read: "allow", glob: "allow", grep: "allow", list: "allow", todowrite: "allow" }, + permissions: [ + { action: "*", resource: "*", effect: "deny" }, + ...["read", "glob", "grep", "list", "todowrite"].map((action) => ({ action, resource: "*", effect: "allow" })), + ], }); }); @@ -72,9 +77,9 @@ describe("opencode launch", () => { }); describe("opencode preflight", () => { - it("asks the model's provider and passes only when the model is listed", () => { - expect(opencode.preflight.argv(lane(), null)).toEqual(["models", "opencode"]); - expect(opencode.preflight.argv(lane({ model: "openrouter/deepseek/deepseek-v4-pro" }), null)).toEqual(["models", "openrouter"]); + it("lists every configured model and passes only when the pinned model is listed", () => { + expect(opencode.preflight.argv(lane(), null)).toEqual(["models"]); + expect(opencode.preflight.argv(lane({ model: "openrouter/deepseek/deepseek-v4-pro" }), null)).toEqual(["models"]); expect(preflight(0, fixture("models-opencode-gate-env.txt"))).toEqual({ kind: "passed", evidence: `model ${MODEL} listed` }); expect(preflight(0, fixture("models-opencode-gate-env.txt"), "", { model: "opencode/deepseek-v4.1-flash" })) .toEqual({ kind: "unavailable-model" }); diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.ts index 6fb20b19..e0c208ce 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/providers/opencode.ts @@ -1,11 +1,12 @@ import { type Access, adapter, type ModelRun, type ParseResult, type ProviderMetadata } from "../registry/contract.ts"; -import { BASE_ALLOWLIST, BASE_PREFIXES, effortArgs, finiteNumber, nullableString, object, type JsonObject } from "./shared.ts"; +import { BASE_ALLOWLIST, BASE_PREFIXES, finiteNumber, nullableString, object, type JsonObject } from "./shared.ts"; // The run-owned global config. `"*": "deny"` removes every tool the allow-list does not name from the model's tool // list, so task, webfetch, websearch, skill and question are gone, and bash, edit and write too for a reader. -// Measured with OpenCode 1.19.1. +// Model, variant, preflight and `--auto` were measured with OpenCode 2.4.0; the config and isolation notes below were +// measured with 1.19.1. const READS = ["read", "glob", "grep", "list", "todowrite"]; -const WRITES = ["bash", "edit", "write"]; +const WRITES = ["shell", "bash", "edit", "write", "patch"]; function lockdown(access: Access) { const tools = access.mode === "read-only" ? READS : [...READS, ...WRITES]; return { @@ -13,7 +14,10 @@ function lockdown(access: Access) { autoupdate: false, snapshot: false, instructions: [], - permission: { "*": "deny", ...Object.fromEntries(tools.map((tool) => [tool, "allow"])) }, + permissions: [ + { action: "*", resource: "*", effect: "deny" }, + ...tools.map((tool) => ({ action: tool, resource: "*", effect: "allow" })), + ], }; } const CONFIG_NAME = "opencode.json"; @@ -96,16 +100,17 @@ function parse(run: ModelRun): ParseResult { export const opencode = adapter({ id: "opencode", executable: "opencode", - effortIn: "flag", + effortIn: "model-variant", preflight: { - // Lists only providers with a usable credential, plus the free OpenCode Zen models. - argv: (lane) => ["models", lane.model.split("/")[0]!], + // Lists the models of every provider with a usable credential, plus the free OpenCode Zen models. + argv: () => ["models"], retryAfterUnauthenticatedMs: null, classify(run, lane) { if (!lane.model.includes("/")) return { kind: "unavailable-model" }; + const model = lane.model.split("#")[0]!; if (run.exitCode === 0) { - return run.stdout.split("\n").some((line) => line.trim() === lane.model) - ? { kind: "passed", evidence: `model ${lane.model} listed` } + return run.stdout.split("\n").some((line) => line.trim() === model) + ? { kind: "passed", evidence: `model ${model} listed` } : { kind: "unavailable-model" }; } return /^Error: Provider not found:/m.test(run.stderr.replace(ANSI, "")) ? { kind: "unauthenticated" } : { kind: "inconclusive" }; @@ -118,7 +123,8 @@ export const opencode = adapter({ needsSharedGitDir: () => false, argv: (lane) => [ "run", - "--pure", + // OpenCode 2.4.0 dropped `--pure`; the run-owned config and the OPENCODE_DISABLE_* flags below isolate the lane. + "--auto", // A config's default_agent would otherwise pick another agent. "--agent", "build", @@ -130,10 +136,10 @@ export const opencode = adapter({ // An unknown model's stdout is a generic UnknownError; the ERROR log line names the cause. "--print-logs", "--log-level", - "ERROR", + "error", "-m", - lane.cliModel, - ...effortArgs(lane, ["--variant", lane.effort]), + // OpenCode 2.4.0 takes the effort as the model's #variant; 1.19.1 took `--variant`. + lane.effort === "default" ? lane.cliModel : `${lane.cliModel}#${lane.effort}`, ], }, parse: (run) => parse(run), @@ -165,17 +171,17 @@ export const opencode = adapter({ "`~/.local/state/opencode/`, `$XDG_CACHE_HOME/opencode/` and `$TMPDIR/opencode/`, which it writes", ], notes: [ - "The model is `provider/model`, such as `opencode/deepseek-v4.1-flash-free`. The effort is `--variant <effort>`, omitted for `default`. OpenCode accepts an unknown variant silently, so only a registered family's efforts are checked.", - "Each lane runs the `build` agent (`--agent build`, because a config's `default_agent` would otherwise pick another agent) with a run-owned config whose `\"*\": \"deny\"` permission removes every tool the config does not allow from the model's tool list. A read-only lane allows `read`, `glob`, `grep`, `list` and `todowrite`. OpenCode's permission policy enforces this, not an OS sandbox.", - "No OpenCode writer is confined, so a writer needs the model sheet's opt-in (`isolated-write-full-access`); the runner refuses a bounded `isolated-write` lane before launch. An opted-in writer's config also allows `bash`, `edit` and `write`. Measured with OpenCode 1.19.1 on macOS in a linked worktree under the home directory, whose main repository and a sibling directory sat beside it: edits, shell writes and a Python run inside the worktree succeeded. The `external_directory` rule stopped the edit tool outside the worktree except through a symlinked directory, and the shell wrote into the sibling, the main checkout, the main repository's shared `.git`, a home directory, `/tmp` and `$TMPDIR`.", - "The runner writes that config to `<receipt>.provider/opencode.json` (0600, in a 0700 directory), points `OPENCODE_CONFIG` at it, and sets `XDG_CONFIG_HOME` and `OPENCODE_TEST_HOME` to the directory, so OpenCode reads the run-owned directory in place of the host's `~/.config/opencode/` and `~/.opencode/`. OpenCode 1.19.1 merges `~/.opencode/opencode.json` after `OPENCODE_CONFIG` and imports `~/.opencode/plugins/*.js` even with `--pure`, and it finds that home `.opencode/` through `OPENCODE_TEST_HOME` when set. Measured with a fresh `HOME` whose `.opencode/opencode.json` allowed `bash`, `edit` and `write` and whose `.opencode/plugins/` held a canary plugin: without `OPENCODE_TEST_HOME`, `opencode debug agent build` listed those tools and the canary ran, and neither `OPENCODE_CONFIG_CONTENT` nor `OPENCODE_CONFIG_DIR` changed that; with it, `debug agent build` and `debug config` showed only the lockdown, the canary did not run, and a lane asked to write and edit files changed nothing. Stored logins still come from the real home. `OPENCODE_DISABLE_PROJECT_CONFIG=1` stops the repository's `opencode.json`, `opencode.jsonc`, `.opencode/` agents and commands, and `AGENTS.md` from loading. `OPENCODE_DISABLE_CLAUDE_CODE=1` stops `~/.claude/CLAUDE.md` and `~/.claude/skills`, and `OPENCODE_DISABLE_EXTERNAL_SKILLS=1` stops `~/.agents/skills`. `OPENCODE_DISABLE_AUTOUPDATE=1` and `--pure` turn off updates and external plugins. The built-in `customize-opencode` skill remains, but the `skill` tool is denied.", + "The model is `provider/model`, such as `opencode/deepseek-v4.1-flash-free`. The effort is the model's `#variant`, such as `provider/model#high`, and `default` adds no variant. Measured with OpenCode 2.4.0. Only a registered family's efforts are checked.", + "Each lane runs the `build` agent (`--agent build`, because a config's `default_agent` would otherwise pick another agent) with a run-owned config whose ordered `permissions` deny `*` and then allow only the lane's tools. A read-only lane allows `read`, `glob`, `grep`, `list` and `todowrite`. OpenCode's permission policy enforces this, not an OS sandbox.", + "No OpenCode writer is confined, so a writer needs the model sheet's opt-in (`isolated-write-full-access`); the runner refuses a bounded `isolated-write` lane before launch. An opted-in writer's config also allows `shell`, `edit`, `write` and `patch`. Measured with OpenCode 1.19.1 on macOS in a linked worktree under the home directory, whose main repository and a sibling directory sat beside it: edits, shell writes and a Python run inside the worktree succeeded. The `external_directory` rule stopped the edit tool outside the worktree except through a symlinked directory, and the shell wrote into the sibling, the main checkout, the main repository's shared `.git`, a home directory, `/tmp` and `$TMPDIR`.", + "The runner writes that config to `<receipt>.provider/opencode.json` (0600, in a 0700 directory), points `OPENCODE_CONFIG` at it, and sets `XDG_CONFIG_HOME` and `OPENCODE_TEST_HOME` to the directory, so OpenCode reads the run-owned directory in place of the host's `~/.config/opencode/` and `~/.opencode/`. The 2.4.0 argv adds `--auto`, because headless OpenCode otherwise rejects a permission prompt. The config and isolation behavior below was measured with OpenCode 1.19.1.", "A managed config (`/Library/Application Support/opencode/` on macOS, `/etc/opencode/` on Linux) merges after the run-owned config and overrides it. Measured on OpenCode 1.19.1 with layers planted through the binary's `OPENCODE_TEST_MANAGED_CONFIG_DIR` redirect: a managed `mcp` server started in a real lane, a managed `lsp` command ran when the model called `read`, a managed `provider` `baseURL` rerouted the lane, and a managed `agent.build` prompt replaced the build agent's prompt. `--agent build` and `-m` took precedence over a managed `default_agent` and `agent.build.model`, and `--pure` kept a managed `plugin` from loading. On macOS, `/Library/Managed Preferences/<user>/ai.opencode.managed.plist` and `/Library/Managed Preferences/ai.opencode.managed.plist` merge last. The plist layer is from OpenCode's source and was not measured.", "A stored `wellknown` login (from `opencode providers login <url>`) or an active console organization (from `opencode console login`) makes every OpenCode process, including each lane, fetch remote config and merge it into the lane's configuration. Measured with a fake well-known login and a local server, whose config added an MCP server and a `default_agent`. The console organization fetch is from OpenCode's source and was not measured.", "OpenCode 1.19.1 imports a repository's `.opencode/plugins/*.js` from the cwd or a parent up to the git root, even with `--pure` and `OPENCODE_DISABLE_PROJECT_CONFIG=1`. The import runs each module's top-level code; only the plugin's initialization is skipped.", "The child environment drops every other `OPENCODE_*` variable, because `OPENCODE_PERMISSION` turns `bash` and `edit` back on and others replace the config or the model catalog. It also drops provider keys such as `OPENROUTER_API_KEY`. A lane authenticates through OpenCode's stored logins (`opencode auth login`, kept in `~/.local/share/opencode/auth.json`), or uses a free OpenCode Zen model, which needs no login.", - "The preflight runs `opencode models <provider>`, where `<provider>` is the model's part before the first `/`. It passes when it exits 0 and one line equals the model. `Error: Provider not found:` with a nonzero exit is `unauthenticated`/77. Exit 0 without the model line is `unavailable-model`/69, and so is a model with no `/`. Any other output is `child-failed`/70.", - "The lane passes `--title pstack-lane`, because without a title OpenCode calls a second model to name the session. The prompt goes on stdin.", - "The reply, session ID, token usage and cost come from the `--format json` event stream on stdout. A lane is complete only when the last `step_finish` has reason `stop` and a `text` event follows the last `step_start`; the reply is those texts in order. Usage and cost are summed over every `step_finish`. An `error` event is `child-failed`/70. For an unknown model that event says only `UnknownError`, and `--print-logs --log-level ERROR` puts its `ProviderModelNotFoundError` cause on stderr, which the receipt keeps. A final `step_finish` with reason `tool-calls` is a permission prompt that headless OpenCode auto-rejected at exit 0, and is `child-failed`/70. Exit 130 or 143 after a signal is `cancelled`/130.", + "The preflight runs `opencode models`, which lists every model under the configured providers and every free OpenCode Zen model. It passes when it exits 0 and one line equals the model without its `#variant`. `Error: Provider not found:` with a nonzero exit is `unauthenticated`/77. Exit 0 without the model line is `unavailable-model`/69, and so is a model with no `/`. Any other output is `child-failed`/70.", + "The lane passes `--title pstack-lane`, because without a title OpenCode calls a second model to name the session. `--auto` approves only calls the run-owned config allows; every other tool is denied. The prompt goes on stdin.", + "The reply, session ID, token usage and cost come from the `--format json` event stream on stdout. A lane is complete only when the last `step_finish` has reason `stop` and a `text` event follows the last `step_start`; the reply is those texts in order. Usage and cost are summed over every `step_finish`. An `error` event is `child-failed`/70. For an unknown model that event says only `UnknownError`, and `--print-logs --log-level error` puts its `ProviderModelNotFoundError` cause on stderr, which the receipt keeps. A final `step_finish` with reason `tool-calls` is a permission prompt that headless OpenCode auto-rejected at exit 0, and is `child-failed`/70. Exit 130 or 143 after a signal is `cancelled`/130.", "No event names the served model, so the model proof is the pinned argv (`pinned-argv`).", "Sessions stay in the local session database. The config turns sharing off, and OpenCode 1.19.1 keeps no server-side session record.", ], diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/registry.test.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/registry.test.ts index 857b3072..f0d25bc3 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/registry.test.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/registry.test.ts @@ -149,14 +149,17 @@ describe("registry data", () => { const routes = renderCatalog(REGISTRY).content.split("\n## Routes\n")[1]!.split("\n## ")[0]!; for (const adapter of REGISTRY.adapters) { const cells = routes.split("\n").find((line) => line.startsWith(`| ${adapter.id} |`))!.split(" | "); - expect(cells.slice(1, 4)).toEqual([ + expect(cells.slice(1, 5)).toEqual([ adapter.id === "claude" ? "native `Agent`" : "external runner", adapter.id === "codex" ? "native `spawn_agent`" : "external runner", adapter.id === "grok" ? "explicit descriptor: external runner; `inherit-parent`, `auto`: native `spawn_subagent`" : "external runner", + adapter.id === "opencode" + ? "explicit descriptor: external runner; `inherit-parent`, `auto`: native `subagent`" + : "external runner", ]); - expect(routes).toContain("| Provider | Claude Code parent | Codex parent | Grok parent |"); + expect(routes).toContain("| Provider | Claude Code parent | Codex parent | Grok parent | OpenCode parent |"); } }); }); @@ -188,7 +191,7 @@ describe("generated files", () => { const dir = root(); writeGenerated(REGISTRY, dir); const first = files(dir); - expect(Object.keys(first)).toContain(CATALOG_PATH); + expect(Object.keys(first).map((path) => path.replaceAll("\\", "/"))).toContain(CATALOG_PATH); writeGenerated(REGISTRY, dir); expect(files(dir)).toEqual(first); expect(main(["--check"], dir)).toBe(0); @@ -243,8 +246,9 @@ describe("hand-written dispatch and setup rules", () => { expect(native).toContain("match the descriptor's `(provider, model)` to one model-matrix row"); expect(native).toContain("`pstack-<family>-<effort>`"); expect(native).toContain("`spawn_subagent`"); + expect(native).toContain("`subagent`"); expect(native).toContain("A headless Grok parent uses auto mode"); - expect(dispatch).toContain("--parent <claude|codex|grok>"); + expect(dispatch).toContain("--parent <claude|codex|grok|opencode>"); }); it("normalizes rolling-alias pins and keeps predecessors before any runtime route", () => { @@ -563,7 +567,7 @@ describe("resolveLane", () => { expect(() => resolveLane(request({ parent: "claude" }))) .toThrow("provider claude is native to parent claude; use the parent subagent primitive"); expect(() => resolveLane(request({ provider: "kiro" }))).toThrow("provider must be one of: claude, codex, grok, devin, opencode, dsh, amp, agy, cursor, muse"); - expect(() => resolveLane(request({ parent: "kiro" }))).toThrow("parent must be one of: claude, codex, grok"); + expect(() => resolveLane(request({ parent: "kiro" }))).toThrow("parent must be one of: claude, codex, grok, opencode"); expect(() => resolveLane(request({ mode: "full" }))).toThrow("mode must be one of: read-only, isolated-write"); expect(() => resolveLane(request({ model: " " }))).toThrow("model is required"); }); @@ -608,11 +612,11 @@ describe("module boundaries", () => { it("imports providers/* only from registry/providers.ts outside providers/", () => { const providers = join(RUNNER, "providers"); const importers = sources(RUNNER) - .filter((path) => !path.startsWith(`${providers}/`)) + .filter((path) => relative(providers, path).startsWith("..")) .filter((path) => [...readFileSync(path, "utf8").matchAll(/from\s+"([^"]+)"/g)] .some(([, specifier]) => specifier!.startsWith(".") - && resolve(dirname(path), specifier!).startsWith(`${providers}/`))) - .map((path) => relative(RUNNER, path)); + && !relative(providers, resolve(dirname(path), specifier!)).startsWith(".."))) + .map((path) => relative(RUNNER, path).replaceAll("\\", "/")); expect(importers).toEqual(["registry/providers.ts"]); }); diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/registry/contract.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/registry/contract.ts index bba1d21e..be76fd77 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/registry/contract.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/registry/contract.ts @@ -117,7 +117,7 @@ export interface ProviderSidecar { export interface ProviderAdapter { readonly id: string; readonly executable: string; - readonly effortIn: "flag" | "model-id" | "config"; + readonly effortIn: "flag" | "model-id" | "model-variant" | "config"; readonly preflight: { argv(lane: Lane, sidecar: LaunchFacts["providerSidecar"]): readonly string[]; readonly retryAfterUnauthenticatedMs: number | null; diff --git a/plugins/pstack/skills/poteto-mode/scripts/runner/types.ts b/plugins/pstack/skills/poteto-mode/scripts/runner/types.ts index 7f74a058..853281f2 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/runner/types.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/runner/types.ts @@ -30,6 +30,12 @@ export const PARENTS = { explicitLaneRoute: "runner", identity: ["GROK_SESSION_ID", "GROK_AGENT"], }, + opencode: { + harness: "OpenCode", + native: "subagent", + explicitLaneRoute: "runner", + identity: ["OPENCODE_SESSION_ID", "OPENCODE"], + }, } as const; export const EFFORTS = ["low", "medium", "high", "xhigh", "max", "ultra", "default"] as const; export const ACCESS_MODES = ["read-only", "isolated-write"] as const; diff --git a/plugins/pstack/skills/poteto-mode/scripts/watch-pr/github.test.ts b/plugins/pstack/skills/poteto-mode/scripts/watch-pr/github.test.ts index 4e589383..efc4e3f0 100644 --- a/plugins/pstack/skills/poteto-mode/scripts/watch-pr/github.test.ts +++ b/plugins/pstack/skills/poteto-mode/scripts/watch-pr/github.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from "bun:test"; import { spawnSync } from "node:child_process"; -import { mkdtempSync, rmSync, writeFileSync } from "node:fs"; +import { mkdtempSync, readFileSync, readdirSync, rmSync, writeFileSync } from "node:fs"; import { tmpdir } from "node:os"; import { join } from "node:path"; import { @@ -295,6 +295,41 @@ it("annotates Bugbot threads with distinct review-pass counts", () => { expect(threads.map((thread) => thread.bugbotReviewPasses)).toEqual([3, 3]); }); +it("treats a PR with no Bugbot comments as zero Bugbot passes", async () => { + const reader = fakeReader({ + threadPages: [{ + threads: [{ + id: "human", + firstComment: { + authorLogin: "reviewer", + body: "please fix", + path: "a.ts", + line: 1, + createdAt: "now", + }, + resolved: false, + }], + endCursor: null, + }], + }); + const threads = await resolveReviewThreads(reader, context); + expect(threads).toHaveLength(1); + expect(threads[0]!.isBugbot).toBe(false); + expect(threads[0]!.bugbotReviewPasses).toBe(0); +}); + +it("never invokes Bugbot from plugin code, setup, or playbooks", () => { + const root = join(import.meta.dir, "../../.."); + const walk = (dir: string): string[] => readdirSync(dir, { withFileTypes: true }).flatMap((entry) => { + if (entry.isDirectory()) return entry.name === "node_modules" ? [] : walk(join(dir, entry.name)); + return /\.(?:md|ts|sh|mjs)$/.test(entry.name) && !entry.name.endsWith(".test.ts") ? [join(dir, entry.name)] : []; + }); + const invocation = /\b(?:npx|bunx|cursor)\s+bugbot\b|\bbugbot\s+(?:run|review)\b|\b(?:Bun\.spawn|spawn|spawnSync|exec|execFile)\s*\([^\n]*bugbot/i; + const hits = walk(root).flatMap((path) => readFileSync(path, "utf8").split("\n").flatMap((line, at) => + invocation.test(line) ? [`${path.slice(root.length + 1)}:${at + 1}: ${line.trim()}`] : [])); + expect(hits).toEqual([]); +}); + describe("review thread pagination", () => { const thread = (id: string, resolved = false) => ({ id, diff --git a/plugins/pstack/skills/recall/SKILL.md b/plugins/pstack/skills/recall/SKILL.md index 48fcecdc..03413cd1 100644 --- a/plugins/pstack/skills/recall/SKILL.md +++ b/plugins/pstack/skills/recall/SKILL.md @@ -11,11 +11,11 @@ Keep it tight and on-topic. Read only what the in-scope threads need, then stop. Your context lives in two records. Your own chat history holds what you did and decided. The shared record holds everything that happened around the same code under other names: the symptoms users keep reporting, the fixes that shipped and got reverted, the errors still firing in prod. That second record is what the **why** skill searches, across source control, the issue tracker, chat and issue channels, long-form docs, and error tracking. A feature with a long bug tail keeps most of its story there, so don't reconstruct it from your transcripts alone. -Transcripts live at `~/.claude/projects/<encoded-cwd>/<uuid>.jsonl`, where `<encoded-cwd>` is the workspace path with each "/" and each "." turned into "-" (so `/Users/you/proj` becomes `-Users-you-proj`, and `/Users/you/proj/.claude/worktrees/x` becomes `-Users-you-proj--claude-worktrees-x`). Every line is one chat message. +Transcripts live at `~/.claude/projects/<encoded-cwd>/<uuid>.jsonl`, where `<encoded-cwd>` is the workspace path with each "/" and each "." turned into "-" (so `/Users/you/proj` becomes `-Users-you-proj`, and `/Users/you/proj/.claude/worktrees/x` becomes `-Users-you-proj--claude-worktrees-x`). Every line is one chat message. On OpenCode there is no JSONL transcript path and no supported database scan; use a session digest plus the live state you already have. 1. Classify, then route. One specific prior chat to resume is the `session-pickup` playbook, not this. Turning habits into a durable skill is `automate-me`. A human-readable summary of your work is a different task. Recall loads working context across recent chats before you act. If the user already gave you a full state capsule (paths, branch, the change), use it and skip the mining. 2. Lock the scope before searching. Pin the window ("recent" is a real range, default the last 7 days), the topic if named, and the workspace (default the active one. Never read another project's transcripts without being asked). State the scope back. Never quietly turn "all" into "recent N". -3. Fan out across your chat history. Spawn parallel subagents on a fast, cheap model, each taking a slice of the corpus. Tell every subagent to order candidates by real modification time (`ls -t`) and never by UUID name, grep the topic first and then read only the matching chats and only their relevant regions, and skip the current chat plus obvious noise (subagent, eval, and test chats). Each returns the same schema, one block per chat: topic, the user's goal, decisions, open threads, struggles and corrections, and artifacts (PRs, tickets, branches), each citing the chat UUID. For one or two chats, skip the fan-out and search directly. The raw transcripts stay in the subagents. The main thread gets only their findings. Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. +3. Fan out across your chat history. Spawn parallel subagents on a fast, cheap model, each taking a slice of the corpus. Tell every subagent to order candidates by real modification time (`ls -t`) and never by UUID name, grep the topic first and then read only the matching chats and only their relevant regions, and skip the current chat plus obvious noise (subagent, eval, and test chats). Each returns the same schema, one block per chat: topic, the user's goal, decisions, open threads, struggles and corrections, and artifacts (PRs, tickets, branches), each citing the chat UUID. For one or two chats, skip the fan-out and search directly. The raw transcripts stay in the subagents. The main thread gets only their findings. Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. On OpenCode, a native `subagent` inherits the parent model; use the configured descriptor through the runner when the role requires a different model. 4. Sweep the shared record whenever the topic names a feature, file, subsystem, area, or bug. This is the default, not a judgment call, and "my work on X" does not exempt it. Hand it to the **why** skill's source investigators, but steer their question from "why was this built this way" to "what's the current state, what's been tried and didn't hold, and what are users still reporting". Reuse its per-source playbooks, run the investigators in parallel with the chat-history mining, and inherit its posture: one investigator per source, null results are findings, skip an unavailable MCP and say so. Fold what comes back into the brief. Skip this step only for pure activity recall with no named target ("what did I do this week"), where your own history and live state are the entire answer. 5. Verify against live state. Take the PRs, branches, and tickets that the mining and the sweep surfaced and check them with `git` and `gh`. When the answer hinges on what an agent actually did (the tools it ran, files it read, errors it hit), read the full transcript, not just a trimmed local copy. 6. Write the brief to the contract below. Group by thread. Stay on the named topic. diff --git a/plugins/pstack/skills/reflect/SKILL.md b/plugins/pstack/skills/reflect/SKILL.md index d0389ce4..268c49de 100644 --- a/plugins/pstack/skills/reflect/SKILL.md +++ b/plugins/pstack/skills/reflect/SKILL.md @@ -7,7 +7,7 @@ description: Spawn three parallel review subagents over the active transcript, s Mine the current conversation for durable learnings, then route them into skill edits. -**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Reviewers need the parent's live MCP surface, so the default and supported portable route is `inherit-parent` (or its `auto` alias). Pass the transcript or digest plus any required evidence paths. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Reviewers need the parent's live MCP surface, so the default and supported portable route is `inherit-parent` (or its `auto` alias). Pass the transcript or digest plus any required evidence paths. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Invoke when the user says "reflect" or "/reflect". Skip when the conversation is trivial, off-topic, or already covered by an existing skill the parent followed correctly. One-offs are not learnings. diff --git a/plugins/pstack/skills/reflect/references/divergent-reviewer.md b/plugins/pstack/skills/reflect/references/divergent-reviewer.md index c972bbd5..776f5990 100644 --- a/plugins/pstack/skills/reflect/references/divergent-reviewer.md +++ b/plugins/pstack/skills/reflect/references/divergent-reviewer.md @@ -18,7 +18,7 @@ Scan for: ## Scope to skills and tools the session actually used -Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, or `~/.claude/plugins/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. +Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, `~/.claude/plugins/`, `.opencode/skills/`, or `<config-home>/skills/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. Two finding shapes are valid: - The parent invoked the skill and you found a real gap in its body. Route to the skill's relevant section. diff --git a/plugins/pstack/skills/reflect/references/judgment-reviewer.md b/plugins/pstack/skills/reflect/references/judgment-reviewer.md index 19daf579..ccd15233 100644 --- a/plugins/pstack/skills/reflect/references/judgment-reviewer.md +++ b/plugins/pstack/skills/reflect/references/judgment-reviewer.md @@ -17,7 +17,7 @@ Scan for: ## Scope to skills and tools the session actually used -Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, or `~/.claude/plugins/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. +Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, `~/.claude/plugins/`, `.opencode/skills/`, or `<config-home>/skills/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. Two finding shapes are valid: - The parent invoked the skill and you found a real gap in its body. Route to the skill's relevant section. diff --git a/plugins/pstack/skills/reflect/references/tooling-reviewer.md b/plugins/pstack/skills/reflect/references/tooling-reviewer.md index 448fb254..382f3106 100644 --- a/plugins/pstack/skills/reflect/references/tooling-reviewer.md +++ b/plugins/pstack/skills/reflect/references/tooling-reviewer.md @@ -28,7 +28,7 @@ Scan for: ## Scope to skills and tools the session actually used -Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, or `~/.claude/plugins/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. +Route findings only to skills, tools, or MCPs this transcript used. A skill counts as used when the transcript shows a `Read` of its `SKILL.md` (under `.claude/skills/`, `~/.claude/skills/`, `~/.claude/plugins/`, `.opencode/skills/`, or `<config-home>/skills/`), an `Agent` prompt naming its path, or a tool call (Shell, Grep, MCP, etc.) matching its documented commands. Speculative routings to skills the parent never opened do not count. Two finding shapes are valid: - The parent invoked the skill and you found a real gap in its body. Route to the skill's relevant section. diff --git a/plugins/pstack/skills/setup-pstack/SKILL.md b/plugins/pstack/skills/setup-pstack/SKILL.md index 3f94470b..6788fc25 100644 --- a/plugins/pstack/skills/setup-pstack/SKILL.md +++ b/plugins/pstack/skills/setup-pstack/SKILL.md @@ -27,15 +27,17 @@ Codex writes `<config-home>/pstack-models.md`. Codex has no `@` include, so mirr Grok writes `<config-home>/rules/pstack-models.md`. Grok loads every Markdown file in that home rules directory, so the sheet needs no include line or mirror. On Grok, `<config-home>/pstack-models.md` in the steps below means this path. +OpenCode writes `<config-home>/pstack-models.md`. The pstack OpenCode plugin appends that file to each model call's instructions, so it needs no include line or mirror. On OpenCode, `<config-home>/pstack-models.md` in the steps below means this path. Install the plugin before setup, as [docs/reference.md](../../../docs/reference.md#running-on-opencode) says. A missing plugin still lets setup write the sheet, but the sheet does not reach a model until the plugin is installed. + ## Steps ### 1. Establish the parent -Use the harness and tool surface running this skill: Claude Code, Codex, T3 Code running one of them, or Grok. Environment markers may corroborate that top-level answer, but do not launch a child and ask it to detect where it came from. Record the parent because the same descriptor takes a different route in each harness. On T3, record the orchestration harness and the model runtime as [T3 host](../poteto-mode/references/provider-dispatch.md#t3-host) says. The runtime, Claude Code or Codex, selects `<config-home>`, the sheet, and the integration below. A Grok parent selects its own. +Use the harness and tool surface running this skill: Claude Code, Codex, T3 Code running one of them, Grok, or OpenCode. Environment markers may corroborate that top-level answer, but do not launch a child and ask it to detect where it came from. Record the parent because the same descriptor takes a different route in each harness. On T3, record the orchestration harness and the model runtime as [T3 host](../poteto-mode/references/provider-dispatch.md#t3-host) says. The runtime, Claude Code, Codex or OpenCode, selects `<config-home>`, the sheet, and the integration below. A Grok parent selects its own. ### 2. Load current state -Inspect `<config-home>/pstack-models.md` and the existing integration: resolve Claude's single model-sheet import, or read Codex's single bounded model block; Grok has no integration, reporting missing targets and stopping on unreadable, malformed, or ambiguous state. Use the sole surviving configuration, or the editable sheet when both configurations agree; on Codex, the sheet remains authoritative and the block is its mirror, recoverable when the sheet is absent. If surviving configurations differ, show both sources and their differing assignments and require an explicit source choice before normalization or probing, without merging them automatically. Use first-run defaults only when neither source contains recoverable configuration, then apply the existing normalization, role-completion, and validation rules to the selected state. Before matrix validation, normalize only versioned predecessors of the catalog's [rolling aliases](../poteto-mode/references/model-catalog.md#kept-predecessors-and-normalization). Match in this order: an exact model-matrix row, then a kept predecessor, then a rolling-alias revision. A model that is its own matrix row, such as a registered exact pin, is never migratable. Any other provider-qualified Claude model is migratable when its model component starts with a rolling alias's versioned-predecessor prefix and the remaining revision contains only digits and hyphens. Replace that component in memory with the alias, preserving the provider, effort, role, and lane order. Record each original and normalized descriptor for the confirmation in step 7. This migration is valid loaded state and does not require a separate operator choice. +Inspect `<config-home>/pstack-models.md` and the existing integration: resolve Claude's single model-sheet import, or read Codex's single bounded model block; Grok and OpenCode have no integration, reporting missing targets and stopping on unreadable, malformed, or ambiguous state. Use the sole surviving configuration, or the editable sheet when both configurations agree; on Codex, the sheet remains authoritative and the block is its mirror, recoverable when the sheet is absent. If surviving configurations differ, show both sources and their differing assignments and require an explicit source choice before normalization or probing, without merging them automatically. Use first-run defaults only when neither source contains recoverable configuration, then apply the existing normalization, role-completion, and validation rules to the selected state. Before matrix validation, normalize only versioned predecessors of the catalog's [rolling aliases](../poteto-mode/references/model-catalog.md#kept-predecessors-and-normalization). Match in this order: an exact model-matrix row, then a kept predecessor, then a rolling-alias revision. A model that is its own matrix row, such as a registered exact pin, is never migratable. Any other provider-qualified Claude model is migratable when its model component starts with a rolling alias's versioned-predecessor prefix and the remaining revision contains only digits and hyphens. Replace that component in memory with the alias, preserving the provider, effort, role, and lane order. Record each original and normalized descriptor for the confirmation in step 7. This migration is valid loaded state and does not require a separate operator choice. A line `<provider> writer sandbox: full-access` or `<provider> writer sandbox: bounded`, such as `codex writer sandbox: full-access`, is a setting, not a role; [Writer sandbox](../poteto-mode/references/provider-dispatch.md#writer-sandbox) says how a parent uses it. Set the setting lines aside before the role overlay, the retired-role rule, and descriptor validation, and carry them through steps 6 to 8, including the line of a provider that no role uses. A second line for one provider, a provider outside the [route table](../poteto-mode/references/model-catalog.md#routes), or another value is inconsistent state. @@ -68,7 +70,7 @@ Before any external CLI availability/authentication check or model probe, resolv If required access is blocked, explain the affected assigned families and the restriction before invoking their CLIs. If permission information is unavailable or incomplete, call it **unknown**, say which required access cannot be established, and resolve it before external checks or probes. Offer exactly two paths when access is blocked or remains unknown: 1. Restart the parent with suitable permissions, chosen deliberately by the operator; stop this setup without writing. See provider-dispatch's **Host and parent prerequisites**, including Grok's nested-sandbox limitation. -2. Explicitly choose native-only role assignments for this parent. Show each affected role and proposed replacement and obtain the operator's named changes, then return to steps 2–4 to validate the revised map and efforts before native probes. On Codex, families of the `codex` provider are native; `inherit-parent` and `auto` also stay native. Do not change any lane automatically, reduce its effort, or launch an external CLI for a now-unassigned family. State any reduction in provider diversity. +2. Explicitly choose native-only role assignments for this parent. Show each affected role and proposed replacement and obtain the operator's named changes, then return to steps 2–4 to validate the revised map and efforts before native probes. On Codex, families of the `codex` provider are native; `inherit-parent` and `auto` also stay native. On OpenCode, only `inherit-parent` and `auto` are native; every explicit descriptor, including every `opencode:*` descriptor, uses the runner. Do not change any lane automatically, reduce its effort, or launch an external CLI for a now-unassigned family. State any reduction in provider diversity. If all chosen families are native, no external CLI permission check or probe is needed; the separate final-write check still applies. When the effective permissions allow the selected external lanes, proceed with the existing routes and requested efforts unchanged. Never change sandbox settings or escalate permissions as part of setup. @@ -76,7 +78,7 @@ Probe only the selected `provider:model@effort` pair of each assigned family. Ru If a Grok probe fails because the host cannot enforce its bounded sandbox, see [Host and parent prerequisites](../poteto-mode/references/provider-dispatch.md#host-and-parent-prerequisites); keep the active configuration unchanged. -Find the family's provider in the [route table](../poteto-mode/references/model-catalog.md#routes). A native-only route gets a native one-turn probe: on Claude Code, the family's `pstack-<family>-<effort>` agent; on Codex, `spawn_agent` with the descriptor's model and `reasoning_effort`. On Grok, `inherit-parent` and `auto` get a `spawn_subagent` probe with `subagent_type: pstack:poteto-agent`, and the parent records any Grok `[subagents.models]`, role, or persona override for that type. An external route gets one `pstack-runner` call with a tiny read-only probe prompt and `--parent` set to the parent running this skill. On a Grok parent every explicit descriptor, including every Grok descriptor, takes that call. The runner's preflight checks the CLI, the login and the model, and its receipt is the result. A T3 route gets one `delegate_task` probe, and its T3 result record must meet T3 host's completion rules. +Find the family's provider in the [route table](../poteto-mode/references/model-catalog.md#routes). A native-only route gets a native one-turn probe: on Claude Code, the family's `pstack-<family>-<effort>` agent; on Codex, `spawn_agent` with the descriptor's model and `reasoning_effort`. On Grok, `inherit-parent` and `auto` get a `spawn_subagent` probe with `subagent_type: pstack:poteto-agent`, and the parent records any Grok `[subagents.models]`, role, or persona override for that type. On OpenCode, `inherit-parent` and `auto` get a `subagent` probe with `agent: "poteto-agent"`. An external route gets one `pstack-runner` call with a tiny read-only probe prompt and `--parent` set to the parent running this skill. On a Grok parent every explicit descriptor, including every Grok descriptor, takes that call. On an OpenCode parent every explicit descriptor, including every OpenCode descriptor, takes that call. The runner's preflight checks the CLI, the login and the model, and its receipt is the result. A T3 route gets one `delegate_task` probe, and its T3 result record must meet T3 host's completion rules. Use a tiny read-only probe that returns a unique marker. For each family that an external writer role uses on a provider whose writer needs a `full-access` setting line, also run one `isolated-write` probe in a disposable linked worktree, with `--writer-sandbox full-access`, that creates a small program and runs it; it passes only when the program's output file holds the expected marker. A login-status command alone proves credentials, not that the requested model and effort flags run. Record native, external, and T3 results separately. Never call the external launcher for a Claude or Codex parent's own provider. @@ -101,7 +103,7 @@ Why and Reflect require the parent's live MCP surface. Keep their investigator, Every non-alias role value must match `<provider>:<model>@<effort>` and must have passed step 5. -After the operator confirms, or the qualifying rerun's probes all pass, separately check the parent's effective write permission for **both actual destinations** (the sheet and parent integration, resolved through `CODEX_HOME` when set; on Grok, the sheet alone) and any directory creation needed. Render both artifacts in memory and perform this check before the first write or directory creation. Native probes succeeding does not grant configuration-write permission. A restricted parent may still be allowed to write under `CODEX_HOME`; assess each resolved destination rather than rejecting it just because it is outside the workspace. If either destination is denied or its permission remains unknown, stop with the destination-specific explanation: leave every existing artifact byte-identical and create neither artifact on a first run. Do not test permission by overwriting a target, write only the allowed artifact, or automatically request escalation. +After the operator confirms, or the qualifying rerun's probes all pass, separately check the parent's effective write permission for **both actual destinations** (the sheet and parent integration, resolved through `CODEX_HOME` when set; on Grok and OpenCode, the sheet alone) and any directory creation needed. Render both artifacts in memory and perform this check before the first write or directory creation. Native probes succeeding does not grant configuration-write permission. A restricted parent may still be allowed to write under `CODEX_HOME`; assess each resolved destination rather than rejecting it just because it is outside the workspace. If either destination is denied or its permission remains unknown, stop with the destination-specific explanation: leave every existing artifact byte-identical and create neither artifact on a first run. Do not test permission by overwriting a target, write only the allowed artifact, or automatically request escalation. Only after both destinations are permitted, write the in-memory render from step 6 using step 8's snapshot and readback procedure. Never paste the role defaults as the result. They only seed step 2; selected efforts and explicit role changes always replace their values before writing. @@ -115,13 +117,15 @@ On Codex, the integration is the exact sheet bytes between one `<!-- pstack:mode On Grok, there is no integration. Snapshot, write, and read back the sheet alone. +On OpenCode, there is no integration artifact: the installed pstack plugin reads the sheet at each model call. Snapshot, write, and read back the sheet alone, and report that the plugin is missing when it is not installed. + Snapshot every target's current bytes. Write the sheet and parent integration only after every requested pair passes and the operator confirms or the rerun qualifies. Read both targets back and compare them with the in-memory render. If either write or readback fails, restore every snapshot and report the failure. An unchanged rerun must produce byte-identical sheet and integration content after normalization. Do not copy the model sheet between harnesses without rerunning the parent-specific probes; route availability can differ even on the same host. ### 9. Behavioral smoke -Before declaring setup complete, run one small read-only mixed panel from this parent: every distinct chosen descriptor, distinct output/receipt paths, and an independent cross-judge. Launch Claude-native agents and every external process in the background with retained handles, then drain them. On T3, run each lane and the judge through the route step 5 gave its family. Verify the native transcript entries, every external receipt, and every T3 result record. A structural config check or unit test is not a substitute. +Before declaring setup complete, run one small read-only mixed panel from this parent: every distinct chosen descriptor, distinct output/receipt paths, and an independent cross-judge. Launch Claude-native agents and every external process in the background with retained handles, then drain them. On OpenCode, launch each native `inherit-parent` or `auto` lane with `subagent`, and every explicit descriptor with the runner. On T3, run each lane and the judge through the route step 5 gave its family. Verify the native transcript entries, every external receipt, and every T3 result record. A structural config check or unit test is not a substitute. Report the sheet path, parent route table, requested-effort probe results, smoke results, and external elapsed/token/cost receipts. Re-running this skill re-probes and updates the same sheet. Do not claim the provider exposed hidden applied-effort observability. diff --git a/plugins/pstack/skills/show-me-your-work/SKILL.md b/plugins/pstack/skills/show-me-your-work/SKILL.md index a9c61992..2df7d79f 100644 --- a/plugins/pstack/skills/show-me-your-work/SKILL.md +++ b/plugins/pstack/skills/show-me-your-work/SKILL.md @@ -53,7 +53,7 @@ Commit it only when the work is ambitious enough that a reviewer needs the trail ## Audit the log against the transcript -At the end of the run, before handing back, check the log told the truth. Read this run's transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/`. Don't glob across `~/.claude/projects/`. That reads unrelated private chats. Walk this run's rows against what actually happened. Each stretch of them begins at one of this run's `start` rows, or at the first row if this run created the log, and ends at the next `start` row of another run: +At the end of the run, before handing back, check the log told the truth. Read this run's transcript under Claude Code's per-project transcripts directory at `~/.claude/projects/<encoded-cwd>/`. Don't glob across `~/.claude/projects/`. That reads unrelated private chats. On OpenCode, use the run's own log and a session digest; there is no JSONL transcript path. Walk this run's rows against what actually happened. Each stretch of them begins at one of this run's `start` rows, or at the first row if this run created the log, and ends at the next `start` row of another run: - Check that every row maps to a real decision or action. - Check that each row's evidence resolves and shows what the row claims. diff --git a/plugins/pstack/skills/swarm/SKILL.md b/plugins/pstack/skills/swarm/SKILL.md index aa5084a8..48eeada6 100644 --- a/plugins/pstack/skills/swarm/SKILL.md +++ b/plugins/pstack/skills/swarm/SKILL.md @@ -5,7 +5,7 @@ description: "Fan out N parallel workers, drain them, and return one report. Use # Swarm -**Dispatch contract.** Resolve each worker descriptor through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). The parent starts native and external lanes; workers never route themselves. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Dispatch contract.** Resolve each worker descriptor through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). The parent starts native and external lanes; workers never route themselves. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). ## Start diff --git a/plugins/pstack/skills/teach/SKILL.md b/plugins/pstack/skills/teach/SKILL.md index 4441b90e..4868fb19 100644 --- a/plugins/pstack/skills/teach/SKILL.md +++ b/plugins/pstack/skills/teach/SKILL.md @@ -9,7 +9,7 @@ description: "Explain a body of work plainly so a person actually understands it Teach sits on top of `how` and `why`. Get your bearings on what the work is and what it touches, then run `how` for how it works and `why` for why it's that way. Those are real skill invocations that do their own digging. Blend what they find into one plain explanation, lead with what matters to the person, and go deeper when they ask. Reword freely for teaching, with one exception. Keep `why`'s confidence language intact (its hedges are findings, not style). -**Platform note.** On Codex or another non-Claude runtime, running `how` and `why` in parallel maps to parallel subagent dispatch (`spawn_agent` fan-out), and the image-generation tool resolves to your platform's equivalent. Resolve tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). +**Platform note.** On Codex, Grok or OpenCode, running `how` and `why` in parallel maps to parallel subagent dispatch (`spawn_agent` fan-out), and the image-generation tool resolves to your platform's equivalent. Resolve tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). On OpenCode use parallel `subagent` calls and `generate_image`. 1. Decide the few things they should walk away understanding. Choose them from why they're asking (about to change it, reviewing it, debugging it, new to it) and what they already know, both read from the conversation, not quizzed out of them. Skip what they plainly already know. Put the depth where their question is. 2. Let `how` and `why` do the work, don't redo it. Read the code yourself to get oriented, then run `how` for how it works and `why` for why. Run them in parallel and combine the results. Match the size to the question. Run both for a subsystem, maybe one is enough for a small change. Keep `why` narrow by default since its full sweep is slow. Put the narrowing in the ask itself (a scoped question, git plus a source or two) so `why` records the skipped categories per its own contract, and widen it only when the reasons are the point. diff --git a/plugins/pstack/skills/why/SKILL.md b/plugins/pstack/skills/why/SKILL.md index ec98ea3e..6be5fbcf 100644 --- a/plugins/pstack/skills/why/SKILL.md +++ b/plugins/pstack/skills/why/SKILL.md @@ -7,7 +7,7 @@ description: "Use for 'why does X work this way', 'why we picked Y', design rati Investigate the motivation and intent behind code. The companion `how` skill answers what the code does and how it works. `why` answers what forces led to its shape. -**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Investigators require the parent's live MCP surface, so the default and supported portable route is `inherit-parent` (or its `auto` alias). Pass the code anchor by path. On Codex, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. +**Dispatch contract.** Resolve every configured role through [`provider-dispatch.md`](../poteto-mode/references/provider-dispatch.md). Investigators require the parent's live MCP surface, so the default and supported portable route is `inherit-parent` (or its `auto` alias). Pass the code anchor by path. On Codex, Grok or OpenCode, resolve remaining Claude tool names via [`codex-tools.md`](../poteto-mode/references/codex-tools.md). Pick each subagent's effort for the job, per the Subagents section of the **poteto-mode** skill. Every lane keeps MCP access. Do not pick a subagent type or execution mode that strips it, because that disables the MCP-backed investigators and the synthesizer's citation spot-checks. Investigators still shouldn't write anything. @@ -31,7 +31,7 @@ Before spawning investigators, build the seed context inline: file paths and lin ### Discovery -Before spawning investigators, list the available MCPs in the Claude Code environment. Use the tool list at the top of the system prompt (every MCP appears as a tool with prefix `mcp__<server>__<name>`). Otherwise read `.mcp.json` in the plugin/project, or run `claude mcp list`. +Before spawning investigators, list the available MCPs in the current runtime. On Claude Code, use the tool list at the top of the system prompt (every MCP appears as a tool with prefix `mcp__<server>__<name>`), read `.mcp.json` in the plugin/project, or run `claude mcp list`. On OpenCode, read the `mcp.servers` object in `opencode.jsonc`/`opencode.json`, run `opencode mcp list`, or inspect the session's MCP tools. On Codex or Grok, use that runtime's MCP listing. Map each available MCP to one evidence category: diff --git a/tests/skill-collision-repro.sh b/tests/skill-collision-repro.sh index 311d0073..7bcb58c7 100755 --- a/tests/skill-collision-repro.sh +++ b/tests/skill-collision-repro.sh @@ -37,12 +37,13 @@ verof() { { grep -m1 '"version"' "$1" || true; } | sed -E 's/.*"version"[[:space vc="$(verof "$repo/plugins/pstack/.claude-plugin/plugin.json")" vx="$(verof "$repo/plugins/pstack/.codex-plugin/plugin.json")" vg="$(verof "$repo/plugins/pstack/.grok-plugin/plugin.json")" +vo="$(verof "$repo/plugins/pstack/package.json")" vm="$(verof "$repo/.claude-plugin/marketplace.json")" vu="$(sed -n 's/| open-pstack version | `\([^`]*\)` |/\1/p' "$repo/UPSTREAM.md")" -if [ -n "$vc" ] && [ "$vc" = "$vx" ] && [ "$vc" = "$vg" ] && [ "$vc" = "$vm" ] && [ "$vc" = "$vu" ]; then - note "ok: open-pstack version matches across UPSTREAM.md and the 4 manifests ($vc)" +if [ -n "$vc" ] && [ "$vc" = "$vx" ] && [ "$vc" = "$vg" ] && [ "$vc" = "$vo" ] && [ "$vc" = "$vm" ] && [ "$vc" = "$vu" ]; then + note "ok: open-pstack version matches across UPSTREAM.md and the 5 manifests ($vc)" else - note "FAIL: open-pstack version differs: upstream=$vu claude-plugin=$vc codex-plugin=$vx grok-plugin=$vg marketplace=$vm" + note "FAIL: open-pstack version differs: upstream=$vu claude-plugin=$vc codex-plugin=$vx grok-plugin=$vg opencode=$vo marketplace=$vm" fail=1 fi @@ -89,7 +90,7 @@ for source in "$setup" "$config_mapping"; do done grep -Fq 'require an explicit source choice before normalization or probing' "$setup" || config_home_bad="${config_home_bad}setup does not require explicit source selection before normalization or probing"$'\n' grep -Fq '[harness config-home rule](../poteto-mode/references/codex-tools.md#harness-config-homes)' "$setup" || config_home_bad="${config_home_bad}setup does not reference the canonical config-home rule"$'\n' -for expression in '"${CLAUDE_CONFIG_DIR:-$HOME/.claude}"' '"${CODEX_HOME:-$HOME/.codex}"'; do +for expression in '"${CLAUDE_CONFIG_DIR:-$HOME/.claude}"' '"${CODEX_HOME:-$HOME/.codex}"' '"${OPENCODE_CONFIG_DIR:-${XDG_CONFIG_HOME:-$HOME/.config}/opencode}"'; do grep -Fxq "$expression" "$config_mapping" || config_home_bad="${config_home_bad}mapping lacks quoted nonempty/default resolution: $expression"$'\n' done for target in pstack-models.md CLAUDE.md AGENTS.md; do