Skip to content

Add experimental prediction forks that inherit parent context - #51884

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/46b41f2ac331562b441dadff1a0a9f926c94880d
Oct 8, 2026
Merged

copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/46b41f2ac331562b441dadff1a0a9f926c94880d

Conversation

@copyberry

@copyberry copyberry Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Add experimental prediction forks that inherit parent context

Why

Prediction forks need to preserve the parent's effective context and request settings to maximize prompt-cache reuse.

What changed

  • Add experimentalPredictionMode to thread/fork for ephemeral forks of loaded, persisted parents. Reject configuration overrides, path, lastTurnId, and beforeTurnId in this mode.
  • Inherit the parent's effective configuration, tools, environments, collaboration settings, disabled plugins, and persisted history.
  • Enable features.reasoning_effort_override on the fork while preserving the parent's request-effort baseline, including when overrides were disabled on the parent.
  • Report the fork's effective model, service tier, and reasoning effort in the response.

Testing

Add coverage for matching parent and fork requests and prompt-cache keys across legacy and paginated history, invalid fork parameters, and reasoning-effort inheritance. Add a context snapshot for identical parent and fork continuations.

## Why

Prediction forks need to preserve the parent's effective context and request settings to maximize prompt-cache reuse.

## What changed

- Add `experimentalPredictionMode` to `thread/fork` for ephemeral forks of loaded, persisted parents. Reject configuration overrides, `path`, `lastTurnId`, and `beforeTurnId` in this mode.
- Inherit the parent's effective configuration, tools, environments, collaboration settings, disabled plugins, and persisted history.
- Enable `features.reasoning_effort_override` on the fork while preserving the parent's request-effort baseline, including when overrides were disabled on the parent.
- Report the fork's effective model, service tier, and reasoning effort in the response.

## Testing

Add coverage for matching parent and fork requests and prompt-cache keys across legacy and paginated history, invalid fork parameters, and reasoning-effort inheritance. Add a context snapshot for identical parent and fork continuations.

GitOrigin-RevId: 46b41f2ac331562b441dadff1a0a9f926c94880d
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/46b41f2ac331562b441dadff1a0a9f926c94880d branch from eba2650 to ec8251c Compare October 8, 2026 00:09
@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review 🔄 Running since 2026-10-08T00:09:14.716805Z eba2650 PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@copyberry
copyberry Bot merged commit ec8251c into main Oct 8, 2026
1 check failed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/46b41f2ac331562b441dadff1a0a9f926c94880d branch October 8, 2026 00:09
@github-actions

github-actions Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor


Thank you for your submission, we really appreciate it. Like many open-source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just posting a Pull Request Comment same as the below format.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot.

@github-actions github-actions Bot locked and limited conversation to collaborators Oct 8, 2026
@icemanLv99
icemanLv99 deployed to issue-triage October 8, 2026 00:16 — with GitHub Actions Active
@icemanLv99
icemanLv99 deployed to issue-triage October 8, 2026 00:16 — with GitHub Actions Active
@icemanLv99
icemanLv99 deployed to issue-triage October 8, 2026 00:16 — with GitHub Actions Active
@ericlitman
ericlitman deployed to issue-triage October 8, 2026 00:19 — with GitHub Actions Active
@ericlitman
ericlitman deployed to issue-triage October 8, 2026 00:19 — with GitHub Actions Active
@ericlitman
ericlitman deployed to issue-triage October 8, 2026 00:19 — with GitHub Actions Active
@ericlitman
ericlitman deployed to issue-triage October 8, 2026 00:20 — with GitHub Actions Active
@solankydev
solankydev deployed to issue-triage October 8, 2026 00:35 — with GitHub Actions Active
@solankydev
solankydev deployed to issue-triage October 8, 2026 00:35 — with GitHub Actions Active
@solankydev
solankydev deployed to issue-triage October 8, 2026 00:35 — with GitHub Actions Active
@solankydev
solankydev deployed to issue-triage October 8, 2026 00:36 — with GitHub Actions Active
@saslifat-gif
saslifat-gif deployed to issue-triage October 8, 2026 00:42 — with GitHub Actions Active
@saslifat-gif
saslifat-gif deployed to issue-triage October 8, 2026 00:42 — with GitHub Actions Active
@saslifat-gif
saslifat-gif deployed to issue-triage October 8, 2026 00:42 — with GitHub Actions Active

This branch was successfully deployed

1 active deployment
issue-triage — ec8251c5 Deployed Oct 8, 2026 by saslifat-gif via Translate non-English issue #18229
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants