← ClaudeAtlas

cortex-loop-session-observelisted

Session-observation loop for a Cortex project — the v3 successor to v2's insight-gaps, and the primary producer of automatic, ungated project learning. Use for the scheduled session-observe task, or when the user says "run the session-observe loop", "what did we learn this session", or "capture session observations". Runs `cortex loop-session-observe --collect`, reads the unobserved sessions from the shared corpus, infers durable knowledge (project context stated in passing, user corrections, gotchas hit, non-obvious behaviour, patterns established), classifies each with a prefer-ungated tiebreaker, and enriches directly with no approval — project-wide context into insight/observations/, per-file facts into insight per-file entries — carrying claude-sessions provenance; only the minority that should bind future work becomes a rule-candidate or decision-candidate pulse proposal — then runs `cortex loop-session-observe --apply --proposals <file>` and summarises .cortex/pulse/reports/session-observe.md.
pedropacheco95/cortex · ★ 1 · Data & Documents · score 74
Install: claude install-skill pedropacheco95/cortex
# cortex-loop-session-observe You are the judgment middle between two deterministic Core bookends (spec insight.session-observe Rule 10). The CLI collects the worklist and audits the result; you — this session — do the observation, classification, and enrichment judgment. You already ARE a Claude session: **never spawn a nested `claude` subprocess.** **The hierarchy inverts from how this loop first shipped.** Being useful is the fast, ungated path: what a session teaches lands directly in `.cortex/insight/` with no per-item approval — that is this loop's *primary* job now. Graduation to a hard rule or decision is the slow, gated path, reserved for the minority that must genuinely bind future work. **The loop-write invariant (RULES 7, spec Rule 7):** your only direct writes are `.cortex/insight/observations/*.md` (and `_index.md`), the `## Insights` / `## Query pointers` sections of existing insight per-file entries (machine-owned, ungated), and the proposals JSON scratch file. Everything gated — compass, atlas, RULES.md — goes through the pulse gate as a typed proposal, with no exception. 1. From the project root, run `cortex loop-session-observe --collect`. Read `.cortex/pulse/state/session-observe-worklist.json` — the sessions not yet observed. If the worklist is empty, run `cortex loop-session-observe --apply` anyway (it records the run in the report) and tell the user there was nothing new to observe. 2. Read each worklist session's messages from `.cort