Repository navigation
feat(headless): allow OPENCODE_CONFIG override for prompt ablation arms - #1855
Merged
Merged
Conversation
Add MAKA_OPENCODE_CONFIG_PATH so a harness A/B arm can point OpenCode at an alternate benchmark config without shadowing MAKA_REPO_ROOT, and add opencode-benchmark-makaprompt.json whose only delta is agent.build.prompt set byte-identically to DEFAULT_HEADLESS_SYSTEM_PROMPT (config-level prompt fully replaces the built-in default in opencode v1.17.18).
…fig provenance Review follow-ups for the ablation seam: - probe the resolved OPENCODE_CONFIG with sha256sum before launch so a mistyped MAKA_OPENCODE_CONFIG_PATH aborts the cell instead of silently running OpenCode's built-in default (wrong arm) - record opencodeConfigPath/opencodeConfigHash in the cell execution identity so A/B arms are distinguishable and auditable from artifacts - pin the single-variable invariant with a full-object contract test: opencode-benchmark-makaprompt.json must equal the benchmark config plus only agent.build.prompt
Astro-Han
force-pushed
the
feat/headless-opencode-config-path
branch
from
August 1, 2026 18:37
9cc1d08 to
e010dad
Compare
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.
Summary
Enables the OpenCode-side prompt-ablation A/B (TB2.1: does Maka's 4-line headless system prompt explain part of the pass-rate gap vs OpenCode 1.17.18?) without forking the pinned toolchain:
MAKA_OPENCODE_CONFIG_PATHenv override inopencode_agent.py, so one harness A/B arm can pointOPENCODE_CONFIGat an alternate benchmark config. Default path and behavior are unchanged when unset.packages/headless/harbor/opencode-benchmark-makaprompt.json: byte-identical copy ofopencode-benchmark.jsonplusagent.build.promptset toDEFAULT_HEADLESS_SYSTEM_PROMPT. In opencode v1.17.18 (session/llm/request.ts), a config-level agent prompt fully replacesSystemPrompt.provider(model); the environment block still appends identically in both arms.Experiment plan (local, git-excluded):
maka-eval/experiments/harness-ab/terminal-bench-2.1/maka-internal-ablation-plan-20260801.md— the OpenCode-prompt leg runsopencode-originalvsopencode-maka-promptsame-round paired on a death-mode-stratified task set.Verification
npm run test --workspace packages/headless: pass (fail 0). New coverage: adapter smoke assertsOPENCODE_CONFIGhonors the override; a contract test pins the ablation config's provider section equal to the baseline and its prompt byte-identical toDEFAULT_HEADLESS_SYSTEM_PROMPT.npm run lint: clean.npm run format: applied.