Skip to content

feat(codex): opt-in full Responses lane (CCP_CODEX_FULL_LANE) and gpt-6.1-terra support - #9

Merged
gongx030 merged 3 commits into
mainfrom
ccp-7-full-lane-terra
Nov 12, 2026
Merged

gongx030 merged 3 commits into
mainfrom
ccp-7-full-lane-terra

Conversation

@gongx030

Copy link
Copy Markdown
Owner

Adds an opt-in "full Responses lane" for the Codex provider and accepts gpt-6.1-terra as a top-level model. With CCP_CODEX_FULL_LANE=1 (or codex.fullLane: true), Sol, Terra and Astra requests go to the full Responses lane and keep parallel_tool_calls; with it off (the default, and CCP_CODEX_FULL_LANE=0 as an explicit opt-out that beats the config file) Sol stays on Lite as today. Luna always stays on Lite.

Closes #7

Which implementation was ported, and why

Three existing implementations were compared:

  • Fork branch feat/codex-full-lane (9e52b7e, 7c39e10): changes the public helper to uses_responses_lite(model, full_lane), breaking every call site and a later upstream merge; has no terra and no lane tests.
  • Fork branch feat/gpt-6.1-terra (5931b29): adds terra to the allowlist, registry and Lite family, stacked on that two-argument signature. Its terra additions are reused here.
  • Upstream v0.1.48 (adbec95): keeps uses_responses_lite(model) unchanged and adds uses_responses_lite_with_full_lane(model, full_lane), with the setting read once per handler and passed explicitly (hermetic tests). It adapts both fork commits, so it is the superset.

adbec95 cannot be cherry-picked: it sits on 61 upstream commits this fork lacks (model catalog, safety work) and conflicts in mod.rs, native.rs and the codex docs. This PR hand-ports its semantics (cited in the commit body), so a later upstream merge should be trivial and the fork carries no duplicate feature.

Design choices settled

  • Two-function API as upstream (no public signature break).
  • /v1/chat/completions also honors the setting (upstream left it on the default lane); one-line revert if strict parity is wanted.
  • Explicit allowlist of six full-lane-eligible models, as upstream.
  • CCP_CODEX_FULL_LANE=0 is the opt-out; env wins over the config file.
  • The catalog test from upstream is skipped (no catalog on the fork).
  • gpt-6.1-terra added to the Terra diagnostics bucket (one line).

Behavior of #5 (thread-cache diagnostics), #6 (ToolSearch deferred tools) and #8 (auto-review classifier: low effort, no reasoning summary/include, guardian:<session> cache key) is unchanged; the ToolSearch goldens stay byte-identical (their test helper now takes an explicit lane flag because terra moved into the Lite family in the first commit).

Tests (all offline)

  • Allowlist/registry//v1/models accept sol and terra (with -fast): fails on the base commit by assertion.
  • full_lane_covers_all_lite_models_except_luna, full_lane_translation_preserves_parallel_tool_restrictions, native_full_lane_preserves_parallel_choice_and_luna_remaps: lane routing and parallel_tool_calls.
  • auto_review_classifier_keeps_guardian_defaults_on_both_lanes; classifier_translation_defaults_preserve_normal_bodies extended with terra.
  • codex_full_lane_defaults_off_reads_config_and_env_takes_precedence.
  • Full suite (fmt, clippy -D warnings, cargo test --locked) green on the pushed head.

Review: /code-review high; 2 findings applied (stale doc comment, changelog), 6 dismissed. Residual risk of the opt-in: the native /v1/responses passthrough forwards the client's own body under full-lane headers, which can only be confirmed against the real provider.

🤖 Generated with Claude Code

gongw13-arch and others added 3 commits November 11, 2026 23:18
Add gpt-6.1-terra (and its -fast alias) to the Codex model allowlist,
the registry routing list and the Responses Lite family, so the server
accepts and lists it like gpt-6.1-sol. Tests cover the allowlist,
registry routing and the /v1/models listing; they failed before this
change because the model was rejected.

Refs #7

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
CCP_CODEX_FULL_LANE=1 (or codex.fullLane: true) sends gpt-5.6-sol,
gpt-5.6-terra, gpt-6-astra, gpt-6-sol, gpt-6.1-sol and gpt-6.1-terra to
the full Responses lane so parallel function calls are kept; =0 opts out
and the environment overrides the config file. Luna stays on Lite and
hosted web search still remaps to the full lane. Default behavior is
unchanged.

This is a hand port of upstream raine/claude-code-proxy adbec95
(two-function API: uses_responses_lite is unchanged and
uses_responses_lite_with_full_lane takes the flag explicitly, so tests
are hermetic). It cannot be cherry-picked: it sits on 61 upstream commits
this fork lacks, so it conflicts in mod.rs, native.rs and the codex docs.
It supersedes origin/feat/codex-full-lane (which changed the helper
signature) and reuses the terra additions of origin/feat/gpt-6.1-terra.
The chat-completions route also honors the setting. Auto-review
classifier defaults (low effort, guardian-scoped cache key), ToolSearch
and thread-cache diagnostics are unchanged; tests cover both lanes.

Refs #7

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Release notes omitted the opt-in fullLane setting and gpt-6.1-terra, and the
apply_model_lane_for_request doc described only the web_search path, not the
full_lane flag or Luna staying on Lite.

Refs #7

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@gongx030
gongx030 merged commit cbe72f9 into main Nov 12, 2026
@gongx030
gongx030 deleted the ccp-7-full-lane-terra branch November 12, 2026 07:35
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.

codex: fork main lacks the fullLane / CCP_CODEX_FULL_LANE opt-in that the SDK sets on spawn

2 participants