Skip to content

Fix OpenAI Codex model discovery for RLM subagents - #718

Closed
nickadminroot wants to merge 2 commits into
PrimeIntellect-ai:mainfrom
nickadminroot:fix/codex-discovery-client-version
Closed

Fix OpenAI Codex model discovery for RLM subagents#718
nickadminroot wants to merge 2 commits into
PrimeIntellect-ai:mainfrom
nickadminroot:fix/codex-discovery-client-version

Conversation

@nickadminroot

@nickadminroot nickadminroot commented Aug 6, 2026

Copy link
Copy Markdown

Summary

  • use a dedicated Codex-compatible client version for OpenAI Codex model discovery
  • restore GPT-5.6 Luna, Sol, and Terra to the executable RLM model catalog
  • add a regression test for the discovery URL and Luna visibility

Fixes #639.

Validation

  • npx tsx ../../node_modules/vitest/dist/cli.js --run test/suite/regressions/639-codex-discovery-client-version.test.ts
  • npm run check
  • live Codex catalog request with client_version=0.144.0 returned Luna, Sol, and Terra

Note

Low Risk
Narrow change to the Codex discovery query parameter plus a regression test; no auth, inference, or data-path changes.

Overview
Fixes RLM/subagent model discovery for OpenAI Codex when GPT-5.6 models (e.g. Luna, Sol, Terra) were missing from the executable catalog.

OpenAI Codex’s /models endpoint filters the catalog by client_version, and it expects a Codex CLI semver, not Prime Agent’s app version. The discovery URL now sends client_version=0.144.0 (documented as the first catalog version that advertises GPT-5.6) instead of the agent VERSION.

A regression test asserts the discovery fetch uses 0.144.0 and that findRlmModels can surface a matching Codex model.

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

Note

Fix OpenAI Codex model discovery by pinning client_version to 0.144.0

The Codex catalog gates GPT-5.6 model availability by the Codex CLI semver passed as client_version in the discovery URL. Previously, the agent's own version was used, which caused GPT-5.6 models to be omitted from RLM model discovery. The fix pins client_version to 0.144.0 (the first catalog version advertising GPT-5.6) in model-registry.ts. A regression test in 639-codex-discovery-client-version.test.ts verifies the correct version is sent.

Macroscope summarized 091c2f9.

zhengr pushed a commit to zhengr/prime-agent that referenced this pull request Aug 8, 2026
@sethkarten

Copy link
Copy Markdown
Contributor

Thank you for the report and proposed work. This root cause is now covered by maintainer-owned stacked PR #1164, authored independently from upstream/main.

We did not inspect or reuse this PR's diff, branch, commits, implementation code, or tests; its public description/comments were used only as a bug report. To keep one review surface, this PR is superseded by #1164 and is being closed.

The complete review stack is #1158#1165. It is being left unmerged for human review after CI and review-bot findings are cleared.

@sethkarten sethkarten closed this Aug 10, 2026
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.

RLM excludes OpenAI Codex models because discovery sends Prime Agent version as client_version

2 participants