Commit Graph

1968 Commits

Author SHA1 Message Date
Joel Hooks 320b75db1c docs: record session-index and alerts worker results, deploy record
Session index: 1.58 GiB FTS5, 134,013 Runs / 447,609 chunks, ~20 ms
restart-to-first-query; adversarial verifier spawned before code commit.
Alerts: on-ingest prefix-growth ledger + Typesense startup budget with
messaging-v2 delivery. Panda k8s worker stays on old image (egress
cannot pull; host-role flagg carries the fix).
2026-07-19 20:30:33 -07:00
Joel Hooks b08cfaec8a docs: fan out remaining typesense-reboot-recovery build steps
Three pi workers claimed and launched: SQLite critical-search port,
compacted session index build, growth/budget alerts. Flagg host worker
redeployed on patched capture code (supervisor respawn, health 200).
2026-07-19 20:20:28 -07:00
Joel Hooks 7e2fb01252 fix: stop session-capture prefix inflation at the source
Capture clients (pi, claude, codex) send byte-accurate from_offset,
to_offset, jsonl_sha256, and deterministic source_identity. Stale
cursors coalesce into one pending outbox segment under one Run ID.
capture-outbox-replay.ts is the only replay implementation; the audit
script fails closed on legacy flags and the scheduled nas-backup caller
is migrated. Raw Run writes reject divergent redelivery; a larger
proven-prefix body returns accepted_prefix without overwrite.

Verified adversarially (multi-byte offsets, repeated stale cursors,
fixture-only replay): 20 bun tests + 2 vitest + tsc clean. Receipts in
.brain/projects/typesense-reboot-recovery/patch-verification.svx.
2026-07-19 20:10:39 -07:00
Joel Hooks 4c6ee7889f docs: reopen capture/replay patch step after adversarial verification
Verifier confirmed provenance, coalescing, and canonical replay under
multi-byte and stale-cursor attack, but found nas-backup.ts still
passing removed replay flags (scheduled backup fails closed). Biome
condition narrowed to touched files; caller-migration condition added.
2026-07-19 19:57:32 -07:00
Joel Hooks c971ce8bdb feat: add reproducible Run manifest generator
Read-only scan of ~/.joelclaw/runs-dev producing byte-proven
prefix-coverage verdicts per Run. Receipts in
.brain/projects/typesense-reboot-recovery/run-manifest-summary.svx.
2026-07-19 19:47:47 -07:00
Joel Hooks aad6e8defe docs: lock in SQLite availability shape for typesense-reboot-recovery
Critical projection becomes a replicated FTS5 critical.db (flagg writes,
both NAS boxes read-only, ordered fallback; panda decommissioning).
Session search goes two-tier: observer layer + flagg-local FTS5 from the
manifest keep-set. Typesense demoted to flagg-only non-critical.
Records worker results: capture/replay patch and byte-proven Run
manifest (134,013 keep / 14,010 skip).
2026-07-19 19:46:06 -07:00
Joel Hooks 3fc1584738 docs: charter typesense-reboot-recovery brief with 8 steps
grill-master charter from the reboot diagnosis (a99aa938). Finish line
constrained to existing tailnet hardware. Execution authorized. Two AFK
tasks (capture/replay patch, Run manifest) launched as pi workers.
2026-07-19 19:27:27 -07:00
shitratgit[bot] a99aa93881 docs: capture Typesense reboot diagnosis 2026-07-20 02:15:00 +00:00
shitratgit[bot] 4bfdcc0ee5 docs: explain gateway lifecycle relaunch marker 2026-07-20 01:44:40 +00:00
shitratgit[bot] e85688acec fix: recognize graceful gateway relaunches 2026-07-20 01:32:05 +00:00
shitratgit[bot] a35b698ff8 fix: correct headless runtime readiness probes 2026-07-19 17:05:19 -07:00
shitratgit[bot] 67636b707f fix: make Flagg headless runtime boot-safe 2026-07-19 23:42:13 +00:00
Joel Hooks 7e9d556dee feat: gateway doctor — health, restart, and delivery truth in one obvious command
joelclaw gateway doctor prints PASS/FAIL for daemon (with crash-relaunch
detection against an operator restart marker), live gateway source
CLEAN/DIRTY (a running daemon plus dirty source is today's outage), and
transport state; --live proves delivery with a real probe that must
return a Telegram platformMessageId — confirmed telemetry alone fails.
Every FAIL prints its exact remediation command. gateway restart writes
the marker and ends with the doctor summary.
2026-07-19 13:13:37 -07:00
Joel Hooks 0b24bf3b03 docs: build step unblocked by closed inventory 2026-07-19 11:47:46 -07:00
Joel Hooks efd3147f2d docs: estate inventory closed — 11 lanes, 2 surprise journals, 6 schema consequences 2026-07-19 11:47:37 -07:00
Joel Hooks cd87f9be2b docs: charter the message event stream — Convex log, key law, strangler with demolition 2026-07-19 11:28:44 -07:00
Joel Hooks 8863396ffb fix: one tap, one action — receipts deterministic, ack sends no DM
Joel's single Seen tap produced repeated receipt DMs: re-delivered
callback_query events each minted a fresh receipt identity. Receipt ids
now derive from rawEventId + actionId (duplicate delivery = same row,
no new send), gateway dedupe is durable across restarts, and
learner-flow.ack sends zero receipt DMs — buttons are real actions,
never acknowledgment chores.
2026-07-19 10:18:42 -07:00
Joel Hooks f9fe273cda feat: button-native telegram actions ride message/action.requested
Joel rejected emoji reactions as the operator action API (2026-07-19).
Labeled inline keyboard buttons on outbound DMs publish
message/action.requested with kind: callback and stable learner-flow.*
action ids; the callback_query owner answers, authorizes, resolves
flowId, verifies the declared action, then publishes. Legacy reaction
consumer stays until the live Seen canary passes.
2026-07-19 09:50:50 -07:00
Joel Hooks 1ecb98fcb9 docs: button-native telegram interaction design; reactions retired by design
Joel rejected the emoji-reaction model outright (2026-07-19). Inline
keyboard callbacks routed through the existing gateway replace it;
callback payloads verified under Telegram's 64-byte limit. Includes
pulse/daily composer spec and the reaction-listener retirement proposal.
2026-07-19 09:04:39 -07:00
shitratgit[bot] 22da7c94c9 fix(audit-backup): truthful verifier and replay receipts
- File verification records ok/missing/timeout/error with null counts
  on timeout/error instead of fake zero files / missing backup.
- Replay receipts preserve child exit code, skipped-large count, and
  the first concrete child error; failures land in the host error list.

Forced-fixture validated (1 ms timeout -> backupStatus timeout,
unreachable Central -> failed attempt + Connection refused, healthy
fixture still passes). Receipts in dark-wizard
.brain/projects/fleet-check-maintenance-2026-07-18/.
2026-07-18 22:09:31 -07:00
shitratgit[bot] 815f470779 fix(system-check): postboot authority + NAS checks assert current architecture
- authority_shape_ok: Flagg is self-Central (joels-mac-studio:3111,
  local Typesense :8108); reject stale Panda-Central values instead of
  requiring them. Normalize one trailing slash.
- nas_mount_status_ok: run the status helper through bash so mount
  truth no longer depends on the checkout's exec bit; add a separate
  required probe for the service-owned LaunchDaemon helper's exec bit.

Validated live-pass + simulated-fail; receipts in dark-wizard
.brain/projects/fleet-check-maintenance-2026-07-18/.
2026-07-18 21:47:00 -07:00
shitratgit[bot] 69660ae957 chore: sync pnpm-lock with packages/digest and message-journal importers
packages/digest was added without a lockfile entry, breaking
pnpm install --frozen-lockfile on every fleet machine.
2026-07-18 18:35:35 -07:00
shitratgit[bot] 1442b1da7a merge: land panda's parked commits — o11y triage fix + brain-joel Slack link capture
Panda's main diverged with two Joel-authored commits from mid-June that
never got pushed:
- 9bba6d72 fix o11y triage classifier JSON parsing + parse contract tests
- 70434b60 auto-capture #brain-joel Slack links into discovery/noted

The triage fix merged clean. The Slack capture was written against the
legacy channels/slack.ts that the messaging-v2 cutover replaced; its
feature block (URL extraction + discovery/noted emit, gated to Joel in
BRAIN_JOEL_CHANNEL_ID) is grafted into slack-runtime.ts, modernized to
use loadGatewayInngestEventConfig instead of hardcoded env fallbacks.

tsc clean; 60 tests green (triage contract tests + chat-sdk + inbound);
biome clean. Landing this makes panda's local main an ancestor of
origin/main so panda reconciles with a plain fast-forward.
2026-07-18 18:33:36 -07:00
shitratgit[bot] ba3976b2ff messaging: explicit --kind for notify send; reaction actions in contract v2
joelclaw notify send now accepts --kind memory|alert|digest|ask|receipt,
passed through the Redis envelope and honored by the gateway compat shim
(invalid kinds are rejected instead of guessing a lane). Without --kind,
low/normal-priority sends are inferred as digest, which the Telegram
digest-lane classifier may silently suppress — that suppressed a
Joel-requested message twice on 2026-07-18. Operator-lane kinds
(ask/alert/memory) always deliver. CLI next_actions now point at otel
delivery verification instead of the ignored --telegram-only flag;
skills/messaging documents the flag and the verify rule.

Also lands the in-flight contract-v2 reaction-actions work from a
concurrent session (MessageAction schema in message-contract, telegram
adapter action messages, notify context.actions passthrough, inbound
reaction callback normalization) — entangled in the same files and
committed together deliberately.

81 tests pass across message-contract, chat-sdk, chat-sdk-inbound, sdk;
tsc clean. Live on flagg since 2026-07-18 (gateway restarted, CLI
rebuilt, kind=ask delivery confirmed via notify.compat_v2.confirmed).
2026-07-18 18:18:20 -07:00
Joel Hooks bd308f4561 memory: outbox deletion receipted — 71.4 GB verified trash removed, 0 files remain 2026-07-17 17:00:30 -07:00
Joel Hooks 448e22efe0 memory-cleanup: effort done — all six steps closed with receipts 2026-07-17 17:00:30 -07:00
Joel Hooks 156f754aea memory: repair effort done — drain complete, page regenerated
Drain 167/167 (123 indexed / 44 covered / 0 failed), alarm in observer
release 01b81cba. memory-system.svx regenerated from post-repair
reality per its maintenance rule.
2026-07-17 17:00:30 -07:00
Joel Hooks ac4b44ee73 memory-cleanup: Chorus step closed — service stopped, receipts verified 2026-07-17 17:00:30 -07:00
Joel Hooks 83ea1da487 docs: fleet sweep — no standing surface references retired memory machinery
24 skills + AGENTS.md + SYSTEM.md updated: recall is Brain-backed
projection search, slog/system-log evidence routes to OTel + Brain
receipts, Chorus marked parked, auto-memory pointer-only, retros =
hook-fired condenser. Per update-fleet-skills-prompts.
2026-07-17 17:00:30 -07:00
Joel Hooks 9b1d85a157 feat(memory): retro writer — memory/retro.requested → condenser → .svx
joelclaw retro <brief-path> fires the event; memory-retro-writer reads
the closed brief + step Result sections, enforces the noise bar (<3
steps and no ledger → skip with OTel warn), condenses via pi, and
atomically writes dark-wizard .brain/resources/retros/<slug>-<yyyy-mm>.svx.
Per decide-retro-writer. 7 tests.
2026-07-17 17:00:30 -07:00
Joel Hooks 081ee693ed fix(memory): keep transcript content out of Inngest step outputs
Large runs (4MB+ replays, long sessions) died on 'step output size is
greater than the limit' — load-jsonl/chunk returned whole transcripts
through persisted step outputs. Steps now reread jsonl_path on disk and
return counts/hashes only; inline payloads spool to a temp file in a
small early step. Receipt: run 01KXRWNW7FTQMX3ES89BS6XZGA.
2026-07-17 17:00:30 -07:00
Joel Hooks 4abe71495e memory-cleanup: retirement closed with steering receipts; final wave dispatched 2026-07-17 17:00:30 -07:00
Joel Hooks 997275cce6 memory: retire legacy stack + system log — one migration
joelclaw recall and voice recall now answer from Brain/observation
stores (19 tests). memory_observations archived to NAS (28,050 docs,
238MB, sha d2f3038d, verified) and dropped. Zombie functions
(reflect/review-promote/proposal-triage/batch-review) unregistered and
deleted with the MEM/FRIC suites (-6,306 lines). System log retired:
panda copy snapshotted (3,981 lines, sha 4e8e815d), slog write path /
system-logger / sync + backup + PDS mirror removed. Per decisions
decide-legacy-memory-retirement + decide-system-log-home.
2026-07-17 17:00:29 -07:00
Joel Hooks 99007d9c37 soul-principles: charter — earned capped constitution for steering
Grilled live 2026-07-17: steering-only injection (workers stay lean),
seed slate through the taste gate, symmetric gate + displacement at cap
(~20). Composition of shipped parts: dreams extract, taste loop
curates, fleet graft injects, Brain stores. Five steps; execution after
memory-system-cleanup lands.
2026-07-17 17:00:29 -07:00
Joel Hooks 0f5c9d1020 memory-cleanup: auto-memory migration closed — pointer index live
18 topic pages dispositioned (5 migrated to dark-wizard 264aeba, 13
duplicates receipted, 3 stale claims flagged and not migrated), topic
pages deleted, MEMORY.md now binding rule + 7 Brain pointers.
2026-07-17 17:00:29 -07:00
Joel Hooks 3d1fca0c47 memory-cleanup: Chorus parked — injection removed, outbox snapshotted
Rhizomatic SessionStart/Stop hooks removed from claude/codex/pi configs
(machine-local; no dark-wizard source exists). 13-mutation outbox
snapshotted with per-file SHA-256 and byte-for-byte verification;
sources untouched. Service stop + un-park path documented in the step;
launchctl disable/bootout is steering's (needs sudo).
2026-07-17 17:00:29 -07:00
Joel Hooks d6138c745c memory: five judgment calls decided; cleanup effort chartered
Grilled live with Joel 2026-07-17: legacy stack retires (recall
retargets to Brain, memory_observations archives to NAS then drops,
zombies unregister, MEM/FRIC dies), system log retires with a NAS
snapshot, Chorus parks, Claude auto-memory becomes a pointer index,
retros get a hook-fired Inngest writer. memory-system-cleanup brief +
six steps charter the execution and the fleet skill/prompt update.
2026-07-17 17:00:29 -07:00
Joel Hooks 8fea91c114 fix(memory): index run metadata row for empty captures
Empty-but-valid captures now upsert the same runs_dev metadata document
as chunk-producing captures (turn_count 0), so outbox replay can verify
them by SHA instead of timing out on a row that never appears. Switch to
single-document upsert so Typesense schema rejection surfaces as an
error instead of hiding behind import's HTTP 200.
2026-07-17 17:00:29 -07:00
shitratgit[bot] 599db56373 refactor(gateway): remove legacy Telegram and Slack owners 2026-07-17 17:00:29 -07:00
shitratgit[bot] ae5db7ed9a docs(memory): replace stale runbook and record taste bench 2026-07-17 17:00:29 -07:00
shitratgit[bot] d5ee515510 fix(memory): harden capture and plan safe outbox replay 2026-07-17 17:00:29 -07:00
shitratgit[bot] f0aea45ba3 fix(voice): make session recall tolerate sparse hits 2026-07-17 17:00:29 -07:00
shitratgit[bot] 59c8de1aa3 brain: file reaction intent-classifier decision (Joel, 2026-07-17)
Deterministic reaction->intent mapping is a dead end (Telegram's
reaction set is huge/open). Classify intent from whatever he taps
instead; converge reactions and buttons on the same receipt-gated path.
2026-07-18 00:00:26 +00:00
shitratgit[bot] 3aecd364d1 digest: render as Telegram HTML with bold headers, drop the form-label dump
The digest read like a form: 'Source:/When:/Why now:/Connection:' on
separate plain-text lines, no hierarchy. Now bold emoji headers, prose
lead lines, and a muted italic footer for provenance — HTML-escaped.
Reads like a person wrote it, per the chief-of-staff voice contract.
2026-07-17 23:57:57 +00:00
shitratgit[bot] 80e029284b docs: rebaseline Slack ingress follow-ups 2026-07-17 11:52:13 -07:00
Joel Hooks 894bf6bc02 memory-system-repair: dream cap + promotion script reviewed and committed (observer 461eddc8); promotion queued behind bench worker 2026-07-17 11:08:43 -07:00
Joel Hooks 66abaf012b memory-system-repair: graph boundary + dream cap closed by workers; taste bench dispatched (wB:p2S) 2026-07-17 11:02:37 -07:00
Joel Hooks b9172794a1 messaging: charter legacy-transport deletion — Joel's go, git is the rollback; reaction re-homing is the hard gate 2026-07-17 10:57:22 -07:00
Joel Hooks 98bf07d951 cutover attempt #3: ChatSDK canonical — sighted canary exit 0, platform message 14587, all health checks green 2026-07-17 10:54:25 -07:00
Joel Hooks 0c561c9287 canary: match journal origin_system_id composite (source:eventId) — attempt-2 rows prove the acting path was healthy; canary was blind, not delivery 2026-07-17 10:52:42 -07:00