mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:31:09 +00:00
Derive collaboration settings from turn context (#32900)
## Why `TurnContext` stored model and reasoning settings both as resolved turn fields and inside `CollaborationMode`, requiring the copies to stay synchronized when the model changed. ## What changed - Store the mode and collaboration-mode developer instructions directly on `TurnContext`. - Reconstruct `CollaborationMode` from those values plus the turn's current model and reasoning effort when callers need it. - Read the mode directly for plan-mode checks, lifecycle events, and telemetry. GitOrigin-RevId: b8fccafdd5d5cbccc84bc70d542588087ddf0093
This commit is contained in:
1 parent
75470c3e2f
commit
4657ab06c6
16 files changed
+58
-41
No files matched your search
@@ -81,7 +81,7 @@ impl PlanHandler {
|
||||
}
|
||||
};
|
||||
|
||||
if turn.collaboration_mode.mode == ModeKind::Plan {
|
||||
if turn.mode == ModeKind::Plan {
|
||||
return Err(FunctionCallError::RespondToModel(
|
||||
"update_plan is a TODO/checklist tool and is not allowed in Plan mode".to_string(),
|
||||
));
|
||||
|
||||
Reference in new issue
Block a user