Use when: Writing memory/YYYY-MM-DD.md at the end of a session, or logging any subagent task outcome.
Why this exists: Memory files are the single source of truth for Langfuse backfill, Quill journal generation, Liv's CCP updates, and QMD search. Format drift = invisible tasks = broken observability. The regex parsers don't forgive variation.
Every agent task gets exactly this structure. No exceptions.
markdown
### [AgentName] Task — YYYY-MM-DD HH:MM
- **Task:** one-line description of what was asked
- **Outcome:** ✅ complete / ⚠️ partial / ❌ failed
- **Metric:** pass/fail, score, or N/A
- **Kept:** yes / no / pending-review
- **Time:** ~X minutes
- **Notes:** what worked, what didn't, key decisions, surprises
Real examples from 2026-03-24:
markdown
### Kit Task — 2026-03-24 06:45
- **Task:** Rebuild /setup page — full agent configuration wizard (5 tabs)
- **Outcome:** ✅ complete
- **Metric:** pass — clean build, 200 on live URL
- **Kept:** yes
- **Time:** ~15 min
- **Notes:** Built all 5 tabs with localStorage persistence. No features cut. Clean TypeScript build first pass.
langfuse-backfill-historical.py uses this regex pattern to find task blocks:
text
### [Name] Task — YYYY-MM-DD
The em-dash ( —) and space on both sides are required. These all break the parser:
❌ WrongWhy it fails### Kit Task 2026-03-24Missing — separator — regex miss### Kit Task: 2026-03-24Colon instead of em-dash — regex miss### Kit Task —\n2026-03-24Date on separate line — regex miss- **Outcome:** doneNot ✅ complete — field extraction returns empty- **Outcome:** complete ✅Emoji at end, not start — field extraction may miss
Naming: memory/YYYY-MM-DD.md
One file per day. Append throughout the day — never overwrite.
Dream cycle archives files >7 days old to memory/archive/.
Typical file structure (top to bottom):
markdown
# Daily Log — YYYY-MM-DD (Day)
_AEST timezone. Written end-of-day._
---
## Summary
[Optional 2-3 sentence overview — only for full sessions]
---
## Cross-Repo Activity — YYYY-MM-DD [Dream Cycle]
[Automatically captured — don't write this manually]
---
### [Agent] Task — YYYY-MM-DD HH:MM
[Task block — see Section 1]
### [Agent] Task — YYYY-MM-DD HH:MM
[Next task block]
---
### Loki Session — YYYY-MM-DD HH:MM–HH:MM (MAIN SESSION)
[Session summary block — see Section 3]
For the main session (Loki's own summary at end of day):
markdown
### Loki Session — YYYY-MM-DD HH:MM–HH:MM (MAIN SESSION)
- **Projects touched:** [list]
- **Outcome:** ✅/⚠️/❌ + brief summary
#### Deliverables this session
1. [numbered list — one line per deliverable]
#### Key decisions
- [append-only, dated — architecture choices, trade-offs made]
#### Blockers / Next
- [what's pending, who owns it, expected resolution]
Write OUTBOX entries in OUTBOX.md (agents append here; Quill reads it to write journals).
markdown
## YYYY-MM-DD — [Short description of work]
**Tasks completed:**
1. [Brief description of each major deliverable]
**Key technical decisions:**
- [Non-obvious choices made]
**Repos touched:** [repo names + commit hashes if known]
Write an OUTBOX entry when:
Skip OUTBOX when:
ConsumerWhat it depends onWhat breaks if format driftslangfuse-backfill-historical.py``### [Name] Task — YYYY-MM-DD header patternTask not extracted → gap in Langfuse observabilityQuill journal pipelineOUTBOX ## YYYY-MM-DD — headersQuill misses entries or writes empty journalsLiv CCP session updateTask outcome blocks to build Notion daily log bodyNotion log is empty or incompleteQMD memory searchConsistent structure across filesRetrieval quality degrades; semantic search misses context
MistakeFix### Kit Task: (colon)Use ### Kit Task — (em-dash, spaces)Date on separate line from headerKeep date on same line: ### Kit Task — 2026-03-24 14:00``Outcome: doneUse exactly ✅ complete / ⚠️ partial / ❌ failedSkipping the Notes fieldMost important field — this is what gets turned into skills and journalsOne giant session blockOne block per task, not per sessionWriting prose narrative instead of task blocksProse is unreadable to parsers. 2026-03-23.md is the cautionary example.Forgetting the timeApproximate is fine ( ~10 min) — needed for Langfuse duration metadata
Task block:
markdown
### [AgentName] Task — YYYY-MM-DD HH:MM
- **Task:**
- **Outcome:** ✅ complete
- **Metric:** pass
- **Kept:** yes
- **Time:** ~X min
- **Notes:**
Session summary:
markdown
### Loki Session — YYYY-MM-DD HH:MM–HH:MM (MAIN SESSION)
- **Projects touched:**
- **Outcome:** ✅
#### Deliverables this session
1.
#### Key decisions
-
#### Blockers / Next
-
OUTBOX entry:
markdown
## YYYY-MM-DD — [Short description]
**Tasks completed:**
1.
**Key technical decisions:**
-
**Repos touched:**