The meta-skill that builds and improves all your skills, including itself. Watches your work sessions (autonomous or human-led), captures patterns, corrections and judgement calls, and turns them into skill improvements and new skill candidates for your review. Practical application of the Augmented Expertise methodology. Open source: CC BY 4.0.
Python agent-skillsai-skillsaugmented-expertiseawesome-skillsclaudeclaude-codeclaude-code-skillclaude-code-skillsclaude-coworkclaude-skillsmeta-skillrebelyticsskill-automationskill-builderskill-creationskill-improvementskill-managementskills
Let a run that cannot write report its observations back
Eoghan Henn92b3c1953fbc
diff --git a/references/environments.md b/references/environments.mdindex 81821d7..1686bbd 100644--- a/references/environments.md+++ b/references/environments.md@@ -234,6 +234,14 @@ Before briefing a delegate under an agent definition or instructionsfile, run the lookup for that file's name; its open entries shape thebrief.+A run of this block that cannot write here or get an approval answered —+a child run with no protocol-running caller, a job with a narrow tool+allowlist, a scheduled task in default permission mode — skips the write+steps, never stalls on them, and ends its final message with a+`## Task-observer notes` section (environments.md, "Sessions whose+output channel is owned by a caller"). Such runs write their output to:+ [RUN OUTPUT PATHS, one per line, or "none"]+An observation file comes into being only throughbash "<skill directory>/scripts/new-observation.sh" <slug> "[ABSOLUTE PATH]"which prints the path to write into. Never by copying another file's@@ -262,6 +270,20 @@ rewritten unasked. On every upgrade, diff the installed block againstthis template; a block copied without its stamp line is read asunstamped.+**Before writing a user-scope block, list its non-interactive consumers.**+A block in a user-level instruction file reaches every run that file+loads, not only the sessions a person watches: scripts calling the CLI+(`claude -p …`), LaunchAgent, cron and Task Scheduler jobs, the desktop+app's scheduled tasks. A run with a narrow tool allowlist can write no+file; one in default permission mode stops at the protocol's first+command and waits for an approval nobody reads. So, before the block is+written: list every such consumer with its permission mode and tool+allowlist, and for each that cannot write or get an approval answered,+put its run-output path into the block's `[RUN OUTPUT PATHS]` line, so+the review knows where to harvest. A consumer the list missed shows up+later as a job that stalls at the protocol's first call — a missing+entry here, not a defect in the block.+On Windows, pin the drive-letter form (`C:/Users/<user>/...`): PowerShell,cmd and Git Bash all accept it ("Paths handed across a boundary areresolved from the far side"), and `scripts/new-observation.sh` converts it@@ -1507,12 +1529,10 @@ step they take. That breaks three install assumptions at once:Per-observation files still prevent write collisions between parallelthreads; the problem here is survival, not concurrency.-The Session Start guard warns and re-anchors when the resolved workspace-is ephemeral; in a thread there is nothing stable to re-anchor on, so the-branch is **report-back mode** ("Anchoring the workspace" above): the-durable route is the channel the surface guarantees survives — the-worker's report to its coordinator, a merged commit — not a location the-worker can reach and hope outlives it.+A thread has nothing stable to re-anchor on, so this is **report-back+mode** ("Anchoring the workspace" above): the durable route is the+channel the surface guarantees survives, never a location the worker can+reach and hope outlives it.The characteristic failure is silent: a never-activated install andobservations stranded on an unmerged branch both produce no error, so@@ -1542,14 +1562,42 @@ is itself a session running this protocol, the activation block'ssubagent rule applies: the worker writes nothing, and a finding worthlogging goes into its result, in whatever field the schema leaves fornotes, for the controller to write. Where the caller runs no protocol —-a script, a CI job, another tool — logging stays fully in force, because-the write is the only report there is: anything that would have been-surfaced becomes an observation file naming the condition that fired, so-the next interactive session inherits it; name the caller in-`session_context`, and log only what the caller cannot see. Handoff-doc-mode is the opposite case (a reader, nowhere to write); report-back mode-("Anchoring the workspace") is the case with neither a stable path nor a-reader.+a script, a CI job, another tool — and the run can write, logging stays+fully in force, because the write is the only report there is: anything+that would have been surfaced becomes an observation file naming the+condition that fired, so the next interactive session inherits it; name+the caller in `session_context`, and log only what the caller cannot see.++**A run that cannot write, or cannot get an approval answered, skips the+write steps and reports back instead.** Three shapes: a child run with+no protocol-running caller (`claude -p` from a script); a job whose tool+allowlist holds no write tool (a LaunchAgent with narrow+`--allowedTools`); a scheduled task in default permission mode, where+the protocol's first command raises an approval card nobody answers. In+each, a declined or unanswered protocol call must not abort the caller's+task: the run reads the shape from its own contract — the allowlist, the+permission mode, the absent caller — skips the probe's write branch, the+id claim and the observation write, says so in one line, and carries its+observations in the final message under a fixed heading, last:++```markdown+## Task-observer notes+- skill: <target skill> — <title>. Issue: <what happened>. Improvement:+ <what should change>. Principle: <generalisation, or none>. Context:+ <caller or job name>, <date>.+```++One bullet per observation, no id (only a session with the log derives+one), and the literal line `none` when nothing was observed — the+section is never omitted, since a missing section and a run that never+ran the protocol read the same. The review's Step 1 harvests these+sections from the run-output paths the activation block's `[RUN OUTPUT+PATHS]` line or the task definition names (`weekly-review.md`, Step 1,+"Harvest the run-output notes"); a run whose output goes nowhere durable+has no route, and the install step above ("Before writing a user-scope+block") is what gives it one. Handoff-doc mode is the opposite case (a+reader, nowhere to write); report-back mode ("Anchoring the workspace")+is the case with neither a stable path nor a reader.## First-run backfilldiff --git a/references/weekly-review.md b/references/weekly-review.mdindex 51acb68..37ae79b 100644--- a/references/weekly-review.md+++ b/references/weekly-review.md@@ -416,6 +416,22 @@ readable from this run, say so under Log integrity ("inbox not read:capture fallback the processing step never drains is a second log nobodyreviews.+**Harvest the run-output notes next.** Runs that cannot write or get an+approval answered end their final message with a `## Task-observer+notes` section (`references/environments.md`, "Sessions whose output+channel is owned by a caller") at the run-output paths the activation+block's `[RUN OUTPUT PATHS]` line or a task definition names. For each+path, read every file not yet marked, take the section's bullets through+the same write path as an inbox entry — one at a time, file on disk+before the source is marked — and mark the source: where the file is+writable, the heading becomes `## Task-observer notes (harvested+<date>)`; where it is not, append its path and sha256 to+`skill-observations/harvested.txt`, which the drain reads first. A+section reading `none` is marked without a write. Report under Log+integrity: "run-output notes: N harvested from M files; <path> not+read: <reason>" — a path the block names that this run cannot reach is a+gap in the log, said in that line, never a silent zero.+Then archive observation files resolved in*previous* sessions — with the sweep as shipped (the sweep block of the idsnippet, run on its own; see Archival on Write in SKILL.md), never an@@ -1777,7 +1793,8 @@ writing sessions' session_context and date; `skill:` names normalised forbucketing (Step 3), old → new; `skill:` entries in qualified and bareform (Step 3), N / M; inbox entries drained (Step 1), or "inboxnot read: <reason>"; "N installed skills fail the validator: …" (Step 2),-each with its one-line staging; or "none"]+each with its one-line staging; run-output notes harvested (Step 1), N+from M files, or the path not read; or "none"]### Skipped (needs manual review)[items with reasons]