@omercnet/paseo-context-mode 2.0.1 → 2.0.2-next.260.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/OVERVIEW.md +1 -1
- package/README.md +2 -2
- package/npm-shrinkwrap.json +14 -14
- package/package.json +6 -6
- package/paseo-plugin.json +1 -1
- package/server/handlers.ts +26 -5
package/OVERVIEW.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
Context Mode connects Paseo agents to [Context Mode](https://github.com/mksglu/context-mode), a separate tool that runs as an MCP server and gives agents tools for indexing and searching project knowledge. The plugin bundles Context Mode 1.0.169 and adds a screen with health, savings, and a knowledge search and indexing panel. It supports the Claude, Codex, Copilot, Cursor, OpenCode, Pi, and OMP providers and leaves others unchanged. It needs Paseo `^0.11.0` and Node.js 24 or later on the daemon host.
|
|
1
|
+
Context Mode connects Paseo agents to [Context Mode](https://github.com/mksglu/context-mode), a separate tool that runs as an MCP server and gives agents tools for indexing and searching project knowledge. The plugin bundles Context Mode 1.0.169 and adds a screen with health, savings, and a knowledge search and indexing panel. It supports the Claude, Codex, Copilot, Cursor, OpenCode, Pi, and OMP providers and leaves others unchanged. It needs Paseo `^0.11.0 || ^0.12.0` and Node.js 24 or later on the daemon host.
|
|
2
2
|
|
|
3
3
|
By default, creating a supported agent adds a Context Mode MCP server to it. Existing agents do not get the server, and opening or resuming a session only sets two environment variables that name the provider and its data folder, with a separate folder per provider. Turning off automatic activation stops the plugin adding these from then on, and it does not remove them from agents that already have them. A server you configured yourself is kept. By default the plugin also reads each provider's config files and skips its own addition when Context Mode is already registered there.
|
|
4
4
|
|
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ These previews were captured from an isolated Paseo test daemon with Context Mod
|
|
|
22
22
|
|
|
23
23
|
- Bundles Context Mode as a runtime dependency; a separately installed global executable remains optional.
|
|
24
24
|
- Resolves a configured absolute executable first, then the daemon's `PATH`, then the bundled runtime.
|
|
25
|
-
- Shows Context Mode version, structured diagnostics, provider activation, storage roots, lifetime savings, activity, categories, and indexed sources. Savings lists the built-in harness storage plus the storage of every provider configured in Paseo (including ones derived with `extends`), the latter under its Paseo provider id and the root its own `env` resolves to. `ctx_stats` and the Setup tab
|
|
25
|
+
- Shows Context Mode version, structured diagnostics, provider activation, storage roots, lifetime savings, activity, categories, and indexed sources. Savings lists the built-in harness storage plus the storage of every provider configured in Paseo (including ones derived with `extends`), the latter under its Paseo provider id and the root its own `env` resolves to. `ctx_stats` and the Setup tab run against a plugin-owned probe store (`<PASEO_HOME>/plugin-data/context-mode/probe`) so they never write into a provider root; it starts empty.
|
|
26
26
|
- Reads Context Mode 1.0.169 SQLite databases in query-only mode, honors active WAL state, isolates corrupt databases, and reports partial coverage instead of mutating schemas.
|
|
27
27
|
- Injects the bundled stdio MCP server into new supported agents through Paseo's `agent.create` hook.
|
|
28
28
|
- Injects provider identity and an existing provider-specific storage root on create, resume, refresh, and import.
|
|
@@ -57,7 +57,7 @@ Update an npm installation to the latest published release:
|
|
|
57
57
|
paseo plugin update context-mode
|
|
58
58
|
```
|
|
59
59
|
|
|
60
|
-
The npm install and update flow requires Paseo `^0.11.0` with npm available on the daemon host.
|
|
60
|
+
The npm install and update flow requires Paseo `^0.11.0 || ^0.12.0` with npm available on the daemon host.
|
|
61
61
|
|
|
62
62
|
|
|
63
63
|
## Commands and limits
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@omercnet/paseo-context-mode",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.2",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@omercnet/paseo-context-mode",
|
|
9
|
-
"version": "2.0.
|
|
9
|
+
"version": "2.0.2",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"context-mode": "1.0.169"
|
|
12
12
|
}
|
|
@@ -40,9 +40,9 @@
|
|
|
40
40
|
}
|
|
41
41
|
},
|
|
42
42
|
"node_modules/@hono/node-server": {
|
|
43
|
-
"version": "2.1.
|
|
44
|
-
"resolved": "https://registry.npmjs.org/@hono/node-server/-/node-server-2.1.
|
|
45
|
-
"integrity": "sha512-
|
|
43
|
+
"version": "2.1.5",
|
|
44
|
+
"resolved": "https://registry.npmjs.org/@hono/node-server/-/node-server-2.1.5.tgz",
|
|
45
|
+
"integrity": "sha512-MgP/I06GdvsilDspMk/qmRzpk8LOUStP6jFAbSRi40W09DhoyUn+Mj7eyKICPqeYKybOjVFLVIAQzvu1bfIa7Q==",
|
|
46
46
|
"license": "MIT",
|
|
47
47
|
"engines": {
|
|
48
48
|
"node": ">=20"
|
|
@@ -906,9 +906,9 @@
|
|
|
906
906
|
"license": "ISC"
|
|
907
907
|
},
|
|
908
908
|
"node_modules/ip-address": {
|
|
909
|
-
"version": "10.7.
|
|
910
|
-
"resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.7.
|
|
911
|
-
"integrity": "sha512-
|
|
909
|
+
"version": "10.7.4",
|
|
910
|
+
"resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.7.4.tgz",
|
|
911
|
+
"integrity": "sha512-DWBMKyeM25D70nrIiTkgQth59/G+naKOTep6huF9j+GmeK3DMD60Zvxg5d5qQnz+38AHgou6ean2LECX+lrKDg==",
|
|
912
912
|
"license": "MIT",
|
|
913
913
|
"engines": {
|
|
914
914
|
"node": ">= 12"
|
|
@@ -1084,9 +1084,9 @@
|
|
|
1084
1084
|
}
|
|
1085
1085
|
},
|
|
1086
1086
|
"node_modules/node-abi": {
|
|
1087
|
-
"version": "3.
|
|
1088
|
-
"resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.
|
|
1089
|
-
"integrity": "sha512-
|
|
1087
|
+
"version": "3.99.0",
|
|
1088
|
+
"resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.99.0.tgz",
|
|
1089
|
+
"integrity": "sha512-lLdwkeg2XUVPTHqWjPltTxH81zbQNbUWC+AEb9ni50KjxkUzAAx1HGtMT21sbntzfUGfIphhcklvs3imJeqDXw==",
|
|
1090
1090
|
"license": "MIT",
|
|
1091
1091
|
"dependencies": {
|
|
1092
1092
|
"semver": "^7.3.5"
|
|
@@ -1235,9 +1235,9 @@
|
|
|
1235
1235
|
}
|
|
1236
1236
|
},
|
|
1237
1237
|
"node_modules/qs": {
|
|
1238
|
-
"version": "6.16.
|
|
1239
|
-
"resolved": "https://registry.npmjs.org/qs/-/qs-6.16.
|
|
1240
|
-
"integrity": "sha512-
|
|
1238
|
+
"version": "6.16.1",
|
|
1239
|
+
"resolved": "https://registry.npmjs.org/qs/-/qs-6.16.1.tgz",
|
|
1240
|
+
"integrity": "sha512-5Px6J7rfHBAGUhNQ3es4YzcOdBBw0SDcVtThJml4RdnKw4tKs2epA0kPZ+K8X+WiHktT93RHVcQ/3ym5aTCgtg==",
|
|
1241
1241
|
"license": "BSD-3-Clause",
|
|
1242
1242
|
"dependencies": {
|
|
1243
1243
|
"es-define-property": "^1.0.1",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@omercnet/paseo-context-mode",
|
|
3
|
-
"version": "2.0.1",
|
|
3
|
+
"version": "2.0.2-next.260.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Provider-aware Context Mode health, savings, and MCP activation for Paseo.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"publishConfig": {
|
|
18
18
|
"access": "public"
|
|
19
19
|
},
|
|
20
|
-
"packageManager": "bun@1.4.
|
|
20
|
+
"packageManager": "bun@1.4.3",
|
|
21
21
|
"engines": {
|
|
22
22
|
"node": ">=24"
|
|
23
23
|
},
|
|
@@ -52,10 +52,10 @@
|
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"@biomejs/biome": "^2.5.10",
|
|
55
|
-
"@getpaseo/cli": "0.
|
|
56
|
-
"@getpaseo/client": "0.
|
|
57
|
-
"@getpaseo/plugin": "0.
|
|
58
|
-
"@getpaseo/protocol": "0.
|
|
55
|
+
"@getpaseo/cli": "0.12.0-beta.2",
|
|
56
|
+
"@getpaseo/client": "0.12.0-beta.2",
|
|
57
|
+
"@getpaseo/plugin": "0.12.0-beta.2",
|
|
58
|
+
"@getpaseo/protocol": "0.12.0-beta.2",
|
|
59
59
|
"@tanstack/react-query": "^5.102.3",
|
|
60
60
|
"@types/node": "^24.10.1",
|
|
61
61
|
"@types/react": "^19.2.18",
|
package/paseo-plugin.json
CHANGED
package/server/handlers.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { homedir } from "node:os";
|
|
2
|
+
import { join } from "node:path";
|
|
1
3
|
import type { PluginSettings } from "@getpaseo/plugin/server";
|
|
2
4
|
import type {
|
|
3
5
|
BinaryStatus,
|
|
@@ -25,11 +27,29 @@ type SettingsHandle = PluginSettings<typeof contextModeSettings.schema>;
|
|
|
25
27
|
type ToolName = "ctx_doctor" | "ctx_stats";
|
|
26
28
|
type FailureReport = Extract<CommandReport, { state: "unavailable" }>;
|
|
27
29
|
|
|
30
|
+
interface ProbeOptions {
|
|
31
|
+
env: NodeJS.ProcessEnv;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Panel probes belong to no provider. Without an explicit storage root Context Mode falls back to
|
|
36
|
+
* whichever provider config directory exists, and writes its sidecar and content store there.
|
|
37
|
+
*/
|
|
38
|
+
function contextModeProbeOptions(env: NodeJS.ProcessEnv = process.env): ProbeOptions {
|
|
39
|
+
const home = env.PASEO_HOME?.trim() || join(homedir(), ".paseo");
|
|
40
|
+
return { env: { CONTEXT_MODE_DIR: join(home, "plugin-data", "context-mode", "probe") } };
|
|
41
|
+
}
|
|
42
|
+
|
|
28
43
|
export interface ContextModeHandlerDependencies {
|
|
29
44
|
now?: () => Date;
|
|
30
45
|
resolveBinary?: (settings: ContextModeSettings) => Promise<BinaryResolution>;
|
|
31
|
-
inspect?: (launch: LaunchDescriptor) => Promise<McpInspection>;
|
|
32
|
-
callTool?: (
|
|
46
|
+
inspect?: (launch: LaunchDescriptor, options: ProbeOptions) => Promise<McpInspection>;
|
|
47
|
+
callTool?: (
|
|
48
|
+
launch: LaunchDescriptor,
|
|
49
|
+
name: ToolName,
|
|
50
|
+
arguments_: Record<string, never>,
|
|
51
|
+
options: ProbeOptions,
|
|
52
|
+
) => Promise<string>;
|
|
33
53
|
createAudit?: (
|
|
34
54
|
settings: ContextModeSettings,
|
|
35
55
|
runtime: { path: string; version: string | null },
|
|
@@ -71,6 +91,7 @@ export function createContextModeHandlers(
|
|
|
71
91
|
const callTool = dependencies.callTool ?? callContextModeTool;
|
|
72
92
|
const buildAudit = dependencies.createAudit ?? createIntegrationAudit;
|
|
73
93
|
const cache = new Map<string, CacheEntry<BinaryStatus | CommandReport>>();
|
|
94
|
+
const probe = contextModeProbeOptions();
|
|
74
95
|
|
|
75
96
|
async function settingsAndBinary(): Promise<
|
|
76
97
|
| {
|
|
@@ -145,7 +166,7 @@ export function createContextModeHandlers(
|
|
|
145
166
|
return cached(cacheKey, 10_000, fresh, async () => {
|
|
146
167
|
const checkedAt = now().toISOString();
|
|
147
168
|
try {
|
|
148
|
-
const inspection = await inspect(resolved.binary.launch);
|
|
169
|
+
const inspection = await inspect(resolved.binary.launch, probe);
|
|
149
170
|
return {
|
|
150
171
|
state: "ready",
|
|
151
172
|
binaryPath: resolved.binary.path,
|
|
@@ -170,7 +191,7 @@ export function createContextModeHandlers(
|
|
|
170
191
|
return {
|
|
171
192
|
state: "ready",
|
|
172
193
|
binaryPath: resolved.binary.path,
|
|
173
|
-
output: await callTool(resolved.binary.launch, name),
|
|
194
|
+
output: await callTool(resolved.binary.launch, name, {}, probe),
|
|
174
195
|
checkedAt,
|
|
175
196
|
};
|
|
176
197
|
} catch (error) {
|
|
@@ -193,7 +214,7 @@ export function createContextModeHandlers(
|
|
|
193
214
|
checkedAt: resolved.report.checkedAt,
|
|
194
215
|
};
|
|
195
216
|
}
|
|
196
|
-
const inspection = await inspect(resolved.binary.launch).catch(() => ({
|
|
217
|
+
const inspection = await inspect(resolved.binary.launch, probe).catch(() => ({
|
|
197
218
|
version: null,
|
|
198
219
|
tools: [],
|
|
199
220
|
}));
|