Files
archie/internal
sam 88bb707e7b feat(edastore): PocketBase-owned collections for event capture and bindings
First slice of the persistence migration, taking the event-capture tables
rather than the task lifecycle. These five tables hold no production rows and
their feature (archie-core-t2db) is unfinished, so they migrate at zero data
risk and the remaining work lands natively instead of being written against
hand-rolled SQL and ported later. They are also the tables that actually want
what PocketBase gives: inspecting a payload nobody has modelled yet, mapping
fields against it, and editing a binding at runtime are the epic's acceptance
criteria, not incidental conveniences.

The task lifecycle deliberately stays on SQLite. tasks/transitions/events
carry FIFO claim ordering, id-cursor pagination and the task-grant map, none
of which gain anything from being hand-editable. binding_dispatches.task_id
is the single seam and stays a plain integer addressing that store.

Idempotency moves from INSERT OR IGNORE on a composite primary key to unique
indexes, so the at-most-once ledgers are enforced by the schema rather than by
each caller remembering the pattern. A save that fails for any other reason is
returned rather than swallowed: treating every error as "already recorded"
would turn a broken ledger into a silent at-least-once dispatcher.

Adds tool_calls, which had no persistence at all. Tool calls were only written
to the on-disk task log (internal/logging), readable as text but never
queryable, filterable or watchable.
2026-09-23 01:27:34 +10:00
..