feat(chat): persist safe Codex next-turn model selection
This commit is contained in:
Vendored
+26
@@ -0,0 +1,26 @@
|
||||
# Codex model protocol fixtures
|
||||
|
||||
These use synthetic models/providers, never guessed production identifiers.
|
||||
Wire shapes were checked against the official app-server documentation and the
|
||||
generated protocol source matching the installed package manifest (Codex 0.163.0):
|
||||
|
||||
- https://developers.openai.com/codex/app-server
|
||||
- https://github.com/openai/codex/blob/rust-v0.163.0/codex-rs/app-server-protocol/schema/typescript/v2/ModelListResponse.ts
|
||||
- Same directory: `ModelListParams.ts`, `Model.ts`, `Thread.ts`, `ThreadStartResponse.ts`, `TurnStartParams.ts`.
|
||||
|
||||
`Model.model` is the turn override, not the catalog row's opaque `id`.
|
||||
`Thread.model` is current configured/latest persisted metadata, not per-turn
|
||||
execution telemetry. `thread/start` also returns model/provider at the top level.
|
||||
The fixtures project fields consumed by this adapter and retain real casing and
|
||||
pagination shapes. Tests use an isolated fake WebSocket JSON-RPC server.
|
||||
|
||||
Local `codex --version` timed out before output, so schema generation was not reached;
|
||||
the installed `codex-package.json` identified version 0.163.0, so version-tagged
|
||||
generated source was read instead. No live app-server socket was contacted.
|
||||
|
||||
Model selection validates via `thread/read` + `model/list`, persists a Pipelines
|
||||
next-turn choice, and supplies `turn/start.model` only when the user sends a
|
||||
prompt. It never calls `thread/resume`, which can awaken a queued goal, nor any
|
||||
configuration-writing API. The acknowledgement means "saved for the next turn,"
|
||||
not "remote settings changed." The override is supplied again after a Pipelines
|
||||
restart; an already-running turn is not reconfigured.
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"data":[{"id":"opaque-picker-id","model":"fixture-model","displayName":"Fixture Model","description":"Test catalog only","hidden":false,"upgrade":null,"upgradeInfo":null,"availabilityNux":null,"modelSpecialty":null,"supportedReasoningEfforts":[{"reasoningEffort":"medium","description":"Fixture effort"}],"defaultReasoningEffort":"medium","inputModalities":["text","image"],"supportsPersonality":false,"multiAgentVersion":null,"additionalSpeedTiers":[],"serviceTiers":[],"defaultServiceTier":null,"availableAccessPrograms":null,"isDefault":true}],"nextCursor":"page-two"}
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"thread":{"id":"01900000-0000-7000-8000-000000000001","name":"Fixture chat","preview":"Fixture","cwd":"/fixture","model":"fixture-current","modelProvider":"fixture-provider","createdAt":1,"updatedAt":2,"status":{"type":"notLoaded"},"turns":[]}}
|
||||
Reference in New Issue
Block a user