Preserve compose buffer when using slash commands

Open 💬 0 comments Opened Aug 2, 2026 by myrsaushkin-sudo

What variant of Codex are you using?

CLI

What feature would you like to see?

Problem

When composing a long prompt in the Codex CLI, I sometimes realize that another model would be more appropriate for the task.

At the moment I have to manually copy the current draft before using /model, otherwise I risk losing what I have already written.

This interrupts the workflow, especially when working in a terminal.

Suggested behavior

The compose buffer should be preserved while executing UI-related slash commands.

For example:

  1. Start writing a prompt.
  2. Run /model.
  3. Select another model.
  4. Continue editing the same prompt.

The current draft should not be discarded unless the prompt is actually submitted or explicitly cleared.

Why this is useful

Switching models is a normal part of the workflow. Users often begin writing first and only later decide which model is appropriate.

This would make the CLI feel much more natural and remove the need for manual copy/paste.

Additional information

This applies not only to /model, but to any future UI-related slash commands.

View original on GitHub ↗