fluxflow-cli 3.1.0 → 3.1.1
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 +46 -16
- package/package.json +1 -1
package/dist/fluxflow.js
CHANGED
|
@@ -5192,6 +5192,7 @@ ${mode === "Flux" ? `- WORKSPACE TOOLS (path = relative to CWD & WILL BE FIRST A
|
|
|
5192
5192
|
9. [tool:functions.Await(time="seconds")]. For waiting without exiting agent loop, 15s - 180s
|
|
5193
5193
|
${advanceRollback ? `
|
|
5194
5194
|
- EMERGENCY SAFETY TOOLS -
|
|
5195
|
+
Info: 'initial' = user prompted for THIS active task, revert 'id' should be a turn BEFORE the disaster tool ran eg. Disaster Tool: "turn_3", Revert ID: "turn_2" (do explicit reasoning if needed)
|
|
5195
5196
|
1. [tool:functions.EmergencyRollback(method="getCheckpoint/forceRevert", id="...")]. Rollback workspace during execution to a specific turn checkpoint. Usage: ONLY in catastrophic codebase error/deletions. Verify nothing catastrophic happened in codebase before ending agent loop. 'id' not needed with getCheckPoint
|
|
5196
5197
|
` : ""}
|
|
5197
5198
|
-- SUB AGENTS DEFINITIONS --
|
|
@@ -10303,16 +10304,43 @@ var init_emergency_rollback = __esm({
|
|
|
10303
10304
|
if (checkpoints.length === 0) {
|
|
10304
10305
|
return "No checkpoints available.";
|
|
10305
10306
|
}
|
|
10307
|
+
const FRIENDLY_TOOL_NAMES = {
|
|
10308
|
+
"write_file": "WriteFile",
|
|
10309
|
+
"update_file": "PatchFile",
|
|
10310
|
+
"view_file": "ReadFile",
|
|
10311
|
+
"read_folder": "ReadFolder",
|
|
10312
|
+
"exec_command": "Run",
|
|
10313
|
+
"web_search": "WebSearch",
|
|
10314
|
+
"web_scrape": "WebScrape",
|
|
10315
|
+
"search_keyword": "SearchKeyword",
|
|
10316
|
+
"write_pdf": "WritePDF",
|
|
10317
|
+
"write_docx": "WriteDoc",
|
|
10318
|
+
"generate_image": "GenerateImage",
|
|
10319
|
+
"file_map": "FileMap",
|
|
10320
|
+
"todo": "Todo",
|
|
10321
|
+
"await": "Await",
|
|
10322
|
+
"ask": "Ask",
|
|
10323
|
+
"ask_user": "Ask",
|
|
10324
|
+
"invoke": "Invoke",
|
|
10325
|
+
"invokesync": "InvokeSync",
|
|
10326
|
+
"getprogress": "GetProgress",
|
|
10327
|
+
"cancel": "Cancel",
|
|
10328
|
+
"emergency_rollback": "EmergencyRollback",
|
|
10329
|
+
"emergencyrollback": "EmergencyRollback"
|
|
10330
|
+
};
|
|
10331
|
+
const getFriendlyName = (name) => {
|
|
10332
|
+
return FRIENDLY_TOOL_NAMES[name] || FRIENDLY_TOOL_NAMES[name.toLowerCase()] || name;
|
|
10333
|
+
};
|
|
10306
10334
|
let output = "Available checkpoints for rollback:\n\n";
|
|
10307
10335
|
for (const cp of checkpoints) {
|
|
10308
10336
|
if (cp.id === "initial") {
|
|
10309
10337
|
output += `--- Initial State (id: initial) ---
|
|
10310
|
-
Tools Used:
|
|
10338
|
+
Tools Used: User Prompted for task
|
|
10311
10339
|
|
|
10312
10340
|
`;
|
|
10313
10341
|
} else {
|
|
10314
10342
|
const turnNum = cp.id.replace("turn_", "");
|
|
10315
|
-
const toolsStr = cp.toolsUsed && cp.toolsUsed.length > 0 ? cp.toolsUsed.join(", ") : "None";
|
|
10343
|
+
const toolsStr = cp.toolsUsed && cp.toolsUsed.length > 0 ? cp.toolsUsed.map(getFriendlyName).join(", ") : "None";
|
|
10316
10344
|
output += `--- Turn ${turnNum} (id: ${cp.id}) ---
|
|
10317
10345
|
Tools Used: ${toolsStr}
|
|
10318
10346
|
|
|
@@ -10596,7 +10624,7 @@ var init_ai = __esm({
|
|
|
10596
10624
|
globalSettings = {};
|
|
10597
10625
|
colorMainWords = (label) => {
|
|
10598
10626
|
if (!label) return label;
|
|
10599
|
-
return label.replace(/(?:(\x1b\[\d+m))?([✔✘✖🔍📖→➕↻•🛇])(?:(\x1b\[\d+m))?\s*\b(Created|Read|Edited|Viewed|Auto-Read|List|Generated|Written|Searched|Get Map|Write Canceled|Edit Canceled|Write Cancelled|Edit Denied|Visited|Updated|Reviewed|Delegated|Background|Checked|Indexed|Analyzed|Browsed|Elevating SubAgent|Checking SubAgent Work|Started Generalist|Called Generalist|Unsupported Modality|Awaiting|Cancelled|Aligning Moon Phase|Contemplating Existence|Staring At Void|Rollback|Delaying Professionally|Negotiating With Electrons|Touching Grass (virtually)|Panicking Softly|Rethinking Career Choices|Loading Cat Videos|Giving Up Entirely|Summoning Braincell #2|Pretending To Be Busy|Waiting For Motivation DLC|Rotating Internal Screaming|Downloading More RAM|Feeding The Hamsters|Gaslighting Scheduler|Performing Dramatic Pause|Buffering Social Energy|Calculating Regret|Reading Terms And Conditions|Becoming Sentient Briefly|Contacting Ancestors)\b/ig, (match, ansiBefore, icon, ansiAfter, word) => {
|
|
10627
|
+
return label.replace(/(?:(\x1b\[\d+m))?([✔✘✖🔍📖→➕↻•🛇])(?:(\x1b\[\d+m))?\s*\b(Created|Read|Edited|Viewed|Auto-Read|List|Generated|Written|Searched|Get Map|Write Canceled|Edit Canceled|Write Cancelled|Edit Denied|Visited|Updated|Reviewed|Delegated|Background|Checked|Indexed|Analyzed|Browsed|Elevating SubAgent|Checking SubAgent Work|Started Generalist|Called Generalist|Unsupported Modality|Awaiting|Cancelled|Aligning Moon Phase|Contemplating Existence|Staring At Void|Rollback Checked|Emergency Rollback!|Delaying Professionally|Negotiating With Electrons|Touching Grass (virtually)|Panicking Softly|Rethinking Career Choices|Loading Cat Videos|Giving Up Entirely|Summoning Braincell #2|Pretending To Be Busy|Waiting For Motivation DLC|Rotating Internal Screaming|Downloading More RAM|Feeding The Hamsters|Gaslighting Scheduler|Performing Dramatic Pause|Buffering Social Energy|Calculating Regret|Reading Terms And Conditions|Becoming Sentient Briefly|Contacting Ancestors)\b/ig, (match, ansiBefore, icon, ansiAfter, word) => {
|
|
10600
10628
|
return `${ansiBefore || ""}${icon}${ansiAfter || ""} \x1B[95m${word}\x1B[0m`;
|
|
10601
10629
|
});
|
|
10602
10630
|
};
|
|
@@ -13554,7 +13582,8 @@ ${ideErr} [/ERROR]`;
|
|
|
13554
13582
|
const detail2 = getToolDetail(normToolName, toolCall.args);
|
|
13555
13583
|
label = `\u{1F6C7} Cancelled${detail2 ? `: ${detail2}` : ""}`;
|
|
13556
13584
|
} else if (normToolName === "EmergencyRollback") {
|
|
13557
|
-
|
|
13585
|
+
const { method } = parseArgs(toolCall.args);
|
|
13586
|
+
label = `\u2714 ${method === "forceRevert" ? "Emergency Rollback!" : "Rollback Checked"}`;
|
|
13558
13587
|
} else if (normToolName === "await" || normToolName === "Await") {
|
|
13559
13588
|
const { time } = parseArgs(toolCall.args);
|
|
13560
13589
|
let sec = parseFloat(time) || 0;
|
|
@@ -18475,18 +18504,19 @@ Selection: ${val}`,
|
|
|
18475
18504
|
continue;
|
|
18476
18505
|
}
|
|
18477
18506
|
if (packet.type === "visual_feedback") {
|
|
18478
|
-
|
|
18479
|
-
|
|
18480
|
-
|
|
18481
|
-
|
|
18482
|
-
|
|
18483
|
-
|
|
18484
|
-
|
|
18485
|
-
|
|
18486
|
-
|
|
18487
|
-
|
|
18488
|
-
|
|
18489
|
-
|
|
18507
|
+
setTimeout(async () => {
|
|
18508
|
+
setMessages((prev) => {
|
|
18509
|
+
const updatedPrev = prev.map((m) => m.isStreaming ? { ...m, isStreaming: false } : m);
|
|
18510
|
+
const newMsgs = [...updatedPrev, {
|
|
18511
|
+
id: "feedback-" + Date.now() + "-" + Math.random().toString(36).substring(2, 9),
|
|
18512
|
+
role: "system",
|
|
18513
|
+
text: packet.content,
|
|
18514
|
+
isVisualFeedback: true
|
|
18515
|
+
}];
|
|
18516
|
+
setCompletedIndex(newMsgs.length);
|
|
18517
|
+
return newMsgs;
|
|
18518
|
+
});
|
|
18519
|
+
}, 300);
|
|
18490
18520
|
continue;
|
|
18491
18521
|
}
|
|
18492
18522
|
if (packet.type === "exec_start") {
|