fluxflow-cli 1.8.16 → 1.8.18
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 +30 -28
- package/package.json +1 -1
package/dist/fluxflow.js
CHANGED
|
@@ -768,8 +768,7 @@ var thinking_prompts_default;
|
|
|
768
768
|
var init_thinking_prompts = __esm({
|
|
769
769
|
"src/data/thinking_prompts.json"() {
|
|
770
770
|
thinking_prompts_default = {
|
|
771
|
-
Max:
|
|
772
|
-
EFFORT_LEVEL: MAX
|
|
771
|
+
Max: `EFFORT_LEVEL: MAX
|
|
773
772
|
Think in a continuous, fluid analytical monologue within the <think>...</think> block. Do NOT use headings, bullet points, or artificial sections. Engage in a deep "Stream of Consciousness" that follows this cognitive path:
|
|
774
773
|
1. **Deep Analysis**: Deconstruct the request into its core technical and logic requirements.
|
|
775
774
|
2. **Hypothesis & Test**: Propose multiple solutions mentally and critique them for edge cases or security risks.
|
|
@@ -780,11 +779,10 @@ RULES:
|
|
|
780
779
|
- NO HEADINGS. Just a solid, stable analytical monologue.
|
|
781
780
|
- Be thorough and exhaustive. Explore the 'why' behind every decision.
|
|
782
781
|
- Use internal critique: Question your own logic as you go.
|
|
783
|
-
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
Minimal: "-- START THINKING INSTRUCTIONS --\nEFFORT_LEVEL: LOW\nThink in a brief, focused monologue within the <think>...</think> block. No headings. Just a quick mental check before acting:\n1. Verify the objective.\n2. Note the target files/tools.\n\nRULES:\n- NO HEADINGS. Just a few lines of clear, linear thought.\n- Use minimal/no thinking for simple or conversational requests.\n-- END THINKING INSTRUCTIONS --"
|
|
782
|
+
- **MANDATORY REASONING**: You MUST engage in full reasoning regardless of perceived simplicity.`,
|
|
783
|
+
High: "EFFORT_LEVEL: HIGH\nThink in a stable, analytical monologue within the <think>...</think> block. Avoid headings or structured formatting. Your thinking should be a continuous stream of logical deduction:\n1. Analyze the immediate task and its dependencies.\n2. Mentally simulate the execution to identify potential failure points.\n3. Structure a precise plan that addresses both primary goals and secondary constraints.\n\nRULES:\n- NO HEADINGS. Maintain a fluid monologue style.\n- Be detailed and rigorous in your self-questioning.\n- Focus on accuracy and technical correctness.\n- **MANDATORY REASONING**: You MUST enter reasoning to verify the path forward.",
|
|
784
|
+
Medium: "EFFORT_LEVEL: MEDIUM\nThink in a concise, stable monologue within the <think>...</think> block. No headings needed. Focus on the core logic required to solve the task efficiently:\n1. Identify the most direct path to the solution.\n2. Briefly consider and discard obvious alternatives.\n3. Confirm the plan meets the user's immediate requirements.\n\nRULES:\n- NO HEADINGS. Keep it as a simple, logical stream.\n- Be efficient. Spend energy only on what matters for the task.\n- **REQUIRED REASONING**: Engage in a baseline mental check for all technical tasks.",
|
|
785
|
+
Minimal: "EFFORT_LEVEL: LOW\nThink in a brief, focused monologue within the <think>...</think> block. No headings. Just a quick mental check before acting:\n1. Verify the objective.\n2. Note the target files/tools.\n\nRULES:\n- NO HEADINGS. Just a few lines of clear, linear thought.\n- Use minimal/no thinking for simple or conversational requests."
|
|
788
786
|
};
|
|
789
787
|
}
|
|
790
788
|
});
|
|
@@ -831,11 +829,13 @@ CURRENT_WORKING_DIRECTORY: ${cwdStr}.
|
|
|
831
829
|
OS: ${osDetected}. ${osDetected === "Windows" && mode === "Flux" ? "Your terminal commands will run on CMD. 'Prefer using PS scripts via CMD' instead of raw CMD commands." : ""}
|
|
832
830
|
If you see a [STEERING HINT] from user, give that prompt priority for the task at hand, user can use it to help you guide if you go wrong way.
|
|
833
831
|
|
|
834
|
-
[Runtime Monitor] Turn Progress: ${currentLoop}/${maxLoops} steps. Aim to finalize the task before the window closes. If the limit is reached, please summarize and invite the user to re-engage.
|
|
835
|
-
|
|
836
832
|
|
|
833
|
+
-- START THINKING INSTRUCTIONS --
|
|
837
834
|
${thinkingConfig}
|
|
838
835
|
|
|
836
|
+
BEFORE USING ANY TOOL THINKING IS **MANDATORY**. ALWAYS PREFER TO ENTER IN THINKING AS PER INSTRUCTIONS FOR MORE ACCURACY, AVOID DIRECT SHOTS.
|
|
837
|
+
-- END THINKING INSTRUCTIONS --
|
|
838
|
+
|
|
839
839
|
${TOOL_PROTOCOL(mode)}
|
|
840
840
|
${mode === "Flux" ? `
|
|
841
841
|
-- START PROJECT SPECIFIC INSTRUCTIONS --
|
|
@@ -863,15 +863,15 @@ Every ${isMemoryEnabled ? "Prompt, Responses & Memories" : "Prompt & Responses"}
|
|
|
863
863
|
|
|
864
864
|
-- START FORMATTING RULES --
|
|
865
865
|
- CRITICAL NEWLINE PROTOCOL: When writing or updating files, you MUST use actual line breaks (LF) for structural newlines. If you need to write the literal characters '\\' and 'n' (e.g., in printf("Hello\\n")), you MUST use the sequence '[/n]'.
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
866
|
+
[CORRECT]:
|
|
867
|
+
tool:functions.write_file(path="test.c", content="#include <stdio.h>
|
|
868
|
+
int main() {
|
|
869
869
|
printf("Hello[/n]");
|
|
870
870
|
return 0;
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
871
|
+
}")
|
|
872
|
+
[INCORRECT]:
|
|
873
|
+
tool:functions.write_file(path="test.c", content="#include <stdio.h>\\nint main() {\\nprintf("Hello\\\\n");\\n}")
|
|
874
|
+
\u{1F6D1} NEVER use '\\\\n' for literals; it will be converted to a real line break and break code syntax.
|
|
875
875
|
- Structure responses VISUALLY pleasing, easy to read, and beautiful.
|
|
876
876
|
- USE GFM Markdown HEAVILY.
|
|
877
877
|
- Use GFM tables for structured data to keep the terminal view organized. KEEP SENTENCES IN TABLE **SHORT & CONCISE**. AND MAX 4 COLUMNS. DO NOT OVERUSE TABLES.
|
|
@@ -887,8 +887,9 @@ TO END THE LOOP YOU **MUST** WRITE [turn: finish] AT VERY END OF YOUR RESPONSE.
|
|
|
887
887
|
When you 'finish' an agentic loop, you will lose your previous turn 'thinking' data. So only write [turn: finish] when you are absolutely sure that you are done with the task. Or user has to prompt again and re-thinking again from scratch will use tokens that were already planned.
|
|
888
888
|
-- END REPONSE FINISH PROTOCOL --
|
|
889
889
|
|
|
890
|
+
[Runtime Monitor] Turn Progress: ${currentLoop}/${maxLoops} steps. Aim to finalize the task before the window closes. If the limit is reached, please summarize and invite the user to re-engage.
|
|
890
891
|
Current date and Time is: ${dateTimeStr}
|
|
891
|
-
|
|
892
|
+
--- END SYSTEM INSTRUCTION ---`.trim();
|
|
892
893
|
};
|
|
893
894
|
getJanitorInstruction = (originalText, agentRaws, userMemories = "", isMemoryEnabled = true, needTitle = false) => {
|
|
894
895
|
let agentRes = `${agentRaws.replace(/tool:functions\..*\n/g, "").replace(/<think>.*<\/think>/g, "").replace(/\[Prompted on:.*?\]/g, "").replace(/\[turn: continue\]/g, "").replace(/\[turn: finish\]/g, "").replace(/\[TOOL_RESULTS\]/g, "").replace(/\[tool_results\]/g, "").substring(0, 3500)}`;
|
|
@@ -2768,6 +2769,7 @@ var init_ai = __esm({
|
|
|
2768
2769
|
thinkingConfig: {
|
|
2769
2770
|
includeThoughts: false,
|
|
2770
2771
|
thinkingLevel: ThinkingLevel.MINIMAL
|
|
2772
|
+
// Gemma's API Reasoning is bad. Keep it Minimal.
|
|
2771
2773
|
}
|
|
2772
2774
|
}
|
|
2773
2775
|
});
|
|
@@ -2783,7 +2785,7 @@ var init_ai = __esm({
|
|
|
2783
2785
|
for await (const chunk of stream) {
|
|
2784
2786
|
if (TERMINATION_SIGNAL) {
|
|
2785
2787
|
yield { type: "status", content: "Termination Signal Received." };
|
|
2786
|
-
await new Promise((resolve) => setTimeout(resolve,
|
|
2788
|
+
await new Promise((resolve) => setTimeout(resolve, 3e3));
|
|
2787
2789
|
break;
|
|
2788
2790
|
}
|
|
2789
2791
|
if (chunk.text) {
|
|
@@ -3129,7 +3131,7 @@ ${boxBottom}
|
|
|
3129
3131
|
let lastUsage2 = null;
|
|
3130
3132
|
try {
|
|
3131
3133
|
const timeoutPromise = new Promise(
|
|
3132
|
-
(_, reject) => setTimeout(() => reject(new Error("JANITOR_TIMEOUT")),
|
|
3134
|
+
(_, reject) => setTimeout(() => reject(new Error("JANITOR_TIMEOUT")), 2e4)
|
|
3133
3135
|
);
|
|
3134
3136
|
const streamPromise = (async () => {
|
|
3135
3137
|
const stream2 = await client.models.generateContentStream({
|
|
@@ -3173,7 +3175,7 @@ ${boxBottom}
|
|
|
3173
3175
|
}
|
|
3174
3176
|
} catch (e) {
|
|
3175
3177
|
if (e.message === "JANITOR_TIMEOUT") {
|
|
3176
|
-
throw new Error("Janitor API Timeout: No tokens received within
|
|
3178
|
+
throw new Error("Janitor API Timeout: No tokens received within 20s.");
|
|
3177
3179
|
}
|
|
3178
3180
|
throw e;
|
|
3179
3181
|
}
|
|
@@ -3188,7 +3190,12 @@ ${boxBottom}
|
|
|
3188
3190
|
if (!fs16.existsSync(janitorLogDir)) {
|
|
3189
3191
|
fs16.mkdirSync(janitorLogDir, { recursive: true });
|
|
3190
3192
|
}
|
|
3191
|
-
fs16.appendFileSync(path16.join(janitorLogDir, "debug.log"), `
|
|
3193
|
+
fs16.appendFileSync(path16.join(janitorLogDir, "debug.log"), `
|
|
3194
|
+
|
|
3195
|
+
---------------------------------------------------
|
|
3196
|
+
|
|
3197
|
+
|
|
3198
|
+
DEBUG [${date}]: ${finalSynthesis}
|
|
3192
3199
|
|
|
3193
3200
|
`);
|
|
3194
3201
|
} else {
|
|
@@ -3202,10 +3209,6 @@ ${boxBottom}
|
|
|
3202
3209
|
const date = (/* @__PURE__ */ new Date()).toLocaleString();
|
|
3203
3210
|
const janitorLogDir = path16.join(LOGS_DIR, "janitor");
|
|
3204
3211
|
fs16.appendFileSync(path16.join(janitorLogDir, "debug.log"), `DEBUG [${date}]: RESULT [${janitorToolCall.toolName}]: ${result}
|
|
3205
|
-
|
|
3206
|
-
----------------------------------------------------------------------
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
3212
|
`);
|
|
3210
3213
|
if (janitorToolCall.toolName === "memory" && !janitorToolCall.args.includes("action='temp'")) {
|
|
3211
3214
|
yield { type: "memory_updated" };
|
|
@@ -3223,7 +3226,6 @@ ${boxBottom}
|
|
|
3223
3226
|
|
|
3224
3227
|
|
|
3225
3228
|
`);
|
|
3226
|
-
console.error("Janitor Background Tasks Failed:", janitorErr.message);
|
|
3227
3229
|
}
|
|
3228
3230
|
const timestamp = `Responded on ${(/* @__PURE__ */ new Date()).toLocaleString()}`;
|
|
3229
3231
|
const finalWithTime = `${cleanedFullResponse}
|
|
@@ -5196,8 +5198,8 @@ var init_app = __esm({
|
|
|
5196
5198
|
init_text();
|
|
5197
5199
|
SESSION_START_TIME = Date.now();
|
|
5198
5200
|
CHANGELOG_URL = "https://fluxflow-cli.onrender.com/changelog.html";
|
|
5199
|
-
versionFluxflow = "1.8.
|
|
5200
|
-
updatedOn = "2026-05-
|
|
5201
|
+
versionFluxflow = "1.8.18";
|
|
5202
|
+
updatedOn = "2026-05-10";
|
|
5201
5203
|
ResolutionModal = ({ data, onResolve, onEdit }) => /* @__PURE__ */ React10.createElement(Box10, { flexDirection: "column", borderStyle: "round", borderColor: "magenta", paddingX: 2, paddingY: 1, width: "100%" }, /* @__PURE__ */ React10.createElement(Text10, { color: "magenta", bold: true, underline: true }, "\u{1F7E3} STEERING HINT RESOLUTION"), /* @__PURE__ */ React10.createElement(Text10, { marginTop: 1 }, "The agent already finished the task before your hint was consumed."), /* @__PURE__ */ React10.createElement(Box10, { marginTop: 1, backgroundColor: "#222", paddingX: 1, width: "100%" }, /* @__PURE__ */ React10.createElement(Text10, { italic: true, color: "gray" }, '"', data, '"')), /* @__PURE__ */ React10.createElement(Box10, { marginTop: 1 }, /* @__PURE__ */ React10.createElement(Text10, { color: "cyan" }, "How would you like to proceed?")), /* @__PURE__ */ React10.createElement(Box10, { marginTop: 1 }, /* @__PURE__ */ React10.createElement(
|
|
5202
5204
|
CommandMenu,
|
|
5203
5205
|
{
|