hippo-memory 3.7.0 → 3.8.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 +277 -213
- package/dist/base/util/env.d.ts +1 -0
- package/dist/base/util/env.js +2 -0
- package/dist/base/util/version.d.ts +1 -1
- package/dist/base/util/version.js +1 -1
- package/dist/surface/cli/embedder-install.d.ts +18 -0
- package/dist/surface/cli/embedder-install.js +121 -0
- package/dist/surface/cli/init.js +32 -1
- package/dist/surface/cli/maintenance.js +2 -2
- package/dist/surface/cli/usage.d.ts +1 -1
- package/dist/surface/cli/usage.js +1 -1
- package/dist/surface/cli/verbs/memory.js +3 -1
- package/extensions/openclaw-plugin/README.md +5 -13
- package/extensions/openclaw-plugin/openclaw.plugin.json +2 -2
- package/extensions/openclaw-plugin/package.json +2 -2
- package/openclaw.plugin.json +2 -2
- package/package.json +4 -5
package/dist/base/util/env.d.ts
CHANGED
|
@@ -45,6 +45,7 @@ export declare function envActiveScope(): string | null;
|
|
|
45
45
|
export declare function envTenant(): string;
|
|
46
46
|
export declare const envSkipAutoIntegrations: () => boolean;
|
|
47
47
|
export declare const envSkipSchedule: () => boolean;
|
|
48
|
+
export declare const envSkipEmbedderInstall: () => boolean;
|
|
48
49
|
export declare const envMcpStdio: () => boolean;
|
|
49
50
|
export declare const envRequireServer: () => boolean;
|
|
50
51
|
export declare const envReadOnly: () => boolean;
|
package/dist/base/util/env.js
CHANGED
|
@@ -16,6 +16,7 @@ const FLAGS = {
|
|
|
16
16
|
HIPPO_AVAILABILITY: false,
|
|
17
17
|
HIPPO_SKIP_AUTO_INTEGRATIONS: false,
|
|
18
18
|
HIPPO_SKIP_SCHEDULE: false,
|
|
19
|
+
HIPPO_SKIP_EMBEDDER_INSTALL: false,
|
|
19
20
|
HIPPO_MCP_STDIO: false,
|
|
20
21
|
HIPPO_REQUIRE_SERVER: false,
|
|
21
22
|
HIPPO_REQUIRE_SESSION_SCOPED_FRESH_TAIL: false,
|
|
@@ -200,6 +201,7 @@ export function envTenant() {
|
|
|
200
201
|
// Install and CLI switches.
|
|
201
202
|
export const envSkipAutoIntegrations = bool('HIPPO_SKIP_AUTO_INTEGRATIONS');
|
|
202
203
|
export const envSkipSchedule = bool('HIPPO_SKIP_SCHEDULE');
|
|
204
|
+
export const envSkipEmbedderInstall = bool('HIPPO_SKIP_EMBEDDER_INSTALL');
|
|
203
205
|
export const envMcpStdio = bool('HIPPO_MCP_STDIO');
|
|
204
206
|
export const envRequireServer = bool('HIPPO_REQUIRE_SERVER');
|
|
205
207
|
export const envReadOnly = bool('HIPPO_READ_ONLY');
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Single source of truth for the package version, written by scripts/sync-version.mjs; never
|
|
3
3
|
* edit by hand. Read by the db rollback guard, /health, MCP. A constant, not a runtime
|
|
4
4
|
* package.json read: the published bundle may lack package.json on a path ESM can resolve. */
|
|
5
|
-
export declare const PACKAGE_VERSION = "3.
|
|
5
|
+
export declare const PACKAGE_VERSION = "3.8.0";
|
|
6
6
|
/** The floor a store takes on its first expiring key: the first release with schema v53, set by
|
|
7
7
|
* hand in that release; scripts/checks/check-expiring-keys-floor.mjs gates it. */
|
|
8
8
|
export declare const EXPIRING_KEYS_MIN_BINARY = "1.64.0";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Single source of truth for the package version, written by scripts/sync-version.mjs; never
|
|
3
3
|
* edit by hand. Read by the db rollback guard, /health, MCP. A constant, not a runtime
|
|
4
4
|
* package.json read: the published bundle may lack package.json on a path ESM can resolve. */
|
|
5
|
-
export const PACKAGE_VERSION = '3.
|
|
5
|
+
export const PACKAGE_VERSION = '3.8.0';
|
|
6
6
|
/** The floor a store takes on its first expiring key: the first release with schema v53, set by
|
|
7
7
|
* hand in that release; scripts/checks/check-expiring-keys-floor.mjs gates it. */
|
|
8
8
|
export const EXPIRING_KEYS_MIN_BINARY = '1.64.0';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type ExecFileSyncOptions } from 'node:child_process';
|
|
2
|
+
import type { EmbeddingsConfig } from '../../base/config/config.js';
|
|
3
|
+
export type RunNode = (file: string, args: readonly string[], opts: ExecFileSyncOptions) => void;
|
|
4
|
+
/** What the step reads from the machine; tests pass stand-ins. */
|
|
5
|
+
export interface EmbedderInstallDeps {
|
|
6
|
+
readonly run: RunNode;
|
|
7
|
+
readonly installed: () => boolean;
|
|
8
|
+
readonly exists: (file: string) => boolean;
|
|
9
|
+
readonly packageRoot: string;
|
|
10
|
+
readonly platform: NodeJS.Platform;
|
|
11
|
+
readonly nodePath: string;
|
|
12
|
+
}
|
|
13
|
+
/** How to install the local embedder where this hippo resolves it, as the end of a sentence. */
|
|
14
|
+
export declare function embedderInstallAdvice(deps?: EmbedderInstallDeps): string;
|
|
15
|
+
/** Installs the local embedder into hippo's own npm global folder, else prints how; never throws.
|
|
16
|
+
* --ignore-scripts: the tree ships prebuilt binaries, so no transitive install script runs. */
|
|
17
|
+
export declare function installLocalEmbedder(embeddings: EmbeddingsConfig, deps?: EmbedderInstallDeps): boolean;
|
|
18
|
+
//# sourceMappingURL=embedder-install.d.ts.map
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
// The init step that installs the local embedder beside a global hippo, so a default install
|
|
2
|
+
// recalls by meaning as well as by keyword while the package itself keeps no runtime dependencies.
|
|
3
|
+
import * as fs from 'node:fs';
|
|
4
|
+
import * as path from 'node:path';
|
|
5
|
+
import { execFileSync } from 'node:child_process';
|
|
6
|
+
import { PACKAGE_ROOT } from '../../base/config/package-root.js';
|
|
7
|
+
import { isEmbeddingAvailable } from '../../base/embeddings/local.js';
|
|
8
|
+
import { envSkipEmbedderInstall } from '../../base/util/env.js';
|
|
9
|
+
import { errorCode, errorFields, errorMessage, log } from '../../base/util/log.js';
|
|
10
|
+
/** Exact: a global install has no lockfile, so this pin is the one review gate on the tree. */
|
|
11
|
+
const EMBEDDER_PACKAGE = '@huggingface/transformers@4.3.2';
|
|
12
|
+
const INSTALL_TIMEOUT_MS = 10 * 60_000;
|
|
13
|
+
const NPM_CLI = path.join('node_modules', 'npm', 'bin', 'npm-cli.js');
|
|
14
|
+
const PROJECT_ADD = [
|
|
15
|
+
['pnpm-lock.yaml', 'pnpm add'],
|
|
16
|
+
['yarn.lock', 'yarn add --ignore-scripts'],
|
|
17
|
+
['bun.lock', 'bun add'],
|
|
18
|
+
['bun.lockb', 'bun add'],
|
|
19
|
+
];
|
|
20
|
+
const MACHINE = {
|
|
21
|
+
run: execFileSync,
|
|
22
|
+
installed: isEmbeddingAvailable,
|
|
23
|
+
exists: fs.existsSync,
|
|
24
|
+
packageRoot: PACKAGE_ROOT,
|
|
25
|
+
platform: process.platform,
|
|
26
|
+
nodePath: process.execPath,
|
|
27
|
+
};
|
|
28
|
+
/** npm puts globals in `{prefix}/node_modules` on Windows and `{prefix}/lib/node_modules`
|
|
29
|
+
* elsewhere, with no package.json above; pnpm, yarn, bun and npm projects are all projects. */
|
|
30
|
+
function layoutOf(deps) {
|
|
31
|
+
const parts = deps.packageRoot.split(/[\\/]/);
|
|
32
|
+
if (parts.includes('_npx'))
|
|
33
|
+
return { kind: 'npx' };
|
|
34
|
+
const first = parts.indexOf('node_modules');
|
|
35
|
+
if (first < 0)
|
|
36
|
+
return { kind: 'project', dir: deps.packageRoot };
|
|
37
|
+
const dir = parts.slice(0, first).join(path.sep) || path.sep;
|
|
38
|
+
const direct = first === parts.length - 2;
|
|
39
|
+
if (direct && !deps.exists(path.join(dir, 'package.json'))) {
|
|
40
|
+
if (deps.platform === 'win32')
|
|
41
|
+
return { kind: 'npm-global', prefix: dir };
|
|
42
|
+
if (path.basename(dir) === 'lib')
|
|
43
|
+
return { kind: 'npm-global', prefix: path.dirname(dir) };
|
|
44
|
+
}
|
|
45
|
+
return { kind: 'project', dir };
|
|
46
|
+
}
|
|
47
|
+
function adviceFor(layout, deps) {
|
|
48
|
+
if (layout.kind === 'npm-global') {
|
|
49
|
+
return `run: npm install -g --ignore-scripts ${EMBEDDER_PACKAGE}`;
|
|
50
|
+
}
|
|
51
|
+
if (layout.kind === 'npx') {
|
|
52
|
+
return 'install hippo globally (npm install -g hippo-memory), then run hippo init again';
|
|
53
|
+
}
|
|
54
|
+
const add = PROJECT_ADD.find(([lockfile]) => deps.exists(path.join(layout.dir, lockfile)))?.[1] ??
|
|
55
|
+
'npm install --ignore-scripts';
|
|
56
|
+
return `run \`${add} ${EMBEDDER_PACKAGE}\` in ${layout.dir}`;
|
|
57
|
+
}
|
|
58
|
+
/** How to install the local embedder where this hippo resolves it, as the end of a sentence. */
|
|
59
|
+
export function embedderInstallAdvice(deps = MACHINE) {
|
|
60
|
+
return adviceFor(layoutOf(deps), deps);
|
|
61
|
+
}
|
|
62
|
+
/** The npm that owns hippo's global folder, else the one shipped beside this node. */
|
|
63
|
+
function npmCliFor(prefix, deps) {
|
|
64
|
+
const lib = deps.platform === 'win32' ? '' : 'lib';
|
|
65
|
+
const nodeHome = path.dirname(deps.nodePath);
|
|
66
|
+
const beside = deps.platform === 'win32' ? nodeHome : path.join(path.dirname(nodeHome), 'lib');
|
|
67
|
+
return [path.join(prefix, lib, NPM_CLI), path.join(beside, NPM_CLI)].find(deps.exists);
|
|
68
|
+
}
|
|
69
|
+
/** execFileSync puts npm's exit code on the error it throws; a kill or a failed start leaves none. */
|
|
70
|
+
function failureLine(error) {
|
|
71
|
+
if (errorCode(error) === 'ETIMEDOUT')
|
|
72
|
+
return 'npm ran for 10 minutes, so hippo stopped it.';
|
|
73
|
+
if ('status' in error && Number.isInteger(error.status)) {
|
|
74
|
+
return `npm stopped with exit code ${String(error.status)}; its error is above.`;
|
|
75
|
+
}
|
|
76
|
+
return `npm did not start (${error.message.split(/\r?\n/, 1)[0]}).`;
|
|
77
|
+
}
|
|
78
|
+
/** Installs the local embedder into hippo's own npm global folder, else prints how; never throws.
|
|
79
|
+
* --ignore-scripts: the tree ships prebuilt binaries, so no transitive install script runs. */
|
|
80
|
+
export function installLocalEmbedder(embeddings, deps = MACHINE) {
|
|
81
|
+
if (embeddings.enabled === false || (embeddings.provider ?? 'local') !== 'local')
|
|
82
|
+
return false;
|
|
83
|
+
if (deps.installed())
|
|
84
|
+
return false;
|
|
85
|
+
if (envSkipEmbedderInstall()) {
|
|
86
|
+
console.log('HIPPO_SKIP_EMBEDDER_INSTALL=1, so init did not install local embeddings.');
|
|
87
|
+
return false;
|
|
88
|
+
}
|
|
89
|
+
const layout = layoutOf(deps);
|
|
90
|
+
const npmCli = layout.kind === 'npm-global' ? npmCliFor(layout.prefix, deps) : undefined;
|
|
91
|
+
if (layout.kind !== 'npm-global' || !npmCli) {
|
|
92
|
+
console.log(`Embeddings are off. For recall by meaning, ${adviceFor(layout, deps)}`);
|
|
93
|
+
return false;
|
|
94
|
+
}
|
|
95
|
+
console.log(`Installing local embeddings (${EMBEDDER_PACKAGE}, about 480 MB, and an 87 MB model on ` +
|
|
96
|
+
'first use) for recall by meaning. This can take a few minutes; --no-embeddings skips it.');
|
|
97
|
+
try {
|
|
98
|
+
deps.run(deps.nodePath, [
|
|
99
|
+
npmCli,
|
|
100
|
+
'install',
|
|
101
|
+
'--global',
|
|
102
|
+
'--prefix',
|
|
103
|
+
layout.prefix,
|
|
104
|
+
'--ignore-scripts',
|
|
105
|
+
EMBEDDER_PACKAGE,
|
|
106
|
+
], { stdio: ['ignore', 'inherit', 'inherit'], timeout: INSTALL_TIMEOUT_MS });
|
|
107
|
+
}
|
|
108
|
+
catch (err) {
|
|
109
|
+
const error = err instanceof Error ? err : new Error(errorMessage(err));
|
|
110
|
+
log.info(`embedder install failed: ${error.message}`, errorFields(error));
|
|
111
|
+
console.log(`${failureLine(error)} For recall by meaning, ${adviceFor(layout, deps)}`);
|
|
112
|
+
return false;
|
|
113
|
+
}
|
|
114
|
+
if (!deps.installed()) {
|
|
115
|
+
console.log(`npm finished, but hippo cannot find the package. For recall by meaning, ${adviceFor(layout, deps)}`);
|
|
116
|
+
return false;
|
|
117
|
+
}
|
|
118
|
+
console.log('Local embeddings are on.');
|
|
119
|
+
return true;
|
|
120
|
+
}
|
|
121
|
+
//# sourceMappingURL=embedder-install.js.map
|
package/dist/surface/cli/init.js
CHANGED
|
@@ -12,7 +12,7 @@ import { installOpencodePlugin } from '../hooks-install/opencode.js';
|
|
|
12
12
|
import { initMemoryStore } from '../../api/store-init.js';
|
|
13
13
|
import { isInitialized } from '../../host/project-identity.js';
|
|
14
14
|
import { hippoHomeDir } from '../../host/agent-homes.js';
|
|
15
|
-
import { memoryList } from '../../api/memories/memories.js';
|
|
15
|
+
import { memoryCountAll, memoryList } from '../../api/memories/memories.js';
|
|
16
16
|
import { cliApiContext, cliInitGlobal, cliSyncOptions } from './api-context.js';
|
|
17
17
|
import { isGitRepo } from '../../base/ports/git.js';
|
|
18
18
|
import { processGit } from '../../infra/git-runner.js';
|
|
@@ -28,6 +28,9 @@ import { learnFromRepo, skipLearnOnSharedStore } from './shared.js';
|
|
|
28
28
|
import { appendHookBlock, HOOK_MARKERS, HOOKS, hippoBlock } from '../hooks-install/instructions.js';
|
|
29
29
|
import { HIPPO_DIR } from '../../base/util/agent-homes.js';
|
|
30
30
|
import { SEED_DAYS_SCAN, SEED_DAYS_SINGLE } from './flag-defaults.js';
|
|
31
|
+
import { installLocalEmbedder } from './embedder-install.js';
|
|
32
|
+
import { loadConfig } from '../../host/config-file.js';
|
|
33
|
+
import { plural } from '../../base/util/format.js';
|
|
31
34
|
// An unreadable or vanished folder is expected while scanning; any other failure is worth a line.
|
|
32
35
|
const QUIET_SCAN_ERRORS = new Set(['EACCES', 'EPERM', 'ENOENT', 'ENOTDIR']);
|
|
33
36
|
function scanForGitRepos(rootDir, maxDepth = 2) {
|
|
@@ -157,6 +160,9 @@ async function initScannedRepos(scanDir, tenantId, flags) {
|
|
|
157
160
|
return;
|
|
158
161
|
}
|
|
159
162
|
console.log(`Found ${repos.length} repositories:\n`);
|
|
163
|
+
const stores = [hippoHomeDir(), ...repos.map((repo) => path.join(repo, HIPPO_DIR))];
|
|
164
|
+
const hadStores = stores.some((store) => isInitialized(store));
|
|
165
|
+
const embedderAdded = maybeInstallEmbedder(hippoHomeDir(), flags);
|
|
160
166
|
const globalRoot = initGlobalFirst();
|
|
161
167
|
const seedDays = numberFlag(flags, 'days') ?? SEED_DAYS_SCAN;
|
|
162
168
|
const machine = currentMachine();
|
|
@@ -170,6 +176,10 @@ async function initScannedRepos(scanDir, tenantId, flags) {
|
|
|
170
176
|
printAgentImport(agentImport, '');
|
|
171
177
|
}
|
|
172
178
|
console.log(`Global store: ${globalRoot}`);
|
|
179
|
+
if (embedderAdded && hadStores) {
|
|
180
|
+
console.log('Memories stored before this run have no vectors yet: run `hippo embed` in each project ' +
|
|
181
|
+
'and `hippo embed --global` to add them.');
|
|
182
|
+
}
|
|
173
183
|
if (initInstallsIntegrations(flags))
|
|
174
184
|
installScanHooks(repos);
|
|
175
185
|
if (!boolFlag(flags, 'no-schedule')) {
|
|
@@ -179,8 +189,11 @@ async function initScannedRepos(scanDir, tenantId, flags) {
|
|
|
179
189
|
}
|
|
180
190
|
async function initGlobalOnly(tenantId, flags) {
|
|
181
191
|
const globalRoot = hippoHomeDir();
|
|
192
|
+
const embedderAdded = maybeInstallEmbedder(globalRoot, flags);
|
|
182
193
|
if (isInitialized(globalRoot)) {
|
|
183
194
|
console.log('Already initialized global store at', globalRoot);
|
|
195
|
+
if (embedderAdded)
|
|
196
|
+
await printEmbedHint(globalRoot, tenantId, 'hippo embed --global');
|
|
184
197
|
}
|
|
185
198
|
else {
|
|
186
199
|
cliInitGlobal();
|
|
@@ -219,8 +232,11 @@ export async function handleInit({ hippoRoot, tenantId, flags }) {
|
|
|
219
232
|
return;
|
|
220
233
|
}
|
|
221
234
|
const alreadyExists = isInitialized(hippoRoot);
|
|
235
|
+
const embedderAdded = maybeInstallEmbedder(hippoRoot, flags);
|
|
222
236
|
if (alreadyExists) {
|
|
223
237
|
console.log('Already initialized at', hippoRoot);
|
|
238
|
+
if (embedderAdded)
|
|
239
|
+
await printEmbedHint(hippoRoot, tenantId, 'hippo embed');
|
|
224
240
|
}
|
|
225
241
|
else {
|
|
226
242
|
await initMemoryStore(cliApiContext(hippoRoot, tenantId));
|
|
@@ -247,6 +263,21 @@ export async function handleInit({ hippoRoot, tenantId, flags }) {
|
|
|
247
263
|
printAgentImport(await importForStore(hippoRoot, cliSyncOptions(tenantId, currentMachine())));
|
|
248
264
|
}
|
|
249
265
|
}
|
|
266
|
+
/** First in every init path: a killed install leaves no store to skip the first-run seed, and
|
|
267
|
+
* the memories init writes get vectors as they land. */
|
|
268
|
+
function maybeInstallEmbedder(configRoot, flags) {
|
|
269
|
+
if (boolFlag(flags, 'no-embeddings'))
|
|
270
|
+
return false;
|
|
271
|
+
return installLocalEmbedder(loadConfig(configRoot).embeddings);
|
|
272
|
+
}
|
|
273
|
+
/** The embedder arrived after this store already held memories, and those have no vectors yet. */
|
|
274
|
+
async function printEmbedHint(root, tenantId, command) {
|
|
275
|
+
const count = await memoryCountAll(cliApiContext(root, tenantId));
|
|
276
|
+
if (count > 0) {
|
|
277
|
+
const stored = plural(count, 'memory', 'memories');
|
|
278
|
+
console.log(` Run \`${command}\` to add vectors to the ${stored} stored before now.`);
|
|
279
|
+
}
|
|
280
|
+
}
|
|
250
281
|
/**
|
|
251
282
|
* Every write init makes into agent config (instruction blocks, hooks, plugins) is an automatic
|
|
252
283
|
* integration, so one switch skips them all.
|
|
@@ -11,6 +11,7 @@ import { boolFlag, numberFlag, stringFlagOrExit, hasFlag, } from './flag-values.
|
|
|
11
11
|
import { requireInit, resolveAuthRoot } from './shared.js';
|
|
12
12
|
import { errorMessage } from '../../base/util/log.js';
|
|
13
13
|
import { fail } from './exit.js';
|
|
14
|
+
import { embedderInstallAdvice } from './embedder-install.js';
|
|
14
15
|
const MAX_FAILED_SHOWN = 5;
|
|
15
16
|
const MAX_PAIRS_SHOWN = 15;
|
|
16
17
|
const PAIR_PREVIEW_CHARS = 90;
|
|
@@ -178,8 +179,7 @@ function readyEmbedProvider(ctx, given) {
|
|
|
178
179
|
return null;
|
|
179
180
|
}
|
|
180
181
|
if (embedProvider.kind === 'local') {
|
|
181
|
-
console.log(
|
|
182
|
-
console.log(' npm install @huggingface/transformers');
|
|
182
|
+
console.log(`Embeddings not available. To turn them on, ${embedderInstallAdvice()}`);
|
|
183
183
|
process.exitCode = 1;
|
|
184
184
|
}
|
|
185
185
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare function printAuditPruneUsage(): void;
|
|
2
2
|
export declare function printSlackBackfillUsage(): void;
|
|
3
3
|
export declare function printSlackWorkspacesUsage(): void;
|
|
4
|
-
export declare const USAGE_HEADER = "\nHippo -
|
|
4
|
+
export declare const USAGE_HEADER = "\nHippo - One memory for every agent you'll ever use.\n\nUsage: hippo <command> [options]\n\nCommands:";
|
|
5
5
|
export declare const USAGE_EXAMPLES = "\n\nExamples:\n hippo init\n hippo remember \"FRED cache can silently drop series\" --tag error\n hippo recall \"data pipeline issues\" --budget 2000\n hippo context --auto --budget 1500\n hippo conflicts\n hippo reject mem_abc123 --reason \"leaked credential\"\n hippo reject --value \"never store my key again\" --reason \"secret\"\n hippo rejections\n hippo unreject a1b2c3d4e5f6\n hippo dormant \"staging hostname\"\n hippo dormant restore mem_abc123\n hippo tokens --days 7\n hippo session log --id sess_123 --task \"Ship feature\" --type progress --content \"Build is green, next step is docs\"\n hippo session latest --json\n hippo session resume\n hippo snapshot save --task \"Ship feature\" --summary \"Tests are green\" --next-step \"Open the PR\" --session sess_123\n hippo handoff create --summary \"PR is open, tests green\" --next \"Merge after review\" --session sess_123 --artifact src/foo.ts\n hippo handoff create --summary s --constraint a --constraint b --outcome partial --target-runtime codex --card-id c1 --tests pass\n hippo card create --title \"Add cards table\" --repo hippo --depends-on card_abc\n hippo card claim card_abc --runtime codex\n hippo card complete card_abc --outcome success\n hippo card heartbeat card_abc --run 7\n hippo card reclaim\n hippo embed --status\n hippo watch -- npm run build\n hippo learn --git --days 30\n hippo promote mem_abc123\n hippo sync\n hippo setup\n hippo hook install claude-code\n hippo decide \"Use PostgreSQL for new services\" --context \"JSONB support\"\n hippo incident \"Prod outage: DB connection pool exhausted\" --context \"spike at 14:00\"\n hippo process new \"Release\" --step \"run tests\" --step \"bump version\" --step \"publish\"\n hippo policy new \"Data retention\" --text \"Delete logs after 90 days\" --from 2026-01-01\n hippo policy asof 2026-03-01 --name \"Data retention\"\n hippo skill new \"Run tests\" --instructions \"npm test before every commit\" --trigger \"before commit\"\n hippo skill export\n hippo brief new \"hippo\" --summary \"Agent-memory library; E2 first-class objects in progress\"\n hippo brief refresh \"hippo\"\n hippo note new \"Acme Corp\" --text \"Renewal call: wants SSO before Q3; champion is the VP Eng\"\n hippo note list --customer \"Acme Corp\" --status active\n hippo graph extract\n hippo invalidate \"REST API\" --dry-run\n hippo invalidate \"REST API\" --reason \"migrated to GraphQL\"\n hippo invalidate --id mem_a1b2c3d4e5f6 --reason \"superseded by new policy\"\n hippo invalidate --churn --dry-run\n hippo export memories.json\n hippo export --format markdown memories.md\n hippo sleep --dry-run\n hippo outcome --good\n hippo status\n";
|
|
6
6
|
//# sourceMappingURL=usage.d.ts.map
|
|
@@ -19,7 +19,7 @@ export function printSlackWorkspacesUsage() {
|
|
|
19
19
|
console.log(' remove --team <T> Remove a workspace registration');
|
|
20
20
|
}
|
|
21
21
|
export const USAGE_HEADER = `
|
|
22
|
-
Hippo -
|
|
22
|
+
Hippo - One memory for every agent you'll ever use.
|
|
23
23
|
|
|
24
24
|
Usage: hippo <command> [options]
|
|
25
25
|
|
|
@@ -15,7 +15,7 @@ export const MEMORY_VERBS = {
|
|
|
15
15
|
repairsCodexWrapper: true,
|
|
16
16
|
scoped: true,
|
|
17
17
|
flags: {
|
|
18
|
-
switches: ['global', 'no-hooks', 'no-learn', 'no-schedule'],
|
|
18
|
+
switches: ['global', 'no-embeddings', 'no-hooks', 'no-learn', 'no-schedule'],
|
|
19
19
|
values: ['scan'],
|
|
20
20
|
numbers: ['days'],
|
|
21
21
|
},
|
|
@@ -28,6 +28,8 @@ export const MEMORY_VERBS = {
|
|
|
28
28
|
--no-hooks Skip auto-detecting and installing agent hooks
|
|
29
29
|
(HIPPO_SKIP_AUTO_INTEGRATIONS=1 does the same)
|
|
30
30
|
--no-schedule Skip auto-creating the machine-level daily runner
|
|
31
|
+
--no-embeddings Skip installing the local embedder (@huggingface/transformers)
|
|
32
|
+
(HIPPO_SKIP_EMBEDDER_INSTALL=1 does the same)
|
|
31
33
|
--no-learn Skip seeding memories from git history and importing
|
|
32
34
|
coding agents' own memories (every init imports those)`,
|
|
33
35
|
],
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Hippo Memory - OpenClaw Plugin
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
One memory for every agent you'll ever use. Hippo writes what you teach a coding agent into a store in your repo, and your other agents read that same store.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
The plugin puts your project's memories in front of the OpenClaw agent at session start, saves the errors its tools hit and gives it hippo's memory tools. Claude Code, Codex, Cursor and any MCP client read the same store.
|
|
6
6
|
|
|
7
7
|
## Install
|
|
8
8
|
|
|
@@ -101,17 +101,9 @@ When `autoLearn` is enabled, the plugin captures tool errors as memories. To pre
|
|
|
101
101
|
|
|
102
102
|
Errors that pass these three filters are stored with `hippo remember`.
|
|
103
103
|
|
|
104
|
-
###
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|---|---|---|
|
|
108
|
-
| Decay | Yes, 365-day half-life by default | No, saves everything |
|
|
109
|
-
| Retrieval strengthening | Yes | No |
|
|
110
|
-
| Outcome feedback | Yes | No |
|
|
111
|
-
| Cross-tool | Claude Code, Codex, Cursor, OpenClaw | Claude Code only |
|
|
112
|
-
| API calls | None by default. If `ANTHROPIC_API_KEY` is set, `hippo sleep` sends memory text to Anthropic; `{"extraction":{"enabled":false}}` stops it | Uses Claude API for compression |
|
|
113
|
-
| Token cost | ~1500 tokens/session (configurable) | Variable |
|
|
114
|
-
| Memecoin | No | Yes ($CMEM on Solana) |
|
|
104
|
+
### Model calls
|
|
105
|
+
|
|
106
|
+
Storing a memory makes no model call. The exception is `hippo sleep`, which sends text to Anthropic when `ANTHROPIC_API_KEY` is set, and `{"extraction":{"enabled":false}}` turns it off.
|
|
115
107
|
|
|
116
108
|
## Requirements
|
|
117
109
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "hippo-memory",
|
|
3
3
|
"name": "Hippo Memory",
|
|
4
|
-
"description": "
|
|
5
|
-
"version": "3.
|
|
4
|
+
"description": "One memory for every agent you'll ever use. Hippo writes what you teach a coding agent into a store in your repo, and your other agents read that same store.",
|
|
5
|
+
"version": "3.8.0",
|
|
6
6
|
|
|
7
7
|
"configSchema": {
|
|
8
8
|
"type": "object",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hippo-memory",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.8.0",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"description": "
|
|
5
|
+
"description": "One memory for every agent you'll ever use. Hippo writes what you teach a coding agent into a store in your repo, and your other agents read that same store.",
|
|
6
6
|
"main": "index.ts",
|
|
7
7
|
"openclaw": {
|
|
8
8
|
"extensions": [
|
package/openclaw.plugin.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "hippo-memory",
|
|
3
3
|
"name": "Hippo Memory",
|
|
4
|
-
"description": "
|
|
5
|
-
"version": "3.
|
|
4
|
+
"description": "One memory for every agent you'll ever use. Hippo writes what you teach a coding agent into a store in your repo, and your other agents read that same store.",
|
|
5
|
+
"version": "3.8.0",
|
|
6
6
|
"configSchema": {
|
|
7
7
|
"type": "object",
|
|
8
8
|
"additionalProperties": false,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hippo-memory",
|
|
3
|
-
"version": "3.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "3.8.0",
|
|
4
|
+
"description": "One memory for every agent you'll ever use. Hippo writes what you teach a coding agent into a store in your repo, and your other agents read that same store.",
|
|
5
5
|
"mcpName": "io.github.kitfunso/hippo-memory",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./dist/index.js",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"fmt": "oxfmt src tests scripts bin",
|
|
53
53
|
"fmt:check": "oxfmt --check src tests scripts bin",
|
|
54
54
|
"sbom": "node scripts/sbom.mjs",
|
|
55
|
-
"audit:security": "
|
|
55
|
+
"audit:security": "node scripts/checks/check-audit.mjs",
|
|
56
56
|
"smoke:pack": "node scripts/smoke-pack.mjs",
|
|
57
57
|
"smoke:openclaw-install": "node scripts/smoke-openclaw-install.mjs",
|
|
58
58
|
"build:ui": "cd ui && npm ci && npm run build",
|
|
@@ -81,12 +81,11 @@
|
|
|
81
81
|
"coding-agent",
|
|
82
82
|
"agents",
|
|
83
83
|
"llm",
|
|
84
|
-
"rag",
|
|
85
84
|
"retrieval",
|
|
86
|
-
"hybrid-search",
|
|
87
85
|
"embeddings",
|
|
88
86
|
"sqlite",
|
|
89
87
|
"local-first",
|
|
88
|
+
"open-source",
|
|
90
89
|
"cli",
|
|
91
90
|
"context",
|
|
92
91
|
"recall"
|