-
Notifications
You must be signed in to change notification settings - Fork 2k
[codex-rs][experiment] New session crate to manage backgrounded codex execution #684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Hi @oai-ragona, Thanks for contributing this! I noticed your PR #684 ( My approach in #522 focuses on adding manual From your description, it seems your implementation ( |
Hey @kshitizz36! Explicitly saving and restoring the state of an interactive session would be great. I haven't taken a close look at your PR yet, but the idea is something I've wanted as well, and is non-overlapping with what I'm up to here. This PR is about spinning off lots of little mostly non-interactive agents. It's currently just for the extra-experimental What I'm working on is, as you note, much more similar to
I'm planning to get this cleaned up and record a little demo video tomorrow, but in the mean time I'm happy to confirm this is totally separate from the mainline TypeScript Best, |
What/Why
I often find myself wanting to drop in and out of a codex session, or just fire off a read-only background task like, "analyze this folder, and look for bugs." I don't want to have to watch the thing closely, I just want it to go work.
Implementation
This PR is largely
codex-rs
generated, and I still need to review it myself. At a high level, it adds a newcodex-session
bin target. It's a CLI closer to something likedocker
orkubectl
, where it's effectively a CRUD interface that just wraps the other bins.The high level flow works by tracking session folders with stdin/out/metadata in
~/.codex/sessions
.We can list previous sessions we've done:
See how they went:
We can drop in and out of running interactive
repl
sessions withattach
:I think a little wrapper like this would quickly become my preferred interface to launch
codex
tasks, and I think we can actually get it working just fine with any type of TUI, so in theory this should be able to wrap any of them. Still in draft mode trying this stuff out and reviewing the model-generated xode.