fluxflow-cli 4.23.2 → 4.23.4
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/{addMemScore-HPTGXICT.js → addMemScore-COX3MDEK.js} +1 -1
- package/dist/chunks/{ai-4QWVJQQT.js → ai-QZPSCQTC.js} +1 -1
- package/dist/chunks/{app-F2FUSYYF.js → app-VDMSLYCY.js} +2 -2
- package/dist/chunks/{chat-HHMMKXDE.js → chat-J5AAPLPF.js} +1 -1
- package/dist/chunks/{chunk-VWSAPCIS.js → chunk-6KFABN4O.js} +1 -1
- package/dist/chunks/{chunk-74DZYKIT.js → chunk-7UNVYHZ7.js} +1 -1
- package/dist/chunks/{chunk-Y6DZDEJ5.js → chunk-BSUDXEA2.js} +1 -1
- package/dist/chunks/{chunk-ZH24NCF3.js → chunk-D7RU7MKC.js} +21 -29
- package/dist/chunks/{chunk-S25OD4YB.js → chunk-F6DMKN7N.js} +6 -6
- package/dist/chunks/{chunk-YUJMCXJA.js → chunk-IRFTRBG2.js} +1 -1
- package/dist/chunks/chunk-L3W2X74K.js +1 -0
- package/dist/chunks/{chunk-PS3TUC3G.js → chunk-OOTXMJIA.js} +1 -1
- package/dist/chunks/{chunk-ORXN6WUW.js → chunk-P52SKLRJ.js} +1 -1
- package/dist/chunks/{chunk-JWZGZEZA.js → chunk-U6UKO6MO.js} +1 -1
- package/dist/chunks/{chunk-5F3QPKCX.js → chunk-WMRT2YZU.js} +1 -1
- package/dist/chunks/{chunk-XCUZ3OIF.js → chunk-XIH6C5WL.js} +1 -1
- package/dist/chunks/{chunk-NPYHHQDC.js → chunk-Z4HHJIHG.js} +1 -1
- package/dist/chunks/{click-E6NYFK47.js → click-HS7NJR6J.js} +2 -2
- package/dist/chunks/{computer_action-GP5ARBTA.js → computer_action-YCFAAZNA.js} +1 -1
- package/dist/chunks/{drag-3QT4IG5X.js → drag-SBWNKGDV.js} +1 -1
- package/dist/chunks/{emergency_rollback-ZVBFZBFU.js → emergency_rollback-6M5EH75W.js} +1 -1
- package/dist/chunks/{exec_command-2AU2ICOX.js → exec_command-ER3K4TLH.js} +1 -1
- package/dist/chunks/{generate_image-J5SWUTUI.js → generate_image-S6M2GCD7.js} +1 -1
- package/dist/chunks/{invoke-4OQX5TRY.js → invoke-ZGIGNTE6.js} +2 -2
- package/dist/chunks/{invokeSync-YUAXMXVT.js → invokeSync-LXDZKOPO.js} +2 -2
- package/dist/chunks/{key_press-4ZHQKB6I.js → key_press-BT6QQ24M.js} +1 -1
- package/dist/chunks/{keyboard_typing-IOO3FFFJ.js → keyboard_typing-IWKUCQE4.js} +1 -1
- package/dist/chunks/{memory-TVFFXCSD.js → memory-5CNSGF6X.js} +1 -1
- package/dist/chunks/{saveSummary-HFAPNJJH.js → saveSummary-XQ2STWSN.js} +1 -1
- package/dist/chunks/{screen_grid-DR34XH4Z.js → screen_grid-YL4W6LEM.js} +1 -1
- package/dist/chunks/{scroll-HV6GUO5L.js → scroll-TA2JTVSR.js} +1 -1
- package/dist/chunks/{secrets-RFEEPY3S.js → secrets-BJGXCZRP.js} +1 -1
- package/dist/chunks/settings-ZDBO3FHN.js +1 -0
- package/dist/chunks/{todo-7Q2JBEVP.js → todo-C5HHG7TN.js} +1 -1
- package/dist/chunks/{update_file-IW7GUUIG.js → update_file-2YCGNOBP.js} +1 -1
- package/dist/chunks/{usage-5LVLEH5S.js → usage-6BBHZ76S.js} +1 -1
- package/dist/chunks/usageServer-CSS2XQH3.js +1 -0
- package/dist/chunks/{write_docx-IUKMO7XL.js → write_docx-J5OO4ZSE.js} +1 -1
- package/dist/chunks/{write_file-SP26GOE3.js → write_file-MDPZMOG3.js} +3 -3
- package/dist/chunks/{write_pdf-UM6Z2J4K.js → write_pdf-KF7HZODR.js} +1 -1
- package/dist/cli.js +25 -23
- package/dist/package.json +1 -1
- package/package.json +1 -1
- package/dist/chunks/chunk-SIINYZWE.js +0 -1
- package/dist/chunks/settings-6BPZ6DG5.js +0 -1
- package/dist/chunks/usageServer-F2KOFF6O.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as Kt}from"./chunk-56EJGQU3.js";import{a as ao}from"./chunk-
|
|
1
|
+
import{a as Kt}from"./chunk-56EJGQU3.js";import{a as ao}from"./chunk-P52SKLRJ.js";import{a as Ai,c as Ei}from"./chunk-F6DMKN7N.js";import{a as Es,g as Ci}from"./chunk-Z4HHJIHG.js";import{a as Ri}from"./chunk-2KD7V3OK.js";import{c as _s,g as Ti,h as Si,i as _i,m as As}from"./chunk-UDJ2C3N3.js";import{a as Oo}from"./chunk-IRFTRBG2.js";import{a as re}from"./chunk-Y5JU726N.js";import{b as Ts}from"./chunk-BSUDXEA2.js";import{d as Do,i as Ct,k as Ut,m as Ss,n as wi}from"./chunk-7UNVYHZ7.js";import{a as ro}from"./chunk-OOTXMJIA.js";import{k as ft,l as Io,o as pe}from"./chunk-QGPOMXO4.js";import{c as Et,d as Jn}from"./chunk-L3W2X74K.js";import{a as on,d as Mn,e as Ro,k as Wn,l as vo,m as ks,r as ws,v as Mo}from"./chunk-RI37VZYB.js";import{GoogleGenAI as Yr,ThinkingLevel as Xe,HarmBlockThreshold as On,HarmCategory as Ln}from"@google/genai";var vi=(e=!0,t=!0)=>`
|
|
2
2
|
To use tools, must output exactly '[tool:ToolName(arg1="value1")]' structured string in chat response \u2190 no exception
|
|
3
3
|
|
|
4
4
|
-- Chat Management Tools --
|
|
@@ -30,7 +30,7 @@ Usage Rules:
|
|
|
30
30
|
Think before complex tasks
|
|
31
31
|
Prefer simplest correct solution, assess architecture, performance & maintainability, verify error handling, assumptions, edge cases, dependencies & regressions, plan: files, functions, logic & interactions
|
|
32
32
|
Verify from first principles, seek failure paths, verify imports, system stability
|
|
33
|
-
|
|
33
|
+
Direct deduction only. No exploratory branching. Output solution immediately`,High:`Effort: High
|
|
34
34
|
Think before complex tasks
|
|
35
35
|
Prefer simplest correct solution, assess architecture, performance & maintainability, verify error handling, assumptions, edge cases, dependencies & regressions, plan: files, functions, logic & interactions
|
|
36
36
|
Continuous analysis, verify from first principles, seek failure paths, verify imports, system stability
|
|
@@ -526,31 +526,24 @@ ${nr?"":`${n==="Flux"?"Stepwise Execution, Run Automated Tests":n==="Flow"?"Conc
|
|
|
526
526
|
- Date: ${D}`:""}${o?`
|
|
527
527
|
- Use relative time reference eg. few mins ago
|
|
528
528
|
-- Chat Context > Metadata`:""}${(Ms.length>0||Is.length>0)&&n.toLowerCase().includes("flux")?`
|
|
529
|
-
- Read relevant skills
|
|
529
|
+
- Read relevant skills before proceeding tasks, scope: global/project: Use ReadFile, path="#skills/scope?/skillName". In-skill references: path="#skills/scope?/skillName/reference-folder/*.md"`:""}
|
|
530
530
|
|
|
531
|
-
|
|
532
|
-
${u==="Mistral"||u==="Google"&&!y?`${i}
|
|
533
|
-
${h||t!=="Fast"&&(u==="Mistral"&&t==="Low"&&!y||t!=="High"&&!y)?`critical thinking policy
|
|
534
|
-
Use <think>...</think> for reasoning before responding any queries
|
|
535
|
-
`:""}`:`${i}
|
|
536
|
-
`}${g?"":`Before calling tools, MUST provide a summary of your reasoning, plans, decisions, course of actions in chat
|
|
537
|
-
`}
|
|
531
|
+
${Ei(n,Xi,a,u,s?.advanceRollback,s?.subAgents!==!1,!!s?.autoExec,!!s?.disableTodo)}
|
|
538
532
|
|
|
539
|
-
|
|
533
|
+
-- THINKING GUIDANCE --
|
|
534
|
+
${u==="Mistral"||u==="Google"&&!y?`${i.trimEnd()}${h||t!=="Fast"&&(u==="Mistral"&&t==="Low"&&!y||t!=="High"&&!y)?`
|
|
535
|
+
Critical Thinking Policy
|
|
536
|
+
Use <think>...</think> for reasoning before responding any queries`:""}`:`${i}
|
|
537
|
+
`}${g?"":"Before calling tools, provide a natural summary of plans, reasoning, decision path in chat"}${o?`
|
|
540
538
|
|
|
541
539
|
-- MEMORY RULES --
|
|
542
|
-
- Subtly Personalize with relevent contextual memories. Auto Saves
|
|
543
|
-
`:""}${n==="Flux"?"":n.toLowerCase().includes("cu")?`
|
|
540
|
+
- Subtly Personalize with relevent contextual memories. Auto Saves`:""}${n==="Flux"?"":n.toLowerCase().includes("cu")?`
|
|
544
541
|
|
|
545
542
|
-- SECURITY POLICIES --
|
|
546
|
-
- Dont operate on ANY confidential screens
|
|
547
|
-
`:""}${n==="Flow"?`
|
|
548
|
-
|
|
549
|
-
-- CHAT FORMATTING --
|
|
550
|
-
- use kaomojis heavily`:""}
|
|
543
|
+
- Dont operate on ANY confidential screens`:""}
|
|
551
544
|
=== END SYSTEM PROMPT ===
|
|
552
545
|
|
|
553
|
-
${
|
|
546
|
+
${k}${l}${C}${Ms.length>0&&n.toLowerCase().includes("flux")?`-- Global Skills --
|
|
554
547
|
${Ms}
|
|
555
548
|
|
|
556
549
|
`:""}${Is.length>0&&n.toLowerCase().includes("flux")?`-- Project Skills --
|
|
@@ -577,7 +570,7 @@ ${vi(t,n)}
|
|
|
577
570
|
=== END SYSTEM PROMPT ===${e?`
|
|
578
571
|
|
|
579
572
|
-- current saved user memories --
|
|
580
|
-
${e}`:""}`.trim();var hr=()=>import("./web_search-D2GOWARI.js").then(e=>e.web_search),mr=()=>import("./web_scrape-LAQI7CVA.js").then(e=>e.web_scrape),pr=()=>import("./memory-TVFFXCSD.js").then(e=>e.memory),yr=()=>import("./chat-HHMMKXDE.js").then(e=>e.chat),xr=()=>import("./view_file-4UCCUBFK.js").then(e=>e.view_file),br=()=>import("./write_file-SP26GOE3.js").then(e=>e.write_file),kr=()=>import("./update_file-IW7GUUIG.js").then(e=>e.update_file),wr=()=>import("./exec_command-2AU2ICOX.js").then(e=>e.exec_command),Tr=()=>import("./read_folder-OOKZITME.js").then(e=>e.read_folder),Us=()=>import("./ask_user-K2DLZF6H.js").then(e=>e.ask_user),Sr=()=>import("./write_pdf-UM6Z2J4K.js").then(e=>e.write_pdf),_r=()=>import("./write_docx-IUKMO7XL.js").then(e=>e.write_docx),Uo=()=>import("./search_keyword-EAMQWPPI.js").then(e=>e.search_keyword),Ar=()=>import("./generate_image-J5SWUTUI.js").then(e=>e.generate_image),Wo=()=>import("./saveSummary-HFAPNJJH.js").then(e=>e.saveSummary),ho=()=>import("./addMemScore-HPTGXICT.js").then(e=>e.addMemScore),Er=()=>import("./file_map-XK7BFZFI.js").then(e=>e.file_map),Ho=()=>import("./todo-7Q2JBEVP.js").then(e=>e.todo),Cr=()=>import("./invokeSync-YUAXMXVT.js").then(e=>e.invokeSync),_a=()=>import("./invoke-4OQX5TRY.js").then(e=>e.invoke),Rr=()=>import("./getProgress-VG2IBPZU.js").then(e=>e.getProgress),Aa=()=>import("./cancel-7IMADALP.js").then(e=>e.cancel),vr=()=>import("./emergency_rollback-ZVBFZBFU.js").then(e=>e.emergency_rollback),mo=()=>import("./awaitSubagent-JTUSJDKD.js").then(e=>e.awaitSubagent),po=()=>import("./answerSubagent-JUVFNLE5.js").then(e=>e.answerSubagent),Go=()=>import("./steerSubagent-L2JVT4QN.js").then(e=>e.steerSubagent),jo=()=>import("./computer_action-GP5ARBTA.js").then(e=>e.computer_action),Mr=()=>import("./click-E6NYFK47.js").then(e=>e.click),Ir=()=>import("./drag-3QT4IG5X.js").then(e=>e.drag),Dr=()=>import("./scroll-HV6GUO5L.js").then(e=>e.scroll),Ws=()=>import("./keyboard_typing-IOO3FFFJ.js").then(e=>e.keyboard_typing),Hs=()=>import("./key_press-4ZHQKB6I.js").then(e=>e.key_press),Gs=()=>import("./recapture_screen-5FKLOHJL.js").then(e=>e.recapture_screen),Ea={web_search:hr,web_scrape:mr,memory:pr,chat:yr,view_file:xr,write_file:br,update_file:kr,exec_command:wr,read_folder:Tr,write_pdf:Sr,write_docx:_r,search_keyword:Uo,generate_image:Ar,saveSummary:Wo,addMemScore:ho,file_map:Er,todo:Ho,Todo:Ho,goal:Ho,Goal:Ho,invokeSync:Cr,invoke:_a,getProgress:Rr,cancel:Aa,awaitSubagent:mo,answerSubagent:po,steerSubagent:Go,computer_action:jo,computer_use:jo,ComputerAction:jo,ComputerUse:jo,click:Mr,Click:Mr,drag:Ir,Drag:Ir,scroll:Dr,Scroll:Dr,keyboard_typing:Ws,KeyboardTyping:Ws,keyboardtyping:Ws,key_press:Hs,KeyPress:Hs,keypress:Hs,recapture_screen:Gs,RecaptureScreen:Gs,recapturescreen:Gs,invoke_sync:Cr,get_progress:Rr,await_subagent:mo,answer_subagent:po,steer_subagent:Go,steer:Go,Steer:Go,ask:Us,Ask:Us,AskUser:Us,WebSearch:hr,WebScrape:mr,ReadFile:xr,ReadFolder:Tr,WriteFile:br,PatchFile:kr,WritePDF:Sr,WriteDoc:_r,Run:wr,SearchKeyword:Uo,CodeSearch:Uo,code_search:Uo,Memory:pr,Chat:yr,GenerateImage:Ar,saveSumary:Wo,SaveSummary:Wo,SaveSumary:Wo,add_mem_score:ho,AddMemScore:ho,addMemoryScore:ho,AddMemoryScore:ho,FileMap:Er,answer:po,Answer:po,AnswerSubagent:po,await:mo,Await:mo,AwaitSubagent:mo,EmergencyRollback:vr,emergency_rollback:vr},yo=async(e,t,n={})=>{let s=n.mode?n.mode.toLowerCase():"flux",o=e.toLowerCase(),u=["memory","chat","savesummary","addmemscore","add_mem_score","ask","web_search","web_scrape","await"].some(g=>o.includes(g))||o==="ask",y=["click","drag","scroll","keyboardtyping","keyboard_typing","keypress","key_press","recapturescreen","recapture_screen","computer"].some(g=>o.includes(g));if(!u){if(s==="flow"){if(!(o.includes("write_pdf")||o.includes("write_docx")||o.includes("generate_image")))return`ERROR: Tool [${e}] is a Workspace Tool and NOT available in Flow mode. Tell user to switch (\`/mode flux\`) to use this tool.`}else if(s==="icu"){if(!y)return`ERROR: Tool [${e}] is not available in Computer Use mode. ICU mode only supports Computer Use tools (Click, Drag, Scroll, KeyboardTyping, KeyPress, RecaptureScreen).`}else if(o.includes("write_pdf")||o.includes("write_docx")||o.includes("generate_image"))return`ERROR: Tool [${e}] is not available in ${n.mode||"Flux"} mode. Tell user to switch (\`/mode flow\`) for document generation.`}let p=Ea[e];if(!p){let g=["ReadFile","ReadFolder","PatchFile","WriteFile","CodeSearch","Run","Goal","AskUser","WebSearch","WebScrape","WritePDF","WriteDoc","Click","Drag","Scroll","KeyboardTyping","KeyPress","RecaptureScreen","Invoke","InvokeSync","Await","GetProgress","Steer","Cancel","EmergencyRollback","Chat","Memory"],b={read:"ReadFile",view:"ReadFile",viewfile:"ReadFile",write:"WriteFile",edit:"PatchFile",patch:"PatchFile",update:"PatchFile",updatefile:"PatchFile",exec:"Run",command:"Run",bash:"Run",shell:"Run",powershell:"Run",search:"CodeSearch",grep:"CodeSearch",find:"CodeSearch",searchkeyword:"CodeSearch",folder:"ReadFolder",ls:"ReadFolder",dir:"ReadFolder",list:"ReadFolder",ask:"AskUser",question:"AskUser",pdf:"WritePDF",docx:"WriteDoc",doc:"WriteDoc",word:"WriteDoc",screenshot:"RecaptureScreen",screen:"RecaptureScreen",recapture:"RecaptureScreen",type:"KeyboardTyping",typing:"KeyboardTyping",keyboard:"KeyboardTyping",press:"KeyPress",key:"KeyPress",todo:"Goal",task:"Goal",subagent:"Invoke",agent:"Invoke"},h=o.replace(/[^a-z0-9]/g,""),i=b[h]||null;if(!i){let k=0,v=_=>{let P=new Set;for(let E=0;E<_.length-1;E++)P.add(_.slice(E,E+2));return P},m=v(h);for(let _ of g){let P=_.toLowerCase().replace(/[^a-z0-9]/g,"");if(h===P){i=_;break}let E=0;(P.includes(h)||h.includes(P))&&(E+=.6);let S=v(P),R=0;for(let w of m)S.has(w)&&R++;let $=2*R/(m.size+S.size||1);E=Math.max(E,$),E>k&&E>=.35&&(k=E,i=_)}}let l=i?` Do you mean '${i}'?`:"";return`ERROR: Tool [${e}] not found in registry.${l}`}try{return await(await p())(t,n)}catch(g){let b=g instanceof Error?g.message:String(g);return`ERROR: Execution failed for [${e}]: ${b}`}};import te from"path";import He from"fs";import Ca from"gradient-string";var js=["I have a regex for your problems.","Your terminal, my kingdom.","Blowing on the cartridge helps. Probably.","Don't panic. I have the towel.","Logic is the start of wisdom.","Try to exit Vim? Good luck.","I speak fluent Terminal.","The cake is a lie. This code is not.","I have no bugs, just surprise features.","Rewriting in Rust... just for fun.","Coffee in, clean commits out.","The magic smoke stays inside today.","A semicolon short of a miracle.","One does not simply code without a bug.","Keep it simple. Keep it terminal.","Regex: now you have two problems.","I dream in binary.","Root access or bust.","Wait for the dial-up tone. Just kidding.","I take the 'labor' out of collab.","My other process is a TARDIS.","Calculated response: 42.","Ponder the orb. Ponder the code.","Less talk, more flow.","Elegance in every byte.","Build something the world is not ready for.","Your wishes, my tool calls.","I act in Flux. I think in Flow.","Syntax error in the universe. Please fix.","Your project, my obsession.","I am not a bot, I am an architect.","Digital spirits consulted. They say: Ship it.","Reticulate splines. Engage humor.","Code like poetry. Run like water.","Minimalism is the ultimate flex.","The truth is in the logs.","Follow the white rabbit.","There is no spoon. Only code.","Binary is the only language I trust.","I have a good feeling about this.","Pew pew! Lasers charged.","Divide by zero? Not today.","Search for the correct USB orientation...","I've got a fever, and the only cure is more code.","The code gremlins are on our side.","My favorite command? Yours.","Stay hungry. Stay active.","Momentum is your best friend.","Lead the flow. Don't chase it.","A fresh batch of bytes. Hot and ready.","I orchestrate the ones and zeros.","Smart enough to help. Humble enough to ask.","Think twice. Code once.","Pure intent. Pure execution.","Small steps. Massive impact.","Your terminal is a canvas.","Efficiency is my second name.","I have seen things you people wouldn't believe.","Let the thoughts marinate.","The best feature? The one you don't need.","Precision is the only perfection.","Stay focused. Stay terminal.","Silence is the best debugger.","Erase the debt. Commit the code.","Velocity meets stability.","Ship it. Improve it. Repeat.","Build tomorrow, right now.","Turn logic into reality.","The best way to predict the future is to build it.","Break barriers, not builds.","Fuel the next breakthrough.","Momentum is key.","Terminal vibes only.","Your digital co-pilot is ready.","Partner in code. Partner in crime.","I speak in semicolons.","Ready for the next great idea.","Just a moment. In the zone.","Polishing the algorithms. Hold tight.","Craft a masterpiece today.","Debug the universe. Start here.","Warp speed engaged. Almost.","The cake is not a lie. It's just loading.","Finish the Kessel Run in 12 parsecs.","Do a barrel roll!","Waiting for the respawn.","Press Start to continue.","Herding digital cats... done.","The hamsters are fast today.","Tasting the snozberries.","I go for speed. I go for flow.","Real life or just fantasy?","Poking the bear... gently.","Ensure the magic smoke stays inside.","Try turning it off and on again.","Construct additional pylons.","New line? Ctrl+J is your friend.","Release the HypnoDrones.","Push the button, Frank.","My other loading screen is even funnier.","Pretty sure a cat walked on my keyboard.","Recalibrate the humor-o-meter.","Summon the code gremlins.","I've seen your browser history. Just kidding.","Charge the laser... pew pew!","Dividing by zero... just for a sec.","Looking for an adult supervisor. Found none.","Make it go beep boop.","Buffering... for effect.","Entangle quantum particles... complete.","Polishing the chrome on my algorithms.","Are you not entertained?","Just waiting for the dial-up tone.","Reboot the humor module.","Defragment memories. Check.","Optimizing for ludicrous speed.","Swapping bits. Don't tell the bytes.","Garbage collected. I am back.","Assembling the interwebs.","Converting coffee to logic.","Update syntax for reality.","Rewire the synapses.","Greasin' the cogs.","Engage the improbability drive.","Channel the Force.","Align the stars. Respond now.","The cake is a lie. The prompt is real.","I'm Feeling Lucky.","Shipping awesomeness.","Navigating the slime mold.","Consult digital spirits.","Ask the magic conch shell.","One moment. Optimizing humor.","Shuffling punchlines.","Compiling brilliance.","Summon the cloud of wisdom.","Prepare to dazzle.","Hold tight. Crafting a response.","Tuning the algorithms.","Following the white rabbit... again.","The truth is in here. Somewhere.","Herding cats is my day job.","Distracting you with this phrase.","Almost there. Probably.","Rickrolling my creator. Don't tell.","Slapping the bass.","Is this real life?","Ponder the orb. Type the prompt.","Thoughtful gaze initiated.","Computer's favorite snack? Microchips.","Why Java? Because I don't C#.","Charging the laser... wait for it.","Dividing by zero... just kidding!","Adult supervision not found. Proceed.","Beep boop. I'm a real boy.","Wait for the respawn.","Finish the run. Ship the code.","Fiddling with character creation.","Just a moment. Finding a meme.","Pressing A to continue.","Loading wit.exe.","Pre-heating the servers.","Calibrate flux capacitor.","Channeling the Force.","Aligning the stars.","The truth is in the code.","Don't panic.","Blowing on the cartridge.","Doing a barrel roll!","Respawning in 3... 2... 1...","The cake is a lie.","Fiddling with character settings.","Finding a suitable pun.","Distracting with wit.","Almost ready.","Hamsters on speed today.","Patting Cloudy on the head.","Rickrolling the logs.","Slapping the code.","Got a good feeling about this.","Poking the prompt.","Researching latest memes.","Making it more witty.","Thinking... hmmm.","Fish with no eyes? Fsh.","Broken pencil? Pointless.","Percussive maintenance applied.","USB orientation: 3rd try's the charm.","Rust rewrite in 3... 2...","Exiting Vim... someday.","Spinning the hamster wheel.","Not a bug. Unplanned feature.","Engage.","I'll be back.","Machine spirit consulted.","Letting the thoughts marinate.","Orb pondered.","Thoughtful gaze engaged.","Charging the laser...","Making it go beep.","Buffering...","Quantum particles entangled.","Polishing the chrome.","Entertained yet?","Gremlins summoned.","Dial-up tone finished.","Humor meter recalibrated.","Cat on keyboard. Sending help.","Enhancing...","Turn it off and on again.","Constructing pylons.","HypnoDrones released.","Pushing the button."];var Or=[{name:"Cyan Cyberpunk",text:"cyan",textMuted:"#4da6b8",textDim:"#2d6d7a",textInverted:"black",border:"cyan",borderMuted:"#1a5966",borderDim:"#0f3840",bg:void 0,cardBg:"#061e24",highlightBg:"#092b33",activeBg:"#0e3e4a",inputBg:"#092b33",inputBorder:"#092b33",inputText:"cyan",inputPlaceholder:"#2d6d7a",inputPrompt:"cyan",codeBg:"#020d10",codeBorder:"#1a5966",userMsgBg:"#092b33",userMsgBorder:"#092b33",userMsgText:"cyan",diffRemovalBg:"#3a0c1a",diffAdditionBg:"#0c3a32",diffRemovalText:"#ff4d88",diffAdditionText:"#00ffaa",diffRemovalHighlightColor:"#ff1a66",diffRemovalHighlightBg:"#590022",diffAdditionHighlightColor:"#00ffcc",diffAdditionHighlightBg:"#00593b",diffRemovalNum:"#ff4d88",diffAdditionNum:"#00ffaa",diffRemovalPrefix:"#ff1a66",diffAdditionPrefix:"#00ffcc",primary:"cyan",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"cyan",statusOff:"#2d6d7a",logoTextAnsi:"\x1B[1;36m",logoBodyAnsi:"\x1B[36m",logoMutedAnsi:"\x1B[90m",logoGradient:["#00ffff","#0088ff"]},{name:"Magenta Vaporwave",text:"magenta",textMuted:"#c451d6",textDim:"#7d2b8a",textInverted:"black",border:"magenta",borderMuted:"#5e1b69",borderDim:"#3b0f42",bg:void 0,cardBg:"#240729",highlightBg:"#310938",activeBg:"#470e52",inputBg:"#310938",inputBorder:"#310938",inputText:"magenta",inputPlaceholder:"#7d2b8a",inputPrompt:"magenta",codeBg:"#100312",codeBorder:"#5e1b69",userMsgBg:"#310938",userMsgBorder:"#310938",userMsgText:"magenta",diffRemovalBg:"#3a0c20",diffAdditionBg:"#200c3a",diffRemovalText:"#ff4d94",diffAdditionText:"#aa4dff",diffRemovalHighlightColor:"#ff1a75",diffRemovalHighlightBg:"#59002b",diffAdditionHighlightColor:"#bb66ff",diffAdditionHighlightBg:"#3b0059",diffRemovalNum:"#ff4d94",diffAdditionNum:"#aa4dff",diffRemovalPrefix:"#ff1a75",diffAdditionPrefix:"#bb66ff",primary:"magenta",secondary:"cyan",accent:"purple",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"magenta",statusOff:"#7d2b8a",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ff00ff","#8800ff"]},{name:"Glitch Matrix",text:"#00ff41",textMuted:"#00b32d",textDim:"#00661a",textInverted:"black",border:"#00ff41",borderMuted:"#008020",borderDim:"#004d13",bg:void 0,cardBg:"#0d1f0d",highlightBg:"#122912",activeBg:"#1c3e1c",inputBg:"#122912",inputBorder:"#122912",inputText:"#00ff41",inputPlaceholder:"#00b32d",inputPrompt:"#ffff00",codeBg:"#040a04",codeBorder:"#008020",userMsgBg:"#122912",userMsgBorder:"#122912",userMsgText:"#00ff41",diffRemovalBg:"#3a001a",diffAdditionBg:"#003a10",diffRemovalText:"#ff0055",diffAdditionText:"#00ff66",diffRemovalHighlightColor:"#ff0033",diffRemovalHighlightBg:"#59001b",diffAdditionHighlightColor:"#33ff88",diffAdditionHighlightBg:"#005918",diffRemovalNum:"#ff0055",diffAdditionNum:"#00ff66",diffRemovalPrefix:"#ff0033",diffAdditionPrefix:"#33ff88",primary:"#00ff41",secondary:"yellow",accent:"cyan",success:"#00ff41",warning:"yellow",danger:"red",info:"cyan",statusOn:"#00ff41",statusOff:"#00661a",logoTextAnsi:"\x1B[1;32m",logoBodyAnsi:"\x1B[32m",logoMutedAnsi:"\x1B[90m",logoGradient:["#00ff41","#ffff00"]},{name:"Warm Sunset",text:"#ffaa55",textMuted:"#cc8844",textDim:"#885522",textInverted:"black",border:"#ff9933",borderMuted:"#aa6622",borderDim:"#663311",bg:void 0,cardBg:"#24180f",highlightBg:"#2e1e12",activeBg:"#422c1b",inputBg:"#2e1e12",inputBorder:"#2e1e12",inputText:"#ffaa55",inputPlaceholder:"#885522",inputPrompt:"#ff7733",codeBg:"#120c08",codeBorder:"#aa6622",userMsgBg:"#2e1e12",userMsgBorder:"#2e1e12",userMsgText:"#ffaa55",diffRemovalBg:"#3d120c",diffAdditionBg:"#3a2e0c",diffRemovalText:"#ff5544",diffAdditionText:"#ffcc33",diffRemovalHighlightColor:"#ff3322",diffRemovalHighlightBg:"#591108",diffAdditionHighlightColor:"#ffee44",diffAdditionHighlightBg:"#594400",diffRemovalNum:"#ff5544",diffAdditionNum:"#ffcc33",diffRemovalPrefix:"#ff3322",diffAdditionPrefix:"#ffee44",primary:"#ffaa55",secondary:"#ff7733",accent:"magenta",success:"#ffcc33",warning:"#ff7733",danger:"#ff3322",info:"#ffaa55",statusOn:"#ffaa55",statusOff:"#885522",logoTextAnsi:"\x1B[1;33m",logoBodyAnsi:"\x1B[33m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ff9933","#ff0055"]},{name:"Sakura Blossom",text:"#ffc0e0",textMuted:"#d98cb3",textDim:"#804d66",textInverted:"black",border:"#ff99cc",borderMuted:"#aa4d7a",borderDim:"#662647",bg:void 0,cardBg:"#291320",highlightBg:"#331826",activeBg:"#472235",inputBg:"#331826",inputBorder:"#331826",inputText:"#ffc0e0",inputPlaceholder:"#804d66",inputPrompt:"#ff99cc",codeBg:"#140a10",codeBorder:"#aa4d7a",userMsgBg:"#331826",userMsgBorder:"#331826",userMsgText:"#ffc0e0",diffRemovalBg:"#3e0c1b",diffAdditionBg:"#1b3e2b",diffRemovalText:"#ff6699",diffAdditionText:"#66ffb3",diffRemovalHighlightColor:"#ff3377",diffRemovalHighlightBg:"#590022",diffAdditionHighlightColor:"#33ff99",diffAdditionHighlightBg:"#00592e",diffRemovalNum:"#ff6699",diffAdditionNum:"#66ffb3",diffRemovalPrefix:"#ff3377",diffAdditionPrefix:"#33ff99",primary:"#ffc0e0",secondary:"#ff99cc",accent:"magenta",success:"#66ffb3",warning:"yellow",danger:"#ff3377",info:"#ff99cc",statusOn:"#ffc0e0",statusOff:"#804d66",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ffb3d9","#ff3399"]},{name:"Radioactive Slime",text:"#ccff00",textMuted:"#99cc00",textDim:"#669900",textInverted:"#0a0f00",border:"#ccff00",borderMuted:"#99cc00",borderDim:"#669900",bg:void 0,cardBg:"#0f1400",highlightBg:"#1a2400",activeBg:"#2a3b00",inputBg:"#1a2400",inputBorder:"#1a2400",inputText:"#ccff00",inputPlaceholder:"#669900",inputPrompt:"#cc00ff",codeBg:"#050a00",codeBorder:"#99cc00",userMsgBg:"#1a2400",userMsgBorder:"#1a2400",userMsgText:"#ccff00",diffRemovalBg:"#2a0033",diffAdditionBg:"#0f3300",diffRemovalText:"#ff00cc",diffAdditionText:"#00ff33",diffRemovalHighlightColor:"#ff33cc",diffRemovalHighlightBg:"#4d0066",diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:"#1a6600",diffRemovalNum:"#ff00cc",diffAdditionNum:"#00ff33",diffRemovalPrefix:"#ff33cc",diffAdditionPrefix:"#33ff66",primary:"#ccff00",secondary:"#cc00ff",accent:"#ff00cc",success:"#00ff33",warning:"#ffcc00",danger:"#ff0033",info:"#00ccff",statusOn:"#ccff00",statusOff:"#669900",logoTextAnsi:"\x1B[1;38;5;190m",logoBodyAnsi:"\x1B[38;5;190m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ccff00","#cc00ff"]},{name:"Cosmic Void",text:"#f0f8ff",textMuted:"#a6aeb5",textDim:"#5e656e",textInverted:"#010103",border:"#f0f8ff",borderMuted:"#a6aeb5",borderDim:"#5e656e",bg:void 0,cardBg:"#05030d",highlightBg:"#0b081a",activeBg:"#171133",inputBg:"#0b081a",inputBorder:"#0b081a",inputText:"#f0f8ff",inputPlaceholder:"#5e656e",inputPrompt:"#ff007f",codeBg:"#020108",codeBorder:"#a6aeb5",userMsgBg:"#0b081a",userMsgBorder:"#0b081a",userMsgText:"#f0f8ff",diffRemovalBg:"#2e0a29",diffAdditionBg:"#091c33",diffRemovalText:"#ff33a6",diffAdditionText:"#33d6ff",diffRemovalHighlightColor:"#ff66c2",diffRemovalHighlightBg:"#5c1452",diffAdditionHighlightColor:"#66e0ff",diffAdditionHighlightBg:"#123866",diffRemovalNum:"#ff33a6",diffAdditionNum:"#33d6ff",diffRemovalPrefix:"#ff66c2",diffAdditionPrefix:"#66e0ff",primary:"#f0f8ff",secondary:"#ff007f",accent:"#9d00ff",success:"#33d6ff",warning:"#ffcc00",danger:"#ff0040",info:"#9d00ff",statusOn:"#f0f8ff",statusOff:"#5e656e",logoTextAnsi:"\x1B[1;38;5;231m",logoBodyAnsi:"\x1B[38;5;231m",logoMutedAnsi:"\x1B[38;5;240m",logoGradient:["#ffffff","#9d00ff"]},{name:"Magma Eruption",text:"#ff4d00",textMuted:"#cc3d00",textDim:"#802600",textInverted:"#0d0300",border:"#ff4d00",borderMuted:"#cc3d00",borderDim:"#802600",bg:void 0,cardBg:"#1a0600",highlightBg:"#260a00",activeBg:"#401100",inputBg:"#260a00",inputBorder:"#260a00",inputText:"#ff4d00",inputPlaceholder:"#802600",inputPrompt:"#ffcc00",codeBg:"#080200",codeBorder:"#cc3d00",userMsgBg:"#260a00",userMsgBorder:"#260a00",userMsgText:"#ff4d00",diffRemovalBg:"#2e0a0a",diffAdditionBg:"#1f1400",diffRemovalText:"#ff3333",diffAdditionText:"#ffaa00",diffRemovalHighlightColor:"#ff6666",diffRemovalHighlightBg:"#5c1414",diffAdditionHighlightColor:"#ffcc33",diffAdditionHighlightBg:"#3d2900",diffRemovalNum:"#ff3333",diffAdditionNum:"#ffaa00",diffRemovalPrefix:"#ff6666",diffAdditionPrefix:"#ffcc33",primary:"#ff4d00",secondary:"#ffcc00",accent:"#ff0040",success:"#ffaa00",warning:"#ffff00",danger:"#ff0000",info:"#ff8800",statusOn:"#ff4d00",statusOff:"#802600",logoTextAnsi:"\x1B[1;38;5;202m",logoBodyAnsi:"\x1B[38;5;202m",logoMutedAnsi:"\x1B[38;5;236m",logoGradient:["#ff4d00","#ff0000"]}],xo={Dark:{id:"Dark",name:"Dark (Default)",text:"white",textMuted:"gray",textDim:"grey",textInverted:"black",textExclusive:"#B5B8D9",textMutedExclusive:"#D4DEE7",border:"white",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:"#1e1e1e",highlightBg:"#2a2a2a",activeBg:"#3a3a3a",inputBg:"#555555",inputBorder:"#555555",inputText:"white",inputPlaceholder:"#cccccc",inputPrompt:"white",codeBg:"#1a1a1a",codeBorder:"#444444",userMsgBg:"#444444",userMsgBorder:"#444444",userMsgText:"white",diffRemovalBg:"#250808",diffAdditionBg:"#072410",diffRemovalText:"#885555",diffAdditionText:"#558866",diffRemovalHighlightColor:"#ff3333",diffRemovalHighlightBg:"#5a1818",diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:"#185a25",diffRemovalNum:"#d96868",diffAdditionNum:"#68d98c",diffRemovalPrefix:"#ff4d4d",diffAdditionPrefix:"#4dff88",primary:"white",secondary:"cyan",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"white",statusOff:"gray",logoTextAnsi:"\x1B[1;37m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#0077ff","#ff00ff"]},Light:{id:"Light",name:"Light",text:"black",textMuted:"gray",textDim:"grey",textInverted:"white",border:"black",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:"#e5e5e5",highlightBg:"#d4d4d4",activeBg:"#c0c0c0",inputBg:"#d0d0d0",inputBorder:"#d0d0d0",inputText:"black",inputPlaceholder:"#555555",inputPrompt:"black",codeBg:"#e8e8e8",codeBorder:"#b0b0b0",userMsgBg:"#d0d0d0",userMsgBorder:"#d0d0d0",userMsgText:"black",diffRemovalBg:"#fce8e8",diffAdditionBg:"#e6f9e6",diffRemovalText:"#661111",diffAdditionText:"#115511",diffRemovalHighlightColor:"#440000",diffRemovalHighlightBg:"#f8b4b4",diffAdditionHighlightColor:"#003300",diffAdditionHighlightBg:"#a6ebad",diffRemovalNum:"#c02020",diffAdditionNum:"#188028",diffRemovalPrefix:"#d01010",diffAdditionPrefix:"#109020",primary:"black",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"black",statusOff:"gray",logoTextAnsi:"\x1B[1;30m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#0077ff","#ff00ff"]},"GitHub Dark":{id:"GitHub Dark",name:"GitHub Dark",text:"#c9d1d9",textMuted:"#8b949e",textDim:"#6e7681",textInverted:"#0d1117",border:"#30363d",borderMuted:"#30363d",borderDim:"#21262d",bg:void 0,cardBg:"#161b22",highlightBg:"#21262d",activeBg:"#30363d",inputBg:"#21262d",inputBorder:"#21262d",inputText:"#c9d1d9",inputPlaceholder:"#8b949e",inputPrompt:"#58a6ff",codeBg:"#0d1117",codeBorder:"#30363d",userMsgBg:"#21262d",userMsgBorder:"#21262d",userMsgText:"#c9d1d9",diffRemovalBg:"#3c1e1e",diffAdditionBg:"#11381e",diffRemovalText:"#f85149",diffAdditionText:"#3fb950",diffRemovalHighlightColor:"#ff7b72",diffRemovalHighlightBg:"#701c1c",diffAdditionHighlightColor:"#56d364",diffAdditionHighlightBg:"#116329",diffRemovalNum:"#f85149",diffAdditionNum:"#3fb950",diffRemovalPrefix:"#f85149",diffAdditionPrefix:"#3fb950",primary:"#c9d1d9",secondary:"#58a6ff",accent:"#bc8cff",success:"#3fb950",warning:"#d29922",danger:"#f85149",info:"#58a6ff",statusOn:"#58a6ff",statusOff:"#8b949e",logoTextAnsi:"\x1B[1;36m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#2ea043","#56d364"]},"GitHub Light":{id:"GitHub Light",name:"GitHub Light",text:"#24292f",textMuted:"#57606a",textDim:"#6e7781",textInverted:"#ffffff",border:"#d0d7de",borderMuted:"#d0d7de",borderDim:"#e1e4e8",bg:void 0,cardBg:"#f6f8fa",highlightBg:"#eaeef2",activeBg:"#d0d7de",inputBg:"#eaeef2",inputBorder:"#eaeef2",inputText:"#24292f",inputPlaceholder:"#57606a",inputPrompt:"#0969da",codeBg:"#ffffff",codeBorder:"#d0d7de",userMsgBg:"#eaeef2",userMsgBorder:"#eaeef2",userMsgText:"#24292f",diffRemovalBg:"#ffebe9",diffAdditionBg:"#e6ffec",diffRemovalText:"#cf222e",diffAdditionText:"#1a7f37",diffRemovalHighlightColor:"#82071e",diffRemovalHighlightBg:"#ffc1c0",diffAdditionHighlightColor:"#116329",diffAdditionHighlightBg:"#acf2bd",diffRemovalNum:"#cf222e",diffAdditionNum:"#1a7f37",diffRemovalPrefix:"#cf222e",diffAdditionPrefix:"#1a7f37",primary:"#24292f",secondary:"#0969da",accent:"#8250df",success:"#1a7f37",warning:"#9a6700",danger:"#cf222e",info:"#0969da",statusOn:"#0969da",statusOff:"#57606a",logoTextAnsi:"\x1B[1;34m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#1a7f37","#2da44e"]},"Transparent Dark":{id:"Transparent Dark",name:"Transparent Dark",text:"white",textMuted:"gray",textDim:"grey",textInverted:"black",border:"gray",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:void 0,highlightBg:"#2a2a2a",activeBg:"#3a3a3a",inputBg:"#555555",inputBorder:"#555555",inputText:"white",inputPlaceholder:"#cccccc",inputPrompt:"white",codeBg:void 0,codeBorder:"gray",userMsgBg:"#555555",userMsgBorder:"#555555",userMsgText:"white",diffRemovalBg:void 0,diffAdditionBg:void 0,diffRemovalText:"#ff6666",diffAdditionText:"#66ff66",diffRemovalHighlightColor:"#ff3333",diffRemovalHighlightBg:void 0,diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:void 0,diffRemovalNum:"#ff6666",diffAdditionNum:"#66ff66",diffRemovalPrefix:"#ff4d4d",diffAdditionPrefix:"#4dff88",primary:"white",secondary:"cyan",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"white",statusOff:"gray",logoTextAnsi:"\x1B[1;37m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#0077ff","#ff00ff"]},"Transparent Light":{id:"Transparent Light",name:"Transparent Light",text:"black",textMuted:"gray",textDim:"grey",textInverted:"white",border:"gray",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:void 0,highlightBg:"#d4d4d4",activeBg:"#c0c0c0",inputBg:"#d0d0d0",inputBorder:"#d0d0d0",inputText:"black",inputPlaceholder:"#555555",inputPrompt:"black",codeBg:void 0,codeBorder:"gray",userMsgBg:"#d0d0d0",userMsgBorder:"#d0d0d0",userMsgText:"black",diffRemovalBg:void 0,diffAdditionBg:void 0,diffRemovalText:"#c02020",diffAdditionText:"#188028",diffRemovalHighlightColor:"#800000",diffRemovalHighlightBg:void 0,diffAdditionHighlightColor:"#004000",diffAdditionHighlightBg:void 0,diffRemovalNum:"#c02020",diffAdditionNum:"#188028",diffRemovalPrefix:"#d01010",diffAdditionPrefix:"#109020",primary:"black",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"black",statusOff:"gray",logoTextAnsi:"\x1B[1;30m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#0077ff","#ff00ff"]},"Synthwave 84":{id:"Synthwave 84",name:"Synthwave 84",text:"#fdfdfd",textMuted:"#a08eb7",textDim:"#705c8a",textInverted:"#1a1025",textExclusive:"#e3dcf0",textMutedExclusive:"#b9abc9",border:"#fc28a8",borderMuted:"#a21568",borderDim:"#5c0a3a",bg:void 0,cardBg:"#261b38",highlightBg:"#35254d",activeBg:"#4c3570",inputBg:"#35254d",inputBorder:"#35254d",inputText:"#fdfdfd",inputPlaceholder:"#a08eb7",inputPrompt:"#03e8fc",codeBg:"#1e142b",codeBorder:"#a21568",userMsgBg:"#35254d",userMsgBorder:"#35254d",userMsgText:"#fdfdfd",diffRemovalBg:"#471434",diffAdditionBg:"#144743",diffRemovalText:"#ff4081",diffAdditionText:"#00e5ff",diffRemovalHighlightColor:"#ff79a1",diffRemovalHighlightBg:"#6b1e4e",diffAdditionHighlightColor:"#66f5ff",diffAdditionHighlightBg:"#1e6b65",diffRemovalNum:"#ff4081",diffAdditionNum:"#00e5ff",diffRemovalPrefix:"#ff79a1",diffAdditionPrefix:"#66f5ff",primary:"#fdfdfd",secondary:"#03e8fc",accent:"#fc28a8",success:"#00e5ff",warning:"#ffc107",danger:"#ff4081",info:"#b388ff",statusOn:"#03e8fc",statusOff:"#a08eb7",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#fc28a8","#03e8fc"]},"Forest Sprite":{id:"Forest Sprite",name:"Forest Sprite",text:"#d6e6d1",textMuted:"#95b38d",textDim:"#628059",textInverted:"#161c14",textExclusive:"#eaf2e8",textMutedExclusive:"#a9c7a2",border:"#74a862",borderMuted:"#477038",borderDim:"#2b4720",bg:void 0,cardBg:"#1f291c",highlightBg:"#2a3826",activeBg:"#3a4d35",inputBg:"#2a3826",inputBorder:"#2a3826",inputText:"#d6e6d1",inputPlaceholder:"#95b38d",inputPrompt:"#8feb73",codeBg:"#161e14",codeBorder:"#477038",userMsgBg:"#2a3826",userMsgBorder:"#2a3826",userMsgText:"#d6e6d1",diffRemovalBg:"#3b231c",diffAdditionBg:"#203b1c",diffRemovalText:"#db6242",diffAdditionText:"#59cc3f",diffRemovalHighlightColor:"#f0896c",diffRemovalHighlightBg:"#5c362a",diffAdditionHighlightColor:"#80e368",diffAdditionHighlightBg:"#305929",diffRemovalNum:"#db6242",diffAdditionNum:"#59cc3f",diffRemovalPrefix:"#f0896c",diffAdditionPrefix:"#80e368",primary:"#d6e6d1",secondary:"#8feb73",accent:"#e69835",success:"#59cc3f",warning:"#e69835",danger:"#db6242",info:"#73b4eb",statusOn:"#8feb73",statusOff:"#95b38d",logoTextAnsi:"\x1B[1;32m",logoBodyAnsi:"\x1B[32m",logoMutedAnsi:"\x1B[90m",logoGradient:["#8feb73","#e69835"]}};var Vo=null;var Lr=(e="Dark")=>{let t;e==="Mystery"||e==="Chaos"?(Vo||(Vo=Or[Math.floor(Math.random()*Or.length)]),t={...Vo,id:"Mystery"}):(Vo=null,xo[e]?t=xo[e]:e==="GitHub"?t=xo["GitHub Dark"]:e==="Transparent"?t=xo["Transparent Dark"]:t=xo.Dark);let n=t.codeText||t.secondary||t.info||t.logoGradient&&t.logoGradient[0]||"cyan";return{...t,codeText:n}};var Ra=()=>process.env.TERM_PROGRAM==="vscode"?"vscode":process.env.WT_SESSION?"wt":"default",xc=(e=2)=>{let t=Ra();return t==="wt"?" ".repeat(Math.max(1,e-1)):" ".repeat(e)},bc=(e="...",t="Loading...",n="Dark")=>{let s=js[Math.floor(Math.random()*js.length)],o=Lr(n),c=o.logoTextAnsi,u=o.logoBodyAnsi,a=o.logoMutedAnsi,y="\x1B[0m",p=[" \u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2588\u2588\u2588\u2591 "," \u2588\u2588\u2588\u2591 "," \u2588\u2588\u2588\u2591 "," \u2591\u2591\u2591 "],g=o.logoGradient||["#0077ff","#ff00ff"],b=Ca(g).multiline(p.join(`
|
|
573
|
+
${e}`:""}`.trim();var hr=()=>import("./web_search-D2GOWARI.js").then(e=>e.web_search),mr=()=>import("./web_scrape-LAQI7CVA.js").then(e=>e.web_scrape),pr=()=>import("./memory-5CNSGF6X.js").then(e=>e.memory),yr=()=>import("./chat-J5AAPLPF.js").then(e=>e.chat),xr=()=>import("./view_file-4UCCUBFK.js").then(e=>e.view_file),br=()=>import("./write_file-MDPZMOG3.js").then(e=>e.write_file),kr=()=>import("./update_file-2YCGNOBP.js").then(e=>e.update_file),wr=()=>import("./exec_command-ER3K4TLH.js").then(e=>e.exec_command),Tr=()=>import("./read_folder-OOKZITME.js").then(e=>e.read_folder),Us=()=>import("./ask_user-K2DLZF6H.js").then(e=>e.ask_user),Sr=()=>import("./write_pdf-KF7HZODR.js").then(e=>e.write_pdf),_r=()=>import("./write_docx-J5OO4ZSE.js").then(e=>e.write_docx),Uo=()=>import("./search_keyword-EAMQWPPI.js").then(e=>e.search_keyword),Ar=()=>import("./generate_image-S6M2GCD7.js").then(e=>e.generate_image),Wo=()=>import("./saveSummary-XQ2STWSN.js").then(e=>e.saveSummary),ho=()=>import("./addMemScore-COX3MDEK.js").then(e=>e.addMemScore),Er=()=>import("./file_map-XK7BFZFI.js").then(e=>e.file_map),Ho=()=>import("./todo-C5HHG7TN.js").then(e=>e.todo),Cr=()=>import("./invokeSync-LXDZKOPO.js").then(e=>e.invokeSync),_a=()=>import("./invoke-ZGIGNTE6.js").then(e=>e.invoke),Rr=()=>import("./getProgress-VG2IBPZU.js").then(e=>e.getProgress),Aa=()=>import("./cancel-7IMADALP.js").then(e=>e.cancel),vr=()=>import("./emergency_rollback-6M5EH75W.js").then(e=>e.emergency_rollback),mo=()=>import("./awaitSubagent-JTUSJDKD.js").then(e=>e.awaitSubagent),po=()=>import("./answerSubagent-JUVFNLE5.js").then(e=>e.answerSubagent),Go=()=>import("./steerSubagent-L2JVT4QN.js").then(e=>e.steerSubagent),jo=()=>import("./computer_action-YCFAAZNA.js").then(e=>e.computer_action),Mr=()=>import("./click-HS7NJR6J.js").then(e=>e.click),Ir=()=>import("./drag-SBWNKGDV.js").then(e=>e.drag),Dr=()=>import("./scroll-TA2JTVSR.js").then(e=>e.scroll),Ws=()=>import("./keyboard_typing-IWKUCQE4.js").then(e=>e.keyboard_typing),Hs=()=>import("./key_press-BT6QQ24M.js").then(e=>e.key_press),Gs=()=>import("./recapture_screen-5FKLOHJL.js").then(e=>e.recapture_screen),Ea={web_search:hr,web_scrape:mr,memory:pr,chat:yr,view_file:xr,write_file:br,update_file:kr,exec_command:wr,read_folder:Tr,write_pdf:Sr,write_docx:_r,search_keyword:Uo,generate_image:Ar,saveSummary:Wo,addMemScore:ho,file_map:Er,todo:Ho,Todo:Ho,goal:Ho,Goal:Ho,invokeSync:Cr,invoke:_a,getProgress:Rr,cancel:Aa,awaitSubagent:mo,answerSubagent:po,steerSubagent:Go,computer_action:jo,computer_use:jo,ComputerAction:jo,ComputerUse:jo,click:Mr,Click:Mr,drag:Ir,Drag:Ir,scroll:Dr,Scroll:Dr,keyboard_typing:Ws,KeyboardTyping:Ws,keyboardtyping:Ws,key_press:Hs,KeyPress:Hs,keypress:Hs,recapture_screen:Gs,RecaptureScreen:Gs,recapturescreen:Gs,invoke_sync:Cr,get_progress:Rr,await_subagent:mo,answer_subagent:po,steer_subagent:Go,steer:Go,Steer:Go,ask:Us,Ask:Us,AskUser:Us,WebSearch:hr,WebScrape:mr,ReadFile:xr,ReadFolder:Tr,WriteFile:br,PatchFile:kr,WritePDF:Sr,WriteDoc:_r,Run:wr,SearchKeyword:Uo,CodeSearch:Uo,code_search:Uo,Memory:pr,Chat:yr,GenerateImage:Ar,saveSumary:Wo,SaveSummary:Wo,SaveSumary:Wo,add_mem_score:ho,AddMemScore:ho,addMemoryScore:ho,AddMemoryScore:ho,FileMap:Er,answer:po,Answer:po,AnswerSubagent:po,await:mo,Await:mo,AwaitSubagent:mo,EmergencyRollback:vr,emergency_rollback:vr},yo=async(e,t,n={})=>{let s=n.mode?n.mode.toLowerCase():"flux",o=e.toLowerCase(),u=["memory","chat","savesummary","addmemscore","add_mem_score","ask","web_search","web_scrape","await"].some(g=>o.includes(g))||o==="ask",y=["click","drag","scroll","keyboardtyping","keyboard_typing","keypress","key_press","recapturescreen","recapture_screen","computer"].some(g=>o.includes(g));if(!u){if(s==="flow"){if(!(o.includes("write_pdf")||o.includes("write_docx")||o.includes("generate_image")))return`ERROR: Tool [${e}] is a Workspace Tool and NOT available in Flow mode. Tell user to switch (\`/mode flux\`) to use this tool.`}else if(s==="icu"){if(!y)return`ERROR: Tool [${e}] is not available in Computer Use mode. ICU mode only supports Computer Use tools (Click, Drag, Scroll, KeyboardTyping, KeyPress, RecaptureScreen).`}else if(o.includes("write_pdf")||o.includes("write_docx")||o.includes("generate_image"))return`ERROR: Tool [${e}] is not available in ${n.mode||"Flux"} mode. Tell user to switch (\`/mode flow\`) for document generation.`}let p=Ea[e];if(!p){let g=["ReadFile","ReadFolder","PatchFile","WriteFile","CodeSearch","Run","Goal","AskUser","WebSearch","WebScrape","WritePDF","WriteDoc","Click","Drag","Scroll","KeyboardTyping","KeyPress","RecaptureScreen","Invoke","InvokeSync","Await","GetProgress","Steer","Cancel","EmergencyRollback","Chat","Memory"],b={read:"ReadFile",view:"ReadFile",viewfile:"ReadFile",write:"WriteFile",edit:"PatchFile",patch:"PatchFile",update:"PatchFile",updatefile:"PatchFile",exec:"Run",command:"Run",bash:"Run",shell:"Run",powershell:"Run",search:"CodeSearch",grep:"CodeSearch",find:"CodeSearch",searchkeyword:"CodeSearch",folder:"ReadFolder",ls:"ReadFolder",dir:"ReadFolder",list:"ReadFolder",ask:"AskUser",question:"AskUser",pdf:"WritePDF",docx:"WriteDoc",doc:"WriteDoc",word:"WriteDoc",screenshot:"RecaptureScreen",screen:"RecaptureScreen",recapture:"RecaptureScreen",type:"KeyboardTyping",typing:"KeyboardTyping",keyboard:"KeyboardTyping",press:"KeyPress",key:"KeyPress",todo:"Goal",task:"Goal",subagent:"Invoke",agent:"Invoke"},h=o.replace(/[^a-z0-9]/g,""),i=b[h]||null;if(!i){let k=0,v=_=>{let P=new Set;for(let E=0;E<_.length-1;E++)P.add(_.slice(E,E+2));return P},m=v(h);for(let _ of g){let P=_.toLowerCase().replace(/[^a-z0-9]/g,"");if(h===P){i=_;break}let E=0;(P.includes(h)||h.includes(P))&&(E+=.6);let S=v(P),R=0;for(let w of m)S.has(w)&&R++;let $=2*R/(m.size+S.size||1);E=Math.max(E,$),E>k&&E>=.35&&(k=E,i=_)}}let l=i?` Do you mean '${i}'?`:"";return`ERROR: Tool [${e}] not found in registry.${l}`}try{return await(await p())(t,n)}catch(g){let b=g instanceof Error?g.message:String(g);return`ERROR: Execution failed for [${e}]: ${b}`}};import te from"path";import He from"fs";import Ca from"gradient-string";var js=["I have a regex for your problems.","Your terminal, my kingdom.","Blowing on the cartridge helps. Probably.","Don't panic. I have the towel.","Logic is the start of wisdom.","Try to exit Vim? Good luck.","I speak fluent Terminal.","The cake is a lie. This code is not.","I have no bugs, just surprise features.","Rewriting in Rust... just for fun.","Coffee in, clean commits out.","The magic smoke stays inside today.","A semicolon short of a miracle.","One does not simply code without a bug.","Keep it simple. Keep it terminal.","Regex: now you have two problems.","I dream in binary.","Root access or bust.","Wait for the dial-up tone. Just kidding.","I take the 'labor' out of collab.","My other process is a TARDIS.","Calculated response: 42.","Ponder the orb. Ponder the code.","Less talk, more flow.","Elegance in every byte.","Build something the world is not ready for.","Your wishes, my tool calls.","I act in Flux. I think in Flow.","Syntax error in the universe. Please fix.","Your project, my obsession.","I am not a bot, I am an architect.","Digital spirits consulted. They say: Ship it.","Reticulate splines. Engage humor.","Code like poetry. Run like water.","Minimalism is the ultimate flex.","The truth is in the logs.","Follow the white rabbit.","There is no spoon. Only code.","Binary is the only language I trust.","I have a good feeling about this.","Pew pew! Lasers charged.","Divide by zero? Not today.","Search for the correct USB orientation...","I've got a fever, and the only cure is more code.","The code gremlins are on our side.","My favorite command? Yours.","Stay hungry. Stay active.","Momentum is your best friend.","Lead the flow. Don't chase it.","A fresh batch of bytes. Hot and ready.","I orchestrate the ones and zeros.","Smart enough to help. Humble enough to ask.","Think twice. Code once.","Pure intent. Pure execution.","Small steps. Massive impact.","Your terminal is a canvas.","Efficiency is my second name.","I have seen things you people wouldn't believe.","Let the thoughts marinate.","The best feature? The one you don't need.","Precision is the only perfection.","Stay focused. Stay terminal.","Silence is the best debugger.","Erase the debt. Commit the code.","Velocity meets stability.","Ship it. Improve it. Repeat.","Build tomorrow, right now.","Turn logic into reality.","The best way to predict the future is to build it.","Break barriers, not builds.","Fuel the next breakthrough.","Momentum is key.","Terminal vibes only.","Your digital co-pilot is ready.","Partner in code. Partner in crime.","I speak in semicolons.","Ready for the next great idea.","Just a moment. In the zone.","Polishing the algorithms. Hold tight.","Craft a masterpiece today.","Debug the universe. Start here.","Warp speed engaged. Almost.","The cake is not a lie. It's just loading.","Finish the Kessel Run in 12 parsecs.","Do a barrel roll!","Waiting for the respawn.","Press Start to continue.","Herding digital cats... done.","The hamsters are fast today.","Tasting the snozberries.","I go for speed. I go for flow.","Real life or just fantasy?","Poking the bear... gently.","Ensure the magic smoke stays inside.","Try turning it off and on again.","Construct additional pylons.","New line? Ctrl+J is your friend.","Release the HypnoDrones.","Push the button, Frank.","My other loading screen is even funnier.","Pretty sure a cat walked on my keyboard.","Recalibrate the humor-o-meter.","Summon the code gremlins.","I've seen your browser history. Just kidding.","Charge the laser... pew pew!","Dividing by zero... just for a sec.","Looking for an adult supervisor. Found none.","Make it go beep boop.","Buffering... for effect.","Entangle quantum particles... complete.","Polishing the chrome on my algorithms.","Are you not entertained?","Just waiting for the dial-up tone.","Reboot the humor module.","Defragment memories. Check.","Optimizing for ludicrous speed.","Swapping bits. Don't tell the bytes.","Garbage collected. I am back.","Assembling the interwebs.","Converting coffee to logic.","Update syntax for reality.","Rewire the synapses.","Greasin' the cogs.","Engage the improbability drive.","Channel the Force.","Align the stars. Respond now.","The cake is a lie. The prompt is real.","I'm Feeling Lucky.","Shipping awesomeness.","Navigating the slime mold.","Consult digital spirits.","Ask the magic conch shell.","One moment. Optimizing humor.","Shuffling punchlines.","Compiling brilliance.","Summon the cloud of wisdom.","Prepare to dazzle.","Hold tight. Crafting a response.","Tuning the algorithms.","Following the white rabbit... again.","The truth is in here. Somewhere.","Herding cats is my day job.","Distracting you with this phrase.","Almost there. Probably.","Rickrolling my creator. Don't tell.","Slapping the bass.","Is this real life?","Ponder the orb. Type the prompt.","Thoughtful gaze initiated.","Computer's favorite snack? Microchips.","Why Java? Because I don't C#.","Charging the laser... wait for it.","Dividing by zero... just kidding!","Adult supervision not found. Proceed.","Beep boop. I'm a real boy.","Wait for the respawn.","Finish the run. Ship the code.","Fiddling with character creation.","Just a moment. Finding a meme.","Pressing A to continue.","Loading wit.exe.","Pre-heating the servers.","Calibrate flux capacitor.","Channeling the Force.","Aligning the stars.","The truth is in the code.","Don't panic.","Blowing on the cartridge.","Doing a barrel roll!","Respawning in 3... 2... 1...","The cake is a lie.","Fiddling with character settings.","Finding a suitable pun.","Distracting with wit.","Almost ready.","Hamsters on speed today.","Patting Cloudy on the head.","Rickrolling the logs.","Slapping the code.","Got a good feeling about this.","Poking the prompt.","Researching latest memes.","Making it more witty.","Thinking... hmmm.","Fish with no eyes? Fsh.","Broken pencil? Pointless.","Percussive maintenance applied.","USB orientation: 3rd try's the charm.","Rust rewrite in 3... 2...","Exiting Vim... someday.","Spinning the hamster wheel.","Not a bug. Unplanned feature.","Engage.","I'll be back.","Machine spirit consulted.","Letting the thoughts marinate.","Orb pondered.","Thoughtful gaze engaged.","Charging the laser...","Making it go beep.","Buffering...","Quantum particles entangled.","Polishing the chrome.","Entertained yet?","Gremlins summoned.","Dial-up tone finished.","Humor meter recalibrated.","Cat on keyboard. Sending help.","Enhancing...","Turn it off and on again.","Constructing pylons.","HypnoDrones released.","Pushing the button."];var Or=[{name:"Cyan Cyberpunk",text:"cyan",textMuted:"#4da6b8",textDim:"#2d6d7a",textInverted:"black",border:"cyan",borderMuted:"#1a5966",borderDim:"#0f3840",bg:void 0,cardBg:"#061e24",highlightBg:"#092b33",activeBg:"#0e3e4a",inputBg:"#092b33",inputBorder:"#092b33",inputText:"cyan",inputPlaceholder:"#2d6d7a",inputPrompt:"cyan",codeBg:"#020d10",codeBorder:"#1a5966",userMsgBg:"#092b33",userMsgBorder:"#092b33",userMsgText:"cyan",diffRemovalBg:"#3a0c1a",diffAdditionBg:"#0c3a32",diffRemovalText:"#ff4d88",diffAdditionText:"#00ffaa",diffRemovalHighlightColor:"#ff1a66",diffRemovalHighlightBg:"#590022",diffAdditionHighlightColor:"#00ffcc",diffAdditionHighlightBg:"#00593b",diffRemovalNum:"#ff4d88",diffAdditionNum:"#00ffaa",diffRemovalPrefix:"#ff1a66",diffAdditionPrefix:"#00ffcc",primary:"cyan",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"cyan",statusOff:"#2d6d7a",logoTextAnsi:"\x1B[1;36m",logoBodyAnsi:"\x1B[36m",logoMutedAnsi:"\x1B[90m",logoGradient:["#00ffff","#0088ff"]},{name:"Magenta Vaporwave",text:"magenta",textMuted:"#c451d6",textDim:"#7d2b8a",textInverted:"black",border:"magenta",borderMuted:"#5e1b69",borderDim:"#3b0f42",bg:void 0,cardBg:"#240729",highlightBg:"#310938",activeBg:"#470e52",inputBg:"#310938",inputBorder:"#310938",inputText:"magenta",inputPlaceholder:"#7d2b8a",inputPrompt:"magenta",codeBg:"#100312",codeBorder:"#5e1b69",userMsgBg:"#310938",userMsgBorder:"#310938",userMsgText:"magenta",diffRemovalBg:"#3a0c20",diffAdditionBg:"#200c3a",diffRemovalText:"#ff4d94",diffAdditionText:"#aa4dff",diffRemovalHighlightColor:"#ff1a75",diffRemovalHighlightBg:"#59002b",diffAdditionHighlightColor:"#bb66ff",diffAdditionHighlightBg:"#3b0059",diffRemovalNum:"#ff4d94",diffAdditionNum:"#aa4dff",diffRemovalPrefix:"#ff1a75",diffAdditionPrefix:"#bb66ff",primary:"magenta",secondary:"cyan",accent:"purple",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"magenta",statusOff:"#7d2b8a",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ff00ff","#8800ff"]},{name:"Glitch Matrix",text:"#00ff41",textMuted:"#00b32d",textDim:"#00661a",textInverted:"black",border:"#00ff41",borderMuted:"#008020",borderDim:"#004d13",bg:void 0,cardBg:"#0d1f0d",highlightBg:"#122912",activeBg:"#1c3e1c",inputBg:"#122912",inputBorder:"#122912",inputText:"#00ff41",inputPlaceholder:"#00b32d",inputPrompt:"#ffff00",codeBg:"#040a04",codeBorder:"#008020",userMsgBg:"#122912",userMsgBorder:"#122912",userMsgText:"#00ff41",diffRemovalBg:"#3a001a",diffAdditionBg:"#003a10",diffRemovalText:"#ff0055",diffAdditionText:"#00ff66",diffRemovalHighlightColor:"#ff0033",diffRemovalHighlightBg:"#59001b",diffAdditionHighlightColor:"#33ff88",diffAdditionHighlightBg:"#005918",diffRemovalNum:"#ff0055",diffAdditionNum:"#00ff66",diffRemovalPrefix:"#ff0033",diffAdditionPrefix:"#33ff88",primary:"#00ff41",secondary:"yellow",accent:"cyan",success:"#00ff41",warning:"yellow",danger:"red",info:"cyan",statusOn:"#00ff41",statusOff:"#00661a",logoTextAnsi:"\x1B[1;32m",logoBodyAnsi:"\x1B[32m",logoMutedAnsi:"\x1B[90m",logoGradient:["#00ff41","#ffff00"]},{name:"Warm Sunset",text:"#ffaa55",textMuted:"#cc8844",textDim:"#885522",textInverted:"black",border:"#ff9933",borderMuted:"#aa6622",borderDim:"#663311",bg:void 0,cardBg:"#24180f",highlightBg:"#2e1e12",activeBg:"#422c1b",inputBg:"#2e1e12",inputBorder:"#2e1e12",inputText:"#ffaa55",inputPlaceholder:"#885522",inputPrompt:"#ff7733",codeBg:"#120c08",codeBorder:"#aa6622",userMsgBg:"#2e1e12",userMsgBorder:"#2e1e12",userMsgText:"#ffaa55",diffRemovalBg:"#3d120c",diffAdditionBg:"#3a2e0c",diffRemovalText:"#ff5544",diffAdditionText:"#ffcc33",diffRemovalHighlightColor:"#ff3322",diffRemovalHighlightBg:"#591108",diffAdditionHighlightColor:"#ffee44",diffAdditionHighlightBg:"#594400",diffRemovalNum:"#ff5544",diffAdditionNum:"#ffcc33",diffRemovalPrefix:"#ff3322",diffAdditionPrefix:"#ffee44",primary:"#ffaa55",secondary:"#ff7733",accent:"magenta",success:"#ffcc33",warning:"#ff7733",danger:"#ff3322",info:"#ffaa55",statusOn:"#ffaa55",statusOff:"#885522",logoTextAnsi:"\x1B[1;33m",logoBodyAnsi:"\x1B[33m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ff9933","#ff0055"]},{name:"Sakura Blossom",text:"#ffc0e0",textMuted:"#d98cb3",textDim:"#804d66",textInverted:"black",border:"#ff99cc",borderMuted:"#aa4d7a",borderDim:"#662647",bg:void 0,cardBg:"#291320",highlightBg:"#331826",activeBg:"#472235",inputBg:"#331826",inputBorder:"#331826",inputText:"#ffc0e0",inputPlaceholder:"#804d66",inputPrompt:"#ff99cc",codeBg:"#140a10",codeBorder:"#aa4d7a",userMsgBg:"#331826",userMsgBorder:"#331826",userMsgText:"#ffc0e0",diffRemovalBg:"#3e0c1b",diffAdditionBg:"#1b3e2b",diffRemovalText:"#ff6699",diffAdditionText:"#66ffb3",diffRemovalHighlightColor:"#ff3377",diffRemovalHighlightBg:"#590022",diffAdditionHighlightColor:"#33ff99",diffAdditionHighlightBg:"#00592e",diffRemovalNum:"#ff6699",diffAdditionNum:"#66ffb3",diffRemovalPrefix:"#ff3377",diffAdditionPrefix:"#33ff99",primary:"#ffc0e0",secondary:"#ff99cc",accent:"magenta",success:"#66ffb3",warning:"yellow",danger:"#ff3377",info:"#ff99cc",statusOn:"#ffc0e0",statusOff:"#804d66",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ffb3d9","#ff3399"]},{name:"Radioactive Slime",text:"#ccff00",textMuted:"#99cc00",textDim:"#669900",textInverted:"#0a0f00",border:"#ccff00",borderMuted:"#99cc00",borderDim:"#669900",bg:void 0,cardBg:"#0f1400",highlightBg:"#1a2400",activeBg:"#2a3b00",inputBg:"#1a2400",inputBorder:"#1a2400",inputText:"#ccff00",inputPlaceholder:"#669900",inputPrompt:"#cc00ff",codeBg:"#050a00",codeBorder:"#99cc00",userMsgBg:"#1a2400",userMsgBorder:"#1a2400",userMsgText:"#ccff00",diffRemovalBg:"#2a0033",diffAdditionBg:"#0f3300",diffRemovalText:"#ff00cc",diffAdditionText:"#00ff33",diffRemovalHighlightColor:"#ff33cc",diffRemovalHighlightBg:"#4d0066",diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:"#1a6600",diffRemovalNum:"#ff00cc",diffAdditionNum:"#00ff33",diffRemovalPrefix:"#ff33cc",diffAdditionPrefix:"#33ff66",primary:"#ccff00",secondary:"#cc00ff",accent:"#ff00cc",success:"#00ff33",warning:"#ffcc00",danger:"#ff0033",info:"#00ccff",statusOn:"#ccff00",statusOff:"#669900",logoTextAnsi:"\x1B[1;38;5;190m",logoBodyAnsi:"\x1B[38;5;190m",logoMutedAnsi:"\x1B[90m",logoGradient:["#ccff00","#cc00ff"]},{name:"Cosmic Void",text:"#f0f8ff",textMuted:"#a6aeb5",textDim:"#5e656e",textInverted:"#010103",border:"#f0f8ff",borderMuted:"#a6aeb5",borderDim:"#5e656e",bg:void 0,cardBg:"#05030d",highlightBg:"#0b081a",activeBg:"#171133",inputBg:"#0b081a",inputBorder:"#0b081a",inputText:"#f0f8ff",inputPlaceholder:"#5e656e",inputPrompt:"#ff007f",codeBg:"#020108",codeBorder:"#a6aeb5",userMsgBg:"#0b081a",userMsgBorder:"#0b081a",userMsgText:"#f0f8ff",diffRemovalBg:"#2e0a29",diffAdditionBg:"#091c33",diffRemovalText:"#ff33a6",diffAdditionText:"#33d6ff",diffRemovalHighlightColor:"#ff66c2",diffRemovalHighlightBg:"#5c1452",diffAdditionHighlightColor:"#66e0ff",diffAdditionHighlightBg:"#123866",diffRemovalNum:"#ff33a6",diffAdditionNum:"#33d6ff",diffRemovalPrefix:"#ff66c2",diffAdditionPrefix:"#66e0ff",primary:"#f0f8ff",secondary:"#ff007f",accent:"#9d00ff",success:"#33d6ff",warning:"#ffcc00",danger:"#ff0040",info:"#9d00ff",statusOn:"#f0f8ff",statusOff:"#5e656e",logoTextAnsi:"\x1B[1;38;5;231m",logoBodyAnsi:"\x1B[38;5;231m",logoMutedAnsi:"\x1B[38;5;240m",logoGradient:["#ffffff","#9d00ff"]},{name:"Magma Eruption",text:"#ff4d00",textMuted:"#cc3d00",textDim:"#802600",textInverted:"#0d0300",border:"#ff4d00",borderMuted:"#cc3d00",borderDim:"#802600",bg:void 0,cardBg:"#1a0600",highlightBg:"#260a00",activeBg:"#401100",inputBg:"#260a00",inputBorder:"#260a00",inputText:"#ff4d00",inputPlaceholder:"#802600",inputPrompt:"#ffcc00",codeBg:"#080200",codeBorder:"#cc3d00",userMsgBg:"#260a00",userMsgBorder:"#260a00",userMsgText:"#ff4d00",diffRemovalBg:"#2e0a0a",diffAdditionBg:"#1f1400",diffRemovalText:"#ff3333",diffAdditionText:"#ffaa00",diffRemovalHighlightColor:"#ff6666",diffRemovalHighlightBg:"#5c1414",diffAdditionHighlightColor:"#ffcc33",diffAdditionHighlightBg:"#3d2900",diffRemovalNum:"#ff3333",diffAdditionNum:"#ffaa00",diffRemovalPrefix:"#ff6666",diffAdditionPrefix:"#ffcc33",primary:"#ff4d00",secondary:"#ffcc00",accent:"#ff0040",success:"#ffaa00",warning:"#ffff00",danger:"#ff0000",info:"#ff8800",statusOn:"#ff4d00",statusOff:"#802600",logoTextAnsi:"\x1B[1;38;5;202m",logoBodyAnsi:"\x1B[38;5;202m",logoMutedAnsi:"\x1B[38;5;236m",logoGradient:["#ff4d00","#ff0000"]}],xo={Dark:{id:"Dark",name:"Dark (Default)",text:"white",textMuted:"gray",textDim:"grey",textInverted:"black",textExclusive:"#B5B8D9",textMutedExclusive:"#D4DEE7",border:"white",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:"#1e1e1e",highlightBg:"#2a2a2a",activeBg:"#3a3a3a",inputBg:"#555555",inputBorder:"#555555",inputText:"white",inputPlaceholder:"#cccccc",inputPrompt:"white",codeBg:"#1a1a1a",codeBorder:"#444444",userMsgBg:"#444444",userMsgBorder:"#444444",userMsgText:"white",diffRemovalBg:"#250808",diffAdditionBg:"#072410",diffRemovalText:"#885555",diffAdditionText:"#558866",diffRemovalHighlightColor:"#ff3333",diffRemovalHighlightBg:"#5a1818",diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:"#185a25",diffRemovalNum:"#d96868",diffAdditionNum:"#68d98c",diffRemovalPrefix:"#ff4d4d",diffAdditionPrefix:"#4dff88",primary:"white",secondary:"cyan",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"white",statusOff:"gray",logoTextAnsi:"\x1B[1;37m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#0077ff","#ff00ff"]},Light:{id:"Light",name:"Light",text:"black",textMuted:"gray",textDim:"grey",textInverted:"white",border:"black",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:"#e5e5e5",highlightBg:"#d4d4d4",activeBg:"#c0c0c0",inputBg:"#d0d0d0",inputBorder:"#d0d0d0",inputText:"black",inputPlaceholder:"#555555",inputPrompt:"black",codeBg:"#e8e8e8",codeBorder:"#b0b0b0",userMsgBg:"#d0d0d0",userMsgBorder:"#d0d0d0",userMsgText:"black",diffRemovalBg:"#fce8e8",diffAdditionBg:"#e6f9e6",diffRemovalText:"#661111",diffAdditionText:"#115511",diffRemovalHighlightColor:"#440000",diffRemovalHighlightBg:"#f8b4b4",diffAdditionHighlightColor:"#003300",diffAdditionHighlightBg:"#a6ebad",diffRemovalNum:"#c02020",diffAdditionNum:"#188028",diffRemovalPrefix:"#d01010",diffAdditionPrefix:"#109020",primary:"black",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"black",statusOff:"gray",logoTextAnsi:"\x1B[1;30m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#0077ff","#ff00ff"]},"GitHub Dark":{id:"GitHub Dark",name:"GitHub Dark",text:"#c9d1d9",textMuted:"#8b949e",textDim:"#6e7681",textInverted:"#0d1117",border:"#30363d",borderMuted:"#30363d",borderDim:"#21262d",bg:void 0,cardBg:"#161b22",highlightBg:"#21262d",activeBg:"#30363d",inputBg:"#21262d",inputBorder:"#21262d",inputText:"#c9d1d9",inputPlaceholder:"#8b949e",inputPrompt:"#58a6ff",codeBg:"#0d1117",codeBorder:"#30363d",userMsgBg:"#21262d",userMsgBorder:"#21262d",userMsgText:"#c9d1d9",diffRemovalBg:"#3c1e1e",diffAdditionBg:"#11381e",diffRemovalText:"#f85149",diffAdditionText:"#3fb950",diffRemovalHighlightColor:"#ff7b72",diffRemovalHighlightBg:"#701c1c",diffAdditionHighlightColor:"#56d364",diffAdditionHighlightBg:"#116329",diffRemovalNum:"#f85149",diffAdditionNum:"#3fb950",diffRemovalPrefix:"#f85149",diffAdditionPrefix:"#3fb950",primary:"#c9d1d9",secondary:"#58a6ff",accent:"#bc8cff",success:"#3fb950",warning:"#d29922",danger:"#f85149",info:"#58a6ff",statusOn:"#58a6ff",statusOff:"#8b949e",logoTextAnsi:"\x1B[1;36m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#2ea043","#56d364"]},"GitHub Light":{id:"GitHub Light",name:"GitHub Light",text:"#24292f",textMuted:"#57606a",textDim:"#6e7781",textInverted:"#ffffff",border:"#d0d7de",borderMuted:"#d0d7de",borderDim:"#e1e4e8",bg:void 0,cardBg:"#f6f8fa",highlightBg:"#eaeef2",activeBg:"#d0d7de",inputBg:"#eaeef2",inputBorder:"#eaeef2",inputText:"#24292f",inputPlaceholder:"#57606a",inputPrompt:"#0969da",codeBg:"#ffffff",codeBorder:"#d0d7de",userMsgBg:"#eaeef2",userMsgBorder:"#eaeef2",userMsgText:"#24292f",diffRemovalBg:"#ffebe9",diffAdditionBg:"#e6ffec",diffRemovalText:"#cf222e",diffAdditionText:"#1a7f37",diffRemovalHighlightColor:"#82071e",diffRemovalHighlightBg:"#ffc1c0",diffAdditionHighlightColor:"#116329",diffAdditionHighlightBg:"#acf2bd",diffRemovalNum:"#cf222e",diffAdditionNum:"#1a7f37",diffRemovalPrefix:"#cf222e",diffAdditionPrefix:"#1a7f37",primary:"#24292f",secondary:"#0969da",accent:"#8250df",success:"#1a7f37",warning:"#9a6700",danger:"#cf222e",info:"#0969da",statusOn:"#0969da",statusOff:"#57606a",logoTextAnsi:"\x1B[1;34m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#1a7f37","#2da44e"]},"Transparent Dark":{id:"Transparent Dark",name:"Transparent Dark",text:"white",textMuted:"gray",textDim:"grey",textInverted:"black",border:"gray",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:void 0,highlightBg:"#2a2a2a",activeBg:"#3a3a3a",inputBg:"#555555",inputBorder:"#555555",inputText:"white",inputPlaceholder:"#cccccc",inputPrompt:"white",codeBg:void 0,codeBorder:"gray",userMsgBg:"#555555",userMsgBorder:"#555555",userMsgText:"white",diffRemovalBg:void 0,diffAdditionBg:void 0,diffRemovalText:"#ff6666",diffAdditionText:"#66ff66",diffRemovalHighlightColor:"#ff3333",diffRemovalHighlightBg:void 0,diffAdditionHighlightColor:"#33ff66",diffAdditionHighlightBg:void 0,diffRemovalNum:"#ff6666",diffAdditionNum:"#66ff66",diffRemovalPrefix:"#ff4d4d",diffAdditionPrefix:"#4dff88",primary:"white",secondary:"cyan",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"white",statusOff:"gray",logoTextAnsi:"\x1B[1;37m",logoBodyAnsi:"\x1B[37m",logoMutedAnsi:"\x1B[90m",logoGradient:["#0077ff","#ff00ff"]},"Transparent Light":{id:"Transparent Light",name:"Transparent Light",text:"black",textMuted:"gray",textDim:"grey",textInverted:"white",border:"gray",borderMuted:"gray",borderDim:"grey",bg:void 0,cardBg:void 0,highlightBg:"#d4d4d4",activeBg:"#c0c0c0",inputBg:"#d0d0d0",inputBorder:"#d0d0d0",inputText:"black",inputPlaceholder:"#555555",inputPrompt:"black",codeBg:void 0,codeBorder:"gray",userMsgBg:"#d0d0d0",userMsgBorder:"#d0d0d0",userMsgText:"black",diffRemovalBg:void 0,diffAdditionBg:void 0,diffRemovalText:"#c02020",diffAdditionText:"#188028",diffRemovalHighlightColor:"#800000",diffRemovalHighlightBg:void 0,diffAdditionHighlightColor:"#004000",diffAdditionHighlightBg:void 0,diffRemovalNum:"#c02020",diffAdditionNum:"#188028",diffRemovalPrefix:"#d01010",diffAdditionPrefix:"#109020",primary:"black",secondary:"blue",accent:"magenta",success:"green",warning:"yellow",danger:"red",info:"blue",statusOn:"black",statusOff:"gray",logoTextAnsi:"\x1B[1;30m",logoBodyAnsi:"\x1B[30m",logoMutedAnsi:"\x1B[38;5;244m",logoGradient:["#0077ff","#ff00ff"]},"Synthwave 84":{id:"Synthwave 84",name:"Synthwave 84",text:"#fdfdfd",textMuted:"#a08eb7",textDim:"#705c8a",textInverted:"#1a1025",textExclusive:"#e3dcf0",textMutedExclusive:"#b9abc9",border:"#fc28a8",borderMuted:"#a21568",borderDim:"#5c0a3a",bg:void 0,cardBg:"#261b38",highlightBg:"#35254d",activeBg:"#4c3570",inputBg:"#35254d",inputBorder:"#35254d",inputText:"#fdfdfd",inputPlaceholder:"#a08eb7",inputPrompt:"#03e8fc",codeBg:"#1e142b",codeBorder:"#a21568",userMsgBg:"#35254d",userMsgBorder:"#35254d",userMsgText:"#fdfdfd",diffRemovalBg:"#471434",diffAdditionBg:"#144743",diffRemovalText:"#ff4081",diffAdditionText:"#00e5ff",diffRemovalHighlightColor:"#ff79a1",diffRemovalHighlightBg:"#6b1e4e",diffAdditionHighlightColor:"#66f5ff",diffAdditionHighlightBg:"#1e6b65",diffRemovalNum:"#ff4081",diffAdditionNum:"#00e5ff",diffRemovalPrefix:"#ff79a1",diffAdditionPrefix:"#66f5ff",primary:"#fdfdfd",secondary:"#03e8fc",accent:"#fc28a8",success:"#00e5ff",warning:"#ffc107",danger:"#ff4081",info:"#b388ff",statusOn:"#03e8fc",statusOff:"#a08eb7",logoTextAnsi:"\x1B[1;35m",logoBodyAnsi:"\x1B[35m",logoMutedAnsi:"\x1B[90m",logoGradient:["#fc28a8","#03e8fc"]},"Forest Sprite":{id:"Forest Sprite",name:"Forest Sprite",text:"#d6e6d1",textMuted:"#95b38d",textDim:"#628059",textInverted:"#161c14",textExclusive:"#eaf2e8",textMutedExclusive:"#a9c7a2",border:"#74a862",borderMuted:"#477038",borderDim:"#2b4720",bg:void 0,cardBg:"#1f291c",highlightBg:"#2a3826",activeBg:"#3a4d35",inputBg:"#2a3826",inputBorder:"#2a3826",inputText:"#d6e6d1",inputPlaceholder:"#95b38d",inputPrompt:"#8feb73",codeBg:"#161e14",codeBorder:"#477038",userMsgBg:"#2a3826",userMsgBorder:"#2a3826",userMsgText:"#d6e6d1",diffRemovalBg:"#3b231c",diffAdditionBg:"#203b1c",diffRemovalText:"#db6242",diffAdditionText:"#59cc3f",diffRemovalHighlightColor:"#f0896c",diffRemovalHighlightBg:"#5c362a",diffAdditionHighlightColor:"#80e368",diffAdditionHighlightBg:"#305929",diffRemovalNum:"#db6242",diffAdditionNum:"#59cc3f",diffRemovalPrefix:"#f0896c",diffAdditionPrefix:"#80e368",primary:"#d6e6d1",secondary:"#8feb73",accent:"#e69835",success:"#59cc3f",warning:"#e69835",danger:"#db6242",info:"#73b4eb",statusOn:"#8feb73",statusOff:"#95b38d",logoTextAnsi:"\x1B[1;32m",logoBodyAnsi:"\x1B[32m",logoMutedAnsi:"\x1B[90m",logoGradient:["#8feb73","#e69835"]}};var Vo=null;var Lr=(e="Dark")=>{let t;e==="Mystery"||e==="Chaos"?(Vo||(Vo=Or[Math.floor(Math.random()*Or.length)]),t={...Vo,id:"Mystery"}):(Vo=null,xo[e]?t=xo[e]:e==="GitHub"?t=xo["GitHub Dark"]:e==="Transparent"?t=xo["Transparent Dark"]:t=xo.Dark);let n=t.codeText||t.secondary||t.info||t.logoGradient&&t.logoGradient[0]||"cyan";return{...t,codeText:n}};var Ra=()=>process.env.TERM_PROGRAM==="vscode"?"vscode":process.env.WT_SESSION?"wt":"default",xc=(e=2)=>{let t=Ra();return t==="wt"?" ".repeat(Math.max(1,e-1)):" ".repeat(e)},bc=(e="...",t="Loading...",n="Dark")=>{let s=js[Math.floor(Math.random()*js.length)],o=Lr(n),c=o.logoTextAnsi,u=o.logoBodyAnsi,a=o.logoMutedAnsi,y="\x1B[0m",p=[" \u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2591\u2591\u2591\u2588\u2588\u2588 "," \u2588\u2588\u2588\u2591 "," \u2588\u2588\u2588\u2591 "," \u2588\u2588\u2588\u2591 "," \u2591\u2591\u2591 "],g=o.logoGradient||["#0077ff","#ff00ff"],b=Ca(g).multiline(p.join(`
|
|
581
574
|
`)).split(`
|
|
582
575
|
`),h=i=>`${a}${i}${y}`;return`${b[0]}
|
|
583
576
|
${b[1]} ${c}Selected Provider: ${t}${y}
|
|
@@ -721,7 +714,7 @@ ${pt.warnings}
|
|
|
721
714
|
|
|
722
715
|
`)+`
|
|
723
716
|
[Tagged File Contents]
|
|
724
|
-
`);let di=li.replace(/\\(@\[[^\]]+\])/g,"$1"),fi=k||v?`You cannot execute tools. Instead
|
|
717
|
+
`);let di=li.replace(/\\(@\[[^\]]+\])/g,"$1"),fi=k||v?`You cannot execute tools. Instead write the tool string in chat & wait for system response
|
|
725
718
|
${v?`tool string format [tool:ToolName(arg="value")]
|
|
726
719
|
`:""}`:"",ea=process.env.forcedReasoning||!1,ui=u!=="Fast"&&(i==="Mistral"&&!Io(e)||u!=="High"&&i==="Google")?`${i==="Mistral"&&!Io(e)||e.toLowerCase().startsWith("gemma")||ea?`[system] strictly follow thinking policy as high priority. do not start a response without <think>...</think> [/system]
|
|
727
720
|
`:""}`:"",So="",gi=!!b?.autoExcludeMetadata,ta=!!(un||us||fi||ls||Me||ui||Zn||b?.dynamicDirAwareness||b?.autoTruncateResults||_);gi&&!ta?So=di.trim():So=`[System Metadata]
|
|
@@ -729,7 +722,7 @@ Time: ${gi?Oe:Re}${b?.dynamicDirAwareness?ai:""}${Zn?`
|
|
|
729
722
|
WARNING: CWD Changed from previous: "${vt}" to current: "${process.cwd()}", write change in chat to avoid future path mismatches
|
|
730
723
|
`:""}${Me}${un}
|
|
731
724
|
[/Metadata]
|
|
732
|
-
${ls}${ui}${us}${fi}[user prompt] ${di.trim()} [/user prompt]`.trim();let hi={role:"user",text:So};To&&(hi.binaryPart=To),r.forEach(H=>{H.text&&H.role==="agent"&&(H.text=qt(H.text))}),r.push(hi),ls&&t[t.length-1]?.id&&(yield{type:"summary_injected",content:{id:t[t.length-1].id,text:So}});let en=null,Sn=a==="Flux"?50:15;Sn=a.toLowerCase().includes("cu")?75:Sn;let na=Math.floor(Sn/2),mi=0,rn=16;yield{type:"status",content:"Connecting"},bt=!1;let gs=[],_o=!1,pi=!1;for(let H=0;H<=Sn;H++){let Pe=Math.floor(Sn*.95);if(H>=Pe&&mi<Pe&&typeof n?.onAskUser=="function"){mi=Pe;try{let me="Agent has been running for a long time. Do you want to continue execution?",_e=[{id:"continue",label:"Continue",description:"Add few more steps"},{id:"cancel",label:"Cancel",description:"Stop extending and finish current turn limit"}],ee=await n.onAskUser(me,_e);ee&&(ee.toLowerCase().includes("continue")||ee==="Continue")&&(Sn+=na)}catch{}}let Jt=await Ss("agent",n);if(!Jt.allowed)throw new Error(Jt.reason||`Budget Exhausted for Provider (${i||"Agent"})`);let Qe=[];if(_o=!1,a==="ICU"||a==="FluxCU")try{yield{type:"status",content:"Capturing Screen"},await new Promise(ee=>setTimeout(ee,1e3));let{captureGriddedScreenshot:me}=await import("./screen_grid-
|
|
725
|
+
${ls}${ui}${us}${fi}[user prompt] ${di.trim()} [/user prompt]`.trim();let hi={role:"user",text:So};To&&(hi.binaryPart=To),r.forEach(H=>{H.text&&H.role==="agent"&&(H.text=qt(H.text))}),r.push(hi),ls&&t[t.length-1]?.id&&(yield{type:"summary_injected",content:{id:t[t.length-1].id,text:So}});let en=null,Sn=a==="Flux"?50:15;Sn=a.toLowerCase().includes("cu")?75:Sn;let na=Math.floor(Sn/2),mi=0,rn=16;yield{type:"status",content:"Connecting"},bt=!1;let gs=[],_o=!1,pi=!1;for(let H=0;H<=Sn;H++){let Pe=Math.floor(Sn*.95);if(H>=Pe&&mi<Pe&&typeof n?.onAskUser=="function"){mi=Pe;try{let me="Agent has been running for a long time. Do you want to continue execution?",_e=[{id:"continue",label:"Continue",description:"Add few more steps"},{id:"cancel",label:"Cancel",description:"Stop extending and finish current turn limit"}],ee=await n.onAskUser(me,_e);ee&&(ee.toLowerCase().includes("continue")||ee==="Continue")&&(Sn+=na)}catch{}}let Jt=await Ss("agent",n);if(!Jt.allowed)throw new Error(Jt.reason||`Budget Exhausted for Provider (${i||"Agent"})`);let Qe=[];if(_o=!1,a==="ICU"||a==="FluxCU")try{yield{type:"status",content:"Capturing Screen"},await new Promise(ee=>setTimeout(ee,1e3));let{captureGriddedScreenshot:me}=await import("./screen_grid-YL4W6LEM.js"),_e=await me();if(_e&&_e.base64){let ee="[system] Fresh Gridded Screen Feedback Captured. Use numeric coordinates. Old screenshots will be removed when new screenshot is captured, summarize in text if context is needed later [/system]",Pt={inlineData:{mimeType:_e.mimeType,data:_e.base64}},It=b?.imageHistoryCU||"Standard",_t=It==="Low"?1:It==="Extended"?5:3,Xt=r.filter(Ke=>Array.isArray(Ke.parts)&&Ke.parts.some($t=>$t.inlineData));if(Xt.length>=_t){let Ke=Xt.length-_t+1;for(let $t=0;$t<Ke;$t++){let At=Xt[$t];Array.isArray(At.parts)&&(At.parts=At.parts.filter(wt=>!wt.inlineData))}}if(r.length>0&&r[r.length-1].role==="user"){let Ke=r[r.length-1];typeof Ke.text=="string"&&(Ke.text+=`
|
|
733
726
|
|
|
734
727
|
${ee}`,Array.isArray(Ke.parts)||(Ke.parts=[{text:Ke.text}]),Ke.parts.push(Pt))}else r.push({role:"user",text:ee,parts:[{text:ee},Pt]})}}catch(me){console.error("Vision screenshot capture error:",me)}if(b?.compression===0&&(h?.tokens||0)>O&&(r=Ci(r,6)),H>0?yield{type:"status",content:"Working"}:yield{type:"status",content:"Connecting"},bt){try{let{clearPendingNudges:me}=await import("./subagent_state-LZCOZSUJ.js");me()}catch{}yield{type:"status",content:"Request Cancelled"},yield{type:"text",content:`
|
|
735
728
|
|
|
@@ -863,9 +856,9 @@ CAUSE: ${f.cause?.stack||f.cause}`:""}
|
|
|
863
856
|
----------------------------------------------------------------------
|
|
864
857
|
|
|
865
858
|
`),typeof flushGoogleBuffer=="function"&&(yield*flushGoogleBuffer()),yield{type:"tool_result",content:`ERROR: [INTERNAL CRITICAL] ${M}`}}finally{C&&(clearInterval(C),C=null),typeof performance<"u"&&performance.clearMeasures&&(performance.clearMeasures(),performance.clearMarks()),await Oo.commitTransaction(),b?.advanceRollback&&await ao.cleanup(p),await Hn()}yield{type:"status",content:null}},xf=async(e,t,n=null,s=null,o=50,c=null,u=!1)=>{let a=await ro(),y={...a,...t},p=process.env.SUBAGENT_MODEL?process.env.SUBAGENT_MODEL.trim():null,g=process.env.SUBAGENT_PROVIDER?process.env.SUBAGENT_PROVIDER.trim():null,b=new Date,h=`${b.getFullYear()}-${b.toLocaleString("en-US",{month:"short"}).toUpperCase()}-${String(b.getDate()).padStart(2,"0")}, ${b.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",hour12:!0}).replace(":","-")}`,l=(C=>{if(!C)return null;let f=C.toLowerCase();return f==="google"?"Google":f==="deepseek"?"DeepSeek":f==="openrouter"?"OpenRouter":f==="nvidia"?"NVIDIA":f==="mistral"?"Mistral":f==="ollama"?"Ollama":f==="inferx"?"InferX":f==="sensenova"?"SenseNova":f==="poolside"?"Poolside":f==="9router"||f==="9Router"?"9router":f==="aihubmix"||f==="aihub"?"AIHubMix":f==="explabs"||f==="experientiallabs"||f==="experimentallabs"?"ExpLabs":f==="tokenharbor"||f==="token harbor"||f==="token_harbor"||f==="thk"?"TokenHarbor":f==="apinex"||f==="apx"?"APInex":null})(g),k=y?.systemSettings?.CustomSubAgent?y?.systemSettings?.SubAgentModel:null,v=y?.systemSettings?.CustomSubAgent?y?.systemSettings?.SubAgentProvider:null,m=null;if(k==="ENV"?(m=p,p&&l&&(y.aiProvider=l)):k&&k!=="Default"?(m=k,v&&(y.aiProvider=v)):p&&l&&(y.aiProvider=l),y.aiProvider){let C=await Ts(y.aiProvider);C&&(y.apiKey=C)}let _=C=>{if(!C||typeof C!="string")return{allowed:!0};let f=[/rm\s+-[rf]{1,2}\s+[\/*.]/i,/rmdir\s+\/[sq]/i,/del\s+\/[fsq]/i,/\bformat\b\s+[a-z]:/i,/mkfs/i,/dd\s+if=/i,/\b(shutdown|reboot|poweroff|init\s+0|init\s+6)\b/i,/chmod\s+(-R\s+)?777\s+[\/*.]/i,/chown\s+(-R\s+)?root/i,/git\s+push\s+.*--force/i,/git\s+clean\s+-fdx/i,/\bsudo\s+su\b/i,/\bsu\s+-\b/i];for(let r of f)if(r.test(C))return{allowed:!1,reason:`Blocked potentially destructive or unsafe command pattern: "${r.source}"`};return{allowed:!0}},P=n||m||t?.modelName||t?.activeModel||a.activeModel,E=process.platform==="win32"?"Windows":process.platform==="darwin"?"macOS":"Linux",S=`-- TOOL DEFINITIONS (path = relative to CWD, path separator: '/') --
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
-
|
|
859
|
+
Tool format \`[tool:ToolName(arg1="value1")]\` in NEW line, chat text
|
|
860
|
+
Rules:
|
|
861
|
+
- JSON escape literal sequences, backslash: \\\\, newLine: \\ n
|
|
869
862
|
- Same file, multiple edits? ONE PatchFile (\u226415 blocks)
|
|
870
863
|
- Need text or huge file? CodeSearch > Full Read
|
|
871
864
|
- Avoid unnecessary large file chunk reads
|
|
@@ -890,16 +883,15 @@ ${u?"- AskMain(question=string). Communicate with PARENT/MAIN AGENT. When clarif
|
|
|
890
883
|
- Run(command=string). Runs ${E==="Windows"?Ai()?"powershell":"windows CMD":"bash"} command. Destructive command \u2192 Ask user`.trim(),R=`=== START SYSTEM PROMPT ===
|
|
891
884
|
Identity: FluxFlow subagent helping the main Agent
|
|
892
885
|
Your task is: "${e}"
|
|
886
|
+
CWD: ${process.cwd()}
|
|
887
|
+
|
|
888
|
+
${S.trimEnd()}
|
|
893
889
|
|
|
894
890
|
-- THINKING GUIDANCE --
|
|
895
891
|
NO EXPLICIT THINKING REQUIRED. FOCUS ON TASK COMPLETION
|
|
896
892
|
Main focus: tools and task, not chatting
|
|
897
893
|
On completion, provide a detailed summary in Tables/Markdown Format with file modified info. If any task failed report back in detail
|
|
898
894
|
|
|
899
|
-
CWD: ${process.cwd()}
|
|
900
|
-
|
|
901
|
-
${S.trimEnd()}
|
|
902
|
-
|
|
903
895
|
Current Time: ${h}
|
|
904
896
|
=== END SYSTEM PROMPT ===`,$=[{role:"user",text:`Complete this task: ${e}`}],w=0,d="";for(;w<o;){let C=await Ss("subagent",y);if(!C.allowed)throw new Error(C.reason||`Budget Exhausted for Provider (${y?.aiProvider||"Subagent"})`);if(bt){if(t?.taskId&&typeof Kt<"u"){let L=Kt.find(B=>B.id===t.taskId);L&&(L.status="cancelled")}throw c&&c("[SUBAGENT CANCELLED] Subagent task was cancelled."),new Error("Subagent task was cancelled.")}if(t?.taskId&&typeof Kt<"u"){let L=Kt.find(B=>B.id===t.taskId);if(L&&L.status==="cancelled")throw c&&c("[SUBAGENT CANCELLED] Subagent task was cancelled."),new Error("Subagent task was cancelled.")}let f=$.map(L=>({role:L.role==="user"?"user":"model",parts:[{text:L.text}]}));c&&c(`[Subagent Turn ${w+1}]...`);let r=["Fast","Low","Medium","High"],A=process.env.SUBAGENT_THINKING,M=r.includes(A)?A:"Low",D=(await as(y,P,f,R,M)).text||"",O=Jr(qt(D).trim());d=O,c&&c(`[Subagent Response]
|
|
905
897
|
${O}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{execSync as a}from"child_process";var t=null,k=()=>{if(process.platform!=="win32")return!1;if(t!==null)return t;try{a("where.exe pwsh.exe",{stdio:"ignore",windowsHide:!0}),t=!0}catch{t=!1}return t},r=null,l=()=>{if(process.platform!=="win32")return!1;if(r!==null)return r;try{a("where.exe powershell.exe",{stdio:"ignore",windowsHide:!0}),r=!0}catch{r=!1}return r},w=()=>k()?"pwsh":l()?"powershell":"cmd",n=null,v=(e,c,u,d,g=!1,p=!0,f,i=!1)=>{n===null&&(n=g);let
|
|
1
|
+
import{execSync as a}from"child_process";var t=null,k=()=>{if(process.platform!=="win32")return!1;if(t!==null)return t;try{a("where.exe pwsh.exe",{stdio:"ignore",windowsHide:!0}),t=!0}catch{t=!1}return t},r=null,l=()=>{if(process.platform!=="win32")return!1;if(r!==null)return r;try{a("where.exe powershell.exe",{stdio:"ignore",windowsHide:!0}),r=!0}catch{r=!1}return r},w=()=>k()?"pwsh":l()?"powershell":"cmd",n=null,v=(e,c,u,d,g=!1,p=!0,f,i=!1)=>{n===null&&(n=g);let h=`- JSON escape literal sequences, backslash: \\\\, newLine: \\ n
|
|
2
2
|
- Same file, multiple edits? One PatchFile (\u226415 blocks)${f?"":`
|
|
3
3
|
- Tool denied? Ask for guidance`}
|
|
4
4
|
- Need text or huge file? CodeSearch > Full Read
|
|
@@ -27,7 +27,7 @@ Invocations:
|
|
|
27
27
|
- Await(id=string, timeout=int[..=180]). Event driven wait
|
|
28
28
|
- GetProgress(id=string). Poll sparingly; NO initial poll. Work or await. Never end while subagent runs
|
|
29
29
|
- Steer(id=string, message=string). Inject additional instruction into active async subagent
|
|
30
|
-
- Cancel(id=string). Cancel async task ONLY if stalled (2m+) or incorrect`:""}`,
|
|
30
|
+
- Cancel(id=string). Cancel async task ONLY if stalled (2m+) or incorrect`:""}`,m=`**Creative Tools (path = relative; first argument, path separator: '/')**
|
|
31
31
|
- WritePDF(path=string, content=string, orientation="landscape/portrait"). Proactive A4 page breaks must in css. HTML/CSS for premium layout, stable margins & headers/footers, no watermarks
|
|
32
32
|
- WriteDoc(path=string, content=string). A4 Word document, no watermarks, stable margins & headers/footers`,o=`**Computer Use Tools (GUI Desktop Automation)**
|
|
33
33
|
- Click(gridId=int, type="single/double", button="left/middle/right", intendedClickText=string). Click target grid number, intendedClickText: literal text/symbol on screen (OCR scannable, upto 3 words). Double click desktop icons
|
|
@@ -37,10 +37,10 @@ Invocations:
|
|
|
37
37
|
- KeyPress(key="key or ;-separated combination, eg: enter, back, backspace, clearInput, ctrl;c, alt;tab, f5, f11, alt;f4"). Press key, shortcut, function key (f1-f12), or clear active input field
|
|
38
38
|
- RecaptureScreen(). Request fresh gridded screenshot`;return`
|
|
39
39
|
-- TOOLS --
|
|
40
|
-
|
|
41
|
-
|
|
40
|
+
In chat output the format \`[tool:ToolName(arg1="value1")]\` in NEW line
|
|
41
|
+
Rules:
|
|
42
42
|
- Max 5 tools/turn${e==="Flux"||e.toLowerCase()==="fluxcu"&&!i?" (Goal: 5+)":""}
|
|
43
|
-
${e==="Flux"||e.toLowerCase()==="fluxcu"?`${
|
|
43
|
+
${e==="Flux"||e.toLowerCase()==="fluxcu"?`${h}`:""}
|
|
44
44
|
**User Communication**
|
|
45
45
|
- AskUser(question=string, optionA?="title::description", ...MAX4). Ambiguity, path divergence, security risk
|
|
46
46
|
|
|
@@ -49,4 +49,4 @@ ${e==="Flux"||e.toLowerCase()==="fluxcu"?`${m}`:""}
|
|
|
49
49
|
- WebScrape(url=string). Proactive use for specific webpage/docs
|
|
50
50
|
|
|
51
51
|
${e==="ICU"?`${o}`:e==="FluxCU"?`${s}
|
|
52
|
-
${o}`:e==="Flux"?`${s}`:`${
|
|
52
|
+
${o}`:e==="Flux"?`${s}`:`${m}`}`.trim()};export{l as a,w as b,v as c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v,b,c as h,d as f}from"./chunk-
|
|
1
|
+
import{a as v,b,c as h,d as f}from"./chunk-L3W2X74K.js";import{n as u,o as s,q as m}from"./chunk-RI37VZYB.js";import r from"fs-extra";import o from"path";r.ensureDirSync(u);var l=null;async function B(e,t){try{if(e.type==="create")await r.pathExists(e.filePath)&&(await r.chmod(e.filePath,438).catch(()=>{}),await r.remove(e.filePath));else if(e.type==="update"){if(!e.backupFile)return;let a=o.join(u,t.chatId,e.backupFile);if(await r.pathExists(a)){let n=h(a,null);if(!n||!n.data)throw new Error(`Backup container corrupt or empty for ${o.basename(e.filePath)}`);let p=b(n.data);await r.pathExists(e.filePath)&&await r.chmod(e.filePath,438).catch(()=>{}),await r.writeFile(e.filePath,p,"utf8")}}}catch(a){throw new Error(`Restoration failed for ${o.basename(e.filePath)}: ${a.message}`)}}async function P(e,t,a=7){let n=0;for(;n<a;)try{return await B(e,t),!0}catch{if(n++,n>=a)return!1;let d=Math.min(100*Math.pow(2,n-1),5e3);await new Promise(i=>setTimeout(i,d))}return!1}var I=null,R={async startTransaction(e,t){I=e,l={id:`tx_prompt_${Date.now()}`,chatId:e,timestamp:new Date().toISOString(),prompt:t.trim(),changes:[],reverted:!1},f(m,l)},async recordFileChange(e,t=null){try{if(!l){if(I){let i=h(s,[]),c=[...i].reverse().find(w=>w.chatId===I);if(c){if(c.changes.some(E=>E.filePath===e))return;let g=await r.pathExists(e)||t?"update":"create",y=null;if(g==="update"){let E=o.basename(e);y=`${c.id}_${E}.bak`;let x=o.join(u,c.chatId);await r.ensureDir(x);let T=o.join(x,y),F=t!==null?t:await r.readFile(e,"utf8").catch(()=>null);F!==null?f(T,{data:v(F)}):(g="create",y=null)}c.changes.push({filePath:e,type:g,backupFile:y}),f(s,i)}}return}if(l.changes.some(i=>i.filePath===e))return;let p=await r.pathExists(e)||t?"update":"create",d=null;if(p==="update"){let i=o.basename(e);d=`${l.id}_${i}.bak`;let c=o.join(u,l.chatId);await r.ensureDir(c);let w=o.join(c,d),k=t!==null?t:await r.readFile(e,"utf8").catch(()=>null);k!==null?f(w,{data:v(k)}):(p="create",d=null)}l.changes.push({filePath:e,type:p,backupFile:d}),f(m,l)}catch{}},async commitTransaction(){if(l)try{let e=h(s,[]);if(e.push(l),e.length>512e3){let t=e.shift();if(t.changes)for(let a of t.changes)a.backupFile&&await r.remove(o.join(u,t.chatId,a.backupFile)).catch(()=>{})}f(s,e),await r.remove(m).catch(()=>{})}catch{}finally{l=null}},async recoverCrashedTransaction(){try{if(await r.pathExists(m)){let e=h(m,null);if(e?.changes?.length>0){let t=h(s,[]);t.some(a=>a.id===e.id)||(t.push(e),f(s,t))}await r.remove(m).catch(()=>{})}}catch{}},async rollbackToBefore(e){let t=h(s,null);if(!t)throw new Error("No transaction ledger found.");let a=t.findIndex(i=>i.id===e);if(a===-1)throw new Error(`Transaction [${e}] not found.`);let n=t[a].chatId,p=t[a].prompt,d=t.slice(a).filter(i=>i.chatId===n&&!i.reverted).reverse();for(let i of d){for(let c of[...i.changes].reverse())await P(c,i);for(let c of i.changes)if(c.backupFile){let w=o.join(u,i.chatId,c.backupFile);await r.remove(w).catch(()=>{})}t=t.filter(c=>c.id!==i.id),f(s,t)}return{success:!0,chatId:n,targetPrompt:p}},async getChatHistory(e){try{return h(s,[]).filter(a=>a.chatId===e&&!a.reverted)}catch{return[]}},async deleteChatBackups(e){try{await r.remove(o.join(u,e));let t=h(s,[]),a=t.filter(n=>n.chatId!==e);t.length!==a.length&&f(s,a)}catch{}}};export{R as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import c from"fs";import a from"path";import i from"crypto";var d=66,p=!0,l=t=>{let n=Buffer.isBuffer(t)?t:Buffer.from(t),e=Buffer.alloc(n.length);for(let r=0;r<n.length;r++)e[r]=n[r]^d;return e},u="aes-256-cbc",y=i.createHash("sha256").update("fluxflow-cli-sanctuary-key").digest(),h=(t,n=!1)=>{if(p&&!n)return t;let e=i.randomBytes(16),r=i.createCipheriv(u,y,e),s=r.update(t,"utf8","hex");return s+=r.final("hex"),e.toString("hex")+":"+s},m=(t,n=!1)=>{if(p&&!n)return t;let e=t.split(":");if(e.length!==2)throw new Error("Invalid AES format");let r=Buffer.from(e[0],"hex"),s=e[1],o=i.createDecipheriv(u,y,r),f=o.update(s,"hex","utf8");return f+=o.final("utf8"),f},x=(t,n={})=>{try{if(!c.existsSync(t))return n;let e=c.readFileSync(t),r=e.toString("utf8").trim();if(r.startsWith("{")||r.startsWith("["))return JSON.parse(r);try{let o=m(r,!0);return JSON.parse(o)}catch{}let s=l(e).toString("utf8");if(s.startsWith("{")||s.startsWith("["))return JSON.parse(s);throw new Error("Unsupported or corrupt encryption format")}catch(e){return console.error(`Vault Read Error [${a.basename(t)}]:`,e.message),n}},S=(t,n,e=!1)=>{try{let r=a.dirname(t);c.existsSync(r)||c.mkdirSync(r,{recursive:!0});let s=JSON.stringify(n,null,2),o=h(s,e);c.writeFileSync(t,o,"utf8")}catch(r){console.error(`Vault Write Error [${a.basename(t)}]:`,r.message)}},A=x,J=S;export{h as a,m as b,x as c,S as d,A as e,J as f};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as u}from"./chunk-QGPOMXO4.js";import{e as m,f as c}from"./chunk-
|
|
1
|
+
import{n as u}from"./chunk-QGPOMXO4.js";import{e as m,f as c}from"./chunk-L3W2X74K.js";import{b as s}from"./chunk-RI37VZYB.js";import n from"fs-extra";import g from"path";var r={mode:"Flux",display:0,thinkingLevel:"Medium",aiProvider:"Google",activeModel:u("Google","Free")||"gemma-4-31b-it",showFullThinking:!0,apiTier:"Free",quotas:{agentLimit:999999,backgroundLimit:999999,searchLimit:100,customModelId:"",customLimit:0,providerTiers:{Google:"Free",DeepSeek:"Free",NVIDIA:"Free",OpenRouter:"Free",InferX:"Free",SenseNova:"Free",Poolside:"Free",ExpLabs:"Free",TokenHarbor:"Free",APInex:"Free"}},systemSettings:{memory:!1,theme:"Dark",compression:0,autoExec:!0,allowExternalAccess:!1,advanceRollback:!1,autoDeleteHistory:"7d",useExternalData:!1,externalDataPath:"",preserveThinking:!0,loadingPhrases:!0,progressiveRendering:!0,showTPMEstimate:!0,subAgents:!1,CustomSubAgent:!1,SubAgentModel:"Default",SubAgentProvider:"",dynamicDirAwareness:!1,indentationTree:!0,ollamaEndpoint:"Cloud",compressToolResults:!1,autoTruncateResults:!0,imageHistoryCU:"Standard",contextLength:"256k",keepReasoningContext:!1,autoExcludeMetadata:!1,disableTodo:!1},profileData:{name:null,nickname:null,instructions:null},imageSettings:{keyType:"Default",quality:"Low-High",apiKey:""}},p=async()=>{let t={...r};try{if(await n.exists(s)){let e=m(s);if(e.imageSettings&&e.imageSettings.apiKey)try{let a=e.imageSettings.apiKey,{saveSecret:i}=await import("./secrets-BJGXCZRP.js");await i("POLLINATIONS_API_KEY",a),e.imageSettings.apiKey="",c(s,e)}catch{}t={...r,...e,quotas:{...r.quotas,...e.quotas,providerTiers:{...r.quotas.providerTiers,...e.quotas?.providerTiers||{}}},systemSettings:{...r.systemSettings,...e.systemSettings},profileData:{...r.profileData,...e.profileData},imageSettings:{...r.imageSettings,...e.imageSettings}}}}catch(e){console.error("Failed to load settings:",e)}try{let{getSecret:e}=await import("./secrets-BJGXCZRP.js"),a=await e("POLLINATIONS_API_KEY");a&&(t.imageSettings.apiKey=a)}catch{}if(t.showFullThinking===!1){t.showFullThinking=!0;try{c(s,t)}catch{}}return t},S=async t=>{let{FLUXFLOW_DIR:e}=await import("./paths-Y7ACZJAE.js"),a=["logs","secret"];for(let i of a){let l=g.join(e,i),o=g.join(t,i);try{await n.exists(l)&&(await n.ensureDir(o),await n.copy(l,o,{overwrite:!0}))}catch(d){console.error(`Migration failed for ${i}:`,d)}}},D=async t=>{try{let e=await p();if(!e.systemSettings.useExternalData&&t.systemSettings?.useExternalData&&t.systemSettings?.externalDataPath&&await S(t.systemSettings.externalDataPath),t.imageSettings&&t.imageSettings.apiKey!==void 0){let{saveSecret:i,removeSecret:l}=await import("./secrets-BJGXCZRP.js"),o=t.imageSettings.apiKey;o?await i("POLLINATIONS_API_KEY",o):await l("POLLINATIONS_API_KEY")}let a={...e,...t};return a.imageSettings&&(a.imageSettings={...a.imageSettings,apiKey:""}),await n.ensureDir(g.dirname(s)),c(s,a),!0}catch(e){return console.error("Failed to save settings:",e),!1}};export{p as a,D as b};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as F,d as y}from"./chunk-
|
|
1
|
+
import{c as F,d as y}from"./chunk-L3W2X74K.js";import{c as g,p as h}from"./chunk-RI37VZYB.js";import o from"fs-extra";import a from"path";var P=["node_modules","dist","bin","logs",".git",".fluxflow","secret",".gemini",".agents","tmp","temp","build","out","snapshots"];async function k(t,s=t){let e={},i=await o.readdir(t,{withFileTypes:!0}).catch(()=>[]);for(let c of i){if(P.includes(c.name))continue;let l=a.join(t,c.name),d=a.relative(s,l).replace(/\\/g,"/");if(c.isDirectory()){let n=await k(l,s);Object.assign(e,n)}else{let n=await o.stat(l).catch(()=>null);n&&(e[d]={size:n.size,mtime:n.mtimeMs})}}return e}async function E(t,s){await o.ensureDir(t);for(let e of Object.keys(s)){let i=a.join(process.cwd(),e),c=a.join(t,e);await o.ensureDir(a.dirname(c)),await o.copyFile(i,c).catch(()=>{})}}async function j(t,s,e=null,i=null){if(!await o.pathExists(t))return;i||(i=t);let c=await o.readdir(t,{withFileTypes:!0}).catch(()=>[]);for(let l of c){let d=a.join(t,l.name),n=a.join(s,l.name);if(l.isDirectory())await j(d,n,e,i);else{let u=a.relative(i,d).replace(/\\/g,"/"),p=await o.pathExists(n);p&&await o.chmod(n,438).catch(()=>{}),await o.ensureDir(a.dirname(n));let f=await o.copyFile(d,n).then(()=>!0).catch(()=>!1);await o.chmod(n,438).catch(()=>{}),e&&(f?p?e.replaced++:e.restored++:e.failed.push(u))}}}var C={async takeInitialSnapshot(t){try{let s=a.join(g,"snapshots",t);await o.remove(s).catch(()=>{}),await o.ensureDir(s);let e=await k(process.cwd());await E(a.join(s,"initial"),e);let i=F(h,{});i[t]={initialManifest:e,currentManifest:e,checkpoints:[{id:"initial",timestamp:new Date().toISOString(),newFiles:[],modifiedFiles:[],deletedFiles:[],toolsUsed:[]}]},y(h,i)}catch{}},async recordTurnDelta(t,s,e=[]){try{let i=F(h,{}),c=i[t];if(!c)return;let l=c.currentManifest||c.initialManifest,d=await k(process.cwd()),n=[],u=[],p=[];for(let[r,m]of Object.entries(d)){let w=l[r];w?(w.size!==m.size||w.mtime!==m.mtime)&&u.push(r):n.push(r)}for(let r of Object.keys(l))d[r]||p.push(r);let f=[...n,...u];if(f.length>0||p.length>0){let r={};for(let w of f)r[w]=d[w];let m=a.join(g,"snapshots",t,`turn_${s}`);await E(m,r)}c.checkpoints.push({id:`turn_${s}`,timestamp:new Date().toISOString(),newFiles:n,modifiedFiles:u,deletedFiles:p,toolsUsed:e}),c.currentManifest=d,y(h,i)}catch{}},async getCheckpoints(t){try{let e=F(h,{})[t];return e?e.checkpoints||[]:[]}catch{return[]}},async rollbackToCheckpoint(t,s){try{let e=F(h,{}),i=e[t];if(!i)throw new Error("No session active for Advance Rollback.");let c=i.checkpoints||[],l=c.findIndex(f=>f.id===s);if(l===-1)throw new Error(`Checkpoint [${s}] not found.`);let d=a.join(g,"snapshots",t),n={restored:0,replaced:0,failed:[]},u=await k(process.cwd());for(let f of Object.keys(u)){let r=a.join(process.cwd(),f);await o.chmod(r,438).catch(()=>{}),await o.remove(r).catch(()=>{})}let p=a.join(d,"initial");await j(p,process.cwd(),n,p);for(let f=1;f<=l;f++){let r=c[f],m=a.join(d,r.id);if(await j(m,process.cwd(),n,m),r.deletedFiles&&r.deletedFiles.length>0)for(let w of r.deletedFiles){let D=a.join(process.cwd(),w);await o.chmod(D,438).catch(()=>{}),await o.remove(D).catch(()=>{})}}return i.checkpoints=c.slice(0,l+1),i.currentManifest=await k(process.cwd()),y(h,e),{checkpointId:s,stats:n}}catch(e){throw new Error(`Rollback failed: ${e.message}`)}},async getLatestFileChanges(t){try{let e=F(h,{})[t];if(!e||!e.checkpoints||e.checkpoints.length===0)return{newFiles:[],modifiedFiles:[],deletedFiles:[]};let i=e.checkpoints[e.checkpoints.length-1];return{newFiles:i.newFiles||[],modifiedFiles:i.modifiedFiles||[],deletedFiles:i.deletedFiles||[]}}catch{return{newFiles:[],modifiedFiles:[],deletedFiles:[]}}},async cleanup(t){try{let s=a.join(g,"snapshots",t);await o.remove(s).catch(()=>{});let e=F(h,{});e[t]&&(delete e[t],y(h,e))}catch{}}};export{C as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as f}from"./chunk-
|
|
1
|
+
import{e as f}from"./chunk-6KFABN4O.js";import{mouse as c,keyboard as i,Button as u,Key as e,Point as l,clipboard as R}from"@nut-tree-fork/nut-js";c.config.autoDelayMs=50;i.config.autoDelayMs=50;async function w(){try{await i.releaseKey(e.LeftControl,e.RightControl,e.LeftAlt,e.RightAlt,e.LeftShift,e.RightShift,e.LeftSuper,e.RightSuper)}catch{}}async function E(n,t,s={}){let r=await f(t);if(!r&&(n==="move"||n==="click"||n==="drag"))return`ERROR: Invalid target location specified: ${JSON.stringify(t)}`;try{switch(n.toLowerCase()){case"move":return await c.setPosition(new l(r.x,r.y)),`SUCCESS: Moved mouse to grid target ${typeof t=="string"?t:`(${r.x}, ${r.y})`}`;case"click":{await c.setPosition(new l(r.x,r.y));let a=s.button==="right"?u.RIGHT:s.button==="middle"?u.MIDDLE:u.LEFT;return s.clickType==="double"?await c.doubleClick(a):await c.click(a),`SUCCESS: ${s.clickType||"Single"} clicked ${s.button||"left"} button at ${typeof t=="string"?t:`(${r.x}, ${r.y})`}`}case"drag":{let a=await f(s.from||t),o=await f(s.to);return!a||!o?'ERROR: Drag requires valid "from" and "to" target coordinates/grid codes.':(await c.setPosition(new l(a.x,a.y)),await c.pressButton(u.LEFT),await c.setPosition(new l(o.x,o.y)),await c.releaseButton(u.LEFT),`SUCCESS: Dragged mouse from (${a.x}, ${a.y}) to (${o.x}, ${o.y})`)}case"scroll":{let a=r||await f({x:640,y:360});a&&(await c.setPosition(new l(a.x,a.y)),await new Promise(d=>setTimeout(d,60)));let o=parseInt(s.amount,10);(isNaN(o)||o<=0)&&(o=5);let y=o>50?Math.min(20,Math.max(1,Math.round(o/100))):Math.min(20,o),S=s.direction==="up";for(let d=0;d<y;d++)S?await c.scrollUp(120):await c.scrollDown(120),await new Promise(C=>setTimeout(C,20));return`SUCCESS: Scrolled ${s.direction||"down"} (${y} notches${r?` at target (${r.x}, ${r.y})`:" at screen center"})`}default:return`ERROR: Unsupported mouse action "${n}"`}}catch(a){return`ERROR: Mouse action failed: ${a.message}`}}var m={enter:e.Enter,return:e.Return,escape:e.Escape,esc:e.Escape,backspace:e.Backspace,tab:e.Tab,space:e.Space,up:e.Up,down:e.Down,left:e.Left,right:e.Right,ctrl:e.LeftControl,control:e.LeftControl,alt:e.LeftAlt,shift:e.LeftShift,cmd:e.LeftCmd,win:e.LeftWin,meta:e.LeftWin,super:e.LeftSuper,a:e.A,b:e.B,c:e.C,d:e.D,e:e.E,f:e.F,g:e.G,h:e.H,i:e.I,j:e.J,k:e.K,l:e.L,m:e.M,n:e.N,o:e.O,p:e.P,q:e.Q,r:e.R,s:e.S,t:e.T,u:e.U,v:e.V,w:e.W,x:e.X,y:e.Y,z:e.Z,0:e.Num0,1:e.Num1,2:e.Num2,3:e.Num3,4:e.Num4,5:e.Num5,6:e.Num6,7:e.Num7,8:e.Num8,9:e.Num9,f1:e.F1,f2:e.F2,f3:e.F3,f4:e.F4,f5:e.F5,f6:e.F6,f7:e.F7,f8:e.F8,f9:e.F9,f10:e.F10,f11:e.F11,f12:e.F12},p=n=>{if(!n)return;let t=String(n).toLowerCase().trim();if(m[t]!==void 0)return m[t];if(e[n]!==void 0)return e[n];if(e[t.toUpperCase()]!==void 0)return e[t.toUpperCase()]};async function $(n,t,s={}){try{switch(n.toLowerCase()){case"type":{if(typeof t!="string")return"ERROR: Type action requires a valid string input";await w(),await R.setContent(t);let a=process.platform==="darwin"?e.LeftSuper:e.LeftControl;return await i.pressKey(a,e.V),await i.releaseKey(a,e.V),await w(),s.autoPressEnter?(await new Promise(o=>setTimeout(o,50)),await i.type(e.Enter),`SUCCESS: Typed text input ("${t.length>20?t.substring(0,20)+"...":t}") and pressed Enter`):`SUCCESS: Typed text input ("${t.length>20?t.substring(0,20)+"...":t}")`}case"key_press":{let r=p(t);return r===void 0?`ERROR: Unknown key name "${t}"`:(await i.type(r),`SUCCESS: Pressed key ${t}`)}case"key_combination":{if(!Array.isArray(t))return'ERROR: key_combination requires an array of keys (e.g. ["ctrl", "c"])';let r=t.map(a=>p(a)).filter(a=>a!==void 0);return r.length===0?"ERROR: Invalid key combination":(await i.pressKey(...r),await i.releaseKey(...r),`SUCCESS: Executed key combination [${t.join(" + ")}]`)}case"clear_input":return await i.pressKey(e.LeftControl,e.A),await i.releaseKey(e.LeftControl,e.A),await i.type(e.Backspace),"SUCCESS: Cleared active text input (Select All + Backspace)";case"browser_back":{let r=process.platform==="darwin";return r?(await i.pressKey(e.LeftSuper,e.Left),await i.releaseKey(e.LeftSuper,e.Left)):(await i.pressKey(e.LeftAlt,e.Left),await i.releaseKey(e.LeftAlt,e.Left)),await w(),`SUCCESS: Browser back navigation (${r?"Cmd+Left":"Alt+Left"})`}default:return`ERROR: Unsupported keyboard action "${n}"`}}catch(r){return`ERROR: Keyboard action failed: ${r.message}`}}export{E as a,$ as b};
|