worker
GitHub适用于 OMX 团队 worker 节点的协作协议,涵盖身份解析、启动 ACK、任务领取与状态流转、邮箱管理及心跳状态更新。
Trigger Scenarios
Install
npx skills add Yeachan-Heo/oh-my-codex --skill worker -g -y
SKILL.md
Frontmatter
{
"name": "worker",
"description": "Team worker protocol (ACK, mailbox, task lifecycle) for tmux-based OMX teams"
}
Worker Skill
When to use
Use only when the session was started as an OMX Team worker. Read AGENTS.md#durable-runtime-invariants-canonical-ssot before acting; it defines the durable ownership and coordination boundaries.
Inputs and preconditions
- Require
OMX_TEAM_WORKER=<team-name>/worker-<n>. - Resolve this skill from the first existing path:
${CODEX_HOME:-~/.codex}/skills/worker/SKILL.md,~/.codex/skills/worker/SKILL.md,<leader_cwd>/.codex/skills/worker/SKILL.md, then<leader_cwd>/skills/worker/SKILL.md. - Resolve the Team state root in this order:
OMX_TEAM_STATE_ROOT, worker identityteam_state_root, config/manifestteam_state_root, local.omx/state.
Operational steps
- Split the environment into
teamNameandworkerName; Send a startup ACK before task work:omx team api send-message --input '{"team_name":"<teamName>","from_worker":"<workerName>","to_worker":"leader-fixed","body":"ACK: <workerName> initialized"}' --json - Read
<team_state_root>/team/<teamName>/workers/<workerName>/inbox.mdand take the first unblocked assignment. - Read
<team_state_root>/team/<teamName>/tasks/task-<id>.json; APIs use the bare numerictask_id(for example"1"). - Claim before editing:
omx team api claim-task --input '{"team_name":"<teamName>","task_id":"<id>","worker":"<workerName>"}' --json - Do the assigned work. Do not write task lifecycle fields directly.
- Complete or fail through the lifecycle API, from
in_progresstocompletedorfailed:
Useomx team api transition-task-status --input '{"team_name":"<teamName>","task_id":"<id>","from":"in_progress","to":"completed","claim_token":"<token>","result":"<evidence>"}' --jsonrelease-task-claimonly to requeue a blocked task topending. - Check and acknowledge mailbox messages:
omx team api mailbox-list --input '{"team_name":"<teamName>","worker":"<workerName>"}' --json omx team api mailbox-mark-delivered --input '{"team_name":"<teamName>","worker":"<workerName>","message_id":"<MESSAGE_ID>"}' --json - Write idle status after the transition:
<team_state_root>/team/<teamName>/workers/<workerName>/status.jsonwith{"state":"idle","updated_at":"<ISO timestamp>"}.
Exit and evidence
Completion evidence names the task id, changed artifacts, verification performed, and any blocker. ACKs, task transitions, mailbox acknowledgements, and status writes must be observable through the Team API/state files. On shutdown, follow the lead's inbox instructions and write the required shutdown acknowledgement before exiting.
Version History
-
3ad79a8
Current 2026-08-28 17:53
重构为结构化操作指南,明确引入 durable runtime invariants 约束,细化任务生命周期 API 调用及证据记录要求。
- e94437f 2026-08-20 07:18


