Skip to content

[v0.8 replacement 1/5] add Prime Agent harness on current main - #2324

Open
sethkarten wants to merge 7 commits into
mainfrom
v080/main-replacement-prime-harness
Open

[v0.8 replacement 1/5] add Prime Agent harness on current main#2324
sethkarten wants to merge 7 commits into
mainfrom
v080/main-replacement-prime-harness

Conversation

@sethkarten

@sethkarten sethkarten commented Aug 11, 2026

Copy link
Copy Markdown

Replacement stack

Node 1/5 in a fresh append-only v0.8 replacement chain rooted at authoritative main commit c2820d3679e6318f9c3d0155c823d6908b4e1faa.

  • Base branch: main
  • Head branch: v080/main-replacement-prime-harness
  • Exact head: f4a32c192fd9dabefe6938e36b6893bf86f9e49c

Scope

Exact coherent #2285 Prime Agent harness/test delta: 12 paths; no dependency or lockfile changes.

The old contributor PR branches remain untouched. This branch was published non-force from a fresh owned repository. Independent Luna semantic review APPROVED the full N1→N5 chain and found no structural scope leakage; authoritative-main renderer provenance is retained and pyproject.toml / uv.lock are unchanged across replacement nodes.

Warning

TEST BLOCKED — do not merge or mark ready. Authoritative c2820d has a stale uv.lock relative to pyproject.toml. A disposable uv sync --locked correctly refused before tests, without changing repository files. The only previously approved interpreter also cannot import current main because pydantic_config is absent. Testing/remediation continues on GitHub; this draft does not claim green.

No live, hosted, Docker, sandbox, model, or paid evaluation was run.

Note

Add Prime Agent harness for running agents via ACP with persistent IPython kernel support

  • Adds PrimeAgentHarness in harness.py that installs and runs Prime Agent via ACP, supporting both one-shot and live-session modes with a persistent IPython kernel across turns.
  • Includes install.sh, a shell script that pins and verifies uv, Node.js (22.8+), and the Prime Agent tarball via SHA-256, with Alpine/musl support.
  • ACPHarnessSession gains an on_error callback so harnesses can attach daemon log diagnostics to untyped errors while preserving typed RolloutError exceptions.
  • Adds four e2e test fixtures and tests covering: IPython cell execution shape, kernel state persistence across turns, provider failure propagation, and GSM8K task solving.
  • Risk: the harness manages per-trace directories, daemon processes, and flock-guarded installs — cleanup failures retain state and raise errors rather than silently continuing.

Macroscope summarized 7e3bfc4.


Note

Medium Risk
Large new harness plus a shared ACP session error-path change; carefully preserves typed rollout errors, but install/runtime behavior and live-process semantics are infra-sensitive.

Overview
Adds a Prime Agent harness that runs the agent through native ACP with a persistent live session (one IPython kernel across turns), pinned install/setup, daemon diagnostics, and careful cleanup.

Extends shared ACPHarnessSession with an optional on_error callback so turn failures can attach daemon logs without replacing typed RolloutErrors (or masking cancellation).

Adds prime_agent-marked Docker e2e coverage for kernel persistence, verbatim IPython cell execution, GSM8K scoring, and provider-failure surfacing, plus deterministic unit guards for install/cleanup/error and unix socket path limits.

Reviewed by Cursor Bugbot for commit 7e3bfc4. Bugbot is set up for automated code reviews on this repo. Configure here.

Comment thread verifiers/v1/harnesses/prime_agent/harness.py Outdated
Comment thread verifiers/v1/harnesses/prime_agent/harness.py Outdated
@sethkarten
sethkarten marked this pull request as ready for review August 12, 2026 06:18
Comment thread tests/v1/fixtures/prime_agent_persistence_v1.py
Comment thread verifiers/v1/harnesses/prime_agent/harness.py
@macroscopeapp

macroscopeapp Bot commented Aug 12, 2026

Copy link
Copy Markdown

Approvability

Verdict: Needs human review

1 blocking correctness issue found. This PR introduces a substantial new Prime Agent harness with ~700+ lines of new implementation code, modifications to core ACP infrastructure for error callbacks, and daemon lifecycle management. New feature additions of this scope warrant human review to verify the design and integration approach.

You can customize Macroscope's approvability policy. Learn more.

Comment thread verifiers/v1/acp/__init__.py

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit dca0477. Configure here.

Comment thread verifiers/v1/acp/__init__.py
@sethkarten
sethkarten requested a review from hallerite August 13, 2026 01:25
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