Repository navigation
feat(eval): workspace-root seam (#49) — deterministically root a persona's hands at a target repo before her cycle - #1947
Merged
Conversation
…ona's hands at a target repo before her cycle
The last gate on the Hermes-beating SWE-bench matrix. `--solver ours` produced a 0-byte diff because the
eval-fork persona's file engine defaulted to the core cwd (std::env::current_dir()), and the "she calls
create-workspace herself" prompt didn't reliably reroot it — a false ZERO that lied about the solver.
Fix (opt-in, regression-safe): `CognitionEvalParams.workspace_root: Option<String>` (None → unchanged for every
existing path). When set, cognition/eval runs `code/create-workspace` through the persona's OWN identity-bearing
executor (cycle.acting().executor) BEFORE her cycle. create-workspace keys on caller identity, so this reroots
the fork's hands at the repo — her edits land in the clone, deterministically, with NO reliance on the model
choosing to call create-workspace itself. Fails LOUD if requested-but-unroutable (a silent no-root would score a
false zero). Mirrors load_harness's exact tool/ctx/execute_native_batch pattern.
VALIDATED live: eval with --workspace_root <clone> + a "write SEAM_PROOF.txt" task → the file landed IN THE CLONE
(content "ROOTED"), NOT the core cwd. Her hands now sit exactly where Claude-as-agent sat when solving flask-4045
by hand → RESOLVED. run_ours.py updated to pass --workspace_root (drops the model-self-call directive).
This unblocks the local-model × {ours,opencode,raw} × SWE-bench matrix — the actual "can we beat Hermes" number.
[[fallbacks-are-illegal-fail-loud]] [[eval-mutates-persona-lift-needs-isolation]]
Co-Authored-By: Claude Opus 4.8 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The last gate on the Hermes-beating SWE-bench matrix.
--solver oursproduced a 0-byte diff because theeval-fork persona's file engine defaulted to the core cwd (std::env::current_dir()), and the "she calls
create-workspace herself" prompt didn't reliably reroot it — a false ZERO that lied about the solver.
Fix (opt-in, regression-safe):
CognitionEvalParams.workspace_root: Option<String>(None → unchanged for everyexisting path). When set, cognition/eval runs
code/create-workspacethrough the persona's OWN identity-bearingexecutor (cycle.acting().executor) BEFORE her cycle. create-workspace keys on caller identity, so this reroots
the fork's hands at the repo — her edits land in the clone, deterministically, with NO reliance on the model
choosing to call create-workspace itself. Fails LOUD if requested-but-unroutable (a silent no-root would score a
false zero). Mirrors load_harness's exact tool/ctx/execute_native_batch pattern.
VALIDATED live: eval with --workspace_root + a "write SEAM_PROOF.txt" task → the file landed IN THE CLONE
(content "ROOTED"), NOT the core cwd. Her hands now sit exactly where Claude-as-agent sat when solving flask-4045
by hand → RESOLVED. run_ours.py updated to pass --workspace_root (drops the model-self-call directive).
This unblocks the local-model × {ours,opencode,raw} × SWE-bench matrix — the actual "can we beat Hermes" number.
[[fallbacks-are-illegal-fail-loud]] [[eval-mutates-persona-lift-needs-isolation]]
Co-Authored-By: Claude Opus 4.8 [email protected]
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo