@bike4mind/cli 0.2.59 → 0.2.60-feat-jupyter-execution-ui.21619
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/{artifactExtractor-WV7T7UVE.js → artifactExtractor-N7SGBUGY.js} +1 -1
- package/dist/{chunk-U52SND4Y.js → chunk-6MNXZFMC.js} +1 -1
- package/dist/{chunk-BWGCVOUE.js → chunk-A5NFPVII.js} +1 -1
- package/dist/{chunk-RVSL3T7O.js → chunk-BBWQJZPG.js} +2 -2
- package/dist/{chunk-EY2AKUAW.js → chunk-BCIB6PU6.js} +4 -1
- package/dist/{chunk-7PKRQKWK.js → chunk-EYRJEDKD.js} +2 -2
- package/dist/{chunk-Z6Y6DXZ3.js → chunk-JA232O4S.js} +16 -16
- package/dist/{chunk-5TQE3IBF.js → chunk-UPBT6KT7.js} +2 -2
- package/dist/{chunk-BPUFVNEJ.js → chunk-XFU5CJGQ.js} +4 -4
- package/dist/commands/doctorCommand.js +1 -1
- package/dist/commands/headlessCommand.js +7 -7
- package/dist/commands/mcpCommand.js +2 -2
- package/dist/commands/updateCommand.js +1 -1
- package/dist/{create-L4BDKZWA.js → create-TR3OS2VJ.js} +3 -3
- package/dist/index.js +162 -8
- package/dist/{llmMarkdownGenerator-YNW45S53.js → llmMarkdownGenerator-XMPPKHWJ.js} +1 -1
- package/dist/{markdownGenerator-KSVUSRRH.js → markdownGenerator-OERCNCIB.js} +1 -1
- package/dist/{mementoService-6P7BDFRA.js → mementoService-7Y5LCMCK.js} +3 -3
- package/dist/{src-VJAN5SFV.js → src-5DSL253O.js} +1 -1
- package/dist/{src-PHDQ4SXS.js → src-AM2Y6A7O.js} +2 -2
- package/dist/{subtractCredits-OF5QCO3A.js → subtractCredits-OZAEB5AG.js} +3 -3
- package/package.json +16 -16
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
CurationArtifactType
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-BCIB6PU6.js";
|
|
5
5
|
|
|
6
6
|
// ../../b4m-core/packages/services/dist/src/notebookCurationService/artifactExtractor.js
|
|
7
7
|
var ARTIFACT_TAG_REGEX = /<artifact\s+(.*?)>([\s\S]*?)<\/artifact>/gi;
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
extractSnippetMeta,
|
|
21
21
|
isGPTImageModel,
|
|
22
22
|
settingsMap
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-BCIB6PU6.js";
|
|
24
24
|
|
|
25
25
|
// ../../b4m-core/packages/utils/dist/src/storage/S3Storage.js
|
|
26
26
|
import { S3Client, PutObjectCommand, DeleteObjectCommand, GetObjectCommand, HeadObjectCommand } from "@aws-sdk/client-s3";
|
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
getSettingsMap,
|
|
8
8
|
getSettingsValue,
|
|
9
9
|
secureParameters
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-A5NFPVII.js";
|
|
11
11
|
import {
|
|
12
12
|
KnowledgeType,
|
|
13
13
|
SupportedFabFileMimeTypes
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-BCIB6PU6.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/fabFileService/create.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -1253,6 +1253,7 @@ var SreTrackingStatus;
|
|
|
1253
1253
|
SreTrackingStatus2["WONT_FIX"] = "wont_fix";
|
|
1254
1254
|
SreTrackingStatus2["DISPATCH_FAILED"] = "dispatch_failed";
|
|
1255
1255
|
SreTrackingStatus2["DRY_RUN"] = "dry_run";
|
|
1256
|
+
SreTrackingStatus2["SCOPE_BLOCKED"] = "scope_blocked";
|
|
1256
1257
|
})(SreTrackingStatus || (SreTrackingStatus = {}));
|
|
1257
1258
|
var SRE_GATE_DEFAULTS = {
|
|
1258
1259
|
enabled: true,
|
|
@@ -1830,7 +1831,9 @@ var KeepCommandType = z11.enum([
|
|
|
1830
1831
|
"jupyter_start_kernel",
|
|
1831
1832
|
"jupyter_execute_cell",
|
|
1832
1833
|
"jupyter_stop_kernel",
|
|
1833
|
-
"jupyter_get_kernelspecs"
|
|
1834
|
+
"jupyter_get_kernelspecs",
|
|
1835
|
+
// Full notebook execution (CLI orchestrates cell-by-cell execution)
|
|
1836
|
+
"jupyter_execute_notebook"
|
|
1834
1837
|
]);
|
|
1835
1838
|
var KeepCommandRequestAction = z11.object({
|
|
1836
1839
|
action: z11.literal("keep_command_request"),
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {
|
|
3
3
|
BadRequestError,
|
|
4
4
|
secureParameters
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-A5NFPVII.js";
|
|
6
6
|
import {
|
|
7
7
|
CompletionApiUsageTransaction,
|
|
8
8
|
GenericCreditDeductTransaction,
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
ToolUsageTransaction,
|
|
14
14
|
TransferCreditTransaction,
|
|
15
15
|
VideoGenerationUsageTransaction
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-BCIB6PU6.js";
|
|
17
17
|
|
|
18
18
|
// ../../b4m-core/packages/services/dist/src/creditService/subtractCredits.js
|
|
19
19
|
import { z } from "zod";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// package.json
|
|
4
4
|
var package_default = {
|
|
5
5
|
name: "@bike4mind/cli",
|
|
6
|
-
version: "0.2.
|
|
6
|
+
version: "0.2.60-feat-jupyter-execution-ui.21619+915612490",
|
|
7
7
|
type: "module",
|
|
8
8
|
description: "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
9
9
|
license: "UNLICENSED",
|
|
@@ -45,15 +45,15 @@ var package_default = {
|
|
|
45
45
|
},
|
|
46
46
|
dependencies: {
|
|
47
47
|
"@anthropic-ai/sdk": "^0.79.0",
|
|
48
|
-
"@aws-sdk/client-apigatewaymanagementapi": "3.
|
|
49
|
-
"@aws-sdk/client-bedrock-runtime": "3.
|
|
50
|
-
"@aws-sdk/client-cloudwatch": "3.
|
|
51
|
-
"@aws-sdk/client-lambda": "3.
|
|
52
|
-
"@aws-sdk/client-s3": "3.
|
|
53
|
-
"@aws-sdk/client-sqs": "3.
|
|
54
|
-
"@aws-sdk/client-transcribe": "3.
|
|
55
|
-
"@aws-sdk/credential-provider-node": "3.972.
|
|
56
|
-
"@aws-sdk/s3-request-presigner": "3.
|
|
48
|
+
"@aws-sdk/client-apigatewaymanagementapi": "^3.1012.0",
|
|
49
|
+
"@aws-sdk/client-bedrock-runtime": "^3.1012.0",
|
|
50
|
+
"@aws-sdk/client-cloudwatch": "^3.1012.0",
|
|
51
|
+
"@aws-sdk/client-lambda": "^3.1012.0",
|
|
52
|
+
"@aws-sdk/client-s3": "^3.1012.0",
|
|
53
|
+
"@aws-sdk/client-sqs": "^3.1012.0",
|
|
54
|
+
"@aws-sdk/client-transcribe": "^3.1012.0",
|
|
55
|
+
"@aws-sdk/credential-provider-node": "^3.972.22",
|
|
56
|
+
"@aws-sdk/s3-request-presigner": "^3.1012.0",
|
|
57
57
|
"@casl/ability": "^6.8.0",
|
|
58
58
|
"@google/genai": "^1.46.0",
|
|
59
59
|
"@joplin/turndown-plugin-gfm": "^1.0.64",
|
|
@@ -118,11 +118,11 @@ var package_default = {
|
|
|
118
118
|
zustand: "^4.5.4"
|
|
119
119
|
},
|
|
120
120
|
devDependencies: {
|
|
121
|
-
"@bike4mind/agents": "0.2.
|
|
122
|
-
"@bike4mind/common": "2.72.
|
|
123
|
-
"@bike4mind/mcp": "1.33.
|
|
124
|
-
"@bike4mind/services": "2.67.
|
|
125
|
-
"@bike4mind/utils": "2.15.
|
|
121
|
+
"@bike4mind/agents": "0.2.4-feat-jupyter-execution-ui.21619+915612490",
|
|
122
|
+
"@bike4mind/common": "2.72.1-feat-jupyter-execution-ui.21619+915612490",
|
|
123
|
+
"@bike4mind/mcp": "1.33.18-feat-jupyter-execution-ui.21619+915612490",
|
|
124
|
+
"@bike4mind/services": "2.67.1-feat-jupyter-execution-ui.21619+915612490",
|
|
125
|
+
"@bike4mind/utils": "2.15.12-feat-jupyter-execution-ui.21619+915612490",
|
|
126
126
|
"@types/better-sqlite3": "^7.6.13",
|
|
127
127
|
"@types/jsonwebtoken": "^9.0.4",
|
|
128
128
|
"@types/node": "^22.9.0",
|
|
@@ -139,7 +139,7 @@ var package_default = {
|
|
|
139
139
|
optionalDependencies: {
|
|
140
140
|
"@vscode/ripgrep": "^1.17.1"
|
|
141
141
|
},
|
|
142
|
-
gitHead: "
|
|
142
|
+
gitHead: "915612490c3ee1d735af5f50d5e6aca991864893"
|
|
143
143
|
};
|
|
144
144
|
|
|
145
145
|
// src/utils/updateChecker.ts
|
|
@@ -6,12 +6,12 @@ import {
|
|
|
6
6
|
getSettingsByNames,
|
|
7
7
|
obfuscateApiKey,
|
|
8
8
|
secureParameters
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-A5NFPVII.js";
|
|
10
10
|
import {
|
|
11
11
|
ApiKeyType,
|
|
12
12
|
MementoTier,
|
|
13
13
|
isSupportedEmbeddingModel
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-BCIB6PU6.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/apiKeyService/get.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
getOpenWeatherKey,
|
|
5
5
|
getSerperKey,
|
|
6
6
|
getWolframAlphaKey
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-UPBT6KT7.js";
|
|
8
8
|
import {
|
|
9
9
|
BFLImageService,
|
|
10
10
|
BaseStorage,
|
|
@@ -16,14 +16,14 @@ import {
|
|
|
16
16
|
OpenAIBackend,
|
|
17
17
|
OpenAIImageService,
|
|
18
18
|
XAIImageService
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-A5NFPVII.js";
|
|
20
20
|
import {
|
|
21
21
|
Logger
|
|
22
22
|
} from "./chunk-PFBYGCOW.js";
|
|
23
23
|
import {
|
|
24
24
|
ConfigStore,
|
|
25
25
|
logger
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-6MNXZFMC.js";
|
|
27
27
|
import {
|
|
28
28
|
ALERT_THRESHOLDS,
|
|
29
29
|
AiEvents,
|
|
@@ -84,7 +84,7 @@ import {
|
|
|
84
84
|
getViewById,
|
|
85
85
|
resolveNavigationIntents,
|
|
86
86
|
sanitizeTelemetryError
|
|
87
|
-
} from "./chunk-
|
|
87
|
+
} from "./chunk-BCIB6PU6.js";
|
|
88
88
|
|
|
89
89
|
// src/utils/fileSearch.ts
|
|
90
90
|
import * as fs from "fs";
|
|
@@ -36,20 +36,20 @@ import {
|
|
|
36
36
|
isReadOnlyTool,
|
|
37
37
|
loadContextFiles,
|
|
38
38
|
setWebSocketToolExecutor
|
|
39
|
-
} from "../chunk-
|
|
39
|
+
} from "../chunk-XFU5CJGQ.js";
|
|
40
40
|
import "../chunk-BDQBOLYG.js";
|
|
41
|
-
import "../chunk-
|
|
41
|
+
import "../chunk-UPBT6KT7.js";
|
|
42
42
|
import "../chunk-GQGOWACU.js";
|
|
43
|
-
import "../chunk-
|
|
44
|
-
import "../chunk-
|
|
45
|
-
import "../chunk-
|
|
43
|
+
import "../chunk-EYRJEDKD.js";
|
|
44
|
+
import "../chunk-BBWQJZPG.js";
|
|
45
|
+
import "../chunk-A5NFPVII.js";
|
|
46
46
|
import "../chunk-PFBYGCOW.js";
|
|
47
47
|
import "../chunk-BPFEGDC7.js";
|
|
48
48
|
import {
|
|
49
49
|
ConfigStore,
|
|
50
50
|
logger
|
|
51
|
-
} from "../chunk-
|
|
52
|
-
import "../chunk-
|
|
51
|
+
} from "../chunk-6MNXZFMC.js";
|
|
52
|
+
import "../chunk-BCIB6PU6.js";
|
|
53
53
|
import {
|
|
54
54
|
DEFAULT_SANDBOX_CONFIG
|
|
55
55
|
} from "../chunk-4BIBE3J7.js";
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
createFabFile,
|
|
4
4
|
createFabFileSchema
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-BBWQJZPG.js";
|
|
6
|
+
import "./chunk-A5NFPVII.js";
|
|
7
7
|
import "./chunk-PFBYGCOW.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-BCIB6PU6.js";
|
|
9
9
|
export {
|
|
10
10
|
createFabFile,
|
|
11
11
|
createFabFileSchema
|
package/dist/index.js
CHANGED
|
@@ -48,25 +48,25 @@ import {
|
|
|
48
48
|
setWebSocketToolExecutor,
|
|
49
49
|
substituteArguments,
|
|
50
50
|
warmFileCache
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-XFU5CJGQ.js";
|
|
52
52
|
import "./chunk-BDQBOLYG.js";
|
|
53
|
-
import "./chunk-
|
|
53
|
+
import "./chunk-UPBT6KT7.js";
|
|
54
54
|
import "./chunk-GQGOWACU.js";
|
|
55
|
-
import "./chunk-
|
|
56
|
-
import "./chunk-
|
|
55
|
+
import "./chunk-EYRJEDKD.js";
|
|
56
|
+
import "./chunk-BBWQJZPG.js";
|
|
57
57
|
import {
|
|
58
58
|
OllamaBackend
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-A5NFPVII.js";
|
|
60
60
|
import "./chunk-PFBYGCOW.js";
|
|
61
61
|
import "./chunk-BPFEGDC7.js";
|
|
62
62
|
import {
|
|
63
63
|
ConfigStore,
|
|
64
64
|
logger
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-6MNXZFMC.js";
|
|
66
66
|
import {
|
|
67
67
|
checkForUpdate,
|
|
68
68
|
package_default
|
|
69
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-JA232O4S.js";
|
|
70
70
|
import {
|
|
71
71
|
selectActiveBackgroundAgents,
|
|
72
72
|
useCliStore
|
|
@@ -76,7 +76,7 @@ import {
|
|
|
76
76
|
ChatModels,
|
|
77
77
|
validateJupyterKernelName,
|
|
78
78
|
validateNotebookPath
|
|
79
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-BCIB6PU6.js";
|
|
80
80
|
import "./chunk-4BIBE3J7.js";
|
|
81
81
|
|
|
82
82
|
// src/index.tsx
|
|
@@ -4244,6 +4244,160 @@ function CliApp() {
|
|
|
4244
4244
|
};
|
|
4245
4245
|
break;
|
|
4246
4246
|
}
|
|
4247
|
+
case "jupyter_execute_notebook": {
|
|
4248
|
+
const notebookJson = params.notebookJson;
|
|
4249
|
+
const sessionId = params.sessionId;
|
|
4250
|
+
const kernelName = params.kernelName || "python3";
|
|
4251
|
+
const timeoutPerCell = params.timeoutPerCell || 3e4;
|
|
4252
|
+
if (!notebookJson) throw new Error("Missing required param: notebookJson");
|
|
4253
|
+
if (!sessionId) throw new Error("Missing required param: sessionId");
|
|
4254
|
+
let notebook;
|
|
4255
|
+
try {
|
|
4256
|
+
notebook = JSON.parse(notebookJson);
|
|
4257
|
+
if (!notebook.cells || !Array.isArray(notebook.cells)) {
|
|
4258
|
+
throw new Error("Invalid notebook: missing cells array");
|
|
4259
|
+
}
|
|
4260
|
+
} catch (parseErr) {
|
|
4261
|
+
throw new Error(
|
|
4262
|
+
`Failed to parse notebook JSON: ${parseErr instanceof Error ? parseErr.message : String(parseErr)}`
|
|
4263
|
+
);
|
|
4264
|
+
}
|
|
4265
|
+
const getCellSource = (cell) => {
|
|
4266
|
+
return Array.isArray(cell.source) ? cell.source.join("") : cell.source;
|
|
4267
|
+
};
|
|
4268
|
+
const codeCells = notebook.cells.filter((c) => c.cell_type === "code");
|
|
4269
|
+
const totalCodeCells = codeCells.length;
|
|
4270
|
+
logger.info(
|
|
4271
|
+
`[Keep] Starting notebook execution: ${totalCodeCells} code cells, kernel: ${kernelName}`
|
|
4272
|
+
);
|
|
4273
|
+
const tempNotebookPath = `/tmp/b4m-notebook-${Date.now()}.ipynb`;
|
|
4274
|
+
await fs.writeFile(tempNotebookPath, notebookJson, "utf-8");
|
|
4275
|
+
const jupyterClient = getRequiredJupyterClient();
|
|
4276
|
+
let jupyterSession = null;
|
|
4277
|
+
let cellsExecuted = 0;
|
|
4278
|
+
let cellsFailed = 0;
|
|
4279
|
+
try {
|
|
4280
|
+
logger.info(`[Keep] Starting Jupyter kernel: ${kernelName}`);
|
|
4281
|
+
jupyterSession = await jupyterClient.startSession(tempNotebookPath, kernelName);
|
|
4282
|
+
const kernelId = jupyterSession.kernel.id;
|
|
4283
|
+
const jupyterSessionId = jupyterSession.id;
|
|
4284
|
+
logger.info(`[Keep] Kernel started: session=${jupyterSessionId}, kernel=${kernelId}`);
|
|
4285
|
+
let codeCellIndex = 0;
|
|
4286
|
+
for (let i = 0; i < notebook.cells.length; i++) {
|
|
4287
|
+
const cell = notebook.cells[i];
|
|
4288
|
+
if (cell.cell_type !== "code") continue;
|
|
4289
|
+
const cellCode = getCellSource(cell);
|
|
4290
|
+
if (!cellCode.trim()) {
|
|
4291
|
+
codeCellIndex++;
|
|
4292
|
+
continue;
|
|
4293
|
+
}
|
|
4294
|
+
logger.info(`[Keep] Executing cell ${codeCellIndex + 1}/${totalCodeCells}`);
|
|
4295
|
+
wsManager?.send({
|
|
4296
|
+
action: "jupyter_cell_output",
|
|
4297
|
+
requestId,
|
|
4298
|
+
sessionId,
|
|
4299
|
+
jupyterSessionId,
|
|
4300
|
+
cellIndex: codeCellIndex,
|
|
4301
|
+
outputType: "stream",
|
|
4302
|
+
content: { text: `Executing cell ${codeCellIndex + 1}/${totalCodeCells}...`, name: "stdout" },
|
|
4303
|
+
executionCount: null,
|
|
4304
|
+
isComplete: false
|
|
4305
|
+
});
|
|
4306
|
+
try {
|
|
4307
|
+
const cellResult = await jupyterClient.executeCell(kernelId, cellCode, timeoutPerCell);
|
|
4308
|
+
cell.outputs = cellResult.outputs;
|
|
4309
|
+
cell.execution_count = cellResult.executionCount;
|
|
4310
|
+
if (cellResult.success) {
|
|
4311
|
+
cellsExecuted++;
|
|
4312
|
+
wsManager?.send({
|
|
4313
|
+
action: "jupyter_cell_output",
|
|
4314
|
+
requestId,
|
|
4315
|
+
sessionId,
|
|
4316
|
+
jupyterSessionId,
|
|
4317
|
+
cellIndex: codeCellIndex,
|
|
4318
|
+
outputType: "execute_result",
|
|
4319
|
+
content: {
|
|
4320
|
+
text: cellResult.outputs.map((o) => {
|
|
4321
|
+
if (o.text) return Array.isArray(o.text) ? o.text.join("") : o.text;
|
|
4322
|
+
if (o.data && typeof o.data === "object" && "text/plain" in o.data) {
|
|
4323
|
+
const textPlain = o.data["text/plain"];
|
|
4324
|
+
return Array.isArray(textPlain) ? textPlain.join("") : String(textPlain);
|
|
4325
|
+
}
|
|
4326
|
+
return "";
|
|
4327
|
+
}).join(""),
|
|
4328
|
+
data: cellResult.outputs.find((o) => o.data)?.data
|
|
4329
|
+
},
|
|
4330
|
+
executionCount: cellResult.executionCount,
|
|
4331
|
+
isComplete: true
|
|
4332
|
+
});
|
|
4333
|
+
} else {
|
|
4334
|
+
cellsFailed++;
|
|
4335
|
+
wsManager?.send({
|
|
4336
|
+
action: "jupyter_cell_output",
|
|
4337
|
+
requestId,
|
|
4338
|
+
sessionId,
|
|
4339
|
+
jupyterSessionId,
|
|
4340
|
+
cellIndex: codeCellIndex,
|
|
4341
|
+
outputType: "error",
|
|
4342
|
+
content: {
|
|
4343
|
+
ename: cellResult.error?.ename || "ExecutionError",
|
|
4344
|
+
evalue: cellResult.error?.evalue || "Cell execution failed",
|
|
4345
|
+
traceback: cellResult.error?.traceback || []
|
|
4346
|
+
},
|
|
4347
|
+
executionCount: cellResult.executionCount,
|
|
4348
|
+
isComplete: true
|
|
4349
|
+
});
|
|
4350
|
+
logger.warn(
|
|
4351
|
+
`[Keep] Cell ${codeCellIndex + 1} failed: ${cellResult.error?.ename}: ${cellResult.error?.evalue}`
|
|
4352
|
+
);
|
|
4353
|
+
}
|
|
4354
|
+
} catch (cellErr) {
|
|
4355
|
+
cellsFailed++;
|
|
4356
|
+
const errMsg = cellErr instanceof Error ? cellErr.message : String(cellErr);
|
|
4357
|
+
wsManager?.send({
|
|
4358
|
+
action: "jupyter_cell_output",
|
|
4359
|
+
requestId,
|
|
4360
|
+
sessionId,
|
|
4361
|
+
jupyterSessionId,
|
|
4362
|
+
cellIndex: codeCellIndex,
|
|
4363
|
+
outputType: "error",
|
|
4364
|
+
content: {
|
|
4365
|
+
ename: "ExecutionError",
|
|
4366
|
+
evalue: errMsg,
|
|
4367
|
+
traceback: []
|
|
4368
|
+
},
|
|
4369
|
+
executionCount: null,
|
|
4370
|
+
isComplete: true
|
|
4371
|
+
});
|
|
4372
|
+
logger.error(`[Keep] Cell ${codeCellIndex + 1} threw error: ${errMsg}`);
|
|
4373
|
+
}
|
|
4374
|
+
codeCellIndex++;
|
|
4375
|
+
}
|
|
4376
|
+
result = {
|
|
4377
|
+
success: cellsFailed === 0,
|
|
4378
|
+
cellsExecuted,
|
|
4379
|
+
cellsFailed,
|
|
4380
|
+
totalCodeCells,
|
|
4381
|
+
executedNotebook: JSON.stringify(notebook)
|
|
4382
|
+
};
|
|
4383
|
+
} finally {
|
|
4384
|
+
if (jupyterSession) {
|
|
4385
|
+
try {
|
|
4386
|
+
logger.info(`[Keep] Stopping Jupyter session: ${jupyterSession.id}`);
|
|
4387
|
+
await jupyterClient.stopSession(jupyterSession.id);
|
|
4388
|
+
} catch (stopErr) {
|
|
4389
|
+
logger.warn(
|
|
4390
|
+
`[Keep] Failed to stop session: ${stopErr instanceof Error ? stopErr.message : String(stopErr)}`
|
|
4391
|
+
);
|
|
4392
|
+
}
|
|
4393
|
+
}
|
|
4394
|
+
try {
|
|
4395
|
+
await fs.unlink(tempNotebookPath);
|
|
4396
|
+
} catch {
|
|
4397
|
+
}
|
|
4398
|
+
}
|
|
4399
|
+
break;
|
|
4400
|
+
}
|
|
4247
4401
|
default:
|
|
4248
4402
|
throw new Error(`Unknown command type: ${commandType}`);
|
|
4249
4403
|
}
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
findMostSimilarMemento,
|
|
4
4
|
getRelevantMementos
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-UPBT6KT7.js";
|
|
6
|
+
import "./chunk-A5NFPVII.js";
|
|
7
7
|
import "./chunk-PFBYGCOW.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-BCIB6PU6.js";
|
|
9
9
|
export {
|
|
10
10
|
findMostSimilarMemento,
|
|
11
11
|
getRelevantMementos
|
|
@@ -143,7 +143,7 @@ import {
|
|
|
143
143
|
validateUrlForFetch,
|
|
144
144
|
warmUpSettingsCache,
|
|
145
145
|
withRetry
|
|
146
|
-
} from "./chunk-
|
|
146
|
+
} from "./chunk-A5NFPVII.js";
|
|
147
147
|
import {
|
|
148
148
|
Logger,
|
|
149
149
|
NotificationDeduplicator,
|
|
@@ -156,7 +156,7 @@ import {
|
|
|
156
156
|
buildRateLimitLogEntry,
|
|
157
157
|
isNearLimit,
|
|
158
158
|
parseRateLimitHeaders
|
|
159
|
-
} from "./chunk-
|
|
159
|
+
} from "./chunk-BCIB6PU6.js";
|
|
160
160
|
export {
|
|
161
161
|
AIVideoService,
|
|
162
162
|
AWSBackend,
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
SubtractCreditsSchema,
|
|
4
4
|
subtractCredits
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-EYRJEDKD.js";
|
|
6
|
+
import "./chunk-A5NFPVII.js";
|
|
7
7
|
import "./chunk-PFBYGCOW.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-BCIB6PU6.js";
|
|
9
9
|
export {
|
|
10
10
|
SubtractCreditsSchema,
|
|
11
11
|
subtractCredits
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bike4mind/cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.60-feat-jupyter-execution-ui.21619+915612490",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
6
6
|
"license": "UNLICENSED",
|
|
@@ -42,15 +42,15 @@
|
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@anthropic-ai/sdk": "^0.79.0",
|
|
45
|
-
"@aws-sdk/client-apigatewaymanagementapi": "3.
|
|
46
|
-
"@aws-sdk/client-bedrock-runtime": "3.
|
|
47
|
-
"@aws-sdk/client-cloudwatch": "3.
|
|
48
|
-
"@aws-sdk/client-lambda": "3.
|
|
49
|
-
"@aws-sdk/client-s3": "3.
|
|
50
|
-
"@aws-sdk/client-sqs": "3.
|
|
51
|
-
"@aws-sdk/client-transcribe": "3.
|
|
52
|
-
"@aws-sdk/credential-provider-node": "3.972.
|
|
53
|
-
"@aws-sdk/s3-request-presigner": "3.
|
|
45
|
+
"@aws-sdk/client-apigatewaymanagementapi": "^3.1012.0",
|
|
46
|
+
"@aws-sdk/client-bedrock-runtime": "^3.1012.0",
|
|
47
|
+
"@aws-sdk/client-cloudwatch": "^3.1012.0",
|
|
48
|
+
"@aws-sdk/client-lambda": "^3.1012.0",
|
|
49
|
+
"@aws-sdk/client-s3": "^3.1012.0",
|
|
50
|
+
"@aws-sdk/client-sqs": "^3.1012.0",
|
|
51
|
+
"@aws-sdk/client-transcribe": "^3.1012.0",
|
|
52
|
+
"@aws-sdk/credential-provider-node": "^3.972.22",
|
|
53
|
+
"@aws-sdk/s3-request-presigner": "^3.1012.0",
|
|
54
54
|
"@casl/ability": "^6.8.0",
|
|
55
55
|
"@google/genai": "^1.46.0",
|
|
56
56
|
"@joplin/turndown-plugin-gfm": "^1.0.64",
|
|
@@ -115,11 +115,11 @@
|
|
|
115
115
|
"zustand": "^4.5.4"
|
|
116
116
|
},
|
|
117
117
|
"devDependencies": {
|
|
118
|
-
"@bike4mind/agents": "0.2.
|
|
119
|
-
"@bike4mind/common": "2.72.
|
|
120
|
-
"@bike4mind/mcp": "1.33.
|
|
121
|
-
"@bike4mind/services": "2.67.
|
|
122
|
-
"@bike4mind/utils": "2.15.
|
|
118
|
+
"@bike4mind/agents": "0.2.4-feat-jupyter-execution-ui.21619+915612490",
|
|
119
|
+
"@bike4mind/common": "2.72.1-feat-jupyter-execution-ui.21619+915612490",
|
|
120
|
+
"@bike4mind/mcp": "1.33.18-feat-jupyter-execution-ui.21619+915612490",
|
|
121
|
+
"@bike4mind/services": "2.67.1-feat-jupyter-execution-ui.21619+915612490",
|
|
122
|
+
"@bike4mind/utils": "2.15.12-feat-jupyter-execution-ui.21619+915612490",
|
|
123
123
|
"@types/better-sqlite3": "^7.6.13",
|
|
124
124
|
"@types/jsonwebtoken": "^9.0.4",
|
|
125
125
|
"@types/node": "^22.9.0",
|
|
@@ -136,5 +136,5 @@
|
|
|
136
136
|
"optionalDependencies": {
|
|
137
137
|
"@vscode/ripgrep": "^1.17.1"
|
|
138
138
|
},
|
|
139
|
-
"gitHead": "
|
|
139
|
+
"gitHead": "915612490c3ee1d735af5f50d5e6aca991864893"
|
|
140
140
|
}
|