Skip to content

eval(harbor): forward stored API keys into the task container - #756

Merged
ericleepi314 merged 1 commit into
mainfrom
eval/forward-api-keys
Jul 26, 2026
Merged

eval(harbor): forward stored API keys into the task container#756
ericleepi314 merged 1 commit into
mainfrom
eval/forward-api-keys

Conversation

@ericleepi314

Copy link
Copy Markdown
Collaborator

WebSearch resolves TAVILY_API_KEY through get_secret(), which reads the env block of the global config (src/tool_system/tools/web_search.py:124). The adapter seeded only settings.effort into the container's ~/.clawcodex/config.json, so that block was absent and every WebSearch call failed with "Web search is not configured" — on terminal-bench 2.1 tasks needing a lookup, the agent could not do it at all.

_seed_container_settings now also writes the host config's env block. Values travel through the exec ENV, never the command string, so they stay out of process listings and Harbor's trial logs. Opt out with --ak forward_keys=false.

This is a capability, not guidance — a distinction that matters for the comparison the eval exists to make. Instructions given to one agent and not the other (the deadline injection removed in #751) skew trajectories and wouldn't exist on a scored run. Key material doesn't: Harbor's built-in claude-code agent likewise runs with its own credentials available, and a harness that can't reach a tool it ships is measuring the wrong thing.

Verified: reads the host key, forward_keys=false opts out, both adapters import under Harbor's interpreter.

🤖 Generated with Claude Code

WebSearch resolves TAVILY_API_KEY through get_secret(), which reads the
"env" block of the global config (src/tool_system/tools/web_search.py:124).
The adapter seeded only settings.effort into the container's
~/.clawcodex/config.json, so that block was absent and every WebSearch call
failed with "Web search is not configured" -- on terminal-bench 2.1 tasks
that need a lookup, the agent simply could not do it.

_seed_container_settings now also writes the host config's "env" block.
Values travel through the exec ENV, never the command string, so they stay
out of process listings and Harbor's trial logs. Opt out with
--ak forward_keys=false.

This is a capability, not guidance. The distinction matters for the
comparison the eval exists to make: instructions given to one agent and not
the other (the deadline injection removed in #751) skew trajectories and
would not exist on a scored run. Key material does not -- Harbor's built-in
claude-code agent likewise runs with its own credentials available, and a
harness that cannot reach a tool it ships is measuring the wrong thing.
@ericleepi314
ericleepi314 merged commit 95969a7 into main Jul 26, 2026
2 checks passed
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