feat: codex dynamic model catalog from codex debug models + per-model efforts seam #158
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Cloonar/coding-lab!158
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "afk/156"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Codex gets true dynamic model discovery; claude-code stays pinned (drift detection is #157). Implements every decision from the 2026-07-13 grill.
Probe (internal/provider/codex/catalog.go)
Newrunscodex debug modelsonce, synchronously, through the adapter's one-shot exec pattern (exec.CommandContexton CodexBin, same house style aslogin status/logout) — hard 10s timeout (defaultProbeTimeout), stdout capped at 8 MiB. Process-lifetime cache: no TTL, no refresh (nix-pinned binary ⇒ restart is the refresh event).visibility=="list"filter (replaces the pinned-era codex-auto-review slug omission), priority-ascending order — first entry = spawn default, so the bare default becomesgpt-5.6-terraon 0.144.1 — labels fromdisplay_name, per-model efforts in binary order,default_reasoning_levelsanitized to "" when not a member. Effort labels: lab-side map (xhigh → "Extra high") + title-case fallback (ultra→ "Ultra",max→ "Max").fallbackModels/fallbackEfforts) with ONE loud structured Warn; boot log records catalog source (probe vs fallback) and binary version. No status surface, no metric.ProbeModelsexported for the live compat probe; trimmed real 0.144.1 capture committed asinternal/provider/codex/testdata/models-0.144.1.json(same trimming convention as the 0.133.0 fixture).Per-model efforts seam
provider.ModelOption= Option + per-modelefforts+default_effort(wire shape{"value","label","efforts":[…],"default_effort"?});Models() []ModelOption;Efforts()stays the union for the repo/global defaults pickers.internal/instance/credential.go): explicit effort validates against the resolved model's list → 400 on unsupported combos (codex does not clamp — live-verifiedgpt-5.5+ultra400s); stored defaults skip-layer against that list; all-layers-unset fallback = the model's reported default (codex: medium, was first-entry low), first-entry rule kept for providers reporting none (claude).SetCatalogsstays source-compatible,SetModelsadded for per-model scenarios).Composer / API
GET /providersships the enriched models. The composer's effort chip catalogs the selected model; a model switch that invalidates the pick snaps to the new model's default (mirrors the server's skip-layer resolution — with stored defaults present, a still-valid layer wins first, exactly like the spawn path); valid picks are kept. Settings/repo defaults pickers keep the flat union — unchanged UX.Docs
LAB_COMPAT_LIVE=1re-verification set.Verification
CGO_ENABLED=0 go test ./...green;golangci-lint run0 issues;gofmtclean.tsc --noEmit && vite buildgreen.TestCompat_Live_debugModelsProbePASS — probe yields 4 models[gpt-5.6-terra gpt-5.6-luna gpt-5.5 gpt-5.4-mini], 6-effort union incl. Max/Ultra.Closes #156
🤖 Generated with Claude Code
https://claude.ai/code/session_01WKhcbE8KTiAN7LA8xnSS6m
codex debug models+ per-model efforts seamcodex debug models+ per-model efforts seam #156