rowboat/apps/x/packages
Ramnique Singh 6c5324eeac feat: ChatGPT subscription (codex) models — provider, model list, composer wiring
Adds the model-call half of "Use your ChatGPT subscription": a new
credential-less "codex" provider flavor (like "rowboat") that runs calls
against the Codex backend using the OAuth session from chatgpt-auth.

- core/models/codex.ts: AI SDK OpenAI provider in Responses mode. A
  wrapLanguageModel middleware injects providerOptions.openai.store=false
  on every call so the SDK emits full self-contained items (text +
  reasoning with encrypted_content) instead of item_reference entries the
  stateless backend 404s. A wire-level fetch wrapper adds auth
  (bearer + chatgpt-account-id) and Cloudflare headers (originator), and
  backstops the contract: store:false, stream forced with SSE aggregation
  for non-streaming callers, max_output_tokens dropped, encrypted-
  reasoning include, friendly usage-limit errors
- live model discovery via /codex/models, gated by client_version
  (mirrored from the local codex CLI's models_cache.json so the catalog
  matches what `codex` shows); visibility "hide" utility models filtered;
  display names carried through; hardcoded fallback list for offline
- createProvider/resolveProviderConfig/mapReasoningEffort codex cases
- models:list merges the "OpenAI Codex" catalog while signed in with
  ChatGPT; chatgpt:statusChanged push event on sign-in/out
- composer picker shows the group gated on the session and refreshes on
  status changes

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-17 17:23:57 +05:30
..
core feat: ChatGPT subscription (codex) models — provider, model list, composer wiring 2026-07-17 17:23:57 +05:30
shared feat: ChatGPT subscription (codex) models — provider, model list, composer wiring 2026-07-17 17:23:57 +05:30