mirror of
https://github.com/openai/codex.git
synced 2026-11-13 14:46:14 +00:00
Fix first-turn model switching and rollback (#37260)
## Why A model switch on the first turn has no prior turn settings to compare, and rolling that turn back could leave its model instructions in history. ## What changed - Track the model that supplied the session's base instructions so first-turn switches inject the target model's instructions, including the selected personality. - Preserve inherited custom base instructions when starting from an empty fork. - Remove first-turn model-switch developer content during rollback so retries and cold resumes do not retain or duplicate stale instructions. ## Testing Add integration coverage for first-turn switches, personality changes, empty-prefix forks, rollback retries, and cold resume. GitOrigin-RevId: 9df532e9e337521ad3b315b77f8c98e039fb384e
This commit is contained in:
1 parent
82b17bc724
commit
a17da5e6e4
7 files changed
+273
-13
No files matched your search
@@ -729,6 +729,7 @@ impl Session {
|
||||
installation_id,
|
||||
auth_manager.clone(),
|
||||
models_manager.clone(),
|
||||
model_info,
|
||||
exec_policy,
|
||||
tx_event.clone(),
|
||||
agent_status_tx.clone(),
|
||||
|
||||
Reference in new issue
Block a user