Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .agents/triage-backlog.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ cd - && git worktree remove --force <tmp>/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/<path>` 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/<path>` 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

Expand Down
4 changes: 2 additions & 2 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -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)"
},
Expand Down
1 change: 1 addition & 0 deletions .claude/skills/verify-open-pstack/features/registry.json
Original file line number Diff line number Diff line change
Expand Up @@ -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/**",
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ plugins/pstack/skills/poteto-mode/scripts/node_modules/

plugins/pstack/skills/statechart/scripts/node_modules/

plugins/pstack/node_modules/

__pycache__/
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.

Expand Down
16 changes: 16 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -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 `<config-home>/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:<owner>/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 <provider/model>#<effort>`, 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.
Expand Down
2 changes: 2 additions & 0 deletions NOTICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand All @@ -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`
Expand Down
Loading