Expand description
Machine-local embedded database (redb).
One redb file per config dir at
<app-support>/stores/<stable-key>.redb holds that config dir’s durable
per-machine state. The key is a SHA-256 of the canonicalised config-dir
path, so a Rust release cannot move it; the single-instance lock keeps its
own digest and is unaffected. redb takes an exclusive file lock on open,
so a second opener on the same path fails here rather than corrupting.
This wrapper is deliberately general - open plus the raw handle.
Table logic lives per-tenant in the submodules: biometric enrolments
(biometric), Gotify subscriptions (gotify), Slack subscriptions
(slack), durable crons (cron) and the schedules their fired
prompts came from (cron_names), session identities (sessions),
review threads (review), forge state
(state, the account-usage cache), the
usage scan’s per-file token summaries (token_usage), cached
model pricing (pricing), plugin update history (plugins),
and the catalog’s per-file worker-tag scans (session_tags).
dynamic_workers is the retired worker table: nothing writes it,
and it holds only until the boot sweep has moved every row onto
sessions.
model_catalog is retired rather than live: it exists only to drop
the table the deleted catalog machinery left behind in older stores.
settings is the same, for the table the /spinner override lived in.
Re-exports§
Modules§
- bench_
results - What this machine’s benches measured, keyed by what they were about.
- biometric
- Biometric enrolments on the redb
biometric_enrolmentstable. - cron
- Durable forge-cron persistence on the redb
cronstable. - cron_
names - The schedule each fired prompt came from, keyed by the prompt’s own id.
- dictate_
models - What this machine has downloaded from the dictation feed, and which model each role was last set to run.
- dynamic_
workers - The retired
dynamic_workerstable, kept only to drain it. - gotify
- Gotify subscription CRUD on the redb
subscriptionstable. - handoffs
- The handoff log: one row per swap, with the numbers
at_percentis tuned from. - model_
catalog - The retired
model_catalogtable, kept only to drop it. - plugins
- Plugin update history on the redb
plugin_updatestable: one row per installed entry (keyplugin_id|scope), holding the latest update forge applied to it - what moved, from where, and the marketplace ref a rollback can restore. Values are serde-json. - pricing
- Cached LiteLLM pricing on the redb
pricing_cachetable. - review
- Review-thread persistence on the redb
review_threadstable. - session_
tags - Per-file worker-tag scan cache on the redb
session_tagstable. - sessions
- Session identity on the redb
sessionstable. - settings
- The retired
settingstable, kept only to drop it. - slack
- Slack subscription CRUD on the redb
slack_subscriptionstable. - speaking_
models - What this machine has installed for the speaking role, keyed by variant.
- speaking_
results - What this machine’s speaking benches measured, keyed by what they ran.
- state
- Machine-local forge state on the redb
account_usagetable: the per-account usage cache, one row per account. Values are serde-json; no field schema on disk. - task_
archive - Durable archive: task rows whose tree has closed.
- task_
chases - Durable chase log: the newest firing of each rung per subject.
- task_
history - Durable task history: one append-only row per status transition.
- tasks
- Durable task persistence on the redb
taskstable. - token_
usage - Per-file usage-summary cache on the redb
token_usagetable.
Structs§
- Db
- Handle to the machine-local redb database.
Functions§
- path_
for - This config dir’s store file:
<app_support>/stores/<stable-key>.redb.