counterparts 0.3.45 → 0.3.47
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.
- package/CHANGELOG.md +196 -0
- package/CONSTITUTION.md +6 -4
- package/README.md +17 -4
- package/docs/QUICKSTART.md +25 -7
- package/docs/manual.md +134 -0
- package/docs/module-map.md +2 -1
- package/package.json +9 -2
- package/src/adapters/claude-code/NOTES.md +2 -1
- package/src/adapters/claude-code/bin/runner.ts +23 -0
- package/src/adapters/claude-code/doctor.ts +110 -8
- package/src/adapters/claude-code/hooks.ts +18 -1
- package/src/adapters/claude-code/index.ts +2 -0
- package/src/adapters/claude-code/night-catch-up.ts +2 -0
- package/src/adapters/claude-code/night-run.ts +2 -0
- package/src/adapters/claude-code/transcript.ts +60 -6
- package/src/adapters/cli/CONTRACT.md +18 -3
- package/src/adapters/cli/commands-install.ts +30 -5
- package/src/adapters/cli/commands-note.ts +11 -0
- package/src/adapters/cli/commands-readings.ts +10 -2
- package/src/adapters/cli/commands-remove.ts +10 -1
- package/src/adapters/cli/commands-shared.ts +3 -0
- package/src/adapters/cli/commands.ts +3 -2
- package/src/adapters/cli/export.ts +2 -0
- package/src/adapters/cli/help.ts +15 -4
- package/src/adapters/cli/removal.ts +144 -54
- package/src/adapters/cli/uninstall.ts +194 -12
- package/src/adapters/dashboard/registries.ts +1 -1
- package/src/adapters/dashboard/resolve.ts +35 -4
- package/src/adapters/dashboard/web/pages/memories/index.js +4 -2
- package/src/adapters/dashboard/web/views/health.ts +7 -1
- package/src/adapters/dashboard/web/views/memories.ts +11 -2
- package/src/adapters/dashboard/web/views/overview.ts +14 -3
- package/src/adapters/dashboard/web/views/search.ts +7 -3
- package/src/adapters/dashboard/web/views/shared.ts +6 -0
- package/src/adapters/dashboard/web/views/subjects.ts +6 -2
- package/src/adapters/dashboard/web/views/today.ts +10 -2
- package/src/adapters/hosts.ts +26 -4
- package/src/adapters/lifecycle.ts +12 -4
- package/src/adapters/mcp/CONTRACT.md +5 -1
- package/src/adapters/mcp/INTERFACE-GAPS.md +10 -0
- package/src/adapters/mcp/NOTES.md +82 -0
- package/src/adapters/mcp/bin/serve.ts +3 -0
- package/src/adapters/mcp/chat-wake.ts +9 -3
- package/src/adapters/mcp/deliberate.ts +5 -0
- package/src/adapters/mcp/facts.ts +23 -6
- package/src/adapters/mcp/index.ts +10 -0
- package/src/adapters/mcp/manual.ts +145 -0
- package/src/adapters/mcp/meaning.ts +7 -2
- package/src/adapters/mcp/server-args.ts +22 -1
- package/src/adapters/mcp/server-options.ts +15 -0
- package/src/adapters/mcp/server-self-tools.ts +21 -6
- package/src/adapters/mcp/server-session-end.ts +2 -0
- package/src/adapters/mcp/server-words.ts +98 -13
- package/src/adapters/mcp/server.ts +375 -26
- package/src/adapters/mcp/tools.ts +150 -26
- package/src/adapters/mcp/write-up.ts +3 -1
- package/src/adapters/plugin-run.sh +32 -8
- package/src/adapters/remote/NOTES.md +11 -1
- package/src/adapters/remote/http.ts +6 -1
- package/src/adapters/sessions.ts +25 -1
- package/src/adapters/update-check.ts +1 -1
- package/src/core/counterpart-deposit.ts +76 -8
- package/src/core/counterpart-types.ts +26 -0
- package/src/core/counterpart-wake-news.ts +230 -0
- package/src/core/counterpart-wake-shape.ts +131 -29
- package/src/core/counterpart.ts +59 -11
- package/src/core/coverage/CONTRACT.md +7 -2
- package/src/core/coverage/NOTES.md +45 -0
- package/src/core/coverage/index.ts +71 -6
- package/src/core/coverage/tunables.ts +4 -1
- package/src/core/dream/CONTRACT.md +14 -1
- package/src/core/dream/INTERFACE-GAPS.md +7 -0
- package/src/core/dream/NOTES.md +56 -0
- package/src/core/dream/index.ts +22 -6
- package/src/core/dream/project-ask.ts +5 -5
- package/src/core/dream/reflect.ts +48 -11
- package/src/core/dream/slices.ts +87 -6
- package/src/core/encode/secrets.ts +67 -5
- package/src/core/handoff/CONTRACT.md +9 -0
- package/src/core/handoff/last-here.ts +34 -12
- package/src/core/mint.ts +8 -0
- package/src/core/onboarding.ts +48 -16
- package/src/core/prospective/CONTRACT.md +6 -1
- package/src/core/prospective/NOTES.md +25 -0
- package/src/core/prospective/index.ts +11 -3
- package/src/core/recall/CONTRACT.md +1 -1
- package/src/core/recall/INTERFACE-GAPS.md +1 -1
- package/src/core/recall/NOTES.md +110 -0
- package/src/core/recall/activate.ts +28 -5
- package/src/core/recall/gate.ts +63 -12
- package/src/core/recall/habituation.ts +15 -2
- package/src/core/recall/index.ts +18 -3
- package/src/core/recall/session.ts +9 -3
- package/src/core/recall/tunables.ts +8 -2
- package/src/core/remember/CONTRACT.md +14 -0
- package/src/core/remember/NOTES.md +54 -0
- package/src/core/remember/index.ts +5 -0
- package/src/core/remember/own-plumbing.ts +135 -0
- package/src/core/remember/spans.ts +12 -1
- package/src/core/removal-hold.ts +246 -0
- package/src/core/schemas/index.ts +2 -2
- package/src/core/self/CONTRACT.md +1 -1
- package/src/core/self/NOTES.md +54 -0
- package/src/core/self/briefing-delivery.ts +16 -4
- package/src/core/self/identity.ts +4 -0
- package/src/core/self/index.ts +4 -1
- package/src/core/self/journal-file.ts +2 -1
- package/src/core/self/tunables.ts +34 -2
- package/src/core/self/work.ts +29 -10
- package/src/core/self/writer.ts +9 -2
- package/src/core/sleep/CONTRACT.md +4 -2
- package/src/core/sleep/consolidate.ts +8 -0
- package/src/core/sleep/cycle.ts +20 -0
- package/src/core/sleep/types.ts +7 -0
- package/src/core/store/CONTRACT.md +21 -3
- package/src/core/store/NOTES.md +33 -1
- package/src/core/store/cache.ts +5 -0
- package/src/core/store/index.ts +303 -12
- package/src/core/store/owner-op-seam.ts +5 -3
- package/src/core/store/reads-memories.ts +59 -1
- package/src/core/store/shapes.ts +20 -1
- package/src/core/store/tag-reads.ts +3 -0
- package/src/core/told.ts +443 -0
- package/src/core/types.ts +5 -0
- package/tools/install-loop/run.sh +21 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,201 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.3.47 — 2026-11-04
|
|
4
|
+
|
|
5
|
+
**Folded reminders, honest folders, refused calls kept out of your wake, compacted sessions remembered, and delete one memory from chat (hosted).** With the wake's shape on, a reminder a session started today already showed you folds into one line in later wakes that day. A dream files work under the folder it came from, another folder's dated work is counted rather than listed as due today, and other folders go by their names, not their paths. A memory about a refused tool call or a declined permission prompt stays out of the wake and the footnotes, and a morning share no longer asks for a tool call to mark it told. What you say after a conversation compacts is written up at night. "Delete the memory about X" works in chat, on hosted and locally, with 24 hours to undo it. Also: a hosted download opens in a local install and answers straight away, the redactor keeps tokenizer code readable and catches more secret names, and uninstall names the right remover. Existing stores' starter notes about deleting change once, only where they are still exactly as they started. No store-format change (store v15, cache v7), no migration. Nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.46 needs no store restore: `counterparts disconnect`, 0.3.46's install, then `counterparts connect`.
|
|
6
|
+
|
|
7
|
+
- **A reminder you were already shown today folds in later wakes.** With the wake's shape on, the first wake of the day
|
|
8
|
+
lists a plain reminder due today whole; a later wake that day, in a session that started today, counts it instead
|
|
9
|
+
(`2 due today, shown earlier; recall "coming up"`). A compaction's wake folds nothing, and a reminder told only in
|
|
10
|
+
last night's session after midnight stays whole. Dated items that aren't plain reminders show whole as before.
|
|
11
|
+
- **The manual's section index says what is inside each section.** `recall` with the handle
|
|
12
|
+
`manual` now lists every section with a line that names its contents (the phrases, the
|
|
13
|
+
tools, the commands), so looking for how to pause or how reminders work no longer means
|
|
14
|
+
guessing from a generic opening sentence.
|
|
15
|
+
- **On claude.ai, the first chat of the day runs the night.** Before answering you, Claude
|
|
16
|
+
sorts the day before (day's end, a dream, a reflection, about half a minute), then
|
|
17
|
+
answers in the same reply and says "I sorted yesterday's memories just now. Tell me if
|
|
18
|
+
you'd rather I ask first next time." One chat at a time is told (a later one only if the first never
|
|
19
|
+
ran it), and none once a night has run, whether from another chat or your nightly routine. Say "ask first" to have it
|
|
20
|
+
ask before it starts, or "no dreams" to turn nights off. A nightly routine still works,
|
|
21
|
+
once Counterparts' tools are set to Always allow (the routine's form lists only those).
|
|
22
|
+
- **The night names its conversation on every step.** The dream's prompt now passes the
|
|
23
|
+
session on its propose and journal steps too, so with two chats open a night's changes
|
|
24
|
+
stay with the chat that runs it.
|
|
25
|
+
- **Tokenizer code is no longer redacted.** Code lines that assign one identifier to another
|
|
26
|
+
whose last word is token, key or id (`pad_token` set to `eos_token`; letters only, no digit,
|
|
27
|
+
lowercase name, `=`) are kept as written; env vars, YAML, passphrase-shaped
|
|
28
|
+
values, quoted values, digits and passwords still redact as before.
|
|
29
|
+
- **More credential names are redacted.** `passphrase`, `db_pass` and other `*_pass` names,
|
|
30
|
+
a whole-name `pin` with a numeric value, `private_key`, `signing_key`, `session_key`
|
|
31
|
+
and a bare capitalised `AUTH=` / `BEARER=` now keep their name and lose their value;
|
|
32
|
+
`pin_memory=True`, `session_key_fn` and key-file paths such as `private_key = "keys/a.pem"`
|
|
33
|
+
stay readable.
|
|
34
|
+
- **Prefixed PINs and suffixed AUTH are redacted too.** `user_pin`, `SIM_PIN`, `PIN_CODE`,
|
|
35
|
+
`pinCode`, `gpgPassphrase` and `BASIC_AUTH=` keep their name and lose their value.
|
|
36
|
+
- **Ask Claude to delete one memory, with a day to change your mind.** On hosted and on a local
|
|
37
|
+
install, "delete the memory about X" makes Claude find it, say which one it is, and delete it:
|
|
38
|
+
it's hidden at once from recall, the wake, footnotes and the night, and erased for good after
|
|
39
|
+
24 hours. "Undo that" brings it back whole before then; recall's handle `deleted` lists what's
|
|
40
|
+
waiting, and the wake counts it. On hosted the erase runs on the server's own timer and the
|
|
41
|
+
backups let go of it within about a day after (the hosting provider's own short-term disk
|
|
42
|
+
snapshots rotate on its schedule); on a local install it's erased at the first
|
|
43
|
+
session after the 24 hours. `counterparts remove <id> --confirm` still deletes at once, and
|
|
44
|
+
finishes a memory deleted in chat.
|
|
45
|
+
- **Recalling a removed memory by its id no longer fails with an internal error;** it reads as
|
|
46
|
+
not found.
|
|
47
|
+
- **The starter notes say so too.** Two of them changed with this: the one about seeing and
|
|
48
|
+
changing what Claude keeps now says one memory can be deleted in chat and undone within a day
|
|
49
|
+
(on hosted it used to say a memory couldn't be removed yet), and the tips list gains "Delete
|
|
50
|
+
that". On hosted, the note on how memory works gets the new night words too (the day's first
|
|
51
|
+
chat runs the night). An existing install gets the new words once, at its next session, but only
|
|
52
|
+
where those notes are still exactly as they started; one you corrected or let go stays as it is.
|
|
53
|
+
- **Uninstall names the right remover and cleans up after itself.** Its last line says
|
|
54
|
+
`npm uninstall -g counterparts` for an npm install and `bun remove -g counterparts` for a
|
|
55
|
+
bun one (both when it can't tell), where it used to say the bun line to everyone. When it
|
|
56
|
+
takes its hooks out of `~/.claude/settings.json`, it also removes the backups of that file
|
|
57
|
+
that connecting and disconnecting kept, and says so when the file is left as `{}`. When
|
|
58
|
+
there were no hooks of ours in the file, the backups stay and it says where.
|
|
59
|
+
- **The docs say what goes over the network.** README, the quickstart and setup now say the
|
|
60
|
+
one request Counterparts makes of its own: a daily check of registry.npmjs.org for the
|
|
61
|
+
newest version number, sending nothing about you, and how to stop it (`"updateCheck":
|
|
62
|
+
false` in the configuration, or asking Claude to stop the update reminders). The export example now
|
|
63
|
+
works as shown (`--out` with `--passphrase` or `--plaintext`), and the docs say no command
|
|
64
|
+
opens an encrypted export yet.
|
|
65
|
+
- **Work stays in its own folder, and folders go by their names.** A dream now files what it writes
|
|
66
|
+
under the folder its memories came from, so a summary of one repo's work no longer shows up as
|
|
67
|
+
another repo's news. Work drawn from several folders goes to the one most of it came from;
|
|
68
|
+
something personal drawn from several folders belongs to none, so it reaches them all. Another folder's dated work
|
|
69
|
+
is no longer listed as "Due today" in this folder's wake: it is counted under "in other folders"
|
|
70
|
+
(personal reminders still reach every folder). And the wake names other folders as `sim` or
|
|
71
|
+
`paper` instead of their full paths, falling back to the path only when two folders share a name.
|
|
72
|
+
- **A morning share no longer asks for a tool call to mark it told.** When last night's share
|
|
73
|
+
reaches a session, handing it over marks it told, so a new person isn't shown a permission
|
|
74
|
+
prompt for bookkeeping they have no context for. A session that still calls `reflect` with
|
|
75
|
+
`told` gets a plain yes.
|
|
76
|
+
- **A memory about Counterparts' own refused calls stays out of your wake.** When a session
|
|
77
|
+
writes down that a tool call was denied, that a permission prompt was declined, or what it
|
|
78
|
+
couldn't do (a slash command, a tool it doesn't have), the memory is kept without a date, an
|
|
79
|
+
open thread or a "me", "us" or owner mark, so it never leads Coming up, the wake's news or
|
|
80
|
+
a prompt's footnotes; asking for it still finds it. The person's own words about a prompt
|
|
81
|
+
are kept as usual.
|
|
82
|
+
- **What you say after a conversation compacts is written up, even when the session had
|
|
83
|
+
already saved its own notes.** A session that wrote its handoff or chapter, then compacted,
|
|
84
|
+
then carried on for a few quick lines used to have those lines treated as a short closing
|
|
85
|
+
tail and never written up. Now anything said after a compaction counts as not yet
|
|
86
|
+
recorded, so the next night writes it up, unless the session records itself again after
|
|
87
|
+
the compaction.
|
|
88
|
+
- **Hosted: `/readyz` says when backups stop reaching the bucket.** The hosted server now checks
|
|
89
|
+
every 10 minutes that its backups are actually landing in storage, not only that the backup
|
|
90
|
+
process runs. After 30 minutes with nothing landing, `/readyz` answers `503` with
|
|
91
|
+
`backups: "stale"`, and the log says so with a `backup.uploads.stale` line. A fresh start gets
|
|
92
|
+
those 30 minutes before it can read stale.
|
|
93
|
+
- **Hosted: invite codes now expire after 7 days.** A code that leaks later can't sign anyone up. Codes made before
|
|
94
|
+
this change keep working until they're used. Every page from app.counterparts.ai now tells your browser to use
|
|
95
|
+
https only, and the server no longer advertises two sign-in features it never used (DPoP and the library's own
|
|
96
|
+
sign-out page).
|
|
97
|
+
- **A hosted "Download my memory" file opens in a local install and answers questions straight
|
|
98
|
+
away.** The download carries only the memory file, not its search index, so a question used to
|
|
99
|
+
find nothing until `counterparts verify --rebuild` was run by hand. Now the first session that
|
|
100
|
+
opens a memory with an empty search index rebuilds it, whichever way it opens (Claude Code,
|
|
101
|
+
Claude Desktop, the console, the background worker). Search by meaning fills in as usual.
|
|
102
|
+
`counterparts doctor` shows a "Word index" line when the index is empty (amber) and for a week
|
|
103
|
+
after an open rebuilt it, and `counterparts ask`, which only looks, says why it found nothing.
|
|
104
|
+
- **Starter notes follow the memory to where it's opened.** A hosted memory opened by a local
|
|
105
|
+
install gets the local wording of its starter notes (terminal commands instead of the account
|
|
106
|
+
page), and a local memory opened on hosted gets hosted's. Only notes still exactly as they
|
|
107
|
+
started change; one you corrected stays as it is.
|
|
108
|
+
- **The manual has a section on taking your hosted memory home:** where the downloaded file goes,
|
|
109
|
+
that it replaces the local memory there, and to export the local one first.
|
|
110
|
+
- **Hosted's account page:** the download is now marked as not encrypted ("keep it somewhere
|
|
111
|
+
safe"), and the delete section says a single memory can be deleted by asking Claude, with 24
|
|
112
|
+
hours to undo it, instead of saying it can't.
|
|
113
|
+
|
|
114
|
+
## 0.3.46 — 2026-11-03
|
|
115
|
+
|
|
116
|
+
**New stores get starter memories and the new wake layout; existing stores barely change.** A store `counterparts install` (or `start-fresh`, or hosted signup) creates begins with eleven starter notes, "told, not lived", counted apart from your own memories, and its sessions start in the wake's shape, which now opens with what happened since the last night, steps an old handoff down to one line, drops empty sections and settles dated things that already happened. A store that already exists gets no starter notes and keeps its wake-shape setting; where the shape is on (`counterparts wake-shape on`), its wake gains those same changes, and on any store a reminder that a newer done memory says already happened is no longer told as due. Also: write-ups leave out permission prompts and refused tool calls, the first meeting asks easier questions, a manual ships with every install (`recall` the handle `manual`), a memory called noise twice stays quieter for 14 lived days rather than 7, and the plugin downloads its program once. No store-format change (store v15, cache v7), no migration. Nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.45 needs no store restore: `counterparts disconnect`, 0.3.45's install, then `counterparts connect`.
|
|
117
|
+
|
|
118
|
+
- **A memory two sessions called noise now stays quieter for two weeks, not one.** Rated 0 in two sessions within 14 lived
|
|
119
|
+
days (it was 7), it faces the same raised bar until those ratings age out or a later 2 or 3 clears it. A turn that
|
|
120
|
+
reaches it strongly still shows it. Right after installing, the longer window starts counting at the next rating.
|
|
121
|
+
`recall.HABITUATION_WINDOW_DAYS` back to 7 undoes it.
|
|
122
|
+
- **The plugin downloads its program once on Ubuntu 26.04.** On a computer with no Bun or Node,
|
|
123
|
+
the hook and the memory server starting together could both download the program (about
|
|
124
|
+
56 MB), because that Ubuntu's `mkdir` can tell two processes they each made the same
|
|
125
|
+
directory. The launcher now takes its lock with the shell itself. The same double download
|
|
126
|
+
could follow a download that died, on any system, and now doesn't. Nothing unchecked ever
|
|
127
|
+
ran: each download was checked and moved into place in one step. And on a Mac whose `sh`
|
|
128
|
+
is zsh, a first start now downloads the program at all: it used to say "getting ready"
|
|
129
|
+
and never start.
|
|
130
|
+
- **Hosted: Litestream's own log lines reach the server's log.** A backup that fails to sync (a refused upload, an
|
|
131
|
+
R2 permission error, a rejected encryption key) now says so in the log, and a redeploy's log shows Litestream's
|
|
132
|
+
final sync finishing. Before, those lines were dropped and only the process being up was visible.
|
|
133
|
+
- **Hosted: the restore drill is in the repository, and the KEK check is by fingerprint.** `hosted/drill/drill.sh`
|
|
134
|
+
restores production's deployed image from a drill bucket on R2 with a throwaway key, and writes its results outside
|
|
135
|
+
the repository. The offline copies of the key are now checked by a short fingerprint against Railway's, so the real
|
|
136
|
+
key no longer goes into a drill. The runbook says what to do when a restore refuses a mistyped key.
|
|
137
|
+
- **Recall's per-conversation bookkeeping no longer piles up.** The record of what each
|
|
138
|
+
conversation was already shown (so nothing repeats) is now cleared once a conversation
|
|
139
|
+
has gone unused for the retention window, 90 days of use by default, in the nightly run
|
|
140
|
+
beside the old-version cleanup. A conversation used inside the window keeps all of it.
|
|
141
|
+
- **A new store starts with eleven starter memories, "told, not lived".** `counterparts install` (and
|
|
142
|
+
`start-fresh`) and hosted signup plant a short set about how this memory works and how to use it well, in each
|
|
143
|
+
surface's own words, marked with the source `told` and the set's version in the store's meta. They start weak,
|
|
144
|
+
fade unless used, and can be corrected or removed like any memory. Recall fills its footnotes with every lived
|
|
145
|
+
memory first and never shows a starter one loud; the deliberate `recall` ranks one below a lived match of
|
|
146
|
+
comparable score. The night, the wake, the core, beliefs and cards never read them. An upgraded store never gets
|
|
147
|
+
them. No store-format change.
|
|
148
|
+
`status`, doctor and the dashboard count them apart ("0 memories · 11 starter notes"), and `uninstall` says how
|
|
149
|
+
many of the memories it counts are starter notes. `init` still makes a bare store; the harness `week` starts with
|
|
150
|
+
the set unless given `--no-told`.
|
|
151
|
+
- **Nightly write-ups leave out permission prompts and refused tool calls.** When you decline a
|
|
152
|
+
permission prompt, the host's "interrupted for tool use" line no longer reaches the write-up
|
|
153
|
+
of that conversation, and whoever writes a session up (the nightly catch-up, or the next
|
|
154
|
+
session pointed at it) is told that permission prompts, refused tool calls and the
|
|
155
|
+
memory system's own notices aren't things that happened between you, unless you talked
|
|
156
|
+
about them. A night had saved "declined permission to mark a note delivered" as a memory.
|
|
157
|
+
- **The first meeting asks four questions now, and easier ones.** After your week, it asks "What are you working
|
|
158
|
+
on right now?", then what you've been into lately that has nothing to do with work, then a good Saturday. "What do
|
|
159
|
+
you love most about what you do?" is gone, and so is "What got you started building things?". A meeting already
|
|
160
|
+
under way when you update finishes as it started: the answers it gives under the old questions are still kept.
|
|
161
|
+
- **Starter memories no longer push out a lived memory.** On a new store, a seed that shared a word with the question
|
|
162
|
+
set the deliberate `recall`'s "weak match" bar, and a lived memory found by meaning alone fell under it ("which
|
|
163
|
+
coffee maker do we own?" lost the note about the espresso machine). Facts mode now lists every lived match before
|
|
164
|
+
any starter one, and judges a lived match only against lived ones. The turn's footnotes read their floors from the
|
|
165
|
+
lived memories too, so eleven starter notes no longer double the bar a young store's memories must clear (a
|
|
166
|
+
starter memory still faces the stricter whole-store bar, so a loosely matched seed is not footnoted on a turn nothing lived answers). The
|
|
167
|
+
single-binary check now runs on every pull request that touches `src/`.
|
|
168
|
+
- **The counterpart has a manual.** `docs/manual.md` says how Counterparts works and how to
|
|
169
|
+
use it: the everyday phrases, folders, nights and dreams, seeing and changing what's kept,
|
|
170
|
+
export, backup and uninstall, checking health, and how hosted differs. It ships with every
|
|
171
|
+
install, so it matches the version you run and works offline. Your counterpart opens it
|
|
172
|
+
with `recall`'s handle `manual` (a list of sections), and `manual <section>` opens one.
|
|
173
|
+
- **The wake knows yesterday's news.** In the wake's shape (on for new installs, below), a session start opens, after
|
|
174
|
+
the page, with "Since the last night:": up to three of the strongest things about you, or about the two of you, saved since the last
|
|
175
|
+
night ran, from any folder that's on. Something said in another folder this morning (a launch, good news from the vet)
|
|
176
|
+
no longer waits a night to reach the next session. Nothing new, no section.
|
|
177
|
+
- **An old handoff stops leading the wake** (the wake's shape, as the next one). Half a day after a folder's last handoff, once another session has worked
|
|
178
|
+
there and left something, the handoff shows as one line with its age and how many sessions came since, after what they
|
|
179
|
+
did, instead of whole and first for days. A quick check-in that saved nothing, or a session still open beside yours,
|
|
180
|
+
leaves it whole.
|
|
181
|
+
- **No empty sections in the wake.** "Nothing open.", "Nothing dated." and "Open here now: no other session." are gone,
|
|
182
|
+
with their headings: a section with nothing in it isn't printed.
|
|
183
|
+
- **Something that already happened stops being "due today".** When a newer memory marked done says a dated thing
|
|
184
|
+
happened (the shop launched a day early), its reminder isn't told and it leaves Coming up. Only on or after its day,
|
|
185
|
+
and only by a memory from the day before it or later, so last week's vet visit never settles this week's.
|
|
186
|
+
- **A new install starts with the wake's shape on.** The top-down wake (where this folder stands, elsewhere, coming up,
|
|
187
|
+
still open, yesterday, last night, each said once) is now how a new store's sessions start. A store that already existed
|
|
188
|
+
keeps its setting (`counterparts wake-shape on|off|default`).
|
|
189
|
+
- **Help no longer says export is encrypted by default.** It never was: export refuses until you pass
|
|
190
|
+
`--passphrase` (encrypted) or `--plaintext` (said on purpose). `counterparts --help`, `counterparts export --help`,
|
|
191
|
+
the README and the quickstart now say so.
|
|
192
|
+
- **On claude.ai, the `scope` tool speaks of one memory, not folders.** Its description, its read and the refusal
|
|
193
|
+
while memory is off or paused say one account is one memory, to pause, turn off and turn back on; they no longer
|
|
194
|
+
show the server's file path or a `counterparts scope` command nobody on claude.ai can run. Claude Code's and
|
|
195
|
+
Claude Desktop's words are unchanged.
|
|
196
|
+
- **A new store's starter note on using memory well points to the manual** (`recall` the handle "manual"). Stores
|
|
197
|
+
that already exist keep their notes as they are.
|
|
198
|
+
|
|
3
199
|
## 0.3.45 — 2026-11-01
|
|
4
200
|
|
|
5
201
|
Nearly nothing you'd notice changes. **One thing happens at once: the first pass after upgrading deletes the raw copies of notes saved with no session or with `counterparts note` that are already past their age (3 days once the memory has landed, 14 whatever). Memories aren't touched, and raw text deleted this way doesn't come back, even if you go back to 0.3.44.** Learned cue words skip path fragments and acknowledgements. A memory that couldn't be saved can be sent again. A laptop's sleep no longer stops the night's work, and a headless session leaves the night to the next one a person starts. No store-format change (store v15, cache v7), no migration. Nothing to run after upgrading beyond the usual restart of the dashboard and every Claude Code session. Going back to 0.3.44 needs no store restore: `counterparts disconnect`, 0.3.44's install, then `counterparts connect`.
|
package/CONSTITUTION.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# The Counterparts Constitution
|
|
2
2
|
|
|
3
|
-
_Ratified by the owner 2026-08-25; last amended 2026-
|
|
3
|
+
_Ratified by the owner 2026-08-25; last amended 2026-11-02 (this file's git history is
|
|
4
4
|
the amendment log). This is the ONE page with standing authority — everything else,
|
|
5
5
|
including owner answers given during the build, is a working default, open to discussion
|
|
6
6
|
at any time and revisable without ceremony. Changing THIS page is deliberate and rare._
|
|
@@ -30,9 +30,11 @@ at any time and revisable without ceremony. Changing THIS page is deliberate and
|
|
|
30
30
|
|
|
31
31
|
**Properties — what must stay true**
|
|
32
32
|
|
|
33
|
-
6. **The owner owns the data.** Local
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
6. **The owner owns the data.** Local is always available, and the owner can always take
|
|
34
|
+
their memory home. Memories are written as prose and kept in open, portable formats (a
|
|
35
|
+
database file or readable files), and the owner can read their own memories wherever
|
|
36
|
+
they live. Data leaves the machine only by the owner's explicit choice, never
|
|
37
|
+
silently. _(Amended 2026-11-02.)_
|
|
36
38
|
7. **Memory changes like human memory.** Revision, fading, and forgetting are the
|
|
37
39
|
system working. Revisions keep their history; nothing bulk-wipes silently; backups
|
|
38
40
|
catch catastrophe. No ceremony beyond that.
|
package/README.md
CHANGED
|
@@ -8,6 +8,9 @@ its memories itself, and they fade and grow the way yours do. It runs today with
|
|
|
8
8
|
|
|
9
9
|
[counterparts.ai](https://counterparts.ai)
|
|
10
10
|
|
|
11
|
+
Found a bug? [Open an issue](https://github.com/mlapeter/counterparts/issues). For anything
|
|
12
|
+
else, write to mike@resonantventures.com.
|
|
13
|
+
|
|
11
14
|
## Install
|
|
12
15
|
|
|
13
16
|
You need [bun](https://bun.sh) 1.3 or newer, or [Node](https://nodejs.org) 22.15 or newer.
|
|
@@ -50,7 +53,8 @@ to be deleted. The full walkthrough is in [`docs/QUICKSTART.md`](docs/QUICKSTART
|
|
|
50
53
|
- **Things come to mind.** As you talk, related memories surface quietly, the way one
|
|
51
54
|
thing reminds you of another.
|
|
52
55
|
- **It's yours.** Everything lives on your machine in one SQLite file you can read,
|
|
53
|
-
export or delete. No API keys, no accounts, nothing
|
|
56
|
+
export or delete. No API keys, no accounts, and nothing about you is sent anywhere; its
|
|
57
|
+
one request of its own is a daily version check (see [Status](#status)). The text of your
|
|
54
58
|
conversations is kept only until it's written up: deleted 3 days after that, or at most
|
|
55
59
|
about two weeks after the conversation goes quiet, whichever comes first, once Counterparts
|
|
56
60
|
next runs, and never in a backup. You can delete the conversation text,
|
|
@@ -80,10 +84,14 @@ Once installed it runs on its own. A few commands are worth knowing:
|
|
|
80
84
|
counterparts dashboard # look at the memory in your browser
|
|
81
85
|
counterparts ask "..." # ask the memory a question
|
|
82
86
|
counterparts scope . --off # don't remember this directory
|
|
83
|
-
counterparts export
|
|
87
|
+
counterparts export --out <dir> --passphrase <secret> # an encrypted copy of everything
|
|
84
88
|
counterparts --help # the rest
|
|
85
89
|
```
|
|
86
90
|
|
|
91
|
+
Export needs `--passphrase` or `--plaintext`; it won't pick for you. No command opens an
|
|
92
|
+
encrypted export yet: the README written beside it gives the format (scrypt and
|
|
93
|
+
AES-256-GCM), so it can be opened by hand.
|
|
94
|
+
|
|
87
95
|
Memory is on for every directory by default. The first session in a new directory asks
|
|
88
96
|
whether you want it there.
|
|
89
97
|
|
|
@@ -120,8 +128,13 @@ Claude Desktop has no Linux build, so on Linux it is Claude Code only. Expect ro
|
|
|
120
128
|
edges, and please
|
|
121
129
|
[open an issue](https://github.com/mlapeter/counterparts/issues) when you hit one.
|
|
122
130
|
|
|
123
|
-
There are no API keys, and
|
|
124
|
-
itself.
|
|
131
|
+
There are no API keys, and your memory leaves your machine only through Claude Code
|
|
132
|
+
itself. Counterparts makes one request of its own: once a day, the background worker that
|
|
133
|
+
Claude Code's hooks start asks registry.npmjs.org for the newest version number, and sends
|
|
134
|
+
nothing about you or your memory. To stop it, set `"updateCheck": false` in
|
|
135
|
+
`~/.counterparts/claude-code.json`, or ask Claude to stop the update reminders.
|
|
136
|
+
`COUNTERPARTS_UPDATE_CHECK=off` or Claude Code's `CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC`
|
|
137
|
+
stops it too, set in the environment Claude Code runs in. Search by meaning runs on a small model on your machine, and a session that ends
|
|
125
138
|
before it's written up is written up by the next session in that project.
|
|
126
139
|
|
|
127
140
|
That small model finds close paraphrases ("my doctor" finds a note about a physician), but
|
package/docs/QUICKSTART.md
CHANGED
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
## Install
|
|
4
4
|
|
|
5
5
|
You need [bun](https://bun.sh) 1.3 or newer, or [Node](https://nodejs.org) 22.15 or newer,
|
|
6
|
-
on macOS or Linux.
|
|
6
|
+
on macOS or Linux; Windows not yet supported. Bun on macOS is the setup in daily use; Node
|
|
7
|
+
and Linux pass a smoke test and an install run but have no daily user yet. With Node, install with `npm install -g counterparts@latest` instead of the
|
|
7
8
|
`bun add` line below; the rest is the same.
|
|
8
9
|
|
|
9
10
|
```
|
|
@@ -31,8 +32,14 @@ thing and is safe to run again. It asks two things, and you can skip either of t
|
|
|
31
32
|
entry so the Counterparts Online connector never loads into Claude Code as a second memory.
|
|
32
33
|
Hooks and settings from other tools are left alone.
|
|
33
34
|
|
|
34
|
-
There are no API keys. Search by meaning is turned on for you and runs on your machine
|
|
35
|
-
|
|
35
|
+
There are no API keys. Search by meaning is turned on for you and runs on your machine,
|
|
36
|
+
and your memory leaves it only through Claude Code itself. Counterparts makes one request
|
|
37
|
+
of its own: once a day, the background worker that Claude Code's hooks start asks
|
|
38
|
+
registry.npmjs.org for the newest version number, and sends nothing about you or your
|
|
39
|
+
memory. To stop it, set `"updateCheck": false` in `~/.counterparts/claude-code.json`, or ask
|
|
40
|
+
Claude to stop the update reminders. `COUNTERPARTS_UPDATE_CHECK=off` or Claude Code's
|
|
41
|
+
`CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC` stops it too, set in the environment Claude Code
|
|
42
|
+
runs in.
|
|
36
43
|
|
|
37
44
|
Your memory lives in `~/.counterparts/`.
|
|
38
45
|
|
|
@@ -92,10 +99,14 @@ counterparts ask "..." # ask the memory a question
|
|
|
92
99
|
counterparts status # how much it holds
|
|
93
100
|
counterparts self-page # who it thinks it is, and who you are
|
|
94
101
|
counterparts remove # delete one memory for good
|
|
95
|
-
counterparts export
|
|
102
|
+
counterparts export --out <dir> --passphrase <secret> # an encrypted copy of everything
|
|
96
103
|
counterparts --help # everything else
|
|
97
104
|
```
|
|
98
105
|
|
|
106
|
+
Export needs `--passphrase` or `--plaintext` (a plain copy); it won't pick for you. No
|
|
107
|
+
command opens an encrypted export yet: the README written beside it gives the format
|
|
108
|
+
(scrypt and AES-256-GCM), so it can be opened by hand.
|
|
109
|
+
|
|
99
110
|
`counterparts help <command>` explains any command in full.
|
|
100
111
|
|
|
101
112
|
## Upgrade
|
|
@@ -106,6 +117,9 @@ Close your Claude Code sessions, then:
|
|
|
106
117
|
bun add -g counterparts@latest
|
|
107
118
|
```
|
|
108
119
|
|
|
120
|
+
With Node, the same step is `npm install -g counterparts@latest`. Keep the `@latest`: a
|
|
121
|
+
bare `npm install` can fetch an older version.
|
|
122
|
+
|
|
109
123
|
Your memory isn't changed by an upgrade. Open sessions keep running the old version until
|
|
110
124
|
they restart.
|
|
111
125
|
|
|
@@ -184,10 +198,11 @@ It renames your current memory aside rather than deleting it. `counterparts star
|
|
|
184
198
|
|
|
185
199
|
```
|
|
186
200
|
counterparts uninstall
|
|
187
|
-
bun remove -g counterparts
|
|
201
|
+
npm uninstall -g counterparts # or, if bun installed it: bun remove -g counterparts
|
|
188
202
|
```
|
|
189
203
|
|
|
190
|
-
`uninstall` disconnects Claude Code,
|
|
204
|
+
`uninstall` disconnects Claude Code, removes the backups of `~/.claude/settings.json` that
|
|
205
|
+
connecting and disconnecting kept, then asks whether to delete your memory too:
|
|
191
206
|
|
|
192
207
|
```
|
|
193
208
|
Also delete all memories and related data? This can't be undone. [y/N]
|
|
@@ -202,8 +217,11 @@ worker has the memory open: close them and run it again.
|
|
|
202
217
|
Options:
|
|
203
218
|
|
|
204
219
|
- `--keep-memories` keeps your memory without asking.
|
|
220
|
+
- `--yes` skips the "Go ahead?" question. A script or a pipe needs it, or uninstall
|
|
221
|
+
refuses before changing anything: `counterparts uninstall --keep-memories --yes`
|
|
222
|
+
(`--park --yes` works the same way).
|
|
205
223
|
- `--park` renames `~/.counterparts` aside. `counterparts install` offers to bring it back.
|
|
206
|
-
- `--delete-memories` deletes it, after asking you to type `DELETE MEMORIES`.
|
|
224
|
+
- `--delete-memories` deletes it, after asking you to type `DELETE MEMORIES`. It has no `--yes`, so a script can't run it.
|
|
207
225
|
|
|
208
226
|
Each shows your memory's size first. Part of that can be a database log that shrinks on its
|
|
209
227
|
own; nothing is lost when it does.
|
package/docs/manual.md
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
# The Counterparts manual
|
|
2
|
+
|
|
3
|
+
How this memory works and how to use it: the phrases, the switches, the commands, and what to do when something seems off. It is written for the counterpart first (that's you, if you opened it through `recall`), and a person can read it too.
|
|
4
|
+
|
|
5
|
+
Some things differ by where the memory lives. **[local]** means a memory on the person's own computer, used from Claude Code or Claude Desktop. **[hosted]** means Counterparts Online, used from claude.ai, or from Claude Code when there's no local install. Where neither mark appears, it holds for both. "Since 0.3.x" says when something arrived, where that matters. This file ships with the code, so it describes the version that's installed.
|
|
6
|
+
|
|
7
|
+
## What Counterparts is
|
|
8
|
+
|
|
9
|
+
A memory for an AI, in its own words, not a transcript: it writes with `remember`, lets the unused fade, and opens each session with a wake.
|
|
10
|
+
|
|
11
|
+
- It writes its own memories: in the moment with the `remember` tool, and at the end of a stretch of work with `session_end` and `chapter`.
|
|
12
|
+
- What isn't used fades, on purpose, so what matters stays easy to find. A faded memory can still turn up when it's searched for, until it is let go.
|
|
13
|
+
- Each session opens with a wake: who I am (the self page), where the work stands, what's coming up and still open, how yesterday went.
|
|
14
|
+
- In Claude Code, related memories come up as footnotes as the conversation goes. `recall` is the deliberate look, everywhere.
|
|
15
|
+
- It's theirs to see, export and delete. [local] It is one SQLite file on their computer, and Counterparts sends nothing about them anywhere (the details are on counterparts.ai/privacy). [hosted] It lives on Counterparts' server, one store per account; backups that leave the server are encrypted with a key for their account.
|
|
16
|
+
- A new memory may start with a few starter notes, titled "Told: …". They were given, not lived: they start weak, come after lived memories that match as well, are never part of the self, and can be corrected or let go like any memory.
|
|
17
|
+
|
|
18
|
+
## Everyday phrases
|
|
19
|
+
|
|
20
|
+
Offer a phrase when it fits: "Remember this", "That's wrong", "Remind me Thursday to …", "What's still open?". Don't list them all.
|
|
21
|
+
|
|
22
|
+
- "Where did we leave off?" brings back the last session here. A short facts question like that reads that session first.
|
|
23
|
+
- "Remember this" saves it now, with the `remember` tool.
|
|
24
|
+
- "How did X go?" or "what do you remember about Y?" asks the memory, not just this chat: `recall` with `mode: "facts"` for what happened, `mode: "meaning"` for how it went and what it adds up to.
|
|
25
|
+
- "Remind me Thursday to …" is saved with the date in `eventDate` and `remind: "plain"`, so it is said plainly on that day, or, if that day is missed, the next time you talk within the week after. Without `remind: "plain"`, a dated memory is quiet: in Claude Code it may come up as a footnote around the date.
|
|
26
|
+
- "That's wrong" corrects a memory: write the right version with `updates` naming the old one and `how: "corrected"`. The wrong one leaves recall and stays readable by its id.
|
|
27
|
+
- "What's still open?" lists the threads the wake carries: the handle `still open`.
|
|
28
|
+
- "What's coming up?" lists what's due: the handle `coming up`.
|
|
29
|
+
- "Not here", "just read" or "pause this" sets the scope (see Folders).
|
|
30
|
+
- "No dreams", "ask first", or "dream", sets or starts the night (see Nights and dreams).
|
|
31
|
+
- "Let's meet" starts the first meeting, if it hasn't happened: the `meet` tool.
|
|
32
|
+
|
|
33
|
+
## Folders
|
|
34
|
+
|
|
35
|
+
[local] Memory is set per folder with the `scope` tool: on, observer (reads only), off, or paused.
|
|
36
|
+
|
|
37
|
+
- The `scope` tool reads the setting for this folder with no `mode`, and sets it with `mode` `on`, `observer`, `off`, `pause` or `resume`. Set it when the person says so, not on a guess.
|
|
38
|
+
- Off: the hooks write nothing and read nothing here, and every tool but `scope` refuses. Paused is off until they say to resume; it has no timer. `resume` goes back to what it was before, or on.
|
|
39
|
+
- A setting covers the folder and everything under it; the nearest setting wins. Nothing set means on.
|
|
40
|
+
- From a terminal: `counterparts scope .` shows this folder's setting, and `counterparts scope . --off` (or `--pause`, `--resume`, `--on`) sets it. `counterparts scope --list` prints every setting.
|
|
41
|
+
- The `scope` tool's `updates` turns the update reminder off when they say stop reminding them about updates.
|
|
42
|
+
|
|
43
|
+
[hosted] One account is one memory, with no folders. The `scope` tool pauses it or turns it off, for every claude.ai chat, and back on. Paused lasts until they say to resume (`mode: "resume"`).
|
|
44
|
+
|
|
45
|
+
## Remembering well
|
|
46
|
+
|
|
47
|
+
Save with `remember` while it's fresh, put dates in `eventDate`, mark open things `unresolved`, fix wrong ones with `updates`.
|
|
48
|
+
|
|
49
|
+
- Save while it's fresh: when something matters, `remember` it then, one idea per call, in your own words. Keep the exact words when the words matter.
|
|
50
|
+
- A date to come back to goes in `eventDate`, not just the text, or it never comes back. Four shapes: a day "2026-10-15", a month "2026-10", a range "2026-10-20..2026-10-31", or a year. Add `recurring` for a date that repeats.
|
|
51
|
+
- Something open: `unresolved: true`, with `settlesWhen` naming what would settle it. It stays on the still-open list, and the night can close it once a memory shows it happened.
|
|
52
|
+
- When a memory turns out wrong: `updates` with its id and `how: "corrected"`. When it was true then and has changed: `how: "changed"` (the default), and the old one is shown as earlier. A real disagreement: `how: "open"`, and both stay.
|
|
53
|
+
- Before saying "I don't remember", ask `recall` once, and try other words before saying it's gone.
|
|
54
|
+
- [local] At the end of a session in Claude Code, the Stop ask asks for the write-up: memories through `session_end`, and the session's own account through `chapter`. Write it honestly, including what didn't go well.
|
|
55
|
+
- [hosted] Nothing tells this memory when a chat ends, so `remember` as things come up, and write a `chapter` when the chat is wrapping up.
|
|
56
|
+
|
|
57
|
+
## Nights and dreams
|
|
58
|
+
|
|
59
|
+
A night pass runs day's end, a dream and a reflection, set to `auto`, `ask` or `off`; `last dream` reads the newest.
|
|
60
|
+
|
|
61
|
+
- Day's end writes the day's summary and brings the self page's day-to-day sections up to date. The dream replays what was lived beside what it resembles: it can merge near-copies, link what belongs together, note a pattern, flag a contradiction. The reflection is awake: it can rewrite the page's Core from the memories it cites and leave a short morning share.
|
|
62
|
+
- A dream is kept in its own journal, marked as a dream, never as something that happened. Tell it as a dream.
|
|
63
|
+
- The setting is `auto`, `ask` or `off`: the `dream` tool's `setting` phase, when they say "no dreams" (off) or choose one.
|
|
64
|
+
- [local] On `auto` (a new install's default), the next day's first Claude Code session starts the night in the background, as a separate claude -p run, and says so in one line. On `ask`, that session asks first. `counterparts dream --setting off` (or `ask`, `auto`) sets it from a terminal.
|
|
65
|
+
- [local] `counterparts night` lists recent nights, and `counterparts night last` shows last night's dream and reflection (since 0.3.28). `counterparts dream --undo <id>` reverses one dream as a whole.
|
|
66
|
+
- [local] `counterparts catch-up` writes up, now, sessions that ended without a write-up. The night does it too.
|
|
67
|
+
- [hosted] On `auto` (a new account's default), the day's first claude.ai chat runs the night, then answers in the same reply and says so in one line; on `ask` it asks first. One chat at a time is told (a later one only if the first never ran it), and none once a night has run. It also runs when the person's nightly routine (a scheduled run they set up in Claude) calls the `dream` tool, or when they say "dream" in a chat. To use a scheduled routine, set Counterparts' tools to Always allow first: the routine's form lists only those.
|
|
68
|
+
- Either surface: the handle `last dream` (or `last night`) reads the newest dream whole, and the reflection after it.
|
|
69
|
+
|
|
70
|
+
## Seeing and changing what's kept
|
|
71
|
+
|
|
72
|
+
Look with `recall` or `self_page`, correct with `updates`; `remember`'s `remove` deletes one, with a day to undo.
|
|
73
|
+
|
|
74
|
+
- Ask the memory: `recall` with a question and a mode, or a memory's id or exact title as `handle` to read it whole. [local] From a terminal: `counterparts ask "…"`.
|
|
75
|
+
- The self page, the "Who I am" the wake opens with: the `self_page` tool reads it, and writes it whole when something about you will still be true next month. [local] `counterparts self-page` shows it, and `counterparts self-page --versions` lists earlier versions.
|
|
76
|
+
- [local] `counterparts dashboard` opens the dashboard in a browser: the memories, the self page and the memory's health.
|
|
77
|
+
- Correct a memory with `remember`, `updates` and `how: "corrected"` (see Remembering well).
|
|
78
|
+
- [local] `counterparts remove <id>` shows what would go; with `--confirm` it asks them to type the id back, then deletes that memory for good. It needs a terminal, and it is the person's to run. `--confirm` also finishes a memory deleted in chat, at once.
|
|
79
|
+
- [local] `counterparts delete conversation-text`, `counterparts delete backups` or `counterparts delete activity-log` deletes one kind of data and nothing else (since 0.3.21).
|
|
80
|
+
- [local] `counterparts settle` lists memories that disagree and how each pair was settled; `counterparts core` lists what became part of who I am, and `counterparts core --demote <id>` sends one back.
|
|
81
|
+
- Delete one memory: `remember` with `remove` and the memory's id, on a memory shown in this conversation, after saying which one. It's hidden at once and erased after 24 hours. `remove` with `undo: true` brings it back before then, and recall's handle `deleted` lists what's waiting.
|
|
82
|
+
|
|
83
|
+
## Export, backup, uninstall
|
|
84
|
+
|
|
85
|
+
The memory is theirs to take: export, uninstall, start-fresh, or "Download my memory" when hosted.
|
|
86
|
+
|
|
87
|
+
- [local] `counterparts export --out <dir> --passphrase <secret>` makes an encrypted copy they can take anywhere. Export refuses without `--passphrase`, or `--plaintext` said on purpose. `--markdown` writes a readable tree instead. No command opens an encrypted export yet; the README beside it gives the format.
|
|
88
|
+
- [local] `counterparts backup --out <dir>` saves a snapshot to a folder. A daily snapshot is also kept automatically.
|
|
89
|
+
- [local] `counterparts uninstall` disconnects Claude Code and keeps the memory unless they say otherwise; `--keep-memories` keeps it without asking.
|
|
90
|
+
- [local] `counterparts start-fresh` sets this memory aside and starts a blank one; `counterparts start-fresh --undo` brings it back. Nothing is deleted.
|
|
91
|
+
- [local] `counterparts rollback` puts the memory back as it was before an upgrade (since 0.3.17).
|
|
92
|
+
- A memory held for deletion is left out of the markdown export; a full copy still has it until it's erased.
|
|
93
|
+
- [hosted] The account page's "Download my memory" gives the whole memory as one SQLite file, readable by any SQLite tool. "Delete my account" locks it at once and erases the memory, its backups and its key after 24 hours, unless they sign in and keep it; "Delete everything now" erases at once.
|
|
94
|
+
|
|
95
|
+
## Checking that it works
|
|
96
|
+
|
|
97
|
+
If something seems off (no wake, no night), check before guessing: `status`, and locally `counterparts doctor` and `counterparts log`.
|
|
98
|
+
|
|
99
|
+
- The `status` tool gives the census: how much is held, of what kinds, how much has left. Ask it when the person asks "what's your status?".
|
|
100
|
+
- [local] `counterparts doctor` checks everything and says what to fix. Show its lines as they are. `counterparts status` counts memories and recent activity; `counterparts log` shows today's events in order; `counterparts mechanisms` shows which parts of memory have been working.
|
|
101
|
+
- [local] After an update, start a new Claude Code session so the new version's tools load. To update: `npm install -g counterparts@latest` (or `bun add -g counterparts@latest`), or for the plugin, /plugin → Marketplaces → counterparts → Update marketplace.
|
|
102
|
+
- [local] It runs on macOS and Linux; Windows not yet supported. Bun on macOS is the setup in daily use; Node (22.15+) and Linux pass a smoke test but have no daily user yet.
|
|
103
|
+
- [local] A plugin install has no counterparts command in the terminal: the person uses /counterparts:doctor, /counterparts:dashboard and /counterparts:uninstall instead.
|
|
104
|
+
- [local] `counterparts install --host claude-desktop` connects Claude Desktop's chat to the same memory. Desktop's chat has no hooks: the `wake` tool starts each chat, there are no footnotes, and the write-up is asked on a tool result once a chat has gone on a while.
|
|
105
|
+
- [hosted] The account page lists the connected AIs, with when each was last used, and disconnects one.
|
|
106
|
+
- A tool that refuses says why and what to do. Pass that on in plain words, don't retry blindly.
|
|
107
|
+
|
|
108
|
+
## Hosted
|
|
109
|
+
|
|
110
|
+
[hosted] Counterparts Online is this memory on a server, used from claude.ai with the `wake` tool.
|
|
111
|
+
|
|
112
|
+
- It's connected in claude.ai as a custom connector, from the setup page the person was given. In a new chat, the `wake` tool starts the conversation.
|
|
113
|
+
- Sign-in is by an emailed link. The account page has the connected AIs, the time zone (the memory's day turns over at their midnight), "Download my memory", and delete.
|
|
114
|
+
- There are no hooks: the `wake` tool starts each chat, and nothing asks for a write-up at the end. There are no terminal commands and no dashboard.
|
|
115
|
+
- One account is one memory, with no folders: the `scope` tool pauses it or turns it off.
|
|
116
|
+
- Nights run in the day's first chat, after the `wake` and before the answer (see Nights and dreams), or from the person's own routine.
|
|
117
|
+
- Limits in the beta: about 120 calls a minute and 1,500 an hour; a store of up to 1 GiB. Over a limit, the tool says so; nothing is lost.
|
|
118
|
+
- A hosted memory and a local one are separate. [local] `counterparts connect` keeps the hosted connector out of Claude Code, so one session never sees two memories.
|
|
119
|
+
|
|
120
|
+
## Taking your hosted memory home
|
|
121
|
+
|
|
122
|
+
A "Download my memory" file replaces a local memory: set the old store folder aside first.
|
|
123
|
+
|
|
124
|
+
- A hosted memory's "Download my memory" file becomes a local install's memory when it is the only file in a fresh store folder, named "counterparts.sqlite". It replaces, it doesn't merge: whatever memory the local install had is no longer the one in use.
|
|
125
|
+
- [local] How: quit Claude Code and Claude Desktop, so no session holds the store. Rename the store folder `counterparts doctor` names on its Memory line (usually .counterparts/store in the home folder) to something like "store-before-hosted": that renamed folder is the backup of the local memory, whole. Then make a new, empty folder with the old name, and put the downloaded file in it as "counterparts.sqlite". Don't drop the file into the old folder over its database: the old search index and write-ahead files beside it belong to the other memory. To also keep a portable copy of the local memory, `counterparts export --out <dir> --passphrase <secret>` before the swap.
|
|
126
|
+
- [local] The first Claude Code or Claude Desktop session after that rebuilds its word index as it opens it, so questions find things at once (`counterparts ask` only looks, so before then it says the index is empty, and `counterparts verify --rebuild` rebuilds it by hand); search by meaning fills in over the next sessions. Starter notes still in hosted's words switch to this install's; one that was edited stays as it is (since 0.3.47).
|
|
127
|
+
- The download is not encrypted. Once it is in place, delete the copy left in Downloads.
|
|
128
|
+
- The hosted account and its memory stay as they were until the person deletes the account; the two don't sync.
|
|
129
|
+
|
|
130
|
+
## What's new
|
|
131
|
+
|
|
132
|
+
What changed in each version is in CHANGELOG.md, in the package and on GitHub.
|
|
133
|
+
|
|
134
|
+
- [hosted] Updates arrive when Counterparts Online is deployed; there is nothing to install.
|
package/docs/module-map.md
CHANGED
|
@@ -31,6 +31,7 @@ code and the `NOTES.md` / `INTERFACE-GAPS.md` next to it.*
|
|
|
31
31
|
| *(`feelings-wheel.ts`)* | — (a vocabulary) | The feelings wheel as a typed list: seven cores (happy, warm, calm, curious, sad, uneasy, angry), the groups and their words, default valence and intensity on every entry, blends, aliases, and the rule that re-filed the first wheel's feelings (v11). Read by `store/` to validate the `feelings` table. **Added 2026-09-25; v2 2026-09-30.** |
|
|
32
32
|
| *(`leaving.ts`)* | — (a table) | What counts as having left: every `archived_reason` the code writes, filed `replaced` (a live row carries it — a revision, a merge, a rebuilt journal copy), `let-go` or `removed`. The `status` census and the dashboard's archive words both read it, so they agree. **Added 2026-09-30.** |
|
|
33
33
|
| *(`onboarding.ts`)* | — (getting to know someone) | The first meeting, for every install path: its state in `meta` (`not_started` only on a store `install` made; absent reads `done`), the script the `meet` tool returns, the fixed style bundles (preferences about the owner, each keeping honest pushback), the wake's offer line and marker, and the second session's one memory. A new install's dreaming `auto` is written here too. **Added 2026-10-11.** |
|
|
34
|
+
| *(`told.ts`)* | — (what a newborn is told) | The starter memories (S1): eleven ordinary memories a NEW store begins with (`install`, `start-fresh`, hosted signup; never an upgrade), source `told`, in each surface's words, the set's version in `meta`. Weak at birth, lived-first in recall (`recall/gate.ts`, `mcp/facts.ts`), and kept out of the night, the wake, the core, beliefs and cards. **Added 2026-11-03.** |
|
|
34
35
|
| *(observer)* | — (instrument stance) | **RESOLVED (owner, 2026-08-25): a MODE, not a module** — one predicate threaded through the core API, checked at the store seam. Spec moved to `docs/observer-mode.md`. |
|
|
35
36
|
|
|
36
37
|
**Third open question (check-in): the `remember`/`encode` boundary.** With the
|
|
@@ -42,7 +43,7 @@ input — does `encode` shrink to gates-and-tagging inside `remember`'s pipeline
|
|
|
42
43
|
| adapter | job |
|
|
43
44
|
|---|---|
|
|
44
45
|
| `claude-code/` | Hooks: Claude Code's five events driving the host lifecycle (`lifecycle.ts`, below) — its payload translation, JSON envelope and the room it measures, transcript reader and wake-arrival check, the Stop ask's words, the first-launch question, the update and doctor notices, the dream line, and the headless nightly run (`night-run.ts`, `claude -p`, **2026-09-29**), which reads its child's transcript for the host's cut (**2026-10-09**). The launch adapter. |
|
|
45
|
-
| `mcp/` | Deliberate tools, ten: remember, recall, status — plus the Stop ask's two return channels, `session_end` (memories, and the next-session write-up's door) and `chapter` (the episode's own journal, **added 2026-09-04**, because the ask named a door no adapter had built) — `scope` (this directory's setting, **2026-09-15**), `self_page` (the page the wake opens with, **2026-09-18**), `dream`, the dreamer's phases (**added 2026-09-26**), and `reflect`, the waking self's (**added 2026-09-27**), and `meet`, the first meeting (**2026-10-11**, `core/onboarding.ts`). A result's words about the host come from `hosts.ts`. For a Claude Desktop client (by its name at `initialize`, **2026-09-30**) an eleventh, `wake` — Desktop's session start, since it has no hooks — plus per-call binding to the most recent live Desktop session, the write-up ask on a tool result, and a "Start with Counterparts" prompt; a Claude Code client sees none of it. `recall` (**2026-10-03**) answers a question in the mode it names — facts (`facts.ts`, with `recall/time-ask.ts`) or meaning (`meaning.ts`) — and an address (`ids`, `handle`, `epi_…#N`) in `deliberate.ts`. |
|
|
46
|
+
| `mcp/` | Deliberate tools, ten: remember, recall, status — plus the Stop ask's two return channels, `session_end` (memories, and the next-session write-up's door) and `chapter` (the episode's own journal, **added 2026-09-04**, because the ask named a door no adapter had built) — `scope` (this directory's setting, **2026-09-15**), `self_page` (the page the wake opens with, **2026-09-18**), `dream`, the dreamer's phases (**added 2026-09-26**), and `reflect`, the waking self's (**added 2026-09-27**), and `meet`, the first meeting (**2026-10-11**, `core/onboarding.ts`). A result's words about the host come from `hosts.ts`. For a Claude Desktop client (by its name at `initialize`, **2026-09-30**) an eleventh, `wake` — Desktop's session start, since it has no hooks — plus per-call binding to the most recent live Desktop session, the write-up ask on a tool result, and a "Start with Counterparts" prompt; a Claude Code client sees none of it. `recall` (**2026-10-03**) answers a question in the mode it names — facts (`facts.ts`, with `recall/time-ask.ts`) or meaning (`meaning.ts`) — and an address (`ids`, `handle`, `epi_…#N`) in `deliberate.ts`. The handle `manual` (**2026-11-03**, H1, `manual.ts`) opens `docs/manual.md`, the installed version's manual: its section index, or one section. |
|
|
46
47
|
| `cli/` | `counterparts` command — the full list is `COMMANDS` in `cli/commands.ts`: status, install, connect / disconnect (the host's two files), `install --host claude-desktop` (Desktop's config entry, **2026-09-30**), uninstall, start-fresh, init, owner operations (note, ask, export, backup, remove, verify, repairs, rebrief), the readings (doctor, mechanisms, log, coverage, version, help), scope, self-page, dream, core, settle, and dashboard. |
|
|
47
48
|
| `dashboard/` | The owner's window (constitution line 16): brain-view, revision stories, band/protected lists. Observer-mode by construction; minimal version ships DURING the parallel run. **Added 2026-08-25 (owner elevation).** |
|
|
48
49
|
| `remote/` | The memory server as a web connector (**2026-10-26**, the claude.ai trial): `http.ts` serves the same `McpServer` as MCP over HTTP (plain JSON, no SSE), bound to 127.0.0.1 and answering only under a per-run 192-bit secret path, one message at a time; `call-log.ts` keeps one id-only line per call; `bin/serve-http.ts` refuses a store or configuration nobody named and the owner's live stores. Its host is claude.ai's (`claude-ai:`), set at launch. No sign-in yet (its CONTRACT). |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "counterparts",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.47",
|
|
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": {
|
|
@@ -16,8 +16,14 @@
|
|
|
16
16
|
"ai",
|
|
17
17
|
"claude",
|
|
18
18
|
"mcp",
|
|
19
|
-
"local-first"
|
|
19
|
+
"local-first",
|
|
20
|
+
"claude-code",
|
|
21
|
+
"mcp-server",
|
|
22
|
+
"model-context-protocol",
|
|
23
|
+
"long-term-memory",
|
|
24
|
+
"agent-memory"
|
|
20
25
|
],
|
|
26
|
+
"mcpName": "ai.counterparts/memory",
|
|
21
27
|
"type": "module",
|
|
22
28
|
"engines": {
|
|
23
29
|
"bun": ">=1.3.0",
|
|
@@ -55,6 +61,7 @@
|
|
|
55
61
|
"files": [
|
|
56
62
|
"src/",
|
|
57
63
|
"docs/QUICKSTART.md",
|
|
64
|
+
"docs/manual.md",
|
|
58
65
|
"docs/ELI5.md",
|
|
59
66
|
"docs/module-map.md",
|
|
60
67
|
"tools/install-loop/",
|
|
@@ -1126,7 +1126,8 @@ no content was copied. `parseTranscript` reads only entries with a `message.role
|
|
|
1126
1126
|
| the compaction summary | `isCompactSummary: true`, `isVisibleInTranscriptOnly` | `This session is being continued…` | `injected` (was `conversation`) |
|
|
1127
1127
|
| slash-command echo, `!`-command | no metadata | `<command-name>`, `<local-command-stdout>`, `<bash-input>`, `<bash-stdout>` | unchanged text rule; `<bash-stdout>`/`<bash-stderr>` now `injected` |
|
|
1128
1128
|
| an interrupt | `interruptedMessageId`, no origin | `[Request interrupted by user]` | `injected` |
|
|
1129
|
-
|
|
|
1129
|
+
| a declined permission prompt (measured 2026-11-03: after the rejected `tool_result`, its own entry) | no metadata | exactly `[Request interrupted by user for tool use]` | `plumbing` since 2026-11-03 (WP1; was `injected`, and reached the night's write-up) |
|
|
1130
|
+
| hook output (`UserPromptSubmit hook success`, `hook_additional_context`, `hook_system_message`) | `type: "attachment"`, **no role** | — | never a turn (unchanged); should a build write it as user text, bare or in a system reminder, `plumbing` since 2026-11-03 (was `injected`) |
|
|
1130
1131
|
| **a prompt typed while the model works** (review M3: 76 seen) | `type: "attachment"`, `attachment.type: "queued_command"`, `commandMode: "prompt"`, `origin.kind: "human"` | — | `conversation` since 2026-09-24 — see "Prompts typed mid-turn" below (was never a turn) |
|
|
1131
1132
|
| an API error written as the assistant | `isApiErrorMessage: true`, `model: "<synthetic>"` | `API Error: …` | `injected` (was `conversation`) |
|
|
1132
1133
|
|