Skip to content

feat(models): add planning specialist and explicit model handoff - #80

Merged
vriesd merged 2 commits into
mainfrom
codex/planning-models
Sep 14, 2026
Merged

vriesd merged 2 commits into
mainfrom
codex/planning-models

Conversation

@vriesd

@vriesd vriesd commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

Why

Users can now choose a planning model without changing their coding model. The selected specialist drafts read-only advice. The manager checks and saves the plan, shows the model handoff before approval, and retains implementation authority.

Scope

Add /flow-models for planning and review preferences. Preserve /flow-reviewer and its stored preference key. Rename the internal reviewer-picker helper to model-picker and use a fixed role registry. The new flow-planner agent is disabled by default and permits only read, glob, and grep. A separate execution guard denies its Flow tool calls.

Status distinguishes configured planning/review settings from the latest observed coding model. Observations are process-local, session-scoped, bounded, and cleared on deletion/disposal. Planning guidance uses the specialist for new or revised drafts only, preserves request IDs and evidence obligations, and reports specialist failure without silently changing models.

Prepare version 8.5.0. No release, tag, paid eval, paid canary, or personal configuration change is included.

Tradeoffs

A planning specialist avoids a new manager model-switching state machine. The coding manager still spends tokens checking and integrating its advice. Default planning adds no specialist task. Existing autonomous authority needs no additional approval.

Blast Radius

Touches optional agent configuration, native TUI settings, planning guidance, and descriptive status. AutoDrive and the Session schema are unchanged. The aggregate prompt budget remains unchanged. Separate measured allowances cover the new planner adapter and menu code.

Verification

A generic Poteto code owner implemented the coupled change under exclusive file ownership. An independent reviewer found no blockers. Parent review found and fixed the initial custom-tool permission gap, then verified the final diff. Comment review removed three lines of test narration; no suppressions were added. Custom Poteto profiles and sticky activation hooks were unavailable or unverified.

The parent built the candidate and used pinned OpenCode 1.18.6 with a local synthetic provider. Observed requests were coding, planning child, coding. The native model menu opened planning selection with a synthetic catalog. Provider-free live host smoke passed 22 tests covering enable/reset and actual permissions. All 13 gated replays reproduced. No external model inference or model-quality claim is established by these checks.

Final clean-worktree preflight passed. 1,198 tests passed and one opt-in live smoke skipped. The separate provider-free smoke passed 22 tests. Focused host checks passed 47 tests and package smoke passed. Typecheck, lint, metadata, and build passed.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 14, 2026

Copy link
Copy Markdown

Codex Review Summary

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

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-14T21:27:14.209768Z 79e4dab 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.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 79e4dabdd9

ℹ️ 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".

};
export function modelPreferencePatch(role: FlowModelRole, model: string) {
const setting = FLOW_MODEL_ROLES[role];
return { agent: { [setting.agent]: { options: { [setting.key]: model } } } };

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Avoid treating saved model preferences as agent collisions

When a user saves a planning choice, this patch persists it as agent.flow-planner.options.flowPlanningModel; on the next server load, createConfigHook reads the preference but leaves that reserved entry in config.agent, so applyFlowConfig invokes onCollision and warns that Flow replaced a user-defined flow-planner that should be renamed. Thus normal /flow-models use emits an alarming collision warning on every reload even though the entry is Flow's supported preference storage; recognize or remove the option-only preference entry before collision reporting.

Useful? React with 👍 / 👎.

@vriesd
vriesd merged commit 8ff4ee0 into main Sep 14, 2026
7 checks passed
@vriesd
vriesd deleted the codex/planning-models branch September 14, 2026 21:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants