/learning-loop:inboxfrom learning-loop
Batch triages inbox notes by classifying intention status, clustering by topic, auto-promoting mature notes, and sweeping fleeting notes for archival. Surfaces limbo notes for close-or-plan decisions.
Ships in learning-loop. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Launches the inbox-organiser agent to process all notes in 0-inbox/. The agent clusters by topic, assesses maturity via the promote-gate skill, detects counter-arguments, and executes promotions autonomously. Merges, deletes, and fleeting archival require approval.
/reflect sessions that deposited notesThis skill emits provenance events for pipeline observability. Run each Bash command silently.
At session start:
ll-run provenance-emit.js '{"agent":"inbox","skill":"inbox","action":"session-start"}'
At session end. Alongside the existing counters, include the common outcome shape: items_in (notes triaged), items_out (promoted plus merged), items_flagged (limbo), duration_ms:
ll-run provenance-emit.js '{"agent":"inbox","skill":"inbox","action":"session-end","promoted":N,"deleted":N,"merged":N,"rewrites":N,"limbo":N,"items_in":N,"items_out":N,"items_flagged":N,"duration_ms":N}'
Per-note tracking is automatic for main-thread writes via the PostToolUse hook; subagent writes and edits (note-writer files, the organiser's own Edits and mv-promotions) bypass it and are covered by the Step 2 hook replays (2a for note-writer output, 2c for the agent's touched-files inventory).
Launch the inbox-organiser agent with:
{{VAULT}}/all (or topic:<name> if the user specified a topic filter)The agent definition is at ${CLAUDE_PLUGIN_ROOT}/agents/inbox-organiser.md (resolve to a literal path before dispatch — see agents-shared/vault-io.md → Placeholders).
Spawn the inbox-organiser agent (dispatch: skills-shared/dispatch.md) with the full prompt from the agent definition, or launch a general-purpose agent that reads the agent file.
While the inbox-organiser agent runs (this check is independent of its output), check the librarian queue for pending observations targeting inbox notes.
Read PLUGIN_DATA/librarian/queue.jsonl (where PLUGIN_DATA = CLAUDE_PLUGIN_DATA env; if absent, resolve via ll-run resolve-paths.mjs PLUGIN_DATA; never hardcode a fallback path). Parse each line as JSON. Filter to items where status === 'pending', target starts with 0-inbox/, and task is one of: voice_flag, tag_suggestion, duplicate_flag.
If matches exist, include them as advisory context when presenting the agent's results, grouped by task type:
Librarian observations:
Voice flags:
"gmail multi daemon pull deduplication": Names a topic, not an insight. Consider retitling.
Tag suggestions:
"ginkgo biloba acute pk profile" → pharmacology, neuroscience
Duplicate flags:
"foo-claim.md" ↔ 3-permanent/foo-claim-original.md (similarity 0.93)
...
These are informational: the user decides whether to act on them during triage. Apply or dismiss them in /health --librarian.
The agent cannot spawn note-writer (subagents cannot spawn subagents). It returns a Rewrite Worklist; executing it is this skill's job.
2a. Autonomous rewrites (no approval needed). For each item with type: rewrite, spawn a note-writer agent (dispatch: skills-shared/dispatch.md) with:
true — the worklist destination already encodes the organiser's verify-note gate (a verify FAIL deliberately routed the note to 1-fleeting/); the gate must NOT re-promote it to 3-permanent/ and defeat that verification gatereason as rewrite contextResolve all path placeholders in each prompt to literal absolute paths (see agents-shared/vault-io.md → Placeholders). Dispatch independent items concurrently (dispatch: skills-shared/dispatch.md). After note-writer reports the written file, rm the 0-inbox/ original and run the three post-promotion frontmatter hygiene checks from the agent's section 6a on the new file. If note-writer returned the note content instead of reporting a written path, Write the file yourself at the worklist destination before rming the original.
When the 2a fan-out completes, replay the PostToolUse hook chain on every written path — subagent Writes bypass it (see skills-shared/hook-replay.md, targeted variant):
printf '%s\n' "$WRITTEN_PATH_1" "$WRITTEN_PATH_2" \
| ll-run sweep-hook-replay.mjs --stdin
Surface any failures from the JSON summary in Step 3.
2b. Gated actions. Present merges, deletes, inbox archival candidates (≤2-pass notes untouched ≥30 days, plus status: resolved notes untouched ≥30 days — agent Steps 1 and 4), and fleeting archival candidates (from the agent's Step 8 sweep) in one block; one user response handles all of them. On approval, execute in order:
rm each approved inbox copytype: merge item, spawn note-writer with BOTH notes' full content as input, the worklist destination, destination_locked: true (same rationale as 2a: the worklist destination already encodes the organiser's gate decisions, and the note-writer gate must not re-promote past them — user approval covered the merge, not a destination override), and instruction to write one merged note; after it reports the written file, rm both source notes, run the 6a hygiene checks, and replay the hook chain on the merged file (same snippet as 2a). If note-writer returned the merged note content instead of reporting a written path, Write the file yourself at the worklist destination before rming the two sources.mv each approved candidate to {{VAULT}}/_archive/0-inbox/ (create with mkdir -p if needed); the agent returns candidates only and never archives. This is the inbox ratchet exit: a weak note untouched for a month leaves triage instead of recirculating forever.mv each approved candidate to {{VAULT}}/_archive/1-fleeting/ (create with mkdir -p if needed); the agent returns candidates only and never archivesIf the agent returned a fleeting repair section (NEEDS-DEEPEN notes — gate-demoted notes with verification markers or source: unverified, untouched >14 days), surface it in Step 3 as a non-destructive /deepen suggestion. These are not gated and are never archived; just relay the recommendation. The agent caps the list at 5 (oldest first) with a +N more line when there are more — relay that line verbatim:
Fleeting notes needing repair (run /deepen to resolve):
- creatine-loading-halves-uptake-time — verification markers, 30 days old → /deepen "creatine-loading-halves-uptake-time"
+3 more — run /health to see the full list
2c. Replay hooks over the agent's touched files. The organiser's own Edit and mv calls (counter-argument link pairs, Zeigarnik status stamps, mv-promotions, 6a hygiene) also bypassed PostToolUse — 2a covers only note-writer output. After the gated actions complete, parse the ### Touched files inventory from the agent's report (one vault path per line; skip if it says none) and replay the hook chain over it, same snippet as 2a:
printf '%s\n' "$TOUCHED_PATH_1" "$TOUCHED_PATH_2" \
| ll-run sweep-hook-replay.mjs --stdin
Counter-argument link pairs matter most here — they are exactly what edge-infer should index. Resolve vault-relative paths to absolute before piping. Surface any failures from the JSON summary in Step 3.
The agent returns a structured summary. Present it to the user, including the top-5 limbo list (Step 5.5 of the agent) verbatim.
The agent only presents that list — it cannot converse. Relay the user's per-note replies by executing the frontmatter edits the agent documented:
status: resolved to the note's frontmatter via Editintentions: frontmatter as a - context: <context> entry with a cue: <cue> line indented under it, and set status: intentionedLimbo notes the skill edits here join the hook-replay scope: pipe them through the same 2c snippet if any were edited after 2c already ran.
inbox-organiser agent and its agents-shared/; note-writer fan-out and gated-action execution live here, because subagents cannot spawn subagents.status: resolved note (closed in limbo triage) is skipped from gating/clustering, and once untouched ≥30 days the agent returns it as an inbox-archival candidate (gated, 2b) — it never recirculates through every run. This closes the inbox ratchet._archive/1-fleeting/. It also returns NEEDS-DEEPEN notes (gate-demoted, untouched >14 days) as a non-destructive /deepen recommendation — closing the loop so marker-bearing fleeting notes get resurfaced for repair instead of accumulating forever.What SKILL.md sets; muted values are Claude Code's defaults
24 skills in this plugin
/deepenStrengthen a single vault note with research. Usage: /learning-loop:deepen "note name" or /learning-loop:deepen (picks shallowest inbox note). Assesses maturity, researches gaps, rewrites in vault voice, promotes when ready./diagramGenerate an Excalidraw diagram for the vault. Usage: /learning-loop:diagram "concept or mechanism" or /learning-loop:diagram (infers from context). Produces .excalidraw.md in vault Excalidraw/ folder./discoveryExplore a topic interactively with web research and vault context. Usage: /learning-loop:discovery "topic" [--style guided|branch|checkpoint] [--tone academic|conversational|persona] [--surf]. --surf skips note creation./doctorDiagnose your learning-loop installation. Runs health checks, presents issues, offers per-fix remediation, re-runs each check after the fix to confirm. Safe to run anytime; only makes changes you approve. Pass --redact to scan plugin data files for leaked credentials instead./dreamConsolidate auto-memory between sessions. Usage: /learning-loop:dream (no args). Four-phase cycle: Orient, Gather Signal, Consolidate, Prune Index. Seven operators: MERGE, RESOLVE, ABSTRACT, COMPRESS, PRUNE, LINK, DATE NORMALIZE. Rebuilds MEMORY.md./dream-evalmeasure whether a /dream pass helps, hurts, or ties against no consolidation. usage: /learning-loop:dream-eval --mode={single|control|repeated} [--passes=N] [--mine]. single scores pre/post on the live corpus; control forks two clones and dreams one; repeated dreams a clone N times and plots the drift + content-survival curve.npx claudepluginhub robinslange/learning-loop --plugin learning-loopOther plugins' skills for the same job