rice-node-sdk 1.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/README.md ADDED
@@ -0,0 +1,270 @@
1
+ # Rice Node SDK
2
+
3
+ Unified Node.js/TypeScript SDK for RiceDB (Persistent Semantic Database) and State (AI Memory).
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install rice-node-sdk
9
+ ```
10
+
11
+ ## Quick Start
12
+
13
+ The SDK provides a unified `Client` to access both Storage and State services.
14
+
15
+ ```typescript
16
+ import { Client } from "rice-node-sdk";
17
+
18
+ // Initialize client (loads config from rice.config.js and .env)
19
+ const client = new Client();
20
+ await client.connect();
21
+
22
+ // --- Storage (RiceDB) ---
23
+ // Insert data
24
+ await client.storage.insert(
25
+ "unique-node-id",
26
+ "This is a piece of information stored in RiceDB.",
27
+ { category: "example", value: 123 }
28
+ );
29
+
30
+ // Search for similar data
31
+ const results = await client.storage.search("information stored", 1, 5);
32
+ console.log(results);
33
+
34
+ // --- State (AI Memory) ---
35
+ // Focus on a context/task
36
+ await client.state.focus("User is asking about weather");
37
+
38
+ // Store a long-term memory (commit)
39
+ await client.state.commit(
40
+ "The user prefers metric units for temperature.",
41
+ "User preference noted.",
42
+ {
43
+ source: "conversation",
44
+ }
45
+ );
46
+
47
+ // Recall relevant memories
48
+ const memories = await client.state.reminisce("weather preferences");
49
+ console.log(memories);
50
+ ```
51
+
52
+ ## Configuration
53
+
54
+ The SDK loads configuration from `rice.config.js` (or `.ts`/`.mjs`), environment variables, and constructor options.
55
+
56
+ ### 1. Configuration File (`rice.config.js`)
57
+
58
+ Control which services are enabled. Useful for applications that only need Storage or only need State.
59
+
60
+ ```javascript
61
+ /** @type {import('rice-node-sdk').RiceConfig} */
62
+ module.exports = {
63
+ // Enable/Disable Storage (RiceDB)
64
+ storage: {
65
+ enabled: true, // Set to false if you only use State
66
+ },
67
+ // Enable/Disable State (Memory)
68
+ state: {
69
+ enabled: true, // Set to false if you only use Storage
70
+ },
71
+ };
72
+ ```
73
+
74
+ ### 2. Environment Variables (`.env`)
75
+
76
+ Configure connection details and authentication.
77
+
78
+ ```bash
79
+ # --- Storage (RiceDB) ---
80
+ # URL of your RiceDB instance (default: localhost:50051)
81
+ STORAGE_INSTANCE_URL=localhost:50051
82
+ # Auth token (if enabled on server)
83
+ STORAGE_AUTH_TOKEN=my-secret-token
84
+ # User for auto-login (default: admin)
85
+ STORAGE_USER=admin
86
+
87
+ # --- State (Memory) ---
88
+ # URL of your State instance
89
+ STATE_INSTANCE_URL=localhost:50051
90
+ # Auth token
91
+ STATE_AUTH_TOKEN=my-secret-token
92
+ # Default Run ID for memory sessions (optional)
93
+ STATE_RUN_ID=default-run-id
94
+
95
+ # --- LLM Providers (for examples) ---
96
+ ANTHROPIC_API_KEY=sk-ant-...
97
+ OPENAI_API_KEY=sk-...
98
+ GOOGLE_API_KEY=...
99
+ ```
100
+
101
+ ### 3. Advanced Configuration
102
+
103
+ #### Custom Config Path
104
+
105
+ You can load a specific config file by passing the path to the `Client` constructor.
106
+
107
+ ```typescript
108
+ const client = new Client({ configPath: "./config/prod.rice.config.js" });
109
+ ```
110
+
111
+ #### Managing Run IDs (Multi-User/Multi-Agent)
112
+
113
+ For State memory, the `runId` determines the session or agent context. You can switch run IDs dynamically to manage memory for different users or agents.
114
+
115
+ ```typescript
116
+ // Option A: Set globally in constructor
117
+ const client = new Client({ runId: "user-123-session" });
118
+
119
+ // Option B: Switch dynamically
120
+ client.state.setRunId("user-456-session");
121
+ await client.state.focus("New task for user 456");
122
+ ```
123
+
124
+ ## AI Tool Definitions
125
+
126
+ The SDK provides pre-built tool definitions tailored for popular LLM providers. These tools map directly to State memory operations.
127
+
128
+ ### Available Imports
129
+
130
+ - `rice-node-sdk/tools/anthropic`
131
+ - `rice-node-sdk/tools/google`
132
+ - `rice-node-sdk/tools/openai`
133
+
134
+ ### Example Usage (Anthropic)
135
+
136
+ ```typescript
137
+ import { state as anthropicTools } from "rice-node-sdk/tools/anthropic";
138
+ import { executeTool } from "rice-node-sdk/tools/execute";
139
+ import { Client } from "rice-node-sdk";
140
+
141
+ const client = new Client();
142
+ await client.connect();
143
+
144
+ // 1. Pass tools to your LLM
145
+ const response = await anthropic.messages.create({
146
+ model: "claude-3-opus-20240229",
147
+ tools: anthropicTools,
148
+ // ...
149
+ });
150
+
151
+ // 2. Execute tools invoked by the LLM
152
+ for (const toolUse of response.content.filter((c) => c.type === "tool_use")) {
153
+ const result = await executeTool(client.state, toolUse.name, toolUse.input);
154
+ console.log("Tool result:", result);
155
+ }
156
+ ```
157
+
158
+ ### Example Usage (OpenAI)
159
+
160
+ ```typescript
161
+ import { state as openaiTools } from "rice-node-sdk/tools/openai";
162
+ import { executeTool } from "rice-node-sdk/tools/execute";
163
+ import { Client } from "rice-node-sdk";
164
+
165
+ const client = new Client();
166
+ await client.connect();
167
+
168
+ // 1. Pass tools to OpenAI
169
+ const response = await openai.chat.completions.create({
170
+ model: "gpt-4",
171
+ messages: [
172
+ /* ... */
173
+ ],
174
+ tools: openaiTools, // Tools are already in OpenAI format
175
+ });
176
+
177
+ // 2. Execute tools
178
+ const toolCalls = response.choices[0].message.tool_calls;
179
+ if (toolCalls) {
180
+ for (const toolCall of toolCalls) {
181
+ const args = JSON.parse(toolCall.function.arguments);
182
+ const result = await executeTool(
183
+ client.state,
184
+ toolCall.function.name,
185
+ args
186
+ );
187
+ console.log("Tool result:", result);
188
+ }
189
+ }
190
+ ```
191
+
192
+ ### Example Usage (Google Gemini)
193
+
194
+ ```typescript
195
+ import { state as googleTools } from "rice-node-sdk/tools/google";
196
+ import { executeTool } from "rice-node-sdk/tools/execute";
197
+ import { Client } from "rice-node-sdk";
198
+
199
+ const client = new Client();
200
+ await client.connect();
201
+
202
+ // 1. Pass tools to Gemini
203
+ const model = genAI.getGenerativeModel({
204
+ model: "gemini-3-flash-preview",
205
+ tools: [{ functionDeclarations: googleTools }],
206
+ });
207
+
208
+ // 2. Execute tools
209
+ const chat = model.startChat();
210
+ const result = await chat.sendMessage("Remember that I like pizza.");
211
+ const call = result.response.functionCalls()?.[0];
212
+
213
+ if (call) {
214
+ const result = await executeTool(client.state, call.name, call.args);
215
+ console.log("Tool result:", result);
216
+ }
217
+ ```
218
+
219
+ ### Tools Included
220
+
221
+ | Tool | Purpose | SDK Method |
222
+ | ---------- | ------------------------------------------------ | -------------------------- |
223
+ | `focus` | Store information in short-term working memory | `client.state.focus()` |
224
+ | `remember` | Store information in long-term persistent memory | `client.state.commit()` |
225
+ | `recall` | Retrieve relevant memories from long-term memory | `client.state.reminisce()` |
226
+
227
+ > **Note**: The `remember` tool provided to LLMs maps to the `commit` method in the SDK.
228
+
229
+ ## API Reference
230
+
231
+ ### Client
232
+
233
+ ```typescript
234
+ class Client {
235
+ constructor(options?: { configPath?: string; runId?: string });
236
+ async connect(): Promise<void>;
237
+ get storage(): RiceDBClient;
238
+ get state(): StateClient;
239
+ }
240
+ ```
241
+
242
+ ### Storage (RiceDB)
243
+
244
+ ```typescript
245
+ interface RiceDBClient {
246
+ insert(id: string, text: string, metadata?: object): Promise<void>;
247
+ search(
248
+ query: string,
249
+ limit?: number,
250
+ offset?: number
251
+ ): Promise<SearchResult[]>;
252
+ delete(id: string): Promise<void>;
253
+ // ... graph operations
254
+ }
255
+ ```
256
+
257
+ ### State (Memory)
258
+
259
+ ```typescript
260
+ interface StateClient {
261
+ focus(content: string): Promise<void>;
262
+ commit(input: string, output: string, metadata?: object): Promise<void>;
263
+ reminisce(query: string): Promise<string[]>;
264
+ setRunId(runId: string): void;
265
+ }
266
+ ```
267
+
268
+ ## License
269
+
270
+ ISC
@@ -0,0 +1,16 @@
1
+ import { RiceDBClient } from "./storage/client/RiceDBClient";
2
+ import { StateClient } from "./state";
3
+ export interface ClientOptions {
4
+ configPath?: string;
5
+ runId?: string;
6
+ }
7
+ export declare class Client {
8
+ private _config;
9
+ private _storage;
10
+ private _state;
11
+ private options;
12
+ constructor(optionsOrPath?: string | ClientOptions);
13
+ connect(): Promise<void>;
14
+ get storage(): RiceDBClient;
15
+ get state(): StateClient;
16
+ }
package/dist/Client.js ADDED
@@ -0,0 +1,117 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.Client = void 0;
37
+ const config_1 = require("./config");
38
+ const RiceDBClient_1 = require("./storage/client/RiceDBClient");
39
+ const state_1 = require("./state");
40
+ const dotenv = __importStar(require("dotenv"));
41
+ const path = __importStar(require("path"));
42
+ class Client {
43
+ constructor(optionsOrPath) {
44
+ this._config = null;
45
+ this._storage = null;
46
+ this._state = null;
47
+ if (typeof optionsOrPath === "string") {
48
+ this.options = { configPath: optionsOrPath };
49
+ }
50
+ else {
51
+ this.options = optionsOrPath || {};
52
+ }
53
+ }
54
+ async connect() {
55
+ // Load environment variables
56
+ dotenv.config({ path: path.resolve(process.cwd(), ".env") });
57
+ // Load config
58
+ this._config = await (0, config_1.loadConfig)(this.options.configPath);
59
+ // Initialize Storage
60
+ if (this._config.storage?.enabled) {
61
+ const storageUrl = process.env.STORAGE_INSTANCE_URL ||
62
+ process.env.RICEDB_HOST ||
63
+ "localhost:50051";
64
+ // Parse host and port
65
+ let host = "localhost";
66
+ let port = 50051;
67
+ const parts = storageUrl.split(":");
68
+ if (parts.length === 2) {
69
+ host = parts[0];
70
+ port = parseInt(parts[1], 10);
71
+ }
72
+ else {
73
+ host = storageUrl;
74
+ }
75
+ const token = process.env.STORAGE_AUTH_TOKEN;
76
+ const user = process.env.STORAGE_USER || "admin";
77
+ // We assume STORAGE_INSTANCE_URL points to the gRPC port
78
+ // Pass token to constructor initially (if it's a valid token, it works; if it's a password, we login)
79
+ this._storage = new RiceDBClient_1.RiceDBClient(host, "auto", port, 3000, token);
80
+ await this._storage.connect();
81
+ if (token) {
82
+ try {
83
+ // Attempt auto-login using the token as password
84
+ console.log(`Attempting login for user ${user}...`);
85
+ const newToken = await this._storage.login(user, token);
86
+ console.log(`Login successful. Token length: ${newToken.length}`);
87
+ }
88
+ catch (e) {
89
+ // If login fails, maybe the token was already a valid session token?
90
+ // Or credentials are wrong. We log warning but don't crash,
91
+ // allowing subsequent calls to fail if auth is missing.
92
+ console.warn(`Auto-login failed for user ${user}:`, e);
93
+ }
94
+ }
95
+ }
96
+ // Initialize State
97
+ if (this._config.state?.enabled) {
98
+ const address = process.env.STATE_INSTANCE_URL || "localhost:50051";
99
+ const token = process.env.STATE_AUTH_TOKEN;
100
+ const runId = this.options.runId || process.env.STATE_RUN_ID || "default";
101
+ this._state = new state_1.StateClient(address, token, runId);
102
+ }
103
+ }
104
+ get storage() {
105
+ if (!this._storage) {
106
+ throw new Error("Config mismatch: storage is not enabled or not connected");
107
+ }
108
+ return this._storage;
109
+ }
110
+ get state() {
111
+ if (!this._state) {
112
+ throw new Error("Config mismatch: state is not enabled or not connected");
113
+ }
114
+ return this._state;
115
+ }
116
+ }
117
+ exports.Client = Client;
@@ -0,0 +1,13 @@
1
+ export interface RiceConfig {
2
+ storage?: {
3
+ enabled: boolean;
4
+ };
5
+ state?: {
6
+ enabled: boolean;
7
+ llm_mode?: boolean;
8
+ flux?: {
9
+ enabled: boolean;
10
+ };
11
+ };
12
+ }
13
+ export declare function loadConfig(configPath?: string): Promise<RiceConfig>;
package/dist/config.js ADDED
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.loadConfig = loadConfig;
37
+ const path = __importStar(require("path"));
38
+ const fs = __importStar(require("fs"));
39
+ async function loadConfig(configPath) {
40
+ const defaultPath = path.resolve(process.cwd(), "rice.config.js");
41
+ const filePath = configPath ? path.resolve(configPath) : defaultPath;
42
+ if (!fs.existsSync(filePath)) {
43
+ throw new Error(`Config file not found at ${filePath}`);
44
+ }
45
+ try {
46
+ // Dynamic import to support both ESM and CJS if environment allows
47
+ const configModule = await Promise.resolve(`${filePath}`).then(s => __importStar(require(s)));
48
+ return configModule.default || configModule;
49
+ }
50
+ catch (error) {
51
+ throw new Error(`Failed to load config from ${filePath}: ${error}`);
52
+ }
53
+ }
@@ -0,0 +1,110 @@
1
+ /**
2
+ * Rice Node SDK
3
+ * Unified client for RiceDB (Storage) and State (AI Memory).
4
+ */
5
+ import { Client } from "./Client";
6
+ export * from "./storage";
7
+ export * from "./state";
8
+ export * from "./Client";
9
+ export * from "./config";
10
+ export * from "./state/tools";
11
+ declare const _default: {
12
+ Client: typeof Client;
13
+ statetool: {
14
+ google: ({
15
+ name: string;
16
+ description: string;
17
+ parameters: {
18
+ type: string;
19
+ properties: {
20
+ content: {
21
+ type: string;
22
+ description: string;
23
+ };
24
+ query?: undefined;
25
+ };
26
+ required: string[];
27
+ };
28
+ } | {
29
+ name: string;
30
+ description: string;
31
+ parameters: {
32
+ type: string;
33
+ properties: {
34
+ query: {
35
+ type: string;
36
+ description: string;
37
+ };
38
+ content?: undefined;
39
+ };
40
+ required: string[];
41
+ };
42
+ })[];
43
+ openai: ({
44
+ type: string;
45
+ function: {
46
+ name: string;
47
+ description: string;
48
+ parameters: {
49
+ type: string;
50
+ properties: {
51
+ content: {
52
+ type: string;
53
+ description: string;
54
+ };
55
+ query?: undefined;
56
+ };
57
+ required: string[];
58
+ };
59
+ };
60
+ } | {
61
+ type: string;
62
+ function: {
63
+ name: string;
64
+ description: string;
65
+ parameters: {
66
+ type: string;
67
+ properties: {
68
+ query: {
69
+ type: string;
70
+ description: string;
71
+ };
72
+ content?: undefined;
73
+ };
74
+ required: string[];
75
+ };
76
+ };
77
+ })[];
78
+ anthropic: ({
79
+ name: string;
80
+ description: string;
81
+ input_schema: {
82
+ type: string;
83
+ properties: {
84
+ content: {
85
+ type: string;
86
+ description: string;
87
+ };
88
+ query?: undefined;
89
+ };
90
+ required: string[];
91
+ };
92
+ } | {
93
+ name: string;
94
+ description: string;
95
+ input_schema: {
96
+ type: string;
97
+ properties: {
98
+ query: {
99
+ type: string;
100
+ description: string;
101
+ };
102
+ content?: undefined;
103
+ };
104
+ required: string[];
105
+ };
106
+ })[];
107
+ execute: typeof import("./tools/execute").execute;
108
+ };
109
+ };
110
+ export default _default;
package/dist/index.js ADDED
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ /**
3
+ * Rice Node SDK
4
+ * Unified client for RiceDB (Storage) and State (AI Memory).
5
+ */
6
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
+ if (k2 === undefined) k2 = k;
8
+ var desc = Object.getOwnPropertyDescriptor(m, k);
9
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
+ desc = { enumerable: true, get: function() { return m[k]; } };
11
+ }
12
+ Object.defineProperty(o, k2, desc);
13
+ }) : (function(o, m, k, k2) {
14
+ if (k2 === undefined) k2 = k;
15
+ o[k2] = m[k];
16
+ }));
17
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
18
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
19
+ };
20
+ Object.defineProperty(exports, "__esModule", { value: true });
21
+ const Client_1 = require("./Client");
22
+ const tools_1 = require("./state/tools");
23
+ // Re-export types and classes from storage (for typing usage)
24
+ __exportStar(require("./storage"), exports);
25
+ // Re-export types and classes from state (for typing usage)
26
+ __exportStar(require("./state"), exports);
27
+ // Export Unified Client, Config, and Tools
28
+ __exportStar(require("./Client"), exports);
29
+ __exportStar(require("./config"), exports);
30
+ __exportStar(require("./state/tools"), exports);
31
+ exports.default = {
32
+ Client: Client_1.Client,
33
+ statetool: tools_1.statetool,
34
+ };
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Client for interacting with State (AI Memory).
3
+ * Provides methods for managing conversational memory, drift, and skills.
4
+ */
5
+ export declare class StateClient {
6
+ private client;
7
+ private metadata;
8
+ private runId;
9
+ /**
10
+ * Creates an instance of StateClient.
11
+ * @param address - The address of the State service (e.g., "localhost:50051").
12
+ * @param token - Optional authorization token.
13
+ * @param runId - Unique identifier for the current run/session. Defaults to "default".
14
+ */
15
+ constructor(address?: string, token?: string, runId?: string);
16
+ /**
17
+ * Sets the run ID for subsequent operations.
18
+ * @param runId - The new run ID to use.
19
+ */
20
+ setRunId(runId: string): void;
21
+ /**
22
+ * Focuses the state on a specific content or context.
23
+ * @param content - The content to focus on.
24
+ * @returns A promise that resolves to the ID of the focus operation.
25
+ */
26
+ focus(content: string): Promise<string>;
27
+ /**
28
+ * Retrieves the current drift or context drift items.
29
+ * @returns A promise that resolves to an array of drift items.
30
+ */
31
+ drift(): Promise<any[]>;
32
+ /**
33
+ * Commits a trace of an interaction (input/outcome) to memory.
34
+ * @param input - The input or prompt.
35
+ * @param outcome - The result or response.
36
+ * @param options - Optional parameters including action, reasoning, and agent_id.
37
+ * @returns A promise that resolves to true if successful.
38
+ */
39
+ commit(input: string, outcome: string, options?: {
40
+ action?: string;
41
+ reasoning?: string;
42
+ agent_id?: string;
43
+ }): Promise<boolean>;
44
+ /**
45
+ * Recalls past memories relevant to a query.
46
+ * @param query - The query text to search for memories.
47
+ * @param limit - Maximum number of memories to retrieve. Defaults to 5.
48
+ * @returns A promise that resolves to an array of traces/memories.
49
+ */
50
+ reminisce(query: string, limit?: number): Promise<any[]>;
51
+ /**
52
+ * Triggers a specific skill or action.
53
+ * @param skillName - The name of the skill to trigger.
54
+ * @returns A promise that resolves to the result code (number).
55
+ */
56
+ trigger(skillName: string): Promise<number>;
57
+ /**
58
+ * Deletes the current run/session and its associated data.
59
+ * @returns A promise that resolves to true if successful.
60
+ */
61
+ deleteRun(): Promise<boolean>;
62
+ }