@mrclrchtr/supi-debug 11.4.0 → 12.0.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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [12.0.0]
|
|
4
|
+
|
|
5
|
+
- **Breaking:** `debug` rejects unknown parameters instead of ignoring them, and `limit` must be at least 1.
|
|
6
|
+
- The `level` and `operationId` schemas no longer send a stray `~optional` keyword to the provider.
|
|
7
|
+
- Codemode now lists the `debug` tool under a `debug` namespace heading, so scripts can find them with `describeNamespace("debug")` or `searchTools(query, { namespace: "debug" })`. It is annotated read-only ([#582](https://github.com/mrclrchtr/supi/issues/582)).
|
|
8
|
+
|
|
3
9
|
## [11.4.0]
|
|
4
10
|
|
|
5
11
|
- With Debug capture enabled, each session start, reload, resume, or fork records a `runtime-provenance` event with the package version and, when SuPi runs from its own Git checkout, the commit, commit time, and whether tracked files had uncommitted changes.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mrclrchtr/supi-debug",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "12.0.0",
|
|
4
4
|
"description": "Capture and inspect SuPi debug events",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"README.md"
|
|
36
36
|
],
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@mrclrchtr/supi-core": "
|
|
38
|
+
"@mrclrchtr/supi-core": "12.0.0"
|
|
39
39
|
},
|
|
40
40
|
"bundledDependencies": [
|
|
41
41
|
"@mrclrchtr/supi-core"
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { ExtensionAPI } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
import { DEBUG_TOOL_NAMESPACE } from "../namespace.ts";
|
|
2
3
|
import { promptGuidelines, promptSnippet, toolDescription } from "./guidance.ts";
|
|
3
4
|
import { renderDebugToolCall, renderDebugToolResult } from "./render.ts";
|
|
4
5
|
import { debugSpec } from "./spec.ts";
|
|
@@ -7,6 +8,7 @@ import { debugSpec } from "./spec.ts";
|
|
|
7
8
|
export function registerDebugTool(pi: ExtensionAPI): void {
|
|
8
9
|
pi.registerTool({
|
|
9
10
|
...debugSpec,
|
|
11
|
+
namespace: DEBUG_TOOL_NAMESPACE,
|
|
10
12
|
description: toolDescription,
|
|
11
13
|
promptSnippet,
|
|
12
14
|
promptGuidelines,
|
package/src/tool/debug/spec.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DebugLevel } from "@mrclrchtr/supi-core/debug";
|
|
1
2
|
import { Type } from "typebox";
|
|
2
3
|
import { makeDebugExecute } from "./execute.ts";
|
|
3
4
|
import { debugLevelSchema, debugOperationIdSchema } from "./input.ts";
|
|
@@ -10,22 +11,37 @@ export const DEBUG_TOOL_LABEL = "SuPi Debug";
|
|
|
10
11
|
export const debugSpec = {
|
|
11
12
|
name: DEBUG_TOOL_NAME,
|
|
12
13
|
label: DEBUG_TOOL_LABEL,
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
14
|
+
annotations: {
|
|
15
|
+
readOnlyHint: true,
|
|
16
|
+
destructiveHint: false,
|
|
17
|
+
idempotentHint: true,
|
|
18
|
+
openWorldHint: false,
|
|
19
|
+
},
|
|
20
|
+
parameters: Type.Object(
|
|
21
|
+
{
|
|
22
|
+
operationId: Type.Optional(
|
|
23
|
+
Type.String({
|
|
24
|
+
...debugOperationIdSchema,
|
|
25
|
+
description: "Filter by exact Debug Operation ID",
|
|
26
|
+
}),
|
|
27
|
+
),
|
|
28
|
+
source: Type.Optional(Type.String({ description: "Filter by extension source, e.g. lsp" })),
|
|
29
|
+
level: Type.Optional(
|
|
30
|
+
Type.Unsafe<DebugLevel>({ ...debugLevelSchema, description: "Filter by debug level" }),
|
|
31
|
+
),
|
|
32
|
+
category: Type.Optional(Type.String({ description: "Filter by event category" })),
|
|
33
|
+
limit: Type.Optional(
|
|
34
|
+
Type.Integer({ minimum: 1, description: "Maximum number of events to return" }),
|
|
35
|
+
),
|
|
36
|
+
sessionFile: Type.Optional(
|
|
37
|
+
Type.String({ description: "PI session JSONL file containing persisted debug events" }),
|
|
38
|
+
),
|
|
39
|
+
includeRaw: Type.Optional(
|
|
40
|
+
Type.Boolean({ description: "Request raw event data when settings permit it" }),
|
|
41
|
+
),
|
|
42
|
+
},
|
|
43
|
+
{ additionalProperties: false },
|
|
44
|
+
),
|
|
29
45
|
outputSchema: debugOutputSchema,
|
|
30
46
|
execute: makeDebugExecute(),
|
|
31
47
|
} as const;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ToolNamespace } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
|
|
3
|
+
/** Codemode namespace for the SuPi Debug tool. */
|
|
4
|
+
export const DEBUG_TOOL_NAMESPACE: ToolNamespace = {
|
|
5
|
+
name: "debug",
|
|
6
|
+
description: "SuPi debug event traces from the live session or a persisted session file.",
|
|
7
|
+
};
|