Repository navigation
fix: keep session assessments working with ChatGPT token sharing - #196344
jason-allen-oneal wants to merge 2 commits into
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: stale review; fresh review needed. Summary Next step Review history (3 earlier review cycles) |
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
|
Heads-up for coordination: #208733 uses the same |
Related: #175646
What Problem This Solves
Fixes: session assessments fail before inference on ChatGPT token-sharing routes because the observer's internal token and temperature defaults are treated as mandatory limits.
User Impact
The observer can use the selected ChatGPT token-sharing credential without switching runtimes, accounts, endpoints, or billing routes. API-key calls keep the existing sampling limits. Explicit caller-required limits remain strict and are still rejected before inference when unsupported.
Why This Change Was Made
Carry the distinction between preferred internal defaults and required sampling limits through the existing isolated-completion contract. The observer marks its hardcoded defaults as preferred; Codex omits them only after resolving an actual token-sharing credential. Other calls keep strict behavior unless they opt into that intent. This adds no configuration option, new authentication path, or permission bypass.
The dependency contract was re-inspected at Codex
633ab199cfd724aa78013c006b27a2b3d049fc3b(the retained execution proof used the earlier pinned source): the native Responses request does not carry these sampling fields. The existing token-sharing rejection remains in place for strict requests.Evidence
November 11 candidate:
191a6937efd18ff868472e412fcd725ca18b6456, treef70e02fa56e3308eec681a35aa43a72d991c2863. Independent native review found no actionable mechanical-conflict or clock-fixture defect. Both new performance-clock spies use scopedusingresources; dedicated deadline tests retain advancing clocks and verify expiry, cancellation, cleanup and retry budgets. Production deadlines are unchanged. New-head hosted CI remains pending.Current-main integration: merged
ae651f116c7713295d6969b36bb1762ee0196edc, retaining opt-in preferred sampling beside upstream invalid-output classification, fallback deadlines and physical work settlement. Independent review found no conflict-resolution defect. Core and extension types, focused production/test lint, formatting, the test-line allocation check and observer preparation (8 checks) passed. The repaired native API-boundary suite passed 13 checks; the budget/deadline suites passed 31 checks. This is integration verification, not a repeat of the retained real-grant execution.Test-fixture correction: the harness-v2 budget case hit its inherited one-second deadline during cold module loading. The token-budget suite and API-boundary sampling table now use the existing monotonic-clock spy pattern (the API-key fixture likewise hit its inherited five-second deadline during cold loading); the request timeout and production deadline implementation are unchanged. The budget/deadline run passed all 31 checks; deadline behavior remains checked with an advancing clock.
Retained execution proof on original candidate
16d08c5bc9b39a67aa539e2da12a646e98421fec. Real-grant Gateway execution, upgrade receipts, controls and limitations.Actual Gateway + real SIWC grant: four model-written observer assessments during a successful 61.8-second session, then persisted
donestate. OpenClaw/Sol drives ordinary activity; Codex/Luna performs the observer assessments. The real grant was obtained through supported stable sign-in; no production credential was copied and no provider response was mocked in this scenario.Latest-stable upgrade: official npm 2026.11.2 → exact candidate through canonical Doctor migration, same isolated state. Account/profile identity and utility model preserved; retained session ID/provider/model/runtime and transcript payloads match. Ordinary Codex-primary turns hit the same separate prepared-API-key support rejection on both builds; the successful observer scenario uses a new OpenClaw-primary session. This is not an identical primary-workload red/green comparison.
Controls: same real grant + explicit 37-token/temperature-0 limits rejects before native launch. Actual managed Codex 0.164.0 preserves 300/0.2 and 37/0 in two physical TLS WebSocket API-key requests. These controls use the built harness API; API-key credentials/receiver output are synthetic. The artifact discloses the PID-observation limit and all failed setup attempts.
Prior native synthetic proof remains historical evidence. Boundary tests: 13 passed; removing the repair fails only the preferred token-sharing case. Budget propagation: 7 passed; prefix stability: 14 passed. Core typecheck, focused lint/formatting, import inventory and package-boundary compilation passed; exact-head CI was green for the original candidate, not this new integration head.
The original candidate's independent read-only code review found no actionable P0–P2 findings. CLI autoreview was unavailable due to authentication failure; no successful CLI review is claimed.
Owner decision remains open: accept the narrow opt-in advisory contract while keeping omitted-mode callers strict. The evidence does not claim that this decision has been approved.
Real provider inference and Gateway runs above were confined to the isolated proof profile. No production Gateway/configuration change, merge or deployment was performed. Runtime deadline, malformed-output recovery and the separate ordinary Codex support gate are outside this PR.