On this page
In short#
The learning loop carries a source event to a ranked proposal, a person's decision, a measured outcome and a label, and feeds the label back into the next ranking. ADR 0060 (docs/adr/0060-self-learning-seams.md, accepted on 7 November 2026) wired measured reward to the served policy; four parts of its seams are still open (see Where it stops).
How it works#
Each stage writes one store under a re-run key, so a repeated pass writes nothing new. Every table named below is under per-organization row-level security, and a person stands between the machine's proposal and anything that happens outside the platform.
| # | Stage | Store | Writer, and who else may change a row | Re-run key | Gate |
|---|---|---|---|---|---|
| 1 | Source data | raw_, then silver tables and agg_ rollups |
Connector sync and the webhook route; the promoter sets processed_ |
Organization, connector, stream, id, payload hash | verify:data on rollups |
| 2 | Signal ledger | signal_ |
The worker only; the web runtime may set four feedback columns | Organization, brand, idempotency key | Append-only trigger, verify:rls |
| 3 | Proposal | decisions, decision_ |
The worker's decision cycle, ranking with the champion policy; episodes are never updated | Organization, brand, date, campaign / episode key | verify:rls decision replay, verify:data |
| 4 | Approval | decisions status, approver and time; experiment_ arm |
Owner or org admin, with an audit entry | Update predicated on the current status, run first | decision- |
| 5 | Action | action_ |
Inserted in the approval's transaction; a control-arm decision's commands are written as held out; a person carries out the rest | The approval claim: a repeated approve inserts none | Marketplace connectors return manual steps |
| 6 | Outcome | decision_; observed lift on experiment_ |
The worker measures on the declared conversion and writes the lift on both arms; a control-arm outcome abstains | One row per decision | verify:data #61 |
| 7 | Label | decision_ verdict; signal_ feedback; alert_ status; chat_ rating |
Owner or org admin confirms hit, partial or miss, marks a brief signal done, acknowledges or resolves an alert; a member rates their own assistant answers | Same row as the outcome, signal, incident or message | Owner check in the router |
| 8 | Learned state | playbook_, signal_, policy_, policy_ |
The worker rebuilds the caches and fits lever posteriors on confirmed lift; promotion and rollback are human-only | Natural key per organization and brand | verify:data re-derives playbook_ and #20 |
Current state per arrow#
| Arrow in the figure | Today | Evidence | Seam |
|---|---|---|---|
| 1 to 2: source to ledger | Orders and inventory snapshots carry their Bronze row and sync batch; webhook ingest and the event bus share one envelope. The data watermark column has no writer yet | packages/, packages/, packages/ |
S4, open |
| 2 to 3: ledger to proposal | The episode carries the fired signal instance it stands on | packages/ |
none |
| 4 to 5: approval to action | The status claim runs first, then the commands and one arm row each, in one transaction; 10 % of decisions fall in a control arm keyed on the decision, so a re-approve keeps its arm | apps/, :349, :1155; packages/ |
S2 |
| 6 to 7: outcome to label | Owner verdict on decisions, refused for a control decision; alert incidents are acknowledged or resolved; assistant answers carry a thumbs rating | apps/, :960; apps/; apps/ |
S1 |
| 7 to 8: label to learned state | Track records rebuild from owner-confirmed verdicts only | packages/ |
none |
| 8 to 3: track record | Reorders a rule once it has 8 confirmed outcomes; the set of eligible rules never changes | packages/, packages/ |
none |
| 8 to 2: dismissals | Demote, never promote; the dataset signal collector reads the weights, the catalog-measure collector does not, because the input is optional | packages/, packages/ |
S1, open |
| 6 to 8: reward | Lift is the conversion after execution against the equal window before it; the lever posterior folds confirmed treatment-arm lifts from a 0 bp prior; without confirmed positive lift the policy abstains as cold start | packages/, packages/, :451 |
S2 |
| 8 to 3: promoted policy | The scan ranks with the champion's configuration when exactly one valid champion exists, else with the defaults; the receipt pins its id and version, and replay re-ranks with it | packages/, packages/, :237 |
S3 |
| Outside the figure: prompts and eval | CI runs the agent eval dry run against a committed baseline; chat records a hash of its system prompt; prompt templates carry a version and hash; a monthly chat token cap per organization | ., apps/, packages/, packages/ |
S5 |
Field-level detail of the envelope and lineage columns is on Event contract.
Where it stops#
- A machine never approves, executes or confirms a decision; approved decision actions are manual steps, and no connector writes to a marketplace or ad account.
- Selection is deterministic, so off-policy evaluation refuses on today's logs. The holdout is a control arm per decision, not a randomized choice among playbooks.
- The lift is before-and-after per decision and is not yet adjusted by the control arm.
- Open parts of the seams: weights required on every signal collector and a
feedbackepisode kind (S1), thumbs in the deck assistant (S1), a writer for the data watermark (S4). - No prior is pooled across organizations; a cross-organization prior needs a consent mechanism that does not exist.
- A separate causal compute service stays out of scope (ADR 0009, deferred by ADR 0060).
- Dated status per capability, including the evidence ladder: Project status.