Skip to content

Garry's Opinionated OpenClaw/Hermes Agent Brain

TypeScript

v0.60.453.0 chore(release): restamp onto master v0.60.452.0

garrytan12dc7898e8be
diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json
index 745ff72231..3069421364 100644
--- a/.claude-plugin/plugin.json
+++ b/.claude-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Personal knowledge brain for your coding agent — hybrid search, synthesis, graph traversal, and durable cross-session memory over Postgres/PGLite with pgvector, plus a curated brain-first skill set.",
"author": {
"name": "Garry Tan",
diff --git a/.codex-plugin/plugin.json b/.codex-plugin/plugin.json
index c7c06ba00b..fd8dac27ff 100644
--- a/.codex-plugin/plugin.json
+++ b/.codex-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Personal knowledge brain for your coding agent — hybrid search, synthesis, graph traversal, and durable cross-session memory over Postgres/PGLite with pgvector, plus a curated brain-first skill set.",
"author": {
"name": "Garry Tan",
diff --git a/BOOTSTRAP_FOR_AGENTS.md b/BOOTSTRAP_FOR_AGENTS.md
index d94ff4ffe3..bd47c0ba40 100644
--- a/BOOTSTRAP_FOR_AGENTS.md
+++ b/BOOTSTRAP_FOR_AGENTS.md
@@ -1,4 +1,4 @@
-<!-- gbrain-runbook-stamp: 0.60.452.0 -->
+<!-- gbrain-runbook-stamp: 0.60.453.0 -->
<!-- This stamp must equal the VERSION file at every release; CI enforces it
(scripts/check-bootstrap-tag.sh). `gbrain bootstrap status` compares it to
the installed binary and warns on skew. -->
diff --git a/CHANGELOG.md b/CHANGELOG.md
index f6d312ec3a..8124ac7eb9 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,34 @@ credits are retained; no result has been reassigned to another provider. Origina
identifiers and attribution are available in the pre-removal Git revision
`6040075c6cb95be5881cc2e1b76ef7d71f4e5d29` (retained on 2026-09-23).
+## [0.60.453.0] - 2026-10-25
+
+**Large pages (over 1 MiB, stored in segments) now keep their links, mentions, timeline, fences, conversation facts and synopses per segment. A write reads only the segments it changed, an append reads only its new tail, and appending to a long conversation re-extracts facts for the new messages only. A sentence that a forced chunk cut used to split is now found whole by search. New transcript sessions import as one page. A page's new chunks go to the embedding provider once.**
+
+### What changed
+
+| Situation | Before | Now |
+|---|---|---|
+| Editing or appending to a large page | links, mentions, timeline entries and facts/takes fences were derived from the whole page | each is kept per segment; only changed segments (or the new tail) are read, with the same results. A rewrite of the whole page costs what it did before |
+| Appending to a long conversation page | fact extraction re-read the conversation | only the new messages' windows are extracted; each fact records the window it came from (`facts.source_window`) |
+| A conversation window whose extraction keeps failing for its own reason (malformed or truncated output, a refusal, input too long) | blocked the older windows behind it | after three runs in a row it is skipped with a receipt and `gbrain doctor` names it; the facts it had stay. Provider outages, auth errors and rate limits never count |
+| A transcript whose format cannot be detected | the extractor guessed | all 22 built-in formats are counted: a page with no messages settles, one with messages is held (no calls, nothing deleted) with a `detection_ambiguous` receipt and doctor `conversation_detection_ambiguous`, until you choose: `gbrain extract-conversation-facts --source-id <s> --slug <slug> --grammar <format\|none> [--dry-run]` |
+| Paying for fact, atom and synopsis extraction on a large page | counted against `embed.max_usd_per_page` | its own cap, `derive.max_usd_per_page` (default $2 per kind over the page's lifetime; unlimited under `spend.posture tokenmax` when unset; `off` disables it). `embed.max_usd_per_page` counts embeddings only. A model with no price records `unpriced_model`, and doctor `derivation_unpriced_model` names the `gbrain pricing set` command |
+| `contextual_retrieval` set to `per_chunk_synopsis` on a large page | the page stayed on the title tier | each chunk gets a synopsis from the title, the page's first 8 KiB and up to 32 KB of its own segment; an unchanged window keeps its synopsis vectors |
+| Long passages on large pages | a forced cut could split a sentence across two chunks | a forced cut lands on a sentence or line end, and timeline passages break only between bullet entries, so a top insert into a long timeline re-embeds at most 2 chunks. Existing pages move with `gbrain reindex --segmented` (preview first, `--apply` to run; never on upgrade). Inline pages are unchanged |
+| A new transcript session | imported as part pages | one page up to the page ceiling. Existing split sessions keep stable parts and no longer rewrite every part when the session grows |
+| Several writers embedding the same page | the post-write effect, `embed --stale`, the backfill job and phase-end embeds could each send the same chunks | a per-page lease means each chunk content version goes to the provider once |
+| Forgetting or purging a fact on a large page | stored link, mention, timeline and fence results could still hold the claim | they are deleted with it. A fact purge also sweeps every stored result in the source that holds the claim (in its normalized form), in short batches. While a sweep is pending, derivation writes holding the claim are refused, and paid steps on covered pages wait (`purge_sweep_pending`). The receipt stays `pending` (exit 75) until nothing is left: `gbrain forget --purge --status --request-id <r> --continue` finishes it, and doctor `derivation_purge_sweeps` names it |
+| Conversation facts from a private page | the segmented and managed paths could publish them as world | they stay private |
+
+### What to watch for after you upgrade
+
+- Migration v273 adds per-segment derivation watermarks (`page_segment_derivations`), `facts.source_window`, the per-page derivation spend ledger and the purge-sweep tables. It is additive. Nothing is re-extracted, re-chunked or re-embedded on upgrade.
+- To move existing large pages to sentence-aligned chunks and bullet-aligned timelines, run `gbrain reindex --segmented`, read the preview, then add `--apply`.
+- On the first transcript run after upgrade, existing transcript parts are rewritten once, with new titles and frontmatter.
+- A held transcript page waits for your `--grammar` choice. Stale facts on it are not collected automatically.
+- A pending purge sweep continues only with `--continue` or a later purge in the same source.
+
## [0.60.452.0] - 2026-10-25
**`search` and `query` take `source_ids`, so one request can be narrowed to the sources the person it serves may see on a shared brain, and the starter MCP tool list that harnesses re-fetch every turn is about 27% smaller: 19,489 bytes instead of 26,546 over stdio (35 tools) and 18,825 instead of 25,555 over HTTP (33 tools). The list only narrows; the token's grant stays the boundary. Every tool is still listed, and every parameter the starter list leaves out is still accepted and comes back from `request_tools {tools: [...]}`.**
diff --git a/VERSION b/VERSION
index 55eefc0951..6bbfea79c7 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.60.452.0
+0.60.453.0
diff --git a/openclaw.plugin.json b/openclaw.plugin.json
index e3f89558cf..f317e135ad 100644
--- a/openclaw.plugin.json
+++ b/openclaw.plugin.json
@@ -1,7 +1,7 @@
{
"id": "gbrain-context-engine",
"name": "gbrain",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Personal knowledge brain with Postgres + pgvector hybrid search",
"family": "bundle-plugin",
"kind": "context-engine",
diff --git a/package.json b/package.json
index 607ce91985..991f592bb5 100644
--- a/package.json
+++ b/package.json
@@ -246,7 +246,7 @@
"bun": ">=1.4.0"
},
"license": "MIT",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"overrides": {
"@ai-sdk/provider-utils": "4.0.56",
"@hono/node-server": "^2.0.5",
diff --git a/plugin-variants/gbrain-coding/.claude-plugin/plugin.json b/plugin-variants/gbrain-coding/.claude-plugin/plugin.json
index 8ada38f718..57082532cd 100644
--- a/plugin-variants/gbrain-coding/.claude-plugin/plugin.json
+++ b/plugin-variants/gbrain-coding/.claude-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain-coding",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Brain-first coding agent working inside a repo: retrieval, routing, ingest discipline, correction hygiene. Default persona for the claude-code harness bridge; also published as the gbrain-coding marketplace variant. (persona variant of the gbrain plugin — 21 skills)",
"author": {
"name": "Garry Tan",
diff --git a/plugin-variants/gbrain-coding/.codex-plugin/plugin.json b/plugin-variants/gbrain-coding/.codex-plugin/plugin.json
index 01d3b41efc..97b89913a7 100644
--- a/plugin-variants/gbrain-coding/.codex-plugin/plugin.json
+++ b/plugin-variants/gbrain-coding/.codex-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain-coding",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Brain-first coding agent working inside a repo: retrieval, routing, ingest discipline, correction hygiene. Default persona for the claude-code harness bridge; also published as the gbrain-coding marketplace variant. (persona variant of the gbrain plugin — 21 skills)",
"author": {
"name": "Garry Tan",
diff --git a/plugin-variants/gbrain-coding/README.md b/plugin-variants/gbrain-coding/README.md
index 0166fe3f39..219680e51c 100644
--- a/plugin-variants/gbrain-coding/README.md
+++ b/plugin-variants/gbrain-coding/README.md
@@ -1,4 +1,4 @@
-<!-- gbrain-plugin-tree-stamp: 0.60.452.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.453.0 -->
# gbrain-coding (generated persona variant — do not hand-edit)
Brain-first coding agent working inside a repo: retrieval, routing, ingest discipline, correction hygiene. Default persona for the claude-code harness bridge; also published as the gbrain-coding marketplace variant.
diff --git a/plugin-variants/gbrain-daily/.claude-plugin/plugin.json b/plugin-variants/gbrain-daily/.claude-plugin/plugin.json
index 7ffbc2a189..ff49429a76 100644
--- a/plugin-variants/gbrain-daily/.claude-plugin/plugin.json
+++ b/plugin-variants/gbrain-daily/.claude-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain-daily",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Personal knowledge-brain daily use: meetings, tasks, briefings, reading, research. Published as the gbrain-daily marketplace variant. (persona variant of the gbrain plugin — 20 skills)",
"author": {
"name": "Garry Tan",
diff --git a/plugin-variants/gbrain-daily/.codex-plugin/plugin.json b/plugin-variants/gbrain-daily/.codex-plugin/plugin.json
index 2dfa545492..b5c8bcb2d1 100644
--- a/plugin-variants/gbrain-daily/.codex-plugin/plugin.json
+++ b/plugin-variants/gbrain-daily/.codex-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain-daily",
- "version": "0.60.452.0",
+ "version": "0.60.453.0",
"description": "Personal knowledge-brain daily use: meetings, tasks, briefings, reading, research. Published as the gbrain-daily marketplace variant. (persona variant of the gbrain plugin — 20 skills)",
"author": {
"name": "Garry Tan",
diff --git a/plugin-variants/gbrain-daily/README.md b/plugin-variants/gbrain-daily/README.md
index 87026cd58b..77b8cfd13a 100644
--- a/plugin-variants/gbrain-daily/README.md
+++ b/plugin-variants/gbrain-daily/README.md
@@ -1,4 +1,4 @@
-<!-- gbrain-plugin-tree-stamp: 0.60.452.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.453.0 -->
# gbrain-daily (generated persona variant — do not hand-edit)
Personal knowledge-brain daily use: meetings, tasks, briefings, reading, research. Published as the gbrain-daily marketplace variant.
diff --git a/plugin/README.md b/plugin/README.md
index e61c503726..1401be6345 100644
--- a/plugin/README.md
+++ b/plugin/README.md
@@ -1,4 +1,4 @@
-<!-- gbrain-plugin-tree-stamp: 0.60.452.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.453.0 -->
# gbrain plugin skill tree (generated — do not hand-edit)
This tree is the curated skill set for the gbrain Codex and Claude Code
diff --git a/src/core/behavior-change-notice.ts b/src/core/behavior-change-notice.ts
index 74c0fe8504..dea5a985ed 100644
--- a/src/core/behavior-change-notice.ts
+++ b/src/core/behavior-change-notice.ts
@@ -1066,30 +1066,30 @@ export const BEHAVIOR_CHANGES: ReadonlyArray<{ since: string; text: ChangeText;
{ since: '0.60.338.0', text: 'The keyword arm keeps one chunk per page in its candidate pool (Postgres and PGLite), so a page with hundreds of matching chunks no longer pushes every other matching page out of the results.' },
{ since: '0.60.338.0', text: 'The title arm\'s any-word retry (after an all-words title match finds nothing) now matches page titles only, as remote callers already did, and drops repeated words (#7135): a date in a question no longer pulls every dated timeline into ranking, which cut a 3-5 s title arm to well under a second on a large brain. A local all-words title match is unchanged.' },
// PR 4 E (one provider call per chunk content version, gbrain-evals#180). `since` is stamped at the merge slot.
- { since: 'TBD', text: 'A page\'s new chunks now go to the embedding provider once per content version. The post-write embedding effect, `gbrain embed --stale`, the embed-backfill job and phase-end embeds each hold a per-page lease (a `gbrain_cycle_locks` row named `embed-page:<page id>`, refreshed while held, expiring within 2 minutes after a holder dies) from reading which chunks lack a vector through installing them; a path that reaches a page another path is embedding waits for it, then embeds only the chunks still missing a vector. The wait ends at the caller\'s deadline or after 2 minutes: a stale drain then skips the page (its chunks stay stale for the next run, not counted as a failure) and an embedding effect retries with `lock_busy`. A holder renews the lease inside its install transaction and installs nothing (`lock_busy`) when the lease expired and another path took it; every release deletes the expired `embed-page:` rows a crashed holder left, so doctor `stale_locks` stops listing them after the next embed. Managed-persistence activation, deactivation and shared-skill activation no longer count `embed-page:` rows, live or expired, as legacy locks or blockers. Before, a stale drain that ran while a write\'s embedding effect was in flight sent the same chunks twice (paid twice on a paid provider). Live `embed-page:` rows can show in the `gbrain status` lock list while an embed runs.' },
+ { since: '0.60.453.0', text: 'A page\'s new chunks now go to the embedding provider once per content version. The post-write embedding effect, `gbrain embed --stale`, the embed-backfill job and phase-end embeds each hold a per-page lease (a `gbrain_cycle_locks` row named `embed-page:<page id>`, refreshed while held, expiring within 2 minutes after a holder dies) from reading which chunks lack a vector through installing them; a path that reaches a page another path is embedding waits for it, then embeds only the chunks still missing a vector. The wait ends at the caller\'s deadline or after 2 minutes: a stale drain then skips the page (its chunks stay stale for the next run, not counted as a failure) and an embedding effect retries with `lock_busy`. A holder renews the lease inside its install transaction and installs nothing (`lock_busy`) when the lease expired and another path took it; every release deletes the expired `embed-page:` rows a crashed holder left, so doctor `stale_locks` stops listing them after the next embed. Managed-persistence activation, deactivation and shared-skill activation no longer count `embed-page:` rows, live or expired, as legacy locks or blockers. Before, a stale drain that ran while a write\'s embedding effect was in flight sent the same chunks twice (paid twice on a paid provider). Live `embed-page:` rows can show in the `gbrain status` lock list while an embed runs.' },
// PR 4 recall (Wave B incremental derivation, transcripts). `since` is restamped at the merge slot.
- { since: 'TBD', text: 'Pages over 1 MiB (stored in segments) now cut a long passage that has to be split at a sentence or line end, so a sentence the old cut split across two chunks is found whole by keyword and vector search; and their timeline passages break only between bullet entries, at entries chosen by their own text, so an entry added at the top of the timeline re-embeds at most two passages instead of every passage after it. Pages stored before keep serving their chunks: `gbrain reindex --segmented` lists them with the chunk counts that would change and writes nothing; `--apply` re-chunks only the segments that change and keeps the vectors of unchanged chunk texts, and `gbrain embed --stale` embeds the new ones. Nothing re-chunks on upgrade.' },
+ { since: '0.60.453.0', text: 'Pages over 1 MiB (stored in segments) now cut a long passage that has to be split at a sentence or line end, so a sentence the old cut split across two chunks is found whole by keyword and vector search; and their timeline passages break only between bullet entries, at entries chosen by their own text, so an entry added at the top of the timeline re-embeds at most two passages instead of every passage after it. Pages stored before keep serving their chunks: `gbrain reindex --segmented` lists them with the chunk counts that would change and writes nothing; `--apply` re-chunks only the segments that change and keeps the vectors of unchanged chunk texts, and `gbrain embed --stale` embeds the new ones. Nothing re-chunks on upgrade.' },
// PR 4 4e (Wave B incremental derivation, transcripts). `since` is restamped at the merge slot.
- { since: 'TBD', text: 'New transcript sessions import as one page; existing split sessions stop rewriting every part when a session grows. `gbrain transcripts ingest` writes a session with no part pages as one page up to the page ceiling (`pages.max_bytes` or the content-sanity block line, whichever is lower), at its base slug with the same `<id>-p1` identity; only a message or session over that ceiling continues into `-pN` pages. A session already split into parts keeps them and their grouping. The part count left hashed content (titles read `(part X)`, `transcript_import.of` is gone and `part_bytes` records the part size), so each part is rewritten once on its next import; after that a grown session changes only its last part or adds one. Nothing merges a split session into one page. The part size is read only from parts the importer last wrote, so a remote edit of `transcript_import` cannot change how a session splits, and a session that would render over 2,000 parts is reported as an errored session with nothing written.' },
+ { since: '0.60.453.0', text: 'New transcript sessions import as one page; existing split sessions stop rewriting every part when a session grows. `gbrain transcripts ingest` writes a session with no part pages as one page up to the page ceiling (`pages.max_bytes` or the content-sanity block line, whichever is lower), at its base slug with the same `<id>-p1` identity; only a message or session over that ceiling continues into `-pN` pages. A session already split into parts keeps them and their grouping. The part count left hashed content (titles read `(part X)`, `transcript_import.of` is gone and `part_bytes` records the part size), so each part is rewritten once on its next import; after that a grown session changes only its last part or adds one. Nothing merges a split session into one page. The part size is read only from parts the importer last wrote, so a remote edit of `transcript_import` cannot change how a session splits, and a session that would render over 2,000 parts is reported as an errored session with nothing written.' },
// PR 4 (Wave B incremental derivation, transcripts)
// PR 4 4b
- { since: 'TBD', text: 'Appending to a long conversation now re-extracts facts only for the new messages.' },
- { since: 'TBD', text: 'Fact and synopsis extraction on a large page now each have their own per-page spend cap, `derive.max_usd_per_page` (default $2 per kind over the page\'s lifetime; unlimited under `spend.posture tokenmax` when unset; `off` disables it), separate from `embed.max_usd_per_page`, which now counts embeddings only, so extraction never uses up a page\'s embedding budget and a new embedding model does not reset extraction spend. Each call reserves its worst case (every retry) and books what the provider reported; a call that failed after the provider answered is still booked, a call the provider may have billed (a timeout, an abort, a dropped connection, a server or gateway error, each retry the provider SDK made) books its worst case, and only one the provider refused outright (a rate limit, an auth or request error, with no usage reported) or a failed embedding books nothing; metered calls, the synopsis step\'s embedding included, turn the SDK\'s hidden retries off. Doctor lists the pages a cap stopped. A model with no price still reserves its ceiling estimate (about one window per page at the default cap; no default changed and no price is assumed), and its receipt now says `unpriced_model` with the model; doctor `derivation_unpriced_model` warns and names the fix, `gbrain pricing set <model> --input <usd> --output <usd>`, which writes `pricing.overrides`.' },
- { since: 'TBD', text: 'A conversation window whose fact extraction fails for a reason of its own (malformed or truncated output, a refusal, input too long) in three runs in a row is now skipped with a receipt, so the older windows of the page still get extracted, and the facts it had before stay; provider outages, auth errors and rate limits never count. `gbrain doctor` names the window and `gbrain extract-conversation-facts --slug <slug> --force` tries it again. Incremental runs on a large conversation page only add or replace facts window by window; facts are removed only when their exact window is extracted again or when a run finishes the whole page with no failed window, no cap, no window limit and no `--since`, which then clears the facts of windows no longer on the page. The page\'s chat format is detected over the whole page (not its first 64 KB) whenever it is not already known; a page whose format is no longer detected over the whole page (text added around a transcript can outweigh its message lines, or it quotes another format) while some conversation format still parses a message in it is now held instead of guessed: no model call, no fact added or removed, so stale facts on such a page wait for the operator\'s call. `gbrain doctor` lists it as `conversation_detection_ambiguous` with each format\'s message count, and `gbrain extract-conversation-facts --source-id <source> --slug <slug> --grammar <format> --dry-run` previews what a run under that format would extract and remove; without `--dry-run` it runs, and `--grammar none` settles the page as not a transcript and clears its conversation facts. `--grammar` applies to one page: a slug in more than one source needs `--source-id`, and the command refuses without it. The choice holds until the page changes; then the page is detected again, and when still no format is detected it is held for a new choice. A page no conversation format parses a message in (facts an older extractor left included) is no longer a transcript: it is marked non-extractable and its conversation facts are cleared, even under `--force`. A page that reads as a transcript yet parses no message keeps every fact and leaves a `no_messages` receipt doctor lists. A run settles and clears only if the page is still the version it read when the publication locks it, so a write that lands during the run leaves the page for the next run with every fact kept. Until a run settles, a page can briefly hold more facts than a settled extraction would: a run that stops partway (an abort, a crash, a limit) adds the facts of the windows it finished, and the facts of windows those replaced on the page stay until a later run extracts their exact window again or settles the page.' },
+ { since: '0.60.453.0', text: 'Appending to a long conversation now re-extracts facts only for the new messages.' },
+ { since: '0.60.453.0', text: 'Fact and synopsis extraction on a large page now each have their own per-page spend cap, `derive.max_usd_per_page` (default $2 per kind over the page\'s lifetime; unlimited under `spend.posture tokenmax` when unset; `off` disables it), separate from `embed.max_usd_per_page`, which now counts embeddings only, so extraction never uses up a page\'s embedding budget and a new embedding model does not reset extraction spend. Each call reserves its worst case (every retry) and books what the provider reported; a call that failed after the provider answered is still booked, a call the provider may have billed (a timeout, an abort, a dropped connection, a server or gateway error, each retry the provider SDK made) books its worst case, and only one the provider refused outright (a rate limit, an auth or request error, with no usage reported) or a failed embedding books nothing; metered calls, the synopsis step\'s embedding included, turn the SDK\'s hidden retries off. Doctor lists the pages a cap stopped. A model with no price still reserves its ceiling estimate (about one window per page at the default cap; no default changed and no price is assumed), and its receipt now says `unpriced_model` with the model; doctor `derivation_unpriced_model` warns and names the fix, `gbrain pricing set <model> --input <usd> --output <usd>`, which writes `pricing.overrides`.' },
+ { since: '0.60.453.0', text: 'A conversation window whose fact extraction fails for a reason of its own (malformed or truncated output, a refusal, input too long) in three runs in a row is now skipped with a receipt, so the older windows of the page still get extracted, and the facts it had before stay; provider outages, auth errors and rate limits never count. `gbrain doctor` names the window and `gbrain extract-conversation-facts --slug <slug> --force` tries it again. Incremental runs on a large conversation page only add or replace facts window by window; facts are removed only when their exact window is extracted again or when a run finishes the whole page with no failed window, no cap, no window limit and no `--since`, which then clears the facts of windows no longer on the page. The page\'s chat format is detected over the whole page (not its first 64 KB) whenever it is not already known; a page whose format is no longer detected over the whole page (text added around a transcript can outweigh its message lines, or it quotes another format) while some conversation format still parses a message in it is now held instead of guessed: no model call, no fact added or removed, so stale facts on such a page wait for the operator\'s call. `gbrain doctor` lists it as `conversation_detection_ambiguous` with each format\'s message count, and `gbrain extract-conversation-facts --source-id <source> --slug <slug> --grammar <format> --dry-run` previews what a run under that format would extract and remove; without `--dry-run` it runs, and `--grammar none` settles the page as not a transcript and clears its conversation facts. `--grammar` applies to one page: a slug in more than one source needs `--source-id`, and the command refuses without it. The choice holds until the page changes; then the page is detected again, and when still no format is detected it is held for a new choice. A page no conversation format parses a message in (facts an older extractor left included) is no longer a transcript: it is marked non-extractable and its conversation facts are cleared, even under `--force`. A page that reads as a transcript yet parses no message keeps every fact and leaves a `no_messages` receipt doctor lists. A run settles and clears only if the page is still the version it read when the publication locks it, so a write that lands during the run leaves the page for the next run with every fact kept. Until a run settles, a page can briefly hold more facts than a settled extraction would: a run that stops partway (an abort, a crash, a limit) adds the facts of the windows it finished, and the facts of windows those replaced on the page stay until a later run extracts their exact window again or settles the page.' },
// PR 4 (Wave B incremental derivation, transcripts) — 4c, contextual synopsis per segment. `since` is restamped at the merge slot.
- { since: 'TBD', text: 'With contextual retrieval set to `per_chunk_synopsis`, a page stored in segments now gets per-chunk synopses instead of staying on the title tier: each chunk\'s synopsis reads the page title, the first 8 KiB of the page and up to 32 KB of its own segment, so the contextual re-embed (`gbrain reindex --markdown` and the per-chunk synopsis backfill) re-synopsizes only the segments an append or edit rewrote and leaves every other chunk\'s vector as it is. The page\'s synopsis cap (`derive.max_usd_per_page`) bounds the synopsis calls: when it is reached, the rest of the page keeps its title-tier vectors (`budget_limited`) and nothing more is spent. A chunk whose synopsis the model refuses is embedded at the title tier. After `gbrain reindex --segmented --apply` re-chunks a page, the next pass synopsizes its new chunks. Pages read whole are unchanged.' },
+ { since: '0.60.453.0', text: 'With contextual retrieval set to `per_chunk_synopsis`, a page stored in segments now gets per-chunk synopses instead of staying on the title tier: each chunk\'s synopsis reads the page title, the first 8 KiB of the page and up to 32 KB of its own segment, so the contextual re-embed (`gbrain reindex --markdown` and the per-chunk synopsis backfill) re-synopsizes only the segments an append or edit rewrote and leaves every other chunk\'s vector as it is. The page\'s synopsis cap (`derive.max_usd_per_page`) bounds the synopsis calls: when it is reached, the rest of the page keeps its title-tier vectors (`budget_limited`) and nothing more is spent. A chunk whose synopsis the model refuses is embedded at the title tier. After `gbrain reindex --segmented --apply` re-chunks a page, the next pass synopsizes its new chunks. Pages read whole are unchanged.' },
// PR 4 (Wave B incremental derivation, transcripts)
// PR 4 4a
- { since: 'TBD', text: 'Links, mentions, timeline entries and facts/takes fences of a large (segmented) page are now kept per segment, so a write reads only the segments it changed, and an append reads its new tail instead of the whole page. A rewrite of the whole page does the same work as before. The results are unchanged.' },
- { since: 'TBD', text: 'Forgetting, purging or withdrawing a fact on a large page now also deletes the stored link, mention, timeline and fence results of the segment that held it, and of segments an earlier write replaced, in the same transaction. A fact purge also deletes every stored result anywhere in the source that still holds the claim (including a page since stored inline) and counts them as `page_segment_derivations`; stored fence results keep a digest of the fence, never its text. A derivation that read a page before a purge, forget or edit no longer writes its results after it.' },
- { since: 'TBD', text: 'A fact purge now finds stored link, mention, timeline and fence results by the claim\'s normalized form, as its fact fingerprint does, so a result that states the claim in other letter case, spacing or punctuation, or in a script whose lowercase JavaScript and the database spell differently (Greek, Turkish), is deleted and the receipt sees it. The claim must fill whole words of one stored value. Only results of the pages the purge rewrote, and results no live segment backs any more, are searched and deleted; a result of a live segment of another page holds what that page\'s prose still says, and the receipt lists it under `page_segment_derivations` as `out_of_scope` with that prose.' },
- { since: 'TBD', text: 'A fact purge now also finds stored link, mention, timeline and fence results that spell a Greek claim with a final sigma (ς) where the claim has σ or Σ, or the other way round, or a Turkish dotted capital İ the way JavaScript lowercases it (i̇). It normalizes only the results that contain the claim\'s words in order, so the search costs about what the plain substring search did. When that search still runs past the purge transaction\'s statement budget, the purge fails with `purge_lookup_timeout` and nothing is purged, instead of being retried until the transaction gives up.' },
- { since: 'TBD', text: 'A fact purge now searches stored link, mention, timeline and fence results in batches of 500 rows per statement, and its receipt checks them the same way, so a claim whose words appear in tens of thousands of stored results can be purged instead of always failing with `purge_lookup_timeout`. The purge still commits all at once. It fails with `purge_lookup_timeout`, purging nothing, only when the search runs past two minutes.' },
- { since: 'TBD', text: 'A fact purge no longer searches stored link, mention, timeline and fence results inside its transaction, so other writes to the source are no longer blocked while it walks them. The purge records the claim and commits; it then deletes the results holding the claim in batches of 500 stored results, each in a short transaction of its own, for up to two minutes. From the commit on, a result holding the claim cannot be written back into what the purge covers. When the walk does not finish in that time, the purge still commits, but its receipt reports `page_segment_derivations` as `incomplete`, `completion: incomplete` (exit 75) and `derivation_sweep: pending`. Running the same purge again with its request id, or purging another fact in the source, continues from where the walk stopped. The walk no longer fails a purge with `purge_lookup_timeout` (this replaces the two-minute failure above).' },
- { since: 'TBD', text: 'A fact purge\'s sweep of stored link, mention, timeline and fence results no longer stops for good on large results: a batch that runs past its 5-second statement budget is retried in half as many results, down to one, and a single result that still runs past it is deleted without being read (stored results are rebuilt from the page). Only when even that delete runs past the budget does the sweep stop; its receipt then says `derivation_sweep: stalled`, and other sweeps in the source go on. A purge now sweeps for its own claim first, so an earlier slow sweep no longer holds it back. `gbrain forget --purge --status --request-id <id> --continue` (new) continues a pending or stalled sweep after the fact is gone, and the receipt\'s `next` names it. Before a sweep ends it walks the stored results again until a walk deletes nothing, and walks again the pages where a result entered its scope meanwhile (a segment replaced, a page deleted), so no result holding the claim is left behind. While a sweep is pending, paid synopsis and fact extraction makes no call on a page it covers (receipts say `purge_sweep_pending`), instead of paying again for results the sweep would refuse to store.' },
- { since: 'TBD', text: 'A fact purge now returns once it has recorded the sweep of stored link, mention, timeline and fence results and run it for up to 5 seconds, instead of up to two minutes; when the sweep has not finished by then, the receipt says `derivation_sweep: pending` (exit 75) and `gbrain forget --purge --status --request-id <id> --continue` finishes it. A sweep never deletes a stored synopsis or conversation-fact result without reading it: when one alone runs past the statement budget, the sweep stops with `derivation_sweep: stalled` and `derivation_sweep_reason: paid_row_unreadable`; a result whose page was restored while the sweep was deleting it unread is kept. A sweep no longer ends while a page delete or segment replacement that brought a result into its scope is still uncommitted; it checks that page after the write commits. When the receipt\'s check of stored results runs out of time after the purge\'s own sweep finished verified, the store reports the sweep\'s result (`reason: verified_by_sweep`, with `probe` naming the deadline) instead of `unverified`. New doctor check `derivation_purge_sweeps` names each pending or stalled sweep with its request id and the command that continues it. Doctor `extraction_input_truncated` reports synopsis and fact receipts a pending sweep blocked as `purge_sweep_pending`, pointing at that check instead of `derive.max_usd_per_page`, and a per-chunk synopsis re-embed job a sweep blocked no longer reports `ok`.' },
- { since: 'TBD', text: 'When a fact purge\'s receipt check counts a stored link, mention, timeline or fence result still holding the claim, it now reports it even if it then runs out of time: a result the sweep covers makes `page_segment_derivations` `incomplete` (with `probe` naming where it stopped) instead of `verified_by_sweep`. A result found after the purge\'s sweep had already ended records that sweep again, so the receipt says `derivation_sweep: pending` and `gbrain forget --purge --status --request-id <id> --continue` deletes it. A sweep that reaches its end while a page delete or segment replacement in the source is still uncommitted no longer starts its walk over: it waits up to 1.5 seconds for those writes (writes that arrive meanwhile wait behind it, briefly), then ends after checking only the pages they touched; when they are still open after that, a later call tries again, so steady imports no longer keep a sweep from ending. A sweep also waits for writes that were already open when the purge recorded it before it starts its verifying walk, so one that commits during that walk can no longer leave a result holding the claim behind. Doctor `derivation_purge_sweeps` now says that continuing a sweep can also delete, without reading it, an unpaid stored result in its scope that is too large to read within the statement budget.' },
- { since: 'TBD', text: 'When a fact purge\'s sweep of stored link, mention, timeline and fence results has walked to its end but cannot finish because a write in the source (an import, sync or page edit) is still open past its 1.5-second wait, the receipt now says `derivation_sweep_reason: scope_lock_busy` and its `next` says to let that write finish before continuing with `gbrain forget --purge --status --request-id <id> --continue`, instead of only saying to continue again. Doctor `derivation_purge_sweeps` lists the same reason for that sweep. The reason clears once the sweep moves on.' },
+ { since: '0.60.453.0', text: 'Links, mentions, timeline entries and facts/takes fences of a large (segmented) page are now kept per segment, so a write reads only the segments it changed, and an append reads its new tail instead of the whole page. A rewrite of the whole page does the same work as before. The results are unchanged.' },
+ { since: '0.60.453.0', text: 'Forgetting, purging or withdrawing a fact on a large page now also deletes the stored link, mention, timeline and fence results of the segment that held it, and of segments an earlier write replaced, in the same transaction. A fact purge also deletes every stored result anywhere in the source that still holds the claim (including a page since stored inline) and counts them as `page_segment_derivations`; stored fence results keep a digest of the fence, never its text. A derivation that read a page before a purge, forget or edit no longer writes its results after it.' },
+ { since: '0.60.453.0', text: 'A fact purge now finds stored link, mention, timeline and fence results by the claim\'s normalized form, as its fact fingerprint does, so a result that states the claim in other letter case, spacing or punctuation, or in a script whose lowercase JavaScript and the database spell differently (Greek, Turkish), is deleted and the receipt sees it. The claim must fill whole words of one stored value. Only results of the pages the purge rewrote, and results no live segment backs any more, are searched and deleted; a result of a live segment of another page holds what that page\'s prose still says, and the receipt lists it under `page_segment_derivations` as `out_of_scope` with that prose.' },
+ { since: '0.60.453.0', text: 'A fact purge now also finds stored link, mention, timeline and fence results that spell a Greek claim with a final sigma (ς) where the claim has σ or Σ, or the other way round, or a Turkish dotted capital İ the way JavaScript lowercases it (i̇). It normalizes only the results that contain the claim\'s words in order, so the search costs about what the plain substring search did. When that search still runs past the purge transaction\'s statement budget, the purge fails with `purge_lookup_timeout` and nothing is purged, instead of being retried until the transaction gives up.' },
+ { since: '0.60.453.0', text: 'A fact purge now searches stored link, mention, timeline and fence results in batches of 500 rows per statement, and its receipt checks them the same way, so a claim whose words appear in tens of thousands of stored results can be purged instead of always failing with `purge_lookup_timeout`. The purge still commits all at once. It fails with `purge_lookup_timeout`, purging nothing, only when the search runs past two minutes.' },
+ { since: '0.60.453.0', text: 'A fact purge no longer searches stored link, mention, timeline and fence results inside its transaction, so other writes to the source are no longer blocked while it walks them. The purge records the claim and commits; it then deletes the results holding the claim in batches of 500 stored results, each in a short transaction of its own, for up to two minutes. From the commit on, a result holding the claim cannot be written back into what the purge covers. When the walk does not finish in that time, the purge still commits, but its receipt reports `page_segment_derivations` as `incomplete`, `completion: incomplete` (exit 75) and `derivation_sweep: pending`. Running the same purge again with its request id, or purging another fact in the source, continues from where the walk stopped. The walk no longer fails a purge with `purge_lookup_timeout` (this replaces the two-minute failure above).' },
+ { since: '0.60.453.0', text: 'A fact purge\'s sweep of stored link, mention, timeline and fence results no longer stops for good on large results: a batch that runs past its 5-second statement budget is retried in half as many results, down to one, and a single result that still runs past it is deleted without being read (stored results are rebuilt from the page). Only when even that delete runs past the budget does the sweep stop; its receipt then says `derivation_sweep: stalled`, and other sweeps in the source go on. A purge now sweeps for its own claim first, so an earlier slow sweep no longer holds it back. `gbrain forget --purge --status --request-id <id> --continue` (new) continues a pending or stalled sweep after the fact is gone, and the receipt\'s `next` names it. Before a sweep ends it walks the stored results again until a walk deletes nothing, and walks again the pages where a result entered its scope meanwhile (a segment replaced, a page deleted), so no result holding the claim is left behind. While a sweep is pending, paid synopsis and fact extraction makes no call on a page it covers (receipts say `purge_sweep_pending`), instead of paying again for results the sweep would refuse to store.' },
+ { since: '0.60.453.0', text: 'A fact purge now returns once it has recorded the sweep of stored link, mention, timeline and fence results and run it for up to 5 seconds, instead of up to two minutes; when the sweep has not finished by then, the receipt says `derivation_sweep: pending` (exit 75) and `gbrain forget --purge --status --request-id <id> --continue` finishes it. A sweep never deletes a stored synopsis or conversation-fact result without reading it: when one alone runs past the statement budget, the sweep stops with `derivation_sweep: stalled` and `derivation_sweep_reason: paid_row_unreadable`; a result whose page was restored while the sweep was deleting it unread is kept. A sweep no longer ends while a page delete or segment replacement that brought a result into its scope is still uncommitted; it checks that page after the write commits. When the receipt\'s check of stored results runs out of time after the purge\'s own sweep finished verified, the store reports the sweep\'s result (`reason: verified_by_sweep`, with `probe` naming the deadline) instead of `unverified`. New doctor check `derivation_purge_sweeps` names each pending or stalled sweep with its request id and the command that continues it. Doctor `extraction_input_truncated` reports synopsis and fact receipts a pending sweep blocked as `purge_sweep_pending`, pointing at that check instead of `derive.max_usd_per_page`, and a per-chunk synopsis re-embed job a sweep blocked no longer reports `ok`.' },
+ { since: '0.60.453.0', text: 'When a fact purge\'s receipt check counts a stored link, mention, timeline or fence result still holding the claim, it now reports it even if it then runs out of time: a result the sweep covers makes `page_segment_derivations` `incomplete` (with `probe` naming where it stopped) instead of `verified_by_sweep`. A result found after the purge\'s sweep had already ended records that sweep again, so the receipt says `derivation_sweep: pending` and `gbrain forget --purge --status --request-id <id> --continue` deletes it. A sweep that reaches its end while a page delete or segment replacement in the source is still uncommitted no longer starts its walk over: it waits up to 1.5 seconds for those writes (writes that arrive meanwhile wait behind it, briefly), then ends after checking only the pages they touched; when they are still open after that, a later call tries again, so steady imports no longer keep a sweep from ending. A sweep also waits for writes that were already open when the purge recorded it before it starts its verifying walk, so one that commits during that walk can no longer leave a result holding the claim behind. Doctor `derivation_purge_sweeps` now says that continuing a sweep can also delete, without reading it, an unpaid stored result in its scope that is too large to read within the statement budget.' },
+ { since: '0.60.453.0', text: 'When a fact purge\'s sweep of stored link, mention, timeline and fence results has walked to its end but cannot finish because a write in the source (an import, sync or page edit) is still open past its 1.5-second wait, the receipt now says `derivation_sweep_reason: scope_lock_busy` and its `next` says to let that write finish before continuing with `gbrain forget --purge --status --request-id <id> --continue`, instead of only saying to continue again. Doctor `derivation_purge_sweeps` lists the same reason for that sweep. The reason clears once the sweep moves on.' },
// GBRA-159 visibility hotfix.
{ since: '0.60.341.0', text: 'Nothing derived from a private page is stored wider than the page. Facts extracted from a `visibility: private` page are private even when `facts.default_visibility` is world (before, a fact with no fence page was then returned to remote callers by recall and the entity card), and a page marked private only by `access: private|restricted|confidential` or `confidentiality: confidential|secret|private|restricted` counts as private for its facts, chronicle events, timeline rows and remember saves. `remember` without a `visibility` now saves private when its target page is private or `facts.default_visibility` is explicitly private; otherwise the default stays world. Google Calendar events marked private or confidential sync as `visibility: private` pages, and a connector re-render keeps a page\'s private label. Remote page reads honor the privacy aliases only after `gbrain config set visibility.honor_aliases true`.' },
{ since: '0.60.341.0', text: 'Doctor `derived_visibility` also reports pages that carry a privacy alias but no `visibility`, chronicle events of a private origin, and world facts held in or extracted from a private page (fact ids a remote caller can read today are listed). `gbrain repair visibility` previews all of them and, with `--apply` only, makes them private; nothing runs on upgrade.' },
diff --git a/templates/bootstrap/template-repo/README.md b/templates/bootstrap/template-repo/README.md
index c04b817f0e..d547d0df95 100644
--- a/templates/bootstrap/template-repo/README.md
+++ b/templates/bootstrap/template-repo/README.md
@@ -1,6 +1,6 @@
# gbrain agent workspace — template
-<!-- gbrain-template-stamp: 0.60.452.0 -->
+<!-- gbrain-template-stamp: 0.60.453.0 -->
This repository is the **"Use this template"** distribution artifact for a
[gbrain](https://github.com/garrytan/gbrain) personal-agent workspace — the same