codex-relay
Relay
Open one native Codex task, hand off a bounded job, end this turn, and verify the worker's callback. The invocation plus a request to open a task is the authorization; never create tasks otherwise.
Preconditions
If any is missing, explain and stop. Do not create an orphan, promise a wake-up you cannot deliver, or substitute a CLI, subagent, or automation.
create_threadandsend_message_to_threadare exposed.CODEX_THREAD_IDis non-empty (plus host if remote). Never derive it from the cwd or reuse a child ID.- The user named the task.
Model and effort
Use exactly what the user selected, handling the two independently: omit only the model field if no model was named, and only the thinking field if no effort was named, so each falls back to the configured default. If a model is unavailable, say so and ask; never substitute. Resolve ambiguity from tool metadata; ask only when material.
Workspace
Use list_projects to find the target when files are involved. Honor a user-specified branch, working-tree state, or saved checkout via the option create_thread supports; only when unspecified, default to a worktree for Git projects and local otherwise. A default worktree starts from the default branch without uncommitted changes; if a requested state is unsupported, say so rather than implying it was included. For projectless work, reference supplied accessible files.