feat: Lyra's journal — permanent thought record + a knowing journal note

Her reflections/metacognition were capped rolling windows (6/5), so older
thoughts were lost for good. Now everything she produces is also appended to a
permanent, append-only journal; the capped lists stay as her working-memory
window for context.

- memory: journal table + add_journal_entry/list_journal
- reflect(): persists every committed reflection + critique to the journal, and
  the examine step gains a "journal" field — a deliberate, first-person note she
  writes for herself (her knowing journaling), tagged by source (dream/manual)
- web: /journal diary view (kind filters, grouped by day) + /journal/data;
  linked from /self
- tests assert reflections + metacognition land in the journal

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-17 06:40:46 +00:00
parent 4c8f7202da
commit 59d684b12b
7 changed files with 214 additions and 5 deletions
+1
View File
@@ -70,6 +70,7 @@
<span class="dot" id="dot"></span>
<h1>🧠 Lyra · Mind</h1>
<a class="back" href="/">← Chat</a>
<a class="back" href="/journal" title="Her permanent journal">📔 Journal</a>
<a class="back" href="/logs" target="_blank" rel="noopener" title="Watch the live log">logs ↗</a>
<button id="reflectBtn" title="Make her reflect now (draft → self-critique → revise). Watch it in /logs.">↻ Reflect now</button>
<span class="updated" id="updated"></span>