@openviking/openclaw-plugin 2026.8.19 → 2026.8.21
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 +2 -2
- package/client.ts +1 -1
- package/config.ts +1 -1
- package/dist/client.js +1 -1
- package/dist/config.js +1 -1
- package/dist/memory-ranking.js +2 -2
- package/dist/plugin/openviking-query-runtime.js +1 -1
- package/dist/plugin/openviking-recall-trace-runtime.js +2 -2
- package/dist/plugin/openviking-runtime-utils.js +4 -2
- package/dist/routing/memory-uri.js +4 -0
- package/memory-ranking.ts +2 -2
- package/openclaw.plugin.json +1 -1
- package/package.json +1 -1
- package/plugin/openviking-query-runtime.ts +1 -1
- package/plugin/openviking-recall-trace-runtime.ts +2 -2
- package/plugin/openviking-runtime-utils.ts +4 -2
- package/routing/memory-uri.ts +4 -0
- package/skills/install-openviking-memory/SKILL.md +1 -1
- package/skills/openviking-context-database/SKILL.md +2 -2
- package/skills/ov-experience-memory/SKILL.md +1 -1
package/README.md
CHANGED
|
@@ -269,7 +269,7 @@ They serve different roles:
|
|
|
269
269
|
Resource and skill imports are intentionally separate because they land in different OpenViking namespaces and use different server APIs:
|
|
270
270
|
|
|
271
271
|
- resources go through `/api/v1/resources` and land under `viking://resources/...`
|
|
272
|
-
- skills go through `/api/v1/skills` and land under `viking://user
|
|
272
|
+
- skills go through `/api/v1/skills` and land under `viking://user/<uid>/skills/...`
|
|
273
273
|
|
|
274
274
|
The plugin also registers explicit slash commands for manual imports:
|
|
275
275
|
|
|
@@ -277,7 +277,7 @@ The plugin also registers explicit slash commands for manual imports:
|
|
|
277
277
|
/add-resource ./README.md --to viking://resources/openviking-readme --wait
|
|
278
278
|
/add-skill ./skills/install-openviking-memory --wait
|
|
279
279
|
/ov-search "OpenViking install" --uri viking://resources/openviking-readme
|
|
280
|
-
/ov-search "memory install skill" --uri viking
|
|
280
|
+
/ov-search "memory install skill" --uri viking://~/skills
|
|
281
281
|
```
|
|
282
282
|
|
|
283
283
|
Resource import supports remote URLs, Git URLs, local files, local directories, and uploaded zip files. OpenViking's built-in parsers cover common documents and media such as Markdown, text, PDF, HTML, Word, PowerPoint, Excel, EPUB, images, audio, and video. Directory imports also accept common code, documentation, and config file extensions such as `.py`, `.js`, `.ts`, `.go`, `.rs`, `.java`, `.cpp`, `.json`, `.yaml`, `.toml`, `.csv`, `.rst`, `.proto`, `.tf`, and `.vue`.
|
package/client.ts
CHANGED
|
@@ -36,7 +36,7 @@ export type FsListResult = FsListEntry[];
|
|
|
36
36
|
|
|
37
37
|
export type CaptureMode = "semantic" | "keyword";
|
|
38
38
|
function userSessionUri(sessionId: string): string {
|
|
39
|
-
return `viking
|
|
39
|
+
return `viking://~/sessions/${encodeURIComponent(sessionId)}`;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
export type OpenVikingClientOptions = {
|
package/config.ts
CHANGED
|
@@ -136,7 +136,7 @@ export type ParsedMemoryOpenVikingConfig = Required<
|
|
|
136
136
|
};
|
|
137
137
|
|
|
138
138
|
const DEFAULT_BASE_URL = "http://127.0.0.1:1933";
|
|
139
|
-
const DEFAULT_TARGET_URI = "viking
|
|
139
|
+
const DEFAULT_TARGET_URI = "viking://~/memories";
|
|
140
140
|
const DEFAULT_TIMEOUT_MS = 15000;
|
|
141
141
|
const DEFAULT_CAPTURE_MODE = "semantic";
|
|
142
142
|
const DEFAULT_CAPTURE_MAX_LENGTH = 24000;
|
package/dist/client.js
CHANGED
|
@@ -8,7 +8,7 @@ import { Zip, ZipDeflate } from "fflate";
|
|
|
8
8
|
import { defaultHttpTransport } from "./adapters/http-transport.js";
|
|
9
9
|
import { defaultResourcePackager, } from "./adapters/resource-packager.js";
|
|
10
10
|
function userSessionUri(sessionId) {
|
|
11
|
-
return `viking
|
|
11
|
+
return `viking://~/sessions/${encodeURIComponent(sessionId)}`;
|
|
12
12
|
}
|
|
13
13
|
const DEFAULT_WAIT_REQUEST_TIMEOUT_MS = 120_000;
|
|
14
14
|
export const DEFAULT_PHASE2_POLL_TIMEOUT_MS = 300_000;
|
package/dist/config.js
CHANGED
|
@@ -2,7 +2,7 @@ import { homedir } from "node:os";
|
|
|
2
2
|
import { readFileSync } from "node:fs";
|
|
3
3
|
import { getEnv } from "./runtime-utils.js";
|
|
4
4
|
const DEFAULT_BASE_URL = "http://127.0.0.1:1933";
|
|
5
|
-
const DEFAULT_TARGET_URI = "viking
|
|
5
|
+
const DEFAULT_TARGET_URI = "viking://~/memories";
|
|
6
6
|
const DEFAULT_TIMEOUT_MS = 15000;
|
|
7
7
|
const DEFAULT_CAPTURE_MODE = "semantic";
|
|
8
8
|
const DEFAULT_CAPTURE_MAX_LENGTH = 24000;
|
package/dist/memory-ranking.js
CHANGED
|
@@ -181,9 +181,9 @@ function inferResourceType(item) {
|
|
|
181
181
|
return "resource";
|
|
182
182
|
if (item.uri.startsWith("viking://session/"))
|
|
183
183
|
return "session";
|
|
184
|
-
if (item.uri.startsWith("viking://user/skills") || item.uri.startsWith("viking://skills"))
|
|
184
|
+
if (item.uri.startsWith("viking://user/skills") || item.uri.startsWith("viking://~/skills") || item.uri.startsWith("viking://skills"))
|
|
185
185
|
return "agent";
|
|
186
|
-
if (item.uri.startsWith("viking://user/"))
|
|
186
|
+
if (item.uri.startsWith("viking://user/") || item.uri.startsWith("viking://~/"))
|
|
187
187
|
return "user";
|
|
188
188
|
return undefined;
|
|
189
189
|
}
|
|
@@ -279,7 +279,7 @@ export function createOpenVikingQueryRuntime(deps) {
|
|
|
279
279
|
};
|
|
280
280
|
const [resourcesSettled, skillsSettled] = await Promise.allSettled([
|
|
281
281
|
runSearch("viking://resources"),
|
|
282
|
-
runSearch("viking
|
|
282
|
+
runSearch("viking://~/skills"),
|
|
283
283
|
]);
|
|
284
284
|
const successful = [];
|
|
285
285
|
if (resourcesSettled.status === "fulfilled") {
|
|
@@ -57,9 +57,9 @@ function inferUriType(uri) {
|
|
|
57
57
|
return "resource";
|
|
58
58
|
if (uri.startsWith("viking://session/"))
|
|
59
59
|
return "session";
|
|
60
|
-
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://skills"))
|
|
60
|
+
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://~/skills") || uri.startsWith("viking://skills"))
|
|
61
61
|
return "skill";
|
|
62
|
-
if (uri.startsWith("viking://user/"))
|
|
62
|
+
if (uri.startsWith("viking://user/") || uri.startsWith("viking://~/"))
|
|
63
63
|
return "user_memory";
|
|
64
64
|
if (uri.includes("/archive") || uri.includes("/history/"))
|
|
65
65
|
return "archive";
|
|
@@ -8,9 +8,11 @@ export function previewText(value, maxChars) {
|
|
|
8
8
|
export function inferRecallResourceType(uri) {
|
|
9
9
|
if (uri.startsWith("viking://resources"))
|
|
10
10
|
return "resource";
|
|
11
|
-
|
|
11
|
+
// viking://~ is the home alias for the caller's own user space; configured target
|
|
12
|
+
// URIs use it, while server responses come back canonical as viking://user/<uid>/...
|
|
13
|
+
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://~/skills") || uri.startsWith("viking://skills"))
|
|
12
14
|
return "agent";
|
|
13
|
-
if (uri.startsWith("viking://user/"))
|
|
15
|
+
if (uri.startsWith("viking://user/") || uri === "viking://~" || uri.startsWith("viking://~/"))
|
|
14
16
|
return "user";
|
|
15
17
|
return undefined;
|
|
16
18
|
}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
const MEMORY_URI_PATTERNS = [
|
|
2
2
|
/^viking:\/\/user\/(?:[^/]+(?:\/agent\/[^/]+)?\/)?memories(?:\/|$)/,
|
|
3
3
|
/^viking:\/\/user\/[^/]+\/peers\/[^/]+\/memories(?:\/|$)/,
|
|
4
|
+
// viking://~ is the home alias for the caller's own user space. Configured targets and
|
|
5
|
+
// model-supplied URIs may use it; server responses stay canonical viking://user/<uid>/...
|
|
6
|
+
/^viking:\/\/~\/memories(?:\/|$)/,
|
|
7
|
+
/^viking:\/\/~\/peers\/[^/]+\/memories(?:\/|$)/,
|
|
4
8
|
/^viking:\/\/agent\/(?:[^/]+(?:\/user\/[^/]+)?\/)?memories(?:\/|$)/,
|
|
5
9
|
];
|
|
6
10
|
export function isMemoryUri(uri) {
|
package/memory-ranking.ts
CHANGED
|
@@ -232,8 +232,8 @@ function lexicalOverlapBoost(tokens: string[], text: string, maxBoost = DEFAULT_
|
|
|
232
232
|
function inferResourceType(item: FindResultItem): string | undefined {
|
|
233
233
|
if (item.uri.startsWith("viking://resources")) return "resource";
|
|
234
234
|
if (item.uri.startsWith("viking://session/")) return "session";
|
|
235
|
-
if (item.uri.startsWith("viking://user/skills") || item.uri.startsWith("viking://skills")) return "agent";
|
|
236
|
-
if (item.uri.startsWith("viking://user/")) return "user";
|
|
235
|
+
if (item.uri.startsWith("viking://user/skills") || item.uri.startsWith("viking://~/skills") || item.uri.startsWith("viking://skills")) return "agent";
|
|
236
|
+
if (item.uri.startsWith("viking://user/") || item.uri.startsWith("viking://~/")) return "user";
|
|
237
237
|
return undefined;
|
|
238
238
|
}
|
|
239
239
|
|
package/openclaw.plugin.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openviking/openclaw-plugin",
|
|
3
|
-
"version": "2026.8.
|
|
3
|
+
"version": "2026.8.21",
|
|
4
4
|
"displayName": "OpenViking",
|
|
5
5
|
"description": "OpenClaw context-engine plugin — OpenViking AI memory, long-term memory, knowledge base, semantic search, RAG, context engine. 长期记忆 · 知识库 · 语义检索 · 上下文引擎",
|
|
6
6
|
"type": "module",
|
|
@@ -386,7 +386,7 @@ export function createOpenVikingQueryRuntime<TQueryConfigContext>(deps: OpenViki
|
|
|
386
386
|
};
|
|
387
387
|
const [resourcesSettled, skillsSettled] = await Promise.allSettled([
|
|
388
388
|
runSearch("viking://resources"),
|
|
389
|
-
runSearch("viking
|
|
389
|
+
runSearch("viking://~/skills"),
|
|
390
390
|
]);
|
|
391
391
|
const successful: FindResult[] = [];
|
|
392
392
|
if (resourcesSettled.status === "fulfilled") {
|
|
@@ -120,8 +120,8 @@ function toLimitedInteger(value: unknown, fallback: number, min: number, max: nu
|
|
|
120
120
|
function inferUriType(uri: string): string {
|
|
121
121
|
if (uri.startsWith("viking://resources") || uri.startsWith("viking://resource")) return "resource";
|
|
122
122
|
if (uri.startsWith("viking://session/")) return "session";
|
|
123
|
-
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://skills")) return "skill";
|
|
124
|
-
if (uri.startsWith("viking://user/")) return "user_memory";
|
|
123
|
+
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://~/skills") || uri.startsWith("viking://skills")) return "skill";
|
|
124
|
+
if (uri.startsWith("viking://user/") || uri.startsWith("viking://~/")) return "user_memory";
|
|
125
125
|
if (uri.includes("/archive") || uri.includes("/history/")) return "archive";
|
|
126
126
|
return "unknown";
|
|
127
127
|
}
|
|
@@ -10,8 +10,10 @@ export function previewText(value: unknown, maxChars: number): string | undefine
|
|
|
10
10
|
|
|
11
11
|
export function inferRecallResourceType(uri: string): RecallResourceType | undefined {
|
|
12
12
|
if (uri.startsWith("viking://resources")) return "resource";
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
// viking://~ is the home alias for the caller's own user space; configured target
|
|
14
|
+
// URIs use it, while server responses come back canonical as viking://user/<uid>/...
|
|
15
|
+
if (uri.startsWith("viking://user/skills") || uri.startsWith("viking://~/skills") || uri.startsWith("viking://skills")) return "agent";
|
|
16
|
+
if (uri.startsWith("viking://user/") || uri === "viking://~" || uri.startsWith("viking://~/")) return "user";
|
|
15
17
|
return undefined;
|
|
16
18
|
}
|
|
17
19
|
|
package/routing/memory-uri.ts
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
const MEMORY_URI_PATTERNS = [
|
|
2
2
|
/^viking:\/\/user\/(?:[^/]+(?:\/agent\/[^/]+)?\/)?memories(?:\/|$)/,
|
|
3
3
|
/^viking:\/\/user\/[^/]+\/peers\/[^/]+\/memories(?:\/|$)/,
|
|
4
|
+
// viking://~ is the home alias for the caller's own user space. Configured targets and
|
|
5
|
+
// model-supplied URIs may use it; server responses stay canonical viking://user/<uid>/...
|
|
6
|
+
/^viking:\/\/~\/memories(?:\/|$)/,
|
|
7
|
+
/^viking:\/\/~\/peers\/[^/]+\/memories(?:\/|$)/,
|
|
4
8
|
/^viking:\/\/agent\/(?:[^/]+(?:\/user\/[^/]+)?\/)?memories(?:\/|$)/,
|
|
5
9
|
];
|
|
6
10
|
|
|
@@ -590,7 +590,7 @@ These are the keys under `plugins.entries.openviking.config` in `openclaw.json`.
|
|
|
590
590
|
| `peer_prefix` | `""` | Optional prefix for assistant `peer_id` / actor peer values when `peer_role=assistant`. Letters / digits / `_` / `-`. |
|
|
591
591
|
| `accountId` | — | Required when `apiKey` is a root key. |
|
|
592
592
|
| `userId` | — | Required when `apiKey` is a root key. |
|
|
593
|
-
| `targetUri` | `viking
|
|
593
|
+
| `targetUri` | `viking://~/memories` | Default search scope URI. |
|
|
594
594
|
| `timeoutMs` | (plugin default) | HTTP timeout for OpenViking calls. |
|
|
595
595
|
| `autoCapture` | `true` | Auto-append turn messages to the OpenViking session at `afterTurn`; extraction runs only after a threshold commit, `/compact`, or explicit `memory_store`. |
|
|
596
596
|
| `captureMode` | `"semantic"` | Filter mode used by the server-side extraction pipeline: `semantic` or `keyword`. |
|
|
@@ -67,7 +67,7 @@ Core config lives under `plugins.entries.openviking.config`:
|
|
|
67
67
|
| `peer_role` | `assistant` | Peer identity mode: `none`, `assistant`, or `person`. Session messages use body `peer_id`; data-plane recall/search uses `X-OpenViking-Actor-Peer`. |
|
|
68
68
|
| `peer_prefix` | empty | Optional prefix for assistant `peer_id` / actor peer values when `peer_role=assistant`. |
|
|
69
69
|
| `accountId` / `userId` | empty | Advanced tenant identity headers for root-key or trusted deployments. |
|
|
70
|
-
| `targetUri` | `viking
|
|
70
|
+
| `targetUri` | `viking://~/memories` | Default search scope for legacy targeted memory search. |
|
|
71
71
|
| `autoCapture` | `true` | Append sanitized turn text to OpenViking sessions. |
|
|
72
72
|
| `captureMode` | `semantic` | `semantic` or `keyword`; affects server-side extraction filtering. |
|
|
73
73
|
| `captureMaxLength` | `24000` | Max sanitized text length per captured turn. |
|
|
@@ -196,7 +196,7 @@ The current OpenClaw tool exposes the parameters above. The underlying client al
|
|
|
196
196
|
|
|
197
197
|
### `add_skill`
|
|
198
198
|
|
|
199
|
-
Import Agent Skills into `viking
|
|
199
|
+
Import Agent Skills into `viking://~/skills/...`.
|
|
200
200
|
|
|
201
201
|
| Parameter | Required | Description |
|
|
202
202
|
|---|---|---|
|
|
@@ -50,7 +50,7 @@ context or deeper intent analysis is useful.
|
|
|
50
50
|
3. Search only the current user's Experience root:
|
|
51
51
|
|
|
52
52
|
```text
|
|
53
|
-
viking
|
|
53
|
+
viking://~/memories/experiences
|
|
54
54
|
```
|
|
55
55
|
|
|
56
56
|
For tools using MCP-style parameters, set `target_uri` to this root. For
|