Skip to content

Run tool installs without package scripts; show why research stopped and earlier-round usage - #81

Merged
hyperdrivebeep merged 1 commit into
mainfrom
public-20261113b
Nov 12, 2026
Merged

hyperdrivebeep merged 1 commit into
mainfrom
public-20261113b

Conversation

@hyperdrivebeep

Copy link
Copy Markdown
Owner

Three follow-ups to v0.2.0-beta.4.

Tool installs run no package scripts

  • The automatic Codex CLI and Claude Code installs now pass --ignore-scripts, so no install script of those packages or their dependencies runs.
  • Codex needs nothing else. Claude Code's own install script only copies the platform package's claude.exe over a 500-byte placeholder. THOTH now does that copy itself, and only when the integrity npm recorded for both the wrapper and the platform package matches the values pinned in adapters/models/tool_pins.py. Otherwise the install fails and nothing is copied. The copy is written beside the target and swapped in.
  • Checked in an isolated folder against the real packages: codex-cli 0.157.1 and 2.1.284 (Claude Code). Re-running over an existing install leaves the binary unchanged.

Why research stopped

  • Before, a request the person stopped showed "The cancellation reason is not available". Now, when a stop is what cancelled a running request, a stop note is kept under its own key in the research execution journal. The stored operation row is unchanged.
  • thread/read and operation/result/read report USER_STOPPED for that operation, and the result card says "You stopped it yourself" in five languages, on the latest round and on earlier rounds.
  • operation/result/read gets the reason through an injected port, so the general handler does not import research code.
  • Cancellations for other reasons and older records keep their current wording.

Usage on earlier rounds

  • Earlier rounds now show the token usage recorded for them, instead of leaving the line out.
  • Measured thread/read cost: about 500 bytes per round. At 10 rounds the median read went from 203 ms to 243 ms; whether that is noise was not separated.

Validation

  • New tests: 12 for installs, 8 for stop reasons, plus earlier-round usage and screen tests.
  • Mutations: the implementer ran 16, and the reviewer added 2 (drop the platform integrity check; record a stop for any cancel). All were caught.
  • Run locally: fast suite (all), 29 integration files that touch these paths, vitest for the changed screens, tsc, eslint, prettier, ruff check and format, architecture checks. Type check showed no new diagnostics in the changed files.
  • The full integration suite runs here.

…and earlier usage

The Codex and Claude Code installs now pass --ignore-scripts. Claude Code's
own install script only copies the platform binary over a placeholder, so
THOTH does that copy itself, and only when the integrity npm recorded for the
wrapper and platform packages matches the values pinned in tool_pins.py.

A research request the person stopped now records that fact, and the result
card says "You stopped it yourself" instead of "reason not available", on the
latest round and on earlier rounds. Cancellations for other reasons and older
records are unchanged.

Earlier rounds now show the token usage recorded for them.
@hyperdrivebeep
hyperdrivebeep merged commit 719f616 into main Nov 12, 2026
22 checks passed
@hyperdrivebeep
hyperdrivebeep deleted the public-20261113b branch November 12, 2026 19:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant