Centralize context update diffing logic#11807
Conversation
9566998 to
42697af
Compare
|
@codex review this |
|
Codex Review: Didn't find any major issues. Delightful! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
65b18b9 to
007e72a
Compare
|
@codex review this |
|
Codex Review: Didn't find any major issues. 👍 ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
ed02fd0 to
37ae399
Compare
|
@codex review this |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 37ae399a74
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review this |
|
Codex Review: Didn't find any major issues. Keep it up! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
This PR centralizes model-visible state diffing for turn context updates into one module, while keeping existing behavior and call sites stable.
What changed
core/src/context_updates.rswith the consolidated diffing logic for:BuildSettingsUpdateItemsParamsso required dependencies are passed explicitly.Session::build_settings_update_itemsincore/src/codex.rsto delegate to the centralized module.personality_message_forhelper from initial-context assembly to avoid duplicated logic.core/src/lib.rs.Why
This is a minimal, shippable step toward the model-visible-state design: all state diff decisions for turn-context update items now live in one place, improving reviewability and reducing drift risk without expanding scope.
Behavior
Testing
Ran targeted tests in this worktree:
cargo test -p codex-core build_settings_update_items_emits_environment_item_for_network_changescargo test -p codex-core collaboration_instructions --test allBoth passed.
Codex author
codex resume 019c540f-3951-7352-a3fa-6f07b834d4ce