@bike4mind/cli 0.2.29-fix-6635-allow-explicit-absolute-paths.18826 → 0.2.29-fix-paste-hang-indicator.18877
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-RDMRUAYS.js → artifactExtractor-EE753J4D.js} +1 -1
- package/dist/{chunk-MPSPHOIZ.js → chunk-5GSDPBTM.js} +7 -1
- package/dist/{chunk-T33BVGIR.js → chunk-BCOGDPUB.js} +2 -2
- package/dist/{chunk-TVW4ZESU.js → chunk-BYXFQJYT.js} +10 -1
- package/dist/{chunk-LM4PJCVX.js → chunk-ELTTBWAQ.js} +2 -2
- package/dist/{chunk-WO5GGMEO.js → chunk-PKKJ44C5.js} +2 -2
- package/dist/{chunk-MDOLASLI.js → chunk-S7BPPS33.js} +25 -3
- package/dist/{create-YRA72AUB.js → create-O3PVSKFE.js} +3 -3
- package/dist/index.js +369 -350
- package/dist/{llmMarkdownGenerator-NLBVQLSH.js → llmMarkdownGenerator-IJKJYJ3U.js} +1 -1
- package/dist/{markdownGenerator-FOWCMKGZ.js → markdownGenerator-SJT7AXLT.js} +1 -1
- package/dist/{mementoService-ACNWTJBC.js → mementoService-PKCNMN4V.js} +3 -3
- package/dist/{src-7NOQH3YS.js → src-C5CZFXVM.js} +2 -2
- package/dist/{src-JZ7PFQMP.js → src-GRO5NIC3.js} +3 -1
- package/dist/{store-FU6NDC2W.js → store-K5MB3SE7.js} +1 -1
- package/dist/{subtractCredits-CP4A2VYJ.js → subtractCredits-WZZAP57N.js} +3 -3
- package/package.json +6 -6
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
CurationArtifactType
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-5GSDPBTM.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;
|
|
@@ -165,6 +165,7 @@ var ChatModels;
|
|
|
165
165
|
ChatModels2["GROK_3_MINI_FAST"] = "grok-3-mini-fast";
|
|
166
166
|
ChatModels2["GROK_2"] = "grok-2-1212";
|
|
167
167
|
ChatModels2["GROK_2_VISION"] = "grok-2-vision-1212";
|
|
168
|
+
ChatModels2["GROK_4"] = "grok-4-0709";
|
|
168
169
|
ChatModels2["GROK_BETA"] = "grok-beta";
|
|
169
170
|
ChatModels2["GROK_VISION_BETA"] = "grok-vision-beta";
|
|
170
171
|
})(ChatModels || (ChatModels = {}));
|
|
@@ -1982,9 +1983,13 @@ var OPENAI_IMAGE_QUALITIES = ["standard", "hd", "low", "medium", "high"];
|
|
|
1982
1983
|
var OpenAIImageQualitySchema = z16.enum(OPENAI_IMAGE_QUALITIES);
|
|
1983
1984
|
var OPENAI_IMAGE_STYLES = ["vivid", "natural"];
|
|
1984
1985
|
var OpenAIImageStyleSchema = z16.enum(OPENAI_IMAGE_STYLES);
|
|
1986
|
+
var LEGACY_IMAGE_MODEL_MAP = {
|
|
1987
|
+
"dall-e-3": ImageModels.GPT_IMAGE_1,
|
|
1988
|
+
"dall-e-2": ImageModels.GPT_IMAGE_1
|
|
1989
|
+
};
|
|
1985
1990
|
var OpenAIImageGenerationInput = z16.object({
|
|
1986
1991
|
prompt: z16.string(),
|
|
1987
|
-
model: z16.enum(ALL_IMAGE_MODELS),
|
|
1992
|
+
model: z16.preprocess((val) => typeof val === "string" && Object.prototype.hasOwnProperty.call(LEGACY_IMAGE_MODEL_MAP, val) ? LEGACY_IMAGE_MODEL_MAP[val] : val, z16.enum(ALL_IMAGE_MODELS)),
|
|
1988
1993
|
n: z16.number().min(1).max(10).optional(),
|
|
1989
1994
|
quality: OpenAIImageQualitySchema.optional(),
|
|
1990
1995
|
response_format: z16.enum(["b64_json", "url"]).optional(),
|
|
@@ -7971,6 +7976,7 @@ export {
|
|
|
7971
7976
|
OpenAIImageQualitySchema,
|
|
7972
7977
|
OPENAI_IMAGE_STYLES,
|
|
7973
7978
|
OpenAIImageStyleSchema,
|
|
7979
|
+
LEGACY_IMAGE_MODEL_MAP,
|
|
7974
7980
|
OpenAIImageGenerationInput,
|
|
7975
7981
|
PASSWORD_RULES,
|
|
7976
7982
|
PASSWORD_ERROR_MESSAGES,
|
|
@@ -6,12 +6,12 @@ import {
|
|
|
6
6
|
getSettingsByNames,
|
|
7
7
|
obfuscateApiKey,
|
|
8
8
|
secureParameters
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-S7BPPS33.js";
|
|
10
10
|
import {
|
|
11
11
|
ApiKeyType,
|
|
12
12
|
MementoTier,
|
|
13
13
|
isSupportedEmbeddingModel
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-5GSDPBTM.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/apiKeyService/get.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -49,7 +49,16 @@ var useCliStore = create((set) => ({
|
|
|
49
49
|
// Input state (for Ctrl+C clearing)
|
|
50
50
|
inputValue: "",
|
|
51
51
|
setInputValue: (value) => set({ inputValue: value }),
|
|
52
|
-
clearInput: () => set({ inputValue: "" }),
|
|
52
|
+
clearInput: () => set({ inputValue: "", pastedContent: null, pastedLineCount: 0 }),
|
|
53
|
+
// Paste state
|
|
54
|
+
pastedContent: null,
|
|
55
|
+
pastedLineCount: 0,
|
|
56
|
+
setPastedContent: (content, lineCount) => set({
|
|
57
|
+
pastedContent: content,
|
|
58
|
+
pastedLineCount: lineCount,
|
|
59
|
+
inputValue: content
|
|
60
|
+
}),
|
|
61
|
+
clearPaste: () => set({ pastedContent: null, pastedLineCount: 0, inputValue: "" }),
|
|
53
62
|
// Permission prompt queue
|
|
54
63
|
permissionPrompt: null,
|
|
55
64
|
permissionQueue: [],
|
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
getSettingsMap,
|
|
8
8
|
getSettingsValue,
|
|
9
9
|
secureParameters
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-S7BPPS33.js";
|
|
11
11
|
import {
|
|
12
12
|
KnowledgeType,
|
|
13
13
|
SupportedFabFileMimeTypes
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-5GSDPBTM.js";
|
|
15
15
|
|
|
16
16
|
// ../../b4m-core/packages/services/dist/src/fabFileService/create.js
|
|
17
17
|
import { z } from "zod";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {
|
|
3
3
|
BadRequestError,
|
|
4
4
|
secureParameters
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-S7BPPS33.js";
|
|
6
6
|
import {
|
|
7
7
|
CompletionApiUsageTransaction,
|
|
8
8
|
GenericCreditDeductTransaction,
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
TextGenerationUsageTransaction,
|
|
13
13
|
TransferCreditTransaction,
|
|
14
14
|
VideoGenerationUsageTransaction
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-5GSDPBTM.js";
|
|
16
16
|
|
|
17
17
|
// ../../b4m-core/packages/services/dist/src/creditService/subtractCredits.js
|
|
18
18
|
import { z } from "zod";
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
dayjsConfig_default,
|
|
16
16
|
extractSnippetMeta,
|
|
17
17
|
settingsMap
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-5GSDPBTM.js";
|
|
19
19
|
import {
|
|
20
20
|
Logger
|
|
21
21
|
} from "./chunk-OCYRD7D6.js";
|
|
@@ -1285,11 +1285,14 @@ async function processFabFilesServer(embeddingFactory, fabFiles, userPrompt, max
|
|
|
1285
1285
|
}
|
|
1286
1286
|
switch (modelInfo?.backend) {
|
|
1287
1287
|
case ModelBackend.OpenAI:
|
|
1288
|
-
case ModelBackend.XAI:
|
|
1288
|
+
case ModelBackend.XAI: {
|
|
1289
|
+
const openaiImageBuffer = await storage.download(file.filePath);
|
|
1290
|
+
const { mime: openaiMimeType } = await getFileType(openaiImageBuffer, file.fileName, file.mimeType);
|
|
1291
|
+
const openaiBase64 = openaiImageBuffer.toString("base64");
|
|
1289
1292
|
imageContent.push({
|
|
1290
1293
|
type: "image_url",
|
|
1291
1294
|
image_url: {
|
|
1292
|
-
url:
|
|
1295
|
+
url: `data:${openaiMimeType};base64,${openaiBase64}`
|
|
1293
1296
|
}
|
|
1294
1297
|
});
|
|
1295
1298
|
imageContent.push({
|
|
@@ -1297,6 +1300,7 @@ async function processFabFilesServer(embeddingFactory, fabFiles, userPrompt, max
|
|
|
1297
1300
|
text: `Image URL: ${fileUrl}`
|
|
1298
1301
|
});
|
|
1299
1302
|
break;
|
|
1303
|
+
}
|
|
1300
1304
|
case ModelBackend.Anthropic:
|
|
1301
1305
|
case ModelBackend.Gemini:
|
|
1302
1306
|
case ModelBackend.Bedrock:
|
|
@@ -6889,6 +6893,24 @@ var XAIBackend = class {
|
|
|
6889
6893
|
}
|
|
6890
6894
|
async getModelInfo() {
|
|
6891
6895
|
return [
|
|
6896
|
+
{
|
|
6897
|
+
id: ChatModels.GROK_4,
|
|
6898
|
+
type: "text",
|
|
6899
|
+
name: "Grok 4",
|
|
6900
|
+
backend: ModelBackend.XAI,
|
|
6901
|
+
contextWindow: 256e3,
|
|
6902
|
+
max_tokens: 16384,
|
|
6903
|
+
can_stream: true,
|
|
6904
|
+
pricing: {
|
|
6905
|
+
// $3.00 / 1M Input tokens, $15.00 / 1M Output tokens. @see https://docs.x.ai/developers/models
|
|
6906
|
+
256e3: { input: 3 / 1e6, output: 15 / 1e6 }
|
|
6907
|
+
},
|
|
6908
|
+
can_think: true,
|
|
6909
|
+
supportsVision: true,
|
|
6910
|
+
supportsTools: true,
|
|
6911
|
+
supportsImageVariation: false,
|
|
6912
|
+
description: "xAI's most capable reasoning model. Excels at complex problem-solving, coding, math, and multimodal understanding with 256K context window."
|
|
6913
|
+
},
|
|
6892
6914
|
{
|
|
6893
6915
|
id: ChatModels.GROK_3,
|
|
6894
6916
|
type: "text",
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
import {
|
|
3
3
|
createFabFile,
|
|
4
4
|
createFabFileSchema
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-ELTTBWAQ.js";
|
|
6
|
+
import "./chunk-S7BPPS33.js";
|
|
7
|
+
import "./chunk-5GSDPBTM.js";
|
|
8
8
|
import "./chunk-OCYRD7D6.js";
|
|
9
9
|
export {
|
|
10
10
|
createFabFile,
|