You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feat: Support streaming all outputs and also support passing history with -q #118
I want to propose a few cli options for non-interactive mode (-q):
--history - pass a message history for non-interactive mode to continue working
--stream - stream all outputs (not just the final output) from non-interactive mode.
If a user runs an initial command with -q (or -j), then gets all the message history from stdout, then they could pass that information back to another -q / -j call in order to incrementally work with the LLM. This is similar to interactive mode, but it also allows non-interactive consumers to pass message history properly in the standard openai message format.
There's another potential command around history that may be useful purely for the interactive CLI --save-history. Essentially it would store chat history in ~/.codex/chats. This would allow a user to restart an interactive session with a previous history by using --load-history ~/.codex/chats/chat-1.json without losing the intermediate messages & context.
Reacted by 成熟苦瓜, Ryan Young, Akshat Giri , Roland Gadinger, cvzakharchenko and Murzin Artem
#146 and #341 both appear related to this. It looks like sessions are already stored to ~/.codex/sessions/rollout-*.json, so we'd need some way to restart an interactive session with a previous history by using those.
Thanks for the feedback! We're primarily focused on the native/Rust implementation of Codex CLI and would love to see if this is still an issue on the latest version. If it is, please let us know, and we can explore these features further.
Activity
scottleibrand commentedon Apr 19, 2025
#146 and #341 both appear related to this. It looks like sessions are already stored to
~/.codex/sessions/rollout-*.json, so we'd need some way to restart an interactive session with a previous history by using those.codex-maintainers commentedon Aug 7, 2025
Thanks for the feedback! We're primarily focused on the native/Rust implementation of Codex CLI and would love to see if this is still an issue on the latest version. If it is, please let us know, and we can explore these features further.
feat(storybook): cover history continuation success flow (CNB openai#118