Skip to content

fix: preserve Slides model routing across nested agents#81

Merged
nicko-ai merged 2 commits into
mainfrom
codex/slides-internal-model-routing-fix
Jul 26, 2026
Merged

fix: preserve Slides model routing across nested agents#81
nicko-ai merged 2 commits into
mainfrom
codex/slides-internal-model-routing-fix

Conversation

@nicko-ai

Copy link
Copy Markdown
Collaborator

Summary

Fix Slides generation when nested planner and HTML-writer agents use an inherited or non-default model.

The previous implementation duplicated model setup across Insert and Modify flows. It could ignore RunConfig.model, select an unrelated fallback, and classify generic OpenAI-compatible endpoints as Codex Responses. That could produce failed or empty Slides output.

Changes

  • Add one shared model-resolution and transport helper for both Slides tools.
  • Resolve the request model first, then the caller model or wrapper, then the default.
  • Use Responses only for verified Codex endpoints.
  • Preserve direct OpenAI, compatible Chat Completions, OpenRouter, LiteLLM, Ollama, wrapper credentials, and request-level model overrides.
  • Recover streamed text when the structured final response is empty.
  • Add focused regression coverage for both Insert and Modify flows.

Validation

  • Focused Slides tests: passed
  • Ruff lint and focused formatting: passed
  • Python compilation check: passed
  • Git diff checks: passed
  • Independent review: clean

Remaining acceptance

Hosted checks will run on this PR. A credentialed live gpt-5.4-mini Insert and Modify flow is still required before merge.

This replaces the current-main-relevant parts of #68 without carrying forward its stale and conflicting changes.

nicko-ai added 2 commits July 24, 2026 04:06
- inherit request and caller model wrappers in Slides planner and writer\n- route only verified Codex browser auth through Responses streaming\n- keep generic compatible, OpenRouter, LiteLLM, and Ollama transports intact\n- recover non-empty structured text from streamed helper output
@nicko-ai
nicko-ai marked this pull request as ready for review July 26, 2026 01:15
@nicko-ai
nicko-ai merged commit ca0aeb2 into main Jul 26, 2026
1 check passed
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.

1 participant