Skip to content

Garry's Opinionated OpenClaw/Hermes Agent Brain

TypeScript

v0.60.400.0 chore(release): restamp onto master v0.60.399.0

garrytan981bbc327bf1
diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json
index 6314df1dce..5b2c30886b 100644
--- a/.claude-plugin/plugin.json
+++ b/.claude-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain",
- "version": "0.60.399.0",
+ "version": "0.60.400.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 87b77f57d2..13961568be 100644
--- a/.codex-plugin/plugin.json
+++ b/.codex-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "gbrain",
- "version": "0.60.399.0",
+ "version": "0.60.400.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 c562108810..e5a2dcb652 100644
--- a/BOOTSTRAP_FOR_AGENTS.md
+++ b/BOOTSTRAP_FOR_AGENTS.md
@@ -1,4 +1,4 @@
-<!-- gbrain-runbook-stamp: 0.60.399.0 -->
+<!-- gbrain-runbook-stamp: 0.60.400.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 1e66e446a3..5af747edce 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -10,6 +10,42 @@ 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.400.0] - 2026-10-23
+
+**Facts that a bulk import dated with the day it ran can now take the date their claim states, and out-of-order timelines can be put back in date order (#7247).** A bulk import that stamps the day it ran onto every fact makes hundreds of facts look like they all happened that day, so timelines and "as of" questions put them on one date. Doctor now spots those days, and an explicit repair moves each such fact to the one date its claim states. A second explicit repair fixes timelines that imports or hand edits left out of date order, with a copied bullet or a second timeline section.
+
+### How to use it
+
+```bash
+gbrain doctor --only fact_bulk_dates # the loaded days per source
+gbrain repair fact-claim-dates --source <id> # preview
+gbrain repair fact-claim-dates --source <id> --apply --expect <hash> --yes
+gbrain repair timeline-order --source <id> [--slug <slug>]... # preview
+gbrain repair timeline-order --source <id> --apply --expect <hash> --yes
+```
+
+### What changed
+
+| Situation | Before | Now |
+|---|---|---|
+| One day holds 200 or more of a source's active facts, at least a quarter of them, across 20 or more entities | nothing reported it | doctor `fact_bulk_dates` warns with the day, its fact and entity counts and how many claims state one earlier date |
+| A fact on such a day whose claim states exactly one earlier date ("closed a seed round on 2025-03-14") | kept the load day | `gbrain repair fact-claim-dates` moves it to that date, in the page's facts table and the database |
+| A fact on such a day with no date, several dates or a later one | kept the load day | still keeps it, and the preview counts it |
+| A timeline with bullets out of date order, an exact copy of a bullet, or a second `## Timeline` section | stayed that way | `gbrain repair timeline-order` sorts the bullets in the direction the page uses, drops the later exact copy and joins the sections |
+
+### What to watch for after you upgrade
+
+- Nothing runs on upgrade. Both repairs run only when named, preview first, and apply exactly the previewed set (`--apply --expect <hash> --yes`). They refuse `preview_changed` when anything moved since the preview.
+- Pages are rewritten through revision-bound `put_page`. On a managed brain, `git revert` of the repair commit undoes it.
+- A page that `timeline-order` cannot safely rearrange is listed as `needs_human` and kept. Near-duplicate bullets are only counted.
+
+### Itemized changes
+
+- `src/commands/doctor/checks/fact-bulk-dates.ts` and `src/core/facts/bulk-days.ts`: the `fact_bulk_dates` check and the shared `findBulkFactDays` rule.
+- `src/core/repair/fact-claim-dates.ts`: the `fact-claim-dates` repair kind (`--day` names a loaded day the rule does not detect).
+- `src/core/timeline-order.ts` and `src/core/repair/timeline-order.ts`: the `timeline-order` repair kind (`--slug` limits it to named pages).
+- Tests: `test/repair-fact-claim-dates-7247.test.ts`, `test/repair-timeline-order.test.ts`, `test/timeline-order.test.ts`; Postgres arms through `test/e2e/` `registerPostgresTests` wrappers.
+
## [0.60.399.0] - 2026-10-23
**The dream summary, the `think --save` page and the drift report keep an edit made while they were being composed, and every overwrite is restorable; the timeline, mention and concept-provenance writers act only on the page revision they read (GBRA-161 PR 5).** These writers used to overwrite or delete against whatever the page held when they finished, so an edit made in between was lost and an overwritten page had no saved copy.
diff --git a/VERSION b/VERSION
index 43ea2c2c93..56adc2c098 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.60.399.0
+0.60.400.0
diff --git a/openclaw.plugin.json b/openclaw.plugin.json
index 8ff2cbdd46..2789d100e2 100644
--- a/openclaw.plugin.json
+++ b/openclaw.plugin.json
@@ -1,7 +1,7 @@
{
"id": "gbrain-context-engine",
"name": "gbrain",
- "version": "0.60.399.0",
+ "version": "0.60.400.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 b768631702..27c6cbd2da 100644
--- a/package.json
+++ b/package.json
@@ -245,7 +245,7 @@
"bun": ">=1.4.0"
},
"license": "MIT",
- "version": "0.60.399.0",
+ "version": "0.60.400.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 8405ca4596..dd81f4cb69 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.399.0",
+ "version": "0.60.400.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 442b321090..0637bfee01 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.399.0",
+ "version": "0.60.400.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 eed51ca7b1..17e6c47a90 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.399.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.400.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 f1e5dd94d9..2911367f9a 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.399.0",
+ "version": "0.60.400.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 706b2b3760..c41c5df92f 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.399.0",
+ "version": "0.60.400.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 d6e2aa09a2..9121f9d6dc 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.399.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.400.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 410593544e..0375da1658 100644
--- a/plugin/README.md
+++ b/plugin/README.md
@@ -1,4 +1,4 @@
-<!-- gbrain-plugin-tree-stamp: 0.60.399.0 -->
+<!-- gbrain-plugin-tree-stamp: 0.60.400.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 72d33e59d4..ed78e7ca70 100644
--- a/src/core/behavior-change-notice.ts
+++ b/src/core/behavior-change-notice.ts
@@ -1169,8 +1169,8 @@ export const BEHAVIOR_CHANGES: ReadonlyArray<{ since: string; text: ChangeText;
// #7270 (GBRA-60). `since` is restamped at the merge slot.
{ since: '0.60.398.0', text: '`gbrain facts relink` and `gbrain facts relink --conversation` no longer attach a fact the assistant or a named third party said (`attributed_to` assistant or other) to an entity page, core pages included: such a fact is left where it was saved, recall still finds it, and the run counts it as `not_user_attributed`. Before, the SessionEnd corpus sweep saved the assistant\'s own report about a page, and every relink pinned it onto that page. Doctor `unlinked_facts` no longer counts these facts. Rows linked before this release stay linked; `gbrain forget <fact-id>` removes one (#7270, reported by @andrew-agents-bot).' },
{ since: '0.60.399.0', text: 'The dream summary, the `think --save` synthesis page and the drift report now keep an edit made while they were being composed (GBRA-161 PR 5): each writer binds its write to the page revision it read before composing, and a page that changed since is left as it is (`generation_fenced`; the summary and drift report note it on stderr and the next run writes them, `think --save` exits non-zero). Each overwrite keeps the earlier page in page history first, and `gbrain repair generations --kind dream_summary|think_synthesis|drift_report --mode restore` (or `gbrain restore <slug>`) puts it back. Timeline orphan retraction, `gbrain extract links --by-mention --rebuild` and concept provenance edges now delete only while the page is still at the revision they read; a page edited in between keeps its rows. A republished concept now drops the provenance edges of atoms that left its group (#4589).' },
- { since: 'TBD', text: 'New doctor check `fact_bulk_dates` warns when one calendar day holds a bulk-loaded share of a source\'s facts as their `valid_from` (200 or more active facts, at least a quarter of the source, across 20 or more entities): those dates record when the facts were loaded, not when they happened. It names `gbrain repair fact-claim-dates --source <id>`, an explicit preview-then-apply repair that moves each such fact whose claim states exactly one earlier ISO date to that date, rewriting the page\'s facts fence row so the database follows the file; facts without a date keep the load day, and nothing changes on upgrade.' },
- { since: 'TBD', text: 'New explicit repair `gbrain repair timeline-order --source <id> [--slug <slug>]` puts existing timelines back in date order: `- **YYYY-MM-DD** | source — summary` bullets that bulk imports or hand edits appended out of order move, with their indented lines, into the direction the page already uses; a later exact copy of a bullet is dropped; and a second `## Timeline` section (or bullets below the timeline sentinel next to a `## Timeline` heading) joins the first when only bullets move. Prose, sub-headings and comments stay where they are, near duplicates are only counted, and a page with a line it cannot place is listed `needs_human`. The preview writes nothing and prints a hash; `--apply --expect <hash> --yes` rewrites exactly the previewed pages through revision-bound `put_page` and refuses `preview_changed` when one moved. No timeline row is added or removed. Nothing runs on upgrade.' },
+ { since: '0.60.400.0', text: 'New doctor check `fact_bulk_dates` warns when one calendar day holds a bulk-loaded share of a source\'s facts as their `valid_from` (200 or more active facts, at least a quarter of the source, across 20 or more entities): those dates record when the facts were loaded, not when they happened. It names `gbrain repair fact-claim-dates --source <id>`, an explicit preview-then-apply repair that moves each such fact whose claim states exactly one earlier ISO date to that date, rewriting the page\'s facts fence row so the database follows the file; facts without a date keep the load day, and nothing changes on upgrade.' },
+ { since: '0.60.400.0', text: 'New explicit repair `gbrain repair timeline-order --source <id> [--slug <slug>]` puts existing timelines back in date order: `- **YYYY-MM-DD** | source — summary` bullets that bulk imports or hand edits appended out of order move, with their indented lines, into the direction the page already uses; a later exact copy of a bullet is dropped; and a second `## Timeline` section (or bullets below the timeline sentinel next to a `## Timeline` heading) joins the first when only bullets move. Prose, sub-headings and comments stay where they are, near duplicates are only counted, and a page with a line it cannot place is listed `needs_human`. The preview writes nothing and prints a hash; `--apply --expect <hash> --yes` rewrites exactly the previewed pages through revision-bound `put_page` and refuses `preview_changed` when one moved. No timeline row is added or removed. Nothing runs on upgrade.' },
];
/** The newest disclosed change's release: the notice id moves only when a release adds rows. */
diff --git a/templates/bootstrap/template-repo/README.md b/templates/bootstrap/template-repo/README.md
index 1505d79625..84cd95802f 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.399.0 -->
+<!-- gbrain-template-stamp: 0.60.400.0 -->
This repository is the **"Use this template"** distribution artifact for a
[gbrain](https://github.com/garrytan/gbrain) personal-agent workspace — the same