core: defer fork context injection to first turn#15442
core: defer fork context injection to first turn#15442charley-oai wants to merge 3 commits intocc/fork-startup-context-snapshotfrom
Conversation
0f137ef to
9e1a4a6
Compare
b4253cc to
f4a3419
Compare
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
codex/codex-rs/core/src/codex.rs
Lines 2165 to 2167 in f4a3419
By removing fork-time build_initial_context injection, a fork that reconstructs a reference_context_item now enters first turn on the diff path only. That diff builder emits permissions/model/collab/realtime/personality/env updates, but not developer_instructions/user_instructions. If fork config or cwd changes those (e.g., different AGENTS/profile), the first request keeps stale source-thread instructions.
ℹ️ 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".
320a845 to
7464ec0
Compare
Co-authored-by: Codex <[email protected]>
f4a3419 to
c4c1e4a
Compare
Clear the model-visible reference baseline after fork reconstruction so the first real turn in the fork emits full initial context under the new session config. Co-authored-by: Codex <[email protected]>
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c4e466b8dc
ℹ️ 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".
Fork startup no longer appends extra context items, so double-fork rollout tests should compare against the exact truncated rollout instead of expecting a longer prefix. Co-authored-by: Codex <[email protected]>
|
Closing this follow-up for now; we'll revisit reliable diffing later. |
Summary
Testing