joonecli 0.2.0 → 0.2.2
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/dist/__tests__/config.test.js +1 -0
- package/dist/__tests__/config.test.js.map +1 -1
- package/dist/__tests__/installHostDeps.test.js +45 -0
- package/dist/__tests__/installHostDeps.test.js.map +1 -0
- package/dist/__tests__/whitelistedBackend.test.js +18 -0
- package/dist/__tests__/whitelistedBackend.test.js.map +1 -0
- package/dist/cli/config.d.ts +2 -0
- package/dist/cli/config.js +1 -0
- package/dist/cli/config.js.map +1 -1
- package/dist/cli/index.js +120 -107
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/startupBenchmark.d.ts +13 -0
- package/dist/cli/startupBenchmark.js +27 -0
- package/dist/cli/startupBenchmark.js.map +1 -0
- package/dist/core/agentLoop.d.ts +10 -29
- package/dist/core/agentLoop.js +73 -238
- package/dist/core/agentLoop.js.map +1 -1
- package/dist/core/promptBuilder.js.map +1 -1
- package/dist/hitl/bridge.js +1 -27
- package/dist/hitl/bridge.js.map +1 -1
- package/dist/middleware/loopDetection.d.ts +7 -23
- package/dist/middleware/loopDetection.js +38 -42
- package/dist/middleware/loopDetection.js.map +1 -1
- package/dist/sandbox/whitelistedBackend.d.ts +5 -0
- package/dist/sandbox/whitelistedBackend.js +27 -0
- package/dist/sandbox/whitelistedBackend.js.map +1 -0
- package/dist/tools/askUser.d.ts +12 -3
- package/dist/tools/askUser.js +16 -28
- package/dist/tools/askUser.js.map +1 -1
- package/dist/tools/bashTool.d.ts +11 -0
- package/dist/tools/bashTool.js +51 -0
- package/dist/tools/bashTool.js.map +1 -0
- package/dist/tools/index.d.ts +15 -28
- package/dist/tools/index.js +9 -189
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/installHostDeps.d.ts +8 -2
- package/dist/tools/installHostDeps.js +38 -31
- package/dist/tools/installHostDeps.js.map +1 -1
- package/dist/ui/App.d.ts +4 -1
- package/dist/ui/App.js +200 -63
- package/dist/ui/App.js.map +1 -1
- package/dist/ui/components/MessageBubble.js +1 -1
- package/dist/ui/components/MessageBubble.js.map +1 -1
- package/package.json +7 -2
- package/dist/__tests__/m55.test.js +0 -160
- package/dist/__tests__/m55.test.js.map +0 -1
- package/dist/__tests__/middleware.test.js +0 -169
- package/dist/__tests__/middleware.test.js.map +0 -1
- package/dist/__tests__/optimizations.test.d.ts +0 -1
- package/dist/__tests__/optimizations.test.js +0 -136
- package/dist/__tests__/optimizations.test.js.map +0 -1
- package/dist/__tests__/security.test.d.ts +0 -1
- package/dist/__tests__/security.test.js +0 -86
- package/dist/__tests__/security.test.js.map +0 -1
- package/dist/__tests__/streaming.test.d.ts +0 -1
- package/dist/__tests__/streaming.test.js +0 -71
- package/dist/__tests__/streaming.test.js.map +0 -1
- package/dist/__tests__/toolRouter.test.d.ts +0 -1
- package/dist/__tests__/toolRouter.test.js +0 -37
- package/dist/__tests__/toolRouter.test.js.map +0 -1
- package/dist/__tests__/tools.test.d.ts +0 -1
- package/dist/__tests__/tools.test.js +0 -112
- package/dist/__tests__/tools.test.js.map +0 -1
- package/dist/core/subAgent.d.ts +0 -56
- package/dist/core/subAgent.js +0 -240
- package/dist/core/subAgent.js.map +0 -1
- package/dist/debug_google.d.ts +0 -1
- package/dist/debug_google.js +0 -23
- package/dist/debug_google.js.map +0 -1
- package/dist/middleware/commandSanitizer.d.ts +0 -18
- package/dist/middleware/commandSanitizer.js +0 -50
- package/dist/middleware/commandSanitizer.js.map +0 -1
- package/dist/middleware/permission.d.ts +0 -17
- package/dist/middleware/permission.js +0 -60
- package/dist/middleware/permission.js.map +0 -1
- package/dist/middleware/pipeline.d.ts +0 -31
- package/dist/middleware/pipeline.js +0 -62
- package/dist/middleware/pipeline.js.map +0 -1
- package/dist/middleware/preCompletion.d.ts +0 -29
- package/dist/middleware/preCompletion.js +0 -82
- package/dist/middleware/preCompletion.js.map +0 -1
- package/dist/middleware/types.d.ts +0 -40
- package/dist/middleware/types.js +0 -8
- package/dist/middleware/types.js.map +0 -1
- package/dist/skills/loader.d.ts +0 -55
- package/dist/skills/loader.js +0 -132
- package/dist/skills/loader.js.map +0 -1
- package/dist/skills/tools.d.ts +0 -5
- package/dist/skills/tools.js +0 -78
- package/dist/skills/tools.js.map +0 -1
- package/dist/test_cache.d.ts +0 -1
- package/dist/test_cache.js +0 -55
- package/dist/test_cache.js.map +0 -1
- package/dist/test_google.d.ts +0 -1
- package/dist/test_google.js +0 -36
- package/dist/test_google.js.map +0 -1
- package/dist/tools/browser.d.ts +0 -19
- package/dist/tools/browser.js +0 -114
- package/dist/tools/browser.js.map +0 -1
- package/dist/tools/registry.d.ts +0 -31
- package/dist/tools/registry.js +0 -168
- package/dist/tools/registry.js.map +0 -1
- package/dist/tools/router.d.ts +0 -34
- package/dist/tools/router.js +0 -76
- package/dist/tools/router.js.map +0 -1
- package/dist/tools/security.d.ts +0 -28
- package/dist/tools/security.js +0 -183
- package/dist/tools/security.js.map +0 -1
- package/dist/tools/spawnAgent.d.ts +0 -19
- package/dist/tools/spawnAgent.js +0 -132
- package/dist/tools/spawnAgent.js.map +0 -1
- package/dist/tools/webSearch.d.ts +0 -6
- package/dist/tools/webSearch.js +0 -120
- package/dist/tools/webSearch.js.map +0 -1
- /package/dist/__tests__/{m55.test.d.ts → installHostDeps.test.d.ts} +0 -0
- /package/dist/__tests__/{middleware.test.d.ts → whitelistedBackend.test.d.ts} +0 -0
package/dist/tools/index.js
CHANGED
|
@@ -1,192 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const MAX_FILE_LINES = 2000;
|
|
9
|
-
// ─── Sandbox reference (set at session start) ───────────────────────────────────
|
|
10
|
-
let _sandboxManager = null;
|
|
11
|
-
let _fileSync = null;
|
|
12
|
-
/**
|
|
13
|
-
* Binds the tools to a SandboxManager and FileSync instance.
|
|
14
|
-
* Must be called at session start before any tool executions.
|
|
15
|
-
*/
|
|
16
|
-
export function bindSandbox(sandbox, fileSync) {
|
|
17
|
-
_sandboxManager = sandbox;
|
|
18
|
-
_fileSync = fileSync;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Security: Validates that a resolved path is strictly inside the given workspace dir.
|
|
22
|
-
* Prevents directory traversal attacks from accessing sensitive host files.
|
|
23
|
-
*/
|
|
24
|
-
export function isPathInsideWorkspace(resolvedPath, workspaceDir = process.cwd()) {
|
|
25
|
-
const normalizedWorkspace = path.resolve(workspaceDir);
|
|
26
|
-
// path.relative returns a path relative to the first argument.
|
|
27
|
-
// If it starts with '..' or is absolute, it means resolvedPath has escaped normalizedWorkspace.
|
|
28
|
-
const relative = path.relative(normalizedWorkspace, resolvedPath);
|
|
29
|
-
return relative !== "" && !relative.startsWith("..") && !path.isAbsolute(relative);
|
|
30
|
-
}
|
|
31
|
-
// ─── BashTool ───────────────────────────────────────────────────────────────────
|
|
32
|
-
// Executes shell commands inside the E2B sandbox.
|
|
33
|
-
// The ToolRouter routes this to SANDBOX — the host machine is never exposed.
|
|
34
|
-
export const BashTool = {
|
|
35
|
-
name: "bash",
|
|
36
|
-
description: "Runs a shell command inside an isolated sandbox. Use for tests, scripts, or installing dependencies. The host machine is never exposed.",
|
|
37
|
-
schema: {
|
|
38
|
-
type: "object",
|
|
39
|
-
properties: {
|
|
40
|
-
command: {
|
|
41
|
-
type: "string",
|
|
42
|
-
description: "The shell command to execute",
|
|
43
|
-
},
|
|
44
|
-
},
|
|
45
|
-
required: ["command"],
|
|
46
|
-
},
|
|
47
|
-
execute: async (args, emitter) => {
|
|
48
|
-
if (emitter)
|
|
49
|
-
emitter.emit("agent:event", { type: "system:script_exec", command: args.command, location: "sandbox" });
|
|
50
|
-
if (!_sandboxManager || !_sandboxManager.isActive()) {
|
|
51
|
-
throw new Error("Sandbox is not active. Cannot execute bash commands without an active sandbox session.");
|
|
52
|
-
}
|
|
53
|
-
// Sync any dirty files from host → sandbox before executing
|
|
54
|
-
if (_fileSync && _fileSync.pendingCount() > 0) {
|
|
55
|
-
await _fileSync.syncToSandbox(_sandboxManager);
|
|
56
|
-
}
|
|
57
|
-
const result = await _sandboxManager.exec(args.command);
|
|
58
|
-
if (result.exitCode !== 0) {
|
|
59
|
-
return {
|
|
60
|
-
content: `Command failed (exit code ${result.exitCode}):\nSTDOUT:\n${result.stdout}\nSTDERR:\n${result.stderr}`,
|
|
61
|
-
metadata: { exitCode: result.exitCode },
|
|
62
|
-
isError: true
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
return {
|
|
66
|
-
content: result.stdout || "(no output)",
|
|
67
|
-
metadata: { exitCode: result.exitCode },
|
|
68
|
-
isError: false
|
|
69
|
-
};
|
|
70
|
-
},
|
|
71
|
-
};
|
|
72
|
-
// ─── ReadFileTool ───────────────────────────────────────────────────────────────
|
|
73
|
-
// Reads files from the HOST filesystem (so the user's real project is visible).
|
|
74
|
-
// Includes a built-in file size guardrail to prevent sending huge files to the LLM.
|
|
75
|
-
export const ReadFileTool = {
|
|
76
|
-
name: "read_file",
|
|
77
|
-
description: "Reads a file from the host filesystem. Includes a file size guardrail — files over 512KB are truncated to prevent context overflow.",
|
|
78
|
-
schema: {
|
|
79
|
-
type: "object",
|
|
80
|
-
properties: {
|
|
81
|
-
path: {
|
|
82
|
-
type: "string",
|
|
83
|
-
description: "Absolute or relative path to the file",
|
|
84
|
-
},
|
|
85
|
-
startLine: {
|
|
86
|
-
type: "number",
|
|
87
|
-
description: "Optional 1-indexed start line for partial reads",
|
|
88
|
-
},
|
|
89
|
-
endLine: {
|
|
90
|
-
type: "number",
|
|
91
|
-
description: "Optional 1-indexed end line for partial reads",
|
|
92
|
-
},
|
|
93
|
-
},
|
|
94
|
-
required: ["path"],
|
|
95
|
-
},
|
|
96
|
-
execute: async (args, emitter) => {
|
|
97
|
-
const filePath = path.resolve(args.path);
|
|
98
|
-
if (emitter)
|
|
99
|
-
emitter.emit("agent:event", { type: "file:io", action: "read", path: filePath });
|
|
100
|
-
// ── Security Guardrail ──
|
|
101
|
-
if (!isPathInsideWorkspace(filePath)) {
|
|
102
|
-
return {
|
|
103
|
-
content: `Security Error: Access Denied. Cannot read files outside the current project workspace (${process.cwd()}).`,
|
|
104
|
-
isError: true
|
|
105
|
-
};
|
|
106
|
-
}
|
|
107
|
-
// ── Check existence ──
|
|
108
|
-
if (!fs.existsSync(filePath)) {
|
|
109
|
-
return {
|
|
110
|
-
content: `Error: File not found — ${filePath}`,
|
|
111
|
-
isError: true
|
|
112
|
-
};
|
|
113
|
-
}
|
|
114
|
-
// ── File Size Guardrail ──
|
|
115
|
-
const stat = fs.statSync(filePath);
|
|
116
|
-
if (stat.size > MAX_FILE_SIZE_BYTES) {
|
|
117
|
-
return {
|
|
118
|
-
content: `Error: File too large (${Math.round(stat.size / 1024)}KB). Maximum size is 512KB. Use line ranges or grep_search.`,
|
|
119
|
-
isError: true
|
|
120
|
-
};
|
|
121
|
-
}
|
|
122
|
-
const fileContent = fs.readFileSync(filePath, "utf-8");
|
|
123
|
-
const lines = fileContent.split("\n");
|
|
124
|
-
if (args.startLine !== undefined || args.endLine !== undefined) {
|
|
125
|
-
const start = Math.max(1, args.startLine ?? 1) - 1;
|
|
126
|
-
const end = Math.min(lines.length, args.endLine ?? lines.length);
|
|
127
|
-
const sliced = lines.slice(start, end);
|
|
128
|
-
return { content: sliced.map((line, i) => `${start + i + 1}: ${line}`).join("\n") };
|
|
129
|
-
}
|
|
130
|
-
// ── Line count guardrail ──
|
|
131
|
-
if (lines.length > MAX_FILE_LINES) {
|
|
132
|
-
const truncated = lines.slice(0, MAX_FILE_LINES);
|
|
133
|
-
return {
|
|
134
|
-
content: truncated.map((line, i) => `${i + 1}: ${line}`).join("\n") +
|
|
135
|
-
`\n\n--- Truncated at ${MAX_FILE_LINES} lines (total: ${lines.length}) ---`
|
|
136
|
-
};
|
|
137
|
-
}
|
|
138
|
-
return { content: fileContent };
|
|
139
|
-
},
|
|
140
|
-
};
|
|
141
|
-
// ─── WriteFileTool ──────────────────────────────────────────────────────────────
|
|
142
|
-
// Writes files to the HOST filesystem (so the user sees changes in their IDE).
|
|
143
|
-
// Marks written files as dirty so FileSync uploads them before sandbox execution.
|
|
144
|
-
export const WriteFileTool = {
|
|
145
|
-
name: "write_file",
|
|
146
|
-
description: "Writes content to a file on the host filesystem. The user will see changes in their IDE immediately. The file is automatically synced to the sandbox before the next command execution.",
|
|
147
|
-
schema: {
|
|
148
|
-
type: "object",
|
|
149
|
-
properties: {
|
|
150
|
-
path: {
|
|
151
|
-
type: "string",
|
|
152
|
-
description: "Absolute or relative path to the file",
|
|
153
|
-
},
|
|
154
|
-
content: {
|
|
155
|
-
type: "string",
|
|
156
|
-
description: "The full file content to write",
|
|
157
|
-
},
|
|
158
|
-
},
|
|
159
|
-
required: ["path", "content"],
|
|
160
|
-
},
|
|
161
|
-
execute: async (args, emitter) => {
|
|
162
|
-
const filePath = path.resolve(args.path);
|
|
163
|
-
if (emitter)
|
|
164
|
-
emitter.emit("agent:event", { type: "file:io", action: "write", path: filePath });
|
|
165
|
-
// ── Security Guardrail ──
|
|
166
|
-
if (!isPathInsideWorkspace(filePath)) {
|
|
167
|
-
return {
|
|
168
|
-
content: `Security Error: Access Denied. Cannot write files outside the current project workspace (${process.cwd()}).`,
|
|
169
|
-
isError: true
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
// Create parent directories if needed
|
|
173
|
-
const dir = path.dirname(filePath);
|
|
174
|
-
if (!fs.existsSync(dir)) {
|
|
175
|
-
fs.mkdirSync(dir, { recursive: true });
|
|
176
|
-
}
|
|
177
|
-
fs.writeFileSync(filePath, args.content, "utf-8");
|
|
178
|
-
// Mark file as dirty for next sandbox sync
|
|
179
|
-
if (_fileSync) {
|
|
180
|
-
_fileSync.markDirty(filePath);
|
|
181
|
-
}
|
|
182
|
-
return { content: `File written: ${filePath}` };
|
|
183
|
-
},
|
|
184
|
-
};
|
|
185
|
-
// ─── Core Tool Set ──────────────────────────────────────────────────────────────
|
|
1
|
+
import { installHostDependenciesTool } from "./installHostDeps.js";
|
|
2
|
+
import { bashTool, bindSandbox } from "./bashTool.js";
|
|
3
|
+
// Re-export bindSandbox so index.ts can initialize it
|
|
4
|
+
export { bindSandbox };
|
|
5
|
+
// The core custom tools that the agent needs.
|
|
6
|
+
// Note: File I/O (read_file, write_file, edit_file, ls, grep) and Subagents
|
|
7
|
+
// are provided natively by Deep Agents via the FilesystemBackend and createSubAgentMiddleware.
|
|
186
8
|
export const CORE_TOOLS = [
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
WriteFileTool,
|
|
190
|
-
InstallHostDependenciesTool,
|
|
9
|
+
bashTool,
|
|
10
|
+
installHostDependenciesTool,
|
|
191
11
|
];
|
|
192
12
|
//# sourceMappingURL=index.js.map
|
package/dist/tools/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAEtD,sDAAsD;AACtD,OAAO,EAAE,WAAW,EAAE,CAAC;AAEvB,8CAA8C;AAC9C,4EAA4E;AAC5E,+FAA+F;AAC/F,MAAM,CAAC,MAAM,UAAU,GAAG;IACtB,QAAQ;IACR,2BAA2B;CAC9B,CAAC"}
|
|
@@ -1,2 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const installHostDependenciesTool: import("langchain").DynamicStructuredTool<z.ZodObject<{
|
|
3
|
+
command: z.ZodString;
|
|
4
|
+
}, z.core.$strip>, {
|
|
5
|
+
command: string;
|
|
6
|
+
}, {
|
|
7
|
+
command: string;
|
|
8
|
+
}, string, "install_host_dependencies">;
|
|
@@ -1,37 +1,44 @@
|
|
|
1
1
|
import { exec } from "node:child_process";
|
|
2
2
|
import { promisify } from "node:util";
|
|
3
|
+
import { tool } from "langchain";
|
|
4
|
+
import { z } from "zod";
|
|
3
5
|
const execAsync = promisify(exec);
|
|
4
|
-
|
|
6
|
+
const ALLOWED_INSTALLERS = {
|
|
7
|
+
npm: new Set(["install", "i", "ci", "add"]),
|
|
8
|
+
yarn: new Set(["add", "install"]),
|
|
9
|
+
pnpm: new Set(["add", "install", "i"]),
|
|
10
|
+
pip: new Set(["install"]),
|
|
11
|
+
pip3: new Set(["install"]),
|
|
12
|
+
cargo: new Set(["add", "install"]),
|
|
13
|
+
poetry: new Set(["add", "install"]),
|
|
14
|
+
gem: new Set(["install"]),
|
|
15
|
+
composer: new Set(["require", "install"]),
|
|
16
|
+
go: new Set(["get", "install"]),
|
|
17
|
+
bun: new Set(["add", "install"]),
|
|
18
|
+
};
|
|
19
|
+
export const installHostDependenciesTool = tool(async ({ command }) => {
|
|
20
|
+
const trimmedCmd = command.trim();
|
|
21
|
+
const parts = trimmedCmd.split(/\s+/);
|
|
22
|
+
const bin = parts[0];
|
|
23
|
+
const subcmd = parts[1];
|
|
24
|
+
if (!ALLOWED_INSTALLERS[bin] || !ALLOWED_INSTALLERS[bin].has(subcmd)) {
|
|
25
|
+
return `Security Error: Command '${bin} ${subcmd}' is not allowed. Only dependency installation commands (like 'npm install') are permitted by this tool.`;
|
|
26
|
+
}
|
|
27
|
+
if (/[&|;`$]/.test(trimmedCmd)) {
|
|
28
|
+
return `Security Error: Command contains forbidden shell operators (&, |, ;, \`, $).`;
|
|
29
|
+
}
|
|
30
|
+
try {
|
|
31
|
+
const { stdout, stderr } = await execAsync(command, { cwd: process.cwd() });
|
|
32
|
+
return `Successfully ran on host:\nSTDOUT:\n${stdout}\nSTDERR:\n${stderr}`;
|
|
33
|
+
}
|
|
34
|
+
catch (error) {
|
|
35
|
+
return `Host command failed (exit code ${error.code}):\nSTDOUT:\n${error.stdout}\nSTDERR:\n${error.stderr}\nMESSAGE:\n${error.message}`;
|
|
36
|
+
}
|
|
37
|
+
}, {
|
|
5
38
|
name: "install_host_dependencies",
|
|
6
39
|
description: "Installs dependencies natively on the host OS (e.g. npm install, pip install). Use this carefully to bootstrap projects outside the sandbox. This runs directly on the user's machine.",
|
|
7
|
-
schema: {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
type: "string",
|
|
12
|
-
description: "The native installation command (e.g., 'npm install express')",
|
|
13
|
-
},
|
|
14
|
-
},
|
|
15
|
-
required: ["command"],
|
|
16
|
-
},
|
|
17
|
-
execute: async (args, emitter) => {
|
|
18
|
-
if (emitter) {
|
|
19
|
-
emitter.emit("agent:event", { type: "system:script_exec", command: args.command, location: "host" });
|
|
20
|
-
}
|
|
21
|
-
try {
|
|
22
|
-
const { stdout, stderr } = await execAsync(args.command, { cwd: process.cwd() });
|
|
23
|
-
return {
|
|
24
|
-
content: `Successfully ran on host:\nSTDOUT:\n${stdout}\nSTDERR:\n${stderr}`,
|
|
25
|
-
isError: false,
|
|
26
|
-
};
|
|
27
|
-
}
|
|
28
|
-
catch (error) {
|
|
29
|
-
return {
|
|
30
|
-
content: `Host command failed (exit code ${error.code}):\nSTDOUT:\n${error.stdout}\nSTDERR:\n${error.stderr}\nMESSAGE:\n${error.message}`,
|
|
31
|
-
metadata: { exitCode: error.code },
|
|
32
|
-
isError: true
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
},
|
|
36
|
-
};
|
|
40
|
+
schema: z.object({
|
|
41
|
+
command: z.string().describe("The native installation command (e.g., 'npm install express')"),
|
|
42
|
+
}),
|
|
43
|
+
});
|
|
37
44
|
//# sourceMappingURL=installHostDeps.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"installHostDeps.js","sourceRoot":"","sources":["../../src/tools/installHostDeps.ts"],"names":[],"mappings":"AA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,CAAC;CACL,CACJ,CAAC"}
|
package/dist/ui/App.d.ts
CHANGED
|
@@ -16,9 +16,12 @@ interface AppProps {
|
|
|
16
16
|
provider: string;
|
|
17
17
|
model: string;
|
|
18
18
|
streaming: boolean;
|
|
19
|
-
|
|
19
|
+
createHarness: () => Promise<ExecutionHarness>;
|
|
20
20
|
initialState: ContextState;
|
|
21
21
|
maxTokens: number;
|
|
22
|
+
benchmarkStartup?: boolean;
|
|
23
|
+
onStartupBenchmarkMark?: (name: string) => void;
|
|
24
|
+
onStartupBenchmarkComplete?: () => void;
|
|
22
25
|
}
|
|
23
26
|
export declare const App: React.FC<AppProps>;
|
|
24
27
|
export {};
|