counterparts 0.3.39 → 0.3.41

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/CHANGELOG.md +47 -0
  2. package/package.json +1 -1
  3. package/src/adapters/claude-code/doctor-open.ts +28 -0
  4. package/src/adapters/claude-code/doctor.ts +5 -1
  5. package/src/adapters/dashboard/registries.ts +3 -0
  6. package/src/adapters/dashboard/web/flow.ts +2 -0
  7. package/src/adapters/dashboard/web/lanes.ts +1 -0
  8. package/src/adapters/dashboard/web/narrate.ts +19 -0
  9. package/src/adapters/fired.ts +1 -1
  10. package/src/adapters/mcp/NOTES.md +59 -0
  11. package/src/adapters/mcp/server-words.ts +1 -1
  12. package/src/adapters/mcp/server.ts +43 -17
  13. package/src/adapters/mcp/tools.ts +23 -5
  14. package/src/adapters/remote/NOTES.md +2 -1
  15. package/src/adapters/update-check.ts +1 -1
  16. package/src/core/counterpart-events.ts +5 -1
  17. package/src/core/counterpart.ts +70 -11
  18. package/src/core/dream/reflect.ts +4 -2
  19. package/src/core/onboarding.ts +35 -7
  20. package/src/core/recall/CONTRACT.md +23 -2
  21. package/src/core/recall/NOTES.md +101 -0
  22. package/src/core/recall/activate.ts +188 -31
  23. package/src/core/recall/gate.ts +8 -2
  24. package/src/core/recall/index.ts +52 -11
  25. package/src/core/recall/prime.ts +7 -1
  26. package/src/core/recall/rated.ts +1 -1
  27. package/src/core/recall/render.ts +15 -2
  28. package/src/core/recall/session.ts +8 -4
  29. package/src/core/recall/tunables.ts +34 -4
  30. package/src/core/schemas/NOTES.md +8 -0
  31. package/src/core/schemas/tunables.ts +6 -1
  32. package/src/core/self/NOTES.md +77 -0
  33. package/src/core/self/briefing-room.ts +88 -12
  34. package/src/core/self/briefing.ts +114 -15
  35. package/src/core/self/identity.ts +40 -8
  36. package/src/core/self/index.ts +56 -23
  37. package/src/core/self/tunables.ts +12 -2
  38. package/src/core/self/work.ts +20 -0
  39. package/src/core/store/index.ts +4 -3
  40. package/src/core/store/reads-memories.ts +37 -7
package/CHANGELOG.md CHANGED
@@ -1,5 +1,52 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.41 — 2026-10-30
4
+
5
+ A memory that names another memory by its id now brings that one along: when a note about a rule comes to mind, the rule shows beside it as a `See also:` line (at most two a turn, and the first lines to go when room is tight). Recall no longer lifts a memory just for being near the session's recent talk, so there should be fewer loosely related footnotes. In the first meeting, a question step sent without an answer is no longer shown as failed, and the meeting's last step is now called `origin`. The night sorts up to 30 cards into people, projects, places and topics, up from 10. No store-format change (store v15, cache v7), and nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.40 needs no store restore: `counterparts disconnect`, 0.3.40's install, then `counterparts connect`.
6
+
7
+ - **A memory that names another by its id brings it along.** When a memory that comes to mind
8
+ mentions another memory's id (a note about a rule, say, that names the rule), that memory
9
+ shows beside it as one `See also:` line, if nothing else keeps it back. Used, it learns the
10
+ words that brought it, so next time it can come back on its own. At most two a turn, kept
11
+ short, and the first lines to go when room is tight.
12
+ - **Recall no longer lifts a memory just for being near the session's recent talk.** The "train of
13
+ thought" head start is off: memories it lifted were rated the least useful of any group. Memories
14
+ linked to what the session used, wrote or has open here, and those sharing its tags, still get
15
+ their head start.
16
+ - **In the first meeting, a question step sent without an answer no longer shows as "Failed".** It now comes back as
17
+ a plain note that nothing was stored, and that starting the meeting needs no call, instead of an error.
18
+ - **The first meeting's last question no longer looks like "the meeting has started".** Its step is now called
19
+ `origin` (the old name `started` still works with an answer), the script says that choosing "Now" needs no call, and
20
+ a bare call to it gets plain words saying the meeting begins with `meet` and no step.
21
+ - **The night sorts three times as many cards.** Each night's tagging step now asks which kind
22
+ (person, project, place or topic) up to 30 cards are, up from 10, so the cards waiting for a kind
23
+ stop piling up.
24
+ - **The wake's project line leaves a record.** Each session start in a project's folder now records
25
+ whether that line showed, and if not why (no belief strong enough yet, or no room), with its size
26
+ and which beliefs it showed. Ids and counts only, never the text.
27
+ - **On claude.ai and Claude Desktop, Memory status is no longer marked read-only.** A status call there that names its
28
+ conversation updates that conversation's record, so the read-only label wasn't true; in Claude Code it still is.
29
+ - **Hosted: a sign-in or account page left open across a server update still works.** The forms' key now comes from
30
+ the server's cookie keys, so an update no longer answers "This form expired"; only a deliberate key rotation does.
31
+
32
+ ## 0.3.40 — 2026-10-29
33
+
34
+ Open items nobody has touched for two weeks are now parked: they leave the wake's "Still open", which says how many are parked (`· 12 parked`), and nothing is deleted or closed. `recall "still open"` still lists every one (the parked last, marked), a question about one still finds it, and using one again brings it back. Items with a date still to come, a `settlesWhen`, or `status: "asked"` (a question or request still waiting) are never parked. The first wake after upgrading may count a lot of parked items at once on a store that has gathered many; that's the backlog of two-week-old threads, all still there. `counterparts doctor` has an Open items line. No store-format change (store v15, cache v7), and nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.39 needs no store restore: `counterparts disconnect`, 0.3.39's install, then `counterparts connect`.
35
+
36
+ - **Open items nobody has touched for two weeks are parked.** An open item untouched for 14
37
+ lived days (it was 21) leaves the wake's "Still open", and the list's count line ends with
38
+ how many are parked (`· 12 parked`). Parked isn't closed: `recall "still open"` lists parked
39
+ items last, marked, a question about the thing still finds one, and using one again (opening
40
+ it and working with it, quoting it, revising it) brings it back. Items with a date still
41
+ to come (or a week past it, or repeating), or that say what would settle them
42
+ (`settlesWhen`), are never parked; a one-off date that has gone by parks like the rest. `counterparts doctor` has an
43
+ Open items line counting open, carried and parked.
44
+ - **The wake says how many open items are parked, even when "Still open" is short or empty.**
45
+ When "Still open" lists everything it carries, it now ends with `(3 parked; recall "still
46
+ open" lists them)`; when nothing is carried at all it reads `Still open: nothing current · 3
47
+ parked (recall "still open" lists them)`. The one-line summary a tight wake folds its lanes
48
+ into keeps the parked count too. Nothing is added when nothing is parked.
49
+
3
50
  ## 0.3.39 — 2026-10-28
4
51
 
5
52
  Counterparts now tells you when an update is out: once a day it asks the npm registry for the newest version number (nothing about you or your memory goes with it), and when you're a few releases behind, or a release is worth taking, your Claude says so once, with the steps for how you installed. **To turn it off,** tell your Claude to stop reminding you about updates, or set `"updateCheck": false` in `~/.counterparts/claude-code.json`, or `COUNTERPARTS_UPDATE_CHECK=off`; it never runs under Claude Code's `CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`. A store now keeps its id after its first week (the session-start cleanup no longer deletes its handle salt). When `claude` isn't on PATH, the `claude mcp add …` line to paste sits on one line of its own. No store-format change (store v15, cache v7), and nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.38 needs no store restore: `counterparts disconnect`, 0.3.38's install, then `counterparts connect`.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "counterparts",
3
- "version": "0.3.39",
3
+ "version": "0.3.41",
4
4
  "license": "MIT",
5
5
  "description": "Memory that turns AI tools into counterparts - a local-first, human-memory-modeled memory layer for AI.",
6
6
  "repository": {
@@ -14,6 +14,7 @@ import {
14
14
  import type { EventRow } from "../../core/store/index.js";
15
15
  import { BUSY_TIMEOUT_MS, journalModeOf } from "../../core/store/db.js";
16
16
  import { JOURNAL_COPY_FAILED_EVENT, JOURNAL_COPY_WRITTEN_EVENT } from "../../core/self/journal-file.js";
17
+ import { SELF_TUNABLES, STILL_OPEN_HANDLE, openCarry } from "../../core/self/index.js";
17
18
  // The same vocabulary the hook's stand-down uses, so the terminal and the
18
19
  // console cannot end up with two answers to "why did it not open".
19
20
  import { describeFault, faultPath, faultId } from "./standdown.js";
@@ -386,3 +387,30 @@ export function chapterSummaryFindings(store: Store): Finding[] {
386
387
  ),
387
388
  ];
388
389
  }
390
+
391
+ /**
392
+ * OPEN ITEMS, CARRIED AND PARKED (P2, 2026-10-28; roadmap 10-28, lightly
393
+ * held): how many open threads the store holds, how many the wake's "Still
394
+ * open" carries, and how many are parked — untouched `OPEN_CARRY_DAYS` lived
395
+ * days with no date and no `settlesWhen` (`self/identity.ts#openCarry`, the
396
+ * one rule). Green and informational: parking is not a fault, and nothing is
397
+ * closed by it. Silent with no open thread. One read of the open rows.
398
+ */
399
+ export function openItemsFindings(store: Store): Finding[] {
400
+ const days = SELF_TUNABLES.OPEN_CARRY_DAYS;
401
+ const carry = openCarry(store, store.livedDay(), days, SELF_TUNABLES.OPEN_CARRY_GLIMPSE_TOUCH);
402
+ const carried = carry.carried.length;
403
+ const parked = carry.notCarried.size;
404
+ const open = carried + parked;
405
+ if (open === 0) return [];
406
+ return [
407
+ finding(
408
+ "open-items",
409
+ "green",
410
+ "Open items",
411
+ `${String(open)} open: ${String(carried)} carried in Still open, ${String(parked)} parked (untouched ${String(days)}+ lived days; not closed, and recall "${STILL_OPEN_HANDLE}" lists them)`,
412
+ "",
413
+ { open, carried, parked, days },
414
+ ),
415
+ ];
416
+ }
@@ -139,7 +139,7 @@ import type { UpdateSwitch } from "../update-check.js";
139
139
  import type { Finding } from "./doctor-finding.js";
140
140
  import { checkoutFindings } from "./doctor-checkout.js";
141
141
  import type { CheckoutReading } from "./doctor-checkout.js";
142
- import { openFindings, journalFindings, journalCopyFindings, chapterSummaryFindings } from "./doctor-open.js";
142
+ import { openFindings, journalFindings, journalCopyFindings, chapterSummaryFindings, openItemsFindings } from "./doctor-open.js";
143
143
  import { aheadWriter } from "./standdown.js";
144
144
  import type { OpenReading, MigrationReading } from "./doctor-open.js";
145
145
  import {
@@ -3498,6 +3498,10 @@ export function doctorFindings(input: DoctorInput): Finding[] {
3498
3498
  ["journal-copy", () => journalCopyFindings(store)],
3499
3499
  // 2026-10-15: written vs automatic chapter summaries this week. Silent without any.
3500
3500
  ["chapter-summaries", () => chapterSummaryFindings(store)],
3501
+ // P2 (2026-10-28): open items, carried and parked; silent with none. Not in
3502
+ // the session-start reading (review of #674): it is never red, which is all
3503
+ // that notice prints, and it reads every open row (`openCarry`).
3504
+ ...(input.budgetMs !== undefined ? [] : [["open-items", (): Finding[] => openItemsFindings(store)] as const]),
3501
3505
  // The process log (2026-09-30): one directory listing and today's file.
3502
3506
  // Not in the session-start reading: it is never red, and it reads a file.
3503
3507
  ...(input.budgetMs !== undefined ? [] : [["log", (): Finding[] => logFindings(input)] as const]),
@@ -91,6 +91,7 @@ import {
91
91
  SELF_PAGE_REVISED_EVENT,
92
92
  SELF_PAGE_WRITER_EVENT,
93
93
  WORK_OVERFLOW_EVENT,
94
+ PROJECT_LINE_EVENT,
94
95
  } from "../../core/self/index.js";
95
96
  // The per-directory handoff's four, from `handoff/` itself (2026-09-20, E1):
96
97
  // working context for a place is not a memory, so its rows are its own.
@@ -222,6 +223,7 @@ export type DurableEventName =
222
223
  | typeof ENVELOPE_GAVE_WAY_EVENT
223
224
  | typeof INJECTION_OVERBUDGET_EVENT
224
225
  | typeof WORK_OVERFLOW_EVENT
226
+ | typeof PROJECT_LINE_EVENT
225
227
  | typeof CHECKOUT_EVENT
226
228
  | typeof SNAPSHOT_TAKEN_EVENT
227
229
  | typeof SNAPSHOT_FAILED_EVENT
@@ -339,6 +341,7 @@ export const DURABLE_EVENTS = {
339
341
  "handoff.lasthere.noroom": "a session start had no room for the \"Last here\" line naming the chapter last written in that project, or the later session that wrote none (the bundle's bytes, the ceiling, and whether a handoff was carried in its place)",
340
342
  // Durable since 2026-10-02: "Work here" had more lines than the wake carried.
341
343
  "self.work.overflow": "a session start had more \"Work here\" lines for its project than it carried — more than the wake shows, so they rotate, or fewer fitted the room (how many, how many shown)",
344
+ "self.project.line": "a session start in a project's folder had the wake's project line to give: whether it showed, and if not why (no belief above the floor, no room), its bytes and the beliefs it showed",
342
345
  "recall.credit": "a boundary decided which memories the replies actually used, and credited them",
343
346
  // Ratings (2026-10-14; Mike's call). Since 2026-10-19 an experiment counts them as use.
344
347
  "recall.rated": "a session scored the memories it was shown, 0 to 3 (by lane, whether each was also drawn on, and how many of the footnotes since its last rating it scored) — and, an experiment since 2026-10-19, what the scores credited and linked",
@@ -389,6 +389,8 @@ export const EVENT_NODE = {
389
389
  // The wake's "Work here" lines, and what an envelope could not carry
390
390
  // (2026-10-02): all of it is the wake's delivery.
391
391
  "self.work.overflow": "wake",
392
+ // The wake's project line (the 10-29 read): the wake's delivery too.
393
+ "self.project.line": "wake",
392
394
  "adapter.envelope.overcap": "wake",
393
395
  "adapter.notice.dropped": "wake",
394
396
  "adapter.envelope.gave-way": "wake",
@@ -123,6 +123,7 @@ export const LANES = {
123
123
  "handoff.refused": "flow",
124
124
  "handoff.lasthere.noroom": "flow",
125
125
  "self.work.overflow": "flow",
126
+ "self.project.line": "flow",
126
127
  "adapter.envelope.overcap": "flow",
127
128
  "adapter.notice.dropped": "flow",
128
129
  "adapter.envelope.gave-way": "flow",
@@ -763,6 +763,22 @@ export const NARRATORS = {
763
763
  return calm(`This project has more work than one wake shows: ${num(shown, 0)} of ${num(found, 0)} "Work here" lines shown, and the rest take turns.`);
764
764
  },
765
765
 
766
+ "self.project.line": (t) => {
767
+ const lines = n(t, "lines") ?? 0;
768
+ const why = s(t, "reason") ?? "shown";
769
+ if (why === "shown") return calm(`This wake carried the project line: ${num(lines, 0)} ${lines === 1 ? "belief" : "beliefs"} about this folder's project.`);
770
+ const held = n(t, "held") ?? 0;
771
+ if (why === "below-floor") {
772
+ if (held === 0) return calm("This folder's project holds no beliefs yet, so the wake had no project line to give.");
773
+ return calm(`This folder's project holds ${num(held, 0)} ${held === 1 ? "belief" : "beliefs"}, none strong enough yet for the wake's project line.`);
774
+ }
775
+ // No room: at the reported ceiling, or inside the line's own byte budget
776
+ // (`WAKE_PROJECT_LINE_BYTES`); a wake with no reported ceiling records 0.
777
+ const budget = n(t, "budget") ?? 0;
778
+ if (why === "no-room") return calm(`There was no room in this wake for the project line, so it was left off${budget > 0 ? ` (the wake was ${num(n(t, "was") ?? 0, 0)} bytes, its ceiling ${num(budget, 0)})` : ""}.`);
779
+ return calm("The wake's project line had nowhere to go in this wake, so it was left off.");
780
+ },
781
+
766
782
  // ── what a delivery could not carry (durable since 2026-10-02) ─────────────
767
783
  "adapter.envelope.overcap": (t) =>
768
784
  amber(`A hook's output came to ${num(n(t, "chars") ?? 0, 0)} characters, past the host's cap of ${num(n(t, "limitChars") ?? 0, 0)}, so the host showed only a preview of it.`),
@@ -1249,6 +1265,9 @@ export const REF_KIND = {
1249
1265
  "adapter.injection.overbudget": "none",
1250
1266
  // A directory's work lines are counted; the row names no memory.
1251
1267
  "self.work.overflow": "none",
1268
+ // The project line's ref is the project card, not a memory; the belief ids
1269
+ // it showed are in its payload.
1270
+ "self.project.line": "none",
1252
1271
  // Both prospective rows point at the MEMORY whose window it is: the window
1253
1272
  // key is a derived address on that row, not an entity of its own.
1254
1273
  "prospective.fire": "memory",
@@ -954,7 +954,7 @@ export const MECHANISMS: readonly Mechanism[] = [
954
954
  // A "Last here" line dropped for room (durable since 2026-10-01) rides with
955
955
  // the delivery it was turned away from, as `no-room` rides with writing;
956
956
  // so does a "Work here" overflow (2026-10-02).
957
- covers: ["handoff.lasthere.noroom", "self.work.overflow"],
957
+ covers: ["handoff.lasthere.noroom", "self.work.overflow", "self.project.line"],
958
958
  since: "2026-09-20",
959
959
  },
960
960
  {
@@ -1921,3 +1921,62 @@ its own small PR, after a look at its live use.
1921
1921
  - **What it can't see.** A newer writer that migrated the store but hasn't published a wake yet leaves the old stamp
1922
1922
  (or none), so the words fall back to what they said before: reload when the record is newer. Unmeasured how often
1923
1923
  a migration lands without a wake following it in the same process.
1924
+
1925
+ ## 2026-10-29 — `meet`'s `started` step is `origin` now (H1)
1926
+
1927
+ - **The misread.** On Mike's first hosted meeting, claude.ai's Claude, right after he picked "Now (about 5 minutes)",
1928
+ called `meet {session, step: "started"}` with no answer: it read the step as "the meeting has started". It got
1929
+ `answer-required`, and he saw a red Failed card.
1930
+ - **Renamed, because nothing held the old name hard.** The only stored trace is the `onboarding.answers` meta row
1931
+ (`{ <step>: <memory id> }`), read by `ahaDue` alone, which already keeps a list of old step names for exactly this
1932
+ (0.3.18/0.3.19's `loved`, `outside`, ...). `started` joins it beside `origin`. The memories carry no step name; the
1933
+ dashboard, the sidebar and the plugin bundle never name a step. `MEET_STATES`' `not_started` is unrelated.
1934
+ - **The old name is still taken, never offered.** `MEET_STEP_ALIASES` serves `started` as `origin` (a meeting in flight
1935
+ across the deploy, an older script); the schema's enum lists only `origin`, since the enum is what invited the
1936
+ misread. An answer sent as `started` is recorded and answered as `origin`.
1937
+ One window, accepted: a client still holding the old tool list has no `origin` in its enum while the new script
1938
+ names it; a client that checks step names before sending can still send `started` with an answer (the alias).
1939
+ - **A bare `origin`/`started` gets its own refusal** (`begins-without-step`, `ORIGIN_WITHOUT_ANSWER`): the meeting
1940
+ begins with `meet` and no step, and Now records nothing. Every other bare question keeps `answer-required`. The
1941
+ script's opening says so too ("Now → no meet call: go on to the next step"): the root of the misread was that Now
1942
+ had no instruction while Later had a call.
1943
+ - It is still a refusal (`isError`), so a client that draws refusals red still will; the words are what changed.
1944
+ (Superseded the same day by H1b, below.)
1945
+
1946
+ ## 2026-10-29 — a bare answer step is not an error (H1b)
1947
+
1948
+ - **Why.** claude.ai draws every error result as a red "Failed" card, so H1's reworded refusal still showed one.
1949
+ - **What changed.** Every answer step (`ANSWER_STEPS`, and the `started` alias) sent with no answer, or a blank one,
1950
+ now returns an ordinary result: the text is `MEET_NO_ANSWER` ("Nothing stored: no answer came with this step. ..."),
1951
+ and `structuredContent` is `{ step, stored: 0, meet, where, style, next }`. `stored: 0` is the count shape the
1952
+ answered steps already use (`stored: 1`), and there is no `recorded`, so neither words nor fields read as a save.
1953
+ It replaces `answer-required` and `begins-without-step` for these cases only; `address` with no answer, an unknown
1954
+ step, a bad `style`, the night run and an observer still refuse as before.
1955
+ - **Not progress either.** The check sits before the offer mark, so a bare step on a meeting nobody has read leaves
1956
+ `not_started` as it was (before, a refusal there still marked it `offered`). It writes no memory, no
1957
+ `onboarding.answers` entry (so `ahaDue` has nothing new to pace), and no `mcp.meet.step` event; it emits
1958
+ `mcp.meet.unanswered`, which is not durable. The one row it may touch is `onboarding.active`, the hold that any
1959
+ `meet` call in a session sets: the meeting really is still going.
1960
+ - **What the hosted request log loses.** It records a refusal's `reason`; these calls are now `ok` with no reason,
1961
+ so a bare step no longer shows there as a refusal. Accepted: it isn't one.
1962
+
1963
+ ## 2026-10-29 — readOnlyHint on a chat's copy (H1)
1964
+
1965
+ - **The ask.** claude.ai asked Mike once per tool on first use. The brief: check `status`, `self_page` and `wake`
1966
+ against `annotate`'s contract (read-only = never changes the store, a file or a setting), and claim nothing about
1967
+ claude.ai that can't be tested.
1968
+ - **`self_page` stays false**: one tool reads and writes (`body`), and an annotation is per tool. **`wake` stays false**:
1969
+ it mints a session. **`recall` stays false**: its use credit is a real write.
1970
+ - **`status` was not honest on a chat host.** Checked through the claude.ai HTTP door with a snapshot of every table in
1971
+ both databases and every file under the store: a `status` naming no session changes nothing, but a `status` that
1972
+ names its session, which the chat copy's schema offers and the unbound result's `bindNote` asks for, rewrites that
1973
+ session's record (`afterDesktopCall` -> `touchDesktopSession`: liveness and the write-up pacer, which decides a later
1974
+ call's `writeUpAsk`). That is a file a later call reads, not telemetry. Desktop's tests pin that a named `status`
1975
+ refreshes and counts (`desktop-chat.test.ts`, review of #294), so the write is by design and the hint was wrong.
1976
+ - **So a chat's copy of a read-only tool is not read-only** (`tools.ts#chatAnnotations`, in `withDesktopSession` and
1977
+ `withClaudeAiSession`): claude.ai and Desktop now mark no tool read-only, and Claude Code's `status`, which takes
1978
+ no session and touches nothing (tested the same way), keeps `readOnlyHint: true`. The other road, a `status` that
1979
+ moves no record, would change Desktop's pacing on purpose and was left alone.
1980
+ - **Not tested, not claimed:** whether claude.ai skips a permission prompt for a read-only tool at all. Nothing here can
1981
+ observe claude.ai's prompts. If Mike was asked about Memory status too on that first use, the hint wasn't what
1982
+ decided it. The real fix for the prompts (an "Always allow" line on the setup page) is the site's.
@@ -21,7 +21,7 @@ export const SERVER_NAME = "counterparts";
21
21
  * host decides whether to trust what follows. Read from a constant rather than
22
22
  * from disk so the server opens no file to answer its first message.
23
23
  */
24
- export const SERVER_VERSION = "0.3.39";
24
+ export const SERVER_VERSION = "0.3.41";
25
25
 
26
26
  /**
27
27
  * THE ONE LINE EVERY TOOL ANSWERS WITH when the store on disk is a schema AHEAD
@@ -97,11 +97,14 @@ import { coreNewer, newerStoreRemedy } from "../update-words.js";
97
97
  import type { NewerStoreInput } from "../update-words.js";
98
98
  import {
99
99
  MEET_STEPS,
100
+ ANSWER_STEPS,
101
+ MEET_NO_ANSWER,
100
102
  STYLE_CHOICES,
101
103
  addressMemory,
102
104
  answerText,
103
105
  finishText,
104
106
  meetState,
107
+ meetStepOf,
105
108
  meetingHold,
106
109
  meetingInstructions,
107
110
  noteActive,
@@ -237,7 +240,7 @@ export function asksStillOpen(question: string): boolean {
237
240
  const folded = question.toLowerCase().replace(/[’']/g, "").replace(/[^a-z ]+/g, " ").replace(/\s+/g, " ").trim();
238
241
  return STILL_OPEN_QUESTIONS.has(folded);
239
242
  }
240
- import { openSettlesCounts, STILL_OPEN_HANDLE, WAKE_BUILD_KEY } from "../../core/self/index.js";
243
+ import { openCarry, openSettlesCounts, STILL_OPEN_HANDLE, WAKE_BUILD_KEY } from "../../core/self/index.js";
241
244
  import type { PageWriterMode } from "../../core/self/index.js";
242
245
  import { canonicalToolName, toolDefinitions, toolSpec } from "./tools.js";
243
246
  import { writeUpDoor } from "./write-up.js";
@@ -1556,7 +1559,7 @@ export class McpServer {
1556
1559
  * script and the state, and the offer is recorded (`offered`), so neither
1557
1560
  * the wake's line nor the mod offers it again today. With a step:
1558
1561
  *
1559
- * - an answer (name, work, loved, problem, peeves, outside) becomes ONE
1562
+ * - an answer (name, week, work, love, saturday, origin) becomes ONE
1560
1563
  * memory through `remember`'s own door — about the owner, said by the
1561
1564
  * owner, marked "(from onboarding)" — and its id is kept for the second
1562
1565
  * session's line; a skipped question is never sent, so nothing is stored;
@@ -1585,7 +1588,8 @@ export class McpServer {
1585
1588
  const named = typeof args["session"] === "string" ? args["session"].trim() : "";
1586
1589
  const session = (named.length > 0 && this.corroborate(named) ? named : null) ?? this.session ?? this.hostSession() ?? UNBOUND_SESSION;
1587
1590
  const on = this.today();
1588
- const step = args["step"];
1591
+ // An old step name is served as its new one (`started` is `origin`, H1).
1592
+ const step = meetStepOf(args["step"]);
1589
1593
  // EVERY CALL IS THE MEETING STILL GOING (2026-10-12, onboarding round 1, A):
1590
1594
  // while it is, this session's write-up ask and the day's dream wait.
1591
1595
  if (!this.observer && session !== UNBOUND_SESSION) {
@@ -1622,11 +1626,18 @@ export class McpServer {
1622
1626
  if (typeof step !== "string" || !(MEET_STEPS as readonly string[]).includes(step)) {
1623
1627
  return this.refuse("meet", "step-unknown", { detail: `step is one of ${MEET_STEPS.join(", ")} — or omit it for the script.` });
1624
1628
  }
1629
+ const answer = typeof args["answer"] === "string" ? args["answer"].trim() : "";
1630
+ // AN ANSWER STEP WITH NO ANSWER (H1b): not an error (claude.ai draws those
1631
+ // as a red Failed card), and not progress either: it comes before the
1632
+ // offer mark, so it moves no meeting state, and nothing is written.
1633
+ if (answer.length === 0 && (ANSWER_STEPS as readonly string[]).includes(step as string)) {
1634
+ this.emit("mcp.meet.unanswered", undefined, { step });
1635
+ return { content: [{ type: "text", text: MEET_NO_ANSWER }], structuredContent: { step, stored: 0, ...onboardingView(store), next: MEET_NO_ANSWER } };
1636
+ }
1625
1637
  // A step taken is an offer made: the mod and the wake stop offering.
1626
1638
  // An answer after a "later" is the meeting resumed: offered again, so it holds.
1627
1639
  const before = meetState(store);
1628
1640
  if (before === "not_started" || (before === "later" && step !== "later" && step !== "skipped" && step !== "done")) noteOffered(store, { on, session, state: true });
1629
- const answer = typeof args["answer"] === "string" ? args["answer"].trim() : "";
1630
1641
  const done = (extra: Record<string, unknown>): ToolResult => {
1631
1642
  this.emit("mcp.meet.step", undefined, { step, stored: typeof extra["stored"] === "number" ? extra["stored"] : null });
1632
1643
  return this.result({ recorded: step, ...onboardingView(store), ...extra }, false);
@@ -1684,10 +1695,7 @@ export class McpServer {
1684
1695
  return done({ stored: ids.length, ids });
1685
1696
  }
1686
1697
  default: {
1687
- // An answer: name, work, loved, problem, peeves, outside.
1688
- if (answer.length === 0) {
1689
- return this.refuse("meet", "answer-required", { detail: "Send the answer, in your words. A skipped question is never sent: nothing is stored for it." });
1690
- }
1698
+ // An answer: name, week, work, love, saturday, origin (a bare one was answered above).
1691
1699
  const text = step === "name" ? `They like to be called ${answer}.` : answer;
1692
1700
  const ids = await this.meetWrite([answerText(text)]);
1693
1701
  if (ids[0] !== undefined) recordAnswer(store, step as AnswerStep, ids[0]);
@@ -2566,7 +2574,8 @@ export class McpServer {
2566
2574
  * on the owner's 10-25 snapshot, those matched none of 156 open threads.
2567
2575
  * For THIS folder since 2026-10-26 (O2), as its wake reads the lane: its
2568
2576
  * own threads first, the personal ones after, another folder's work not
2569
- * listed and not counted.
2577
+ * listed and not counted. Then the parked ones (P2, 2026-10-28), listed
2578
+ * last and marked `parked: true`, with `parked` their count.
2570
2579
  *
2571
2580
  * Reads only, like `last exchange`: no recall row, no credit, no seen set,
2572
2581
  * no quotable record — a ring event alone. Being listed is not a touch
@@ -2611,21 +2620,32 @@ export class McpServer {
2611
2620
  );
2612
2621
  }
2613
2622
 
2623
+ /** How many open threads are parked, store-wide (P2, `self/identity.ts#openCarry`); 0 when the store cannot answer. */
2624
+ private parkedCount(): number {
2625
+ const t = this.counterpart.self.tunables;
2626
+ const store = this.counterpart.store;
2627
+ return openCarry(store, store.livedDay(), t.OPEN_CARRY_DAYS, t.OPEN_CARRY_GLIMPSE_TOUCH).notCarried.size;
2628
+ }
2629
+
2614
2630
  private stillOpenTool(page: number, routed: boolean): ToolResult {
2615
2631
  // For this folder, as its wake reads it (O2, 2026-10-26): its own first,
2616
2632
  // the personal ones after, another folder's work not listed or counted;
2617
2633
  // a joined folder the setting has off is not this one's (`folderOn`).
2618
2634
  const on = this.folderOn();
2619
- const { items, notCarried } = this.counterpart.stillOpen({ scope: this.scope, ...(on === undefined ? {} : { exportsFrom: on }) });
2635
+ const { items, parked } = this.counterpart.stillOpen({ scope: this.scope, ...(on === undefined ? {} : { exportsFrom: on }) });
2620
2636
  const pages = Math.max(1, Math.ceil(items.length / STILL_OPEN_PAGE));
2621
2637
  const at = Math.min(page, pages);
2622
2638
  const shown = items.slice((at - 1) * STILL_OPEN_PAGE, at * STILL_OPEN_PAGE);
2623
- this.emit("mcp.recall.stillopen", undefined, { total: items.length, page: at, shown: shown.length, notCarried, routed });
2639
+ this.emit("mcp.recall.stillopen", undefined, { total: items.length, page: at, shown: shown.length, parked, routed });
2624
2640
  const touched = (n: number): string => (n === 0 ? "this lived day" : n === 1 ? "1 lived day ago" : `${String(n)} lived days ago`);
2625
- const faded =
2626
- notCarried === 0
2641
+ // THE PARKED, LISTED AND MARKED (P2, 2026-10-28): after every carried
2642
+ // item, the open threads nobody touched in `OPEN_CARRY_DAYS` lived days —
2643
+ // in no lane of the wake, not closed. Said once here, `parked: true` on each.
2644
+ const carried = items.length - parked;
2645
+ const parkedNote =
2646
+ parked === 0
2627
2647
  ? ""
2628
- : ` Not listed: ${String(notCarried)} open ${notCarried === 1 ? "thread" : "threads"} untouched for ${String(this.counterpart.self.tunables.OPEN_CARRY_DAYS)}+ lived days, no longer carried — not closed; a question about the thing itself finds one, and a touch carries it again.`;
2648
+ : ` ${carried === 0 ? (parked === 1 ? "It is" : "All are") : parked === 1 ? "The last one is" : `The last ${String(parked)} are`} parked (parked: true): open, untouched for ${String(this.counterpart.self.tunables.OPEN_CARRY_DAYS)}+ lived days, so left out of the wake's Still open — not closed. A touch (opened by id and used, quoted, drawn on, revised) brings one back.`;
2629
2649
  return this.result(
2630
2650
  {
2631
2651
  path: "handle",
@@ -2635,7 +2655,7 @@ export class McpServer {
2635
2655
  total: items.length,
2636
2656
  page: at,
2637
2657
  pages,
2638
- ...(notCarried === 0 ? {} : { notCarried }),
2658
+ ...(parked === 0 ? {} : { parked }),
2639
2659
  items: shown.map((i) => ({
2640
2660
  id: i.id,
2641
2661
  title: i.title,
@@ -2643,11 +2663,12 @@ export class McpServer {
2643
2663
  ...(i.reconsidering === true ? { reconsidering: "a core memory being reconsidered: keep or retire it" } : {}),
2644
2664
  ...(i.date === undefined ? {} : { date: i.date }),
2645
2665
  ...(i.settlesWhen === undefined ? {} : { settlesWhen: i.settlesWhen }),
2666
+ ...(i.parked === true ? { parked: true } : {}),
2646
2667
  })),
2647
2668
  note:
2648
2669
  (items.length === 0
2649
2670
  ? "Nothing is still open."
2650
- : `What "Still open" carries, in the wake's order: what is live first, newest touched first.${at < pages ? ` More on page ${String(at + 1)} (page: ${String(at + 1)}).` : ""} Recall an id to read it whole. A lived day is a day the memory was in use.`) + faded,
2671
+ : `${carried === 0 ? `Nothing open is carried in the wake's "Still open" now.` : `What "Still open" carries, in the wake's order: what is live first, newest touched first.`}${at < pages ? ` More on page ${String(at + 1)} (page: ${String(at + 1)}).` : ""} Recall an id to read it whole. A lived day is a day the memory was in use.`) + parkedNote,
2651
2672
  },
2652
2673
  false,
2653
2674
  );
@@ -3576,7 +3597,12 @@ export class McpServer {
3576
3597
  // WHAT WOULD SETTLE THEM (2026-10-27, S1): every open item, carried or
3577
3598
  // not, and how many name a trigger — counted so a "let it go" offer
3578
3599
  // for the rest can be decided later. Nothing acts on it yet.
3579
- openItems: { ...openSettlesCounts(store), note: "Open items (unresolved), carried or not: how many name what would settle them (settlesWhen), how many have only a date (eventDate), and how many have neither." },
3600
+ // And how many are parked (P2, 2026-10-28, `openCarry`).
3601
+ openItems: {
3602
+ ...openSettlesCounts(store),
3603
+ parked: this.parkedCount(),
3604
+ note: `Open items (unresolved), carried or not: how many name what would settle them (settlesWhen), how many have only a date (eventDate), and how many have neither. parked: untouched for ${String(this.counterpart.self.tunables.OPEN_CARRY_DAYS)}+ lived days with no date still to come and no settlesWhen, so left out of the wake's Still open — not closed; recall "still open" lists them last.`,
3605
+ },
3580
3606
  stance: { observer: this.observer },
3581
3607
  };
3582
3608
  }
@@ -188,7 +188,9 @@ export interface ToolSpec {
188
188
  * them for safety — but they are kept true to the code:
189
189
  *
190
190
  * - `readOnlyHint` is true only for a tool that never changes the store, a file
191
- * or a setting. Diagnostic events (the ring, the adapter-event telemetry
191
+ * or a setting. A chat host's copy of a tool takes `session`, and a call that
192
+ * names it touches that session's record, so no chat copy is read-only
193
+ * (`chatAnnotations`). Diagnostic events (the ring, the adapter-event telemetry
192
194
  * rows every tool may leave) do not count as a change; anything a later
193
195
  * strengthening, fading or wake reads does — so `recall` is NOT read-only:
194
196
  * what it delivers is recorded for this session (`Counterpart#noteAsked`, a
@@ -956,8 +958,11 @@ const STATUS: ToolSpec = {
956
958
  ],
957
959
  privileges: [
958
960
  {
959
- claim: "It writes nothing and trains nothing.",
960
- mechanizedBy: "src/adapters/mcp/server.ts#census (Store reads only)",
961
+ // Not "writes nothing" (review of #679): on a chat host a call naming its
962
+ // session refreshes that session's record, which is why the chat copy is
963
+ // not read-only (`chatAnnotations`). The claim is every host's, so it says that.
964
+ claim: "It writes no memory and trains nothing; on a chat host, a call naming its session refreshes that session's record.",
965
+ mechanizedBy: "src/adapters/mcp/server.ts#census (Store reads only) + src/adapters/mcp/server.ts#afterDesktopCall -> src/adapters/sessions.ts#touchDesktopSession",
961
966
  },
962
967
  {
963
968
  claim:
@@ -2096,11 +2101,24 @@ const DESKTOP_SESSION_PROPERTY = {
2096
2101
  "This chat's session id from the wake tool — or, in a Claude Code session (Desktop's Code tab), the id your wake or Stop ask names. Pass it on every call, so the call is filed under your own session and not the most recent Desktop chat's.",
2097
2102
  };
2098
2103
 
2104
+ /**
2105
+ * A CHAT'S COPY OF A READ-ONLY TOOL IS NOT READ-ONLY (H1, 2026-10-29). A call
2106
+ * that names its chat session refreshes that session's record and moves its
2107
+ * write-up pacer (`mcp/server.ts#afterDesktopCall` -> `sessions.ts#touchDesktopSession`),
2108
+ * a file a later call reads (whether it carries the write-up ask). So the copy
2109
+ * that gains `session` loses `readOnlyHint` (and `idempotentHint`: each named
2110
+ * call counts). Only `status` is read-only to begin with; Claude Code's `status`,
2111
+ * which takes no session, keeps it.
2112
+ */
2113
+ function chatAnnotations(a: ToolAnnotations): ToolAnnotations {
2114
+ return a.readOnlyHint ? { ...a, readOnlyHint: false, idempotentHint: false } : a;
2115
+ }
2116
+
2099
2117
  function withDesktopSession(spec: ToolSpec): ToolSpec {
2100
2118
  const schema = spec.inputSchema as { properties?: Record<string, unknown> };
2101
2119
  const properties = schema.properties ?? {};
2102
2120
  if ("session" in properties) return spec;
2103
- return { ...spec, inputSchema: { ...spec.inputSchema, properties: { ...properties, session: DESKTOP_SESSION_PROPERTY } } };
2121
+ return { ...spec, annotations: chatAnnotations(spec.annotations), inputSchema: { ...spec.inputSchema, properties: { ...properties, session: DESKTOP_SESSION_PROPERTY } } };
2104
2122
  }
2105
2123
 
2106
2124
  /**
@@ -2221,7 +2239,7 @@ function withClaudeAiSession(spec: ToolSpec): ToolSpec {
2221
2239
  const schema = spec.inputSchema as { properties?: Record<string, unknown> };
2222
2240
  const properties = schema.properties ?? {};
2223
2241
  if ("session" in properties) return spec;
2224
- return { ...spec, inputSchema: { ...spec.inputSchema, properties: { ...properties, session: CLAUDE_AI_SESSION_PROPERTY } } };
2242
+ return { ...spec, annotations: chatAnnotations(spec.annotations), inputSchema: { ...spec.inputSchema, properties: { ...properties, session: CLAUDE_AI_SESSION_PROPERTY } } };
2225
2243
  }
2226
2244
 
2227
2245
  /**
@@ -33,7 +33,8 @@
33
33
  moved up whole), and no dream line — its nights are the person's routine. Its tool
34
34
  words describe and never command: the directory's review refuses "call this first",
35
35
  so wake-first lives in the person's instruction block. Its one MCP prompt is "Wake
36
- Counterparts" (the + menu). readOnly stays on Memory status alone: recall records what
36
+ Counterparts" (the + menu). readOnly stays on Memory status alone (since H1, 2026-10-29,
37
+ not even there: see mcp NOTES "readOnlyHint on a chat's copy"): recall records what
37
38
  it delivered (a gate record the credit pass reads) and wake mints a session, so the
38
39
  hint would be stretched; the honest route to a read-only recall is one that records
39
40
  nothing (an observer read), which is a design change, not an annotation.
@@ -63,7 +63,7 @@ import { PLUGIN_UPDATE_COMMUNITY, PLUGIN_UPDATE_STEP, PLUGIN_UPDATE_SYNCED, npmU
63
63
  * 30 days old from this alone, with nothing fetched. `test/update-check.test.ts`
64
64
  * holds it to CHANGELOG's heading for `SERVER_VERSION` once there is one.
65
65
  */
66
- export const RELEASE_DATE = "2026-10-28";
66
+ export const RELEASE_DATE = "2026-10-30";
67
67
 
68
68
  export const UPDATE_CHECK_ENV = "COUNTERPARTS_UPDATE_CHECK";
69
69
  export const NONESSENTIAL_TRAFFIC_ENV = "CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC";
@@ -961,7 +961,8 @@ function tierRows(
961
961
  id: string;
962
962
  sal: number | null;
963
963
  activation: number | null;
964
- via?: "link";
964
+ via?: "link" | "see-also";
965
+ seeAlso?: { readonly by: string };
965
966
  habituated?: true;
966
967
  competed?: { readonly with: string; readonly factor: number };
967
968
  primed?: { link: number; train: number; from: readonly string[]; lifted?: true; tag?: number; by?: "link" | "tag" | "train"; top?: string };
@@ -977,6 +978,9 @@ function tierRows(
977
978
  sal: v?.sal ?? null,
978
979
  activation: v?.activation ?? null,
979
980
  ...(v?.via === undefined ? {} : { via: v.via }),
981
+ // And a memory brought along because a shown one names its id
982
+ // (see-also, 2026-10-29): which one named it, so a rating joins to it.
983
+ ...(v?.seeAlso === undefined ? {} : { seeAlso: v.seeAlso }),
980
984
  ...(v?.habituated === true ? { habituated: true as const } : {}),
981
985
  // And the older of an unsettled pair shown although it competed (E3,
982
986
  // 2026-10-24): which newer, and the weight its activation counted at.