From 562cf536b2b6736d6ca090bdaad74cefa0a57d09 Mon Sep 17 00:00:00 2001 From: "Jhonatan S. Reyes C." Date: Sun, 1 Nov 2026 08:14:45 +0000 Subject: [PATCH] feat(statechart): ask before installing mise Upstream's skill assumes mise is installed. Without it, the run fails with "spawn mise ENOENT", and agents then searched the disk, downloaded Java, or installed mise without asking. Before modelling, the agent now checks for mise on PATH or TLA2TOOLS. If neither is there, it asks whether to install mise for the user. It continues on yes and stops with the TLA2TOOLS alternative on no. Upstream's own setup line stays verbatim; the added paragraph is recorded as an adaptation. --- README.md | 2 +- proofs/benny-runtime.json | 12 ++++++------ scripts/check-content.ts | 9 ++++++++- skills/statechart/SKILL.md | 2 ++ upstream.json | 13 +++++++++++-- 5 files changed, 28 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index f21f06b..f7a002d 100644 --- a/README.md +++ b/README.md @@ -201,7 +201,7 @@ The [complete skills reference](./docs/guide/skills.md) lists all 59 discoverabl | [`/statechart`](./skills/statechart/SKILL.md) | Check a TLA+ state model with TLC and draw a Mermaid chart. Mark each state that breaks a rule and give the shortest path to it. | | [`/ketchup-video`](./skills/ketchup-video/SKILL.md) | Catch up with a short subtitled video and waiting decisions. Deliver a file link or attachment when the client cannot embed video. | -The 0.15.36 upstream port replaces the `orch` helper with agent-driven orchestration through native tasks and durable tracker files. `/interrogate` now reports only findings demonstrated by a run and verified by the parent. `/statechart` ships the upstream skill and its tests byte for byte. By default it needs `mise` on `PATH`. mise installs TLC 1.7.4 and Temurin 25 Java when they are missing, which needs network access. Setting `TLA2TOOLS` bypasses mise. Root `tsc` skips `skills/statechart/scripts`, which keeps upstream's own `tsconfig.json`. Video generation uses available rendering tools outside the repository. +The 0.15.36 upstream port replaces the `orch` helper with agent-driven orchestration through native tasks and durable tracker files. `/interrogate` now reports only findings demonstrated by a run and verified by the parent. `/statechart` ships the upstream skill and its tests byte for byte, except one added `SKILL.md` paragraph. Before modelling, the agent checks for `mise` or `TLA2TOOLS` and asks before it installs mise. By default the skill needs `mise` on `PATH`. mise installs TLC 1.7.4 and Temurin 25 Java when they are missing, which needs network access. Setting `TLA2TOOLS` bypasses mise. Root `tsc` skips `skills/statechart/scripts`, which keeps upstream's own `tsconfig.json`. Video generation uses available rendering tools outside the repository. `/session-review` reviews the last 10 sessions in the current workspace. Use `/session-review 25` to select the last 25, or `/session-review 25 --plugin-report` to add a separate, sanitized plugin-feedback section. The bare command rejects invalid counts and flags locally before dispatching a model turn. The `/skill:session-review` alternative is prompt-driven and has no host-side argument gate. The review uses the full available history window, not only the last seven days, and never edits the repository or sends a report elsewhere. Results appear in chat unless you explicitly request a private saved copy. diff --git a/proofs/benny-runtime.json b/proofs/benny-runtime.json index 7c24a50..5ac4ba3 100644 --- a/proofs/benny-runtime.json +++ b/proofs/benny-runtime.json @@ -1,11 +1,11 @@ { "fixture": true, - "capturedAt": "2026-11-01T06:32:33.492Z", + "capturedAt": "2026-11-01T08:14:40.074Z", "actualModel": "openai-codex/gpt-6-astra:high", "fixtureTransports": { - "slack": "http://localhost:35657/api", - "tracker": "http://localhost:44747/graphql", - "github": "localhost:41147" + "slack": "http://localhost:34213/api", + "tracker": "http://localhost:33059/graphql", + "github": "localhost:41821" }, "effectiveBudgets": { "poll_seconds": 45, @@ -46,7 +46,7 @@ ], "trackerIssues": 1, "draftPulls": 1, - "publishedHeadOid": "e7332567212abbbfa2558f5536e1c7f347c8b620", + "publishedHeadOid": "705bf90ab06c605390d2e20f781a9cdcf6aa950b", "sourceThreadPosts": 2, "canaryEligible": true, "producerInputs": [ @@ -83,5 +83,5 @@ "src/trackers/contract.ts", "src/trackers/linear.ts" ], - "producerDigest": "44e0f512a24acc87d85d31c14952cd7437d503a6636eb4b1b982d2a4bb0878ab" + "producerDigest": "75b6b498ac5023395aefac52c385fa6eb64e25c52d09b14b7f2b831abcbf88c1" } diff --git a/scripts/check-content.ts b/scripts/check-content.ts index 8e836b5..fc78cee 100755 --- a/scripts/check-content.ts +++ b/scripts/check-content.ts @@ -340,6 +340,13 @@ const VERIFICATION_CLASSES: VerificationClass[] = [ contract: "Bootstrap-installer removal proven by the native marketplace-install scenario succeeding without it.", authorizesAbsence: true, }, + { + id: "statechart-toolchain-preflight", + pattern: /^skills\/statechart\/SKILL\.md$/, + kind: "pinned-byte/link inspection", + artifacts: ["scripts/check-content.ts"], + contract: "The mise preflight is agent instruction prose. This class checks inventory integrity and links; the ask-then-install behavior is proven by headless OMP sessions recorded in the pull request, not by TLC.", + }, { id: "claude-code-source-only", pattern: /^upstream-only\/(?:harness\/pstack\/.+|scripts\/generate-pstack-harness-trees\.mjs|\.claude-plugin\/marketplace\.json)$/, @@ -1087,7 +1094,7 @@ async function main(): Promise { } else { checkHeader(inv); const digest = inventoryDigest(inv.files); - const pinnedDigest = "b4fd2075c895258d2387583ef69e3c2ec95259717f485183f1fb070eccf4392f"; + const pinnedDigest = "b5d6ae58923e929c15d223472da855201c7660091bee2dbb6e3e6ef63fa7cfb1"; if (digest !== pinnedDigest) { fail(`upstream.json: pinned integrity digest mismatch (computed ${digest}, pinned ${pinnedDigest}) — source rows, targets, modes, or adaptation verification metadata (kind/artifacts) were changed without repinning`); } diff --git a/skills/statechart/SKILL.md b/skills/statechart/SKILL.md index f5a64a8..9a42fb0 100644 --- a/skills/statechart/SKILL.md +++ b/skills/statechart/SKILL.md @@ -20,6 +20,8 @@ Work in a scratch folder outside the repo. Write a TLA+ spec and its config. The The first run installs TLC and Java with mise and needs the network. +Before you write the spec, check that `mise` is on `PATH` or that `TLA2TOOLS` is set. If neither is, ask the user whether to install mise with `curl -fsSL https://mise.run | sh`, which puts it in `~/.local/bin` for their user only. If they agree, install it, add `~/.local/bin` to `PATH`, and continue. If they decline, stop and tell them to set `TLA2TOOLS` to a `tla2tools.jar` they already have, and `JAVA` when `java` is not on `PATH`. Do not search the disk for Java or TLC, and do not download them yourself. + ## Write the spec - Write each rule that the reader agrees to as an INVARIANT. A rule can be about a screen, a result, a stored value, or a message. If the model has no variable for a rule, add the variable. Never weaken a rule to make it hold. diff --git a/upstream.json b/upstream.json index 4d1203f..1cc1d4a 100644 --- a/upstream.json +++ b/upstream.json @@ -47,7 +47,7 @@ "target": "README.md", "mode": "100644", "adaptation": { - "reason": "README identity, editorial voice, credits, and presentation distinguish this independently maintained OMP plugin adaptation from upstream P Stack by Lauren Tan (poteto), link the original source, retain its MIT notice, attribute poteto-mode's style to its creator, point to pinned provenance in upstream.json, and feature original Astra-generated watercolor artwork of Jrecos and OMP robot agents instead of upstream character art.; Install section: /add-plugin pstack replaced with omp plugin marketplace add https://github.com/Jrecos/omp-pstack + omp plugin install omp-pstack@omp-pstack.; 'turns cursor into'/'cursor gives you' reworded to agent/omp; cursor's /loop attributed to omp's built-in /loop.; poteto-agent and Comment Sicko spawn recipes translated to native task agent names; 'substituting generalPurpose' reworded.; 'not shipped here' (cursor-team-kit, /create-skill, /babysit) replaced by a host-adaptations section naming the packaged references omp-deslop.md, omp-control-cli.md, omp-control-ui.md, omp-create-skill.md.; Plan-mode section references omp native plan mode; benny setup path .cursor/automations/benny/ changed to .omp/automations/benny/ and 'point cursor' to 'point the agent'.; Added explicit optional official Spec Kit Feature setup, pinned provenance, and security limits. Pin OMP18.10.2 and link the measured native-capability assessment while preserving original attribution and native installation. Describe statechart as the upstream skill shipped byte for byte, its default mise bootstrap, its root tsc exclusion, and its test-time renderer installs with root fast-check 4.5.3. These source-backed documentation corrections do not claim measured behavioral equivalence.", + "reason": "README identity, editorial voice, credits, and presentation distinguish this independently maintained OMP plugin adaptation from upstream P Stack by Lauren Tan (poteto), link the original source, retain its MIT notice, attribute poteto-mode's style to its creator, point to pinned provenance in upstream.json, and feature original Astra-generated watercolor artwork of Jrecos and OMP robot agents instead of upstream character art.; Install section: /add-plugin pstack replaced with omp plugin marketplace add https://github.com/Jrecos/omp-pstack + omp plugin install omp-pstack@omp-pstack.; 'turns cursor into'/'cursor gives you' reworded to agent/omp; cursor's /loop attributed to omp's built-in /loop.; poteto-agent and Comment Sicko spawn recipes translated to native task agent names; 'substituting generalPurpose' reworded.; 'not shipped here' (cursor-team-kit, /create-skill, /babysit) replaced by a host-adaptations section naming the packaged references omp-deslop.md, omp-control-cli.md, omp-control-ui.md, omp-create-skill.md.; Plan-mode section references omp native plan mode; benny setup path .cursor/automations/benny/ changed to .omp/automations/benny/ and 'point cursor' to 'point the agent'.; Added explicit optional official Spec Kit Feature setup, pinned provenance, and security limits. Pin OMP18.10.2 and link the measured native-capability assessment while preserving original attribution and native installation. Describe statechart as the upstream skill shipped byte for byte except its mise preflight paragraph, its default mise bootstrap, its root tsc exclusion, and its test-time renderer installs with root fast-check 4.5.3. These source-backed documentation corrections do not claim measured behavioral equivalence.", "verification": { "kind": "omp/cli scenario", "artifacts": [ @@ -10793,7 +10793,16 @@ "source": "pstack/skills/statechart/SKILL.md", "blob": "f5a64a8db4b8a5957ac5e76e051b1823cecd4d5e", "target": "skills/statechart/SKILL.md", - "mode": "100644" + "mode": "100644", + "adaptation": { + "reason": "Add one paragraph to Run: before modelling, check for mise on PATH or TLA2TOOLS. When neither is present, ask the user before installing mise with the mise.run installer, continue on yes, and stop with the TLA2TOOLS/JAVA alternative on no. Never search the disk for Java or TLC or download them unasked. Upstream's line about the first run installing TLC and Java with mise is kept verbatim.", + "verification": { + "kind": "pinned-byte/link inspection", + "artifacts": [ + "scripts/check-content.ts" + ] + } + } }, { "source": "pstack/skills/statechart/references/render.md",