Documentation
¶
Overview ¶
Package codex is the delivery adapter for Codex. It hands bundles to a thread with `codex queue`, which Codex starts once the thread's current turn ends, and checks a thread through `codex app-server` (JSON-RPC over standard input and output) before an agent is bound to it, refusing sub-agent threads.
Index ¶
- type Adapter
- func (a *Adapter) Hand(ctx context.Context, h delivery.Handover) (bool, error)
- func (*Adapter) Harness() string
- func (a *Adapter) HasQueue(ctx context.Context) bool
- func (a *Adapter) Validate(ctx context.Context, threadID string) error
- func (a *Adapter) Version(ctx context.Context) (string, error)
- func (*Adapter) WaitsForIdle() bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Adapter ¶
type Adapter struct {
// ClientVersion is sent to the app server as the client's version.
ClientVersion string
}
Adapter runs the codex command found on the PATH.
func (*Adapter) Hand ¶
Hand queues the bundle for the thread. The message is passed as an argument, never through a shell. Exit status 0 means Codex took it, which confirms it.
func (*Adapter) Validate ¶
Validate reads the exact thread through the app server and refuses a thread that doesn't exist or that a parent thread spawned, saying so in Codex's words.
func (*Adapter) Version ¶
Version returns what `codex --version` prints, such as "codex-cli 0.159.3".
func (*Adapter) WaitsForIdle ¶
WaitsForIdle is false: Codex queues a bundle until the thread's turn ends.