Garry's Opinionated OpenClaw/Hermes Agent Brain
TypeScript
Merge remote-tracking branch 'origin/master' into capy/6803-wave
garrytana32e533bd975
diff --cc CHANGELOG.mdindex effd951aee,a193ca859e..50f30be39a--- a/CHANGELOG.md+++ b/CHANGELOG.md@@@ -10,75 -10,89 +10,158 @@@ credits are retained; no result has beeidentifiers and attribution are available in the pre-removal Git revision`6040075c6cb95be5881cc2e1b76ef7d71f4e5d29` (retained on 2026-09-23).- ## [0.60.276.0] - 2026-10-17++## [0.60.277.0] - 2026-10-17++**A stuck upgrade queue drains, held embeddings say what they need, and doctor and status answer in bounded time (#6803, #6847).** Four things got better for anyone whose brain grew big or went through the recent upgrades. Image pages that an old upgrade left queued (and missing from search) can now be put back with one keyless command when gbrain already knows they're safe, and the rest are counted and named instead of hidden. Large pages waiting for your embedding approval are reported everywhere with one exact command to approve them, and that command now works on free local embedding models too. `gbrain doctor --json` and `gbrain sync --status` stop running for minutes on a large brain. And the "un-extracted edges" nudge after a sync now agrees with doctor and names the command that actually finishes the job.++### What you'd see++| Situation | Before | Now |+|---|---|---|+| tens of thousands of image pages queued by the 0.51 activation | never left the queue; every resident tick probed all of them; out of search | `gbrain projections drain` seals the ones the importer already attested safe (keyless, no re-embedding); the rest are counted as `reimport`, `protected` or `archived`; the resident probes at most 500 rows per tick |+| doctor `text_projection_readiness` | one `pending` number | counts per class, a drain fix sized to about a minute that asks first, and by-design classes reported as info |+| `gbrain embed --stale` with pages held for approval | silent | `budget_limited`: "N large page(s) have chunks waiting for embedding approval …" plus a per-source approve command |+| `gbrain embed --held --dry-run` on a multi-source brain | exit 1 | lists every source with one approve command each, exit 0 |+| `gbrain embed --held --source <id> --max-usd N` on a free (local) embedding model | reprinted the hold forever | releases it and embeds the page at $0 |+| receipts for a held page | `gbrain reindex --held` (does not exist) | `gbrain embed --held --dry-run --source <id>` |+| `gbrain sync --status --json` | ran a full sync of the source | prints the status envelope with a one-line hint |+| `gbrain doctor --json` on a large brain (non-interactive) | could run past two minutes; slow checks kept running server-side | stops its check run at 90 s by default; each check cancels its own statements at its budget; the cheap incident checks run first |+| "N page(s) have un-extracted edges" after a sync | counted attendance-blocked meetings; named only `extract --stale` | silent when doctor wouldn't warn; names `gbrain extract --stale` and `--catch-up` with time estimates |+| `gbrain extract --stale --source <id>` | ran brain-wide | refuses with `invalid_params`, pointing at `--source-id <id>` |++### What to do after upgrading++Nothing runs on upgrade. Each repair below is preview-first, and you choose when to run it.++- **Queued image pages.** Run `gbrain doctor --only text_projection_readiness --json` to see the counts, then `gbrain projections drain --dry-run --json`. With your go-ahead, run `gbrain projections drain --limit <n>` on the brain host and repeat until `sealable` is 0. It's keyless and makes no provider calls. `reimport` images need their importer: `gbrain embed --stale --images --dry-run`, then the paid run. `protected` and `archived` pages stay out of search by design.+- **Held embeddings.** `gbrain embed --held --dry-run` lists every source. Then `gbrain embed --held --source <id> --max-usd <N>` per source, and `gbrain embed --held --dry-run --source <id> --json` shows held 0. `--max-usd N` is both the run's cap and a saved per-page allowance.+- **Slow status and doctor.** Use `gbrain sync status --source <id> --json`, and `gbrain doctor --tier ops --json` or `--budget-ms 90000`. `gbrain config set doctor.default_budget_ms 0` turns the new default off.+- **Un-extracted edges.** `gbrain extract --stale --dry-run --json` shows the work. On the host, `gbrain extract --stale --catch-up [--source-id <id>]` finishes it in one interruptible run. Done means `actionable: 0`.++### Itemized changes++#### Projection queue (part 2)++- `page-state/projection-class.ts` partitions every queued row into `text`, `sealable`, `reimport`, `protected` and `archived` in one SQL fragment, shared by `projectionBacklog`, the drain preview, the drain, doctor and search readiness.+- `page-state/image-seal.ts` `sealImageProjections` restores the importer's own seal on `sealable` images in groups of up to 500 under the page guard. It writes no chunk and leaves `embedding_image` untouched. Measured: about 1,800 to 2,000 images a second, which sets `IMAGE_SEAL_PAGES_PER_SECOND` and the drain `--limit`.+- `page-state/projection-window.ts` bounds each resident tick and each idle probe to a recency lane plus a 500-row primary-key window with a wrap-around cursor. Segmented rows are probed queue-wide.+- `page-state/projection-status.ts` caches the class counts off the tick path for the resident's `projection_status` reply.+- Embed paths count image pages as blocked instead of queuing `embedding_recovery` rows.+- `embed --stale --images` skips sealable pages and reports `reimport`, `incomplete_sealed`, `ocr_required`, `protected` and `archived`.+- `gbrain projections drain` reports per-class `remaining_by_class` and never says "empty" while image rows remain.+- A read-only `[AGENT]` notice after upgrading names the drain preview.+- `gbrain migrate --to <engine>` (the legacy copier) now carries an image chunk's `embedding_image` vector (#6871). Before, a migrated image page arrived without it and needed a paid re-embed to show up in image search.+- A preparation read issued after its budget ran out (for example a page purge's journal sweep) is now refused before it is sent. Before, it went out with a 1 ms statement timeout, and a fast read could finish inside that, so the purge committed past its deadline instead of releasing.++#### Held embedding budgets (part 3, #6847)++- `held-embedding.ts` provides `readBudgetLimited` and the shared phrase. `held-embedding-action.ts` provides `heldApproveAction`, which builds the approve command used by `embed --stale`, embed-backfill, doctor and the oversized receipt.+- `partial_embedding` is its own doctor registry entry.+- An explicit `--max-usd` is the hold approval on any provider, and free-recipe models cost $0 in the per-page ledger. The printed paid N is `derivedCapUsd` of the estimate (×1.5, $0.25 floor).+- An approval is refused before release when embeddings can't run (`embedding_unavailable`) or the paid model has no price (`no_pricing`).++#### Bounded doctor and status (part 5)++- `statement-deadline.ts` gives each doctor entry its own deadline engine: Postgres cancels the statement, and PGLite refuses the next one. Frontmatter and fence scans stop at the deadline and report partial results.+- `doctor/default-budget.ts`: `doctor.default_budget_ms` (file plane, default 90000) applies only to plain non-interactive CLI `doctor --json`.+- `capacitySnapshotWithin` waits at most 1.5 s per caller and never caches a timed-out fetch. `capacity-memo.ts` forecasts once per doctor run.+- `sync/operator.ts` `syncOperatorVerb` canonicalizes `sync --status`. `--preview` and `--check` refuse.+- `scripts/bench/doctor-scale.ts` measures doctor, `sync status` and the cheap checks at scale, with a pass criterion.++#### Extraction nudge (part 6)++- `extraction-lag.ts` gives doctor `links_extraction_lag` and the sync nudge one statement and one verdict, with attendance-blocked pages excluded.+- `extract-stale-options.ts` validates `--source` before direct and owner dispatch. Extract's routing flag is `--source-id`.+- `SyncTailReport.underived` drives the per-source line.+- `EXTRACTOR_BUMP_NOTES` pins the link-extractor version, and its test requires a note for every bump.++#### Agent protocol++- `AGENT_TOOL_LIMIT_MS` (120 s): a fix expected to run longer than that is the user's or host admin's (`tell_user_to_run`), never the agent's.++ ## [0.60.276.0] - 2026-10-17++ **Sync stops handing one page's history to another when Git guesses a rename, and background work on a managed brain stops spending write ids it can never use (fix wave 18a).** When you move a note and edit it in the same commit, Git only guesses that it was a move. Two notes made from the same template and moved together could be paired the wrong way round, and sync then carried one page's facts, links and aliases onto the other. Now sync keeps a page across a guessed move only when the files agree: the same `id`, or the same unique `slug:` line or title. Anything else becomes a new page, and the old one stays restorable, with the exact restore command printed and the purge holding it until someone decides. Contributed by @javieraldape (PR #6732, rewritten).++ On a brain whose writes go through a writer, background work (the autopilot cycle, jobs, connector syncs) kept submitting writes to a source that could not publish them, a worktree in recovery or a deleted owner marker, and every attempt used up a permanent request id. Those writes are now refused before they take an id. The purge skips such sources and sets aside pages that keep failing instead of failing the cycle, and re-ingesting transcripts that did not change takes no ids at all.++ Four smaller fixes ride along: dream synthesis no longer fails a pass when looking up its own outputs times out, `propose_takes` stops paying again every cycle for a reply that says "nothing here", `gbrain transcripts ingest --since last` moves past Codex sub-agent sessions, and `gbrain repair slug-conflicts` clears a hold it used to leave for a person.++ ### What you'd see++ | Situation | Before | Now |+ |---|---|---|+ | two similar notes moved and edited in one commit (Git reports `R087`) | sync could move one page's facts, links and aliases onto the other | the page keeps its identity only on a shared frontmatter `id`, or a unique `slug:` line or title; otherwise a fresh page plus the old one soft-deleted, the report prints `gbrain restore <old-slug> --source-id <id> --force` and doctor `rename_identity_downgrades` names the pair |+ | a note moved to another folder and rewritten, Git did not pair the two files | a delete plus an add | the same page, when the deleted file carries the same unique `id` and the same file name, title or bytes; a reused template `id` alone still starts a fresh page |+ | a file moved and broken in the same commit (unreadable frontmatter) | held with the old page's identity | the old page is soft-deleted and recorded as above, the file is held as a new file; an exact move (`R100`) still keeps its page |+ | a managed sync finds the one legacy page whose slug folds to the file's, and both carry different explicit `id`s | adopted the legacy page (v0.60.269.0) | held `legacy_slug_conflict` with reason `explicit_id_conflict` |+ | a background write to a source whose worktree is in recovery or whose owner marker `.gbrain-owner.json` is gone | admitted with a permanent request id, then failed at publication | refused `owner_unavailable` before any receipt, fix `gbrain sources writer status --source <id> --json`, checked once per source per run |+ | the managed purge meets a source in recovery, or a page that fails to purge every run | submitted every run; the cycle purge phase failed | the source is skipped (`writer_not_active`), the page is parked after 5 failures (doctor `purge_parked_pages`), the phase warns; `gbrain pages purge-deleted --retry-parked` retries once |+ | `gbrain transcripts ingest` re-reads unchanged sessions on a writer-claimed brain | one new request id per session part per run | none |+ | `gbrain transcripts ingest --since last` with Codex guardian or other sub-agent rollouts | counted as drift, so the watermark never advanced and every run rescanned every session | `N sub-agent rollouts (no user turns by design)`; the watermark advances, real drift still holds it |+ | dream synthesis postprocess times out looking up its committed outputs | the pass failed after the paid synthesis had run | deferred to a later pass and finished there without another synthesis call |+ | `propose_takes` gets `[]` followed by prose | retried as a failure, a paid call every cycle | an empty extraction: the page is tombstoned until its body changes |+ | `gbrain repair slug-conflicts` on a hold whose only other fix is a style-only `NESTED_QUOTES` re-quote | `still_invalid`, needed `repair frontmatter --include-ambiguous` | cleared by removing the `slug:` line; the array stays as written and is listed as `style_only` |++ ## To take advantage of v0.60.276.0++ `gbrain upgrade` should do this automatically. If it didn't, or if `gbrain doctor` warns about a partial migration:++ 1. **Run the orchestrator manually:**+ ```bash+ gbrain apply-migrations --yes+ ```+ 2. **Your agent reads `skills/migrations/v0.60.276.0.md` the next time you interact with it.** The schema step (one new index, built online on Postgres) needs no action; the note covers the two new doctor checks and the `owner_unavailable` refusal.+ 3. **Verify the outcome:**+ ```bash+ gbrain doctor --only persistence_request_indexes,rename_identity_downgrades,purge_parked_pages+ gbrain stats+ ```+ 4. **If any step fails or the numbers look wrong,** please file an issue:+ https://github.com/garrytan/gbrain/issues with:+ - output of `gbrain doctor`+ - contents of `~/.gbrain/upgrade-errors.jsonl` if it exists+ - which step broke++ This feedback loop is how the gbrain maintainers find fragile upgrade paths. Thank you.++ ### Itemized changes++ #### Rename identity across inexact Git renames (#6729)++ - Sync no longer moves one page's facts, links and aliases onto a different page when Git guesses an inexact rename between two similar files. Identity follows a shared frontmatter `id`, a unique `slug:` line or a unique title; anything else is a delete plus an add, reported with its restore command and held from the purge until the pair is settled (#6729). Contributed by @javieraldape (PR #6732, rewritten).+ - `src/core/sync-rename-identity.ts` is the one confirmation stage: `confirmRenameIdentities` reads committed sides through one `git cat-file --batch` stream (64 KiB heads) and the dirty tree from disk; the title follows parseMarkdown precedence (frontmatter, then the first H1, never the filename) and the old side uses the title its page row stores. `explicitIdVeto` is the one explicit-id veto the managed takeovers consult.+ - A `--working-tree` verdict is bound to the bytes it read (`identityHead`, sha256 of the first 64 KiB): classic `applyRename` re-checks it before the identity moves, and a managed sync refuses `source_changed` on frozen bytes that differ.+ - `src/core/sync-identity-downgrades.ts` records each downgraded pair in `op_checkpoints` (op `sync-identity-downgrade`, open until a disposition is set or the old page is restored or purged, no time window). `gbrain sync status --json` lists them under `identity_downgrades`; doctor `rename_identity_downgrades` warns while one is open. On an unbound Postgres source with a checkout, where a restore would refuse `owner_unavailable`, the report and doctor do not offer it.+ - A managed sync refuses `page_identity_changed` (detail `rename_identity_conflict`) when a file would take over a page, or a held rename would carry one, whose frontmatter `id` differs from its own. The #6727 legacy-slug adoption consults the same veto: two different explicit ids hold the file `legacy_slug_conflict` with reason `explicit_id_conflict` instead of adopting the page.+ - `buildSyncManifest` rename entries carry Git's `similarity`.++ #### Background writes on a source that cannot publish (#6741)++ - Managed brains: background writes no longer spend permanent request ids on a source that cannot publish (a worktree in recovery, or a failed owner check such as a deleted .gbrain-owner.json); they are refused owner_unavailable before any receipt. The purge skips such sources and parks pages that keep failing, the cycle warns instead of failing, and `gbrain pages purge-deleted --retry-parked` retries parked pages within the cutoff and rename holds. (#6741)+ - `src/core/persistence/owner-verification.ts` (`verifyOwnerRoot`, `assertBackgroundOwner`) is the claim's owner verification, shared by writer onboarding and background admissions and cached once per source per run (`admission-origin.ts`). A device-only change is still re-stamped by the write, and a paused (draining) owner still accepts and replays. `assertWorktreeAdmission` refuses a background admission to a `recovering` worktree under its existing lock. Interactive CLI, MCP and repair writes are unaffected.+ - `src/core/persistence/purge-parks.ts` keeps per-tombstone parks in `op_checkpoints` (op `purge-deleted-park`, keyed by source, slug and deletion time, so a re-deleted page starts fresh). `PURGE_PARK_LIMIT` is 5 non-deferral failures; a success clears the park, and parks rearm the first run a source's writer is active again. `selectPurgeCandidates` (`purge-deleted.ts`) is the one eligibility selector for the preview, the consent, the `purge_deleted_pages` op and the run. Doctor `purge_parked_pages` names each parked page with its last error; its fix previews with `gbrain pages purge-deleted --retry-parked --dry-run --json` and runs behind the user's agreement.+ - Managed brains: re-ingesting unchanged transcripts no longer burns a permanent write-request id per session part (an unchanged part is screened by the publication preparer and the no-op kernel before admission). (#6741) The screen is `unchangedPutPage` in `src/core/persistence/put-page-screen.ts`; a pending request, projection work, a missing or edited canonical file or a segmented page still admits. The stale-part delete now runs as a background admission.+ - `gbrain transcripts ingest --since last` no longer rescans every session forever when Codex guardian or other sub-agent rollouts are present: those rollouts are counted as "sub-agent rollouts (no user turns by design)" and the watermark advances. Real drift still holds it. (#6741) `--json` gains `subagentRollouts` at the top level and `subagentRollout: true` on a file outcome (additive).++ #### Dream synthesis postprocess (#6757)++ - Schema migration v250 (`persistence_request_id_index`) adds `persistence_requests_request_id`, built `CONCURRENTLY` on Postgres (an invalid leftover is dropped first) and inline on PGLite; `gbrain repair request-indexes` builds it on a brain whose schema is already current. DDL only, no backfill.+ - Synthesis postprocess finds each child's committed `put_page` by request id through that index. A statement timeout on the read defers the postprocess (`dream.synthesize.postprocess_pending`, `src/core/cycle/synthesize-postprocess-deferral.ts`); the next pass replays it without a child job and verifies the output's quotes against the current transcript, sending a quote it cannot find to `unverified_claims`. Three deferrals in a row add a line to doctor `persistence_request_indexes`, whose messages now say "request-table indexes".++ #### Smaller fixes++ - #6782: `propose_takes` decides takes and the empty tombstone from one reply outcome, so `[]` with trailing prose is memoized. The tombstone is keyed by a hash of the page body, so any body edit re-extracts the page; there is no per-page force flag (`docs/guides/cron-schedule.md`).+ - #6749: `gbrain repair content` and `repair slug-conflicts` clear a `frontmatter_slug_conflict` hold with `remove_slug` when the only other change `autoFixFrontmatter` would make is a style-only `NESTED_QUOTES` re-quote of a valid JSON-style tag or alias array. `ContentRepairReceipt` gains an optional `style_only` list (receipts without it are byte-identical). A hold the lane still cannot clear names the fix codes it needs in its `still_invalid` message.++ ### For contributors++ - Flake fix: `scripts/ci-bounded-run.ts` no longer reports a command that already exited as stalled when the runner is descheduled past the bound.+ - Flake fix: the CJK keyword deadline test (`cjk-keyword-deadline-postgres`) asserts the arm's statement budgets instead of wall time, so a stalled test process no longer fails a correct arm; a new case injects a stall mid-arm and checks the arm starts nothing past its deadline.+ - Shard weights (`scripts/test-weights.json`, `serial-weights.json`, `e2e-weights.json`) were refreshed from recent Test and E2E runs.+ - Tests whose fixture was an inexact move onto a broken file now use an exact move held by a stale `slug:` line (every hold-lane assertion unchanged); the inexact case keeps one test per path asserting its new outcome. `test/pages-purge-deleted-args.test.ts` expectations gained `retryParked: false`. `test/persistence-connector-fencing.test.ts` orders its request-id reads, since the new index changed the unordered row order.+ - Migration note: `skills/migrations/v0.60.276.0.md`.+## [0.60.275.0] - 2026-10-17**`gstack-pregate` now reaches a verdict on small machines: on a machine under 8 cores, the test tier goes to the full Ubicloud gate instead of thousands of local files.** On a 4-core machine, a one-line edit to a hub file such as `src/core/config.ts` selected about 3,900 test files, and pregate hit its 40-minute cap after 308 of them. `.gstack/pregate.json` now declares a `remote_gate`. Pregate records the selected files as one remote obligation in seconds, and `gstack-pregate --remote` clears it by running the full gate on the working tree.diff --cc docs/architecture/key-files/commands-2-continued.mdindex 158f5c1b5b,c580112b8c..12c474faa8--- a/docs/architecture/key-files/commands-2-continued.md+++ b/docs/architecture/key-files/commands-2-continued.md@@@ -29,5 -29,9 +29,9 @@@ Current behavior and load-bearing invar- `src/commands/doctor/checks/keyword-plan.ts` — `keyword_plan` (#6495, OPS, wave check with operator resolution; the keyword-side twin of `vector_plan` in commands-2.md). Postgres only: reads the commonest lexeme the planner knows for `content_chunks.search_vector` (`pg_stats.most_common_elems` with its frequency), EXPLAINs (no ANALYZE) the strict page-count statement for it (`buildKeywordCountStatement`, the builder the engine uses) and times the engine's own bounded `countKeywordPages(term, { timeoutMs: 2000 })`; warns `canary_timed_out` when that count hits its bound and `canary_slow` when it takes more than half of `search.keyword_statement_timeout_ms`, naming the knob with its range (1000-60000), the fail-open to the vector arm (`keyword_arm_failed`), that a longer bound buys time and not a cheaper statement, that one canary term is not workload coverage, and that a timed-out count is never "no matches". Skipped on PGLite, below 10,000 chunks (`pg_class.reltuples`) and without planner statistics (it names `ANALYZE content_chunks`); a failing probe reports unknown health. `engineKeywordPlanProbe(engine)` is the database side; `keywordPlanCheck(engine, probe?)` takes a fake for tests. Tested in `test/doctor-keyword-plan-6495.test.ts` (fake probe for every outcome; with DATABASE_URL the real probe on a seeded brain and a lock-forced timeout).- `src/commands/doctor/checks/image-embedding-coverage.ts` — `image_embedding_coverage` (#6529, brain category, after `image_assets`). Counts live image pages (`page_kind = 'image'`), those with no `embedding_image` chunk, those with a NULL `source_path`, and the `managed_image_sync_unsupported` holds per source, and reads `isMultimodalEnabled()`. Ok when the brain has no image pages, when every image page has an image vector and a `source_path` and nothing is held, or when multimodal embedding is off (the counts are then informational: image search is not expected to work). On a multimodal install it warns with the counts (text coverage counts those pages as embedded while image search does not see them) and names `gbrain embed --stale --images` and `gbrain sync --no-pull --source <id>` for the holds. Read-only; no paid call. Test: `test/doctor-image-embedding-coverage.test.ts`.- `src/commands/doctor/checks/provider-consent.ts` — `provider_consent` (OPS, engine-free filesystem lane right after `embedding_key_source`; not in `doctorReportRemote`): the provider-use decision `gbrain setup` recorded for this install (`localSetupRecords` in `src/core/setup/local-receipts.ts`). A decline (any live receipt; opt-outs win) is `ok` + info `disabled_by_choice`, "skipped by consent", naming the provider key variables present (names only) and carrying `providerConsentFix`: `gbrain setup <harness> --providers` (+ `--name`/`--scope project`), actor `user`, consent `paid`+`egress`, so `next: tell_user_to_run`. Accepted is plain `ok`; no receipt is info `not_applicable`. The same fix rides `embedding_provider`'s `--probe` skip (`checks/embedding-health.ts`), and `probe-consent.ts` authorizes nothing when a decline is recorded. Reads files only; sends nothing. Pinned by `test/doctor-provider-consent.serial.test.ts` (request counter: zero outbound under a decline, controls prove discovery and the probe are seen otherwise).-- `src/commands/doctor/budget.ts` + `checks/ops-sections.ts` + `checks/orphan-estimate.ts` — doctor tiers and budgets (#6696 B1). `parseDoctorTier` (`--tier ops|standard|deep`, a bad value is `invalid_params`), `parseBudgetMs` (`--budget-ms`, default 4000 under ops, none otherwise) and `startDoctorDeadline` build the `DoctorDeadline` the CLI starts before connecting. `runDoctorRegistry` runs the entries tagged `tier: 'ops'` (persistence capacity, terminal failures, managed sync movement, persistence compaction, serve build drift, schema-pack consistency, embedding state) right after the connection lane; under `--tier ops` it runs only those, reads through `deadlineEngine` (each `executeRaw` gets the absolute `deadlineAt`, so `SET LOCAL statement_timeout` is the time left after the pool wait: `postgres-engine/bounded-statement.ts`), reports an entry marked `opsPglite: 'not_applicable'` as an `ok` info row on PGLite, and stays complete. Every other tier bounds each entry by `doctor.entry_budget_ms` (default 15000). An entry past its budget, an unknown reported after the overall deadline, or a connect the deadline ended becomes `budgetUnknownCheck` (warn, `details.health: 'unknown'`, `reason: 'budget'`, `exact: false`, a rerun-alone fix), never a clear result; every check carries `elapsed_ms`, and the report adds `tier`/`complete`/`unknown_sections`/`elapsed_ms`/`budget_ms` only when `--tier` or `--budget-ms` was given (`doctorRunSummary`). `doctorHealth(ctx)` memoizes `getHealth` for one run. `orphan_ratio` estimates from a `TABLESAMPLE SYSTEM` sample above `doctor.orphan_ratio.full_scan_max_pages` (default 50000) unless `--tier deep`. Capacity (`persistence_capacity`, PR A's forecast) and compaction freshness (`persistence_compaction`) run as ops entries in `checks/ops-sections.ts`. Tests: `test/doctor-tier-6696.test.ts`, `test/doctor-day-zero.test.ts` (`--tier ops`), `test/e2e/doctor-ops-tier-postgres.test.ts`.+- `src/commands/doctor/budget.ts` + `checks/ops-sections.ts` + `checks/orphan-estimate.ts` — doctor tiers and budgets (#6696 B1). `parseDoctorTier` (`--tier ops|standard|deep`, a bad value is `invalid_params`), `parseBudgetMs` (`--budget-ms`, default 4000 under ops, none otherwise) and `startDoctorDeadline` build the `DoctorDeadline` the CLI starts before connecting. `runDoctorRegistry` runs the entries tagged `tier: 'ops'` (persistence capacity, terminal failures, managed sync movement, persistence compaction, serve build drift, schema-pack consistency, embedding state) right after the connection lane; under `--tier ops` it runs only those (each `executeRaw` gets the absolute `deadlineAt`, so `SET LOCAL statement_timeout` is the time left after the pool wait: `postgres-engine/bounded-statement.ts`), reports an entry marked `opsPglite: 'not_applicable'` as an `ok` info row on PGLite, and stays complete. Every other tier bounds each entry by `doctor.entry_budget_ms` (default 15000). An entry past its budget, an unknown reported after the overall deadline, or a connect the deadline ended becomes `budgetUnknownCheck` (warn, `details.health: 'unknown'`, `reason: 'budget'`, `exact: false`, a rerun-alone fix), never a clear result; every check carries `elapsed_ms`, and the report adds `tier`/`complete`/`unknown_sections`/`elapsed_ms`/`budget_ms` only when `--tier` or `--budget-ms` was given (`doctorRunSummary`). `doctorHealth(ctx)` memoizes `getHealth` for one run. `orphan_ratio` estimates from a `TABLESAMPLE SYSTEM` sample above `doctor.orphan_ratio.full_scan_max_pages` (default 50000) unless `--tier deep`. Capacity (`persistence_capacity`, PR A's forecast) and compaction freshness (`persistence_compaction`) run as ops entries in `checks/ops-sections.ts`. #6803 (Part 5): on every tier each entry runs inside its own `StatementDeadline` (`src/core/statement-deadline.ts`: an AsyncLocalStorage scope plus `deadlineBoundEngine`, one stable Proxy per real engine that refuses any engine call past the deadline, carries the deadline to the server on Postgres `executeRaw`, and marks the scope expired on a cancel even when the check catches it; `engineCacheKey` maps the wrapper to the real engine for engine-keyed caches; PGLite gets only the pre-statement refusal). The budget-config read is one bounded statement (2 s, default kept). `CHEAP_INCIDENT_CHECKS` (by check name: persistence capacity, managed sync movement, `text_projection_readiness`, `partial_embedding`, `links_extraction_lag`, now its own entry) run right after the ops sections, before any full scan. `scanDeadline` clips the frontmatter walk and the fence census to the entry deadline less 250 ms, so they report partial results. `--only` with an explicit `--budget-ms` gives the selected entries the whole overall budget; `budgetUnknownCheck` names the limiting budget (`details.limit`: `entry` or `overall`) and fixes with `--only <check> --budget-ms N` (N ten times that budget; actor agent while N fits `AGENT_TOOL_LIMIT_MS` less 10 s, else actor user). `--budget-ms 0` is no overall budget. `default-budget.ts`: a plain non-interactive CLI `doctor --json` (stderr not a TTY; no `--budget-ms`, `--tier`, `--fix`, `--remediate` or `--remediation-plan`) caps its check run at `doctor.default_budget_ms` (file plane, default 90000, 0 off), started by `startDeferredDeadline` when the registry starts (connect and migrations are outside it), with one stderr line; the report then carries the tier fields. `capacity-memo.ts` `doctorCapacityForecast`: one forecast per run (shared by `persistence_capacity` and `persistence_request_growth`) read under the run's overall deadline and dropped from the memo on a deadline failure, which makes the waiting check unknown instead of a counter-only verdict. `persistence_session_timeouts` reads `SHOW statement_timeout` outside the entry deadline. Tests: `test/doctor-tier-6696.test.ts`, `test/doctor-day-zero.test.ts` (`--tier ops`), `test/e2e/doctor-ops-tier-postgres.test.ts`, `test/doctor-entry-deadline-6803.test.ts` (plus `test/e2e/doctor-entry-deadline-postgres.test.ts`, in the PgBouncer matrix), `test/doctor-default-budget-6803.test.ts`; bench `scripts/bench/doctor-scale.ts`.- `src/commands/doctor/brain-health-bands.ts` + `remote-tier.ts` + `ops-snapshot.ts`, `src/core/doctor-remote-tier.ts`, `src/core/persistence/capacity-view.ts` — the ops tier for agents and remote clients (#6696 B2). `readCapacityView` (for `/admin/api/ops`) reads the counter rows, `capacityDiagnostics`, the light `readCapacityForecast` (null when unreadable: days unknown) and `readLastCompaction`; the bands read `cachedCapacitySnapshot`; `capacityVerify()` is the verify of every capacity fix (`gbrain doctor --only persistence_capacity --json` plus MCP `get_brain_health`). `readBrainHealthBands` backs the read-scope `get_brain_health` op: capacity band and days band, write failures and active blockers as count bands for the caller's readable sources, no slugs or exact counters, cached 60 s per engine and scope. `runRemoteDoctorTier` backs `run_doctor`'s `tier: "ops"` / `only` (admin). `runScopedRemoteDoctor` is the thin client's `gbrain doctor --tier ops` / `--only <registry check>`: it reads `tools/list` and uses `run_doctor` with the parameters, else the bands (`BAND_CHECKS`), else refuses `doctor_tier_unavailable`; it never runs the full remote report in their place. `cachedOpsSnapshot` serves `/admin/api/ops` from one ops run a minute. Tests: `test/doctor-ops-remote-6696.test.ts`.++ - `src/commands/doctor/checks/rename-identity-downgrades.ts` — `rename_identity_downgrades` (#6729): warn while a downgraded rename record is open (`sync-identity-downgrades.ts`), naming up to 5 pairs with their facts and links; fix = restore the first restorable old page (`gbrain restore <old-slug> --source-id <id> --force`), behind ask_user; a source where the restore is unavailable is named instead.++ - `src/commands/doctor/checks/purge-parks.ts` — `purge_parked_pages` (#6741 C): names parked purges with their last error; fix `gbrain pages purge-deleted --retry-parked --yes` (preview `--dry-run --json`), consent destructive, ask_user.diff --cc docs/architecture/key-files/core-persistence-capacity.mdindex 473c6d0ecb,2404e95b3f..448542b3ed--- a/docs/architecture/key-files/core-persistence-capacity.md+++ b/docs/architecture/key-files/core-persistence-capacity.md@@@ -4,9 -4,10 +4,10 @@@ Cumulative write caps (permanent reques- `src/core/persistence/receipt-bytes.ts` — `receiptReservation({intent, authority}, extra)`: what an admission reserves (serialized intent and authority plus `RECEIPT_COMPLETION_BYTES` 12 KiB, never below `RECEIPT_RESERVATION_FLOOR` 16 KiB) on single, group and caller-overridden paths (`journal.ts` takes the larger of a caller's value and the formula); `reservationForRetained` is the same estimate from bytes alone (the sync preflight); `retainedReceiptBytes` is what a terminal or compacted row keeps, shared with `intent-redaction.ts` and compaction; `EFFECT_BYTES_SQL` and `TRUE_UP_CLAMP_SQL` (counts clamped decrements under `persistence.true_up.clamped`).- `src/core/persistence/receipt-true-up.ts` — `trueUpRequests(engine, ids)`: after the settling transaction commits, in its own short transaction, locks the brain and principal counters in key order, then a compare-and-set on each request row (still `terminal_reservation` as read, no queued or running effect, same effect bytes) shrinks it to `retainedReceiptBytes` and releases the difference. Idempotent; never touches `updated_at`. Called from the effect runner (`effects.ts`, every claimed request), `embedding-settlement.ts`, `embedding-noop-settle.ts` (the `embed --stale` bulk settle), `effect-retry.ts` (reconciled) and `backup/snapshot.ts` (restore). `test/persistence-true-up-sites.test.ts` fails on an effect state-change site that is not wired. `sweepCompactedReservations` is the bounded one-shot pass over receipts compacted with their full reservation (cursor `persistence.true_up.compacted_through`, `done` at the end).- - `src/core/persistence/admission-origin.ts` — `withAdmissionOrigin('interactive' | 'background')` (an outer background scope wins), `resolveAdmissionOrigin` (unset reads background, never derived from `ctx.remote`), `persistence.capacity.background_pause_pct` (default 80) and `backgroundPaused`, the `write_capacity_backpressure` refusal background producers get past the line.+ - `src/core/persistence/admission-origin.ts` — `withAdmissionOrigin('interactive' | 'background')` (an outer background scope wins), `resolveAdmissionOrigin` (unset reads background, never derived from `ctx.remote`), `persistence.capacity.background_pause_pct` (default 80) and `backgroundPaused`, the `write_capacity_backpressure` refusal background producers get past the line. A background scope also carries the per-run owner cache (`backgroundOwnerCheck`); `backgroundWorktreeInactive` (a `recovering` worktree, read under the admission's lock in `journal.ts`) and `backgroundOwnerUnverified` refuse `owner_unavailable` pre-receipt with the owner-status fix; a draining worktree still admits.+ - `src/core/persistence/owner-verification.ts` — #6741 C: the claim's owner verification (`verifyOwnerRoot`: paths recorded, physical root, marker and reservation intact; a device-only change is `restampable`), shared by writer onboarding and background admissions; `assertBackgroundOwner` refuses a background admission `owner_unavailable` once per source per run (cache: admission-origin.ts `backgroundOwnerCheck`). Tests: `test/background-owner-verification.test.ts`.- `src/core/persistence/capacity-forecast.ts` — `readCapacityForecast`: per principal, one statement walks `persistence_requests_principal` newest first until `created_at` leaves the 7-day window and buckets by day; gross and net (compacted) receipt rates, `days_to_exhaustion`, `basis` (`:legacy_under_reserved` while receipts admitted before the intent-sized reservation remain), `recommended_limit`. `light` skips the reclaim read and table size. Thresholds `persistence.capacity.warn_days` (30) and `fail_days` (7).-- `src/core/persistence/capacity-snapshot.ts` — `cachedCapacitySnapshot`: one light forecast per engine per 60 s, shared by every caller; `capacityNotices` builds `write_capacity_low` (kind `info`, muteable; hourly per process per scope on write and sync receipts, `scopes` limits a remote caller to the brain and its own principal) and `write_capacity_backpressure` (once per pause start). Read by `mcp/dispatch.ts`, `cli/main.ts`, `commands/sync/{run,operator}.ts`, `cycle.ts` and the admin `/metrics` gauges in `serve-http-metrics.ts`.+- `src/core/persistence/capacity-snapshot.ts` — `cachedCapacitySnapshot`: one light forecast per engine per 60 s, shared by every caller; `capacityNotices` builds `write_capacity_low` (kind `info`, muteable; hourly per process per scope on write and sync receipts, `scopes` limits a remote caller to the brain and its own principal) and `write_capacity_backpressure` (once per pause start). Read by `mcp/dispatch.ts`, `cli/main.ts`, `commands/sync/{run,operator}.ts`, `cycle.ts` and the admin `/metrics` gauges in `serve-http-metrics.ts`. #6803: the cache keys on the real engine (`engineCacheKey`), the shared fetch is bounded at `CAPACITY_FETCH_BOUND_MS` (10 s) and a timed-out fetch is never cached; `capacitySnapshotWithin` (sync status, write and sync receipts: `CAPACITY_READ_WAIT_MS`, 1.5 s) returns `unknown` for that call alone, and `capacityNotices` on an unknown snapshot returns no notice and leaves throttle and pause state as it was. Test: `test/capacity-bounded-read-6803.test.ts`.- `src/core/persistence/compaction-pass.ts` — `runCompactionPass`, the consumer's idle and volume maintenance: `compactWriteReceiptsDetailed`, one sweep step, and the `persistence.maintenance.last_compaction` record (`at`, `host_id`, `compacted`, `freed_bytes`, `skipped_by_reason`). `journal.ts` `compactReceipt` compacts one receipt in its own transaction (counters first, `lock_timeout` 2 s, `statement_timeout` 15 s) and skips open managed-sync runs (`OPEN_SYNC_CURSOR_EXCLUSION`) and the newest sync receipt per worktree (`newestSyncReceipt`).- `src/core/repair/receipt-compaction.ts` — `gbrain repair receipt-compaction`: explicit-only, preview-bound, destructive consent, `publication: 'projection'`; `--older-than` (the `pages purge-deleted` grammar) floored at the configured retention unless `--force`, committed only unless `--include-failures`; the approved set binds an absolute cutoff and the newest sequence. Test: `test/repair-receipt-compaction.test.ts`.- `src/core/persistence/refusal-breaker.ts` — `assertRefusalBreakerClosed`: `submitMaintenance` refuses before admission after `persistence.maintenance.refusal_breaker_threshold` (3; 0 off) same-code terminal refusals in 24 h for the same request `digest` (source, slug, intent with its revision and planner); `listSuppressedWrites` feeds doctor `maintenance_write_drift`. The ghost case (`canonical_file_missing`, tagged by `page-prepare.ts`, kept in `error_detail.origin`, returned by `liveFileDrift`) refuses before admission in `prepared-maintenance.ts`. Test: `test/maintenance-ghost-breaker-6696.test.ts`.diff --cc scripts/e2e-weights.jsonindex c499d51dcc,98f2ef628a..a3ab049976--- a/scripts/e2e-weights.json+++ b/scripts/e2e-weights.json@@@ -1,587 -1,600 +1,604 @@@{- "test/e2e/access-token-grants.test.ts": 9660,- "test/e2e/agent-journey-postgres.test.ts": 18270,- "test/e2e/anomalies-pglite.test.ts": 1241,- "test/e2e/apply-migrations-orchestration-lock.test.ts": 6050,- "test/e2e/apply-migrations-schema-exit.test.ts": 6180,- "test/e2e/attendance-repair-postgres.test.ts": 23030,- "test/e2e/attendance-retrieval-postgres.test.ts": 38900,- "test/e2e/audit-pooler-misroute-postgres.test.ts": 3960,- "test/e2e/auth-clients-operations-postgres.test.ts": 22930,- "test/e2e/auth-permissions.test.ts": 1176,- "test/e2e/auth-rescope-token.test.ts": 2740,- "test/e2e/auth-takes-holders-pglite.test.ts": 631,- "test/e2e/autopilot-auto-drain-dispatch.test.ts": 1103,- "test/e2e/autopilot-cooldown-parity.test.ts": 3210,- "test/e2e/autopilot-fanout-postgres.test.ts": 1530,- "test/e2e/autopilot-linux-lifecycle.serial.test.ts": 5350,- "test/e2e/autopilot-multi-brain.serial.test.ts": 21910,- "test/e2e/backup-coverage-parity.test.ts": 1530,- "test/e2e/bootstrap-attach.serial.test.ts": 4370,- "test/e2e/bootstrap-compiled-binary.serial.test.ts": 2780,- "test/e2e/bootstrap-degraded-modes.serial.test.ts": 4220,- "test/e2e/bootstrap-keyed-postgres.serial.test.ts": 13400,- "test/e2e/bootstrap-lifecycle.serial.test.ts": 5840,- "test/e2e/bootstrap-magic-moment.serial.test.ts": 3600,- "test/e2e/bootstrap-persistence.serial.test.ts": 812,- "test/e2e/bootstrap-real-claude.serial.test.ts": 734,- "test/e2e/bootstrap-real-codex.serial.test.ts": 450,- "test/e2e/brainstorm-resume.test.ts": 3830,- "test/e2e/budget-meter-group.test.ts": 1290,- "test/e2e/cache-gate-pglite.test.ts": 1500,- "test/e2e/calibration-profile-write.test.ts": 3050,- "test/e2e/canonical-projection-history.test.ts": 4170,- "test/e2e/canonical-projection-statements.test.ts": 7230,- "test/e2e/capture-dedup-postgres.test.ts": 19880,- "test/e2e/capture-generation-regression.test.ts": 1100,- "test/e2e/chronicle-auto-decision-postgres.test.ts": 52550,- "test/e2e/chronicle-auto-phase-postgres.test.ts": 70800,- "test/e2e/chronicle-date-quality-postgres.test.ts": 23060,- "test/e2e/chronicle-event-identity-postgres.test.ts": 8390,- "test/e2e/chronicle-event-privacy-postgres.test.ts": 1900,- "test/e2e/chronicle-event-projection-parity.test.ts": 1183,- "test/e2e/chronicle-invite-projection-postgres.test.ts": 15130,- "test/e2e/chronicle-last-seen-postgres.test.ts": 641,- "test/e2e/chronicle-max-events-5329-postgres.test.ts": 10700,- "test/e2e/chronicle-surfaces-postgres.test.ts": 1000,- "test/e2e/chunk-canonical-text-privacy.test.ts": 1540,- "test/e2e/chunker-takes-strip.test.ts": 1510,- "test/e2e/cjk-keyword-deadline-postgres.test.ts": 45140,- "test/e2e/cjk-roundtrip.test.ts": 1560,- "test/e2e/claim-earlier-equivalence.test.ts": 4140,- "test/e2e/claude-plugin-install-real.serial.test.ts": 557,- "test/e2e/cli-json-commands-postgres.test.ts": 2900,- "test/e2e/cli-source-scoping-pglite.test.ts": 910,- "test/e2e/client-grants.test.ts": 1940,- "test/e2e/code-edges-jsonb-postgres.test.ts": 2740,- "test/e2e/code-edges-read-parity.test.ts": 1144,- "test/e2e/code-indexing.test.ts": 1760,- "test/e2e/code-intel-mcp-ops-pglite.test.ts": 2740,- "test/e2e/code-intel-n13-postgres.test.ts": 2610,- "test/e2e/code-intel-walk-resolved-ids-postgres.test.ts": 3190,- "test/e2e/codex-plugin-install-real.serial.test.ts": 430,- "test/e2e/company-brain-receipts.test.ts": 2140,- "test/e2e/compile-context-pglite.test.ts": 860,- "test/e2e/concept-publication-file-recheck-postgres.test.ts": 1880,- "test/e2e/concurrent-embed-race.test.ts": 931,- "test/e2e/connector-cycle-extract-postgres.test.ts": 5170,- "test/e2e/connector-holds.test.ts": 17780,- "test/e2e/connector-sync-handler-pglite.test.ts": 1428,- "test/e2e/connector-wave3.test.ts": 45090,- "test/e2e/connectors-ingest-failure-pglite.test.ts": 1520,- "test/e2e/connectors-sync-checkpoints-pglite.test.ts": 5590,- "test/e2e/connectors-sync-pglite.test.ts": 8470,- "test/e2e/consolidate-divergence-postgres.test.ts": 623,- "test/e2e/consumer-idle-lane-single-flight-postgres.test.ts": 1424,- "test/e2e/context-engine-rung3-extraction.test.ts": 4030.0000000000005,- "test/e2e/context-pack-provenance-postgres.test.ts": 6280,- "test/e2e/contextual-retrieval-pglite.test.ts": 2009.9999999999998,- "test/e2e/conversation-facts-keyset-6500-postgres.test.ts": 8180,- "test/e2e/conversation-facts-managed-postgres.test.ts": 43220,- "test/e2e/conversation-parser-pglite.test.ts": 3070,- "test/e2e/core-memory-locks-postgres.test.ts": 6630,- "test/e2e/credential-projection-repair.test.ts": 4390,- "test/e2e/cross-modal-eval.test.ts": 118,- "test/e2e/cycle-consolidate-postgres.test.ts": 806,- "test/e2e/cycle-maintenance-lock.test.ts": 1495,- "test/e2e/cycle-recompute-emotional-weight-pglite.test.ts": 864,- "test/e2e/cycle.test.ts": 2610,- "test/e2e/daily-ledger-postgres.test.ts": 2880,- "test/e2e/db-connect-timeout.test.ts": 265,- "test/e2e/db-guard.test.ts": 374,- "test/e2e/db-lock-acquisition-token.test.ts": 359,- "test/e2e/db-lock-token-predicate-postgres.test.ts": 2930,- "test/e2e/db-singleton-shared-recovery.test.ts": 208,- "test/e2e/decide-store-postgres.test.ts": 1369,- "test/e2e/deep-research-http.test.ts": 2730,- "test/e2e/deep-research-source-id.test.ts": 10800,- "test/e2e/delegated-grants-withdrawal.test.ts": 1650,- "test/e2e/delegated-http-worker.test.ts": 2150,- "test/e2e/delta-cursor-integrity-postgres.test.ts": 7150,- "test/e2e/derived-page-visibility.test.ts": 5780,- "test/e2e/derived-visibility-repair.test.ts": 9940,- "test/e2e/doctor-connectors-pglite.test.ts": 2150,+ "test/e2e/access-token-grants.test.ts": 1427,+ "test/e2e/agent-journey-postgres.test.ts": 13280,+ "test/e2e/amends-link-postgres.test.ts": 4460,+ "test/e2e/anomalies-pglite.test.ts": 1148,+ "test/e2e/apply-migrations-orchestration-lock.test.ts": 5080,+ "test/e2e/apply-migrations-schema-exit.test.ts": 3150,+ "test/e2e/attendance-repair-postgres.test.ts": 15930,+ "test/e2e/attendance-retrieval-postgres.test.ts": 27270,+ "test/e2e/audit-pooler-misroute-postgres.test.ts": 1494,+ "test/e2e/auth-clients-operations-postgres.test.ts": 2550,+ "test/e2e/auth-permissions.test.ts": 1061,+ "test/e2e/auth-rescope-token.test.ts": 1035,+ "test/e2e/auth-takes-holders-pglite.test.ts": 609,+ "test/e2e/autopilot-auto-drain-dispatch.test.ts": 1061,+ "test/e2e/autopilot-cooldown-parity.test.ts": 1402,+ "test/e2e/autopilot-fanout-postgres.test.ts": 1343,+ "test/e2e/autopilot-linux-lifecycle.serial.test.ts": 3910,+ "test/e2e/autopilot-multi-brain.serial.test.ts": 19930,+ "test/e2e/backup-coverage-parity.test.ts": 1439,+ "test/e2e/bootstrap-attach.serial.test.ts": 4430,+ "test/e2e/bootstrap-compiled-binary.serial.test.ts": 2710,+ "test/e2e/bootstrap-degraded-modes.serial.test.ts": 3540,+ "test/e2e/bootstrap-keyed-postgres.serial.test.ts": 9530,+ "test/e2e/bootstrap-lifecycle.serial.test.ts": 4340,+ "test/e2e/bootstrap-magic-moment.serial.test.ts": 4790,+ "test/e2e/bootstrap-persistence.serial.test.ts": 664,+ "test/e2e/bootstrap-real-claude.serial.test.ts": 501,+ "test/e2e/bootstrap-real-codex.serial.test.ts": 414,+ "test/e2e/brainstorm-resume.test.ts": 3680,+ "test/e2e/budget-meter-group.test.ts": 1341,+ "test/e2e/cache-gate-pglite.test.ts": 1445,+ "test/e2e/calibration-profile-write.test.ts": 1680,+ "test/e2e/canonical-projection-history.test.ts": 5020,+ "test/e2e/canonical-projection-statements.test.ts": 5120,+ "test/e2e/capture-dedup-postgres.test.ts": 12270,+ "test/e2e/capture-generation-regression.test.ts": 1201,+ "test/e2e/chronicle-auto-decision-postgres.test.ts": 7970,+ "test/e2e/chronicle-auto-phase-postgres.test.ts": 43390,+ "test/e2e/chronicle-date-quality-postgres.test.ts": 16190.000000000002,+ "test/e2e/chronicle-event-identity-postgres.test.ts": 11890,+ "test/e2e/chronicle-event-privacy-postgres.test.ts": 2100,+ "test/e2e/chronicle-event-projection-parity.test.ts": 1245,+ "test/e2e/chronicle-invite-projection-postgres.test.ts": 16840,+ "test/e2e/chronicle-last-seen-postgres.test.ts": 754,+ "test/e2e/chronicle-max-events-5329-postgres.test.ts": 9620,+ "test/e2e/chronicle-surfaces-postgres.test.ts": 912,+ "test/e2e/chunk-canonical-text-privacy.test.ts": 1373,+ "test/e2e/chunker-takes-strip.test.ts": 939,+ "test/e2e/cjk-keyword-deadline-postgres.test.ts": 30420,+ "test/e2e/cjk-roundtrip.test.ts": 1088,+ "test/e2e/claim-earlier-equivalence.test.ts": 4490,+ "test/e2e/claude-plugin-install-real.serial.test.ts": 448,+ "test/e2e/cli-json-commands-postgres.test.ts": 1190,+ "test/e2e/cli-source-scoping-pglite.test.ts": 1126,+ "test/e2e/client-grants.test.ts": 2470,+ "test/e2e/code-edges-jsonb-postgres.test.ts": 897,+ "test/e2e/code-edges-read-parity.test.ts": 1337,+ "test/e2e/code-indexing.test.ts": 1620,+ "test/e2e/code-intel-mcp-ops-pglite.test.ts": 2750,+ "test/e2e/code-intel-n13-postgres.test.ts": 2820,+ "test/e2e/code-intel-walk-resolved-ids-postgres.test.ts": 2590,+ "test/e2e/codex-plugin-install-real.serial.test.ts": 426,+ "test/e2e/company-brain-receipts.test.ts": 1810,+ "test/e2e/compile-context-pglite.test.ts": 1009,+ "test/e2e/concept-publication-file-recheck-postgres.test.ts": 2110,+ "test/e2e/concurrent-embed-race.test.ts": 909,+ "test/e2e/connector-cycle-extract-postgres.test.ts": 3250,+ "test/e2e/connector-holds.test.ts": 13940,+ "test/e2e/connector-sync-handler-pglite.test.ts": 1139,+ "test/e2e/connector-wave3.test.ts": 53270,+ "test/e2e/connectors-ingest-failure-pglite.test.ts": 1022,+ "test/e2e/connectors-sync-checkpoints-pglite.test.ts": 2900,+ "test/e2e/connectors-sync-pglite.test.ts": 4940,+ "test/e2e/consolidate-divergence-postgres.test.ts": 801,+ "test/e2e/consumer-idle-lane-single-flight-postgres.test.ts": 3830,+ "test/e2e/context-engine-rung3-extraction.test.ts": 1428,+ "test/e2e/context-pack-provenance-postgres.test.ts": 776,+ "test/e2e/contextual-retrieval-pglite.test.ts": 2040,+ "test/e2e/conversation-facts-keyset-6500-postgres.test.ts": 8830,+ "test/e2e/conversation-facts-managed-postgres.test.ts": 26050,+ "test/e2e/conversation-parser-pglite.test.ts": 3150,+ "test/e2e/core-memory-locks-postgres.test.ts": 4890,+ "test/e2e/cosine-rescore-sql-postgres.test.ts": 2140,+ "test/e2e/credential-projection-repair.test.ts": 3740,+ "test/e2e/cross-modal-eval.test.ts": 113,+ "test/e2e/cycle-consolidate-postgres.test.ts": 992,+ "test/e2e/cycle-maintenance-lock.test.ts": 1021,+ "test/e2e/cycle-patterns-segmented-postgres.test.ts": 4110,+ "test/e2e/cycle-recompute-emotional-weight-pglite.test.ts": 779,+ "test/e2e/cycle.test.ts": 2670,+ "test/e2e/daily-ledger-postgres.test.ts": 1211,+ "test/e2e/db-connect-timeout.test.ts": 258,+ "test/e2e/db-guard.test.ts": 241,+ "test/e2e/db-lock-acquisition-token.test.ts": 425,+ "test/e2e/db-lock-token-predicate-postgres.test.ts": 1770,+ "test/e2e/db-singleton-shared-recovery.test.ts": 169,+ "test/e2e/decide-store-postgres.test.ts": 764,+ "test/e2e/deep-research-http.test.ts": 1950,+ "test/e2e/deep-research-source-id.test.ts": 8640,+ "test/e2e/delegated-grants-withdrawal.test.ts": 1570,+ "test/e2e/delegated-http-worker.test.ts": 2029.9999999999998,+ "test/e2e/delta-cursor-integrity-postgres.test.ts": 8730,+ "test/e2e/derived-page-visibility.test.ts": 2920,+ "test/e2e/derived-visibility-repair.test.ts": 8280,+ "test/e2e/doctor-connectors-pglite.test.ts": 1630,+ "test/e2e/doctor-entry-deadline-postgres.test.ts": 32000,- "test/e2e/doctor-hot-checks-golden.test.ts": 23850,- "test/e2e/doctor-json-golden.test.ts": 8760,- "test/e2e/doctor-ops-tier-postgres.test.ts": 2009.9999999999998,- "test/e2e/doctor-progress.test.ts": 6730,- "test/e2e/doctor-revision-backfill-postgres.test.ts": 11240,- "test/e2e/doctor-silent-death-parity.test.ts": 2970,- "test/e2e/dream-allow-list-pglite.test.ts": 1660,- "test/e2e/dream-breaker-postgres.test.ts": 680,- "test/e2e/dream-cycle-phase-order-pglite.test.ts": 3830,- "test/e2e/dream-patterns-pglite.test.ts": 2590,- "test/e2e/dream-synthesize-concurrency-postgres.test.ts": 8320,- "test/e2e/dream-synthesize-pglite.test.ts": 12030,- "test/e2e/dream-triage-backoff-postgres.test.ts": 1129,- "test/e2e/dream-triage-postgres.test.ts": 1479,- "test/e2e/dream.test.ts": 3040,- "test/e2e/edge-proposals-json-postgres.test.ts": 1580,- "test/e2e/embed-background-cap.test.ts": 859,- "test/e2e/embed-stale-dry-run-restamp-5289-postgres.test.ts": 3950,- "test/e2e/embed-stale-pagination.test.ts": 2140,- "test/e2e/embed-stale-pool-default-postgres.test.ts": 8020,- "test/e2e/embedding-column-pglite.test.ts": 1158,- "test/e2e/embedding-column-postgres.test.ts": 614,- "test/e2e/embedding-migration-settle-postgres.test.ts": 19960,- "test/e2e/embedding-recovery-parity.test.ts": 47950,- "test/e2e/embedding-state-postgres.test.ts": 739,- "test/e2e/embedding-tombstones-postgres.test.ts": 3690,- "test/e2e/embedding-zero-norm-4616-postgres.test.ts": 2830,- "test/e2e/engine-content-privacy.test.ts": 5560,- "test/e2e/engine-parity-cjk.test.ts": 1373,- "test/e2e/engine-parity-salience.test.ts": 3250,- "test/e2e/engine-parity.test.ts": 47810,- "test/e2e/engine-sql-capabilities-parity.test.ts": 1750,- "test/e2e/engine-sql-health-parity.test.ts": 12750,- "test/e2e/engine-sql-normalize-parity.test.ts": 3380,- "test/e2e/engine-sql-prepare-parity.test.ts": 1670,- "test/e2e/engine-sql-rls-scope.test.ts": 2350,- "test/e2e/engine-sql-transaction-parity.test.ts": 1680,- "test/e2e/enrich-pglite.test.ts": 10090,- "test/e2e/entity-names-parity-postgres.test.ts": 5070,- "test/e2e/eval-capture.test.ts": 403,- "test/e2e/eval-contradictions-postgres.test.ts": 650,- "test/e2e/eval-loop.test.ts": 1172,- "test/e2e/eval-replay-column.test.ts": 685,- "test/e2e/eval-takes-quality.test.ts": 745,- "test/e2e/evidence-delivery-leak.test.ts": 42820,- "test/e2e/evidence-delivery-parity.test.ts": 15130,- "test/e2e/executor-binding-matrix.test.ts": 1206,- "test/e2e/export-db-only-own-lease-postgres.test.ts": 3540,- "test/e2e/export-snapshot-postgres.test.ts": 6450,- "test/e2e/extract-atoms-discovery-sql.test.ts": 844,- "test/e2e/extract-atoms-drain-postgres.test.ts": 898,- "test/e2e/extract-atoms-page-state.test.ts": 7950,- "test/e2e/extract-db-batch-equivalence.test.ts": 44060,- "test/e2e/extract-endpoint-revision-postgres.test.ts": 3650,- "test/e2e/extract-facts-reconcile-drain-postgres.test.ts": 39830,- "test/e2e/extract-facts-unfenced-rows-postgres.test.ts": 11720,- "test/e2e/extract-rollup-halt-reasons-5495-postgres.test.ts": 2700,- "test/e2e/extract-takes-from-pages-resolutions.test.ts": 11790,- "test/e2e/extract-takes-managed.test.ts": 3680,- "test/e2e/extract-timeline-attendance-postgres.test.ts": 8660,- "test/e2e/extract-timeline-db-postgres.test.ts": 4140,+ "test/e2e/doctor-hot-checks-golden.test.ts": 28900,+ "test/e2e/doctor-json-golden.test.ts": 4990,+ "test/e2e/doctor-ops-tier-postgres.test.ts": 2090,+ "test/e2e/doctor-progress.test.ts": 5300,+ "test/e2e/doctor-revision-backfill-postgres.test.ts": 10820,+ "test/e2e/doctor-silent-death-parity.test.ts": 3030,+ "test/e2e/dream-allow-list-pglite.test.ts": 1540,+ "test/e2e/dream-breaker-postgres.test.ts": 1179,+ "test/e2e/dream-cycle-phase-order-pglite.test.ts": 3380,+ "test/e2e/dream-patterns-pglite.test.ts": 2990,+ "test/e2e/dream-synthesize-concurrency-postgres.test.ts": 11410,+ "test/e2e/dream-synthesize-pglite.test.ts": 12190,+ "test/e2e/dream-triage-backoff-postgres.test.ts": 787,+ "test/e2e/dream-triage-postgres.test.ts": 758,+ "test/e2e/dream.test.ts": 2020,+ "test/e2e/edge-proposals-json-postgres.test.ts": 1310,+ "test/e2e/embed-backfill-stall-postgres.test.ts": 3200,+ "test/e2e/embed-background-cap.test.ts": 745,+ "test/e2e/embed-stale-dry-run-restamp-5289-postgres.test.ts": 3990,+ "test/e2e/embed-stale-pagination.test.ts": 1388,+ "test/e2e/embed-stale-pool-default-postgres.test.ts": 5610,+ "test/e2e/embedding-column-pglite.test.ts": 755,+ "test/e2e/embedding-column-postgres.test.ts": 410,+ "test/e2e/embedding-migration-settle-postgres.test.ts": 8290,+ "test/e2e/embedding-recovery-parity.test.ts": 24910,+ "test/e2e/embedding-state-postgres.test.ts": 781,+ "test/e2e/embedding-tombstones-postgres.test.ts": 1417,+ "test/e2e/embedding-zero-norm-4616-postgres.test.ts": 3020,+ "test/e2e/engine-content-privacy.test.ts": 4670,+ "test/e2e/engine-parity-cjk.test.ts": 1233,+ "test/e2e/engine-parity-salience.test.ts": 2520,+ "test/e2e/engine-parity.test.ts": 18810,+ "test/e2e/engine-sql-capabilities-parity.test.ts": 1443,+ "test/e2e/engine-sql-health-parity.test.ts": 13110,+ "test/e2e/engine-sql-normalize-parity.test.ts": 1269,+ "test/e2e/engine-sql-prepare-parity.test.ts": 925,+ "test/e2e/engine-sql-rls-scope.test.ts": 1252,+ "test/e2e/engine-sql-transaction-parity.test.ts": 1540,+ "test/e2e/enrich-pglite.test.ts": 8270,+ "test/e2e/entity-names-parity-postgres.test.ts": 2920,+ "test/e2e/entity-records-postgres.test.ts": 4100,+ "test/e2e/eval-capture.test.ts": 446,+ "test/e2e/eval-contradictions-postgres.test.ts": 576,+ "test/e2e/eval-loop.test.ts": 709,+ "test/e2e/eval-replay-column.test.ts": 519,+ "test/e2e/eval-takes-quality.test.ts": 770,+ "test/e2e/evidence-delivery-leak.test.ts": 33570,+ "test/e2e/evidence-delivery-parity.test.ts": 6570,+ "test/e2e/evidence-long-page.test.ts": 4120,+ "test/e2e/executor-binding-matrix.test.ts": 1261,+ "test/e2e/export-db-only-own-lease-postgres.test.ts": 3480,+ "test/e2e/export-snapshot-postgres.test.ts": 3510,+ "test/e2e/extract-atoms-discovery-sql.test.ts": 693,+ "test/e2e/extract-atoms-drain-postgres.test.ts": 827,+ "test/e2e/extract-atoms-page-state.test.ts": 5340,+ "test/e2e/extract-db-batch-equivalence.test.ts": 29040,+ "test/e2e/extract-endpoint-revision-postgres.test.ts": 4780,+ "test/e2e/extract-facts-reconcile-drain-postgres.test.ts": 18640,+ "test/e2e/extract-facts-unfenced-rows-postgres.test.ts": 24000,+ "test/e2e/extract-rollup-halt-reasons-5495-postgres.test.ts": 3470,+ "test/e2e/extract-rollup-schema-errors-postgres.test.ts": 3650,+ "test/e2e/extract-takes-from-pages-resolutions.test.ts": 11360,+ "test/e2e/extract-takes-managed.test.ts": 2600,+ "test/e2e/extract-timeline-attendance-postgres.test.ts": 6090,+ "test/e2e/extract-timeline-db-postgres.test.ts": 4660,+ "test/e2e/extraction-nudge-6803-postgres.test.ts": 4200,- "test/e2e/extraction-review-postgres.test.ts": 8150,- "test/e2e/fact-embedding-backfill-parity.test.ts": 5810,- "test/e2e/fact-embedding-opt-out.test.ts": 4430,- "test/e2e/fact-fingerprint-search-path-postgres.test.ts": 1930,- "test/e2e/fact-vector-repair-parity.test.ts": 8400,- "test/e2e/fact-withdrawal-scope-postgres.test.ts": 5110,- "test/e2e/facts-context-injection-postgres.test.ts": 2120,- "test/e2e/facts-cross-source-isolation.test.ts": 1219,- "test/e2e/facts-fence-reconcile-postgres.test.ts": 3480,- "test/e2e/facts-forget.test.ts": 1920,- "test/e2e/facts-fts-index-postgres.test.ts": 2370,- "test/e2e/facts-notability-roundtrip.test.ts": 1375,- "test/e2e/facts-recall-event-time-postgres.test.ts": 1980,- "test/e2e/facts-recall-render.test.ts": 915,- "test/e2e/facts-relink-routing.test.ts": 3580,- "test/e2e/facts-separation-postgres.test.ts": 1760,- "test/e2e/facts-withdrawal-fingerprint-once.test.ts": 6540,- "test/e2e/facts-worker-config.test.ts": 3900,- "test/e2e/federated-link-reads-postgres.test.ts": 6860,- "test/e2e/feedback-parity.test.ts": 871,- "test/e2e/fence-census-postgres.test.ts": 1850,- "test/e2e/fence-chunk-overlay-postgres.test.ts": 4030.0000000000005,- "test/e2e/fence-chunk-trust-read-postgres.test.ts": 3620,- "test/e2e/fence-repair-attempts-postgres.test.ts": 2630,- "test/e2e/file-drift-bulk-reconcile-postgres.test.ts": 10000,- "test/e2e/fix-wave-3-integration.test.ts": 45490,- "test/e2e/fix-wave-4-integration.test.ts": 25420,- "test/e2e/fix-wave-4-lane-a.test.ts": 44840,- "test/e2e/fix-wave-5-integration.test.ts": 27220,- "test/e2e/fixture-reset-postgres.test.ts": 12360,- "test/e2e/frontmatter-migration.test.ts": 2670,- "test/e2e/fts-cjk-boundary-postgres.test.ts": 2460,- "test/e2e/get-health-embedding-column-postgres.test.ts": 1490,- "test/e2e/ghost-pages-6696-postgres.test.ts": 7630,- "test/e2e/global-basename-pglite.test.ts": 2570,- "test/e2e/google-attachments-postgres.test.ts": 33520,- "test/e2e/google-loops-recovery-postgres.test.ts": 13660,- "test/e2e/graduation-cli-history.test.ts": 171470,- "test/e2e/graduation-cli-topologies.test.ts": 34560,- "test/e2e/graduation-cli-zero-mutation-1.test.ts": 66980,- "test/e2e/graduation-cli-zero-mutation-2.test.ts": 93280,- "test/e2e/graduation-cli-zero-mutation-3.test.ts": 108550,- "test/e2e/graduation-cli.test.ts": 62550,- "test/e2e/graduation-clients-serve.test.ts": 73300,- "test/e2e/graduation-clients.test.ts": 119260,- "test/e2e/graduation-copy.test.ts": 97260,- "test/e2e/graduation-crash-rollback-1.test.ts": 82150,- "test/e2e/graduation-crash-rollback-2.test.ts": 85720,- "test/e2e/graduation-crash-run-1.test.ts": 63240,- "test/e2e/graduation-crash-run-2.test.ts": 128460.00000000001,- "test/e2e/graduation-crash-run-3.test.ts": 59830,- "test/e2e/graduation-faults.test.ts": 65930,- "test/e2e/graduation-legacy-copy.test.ts": 31450,- "test/e2e/grandfather-projection-postgres.test.ts": 14900,- "test/e2e/graph-quality.test.ts": 2110,- "test/e2e/graph-signals-engine.test.ts": 699,- "test/e2e/graph-signals-eval.test.ts": 4360,- "test/e2e/harness-access.test.ts": 3760,- "test/e2e/health-entity-types-pack.test.ts": 12000,- "test/e2e/health-parity-postgres.test.ts": 1315,+ "test/e2e/extraction-review-postgres.test.ts": 1067,+ "test/e2e/fact-embedding-backfill-parity.test.ts": 3910,+ "test/e2e/fact-embedding-opt-out.test.ts": 2480,+ "test/e2e/fact-fingerprint-search-path-postgres.test.ts": 1980,+ "test/e2e/fact-vector-repair-parity.test.ts": 3970,+ "test/e2e/fact-withdrawal-scope-postgres.test.ts": 3770,+ "test/e2e/facts-context-injection-postgres.test.ts": 1098,+ "test/e2e/facts-cross-source-isolation.test.ts": 754,+ "test/e2e/facts-fence-reconcile-postgres.test.ts": 3130,+ "test/e2e/facts-forget.test.ts": 778,+ "test/e2e/facts-fts-index-postgres.test.ts": 1730,+ "test/e2e/facts-notability-roundtrip.test.ts": 720,+ "test/e2e/facts-recall-event-time-postgres.test.ts": 912,+ "test/e2e/facts-recall-render.test.ts": 747,+ "test/e2e/facts-relink-routing.test.ts": 3510,+ "test/e2e/facts-separation-postgres.test.ts": 776,+ "test/e2e/facts-withdrawal-fingerprint-once.test.ts": 3460,+ "test/e2e/facts-worker-config.test.ts": 3110,+ "test/e2e/federated-link-reads-postgres.test.ts": 1750,+ "test/e2e/feedback-parity.test.ts": 967,+ "test/e2e/fence-census-postgres.test.ts": 1620,+ "test/e2e/fence-chunk-overlay-postgres.test.ts": 2040,+ "test/e2e/fence-chunk-trust-read-postgres.test.ts": 2430,+ "test/e2e/fence-repair-attempts-postgres.test.ts": 1960,+ "test/e2e/file-drift-bulk-reconcile-postgres.test.ts": 4910,+ "test/e2e/fix-wave-3-integration.test.ts": 27680,+ "test/e2e/fix-wave-4-integration.test.ts": 20760,+ "test/e2e/fix-wave-4-lane-a.test.ts": 34150,+ "test/e2e/fix-wave-5-integration.test.ts": 21420,+ "test/e2e/fixture-reset-postgres.test.ts": 10790,+ "test/e2e/frontmatter-migration.test.ts": 1980,+ "test/e2e/fts-cjk-boundary-postgres.test.ts": 1510,+ "test/e2e/get-health-embedding-column-postgres.test.ts": 750,+ "test/e2e/ghost-pages-6696-postgres.test.ts": 6290,+ "test/e2e/global-basename-pglite.test.ts": 1540,+ "test/e2e/google-attachments-postgres.test.ts": 44900,+ "test/e2e/google-loops-recovery-postgres.test.ts": 4450,+ "test/e2e/graduation-cli-history.test.ts": 215460,+ "test/e2e/graduation-cli-topologies.test.ts": 29840,+ "test/e2e/graduation-cli-zero-mutation-1.test.ts": 81190,+ "test/e2e/graduation-cli-zero-mutation-2.test.ts": 81140,+ "test/e2e/graduation-cli-zero-mutation-3.test.ts": 77830,+ "test/e2e/graduation-cli.test.ts": 75920,+ "test/e2e/graduation-clients-serve.test.ts": 85520,+ "test/e2e/graduation-clients.test.ts": 103200,+ "test/e2e/graduation-copy.test.ts": 150900,+ "test/e2e/graduation-crash-rollback-1.test.ts": 68040,+ "test/e2e/graduation-crash-rollback-2.test.ts": 46440,+ "test/e2e/graduation-crash-run-1.test.ts": 70410,+ "test/e2e/graduation-crash-run-2.test.ts": 94200,+ "test/e2e/graduation-crash-run-3.test.ts": 63190,+ "test/e2e/graduation-faults.test.ts": 57830,+ "test/e2e/graduation-legacy-copy.test.ts": 24870,+ "test/e2e/grandfather-projection-postgres.test.ts": 13340,+ "test/e2e/graph-quality.test.ts": 2450,+ "test/e2e/graph-signals-engine.test.ts": 778,+ "test/e2e/graph-signals-eval.test.ts": 4080,+ "test/e2e/harness-access.test.ts": 3400,+ "test/e2e/health-entity-types-pack.test.ts": 2170,+ "test/e2e/health-parity-postgres.test.ts": 1148,+ "test/e2e/held-embedding-budgets-postgres.test.ts": 4000,- "test/e2e/hnsw-iterative-scan-recall-postgres.test.ts": 10150,- "test/e2e/hot-memory-invalidation-postgres.test.ts": 5340,- "test/e2e/http-transport.test.ts": 2850,- "test/e2e/import-credential-preflight.test.ts": 600,- "test/e2e/import-embed-skip-recovery.test.ts": 1184,- "test/e2e/import-reads.test.ts": 6620,- "test/e2e/inflight-budget-raisers-6543-postgres.test.ts": 6030,- "test/e2e/ingestion-roundtrip.test.ts": 2200,- "test/e2e/init-schema-lock-blocked.test.ts": 5920,- "test/e2e/install-real-grok.serial.test.ts": 430,- "test/e2e/install-real-hermes.serial.test.ts": 404,- "test/e2e/install-real-opencode.serial.test.ts": 408,- "test/e2e/integrity-batch.test.ts": 1014,- "test/e2e/jit-off-reads-postgres.test.ts": 14270,- "test/e2e/job-deferral-postgres.test.ts": 1157,- "test/e2e/job-isolation.test.ts": 1920,- "test/e2e/jobs-agent-scope-postgres.test.ts": 2950,- "test/e2e/jobs-watch-readsnapshot.test.ts": 818,- "test/e2e/journey-atoms-sync-race-postgres.test.ts": 3830,- "test/e2e/jsonb-batch-poison-postgres.test.ts": 2150,- "test/e2e/jsonb-roundtrip.test.ts": 1730,- "test/e2e/keyword-arm-ranking-postgres.test.ts": 29640,- "test/e2e/knowledge-source-uri-postgres.test.ts": 2870,- "test/e2e/legacy-chunk-privacy.test.ts": 8320,- "test/e2e/legacy-fact-extraction-dedup-postgres.test.ts": 2680,- "test/e2e/legacy-slug-delete-postgres.test.ts": 10350,- "test/e2e/legacy-vector-compatibility-postgres.test.ts": 3290,- "test/e2e/line-grammar-toggle-postgres.test.ts": 17190,- "test/e2e/link-relationships-postgres.test.ts": 447,- "test/e2e/link-source-check-repair-postgres.test.ts": 856,- "test/e2e/links-read-order.test.ts": 2710,- "test/e2e/list-all-sources-postgres.test.ts": 1169,- "test/e2e/list-pages-regression.test.ts": 1150,- "test/e2e/loops-close-fact-postgres.test.ts": 8580,- "test/e2e/loops-counterparty-null-entity-postgres.test.ts": 4720,- "test/e2e/maintenance-file-drift-6643-postgres.test.ts": 7080,- "test/e2e/maintenance-write-wait.test.ts": 10340,- "test/e2e/managed-atom-compaction.test.ts": 6010,- "test/e2e/managed-atom-regressions.test.ts": 17460,- "test/e2e/managed-connector-fencing.test.ts": 4240,- "test/e2e/managed-connector-job-contract.test.ts": 26570,- "test/e2e/managed-connector-recovery.test.ts": 18700,- "test/e2e/managed-connector-retry.test.ts": 41680,- "test/e2e/managed-connector-routing.test.ts": 31020,- "test/e2e/managed-extract-atoms.test.ts": 11830,- "test/e2e/managed-facts-backstop.test.ts": 14870,- "test/e2e/managed-facts-compaction.test.ts": 13100,- "test/e2e/managed-facts-embedding.test.ts": 6720,- "test/e2e/managed-facts-writers.test.ts": 10610,- "test/e2e/managed-import-crash.test.ts": 11390,- "test/e2e/managed-maintenance.test.ts": 15890,- "test/e2e/managed-migration-chain-postgres.test.ts": 12560,- "test/e2e/managed-ontology-propose-postgres.test.ts": 1500,- "test/e2e/managed-phase-matrix.test.ts": 7080,- "test/e2e/managed-sync-failures.test.ts": 20140,- "test/e2e/managed-sync-shared-origin-6517.test.ts": 5850,- "test/e2e/managed-synthesis-postprocess.test.ts": 15030,- "test/e2e/managed-write-single-attribution-postgres.test.ts": 6690,- "test/e2e/managed-writer-guard-null-source-5983-postgres.test.ts": 5360,- "test/e2e/managed-writers-w3.test.ts": 6190,- "test/e2e/mcp-budget-reservation-postgres.test.ts": 453,- "test/e2e/mcp-search-transport-matrix.test.ts": 54830,- "test/e2e/mechanical.test.ts": 50480,- "test/e2e/memory-safety-wave-postgres.test.ts": 5100,- "test/e2e/mentions-parity.test.ts": 3770,- "test/e2e/migrate-chain.test.ts": 4000,- "test/e2e/migrate-embeddings-ann-build-5088-postgres.test.ts": 1424,- "test/e2e/migrate-embeddings-postgres.test.ts": 3120,- "test/e2e/migrate-engine-pglite-to-postgres.test.ts": 6630,- "test/e2e/migrate-engine-sources-postgres.test.ts": 3610,- "test/e2e/migrate-full-row-projections-postgres.test.ts": 2590,- "test/e2e/migration-drop-invalid-concurrent-index.test.ts": 1118,- "test/e2e/migration-flow.test.ts": 5400,- "test/e2e/migration-lease-lost.test.ts": 928,- "test/e2e/migration-preview-safety.test.ts": 7070,- "test/e2e/migration-v35-auto-rls.test.ts": 1830,- "test/e2e/migration-v35-event-trigger.test.ts": 3230,- "test/e2e/migration-v47-notability.test.ts": 2580,- "test/e2e/migration-v50-ingest-log-source-id.test.ts": 1650,- "test/e2e/migration-vector-replay-postgres.test.ts": 2100,- "test/e2e/migration-wave-budget-crash.test.ts": 30200,- "test/e2e/migration-wave-healing-fence.test.ts": 6350,- "test/e2e/migration-wave-intermediate-retrieval.test.ts": 10800,- "test/e2e/migration-wave-phase-leases.test.ts": 5630,- "test/e2e/migration-wave-prepared-withdrawal.test.ts": 4030.0000000000005,- "test/e2e/migration-wave-provider-outcomes.test.ts": 27550,- "test/e2e/migrations-v0_32_2-managed.test.ts": 14610,- "test/e2e/minions-authority-parity.test.ts": 1800,- "test/e2e/minions-concurrency.test.ts": 1249,- "test/e2e/minions-legacy-coalesce-postgres.test.ts": 4030.0000000000005,- "test/e2e/minions-legacy-journey-postgres.test.ts": 3080,- "test/e2e/minions-prefix-strip-smoke.test.ts": 1312,- "test/e2e/minions-resilience.test.ts": 13120,- "test/e2e/minions-shell-pglite.test.ts": 2070,- "test/e2e/minions-shell.test.ts": 2320,- "test/e2e/multi-source-bug-class.test.ts": 2410,- "test/e2e/multi-source-emotional-weight-pglite.test.ts": 690,- "test/e2e/multi-source.test.ts": 3140,- "test/e2e/multimodal-postgres.test.ts": 1397,- "test/e2e/non-tty-output.serial.test.ts": 5960,- "test/e2e/oauth-client-grant-axes.test.ts": 6480,- "test/e2e/oauth-client-registered-via-postgres.test.ts": 2580,- "test/e2e/oauth-grant-transactions.test.ts": 909,- "test/e2e/oauth-owner-consent-source-postgres.test.ts": 3020,- "test/e2e/oauth-token-ttl-clamp-postgres.test.ts": 5830,- "test/e2e/onboard-full-flow.test.ts": 2560,- "test/e2e/ontology-fence-sweep-postgres.test.ts": 9150,- "test/e2e/ontology-merge-parity.test.ts": 1228,- "test/e2e/op-checkpoint-jsonb-parity.test.ts": 724,- "test/e2e/openclaw-context-engine-plugin.test.ts": 273,- "test/e2e/openclaw-plugin-load-real.test.ts": 87,- "test/e2e/openclaw-reference-compat.test.ts": 288,- "test/e2e/orphan-reduction.test.ts": 2140,- "test/e2e/p5-graph-postgres.test.ts": 4260,- "test/e2e/p8-memory-writes-postgres.test.ts": 1432,- "test/e2e/page-guards-postgres.test.ts": 4960,- "test/e2e/page-revision-rollout-5216-postgres.test.ts": 3330,- "test/e2e/page-snapshot-alias-plan-postgres.test.ts": 4820,- "test/e2e/page-snapshot-batch.test.ts": 1367,- "test/e2e/page-timeline-tsvector-bound-postgres.test.ts": 2610,- "test/e2e/pages-reconcile-name-indexes-postgres.test.ts": 1167,- "test/e2e/persistence-admin-intent.test.ts": 6170,- "test/e2e/persistence-chaos.test.ts": 26820,- "test/e2e/persistence-client-request-id-postgres.test.ts": 1760,- "test/e2e/persistence-consumer-claim-loss.test.ts": 9760,- "test/e2e/persistence-consumers-postgres.test.ts": 6850,- "test/e2e/persistence-deactivate-race.test.ts": 10520,- "test/e2e/persistence-dead-owner-reclaim-6650.test.ts": 20810,- "test/e2e/persistence-embedding-effects.test.ts": 30610,- "test/e2e/persistence-git-coalescing-5530-postgres.test.ts": 63030,- "test/e2e/persistence-git-durability-probe-6210-postgres.test.ts": 17960,- "test/e2e/persistence-group-deadline-postgres.test.ts": 19430,- "test/e2e/persistence-http-liveness.test.ts": 45600,- "test/e2e/persistence-idle-pool.test.ts": 120370,- "test/e2e/persistence-large-manifest-50k.test.ts": 30100,- "test/e2e/persistence-large-manifest-postgres.test.ts": 50890,- "test/e2e/persistence-links-effect-postgres.test.ts": 3410,- "test/e2e/persistence-lock-open-failure-postgres.test.ts": 3090,- "test/e2e/persistence-managed-takes-extract.test.ts": 2790,- "test/e2e/persistence-phase-liveness.test.ts": 71560,- "test/e2e/persistence-pooler-wedge-postgres.test.ts": 10900,- "test/e2e/persistence-preparation-attempts-postgres.test.ts": 4430,- "test/e2e/persistence-preparation-deadline.e2e.test.ts": 52600,- "test/e2e/persistence-preparation-lock-wait-postgres.test.ts": 21110,- "test/e2e/persistence-publication-parity.test.ts": 4970,- "test/e2e/persistence-publish-lock-order-postgres.test.ts": 13080,- "test/e2e/persistence-recovery.test.ts": 11220,- "test/e2e/persistence-request-indexes-postgres.test.ts": 37570,- "test/e2e/persistence-robot-fixture-release.test.ts": 4510,- "test/e2e/persistence-runtime-matrix.test.ts": 836,- "test/e2e/persistence-skill-bundles-postgres.test.ts": 24880,- "test/e2e/persistence-statement-budget.test.ts": 10760,- "test/e2e/persistence-sync-company-parity.test.ts": 12490,- "test/e2e/persistence-sync-options-parity.test.ts": 58470,- "test/e2e/persistence-sync-origin-parity.test.ts": 10340,- "test/e2e/persistence-two-consumers-postgres.test.ts": 8670,- "test/e2e/persistence-writer-admin-lock.test.ts": 5670,- "test/e2e/persistence-writer-stamps.test.ts": 13140,- "test/e2e/pgbouncer-pipelined-read-pool.test.ts": 191,- "test/e2e/pgbouncer-teardown.test.ts": 138,- "test/e2e/pglite-cli-exit.serial.test.ts": 21530,- "test/e2e/phantom-redirect.test.ts": 33000,- "test/e2e/physical-root-relocation.test.ts": 11700,- "test/e2e/pinned-questions-postgres.test.ts": 16040,- "test/e2e/planner-stats-postgres.test.ts": 2730,- "test/e2e/pool-size-one-migrations.test.ts": 5630,- "test/e2e/postgres-bootstrap.test.ts": 4820,- "test/e2e/postgres-checkout-observer.test.ts": 434,- "test/e2e/postgres-driver-6543-postgres.test.ts": 656,- "test/e2e/postgres-driver-cancel-pipeline.test.ts": 4310,- "test/e2e/postgres-driver-desync-tripwire.test.ts": 523,- "test/e2e/postgres-driver-install.test.ts": 121,- "test/e2e/postgres-driver-retry-pipeline.test.ts": 292,- "test/e2e/postgres-driver-row-count-postgres.test.ts": 656,- "test/e2e/postgres-engine-disconnect-idempotency.test.ts": 239,- "test/e2e/postgres-initschema-advisory-lock.test.ts": 9710,- "test/e2e/postgres-jsonb.test.ts": 1046,- "test/e2e/postgres-pipelined-build-failure-postgres.test.ts": 946,- "test/e2e/postgres-poisoned-connection.test.ts": 407,- "test/e2e/postgres-reconnect-singleton.test.ts": 261,- "test/e2e/postgres-shared-types.test.ts": 10110,- "test/e2e/postgres-stuck-connection-postgres.test.ts": 23020,- "test/e2e/postgres-transaction-abort-postgres.test.ts": 3880,- "test/e2e/preview-approval-postgres.test.ts": 2780,- "test/e2e/private-visibility-plan-postgres.test.ts": 2630,- "test/e2e/projection-drain-postgres.test.ts": 30590,+ "test/e2e/hnsw-iterative-scan-recall-postgres.test.ts": 7000,+ "test/e2e/hot-memory-invalidation-postgres.test.ts": 2810,+ "test/e2e/http-transport.test.ts": 1431,+ "test/e2e/import-credential-preflight.test.ts": 631,+ "test/e2e/import-embed-skip-recovery.test.ts": 724,+ "test/e2e/import-reads.test.ts": 3140,+ "test/e2e/inflight-budget-raisers-6543-postgres.test.ts": 5900,+ "test/e2e/ingestion-roundtrip.test.ts": 1940,+ "test/e2e/init-schema-lock-blocked.test.ts": 5910,+ "test/e2e/install-real-grok.serial.test.ts": 346,+ "test/e2e/install-real-hermes.serial.test.ts": 360,+ "test/e2e/install-real-opencode.serial.test.ts": 451,+ "test/e2e/integrity-batch.test.ts": 1493,+ "test/e2e/jit-off-reads-postgres.test.ts": 9580,+ "test/e2e/job-deferral-postgres.test.ts": 1003,+ "test/e2e/job-isolation.test.ts": 1760,+ "test/e2e/jobs-agent-scope-postgres.test.ts": 978,+ "test/e2e/jobs-watch-readsnapshot.test.ts": 659,+ "test/e2e/journey-atoms-sync-race-postgres.test.ts": 3690,+ "test/e2e/jsonb-batch-poison-postgres.test.ts": 1144,+ "test/e2e/jsonb-roundtrip.test.ts": 863,+ "test/e2e/keyword-arm-ranking-postgres.test.ts": 6330,+ "test/e2e/knowledge-source-uri-postgres.test.ts": 2460,+ "test/e2e/large-pages-10mb.test.ts": 21080,+ "test/e2e/legacy-chunk-privacy.test.ts": 6170,+ "test/e2e/legacy-fact-extraction-dedup-postgres.test.ts": 2190,+ "test/e2e/legacy-slug-delete-postgres.test.ts": 3960,+ "test/e2e/legacy-vector-compatibility-postgres.test.ts": 2450,+ "test/e2e/line-grammar-toggle-postgres.test.ts": 9260,+ "test/e2e/link-relationships-postgres.test.ts": 394,+ "test/e2e/link-source-check-repair-postgres.test.ts": 864,+ "test/e2e/links-read-order.test.ts": 2160,+ "test/e2e/list-all-sources-postgres.test.ts": 764,+ "test/e2e/list-pages-regression.test.ts": 883,+ "test/e2e/loops-close-fact-postgres.test.ts": 6090,+ "test/e2e/loops-counterparty-null-entity-postgres.test.ts": 3110,+ "test/e2e/loops-noise-5012-postgres.test.ts": 1940,+ "test/e2e/maintenance-file-drift-6643-postgres.test.ts": 3090,+ "test/e2e/maintenance-write-wait.test.ts": 9300,+ "test/e2e/managed-atom-compaction.test.ts": 4750,+ "test/e2e/managed-atom-regressions.test.ts": 12530,+ "test/e2e/managed-connector-fencing.test.ts": 4150,+ "test/e2e/managed-connector-job-contract.test.ts": 20690,+ "test/e2e/managed-connector-recovery.test.ts": 18250,+ "test/e2e/managed-connector-retry.test.ts": 25070,+ "test/e2e/managed-connector-routing.test.ts": 30000,+ "test/e2e/managed-extract-atoms.test.ts": 11980,+ "test/e2e/managed-facts-backstop.test.ts": 8210,+ "test/e2e/managed-facts-compaction.test.ts": 5750,+ "test/e2e/managed-facts-embedding.test.ts": 10150,+ "test/e2e/managed-facts-writers.test.ts": 11460,+ "test/e2e/managed-import-crash.test.ts": 7840,+ "test/e2e/managed-maintenance.test.ts": 16110,+ "test/e2e/managed-migration-chain-postgres.test.ts": 8660,+ "test/e2e/managed-ontology-propose-postgres.test.ts": 2650,+ "test/e2e/managed-phase-matrix.test.ts": 7740,+ "test/e2e/managed-sync-failures.test.ts": 14770,+ "test/e2e/managed-sync-shared-origin-6517.test.ts": 4500,+ "test/e2e/managed-synthesis-postprocess.test.ts": 14210,+ "test/e2e/managed-timeline-facts-postgres.test.ts": 6420,+ "test/e2e/managed-write-single-attribution-postgres.test.ts": 3400,+ "test/e2e/managed-writer-guard-null-source-5983-postgres.test.ts": 1830,+ "test/e2e/managed-writers-w3.test.ts": 3810,+ "test/e2e/mcp-budget-reservation-postgres.test.ts": 541,+ "test/e2e/mcp-search-transport-matrix.test.ts": 73350,+ "test/e2e/mechanical.test.ts": 45560,+ "test/e2e/memory-safety-wave-postgres.test.ts": 5770,+ "test/e2e/mentions-parity.test.ts": 1630,+ "test/e2e/migrate-chain.test.ts": 3060,+ "test/e2e/migrate-embeddings-ann-build-5088-postgres.test.ts": 892,+ "test/e2e/migrate-embeddings-lease-heartbeat.test.ts": 9150,+ "test/e2e/migrate-embeddings-postgres.test.ts": 1390,+ "test/e2e/migrate-engine-pglite-to-postgres.test.ts": 4420,+ "test/e2e/migrate-engine-sources-postgres.test.ts": 2190,+ "test/e2e/migrate-full-row-projections-postgres.test.ts": 2650,+ "test/e2e/migration-drop-invalid-concurrent-index.test.ts": 886,+ "test/e2e/migration-flow.test.ts": 3660,+ "test/e2e/migration-lease-lost.test.ts": 658,+ "test/e2e/migration-preview-safety.test.ts": 8020,+ "test/e2e/migration-v35-auto-rls.test.ts": 2610,+ "test/e2e/migration-v35-event-trigger.test.ts": 1283,+ "test/e2e/migration-v47-notability.test.ts": 1740,+ "test/e2e/migration-v50-ingest-log-source-id.test.ts": 910,+ "test/e2e/migration-vector-replay-postgres.test.ts": 2250,+ "test/e2e/migration-wave-budget-crash.test.ts": 34660,+ "test/e2e/migration-wave-healing-fence.test.ts": 5400,+ "test/e2e/migration-wave-intermediate-retrieval.test.ts": 7820,+ "test/e2e/migration-wave-phase-leases.test.ts": 8850,+ "test/e2e/migration-wave-prepared-withdrawal.test.ts": 6060,+ "test/e2e/migration-wave-provider-outcomes.test.ts": 12770,+ "test/e2e/migrations-v0_32_2-managed.test.ts": 31050,+ "test/e2e/minions-authority-parity.test.ts": 1890,+ "test/e2e/minions-concurrency.test.ts": 1450,+ "test/e2e/minions-legacy-coalesce-postgres.test.ts": 2980,+ "test/e2e/minions-legacy-journey-postgres.test.ts": 2180,+ "test/e2e/minions-prefix-strip-smoke.test.ts": 737,+ "test/e2e/minions-resilience.test.ts": 13710,+ "test/e2e/minions-shell-pglite.test.ts": 1700,+ "test/e2e/minions-shell.test.ts": 1299,+ "test/e2e/multi-source-bug-class.test.ts": 3040,+ "test/e2e/multi-source-emotional-weight-pglite.test.ts": 638,+ "test/e2e/multi-source.test.ts": 2790,+ "test/e2e/multimodal-postgres.test.ts": 983,+ "test/e2e/non-tty-output.serial.test.ts": 3620,+ "test/e2e/oauth-client-grant-axes.test.ts": 1530,+ "test/e2e/oauth-client-registered-via-postgres.test.ts": 1610,+ "test/e2e/oauth-grant-transactions.test.ts": 813,+ "test/e2e/oauth-owner-consent-source-postgres.test.ts": 1210,+ "test/e2e/oauth-token-ttl-clamp-postgres.test.ts": 3920,+ "test/e2e/onboard-full-flow.test.ts": 2450,+ "test/e2e/ontology-fence-sweep-postgres.test.ts": 10220,+ "test/e2e/ontology-merge-parity.test.ts": 1061,+ "test/e2e/op-checkpoint-jsonb-parity.test.ts": 866,+ "test/e2e/openclaw-context-engine-plugin.test.ts": 251,+ "test/e2e/openclaw-plugin-load-real.test.ts": 86,+ "test/e2e/openclaw-reference-compat.test.ts": 282,+ "test/e2e/orphan-reduction.test.ts": 2530,+ "test/e2e/p5-graph-postgres.test.ts": 5230,+ "test/e2e/p8-memory-writes-postgres.test.ts": 1560,+ "test/e2e/page-guards-postgres.test.ts": 7740,+ "test/e2e/page-revision-rollout-5216-postgres.test.ts": 933,+ "test/e2e/page-snapshot-alias-plan-postgres.test.ts": 4360,+ "test/e2e/page-snapshot-batch.test.ts": 1770,+ "test/e2e/page-timeline-tsvector-bound-postgres.test.ts": 1640,+ "test/e2e/pages-reconcile-name-indexes-postgres.test.ts": 1393,+ "test/e2e/persistence-admin-intent.test.ts": 6690,+ "test/e2e/persistence-chaos.test.ts": 45370,+ "test/e2e/persistence-client-request-id-postgres.test.ts": 944,+ "test/e2e/persistence-consumer-claim-loss.test.ts": 8540,+ "test/e2e/persistence-consumers-postgres.test.ts": 2220,+ "test/e2e/persistence-deactivate-race.test.ts": 4940,+ "test/e2e/persistence-dead-owner-reclaim-6650.test.ts": 37540,+ "test/e2e/persistence-embedding-effects.test.ts": 40010,+ "test/e2e/persistence-git-coalescing-5530-postgres.test.ts": 53090,+ "test/e2e/persistence-git-durability-probe-6210-postgres.test.ts": 21470,+ "test/e2e/persistence-group-deadline-postgres.test.ts": 15160,+ "test/e2e/persistence-http-liveness.test.ts": 45770,+ "test/e2e/persistence-idle-pool.test.ts": 120320,+ "test/e2e/persistence-large-manifest-50k.test.ts": 31700,+ "test/e2e/persistence-large-manifest-postgres.test.ts": 31320,+ "test/e2e/persistence-links-effect-postgres.test.ts": 3690,+ "test/e2e/persistence-lock-open-failure-postgres.test.ts": 2710,+ "test/e2e/persistence-managed-takes-extract.test.ts": 2590,+ "test/e2e/persistence-phase-liveness.test.ts": 26290,+ "test/e2e/persistence-pooler-wedge-postgres.test.ts": 8980,+ "test/e2e/persistence-preparation-attempts-postgres.test.ts": 1205,+ "test/e2e/persistence-preparation-deadline.e2e.test.ts": 54180,+ "test/e2e/persistence-preparation-lock-wait-postgres.test.ts": 15810,+ "test/e2e/persistence-publication-parity.test.ts": 2670,+ "test/e2e/persistence-publish-lock-order-postgres.test.ts": 10180,+ "test/e2e/persistence-recovery.test.ts": 12390,+ "test/e2e/persistence-request-indexes-postgres.test.ts": 35100,+ "test/e2e/persistence-robot-fixture-release.test.ts": 5140,+ "test/e2e/persistence-runtime-matrix.test.ts": 457,+ "test/e2e/persistence-skill-bundles-postgres.test.ts": 10590,+ "test/e2e/persistence-statement-budget.test.ts": 7430,+ "test/e2e/persistence-sync-company-parity.test.ts": 16320,+ "test/e2e/persistence-sync-options-parity.test.ts": 60890,+ "test/e2e/persistence-sync-origin-parity.test.ts": 18560,+ "test/e2e/persistence-two-consumers-postgres.test.ts": 7000,+ "test/e2e/persistence-writer-admin-lock.test.ts": 5950,+ "test/e2e/persistence-writer-stamps.test.ts": 7390,+ "test/e2e/pgbouncer-pipelined-read-pool.test.ts": 180,+ "test/e2e/pgbouncer-teardown.test.ts": 143,+ "test/e2e/pglite-cli-exit.serial.test.ts": 20900,+ "test/e2e/phantom-redirect.test.ts": 32880,+ "test/e2e/physical-root-relocation.test.ts": 5840,+ "test/e2e/pinned-questions-postgres.test.ts": 17000,+ "test/e2e/planner-stats-postgres.test.ts": 2420,+ "test/e2e/pool-size-one-migrations.test.ts": 4500,+ "test/e2e/postgres-bootstrap.test.ts": 4970,+ "test/e2e/postgres-checkout-observer.test.ts": 410,+ "test/e2e/postgres-driver-6543-postgres.test.ts": 658,+ "test/e2e/postgres-driver-cancel-pipeline.test.ts": 4250,+ "test/e2e/postgres-driver-desync-tripwire.test.ts": 511,+ "test/e2e/postgres-driver-install.test.ts": 106,+ "test/e2e/postgres-driver-retry-pipeline.test.ts": 226,+ "test/e2e/postgres-driver-row-count-postgres.test.ts": 663,+ "test/e2e/postgres-engine-disconnect-idempotency.test.ts": 246,+ "test/e2e/postgres-initschema-advisory-lock.test.ts": 16090,+ "test/e2e/postgres-jsonb.test.ts": 891,+ "test/e2e/postgres-pipelined-build-failure-postgres.test.ts": 967,+ "test/e2e/postgres-poisoned-connection.test.ts": 328,+ "test/e2e/postgres-reconnect-singleton.test.ts": 224,+ "test/e2e/postgres-shared-types.test.ts": 9930,+ "test/e2e/postgres-stuck-connection-postgres.test.ts": 22850,+ "test/e2e/postgres-transaction-abort-postgres.test.ts": 3820,+ "test/e2e/preview-approval-postgres.test.ts": 1154,+ "test/e2e/private-visibility-plan-postgres.test.ts": 1940,+ "test/e2e/projection-drain-postgres.test.ts": 11690,+ "test/e2e/projection-embedding-input-hash.test.ts": 2690,+ "test/e2e/projection-image-drain-postgres.test.ts": 9000,- "test/e2e/projection-embedding-input-hash.test.ts": 2800,- "test/e2e/projection-readiness-currency.test.ts": 2930,- "test/e2e/projection-recovery-parity.test.ts": 36060,- "test/e2e/projection-statistics-postgres.test.ts": 446,- "test/e2e/projections-drain-stale-row-6400-postgres.test.ts": 1510,- "test/e2e/propose-takes-jsonb-postgres.test.ts": 1940,- "test/e2e/publication-claim-lease-6574-postgres.test.ts": 2060,- "test/e2e/publication-deadline-group-postgres.test.ts": 5640,- "test/e2e/publication-deadline-pgbouncer.test.ts": 143,- "test/e2e/purge-deleted-dryrun-postgres.test.ts": 955,- "test/e2e/put-page-persistence-postgres.test.ts": 15140,- "test/e2e/put-pages-group-postgres.test.ts": 8210,- "test/e2e/quarantine-search-exclusion.test.ts": 2390,- "test/e2e/query-embed-cache-ranking-postgres.test.ts": 11100,- "test/e2e/query-embedding-opt-out.test.ts": 2310,- "test/e2e/read-enrichment-privacy.test.ts": 6150,- "test/e2e/recall-question-postgres.test.ts": 3000,- "test/e2e/reconcile-crash-unactivated.test.ts": 121410,- "test/e2e/reconcile-crash.test.ts": 132430,- "test/e2e/reconcile-pgbouncer.test.ts": 385,- "test/e2e/reconcile-unbound-collision.test.ts": 7750,- "test/e2e/recovery-layer.test.ts": 18970,- "test/e2e/reflex-private-visibility-postgres.test.ts": 5680,- "test/e2e/reindex-auto-workers-5181.test.ts": 4800,- "test/e2e/remote-fact-list-private-provenance-postgres.test.ts": 3490,- "test/e2e/remote-fact-write-private-provenance-postgres.test.ts": 2650,- "test/e2e/repair-captured-facts-postgres.test.ts": 17830,- "test/e2e/repair-command.test.ts": 16470,- "test/e2e/repair-contextual-mode-5621-postgres.test.ts": 4380,- "test/e2e/repair-conversation-labels-postgres.test.ts": 3610,- "test/e2e/repair-extractor-facts-postgres.test.ts": 50990,- "test/e2e/repair-failed-writes-5983-postgres.test.ts": 3350,- "test/e2e/repair-failed-writes-5994.test.ts": 4240,- "test/e2e/repair-fences-during-catchup-postgres.test.ts": 6620,- "test/e2e/repair-orphan-children-plan-postgres.test.ts": 1530,- "test/e2e/repair-stale-atoms-postgres.test.ts": 9120,- "test/e2e/repair-stuck-recovery-postgres.test.ts": 3270,- "test/e2e/repair-take-supersession-postgres.test.ts": 15970,- "test/e2e/repair-timeline-comments.test.ts": 1890,- "test/e2e/restore-source-config-jsonb-postgres.test.ts": 740,- "test/e2e/safe-chunk-reseal.test.ts": 3420,- "test/e2e/salience-anomalies-source-isolation-pglite.test.ts": 1388,- "test/e2e/salience-llm-routing.test.ts": 28230,- "test/e2e/salience-pglite.test.ts": 1750,- "test/e2e/schema-catalog-golden.test.ts": 24300,- "test/e2e/schema-cathedral.test.ts": 2360,- "test/e2e/schema-drift.test.ts": 7660,- "test/e2e/schema-migrations-replay.test.ts": 21320,- "test/e2e/search-exclude.test.ts": 1226,- "test/e2e/search-keyword-paging-parity.test.ts": 4370,- "test/e2e/search-quality.test.ts": 966,- "test/e2e/search-query-contract-postgres.test.ts": 2440,- "test/e2e/search-statistics-guard-postgres.test.ts": 2640,- "test/e2e/search-swamp.test.ts": 805,- "test/e2e/self-upgrade-binary-swap.test.ts": 197,- "test/e2e/self-upgrade-marker.test.ts": 1790,- "test/e2e/serve-delegated-managed-sync.serial.test.ts": 10350,- "test/e2e/serve-http-api-keys.test.ts": 1840,- "test/e2e/serve-http-consent.test.ts": 3910,- "test/e2e/serve-http-ingest-webhook.test.ts": 22200,- "test/e2e/serve-http-meta.test.ts": 2190,- "test/e2e/serve-http-multi-agent.test.ts": 10620,- "test/e2e/serve-http-oauth.test.ts": 10940,- "test/e2e/serve-http-source-grant.test.ts": 3430,- "test/e2e/serve-http-takes-holders.test.ts": 3170,- "test/e2e/serve-http-trust-floor.test.ts": 5970,- "test/e2e/serve-loop-migrations-postgres.test.ts": 3020,- "test/e2e/session-seat-synthesize.test.ts": 5060,- "test/e2e/shared-skills-rls.test.ts": 4059.9999999999995,- "test/e2e/shared-skills-transports.test.ts": 14960,- "test/e2e/single-write-fast-path-postgres.test.ts": 34900,- "test/e2e/single-write-group-parity-postgres.test.ts": 4570,- "test/e2e/skill-brain-first.test.ts": 816,- "test/e2e/skillopt-loop.serial.test.ts": 3590,- "test/e2e/skillopt-models-strict.serial.test.ts": 2690,- "test/e2e/skillopt-models-used.serial.test.ts": 1262,- "test/e2e/skillopt-outcome.serial.test.ts": 3660,- "test/e2e/skillopt-pglite.serial.test.ts": 1110,- "test/e2e/skillpack-third-party.test.ts": 1580,- "test/e2e/skills.test.ts": 236,- "test/e2e/slug-stamp-double-hyphen.test.ts": 5700,- "test/e2e/source-boundary-mutation-postgres.test.ts": 2430,- "test/e2e/source-isolation-pglite.test.ts": 4110,- "test/e2e/source-retire-symlink-manifest.test.ts": 5780,- "test/e2e/source-routing.test.ts": 1740,- "test/e2e/sources-mirror-read-only-postgres.test.ts": 8250,- "test/e2e/sources-remote-mcp.test.ts": 8070,- "test/e2e/sources-remove-bindings.test.ts": 1233,- "test/e2e/sql-trace-postgres.test.ts": 1410,- "test/e2e/status-pglite.test.ts": 1388,- "test/e2e/storage-tiering.test.ts": 12880,- "test/e2e/subagent-crash-replay-multi-provider.test.ts": 2020,- "test/e2e/subagent-gateway-path.test.ts": 1770,- "test/e2e/subagent-gateway-resume-reconciliation.test.ts": 2009.9999999999998,- "test/e2e/supavisor-read-pool.test.ts": 162,- "test/e2e/supervisor-stop-drain-5062.test.ts": 26860,- "test/e2e/symbol-resolver-pglite.test.ts": 1170,- "test/e2e/sync-cjk-git.test.ts": 378,- "test/e2e/sync-credential-preflight.test.ts": 1347,- "test/e2e/sync-delegation-under-serve.serial.test.ts": 52070,- "test/e2e/sync-lock-overlap-postgres.test.ts": 9050,- "test/e2e/sync-lock-recovery.test.ts": 5550,- "test/e2e/sync-parallel.test.ts": 5270,- "test/e2e/sync-reconcile-postgres.test.ts": 1406,- "test/e2e/sync-rename-collision.test.ts": 3600,- "test/e2e/sync-run-workers-postgres.test.ts": 1870,- "test/e2e/sync-sigkill-resume-postgres.test.ts": 17410,- "test/e2e/sync-status-pglite.test.ts": 1590,- "test/e2e/sync.test.ts": 3030,- "test/e2e/synthesize-bigint-job-id-postgres.test.ts": 2130,- "test/e2e/system-of-record-invariant.test.ts": 6620,- "test/e2e/takes-extract-cursor-postgres.test.ts": 1031,- "test/e2e/takes-postgres.test.ts": 2540,- "test/e2e/takes-propose-accept-managed.test.ts": 15330,- "test/e2e/takes-row-reservation-postgres.test.ts": 4640,- "test/e2e/takes-scorecard-parity.test.ts": 4500,- "test/e2e/takes-weight-rounding-postgres.test.ts": 1770,- "test/e2e/takes-write-ops-postgres.test.ts": 12610,- "test/e2e/thin-client.test.ts": 10440,- "test/e2e/think-source-isolation-pglite.test.ts": 1191,- "test/e2e/think-trajectory-pglite.test.ts": 3620,- "test/e2e/timeline-materialize.test.ts": 13190,- "test/e2e/timeline-omission.test.ts": 8090,- "test/e2e/title-arm-postgres.test.ts": 14320,- "test/e2e/token-usage-skip-locked.test.ts": 2220,- "test/e2e/transcripts-no-timestamp-pglite.test.ts": 1183,- "test/e2e/transcripts-secret-audit-postgres.test.ts": 864,- "test/e2e/transcripts-writeback-fidelity.test.ts": 2650,- "test/e2e/truncate-cascade-postgres.test.ts": 777,- "test/e2e/trust-backfill-postgres.test.ts": 3710,- "test/e2e/trust-cross-session-parity.test.ts": 6150,- "test/e2e/trust-generation-postgres.test.ts": 4720,- "test/e2e/trust-route-matrix.test.ts": 10400,- "test/e2e/trust-taint-dream.test.ts": 9650,- "test/e2e/trust-taint-origin.test.ts": 2680,- "test/e2e/trust-tier-postgres.test.ts": 9700,- "test/e2e/type-unification-full-flow.test.ts": 1233,- "test/e2e/unbound-source-postgres.test.ts": 56230,- "test/e2e/unsupported-embedding-identity-postgres.test.ts": 46970,- "test/e2e/upgrade.test.ts": 862,- "test/e2e/upsert-chunks-registry-column.test.ts": 2000,- "test/e2e/v0_29-mcp-dispatch-pglite.test.ts": 924,- "test/e2e/vector-candidate-safety-postgres.test.ts": 27430,- "test/e2e/vector-chunk-statistics-postgres.test.ts": 4930,- "test/e2e/vector-ef-search-postgres.test.ts": 3630,- "test/e2e/vector-plan-real-column-postgres.test.ts": 19450,- "test/e2e/vector-scope-recall-postgres.test.ts": 21800,- "test/e2e/visibility-withdrawal-postgres.test.ts": 8140.000000000001,- "test/e2e/volunteer-context-postgres.test.ts": 732,- "test/e2e/w5-persistence-postgres.test.ts": 50200,- "test/e2e/wanted-links-postgres.test.ts": 23200,- "test/e2e/wave8-lane-d2-postgres.test.ts": 2550,- "test/e2e/whoknows.test.ts": 7750,- "test/e2e/withdrawal-bounded-safety-postgres.test.ts": 9470,- "test/e2e/withdrawal-crash-postgres.test.ts": 6750,- "test/e2e/withdrawal-followup-writes-postgres.test.ts": 4620,- "test/e2e/withdrawn-detail-postgres.test.ts": 20130,- "test/e2e/worker-abort-recovery.test.ts": 4710,- "test/e2e/worker-configuration-release.test.ts": 34450,- "test/e2e/worker-lock-renewal-starvation.test.ts": 4670,- "test/e2e/worker-readiness-cli.test.ts": 2450,- "test/e2e/worker-shutdown-error-matrix-postgres.test.ts": 3200,- "test/e2e/workspace-generic-compat.test.ts": 210,- "test/e2e/worktree-refresh-postgres.test.ts": 30570,- "test/e2e/write-attribution-postgres.test.ts": 51700,- "test/e2e/write-attribution-read-parity.test.ts": 3520,- "test/e2e/write-attribution-timeline-10k-postgres.test.ts": 33230,- "test/e2e/write-contract-conformance.test.ts": 63800,- "test/e2e/write-gate-store-postgres.test.ts": 3030,- "test/e2e/write-single-dedup-postgres.test.ts": 1660,- "test/e2e/zombie-reaping.test.ts": 8540,- "test/phantom-redirect-engine-parity.test.ts": 2450+ "test/e2e/projection-readiness-currency.test.ts": 1850,+ "test/e2e/projection-recovery-parity.test.ts": 11840,+ "test/e2e/projection-statistics-postgres.test.ts": 351,+ "test/e2e/projections-drain-stale-row-6400-postgres.test.ts": 1352,+ "test/e2e/propose-takes-jsonb-postgres.test.ts": 959,+ "test/e2e/publication-claim-lease-6574-postgres.test.ts": 1670,+ "test/e2e/publication-deadline-group-postgres.test.ts": 4730,+ "test/e2e/publication-deadline-pgbouncer.test.ts": 151,+ "test/e2e/purge-deleted-dryrun-postgres.test.ts": 788,+ "test/e2e/put-page-persistence-postgres.test.ts": 15460,+ "test/e2e/put-pages-group-postgres.test.ts": 11300,+ "test/e2e/quarantine-search-exclusion.test.ts": 1660,+ "test/e2e/query-embed-cache-ranking-postgres.test.ts": 3670,+ "test/e2e/query-embedding-opt-out.test.ts": 2500,+ "test/e2e/read-enrichment-privacy.test.ts": 3440,+ "test/e2e/recall-question-postgres.test.ts": 3190,+ "test/e2e/reconcile-crash-unactivated.test.ts": 115370,+ "test/e2e/reconcile-crash.test.ts": 110770,+ "test/e2e/reconcile-pgbouncer.test.ts": 329,+ "test/e2e/reconcile-unbound-collision.test.ts": 3300,+ "test/e2e/recovery-layer.test.ts": 39080,+ "test/e2e/reflex-private-visibility-postgres.test.ts": 3100,+ "test/e2e/reindex-auto-workers-5181.test.ts": 3240,+ "test/e2e/remote-fact-list-private-provenance-postgres.test.ts": 2120,+ "test/e2e/remote-fact-write-private-provenance-postgres.test.ts": 2100,+ "test/e2e/repair-captured-facts-postgres.test.ts": 13620,+ "test/e2e/repair-command.test.ts": 14190,+ "test/e2e/repair-contextual-mode-5621-postgres.test.ts": 3120,+ "test/e2e/repair-conversation-labels-postgres.test.ts": 3500,+ "test/e2e/repair-extractor-facts-postgres.test.ts": 59790,+ "test/e2e/repair-failed-writes-5983-postgres.test.ts": 3000,+ "test/e2e/repair-failed-writes-5994.test.ts": 3210,+ "test/e2e/repair-fences-during-catchup-postgres.test.ts": 3940,+ "test/e2e/repair-orphan-children-plan-postgres.test.ts": 2760,+ "test/e2e/repair-stale-atoms-postgres.test.ts": 4900,+ "test/e2e/repair-stuck-recovery-postgres.test.ts": 4590,+ "test/e2e/repair-take-supersession-postgres.test.ts": 10870,+ "test/e2e/repair-timeline-comments.test.ts": 1600,+ "test/e2e/restore-source-config-jsonb-postgres.test.ts": 831,+ "test/e2e/safe-chunk-reseal.test.ts": 4550,+ "test/e2e/salience-anomalies-source-isolation-pglite.test.ts": 1171,+ "test/e2e/salience-llm-routing.test.ts": 26400,+ "test/e2e/salience-pglite.test.ts": 1098,+ "test/e2e/schema-catalog-golden.test.ts": 28130,+ "test/e2e/schema-cathedral.test.ts": 2680,+ "test/e2e/schema-drift.test.ts": 3260,+ "test/e2e/schema-migrations-replay.test.ts": 10830,+ "test/e2e/search-exclude.test.ts": 1530,+ "test/e2e/search-keyword-paging-parity.test.ts": 7210,+ "test/e2e/search-quality.test.ts": 697,+ "test/e2e/search-query-contract-postgres.test.ts": 1750,+ "test/e2e/search-statistics-guard-postgres.test.ts": 1660,+ "test/e2e/search-swamp.test.ts": 734,+ "test/e2e/segment-gc-parity.test.ts": 1389,+ "test/e2e/segmented-storage-statistics-postgres.test.ts": 1840,+ "test/e2e/self-upgrade-binary-swap.test.ts": 115,+ "test/e2e/self-upgrade-marker.test.ts": 1337,+ "test/e2e/serve-delegated-managed-sync.serial.test.ts": 7310,+ "test/e2e/serve-http-api-keys.test.ts": 947,+ "test/e2e/serve-http-consent.test.ts": 3210,+ "test/e2e/serve-http-ingest-webhook.test.ts": 38860,+ "test/e2e/serve-http-meta.test.ts": 1178,+ "test/e2e/serve-http-multi-agent.test.ts": 10710,+ "test/e2e/serve-http-oauth.test.ts": 13550,+ "test/e2e/serve-http-source-grant.test.ts": 2810,+ "test/e2e/serve-http-takes-holders.test.ts": 2960,+ "test/e2e/serve-http-trust-floor.test.ts": 3190,+ "test/e2e/serve-loop-migrations-postgres.test.ts": 1299,+ "test/e2e/session-seat-synthesize.test.ts": 6580,+ "test/e2e/shared-skills-rls.test.ts": 1770,+ "test/e2e/shared-skills-transports.test.ts": 28150,+ "test/e2e/single-write-fast-path-postgres.test.ts": 30430,+ "test/e2e/single-write-group-parity-postgres.test.ts": 6740,+ "test/e2e/skill-brain-first.test.ts": 665,+ "test/e2e/skillopt-loop.serial.test.ts": 3160,+ "test/e2e/skillopt-models-strict.serial.test.ts": 2220,+ "test/e2e/skillopt-models-used.serial.test.ts": 1334,+ "test/e2e/skillopt-outcome.serial.test.ts": 3150,+ "test/e2e/skillopt-pglite.serial.test.ts": 1410,+ "test/e2e/skillpack-third-party.test.ts": 1133,+ "test/e2e/skills.test.ts": 359,+ "test/e2e/slug-stamp-double-hyphen.test.ts": 2690,+ "test/e2e/source-boundary-mutation-postgres.test.ts": 714,+ "test/e2e/source-isolation-pglite.test.ts": 3950,+ "test/e2e/source-retire-symlink-manifest.test.ts": 2350,+ "test/e2e/source-routing.test.ts": 880,+ "test/e2e/sources-mirror-read-only-postgres.test.ts": 8890,+ "test/e2e/sources-remote-mcp.test.ts": 6570,+ "test/e2e/sources-remove-bindings.test.ts": 1037,+ "test/e2e/sql-trace-postgres.test.ts": 1340,+ "test/e2e/status-pglite.test.ts": 1448,+ "test/e2e/storage-tiering.test.ts": 2060,+ "test/e2e/subagent-crash-replay-multi-provider.test.ts": 2150,+ "test/e2e/subagent-gateway-path.test.ts": 2060,+ "test/e2e/subagent-gateway-resume-reconciliation.test.ts": 1830,+ "test/e2e/supavisor-read-pool.test.ts": 135,+ "test/e2e/supervisor-stop-drain-5062.test.ts": 26480,+ "test/e2e/symbol-resolver-pglite.test.ts": 1500,+ "test/e2e/sync-cjk-git.test.ts": 369,+ "test/e2e/sync-credential-preflight.test.ts": 1201,+ "test/e2e/sync-delegation-under-serve.serial.test.ts": 72440,+ "test/e2e/sync-lock-overlap-postgres.test.ts": 8109.999999999999,+ "test/e2e/sync-lock-recovery.test.ts": 5040,+ "test/e2e/sync-parallel.test.ts": 4740,+ "test/e2e/sync-reconcile-postgres.test.ts": 2630,+ "test/e2e/sync-rename-collision.test.ts": 2040,+ "test/e2e/sync-run-workers-postgres.test.ts": 1477,+ "test/e2e/sync-sigkill-resume-postgres.test.ts": 8820,+ "test/e2e/sync-status-pglite.test.ts": 1149,+ "test/e2e/sync.test.ts": 3560,+ "test/e2e/synthesize-bigint-job-id-postgres.test.ts": 714,+ "test/e2e/system-of-record-invariant.test.ts": 7650,+ "test/e2e/takes-extract-cursor-postgres.test.ts": 606,+ "test/e2e/takes-postgres.test.ts": 1560,+ "test/e2e/takes-propose-accept-managed.test.ts": 13170,+ "test/e2e/takes-row-reservation-postgres.test.ts": 4630,+ "test/e2e/takes-scorecard-parity.test.ts": 1540,+ "test/e2e/takes-weight-rounding-postgres.test.ts": 797,+ "test/e2e/takes-write-ops-postgres.test.ts": 13900,+ "test/e2e/thin-client.test.ts": 7660,+ "test/e2e/think-source-isolation-pglite.test.ts": 867,+ "test/e2e/think-trajectory-pglite.test.ts": 2830,+ "test/e2e/timeline-materialize.test.ts": 7110,+ "test/e2e/timeline-omission.test.ts": 4940,+ "test/e2e/title-arm-postgres.test.ts": 14380,+ "test/e2e/token-usage-skip-locked.test.ts": 1600,+ "test/e2e/transaction-cancel-held-lock.test.ts": 553,+ "test/e2e/transcripts-no-timestamp-pglite.test.ts": 1087,+ "test/e2e/transcripts-secret-audit-postgres.test.ts": 738,+ "test/e2e/transcripts-writeback-fidelity.test.ts": 2110,+ "test/e2e/truncate-cascade-postgres.test.ts": 682,+ "test/e2e/trust-backfill-postgres.test.ts": 4110,+ "test/e2e/trust-cross-session-parity.test.ts": 3120,+ "test/e2e/trust-generation-postgres.test.ts": 5320,+ "test/e2e/trust-route-matrix.test.ts": 8840,+ "test/e2e/trust-taint-dream.test.ts": 5500,+ "test/e2e/trust-taint-origin.test.ts": 3470,+ "test/e2e/trust-tier-postgres.test.ts": 2260,+ "test/e2e/type-unification-full-flow.test.ts": 1530,+ "test/e2e/typed-search-jit-postgres.test.ts": 2110,+ "test/e2e/unbound-source-postgres.test.ts": 34910,+ "test/e2e/unsupported-embedding-identity-postgres.test.ts": 44200,+ "test/e2e/upgrade.test.ts": 663,+ "test/e2e/upsert-chunks-registry-column.test.ts": 1450,+ "test/e2e/v0_29-mcp-dispatch-pglite.test.ts": 1118,+ "test/e2e/vector-candidate-safety-postgres.test.ts": 21930,+ "test/e2e/vector-chunk-statistics-postgres.test.ts": 3950,+ "test/e2e/vector-ef-search-postgres.test.ts": 3010,+ "test/e2e/vector-index-walk-plan-postgres.test.ts": 3100,+ "test/e2e/vector-plan-real-column-postgres.test.ts": 16070,+ "test/e2e/vector-scope-recall-postgres.test.ts": 22840,+ "test/e2e/visibility-withdrawal-postgres.test.ts": 10270,+ "test/e2e/volunteer-context-postgres.test.ts": 692,+ "test/e2e/w5-persistence-postgres.test.ts": 35530,+ "test/e2e/wanted-links-postgres.test.ts": 9320,+ "test/e2e/wave8-lane-d2-postgres.test.ts": 2080,+ "test/e2e/whoknows.test.ts": 5220,+ "test/e2e/withdrawal-bounded-safety-postgres.test.ts": 12650,+ "test/e2e/withdrawal-crash-postgres.test.ts": 5410,+ "test/e2e/withdrawal-discovery-literal-postgres.test.ts": 2260,+ "test/e2e/withdrawal-followup-writes-postgres.test.ts": 4290,+ "test/e2e/withdrawn-detail-postgres.test.ts": 9840,+ "test/e2e/worker-abort-recovery.test.ts": 4420,+ "test/e2e/worker-configuration-release.test.ts": 32049.999999999996,+ "test/e2e/worker-lock-renewal-starvation.test.ts": 4220,+ "test/e2e/worker-readiness-cli.test.ts": 2810,+ "test/e2e/worker-shutdown-error-matrix-postgres.test.ts": 3110,+ "test/e2e/workspace-generic-compat.test.ts": 219,+ "test/e2e/worktree-refresh-postgres.test.ts": 23360,+ "test/e2e/write-attribution-postgres.test.ts": 36310,+ "test/e2e/write-attribution-read-parity.test.ts": 3200,+ "test/e2e/write-attribution-timeline-10k-postgres.test.ts": 19880,+ "test/e2e/write-contract-conformance.test.ts": 44640,+ "test/e2e/write-gate-store-postgres.test.ts": 1249,+ "test/e2e/write-single-dedup-postgres.test.ts": 1013,+ "test/e2e/zombie-reaping.test.ts": 8950,+ "test/phantom-redirect-engine-parity.test.ts": 2390}diff --cc src/commands/doctor/checks/persistence-requests.tsindex 0c9cd28067,a6069058aa..b4fcf64816--- a/src/commands/doctor/checks/persistence-requests.ts+++ b/src/commands/doctor/checks/persistence-requests.ts@@@ -8,9 -8,9 +8,11 @@@ import { readPreparationPolicy } from 'import { resolvePrepare, resolveSessionTimeouts } from '../../../core/db.ts';import { agentFix, checkError, doctorVerify } from '../check-fix.ts';import { lostCallerWrites } from '../../../core/repair/failed-writes.ts';-import { readCapacityForecast, readCapacityThresholds } from '../../../core/persistence/capacity-forecast.ts';+import { readCapacityThresholds } from '../../../core/persistence/capacity-forecast.ts';+import { doctorCapacityForecast, forecastOrNull } from '../capacity-memo.ts';+import { withStatementDeadline } from '../../../core/statement-deadline.ts';+ import { DEFERRED_READ_LABEL, repeatedPostprocessDeferrals } from '../../../core/cycle/synthesize-postprocess-deferral.ts';+ import { PERSISTENCE_REQUEST_ID_INDEX } from '../../../core/persistence/schema.ts';const WINDOW_DAYS = 7;const SAMPLE = 10_000;diff --cc src/core/behavior-change-notice.tsindex fb73116281,d7e9575451..f3bc932f1b--- a/src/core/behavior-change-notice.ts+++ b/src/core/behavior-change-notice.ts@@@ -741,16 -741,17 +741,27 @@@ export const BEHAVIOR_CHANGES: Readonly{ since: '0.60.273.0', text: '`gbrain migrate --to <engine>` through the legacy copier (graduation turned off, or Postgres to PGLite) now refuses a brain that holds page versions, with `writer_coordinator_required`, `reason: page_history` and the number of versions it would discard, instead of copying the pages without them. Nothing changes in either datastore. Graduation from PGLite to Postgres carries versions and is unaffected.' },{ since: '0.60.274.0', text: '`gbrain sources refresh` now completes once every member source has synced to the refresh target or to a commit on top of it. Before, a commit that landed on the target while the refresh synced left it `syncing`, with the worktree fenced, and `--resume` could not finish it either. A refresh left `syncing` by a crashed process still waits for `gbrain sources refresh <source> --resume` when a later sync went past the target.' },{ since: '0.60.274.0', text: '`gbrain repair file-drift --slug|--request` now resolves a live page whose canonical file is gone from the last commit (a held deletion whose page changed, or a write refused `canonical_file_missing`): `--prefer database` recreates the file from the page, and `--prefer file` soft-deletes exactly that page (purged after 72 h; `gbrain restore <slug> --force` undoes it). Both are preview-bound to the page revision and the file\'s absence, and soft deletes honor the mass-delete valve. A file deleted only in the worktree (still committed) is listed `deletion_uncommitted` and routed to committing the deletion or `gbrain repair ghost-pages`. `gbrain sources reconcile --preview` on a missing file names the same routes, and a held deletion\'s next step is the file-drift preview instead of a reconcile preview that refused. An older gbrain refuses a recreate request and writes nothing.' },+ // Wave 18a S1 (#6757 #6782 #6729 #6741 #6749).+ { since: '0.60.276.0', text: 'Dream synthesis postprocess finds committed outputs by request id through a new online index (`persistence_requests_request_id`, built concurrently on Postgres, covered by `gbrain repair request-indexes`). A statement timeout on that read now defers the postprocess to a later pass (kept in `dream.synthesize.postprocess_pending`, finished without another synthesis call) instead of failing the pass (the replay runs no child job and verifies the output\'s quotes against the current transcript; a quote not found goes to `unverified_claims`); three deferrals in a row add a line to doctor `persistence_request_indexes`, whose messages now say "request-table indexes".' },+ { since: '0.60.276.0', text: '`propose_takes` now treats a reply of `[]` followed by prose as an empty extraction and tombstones the page, instead of retrying the paid call every cycle. Pages that were retried forever get a tombstone on their next run. There is no per-page force flag: the tombstone is keyed by a hash of the page body, so any edit to the body re-extracts the page (docs/guides/cron-schedule.md).' },+ { since: '0.60.276.0', text: 'An inexact Git rename (a move that also changed the file, reported as R<100) now keeps its page identity only when the files confirm it: the same frontmatter `id` on both sides that no other file or page carries, or, with no id on either side, a `slug:` line or title (the frontmatter `title:`, else the first `# Heading`, compared with the title the brain stores for the old page) that no other file in the sync and no other live page shares; a respelled path that keeps its slug keeps its page unless the ids conflict (#6729). Any other pair is imported as a delete plus an add: the new file starts a fresh page and the old page keeps its facts, links and aliases on its soft-deleted slug. The sync report prints each pair with `gbrain restore <old-slug> --source-id <id> --force`, `gbrain sync status --json` lists it under `identity_downgrades`, doctor `rename_identity_downgrades` names it, and the purge leaves the old page alone, with no time limit, until the pair gets a disposition (the old page restored, or, once the remedy ships, remedied or closed without merging). A new file whose frontmatter `id` uniquely matches a file deleted in the same sync range, with the same file name, title or bytes, is now its rename even when Git did not pair them; a template id reused by an unrelated new note stays a new page.' },+ { since: '0.60.276.0', text: 'A file moved and broken in the same commit (unreadable frontmatter, so Git reports an inexact rename) is no longer held with the old page identity: the old page is soft-deleted and recorded as above and the broken file is held as a new file (#6729). An exact move (R100) that is held still keeps the old page identity and `rename_from`. A managed sync refuses `page_identity_changed` (detail `rename_identity_conflict`) when a file would take over a page, or a held rename would carry one, whose frontmatter `id` differs from its own.' },+ { since: '0.60.276.0', text: 'A managed sync no longer adopts the one legacy page that folds to a file\'s slug when both carry an explicit frontmatter id and the ids differ: they are different documents, so the file is held `legacy_slug_conflict` with reason `explicit_id_conflict` (#6729, #6727).' },+ { since: '0.60.276.0', text: '`gbrain transcripts ingest --since last` now advances past Codex sub-agent rollouts (session_meta source {subagent: ...}, such as the guardian auto-reviewer). They have no user turn by design, so they are reported as "N sub-agent rollouts (no user turns by design)" (JSON: subagentRollouts), not as drift. An ordinary rollout with assistant turns and no user turn is still drift and still holds the watermark.' },+ { since: '0.60.276.0', text: 'On a writer-claimed brain, `gbrain transcripts ingest` no longer submits a write request for a session part whose page would not change: an unchanged re-ingest takes no permanent request id. A part with pending projection work, a pending request, a missing or edited canonical file, or a large (segmented) page is still submitted.' },+ { since: '0.60.276.0', text: 'On a writer-claimed brain, background writes are refused before any receipt, so they spend no write-request id, when their source cannot publish: the worktree is in recovery, or the claim\'s owner verification fails on the owner host (a missing canonical or coordination path, or a physical root whose owner marker .gbrain-owner.json or reservation is gone or changed; a device-only change is still re-stamped by the write). The refusal is owner_unavailable with the fix `gbrain sources writer status --source <id> --json`, checked once per source per run. Background writes are every write not made from an interactive surface: the autopilot cycle and its maintenance phases (extraction, synthesis, patterns, consolidation, fence and content repair, lint fixes), Minion jobs (sync, extract and the other job handlers), connector syncs, delegated serve syncs started as background, the keep-DB reconcile, autopilot and job managed syncs, and the transcript stale-part delete. Interactive CLI, MCP and repair writes are unaffected; a paused (draining) owner still accepts and replays.' },+ { since: '0.60.276.0', text: 'The managed purge (autopilot purge phase, the purge job and `gbrain pages purge-deleted`) submits nothing for a source whose writer needs recovery (reported `writer_not_active` with its state and reason) and parks a page after five failed purges (doctor `purge_parked_pages`: actor agent on the CLI, host_admin remotely). The cycle purge phase reports warn, not fail, for either. `gbrain pages purge-deleted --retry-parked` retries parked pages once; it obeys `--older-than` (a parked page younger than the cutoff is not retried) and the rename-recovery hold, and its preview, its consent text (which names the parked count) and its run come from one selector.' },+ { since: '0.60.276.0', text: '`gbrain repair content` / `repair slug-conflicts` now clears a frontmatter_slug_conflict hold deterministically (remove_slug) when the only other change autoFixFrontmatter would make is a style-only NESTED_QUOTES re-quote of a valid JSON-style tag or alias array. Only the slug: line is removed; the array is left as written and listed as style_only in the preview, the run result and the content_repair receipt. Such holds used to stay still_invalid and needed `repair frontmatter --include-ambiguous`. When the lane still cannot clear a hold because the frontmatter needs other fixes, the still_invalid message now names those fix codes (for example NULL_BYTES).' },+ // #6803 wave (projection queue, held embedding budgets, bounded doctor/status reads, extraction nudge). `since` is the branch VERSION until the merge-slot stamp.- { since: '0.60.275.0', text: '`gbrain sync --status` now prints the `gbrain sync status` envelope (with a one-line hint) instead of running a full sync of the source, which nothing used to stop because no sync path read the flag. `gbrain sync --preview` and `--check`, which sync never read either, now refuse with `invalid_params` and a `--dry-run` fix; `--dry-run` is unchanged.' },- { since: '0.60.275.0', text: 'A plain non-interactive CLI `gbrain doctor --json` (stderr not a terminal, no `--budget-ms`, `--tier`, `--fix` or remediation flag) now caps its check run at `doctor.default_budget_ms` (90000 ms; file plane; connect and migrations are not counted) and prints one stderr line saying so; checks past it report health unknown, and the JSON gains `tier`, `complete`, `unknown_sections`, `elapsed_ms` and `budget_ms`. `--budget-ms 0` turns it off for one run and `gbrain config set doctor.default_budget_ms 0` for good. `gbrain config set` now accepts `doctor.entry_budget_ms` and `doctor.orphan_ratio.full_scan_max_pages`.' },- { since: '0.60.275.0', text: 'Doctor entries now stop their database statements at their own budget on every tier (Postgres cancels the statement; PGLite refuses the next one), so a slow check no longer keeps a backend running after the report. The cheap incident checks (`persistence_capacity`, `managed_sync_not_moving`, `managed_sync_blocked`, `text_projection_readiness`, `partial_embedding` and `links_extraction_lag`, now its own entry) run right after the ops sections, the frontmatter and fence scans report partial results at the deadline, `--only <check> --budget-ms N` gives that check the whole N, and a check past its budget names which budget (`details.limit`) and prints that rerun.' },- { since: '0.60.275.0', text: '`gbrain sync status` and write and sync receipts wait at most 1.5 s for the shared capacity snapshot and read capacity as unknown for that call when it is late, without clearing or re-announcing a background pause; a snapshot fetch that timed out is no longer cached for a minute. Doctor now computes the capacity forecast once per run instead of twice.' },- { since: '0.60.275.0', text: '`gbrain projections drain` now seals image pages the importer already attested safe (one image chunk written at or after the safe-chunk fence, unchanged since) in place, keyless, with no chunk write or provider call, so image search ranks them again; every other image page stays queued and out of search until its importer re-imports it (`gbrain embed --stale --images --dry-run`, then the paid run). Its `--json` gains `limited`, `sealed`, `sealed_with_visual`, `sealed_text_only`, `statistics_refreshed` and `remaining_by_class`, and under a resident PGLite owner it prints an exclusive stop, drain and start step instead of only refusing. The resident drains text only and probes at most 500 queued rows per tick.' },- { since: '0.60.275.0', text: 'Doctor `text_projection_readiness` counts the queue by class (`pending`, `sealable`, `reimport`, `protected`, `archived`, `failed`, `as_of`): it warns on pending, sealable, reimport and failed rows, with `gbrain projections drain --limit <n>` (asks first) or the paid importer as the fix, and reports protected-OCR and archived-source images as by design (search reports the `projection_by_design` stage for them instead of `projection_pending`). On a PGLite resident it can move from ok to warn; on Postgres it can move from warn to ok. Embed paths no longer queue `embedding_recovery` rows for image pages, `gbrain embed --stale --images` skips sealable pages and reports `ocr_required`, and a read-only notice after upgrading names `gbrain projections drain --dry-run` when image rows are queued.' },- { since: '0.60.275.0', text: '`gbrain embed --stale` and the embed-backfill job report `budget_limited` (pages held for approval or at their per-page cap, by source) and print one line instead of saying nothing; it is never a failure. Doctor `partial_embedding` is its own entry (`--only oversized_pages` no longer emits it) and its fix is a per-source approve, `gbrain embed --held --source <id> --max-usd <N>` with a concrete N, with every other source in `details.by_source`. `gbrain embed --held --dry-run` lists every source and exits 0 on a multi-source brain; `--held --max-usd` without `--source` there refuses with `invalid_params`. Receipts name `gbrain embed --held --dry-run --source <id>` instead of `gbrain reindex --held`, which does not exist.' },- { since: '0.60.275.0', text: 'An explicit `--max-usd N` on `gbrain embed --slugs` or `--held` now releases a held page on a free embedding provider too (#6847); it used to reprint the hold. Free-recipe models cost $0 in the per-page ledger, printed approve commands carry a concrete N (a paid N includes the 1.5x headroom and $0.25 floor), a free provider\'s approve asks for no paid or egress consent, and an approval when embeddings cannot run or the paid model has no price is refused before the hold is released. `--yes` still never releases a hold.' },- { since: '0.60.275.0', text: '`gbrain extract --stale --source <id>` now refuses with `invalid_params` naming `--source-id <id>` instead of running brain-wide; `--source fs` exits 2 `invalid_params` (it exited 1), and `--source db` refuses as ambiguous when a source is named `db`. Rendered extract fixes pin `--source-id`. The end-of-sync extraction nudge stays silent when doctor `links_extraction_lag` would not warn (attendance-blocked meetings no longer count), names both `gbrain extract --stale` and `gbrain extract --stale --catch-up` with estimates, and becomes a run-it-yourself step above two minutes; `extract --stale` JSON gains `actionable`, `attendance_blocked`, `mention_due` and `complete`; the per-source "still owe extraction" line counts only pages that sync imported; and an owner-delegated plain `extract --stale` keeps the 30-minute budget (`--catch-up` is carried through).' },++ { since: '0.60.276.0', text: '`gbrain sync --status` now prints the `gbrain sync status` envelope (with a one-line hint) instead of running a full sync of the source, which nothing used to stop because no sync path read the flag. `gbrain sync --preview` and `--check`, which sync never read either, now refuse with `invalid_params` and a `--dry-run` fix; `--dry-run` is unchanged.' },++ { since: '0.60.276.0', text: 'A plain non-interactive CLI `gbrain doctor --json` (stderr not a terminal, no `--budget-ms`, `--tier`, `--fix` or remediation flag) now caps its check run at `doctor.default_budget_ms` (90000 ms; file plane; connect and migrations are not counted) and prints one stderr line saying so; checks past it report health unknown, and the JSON gains `tier`, `complete`, `unknown_sections`, `elapsed_ms` and `budget_ms`. `--budget-ms 0` turns it off for one run and `gbrain config set doctor.default_budget_ms 0` for good. `gbrain config set` now accepts `doctor.entry_budget_ms` and `doctor.orphan_ratio.full_scan_max_pages`.' },++ { since: '0.60.276.0', text: 'Doctor entries now stop their database statements at their own budget on every tier (Postgres cancels the statement; PGLite refuses the next one), so a slow check no longer keeps a backend running after the report. The cheap incident checks (`persistence_capacity`, `managed_sync_not_moving`, `managed_sync_blocked`, `text_projection_readiness`, `partial_embedding` and `links_extraction_lag`, now its own entry) run right after the ops sections, the frontmatter and fence scans report partial results at the deadline, `--only <check> --budget-ms N` gives that check the whole N, and a check past its budget names which budget (`details.limit`) and prints that rerun.' },++ { since: '0.60.276.0', text: '`gbrain sync status` and write and sync receipts wait at most 1.5 s for the shared capacity snapshot and read capacity as unknown for that call when it is late, without clearing or re-announcing a background pause; a snapshot fetch that timed out is no longer cached for a minute. Doctor now computes the capacity forecast once per run instead of twice.' },++ { since: '0.60.276.0', text: '`gbrain projections drain` now seals image pages the importer already attested safe (one image chunk written at or after the safe-chunk fence, unchanged since) in place, keyless, with no chunk write or provider call, so image search ranks them again; every other image page stays queued and out of search until its importer re-imports it (`gbrain embed --stale --images --dry-run`, then the paid run). Its `--json` gains `limited`, `sealed`, `sealed_with_visual`, `sealed_text_only`, `statistics_refreshed` and `remaining_by_class`, and under a resident PGLite owner it prints an exclusive stop, drain and start step instead of only refusing. The resident drains text only and probes at most 500 queued rows per tick.' },++ { since: '0.60.276.0', text: 'Doctor `text_projection_readiness` counts the queue by class (`pending`, `sealable`, `reimport`, `protected`, `archived`, `failed`, `as_of`): it warns on pending, sealable, reimport and failed rows, with `gbrain projections drain --limit <n>` (asks first) or the paid importer as the fix, and reports protected-OCR and archived-source images as by design (search reports the `projection_by_design` stage for them instead of `projection_pending`). On a PGLite resident it can move from ok to warn; on Postgres it can move from warn to ok. Embed paths no longer queue `embedding_recovery` rows for image pages, `gbrain embed --stale --images` skips sealable pages and reports `ocr_required`, and a read-only notice after upgrading names `gbrain projections drain --dry-run` when image rows are queued.' },++ { since: '0.60.276.0', text: '`gbrain embed --stale` and the embed-backfill job report `budget_limited` (pages held for approval or at their per-page cap, by source) and print one line instead of saying nothing; it is never a failure. Doctor `partial_embedding` is its own entry (`--only oversized_pages` no longer emits it) and its fix is a per-source approve, `gbrain embed --held --source <id> --max-usd <N>` with a concrete N, with every other source in `details.by_source`. `gbrain embed --held --dry-run` lists every source and exits 0 on a multi-source brain; `--held --max-usd` without `--source` there refuses with `invalid_params`. Receipts name `gbrain embed --held --dry-run --source <id>` instead of `gbrain reindex --held`, which does not exist.' },++ { since: '0.60.276.0', text: 'An explicit `--max-usd N` on `gbrain embed --slugs` or `--held` now releases a held page on a free embedding provider too (#6847); it used to reprint the hold. Free-recipe models cost $0 in the per-page ledger, printed approve commands carry a concrete N (a paid N includes the 1.5x headroom and $0.25 floor), a free provider\'s approve asks for no paid or egress consent, and an approval when embeddings cannot run or the paid model has no price is refused before the hold is released. `--yes` still never releases a hold.' },++ { since: '0.60.276.0', text: '`gbrain extract --stale --source <id>` now refuses with `invalid_params` naming `--source-id <id>` instead of running brain-wide; `--source fs` exits 2 `invalid_params` (it exited 1), and `--source db` refuses as ambiguous when a source is named `db`. Rendered extract fixes pin `--source-id`. The end-of-sync extraction nudge stays silent when doctor `links_extraction_lag` would not warn (attendance-blocked meetings no longer count), names both `gbrain extract --stale` and `gbrain extract --stale --catch-up` with estimates, and becomes a run-it-yourself step above two minutes; `extract --stale` JSON gains `actionable`, `attendance_blocked`, `mention_due` and `complete`; the per-source "still owe extraction" line counts only pages that sync imported; and an owner-delegated plain `extract --stale` keeps the 30-minute budget (`--catch-up` is carried through).' },];/** The newest disclosed change's release: the notice id moves only when a release adds rows. */