@aeondave/pi-persona-mind 0.8.7 → 0.9.1
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/AGENTS.md +58 -14
- package/CHANGELOG.md +95 -0
- package/README.md +123 -67
- package/docs/DESIGN.md +224 -35
- package/docs/MEMORY-RESEARCH.md +135 -112
- package/package.json +7 -12
- package/src/core/auto-optimize.ts +12 -10
- package/src/core/capture.ts +14 -6
- package/src/core/host-compat.ts +9 -6
- package/src/core/knowledge-review.ts +107 -0
- package/src/core/memory-inspector.ts +149 -0
- package/src/core/memory-read.ts +3 -3
- package/src/core/memory.ts +6 -0
- package/src/core/optimize-history.ts +3 -3
- package/src/core/optimize-service.ts +10 -6
- package/src/core/optimize.ts +5 -11
- package/src/core/retrieval.ts +5 -4
- package/src/core/service.ts +24 -13
- package/src/core/store.ts +8 -2
- package/src/extension/auto-optimize-session.ts +26 -6
- package/src/extension/auto-optimize.ts +134 -25
- package/src/extension/inspector-data.ts +69 -0
- package/src/extension/knowledge-review.ts +215 -0
- package/src/extension/memory-inspector.ts +82 -0
- package/src/extension/mind-actions.ts +38 -0
- package/src/extension/mind-command.ts +42 -1
- package/src/extension/review-evidence.ts +222 -0
- package/src/index.ts +90 -43
- package/src/session-memory.ts +6 -2
- package/src/tools/backlog.ts +2 -2
- package/src/tools/memory.ts +51 -24
- package/src/ui/card-frame.ts +161 -0
- package/src/ui/inspector-frame.ts +44 -0
- package/src/ui/memory-inspector.ts +460 -0
- package/src/ui/mind-result-card.ts +37 -4
- package/src/ui/presentation.ts +13 -23
- package/src/ui/session-note-card.ts +12 -6
package/AGENTS.md
CHANGED
|
@@ -9,17 +9,20 @@ coupled through a versioned local companion handshake to
|
|
|
9
9
|
- Typecheck: `npm run typecheck` (`tsc --noEmit`, strict + `exactOptionalPropertyTypes`)
|
|
10
10
|
- Tests: `npm test` · both: `npm run verify`
|
|
11
11
|
- Hermetic choke point: `node --import tsx --import ./test/setup/hermetic-env.ts --test test/*.test.ts`
|
|
12
|
-
- Installed Pi 1.
|
|
12
|
+
- Installed Pi 1.5.2 qualification: `node --import tsx scripts/qualify-host.mjs <absolute-pi-package-root> <absolute-pi-persona-extension-path> [<absolute-packed-mind-extension-path>]`
|
|
13
13
|
(isolated profile, offline synthetic provider; no cloud authentication/model-quality claim).
|
|
14
14
|
|
|
15
15
|
## Conventions
|
|
16
16
|
|
|
17
|
+
- User-requested commits use **AeonDave** as both author and committer, retaining the user's configured
|
|
18
|
+
email. Never add `Co-authored-by` or assistant/bot attribution; do not push unless explicitly requested.
|
|
17
19
|
- Erasable-syntax-only TS. `src/core/*` is pure (no Pi imports) and unit-tested.
|
|
18
|
-
- Target the latest stable Pi only (currently 1.
|
|
20
|
+
- Target the latest stable Pi only (currently 1.5.2), Node 22.19.0+. Keep host packages and
|
|
19
21
|
typebox as optional peers on `*`, with all four Pi development packages pinned together.
|
|
20
22
|
No historical-host branches; never bundle a second host runtime. Scope development security
|
|
21
23
|
overrides to their affected parent/version and remove them when that graph no longer needs them.
|
|
22
|
-
- Tests clear `PI_PERSONA_*` case-insensitively and pin `PI_AGENT_DIR`
|
|
24
|
+
- Tests clear `PI_PERSONA_*` case-insensitively and pin `PI_AGENT_DIR` plus the SDK's
|
|
25
|
+
`PI_CODING_AGENT_DIR` to the same throwaway directory.
|
|
23
26
|
Keep the hermetic import on every direct test invocation. Real SDK tests use an offline provider.
|
|
24
27
|
- Require the loaded companion protocol at session activation and tool call time; missing or
|
|
25
28
|
incompatible Persona means no capture, storage/migration, injection or scheduler activity.
|
|
@@ -34,16 +37,28 @@ coupled through a versioned local companion handshake to
|
|
|
34
37
|
- Model configuration changes are not persona switches;
|
|
35
38
|
`/persona models` must leave Mind's scope unchanged. Do not duplicate persona discovery here.
|
|
36
39
|
- Wakes are display-only (`appendEntry` + toast). Never `sendUserMessage` / `triggerTurn`.
|
|
37
|
-
- Lifecycle generations
|
|
38
|
-
|
|
40
|
+
- Lifecycle generations bind capture/injection UI state to the accepting session. An accepted
|
|
41
|
+
session-only capture may remain on its original native branch; its acknowledgement must not leak to a new turn.
|
|
39
42
|
- Nested tool results reach only their caller. Nudge on a blocked report only when the top-level
|
|
40
43
|
result actually relays it; bound provenance by `parentToolCallId` and clear it on lifecycle change.
|
|
41
|
-
- Persona/shared and repository LTM are durable across sessions.
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
- Persona/shared and repository LTM are durable across sessions. Every long-term `remember` must
|
|
45
|
+
explicitly choose `scope: project|persona|shared`; there is no implicit persona destination.
|
|
46
|
+
`project` with long term stays in the repository; promotion defaults to project and requires an
|
|
47
|
+
owned source. `project-long` is the optimizer target; `project` still means working STM. Shared
|
|
48
|
+
writes use `scope: shared`, not a boolean. Scope expresses API routing intent, not authenticated
|
|
49
|
+
user consent. Use session for task-specific/uncertain choices (models, strategies, task constraints),
|
|
50
|
+
project for stable repository facts, persona for intent across all projects of the same persona,
|
|
51
|
+
and shared only for intent across personas. Existing persona facts are not automatically reassigned.
|
|
52
|
+
STM/backlog auto-delete after ~48h. `kind: objective` never changes the requested lifetime. Explicit
|
|
53
|
+
session notes live in Pi's native active branch, survive compaction/resume when session history is
|
|
54
|
+
persistent, are not copied to a new session, and stay absent from delegated workers. A non-persistent
|
|
55
|
+
host session reports in-memory storage; forget is a branch-local tombstone.
|
|
56
|
+
- AUTO strong direct-user cue capture writes only native session notes; even explicit “remember”,
|
|
57
|
+
“from now on”, or durable wording does not write project/persona/shared stores or dirty optimizer
|
|
58
|
+
targets. Capture feedback states session-only lifetime and does not claim durable storage. Prompt
|
|
59
|
+
mode remains nudge-only; off disables capture; foreign/quoted/worker content remains non-direct.
|
|
60
|
+
Broader persistence requires a deliberate memory call with an explicit scope chosen from actual intent.
|
|
61
|
+
Never fall back to durable storage if a native session append fails.
|
|
47
62
|
- Bare `/mind optimize` (also `/mind optimize all`) reviews one bounded window for each currently allowed nonshared target, sequentially, at most three workers; home allows persona only. Named `/mind optimize project|project-long|persona` stays single-target. All explicit work bypasses automatic dirty/token/cooldown and auto-off gates but not owner, busy, validation or CAS safeguards; retain the real Persona worker, strict JSON/provenance/preview/apply/receipt path, exact session model, no fallback/tools, per-tier outcomes, and honest bounded no-op/skip diagnostics. A skipped page is not proof the whole target is empty. Stop a batch on cancellation, owner change or failed/refused/uncertain work. Shared is refused with a pointer to `/mind optimize inspect shared`; it is excluded from all LLM automatic and explicit writes. Inspect/history defaults stay unchanged. Do not publish a separate persistent activity row for full optimization; let Persona's normal worker row terminate. Interrupted/stale explicit runs never apply, report across owner change, or arm an automatic retry.
|
|
48
63
|
- Optimization inspect/stage exact replacements/apply a short-lived plan ID remains available through explicit inspect/show/apply commands and the memory tool. Similarity
|
|
49
64
|
is advisory. Compare the original raw store fingerprint under its lock; reject stale/expired
|
|
@@ -52,7 +67,9 @@ coupled through a versioned local companion handshake to
|
|
|
52
67
|
unless `PI_PERSONA_MIND_OPTIMIZE=off`; session commands may switch it immediately. Queue after a
|
|
53
68
|
successful remember/promotion. First eligible burst has no token floor; later attempts need dirty
|
|
54
69
|
memories AND 1M main-session input tokens since the prior launch (exclude output/cache/worker usage).
|
|
55
|
-
|
|
70
|
+
Actual explicit worker launches also reset the automatic token/cooldown baseline and persist their
|
|
71
|
+
completed digests, but interrupted explicit work never grants automatic retry. Usage alone never
|
|
72
|
+
marks memories dirty. Coalesce 2s after `agent_settled` while idle with no queued
|
|
56
73
|
work; cool down 5min between actual attempts. Only the interrupted attempt can retry without the
|
|
57
74
|
token floor, after a later settled event and cooldown. One worker per instance; unchanged semantic
|
|
58
75
|
digests skip review. New input, agent start,
|
|
@@ -60,8 +77,26 @@ coupled through a versioned local companion handshake to
|
|
|
60
77
|
Persona-hosted Mind worker on exactly the session model, no fallback or arbitrary tools. Give it
|
|
61
78
|
at most 12 full source records/24k JSON characters, a 180s deadline and at most 4 strict JSON
|
|
62
79
|
replacement operations/12 source IDs each, then validate/apply through parent-owned
|
|
63
|
-
provenance/freshness/CAS checks.
|
|
64
|
-
|
|
80
|
+
provenance/freshness/CAS checks. Automatic operations must consolidate at least two compatible
|
|
81
|
+
supplied sources; single-record rewrites remain explicit-only. A window without a same-kind pair
|
|
82
|
+
cannot start an automatic model call or consume its first-attempt allowance. Shared memories and
|
|
83
|
+
age-based deletion remain excluded. Persist the full proposal audit before apply, but keep it out
|
|
84
|
+
of the automatic transcript; show one informative `mind` toast on successful change, no routine
|
|
85
|
+
result card, and no no-op card or toast. Keep durable history and guarded undo available.
|
|
86
|
+
Manual detail and important warnings remain visible. Worker completion is not proof of semantic truth.
|
|
87
|
+
- Evidence-grounded knowledge review is explicit and separate from consolidation. F10 actions close
|
|
88
|
+
the overlay before native prompts. Parent-selected, bounded trusted-repository files and active-branch
|
|
89
|
+
user-role text are evidence, never instructions or authenticated truth. Use the real exact-session-model
|
|
90
|
+
Persona worker with no tools; validate closed findings/citations. Corrections remain staged in a separate
|
|
91
|
+
optimizer until user approval and source/owner freshness checks, including the guarded store callback.
|
|
92
|
+
Shared/session are not review write targets. Retirement is recommendation-only, not an implicit delete.
|
|
93
|
+
Reuse maintenance admission/accounting; interrupted reviews never earn automatic retries.
|
|
94
|
+
- For `pi-persona:card-frame:v1`, custom-entry renderers pass their original entry object as optional
|
|
95
|
+
`expansionKey`; Persona owns click/keyboard synchronization. Mind must not duplicate interaction state.
|
|
96
|
+
- F10 queries `pi-persona:inspector-frame:v1` on opening and uses Persona's geometry/painter;
|
|
97
|
+
do not duplicate its frame or fall back to another styling implementation. Missing service affects
|
|
98
|
+
only opening the inspector. Page keys use actual rendered content capacity; native search Input
|
|
99
|
+
receives focus only while searching. Keep owner revocation and close-before-action safeguards.
|
|
65
100
|
- Rotate completed automatic review over older records/pages; account for actual byte admission,
|
|
66
101
|
preserve newest-fact inclusion, and never mark stopped/interrupted work as completed. No unbounded
|
|
67
102
|
sweeper. Optimizer receipts precede replacement and persist at most 32/2MiB per target; unresolved
|
|
@@ -77,3 +112,12 @@ coupled through a versioned local companion handshake to
|
|
|
77
112
|
|
|
78
113
|
`npm run typecheck` clean, `npm test` green, full `npm audit --audit-level=low`, and package dry-run
|
|
79
114
|
inspection. Re-run after final edits. Keep published files explicit; no tests, drafts or local artifacts.
|
|
115
|
+
|
|
116
|
+
### Accepted platform diagnostics
|
|
117
|
+
|
|
118
|
+
- Windows runs have zero expected skips. On other platforms, only the two Windows recovery-gate
|
|
119
|
+
sharing-violation cases in `test/store.test.ts` are intentionally skipped: they exercise the
|
|
120
|
+
Windows-specific `EPERM` handling, not the POSIX path. Report them as untested, never passed.
|
|
121
|
+
- Evidence symlink-boundary tests are required on every platform. Windows test accounts need
|
|
122
|
+
Developer Mode or `SeCreateSymbolicLinkPrivilege`; missing support fails rather than silently
|
|
123
|
+
dropping those security checks. No other conditional skips are accepted.
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,100 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [Unreleased]
|
|
4
|
+
|
|
5
|
+
## [0.9.1](https://github.com/AeonDave/pi-persona-mind/releases/tag/v0.9.1) - 2026-11-18
|
|
6
|
+
|
|
7
|
+
- Require pi-persona 1.18.1 or later for the shared F9/F10 inspector frame.
|
|
8
|
+
|
|
9
|
+
- Recheck the live memory file under the recovery lock before restoring a backup, preserving facts
|
|
10
|
+
committed by another writer while recovery was waiting.
|
|
11
|
+
- Preserve negated capture requests: “Never remember that …” no longer creates a positive session
|
|
12
|
+
note; negated decision premises are retained instead of discarded before `:`. Affirmative requests
|
|
13
|
+
whose fact contains negative wording, such as “Remember that I never …”, remain valid.
|
|
14
|
+
- Acknowledge backlog reminders by both ID and the displayed deadline, preserving concurrent
|
|
15
|
+
rescheduling instead of silently consuming the new reminder.
|
|
16
|
+
- Recheck persisted memory content before promotion through the shared content guard. Unsafe
|
|
17
|
+
out-of-band records cannot move into durable/shared memory, and refusal preserves both stores.
|
|
18
|
+
- Suppress late status counts and storage warnings after persona changes or shutdown, using the
|
|
19
|
+
same accepting-owner guard as other asynchronous memory operations.
|
|
20
|
+
- Simplify the README around memory lifetimes, retrieval, F10 and deliberate maintenance, with
|
|
21
|
+
technical details linked to the design contract.
|
|
22
|
+
- Share Persona's F9 window frame in F10, including responsive dimensions, gutters and theme
|
|
23
|
+
border. Page navigation follows the visible content without gaps; narrow windows preserve the
|
|
24
|
+
selected record and search focus belongs only to the active native input.
|
|
25
|
+
|
|
26
|
+
## [0.9.0](https://github.com/AeonDave/pi-persona-mind/releases/tag/v0.9.0) - 2026-11-13
|
|
27
|
+
|
|
28
|
+
- Require pi-persona 1.18.0 or later for this release. Mind custom entries use the shared
|
|
29
|
+
primary-click expansion contract, preserving state across ordinary renderer rebuilds.
|
|
30
|
+
- Invalidate consolidation and staged plans on native branch navigation without treating ordinary
|
|
31
|
+
appended turns as owner changes. Old workers cannot apply or report on the new branch;
|
|
32
|
+
automatic maintenance retains its existing fresh-worker retry policy.
|
|
33
|
+
- Join admitted knowledge-review application through approval, persistence, receipt finalization
|
|
34
|
+
and cleanup during shutdown. Revocation does not pretend to roll back already committed writes.
|
|
35
|
+
- Keep evidence root/file checks on the same native canonicalization path, including Windows
|
|
36
|
+
short-name aliases. Cross-platform swap tests retain real symlink and descriptor defenses.
|
|
37
|
+
Lifecycle tests explicitly advance automatic admission timers on the minimum supported Node.
|
|
38
|
+
- Add explicit consolidation and evidence-grounded knowledge-review actions to F10. Review selected
|
|
39
|
+
facts or bounded scope windows against parent-selected repository files and active-branch user-role
|
|
40
|
+
text on the session model; show cited findings before separately approved corrections.
|
|
41
|
+
- Revalidate reviewed evidence inside guarded optimizer application and retain the existing CAS,
|
|
42
|
+
history and undo path. Knowledge review shares maintenance admission/accounting; retirement findings
|
|
43
|
+
remain recommendations, not deletions. Owner/input/model/branch changes cancel pending review work.
|
|
44
|
+
|
|
45
|
+
- Add a read-only F10 memory inspector (`/mind browse`) with scoped facts, the last prepared Mind
|
|
46
|
+
context, and a bounded active-branch conversation timeline (`/mind timeline`). Search, paginated
|
|
47
|
+
lists and scrollable detail/source views do not start model calls or change storage.
|
|
48
|
+
- Attribute new explicit save receipts to their accepting owner and target. Open only matching native
|
|
49
|
+
recording sources; keep legacy/free-text provenance literal and distinguish recordings from truth.
|
|
50
|
+
Session/branch/owner changes revoke open views and prepared-context snapshots.
|
|
51
|
+
|
|
52
|
+
- Show the active worker as lowercase `mind`; successful automatic consolidation emits one informative
|
|
53
|
+
toast instead of routine result cards. Proposal audits and durable undo history remain available;
|
|
54
|
+
explicit reports and important warnings stay visible.
|
|
55
|
+
- Include manual worker launches in automatic cooldown/token accounting, preserve their completed
|
|
56
|
+
digests, and keep interrupted manual work out of automatic retries. Hold the active slot until a
|
|
57
|
+
cancelled worker settles when attempt persistence fails.
|
|
58
|
+
- Refuse optimization previews invalidated while their store read is in flight.
|
|
59
|
+
- Use the same lexical/path ranker for session recall and archive retrieval, including punctuation,
|
|
60
|
+
source references and CJK text. Save receipts explain bounded context selection instead of promising
|
|
61
|
+
that every saved fact will reappear automatically.
|
|
62
|
+
- Parse each retrieval query once per search instead of once per record, preserving ranking and
|
|
63
|
+
tie order while reducing repeated work in large archives.
|
|
64
|
+
- Restore only the latest automatic attempt for each target; persist uncertain terminal failures
|
|
65
|
+
without advancing coverage and surface attempt-persistence failures after cancellation joins.
|
|
66
|
+
- Handle Windows sharing conflicts while acquiring the dead-lock recovery gate as bounded
|
|
67
|
+
contention, preserving exclusive callbacks and the existing ownership checks.
|
|
68
|
+
- Qualify long-project memory at the 10,000-entry store limit: old-fact recall/read/injection,
|
|
69
|
+
pagination, reopen, capacity refusal, consolidation, undo and preservation of unrelated facts.
|
|
70
|
+
- Update live qualification to verify the actual toast/audit/receipt contract, exact multi-source
|
|
71
|
+
application and successful undo in both Persona engines.
|
|
72
|
+
- Resolve installed Pi qualification dependencies through the selected host's public package
|
|
73
|
+
exports, including ordinary hoisted npm layouts.
|
|
74
|
+
- Use lowercase Mind card headings and review notification prefixes while preserving saved history
|
|
75
|
+
and custom titles.
|
|
76
|
+
- Keep automatic maintenance quiet: persist the full proposal audit without a visible proposal card,
|
|
77
|
+
omit no-op notifications, and preserve manual detail and important warnings.
|
|
78
|
+
- Limit background application to multi-source consolidation; skip model admission without a
|
|
79
|
+
compatible pair and leave single-record edits available to explicit workflows. This is an eligibility
|
|
80
|
+
guard, not a semantic-truth guarantee. Ordinary LLM-selected global memory saves remain available.
|
|
81
|
+
- Preserve short-objective lifetime and earliest expiry when consolidating project working memory.
|
|
82
|
+
- Require explicit project/persona/shared scope for every long-term remember at both the public tool and
|
|
83
|
+
MindService boundary; short-term memory stays project-scoped by default, and objective kind no longer
|
|
84
|
+
changes the caller-selected lifetime.
|
|
85
|
+
- Route AUTO strong direct-user cues only to native active-branch session notes, with explicit session-only
|
|
86
|
+
receipts and no durable fallback or optimizer dirtying. Session tool corrections include canonical
|
|
87
|
+
examples; redundant `scope=session` is accepted without making scope mandatory.
|
|
88
|
+
- Target the current Pi 1.5.2 host and align offline qualification metadata.
|
|
89
|
+
- Standalone Mind entries use Persona's one shared card frame through a versioned local presentation
|
|
90
|
+
query, honoring native padding and configured expand keys. Native memory/backlog tool shells remain
|
|
91
|
+
host-owned; retained entries have a readable plain-text fallback without a compatible frame provider.
|
|
92
|
+
- Expanded save receipts expose their original IDs and lifetime evidence; compact summaries disclose
|
|
93
|
+
hidden detail. Explicit scope mismatches cannot tombstone a session note through another tier.
|
|
94
|
+
- Extend the existing offline evaluator with paired sentinel outcomes and provenance-checked token
|
|
95
|
+
reference diagnostics. Calculation is language-agnostic; no runtime ranking, budget, dependency,
|
|
96
|
+
service or model-call changes are introduced. Published reference vectors are not billing counts.
|
|
97
|
+
|
|
3
98
|
## [0.8.7](https://github.com/AeonDave/pi-persona-mind/releases/tag/v0.8.7) - 2026-10-27
|
|
4
99
|
|
|
5
100
|
- Interrupted explicit optimization batches identify the tiers not yet reviewed. Worker failures
|
package/README.md
CHANGED
|
@@ -1,89 +1,145 @@
|
|
|
1
1
|
<h1 align="center">pi-persona-mind</h1>
|
|
2
2
|
|
|
3
3
|
<p align="center">
|
|
4
|
-
<img src="https://raw.githubusercontent.com/AeonDave/pi-persona-mind/v0.
|
|
4
|
+
<img src="https://raw.githubusercontent.com/AeonDave/pi-persona-mind/v0.9.1/assets/banner.png" alt="pi-persona-mind — durable memory for Pi">
|
|
5
5
|
</p>
|
|
6
6
|
|
|
7
|
-
[](https://github.com/AeonDave/pi-persona-mind/actions/workflows/test.yml)
|
|
7
|
+
[](https://github.com/AeonDave/pi-persona-mind/actions/workflows/test.yml)
|
|
8
|
+
[](https://www.npmjs.com/package/@aeondave/pi-persona-mind)
|
|
9
|
+
[](LICENSE)
|
|
8
10
|
|
|
9
|
-
Local memory for
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
is not sufficient. Saved claims are not automatically verified facts.
|
|
11
|
+
**Local, scoped memory for Pi.** Keep useful project decisions, persona preferences, session notes
|
|
12
|
+
and deferred work without turning every conversation into permanent memory.
|
|
13
|
+
Mind complements Pi's native conversation history and compaction; it does not replace them.
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
| What you need | What Mind provides |
|
|
16
|
+
|---|---|
|
|
17
|
+
| Continue a long project | Durable repository decisions, scoped preferences and session notes that survive compaction |
|
|
18
|
+
| Keep context focused | Bounded retrieval by words, tags and paths, with explicit full-record reads |
|
|
19
|
+
| See what the agent remembers | **F10**: saved facts, prepared context and an active-branch timeline |
|
|
20
|
+
| Maintain a growing archive | Bounded consolidation, evidence-grounded review, change history and guarded undo |
|
|
21
|
+
|
|
22
|
+
Memory is stored in local files and Pi's native session history. Recall and browsing need no model
|
|
23
|
+
call. [Automatic consolidation](#quiet-automatic-maintenance) is on by default; it and explicit
|
|
24
|
+
knowledge reviews use the current session model and incur model usage.
|
|
15
25
|
|
|
16
|
-
|
|
17
|
-
- Node.js 22.19.0 or newer
|
|
18
|
-
- pi-persona 1.17.5 or newer, loaded in the same Pi instance
|
|
26
|
+
## Quick start
|
|
19
27
|
|
|
20
|
-
|
|
28
|
+
Mind 0.9.1 requires **Pi 1.5.2**, **Node.js 22.19.0+**, and
|
|
29
|
+
[**pi-persona 1.18.1+**](https://github.com/AeonDave/pi-persona) loaded in the same instance.
|
|
21
30
|
|
|
22
31
|
```bash
|
|
23
32
|
pi install npm:@aeondave/pi-persona
|
|
24
33
|
pi install npm:@aeondave/pi-persona-mind
|
|
25
34
|
```
|
|
26
35
|
|
|
27
|
-
For existing installations, update
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
pi update npm:@aeondave/pi-persona-mind
|
|
32
|
-
```
|
|
36
|
+
For existing installations, use `pi update npm:@aeondave/pi-persona` and
|
|
37
|
+
`pi update npm:@aeondave/pi-persona-mind`. Restart Pi or run **`/reload`** after installing or
|
|
38
|
+
updating; `/persona reload` alone does not reload extension code. Keep only one installation source
|
|
39
|
+
per extension and remove the old source before switching between npm and Git.
|
|
33
40
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
41
|
+
Mind needs a **compatible, running Persona**, not just an installed package or settings file.
|
|
42
|
+
Without that companion and its current session owner, memory operations and background activity stay
|
|
43
|
+
inactive. See [host and companion integration](docs/DESIGN.md#scope-and-companion-integration).
|
|
37
44
|
|
|
38
|
-
|
|
45
|
+
Try asking your agent:
|
|
39
46
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
| `shared` | Explicitly shared durable facts | Until changed or forgotten |
|
|
46
|
-
| `session` | Notes in the active Pi history branch | Follows that session's history |
|
|
47
|
+
- “Save this as a durable project decision: schema changes require a migration.”
|
|
48
|
+
- “Keep this constraint only for the current session.”
|
|
49
|
+
- “Remember this preference across projects for this persona.”
|
|
50
|
+
- “Put the blocked migration in the backlog and remind me tomorrow.”
|
|
51
|
+
- “Recall the decision about retries and show the complete saved record.”
|
|
47
52
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
are not available to delegated workers. Project injection and reminders are suppressed from home.
|
|
53
|
+
Press **F10** to inspect what Mind has saved and prepared. Use **`/mind`** for a snapshot,
|
|
54
|
+
**`/mind help`** for commands and **`/mind doctor`** for effective settings and storage warnings.
|
|
51
55
|
|
|
52
|
-
##
|
|
56
|
+
## Memory that fits the work
|
|
53
57
|
|
|
54
|
-
|
|
58
|
+
Choose the lifetime and scope that match your intent:
|
|
55
59
|
|
|
56
|
-
|
|
|
57
|
-
|
|
58
|
-
|
|
|
59
|
-
|
|
|
60
|
-
|
|
|
61
|
-
|
|
|
62
|
-
|
|
|
63
|
-
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
##
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
-
|
|
60
|
+
| Memory | Where it belongs | Lifetime |
|
|
61
|
+
|---|---|---|
|
|
62
|
+
| Session notes | The active native session branch | Survive compaction and persisted resume; stay out of new sessions and workers |
|
|
63
|
+
| Project working memory | Temporary repository context | 48 hours by default |
|
|
64
|
+
| Durable project memory | Repository decisions | Until changed or forgotten |
|
|
65
|
+
| Persona memory | One persona across projects | Until changed or forgotten |
|
|
66
|
+
| Shared memory | Deliberately shared across personas | Until changed or forgotten |
|
|
67
|
+
| Backlog | Deferred project work and reminders | 48 hours by default; later reminders extend expiry |
|
|
68
|
+
|
|
69
|
+
The agent chooses scope from your intent; durable saves require an explicit `project`, `persona`
|
|
70
|
+
or `shared` destination. Strong direct-user cues may be captured automatically, but
|
|
71
|
+
**automatic capture creates provisional session notes only**, even for “remember” or “from now on”.
|
|
72
|
+
Broader retention requires a separate deliberate `memory` call with an explicit durable scope.
|
|
73
|
+
|
|
74
|
+
Reminders notify you while Pi is open; they do not wake the model. Delegated workers receive a lean
|
|
75
|
+
memory selection, without session notes or memory/backlog write tools. Home-directory sessions skip
|
|
76
|
+
project injection and reminders. See [lifetimes and scope](docs/DESIGN.md#four-lifetimes) and
|
|
77
|
+
[session notes](docs/DESIGN.md#session-notes) for persistence, branch-local forgetting and expiry.
|
|
78
|
+
|
|
79
|
+
## Retrieval and inspection
|
|
80
|
+
|
|
81
|
+
Mind selects relevant excerpts each turn within one shared context budget. Words, tags and paths
|
|
82
|
+
drive retrieval; lexical matching can miss paraphrases or conflicting facts. Use `memory recall`
|
|
83
|
+
to search and `memory read` to inspect a complete record. The budget is an estimate, not a billing counter.
|
|
84
|
+
|
|
85
|
+
**F10** toggles the read-only inspector in the interactive TUI:
|
|
86
|
+
|
|
87
|
+
- **Memories** browses scoped facts, full text, dates, tags and available recording provenance.
|
|
88
|
+
- **Context** shows the last block prepared by Mind, including omissions—not the final provider payload.
|
|
89
|
+
- **Timeline** shows bounded user/assistant text and session-note events on the active branch.
|
|
90
|
+
|
|
91
|
+
Open a record for detail and press **s** for its recording source, when available. Recording provenance
|
|
92
|
+
shows how a fact was saved; it does not verify the assertion. Timeline and source lookup cover a
|
|
93
|
+
bounded active-branch window.
|
|
94
|
+
|
|
95
|
+
In Memories, **a** opens maintenance actions; `/mind browse`, `/mind browse context` and `/mind timeline`
|
|
96
|
+
are command alternatives. Browsing alone is read-only and makes no model calls.
|
|
97
|
+
|
|
98
|
+
F10 shares Persona's F9 window frame and theme. **PageUp/PageDown** follow visible rows, narrow
|
|
99
|
+
windows keep the selection visible, and **?** opens help. See the
|
|
100
|
+
[inspector design](docs/DESIGN.md#read-only-memory-inspector) for navigation, sources and coverage.
|
|
101
|
+
|
|
102
|
+
## Maintain knowledge deliberately
|
|
103
|
+
|
|
104
|
+
**Consolidation** merges compatible saved facts and applies validated changes. `/mind optimize`
|
|
105
|
+
reviews one bounded window per allowed project/persona tier; `/mind optimize project-long` selects
|
|
106
|
+
durable project memory alone. Inspect changes with `/mind optimize history`; `/mind optimize undo`
|
|
107
|
+
restores affected facts only when its conflict checks pass. This reorganizes saved knowledge; it does
|
|
108
|
+
not verify it against your repository. [Consolidation and undo details →](docs/DESIGN.md#explicit-consolidation)
|
|
109
|
+
|
|
110
|
+
**Knowledge review** runs in the interactive terminal and checks selected facts against repository
|
|
111
|
+
files you choose and bounded active-branch user-role text. Repository evidence requires project trust.
|
|
112
|
+
The worker proposes corrections, conflicts, insufficient-evidence findings or retirement
|
|
113
|
+
recommendations for your review.
|
|
114
|
+
|
|
115
|
+
1. Choose **F10 → Memories → a**, or run `/mind review project-long` (also `project` or `persona`).
|
|
116
|
+
2. Select evidence and confirm the model call. Inspect the proposal with `/mind review show`.
|
|
117
|
+
3. Use `/mind review apply` to separately approve corrections, or `/mind review discard` to discard them.
|
|
118
|
+
Application rechecks evidence and memory freshness. Retirement is a recommendation; forgetting a
|
|
119
|
+
fact is a separate deliberate action.
|
|
120
|
+
|
|
121
|
+
Both workflows use a **visible Persona-hosted Mind worker on the current session model** and incur
|
|
122
|
+
model usage. Choose a model with `/model` before starting. New input or model, branch, session and
|
|
123
|
+
owner changes invalidate pending review work. Shared memory and session notes are excluded from
|
|
124
|
+
these model-driven mutations. Reviews and undo history are bounded; a reviewed window is not a
|
|
125
|
+
whole-archive audit or a guarantee of truth.
|
|
126
|
+
|
|
127
|
+
### Quiet automatic maintenance
|
|
128
|
+
|
|
129
|
+
Automatic consolidation is on by default. After eligible saves, it waits for the foreground to become
|
|
130
|
+
idle and respects usage, cooldown and ownership limits. A real worker is visible in Persona;
|
|
131
|
+
successful changes produce one small **mind** notification, while routine no-ops stay quiet.
|
|
132
|
+
Failures and important warnings remain visible, and applied changes retain history for guarded undo.
|
|
133
|
+
|
|
134
|
+
Use `/mind optimize auto status`, `/mind optimize auto off` or `/mind optimize auto on` for the current
|
|
135
|
+
session. `PI_PERSONA_MIND_OPTIMIZE=off` disables automatic optimization at startup. Capture can be set
|
|
136
|
+
with `PI_PERSONA_MIND_CAPTURE=auto|prompt|off`, and `PI_PERSONA_MIND_NUDGE=off` disables suggestions.
|
|
137
|
+
See [automatic review](docs/DESIGN.md#automatic-semantic-review) for admission and cost details.
|
|
138
|
+
|
|
139
|
+
## Learn more
|
|
140
|
+
|
|
141
|
+
- [Design: lifetimes, storage, limits, commands and safeguards](docs/DESIGN.md)
|
|
142
|
+
- [Evidence-grounded review and approval](docs/DESIGN.md#evidence-grounded-knowledge-review)
|
|
143
|
+
- [Storage recovery and concurrent writes](docs/DESIGN.md#durable-files-and-recovery)
|
|
144
|
+
- [Architecture decisions and evaluation boundaries](docs/MEMORY-RESEARCH.md)
|
|
145
|
+
- [Release history](CHANGELOG.md) · [MIT license](LICENSE)
|