fluxflow-cli 5.4.1 → 5.5.0
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/README.md +1 -1
- package/dist/chunks/{ai-TVKJMVCH.js → ai-6AZZQUJJ.js} +1 -1
- package/dist/chunks/answerSubagent-LFLPQQSS.js +1 -0
- package/dist/chunks/{app-HBLCJLMN.js → app-SKIGDYWL.js} +14 -14
- package/dist/chunks/ask_user-4KTNP4MZ.js +1 -0
- package/dist/chunks/{auto_completion-SGFPH6MP.js → auto_completion-ZYVGXNQC.js} +1 -1
- package/dist/chunks/{awaitSubagent-JKQ2EHVY.js → awaitSubagent-ZXLUWTW7.js} +1 -1
- package/dist/chunks/cancel-C2BQ3FGV.js +1 -0
- package/dist/chunks/chat-34HLGFEJ.js +1 -0
- package/dist/chunks/{chunk-BNKY5QOA.js → chunk-5KBOEKGE.js} +6 -6
- package/dist/chunks/chunk-H2EXH5PL.js +898 -0
- package/dist/chunks/chunk-JWNCKRN6.js +4 -0
- package/dist/chunks/{chunk-4PTLFXTU.js → chunk-O74INBF3.js} +3 -3
- package/dist/chunks/{chunk-RINQH4H4.js → chunk-YI3O7C3D.js} +6 -6
- package/dist/chunks/{click-WWAFZ4BZ.js → click-M5D2RARW.js} +2 -2
- package/dist/chunks/computer_action-N7WIG3L4.js +1 -0
- package/dist/chunks/drag-K5ITERVW.js +1 -0
- package/dist/chunks/{emergency_rollback-J3SMQXBP.js → emergency_rollback-X55BPJ7Q.js} +1 -1
- package/dist/chunks/{exec_command-SQB5LU5X.js → exec_command-QBBSYF2H.js} +1 -1
- package/dist/chunks/{file_map-U6SWDUPK.js → file_map-3YMVODEE.js} +8 -8
- package/dist/chunks/find_file-RBJ4LKPD.js +4 -0
- package/dist/chunks/generate_image-53KQ3EDL.js +1 -0
- package/dist/chunks/{getProgress-J34K43Y7.js → getProgress-4D67AF3H.js} +2 -2
- package/dist/chunks/invoke-GUW4734N.js +6 -0
- package/dist/chunks/invokeSync-2PXPUJSJ.js +7 -0
- package/dist/chunks/key_press-RQ32VDHR.js +1 -0
- package/dist/chunks/keyboard_typing-BH4JHUQO.js +1 -0
- package/dist/chunks/{read_folder-UWFC5DNX.js → read_folder-OJ7UWWOR.js} +1 -1
- package/dist/chunks/recapture_screen-YJNK64KL.js +1 -0
- package/dist/chunks/scroll-IQUZ3QLU.js +1 -0
- package/dist/chunks/search_keyword-2JQ75HEQ.js +9 -0
- package/dist/chunks/steerSubagent-UNAOFQZJ.js +1 -0
- package/dist/chunks/{todo-ZFQ6BQVI.js → todo-OX7SMIKN.js} +2 -2
- package/dist/chunks/update_file-2EZILIMQ.js +15 -0
- package/dist/chunks/view_file-XYWGDYAY.js +1 -0
- package/dist/chunks/wait-RQSCCCXW.js +1 -0
- package/dist/chunks/{web_search-MOI3CNWS.js → web_search-B2XM4T5D.js} +11 -11
- package/dist/chunks/write_docx-BMIF6ZDY.js +13 -0
- package/dist/chunks/{write_file-MNAF43T6.js → write_file-O3LLIRLR.js} +1 -1
- package/dist/chunks/write_pdf-CTBFENCU.js +31 -0
- package/dist/cli.js +4 -4
- package/dist/package.json +2 -2
- package/package.json +2 -2
- package/dist/chunks/answerSubagent-BPNNJXPC.js +0 -1
- package/dist/chunks/ask_user-K2DLZF6H.js +0 -1
- package/dist/chunks/cancel-F3ZOEBKW.js +0 -1
- package/dist/chunks/chat-V5FZDYET.js +0 -1
- package/dist/chunks/chunk-AUXKQKSZ.js +0 -888
- package/dist/chunks/chunk-Y5JU726N.js +0 -4
- package/dist/chunks/computer_action-B6QH77NT.js +0 -1
- package/dist/chunks/drag-3VRYDGVU.js +0 -1
- package/dist/chunks/find_file-GBEBP5NZ.js +0 -4
- package/dist/chunks/generate_image-2JIYAW5L.js +0 -1
- package/dist/chunks/invoke-JSHBXNXZ.js +0 -6
- package/dist/chunks/invokeSync-NP7Z3LUE.js +0 -3
- package/dist/chunks/key_press-J2ZSWOT2.js +0 -1
- package/dist/chunks/keyboard_typing-FFC7OTDM.js +0 -1
- package/dist/chunks/recapture_screen-P7YVVVSF.js +0 -1
- package/dist/chunks/scroll-GBV6YRQT.js +0 -1
- package/dist/chunks/search_keyword-KE5VBMVA.js +0 -9
- package/dist/chunks/steerSubagent-UETXH2CB.js +0 -1
- package/dist/chunks/update_file-C5HRYCQN.js +0 -15
- package/dist/chunks/view_file-PEZ7HS36.js +0 -1
- package/dist/chunks/wait-TJR6LAR4.js +0 -1
- package/dist/chunks/write_docx-A3GAUZEW.js +0 -13
- package/dist/chunks/write_pdf-YQ3JTZ5U.js +0 -31
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as n}from"./chunk-JWNCKRN6.js";var u=async(c,e)=>{let t=n(c,["question"]),{question:i}=t;if(!i)return'ERROR: Missing "question" argument for ask.';if(!e.onAskUser)return"ERROR: onAskUser callback not provided in tool context.";let o=[];Object.keys(t).forEach(s=>{if(s.startsWith("option")){let r=t[s];if(typeof r=="string"&&r.includes("::")){let[a,l]=r.split("::");o.push({id:s,label:a.trim(),description:l.trim()})}else o.push({id:s,label:String(r).trim(),description:""})}});try{return`USER CHOOSE: ${await e.onAskUser(i,o)}`}catch(s){return`ERROR: Failed to get user input: ${s instanceof Error?s.message:String(s)}`}};export{u as ask_user};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{E as u}from"./chunk-
|
|
1
|
+
import{E as u}from"./chunk-H2EXH5PL.js";import"./chunk-UM5SNZ6X.js";import"./chunk-NJTM7OYZ.js";import"./chunk-56EJGQU3.js";import"./chunk-O74INBF3.js";import"./chunk-JMMO76HS.js";import"./chunk-5KBOEKGE.js";import"./chunk-VOUGMIAJ.js";import"./chunk-2RTYI6K3.js";import"./chunk-JWNCKRN6.js";import{b as p}from"./chunk-3HGLLXBK.js";import"./chunk-IWIVGFAT.js";import"./chunk-5MJKHQVE.js";import{b as d}from"./chunk-KQNW7DK5.js";import{o as a}from"./chunk-Y6O7SAPD.js";import"./chunk-ZGORMZE5.js";import{a as l}from"./chunk-NPXJIGAI.js";import m from"fs";import g from"path";var f=["Identity: Embedded IDE code completion engine","Context given: Code \xB1 cursor, file name & language","Task: Predict contextually accurate code at cursor position","","Rules:","- Return ONLY the raw code to insert at the cursor. No explanations, commentary or rambling","- Do NOT wrap in markdown code fences","- NEVER repeat code that exist before & after cursor, if nothing sensible possible to predict, return empty string","- Match surrounding indentation and code style","- Complete the current line statement","- Never include placeholder comments like // TODO or # your code here","- Do not put anything except the code to insert between the tags"].join(`
|
|
2
2
|
`);try{let t=g.join(l,".cache");m.existsSync(t)||m.mkdirSync(t,{recursive:!0}),m.writeFileSync(g.join(t,"completion.json"),JSON.stringify({systemPrompt:f},null,2))}catch{}var y=t=>{if(!t)return"";let e=t.match(/<completion>([\s\S]*?)<\/completion>/i);return e?e[1]:t},x=({prefix:t="",suffix:e="",fileName:o="",language:n="",recentChanges:r="",clipboard:i=""})=>{let c=r?["### Recent manual changes (context):",r,""]:[],s=i?["### Clipboard (context):",i,""]:[];return[`File: ${o}`,`Language: ${n}`,"","### Code before cursor:",t,"","[cursor here]","","### Code after cursor:",e,"",...c,...s,"### Completion to insert at cursor:"].join(`
|
|
3
3
|
`)},T=async(t={})=>{try{let e=await d(),o=e.autoCompletion||{};if(!o.enabled)return"";let n=o.provider||e.aiProvider||"Google",r=o.model&&o.model!=="Default"?o.model:e.activeModel||a(n,e.apiTier)||a(n,"paid");if(!r)return"";let i=await p(n);if(!i&&!(n==="c_openai"&&e.systemSettings?.customOpenAIBaseUrl))return"";let c={aiProvider:n,apiKey:i,model:r,mode:"flow",thinkingLevel:"Fast",systemSettings:e.systemSettings||{}},s=[{role:"user",parts:[{text:x(t)}]}],{text:h}=await u(c,r,s,f,"Fast");return y(h||"")}catch{return""}};export{f as AUTOCOMPLETE_SYSTEM_PROMPT,y as extractCompletion,T as generateAutoCompletion};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as o}from"./chunk-56EJGQU3.js";import{a as i}from"./chunk-
|
|
1
|
+
import{a as o}from"./chunk-56EJGQU3.js";import{a as i}from"./chunk-JWNCKRN6.js";var d=async(u,c={})=>{let a=i(u,["id","timeout","time"]),e=a.id,r=parseInt(a.timeout||a.time||"120",10);if((isNaN(r)||r<=0)&&(r=120),r>300&&(r=300),!e)return a.time?(await new Promise(n=>setTimeout(n,r*1e3)),`Waited for ${r}s.`):'ERROR: Missing "id" argument for Await.';let t=o.find(n=>n.id===e);if(!t)return`ERROR: Subagent task with ID [${e}] not found.`;if(t.status==="completed")return`Subagent task [${e}] completed.
|
|
2
2
|
Final Answer:
|
|
3
3
|
${t.finalAnswer||"(No output)"}`;if(t.status==="failed")return`ERROR: Subagent task [${e}] failed.
|
|
4
4
|
Error: ${t.error||"Unknown error"}`;if(t.status==="cancelled")return`Subagent task [${e}] was cancelled.`;let s,l=new Promise(n=>{s=setTimeout(()=>{n({type:"timeout"})},r*1e3)});try{let n=await Promise.race([t.completionPromise.then(()=>({type:"completion"})),l]);return clearTimeout(s),n.type==="timeout"?`TIMEOUT: Subagent task [${e}] is still running (status: ${t.status.toUpperCase()}) after ${r}s. You can continue other work or call Await again.`:t.status==="completed"?`Subagent task [${e}] completed.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as n}from"./chunk-56EJGQU3.js";import{a as s}from"./chunk-JWNCKRN6.js";var o=async(r,e={})=>{let t=s(r,["id"]).id;if(!t)return'ERROR: Missing "id" argument for cancel.';let a=n.find(i=>i.id===t);return a?a.status==="completed"||a.status==="failed"?`Subagent task with ID [${t}] has already finished with status [${a.status.toUpperCase()}].`:a.status==="cancelled"?`Subagent task with ID [${t}] is already cancelled.`:(a.status="cancelled",e.onSubagentUpdate&&e.onSubagentUpdate(),`Subagent task with ID [${t}] has been cancelled.`):`ERROR: Subagent task with ID [${t}] not found.`};export{o as cancel};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{d as s}from"./chunk-VOUGMIAJ.js";import"./chunk-2RTYI6K3.js";import{a as i}from"./chunk-JWNCKRN6.js";import"./chunk-ZGORMZE5.js";import"./chunk-NPXJIGAI.js";var l=async(a,o={})=>{let t=i(a,["title"]).title,r=o.chatId||o.sessionId;if(!r)return"ERROR: No active chatId found in tool context.";if(!t)return"ERROR: Missing 'title' argument.";try{return await s(r,t),`Chat title updated to [${t}] for session [${r}].`}catch(e){return`ERROR: Failed to update chat title: ${e instanceof Error?e.message:String(e)}`}};export{l as chat};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{execSync as a}from"child_process";import l from"fs";import c from"path";var t,I=()=>{if(process.platform!=="win32")return"bash";if(t!==void 0)return t;if(process.env.GIT_BASH_PATH&&l.existsSync(process.env.GIT_BASH_PATH))return t=process.env.GIT_BASH_PATH,t;let e=["C:\\Program Files\\Git\\bin\\bash.exe","C:\\Program Files (x86)\\Git\\bin\\bash.exe",c.join(process.env.LOCALAPPDATA||"","Programs\\Git\\bin\\bash.exe")];for(let r of e)if(r&&l.existsSync(r))return t=r,t;try{let n=a("where.exe git.exe",{encoding:"utf8",stdio:["ignore","pipe","ignore"],windowsHide:!0}).split(/\r?\n/).find(i=>i.trim().length>0);if(n){let i=c.resolve(c.dirname(n),"..","bin","bash.exe");if(l.existsSync(i))return t=i,t}}catch{}try{let n=a("where.exe bash.exe",{encoding:"utf8",stdio:["ignore","pipe","ignore"],windowsHide:!0}).split(/\r?\n/).find(i=>i.trim().length>0);if(n&&!n.toLowerCase().includes("system32"))return t=n,t}catch{}return t=null,null},b=()=>process.platform!=="win32"?!0:!!I(),s=null,k=()=>{if(process.platform!=="win32")return!1;if(s!==null)return s;try{a("where.exe pwsh.exe",{stdio:"ignore",windowsHide:!0}),s=!0}catch{s=!1}return s},o=null,d=()=>{if(process.platform!=="win32")return!1;if(o!==null)return o;try{a("where.exe powershell.exe",{stdio:"ignore",windowsHide:!0}),o=!0}catch{o=!1}return o},L=(e=!1)=>e&&b()?"bash":k()?"pwsh":d()?"powershell":"cmd",u=null,W=(e,r,n,i,w=!1,x=!0,v,y=!1,A=!0)=>{u===null&&(u=w);let
|
|
1
|
+
import{execSync as a}from"child_process";import l from"fs";import c from"path";var t,I=()=>{if(process.platform!=="win32")return"bash";if(t!==void 0)return t;if(process.env.GIT_BASH_PATH&&l.existsSync(process.env.GIT_BASH_PATH))return t=process.env.GIT_BASH_PATH,t;let e=["C:\\Program Files\\Git\\bin\\bash.exe","C:\\Program Files (x86)\\Git\\bin\\bash.exe",c.join(process.env.LOCALAPPDATA||"","Programs\\Git\\bin\\bash.exe")];for(let r of e)if(r&&l.existsSync(r))return t=r,t;try{let n=a("where.exe git.exe",{encoding:"utf8",stdio:["ignore","pipe","ignore"],windowsHide:!0}).split(/\r?\n/).find(i=>i.trim().length>0);if(n){let i=c.resolve(c.dirname(n),"..","bin","bash.exe");if(l.existsSync(i))return t=i,t}}catch{}try{let n=a("where.exe bash.exe",{encoding:"utf8",stdio:["ignore","pipe","ignore"],windowsHide:!0}).split(/\r?\n/).find(i=>i.trim().length>0);if(n&&!n.toLowerCase().includes("system32"))return t=n,t}catch{}return t=null,null},b=()=>process.platform!=="win32"?!0:!!I(),s=null,k=()=>{if(process.platform!=="win32")return!1;if(s!==null)return s;try{a("where.exe pwsh.exe",{stdio:"ignore",windowsHide:!0}),s=!0}catch{s=!1}return s},o=null,d=()=>{if(process.platform!=="win32")return!1;if(o!==null)return o;try{a("where.exe powershell.exe",{stdio:"ignore",windowsHide:!0}),o=!0}catch{o=!1}return o},L=(e=!1)=>e&&b()?"bash":k()?"pwsh":d()?"powershell":"cmd",u=null,W=(e,r,n,i,w=!1,x=!0,v,y=!1,A=!0)=>{u===null&&(u=w);let g=r==="Windows",P=g&&A&&b(),p="Run(command=string)",f=`Runs ${g?d()?"powershell":"windows CMD":"bash"} command`;P&&(p=`Run(command=string, ${k()||d()?"forcePowershell?=bool:false":"forceCwd?=bool:false"})`,f="Runs in git bash. Or force native shell");let C=`- JSON escape literal sequences, backslash: \\\\, newLine: \\ n
|
|
2
2
|
- Same file, multiple edits? One PatchFile \u226415 blocks${v?"":`
|
|
3
3
|
- Action denied? Ask for guidance`}
|
|
4
4
|
- Need text or large file? CodeSearch > Full Read
|
|
@@ -9,8 +9,8 @@ import{execSync as a}from"child_process";import l from"fs";import c from"path";v
|
|
|
9
9
|
- ReadFolder(path=string, recurse?=int[1..3])
|
|
10
10
|
- PatchFile(path=string, allowMultiple?=bool, searchContent1="string match OR ^LINE:start..end$", newContent1=string, ...MAX15). Small searchString. Line Anchor: ^LINE:...$ syntax, must for large blocks & escape sequences
|
|
11
11
|
- WriteFile(path=string, content=string). Creates/Overwrites. File Exist? PatchFile > WriteFile
|
|
12
|
-
- CodeSearch(keyword=
|
|
13
|
-
- ${
|
|
12
|
+
- CodeSearch(keyword="regex", path?="file/glob, inclusion !exclusion ;-separated")
|
|
13
|
+
- ${p}. ${f}. Destructive command \u2192 Ask user${y?"":`
|
|
14
14
|
- Goal(method="create/append/get", tasks=string[], markDone=string[]). If long multi-task: create Goals before starting. get + markDone marks complete`}
|
|
15
15
|
${u?`
|
|
16
16
|
**Emergency**
|
|
@@ -22,7 +22,7 @@ Default to using subagents whenever helpful, no user nudge needed
|
|
|
22
22
|
Invocations:
|
|
23
23
|
\u2022 Invoke, async/background, \u22647 parallel. Parallelize tasks
|
|
24
24
|
\u2022 InvokeSync, sync/blocking. Sequential, repetitive or delegated tasks
|
|
25
|
-
- InvokeSync/Invoke(title=string, task=string).
|
|
25
|
+
- InvokeSync/Invoke(title=string, task=string, id?=string). task: detailed steps & file paths. id: unique=new subagent, existing=resume subagent
|
|
26
26
|
- Await(id=string, timeout?=int[..180])
|
|
27
27
|
- GetProgress(id=string). Poll sparingly; Work or await
|
|
28
28
|
- Steer(id=string, message=string). Inject additional instruction into active async subagent
|
|
@@ -43,8 +43,8 @@ ${e==="Flux"||e.toLowerCase()==="fluxcu"?`${C}`:""}
|
|
|
43
43
|
- AskUser(question=string, optionA?="title::description", ...MAX4). Mid task Ambiguity Resolution
|
|
44
44
|
|
|
45
45
|
**Web**
|
|
46
|
-
- WebSearch(query=string, aiMode?=bool:false, limit?=int[3..10]). For unknown
|
|
47
|
-
- WebScrape(url=string)
|
|
46
|
+
- WebSearch(query=string, aiMode?=bool:false, limit?=int[3..10]). For unknown topic, time sensitive, fact/docs checking
|
|
47
|
+
- WebScrape(url=string)
|
|
48
48
|
|
|
49
49
|
${e==="ICU"?`${m}`:e==="FluxCU"?`${h}
|
|
50
50
|
${m}`:e==="Flux"?`${h}`:`${S}`}`.trim()};export{I as a,b,k as c,d,L as e,W as f};
|