Skip to content
Merged
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 .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"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.19.0",
"version": "1.20.0",
"author": {
"name": "Lauren Tan (original)"
},
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/verify-open-pstack/features/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The ownership table below says which features a changed path reaches. `SKILL.md`
| --- | --- |
| `skills` | One `skill-invocation:<name>` exercise per selected skill, in both harnesses |
| `shared` | All listed skills, setup, runner, shipped tools, and `hook:startup` in both harnesses, and Claude's `agent-preload:poteto-agent`; a version-only manifest change reaches less, as described below |
| `catalog` | The generated model catalog and native agents, and the registry sources: `catalog`, `setup`, and `runner`, and no skill check; a provider adapter under `runner/providers/` also reaches `writers` |
| `catalog` | The generated model catalog and native agents, and the registry sources: `catalog`, `setup`, and `runner`, and no skill check; a provider adapter under `runner/providers/` also reaches `writers:<provider>`, or `writers` when no writer case names that provider |
| `assets` | Installed UI/resource surface for each actual consumer found in the pinned plugin manifests |
| `setup` | Installed setup/model configuration with byte-exact daily Claude file restoration before publication |
| `runner` | Installed parent invoking real configured provider lanes |
Expand Down
8 changes: 6 additions & 2 deletions .claude/skills/verify-open-pstack/features/recipes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ function codexWriter(optIn: boolean): Case {

const PROVIDER_WRITERS: [descriptor: string, optIn: boolean][] = [
['devin:swe-2@medium', false], ['dsh:deepseek-flash@low', false], ['opencode:opencode/deepseek-v4.1-flash-free@low', true],
['agy:gemini-3.8-flash@low', true], ['cursor:composer-2.5@default', true],
['agy:gemini-3.8-flash@low', true], ['cursor:composer-2.5@default', true], ['amp:smart@default', true],
];
const MUSE = { provider: 'muse', model: 'muse-spark-1.3', effort: 'low' };

Expand Down Expand Up @@ -810,7 +810,11 @@ export function recipe(feature: string, harness: Harness, routes: string[] = [])
if (feature === 'project-skill') return [projectSkill];
if (feature === 'hook:startup') return [startupHook];
if (feature === 'runner') return runner(harness, routes);
if (feature === 'writers') return [...PROVIDER_WRITERS.map(([descriptor, optIn]) => providerWriter(descriptor, optIn)), museWriter, museReader];
const writers = /^writers(?::([a-z]+))?$/.exec(feature);
if (writers) {
const cases = [...PROVIDER_WRITERS.map(([descriptor, optIn]) => providerWriter(descriptor, optIn)), museWriter, museReader];
Comment thread
github-actions[bot] marked this conversation as resolved.
Resolved
return writers[1] === undefined ? cases : cases.filter(c => c.id.startsWith(`${writers[1]}-`));
}
if (feature === 'setup' || feature === 'skill-invocation:setup-pstack') return setup;
if (feature === 'catalog') return catalog(harness);
if (feature === 'shipped-tools') return [shippedTools];
Expand Down
2 changes: 1 addition & 1 deletion .claude/skills/verify-open-pstack/features/runner.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ From Codex the recipe adds the `linked-worktree-writer` case: one `claude:opus@m

From Claude the recipe adds the `full-access-writer` case. Its fixture sheet puts `feature, refactoring` on `codex:gpt-6.1-sol@max` and holds the line `codex writer sandbox: full-access`. The prompt names the sheet, the role and the lane's paths, never the runner flag. The child writes a per-run nonce to `.agents/result.json` in its cwd, and adds a second nonce that it reads from the DOM headless Chrome dumps for a fixture page (Playwright's Chromium when Chrome is absent). The page file holds that nonce only base64-encoded. The case asserts the receipt is `complete` for that route and cwd, records `writerSandbox: "full-access"` and carries `--sandbox danger-full-access` in its argv, and that the `.agents/` result written this session holds both nonces. Its counterpart, `bounded-writer`, uses the same dispatch from a fixture sheet that puts `feature, refactoring` on `codex:gpt-6.1-sol@low` and has no setting line. The child writes a per-run nonce to the plain file `result.json` in its cwd, which `workspace-write` allows; it uses no browser and no `.agents/` path. The case asserts the receipt is `complete` for that route and cwd, records `writerSandbox: "bounded"`, carries `--sandbox workspace-write` and never `danger-full-access` in its argv, and that `result.json` written this session holds the nonce. Docker is not exercised. Route overrides do not change these cases.

The `writers` feature is reachable when a path under `plugins/pstack/skills/poteto-mode/scripts/runner/providers/` changes, and runs only when named. Its recipe has one writer case each for `devin:swe-2@medium` and `dsh:deepseek-flash@low`, whose sheets hold no setting line, and for `opencode:opencode/deepseek-v4.1-flash-free@low`, `agy:gemini-3.8-flash@low` and `cursor:composer-2.5@default`, whose sheets hold `<provider> writer sandbox: full-access`. Each fixture sheet puts `feature, refactoring` on that descriptor, and the prompt names the sheet, the role and the lane's paths, never the runner flag. The lane's cwd is a linked worktree of a run-owned repository. The child runs a Python command that writes the SHA-256 of a per-run nonce to `result.txt`; the case asserts the receipt is `complete` for that route, cwd and writer sandbox, and that `result.txt`, written this session, holds the hash, which the model cannot produce without running the command. `muse-writer` runs the same task with launcher arguments that name `--writer-sandbox full-access`, because no Muse family is registered for a sheet to name. `muse-reader` runs a read-only `muse:muse-spark-1.3@low` lane that must reply with a per-run marker from a fixture file, with a `pinned-argv` receipt.
The `writers` feature is reachable when a path under `plugins/pstack/skills/poteto-mode/scripts/runner/providers/` changes, and runs only when named. Its recipe has one writer case each for `devin:swe-2@medium` and `dsh:deepseek-flash@low`, whose sheets hold no setting line, and for `opencode:opencode/deepseek-v4.1-flash-free@low`, `agy:gemini-3.8-flash@low`, `cursor:composer-2.5@default` and `amp:smart@default`, whose sheets hold `<provider> writer sandbox: full-access`. Each fixture sheet puts `feature, refactoring` on that descriptor, and the prompt names the sheet, the role and the lane's paths, never the runner flag. The lane's cwd is a linked worktree of a run-owned repository. The child runs a Python command that writes the SHA-256 of a per-run nonce to `result.txt`; the case asserts the receipt is `complete` for that route, cwd and writer sandbox, and that `result.txt`, written this session, holds the hash, which the model cannot produce without running the command. `muse-writer` runs the same task with launcher arguments that name `--writer-sandbox full-access`, because no Muse family is registered for a sheet to name. `muse-reader` runs a read-only `muse:muse-spark-1.3@low` lane that must reply with a per-run marker from a fixture file, with a `pinned-argv` receipt. Each provider's cases also form the feature `writers:<provider>`, such as `writers:amp` or `writers:muse` (both Muse cases), and a change to that provider's adapter, tests or fixtures under `runner/providers/` reaches only that feature, while any other path there reaches the whole `writers` set.
3 changes: 2 additions & 1 deletion .claude/skills/verify-open-pstack/scripts/catalog.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,8 @@ test('each provider writer case puts its setting line in the sheet only for an o
const run = { ...record('claude', 'pstack:poteto-mode'), commands: ['"$RUNNER/pstack-runner" --provider x'] };
for (const [name, model, effort, optIn] of [
['devin', 'swe-2', 'medium', false], ['dsh', 'deepseek-flash', 'low', false], ['opencode', 'opencode/deepseek-v4.1-flash-free', 'low', true],
['agy', 'gemini-3.8-flash', 'low', true], ['cursor', 'composer-2.5', 'default', true], ['muse', 'muse-spark-1.3', 'low', true],
['agy', 'gemini-3.8-flash', 'low', true], ['cursor', 'composer-2.5', 'default', true], ['amp', 'smart', 'default', true],
['muse', 'muse-spark-1.3', 'low', true],
] as const) {
const f = await fixture('claude'), c = recipe('writers', 'claude').find(c => c.id === `${name}-writer`)!;
await c.prepare!(f);
Expand Down
13 changes: 10 additions & 3 deletions .claude/skills/verify-open-pstack/scripts/core.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { resolve } from 'node:path';
import registryData from '../features/registry.json';
import { recipe } from '../features/recipes.ts';
import { classify, completeEvidence, matches, newReceipt, requiredFeatures, requiredHarnesses, validateRegistry } from './core.ts';
import { HARNESSES, LIVE_HARNESSES, type Receipt } from './types.ts';
import { HARNESSES, LIVE_HARNESSES, WRITER_PROVIDERS, type Receipt } from './types.ts';
import codexManifest from '../../../../plugins/pstack/.codex-plugin/plugin.json';
import claudeManifest from '../../../../plugins/pstack/.claude-plugin/plugin.json';

Expand Down Expand Up @@ -89,8 +89,15 @@ describe('registry and ownership', () => {
expect(s.skills).toEqual([]);
expect(s.features).toEqual(both('catalog', 'runner', 'setup'));
}
expect(classify([{ filename: 'plugins/pstack/skills/poteto-mode/scripts/runner/providers/grok.ts' }], registry).features)
.toEqual(both('catalog', 'runner', 'setup', 'writers'));
const PROVIDERS = 'plugins/pstack/skills/poteto-mode/scripts/runner/providers/';
for (const [filename, writers] of [
['grok.ts', 'writers'], ['shared.ts', 'writers'], ['adapter-suite.ts', 'writers'], ['fixtures/claude/stream.jsonl', 'writers'],
...WRITER_PROVIDERS.map(provider => [`${provider}.ts`, `writers:${provider}`]),
['amp.test.ts', 'writers:amp'], ['fixtures/amp/lockdown-settings.json', 'writers:amp'], ['dsh-preflight.yml', 'writers:dsh'],
]) {
expect([filename, classify([{ filename: `${PROVIDERS}${filename}` }], registry).features])
.toEqual([filename, both('catalog', 'runner', 'setup', writers!)]);
}
});
test('a renamed or deleted catalog path keeps catalog ownership', () => {
for (const previous_filename of [CATALOG, 'plugins/pstack/agents/pstack-opus-max.md']) {
Expand Down
5 changes: 3 additions & 2 deletions .claude/skills/verify-open-pstack/scripts/core.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { HARNESSES, LIVE_HARNESSES, REPO, type ChangedFile, type Harness, type Receipt, type Registry, type Selection } from './types.ts';
import { HARNESSES, LIVE_HARNESSES, REPO, WRITER_PROVIDERS, type ChangedFile, type Harness, type Receipt, type Registry, type Selection } from './types.ts';

export function validateRegistry(value: unknown): Registry {
if (!value || typeof value !== 'object') throw new Error('Invalid feature registry');
Expand Down Expand Up @@ -55,7 +55,8 @@ export function classify(files: ChangedFile[], registry: Registry): Selection {
if (registry[key].some(p => matches(path, p))) { both(feature); covered = true; }
}
if (/^plugins\/pstack\/skills\/poteto-mode\/scripts\/resolve-codex-transcript(?:\.ts)?$/.test(path)) { skills.add('reflect'); covered = true; }
if (path.startsWith('plugins/pstack/skills/poteto-mode/scripts/runner/providers/')) both('writers');
const provider = /^plugins\/pstack\/skills\/poteto-mode\/scripts\/runner\/providers\/(?:fixtures\/)?([a-z]+)?/.exec(path);
if (provider) both((WRITER_PROVIDERS as readonly string[]).includes(provider[1] ?? '') ? `writers:${provider[1]}` : 'writers');
const skill = /^plugins\/pstack\/skills\/([^/]+)\/(.+)$/.exec(path);
if (!catalog && skill && registry.skills.includes(skill[1]!)) {
const leaf = skill[2]!;
Expand Down
8 changes: 6 additions & 2 deletions .claude/skills/verify-open-pstack/scripts/runner.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { tmpdir } from 'node:os';
import { join, resolve } from 'node:path';
import { recipe, type Fixture } from '../features/recipes.ts';
import { command } from './io.ts';
import type { SessionRecord } from './types.ts';
import { WRITER_PROVIDERS, type SessionRecord } from './types.ts';

const roots: string[] = [];
afterEach(async () => { for (const root of roots.splice(0)) await rm(root, { recursive: true, force: true }); });
Expand All @@ -31,7 +31,11 @@ test('the runner recipe adds one linked-worktree writer case for a Codex parent
expect(recipe('runner', 'claude').map(c => c.id)).toEqual(['route-1', 'full-access-writer', 'bounded-writer']);
expect(recipe('runner', 'codex').map(c => c.id)).toEqual(['route-1', 'linked-worktree-writer']);
expect(recipe('writers', 'claude').map(c => c.id))
.toEqual(['devin-writer', 'dsh-writer', 'opencode-writer', 'agy-writer', 'cursor-writer', 'muse-writer', 'muse-reader']);
.toEqual(['devin-writer', 'dsh-writer', 'opencode-writer', 'agy-writer', 'cursor-writer', 'amp-writer', 'muse-writer', 'muse-reader']);
expect(WRITER_PROVIDERS.flatMap(provider => recipe(`writers:${provider}`, 'claude').map(c => c.id)).sort())
.toEqual(recipe('writers', 'claude').map(c => c.id).sort());
expect(recipe('writers:amp', 'codex').map(c => c.id)).toEqual(['amp-writer']);
expect(recipe('writers:muse', 'codex').map(c => c.id)).toEqual(['muse-writer', 'muse-reader']);

const dir = await realpath(await mkdtemp(join(tmpdir(), 'pstack-runner-recipe-'))); roots.push(dir);
const workspace = resolve(import.meta.dir, '../../../..');
Expand Down
1 change: 1 addition & 0 deletions .claude/skills/verify-open-pstack/scripts/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ export const REPO = 'ericlitman/open-pstack';
export const HARNESSES = ['claude', 'codex'] as const;
export type CoreHarness = typeof HARNESSES[number];
export const LIVE_HARNESSES = [...HARNESSES, 't3'] as const;
export const WRITER_PROVIDERS = ['devin', 'dsh', 'opencode', 'agy', 'cursor', 'amp', 'muse'] as const;
export type Harness = typeof LIVE_HARNESSES[number];
export type Phase = 'resolve' | 'classify' | 'prepare' | 'exercise' | 'publish' | 'failed' | 'head-moved';
export interface Pull {
Expand Down
8 changes: 8 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
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.20.0 gives Amp an opted-in writer

Open Pstack 1.20.0 keeps the Cursor pstack 0.15.36 sync. Default roles and panels are unchanged.

**Amp writer (#269).** Amp's writer was measured on Amp CLI 0.0.1792123242-g03edc7: its edit tool and shell wrote outside the lane's worktree, including into the main repository's shared `.git`, a home directory and `/tmp`, so an Amp writer runs only when the model sheet holds `amp writer sandbox: full-access`. Its settings then enable the edit tools and the shell, and every other tool stays rejected. A bounded `isolated-write` Amp lane is refused before launch.

**One writer case per provider in the live gate (#269).** The verifier's `writers` feature gains an Amp case, and each provider's cases are also the feature `writers:<provider>`, such as `writers:amp`. A change to one provider's adapter, tests or fixtures reaches only that provider's feature, so its live gate runs one case.

## 1.19.0 adds T3 Code as a third harness

Open Pstack 1.19.0 keeps the Cursor pstack 0.15.36 sync. Default roles and panels are unchanged.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ This repository also keeps:

## Staying close to Lauren's pstack

Open Pstack 1.19.0 tracks pstack 0.15.36 at Cursor commit [`2776ddd2355d6d6c8747d3964600f28daf62f049`](https://github.com/cursor/plugins/commit/2776ddd2355d6d6c8747d3964600f28daf62f049).
Open Pstack 1.20.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.

Expand Down
4 changes: 2 additions & 2 deletions UPSTREAM.md
Original file line number Diff line number Diff line change
Expand Up @@ -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.19.0` |
| open-pstack version | `1.20.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 and 1.19.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.20.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

Expand Down
2 changes: 1 addition & 1 deletion docs/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -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 and T3 Code without Cursor. One shared skill tree serves all three 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.19.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 and T3 Code without Cursor. One shared skill tree serves all three 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.20.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`.

Expand Down
2 changes: 1 addition & 1 deletion plugins/pstack/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "pstack",
"displayName": "pstack",
"version": "1.19.0",
"version": "1.20.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.",
"author": {
"name": "Lauren Tan"
Expand Down
2 changes: 1 addition & 1 deletion plugins/pstack/.codex-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pstack",
"version": "1.19.0",
"version": "1.20.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"
Expand Down
Loading
Loading