clawvault 3.4.1 → 3.5.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/README.md +26 -26
- package/dist/{chunk-DCF4KMFD.js → chunk-DPK6P6BO.js} +3 -3
- package/dist/{chunk-BLQXXX7Q.js → chunk-FNFP7N6A.js} +2 -2
- package/dist/{chunk-QFWERBDP.js → chunk-J6DW6HBX.js} +1 -1
- package/dist/{chunk-VXAGOLDP.js → chunk-LCBHM3D6.js} +1 -1
- package/dist/{chunk-HGDDW24U.js → chunk-NTQD55S3.js} +3 -3
- package/dist/{chunk-PLNK37JD.js → chunk-P35SHNAU.js} +163 -320
- package/dist/cli/index.js +9 -9
- package/dist/commands/inject.js +2 -2
- package/dist/commands/maintain.js +2 -2
- package/dist/commands/observe.js +5 -5
- package/dist/commands/rebuild.js +3 -3
- package/dist/commands/replay.js +4 -4
- package/dist/commands/sleep.js +5 -5
- package/dist/commands/status.js +7 -7
- package/dist/index.d.ts +2 -2
- package/dist/index.js +25 -22
- package/dist/{openclaw-plugin--gqA2BZw.d.ts → openclaw-plugin-9M9qCZgl.d.ts} +2 -2
- package/dist/openclaw-plugin.d.ts +1 -1
- package/dist/openclaw-plugin.js +11 -1
- package/openclaw.plugin.json +1 -1
- package/package.json +1 -5
- package/hooks/clawvault/HOOK.md +0 -130
- package/hooks/clawvault/handler.js +0 -1696
- package/hooks/clawvault/handler.test.js +0 -576
- package/hooks/clawvault/integrity.js +0 -112
- package/hooks/clawvault/integrity.test.js +0 -32
- package/hooks/clawvault/openclaw.plugin.json +0 -190
- package/dist/{chunk-7SWP5FKU.js → chunk-FSYISBTU.js} +4 -4
- package/dist/{chunk-D5U3Q4N5.js → chunk-IOKLQR4W.js} +4 -4
- package/dist/{chunk-OFOCU2V4.js → chunk-QL34TMGN.js} +3 -3
package/dist/cli/index.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import {
|
|
2
2
|
registerCliCommands
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-DPK6P6BO.js";
|
|
4
4
|
import "../chunk-KCYWJDDW.js";
|
|
5
5
|
import "../chunk-TIGW564L.js";
|
|
6
6
|
import "../chunk-IVRIKYFE.js";
|
|
7
7
|
import "../chunk-DOIUYIXV.js";
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
12
|
-
import "../chunk-
|
|
13
|
-
import "../chunk-7SWP5FKU.js";
|
|
14
|
-
import "../chunk-HRLWZGMA.js";
|
|
15
|
-
import "../chunk-DVOUSOR3.js";
|
|
8
|
+
import "../chunk-QL34TMGN.js";
|
|
9
|
+
import "../chunk-IOKLQR4W.js";
|
|
10
|
+
import "../chunk-FNFP7N6A.js";
|
|
11
|
+
import "../chunk-LCBHM3D6.js";
|
|
12
|
+
import "../chunk-FSYISBTU.js";
|
|
16
13
|
import "../chunk-4PY655YM.js";
|
|
17
14
|
import "../chunk-AXSJIFOJ.js";
|
|
18
15
|
import "../chunk-GFCHWMGD.js";
|
|
19
16
|
import "../chunk-T7E764W3.js";
|
|
20
17
|
import "../chunk-HEHO7SMV.js";
|
|
21
18
|
import "../chunk-2PKBIKDH.js";
|
|
19
|
+
import "../chunk-TWMI3SNN.js";
|
|
22
20
|
import "../chunk-35JCYSRR.js";
|
|
21
|
+
import "../chunk-HRLWZGMA.js";
|
|
22
|
+
import "../chunk-DVOUSOR3.js";
|
|
23
23
|
import "../chunk-BSJ6RIT7.js";
|
|
24
24
|
import "../chunk-ECGJYWNA.js";
|
|
25
25
|
import "../chunk-2CDEETQN.js";
|
package/dist/commands/inject.js
CHANGED
|
@@ -2,9 +2,9 @@ import {
|
|
|
2
2
|
buildInjectionResult,
|
|
3
3
|
injectCommand,
|
|
4
4
|
registerInjectCommand
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-DVOUSOR3.js";
|
|
5
|
+
} from "../chunk-QL34TMGN.js";
|
|
7
6
|
import "../chunk-AXSJIFOJ.js";
|
|
7
|
+
import "../chunk-DVOUSOR3.js";
|
|
8
8
|
import "../chunk-2CDEETQN.js";
|
|
9
9
|
import "../chunk-33DOSHTA.js";
|
|
10
10
|
import "../chunk-2ZDO52B4.js";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
maintainCommand,
|
|
3
3
|
registerMaintainCommand
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-DVOUSOR3.js";
|
|
4
|
+
} from "../chunk-IOKLQR4W.js";
|
|
6
5
|
import "../chunk-2PKBIKDH.js";
|
|
7
6
|
import "../chunk-35JCYSRR.js";
|
|
7
|
+
import "../chunk-DVOUSOR3.js";
|
|
8
8
|
import "../chunk-GJO3CFUN.js";
|
|
9
9
|
import "../chunk-2ZDO52B4.js";
|
|
10
10
|
export {
|
package/dist/commands/observe.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
observeCommand,
|
|
3
3
|
registerObserveCommand
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-HRLWZGMA.js";
|
|
8
|
-
import "../chunk-DVOUSOR3.js";
|
|
4
|
+
} from "../chunk-FNFP7N6A.js";
|
|
5
|
+
import "../chunk-LCBHM3D6.js";
|
|
6
|
+
import "../chunk-FSYISBTU.js";
|
|
9
7
|
import "../chunk-4PY655YM.js";
|
|
10
8
|
import "../chunk-AXSJIFOJ.js";
|
|
9
|
+
import "../chunk-HRLWZGMA.js";
|
|
10
|
+
import "../chunk-DVOUSOR3.js";
|
|
11
11
|
import "../chunk-BSJ6RIT7.js";
|
|
12
12
|
import "../chunk-2CDEETQN.js";
|
|
13
13
|
import "../chunk-GJO3CFUN.js";
|
package/dist/commands/rebuild.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
rebuildCommand,
|
|
3
3
|
registerRebuildCommand
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-DVOUSOR3.js";
|
|
4
|
+
} from "../chunk-J6DW6HBX.js";
|
|
5
|
+
import "../chunk-FSYISBTU.js";
|
|
7
6
|
import "../chunk-4PY655YM.js";
|
|
8
7
|
import "../chunk-AXSJIFOJ.js";
|
|
8
|
+
import "../chunk-DVOUSOR3.js";
|
|
9
9
|
import "../chunk-BSJ6RIT7.js";
|
|
10
10
|
import "../chunk-2CDEETQN.js";
|
|
11
11
|
import "../chunk-GJO3CFUN.js";
|
package/dist/commands/replay.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
registerReplayCommand,
|
|
3
3
|
replayCommand
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-7SWP5FKU.js";
|
|
7
|
-
import "../chunk-DVOUSOR3.js";
|
|
4
|
+
} from "../chunk-NTQD55S3.js";
|
|
5
|
+
import "../chunk-FSYISBTU.js";
|
|
8
6
|
import "../chunk-4PY655YM.js";
|
|
9
7
|
import "../chunk-AXSJIFOJ.js";
|
|
8
|
+
import "../chunk-TWMI3SNN.js";
|
|
9
|
+
import "../chunk-DVOUSOR3.js";
|
|
10
10
|
import "../chunk-BSJ6RIT7.js";
|
|
11
11
|
import "../chunk-2CDEETQN.js";
|
|
12
12
|
import "../chunk-MQUJNOHK.js";
|
package/dist/commands/sleep.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
clearDirtyFlag
|
|
3
3
|
} from "../chunk-F55HGNU4.js";
|
|
4
|
-
import {
|
|
5
|
-
runReflection
|
|
6
|
-
} from "../chunk-TWMI3SNN.js";
|
|
7
4
|
import {
|
|
8
5
|
Observer
|
|
9
|
-
} from "../chunk-
|
|
10
|
-
import "../chunk-DVOUSOR3.js";
|
|
6
|
+
} from "../chunk-FSYISBTU.js";
|
|
11
7
|
import "../chunk-4PY655YM.js";
|
|
12
8
|
import "../chunk-AXSJIFOJ.js";
|
|
9
|
+
import {
|
|
10
|
+
runReflection
|
|
11
|
+
} from "../chunk-TWMI3SNN.js";
|
|
12
|
+
import "../chunk-DVOUSOR3.js";
|
|
13
13
|
import "../chunk-BSJ6RIT7.js";
|
|
14
14
|
import {
|
|
15
15
|
ClawVault
|
package/dist/commands/status.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
formatAge
|
|
3
|
-
} from "../chunk-7ZRP733D.js";
|
|
4
1
|
import {
|
|
5
2
|
scanVaultLinks
|
|
6
3
|
} from "../chunk-7YZWHM36.js";
|
|
7
4
|
import "../chunk-J7ZWCI2C.js";
|
|
5
|
+
import {
|
|
6
|
+
formatAge
|
|
7
|
+
} from "../chunk-7ZRP733D.js";
|
|
8
8
|
import {
|
|
9
9
|
getObserverStaleness
|
|
10
|
-
} from "../chunk-
|
|
11
|
-
import "../chunk-
|
|
12
|
-
import "../chunk-HRLWZGMA.js";
|
|
13
|
-
import "../chunk-DVOUSOR3.js";
|
|
10
|
+
} from "../chunk-LCBHM3D6.js";
|
|
11
|
+
import "../chunk-FSYISBTU.js";
|
|
14
12
|
import "../chunk-4PY655YM.js";
|
|
15
13
|
import "../chunk-AXSJIFOJ.js";
|
|
14
|
+
import "../chunk-HRLWZGMA.js";
|
|
15
|
+
import "../chunk-DVOUSOR3.js";
|
|
16
16
|
import "../chunk-BSJ6RIT7.js";
|
|
17
17
|
import {
|
|
18
18
|
ClawVault
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Command } from 'commander';
|
|
2
2
|
import { V as VaultConfig, S as StoreOptions, D as Document, P as PatchOptions, a as SearchOptions, b as SearchResult, c as SyncOptions, d as SyncResult, C as Category, M as MemoryType, H as HandoffDocument, e as SessionRecap, f as VaultSearchConfig } from './types-DslKvCaj.js';
|
|
3
3
|
export { g as DEFAULT_CATEGORIES, h as DEFAULT_CONFIG, E as EmbeddingProvider, i as MEMORY_TYPES, j as PatchMode, R as RerankProvider, k as SearchBackend, T as TYPE_TO_CATEGORY, l as VaultMeta } from './types-DslKvCaj.js';
|
|
4
|
-
import { C as CaptureOptions, a as CaptureStoreResult, b as CaptureCandidate } from './openclaw-plugin
|
|
5
|
-
export { c as CaptureMessage, d as CaptureRejection, e as CapturedMemoryType, M as MemorySlot, f as MemorySlotInitOptions, g as MemorySlotRecallOptions, h as MemorySlotSearchOptions, i as MemorySlotStoreOptions, j as MemoryStoreMetadata, k as createMemorySlot, l as createMemorySlotPlugin, m as openclawHookPlugin, r as registerMemorySlot } from './openclaw-plugin
|
|
4
|
+
import { C as CaptureOptions, a as CaptureStoreResult, b as CaptureCandidate } from './openclaw-plugin-9M9qCZgl.js';
|
|
5
|
+
export { c as CaptureMessage, d as CaptureRejection, e as CapturedMemoryType, M as MemorySlot, f as MemorySlotInitOptions, g as MemorySlotRecallOptions, h as MemorySlotSearchOptions, i as MemorySlotStoreOptions, j as MemoryStoreMetadata, k as createMemorySlot, l as createMemorySlotPlugin, m as openclawHookPlugin, r as registerMemorySlot } from './openclaw-plugin-9M9qCZgl.js';
|
|
6
6
|
export { setupCommand } from './commands/setup.js';
|
|
7
7
|
export { CompatCheck, CompatCommandOptions, CompatReport, CompatStatus, checkOpenClawCompatibility, compatCommand, compatibilityExitCode } from './commands/compat.js';
|
|
8
8
|
export { GraphSummary, graphCommand, graphSummary } from './commands/graph.js';
|
package/dist/index.js
CHANGED
|
@@ -5,19 +5,14 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
rebuildCommand,
|
|
7
7
|
registerRebuildCommand
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-J6DW6HBX.js";
|
|
9
9
|
import {
|
|
10
10
|
recallCommand
|
|
11
11
|
} from "./chunk-YTRZNA64.js";
|
|
12
12
|
import {
|
|
13
13
|
registerReplayCommand,
|
|
14
14
|
replayCommand
|
|
15
|
-
} from "./chunk-
|
|
16
|
-
import {
|
|
17
|
-
buildSessionRecap,
|
|
18
|
-
formatSessionRecapMarkdown,
|
|
19
|
-
sessionRecapCommand
|
|
20
|
-
} from "./chunk-ZKGY7WTT.js";
|
|
15
|
+
} from "./chunk-NTQD55S3.js";
|
|
21
16
|
import {
|
|
22
17
|
setupCommand
|
|
23
18
|
} from "./chunk-EL6UBSX5.js";
|
|
@@ -60,11 +55,19 @@ import {
|
|
|
60
55
|
openclaw_plugin_default,
|
|
61
56
|
plausibilityScore,
|
|
62
57
|
registerMemorySlot
|
|
63
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-P35SHNAU.js";
|
|
64
59
|
import {
|
|
65
60
|
buildRecallResult,
|
|
66
61
|
classifyRecallQuery
|
|
67
62
|
} from "./chunk-RL2L6I6K.js";
|
|
63
|
+
import "./chunk-OIWVQYQF.js";
|
|
64
|
+
import "./chunk-7ZRP733D.js";
|
|
65
|
+
import {
|
|
66
|
+
buildSessionRecap,
|
|
67
|
+
formatSessionRecapMarkdown,
|
|
68
|
+
sessionRecapCommand
|
|
69
|
+
} from "./chunk-ZKGY7WTT.js";
|
|
70
|
+
import "./chunk-F55HGNU4.js";
|
|
68
71
|
import {
|
|
69
72
|
ensureEntityProfiles,
|
|
70
73
|
readEntityProfile,
|
|
@@ -73,7 +76,7 @@ import {
|
|
|
73
76
|
} from "./chunk-NSXYM6EZ.js";
|
|
74
77
|
import {
|
|
75
78
|
registerCliCommands
|
|
76
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-DPK6P6BO.js";
|
|
77
80
|
import {
|
|
78
81
|
registerTailscaleCommands,
|
|
79
82
|
registerTailscaleDiscoverCommand,
|
|
@@ -111,9 +114,6 @@ import {
|
|
|
111
114
|
reflectCommand,
|
|
112
115
|
registerReflectCommand
|
|
113
116
|
} from "./chunk-DOIUYIXV.js";
|
|
114
|
-
import {
|
|
115
|
-
runReflection
|
|
116
|
-
} from "./chunk-TWMI3SNN.js";
|
|
117
117
|
import {
|
|
118
118
|
buildInjectionResult,
|
|
119
119
|
deterministicInjectMatches,
|
|
@@ -121,22 +121,22 @@ import {
|
|
|
121
121
|
injectCommand,
|
|
122
122
|
registerInjectCommand,
|
|
123
123
|
runPromptInjection
|
|
124
|
-
} from "./chunk-
|
|
124
|
+
} from "./chunk-QL34TMGN.js";
|
|
125
125
|
import {
|
|
126
126
|
maintainCommand,
|
|
127
127
|
registerMaintainCommand
|
|
128
|
-
} from "./chunk-
|
|
128
|
+
} from "./chunk-IOKLQR4W.js";
|
|
129
129
|
import {
|
|
130
130
|
SessionWatcher,
|
|
131
131
|
observeCommand,
|
|
132
132
|
registerObserveCommand
|
|
133
|
-
} from "./chunk-
|
|
133
|
+
} from "./chunk-FNFP7N6A.js";
|
|
134
134
|
import {
|
|
135
135
|
getObserverStaleness,
|
|
136
136
|
getScaledObservationThresholdBytes,
|
|
137
137
|
observeActiveSessions,
|
|
138
138
|
parseSessionSourceLabel
|
|
139
|
-
} from "./chunk-
|
|
139
|
+
} from "./chunk-LCBHM3D6.js";
|
|
140
140
|
import {
|
|
141
141
|
Observer,
|
|
142
142
|
Reflector,
|
|
@@ -145,12 +145,7 @@ import {
|
|
|
145
145
|
createGeminiFlashAdapter,
|
|
146
146
|
createLlmFunction,
|
|
147
147
|
resolveFactExtractionMode
|
|
148
|
-
} from "./chunk-
|
|
149
|
-
import "./chunk-HRLWZGMA.js";
|
|
150
|
-
import {
|
|
151
|
-
requestLlmCompletion,
|
|
152
|
-
resolveLlmProvider
|
|
153
|
-
} from "./chunk-DVOUSOR3.js";
|
|
148
|
+
} from "./chunk-FSYISBTU.js";
|
|
154
149
|
import {
|
|
155
150
|
archiveProject,
|
|
156
151
|
createProject,
|
|
@@ -191,7 +186,15 @@ import {
|
|
|
191
186
|
registerInboxCommand
|
|
192
187
|
} from "./chunk-HEHO7SMV.js";
|
|
193
188
|
import "./chunk-2PKBIKDH.js";
|
|
189
|
+
import {
|
|
190
|
+
runReflection
|
|
191
|
+
} from "./chunk-TWMI3SNN.js";
|
|
194
192
|
import "./chunk-35JCYSRR.js";
|
|
193
|
+
import "./chunk-HRLWZGMA.js";
|
|
194
|
+
import {
|
|
195
|
+
requestLlmCompletion,
|
|
196
|
+
resolveLlmProvider
|
|
197
|
+
} from "./chunk-DVOUSOR3.js";
|
|
195
198
|
import {
|
|
196
199
|
FactStore,
|
|
197
200
|
extractFactsLlm,
|
|
@@ -249,7 +249,7 @@ declare const clawvaultPlugin: {
|
|
|
249
249
|
name: string;
|
|
250
250
|
kind: "memory";
|
|
251
251
|
description: string;
|
|
252
|
-
register(apiOrRuntime?: unknown):
|
|
252
|
+
register(apiOrRuntime?: unknown): {
|
|
253
253
|
plugins: {
|
|
254
254
|
slots: {
|
|
255
255
|
memory: MemorySlot;
|
|
@@ -261,7 +261,7 @@ declare const clawvaultPlugin: {
|
|
|
261
261
|
memory: ClawVaultMemoryManager;
|
|
262
262
|
};
|
|
263
263
|
};
|
|
264
|
-
}
|
|
264
|
+
};
|
|
265
265
|
};
|
|
266
266
|
|
|
267
267
|
export { type CaptureOptions as C, type MemorySlot as M, type CaptureStoreResult as a, type CaptureCandidate as b, type CaptureMessage as c, type CaptureRejection as d, type CapturedMemoryType as e, type MemorySlotInitOptions as f, type MemorySlotRecallOptions as g, type MemorySlotSearchOptions as h, type MemorySlotStoreOptions as i, type MemoryStoreMetadata as j, createMemorySlot as k, createMemorySlotPlugin as l, clawvaultPlugin as m, registerMemorySlot as r };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { l as createMemorySlotPlugin, m as default } from './openclaw-plugin
|
|
1
|
+
export { l as createMemorySlotPlugin, m as default } from './openclaw-plugin-9M9qCZgl.js';
|
|
2
2
|
import './types-DslKvCaj.js';
|
|
3
3
|
import './lib/config.js';
|
|
4
4
|
import './types-CbL-wIKi.js';
|
package/dist/openclaw-plugin.js
CHANGED
|
@@ -1,18 +1,28 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createMemorySlotPlugin,
|
|
3
3
|
openclaw_plugin_default
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-P35SHNAU.js";
|
|
5
5
|
import "./chunk-RL2L6I6K.js";
|
|
6
|
+
import "./chunk-OIWVQYQF.js";
|
|
7
|
+
import "./chunk-7ZRP733D.js";
|
|
8
|
+
import "./chunk-ZKGY7WTT.js";
|
|
9
|
+
import "./chunk-F55HGNU4.js";
|
|
6
10
|
import "./chunk-NSXYM6EZ.js";
|
|
11
|
+
import "./chunk-TWMI3SNN.js";
|
|
7
12
|
import "./chunk-35JCYSRR.js";
|
|
13
|
+
import "./chunk-HRLWZGMA.js";
|
|
14
|
+
import "./chunk-DVOUSOR3.js";
|
|
8
15
|
import "./chunk-BSJ6RIT7.js";
|
|
9
16
|
import "./chunk-ECGJYWNA.js";
|
|
10
17
|
import "./chunk-2CDEETQN.js";
|
|
11
18
|
import "./chunk-FZ5I2NF7.js";
|
|
12
19
|
import "./chunk-PTWPPVC7.js";
|
|
13
20
|
import "./chunk-H3JZIB5O.js";
|
|
21
|
+
import "./chunk-MQUJNOHK.js";
|
|
14
22
|
import "./chunk-GJO3CFUN.js";
|
|
23
|
+
import "./chunk-FHFUXL6G.js";
|
|
15
24
|
import "./chunk-33DOSHTA.js";
|
|
25
|
+
import "./chunk-Z2XBWN7A.js";
|
|
16
26
|
import "./chunk-2ZDO52B4.js";
|
|
17
27
|
export {
|
|
18
28
|
createMemorySlotPlugin,
|
package/openclaw.plugin.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clawvault",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.5.1",
|
|
4
4
|
"description": "Structured memory system for AI agents — typed storage, knowledge graph, context profiles, canvas dashboards, neural graph themes, and Obsidian-native task views. An elephant never forgets. 🐘",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.cjs",
|
|
@@ -21,16 +21,12 @@
|
|
|
21
21
|
"bin",
|
|
22
22
|
"dashboard",
|
|
23
23
|
"templates",
|
|
24
|
-
"hooks",
|
|
25
24
|
"openclaw.plugin.json"
|
|
26
25
|
],
|
|
27
26
|
"openclaw": {
|
|
28
27
|
"plugin": "./openclaw.plugin.json",
|
|
29
28
|
"extensions": [
|
|
30
29
|
"./dist/openclaw-plugin.js"
|
|
31
|
-
],
|
|
32
|
-
"hooks": [
|
|
33
|
-
"./hooks/clawvault"
|
|
34
30
|
]
|
|
35
31
|
},
|
|
36
32
|
"scripts": {
|
package/hooks/clawvault/HOOK.md
DELETED
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: clawvault
|
|
3
|
-
description: "Context resilience - recovery detection, auto-checkpoint, and session context injection"
|
|
4
|
-
metadata:
|
|
5
|
-
openclaw:
|
|
6
|
-
emoji: "🐘"
|
|
7
|
-
events: ["gateway:startup", "gateway:heartbeat", "command:new", "session:start", "compaction:memoryFlush", "cron.weekly"]
|
|
8
|
-
requires:
|
|
9
|
-
bins: ["clawvault"]
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
# ClawVault Hook
|
|
13
|
-
|
|
14
|
-
Integrates ClawVault's context death resilience into OpenClaw:
|
|
15
|
-
|
|
16
|
-
- **On gateway startup**: Checks for context death, alerts agent
|
|
17
|
-
- **On heartbeat**: Runs cheap threshold checks and observes active sessions when needed
|
|
18
|
-
- **On /new command**: Auto-checkpoints before session reset
|
|
19
|
-
- **On context compaction**: Forces incremental observation flush before context is lost
|
|
20
|
-
- **On session start**: Injects relevant vault context for the initial prompt
|
|
21
|
-
- **On weekly cron**: Runs `clawvault reflect` every Sunday midnight (UTC)
|
|
22
|
-
|
|
23
|
-
## Installation
|
|
24
|
-
|
|
25
|
-
```bash
|
|
26
|
-
npm install -g clawvault
|
|
27
|
-
openclaw hooks install clawvault
|
|
28
|
-
openclaw hooks enable clawvault
|
|
29
|
-
|
|
30
|
-
# Verify
|
|
31
|
-
openclaw hooks list --verbose
|
|
32
|
-
openclaw hooks info clawvault
|
|
33
|
-
openclaw hooks check
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
After enabling, restart your OpenClaw gateway process so hook registration reloads.
|
|
37
|
-
|
|
38
|
-
## Requirements
|
|
39
|
-
|
|
40
|
-
- ClawVault CLI installed globally
|
|
41
|
-
- Vault initialized (`clawvault setup` or `CLAWVAULT_PATH` set)
|
|
42
|
-
|
|
43
|
-
## What It Does
|
|
44
|
-
|
|
45
|
-
### Gateway Startup
|
|
46
|
-
|
|
47
|
-
1. Runs `clawvault recover --clear`
|
|
48
|
-
2. If context death detected, injects warning into first agent turn
|
|
49
|
-
3. Clears dirty death flag for clean session start
|
|
50
|
-
|
|
51
|
-
### Command: /new
|
|
52
|
-
|
|
53
|
-
1. Creates automatic checkpoint with session info
|
|
54
|
-
2. Captures state even if agent forgot to handoff
|
|
55
|
-
3. Ensures continuity across session resets
|
|
56
|
-
|
|
57
|
-
### Session Start
|
|
58
|
-
|
|
59
|
-
1. Extracts the initial user prompt (`context.initialPrompt` or first user message)
|
|
60
|
-
2. Runs `clawvault context "<prompt>" --format json --profile auto -v <vaultPath>`
|
|
61
|
-
- Delegates profile selection to the shared context intent policy (`incident`, `planning`, `handoff`, or `default`)
|
|
62
|
-
3. Injects up to 4 relevant context bullets into session messages
|
|
63
|
-
|
|
64
|
-
Injection format:
|
|
65
|
-
|
|
66
|
-
```text
|
|
67
|
-
[ClawVault] Relevant context for this task:
|
|
68
|
-
- <title> (<age>): <snippet>
|
|
69
|
-
- <title> (<age>): <snippet>
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
### Event Compatibility
|
|
73
|
-
|
|
74
|
-
The hook accepts canonical OpenClaw events (`gateway:startup`, `gateway:heartbeat`, `command:new`, `session:start`, `compaction:memoryFlush`, `cron.weekly`) and tolerates alias payload shapes (`event`, `eventName`, `name`, `hook`, `trigger`) to remain robust across runtime wrappers.
|
|
75
|
-
|
|
76
|
-
## Configuration
|
|
77
|
-
|
|
78
|
-
### Plugin Configuration (Recommended)
|
|
79
|
-
|
|
80
|
-
Configure the plugin via OpenClaw's config system:
|
|
81
|
-
|
|
82
|
-
```bash
|
|
83
|
-
# Set vault path
|
|
84
|
-
openclaw config set plugins.entries.clawvault.config.vaultPath ~/my-vault
|
|
85
|
-
|
|
86
|
-
# View current config
|
|
87
|
-
openclaw config get plugins.entries.clawvault
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
Available configuration options (all privileged actions are opt-in):
|
|
91
|
-
|
|
92
|
-
| Key | Type | Default | Description |
|
|
93
|
-
|-----|------|---------|-------------|
|
|
94
|
-
| `vaultPath` | string | (auto-detected) | Path to the ClawVault vault directory |
|
|
95
|
-
| `agentVaults` | object | `{}` | Per-agent vault mapping |
|
|
96
|
-
| `allowClawvaultExec` | boolean | `false` | Required gate for all `child_process` calls |
|
|
97
|
-
| `clawvaultBinaryPath` | string | (PATH lookup) | Optional absolute path to `clawvault` binary |
|
|
98
|
-
| `clawvaultBinarySha256` | string | (unset) | Optional SHA-256 executable integrity check |
|
|
99
|
-
| `allowEnvAccess` | boolean | `false` | Allow env fallbacks (`OPENCLAW_*`, `CLAWVAULT_PATH`) |
|
|
100
|
-
| `enableStartupRecovery` | boolean | `false` | Enable `gateway:startup` recovery check |
|
|
101
|
-
| `enableSessionContextInjection` | boolean | `false` | Enable `session:start` recap/context injection |
|
|
102
|
-
| `enableAutoCheckpoint` | boolean | `false` | Enable checkpoint on `command:new` |
|
|
103
|
-
| `enableObserveOnNew` | boolean | `false` | Enable observer flush on `command:new` |
|
|
104
|
-
| `enableHeartbeatObservation` | boolean | `false` | Enable heartbeat-driven observation |
|
|
105
|
-
| `enableCompactionObservation` | boolean | `false` | Enable observer flush on compaction |
|
|
106
|
-
| `enableWeeklyReflection` | boolean | `false` | Enable weekly reflection cron |
|
|
107
|
-
| `enableFactExtraction` | boolean | `false` | Enable local fact extraction/entity graph updates |
|
|
108
|
-
| `autoCheckpoint` | boolean | `false` | Deprecated alias for `enableAutoCheckpoint` |
|
|
109
|
-
| `contextProfile` | string | `"auto"` | Default context profile (`default`, `planning`, `incident`, `handoff`, `auto`) |
|
|
110
|
-
| `maxContextResults` | integer | `4` | Maximum context results to inject on session start |
|
|
111
|
-
| `observeOnHeartbeat` | boolean | `false` | Deprecated alias for `enableHeartbeatObservation` |
|
|
112
|
-
| `weeklyReflection` | boolean | `false` | Deprecated alias for `enableWeeklyReflection` |
|
|
113
|
-
|
|
114
|
-
Security details and threat model: see [SECURITY.md](../../SECURITY.md).
|
|
115
|
-
|
|
116
|
-
### Vault Path Resolution
|
|
117
|
-
|
|
118
|
-
When `allowEnvAccess=true`, the hook resolves the vault path in this order:
|
|
119
|
-
|
|
120
|
-
1. Plugin config (`plugins.entries.clawvault.config.vaultPath` set via `openclaw config`)
|
|
121
|
-
2. `OPENCLAW_PLUGIN_CLAWVAULT_VAULTPATH` environment variable
|
|
122
|
-
3. `CLAWVAULT_PATH` environment variable
|
|
123
|
-
4. Walking up from cwd to find `.clawvault.json`
|
|
124
|
-
5. Checking `memory/` subdirectory (OpenClaw convention)
|
|
125
|
-
|
|
126
|
-
When `allowEnvAccess=false` (default), steps 2 and 3 are skipped.
|
|
127
|
-
|
|
128
|
-
### Troubleshooting
|
|
129
|
-
|
|
130
|
-
If `openclaw hooks enable clawvault` fails with hook-not-found, run `openclaw hooks install clawvault` first and verify discovery with `openclaw hooks list --verbose`.
|