moai-lane-watchdog
One lane stall watchdog iteration: measure lane progress on three channels, classify the stall cause, apply the remedy or resolve the judgment through the…
от modu-ai★ 1 264 звезды на GitHub
Установить moai-lane-watchdog в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Lane Stall Watchdog — One Iteration
[HARD] Before the first watchdog pass of a session running this skill, read BOTH role-gated rule files in full: .claude/rules/moai/workflow/factory-dispatch.md and .claude/rules/moai/workflow/cross-session-messaging.md. A Codex-only project deploys the same files under .moai/policies/ (for example .moai/policies/workflow/factory-dispatch.md) — read whichever layout this project carries. The always-loaded surface carries only their stubs; the lane obligations and the messaging rules the ladder operates under live in those two files.
One watchdog pass for a lane session (a factory lane running
under moai cc / moai glm / moai codex). The law — the ladder, the
outcome transitions, the gate inventory, the view–SSOT rule, the record
formats — lives in .claude/rules/moai/workflow/auto-semantics.md. Read
that doctrine before the first pass and whenever a step below needs its
detail; this body is the executable procedure.
0. Never prompt
The watchdog never asks the operator a question and never answers an
approval gate on anyone's behalf. Everything that would have been a question
becomes either a resolved judgment (the ladder) or an explicit wait record.
A keep-set gate — environment-impossible, operator-held, or an irreversible
external-shared operation — is never satisfied here: the recheck reads the
gate surface, and finding no change, it re-records the wait and yields.
0a. Renew the card lease (first step of every pass)
Renew this lane's own card lease before anything else, through the factory renew verb, with the card id this lane holds (the same id the snapshot path below names):
moai factory renew <card-id> --json
Read result from the verb's JSON object on stdout. A refusal exits non-zero after printing that object, so read stdout even when the exit status is non-zero. result is one of renewed, refused-expired, refused-not-holder, or error. Hold the value for the snapshot: §1 copies it into the snapshot field renew_result. A refused renewal does not end the pass. A refused-expired, refused-not-holder, or error result is recorded, and the pass continues to §1 and measures in the same pass. Do not retry the renewal within the pass; the next pass renews again.
This step renews the card the lane is executing and no other card: a lane whose cards are all merge-ready, held, or waiting for the serial slot does not renew in that pass, and the pass carries the previous renew_result forward.
1. Measure progress
Three channels (doctrine §3–4):
- HEAD:
git rev-parse --short HEADin the lane's own worktree. - evidence mtimes: the newest mtime across
.moai/reports/<card-id>/
and the active SPEC'sprogress.md. - integration-window state:
moai integration status.
Compare against the previous snapshot at.moai/state/watchdog/<card-id>.json (fields: observed_at, head_sha,evidence_mtime_max, window_state, renew_result, last_change_at). The
lane is stalled only when ALL THREE channels are unchanged since the previous
snapshot AND at least N minutes have passed since the last observed channel
change, which last_change_at records (auto-semantics §4). N
defaults to 15 minutes and is a per-invocation parameter — never a config
key. No previous snapshot → record a fresh one with last_change_at set to
its own observed_at, no stall verdict (fail-open first observation). One
channel moving is progress — evidence mtime advancing without a commit
included: end the iteration with a one-line status — unless the lane itself
is parked on a delegate (§3.5): then the movement is the delegate's, and the
deliverable read in §3.5 decides, not this rule. A pass that moved a channel
sets last_change_at to its observed_at; a pass that moved none carries
the previous value forward. Write the new snapshot after the verdict, in the
same pass as the renewal of §0a: the four measurement fields (observed_at,head_sha, evidence_mtime_max, window_state), last_change_at (the value
this pass settled, per the rule above), and renew_result.
2. Classify the cause
| Cause | Signature |
|---|---|
| awaited-judgment | the lane stopped where a judgment was needed (a gate, a verdict, a choice) and no reply arrived |
| blocked-by | the card waits on a predecessor card; the predecessor's landing state is the open question |
| shell-error | the lane halted on an unadjudicated command failure (a non-zero exit with no recorded disposition) |
| accidental-stop | the session died or was interrupted mid-card — an API error (a 429) ends the turn with no further model action — and no deliberate stop was recorded |
| awaited-delegate | the lane parked on delegated work — a spawned agent's report, a background run's completion — and the report or notice has not arrived; an available idle notice that promised a later report counts, because that agent sen |
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
- 01
Read - 02
Grep - 03
Glob - 04
Bash(git rev-parse:*) - 05
Bash(git status:*) - 06
Bash(git log:*) - 07
Bash(stat:*) - 08
Bash(ls:*) - 09
Bash(test:*) - 10
Bash(moai integration status:*) - 11
Bash(moai factory renew:*)
FAQ
Что делает скилл moai-lane-watchdog?
One lane stall watchdog iteration: measure lane progress on three channels, classify the stall cause, apply the remedy or resolve the judgment through the decision ladder — instead of waiting on a reply — then record the outcome and report. Reads the unified --auto doctrine at .claude/rules/moai/workflow/auto-semantics.md for the ladder, the gate inventory, and the record formats.
Как установить скилл moai-lane-watchdog?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл moai-lane-watchdog запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
docx
AnthropicUse this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
xlsx
AnthropicUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
pptx
AnthropicUse this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…