fluxflow-cli 3.2.1 → 3.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/fluxflow.js +52 -23
- package/package.json +1 -1
package/dist/fluxflow.js
CHANGED
|
@@ -4848,10 +4848,10 @@ var init_StatusBar = __esm({
|
|
|
4848
4848
|
init_text();
|
|
4849
4849
|
activeGetMemoryInfo = null;
|
|
4850
4850
|
getLatencyColor = (delay) => {
|
|
4851
|
-
if (delay <=
|
|
4851
|
+
if (delay <= 370) return "#00a564";
|
|
4852
4852
|
if (delay >= 5e3) return "#ff0000";
|
|
4853
4853
|
const points = [
|
|
4854
|
-
{ t:
|
|
4854
|
+
{ t: 370, r: 0, g: 165, b: 100 },
|
|
4855
4855
|
{ t: 800, r: 120, g: 220, b: 80 },
|
|
4856
4856
|
{ t: 1500, r: 250, g: 210, b: 40 },
|
|
4857
4857
|
{ t: 3e3, r: 255, g: 120, b: 0 },
|
|
@@ -4941,7 +4941,7 @@ var init_StatusBar = __esm({
|
|
|
4941
4941
|
let maxLimit = 262144;
|
|
4942
4942
|
if (aiProvider === "NVIDIA" && (activeModel?.includes("glm") || activeModel?.includes("gpt") || activeModel?.includes("qwen"))) {
|
|
4943
4943
|
maxLimit = 128e3;
|
|
4944
|
-
} else if (aiProvider === "DeepSeek" || aiProvider === "Google" && apiTier === "Paid") {
|
|
4944
|
+
} else if (aiProvider === "DeepSeek" || aiProvider === "Google" && apiTier === "Paid" || aiProvider === "NVIDIA" && activeModel.includes("deepseek")) {
|
|
4945
4945
|
maxLimit = 409600;
|
|
4946
4946
|
}
|
|
4947
4947
|
return /* @__PURE__ */ React5.createElement(
|
|
@@ -12082,14 +12082,14 @@ ${originalTextProcessed.length > USER_CONTEXT_LENGTH ? "... (truncated) ...\n\n"
|
|
|
12082
12082
|
return { text: fullText, usageMetadata };
|
|
12083
12083
|
});
|
|
12084
12084
|
};
|
|
12085
|
-
consolidatePastMemories = async (currentChatId, settings) => {
|
|
12085
|
+
consolidatePastMemories = async (currentChatId, settings, tempStorage = null) => {
|
|
12086
12086
|
try {
|
|
12087
12087
|
const { aiProvider = "Google" } = settings;
|
|
12088
|
-
const
|
|
12089
|
-
const totalMemoriesCount = Object.values(
|
|
12090
|
-
if (totalMemoriesCount <=
|
|
12091
|
-
const chatsToSummarize = Object.keys(
|
|
12092
|
-
return id !== currentChatId && Array.isArray(
|
|
12088
|
+
const tempStorage2 = tempStorage2 || readEncryptedJson(TEMP_MEM_FILE, {});
|
|
12089
|
+
const totalMemoriesCount = Object.values(tempStorage2).flat().length;
|
|
12090
|
+
if (totalMemoriesCount <= 5) return;
|
|
12091
|
+
const chatsToSummarize = Object.keys(tempStorage2).filter((id) => {
|
|
12092
|
+
return id !== currentChatId && Array.isArray(tempStorage2[id]) && tempStorage2[id].length > 2;
|
|
12093
12093
|
});
|
|
12094
12094
|
if (chatsToSummarize.length === 0) return;
|
|
12095
12095
|
let prompt = `You are a silent background process for the FluxFlow CLI Agent.
|
|
@@ -12110,7 +12110,7 @@ Chats to process:
|
|
|
12110
12110
|
`;
|
|
12111
12111
|
const cacheStorage = readEncryptedJson(TEMP_MEM_CHAT_FILE, {});
|
|
12112
12112
|
for (const id of chatsToSummarize) {
|
|
12113
|
-
const rawMemories =
|
|
12113
|
+
const rawMemories = tempStorage2[id];
|
|
12114
12114
|
const newMemoryListStr = rawMemories.map((m) => `- ${m}`).join("\n");
|
|
12115
12115
|
const oldSummary = cacheStorage[id];
|
|
12116
12116
|
prompt += `[Chat ID: ${id}]
|
|
@@ -12340,8 +12340,12 @@ Provide a consolidated summary of the entire session.`;
|
|
|
12340
12340
|
}
|
|
12341
12341
|
}
|
|
12342
12342
|
if (isFirstPrompt && isMemoryEnabled) {
|
|
12343
|
-
|
|
12344
|
-
|
|
12343
|
+
const tempStorage2 = readEncryptedJson(TEMP_MEM_FILE, {});
|
|
12344
|
+
const totalMemoriesCount = Object.values(tempStorage2).flat().length;
|
|
12345
|
+
if (totalMemoriesCount > 5) {
|
|
12346
|
+
yield { type: "status", content: "Condensing past chat memories" };
|
|
12347
|
+
await consolidatePastMemories(chatId, settings, tempStorage2);
|
|
12348
|
+
}
|
|
12345
12349
|
}
|
|
12346
12350
|
const tempStorage = readEncryptedJson(TEMP_MEM_FILE, {});
|
|
12347
12351
|
const cacheStorage = readEncryptedJson(TEMP_MEM_CHAT_FILE, {});
|
|
@@ -15849,7 +15853,7 @@ var init_witty_phrases = __esm({
|
|
|
15849
15853
|
"Letting the thoughts marinate",
|
|
15850
15854
|
"Just remembered where I put my keys",
|
|
15851
15855
|
"Pondering the orb",
|
|
15852
|
-
"I've seen things you people wouldn't believe
|
|
15856
|
+
// "I've seen things you people wouldn't believe… like a user who reads loading messages.",
|
|
15853
15857
|
"Initiating thoughtful gaze",
|
|
15854
15858
|
"What's a computer's favorite snack? Microchips.",
|
|
15855
15859
|
"Why do Java developers wear glasses? Because they don't C#.",
|
|
@@ -15868,7 +15872,8 @@ var init_witty_phrases = __esm({
|
|
|
15868
15872
|
"Pretty sure there's a cat walking on the keyboard somewhere",
|
|
15869
15873
|
"Enhancing\u2026 Enhancing\u2026 Still loading.",
|
|
15870
15874
|
"It's not a bug, it's a feature\u2026 of this loading screen.",
|
|
15871
|
-
"Have you tried turning it off and on again?
|
|
15875
|
+
"Have you tried turning it off and on again?",
|
|
15876
|
+
// 'Have you tried turning it off and on again? (The loading screen, not me.)',
|
|
15872
15877
|
"Constructing additional pylons",
|
|
15873
15878
|
"New line? That\u2019s Ctrl+J.",
|
|
15874
15879
|
"Releasing the HypnoDrones",
|
|
@@ -16011,9 +16016,9 @@ var init_GlintText = __esm({
|
|
|
16011
16016
|
"src/components/GlintText.jsx"() {
|
|
16012
16017
|
GlintText = ({
|
|
16013
16018
|
text,
|
|
16014
|
-
baseColor = "
|
|
16019
|
+
baseColor = "grey",
|
|
16015
16020
|
glintColor = "gray",
|
|
16016
|
-
speed =
|
|
16021
|
+
speed = 200,
|
|
16017
16022
|
glintWidth = 6,
|
|
16018
16023
|
typeSpeed = 30,
|
|
16019
16024
|
// 👈 New prop! How fast it backspaces and types! ⌨️
|
|
@@ -16028,7 +16033,7 @@ var init_GlintText = __esm({
|
|
|
16028
16033
|
return () => clearInterval(timer);
|
|
16029
16034
|
}, [displayedText.length, speed, glintWidth]);
|
|
16030
16035
|
useEffect11(() => {
|
|
16031
|
-
if (text && text.includes("Trying to reach")) {
|
|
16036
|
+
if (text && text.includes("Trying to reach") && displayedText && displayedText.includes("Trying to reach")) {
|
|
16032
16037
|
setDisplayedText(text);
|
|
16033
16038
|
return;
|
|
16034
16039
|
}
|
|
@@ -19201,6 +19206,30 @@ Selection: ${val}`,
|
|
|
19201
19206
|
useEffect12(() => {
|
|
19202
19207
|
setSelectedIndex(0);
|
|
19203
19208
|
}, [suggestions]);
|
|
19209
|
+
const [suggestionVisibleCount, setSuggestionVisibleCount] = useState15(0);
|
|
19210
|
+
const prevSuggestionsLenRef = useRef4(0);
|
|
19211
|
+
useEffect12(() => {
|
|
19212
|
+
const wasOpen = prevSuggestionsLenRef.current > 0;
|
|
19213
|
+
const isOpen = suggestions.length > 0;
|
|
19214
|
+
prevSuggestionsLenRef.current = suggestions.length;
|
|
19215
|
+
if (!isOpen) {
|
|
19216
|
+
setSuggestionVisibleCount(0);
|
|
19217
|
+
return;
|
|
19218
|
+
}
|
|
19219
|
+
if (!wasOpen) {
|
|
19220
|
+
setSuggestionVisibleCount(1);
|
|
19221
|
+
return;
|
|
19222
|
+
}
|
|
19223
|
+
setSuggestionVisibleCount(suggestions.length);
|
|
19224
|
+
}, [suggestions]);
|
|
19225
|
+
useEffect12(() => {
|
|
19226
|
+
if (suggestionVisibleCount > 0 && suggestionVisibleCount < suggestions.length) {
|
|
19227
|
+
const t = setTimeout(() => {
|
|
19228
|
+
setSuggestionVisibleCount((prev) => Math.min(prev + 1, suggestions.length));
|
|
19229
|
+
}, 5);
|
|
19230
|
+
return () => clearTimeout(t);
|
|
19231
|
+
}
|
|
19232
|
+
}, [suggestionVisibleCount, suggestions.length]);
|
|
19204
19233
|
useEffect12(() => {
|
|
19205
19234
|
if (activeView !== "providerBudgetSelect") return;
|
|
19206
19235
|
const PBS_PROVIDERS = ["Google", "DeepSeek", "NVIDIA", "OpenRouter"];
|
|
@@ -20161,14 +20190,14 @@ Selection: ${val}`,
|
|
|
20161
20190
|
GlintText_default,
|
|
20162
20191
|
{
|
|
20163
20192
|
text: statusText.trimEnd(),
|
|
20164
|
-
baseColor: "#
|
|
20165
|
-
glintColor: "#
|
|
20193
|
+
baseColor: "#B5B8D9",
|
|
20194
|
+
glintColor: "#BFD4DB",
|
|
20166
20195
|
speed: 60,
|
|
20167
20196
|
italic: true,
|
|
20168
20197
|
glintWidth: 2,
|
|
20169
20198
|
typeSpeed: 10
|
|
20170
20199
|
}
|
|
20171
|
-
), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, activeTime > 0 ? `(${activeTime.toFixed(0)}s)` : "")) : /* @__PURE__ */ React16.createElement(Text16, { color: "grey", italic: true }, input.length > 0 && escPressCount ? "Press ESC again to clear input" : hasPasteBlock ? "Press CTRL + O to expand" : "Waiting for input...")), /* @__PURE__ */ React16.createElement(Box14, null, isProcessing && Date.now() - lastChunkTime > 15e3 && !activeSubagents.some((sa) => sa.status === "running" && !statusText.toLowerCase().includes("waiting")) ? /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(
|
|
20200
|
+
), /* @__PURE__ */ React16.createElement(Text16, { color: "gray" }, activeTime > 0 ? `(${activeTime.toFixed(0)}s)` : "")) : /* @__PURE__ */ React16.createElement(Text16, { color: "grey", italic: true }, input.length > 0 && escPressCount ? "Press ESC again to clear input" : hasPasteBlock ? "Press CTRL + O to expand" : "Waiting for input...")), /* @__PURE__ */ React16.createElement(Box14, null, isProcessing && Date.now() - lastChunkTime > 15e3 && !activeSubagents.some((sa) => sa.status === "running" && !statusText.toLowerCase().includes("waiting")) ? /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(GlintText_default, { text: "Waiting for API", baseColor: "white", glintColor: "gray", glintWidth: 4, speed: 80 }), /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true }, " \u2503 ")) : wittyPhrase ? /* @__PURE__ */ React16.createElement(Box14, null, /* @__PURE__ */ React16.createElement(GlintText_default, { text: wittyPhrase, italic: true, speed: 80, typeSpeed: 15 }), /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true }, " \u2503 ")) : null, /* @__PURE__ */ React16.createElement(GlintText_default, { text: tempModelOverride || activeModel.split("/")[1] || activeModel, baseColor: "white", glintColor: "gray", glintWidth: 3 }))), /* @__PURE__ */ React16.createElement(Box14, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React16.createElement(Box14, { width: "100%", height: 1, overflow: "hidden" }, /* @__PURE__ */ React16.createElement(Text16, { color: "#555555" }, "\u2584".repeat(Math.max(1, terminalSize.columns)))), /* @__PURE__ */ React16.createElement(
|
|
20172
20201
|
Box14,
|
|
20173
20202
|
{
|
|
20174
20203
|
backgroundColor: "#555555",
|
|
@@ -20281,7 +20310,7 @@ Selection: ${val}`,
|
|
|
20281
20310
|
}
|
|
20282
20311
|
return /* @__PURE__ */ React16.createElement(Text16, { color: "gray", dimColor: true, italic: true }, "Paid API Strategy has more models. Configure ", /* @__PURE__ */ React16.createElement(Text16, { color: "cyan", underline: true }, `\x1B]8;;${url}\x07${label}\x1B]8;;\x07`), " & /settings");
|
|
20283
20312
|
})() : null),
|
|
20284
|
-
visible.map((s, i) => {
|
|
20313
|
+
visible.slice(0, suggestionVisibleCount).map((s, i) => {
|
|
20285
20314
|
const actualIdx = startIdx + i;
|
|
20286
20315
|
const isActive = actualIdx === selectedIndex;
|
|
20287
20316
|
const isGemmaDisabled = s.cmd === "gemma-4-31b-it" && apiTier !== "Free";
|
|
@@ -20592,10 +20621,10 @@ var init_app = __esm({
|
|
|
20592
20621
|
})();
|
|
20593
20622
|
cachedShortcut = "Ctrl + Enter";
|
|
20594
20623
|
getLatencyColor2 = (delay) => {
|
|
20595
|
-
if (delay <=
|
|
20624
|
+
if (delay <= 370) return "#00a564";
|
|
20596
20625
|
if (delay >= 5e3) return "#ff0000";
|
|
20597
20626
|
const points = [
|
|
20598
|
-
{ t:
|
|
20627
|
+
{ t: 370, r: 0, g: 165, b: 100 },
|
|
20599
20628
|
{ t: 800, r: 120, g: 220, b: 80 },
|
|
20600
20629
|
{ t: 1500, r: 250, g: 210, b: 40 },
|
|
20601
20630
|
{ t: 3e3, r: 255, g: 120, b: 0 },
|