From 060da7ea1db66cfc40ed4aed1f2d79c8aeb5bcf0 Mon Sep 17 00:00:00 2001 From: zap Date: Thu, 12 Mar 2026 21:23:25 +0000 Subject: [PATCH] docs(agent): add stuck-subagent intervention rule --- AGENTS.md | 12 ++++++++++++ MEMORY.md | 1 + 2 files changed, 13 insertions(+) diff --git a/AGENTS.md b/AGENTS.md index fa1ca6d..c70b80a 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -190,6 +190,18 @@ Handoff rule: - relevant files / ids / commands - what counts as success for the next pass +Subagent drift / stuck rule: +- if a fresh implementation subagent is no longer making crisp progress, inspect before waiting longer +- treat these as intervention triggers: + - the run is still active after a reasonable window for the task and has not updated `WIP.md` + - the run is looping on broad reads/re-verification without landing state updates or commits + - the completion result is unusable, missing evidence, or obviously unrelated to the assigned pass +- when triggered: + 1. inspect the subagent session/history once + 2. if meaningful progress is still happening, let it finish + 3. otherwise kill the run, verify the workspace directly, finish the pass in the main session, and update `WIP.md` yourself + 4. record the behavior in memory if it reveals a repeatable failure mode + Delegation helper: - Use `skills/delegation-router/SKILL.md` as the local quick policy for choosing direct vs subagent vs ACP and selecting model tier. diff --git a/MEMORY.md b/MEMORY.md index 8fc266d..6277376 100644 --- a/MEMORY.md +++ b/MEMORY.md @@ -41,6 +41,7 @@ - Council tiers should use local LiteLLM-backed models for usage monitoring: light = `litellm/gpt-5.3-codex` with low thinking, medium = `litellm/gpt-5.3-codex` with high thinking, heavy = `litellm/gpt-5.4` with high thinking. - For non-trivial implementation work, treat `WIP.md` as the canonical state file and update it after each completed task/sub-task with status, concrete evidence, and the next recommended action. - If a subagent model choice causes execution/auth issues, prefer retrying implementation work on Codex GPT-5.4. +- If a fresh implementation subagent stops making crisp progress, inspect once; if it is looping, not updating `WIP.md`, or returns an unusable result, kill it, verify the workspace directly, and finish the pass in the main session. ## Infrastructure notes worth remembering - Full `~/.openclaw` backups upload to MinIO bucket `zap` and are scheduled via OS cron every 6 hours.