@bike4mind/cli 0.2.11-fix-cli-socket-hangup-error-handling.17320 → 0.2.11-ja-fix-confluence-table-data-5752.17346
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-3KB44W7B.js → artifactExtractor-FNFWQEQU.js} +1 -1
- package/dist/{chunk-HPYQM2B7.js → chunk-FJM3L5N3.js} +2 -2
- package/dist/{chunk-3OX632TE.js → chunk-FQDYYJMI.js} +115 -30
- package/dist/{chunk-7ORA6KGN.js → chunk-LZXUR7SE.js} +2 -2
- package/dist/{chunk-JYH72REB.js → chunk-MNS37QTQ.js} +1 -1
- package/dist/{chunk-7JR6VASX.js → chunk-NBCK5RYI.js} +2 -2
- package/dist/{create-MSSVWSVO.js → create-2NDKBHAN.js} +3 -3
- package/dist/index.js +36 -110
- package/dist/{llmMarkdownGenerator-LCCZ76BQ.js → llmMarkdownGenerator-4HNYPA24.js} +1 -1
- package/dist/{markdownGenerator-4OF7GEBT.js → markdownGenerator-ZYSYZQOV.js} +1 -1
- package/dist/{mementoService-A6UR5AZY.js → mementoService-SGXIM4IA.js} +3 -3
- package/dist/{src-GFWGZLJE.js → src-HFFCVWXX.js} +2 -2
- package/dist/{src-7UYCXFTE.js → src-VSPXREOD.js} +7 -3
- package/dist/{subtractCredits-L52DZ3SP.js → subtractCredits-NJVQR2WJ.js} +3 -3
- package/package.json +6 -6
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
getSettingsMap,
|
|
8
8
|
getSettingsValue,
|
|
9
9
|
secureParameters
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-MNS37QTQ.js";
|
|
11
11
|
import {
|
|
12
12
|
KnowledgeType,
|
|
13
13
|
SupportedFabFileMimeTypes
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-FQDYYJMI.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/fabFileService/create.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -5052,6 +5052,74 @@ function formatUserList(users) {
|
|
|
5052
5052
|
}
|
|
5053
5053
|
|
|
5054
5054
|
// ../../b4m-core/packages/common/dist/src/jira/api.js
|
|
5055
|
+
function wikiMarkupToAdf(text) {
|
|
5056
|
+
const lines = text.split("\n");
|
|
5057
|
+
const content = [];
|
|
5058
|
+
let currentTableRows = [];
|
|
5059
|
+
let inTable = false;
|
|
5060
|
+
for (const line of lines) {
|
|
5061
|
+
const trimmedLine = line.trim();
|
|
5062
|
+
if (trimmedLine.startsWith("||") && trimmedLine.endsWith("||")) {
|
|
5063
|
+
inTable = true;
|
|
5064
|
+
const cells = trimmedLine.slice(2, -2).split("||").map((cell) => cell.trim());
|
|
5065
|
+
const headerRow = {
|
|
5066
|
+
type: "tableRow",
|
|
5067
|
+
content: cells.map((cell) => ({
|
|
5068
|
+
type: "tableHeader",
|
|
5069
|
+
attrs: {},
|
|
5070
|
+
content: [{ type: "paragraph", content: [{ type: "text", text: cell || " " }] }]
|
|
5071
|
+
}))
|
|
5072
|
+
};
|
|
5073
|
+
currentTableRows.push(headerRow);
|
|
5074
|
+
continue;
|
|
5075
|
+
}
|
|
5076
|
+
if (trimmedLine.startsWith("|") && trimmedLine.endsWith("|") && !trimmedLine.startsWith("||")) {
|
|
5077
|
+
inTable = true;
|
|
5078
|
+
const cells = trimmedLine.slice(1, -1).split("|").map((cell) => cell.trim());
|
|
5079
|
+
const dataRow = {
|
|
5080
|
+
type: "tableRow",
|
|
5081
|
+
content: cells.map((cell) => ({
|
|
5082
|
+
type: "tableCell",
|
|
5083
|
+
attrs: {},
|
|
5084
|
+
content: [{ type: "paragraph", content: [{ type: "text", text: cell || " " }] }]
|
|
5085
|
+
}))
|
|
5086
|
+
};
|
|
5087
|
+
currentTableRows.push(dataRow);
|
|
5088
|
+
continue;
|
|
5089
|
+
}
|
|
5090
|
+
if (inTable && currentTableRows.length > 0) {
|
|
5091
|
+
const table = {
|
|
5092
|
+
type: "table",
|
|
5093
|
+
attrs: { isNumberColumnEnabled: false, layout: "default" },
|
|
5094
|
+
content: currentTableRows
|
|
5095
|
+
};
|
|
5096
|
+
content.push(table);
|
|
5097
|
+
currentTableRows = [];
|
|
5098
|
+
inTable = false;
|
|
5099
|
+
}
|
|
5100
|
+
if (trimmedLine) {
|
|
5101
|
+
content.push({
|
|
5102
|
+
type: "paragraph",
|
|
5103
|
+
content: [{ type: "text", text: trimmedLine }]
|
|
5104
|
+
});
|
|
5105
|
+
}
|
|
5106
|
+
}
|
|
5107
|
+
if (currentTableRows.length > 0) {
|
|
5108
|
+
const table = {
|
|
5109
|
+
type: "table",
|
|
5110
|
+
attrs: { isNumberColumnEnabled: false, layout: "default" },
|
|
5111
|
+
content: currentTableRows
|
|
5112
|
+
};
|
|
5113
|
+
content.push(table);
|
|
5114
|
+
}
|
|
5115
|
+
if (content.length === 0) {
|
|
5116
|
+
content.push({ type: "paragraph", content: [{ type: "text", text: " " }] });
|
|
5117
|
+
}
|
|
5118
|
+
return { type: "doc", version: 1, content };
|
|
5119
|
+
}
|
|
5120
|
+
function containsWikiTable(text) {
|
|
5121
|
+
return /^\|\|.+\|\|$/m.test(text) || /^\|(?!\|).+\|$/m.test(text);
|
|
5122
|
+
}
|
|
5055
5123
|
var JiraApi = class {
|
|
5056
5124
|
config;
|
|
5057
5125
|
constructor(config) {
|
|
@@ -5131,16 +5199,21 @@ var JiraApi = class {
|
|
|
5131
5199
|
...customFields
|
|
5132
5200
|
};
|
|
5133
5201
|
if (description) {
|
|
5134
|
-
|
|
5135
|
-
|
|
5136
|
-
|
|
5137
|
-
|
|
5138
|
-
|
|
5139
|
-
|
|
5140
|
-
|
|
5141
|
-
|
|
5142
|
-
|
|
5143
|
-
|
|
5202
|
+
if (containsWikiTable(description)) {
|
|
5203
|
+
console.log("[JIRA-ADF] Converting wiki table to ADF", { length: description.length });
|
|
5204
|
+
fields.description = wikiMarkupToAdf(description);
|
|
5205
|
+
} else {
|
|
5206
|
+
fields.description = {
|
|
5207
|
+
type: "doc",
|
|
5208
|
+
version: 1,
|
|
5209
|
+
content: [
|
|
5210
|
+
{
|
|
5211
|
+
type: "paragraph",
|
|
5212
|
+
content: [{ type: "text", text: description }]
|
|
5213
|
+
}
|
|
5214
|
+
]
|
|
5215
|
+
};
|
|
5216
|
+
}
|
|
5144
5217
|
}
|
|
5145
5218
|
if (assignee) {
|
|
5146
5219
|
fields.assignee = { id: assignee };
|
|
@@ -5166,16 +5239,21 @@ var JiraApi = class {
|
|
|
5166
5239
|
fields.summary = summary;
|
|
5167
5240
|
}
|
|
5168
5241
|
if (description) {
|
|
5169
|
-
|
|
5170
|
-
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
|
|
5178
|
-
|
|
5242
|
+
if (containsWikiTable(description)) {
|
|
5243
|
+
console.log("[JIRA-ADF] Converting wiki table to ADF (update)", { length: description.length });
|
|
5244
|
+
fields.description = wikiMarkupToAdf(description);
|
|
5245
|
+
} else {
|
|
5246
|
+
fields.description = {
|
|
5247
|
+
type: "doc",
|
|
5248
|
+
version: 1,
|
|
5249
|
+
content: [
|
|
5250
|
+
{
|
|
5251
|
+
type: "paragraph",
|
|
5252
|
+
content: [{ type: "text", text: description }]
|
|
5253
|
+
}
|
|
5254
|
+
]
|
|
5255
|
+
};
|
|
5256
|
+
}
|
|
5179
5257
|
}
|
|
5180
5258
|
if (labels) {
|
|
5181
5259
|
fields.labels = labels;
|
|
@@ -5335,16 +5413,21 @@ var JiraApi = class {
|
|
|
5335
5413
|
issuetype: { name: issueTypeName }
|
|
5336
5414
|
};
|
|
5337
5415
|
if (description) {
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
|
|
5346
|
-
|
|
5347
|
-
|
|
5416
|
+
if (containsWikiTable(description)) {
|
|
5417
|
+
console.log("[JIRA-ADF] Converting wiki table to ADF (bulk)", { length: description.length });
|
|
5418
|
+
fields.description = wikiMarkupToAdf(description);
|
|
5419
|
+
} else {
|
|
5420
|
+
fields.description = {
|
|
5421
|
+
type: "doc",
|
|
5422
|
+
version: 1,
|
|
5423
|
+
content: [
|
|
5424
|
+
{
|
|
5425
|
+
type: "paragraph",
|
|
5426
|
+
content: [{ type: "text", text: description }]
|
|
5427
|
+
}
|
|
5428
|
+
]
|
|
5429
|
+
};
|
|
5430
|
+
}
|
|
5348
5431
|
}
|
|
5349
5432
|
if (assignee) {
|
|
5350
5433
|
fields.assignee = { id: assignee };
|
|
@@ -6164,6 +6247,8 @@ export {
|
|
|
6164
6247
|
formatUser,
|
|
6165
6248
|
formatTransitionResult,
|
|
6166
6249
|
formatUserList,
|
|
6250
|
+
wikiMarkupToAdf,
|
|
6251
|
+
containsWikiTable,
|
|
6167
6252
|
JiraApi,
|
|
6168
6253
|
getErrorMessage,
|
|
6169
6254
|
getAtlassianConfig,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {
|
|
3
3
|
BadRequestError,
|
|
4
4
|
secureParameters
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MNS37QTQ.js";
|
|
6
6
|
import {
|
|
7
7
|
GenericCreditDeductTransaction,
|
|
8
8
|
ImageEditUsageTransaction,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
RealtimeVoiceUsageTransaction,
|
|
11
11
|
TextGenerationUsageTransaction,
|
|
12
12
|
TransferCreditTransaction
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-FQDYYJMI.js";
|
|
14
14
|
|
|
15
15
|
// ../../b4m-core/packages/services/dist/src/creditService/subtractCredits.js
|
|
16
16
|
import { z } from "zod";
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
dayjsConfig_default,
|
|
17
17
|
extractSnippetMeta,
|
|
18
18
|
settingsMap
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-FQDYYJMI.js";
|
|
20
20
|
|
|
21
21
|
// ../../b4m-core/packages/utils/dist/src/storage/S3Storage.js
|
|
22
22
|
import { S3Client, PutObjectCommand, DeleteObjectCommand, GetObjectCommand, HeadObjectCommand } from "@aws-sdk/client-s3";
|
|
@@ -6,12 +6,12 @@ import {
|
|
|
6
6
|
getSettingsByNames,
|
|
7
7
|
obfuscateApiKey,
|
|
8
8
|
secureParameters
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-MNS37QTQ.js";
|
|
10
10
|
import {
|
|
11
11
|
ApiKeyType,
|
|
12
12
|
MementoTier,
|
|
13
13
|
isSupportedEmbeddingModel
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-FQDYYJMI.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/apiKeyService/get.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
createFabFile,
|
|
4
4
|
createFabFileSchema
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-FJM3L5N3.js";
|
|
6
|
+
import "./chunk-MNS37QTQ.js";
|
|
7
7
|
import "./chunk-AMDXHL6S.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-FQDYYJMI.js";
|
|
9
9
|
import "./chunk-PDX44BCA.js";
|
|
10
10
|
export {
|
|
11
11
|
createFabFile,
|
package/dist/index.js
CHANGED
|
@@ -4,9 +4,9 @@ import {
|
|
|
4
4
|
getEffectiveApiKey,
|
|
5
5
|
getOpenWeatherKey,
|
|
6
6
|
getSerperKey
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-NBCK5RYI.js";
|
|
8
|
+
import "./chunk-LZXUR7SE.js";
|
|
9
|
+
import "./chunk-FJM3L5N3.js";
|
|
10
10
|
import {
|
|
11
11
|
BFLImageService,
|
|
12
12
|
BaseStorage,
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
OpenAIBackend,
|
|
16
16
|
OpenAIImageService,
|
|
17
17
|
XAIImageService
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-MNS37QTQ.js";
|
|
19
19
|
import {
|
|
20
20
|
Logger
|
|
21
21
|
} from "./chunk-AMDXHL6S.js";
|
|
@@ -73,7 +73,7 @@ import {
|
|
|
73
73
|
XAI_IMAGE_MODELS,
|
|
74
74
|
b4mLLMTools,
|
|
75
75
|
getMcpProviderMetadata
|
|
76
|
-
} from "./chunk-
|
|
76
|
+
} from "./chunk-FQDYYJMI.js";
|
|
77
77
|
import {
|
|
78
78
|
__require
|
|
79
79
|
} from "./chunk-PDX44BCA.js";
|
|
@@ -11253,7 +11253,7 @@ var ServerLlmBackend = class {
|
|
|
11253
11253
|
reject(error);
|
|
11254
11254
|
});
|
|
11255
11255
|
} catch (error) {
|
|
11256
|
-
logger.
|
|
11256
|
+
logger.error("LLM completion failed", error);
|
|
11257
11257
|
if (isAxiosError(error)) {
|
|
11258
11258
|
logger.debug(
|
|
11259
11259
|
`[ServerLlmBackend] Axios error details: ${JSON.stringify({
|
|
@@ -11316,12 +11316,6 @@ var ServerLlmBackend = class {
|
|
|
11316
11316
|
reject(new Error("Cannot connect to Bike4Mind server. Please check your internet connection."));
|
|
11317
11317
|
} else if (error.message.includes("Rate limit exceeded")) {
|
|
11318
11318
|
reject(error);
|
|
11319
|
-
} else if (error.message.includes("socket hang up")) {
|
|
11320
|
-
reject(
|
|
11321
|
-
new Error(
|
|
11322
|
-
"Connection to server was interrupted (socket hang up). This can happen due to server timeouts or network issues. Please try again."
|
|
11323
|
-
)
|
|
11324
|
-
);
|
|
11325
11319
|
} else {
|
|
11326
11320
|
reject(new Error(`Failed to complete LLM request: ${error.message}`));
|
|
11327
11321
|
}
|
|
@@ -11554,7 +11548,7 @@ import { isAxiosError as isAxiosError2 } from "axios";
|
|
|
11554
11548
|
// package.json
|
|
11555
11549
|
var package_default = {
|
|
11556
11550
|
name: "@bike4mind/cli",
|
|
11557
|
-
version: "0.2.11-fix-
|
|
11551
|
+
version: "0.2.11-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
11558
11552
|
type: "module",
|
|
11559
11553
|
description: "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
11560
11554
|
license: "UNLICENSED",
|
|
@@ -11658,10 +11652,10 @@ var package_default = {
|
|
|
11658
11652
|
},
|
|
11659
11653
|
devDependencies: {
|
|
11660
11654
|
"@bike4mind/agents": "0.1.0",
|
|
11661
|
-
"@bike4mind/common": "2.40.1-fix-
|
|
11662
|
-
"@bike4mind/mcp": "1.20.5-fix-
|
|
11663
|
-
"@bike4mind/services": "2.35.1-fix-
|
|
11664
|
-
"@bike4mind/utils": "2.1.5-fix-
|
|
11655
|
+
"@bike4mind/common": "2.40.1-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
11656
|
+
"@bike4mind/mcp": "1.20.5-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
11657
|
+
"@bike4mind/services": "2.35.1-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
11658
|
+
"@bike4mind/utils": "2.1.5-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
11665
11659
|
"@types/better-sqlite3": "^7.6.13",
|
|
11666
11660
|
"@types/diff": "^5.0.9",
|
|
11667
11661
|
"@types/jsonwebtoken": "^9.0.4",
|
|
@@ -11674,7 +11668,7 @@ var package_default = {
|
|
|
11674
11668
|
typescript: "^5.9.3",
|
|
11675
11669
|
vitest: "^3.2.4"
|
|
11676
11670
|
},
|
|
11677
|
-
gitHead: "
|
|
11671
|
+
gitHead: "899c98af0bfb597fe554bd11a5b8555eeae79f70"
|
|
11678
11672
|
};
|
|
11679
11673
|
|
|
11680
11674
|
// src/config/constants.ts
|
|
@@ -11756,21 +11750,9 @@ var SubagentOrchestrator = class {
|
|
|
11756
11750
|
this.beforeRunCallback(subagent, type);
|
|
11757
11751
|
}
|
|
11758
11752
|
const startTime = Date.now();
|
|
11759
|
-
|
|
11760
|
-
|
|
11761
|
-
|
|
11762
|
-
maxIterations
|
|
11763
|
-
});
|
|
11764
|
-
} catch (error) {
|
|
11765
|
-
const duration2 = Date.now() - startTime;
|
|
11766
|
-
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
11767
|
-
this.deps.logger.error(`Subagent failed after ${duration2}ms: ${errorMessage}`);
|
|
11768
|
-
throw new Error(
|
|
11769
|
-
`Subagent execution failed: ${errorMessage}
|
|
11770
|
-
|
|
11771
|
-
This error occurred while running a ${type} subagent. The main conversation has been preserved, and you can retry or continue with other tasks.`
|
|
11772
|
-
);
|
|
11773
|
-
}
|
|
11753
|
+
const result = await subagent.run(task, {
|
|
11754
|
+
maxIterations
|
|
11755
|
+
});
|
|
11774
11756
|
const duration = Date.now() - startTime;
|
|
11775
11757
|
if (this.afterRunCallback) {
|
|
11776
11758
|
this.afterRunCallback(subagent, type);
|
|
@@ -11984,18 +11966,13 @@ function createSubagentDelegateTool(orchestrator, parentSessionId) {
|
|
|
11984
11966
|
}
|
|
11985
11967
|
const thoroughness = params.thoroughness || "medium";
|
|
11986
11968
|
const type = params.type;
|
|
11987
|
-
|
|
11988
|
-
|
|
11989
|
-
|
|
11990
|
-
|
|
11991
|
-
|
|
11992
|
-
|
|
11993
|
-
|
|
11994
|
-
return result.summary;
|
|
11995
|
-
} catch (error) {
|
|
11996
|
-
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
11997
|
-
throw new Error(`Failed to execute ${type} subagent: ${errorMessage}`);
|
|
11998
|
-
}
|
|
11969
|
+
const result = await orchestrator.delegateToSubagent({
|
|
11970
|
+
task: params.task,
|
|
11971
|
+
type,
|
|
11972
|
+
thoroughness,
|
|
11973
|
+
parentSessionId
|
|
11974
|
+
});
|
|
11975
|
+
return result.summary;
|
|
11999
11976
|
},
|
|
12000
11977
|
toolSchema: {
|
|
12001
11978
|
name: "subagent_delegate",
|
|
@@ -12620,31 +12597,6 @@ Remember: Use context from previous messages to understand follow-up questions.$
|
|
|
12620
12597
|
return;
|
|
12621
12598
|
}
|
|
12622
12599
|
useCliStore.getState().setIsThinking(true);
|
|
12623
|
-
const currentSteps = [];
|
|
12624
|
-
const pendingAssistantMessage = {
|
|
12625
|
-
id: uuidv410(),
|
|
12626
|
-
role: "assistant",
|
|
12627
|
-
content: "...",
|
|
12628
|
-
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
12629
|
-
metadata: {
|
|
12630
|
-
steps: []
|
|
12631
|
-
}
|
|
12632
|
-
};
|
|
12633
|
-
const stepHandler = (step) => {
|
|
12634
|
-
currentSteps.push(step);
|
|
12635
|
-
const { pendingMessages, updatePendingMessage } = useCliStore.getState();
|
|
12636
|
-
const lastIdx = pendingMessages.length - 1;
|
|
12637
|
-
if (lastIdx >= 0 && pendingMessages[lastIdx].role === "assistant") {
|
|
12638
|
-
updatePendingMessage(lastIdx, {
|
|
12639
|
-
...pendingMessages[lastIdx],
|
|
12640
|
-
metadata: {
|
|
12641
|
-
...pendingMessages[lastIdx].metadata,
|
|
12642
|
-
steps: [...currentSteps]
|
|
12643
|
-
}
|
|
12644
|
-
});
|
|
12645
|
-
}
|
|
12646
|
-
};
|
|
12647
|
-
state.agent.on("action", stepHandler);
|
|
12648
12600
|
try {
|
|
12649
12601
|
let messageContent = message;
|
|
12650
12602
|
let userMessageContent = message;
|
|
@@ -12659,6 +12611,15 @@ Remember: Use context from previous messages to understand follow-up questions.$
|
|
|
12659
12611
|
content: userMessageContent,
|
|
12660
12612
|
timestamp: (/* @__PURE__ */ new Date()).toISOString()
|
|
12661
12613
|
};
|
|
12614
|
+
const pendingAssistantMessage = {
|
|
12615
|
+
id: uuidv410(),
|
|
12616
|
+
role: "assistant",
|
|
12617
|
+
content: "...",
|
|
12618
|
+
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
12619
|
+
metadata: {
|
|
12620
|
+
steps: []
|
|
12621
|
+
}
|
|
12622
|
+
};
|
|
12662
12623
|
const sessionWithUserMessage = {
|
|
12663
12624
|
...state.session,
|
|
12664
12625
|
messages: [...state.session.messages, userMessage],
|
|
@@ -12712,50 +12673,15 @@ Remember: Use context from previous messages to understand follow-up questions.$
|
|
|
12712
12673
|
setStoreSession(updatedSession);
|
|
12713
12674
|
await state.sessionStore.save(updatedSession);
|
|
12714
12675
|
} catch (error) {
|
|
12715
|
-
|
|
12716
|
-
let displayMessage;
|
|
12676
|
+
useCliStore.getState().clearPendingMessages();
|
|
12717
12677
|
if (error instanceof Error) {
|
|
12718
12678
|
if (error.message.includes("Authentication failed") || error.message.includes("Authentication expired")) {
|
|
12719
|
-
|
|
12720
|
-
|
|
12721
|
-
|
|
12722
|
-
|
|
12723
|
-
${errorMessage}
|
|
12724
|
-
|
|
12725
|
-
\u{1F4A1} This is usually a temporary issue. Please try your request again.`;
|
|
12726
|
-
} else {
|
|
12727
|
-
displayMessage = `\u274C Error
|
|
12728
|
-
|
|
12729
|
-
${errorMessage}`;
|
|
12730
|
-
}
|
|
12731
|
-
} else {
|
|
12732
|
-
displayMessage = `\u274C Error
|
|
12733
|
-
|
|
12734
|
-
${errorMessage}`;
|
|
12735
|
-
}
|
|
12736
|
-
const errorAssistantMessage = {
|
|
12737
|
-
id: pendingAssistantMessage.id,
|
|
12738
|
-
role: "assistant",
|
|
12739
|
-
content: displayMessage,
|
|
12740
|
-
timestamp: pendingAssistantMessage.timestamp,
|
|
12741
|
-
metadata: {
|
|
12742
|
-
steps: currentSteps
|
|
12743
|
-
// Include any steps that were completed before error
|
|
12679
|
+
console.log("\n\u274C Authentication failed");
|
|
12680
|
+
console.log("\u{1F4A1} Run /login to authenticate with your API environment.\n");
|
|
12681
|
+
return;
|
|
12744
12682
|
}
|
|
12745
|
-
};
|
|
12746
|
-
useCliStore.getState().completePendingMessage(0, errorAssistantMessage);
|
|
12747
|
-
const currentSession = useCliStore.getState().session;
|
|
12748
|
-
if (currentSession) {
|
|
12749
|
-
const updatedSession = {
|
|
12750
|
-
...currentSession,
|
|
12751
|
-
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
12752
|
-
};
|
|
12753
|
-
setState((prev) => ({ ...prev, session: updatedSession }));
|
|
12754
|
-
setStoreSession(updatedSession);
|
|
12755
|
-
await state.sessionStore.save(updatedSession);
|
|
12756
12683
|
}
|
|
12757
|
-
|
|
12758
|
-
state.agent.off("action", stepHandler);
|
|
12684
|
+
console.error("Error processing message:", error);
|
|
12759
12685
|
}
|
|
12760
12686
|
};
|
|
12761
12687
|
const handleBashCommand = useCallback(
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
findMostSimilarMemento,
|
|
4
4
|
getRelevantMementos
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-NBCK5RYI.js";
|
|
6
|
+
import "./chunk-MNS37QTQ.js";
|
|
7
7
|
import "./chunk-AMDXHL6S.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-FQDYYJMI.js";
|
|
9
9
|
import "./chunk-PDX44BCA.js";
|
|
10
10
|
export {
|
|
11
11
|
findMostSimilarMemento,
|
|
@@ -120,7 +120,7 @@ import {
|
|
|
120
120
|
validateMermaidSyntax,
|
|
121
121
|
warmUpSettingsCache,
|
|
122
122
|
withRetry
|
|
123
|
-
} from "./chunk-
|
|
123
|
+
} from "./chunk-MNS37QTQ.js";
|
|
124
124
|
import {
|
|
125
125
|
Logger,
|
|
126
126
|
NotificationDeduplicator,
|
|
@@ -129,7 +129,7 @@ import {
|
|
|
129
129
|
postLowCreditsNotificationToSlack,
|
|
130
130
|
postMessageToSlack
|
|
131
131
|
} from "./chunk-AMDXHL6S.js";
|
|
132
|
-
import "./chunk-
|
|
132
|
+
import "./chunk-FQDYYJMI.js";
|
|
133
133
|
import "./chunk-PDX44BCA.js";
|
|
134
134
|
export {
|
|
135
135
|
AWSBackend,
|
|
@@ -229,6 +229,7 @@ import {
|
|
|
229
229
|
canUserDeleteArtifact,
|
|
230
230
|
canUserReadArtifact,
|
|
231
231
|
canUserWriteArtifact,
|
|
232
|
+
containsWikiTable,
|
|
232
233
|
createArtifactId,
|
|
233
234
|
createDefaultPermissions,
|
|
234
235
|
dayjsConfig_default,
|
|
@@ -292,8 +293,9 @@ import {
|
|
|
292
293
|
validateQuest,
|
|
293
294
|
validateQuestMasterArtifactV2,
|
|
294
295
|
validateReactArtifactV2,
|
|
295
|
-
validateSvgArtifactV2
|
|
296
|
-
|
|
296
|
+
validateSvgArtifactV2,
|
|
297
|
+
wikiMarkupToAdf
|
|
298
|
+
} from "./chunk-FQDYYJMI.js";
|
|
297
299
|
import "./chunk-PDX44BCA.js";
|
|
298
300
|
export {
|
|
299
301
|
ALL_IMAGE_MODELS,
|
|
@@ -525,6 +527,7 @@ export {
|
|
|
525
527
|
canUserDeleteArtifact,
|
|
526
528
|
canUserReadArtifact,
|
|
527
529
|
canUserWriteArtifact,
|
|
530
|
+
containsWikiTable,
|
|
528
531
|
createArtifactId,
|
|
529
532
|
createDefaultPermissions,
|
|
530
533
|
dayjsConfig_default as dayjs,
|
|
@@ -588,5 +591,6 @@ export {
|
|
|
588
591
|
validateQuest,
|
|
589
592
|
validateQuestMasterArtifactV2,
|
|
590
593
|
validateReactArtifactV2,
|
|
591
|
-
validateSvgArtifactV2
|
|
594
|
+
validateSvgArtifactV2,
|
|
595
|
+
wikiMarkupToAdf
|
|
592
596
|
};
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
SubtractCreditsSchema,
|
|
4
4
|
subtractCredits
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-LZXUR7SE.js";
|
|
6
|
+
import "./chunk-MNS37QTQ.js";
|
|
7
7
|
import "./chunk-AMDXHL6S.js";
|
|
8
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-FQDYYJMI.js";
|
|
9
9
|
import "./chunk-PDX44BCA.js";
|
|
10
10
|
export {
|
|
11
11
|
SubtractCreditsSchema,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bike4mind/cli",
|
|
3
|
-
"version": "0.2.11-fix-
|
|
3
|
+
"version": "0.2.11-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Interactive CLI tool for Bike4Mind with ReAct agents",
|
|
6
6
|
"license": "UNLICENSED",
|
|
@@ -104,10 +104,10 @@
|
|
|
104
104
|
},
|
|
105
105
|
"devDependencies": {
|
|
106
106
|
"@bike4mind/agents": "0.1.0",
|
|
107
|
-
"@bike4mind/common": "2.40.1-fix-
|
|
108
|
-
"@bike4mind/mcp": "1.20.5-fix-
|
|
109
|
-
"@bike4mind/services": "2.35.1-fix-
|
|
110
|
-
"@bike4mind/utils": "2.1.5-fix-
|
|
107
|
+
"@bike4mind/common": "2.40.1-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
108
|
+
"@bike4mind/mcp": "1.20.5-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
109
|
+
"@bike4mind/services": "2.35.1-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
110
|
+
"@bike4mind/utils": "2.1.5-ja-fix-confluence-table-data-5752.17346+899c98af0",
|
|
111
111
|
"@types/better-sqlite3": "^7.6.13",
|
|
112
112
|
"@types/diff": "^5.0.9",
|
|
113
113
|
"@types/jsonwebtoken": "^9.0.4",
|
|
@@ -120,5 +120,5 @@
|
|
|
120
120
|
"typescript": "^5.9.3",
|
|
121
121
|
"vitest": "^3.2.4"
|
|
122
122
|
},
|
|
123
|
-
"gitHead": "
|
|
123
|
+
"gitHead": "899c98af0bfb597fe554bd11a5b8555eeae79f70"
|
|
124
124
|
}
|