@howaboua/pi-durable-js-notebook 0.10.0 → 0.13.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.
@@ -1,4 +1,4 @@
1
- import { type Context } from "@earendil-works/chord";
1
+ import type { Context } from "@earendil-works/chord/context";
2
2
  import { type ToolExecutionApi } from "@earendil-works/pi-durable";
3
3
  import type { CellEngine } from "../../execution/src/cell-contract.ts";
4
4
  import type { NotebookControlRequest, NotebookControlResult } from "./runtime-contract.ts";
@@ -1,4 +1,4 @@
1
- import { type Context } from "@earendil-works/chord";
1
+ import type { Context } from "@earendil-works/chord/context";
2
2
  import { type Harness, type TaskId } from "@earendil-works/pi-durable";
3
3
  import { Type } from "typebox";
4
4
  import { type ShellRuntimeOptions } from "../../execution/src/shell.ts";
@@ -32,7 +32,7 @@ export declare function createJsNotebookMode(options: JsNotebookModeOptions): {
32
32
  prepareArguments?(args: unknown): {
33
33
  input?: string;
34
34
  };
35
- structuredOutputSchema?: Type.TSchema;
35
+ structuredOutputSchema?: object;
36
36
  callers?: readonly ("model" | "tools")[];
37
37
  deferred?: true;
38
38
  outputLimits?: {
@@ -42,7 +42,10 @@ export declare function createJsNotebookMode(options: JsNotebookModeOptions): {
42
42
  };
43
43
  execute(args: {
44
44
  input?: string;
45
- }, api: import("@earendil-works/pi-durable").ToolExecutionApi<import("@earendil-works/chord").JsonValue>, context: Context): Promise<import("@earendil-works/pi-durable").ToolExecutionResult<import("@earendil-works/chord").JsonValue>>;
45
+ }, api: import("@earendil-works/pi-durable").ToolExecutionApi<import("@earendil-works/chord/json").JsonValue, import("@earendil-works/chord/json").JsonValue>, context: Context): Promise<import("@earendil-works/pi-durable").ToolExecutionResult<import("@earendil-works/chord/json").JsonValue> | import("@earendil-works/pi-durable").ToolPark<import("@earendil-works/chord/json").JsonValue>>;
46
+ cancel?(args: {
47
+ input?: string;
48
+ }, api: import("@earendil-works/pi-durable").ToolExecutionApi<import("@earendil-works/chord/json").JsonValue, import("@earendil-works/chord/json").JsonValue>, context: Context): Promise<void>;
46
49
  executionHints: {
47
50
  discovery: "help";
48
51
  };
@@ -25,6 +25,7 @@ export interface ToolExecutionContext {
25
25
  onYield?: (() => Promise<void>) | undefined;
26
26
  }
27
27
  export interface NotebookToolDefinition {
28
+ hidden?: boolean;
28
29
  name: string;
29
30
  description: string;
30
31
  usage: string;
@@ -1,3 +1,4 @@
1
+ import type { JsToolNamespace } from "../../execution/src/tool-namespaces.ts";
1
2
  import type { NotebookStorageRetention } from "./storage-retention.ts";
2
3
  export interface NotebookSessionContext {
3
4
  cwd: string;
@@ -32,6 +33,8 @@ export interface NotebookToolIdentity {
32
33
  namespace?: string | undefined;
33
34
  }
34
35
  export interface NotebookToolDefinition {
36
+ hidden?: boolean;
37
+ jsNamespace?: JsToolNamespace;
35
38
  name: string;
36
39
  description: string;
37
40
  usage: string;
@@ -1,13 +1,14 @@
1
- import { type Context } from "@earendil-works/chord";
1
+ import type { Context } from "@earendil-works/chord/context";
2
2
  import { type TaskId, type ToolExecutionApi } from "@earendil-works/pi-durable";
3
3
  import type { CellObservation } from "../../execution/src/cell-contract.ts";
4
4
  export declare function notebookCellTaskId(value: string): TaskId<import("@earendil-works/pi-durable").ToolExecutionResult>;
5
5
  export declare function observeNotebookCell(observation: CellObservation, maxTokens: number, api: ToolExecutionApi, context: Context): Promise<import("@earendil-works/pi-durable").ToolExecutionResult | {
6
- structuredOutput?: import("@earendil-works/chord").JsonValue;
6
+ structuredOutput?: import("@earendil-works/chord/json").JsonValue;
7
7
  isError?: boolean;
8
8
  diagnostics?: readonly import("@earendil-works/pi-durable").ToolDiagnostic[];
9
9
  usage?: import("@earendil-works/pi-ai").Usage;
10
10
  control?: import("@earendil-works/pi-durable").ToolControl;
11
+ kind?: never;
11
12
  output: (import("@earendil-works/pi-ai").ImageContent | {
12
13
  type: "text";
13
14
  text: string;
@@ -15,7 +16,7 @@ export declare function observeNotebookCell(observation: CellObservation, maxTok
15
16
  details: {
16
17
  cell_id: string;
17
18
  status: "aborted" | "completed" | "failed" | "interrupted" | "running";
18
- forwardedToolCalls?: import("@earendil-works/chord").JsonValue;
19
- runtime?: import("@earendil-works/chord").JsonValue;
19
+ forwardedToolCalls?: import("@earendil-works/chord/json").JsonValue;
20
+ runtime?: import("@earendil-works/chord/json").JsonValue;
20
21
  };
21
22
  }>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@howaboua/pi-durable-js-notebook",
3
- "version": "0.10.0",
3
+ "version": "0.13.0",
4
4
  "description": "Persistent QuickJS notebook and shell tools for Pi Durable",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -38,18 +38,19 @@
38
38
  "sideEffects": false,
39
39
  "dependencies": {
40
40
  "node-pty": "1.1.0",
41
- "smol-toml": "1.9.0",
42
- "typebox": "1.3.27",
41
+ "smol-toml": "1.9.1",
42
+ "typebox": "1.4.7",
43
43
  "acorn": "8.19.0",
44
44
  "quickjs-wasi": "3.6.3",
45
- "@earendil-works/pi-codemode": "1.4.0",
46
- "@howaboua/pi-durable-components": "0.10.0"
45
+ "@earendil-works/pi-codemode": "1.8.0",
46
+ "@howaboua/pi-durable-components": "0.13.0",
47
+ "@earendil-works/pi-schema": "1.8.0"
47
48
  },
48
49
  "peerDependencies": {
49
- "@earendil-works/chord": "1.4.0",
50
- "@earendil-works/pi-ai": "1.4.0",
51
- "@earendil-works/pi-durable": "1.4.0",
52
- "@modelcontextprotocol/sdk": ">=1.25.2 <2"
50
+ "@earendil-works/chord": "1.8.0",
51
+ "@earendil-works/pi-ai": "1.8.0",
52
+ "@earendil-works/pi-durable": "1.8.0",
53
+ "@modelcontextprotocol/sdk": ">=1.32.2 <2"
53
54
  },
54
55
  "publishConfig": {
55
56
  "access": "public"