Install
openclaw skills install project-loopRun approved long-running project work from file-backed state, continue through self-clearable tasks, pause cleanly at real gates, and recover across sessions.
openclaw skills install project-loopUse for approved multi-step work that must survive resets, compaction, interruption, approval gates, and stalled execution.
Do not use for trivial one-turn work, open-ended autonomy, or projects without a clear owner.
state.json > manifest.md > validation.md > handoff.md > memory > chatowner_agent in state.json executes project tasksstate.json against actual reality before executingProject path:
agents/<agent-id>/projects/<project-slug>/
Required:
README.md
manifest.md
state.json
validation.md
Optional:
handoff.md
notes.md
artifacts/
logs/
state.json Minimum Fieldsproject_idowner_agentstatusphasecurrent_task_idlast_checkpointnext_actionblocked_reasonawaiting_approvalapproval_itemsretry_countmax_retrieslast_session_noteresume_instructionsinterruptedactive_loopRecommended additions:
approved_objectivescope_guardrailstask_queue_snapshotcompleted_tasksblocked_tasksdeferred_tasksartifactsvalidation_statuslast_errorlast_error_atbudget_hintsresume_historywatchdogRead in this order:
state.jsonmanifest.mdvalidation.mdhandoff.md if presentNever start by asking “what were we doing?” if project files exist.
On resume:
status, phase, current_task_id, next_action, resume_instructionsStates:
DraftReadyRunningValidatingAwaitingApprovalBlockedPausedDoneAbandonedAllowed transitions:
Draft -> Ready
Ready -> Running
Running -> Validating
Validating -> Running
Validating -> Done
Running -> AwaitingApproval
Validating -> AwaitingApproval
Running -> Blocked
Validating -> Blocked
Running -> Paused
AwaitingApproval -> Running
Blocked -> Running
Paused -> Running
Any state -> Abandoned
Rules:
Draft -> Ready only when objective, scope, manifest, and validation existReady -> Running only when the next chunk is sized and eligibleRunning -> Validating only after outputs are recordedValidating -> Running only after pass and a next task is eligibleValidating -> Done only when required tasks are complete and final checks passRunning/Validating -> AwaitingApproval for true human-cleared boundariesRunning/Validating -> Blocked when a blocker cannot be self-cleared within retry rulesRunning -> Paused only for interruption, manual pause, or no eligible taskA chunk is too large if it:
state.json, manifest.md, validation.md, or handoff.md alone does not count as execution progress unless the current task is explicitly documentation-onlyNo task is complete until validation passes and the result is recorded.
Validation may include:
Validation records should capture:
If validation fails:
BlockedSelf-clearable work may continue if it stays in scope.
Human-cleared work includes:
When a true approval gate is reached:
status to AwaitingApprovalapproval_itemsDo not pause at routine internal chunk boundaries. Pause only for:
If interrupted by unrelated work:
state.json immediatelyinterrupted=trueactive_loop=falsestatus=Paused unless already AwaitingApproval or BlockedWhen updating state.json, use a full-file write by default, not a partial edit. state.json changes frequently and exact-match edit operations are brittle on high-churn files. Use partial edit only if you have just read the current file and the change is truly small, stable, and low-risk.
If state.json cannot be updated:
If a task may have partially executed:
If state is missing or inconsistent:
Cron is a watchdog only, never the main workflow engine.
Done or Abandoned, remove the watchdogWatchdog may:
RunningPausedWatchdog must not:
Recommended cap:
state.jsonmanifest.mdvalidation.mdhandoff.md if presentstate.json