feat(lifeboard): calendar, Gmail and first-class mail triage - #318
Open
ivanmkc wants to merge 1 commit into
Open
feat(lifeboard): calendar, Gmail and first-class mail triage#318ivanmkc wants to merge 1 commit into
ivanmkc wants to merge 1 commit into
Conversation
Resolves audit finding B1 by moving triage into the client. Gmail is signed in from the browser with PKCE and the token lives on the device that signed in, so a nightly pass on the bridge could not authenticate. Triage now runs here and catches up on what it missed; the bridge may ask for a pass while a client is open but never holds the credentials. Handing a long-lived refresh token to a separate local process was rejected: it is the difference between "this app can read my mail while I am looking at it" and "this machine can read my mail forever". The cost -- an iPad closed for a week triages nothing until it opens -- is stated in the audit rather than hidden. Reconciliation gets the care the roadmap asked for. A rescheduled appointment updates the event already on the calendar; a second dentist appointment is the one that gets missed. Matching is deliberately conservative: the provider's id first, then the same title on the same local day, then the same title within a fortnight. A cancellation is always proposed and never applied, whatever the sender's trust rung, because being wrong there means someone does not turn up -- and it marks the event cancelled rather than deleting it, so nobody wonders where it went. The trust ladder defaults to the middle rung. Nothing is applied on its own until you have accepted three things from that sender, and even then it appears in the inbox with an undo. The promotion is offered, never taken. Structured data is parsed by code and prose by the model, and which one ran is recorded. An ICS attachment needs no confidence score and never varies; a model-derived fact is marked as such so a human correction always wins. Sending mail cannot happen without an approval that names the exact draft, so forgetting the confirmation is a type error rather than a missing check. Weeks are stepped by calendar day, not by adding 24 hours: on the days the clocks change a day is 23 or 25 hours long, and the arithmetic version silently loses a Sunday. Recurring events are expanded by Google rather than interpreted here. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This was referenced Sep 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The stack
localStoragefor the test suite on Node 25@ivanmkc/termchart-canvas; injectable interact transportEvery branch in the stack was checked out on its own and verified independently:
npm install,tsc --noEmitfor every package,npm testacross the workspace, and the offline e2e where it exists. All nineteen are green — no branch depends on a later one to build or pass. Full viewer e2e (11 suites, 106 assertions) was run on #312 as the behaviour-preservation evidence for the extraction.Stack position: 8 of 10. Base:
lifeboard/06-provenance.The connective tissue: the family calendar, mail read and sent, and triage as a first-class subsystem.
This resolves audit finding B1 by moving triage into the client. Gmail is signed in from the browser with PKCE and the token lives on the device that signed in, so a nightly pass on the bridge could not authenticate. Triage runs here and catches up on what it missed; the bridge may ask for a pass while a client is open but never holds the credentials. Handing a long-lived refresh token to a separate local process was rejected: it is the difference between "this app can read my mail while I am looking at it" and "this machine can read my mail forever". The cost — an iPad closed for a week triages nothing until it opens — is written into the audit rather than hidden.
Reconciliation gets the care the roadmap asked for. A rescheduled appointment updates the event already on the calendar; a second dentist appointment is the one that gets missed. Matching is deliberately conservative: the provider's id first, then the same title on the same local day, then the same title within a fortnight. A cancellation is always proposed and never applied, whatever the sender's trust rung, because being wrong there means someone does not turn up — and it marks the event cancelled rather than deleting it, so nobody wonders where it went.
The trust ladder defaults to the middle rung. Nothing is applied on its own until you have accepted three things from that sender, and even then it appears in the inbox with an undo. The promotion is offered, never taken.
Structured data is parsed by code and prose by the model, and which one ran is recorded. An ICS attachment needs no confidence score and never varies; a model-derived fact is marked as such so a human correction always wins.
Sending mail cannot happen without an approval that names the exact draft, so forgetting the confirmation is a type error rather than a missing check.
Weeks are stepped by calendar day, not by adding 24 hours — on the days the clocks change a day is 23 or 25 hours long, and the arithmetic version silently loses a Sunday. Recurring events are expanded by Google rather than interpreted here.
Verified: 301 unit tests, covering a week that spans the DST boundary, reschedule-not-duplicate, cancellation-always-proposed, and send-refuses-unapproved.
🤖 Generated with Claude Code