hippo-memory 1.67.0 → 1.69.0
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/README.md +1 -1
- package/dist/agent-memories/copilot.d.ts +3 -1
- package/dist/agent-memories/copilot.js +2 -2
- package/dist/api/auth.d.ts +14 -18
- package/dist/api/auth.js +93 -60
- package/dist/api/context-select.d.ts +10 -0
- package/dist/api/context-select.js +16 -18
- package/dist/api/context.js +101 -60
- package/dist/api/forget.d.ts +2 -2
- package/dist/api/forget.js +11 -0
- package/dist/api/outcome.d.ts +4 -4
- package/dist/api/outcome.js +29 -6
- package/dist/api/promote.d.ts +3 -3
- package/dist/api/promote.js +45 -90
- package/dist/api/remember.d.ts +3 -2
- package/dist/api/remember.js +38 -11
- package/dist/api/types.d.ts +9 -0
- package/dist/auth.d.ts +19 -0
- package/dist/auth.js +14 -6
- package/dist/capture/compact.js +21 -2
- package/dist/capture/copilot-transcript.d.ts +3 -0
- package/dist/capture/copilot-transcript.js +8 -1
- package/dist/capture/session-worker.d.ts +13 -0
- package/dist/capture/session-worker.js +194 -0
- package/dist/capture-contract.d.ts +3 -1
- package/dist/capture-contract.js +36 -0
- package/dist/cli/session-hooks.js +90 -22
- package/dist/cli/setup.js +70 -24
- package/dist/cli/usage.js +4 -1
- package/dist/cli.js +1 -1
- package/dist/connectors/github/ingest.js +2 -1
- package/dist/connectors/slack/deletion.js +2 -1
- package/dist/connectors/slack/ingest.js +2 -1
- package/dist/embeddings.d.ts +10 -10
- package/dist/embeddings.js +103 -18
- package/dist/env.d.ts +2 -0
- package/dist/env.js +2 -0
- package/dist/hooks/copilot.d.ts +50 -8
- package/dist/hooks/copilot.js +116 -30
- package/dist/hooks/json-hooks.d.ts +2 -0
- package/dist/hooks/json-hooks.js +11 -2
- package/dist/hooks/shared.d.ts +7 -1
- package/dist/hooks/shared.js +18 -3
- package/dist/mcp/memory-tools.d.ts +2 -2
- package/dist/mcp/memory-tools.js +9 -8
- package/dist/mcp/request.js +3 -3
- package/dist/memory.d.ts +2 -0
- package/dist/memory.js +7 -0
- package/dist/prompt-recall.d.ts +5 -0
- package/dist/prompt-recall.js +13 -0
- package/dist/raw-archive.d.ts +2 -2
- package/dist/raw-archive.js +5 -3
- package/dist/recall-scope.d.ts +2 -5
- package/dist/recall-scope.js +5 -6
- package/dist/server/routes/admin.js +2 -2
- package/dist/server/routes/memories.js +9 -6
- package/dist/server-detect.js +3 -2
- package/dist/server.d.ts +20 -4
- package/dist/server.js +23 -11
- package/dist/store/audit-event.d.ts +1 -1
- package/dist/store/audit-event.js +1 -1
- package/dist/store/entry-writes-group.d.ts +9 -0
- package/dist/store/entry-writes-group.js +157 -0
- package/dist/store/handoffs.d.ts +5 -2
- package/dist/store/handoffs.js +35 -5
- package/dist/store/key-writes.d.ts +9 -0
- package/dist/store/key-writes.js +30 -0
- package/dist/store/open.d.ts +2 -0
- package/dist/store/open.js +10 -0
- package/dist/store/search-rows.js +3 -9
- package/dist/store/sessions.d.ts +5 -0
- package/dist/store/sessions.js +4 -1
- package/dist/store/vector-writes.d.ts +6 -0
- package/dist/store/vector-writes.js +59 -0
- package/dist/store-port.d.ts +143 -1
- package/dist/store-port.js +48 -12
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/extensions/openclaw-plugin/openclaw.plugin.json +1 -1
- package/extensions/openclaw-plugin/package.json +1 -1
- package/openclaw.plugin.json +1 -1
- package/package.json +1 -1
package/dist/store-port.js
CHANGED
|
@@ -1,20 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
import { readApiKeyRecord } from './auth.js';
|
|
1
|
+
import { loadAmbientTallies } from './ambient-store.js';
|
|
2
|
+
import { listApiKeyRows, readApiKeyRecord } from './auth.js';
|
|
3
3
|
import { appendAuditEvent, listAuditEventsAfter } from './audit.js';
|
|
4
|
-
import {
|
|
4
|
+
import { withWriteScope } from './db.js';
|
|
5
5
|
import { StoreNotPortedError } from './db/sqlite-blocked.js';
|
|
6
6
|
import { embeddingIndexStateAt, loadStoredVectors } from './embeddings.js';
|
|
7
7
|
import { activeGoalsWithPolicies, localGoalRecallRows, writeGoalRecallLog, } from './goals.js';
|
|
8
8
|
import { loadPhysicsState } from './physics-state.js';
|
|
9
9
|
import { planningFallacyEvidenceAt } from './predictions/planning-fallacy.js';
|
|
10
10
|
import { writeRecallTrace } from './recall-trace.js';
|
|
11
|
+
import { loadAmbientCandidates, loadContextCandidates, } from './store/candidates.js';
|
|
11
12
|
import { loadEntriesByIds, loadFreshRawMemories } from './store/entry-reads.js';
|
|
12
13
|
import { auditHighIdAt, revokeKeyAt } from './store/key-audit.js';
|
|
14
|
+
import { createKeyAt, createSelfKeyAt } from './store/key-writes.js';
|
|
13
15
|
import { strengthenRetrievedInOwnTx } from './store/entry-writes.js';
|
|
16
|
+
import { sqliteEntryWrites } from './store/entry-writes-group.js';
|
|
14
17
|
import { loadLatestHandoff } from './store/handoffs.js';
|
|
15
18
|
import { updateStats } from './store/index-and-stats.js';
|
|
19
|
+
import { onHandle } from './store/open.js';
|
|
16
20
|
import { loadRecallSearchEntries, loadVectorCandidateEntries } from './store/search-rows.js';
|
|
17
21
|
import { listSessionEvents, loadActiveTaskSnapshot } from './store/sessions.js';
|
|
22
|
+
import { entriesWithoutVectorAt, writeVectorsAt } from './store/vector-writes.js';
|
|
18
23
|
import { recordTokenUse } from './token-ledger.js';
|
|
19
24
|
export function hasGroup(store, group) {
|
|
20
25
|
return group === 'base' || store[group] !== undefined;
|
|
@@ -27,15 +32,6 @@ export function requireGroup(store, group) {
|
|
|
27
32
|
throw new StoreNotPortedError(store.kind, group);
|
|
28
33
|
return methods;
|
|
29
34
|
}
|
|
30
|
-
function onHandle(hippoRoot, fn) {
|
|
31
|
-
const db = openHippoDb(hippoRoot);
|
|
32
|
-
try {
|
|
33
|
-
return fn(db);
|
|
34
|
-
}
|
|
35
|
-
finally {
|
|
36
|
-
closeHippoDb(db);
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
35
|
/** The store a request runs on: the served one, else hippo.db under its root, as the CLI and SDK callers have it. */
|
|
40
36
|
export function storeFor(ctx) {
|
|
41
37
|
return ctx.store ?? sqliteStore(ctx.hippoRoot);
|
|
@@ -98,9 +94,49 @@ export function sqliteStore(hippoRoot) {
|
|
|
98
94
|
},
|
|
99
95
|
},
|
|
100
96
|
keyAudit: sqliteKeyAudit(hippoRoot),
|
|
97
|
+
keyWrites: sqliteKeyWrites(hippoRoot),
|
|
98
|
+
vectorWrites: {
|
|
99
|
+
async entriesWithoutVector(query) {
|
|
100
|
+
return onHandle(hippoRoot, (db) => entriesWithoutVectorAt(db, query));
|
|
101
|
+
},
|
|
102
|
+
async writeVectors(write) {
|
|
103
|
+
return onHandle(hippoRoot, (db) => writeVectorsAt(db, write));
|
|
104
|
+
},
|
|
105
|
+
},
|
|
106
|
+
entryWrites: sqliteEntryWrites(hippoRoot),
|
|
107
|
+
contextReads: sqliteContextReads(hippoRoot),
|
|
101
108
|
async close() { },
|
|
102
109
|
};
|
|
103
110
|
}
|
|
111
|
+
function sqliteContextReads(hippoRoot) {
|
|
112
|
+
return {
|
|
113
|
+
async unfinishedHandoff(tenantId, maxAgeMs, key) {
|
|
114
|
+
return loadLatestHandoff(hippoRoot, tenantId, undefined, { unfinishedOnly: true, maxAgeMs, scopeFilter: 'default-deny' }, key ?? undefined);
|
|
115
|
+
},
|
|
116
|
+
async ambientCandidates(tenantId, { recentNeeded, admit, recall, origins }) {
|
|
117
|
+
return loadAmbientCandidates(hippoRoot, tenantId, recentNeeded, admit, recall, origins);
|
|
118
|
+
},
|
|
119
|
+
async contextCandidates(tenantId, filter) {
|
|
120
|
+
return loadContextCandidates(hippoRoot, tenantId, filter);
|
|
121
|
+
},
|
|
122
|
+
async ambientTallies(tenantId, filter) {
|
|
123
|
+
return loadAmbientTallies(hippoRoot, tenantId, filter);
|
|
124
|
+
},
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
function sqliteKeyWrites(hippoRoot) {
|
|
128
|
+
return {
|
|
129
|
+
async createApiKey(mint) {
|
|
130
|
+
onHandle(hippoRoot, (db) => createKeyAt(db, mint));
|
|
131
|
+
},
|
|
132
|
+
async createSelfApiKey(mint) {
|
|
133
|
+
return onHandle(hippoRoot, (db) => createSelfKeyAt(db, mint));
|
|
134
|
+
},
|
|
135
|
+
async listApiKeys(query) {
|
|
136
|
+
return onHandle(hippoRoot, (db) => listApiKeyRows(db, query));
|
|
137
|
+
},
|
|
138
|
+
};
|
|
139
|
+
}
|
|
104
140
|
function sqliteKeyAudit(hippoRoot) {
|
|
105
141
|
return {
|
|
106
142
|
async revokeApiKey(revoke) {
|
package/dist/version.d.ts
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
* an ESM `import` can resolve cleanly, and a hardcoded constant survives
|
|
17
17
|
* any packager that drops .json files.
|
|
18
18
|
*/
|
|
19
|
-
export declare const PACKAGE_VERSION = "1.
|
|
19
|
+
export declare const PACKAGE_VERSION = "1.69.0";
|
|
20
20
|
/** The floor a store takes on its first expiring key: the first release with schema v53, set by hand in that release; scripts/check-expiring-keys-floor.mjs gates it. */
|
|
21
21
|
export declare const EXPIRING_KEYS_MIN_BINARY = "1.64.0";
|
|
22
22
|
/** The floor a store takes on its first session bind or owner snapshot: first release with v54; set by hand in that release. */
|
package/dist/version.js
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
* an ESM `import` can resolve cleanly, and a hardcoded constant survives
|
|
17
17
|
* any packager that drops .json files.
|
|
18
18
|
*/
|
|
19
|
-
export const PACKAGE_VERSION = '1.
|
|
19
|
+
export const PACKAGE_VERSION = '1.69.0';
|
|
20
20
|
/** The floor a store takes on its first expiring key: the first release with schema v53, set by hand in that release; scripts/check-expiring-keys-floor.mjs gates it. */
|
|
21
21
|
export const EXPIRING_KEYS_MIN_BINARY = '1.64.0';
|
|
22
22
|
/** The floor a store takes on its first session bind or owner snapshot: first release with v54; set by hand in that release. */
|
package/openclaw.plugin.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "hippo-memory",
|
|
3
3
|
"name": "Hippo Memory",
|
|
4
4
|
"description": "Make your agent's memory work like a brain. Hippo is long-term memory for coding agents.",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.69.0",
|
|
6
6
|
"configSchema": {
|
|
7
7
|
"type": "object",
|
|
8
8
|
"additionalProperties": false,
|
package/package.json
CHANGED