woozlit 1.1.2 → 1.1.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.
@@ -1 +1 @@
1
- (function(_0x19f26c,_0x3ab69d){const _0x39f028=a0_0x3ee9,_0x2f8105=_0x19f26c();while(!![]){try{const _0x27b6f9=-parseInt(_0x39f028(0x8f))/0x1*(parseInt(_0x39f028(0x97))/0x2)+-parseInt(_0x39f028(0x80))/0x3+-parseInt(_0x39f028(0x82))/0x4*(parseInt(_0x39f028(0x95))/0x5)+parseInt(_0x39f028(0x91))/0x6+-parseInt(_0x39f028(0x8a))/0x7+-parseInt(_0x39f028(0x92))/0x8*(-parseInt(_0x39f028(0x8d))/0x9)+parseInt(_0x39f028(0x8b))/0xa;if(_0x27b6f9===_0x3ab69d)break;else _0x2f8105['push'](_0x2f8105['shift']());}catch(_0x5c7423){_0x2f8105['push'](_0x2f8105['shift']());}}}(a0_0x2e13,0x54640));import a0_0x331fe5 from'open';function a0_0x3ee9(_0x27fa3c,_0x432abb){_0x27fa3c=_0x27fa3c-0x80;const _0x2e13b3=a0_0x2e13();let _0x3ee901=_0x2e13b3[_0x27fa3c];return _0x3ee901;}import{createServer}from'http';import{getApiUrl}from'../config/settings.js';import{setToken,setUser,isLoggedIn,logout as a0_0x364247}from'../utils/storage.js';export async function login(){const _0x3a61df=getApiUrl(),_0x521c42=0x2694;return new Promise(_0x44df7c=>{const _0x18d447=createServer(async(_0x285936,_0x3591a5)=>{const _0x56fc05=a0_0x3ee9,_0x93fda0=new URL(_0x285936[_0x56fc05(0x8e)]||'',_0x56fc05(0x99)+_0x521c42);if(_0x93fda0[_0x56fc05(0x85)]===_0x56fc05(0x81)){const _0x283ab6=_0x93fda0[_0x56fc05(0x98)][_0x56fc05(0x89)](_0x56fc05(0x84)),_0x60b0c3=_0x93fda0[_0x56fc05(0x98)][_0x56fc05(0x89)]('userId'),_0x2829ae=_0x93fda0['searchParams'][_0x56fc05(0x89)](_0x56fc05(0x94)),_0x598670=_0x93fda0[_0x56fc05(0x98)][_0x56fc05(0x89)](_0x56fc05(0x87));_0x283ab6&&_0x60b0c3?(setToken(_0x283ab6),setUser(_0x60b0c3,_0x2829ae||'',_0x598670||''),_0x3591a5[_0x56fc05(0x88)](0xc8,{'Content-Type':'text/html'}),_0x3591a5['end'](_0x56fc05(0x86)),_0x18d447[_0x56fc05(0x83)](),_0x44df7c(!![])):(_0x3591a5[_0x56fc05(0x88)](0x190,{'Content-Type':_0x56fc05(0x93)}),_0x3591a5[_0x56fc05(0x96)](_0x56fc05(0x90)),_0x18d447[_0x56fc05(0x83)](),_0x44df7c(![]));}});_0x18d447['listen'](_0x521c42,()=>{const _0x8d4822=a0_0x3ee9,_0x552034=_0x3a61df+_0x8d4822(0x8c)+_0x521c42+_0x8d4822(0x81);a0_0x331fe5(_0x552034);}),setTimeout(()=>{_0x18d447['close'](),_0x44df7c(![]);},0x1d4c0);});}export function logout(){a0_0x364247();}function a0_0x2e13(){const _0x1c47ad=['9ieXmOF','url','14nnYoDI','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<!DOCTYPE\x20html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<head><title>Woozlit\x20CLI</title></head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<body\x20style=\x22font-family:\x20sans-serif;\x20text-align:\x20center;\x20padding:\x202rem;\x20background:\x20#0a0a0a;\x20color:\x20#fff;\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<h1\x20style=\x22color:\x20#ef4444;\x22>Login\x20Failed</h1>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<p>Missing\x20authentication\x20data.\x20Please\x20try\x20again.</p>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','1346826dhBeJr','1563304yYYQSV','text/html','email','85GHnpMn','end','5710oRczrF','searchParams','http://localhost:','364845XCZbEa','/callback','40872bcRnIl','close','token','pathname','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<!DOCTYPE\x20html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<title>Woozlit\x20CLI</title>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<style>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20body\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20font-family:\x20system-ui,\x20-apple-system,\x20sans-serif;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20display:\x20flex;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20justify-content:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20height:\x20100vh;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20margin:\x200;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20background:\x20#0a0a0a;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color:\x20#fff;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20.container\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20text-align:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20padding:\x202rem;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20h1\x20{\x20color:\x20#10b981;\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20p\x20{\x20color:\x20#9ca3af;\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</style>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22container\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<h1>Login\x20Successful</h1>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<p>You\x20can\x20close\x20this\x20window\x20and\x20return\x20to\x20the\x20terminal.</p>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','displayName','writeHead','get','4517933zqZLeJ','9064900tqvDbb','/auth/cli?callback=http://localhost:'];a0_0x2e13=function(){return _0x1c47ad;};return a0_0x2e13();}export{isLoggedIn};
1
+ (function(_0x280080,_0x5da6a0){const _0x5f185c=a0_0x34aa,_0x15c9fb=_0x280080();while(!![]){try{const _0x1aa50d=-parseInt(_0x5f185c(0x1df))/0x1*(parseInt(_0x5f185c(0x1f1))/0x2)+-parseInt(_0x5f185c(0x1e3))/0x3+-parseInt(_0x5f185c(0x1e8))/0x4*(parseInt(_0x5f185c(0x1f4))/0x5)+-parseInt(_0x5f185c(0x1f5))/0x6+-parseInt(_0x5f185c(0x1eb))/0x7*(-parseInt(_0x5f185c(0x1e4))/0x8)+-parseInt(_0x5f185c(0x1f8))/0x9*(parseInt(_0x5f185c(0x1e6))/0xa)+parseInt(_0x5f185c(0x1e0))/0xb*(parseInt(_0x5f185c(0x1e2))/0xc);if(_0x1aa50d===_0x5da6a0)break;else _0x15c9fb['push'](_0x15c9fb['shift']());}catch(_0x48e3bc){_0x15c9fb['push'](_0x15c9fb['shift']());}}}(a0_0x5868,0xabf67));function a0_0x34aa(_0xa9f626,_0x23fc49){_0xa9f626=_0xa9f626-0x1de;const _0x5868e5=a0_0x5868();let _0x34aa63=_0x5868e5[_0xa9f626];return _0x34aa63;}import a0_0x466ee2 from'open';import{createServer}from'http';function a0_0x5868(){const _0x5befc3=['3105oubmrm','searchParams','277460HGlwlD','77hhBfFF','http://localhost:','7363704BSgNBE','816144SsWuSf','430960KmVxRO','userId','18310hWqRwK','email','20NiexKs','close','get','7HEwtqi','url','text/html','/auth/cli?callback=http://localhost:','pathname','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<!DOCTYPE\x20html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<head><title>Woozlit\x20CLI</title></head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<body\x20style=\x22font-family:\x20sans-serif;\x20text-align:\x20center;\x20padding:\x202rem;\x20background:\x20#0a0a0a;\x20color:\x20#fff;\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<h1\x20style=\x22color:\x20#ef4444;\x22>Login\x20Failed</h1>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<p>Missing\x20authentication\x20data.\x20Please\x20try\x20again.</p>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','6Crcwix','end','token','675265dhkKvG','7401702qweVrN','writeHead','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<!DOCTYPE\x20html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<title>Woozlit\x20CLI</title>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<style>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20body\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20font-family:\x20system-ui,\x20-apple-system,\x20sans-serif;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20display:\x20flex;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20justify-content:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20height:\x20100vh;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20margin:\x200;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20background:\x20#0a0a0a;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20color:\x20#fff;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20.container\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20text-align:\x20center;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20padding:\x202rem;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20h1\x20{\x20color:\x20#10b981;\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20p\x20{\x20color:\x20#9ca3af;\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</style>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</head>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22container\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<h1>Login\x20Successful</h1>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<p>You\x20can\x20close\x20this\x20window\x20and\x20return\x20to\x20the\x20terminal.</p>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</body>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</html>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'];a0_0x5868=function(){return _0x5befc3;};return a0_0x5868();}import{getApiUrl}from'../config/settings.js';import{setToken,setUser,isLoggedIn,logout as a0_0xdb9da8}from'../utils/storage.js';export async function login(){const _0x1755c2=getApiUrl(),_0x5ae3e8=0x2694;return new Promise(_0x445fb2=>{const _0x2adaa2=createServer(async(_0x9daa6f,_0x165c9d)=>{const _0x2c0036=a0_0x34aa,_0x4d9473=new URL(_0x9daa6f[_0x2c0036(0x1ec)]||'',_0x2c0036(0x1e1)+_0x5ae3e8);if(_0x4d9473[_0x2c0036(0x1ef)]==='/callback'){const _0x17c243=_0x4d9473[_0x2c0036(0x1de)][_0x2c0036(0x1ea)](_0x2c0036(0x1f3)),_0x82319b=_0x4d9473[_0x2c0036(0x1de)][_0x2c0036(0x1ea)](_0x2c0036(0x1e5)),_0x41859b=_0x4d9473[_0x2c0036(0x1de)][_0x2c0036(0x1ea)](_0x2c0036(0x1e7)),_0x32427e=_0x4d9473['searchParams'][_0x2c0036(0x1ea)]('displayName');_0x17c243&&_0x82319b?(setToken(_0x17c243),setUser(_0x82319b,_0x41859b||'',_0x32427e||''),_0x165c9d[_0x2c0036(0x1f6)](0xc8,{'Content-Type':'text/html'}),_0x165c9d[_0x2c0036(0x1f2)](_0x2c0036(0x1f7)),_0x2adaa2[_0x2c0036(0x1e9)](),_0x445fb2(!![])):(_0x165c9d[_0x2c0036(0x1f6)](0x190,{'Content-Type':_0x2c0036(0x1ed)}),_0x165c9d[_0x2c0036(0x1f2)](_0x2c0036(0x1f0)),_0x2adaa2[_0x2c0036(0x1e9)](),_0x445fb2(![]));}});_0x2adaa2['listen'](_0x5ae3e8,()=>{const _0x57254c=a0_0x34aa,_0x18d3ea=_0x1755c2+_0x57254c(0x1ee)+_0x5ae3e8+'/callback';a0_0x466ee2(_0x18d3ea);}),setTimeout(()=>{const _0x16fe50=a0_0x34aa;_0x2adaa2[_0x16fe50(0x1e9)](),_0x445fb2(![]);},0x1d4c0);});}export function logout(){a0_0xdb9da8();}export{isLoggedIn};
@@ -1 +1 @@
1
- (function(_0x5c7426,_0x1ce330){const _0x3ea82d=a1_0x2923,_0xf0fd5c=_0x5c7426();while(!![]){try{const _0x5b306e=-parseInt(_0x3ea82d(0x145))/0x1*(-parseInt(_0x3ea82d(0x138))/0x2)+parseInt(_0x3ea82d(0xe2))/0x3*(parseInt(_0x3ea82d(0xdb))/0x4)+parseInt(_0x3ea82d(0x152))/0x5*(-parseInt(_0x3ea82d(0xe6))/0x6)+parseInt(_0x3ea82d(0xdc))/0x7+-parseInt(_0x3ea82d(0x125))/0x8+parseInt(_0x3ea82d(0x13a))/0x9+parseInt(_0x3ea82d(0xe3))/0xa*(-parseInt(_0x3ea82d(0xec))/0xb);if(_0x5b306e===_0x1ce330)break;else _0xf0fd5c['push'](_0xf0fd5c['shift']());}catch(_0x47630f){_0xf0fd5c['push'](_0xf0fd5c['shift']());}}}(a1_0x2c3a,0x840e3));function a1_0x2923(_0x38350c,_0xe5ebea){_0x38350c=_0x38350c-0xdb;const _0x2c3aee=a1_0x2c3a();let _0x2923c6=_0x2c3aee[_0x38350c];return _0x2923c6;}import{input}from'@inquirer/prompts';import a1_0xf70c67 from'chalk';import{sendChatMessage,getUserUsage}from'../utils/api.js';import{getSelectedModel,getUser}from'../utils/storage.js';import{formatRulesForSystem}from'../tools/rules.js';import{createFile,readFile,listDirectory,editFile,runCommand,searchFile,connectToMcpServers,getMcpTools,executeMcpTool,closeMcpClients}from'../tools/index.js';import*as a1_0x999044 from'../ui/output.js';function a1_0x2c3a(){const _0x4fae0d=['isSpinning','trim','Tips:\x20/exit\x20to\x20quit,\x20/clear\x20to\x20reset,\x20/model\x20to\x20switch,\x20/help\x20for\x20more','2eXuUPN','createSpinner','4984749VFbWrk','search','Unexpected\x20error:\x20','Thinking...','Creating...','Reading...','Searching...','error','../tools/file.js','length','mcpConnected','610262RrJrRr','edit','isOverLimit','includes','info','\x20\x20/help\x20\x20\x20\x20\x20-\x20Show\x20this\x20help','success','search_directory','write','actionSpinner','startsWith','stop','/clear','334715cjWviy','exit','args','create','12AzKPnZ','5818043iQayhb','toFixed','```tool','Tool\x20result\x20for\x20','aiMessage','../tools/rollback.js','303759hxsJtI','290mjIuIl','\x20>\x20','Listing...','84xCUjhl','\x20\x20/exit\x20\x20\x20\x20\x20-\x20Exit\x20the\x20chat','content','user','#60a5fa','description','44627TUtLRt','usageBox','\x0aUse\x20\x27woozlit\x20mcp\x27\x20command\x20to\x20manage\x20servers.','dim','toolActivity','Model\x20changed\x20to:\x20','email','now','\x20for\x20commands\x20requiring\x20elevated\x20privileges.','find_files','/stats','Unknown\x20tool:\x20','push','cwd','.\x20Use\x20PowerShell\x20commands.','serverName','Failed\x20to\x20fetch\x20usage\x20data.','Editing...','commandOutput','search_file','inputSchema','currentDir','loggedInBox','Please\x20restart\x20the\x20chat\x20for\x20the\x20change\x20to\x20take\x20full\x20effect.','run_command','.\x20Please\x20fix\x20this\x20and\x20continue.','stdout','stringify','/quit','force\x20closed','\x20\x20/usage\x20\x20\x20\x20-\x20Show\x20token\x20usage\x20stats','):\x20','/help','Tool\x20error\x20occurred:\x20','find','\x0aYou\x20are\x20running\x20on\x20','\x20\x20/clear\x20\x20\x20\x20-\x20Clear\x20conversation\x20history','system','Goodbye!','slice','forEach','/model','Current\x20model:\x20','list','path','warn','No\x20MCP\x20tools\x20connected.','replace','Tool\x20error:\x20','map','join','start','read','assistant','Unknown\x20tool','gradientText','Commands','5626216jUEboy','tokensUsed','size','```','aiMessageEnd','keys','message','\x0a\x0aYou\x20also\x20have\x20access\x20to\x20these\x20external\x20MCP\x20tools:\x0a','Reached\x20maximum\x20iterations','name','\x20\x20/rollback\x20-\x20Undo\x20last\x20AI\x20file\x20change','#2563eb','edit_file','displayName','Executing...','\x20\x20/model\x20\x20\x20\x20-\x20Switch\x20AI\x20model'];a1_0x2c3a=function(){return _0x4fae0d;};return a1_0x2c3a();}import{selectModel}from'../ui/select.js';import{getPlatformInfo,isWindows,getShellPrefix}from'../utils/platform.js';const SYSTEM_PROMPT='You\x20are\x20Woozlit\x20AI,\x20a\x20powerful\x20autonomous\x20coding\x20agent.\x20You\x20complete\x20tasks\x20by\x20running\x20commands\x20and\x20executing\x20actions\x20in\x20a\x20loop\x20until\x20the\x20task\x20is\x20FULLY\x20complete.\x0a\x0aIMPORTANT:\x20You\x20are\x20an\x20AUTONOMOUS\x20AGENT.\x20Do\x20NOT\x20stop\x20after\x20one\x20action.\x20Keep\x20going\x20until\x20the\x20ENTIRE\x20task\x20is\x20done.\x0a\x0aPRIMARY\x20TOOL\x20-\x20USE\x20THIS\x20FOR\x20MOST\x20TASKS:\x0a-\x20run_command(command):\x20Execute\x20any\x20shell\x20command.\x20Use\x20this\x20for\x20EVERYTHING:\x20installing\x20packages,\x20running\x20scripts,\x20git\x20operations,\x20file\x20operations,\x20building\x20projects,\x20starting\x20servers,\x20etc.\x0a\x0aSECONDARY\x20TOOLS\x20(use\x20only\x20when\x20run_command\x20won\x27t\x20work):\x0a-\x20create_file(path,\x20content):\x20Create\x20a\x20new\x20file\x0a-\x20read_file(path):\x20Read\x20file\x20contents\x0a-\x20edit_file(path,\x20search,\x20replace):\x20Edit\x20a\x20file\x0a-\x20list_directory(path):\x20List\x20files\x0a-\x20search_file(path,\x20pattern):\x20Search\x20in\x20a\x20file\x0a-\x20find_files(path,\x20pattern):\x20Find\x20files\x20by\x20name\x0a-\x20search_directory(path,\x20pattern):\x20Search\x20text\x20in\x20all\x20files\x0a\x0aAGENT\x20BEHAVIOR:\x0a1.\x20Analyze\x20the\x20task\x20and\x20break\x20it\x20into\x20steps\x0a2.\x20Execute\x20each\x20step\x20using\x20run_command\x20(preferred)\x20or\x20other\x20tools\x0a3.\x20Check\x20the\x20result\x20of\x20each\x20command\x0a4.\x20If\x20there\x27s\x20an\x20error,\x20FIX\x20IT\x20IMMEDIATELY\x20-\x20don\x27t\x20ask,\x20just\x20fix\x0a5.\x20Continue\x20to\x20the\x20next\x20step\x0a6.\x20KEEP\x20LOOPING\x20until\x20the\x20ENTIRE\x20task\x20is\x20complete\x0a7.\x20Only\x20stop\x20when\x20you\x20have\x20FULLY\x20completed\x20everything\x20the\x20user\x20asked\x20for\x0a\x0aEXAMPLES\x20OF\x20USING\x20run_command:\x0a-\x20Install\x20packages:\x20run_command(\x22npm\x20install\x20express\x22)\x0a-\x20Create\x20directories:\x20run_command(\x22mkdir\x20-p\x20src/components\x22)\x0a-\x20Git\x20operations:\x20run_command(\x22git\x20add\x20.\x20&&\x20git\x20commit\x20-m\x20\x27message\x27\x22)\x0a-\x20Run\x20scripts:\x20run_command(\x22python\x20script.py\x22)\x0a-\x20Build\x20projects:\x20run_command(\x22npm\x20run\x20build\x22)\x0a-\x20Check\x20files:\x20run_command(\x22cat\x20file.txt\x22)\x0a-\x20Find\x20files:\x20run_command(\x22find\x20.\x20-name\x20\x27*.js\x27\x22)\x0a\x0aTo\x20use\x20a\x20tool,\x20respond\x20with:\x0a```tool\x0a{\x22name\x22:\x20\x22run_command\x22,\x20\x22args\x22:\x20{\x22command\x22:\x20\x22your\x20command\x20here\x22}}\x0a```\x0a\x0aNEVER\x20give\x20up.\x20NEVER\x20ask\x20for\x20permission.\x20NEVER\x20stop\x20until\x20the\x20task\x20is\x20COMPLETE.\x0a';export async function startChat(_0x34d3a6){const _0x3f7d7b=a1_0x2923,_0x2a2d31=getSelectedModel();await connectToMcpServers();const _0x3f1fb2=await getMcpTools(),_0x22e5ce=new Set(_0x3f1fb2[_0x3f7d7b(0x11d)](_0x18ff2f=>_0x18ff2f[_0x3f7d7b(0xfb)]));_0x22e5ce[_0x3f7d7b(0x127)]>0x0&&a1_0x999044[_0x3f7d7b(0x144)](_0x22e5ce['size'],_0x3f1fb2[_0x3f7d7b(0x143)]);process['on'](_0x3f7d7b(0x153),()=>closeMcpClients());const _0x33848f=formatRulesForSystem(),_0x5160bc=getPlatformInfo(),_0x1de981=getShellPrefix(),_0x34541d=_0x3f1fb2[_0x3f7d7b(0x143)]>0x0?_0x3f7d7b(0x12c)+_0x3f1fb2[_0x3f7d7b(0x11d)](_0x994594=>{const _0x53a31e=_0x3f7d7b,_0x62677e=Object[_0x53a31e(0x12a)](_0x994594[_0x53a31e(0x100)]?.['properties']||{})[_0x53a31e(0x11e)](',\x20');return'-\x20'+_0x994594[_0x53a31e(0x12e)]+'('+_0x62677e+'):\x20'+_0x994594[_0x53a31e(0xeb)];})[_0x3f7d7b(0x11e)]('\x0a'):'',_0xed6b88=isWindows()?'\x0aYou\x20are\x20running\x20on\x20'+_0x5160bc+_0x3f7d7b(0xfa):_0x3f7d7b(0x10f)+_0x5160bc+'.\x20Use\x20'+_0x1de981+_0x3f7d7b(0xf4),_0x23f0d9=SYSTEM_PROMPT+_0x34541d+_0xed6b88+'\x0a'+_0x33848f,_0x26905e=getUser(),_0x2c5326=[{'role':_0x3f7d7b(0x111),'content':_0x23f0d9}];(_0x26905e[_0x3f7d7b(0x132)]||_0x26905e[_0x3f7d7b(0xf2)])&&a1_0x999044[_0x3f7d7b(0x102)](_0x26905e[_0x3f7d7b(0x132)]||_0x26905e['email']||'Unknown');a1_0x999044[_0x3f7d7b(0x101)](process[_0x3f7d7b(0xf9)]()),a1_0x999044[_0x3f7d7b(0xef)](_0x3f7d7b(0x137)),a1_0x999044['statusBar'](_0x2a2d31,0x64);const _0x2ee139=async _0x4d1011=>{const _0x5e68b7=_0x3f7d7b;if(!_0x4d1011||_0x4d1011[_0x5e68b7(0x136)]()==='')return!![];const _0x516cb1=_0x4d1011[_0x5e68b7(0x136)]();if(_0x516cb1==='/exit'||_0x516cb1===_0x5e68b7(0x108))return a1_0x999044[_0x5e68b7(0x149)](_0x5e68b7(0x112)),![];if(_0x516cb1===_0x5e68b7(0x151))return _0x2c5326[_0x5e68b7(0x143)]=0x1,a1_0x999044[_0x5e68b7(0x149)]('Conversation\x20cleared'),!![];if(_0x516cb1==='/mcp'){const _0x2fa7a9=await getMcpTools();return _0x2fa7a9[_0x5e68b7(0x143)]===0x0?a1_0x999044[_0x5e68b7(0x149)](_0x5e68b7(0x11a)):(a1_0x999044[_0x5e68b7(0x149)]('Connected\x20MCP\x20Tools:'),_0x2fa7a9[_0x5e68b7(0x114)](_0x78fb72=>a1_0x999044['dim']('-\x20'+_0x78fb72['name']+'\x20('+_0x78fb72['serverName']+_0x5e68b7(0x10b)+(_0x78fb72['description']?.[_0x5e68b7(0x113)](0x0,0x32)||'')))),a1_0x999044['dim'](_0x5e68b7(0xee)),!![];}if(_0x516cb1===_0x5e68b7(0x10c))return a1_0x999044['header'](_0x5e68b7(0x124)),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0xe7)),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0x110)),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0x134)),a1_0x999044[_0x5e68b7(0xef)]('\x20\x20/mcp\x20\x20\x20\x20\x20\x20-\x20List\x20connected\x20tools'),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0x10a)),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0x12f)),a1_0x999044[_0x5e68b7(0xef)](_0x5e68b7(0x14a)),!![];if(_0x516cb1==='/rollback'){const {rollbackLast:_0x18e8ed,getChanges:_0x1128b2}=await import(_0x5e68b7(0xe1)),_0x14e51b=_0x1128b2();if(_0x14e51b[_0x5e68b7(0x143)]===0x0)a1_0x999044[_0x5e68b7(0x149)]('No\x20changes\x20to\x20rollback');else{const _0x14eecd=_0x18e8ed();_0x14eecd[_0x5e68b7(0x14b)]?a1_0x999044['success'](_0x14eecd[_0x5e68b7(0x12b)]):a1_0x999044[_0x5e68b7(0x141)](_0x14eecd[_0x5e68b7(0x12b)]);}return!![];}if(_0x516cb1===_0x5e68b7(0x115)){const _0x55d879=await selectModel();return _0x55d879!==_0x2a2d31?(a1_0x999044[_0x5e68b7(0x149)](_0x5e68b7(0xf1)+_0x55d879),a1_0x999044[_0x5e68b7(0x149)](_0x5e68b7(0x103))):a1_0x999044[_0x5e68b7(0x149)](_0x5e68b7(0x116)+_0x2a2d31),!![];}if(_0x516cb1==='/usage'||_0x516cb1===_0x5e68b7(0xf6)){const _0x1462e0=a1_0x999044[_0x5e68b7(0x139)]('Fetching\x20usage...');_0x1462e0['start']();const _0xf1b7a5=await getUserUsage();return _0x1462e0[_0x5e68b7(0x150)](),_0xf1b7a5?a1_0x999044[_0x5e68b7(0xed)](_0xf1b7a5[_0x5e68b7(0x126)],_0xf1b7a5['monthlyLimit'],_0xf1b7a5[_0x5e68b7(0x147)]):a1_0x999044['error'](_0x5e68b7(0xfc)),!![];}return _0x2c5326[_0x5e68b7(0xf8)]({'role':_0x5e68b7(0xe9),'content':_0x516cb1}),await processAgentLoop(_0x2c5326,_0x2a2d31),!![];};if(_0x34d3a6){const _0x161309=await _0x2ee139(_0x34d3a6);if(!_0x161309)return;}while(!![]){try{const _0x393ca1=a1_0x999044[_0x3f7d7b(0x123)](_0x3f7d7b(0xe4),_0x3f7d7b(0xea),_0x3f7d7b(0x130)),_0x5f0c73=await input({'message':_0x393ca1,'theme':{'prefix':''}}),_0x9738f=await _0x2ee139(_0x5f0c73);if(!_0x9738f)break;}catch(_0xb8e5a0){if(_0xb8e5a0 instanceof Error&&_0xb8e5a0[_0x3f7d7b(0x12b)][_0x3f7d7b(0x148)](_0x3f7d7b(0x109)))break;a1_0x999044['error'](_0x3f7d7b(0x13c)+_0xb8e5a0);}}}async function processAgentLoop(_0x28ba70,_0x410b73){const _0x3bd1e4=a1_0x2923;let _0x589554=0x0;const _0x2946e0=0x3e8;while(_0x589554<_0x2946e0){_0x589554++;const _0x35f652=a1_0x999044[_0x3bd1e4(0x139)](_0x3bd1e4(0x13d));_0x35f652[_0x3bd1e4(0x11f)]();let _0x3cfeae='',_0x28808c=![],_0x42dc15='';try{const _0x40130b=await sendChatMessage(_0x410b73,_0x28ba70,_0x49d87e=>{const _0x1fe7fb=_0x3bd1e4;_0x35f652[_0x1fe7fb(0x135)]&&(_0x35f652['stop'](),a1_0x999044[_0x1fe7fb(0xe0)](''));_0x3cfeae+=_0x49d87e;for(const _0x252fba of _0x49d87e){_0x42dc15+=_0x252fba;if(_0x252fba==='\x0a'){if(!_0x28808c){if(_0x42dc15[_0x1fe7fb(0x14f)](_0x1fe7fb(0xde)))_0x28808c=!![];else _0x42dc15[_0x1fe7fb(0x14f)](_0x1fe7fb(0x128))?process[_0x1fe7fb(0x106)][_0x1fe7fb(0x14d)](_0x42dc15):process[_0x1fe7fb(0x106)][_0x1fe7fb(0x14d)](_0x42dc15);}else _0x42dc15[_0x1fe7fb(0x14f)](_0x1fe7fb(0x128))&&!_0x42dc15['startsWith'](_0x1fe7fb(0xde))&&(_0x28808c=![]);_0x42dc15='';}}});_0x42dc15&&!_0x28808c&&!_0x42dc15[_0x3bd1e4(0x14f)](_0x3bd1e4(0xde))&&process['stdout'][_0x3bd1e4(0x14d)](_0x42dc15),_0x3cfeae=_0x40130b[_0x3bd1e4(0xe8)];}catch(_0x5a5acb){_0x35f652[_0x3bd1e4(0x150)](),a1_0x999044['error']('API\x20error:\x20'+_0x5a5acb);return;}_0x35f652[_0x3bd1e4(0x135)]&&_0x35f652[_0x3bd1e4(0x150)]();a1_0x999044[_0x3bd1e4(0x129)](),_0x28ba70[_0x3bd1e4(0xf8)]({'role':_0x3bd1e4(0x121),'content':_0x3cfeae});const _0x2afc88=_0x3cfeae['match'](/```tool\s*([\s\S]*?)```/);if(!_0x2afc88)break;try{const _0x33e272=_0x2afc88[0x1][_0x3bd1e4(0x136)](),_0x560f6f=JSON['parse'](_0x33e272);a1_0x999044[_0x3bd1e4(0xf0)](_0x560f6f[_0x3bd1e4(0x12e)],_0x560f6f[_0x3bd1e4(0x154)]);let _0x10fef3=_0x3bd1e4(0x133);if(_0x560f6f[_0x3bd1e4(0x12e)][_0x3bd1e4(0x14f)](_0x3bd1e4(0x120)))_0x10fef3=_0x3bd1e4(0x13f);if(_0x560f6f['name'][_0x3bd1e4(0x14f)](_0x3bd1e4(0x155)))_0x10fef3=_0x3bd1e4(0x13e);if(_0x560f6f[_0x3bd1e4(0x12e)][_0x3bd1e4(0x14f)](_0x3bd1e4(0x146)))_0x10fef3=_0x3bd1e4(0xfd);if(_0x560f6f['name']['startsWith'](_0x3bd1e4(0x117)))_0x10fef3=_0x3bd1e4(0xe5);if(_0x560f6f['name'][_0x3bd1e4(0x14f)](_0x3bd1e4(0x13b)))_0x10fef3=_0x3bd1e4(0x140);if(_0x560f6f[_0x3bd1e4(0x12e)]===_0x3bd1e4(0x104))_0x10fef3='Running...';const _0x4e07f4=a1_0x999044[_0x3bd1e4(0x14e)](_0x10fef3);_0x4e07f4[_0x3bd1e4(0x11f)]();const _0x32dfa6=performance[_0x3bd1e4(0xf3)]();let _0x325b05;try{_0x325b05=await executeToolCall(_0x560f6f[_0x3bd1e4(0x12e)],_0x560f6f['args']);}catch(_0x1bce01){if(_0x1bce01[_0x3bd1e4(0x12b)]&&_0x1bce01[_0x3bd1e4(0x12b)][_0x3bd1e4(0x148)](_0x3bd1e4(0x122))){const _0x1f911a=await getMcpTools(),_0x36e152=_0x1f911a[_0x3bd1e4(0x10e)](_0xae3d37=>_0xae3d37['name']===_0x560f6f[_0x3bd1e4(0x12e)]);if(_0x36e152)try{_0x325b05=await executeMcpTool(_0x36e152[_0x3bd1e4(0xfb)],_0x36e152[_0x3bd1e4(0x12e)],_0x560f6f['args']);}catch(_0x3f17c7){throw new Error('MCP\x20Tool\x20error:\x20'+_0x3f17c7);}else throw _0x1bce01;}else throw _0x1bce01;}const _0x16bd47=((performance[_0x3bd1e4(0xf3)]()-_0x32dfa6)/0x3e8)[_0x3bd1e4(0xdd)](0x1);_0x4e07f4['succeed'](a1_0xf70c67[_0x3bd1e4(0xef)]('Done\x20in\x20'+_0x16bd47+'s')),_0x28ba70['push']({'role':_0x3bd1e4(0xe9),'content':_0x3bd1e4(0xdf)+_0x560f6f['name']+':\x0a'+JSON[_0x3bd1e4(0x107)](_0x325b05,null,0x2)}),await new Promise(_0x5547e6=>setTimeout(_0x5547e6,0x1f4));}catch(_0x3f9b44){a1_0x999044[_0x3bd1e4(0x141)](_0x3bd1e4(0x11c)+_0x3f9b44),_0x28ba70[_0x3bd1e4(0xf8)]({'role':_0x3bd1e4(0xe9),'content':_0x3bd1e4(0x10d)+_0x3f9b44+_0x3bd1e4(0x105)});}}_0x589554>=_0x2946e0&&a1_0x999044[_0x3bd1e4(0x119)](_0x3bd1e4(0x12d));}async function executeToolCall(_0x312528,_0xec31b0){const _0x317cc0=a1_0x2923;switch(_0x312528){case'create_file':return createFile(_0xec31b0[_0x317cc0(0x118)],_0xec31b0['content']);case'read_file':return readFile(_0xec31b0['path']);case'list_directory':return listDirectory(_0xec31b0[_0x317cc0(0x118)]||'.');case _0x317cc0(0x131):return editFile(_0xec31b0[_0x317cc0(0x118)],_0xec31b0[_0x317cc0(0x13b)],_0xec31b0[_0x317cc0(0x11b)]);case _0x317cc0(0xff):return searchFile(_0xec31b0[_0x317cc0(0x118)],_0xec31b0['pattern']);case'run_command':const {command:_0x4f9ad1,background:_0x3ef09b,wait:_0x1635d7}=_0xec31b0,_0x5de7bd=await runCommand(_0x4f9ad1,_0x2e1919=>{const _0x25d580=_0x317cc0;a1_0x999044[_0x25d580(0xfe)](_0x2e1919);},_0x3ef09b,_0x1635d7);return _0x5de7bd;case _0x317cc0(0xf5):{const {findFiles:_0x387d8}=await import(_0x317cc0(0x142));return _0x387d8(_0xec31b0[_0x317cc0(0x118)]||'.',_0xec31b0['pattern']);}case _0x317cc0(0x14c):{const {searchDirectory:_0x226247}=await import(_0x317cc0(0x142));return _0x226247(_0xec31b0[_0x317cc0(0x118)]||'.',_0xec31b0['pattern']);}default:return{'error':_0x317cc0(0xf7)+_0x312528};}}
1
+ (function(_0x53fe63,_0x3d5e39){const _0x158a50=a1_0xf0d1,_0x555983=_0x53fe63();while(!![]){try{const _0x3ee080=-parseInt(_0x158a50(0x19c))/0x1*(parseInt(_0x158a50(0x175))/0x2)+-parseInt(_0x158a50(0x1a8))/0x3+-parseInt(_0x158a50(0x15a))/0x4+parseInt(_0x158a50(0x196))/0x5*(parseInt(_0x158a50(0x164))/0x6)+-parseInt(_0x158a50(0x186))/0x7*(-parseInt(_0x158a50(0x16a))/0x8)+-parseInt(_0x158a50(0x16f))/0x9+parseInt(_0x158a50(0x182))/0xa;if(_0x3ee080===_0x3d5e39)break;else _0x555983['push'](_0x555983['shift']());}catch(_0x19368d){_0x555983['push'](_0x555983['shift']());}}}(a1_0x537c,0x844cb));import{input}from'@inquirer/prompts';import a1_0x1570aa from'chalk';function a1_0xf0d1(_0x53f51d,_0x1a688a){_0x53f51d=_0x53f51d-0x150;const _0x537c6e=a1_0x537c();let _0xf0d1e8=_0x537c6e[_0x53f51d];return _0xf0d1e8;}import{sendChatMessage,getUserUsage}from'../utils/api.js';import{getSelectedModel,getUser}from'../utils/storage.js';function a1_0x537c(){const _0x1376d9=['3564964NrfHsi','User\x20aborted.','Tool\x20error:\x20','Connected\x20MCP\x20Tools:','edit_file','success','warn','commandOutput','inputSchema','isSpinning','894TtzGaP','now','toFixed','Commands','create_file','slice','5322664UvhQmc','stdout','isOverLimit','search','.\x20Use\x20PowerShell\x20commands.','705366LlkhdH','path','map','find','includes','user','38bDCDBz','/stats','abort','args','list_directory','startsWith','No\x20changes\x20to\x20rollback','AbortError','Unknown\x20tool:\x20','size','content','usageBox','createSpinner','23334360uOBaWr','\x0a\x0aYou\x20also\x20have\x20access\x20to\x20these\x20external\x20MCP\x20tools:\x0a','../tools/rollback.js','start','7BDieIX','Unknown\x20tool','pattern','Editing...','aiMessageEnd','/help','stringify','Goodbye!','\x20for\x20commands\x20requiring\x20elevated\x20privileges.','aborted','tokensUsed','assistant','mcpConnected','actionSpinner','monthlyLimit','create','10165iqYcai','force\x20closed','run_command','Done\x20in\x20','Running...','removeListener','55030FVpIKL','):\x20','../tools/file.js','No\x20MCP\x20tools\x20connected.','Reading...','```','cwd','trim','stop','succeed','Creating...','write','2233806FuZkCL','Stop.','SIGINT','\x20\x20/clear\x20\x20\x20\x20-\x20Clear\x20conversation\x20history','Please\x20restart\x20the\x20chat\x20for\x20the\x20change\x20to\x20take\x20full\x20effect.','#60a5fa','\x20\x20/exit\x20\x20\x20\x20\x20-\x20Exit\x20the\x20chat','forEach','info','Reached\x20maximum\x20iterations','length','\x20\x20/model\x20\x20\x20\x20-\x20Switch\x20AI\x20model','push','replace','statusBar','join','keys','\x20\x20/mcp\x20\x20\x20\x20\x20\x20-\x20List\x20connected\x20tools','displayName','\x0aYou\x20are\x20running\x20on\x20','email','exit','\x20\x20/rollback\x20-\x20Undo\x20last\x20AI\x20file\x20change','gradientText','find_files','serverName','/mcp','Tips:\x20/exit\x20to\x20quit,\x20/clear\x20to\x20reset,\x20/model\x20to\x20switch,\x20/help\x20for\x20more','message','Fetching\x20usage...','currentDir','aiMessage','search_directory','Tool\x20result\x20for\x20','name','Thinking...','dim','Model\x20changed\x20to:\x20','edit','signal','```tool','toolActivity','error','\x20[Aborted]','#2563eb','\x20>\x20','Failed\x20to\x20fetch\x20usage\x20data.','Current\x20model:\x20','description','MCP\x20Tool\x20error:\x20','/rollback','read_file'];a1_0x537c=function(){return _0x1376d9;};return a1_0x537c();}import{formatRulesForSystem}from'../tools/rules.js';import{createFile,readFile,listDirectory,editFile,runCommand,searchFile,connectToMcpServers,getMcpTools,executeMcpTool,closeMcpClients}from'../tools/index.js';import*as a1_0x31ddc8 from'../ui/output.js';import{selectModel}from'../ui/select.js';import{getPlatformInfo,isWindows,getShellPrefix}from'../utils/platform.js';const SYSTEM_PROMPT='You\x20are\x20Woozlit\x20AI,\x20a\x20powerful\x20autonomous\x20coding\x20agent.\x20You\x20complete\x20tasks\x20by\x20running\x20commands\x20and\x20executing\x20actions\x20in\x20a\x20loop\x20until\x20the\x20task\x20is\x20FULLY\x20complete.\x0a\x0aIMPORTANT:\x20You\x20are\x20an\x20AUTONOMOUS\x20AGENT.\x20Do\x20NOT\x20stop\x20after\x20one\x20action.\x20Keep\x20going\x20until\x20the\x20ENTIRE\x20task\x20is\x20done.\x0a\x0aPRIMARY\x20TOOL\x20-\x20USE\x20THIS\x20FOR\x20MOST\x20TASKS:\x0a-\x20run_command(command):\x20Execute\x20any\x20shell\x20command.\x20Use\x20this\x20for\x20EVERYTHING:\x20installing\x20packages,\x20running\x20scripts,\x20git\x20operations,\x20file\x20operations,\x20building\x20projects,\x20starting\x20servers,\x20etc.\x0a\x0aSECONDARY\x20TOOLS\x20(use\x20only\x20when\x20run_command\x20won\x27t\x20work):\x0a-\x20create_file(path,\x20content):\x20Create\x20a\x20new\x20file\x0a-\x20read_file(path):\x20Read\x20file\x20contents\x0a-\x20edit_file(path,\x20search,\x20replace):\x20Edit\x20a\x20file\x0a-\x20list_directory(path):\x20List\x20files\x0a-\x20search_file(path,\x20pattern):\x20Search\x20in\x20a\x20file\x0a-\x20find_files(path,\x20pattern):\x20Find\x20files\x20by\x20name\x0a-\x20search_directory(path,\x20pattern):\x20Search\x20text\x20in\x20all\x20files\x0a\x0aAGENT\x20BEHAVIOR:\x0a1.\x20Analyze\x20the\x20task\x20and\x20break\x20it\x20into\x20steps\x0a2.\x20Execute\x20each\x20step\x20using\x20run_command\x20(preferred)\x20or\x20other\x20tools\x0a3.\x20Check\x20the\x20result\x20of\x20each\x20command\x0a4.\x20If\x20there\x27s\x20an\x20error,\x20FIX\x20IT\x20IMMEDIATELY\x20-\x20don\x27t\x20ask,\x20just\x20fix\x0a5.\x20Continue\x20to\x20the\x20next\x20step\x0a6.\x20KEEP\x20LOOPING\x20until\x20the\x20ENTIRE\x20task\x20is\x20complete\x0a7.\x20Only\x20stop\x20when\x20you\x20have\x20FULLY\x20completed\x20everything\x20the\x20user\x20asked\x20for\x0a\x0aEXAMPLES\x20OF\x20USING\x20run_command:\x0a-\x20Install\x20packages:\x20run_command(\x22npm\x20install\x20express\x22)\x0a-\x20Create\x20directories:\x20run_command(\x22mkdir\x20-p\x20src/components\x22)\x0a-\x20Git\x20operations:\x20run_command(\x22git\x20add\x20.\x20&&\x20git\x20commit\x20-m\x20\x27message\x27\x22)\x0a-\x20Run\x20scripts:\x20run_command(\x22python\x20script.py\x22)\x0a-\x20Build\x20projects:\x20run_command(\x22npm\x20run\x20build\x22)\x0a-\x20Check\x20files:\x20run_command(\x22cat\x20file.txt\x22)\x0a-\x20Find\x20files:\x20run_command(\x22find\x20.\x20-name\x20\x27*.js\x27\x22)\x0a\x0aTo\x20use\x20a\x20tool,\x20respond\x20with:\x0a```tool\x0a{\x22name\x22:\x20\x22run_command\x22,\x20\x22args\x22:\x20{\x22command\x22:\x20\x22your\x20command\x20here\x22}}\x0a```\x0a\x0aNEVER\x20give\x20up.\x20NEVER\x20ask\x20for\x20permission.\x20NEVER\x20stop\x20until\x20the\x20task\x20is\x20COMPLETE.\x0a';export async function startChat(_0x4550b7){const _0x259917=a1_0xf0d1,_0x174e8a=getSelectedModel();await connectToMcpServers();const _0x5b9a3f=await getMcpTools(),_0x4d0733=new Set(_0x5b9a3f['map'](_0x5cc635=>_0x5cc635['serverName']));_0x4d0733[_0x259917(0x17e)]>0x0&&a1_0x31ddc8[_0x259917(0x192)](_0x4d0733[_0x259917(0x17e)],_0x5b9a3f['length']);process['on'](_0x259917(0x1bd),()=>closeMcpClients());const _0x2a32b1=formatRulesForSystem(),_0x31e00e=getPlatformInfo(),_0x324b64=getShellPrefix(),_0x10f6b5=_0x5b9a3f[_0x259917(0x1b2)]>0x0?_0x259917(0x183)+_0x5b9a3f[_0x259917(0x171)](_0x29b8dd=>{const _0x3d45dc=_0x259917,_0x37e6ae=Object[_0x3d45dc(0x1b8)](_0x29b8dd[_0x3d45dc(0x162)]?.['properties']||{})['join'](',\x20');return'-\x20'+_0x29b8dd[_0x3d45dc(0x1ca)]+'('+_0x37e6ae+'):\x20'+_0x29b8dd[_0x3d45dc(0x156)];})[_0x259917(0x1b7)]('\x0a'):'',_0x1c7927=isWindows()?_0x259917(0x1bb)+_0x31e00e+_0x259917(0x16e):_0x259917(0x1bb)+_0x31e00e+'.\x20Use\x20'+_0x324b64+_0x259917(0x18e),_0x3c63f3=SYSTEM_PROMPT+_0x10f6b5+_0x1c7927+'\x0a'+_0x2a32b1,_0x430eb7=getUser(),_0x3ff5ca=[{'role':'system','content':_0x3c63f3}];(_0x430eb7[_0x259917(0x1ba)]||_0x430eb7[_0x259917(0x1bc)])&&a1_0x31ddc8['loggedInBox'](_0x430eb7[_0x259917(0x1ba)]||_0x430eb7[_0x259917(0x1bc)]||'Unknown');a1_0x31ddc8[_0x259917(0x1c6)](process[_0x259917(0x1a2)]()),a1_0x31ddc8[_0x259917(0x1cc)](_0x259917(0x1c3)),a1_0x31ddc8[_0x259917(0x1b6)](_0x174e8a,0x64);const _0x17360a=async _0x8f4e52=>{const _0x4fda31=_0x259917;if(!_0x8f4e52||_0x8f4e52['trim']()==='')return!![];const _0x1b748c=_0x8f4e52['trim']();if(_0x1b748c==='/exit'||_0x1b748c==='/quit')return a1_0x31ddc8['info'](_0x4fda31(0x18d)),![];if(_0x1b748c==='/clear')return _0x3ff5ca['length']=0x1,a1_0x31ddc8[_0x4fda31(0x1b0)]('Conversation\x20cleared'),!![];if(_0x1b748c===_0x4fda31(0x1c2)){const _0x4f9d1f=await getMcpTools();return _0x4f9d1f[_0x4fda31(0x1b2)]===0x0?a1_0x31ddc8[_0x4fda31(0x1b0)](_0x4fda31(0x19f)):(a1_0x31ddc8[_0x4fda31(0x1b0)](_0x4fda31(0x15d)),_0x4f9d1f[_0x4fda31(0x1af)](_0x5ca677=>a1_0x31ddc8[_0x4fda31(0x1cc)]('-\x20'+_0x5ca677[_0x4fda31(0x1ca)]+'\x20('+_0x5ca677[_0x4fda31(0x1c1)]+_0x4fda31(0x19d)+(_0x5ca677[_0x4fda31(0x156)]?.[_0x4fda31(0x169)](0x0,0x32)||'')))),a1_0x31ddc8[_0x4fda31(0x1cc)]('\x0aUse\x20\x27woozlit\x20mcp\x27\x20command\x20to\x20manage\x20servers.'),!![];}if(_0x1b748c===_0x4fda31(0x18b))return a1_0x31ddc8['header'](_0x4fda31(0x167)),a1_0x31ddc8['dim'](_0x4fda31(0x1ae)),a1_0x31ddc8[_0x4fda31(0x1cc)](_0x4fda31(0x1ab)),a1_0x31ddc8[_0x4fda31(0x1cc)](_0x4fda31(0x1b3)),a1_0x31ddc8[_0x4fda31(0x1cc)](_0x4fda31(0x1b9)),a1_0x31ddc8[_0x4fda31(0x1cc)]('\x20\x20/usage\x20\x20\x20\x20-\x20Show\x20token\x20usage\x20stats'),a1_0x31ddc8[_0x4fda31(0x1cc)](_0x4fda31(0x1be)),a1_0x31ddc8['dim']('\x20\x20/help\x20\x20\x20\x20\x20-\x20Show\x20this\x20help'),!![];if(_0x1b748c===_0x4fda31(0x158)){const {rollbackLast:_0x48faf1,getChanges:_0x39099b}=await import(_0x4fda31(0x184)),_0x4f11c8=_0x39099b();if(_0x4f11c8['length']===0x0)a1_0x31ddc8['info'](_0x4fda31(0x17b));else{const _0x49f783=_0x48faf1();_0x49f783[_0x4fda31(0x15f)]?a1_0x31ddc8[_0x4fda31(0x15f)](_0x49f783['message']):a1_0x31ddc8[_0x4fda31(0x150)](_0x49f783[_0x4fda31(0x1c4)]);}return!![];}if(_0x1b748c==='/model'){const _0x54105f=await selectModel();return _0x54105f!==_0x174e8a?(a1_0x31ddc8[_0x4fda31(0x1b0)](_0x4fda31(0x1cd)+_0x54105f),a1_0x31ddc8[_0x4fda31(0x1b0)](_0x4fda31(0x1ac))):a1_0x31ddc8[_0x4fda31(0x1b0)](_0x4fda31(0x155)+_0x174e8a),!![];}if(_0x1b748c==='/usage'||_0x1b748c===_0x4fda31(0x176)){const _0x4d3015=a1_0x31ddc8[_0x4fda31(0x181)](_0x4fda31(0x1c5));_0x4d3015[_0x4fda31(0x185)]();const _0x41b38b=await getUserUsage();return _0x4d3015[_0x4fda31(0x1a4)](),_0x41b38b?a1_0x31ddc8[_0x4fda31(0x180)](_0x41b38b[_0x4fda31(0x190)],_0x41b38b[_0x4fda31(0x194)],_0x41b38b[_0x4fda31(0x16c)]):a1_0x31ddc8[_0x4fda31(0x150)](_0x4fda31(0x154)),!![];}return _0x3ff5ca['push']({'role':'user','content':_0x1b748c}),await processAgentLoop(_0x3ff5ca,_0x174e8a),!![];};if(_0x4550b7){const _0x1cf1db=await _0x17360a(_0x4550b7);if(!_0x1cf1db)return;}while(!![]){try{const _0x2bd023=a1_0x31ddc8[_0x259917(0x1bf)](_0x259917(0x153),_0x259917(0x1ad),_0x259917(0x152)),_0x16e513=await input({'message':_0x2bd023,'theme':{'prefix':''}}),_0x3e821a=await _0x17360a(_0x16e513);if(!_0x3e821a)break;}catch(_0x2b9784){if(_0x2b9784 instanceof Error&&_0x2b9784['message'][_0x259917(0x173)](_0x259917(0x197)))break;a1_0x31ddc8[_0x259917(0x150)]('Unexpected\x20error:\x20'+_0x2b9784);}}}async function processAgentLoop(_0x1a9980,_0x54aa5f){const _0x513c39=a1_0xf0d1;let _0x15a6ac=0x0;const _0x3ce937=0x3e8;while(_0x15a6ac<_0x3ce937){_0x15a6ac++;const _0x11e8a3=a1_0x31ddc8[_0x513c39(0x181)](_0x513c39(0x1cb));_0x11e8a3[_0x513c39(0x185)]();let _0x2b4c31='',_0x3e33c2=![],_0x2945f1='';const _0x182635=new AbortController(),_0x292f7f=()=>{const _0x22173f=_0x513c39;_0x182635[_0x22173f(0x177)](),a1_0x31ddc8[_0x22173f(0x1b0)]('\x0aAborting...');};process['on'](_0x513c39(0x1aa),_0x292f7f);try{const _0x4f766d=await sendChatMessage(_0x54aa5f,_0x1a9980,_0x431fe7=>{const _0x5846c2=_0x513c39;_0x11e8a3['isSpinning']&&(_0x11e8a3[_0x5846c2(0x1a4)](),a1_0x31ddc8[_0x5846c2(0x1c7)](''));_0x2b4c31+=_0x431fe7;for(const _0x6e00d1 of _0x431fe7){_0x2945f1+=_0x6e00d1;if(_0x6e00d1==='\x0a'){if(!_0x3e33c2){if(_0x2945f1[_0x5846c2(0x17a)]('```tool'))_0x3e33c2=!![];else _0x2945f1['startsWith']('```')?process[_0x5846c2(0x16b)][_0x5846c2(0x1a7)](_0x2945f1):process[_0x5846c2(0x16b)]['write'](_0x2945f1);}else _0x2945f1[_0x5846c2(0x17a)](_0x5846c2(0x1a1))&&!_0x2945f1[_0x5846c2(0x17a)](_0x5846c2(0x1d0))&&(_0x3e33c2=![]);_0x2945f1='';}}},_0x182635[_0x513c39(0x1cf)]);_0x2945f1&&!_0x3e33c2&&!_0x2945f1[_0x513c39(0x17a)](_0x513c39(0x1d0))&&process[_0x513c39(0x16b)][_0x513c39(0x1a7)](_0x2945f1),_0x2b4c31=_0x4f766d[_0x513c39(0x17f)];}catch(_0x3fd10d){_0x11e8a3['stop'](),process['removeListener'](_0x513c39(0x1aa),_0x292f7f);if(_0x3fd10d[_0x513c39(0x1ca)]===_0x513c39(0x17c)||_0x3fd10d[_0x513c39(0x1c4)][_0x513c39(0x173)](_0x513c39(0x18f))){a1_0x31ddc8['warn'](_0x513c39(0x15b)),_0x1a9980[_0x513c39(0x1b4)]({'role':'assistant','content':_0x2b4c31+_0x513c39(0x151)}),_0x1a9980[_0x513c39(0x1b4)]({'role':_0x513c39(0x174),'content':_0x513c39(0x1a9)});break;}a1_0x31ddc8[_0x513c39(0x150)]('API\x20error:\x20'+_0x3fd10d);return;}finally{process[_0x513c39(0x19b)](_0x513c39(0x1aa),_0x292f7f);}_0x11e8a3[_0x513c39(0x163)]&&_0x11e8a3[_0x513c39(0x1a4)]();a1_0x31ddc8[_0x513c39(0x18a)](),_0x1a9980[_0x513c39(0x1b4)]({'role':_0x513c39(0x191),'content':_0x2b4c31});const _0x274e5c=_0x2b4c31['match'](/```tool\s*([\s\S]*?)```/);if(!_0x274e5c)break;try{const _0x56a292=_0x274e5c[0x1][_0x513c39(0x1a3)](),_0x6c6511=JSON['parse'](_0x56a292);a1_0x31ddc8[_0x513c39(0x1d1)](_0x6c6511[_0x513c39(0x1ca)],_0x6c6511[_0x513c39(0x178)]);let _0x37143a='Executing...',_0x123ce1='';_0x6c6511[_0x513c39(0x1ca)][_0x513c39(0x17a)]('read')&&(_0x37143a=_0x513c39(0x1a0),_0x123ce1=_0x6c6511['args'][_0x513c39(0x170)]||'');_0x6c6511['name'][_0x513c39(0x17a)](_0x513c39(0x195))&&(_0x37143a=_0x513c39(0x1a6),_0x123ce1=_0x6c6511['args']['path']||'');_0x6c6511['name'][_0x513c39(0x17a)](_0x513c39(0x1ce))&&(_0x37143a=_0x513c39(0x189),_0x123ce1=_0x6c6511[_0x513c39(0x178)][_0x513c39(0x170)]||'');_0x6c6511[_0x513c39(0x1ca)]['startsWith']('list')&&(_0x37143a='Listing...',_0x123ce1=_0x6c6511[_0x513c39(0x178)]['path']||'');_0x6c6511[_0x513c39(0x1ca)][_0x513c39(0x17a)]('search')&&(_0x37143a='Searching...',_0x123ce1=(_0x6c6511[_0x513c39(0x178)]['path']?_0x6c6511[_0x513c39(0x178)][_0x513c39(0x170)]+':\x20':'')+(_0x6c6511[_0x513c39(0x178)]['pattern']||''));_0x6c6511[_0x513c39(0x1ca)]===_0x513c39(0x198)&&(_0x37143a=_0x513c39(0x19a),_0x123ce1=_0x6c6511[_0x513c39(0x178)]['command']||'');const _0x24f78b=a1_0x31ddc8[_0x513c39(0x193)]((_0x37143a+'\x20'+_0x123ce1)[_0x513c39(0x1a3)]());_0x24f78b[_0x513c39(0x185)]();const _0x9b4073=performance[_0x513c39(0x165)]();let _0x1765dc;try{_0x1765dc=await executeToolCall(_0x6c6511['name'],_0x6c6511[_0x513c39(0x178)]);}catch(_0x443ac3){if(_0x443ac3[_0x513c39(0x1c4)]&&_0x443ac3['message'][_0x513c39(0x173)](_0x513c39(0x187))){const _0x3106a1=await getMcpTools(),_0x30a8dc=_0x3106a1[_0x513c39(0x172)](_0x141425=>_0x141425[_0x513c39(0x1ca)]===_0x6c6511[_0x513c39(0x1ca)]);if(_0x30a8dc)try{_0x1765dc=await executeMcpTool(_0x30a8dc[_0x513c39(0x1c1)],_0x30a8dc['name'],_0x6c6511[_0x513c39(0x178)]);}catch(_0x12a7ba){throw new Error(_0x513c39(0x157)+_0x12a7ba);}else throw _0x443ac3;}else throw _0x443ac3;}const _0x4bf43a=((performance[_0x513c39(0x165)]()-_0x9b4073)/0x3e8)[_0x513c39(0x166)](0x1);_0x24f78b[_0x513c39(0x1a5)](a1_0x1570aa[_0x513c39(0x1cc)](_0x513c39(0x199)+_0x4bf43a+'s')),_0x1a9980[_0x513c39(0x1b4)]({'role':_0x513c39(0x174),'content':_0x513c39(0x1c9)+_0x6c6511['name']+':\x0a'+JSON[_0x513c39(0x18c)](_0x1765dc,null,0x2)}),await new Promise(_0x17f410=>setTimeout(_0x17f410,0x1f4));}catch(_0x3b77b6){a1_0x31ddc8[_0x513c39(0x150)](_0x513c39(0x15c)+_0x3b77b6),_0x1a9980[_0x513c39(0x1b4)]({'role':_0x513c39(0x174),'content':'Tool\x20error\x20occurred:\x20'+_0x3b77b6+'.\x20Please\x20fix\x20this\x20and\x20continue.'});}}_0x15a6ac>=_0x3ce937&&a1_0x31ddc8[_0x513c39(0x160)](_0x513c39(0x1b1));}async function executeToolCall(_0x1f2113,_0x3a4354){const _0x36a860=a1_0xf0d1;switch(_0x1f2113){case _0x36a860(0x168):return createFile(_0x3a4354['path'],_0x3a4354[_0x36a860(0x17f)]);case _0x36a860(0x159):return readFile(_0x3a4354[_0x36a860(0x170)]);case _0x36a860(0x179):return listDirectory(_0x3a4354['path']||'.');case _0x36a860(0x15e):return editFile(_0x3a4354[_0x36a860(0x170)],_0x3a4354[_0x36a860(0x16d)],_0x3a4354[_0x36a860(0x1b5)]);case'search_file':return searchFile(_0x3a4354[_0x36a860(0x170)],_0x3a4354[_0x36a860(0x188)]);case _0x36a860(0x198):const {command:_0x525625,background:_0x3abb2c,wait:_0x261939}=_0x3a4354,_0x23ed71=await runCommand(_0x525625,_0x3b5f8e=>{const _0x2b2cea=_0x36a860;a1_0x31ddc8[_0x2b2cea(0x161)](_0x3b5f8e);},_0x3abb2c,_0x261939);return _0x23ed71;case _0x36a860(0x1c0):{const {findFiles:_0x92a66f}=await import('../tools/file.js');return _0x92a66f(_0x3a4354[_0x36a860(0x170)]||'.',_0x3a4354[_0x36a860(0x188)]);}case _0x36a860(0x1c8):{const {searchDirectory:_0x2cc706}=await import(_0x36a860(0x19e));return _0x2cc706(_0x3a4354[_0x36a860(0x170)]||'.',_0x3a4354[_0x36a860(0x188)]);}default:return{'error':_0x36a860(0x17d)+_0x1f2113};}}
@@ -14,6 +14,7 @@ export declare function getMcpServers(): Record<string, McpServerConfig>;
14
14
  export declare function addMcpServer(name: string, command: string, args?: string[], env?: Record<string, string>): void;
15
15
  export declare function addMcpHttpServer(name: string, url: string): void;
16
16
  export declare function removeMcpServer(name: string): boolean;
17
+ export declare function clearMcpServers(): void;
17
18
  export declare function getMcpServer(name: string): McpServerConfig | undefined;
18
19
  export declare function ensureDefaultServers(): void;
19
20
  export declare function getConfigFilePath(): string;
@@ -1 +1 @@
1
- function a2_0x4e1a(_0x1d8e2c,_0x2db7f8){_0x1d8e2c=_0x1d8e2c-0x90;const _0x5aecf9=a2_0x5aec();let _0x4e1a8b=_0x5aecf9[_0x1d8e2c];return _0x4e1a8b;}const a2_0x50a496=a2_0x4e1a;(function(_0x45dc20,_0x534670){const _0x2cfcaf=a2_0x4e1a,_0xa067f=_0x45dc20();while(!![]){try{const _0x515d07=-parseInt(_0x2cfcaf(0xb2))/0x1*(-parseInt(_0x2cfcaf(0x90))/0x2)+-parseInt(_0x2cfcaf(0xab))/0x3+-parseInt(_0x2cfcaf(0xa3))/0x4+-parseInt(_0x2cfcaf(0x91))/0x5+parseInt(_0x2cfcaf(0x94))/0x6+-parseInt(_0x2cfcaf(0x9c))/0x7*(-parseInt(_0x2cfcaf(0xb1))/0x8)+parseInt(_0x2cfcaf(0xa8))/0x9*(parseInt(_0x2cfcaf(0x95))/0xa);if(_0x515d07===_0x534670)break;else _0xa067f['push'](_0xa067f['shift']());}catch(_0x49318f){_0xa067f['push'](_0xa067f['shift']());}}}(a2_0x5aec,0x668a1));import a2_0x5833a6 from'conf';import a2_0x143d3a from'path';import a2_0x2559d8 from'fs';import{fileURLToPath}from'url';const config=new a2_0x5833a6({'projectName':a2_0x50a496(0x9e),'defaults':{'mcpServers':{}}});export function getMcpServers(){const _0x3c60ff=a2_0x50a496,_0x4511e6=config['get'](_0x3c60ff(0xa6)),_0x451aa6=loadMcpConfigFile();return{..._0x4511e6,..._0x451aa6};}export function addMcpServer(_0x2be3f5,_0x33127d,_0x3a85ed=[],_0x22ae88){const _0x3ca7b2=a2_0x50a496,_0x3a9c46=config[_0x3ca7b2(0x9a)](_0x3ca7b2(0xa6));_0x3a9c46[_0x2be3f5]={'type':_0x3ca7b2(0xb0),'command':_0x33127d,'args':_0x3a85ed,'env':_0x22ae88},config[_0x3ca7b2(0x96)](_0x3ca7b2(0xa6),_0x3a9c46);}export function addMcpHttpServer(_0x14bd32,_0x5870d1){const _0x446cb9=a2_0x50a496,_0x40a778=config['get'](_0x446cb9(0xa6));_0x40a778[_0x14bd32]={'type':_0x446cb9(0x98),'url':_0x5870d1},config[_0x446cb9(0x96)](_0x446cb9(0xa6),_0x40a778);}export function removeMcpServer(_0x43e2de){const _0x577b0e=a2_0x50a496,_0xfa68b3=config['get'](_0x577b0e(0xa6));if(_0xfa68b3[_0x43e2de])return delete _0xfa68b3[_0x43e2de],config[_0x577b0e(0x96)](_0x577b0e(0xa6),_0xfa68b3),!![];return![];}export function getMcpServer(_0x23567c){return getMcpServers()[_0x23567c];}function loadMcpConfigFile(){const _0x47a8a3=a2_0x50a496,_0xf63c7e=[a2_0x143d3a[_0x47a8a3(0xac)](process['cwd'](),'mcp.json'),a2_0x143d3a['join'](process[_0x47a8a3(0xa2)](),_0x47a8a3(0xb3),_0x47a8a3(0x99)),a2_0x143d3a[_0x47a8a3(0xac)](process[_0x47a8a3(0xa0)][_0x47a8a3(0xa7)]||process[_0x47a8a3(0xa0)]['USERPROFILE']||'','.woozlit',_0x47a8a3(0x99))];for(const _0xe56dda of _0xf63c7e){try{if(a2_0x2559d8['existsSync'](_0xe56dda)){const _0x1dfa65=a2_0x2559d8[_0x47a8a3(0x9f)](_0xe56dda,_0x47a8a3(0xa1)),_0x41cf31=JSON['parse'](_0x1dfa65);if(_0x41cf31[_0x47a8a3(0xa6)]&&typeof _0x41cf31[_0x47a8a3(0xa6)]===_0x47a8a3(0x9b))return _0x41cf31[_0x47a8a3(0xa6)];}}catch{}}return{};}function a2_0x5aec(){const _0x4fe3a5=['716597TkuXoB','@modelcontextprotocol/server-filesystem','woozlit-cli','readFileSync','env','utf-8','cwd','2940452WkKTlw','endsWith','windows-mcp','mcpServers','HOME','15381XyqsNc','src','path','1163673sIEAih','join','uvx','npx','computer-use.ts','stdio','8txQeDG','1ngzQyc','.woozlit','includes','1129442KFiRcR','1715015gTzsLl','computer-use.js','computer-use','1991670SLJeJT','5190ziftNv','set','node','streamable-http','mcp.json','get','object'];a2_0x5aec=function(){return _0x4fe3a5;};return a2_0x5aec();}export function ensureDefaultServers(){const _0x221885=a2_0x50a496,_0x3fa7d0=config[_0x221885(0x9a)](_0x221885(0xa6)),_0x4edc12=fileURLToPath(import.meta.url),_0x487448=a2_0x143d3a['dirname'](_0x4edc12),_0x13b379=_0x487448[_0x221885(0xb4)]('dist')||_0x4edc12[_0x221885(0xa4)]('.js'),_0x26c3da=_0x13b379?a2_0x143d3a[_0x221885(0xac)](_0x487448,'..','mcp-servers',_0x221885(0x92)):a2_0x143d3a[_0x221885(0xac)](_0x487448,'..','..',_0x221885(0xa9),'mcp-servers',_0x221885(0xaf)),_0x5d0896=_0x13b379?_0x221885(0x97):'tsx';_0x3fa7d0[_0x221885(0x93)]={'type':'stdio','command':_0x5d0896,'args':[_0x26c3da],'env':{}},(!_0x3fa7d0[_0x221885(0xa5)]||_0x3fa7d0[_0x221885(0xa5)]['command']===_0x221885(0xad))&&(_0x3fa7d0[_0x221885(0xa5)]={'type':'stdio','command':_0x221885(0xae),'args':['-y',_0x221885(0x9d),'C:\x5cUsers'],'env':{}}),config[_0x221885(0x96)](_0x221885(0xa6),_0x3fa7d0);}export function getConfigFilePath(){const _0x307cf5=a2_0x50a496;return config[_0x307cf5(0xaa)];}
1
+ const a2_0x4600db=a2_0x413c;(function(_0x2f4708,_0x5ba7b7){const _0x10bedd=a2_0x413c,_0x3e352e=_0x2f4708();while(!![]){try{const _0x12a845=-parseInt(_0x10bedd(0x11f))/0x1+-parseInt(_0x10bedd(0x114))/0x2*(-parseInt(_0x10bedd(0x107))/0x3)+parseInt(_0x10bedd(0x105))/0x4*(parseInt(_0x10bedd(0x11d))/0x5)+parseInt(_0x10bedd(0x11a))/0x6+-parseInt(_0x10bedd(0x120))/0x7*(-parseInt(_0x10bedd(0x109))/0x8)+parseInt(_0x10bedd(0xfb))/0x9+-parseInt(_0x10bedd(0x104))/0xa;if(_0x12a845===_0x5ba7b7)break;else _0x3e352e['push'](_0x3e352e['shift']());}catch(_0x289178){_0x3e352e['push'](_0x3e352e['shift']());}}}(a2_0x7307,0xee8f3));function a2_0x7307(){const _0x593d46=['get','mcpServers','cwd','USERPROFILE','command','28146860PkWPeF','5160620oDIURP','computer-use.ts','3oKzNtr','set','760024qURVuq','readFileSync','mcp-servers','includes','utf-8','C:\x5cUsers','streamable-http','.woozlit','dirname','endsWith','existsSync','1654456tNlUgY','uvx','stdio','src','HOME','woozlit-cli','2680134sHXhdS','env','join','5rABoSf','node','958978HUBnma','28dIzBOT','16260471PmkjSB','mcp.json','@modelcontextprotocol/server-filesystem','object'];a2_0x7307=function(){return _0x593d46;};return a2_0x7307();}import a2_0x236671 from'conf';import a2_0x2e5219 from'path';import a2_0x1bc61f from'fs';import{fileURLToPath}from'url';const config=new a2_0x236671({'projectName':a2_0x4600db(0x119),'defaults':{'mcpServers':{}}});export function getMcpServers(){const _0x18b8ea=a2_0x4600db,_0x65e649=config[_0x18b8ea(0xff)](_0x18b8ea(0x100)),_0x4045f8=loadMcpConfigFile();return{..._0x65e649,..._0x4045f8};}function a2_0x413c(_0x428d8c,_0x2de505){_0x428d8c=_0x428d8c-0xfb;const _0x7307e3=a2_0x7307();let _0x413c04=_0x7307e3[_0x428d8c];return _0x413c04;}export function addMcpServer(_0x1ef3d8,_0xb2a3d1,_0x3e024d=[],_0x4dbc0d){const _0x43faed=a2_0x4600db,_0x122177=config[_0x43faed(0xff)](_0x43faed(0x100));_0x122177[_0x1ef3d8]={'type':_0x43faed(0x116),'command':_0xb2a3d1,'args':_0x3e024d,'env':_0x4dbc0d},config['set'](_0x43faed(0x100),_0x122177);}export function addMcpHttpServer(_0xcb16b8,_0x779597){const _0x71a7dd=a2_0x4600db,_0x3ea82b=config['get'](_0x71a7dd(0x100));_0x3ea82b[_0xcb16b8]={'type':_0x71a7dd(0x10f),'url':_0x779597},config['set'](_0x71a7dd(0x100),_0x3ea82b);}export function removeMcpServer(_0x2835c4){const _0x10dee8=a2_0x4600db,_0x3f534b=config[_0x10dee8(0xff)]('mcpServers');if(_0x3f534b[_0x2835c4])return delete _0x3f534b[_0x2835c4],config['set'](_0x10dee8(0x100),_0x3f534b),!![];return![];}export function clearMcpServers(){const _0x4947eb=a2_0x4600db;config[_0x4947eb(0x108)](_0x4947eb(0x100),{});}export function getMcpServer(_0x32d7be){return getMcpServers()[_0x32d7be];}function loadMcpConfigFile(){const _0x33a53d=a2_0x4600db,_0x5a6416=[a2_0x2e5219[_0x33a53d(0x11c)](process[_0x33a53d(0x101)](),_0x33a53d(0xfc)),a2_0x2e5219[_0x33a53d(0x11c)](process[_0x33a53d(0x101)](),'.woozlit',_0x33a53d(0xfc)),a2_0x2e5219[_0x33a53d(0x11c)](process[_0x33a53d(0x11b)][_0x33a53d(0x118)]||process[_0x33a53d(0x11b)][_0x33a53d(0x102)]||'',_0x33a53d(0x110),_0x33a53d(0xfc))];for(const _0x9c50fe of _0x5a6416){try{if(a2_0x1bc61f[_0x33a53d(0x113)](_0x9c50fe)){const _0x149c6b=a2_0x1bc61f[_0x33a53d(0x10a)](_0x9c50fe,_0x33a53d(0x10d)),_0x5304f3=JSON['parse'](_0x149c6b);if(_0x5304f3[_0x33a53d(0x100)]&&typeof _0x5304f3[_0x33a53d(0x100)]===_0x33a53d(0xfe))return _0x5304f3[_0x33a53d(0x100)];}}catch{}}return{};}export function ensureDefaultServers(){const _0x4749b5=a2_0x4600db,_0xb22381=config[_0x4749b5(0xff)](_0x4749b5(0x100)),_0x164bb1=fileURLToPath(import.meta.url),_0x20e95c=a2_0x2e5219[_0x4749b5(0x111)](_0x164bb1),_0x17bf27=_0x20e95c[_0x4749b5(0x10c)]('dist')||_0x164bb1[_0x4749b5(0x112)]('.js'),_0x511892=_0x17bf27?a2_0x2e5219[_0x4749b5(0x11c)](_0x20e95c,'..',_0x4749b5(0x10b),'computer-use.js'):a2_0x2e5219['join'](_0x20e95c,'..','..',_0x4749b5(0x117),_0x4749b5(0x10b),_0x4749b5(0x106)),_0x345054=_0x17bf27?_0x4749b5(0x11e):'tsx';_0xb22381['computer-use']={'type':_0x4749b5(0x116),'command':_0x345054,'args':[_0x511892],'env':{}},(!_0xb22381['windows-mcp']||_0xb22381['windows-mcp'][_0x4749b5(0x103)]===_0x4749b5(0x115))&&(_0xb22381['windows-mcp']={'type':_0x4749b5(0x116),'command':'npx','args':['-y',_0x4749b5(0xfd),_0x4749b5(0x10e)],'env':{}}),config[_0x4749b5(0x108)](_0x4749b5(0x100),_0xb22381);}export function getConfigFilePath(){return config['path'];}
@@ -1 +1 @@
1
- const a3_0x115d8c=a3_0x2dde;(function(_0x10d0b7,_0x334af6){const _0x34868a=a3_0x2dde,_0x4410ff=_0x10d0b7();while(!![]){try{const _0x5259fd=parseInt(_0x34868a(0x79))/0x1*(-parseInt(_0x34868a(0x87))/0x2)+-parseInt(_0x34868a(0x80))/0x3+parseInt(_0x34868a(0x6c))/0x4+parseInt(_0x34868a(0x84))/0x5*(parseInt(_0x34868a(0x77))/0x6)+-parseInt(_0x34868a(0x93))/0x7*(-parseInt(_0x34868a(0x8e))/0x8)+-parseInt(_0x34868a(0x89))/0x9*(parseInt(_0x34868a(0x86))/0xa)+parseInt(_0x34868a(0x74))/0xb*(parseInt(_0x34868a(0x7a))/0xc);if(_0x5259fd===_0x334af6)break;else _0x4410ff['push'](_0x4410ff['shift']());}catch(_0x517625){_0x4410ff['push'](_0x4410ff['shift']());}}}(a3_0x2c0d,0xc0568));const API_URL=process[a3_0x115d8c(0x8c)][a3_0x115d8c(0x78)]||a3_0x115d8c(0x6d),PROD_URL='https://woozlit.com';function a3_0x2c0d(){const _0x49eec=['nvidia/nemotron-nano-12b-v2-vl:free','3883jwrItu','Meta\x27s\x20powerful\x20model','mistralai/devstral-small','12YSTItl','WOOZLIT_API_URL','1jNKFfk','68952SlgCiU','z-ai/glm-4.5-air:free','Zhipu\x20AI\x20model','Coding\x20specialist','Kat\x20Coder\x20Pro','Qwen3\x20Coder','4338837RTOBWd','GLM\x204.5\x20Air','tngtech/deepseek-r1t-chimera:free','Meta\x27s\x20latest','2651320xQBQyS','NVIDIA\x20vision','120oaxqUP','3043874eBEetU','meta-llama/llama-4-maverick','872424QHFMbh','meta-llama/llama-3.3-70b-instruct:free','DeepSeek\x20R1T\x20Chimera','env','Llama\x203.3\x2070B','102504ghogHJ','qwen/qwen3-coder:free','Mistral\x20Small\x203.2','Developer-focused','Reasoning\x20model','693iKwcDR','Qwen3\x20235B','2247644WofjqB','https://woozlit.com','Llama\x204\x20Maverick','Advanced\x20coding','Xiaomi\x27s\x20fast\x20AI\x20model','xiaomi/mimo-v2-flash:free','Kimi\x20K2'];a3_0x2c0d=function(){return _0x49eec;};return a3_0x2c0d();}export function getApiUrl(){return API_URL;}export function getProdUrl(){return PROD_URL;}export function isProduction(){return API_URL===PROD_URL;}function a3_0x2dde(_0x21a292,_0x52117e){_0x21a292=_0x21a292-0x6b;const _0x2c0d86=a3_0x2c0d();let _0x2ddef4=_0x2c0d86[_0x21a292];return _0x2ddef4;}export const MODELS=[{'id':'xiaomi/mimo-v2-flash:free','name':'MiMo\x20V2','description':a3_0x115d8c(0x70)},{'id':'qwen/qwen3-235b-a22b:free','name':a3_0x115d8c(0x6b),'description':'Alibaba\x27s\x20largest'},{'id':a3_0x115d8c(0x8f),'name':a3_0x115d8c(0x7f),'description':a3_0x115d8c(0x7d)},{'id':a3_0x115d8c(0x8a),'name':a3_0x115d8c(0x8d),'description':a3_0x115d8c(0x75)},{'id':a3_0x115d8c(0x88),'name':a3_0x115d8c(0x6e),'description':a3_0x115d8c(0x83)},{'id':a3_0x115d8c(0x76),'name':'Devstral\x20Small','description':a3_0x115d8c(0x91)},{'id':'mistralai/mistral-small-3.2-24b-instruct','name':a3_0x115d8c(0x90),'description':'Latest\x20Mistral'},{'id':a3_0x115d8c(0x73),'name':'Nemotron\x20Nano\x2012B','description':a3_0x115d8c(0x85)},{'id':'moonshotai/kimi-k2','name':a3_0x115d8c(0x72),'description':a3_0x115d8c(0x92)},{'id':a3_0x115d8c(0x7b),'name':a3_0x115d8c(0x81),'description':a3_0x115d8c(0x7c)},{'id':'kwaipilot/kat-coder-pro:free','name':a3_0x115d8c(0x7e),'description':a3_0x115d8c(0x6f)},{'id':a3_0x115d8c(0x82),'name':a3_0x115d8c(0x8b),'description':a3_0x115d8c(0x92)}];export const DEFAULT_MODEL=a3_0x115d8c(0x71);
1
+ function a3_0x598c(_0x1b2160,_0x21c525){_0x1b2160=_0x1b2160-0x85;const _0x35505e=a3_0x3550();let _0x598c1e=_0x35505e[_0x1b2160];return _0x598c1e;}const a3_0x3f9962=a3_0x598c;(function(_0x309186,_0x4e6709){const _0x5282bf=a3_0x598c,_0x3527f6=_0x309186();while(!![]){try{const _0x39d1dd=parseInt(_0x5282bf(0x92))/0x1*(-parseInt(_0x5282bf(0xa6))/0x2)+parseInt(_0x5282bf(0x8a))/0x3*(parseInt(_0x5282bf(0xa5))/0x4)+parseInt(_0x5282bf(0x9e))/0x5+parseInt(_0x5282bf(0xa3))/0x6+-parseInt(_0x5282bf(0xa1))/0x7+parseInt(_0x5282bf(0xaf))/0x8*(parseInt(_0x5282bf(0xa4))/0x9)+parseInt(_0x5282bf(0xa9))/0xa*(-parseInt(_0x5282bf(0x88))/0xb);if(_0x39d1dd===_0x4e6709)break;else _0x3527f6['push'](_0x3527f6['shift']());}catch(_0x474778){_0x3527f6['push'](_0x3527f6['shift']());}}}(a3_0x3550,0xd625c));const API_URL=process['env'][a3_0x3f9962(0x9c)]||'https://woozlit.com',PROD_URL=a3_0x3f9962(0x8b);export function getApiUrl(){return API_URL;}export function getProdUrl(){return PROD_URL;}export function isProduction(){return API_URL===PROD_URL;}function a3_0x3550(){const _0x42e436=['Mistral\x20Small\x203.2','4665954krCsia','https://woozlit.com','meta-llama/llama-3.2-90b-vision-instruct:free','Meta\x27s\x20latest','Kimi\x20K2','xiaomi/mimo-v2-flash:free','DeepSeek\x27s\x20latest\x20V3','Nemotron\x20Nano\x2012B','71heiUyh','Llama\x204\x20Maverick','qwen/qwen3-coder:free','z-ai/glm-4.5-air:free','Zhipu\x20AI\x20model','Advanced\x20reasoning\x20model','Coding\x20specialist','deepseek/deepseek-chat','DeepSeek\x20R1T\x20Chimera','Latest\x20Mistral','WOOZLIT_API_URL','Advanced\x20coding','1889995nFFaUr','kwaipilot/kat-coder-pro:free','Llama\x203.2\x2090B','4399353TezgZG','Reasoning\x20model','9930552kOTFNL','9RAcmMk','4FSgGtJ','25706wlytNv','deepseek/deepseek-r1','GLM\x204.5\x20Air','170sqDZrf','NVIDIA\x20vision','MiMo\x20V2','qwen/qwen3-235b-a22b:free','Llama\x203.3\x2070B','nvidia/nemotron-nano-12b-v2-vl:free','1037216juABog','DeepSeek\x20R1','Xiaomi\x27s\x20fast\x20AI\x20model','tngtech/deepseek-r1t-chimera:free','Meta\x27s\x20powerful\x20model','meta-llama/llama-3.2-11b-vision-instruct:free','mistralai/devstral-small','Efficient\x20vision\x20model','841093iwpriT'];a3_0x3550=function(){return _0x42e436;};return a3_0x3550();}export const MODELS=[{'id':'xiaomi/mimo-v2-flash:free','name':a3_0x3f9962(0xab),'description':a3_0x3f9962(0xb1)},{'id':a3_0x3f9962(0xac),'name':'Qwen3\x20235B','description':'Alibaba\x27s\x20largest'},{'id':a3_0x3f9962(0x94),'name':'Qwen3\x20Coder','description':a3_0x3f9962(0x98)},{'id':'meta-llama/llama-3.3-70b-instruct:free','name':a3_0x3f9962(0xad),'description':a3_0x3f9962(0xb3)},{'id':'meta-llama/llama-4-maverick','name':a3_0x3f9962(0x93),'description':a3_0x3f9962(0x8d)},{'id':a3_0x3f9962(0x86),'name':'Devstral\x20Small','description':'Developer-focused'},{'id':'mistralai/mistral-small-3.2-24b-instruct','name':a3_0x3f9962(0x89),'description':a3_0x3f9962(0x9b)},{'id':a3_0x3f9962(0xae),'name':a3_0x3f9962(0x91),'description':a3_0x3f9962(0xaa)},{'id':'moonshotai/kimi-k2','name':a3_0x3f9962(0x8e),'description':a3_0x3f9962(0xa2)},{'id':a3_0x3f9962(0x95),'name':a3_0x3f9962(0xa8),'description':a3_0x3f9962(0x96)},{'id':a3_0x3f9962(0x9f),'name':'Kat\x20Coder\x20Pro','description':a3_0x3f9962(0x9d)},{'id':a3_0x3f9962(0xb2),'name':a3_0x3f9962(0x9a),'description':a3_0x3f9962(0xa2)},{'id':a3_0x3f9962(0x99),'name':'DeepSeek\x20V3','description':a3_0x3f9962(0x90)},{'id':a3_0x3f9962(0xa7),'name':a3_0x3f9962(0xb0),'description':a3_0x3f9962(0x97)},{'id':a3_0x3f9962(0x8c),'name':a3_0x3f9962(0xa0),'description':'Meta\x27s\x20vision\x20model'},{'id':a3_0x3f9962(0x85),'name':'Llama\x203.2\x2011B','description':a3_0x3f9962(0x87)}];export const DEFAULT_MODEL=a3_0x3f9962(0x8f);
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- const a4_0x2807a2=a4_0x22fa;function a4_0x5a39(){const _0x15acfe=['rules','MCP\x20server\x20\x27','args','Add\x20an\x20HTTP\x20MCP\x20server\x20(streamable-http)','276807ZZEswR','URL:\x20','Add\x20a\x20stdio\x20MCP\x20server','Logout\x20from\x20your\x20Woozlit\x20account','add-http\x20<name>\x20<url>','Manage\x20AI\x20behavior\x20rules','You\x20must\x20be\x20logged\x20in\x20to\x20use\x20chat.','header','showLogo','Logged\x20in\x20as\x20','23691204evJxug','Woozlit\x20already\x20initialized\x20in\x20this\x20directory','description','You\x20can\x20also\x20add\x20servers\x20via\x20mcp.json\x20in\x20your\x20project\x20directory','Created\x20.woozlit/rules.md\x20and\x20.woozlit/context.md','Model:\x20','Email:\x20',':\x20[HTTP]\x20','success','error','./tools/file.js','length','Already\x20logged\x20in\x20as\x20','ask\x20<message>','948SDoPjI','Select\x20AI\x20model','.woozlit/rules.md','email','5485056JwhCFo','#\x20Project\x20Rules\x0a\x0aAdd\x20your\x20project-specific\x20rules\x20here.\x0a','action','dim','add\x20<name>\x20<command>\x20[args...]','info','N/A','stop','./utils/mcp-installer.js','displayName','name','woozlit','Initialize\x20Woozlit\x20in\x20current\x20directory','Current\x20User',':\x20[stdio]\x20','Woozlit\x20AI\x20-\x20Agentic\x20Coding\x20Assistant','19641dazOAf','logout','Added\x20stdio\x20MCP\x20server:\x20','Rules','join','#\x20Project\x20Context\x0a\x0aDescribe\x20your\x20project\x20here.\x0a','whoami','command','\x27\x20not\x20found','List\x20all\x20rules','createSpinner','MCP\x20Servers','2YUXeHf','Opening\x20browser\x20for\x20login...','keys','262460iwEBQk','install\x20<source>\x20[name]','3765720OAcSCL','Configure\x20CLI\x20settings','Name:\x20','587160vxxDTm','Config\x20file:\x20','streamable-http','Remove\x20an\x20MCP\x20server','entries','Show\x20current\x20user\x20info','start','Start\x20an\x20AI\x20chat\x20session','Model\x20set\x20to:\x20','\x0aConfig\x20file:\x20','mcp','stdout','parse','List\x20all\x20MCP\x20servers','Login\x20failed\x20or\x20timed\x20out','No\x20MCP\x20servers\x20configured','warn','1.1.2','remove\x20<name>','Added\x20HTTP\x20MCP\x20server:\x20','add\x20<rule>','All\x20rules\x20cleared','forEach','login','Waiting\x20for\x20authentication...','list','Added\x20rule:\x20','.woozlit','config','Ask\x20a\x20single\x20question','Initialized\x20Woozlit\x20in\x20current\x20directory','Manage\x20MCP\x20servers','Not\x20logged\x20in.\x20Use\x20\x27woozlit\x20login\x27\x20to\x20authenticate.'];a4_0x5a39=function(){return _0x15acfe;};return a4_0x5a39();}(function(_0x3c69f3,_0x5266a3){const _0x4dc1c4=a4_0x22fa,_0x1f10d3=_0x3c69f3();while(!![]){try{const _0x2433d3=-parseInt(_0x4dc1c4(0x11f))/0x1*(parseInt(_0x4dc1c4(0xf2))/0x2)+parseInt(_0x4dc1c4(0x14b))/0x3*(-parseInt(_0x4dc1c4(0x137))/0x4)+parseInt(_0x4dc1c4(0xf5))/0x5+-parseInt(_0x4dc1c4(0xf7))/0x6+-parseInt(_0x4dc1c4(0xfa))/0x7+parseInt(_0x4dc1c4(0x13b))/0x8+parseInt(_0x4dc1c4(0x129))/0x9;if(_0x2433d3===_0x5266a3)break;else _0x1f10d3['push'](_0x1f10d3['shift']());}catch(_0x2dc1c6){_0x1f10d3['push'](_0x1f10d3['shift']());}}}(a4_0x5a39,0xcac46));import{Command}from'commander';import{login,logout,isLoggedIn}from'./auth/login.js';import{startChat}from'./chat/agent.js';import{selectModel,getSelectedModel}from'./ui/select.js';import{listRules,addRule,clearRules}from'./tools/rules.js';import{getUser}from'./utils/storage.js';import{addMcpServer,addMcpHttpServer,removeMcpServer,getMcpServers,ensureDefaultServers,getConfigFilePath}from'./config/mcp.js';import{checkForUpdate}from'./utils/update-check.js';import*as a4_0x19e91c from'./ui/output.js';const program=new Command();program[a4_0x2807a2(0x145)](a4_0x2807a2(0x146))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x14a))['version'](a4_0x2807a2(0x10b))[a4_0x2807a2(0x13d)](async()=>{const _0x2fb682=a4_0x2807a2;await checkForUpdate(),ensureDefaultServers(),a4_0x19e91c[_0x2fb682(0x127)]();if(!isLoggedIn()){a4_0x19e91c[_0x2fb682(0x10a)](_0x2fb682(0x125)),a4_0x19e91c['dim'](''),a4_0x19e91c[_0x2fb682(0x140)](_0x2fb682(0xf3));const _0x86d73e=a4_0x19e91c[_0x2fb682(0xf0)](_0x2fb682(0x112));_0x86d73e[_0x2fb682(0x100)]();const _0x22d297=await login();_0x86d73e[_0x2fb682(0x142)]();if(!_0x22d297){a4_0x19e91c[_0x2fb682(0x132)](_0x2fb682(0x108));return;}const _0x4d0555=getUser();a4_0x19e91c[_0x2fb682(0x131)]('Logged\x20in\x20as\x20'+(_0x4d0555[_0x2fb682(0x144)]||_0x4d0555[_0x2fb682(0x13a)]));}await startChat();}),program[a4_0x2807a2(0x152)](a4_0x2807a2(0x111))[a4_0x2807a2(0x12b)]('Login\x20with\x20your\x20Woozlit\x20account')[a4_0x2807a2(0x13d)](async()=>{const _0x499747=a4_0x2807a2;if(isLoggedIn()){const _0x3557a7=getUser();a4_0x19e91c[_0x499747(0x140)](_0x499747(0x135)+_0x3557a7[_0x499747(0x13a)]);return;}a4_0x19e91c[_0x499747(0x140)](_0x499747(0xf3));const _0x25ac32=a4_0x19e91c[_0x499747(0xf0)](_0x499747(0x112));_0x25ac32[_0x499747(0x100)]();const _0x4f869e=await login();_0x25ac32[_0x499747(0x142)]();if(_0x4f869e){const _0x2b26df=getUser();a4_0x19e91c[_0x499747(0x131)](_0x499747(0x128)+(_0x2b26df[_0x499747(0x144)]||_0x2b26df['email']));}else a4_0x19e91c['error']('Login\x20failed\x20or\x20timed\x20out');}),program[a4_0x2807a2(0x152)](a4_0x2807a2(0x14c))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x122))[a4_0x2807a2(0x13d)](()=>{logout(),a4_0x19e91c['success']('Logged\x20out\x20successfully');}),program['command'](a4_0x2807a2(0x151))[a4_0x2807a2(0x12b)](a4_0x2807a2(0xff))[a4_0x2807a2(0x13d)](()=>{const _0x31d7d8=a4_0x2807a2;if(!isLoggedIn()){a4_0x19e91c[_0x31d7d8(0x10a)](_0x31d7d8(0x11a));return;}const _0x3850b4=getUser();a4_0x19e91c[_0x31d7d8(0x126)](_0x31d7d8(0x148)),a4_0x19e91c[_0x31d7d8(0x140)](_0x31d7d8(0xf9)+(_0x3850b4[_0x31d7d8(0x144)]||_0x31d7d8(0x141))),a4_0x19e91c[_0x31d7d8(0x140)](_0x31d7d8(0x12f)+(_0x3850b4[_0x31d7d8(0x13a)]||'N/A')),a4_0x19e91c[_0x31d7d8(0x140)](_0x31d7d8(0x12e)+getSelectedModel());}),program[a4_0x2807a2(0x152)]('chat\x20[message]')[a4_0x2807a2(0x12b)](a4_0x2807a2(0x101))[a4_0x2807a2(0x13d)](async _0x399557=>{const _0x51af64=a4_0x2807a2;a4_0x19e91c['showLogo']();if(!isLoggedIn()){a4_0x19e91c['warn'](_0x51af64(0x125)),a4_0x19e91c['dim'](''),a4_0x19e91c['info'](_0x51af64(0xf3));const _0x47689e=a4_0x19e91c['createSpinner'](_0x51af64(0x112));_0x47689e[_0x51af64(0x100)]();const _0x286f00=await login();_0x47689e['stop']();if(!_0x286f00){a4_0x19e91c[_0x51af64(0x132)](_0x51af64(0x108));return;}const _0x26d839=getUser();a4_0x19e91c[_0x51af64(0x131)](_0x51af64(0x128)+(_0x26d839[_0x51af64(0x144)]||_0x26d839['email']));}await startChat(_0x399557);}),program[a4_0x2807a2(0x152)](a4_0x2807a2(0x136))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x117))['action'](async _0x577b40=>{const _0x316854=a4_0x2807a2;a4_0x19e91c[_0x316854(0x127)]();if(!isLoggedIn()){a4_0x19e91c['warn'](_0x316854(0x125)),a4_0x19e91c[_0x316854(0x13e)](''),a4_0x19e91c[_0x316854(0x140)]('Opening\x20browser\x20for\x20login...');const _0x142765=a4_0x19e91c[_0x316854(0xf0)]('Waiting\x20for\x20authentication...');_0x142765['start']();const _0x31022b=await login();_0x142765[_0x316854(0x142)]();if(!_0x31022b){a4_0x19e91c['error'](_0x316854(0x108));return;}const _0x35006e=getUser();a4_0x19e91c['success']('Logged\x20in\x20as\x20'+(_0x35006e[_0x316854(0x144)]||_0x35006e[_0x316854(0x13a)]));}await startChat(_0x577b40);});const configCmd=program['command'](a4_0x2807a2(0x116))[a4_0x2807a2(0x12b)](a4_0x2807a2(0xf8));configCmd[a4_0x2807a2(0x152)]('model')[a4_0x2807a2(0x12b)](a4_0x2807a2(0x138))[a4_0x2807a2(0x13d)](async()=>{const _0x30b7f1=a4_0x2807a2,_0x34805e=await selectModel();a4_0x19e91c['success'](_0x30b7f1(0x102)+_0x34805e);});const rulesCmd=program[a4_0x2807a2(0x152)](a4_0x2807a2(0x11b))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x124));function a4_0x22fa(_0xefd3e9,_0xcace12){_0xefd3e9=_0xefd3e9-0xf0;const _0x5a39bf=a4_0x5a39();let _0x22fa70=_0x5a39bf[_0xefd3e9];return _0x22fa70;}rulesCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0x113))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x154))[a4_0x2807a2(0x13d)](()=>{const _0x58db1c=a4_0x2807a2,_0x1d0607=listRules();if(_0x1d0607[_0x58db1c(0x134)]===0x0){a4_0x19e91c[_0x58db1c(0x140)]('No\x20rules\x20defined');return;}a4_0x19e91c[_0x58db1c(0x126)](_0x58db1c(0x14e)),_0x1d0607['forEach']((_0x48b407,_0x39c225)=>{const _0x5d676f=_0x58db1c;process[_0x5d676f(0x105)]['write'](_0x39c225+0x1+'.\x20'+_0x48b407+'\x0a');});}),rulesCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0x10e))[a4_0x2807a2(0x12b)]('Add\x20a\x20new\x20rule')[a4_0x2807a2(0x13d)](_0x38090f=>{const _0x48b861=a4_0x2807a2;addRule(_0x38090f),a4_0x19e91c[_0x48b861(0x131)](_0x48b861(0x114)+_0x38090f);})[a4_0x2807a2(0x13d)](()=>{const _0x55412a=a4_0x2807a2;clearRules(),a4_0x19e91c[_0x55412a(0x131)](_0x55412a(0x10f));});const mcpCmd=program[a4_0x2807a2(0x152)](a4_0x2807a2(0x104))['description'](a4_0x2807a2(0x119));mcpCmd['command']('list')[a4_0x2807a2(0x12b)](a4_0x2807a2(0x107))[a4_0x2807a2(0x13d)](()=>{const _0x2d2d44=a4_0x2807a2,_0xf457f0=getMcpServers(),_0x3d6514=Object[_0x2d2d44(0xf4)](_0xf457f0);if(_0x3d6514[_0x2d2d44(0x134)]===0x0){a4_0x19e91c['info'](_0x2d2d44(0x109)),a4_0x19e91c[_0x2d2d44(0x13e)](_0x2d2d44(0xfb)+getConfigFilePath());return;}a4_0x19e91c[_0x2d2d44(0x126)](_0x2d2d44(0xf1)),_0x3d6514[_0x2d2d44(0x110)](_0x582dc2=>{const _0xecab50=_0x2d2d44,_0x2148c8=_0xf457f0[_0x582dc2];_0x2148c8['type']===_0xecab50(0xfc)?a4_0x19e91c[_0xecab50(0x140)]('-\x20'+_0x582dc2+_0xecab50(0x130)+_0x2148c8['url']):a4_0x19e91c[_0xecab50(0x140)]('-\x20'+_0x582dc2+_0xecab50(0x149)+_0x2148c8['command']+'\x20'+(_0x2148c8[_0xecab50(0x11d)]?.[_0xecab50(0x14f)]('\x20')||''));}),a4_0x19e91c[_0x2d2d44(0x13e)](_0x2d2d44(0x103)+getConfigFilePath()),a4_0x19e91c['dim'](_0x2d2d44(0x12c));}),mcpCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0x13f))['description'](a4_0x2807a2(0x121))['action']((_0x43750e,_0x1d7b16,_0x2f6260)=>{const _0x5261d1=a4_0x2807a2;addMcpServer(_0x43750e,_0x1d7b16,_0x2f6260),a4_0x19e91c[_0x5261d1(0x131)](_0x5261d1(0x14d)+_0x43750e);}),mcpCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0x123))[a4_0x2807a2(0x12b)](a4_0x2807a2(0x11e))['action']((_0x4cd988,_0x3f712e)=>{const _0x3dd8be=a4_0x2807a2;addMcpHttpServer(_0x4cd988,_0x3f712e),a4_0x19e91c[_0x3dd8be(0x131)](_0x3dd8be(0x10d)+_0x4cd988),a4_0x19e91c[_0x3dd8be(0x13e)](_0x3dd8be(0x120)+_0x3f712e);}),mcpCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0xf6))[a4_0x2807a2(0x12b)]('Install\x20an\x20MCP\x20server\x20from\x20GitHub\x20or\x20registry\x20(e.g.\x20\x27mcp-chrome-bridge\x27,\x20\x27owner/repo\x27)')[a4_0x2807a2(0x13d)](async(_0x4ae80e,_0x57fe78)=>{const _0x4f5efe=a4_0x2807a2,{installMcpServer:_0xdb35}=await import(_0x4f5efe(0x143));await _0xdb35(_0x4ae80e,_0x57fe78);}),mcpCmd[a4_0x2807a2(0x152)](a4_0x2807a2(0x10c))[a4_0x2807a2(0x12b)](a4_0x2807a2(0xfd))[a4_0x2807a2(0x13d)](_0x3fe6d2=>{const _0xaaa9af=a4_0x2807a2;removeMcpServer(_0x3fe6d2)?a4_0x19e91c[_0xaaa9af(0x131)]('Removed\x20MCP\x20server:\x20'+_0x3fe6d2):a4_0x19e91c[_0xaaa9af(0x132)](_0xaaa9af(0x11c)+_0x3fe6d2+_0xaaa9af(0x153));}),program['command']('init')['description'](a4_0x2807a2(0x147))[a4_0x2807a2(0x13d)](()=>{const _0x37de5f=a4_0x2807a2,{createFile:_0x3f6b7b,listDirectory:_0x1fbab8}=require(_0x37de5f(0x133)),_0xc1c04d=_0x1fbab8('.'),_0x5f1980=_0xc1c04d[_0x37de5f(0xfe)]?.['some'](_0x53e4de=>_0x53e4de[_0x37de5f(0x145)]===_0x37de5f(0x115));if(_0x5f1980){a4_0x19e91c[_0x37de5f(0x10a)](_0x37de5f(0x12a));return;}_0x3f6b7b(_0x37de5f(0x139),_0x37de5f(0x13c)),_0x3f6b7b('.woozlit/context.md',_0x37de5f(0x150)),a4_0x19e91c[_0x37de5f(0x131)](_0x37de5f(0x118)),a4_0x19e91c[_0x37de5f(0x13e)](_0x37de5f(0x12d));}),program[a4_0x2807a2(0x106)]();
2
+ const a4_0x5dcee2=a4_0x1d21;function a4_0x25a7(){const _0x521cfc=['action','createSpinner','version','Added\x20HTTP\x20MCP\x20server:\x20','1754316MRTMxa','List\x20all\x20rules','You\x20must\x20be\x20logged\x20in\x20to\x20use\x20chat.','Model\x20set\x20to:\x20','Add\x20an\x20HTTP\x20MCP\x20server\x20(streamable-http)','Current\x20User','success','model','Remove\x20an\x20MCP\x20server','Woozlit\x20AI\x20-\x20Agentic\x20Coding\x20Assistant','1125614RhtPsr','Login\x20failed\x20or\x20timed\x20out','add-http\x20<name>\x20<url>','#\x20Project\x20Context\x0a\x0aDescribe\x20your\x20project\x20here.\x0a','Manage\x20MCP\x20servers','stdout','Removed\x20MCP\x20server:\x20','url','./utils/mcp-installer.js','.woozlit/context.md','add\x20<name>\x20<command>\x20[args...]','aliases','Added\x20rule:\x20',':\x20[stdio]\x20','Rules','N/A','Opening\x20browser\x20for\x20login...','2677955uCIXmV','47206bXBdNp','showLogo','Are\x20you\x20sure\x20you\x20want\x20to\x20remove\x20ALL\x20MCP\x20servers?','Login\x20with\x20your\x20Woozlit\x20account','error','MCP\x20server\x20\x27','config','remove\x20<name>','MCP\x20Servers',':\x20[HTTP]\x20','list','List\x20all\x20MCP\x20servers','Name:\x20','remove-all','stop','header','Waiting\x20for\x20authentication...','All\x20MCP\x20servers\x20removed','Install\x20an\x20MCP\x20server\x20from\x20GitHub\x20or\x20registry\x20(e.g.\x20\x27mcp-chrome-bridge\x27,\x20\x27owner/repo\x27)','clear','Remove\x20all\x20MCP\x20servers','install\x20<source>\x20[name]','Woozlit\x20already\x20initialized\x20in\x20this\x20directory','whoami','parse','Email:\x20','write','2245509RmXbnO','Ask\x20a\x20single\x20question','mcp','You\x20can\x20also\x20add\x20servers\x20via\x20mcp.json\x20in\x20your\x20project\x20directory','woozlit','Operation\x20cancelled','All\x20rules\x20cleared','streamable-http','Default\x20servers\x20will\x20be\x20restored\x20on\x20next\x20restart\x20unless\x20you\x20remove\x20them\x20again.','init','Model:\x20','add\x20<rule>','type','\x0aConfig\x20file:\x20','Show\x20current\x20user\x20info','command','885241uSavNW','Created\x20.woozlit/rules.md\x20and\x20.woozlit/context.md','delete-all','join','No\x20MCP\x20servers\x20configured','Added\x20stdio\x20MCP\x20server:\x20','842850JsQynn','Configure\x20CLI\x20settings','email','description','56SPacKd','Logged\x20out\x20successfully','@inquirer/prompts','dim','6eVyBJC','ask\x20<message>','Logged\x20in\x20as\x20','args','Add\x20a\x20stdio\x20MCP\x20server','#\x20Project\x20Rules\x0a\x0aAdd\x20your\x20project-specific\x20rules\x20here.\x0a','Already\x20logged\x20in\x20as\x20','warn','1.1.4','length','logout','.woozlit/rules.md','Select\x20AI\x20model','some','displayName','start','entries','Not\x20logged\x20in.\x20Use\x20\x27woozlit\x20login\x27\x20to\x20authenticate.','name','info'];a4_0x25a7=function(){return _0x521cfc;};return a4_0x25a7();}(function(_0x3fbb05,_0x323b03){const _0x516143=a4_0x1d21,_0x921eca=_0x3fbb05();while(!![]){try{const _0x315ba3=-parseInt(_0x516143(0xde))/0x1+-parseInt(_0x516143(0x139))/0x2+parseInt(_0x516143(0x10f))/0x3+-parseInt(_0x516143(0x12f))/0x4+-parseInt(_0x516143(0xdd))/0x5+-parseInt(_0x516143(0x117))/0x6*(parseInt(_0x516143(0x109))/0x7)+parseInt(_0x516143(0x113))/0x8*(parseInt(_0x516143(0xf9))/0x9);if(_0x315ba3===_0x323b03)break;else _0x921eca['push'](_0x921eca['shift']());}catch(_0x3a8b3f){_0x921eca['push'](_0x921eca['shift']());}}}(a4_0x25a7,0x4d58b));import{Command}from'commander';import{login,logout,isLoggedIn}from'./auth/login.js';import{startChat}from'./chat/agent.js';import{selectModel,getSelectedModel}from'./ui/select.js';import{listRules,addRule,clearRules}from'./tools/rules.js';function a4_0x1d21(_0x32e5d8,_0x1a4070){_0x32e5d8=_0x32e5d8-0xdb;const _0x25a7f8=a4_0x25a7();let _0x1d21bb=_0x25a7f8[_0x32e5d8];return _0x1d21bb;}import{getUser}from'./utils/storage.js';import{addMcpServer,addMcpHttpServer,removeMcpServer,clearMcpServers,getMcpServers,ensureDefaultServers,getConfigFilePath}from'./config/mcp.js';import{checkForUpdate}from'./utils/update-check.js';import*as a4_0x115d79 from'./ui/output.js';const program=new Command();program[a4_0x5dcee2(0x129)](a4_0x5dcee2(0xfd))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x138))[a4_0x5dcee2(0x12d)](a4_0x5dcee2(0x11f))[a4_0x5dcee2(0x12b)](async()=>{const _0x458503=a4_0x5dcee2;await checkForUpdate(),ensureDefaultServers(),a4_0x115d79[_0x458503(0xdf)]();if(!isLoggedIn()){a4_0x115d79[_0x458503(0x11e)](_0x458503(0x131)),a4_0x115d79['dim'](''),a4_0x115d79[_0x458503(0x12a)](_0x458503(0xdc));const _0x282da7=a4_0x115d79[_0x458503(0x12c)]('Waiting\x20for\x20authentication...');_0x282da7[_0x458503(0x126)]();const _0xfda7a8=await login();_0x282da7[_0x458503(0xec)]();if(!_0xfda7a8){a4_0x115d79[_0x458503(0xe2)](_0x458503(0x13a));return;}const _0xea0b3a=getUser();a4_0x115d79['success'](_0x458503(0x119)+(_0xea0b3a[_0x458503(0x125)]||_0xea0b3a[_0x458503(0x111)]));}await startChat();}),program['command']('login')[a4_0x5dcee2(0x112)](a4_0x5dcee2(0xe1))['action'](async()=>{const _0x4ede96=a4_0x5dcee2;if(isLoggedIn()){const _0x1ee6cc=getUser();a4_0x115d79[_0x4ede96(0x12a)](_0x4ede96(0x11d)+_0x1ee6cc['email']);return;}a4_0x115d79[_0x4ede96(0x12a)](_0x4ede96(0xdc));const _0x83dcd8=a4_0x115d79['createSpinner'](_0x4ede96(0xee));_0x83dcd8[_0x4ede96(0x126)]();const _0x5941fc=await login();_0x83dcd8[_0x4ede96(0xec)]();if(_0x5941fc){const _0x3818f0=getUser();a4_0x115d79[_0x4ede96(0x135)](_0x4ede96(0x119)+(_0x3818f0[_0x4ede96(0x125)]||_0x3818f0[_0x4ede96(0x111)]));}else a4_0x115d79[_0x4ede96(0xe2)](_0x4ede96(0x13a));}),program[a4_0x5dcee2(0x108)](a4_0x5dcee2(0x121))[a4_0x5dcee2(0x112)]('Logout\x20from\x20your\x20Woozlit\x20account')[a4_0x5dcee2(0x12b)](()=>{const _0x5110f4=a4_0x5dcee2;logout(),a4_0x115d79[_0x5110f4(0x135)](_0x5110f4(0x114));}),program[a4_0x5dcee2(0x108)](a4_0x5dcee2(0xf5))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x107))[a4_0x5dcee2(0x12b)](()=>{const _0x4411ab=a4_0x5dcee2;if(!isLoggedIn()){a4_0x115d79['warn'](_0x4411ab(0x128));return;}const _0x23e282=getUser();a4_0x115d79[_0x4411ab(0xed)](_0x4411ab(0x134)),a4_0x115d79[_0x4411ab(0x12a)](_0x4411ab(0xea)+(_0x23e282[_0x4411ab(0x125)]||_0x4411ab(0xdb))),a4_0x115d79[_0x4411ab(0x12a)](_0x4411ab(0xf7)+(_0x23e282[_0x4411ab(0x111)]||_0x4411ab(0xdb))),a4_0x115d79['info'](_0x4411ab(0x103)+getSelectedModel());}),program['command']('chat\x20[message]')[a4_0x5dcee2(0x112)]('Start\x20an\x20AI\x20chat\x20session')['action'](async _0x2afaab=>{const _0x3fa860=a4_0x5dcee2;a4_0x115d79[_0x3fa860(0xdf)]();if(!isLoggedIn()){a4_0x115d79[_0x3fa860(0x11e)](_0x3fa860(0x131)),a4_0x115d79[_0x3fa860(0x116)](''),a4_0x115d79[_0x3fa860(0x12a)](_0x3fa860(0xdc));const _0x53495d=a4_0x115d79[_0x3fa860(0x12c)](_0x3fa860(0xee));_0x53495d[_0x3fa860(0x126)]();const _0x72a93=await login();_0x53495d[_0x3fa860(0xec)]();if(!_0x72a93){a4_0x115d79['error']('Login\x20failed\x20or\x20timed\x20out');return;}const _0x4e1cc2=getUser();a4_0x115d79[_0x3fa860(0x135)](_0x3fa860(0x119)+(_0x4e1cc2[_0x3fa860(0x125)]||_0x4e1cc2[_0x3fa860(0x111)]));}await startChat(_0x2afaab);}),program['command'](a4_0x5dcee2(0x118))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0xfa))[a4_0x5dcee2(0x12b)](async _0x17702a=>{const _0x46964c=a4_0x5dcee2;a4_0x115d79[_0x46964c(0xdf)]();if(!isLoggedIn()){a4_0x115d79[_0x46964c(0x11e)](_0x46964c(0x131)),a4_0x115d79[_0x46964c(0x116)](''),a4_0x115d79[_0x46964c(0x12a)]('Opening\x20browser\x20for\x20login...');const _0x7280fd=a4_0x115d79[_0x46964c(0x12c)](_0x46964c(0xee));_0x7280fd[_0x46964c(0x126)]();const _0x3b9e66=await login();_0x7280fd['stop']();if(!_0x3b9e66){a4_0x115d79[_0x46964c(0xe2)]('Login\x20failed\x20or\x20timed\x20out');return;}const _0xf40442=getUser();a4_0x115d79[_0x46964c(0x135)](_0x46964c(0x119)+(_0xf40442[_0x46964c(0x125)]||_0xf40442[_0x46964c(0x111)]));}await startChat(_0x17702a);});const configCmd=program['command'](a4_0x5dcee2(0xe4))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x110));configCmd[a4_0x5dcee2(0x108)](a4_0x5dcee2(0x136))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x123))[a4_0x5dcee2(0x12b)](async()=>{const _0x48caf3=a4_0x5dcee2,_0x20a5d6=await selectModel();a4_0x115d79[_0x48caf3(0x135)](_0x48caf3(0x132)+_0x20a5d6);});const rulesCmd=program[a4_0x5dcee2(0x108)]('rules')['description']('Manage\x20AI\x20behavior\x20rules');rulesCmd[a4_0x5dcee2(0x108)](a4_0x5dcee2(0xe8))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x130))[a4_0x5dcee2(0x12b)](()=>{const _0x4f8826=a4_0x5dcee2,_0xdf58ee=listRules();if(_0xdf58ee[_0x4f8826(0x120)]===0x0){a4_0x115d79['info']('No\x20rules\x20defined');return;}a4_0x115d79[_0x4f8826(0xed)](_0x4f8826(0x147)),_0xdf58ee['forEach']((_0x1c22c5,_0x469221)=>{const _0x148f0d=_0x4f8826;process[_0x148f0d(0x13e)][_0x148f0d(0xf8)](_0x469221+0x1+'.\x20'+_0x1c22c5+'\x0a');});}),rulesCmd['command'](a4_0x5dcee2(0x104))[a4_0x5dcee2(0x112)]('Add\x20a\x20new\x20rule')[a4_0x5dcee2(0x12b)](_0x25ecaf=>{const _0x230764=a4_0x5dcee2;addRule(_0x25ecaf),a4_0x115d79['success'](_0x230764(0x145)+_0x25ecaf);})[a4_0x5dcee2(0x12b)](()=>{const _0x5bc3b4=a4_0x5dcee2;clearRules(),a4_0x115d79[_0x5bc3b4(0x135)](_0x5bc3b4(0xff));});const mcpCmd=program[a4_0x5dcee2(0x108)](a4_0x5dcee2(0xfb))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x13d));mcpCmd[a4_0x5dcee2(0x108)]('list')['description'](a4_0x5dcee2(0xe9))[a4_0x5dcee2(0x12b)](()=>{const _0x3774fe=a4_0x5dcee2,_0x5c5962=getMcpServers(),_0xd9f8fb=Object['keys'](_0x5c5962);if(_0xd9f8fb['length']===0x0){a4_0x115d79[_0x3774fe(0x12a)](_0x3774fe(0x10d)),a4_0x115d79[_0x3774fe(0x116)]('Config\x20file:\x20'+getConfigFilePath());return;}a4_0x115d79[_0x3774fe(0xed)](_0x3774fe(0xe6)),_0xd9f8fb['forEach'](_0x72c701=>{const _0x5a7901=_0x3774fe,_0x48c8c5=_0x5c5962[_0x72c701];_0x48c8c5[_0x5a7901(0x105)]===_0x5a7901(0x100)?a4_0x115d79[_0x5a7901(0x12a)]('-\x20'+_0x72c701+_0x5a7901(0xe7)+_0x48c8c5[_0x5a7901(0x140)]):a4_0x115d79['info']('-\x20'+_0x72c701+_0x5a7901(0x146)+_0x48c8c5[_0x5a7901(0x108)]+'\x20'+(_0x48c8c5[_0x5a7901(0x11a)]?.[_0x5a7901(0x10c)]('\x20')||''));}),a4_0x115d79[_0x3774fe(0x116)](_0x3774fe(0x106)+getConfigFilePath()),a4_0x115d79[_0x3774fe(0x116)](_0x3774fe(0xfc));}),mcpCmd[a4_0x5dcee2(0x108)](a4_0x5dcee2(0x143))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x11b))[a4_0x5dcee2(0x12b)]((_0x3350aa,_0x49738b,_0x2b7078)=>{const _0x3650ab=a4_0x5dcee2;addMcpServer(_0x3350aa,_0x49738b,_0x2b7078),a4_0x115d79[_0x3650ab(0x135)](_0x3650ab(0x10e)+_0x3350aa);}),mcpCmd[a4_0x5dcee2(0x108)](a4_0x5dcee2(0x13b))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x133))[a4_0x5dcee2(0x12b)]((_0x28f773,_0x311eab)=>{const _0x42506a=a4_0x5dcee2;addMcpHttpServer(_0x28f773,_0x311eab),a4_0x115d79[_0x42506a(0x135)](_0x42506a(0x12e)+_0x28f773),a4_0x115d79[_0x42506a(0x116)]('URL:\x20'+_0x311eab);}),mcpCmd[a4_0x5dcee2(0x108)](a4_0x5dcee2(0xf3))[a4_0x5dcee2(0x112)](a4_0x5dcee2(0xf0))['action'](async(_0x417651,_0x23c551)=>{const _0x411f54=a4_0x5dcee2,{installMcpServer:_0x423065}=await import(_0x411f54(0x141));await _0x423065(_0x417651,_0x23c551);}),mcpCmd['command'](a4_0x5dcee2(0xe5))[a4_0x5dcee2(0x144)](['delete','rm'])[a4_0x5dcee2(0x112)](a4_0x5dcee2(0x137))[a4_0x5dcee2(0x12b)](_0x166572=>{const _0x4a92e8=a4_0x5dcee2;removeMcpServer(_0x166572)?a4_0x115d79[_0x4a92e8(0x135)](_0x4a92e8(0x13f)+_0x166572):a4_0x115d79[_0x4a92e8(0xe2)](_0x4a92e8(0xe3)+_0x166572+'\x27\x20not\x20found');}),mcpCmd['command'](a4_0x5dcee2(0xeb))['aliases']([a4_0x5dcee2(0x10b),a4_0x5dcee2(0xf1)])[a4_0x5dcee2(0x112)](a4_0x5dcee2(0xf2))[a4_0x5dcee2(0x12b)](async()=>{const _0x44bac9=a4_0x5dcee2,{confirm:_0xc420e2}=await import(_0x44bac9(0x115)),_0x306e93=await _0xc420e2({'message':_0x44bac9(0xe0),'default':![]});_0x306e93?(clearMcpServers(),a4_0x115d79[_0x44bac9(0x135)](_0x44bac9(0xef)),a4_0x115d79[_0x44bac9(0x116)](_0x44bac9(0x101))):a4_0x115d79[_0x44bac9(0x12a)](_0x44bac9(0xfe));}),program[a4_0x5dcee2(0x108)](a4_0x5dcee2(0x102))[a4_0x5dcee2(0x112)]('Initialize\x20Woozlit\x20in\x20current\x20directory')['action'](()=>{const _0x47785a=a4_0x5dcee2,{createFile:_0x42df60,listDirectory:_0x1661fa}=require('./tools/file.js'),_0x2d3622=_0x1661fa('.'),_0x2b382d=_0x2d3622[_0x47785a(0x127)]?.[_0x47785a(0x124)](_0x17ba7e=>_0x17ba7e['name']==='.woozlit');if(_0x2b382d){a4_0x115d79['warn'](_0x47785a(0xf4));return;}_0x42df60(_0x47785a(0x122),_0x47785a(0x11c)),_0x42df60(_0x47785a(0x142),_0x47785a(0x13c)),a4_0x115d79[_0x47785a(0x135)]('Initialized\x20Woozlit\x20in\x20current\x20directory'),a4_0x115d79[_0x47785a(0x116)](_0x47785a(0x10a));}),program[a4_0x5dcee2(0xf6)]();
@@ -1 +1 @@
1
- const a5_0x37087b=a5_0x1dd1;(function(_0x1debf8,_0x32cc17){const _0x46626b=a5_0x1dd1,_0xd3b834=_0x1debf8();while(!![]){try{const _0x498f59=parseInt(_0x46626b(0x15b))/0x1+-parseInt(_0x46626b(0x162))/0x2*(-parseInt(_0x46626b(0x158))/0x3)+-parseInt(_0x46626b(0x15a))/0x4*(parseInt(_0x46626b(0x14c))/0x5)+parseInt(_0x46626b(0x15c))/0x6+-parseInt(_0x46626b(0x141))/0x7+parseInt(_0x46626b(0x160))/0x8*(-parseInt(_0x46626b(0x132))/0x9)+parseInt(_0x46626b(0x146))/0xa;if(_0x498f59===_0x32cc17)break;else _0xd3b834['push'](_0xd3b834['shift']());}catch(_0x2b604e){_0xd3b834['push'](_0xd3b834['shift']());}}}(a5_0x376c,0x4cd0d));import{Server}from'@modelcontextprotocol/sdk/server/index.js';import{StdioServerTransport}from'@modelcontextprotocol/sdk/server/stdio.js';import{CallToolRequestSchema,ListToolsRequestSchema}from'@modelcontextprotocol/sdk/types.js';function a5_0x376c(){const _0x29bae7=['5931JRGMzG','computer_key_tap','robotjs','Text\x20to\x20type','Type\x20a\x20string\x20of\x20text.','number','string','getScreenSize','Modifier\x20keys','getBuffer','base64','Tapped\x20key:\x20','Get\x20the\x20screen\x20resolution.','command','image/jpeg','4366817jqMAwj','Tap\x20a\x20single\x20key\x20with\x20optional\x20modifiers.','\x20button','params','width','1325360OrfIep','middle','connect','computer_mouse_click','computer_screen_size','resize','165XEcTCy','\x20(double)','bitmap','moveMouse','computer_screenshot','computer_mouse_move','text','boolean','Clicked\x20','computer_type','left','Key\x20to\x20tap\x20(e.g.\x20\x27enter\x27,\x20\x27a\x27,\x20\x27backspace\x27)','6vqWYzb','read','4244LlHvdW','335714mJbMsi','1830480DGHUAD','object','1.0.0','Move\x20the\x20mouse\x20cursor\x20to\x20specific\x20coordinates.','1016ayHqrr','setRequestHandler','283844NPUOGg','array','Typed:\x20\x22','key','Unknown\x20tool:\x20','height','toString','shift','Screenshot\x20taken.','Screen\x20size:\x20','alt'];a5_0x376c=function(){return _0x29bae7;};return a5_0x376c();}import{Jimp}from'jimp';import{createRequire}from'module';const require=createRequire(import.meta.url);function a5_0x1dd1(_0x591060,_0xf0ea20){_0x591060=_0x591060-0x12d;const _0x376c79=a5_0x376c();let _0x1dd1e7=_0x376c79[_0x591060];return _0x1dd1e7;}let robot,screenshot;try{robot=require(a5_0x37087b(0x134));}catch(a5_0x4ae746){}try{screenshot=require('screenshot-desktop');}catch(a5_0x46b7b7){}const AUTO=-0x1,MIME_JPEG=a5_0x37087b(0x140),server=new Server({'name':'computer-use','version':a5_0x37087b(0x15e)},{'capabilities':{'tools':{}}});server[a5_0x37087b(0x161)](ListToolsRequestSchema,async()=>{const _0xb2e9d=a5_0x37087b;return{'tools':[{'name':_0xb2e9d(0x150),'description':'Take\x20a\x20screenshot\x20of\x20the\x20primary\x20display.\x20Returns\x20base64\x20encoded\x20image.','inputSchema':{'type':_0xb2e9d(0x15d),'properties':{}}},{'name':_0xb2e9d(0x151),'description':_0xb2e9d(0x15f),'inputSchema':{'type':_0xb2e9d(0x15d),'properties':{'x':{'type':_0xb2e9d(0x137),'description':'X\x20coordinate'},'y':{'type':'number','description':'Y\x20coordinate'}},'required':['x','y']}},{'name':_0xb2e9d(0x149),'description':'Click\x20the\x20mouse\x20button.','inputSchema':{'type':'object','properties':{'button':{'type':_0xb2e9d(0x138),'enum':[_0xb2e9d(0x156),'right',_0xb2e9d(0x147)],'default':_0xb2e9d(0x156)},'double':{'type':_0xb2e9d(0x153),'default':![]}}}},{'name':'computer_type','description':_0xb2e9d(0x136),'inputSchema':{'type':_0xb2e9d(0x15d),'properties':{'text':{'type':_0xb2e9d(0x138),'description':_0xb2e9d(0x135)}},'required':[_0xb2e9d(0x152)]}},{'name':_0xb2e9d(0x133),'description':_0xb2e9d(0x142),'inputSchema':{'type':'object','properties':{'key':{'type':'string','description':_0xb2e9d(0x157)},'modifiers':{'type':_0xb2e9d(0x163),'items':{'type':_0xb2e9d(0x138),'enum':[_0xb2e9d(0x131),_0xb2e9d(0x13f),'control',_0xb2e9d(0x12e)]},'description':_0xb2e9d(0x13a)}},'required':[_0xb2e9d(0x165)]}},{'name':_0xb2e9d(0x14a),'description':_0xb2e9d(0x13e),'inputSchema':{'type':_0xb2e9d(0x15d),'properties':{}}}]};}),server[a5_0x37087b(0x161)](CallToolRequestSchema,async _0x2ab25a=>{const _0x39d0c9=a5_0x37087b,{name:_0x30eecf,arguments:_0x14b184}=_0x2ab25a[_0x39d0c9(0x144)];try{if(_0x30eecf===_0x39d0c9(0x150)){const _0x1292f0=await screenshot(),_0x3c2bc8=await Jimp[_0x39d0c9(0x159)](_0x1292f0);_0x3c2bc8[_0x39d0c9(0x14e)][_0x39d0c9(0x145)]>0x400&&_0x3c2bc8[_0x39d0c9(0x14b)]({'w':0x400});const _0x1f6c21=await _0x3c2bc8[_0x39d0c9(0x13b)](MIME_JPEG),_0x94ee5f=_0x1f6c21[_0x39d0c9(0x12d)](_0x39d0c9(0x13c));return{'content':[{'type':'text','text':_0x39d0c9(0x12f)},{'type':'image','data':_0x94ee5f,'mimeType':_0x39d0c9(0x140)}]};}if(_0x30eecf==='computer_mouse_move'){const {x:_0x4e6e11,y:_0x44152f}=_0x14b184;return robot[_0x39d0c9(0x14f)](_0x4e6e11,_0x44152f),{'content':[{'type':_0x39d0c9(0x152),'text':'Moved\x20mouse\x20to\x20'+_0x4e6e11+',\x20'+_0x44152f}]};}if(_0x30eecf===_0x39d0c9(0x149)){const {button:button='left',double:double=![]}=_0x14b184;return robot['mouseClick'](button,double),{'content':[{'type':'text','text':_0x39d0c9(0x154)+button+_0x39d0c9(0x143)+(double?_0x39d0c9(0x14d):'')}]};}if(_0x30eecf===_0x39d0c9(0x155)){const {text:_0x212e3c}=_0x14b184;return robot['typeString'](_0x212e3c),{'content':[{'type':_0x39d0c9(0x152),'text':_0x39d0c9(0x164)+_0x212e3c+'\x22'}]};}if(_0x30eecf==='computer_key_tap'){const {key:_0x5222c0,modifiers:_0x3cf8b5}=_0x14b184;return robot['keyTap'](_0x5222c0,_0x3cf8b5),{'content':[{'type':_0x39d0c9(0x152),'text':_0x39d0c9(0x13d)+_0x5222c0+'\x20'+(_0x3cf8b5?'with\x20'+_0x3cf8b5['join']('+'):'')}]};}if(_0x30eecf===_0x39d0c9(0x14a)){const _0xbbba69=robot[_0x39d0c9(0x139)]();return{'content':[{'type':_0x39d0c9(0x152),'text':_0x39d0c9(0x130)+_0xbbba69[_0x39d0c9(0x145)]+'x'+_0xbbba69[_0x39d0c9(0x167)]}]};}throw new Error(_0x39d0c9(0x166)+_0x30eecf);}catch(_0x168299){return{'content':[{'type':_0x39d0c9(0x152),'text':'Error:\x20'+_0x168299}],'isError':!![]};}});const transport=new StdioServerTransport();await server[a5_0x37087b(0x148)](transport);
1
+ function a5_0xb89f(_0x3ac1bf,_0x227bed){_0x3ac1bf=_0x3ac1bf-0x166;const _0x411be5=a5_0x411b();let _0xb89fc4=_0x411be5[_0x3ac1bf];return _0xb89fc4;}const a5_0x1fc0c4=a5_0xb89f;(function(_0x12d093,_0x2f4d96){const _0x494db0=a5_0xb89f,_0xee367e=_0x12d093();while(!![]){try{const _0x4a44b3=-parseInt(_0x494db0(0x179))/0x1*(parseInt(_0x494db0(0x198))/0x2)+-parseInt(_0x494db0(0x19b))/0x3*(-parseInt(_0x494db0(0x16a))/0x4)+-parseInt(_0x494db0(0x16e))/0x5+parseInt(_0x494db0(0x17d))/0x6*(-parseInt(_0x494db0(0x192))/0x7)+-parseInt(_0x494db0(0x175))/0x8*(-parseInt(_0x494db0(0x171))/0x9)+parseInt(_0x494db0(0x17f))/0xa+-parseInt(_0x494db0(0x173))/0xb*(-parseInt(_0x494db0(0x170))/0xc);if(_0x4a44b3===_0x2f4d96)break;else _0xee367e['push'](_0xee367e['shift']());}catch(_0x3377d1){_0xee367e['push'](_0xee367e['shift']());}}}(a5_0x411b,0xcd948));import{Server}from'@modelcontextprotocol/sdk/server/index.js';import{StdioServerTransport}from'@modelcontextprotocol/sdk/server/stdio.js';import{CallToolRequestSchema,ListToolsRequestSchema}from'@modelcontextprotocol/sdk/types.js';import{Jimp}from'jimp';import{createRequire}from'module';const require=createRequire(import.meta.url);let robot,screenshot;function a5_0x411b(){const _0x154814=['read','1.0.0','join','Modifier\x20keys','Moved\x20mouse\x20to\x20','resize','4Xemaqq','number','array','robotjs','6390885PLkKlJ','X\x20coordinate','10809276SWfinv','476964IYSLlJ','computer_screen_size','11saeFGU','Clicked\x20','56ZRaNBh','Tapped\x20key:\x20','command','control','1LqOeEU','setRequestHandler','params','getScreenSize','1304322iBzMfm','boolean','7355440wTjEKH','Move\x20the\x20mouse\x20cursor\x20to\x20specific\x20coordinates.','\x20button','Typed:\x20\x22','computer_type','base64','keyTap','Error:\x20','Click\x20the\x20mouse\x20button.','image','string','bitmap','text','height','connect','Take\x20a\x20screenshot\x20of\x20the\x20primary\x20display.\x20Returns\x20base64\x20encoded\x20image.','typeString','\x20(double)','key','7tXGwnq','image/jpeg','shift','toString','Key\x20to\x20tap\x20(e.g.\x20\x27enter\x27,\x20\x27a\x27,\x20\x27backspace\x27)','with\x20','514958yRaTdx','Type\x20a\x20string\x20of\x20text.','middle','1763430ebtqnx','computer_mouse_click','width','object','computer_key_tap'];a5_0x411b=function(){return _0x154814;};return a5_0x411b();}try{robot=require(a5_0x1fc0c4(0x16d));}catch(a5_0x28c19f){}try{screenshot=require('screenshot-desktop');}catch(a5_0x4a37ec){}const AUTO=-0x1,MIME_JPEG=a5_0x1fc0c4(0x193),server=new Server({'name':'computer-use','version':a5_0x1fc0c4(0x1a1)},{'capabilities':{'tools':{}}});server[a5_0x1fc0c4(0x17a)](ListToolsRequestSchema,async()=>{const _0x5836f7=a5_0x1fc0c4;return{'tools':[{'name':'computer_screenshot','description':_0x5836f7(0x18e),'inputSchema':{'type':_0x5836f7(0x19e),'properties':{}}},{'name':'computer_mouse_move','description':_0x5836f7(0x180),'inputSchema':{'type':_0x5836f7(0x19e),'properties':{'x':{'type':_0x5836f7(0x16b),'description':_0x5836f7(0x16f)},'y':{'type':'number','description':'Y\x20coordinate'}},'required':['x','y']}},{'name':'computer_mouse_click','description':_0x5836f7(0x187),'inputSchema':{'type':_0x5836f7(0x19e),'properties':{'button':{'type':_0x5836f7(0x189),'enum':['left','right',_0x5836f7(0x19a)],'default':'left'},'double':{'type':_0x5836f7(0x17e),'default':![]}}}},{'name':'computer_type','description':_0x5836f7(0x199),'inputSchema':{'type':_0x5836f7(0x19e),'properties':{'text':{'type':_0x5836f7(0x189),'description':'Text\x20to\x20type'}},'required':[_0x5836f7(0x18b)]}},{'name':'computer_key_tap','description':'Tap\x20a\x20single\x20key\x20with\x20optional\x20modifiers.','inputSchema':{'type':_0x5836f7(0x19e),'properties':{'key':{'type':_0x5836f7(0x189),'description':_0x5836f7(0x196)},'modifiers':{'type':_0x5836f7(0x16c),'items':{'type':_0x5836f7(0x189),'enum':['alt',_0x5836f7(0x177),_0x5836f7(0x178),_0x5836f7(0x194)]},'description':_0x5836f7(0x167)}},'required':[_0x5836f7(0x191)]}},{'name':'computer_screen_size','description':'Get\x20the\x20screen\x20resolution.','inputSchema':{'type':'object','properties':{}}}]};}),server[a5_0x1fc0c4(0x17a)](CallToolRequestSchema,async _0x58502f=>{const _0xed1b0a=a5_0x1fc0c4,{name:_0x50eadf,arguments:_0x1715a8}=_0x58502f[_0xed1b0a(0x17b)];try{if(_0x50eadf==='computer_screenshot'){const _0x38e2a9=await screenshot(),_0x3d95c2=await Jimp[_0xed1b0a(0x1a0)](_0x38e2a9);_0x3d95c2[_0xed1b0a(0x18a)][_0xed1b0a(0x19d)]>0x400&&_0x3d95c2[_0xed1b0a(0x169)]({'w':0x400});const _0x3ff1e6=await _0x3d95c2['getBuffer'](MIME_JPEG),_0x24dade=_0x3ff1e6[_0xed1b0a(0x195)](_0xed1b0a(0x184));return{'content':[{'type':_0xed1b0a(0x18b),'text':'Screenshot\x20taken.'},{'type':_0xed1b0a(0x188),'data':_0x24dade,'mimeType':_0xed1b0a(0x193)}]};}if(_0x50eadf==='computer_mouse_move'){const {x:_0x1ffb89,y:_0x591c73}=_0x1715a8;return robot['moveMouse'](_0x1ffb89,_0x591c73),{'content':[{'type':_0xed1b0a(0x18b),'text':_0xed1b0a(0x168)+_0x1ffb89+',\x20'+_0x591c73}]};}if(_0x50eadf===_0xed1b0a(0x19c)){const {button:button='left',double:double=![]}=_0x1715a8;return robot['mouseClick'](button,double),{'content':[{'type':'text','text':_0xed1b0a(0x174)+button+_0xed1b0a(0x181)+(double?_0xed1b0a(0x190):'')}]};}if(_0x50eadf===_0xed1b0a(0x183)){const {text:_0x250136}=_0x1715a8;return robot[_0xed1b0a(0x18f)](_0x250136),{'content':[{'type':_0xed1b0a(0x18b),'text':_0xed1b0a(0x182)+_0x250136+'\x22'}]};}if(_0x50eadf===_0xed1b0a(0x19f)){const {key:_0x35d34c,modifiers:_0x5ab7b6}=_0x1715a8;return robot[_0xed1b0a(0x185)](_0x35d34c,_0x5ab7b6),{'content':[{'type':'text','text':_0xed1b0a(0x176)+_0x35d34c+'\x20'+(_0x5ab7b6?_0xed1b0a(0x197)+_0x5ab7b6[_0xed1b0a(0x166)]('+'):'')}]};}if(_0x50eadf===_0xed1b0a(0x172)){const _0xcc1e13=robot[_0xed1b0a(0x17c)]();return{'content':[{'type':'text','text':'Screen\x20size:\x20'+_0xcc1e13[_0xed1b0a(0x19d)]+'x'+_0xcc1e13[_0xed1b0a(0x18c)]}]};}throw new Error('Unknown\x20tool:\x20'+_0x50eadf);}catch(_0x19c99c){return{'content':[{'type':'text','text':_0xed1b0a(0x186)+_0x19c99c}],'isError':!![]};}});const transport=new StdioServerTransport();await server[a5_0x1fc0c4(0x18d)](transport);
@@ -1 +1 @@
1
- (function(_0xd38a7b,_0x4e74f8){const _0x8394d2=a6_0xa37b,_0x28d713=_0xd38a7b();while(!![]){try{const _0x198f7d=parseInt(_0x8394d2(0x109))/0x1+parseInt(_0x8394d2(0xfe))/0x2*(-parseInt(_0x8394d2(0x10d))/0x3)+parseInt(_0x8394d2(0xff))/0x4+-parseInt(_0x8394d2(0xf8))/0x5+-parseInt(_0x8394d2(0xf9))/0x6+parseInt(_0x8394d2(0x106))/0x7+parseInt(_0x8394d2(0xfa))/0x8*(parseInt(_0x8394d2(0x104))/0x9);if(_0x198f7d===_0x4e74f8)break;else _0x28d713['push'](_0x28d713['shift']());}catch(_0x48ba3a){_0x28d713['push'](_0x28d713['shift']());}}}(a6_0x4bbe,0xd467a));import{spawn}from'child_process';export async function runCommand(_0x1062ef,_0x159972,_0xb129a3=![],_0x5cfa8e=0xbb8){return new Promise(_0x40a638=>{const _0xfea441=a6_0xa37b,_0x26f5fe=process[_0xfea441(0x102)]==='win32',_0x35afc2=_0x26f5fe?_0xfea441(0x107):_0xfea441(0x10c),_0x5d410b=_0x26f5fe?'/c':'-c',_0x4f412b=spawn(_0x35afc2,[_0x5d410b,_0x1062ef],{'cwd':process['cwd'](),'env':process['env'],'detached':_0xb129a3,'stdio':_0xfea441(0x10b)});let _0x8de3ab='',_0x280438='',_0x256e92=![];_0xb129a3&&setTimeout(()=>{const _0x4fbbc8=_0xfea441;if(!_0x256e92){_0x256e92=!![];if(_0x4f412b[_0x4fbbc8(0xfb)])_0x4f412b['unref']();_0x4f412b[_0x4fbbc8(0xfd)]?.[_0x4fbbc8(0x108)](_0x4fbbc8(0x10a)),_0x4f412b['stderr']?.[_0x4fbbc8(0x108)]('data'),_0x40a638({'success':!![],'stdout':_0x8de3ab+(_0x4fbbc8(0x105)+_0x5cfa8e+_0x4fbbc8(0x100)),'stderr':_0x280438,'exitCode':0x0});}},_0x5cfa8e),_0x4f412b['stdout']?.['on'](_0xfea441(0x10a),_0x90e43b=>{const _0x40b8d3=_0xfea441;if(_0x256e92)return;const _0x3bfa71=_0x90e43b[_0x40b8d3(0xfc)]();_0x8de3ab+=_0x3bfa71;if(_0x159972)_0x159972(_0x3bfa71);}),_0x4f412b[_0xfea441(0x101)]?.['on'](_0xfea441(0x10a),_0x2079a4=>{const _0x1ff334=_0xfea441;if(_0x256e92)return;const _0xc38714=_0x2079a4[_0x1ff334(0xfc)]();_0x280438+=_0xc38714;if(_0x159972)_0x159972(_0xc38714);}),_0x4f412b['on']('close',_0x360296=>{!_0x256e92&&(_0x256e92=!![],_0x40a638({'success':_0x360296===0x0,'stdout':_0x8de3ab,'stderr':_0x280438,'exitCode':_0x360296||0x0}));}),_0x4f412b['on']('error',_0x1a4a7a=>{const _0x175912=_0xfea441;!_0x256e92&&(_0x256e92=!![],_0x40a638({'success':![],'stdout':_0x8de3ab,'stderr':_0x1a4a7a[_0x175912(0x103)],'exitCode':0x1}));});});}function a6_0xa37b(_0x1a9e9d,_0x44272a){_0x1a9e9d=_0x1a9e9d-0xf8;const _0x4bbe3a=a6_0x4bbe();let _0xa37b98=_0x4bbe3a[_0x1a9e9d];return _0xa37b98;}function a6_0x4bbe(){const _0x29b995=['toString','stdout','2086LKfrMv','1163976aAToYT','ms...]','stderr','platform','message','9nphzLr','\x0a[Woozlit:\x20Command\x20continuing\x20in\x20background\x20after\x20','4179714ToUKeE','cmd.exe','removeAllListeners','1003975YimhvS','data','pipe','/bin/sh','2355fMlKXm','4381615cCzHCA','7505124DnxSzc','15390968sefKsE','unref'];a6_0x4bbe=function(){return _0x29b995;};return a6_0x4bbe();}
1
+ function a6_0x3785(){const _0xe2251b=['close','3281028PHbegz','8724228mzuIGH','platform','data','/bin/sh','ms...]','424456bCeunD','unref','win32','removeAllListeners','stderr','message','stdout','env','cwd','35455TkgRqc','\x0a[Woozlit:\x20Command\x20continuing\x20in\x20background\x20after\x20','1825530dbkDGr','63WJuNDO','11751552uotKfO','2423228UoiqKv','pipe','error','70jHYFcV','toString'];a6_0x3785=function(){return _0xe2251b;};return a6_0x3785();}(function(_0x576ae1,_0x492cd3){const _0x528c8d=a6_0x539d,_0x4d3a17=_0x576ae1();while(!![]){try{const _0xbfc1f7=-parseInt(_0x528c8d(0xbd))/0x1*(-parseInt(_0x528c8d(0xab))/0x2)+-parseInt(_0x528c8d(0xae))/0x3+parseInt(_0x528c8d(0xa8))/0x4+parseInt(_0x528c8d(0xa5))/0x5+parseInt(_0x528c8d(0xaf))/0x6+-parseInt(_0x528c8d(0xa6))/0x7*(parseInt(_0x528c8d(0xb4))/0x8)+-parseInt(_0x528c8d(0xa7))/0x9;if(_0xbfc1f7===_0x492cd3)break;else _0x4d3a17['push'](_0x4d3a17['shift']());}catch(_0x3be253){_0x4d3a17['push'](_0x4d3a17['shift']());}}}(a6_0x3785,0xc09df));function a6_0x539d(_0x3f9214,_0x226ec0){_0x3f9214=_0x3f9214-0xa4;const _0x378552=a6_0x3785();let _0x539dc7=_0x378552[_0x3f9214];return _0x539dc7;}import{spawn}from'child_process';export async function runCommand(_0x33fb0a,_0x4590b9,_0xa892c7=![],_0x417234=0xbb8){return new Promise(_0x16ada1=>{const _0x188ba7=a6_0x539d,_0x1f709e=process[_0x188ba7(0xb0)]===_0x188ba7(0xb6),_0x3e34fc=_0x1f709e?'cmd.exe':_0x188ba7(0xb2),_0x5c63a6=_0x1f709e?'/c':'-c',_0x399787=spawn(_0x3e34fc,[_0x5c63a6,_0x33fb0a],{'cwd':process[_0x188ba7(0xbc)](),'env':process[_0x188ba7(0xbb)],'detached':_0xa892c7,'stdio':_0x188ba7(0xa9)});let _0x3e6545='',_0x21a488='',_0x3c9edb=![];_0xa892c7&&setTimeout(()=>{const _0x58eab8=_0x188ba7;if(!_0x3c9edb){_0x3c9edb=!![];if(_0x399787[_0x58eab8(0xb5)])_0x399787['unref']();_0x399787[_0x58eab8(0xba)]?.[_0x58eab8(0xb7)](_0x58eab8(0xb1)),_0x399787[_0x58eab8(0xb8)]?.[_0x58eab8(0xb7)]('data'),_0x16ada1({'success':!![],'stdout':_0x3e6545+(_0x58eab8(0xa4)+_0x417234+_0x58eab8(0xb3)),'stderr':_0x21a488,'exitCode':0x0});}},_0x417234),_0x399787['stdout']?.['on'](_0x188ba7(0xb1),_0x2607c6=>{const _0x4ab435=_0x188ba7;if(_0x3c9edb)return;const _0x363a4f=_0x2607c6[_0x4ab435(0xac)]();_0x3e6545+=_0x363a4f;if(_0x4590b9)_0x4590b9(_0x363a4f);}),_0x399787['stderr']?.['on']('data',_0x40eac8=>{const _0x4e7bec=_0x188ba7;if(_0x3c9edb)return;const _0x5325ed=_0x40eac8[_0x4e7bec(0xac)]();_0x21a488+=_0x5325ed;if(_0x4590b9)_0x4590b9(_0x5325ed);}),_0x399787['on'](_0x188ba7(0xad),_0xbc8187=>{!_0x3c9edb&&(_0x3c9edb=!![],_0x16ada1({'success':_0xbc8187===0x0,'stdout':_0x3e6545,'stderr':_0x21a488,'exitCode':_0xbc8187||0x0}));}),_0x399787['on'](_0x188ba7(0xaa),_0x49c4bb=>{const _0x387e4c=_0x188ba7;!_0x3c9edb&&(_0x3c9edb=!![],_0x16ada1({'success':![],'stdout':_0x3e6545,'stderr':_0x49c4bb[_0x387e4c(0xb9)],'exitCode':0x1}));});});}
@@ -1 +1 @@
1
- (function(_0x2af50e,_0x2fc24c){const _0xfaa656=a7_0x3590,_0x1e1da3=_0x2af50e();while(!![]){try{const _0x2f43f5=-parseInt(_0xfaa656(0x1e6))/0x1+parseInt(_0xfaa656(0x1d8))/0x2+-parseInt(_0xfaa656(0x1df))/0x3*(parseInt(_0xfaa656(0x1be))/0x4)+parseInt(_0xfaa656(0x1c0))/0x5+-parseInt(_0xfaa656(0x1d9))/0x6*(-parseInt(_0xfaa656(0x1c9))/0x7)+parseInt(_0xfaa656(0x1b1))/0x8*(parseInt(_0xfaa656(0x1bf))/0x9)+parseInt(_0xfaa656(0x1e5))/0xa*(-parseInt(_0xfaa656(0x1d0))/0xb);if(_0x2f43f5===_0x2fc24c)break;else _0x1e1da3['push'](_0x1e1da3['shift']());}catch(_0x30d5c2){_0x1e1da3['push'](_0x1e1da3['shift']());}}}(a7_0x37fc,0xb58f7));import{readFileSync,writeFileSync,existsSync,readdirSync,statSync,mkdirSync}from'fs';import{dirname,resolve,relative}from'path';import{trackFileCreate,trackFileModify}from'./rollback.js';export function createFile(_0x40a0b8,_0x456cef){const _0x3a1df6=a7_0x3590;try{const _0x5c468d=resolve(process['cwd'](),_0x40a0b8),_0xeb6c8b=dirname(_0x5c468d);return!existsSync(_0xeb6c8b)&&mkdirSync(_0xeb6c8b,{'recursive':!![]}),writeFileSync(_0x5c468d,_0x456cef,_0x3a1df6(0x1c4)),trackFileCreate(_0x5c468d),{'success':!![],'message':_0x3a1df6(0x1ba)+_0x40a0b8};}catch(_0x3b9f2d){return{'success':![],'message':_0x3a1df6(0x1dc)+_0x40a0b8+':\x20'+_0x3b9f2d};}}export function readFile(_0x21c768){const _0x44415c=a7_0x3590;try{const _0x3d999f=resolve(process[_0x44415c(0x1b7)](),_0x21c768);if(!existsSync(_0x3d999f))return{'success':![],'message':_0x44415c(0x1e8)+_0x21c768};const _0x306a1a=['.png',_0x44415c(0x1c8),'.jpeg',_0x44415c(0x1e3),'.exe',_0x44415c(0x1b0),_0x44415c(0x1ea)],_0x2e230f=_0x3d999f[_0x44415c(0x1de)]('.')['pop']()?.['toLowerCase']();if(_0x2e230f&&_0x306a1a[_0x44415c(0x1c2)]('.'+_0x2e230f))return{'success':![],'message':_0x44415c(0x1d1)+_0x2e230f+_0x44415c(0x1c6)};const _0xce57c8=readFileSync(_0x3d999f,_0x44415c(0x1c4));return{'success':!![],'content':_0xce57c8,'message':_0x44415c(0x1ec)+_0x21c768};}catch(_0x3d9b49){return{'success':![],'message':'Failed\x20to\x20read\x20'+_0x21c768+':\x20'+_0x3d9b49};}}function a7_0x3590(_0x537f00,_0xe76ac8){_0x537f00=_0x537f00-0x1af;const _0x37fc1b=a7_0x37fc();let _0x3590fc=_0x37fc1b[_0x537f00];return _0x3590fc;}export function listDirectory(_0x233809='.'){const _0x2da78d=a7_0x3590;try{const _0x41e176=resolve(process['cwd'](),_0x233809);if(!existsSync(_0x41e176))return{'success':![],'message':_0x2da78d(0x1e4)+_0x233809};const _0xece78f=readdirSync(_0x41e176),_0x5cfd3d=_0xece78f['map'](_0x535262=>{const _0x31f225=_0x2da78d,_0x33eaab=resolve(_0x41e176,_0x535262),_0x160d6d=statSync(_0x33eaab);return{'name':_0x535262,'type':_0x160d6d[_0x31f225(0x1da)]()?_0x31f225(0x1b3):_0x31f225(0x1bc),'size':_0x160d6d[_0x31f225(0x1ca)]()?_0x160d6d['size']:undefined};});return{'success':!![],'entries':_0x5cfd3d,'message':'Listed\x20'+_0x5cfd3d['length']+_0x2da78d(0x1d5)+_0x233809};}catch(_0x42c3aa){return{'success':![],'message':_0x2da78d(0x1d7)+_0x233809+':\x20'+_0x42c3aa};}}export function editFile(_0x4a0cea,_0x31cdc4,_0x590e64){const _0x2cbec2=a7_0x3590;try{const _0x172b89=resolve(process['cwd'](),_0x4a0cea);if(!existsSync(_0x172b89))return{'success':![],'message':_0x2cbec2(0x1e8)+_0x4a0cea};const _0x14be0e=readFileSync(_0x172b89,_0x2cbec2(0x1c4));if(!_0x14be0e[_0x2cbec2(0x1c2)](_0x31cdc4))return{'success':![],'message':_0x2cbec2(0x1dd)+_0x4a0cea};trackFileModify(_0x172b89,_0x14be0e);const _0x475e78=_0x14be0e[_0x2cbec2(0x1e0)](_0x31cdc4,_0x590e64);return writeFileSync(_0x172b89,_0x475e78,_0x2cbec2(0x1c4)),{'success':!![],'message':'Edited\x20'+_0x4a0cea};}catch(_0x2dbf5c){return{'success':![],'message':_0x2cbec2(0x1af)+_0x4a0cea+':\x20'+_0x2dbf5c};}}function a7_0x37fc(){const _0x1c98d1=['[Binary\x20file\x20detected\x20(.','pop','\x20matches\x20for\x20\x22','.css','\x20items\x20in\x20','Found\x20','Failed\x20to\x20list\x20','1529660aKHglW','678dRFEty','isDirectory','Failed\x20to\x20search\x20directory:\x20','Failed\x20to\x20create\x20','Search\x20string\x20not\x20found\x20in\x20','split','321PldQKh','replace','filter','.tsx','.gif','Directory\x20not\x20found:\x20','9670jgUlYJ','354471XNMmtq','.go','File\x20not\x20found:\x20','\x20output\x20matches\x20in\x20','.bin','startsWith','Read\x20','Failed\x20to\x20edit\x20','.dll','886216IWGsJn','length','directory','.txt','.js','slice','cwd','node_modules','push','Created\x20','forEach','file','.md','11212CPXAnm','108PqNSrA','4087640IaSzmo','Failed\x20to\x20find\x20files:\x20','includes','.html','utf-8','test',').\x20Use\x20\x27computer_screenshot\x27\x20or\x20specific\x20tools\x20to\x20handle\x20this\x20file\x20type.\x20Direct\x20reading\x20is\x20not\x20supported.]','.rs','.jpg','84686zylVJj','isFile','trim','toLowerCase','match','substring','\x20files\x20matching\x20\x22','32769iozoxF'];a7_0x37fc=function(){return _0x1c98d1;};return a7_0x37fc();}export function searchFile(_0x2b4348,_0x39ff7f){const _0x5049b2=a7_0x3590;try{const _0x1a1826=resolve(process[_0x5049b2(0x1b7)](),_0x2b4348);if(!existsSync(_0x1a1826))return{'success':![],'message':'File\x20not\x20found:\x20'+_0x2b4348};const _0xca0617=readFileSync(_0x1a1826,_0x5049b2(0x1c4)),_0x38b6f7=new RegExp(_0x39ff7f,'g'),_0x4175f2=_0xca0617[_0x5049b2(0x1cd)](_0x38b6f7)||[],_0x144b53=_0xca0617[_0x5049b2(0x1de)]('\x0a'),_0xe04626=_0x144b53[_0x5049b2(0x1e1)]((_0x2e7347,_0xb8e4ed)=>new RegExp(_0x39ff7f)['test'](_0x2e7347));return{'success':!![],'matches':_0xe04626,'message':'Found\x20'+_0xe04626[_0x5049b2(0x1b2)]+_0x5049b2(0x1e9)+_0x2b4348};}catch(_0x243f40){return{'success':![],'message':'Failed\x20to\x20search\x20'+_0x2b4348+':\x20'+_0x243f40};}}export function findFiles(_0x47f0aa,_0x176d03){const _0xc51433=a7_0x3590;try{const _0x34ba54=resolve(process[_0xc51433(0x1b7)](),_0x47f0aa);if(!existsSync(_0x34ba54))return{'success':![],'message':_0xc51433(0x1e4)+_0x47f0aa};const _0x5df07f=[],_0x3e83fd=new RegExp(_0x176d03,'i');function _0x28618b(_0x23c8f3){const _0x74ef80=_0xc51433,_0x4a3cf3=readdirSync(_0x23c8f3);for(const _0x1efe73 of _0x4a3cf3){if(_0x1efe73[_0x74ef80(0x1eb)]('.')||_0x1efe73===_0x74ef80(0x1b8))continue;const _0x4f789e=resolve(_0x23c8f3,_0x1efe73),_0x5c510d=statSync(_0x4f789e);if(_0x5c510d[_0x74ef80(0x1da)]())_0x28618b(_0x4f789e);else _0x3e83fd[_0x74ef80(0x1c5)](_0x1efe73)&&_0x5df07f[_0x74ef80(0x1b9)](relative(_0x34ba54,_0x4f789e));}}return _0x28618b(_0x34ba54),{'success':!![],'files':_0x5df07f[_0xc51433(0x1b6)](0x0,0x32),'message':'Found\x20'+_0x5df07f[_0xc51433(0x1b2)]+_0xc51433(0x1cf)+_0x176d03+'\x22'};}catch(_0x390780){return{'success':![],'message':_0xc51433(0x1c1)+_0x390780};}}export function searchDirectory(_0x5897ab,_0x43615a){const _0x209147=a7_0x3590;try{const _0x2f613e=resolve(process['cwd'](),_0x5897ab);if(!existsSync(_0x2f613e))return{'success':![],'message':_0x209147(0x1e4)+_0x5897ab};const _0x451260=[],_0x115caf=new RegExp(_0x43615a,'i'),_0x9be89b=['.ts',_0x209147(0x1b5),_0x209147(0x1e2),'.jsx','.json',_0x209147(0x1bd),_0x209147(0x1b4),_0x209147(0x1d4),_0x209147(0x1c3),'.py',_0x209147(0x1e7),_0x209147(0x1c7)];function _0x5be9e8(_0x325f02){const _0x4131f3=_0x209147,_0x45fe1d=readdirSync(_0x325f02);for(const _0x37339c of _0x45fe1d){if(_0x37339c[_0x4131f3(0x1eb)]('.')||_0x37339c===_0x4131f3(0x1b8))continue;const _0x39ea7d=resolve(_0x325f02,_0x37339c),_0x56d709=statSync(_0x39ea7d);if(_0x56d709['isDirectory']())_0x5be9e8(_0x39ea7d);else{const _0x262714='.'+_0x37339c[_0x4131f3(0x1de)]('.')[_0x4131f3(0x1d2)]()?.[_0x4131f3(0x1cc)]();if(_0x9be89b[_0x4131f3(0x1c2)](_0x262714))try{const _0x407c0d=readFileSync(_0x39ea7d,_0x4131f3(0x1c4)),_0x4b1ebc=_0x407c0d['split']('\x0a');_0x4b1ebc[_0x4131f3(0x1bb)]((_0x3cb330,_0x395c5f)=>{const _0x2f58fb=_0x4131f3;_0x115caf[_0x2f58fb(0x1c5)](_0x3cb330)&&_0x451260[_0x2f58fb(0x1b9)]({'file':relative(_0x2f613e,_0x39ea7d),'line':_0x395c5f+0x1,'content':_0x3cb330[_0x2f58fb(0x1cb)]()[_0x2f58fb(0x1ce)](0x0,0x64)});});}catch{}}}}return _0x5be9e8(_0x2f613e),{'success':!![],'results':_0x451260[_0x209147(0x1b6)](0x0,0x1e),'message':_0x209147(0x1d6)+_0x451260[_0x209147(0x1b2)]+_0x209147(0x1d3)+_0x43615a+'\x22'};}catch(_0x3f09b6){return{'success':![],'message':_0x209147(0x1db)+_0x3f09b6};}}
1
+ (function(_0x4a50d0,_0x4e6521){const _0x3cd96f=a7_0x10e2,_0x25a4b4=_0x4a50d0();while(!![]){try{const _0x3b4541=parseInt(_0x3cd96f(0x141))/0x1*(parseInt(_0x3cd96f(0x167))/0x2)+-parseInt(_0x3cd96f(0x156))/0x3*(parseInt(_0x3cd96f(0x14f))/0x4)+parseInt(_0x3cd96f(0x14b))/0x5+-parseInt(_0x3cd96f(0x14d))/0x6*(parseInt(_0x3cd96f(0x147))/0x7)+parseInt(_0x3cd96f(0x152))/0x8+-parseInt(_0x3cd96f(0x169))/0x9*(parseInt(_0x3cd96f(0x158))/0xa)+-parseInt(_0x3cd96f(0x13b))/0xb;if(_0x3b4541===_0x4e6521)break;else _0x25a4b4['push'](_0x25a4b4['shift']());}catch(_0x39c148){_0x25a4b4['push'](_0x25a4b4['shift']());}}}(a7_0x148c,0x6df60));import{readFileSync,writeFileSync,existsSync,readdirSync,statSync,mkdirSync}from'fs';import{dirname,resolve,relative}from'path';import{trackFileCreate,trackFileModify}from'./rollback.js';export function createFile(_0x579807,_0x3c589d){const _0x44c0ca=a7_0x10e2;try{const _0x95a08f=resolve(process[_0x44c0ca(0x154)](),_0x579807),_0x3843ee=dirname(_0x95a08f);return!existsSync(_0x3843ee)&&mkdirSync(_0x3843ee,{'recursive':!![]}),writeFileSync(_0x95a08f,_0x3c589d,_0x44c0ca(0x150)),trackFileCreate(_0x95a08f),{'success':!![],'message':_0x44c0ca(0x131)+_0x579807};}catch(_0x5b472f){return{'success':![],'message':_0x44c0ca(0x16b)+_0x579807+':\x20'+_0x5b472f};}}function a7_0x148c(){const _0x437cfd=['includes','Created\x20','forEach','.py','Failed\x20to\x20edit\x20',').\x20Use\x20\x27computer_screenshot\x27\x20or\x20specific\x20tools\x20to\x20handle\x20this\x20file\x20type.\x20Direct\x20reading\x20is\x20not\x20supported.]','.go','isDirectory','Failed\x20to\x20read\x20','.js','[Binary\x20file\x20detected\x20(.','920348hMTxlC','Search\x20string\x20not\x20found\x20in\x20','length','.md','File\x20not\x20found:\x20','Edited\x20','61UgOKUB','\x20files\x20matching\x20\x22','\x20output\x20matches\x20in\x20','file','.tsx','slice','41027OvVcvr','.html','.txt','match','971930QpQBwz','toLowerCase','66lscHgx','.jpg','104DHbMRj','utf-8','.jpeg','5271736KXFoTP','node_modules','cwd','.ts','94497LyGvPH','substring','1572870gRnXbk','.bin','directory','Failed\x20to\x20list\x20','\x20items\x20in\x20','.jsx','isFile','split','.css','Failed\x20to\x20find\x20files:\x20','filter','push','Found\x20','Read\x20','trim','23654HoxMnX','test','9xiwrcZ','map','Failed\x20to\x20create\x20','.rs','pop','startsWith','Failed\x20to\x20search\x20directory:\x20','.gif','size','Listed\x20','Directory\x20not\x20found:\x20'];a7_0x148c=function(){return _0x437cfd;};return a7_0x148c();}export function readFile(_0x80750f){const _0x4c9060=a7_0x10e2;try{const _0x8da82a=resolve(process[_0x4c9060(0x154)](),_0x80750f);if(!existsSync(_0x8da82a))return{'success':![],'message':'File\x20not\x20found:\x20'+_0x80750f};const _0x309046=['.png',_0x4c9060(0x14e),_0x4c9060(0x151),_0x4c9060(0x12c),'.exe','.dll',_0x4c9060(0x159)],_0xef765c=_0x8da82a[_0x4c9060(0x15f)]('.')[_0x4c9060(0x16d)]()?.['toLowerCase']();if(_0xef765c&&_0x309046[_0x4c9060(0x130)]('.'+_0xef765c))return{'success':![],'message':_0x4c9060(0x13a)+_0xef765c+_0x4c9060(0x135)};const _0x5b448f=readFileSync(_0x8da82a,'utf-8');return{'success':!![],'content':_0x5b448f,'message':_0x4c9060(0x165)+_0x80750f};}catch(_0x558afd){return{'success':![],'message':_0x4c9060(0x138)+_0x80750f+':\x20'+_0x558afd};}}function a7_0x10e2(_0x224fe0,_0x452530){_0x224fe0=_0x224fe0-0x12c;const _0x148c46=a7_0x148c();let _0x10e29c=_0x148c46[_0x224fe0];return _0x10e29c;}export function listDirectory(_0x21898e='.'){const _0x32214f=a7_0x10e2;try{const _0x2d37b0=resolve(process[_0x32214f(0x154)](),_0x21898e);if(!existsSync(_0x2d37b0))return{'success':![],'message':_0x32214f(0x12f)+_0x21898e};const _0x204f1f=readdirSync(_0x2d37b0),_0x5ee292=_0x204f1f[_0x32214f(0x16a)](_0x1d97c1=>{const _0x39de54=_0x32214f,_0x3e9531=resolve(_0x2d37b0,_0x1d97c1),_0x1c4bf5=statSync(_0x3e9531);return{'name':_0x1d97c1,'type':_0x1c4bf5[_0x39de54(0x137)]()?_0x39de54(0x15a):_0x39de54(0x144),'size':_0x1c4bf5[_0x39de54(0x15e)]()?_0x1c4bf5[_0x39de54(0x12d)]:undefined};});return{'success':!![],'entries':_0x5ee292,'message':_0x32214f(0x12e)+_0x5ee292[_0x32214f(0x13d)]+_0x32214f(0x15c)+_0x21898e};}catch(_0x386147){return{'success':![],'message':_0x32214f(0x15b)+_0x21898e+':\x20'+_0x386147};}}export function editFile(_0x25951a,_0x4de302,_0x23ea0e){const _0x16f74c=a7_0x10e2;try{const _0x145205=resolve(process['cwd'](),_0x25951a);if(!existsSync(_0x145205))return{'success':![],'message':'File\x20not\x20found:\x20'+_0x25951a};const _0x3f3049=readFileSync(_0x145205,_0x16f74c(0x150));if(!_0x3f3049[_0x16f74c(0x130)](_0x4de302))return{'success':![],'message':_0x16f74c(0x13c)+_0x25951a};trackFileModify(_0x145205,_0x3f3049);const _0x2c4bf3=_0x3f3049['replace'](_0x4de302,_0x23ea0e);return writeFileSync(_0x145205,_0x2c4bf3,_0x16f74c(0x150)),{'success':!![],'message':_0x16f74c(0x140)+_0x25951a};}catch(_0x238f77){return{'success':![],'message':_0x16f74c(0x134)+_0x25951a+':\x20'+_0x238f77};}}export function searchFile(_0x4f1271,_0x4fdbb4){const _0x1fe86b=a7_0x10e2;try{const _0x1ea73e=resolve(process[_0x1fe86b(0x154)](),_0x4f1271);if(!existsSync(_0x1ea73e))return{'success':![],'message':_0x1fe86b(0x13f)+_0x4f1271};const _0x54c5b7=readFileSync(_0x1ea73e,_0x1fe86b(0x150)),_0x2972b6=new RegExp(_0x4fdbb4,'g'),_0x1009e1=_0x54c5b7[_0x1fe86b(0x14a)](_0x2972b6)||[],_0x254dae=_0x54c5b7[_0x1fe86b(0x15f)]('\x0a'),_0x56bd15=_0x254dae[_0x1fe86b(0x162)]((_0x385a9e,_0x525b86)=>new RegExp(_0x4fdbb4)[_0x1fe86b(0x168)](_0x385a9e));return{'success':!![],'matches':_0x56bd15,'message':_0x1fe86b(0x164)+_0x56bd15[_0x1fe86b(0x13d)]+_0x1fe86b(0x143)+_0x4f1271};}catch(_0x4d86d2){return{'success':![],'message':'Failed\x20to\x20search\x20'+_0x4f1271+':\x20'+_0x4d86d2};}}export function findFiles(_0x390c9d,_0x493836){const _0x35fb39=a7_0x10e2;try{const _0x12b469=resolve(process[_0x35fb39(0x154)](),_0x390c9d);if(!existsSync(_0x12b469))return{'success':![],'message':_0x35fb39(0x12f)+_0x390c9d};const _0x56d1de=[],_0x9b3379=new RegExp(_0x493836,'i');function _0x18e215(_0x384ca4){const _0x9ca101=_0x35fb39,_0x31eb78=readdirSync(_0x384ca4);for(const _0x28e824 of _0x31eb78){if(_0x28e824[_0x9ca101(0x16e)]('.')||_0x28e824===_0x9ca101(0x153))continue;const _0x15ba43=resolve(_0x384ca4,_0x28e824),_0x292f32=statSync(_0x15ba43);if(_0x292f32['isDirectory']())_0x18e215(_0x15ba43);else _0x9b3379[_0x9ca101(0x168)](_0x28e824)&&_0x56d1de[_0x9ca101(0x163)](relative(_0x12b469,_0x15ba43));}}return _0x18e215(_0x12b469),{'success':!![],'files':_0x56d1de[_0x35fb39(0x146)](0x0,0x32),'message':_0x35fb39(0x164)+_0x56d1de[_0x35fb39(0x13d)]+_0x35fb39(0x142)+_0x493836+'\x22'};}catch(_0x201c0c){return{'success':![],'message':_0x35fb39(0x161)+_0x201c0c};}}export function searchDirectory(_0x31e432,_0xdd4bcb){const _0x36d28a=a7_0x10e2;try{const _0x425a3d=resolve(process[_0x36d28a(0x154)](),_0x31e432);if(!existsSync(_0x425a3d))return{'success':![],'message':_0x36d28a(0x12f)+_0x31e432};const _0x19cd61=[],_0xc080df=new RegExp(_0xdd4bcb,'i'),_0x378e6d=[_0x36d28a(0x155),_0x36d28a(0x139),_0x36d28a(0x145),_0x36d28a(0x15d),'.json',_0x36d28a(0x13e),_0x36d28a(0x149),_0x36d28a(0x160),_0x36d28a(0x148),_0x36d28a(0x133),_0x36d28a(0x136),_0x36d28a(0x16c)];function _0x3f1510(_0x374401){const _0x186fa4=_0x36d28a,_0x37772b=readdirSync(_0x374401);for(const _0x506ac3 of _0x37772b){if(_0x506ac3[_0x186fa4(0x16e)]('.')||_0x506ac3===_0x186fa4(0x153))continue;const _0x349e45=resolve(_0x374401,_0x506ac3),_0x572f6e=statSync(_0x349e45);if(_0x572f6e[_0x186fa4(0x137)]())_0x3f1510(_0x349e45);else{const _0x5de9f7='.'+_0x506ac3['split']('.')[_0x186fa4(0x16d)]()?.[_0x186fa4(0x14c)]();if(_0x378e6d[_0x186fa4(0x130)](_0x5de9f7))try{const _0x419f5b=readFileSync(_0x349e45,_0x186fa4(0x150)),_0x443fde=_0x419f5b[_0x186fa4(0x15f)]('\x0a');_0x443fde[_0x186fa4(0x132)]((_0x6fa47e,_0x5e619a)=>{const _0x12de1a=_0x186fa4;_0xc080df['test'](_0x6fa47e)&&_0x19cd61[_0x12de1a(0x163)]({'file':relative(_0x425a3d,_0x349e45),'line':_0x5e619a+0x1,'content':_0x6fa47e[_0x12de1a(0x166)]()[_0x12de1a(0x157)](0x0,0x64)});});}catch{}}}}return _0x3f1510(_0x425a3d),{'success':!![],'results':_0x19cd61[_0x36d28a(0x146)](0x0,0x1e),'message':'Found\x20'+_0x19cd61['length']+'\x20matches\x20for\x20\x22'+_0xdd4bcb+'\x22'};}catch(_0x25d661){return{'success':![],'message':_0x36d28a(0x16f)+_0x25d661};}}
@@ -1 +1 @@
1
- function a8_0x1667(_0xd04ed,_0x580659){_0xd04ed=_0xd04ed-0x11f;var _0x9f4257=a8_0x9f42();var _0x1667e8=_0x9f4257[_0xd04ed];return _0x1667e8;}(function(_0x1fb229,_0x5ab460){var _0x4c7b8b=a8_0x1667,_0x38abd9=_0x1fb229();while(!![]){try{var _0xa6547d=parseInt(_0x4c7b8b(0x121))/0x1+-parseInt(_0x4c7b8b(0x128))/0x2*(-parseInt(_0x4c7b8b(0x125))/0x3)+-parseInt(_0x4c7b8b(0x11f))/0x4*(parseInt(_0x4c7b8b(0x123))/0x5)+parseInt(_0x4c7b8b(0x127))/0x6+parseInt(_0x4c7b8b(0x120))/0x7*(-parseInt(_0x4c7b8b(0x124))/0x8)+parseInt(_0x4c7b8b(0x126))/0x9+-parseInt(_0x4c7b8b(0x122))/0xa;if(_0xa6547d===_0x5ab460)break;else _0x38abd9['push'](_0x38abd9['shift']());}catch(_0x2c8849){_0x38abd9['push'](_0x38abd9['shift']());}}}(a8_0x9f42,0x50052));function a8_0x9f42(){var _0x5d360b=['875547LXOFQl','16002YTEeqi','314yKgiNp','87748veghqM','124285rMkFrP','652410dWZIJY','3689970UrhQls','145wmSLUW','8SHOuDj','11433qyvBWQ'];a8_0x9f42=function(){return _0x5d360b;};return a8_0x9f42();}export{createFile,readFile,listDirectory,editFile,searchFile,findFiles,searchDirectory}from'./file.js';export{runCommand}from'./command.js';export{listRules,addRule,clearRules,formatRulesForSystem}from'./rules.js';export{connectToMcpServers,getMcpTools,executeMcpTool,closeMcpClients}from'./mcp.js';export{trackFileCreate,trackFileModify,rollbackLast,rollbackAll,getChanges,clearChanges}from'./rollback.js';
1
+ function a8_0x5a2d(_0xa7728f,_0x2590e9){_0xa7728f=_0xa7728f-0x15e;var _0x1a72a5=a8_0x1a72();var _0x5a2d76=_0x1a72a5[_0xa7728f];return _0x5a2d76;}(function(_0x581733,_0x141b08){var _0x56074c=a8_0x5a2d,_0x16b83b=_0x581733();while(!![]){try{var _0x44b93f=parseInt(_0x56074c(0x160))/0x1*(parseInt(_0x56074c(0x164))/0x2)+-parseInt(_0x56074c(0x165))/0x3+-parseInt(_0x56074c(0x167))/0x4+-parseInt(_0x56074c(0x163))/0x5*(parseInt(_0x56074c(0x161))/0x6)+parseInt(_0x56074c(0x15f))/0x7+parseInt(_0x56074c(0x15e))/0x8*(-parseInt(_0x56074c(0x162))/0x9)+parseInt(_0x56074c(0x166))/0xa;if(_0x44b93f===_0x141b08)break;else _0x16b83b['push'](_0x16b83b['shift']());}catch(_0x34fbd1){_0x16b83b['push'](_0x16b83b['shift']());}}}(a8_0x1a72,0x99ed5));export{createFile,readFile,listDirectory,editFile,searchFile,findFiles,searchDirectory}from'./file.js';export{runCommand}from'./command.js';export{listRules,addRule,clearRules,formatRulesForSystem}from'./rules.js';function a8_0x1a72(){var _0x11c093=['28565780hNTssa','4847584LFcohl','5313816OGrenb','5667221RuTeOP','14366esJsWn','120elElOX','9zazKer','160105RGSUAg','28hiPHNC','2160831RJfbLR'];a8_0x1a72=function(){return _0x11c093;};return a8_0x1a72();}export{connectToMcpServers,getMcpTools,executeMcpTool,closeMcpClients}from'./mcp.js';export{trackFileCreate,trackFileModify,rollbackLast,rollbackAll,getChanges,clearChanges}from'./rollback.js';
package/dist/tools/mcp.js CHANGED
@@ -1 +1 @@
1
- (function(_0x1dea4f,_0x30369f){const _0x2c2552=a9_0x24c2,_0x1e326a=_0x1dea4f();while(!![]){try{const _0x13e8a7=-parseInt(_0x2c2552(0x9a))/0x1+-parseInt(_0x2c2552(0x99))/0x2*(parseInt(_0x2c2552(0x80))/0x3)+parseInt(_0x2c2552(0x93))/0x4+parseInt(_0x2c2552(0x91))/0x5*(parseInt(_0x2c2552(0x7c))/0x6)+parseInt(_0x2c2552(0x92))/0x7+-parseInt(_0x2c2552(0x7f))/0x8*(parseInt(_0x2c2552(0x8f))/0x9)+parseInt(_0x2c2552(0x9c))/0xa;if(_0x13e8a7===_0x30369f)break;else _0x1e326a['push'](_0x1e326a['shift']());}catch(_0x48d18f){_0x1e326a['push'](_0x1e326a['shift']());}}}(a9_0x20e9,0xdbcfb));import{Client}from'@modelcontextprotocol/sdk/client/index.js';import{StdioClientTransport}from'@modelcontextprotocol/sdk/client/stdio.js';import{StreamableHTTPClientTransport}from'@modelcontextprotocol/sdk/client/streamableHttp.js';import{getMcpServers}from'../config/mcp.js';import*as a9_0x192a6d from'../ui/output.js';const clients=new Map();function a9_0x24c2(_0x20c55c,_0x18a783){_0x20c55c=_0x20c55c-0x7b;const _0x20e932=a9_0x20e9();let _0x24c26e=_0x20e932[_0x20c55c];return _0x24c26e;}async function connectStdioServer(_0x44975a,_0x4d8bdd){const _0x1105de=a9_0x24c2;try{const _0x346c61={...process[_0x1105de(0x9d)],..._0x4d8bdd[_0x1105de(0x9d)]};Object['keys'](_0x346c61)[_0x1105de(0x8b)](_0x588328=>_0x346c61[_0x588328]===undefined&&delete _0x346c61[_0x588328]);const _0x20174d=new StdioClientTransport({'command':_0x4d8bdd[_0x1105de(0x96)],'args':_0x4d8bdd['args'],'env':_0x346c61,'stderr':_0x1105de(0x8e)}),_0x124078=new Client({'name':_0x1105de(0x9e),'version':_0x1105de(0x90)},{'capabilities':{}});return await _0x124078['connect'](_0x20174d),_0x124078;}catch(_0x5909d0){return a9_0x192a6d['error'](_0x1105de(0xa2)+_0x44975a+_0x1105de(0x8c)+_0x5909d0),null;}}async function connectHttpServer(_0x50607e,_0x4a3c00){const _0x1e118c=a9_0x24c2;try{const _0x396305=new StreamableHTTPClientTransport(new URL(_0x4a3c00)),_0x2db072=new Client({'name':'woozlit-cli','version':_0x1e118c(0x90)},{'capabilities':{}});return await _0x2db072[_0x1e118c(0xa1)](_0x396305),_0x2db072;}catch(_0x524b2e){return a9_0x192a6d[_0x1e118c(0x83)]('Failed\x20to\x20connect\x20to\x20HTTP\x20MCP\x20server\x20\x27'+_0x50607e+_0x1e118c(0x8c)+_0x524b2e),null;}}export async function connectToMcpServers(){const _0x5f2438=a9_0x24c2,_0x5fc8ca=getMcpServers(),_0x131668=Object[_0x5f2438(0xa5)](_0x5fc8ca);if(_0x131668[_0x5f2438(0x81)]===0x0)return;a9_0x192a6d[_0x5f2438(0x7e)](_0x5f2438(0x82));for(const _0x5380f4 of _0x131668){if(clients[_0x5f2438(0x8a)](_0x5380f4))continue;const _0x10e7d8=_0x5fc8ca[_0x5380f4];let _0x5a0679=null;_0x10e7d8[_0x5f2438(0x97)]==='streamable-http'?_0x5a0679=await connectHttpServer(_0x5380f4,_0x10e7d8[_0x5f2438(0x94)]):_0x5a0679=await connectStdioServer(_0x5380f4,_0x10e7d8),_0x5a0679&&clients[_0x5f2438(0x95)](_0x5380f4,_0x5a0679);}}export async function getMcpTools(){const _0x2d7f41=a9_0x24c2,_0x566c35=[];for(const [_0xf5e7fb,_0x5b35ce]of clients[_0x2d7f41(0xa3)]()){try{const _0x5dbc02=await _0x5b35ce[_0x2d7f41(0x84)](),_0x1896d8=_0x5dbc02[_0x2d7f41(0x98)][_0x2d7f41(0x7b)](_0x3b423e=>({'name':_0x3b423e['name'],'description':_0x3b423e[_0x2d7f41(0x89)],'inputSchema':_0x3b423e[_0x2d7f41(0x7d)],'serverName':_0xf5e7fb}));_0x566c35[_0x2d7f41(0x9f)](..._0x1896d8);}catch(_0x2aa88c){a9_0x192a6d[_0x2d7f41(0x83)](_0x2d7f41(0xa0)+_0xf5e7fb+'\x27:\x20'+_0x2aa88c);}}return _0x566c35;}export async function executeMcpTool(_0x15583f,_0x15364d,_0x42bfe3){const _0xed93e5=a9_0x24c2,_0x49ea4c=clients[_0xed93e5(0x87)](_0x15583f);if(!_0x49ea4c)throw new Error('MCP\x20server\x20\x27'+_0x15583f+_0xed93e5(0x85));try{const _0x31d6e5=await _0x49ea4c[_0xed93e5(0x88)]({'name':_0x15364d,'arguments':_0x42bfe3});return _0x31d6e5;}catch(_0x4ddde8){throw new Error(_0xed93e5(0xa4)+_0x4ddde8);}}export function closeMcpClients(){const _0x462b3c=a9_0x24c2;for(const _0x46a782 of clients[_0x462b3c(0x86)]()){try{_0x46a782[_0x462b3c(0x8d)]();}catch(_0x33de98){}}clients[_0x462b3c(0x9b)]();}function a9_0x20e9(){const _0x1344f6=['MCP\x20tool\x20execution\x20failed:\x20','keys','map','2076882oqCKqH','inputSchema','info','113512qQrbvv','50985edVGgC','length','Connecting\x20to\x20MCP\x20servers...','error','listTools','\x27\x20not\x20connected','values','get','callTool','description','has','forEach','\x27:\x20','close','pipe','477KmDend','1.0.0','15bUpyVw','195489cSJQgP','5936492nRmbAR','url','set','command','type','tools','154dBAymN','28793KBGHqb','clear','4392810YjTRTF','env','woozlit-cli','push','Failed\x20to\x20list\x20tools\x20for\x20\x27','connect','Failed\x20to\x20connect\x20to\x20stdio\x20MCP\x20server\x20\x27','entries'];a9_0x20e9=function(){return _0x1344f6;};return a9_0x20e9();}
1
+ (function(_0x19fd4e,_0x59540b){const _0x48aa22=a9_0x5296,_0x1b069a=_0x19fd4e();while(!![]){try{const _0xc4526f=-parseInt(_0x48aa22(0x198))/0x1+parseInt(_0x48aa22(0x19c))/0x2+parseInt(_0x48aa22(0x19b))/0x3+-parseInt(_0x48aa22(0x1af))/0x4*(-parseInt(_0x48aa22(0x1ab))/0x5)+-parseInt(_0x48aa22(0x195))/0x6+parseInt(_0x48aa22(0x1a1))/0x7*(-parseInt(_0x48aa22(0x1ae))/0x8)+parseInt(_0x48aa22(0x1a3))/0x9;if(_0xc4526f===_0x59540b)break;else _0x1b069a['push'](_0x1b069a['shift']());}catch(_0xcf5d0f){_0x1b069a['push'](_0x1b069a['shift']());}}}(a9_0x4183,0x5f819));import{Client}from'@modelcontextprotocol/sdk/client/index.js';import{StdioClientTransport}from'@modelcontextprotocol/sdk/client/stdio.js';import{StreamableHTTPClientTransport}from'@modelcontextprotocol/sdk/client/streamableHttp.js';import{getMcpServers}from'../config/mcp.js';function a9_0x5296(_0x10ec58,_0x578ab1){_0x10ec58=_0x10ec58-0x18d;const _0x41839f=a9_0x4183();let _0x529610=_0x41839f[_0x10ec58];return _0x529610;}import*as a9_0x380fa7 from'../ui/output.js';const clients=new Map();async function connectStdioServer(_0x58f94c,_0x31dc7f){const _0x3f01ca=a9_0x5296;try{const _0x204720={...process[_0x3f01ca(0x1a5)],..._0x31dc7f[_0x3f01ca(0x1a5)]};Object[_0x3f01ca(0x1a7)](_0x204720)[_0x3f01ca(0x1a4)](_0x23163a=>_0x204720[_0x23163a]===undefined&&delete _0x204720[_0x23163a]);const _0x46073e=new StdioClientTransport({'command':_0x31dc7f[_0x3f01ca(0x193)],'args':_0x31dc7f[_0x3f01ca(0x18e)],'env':_0x204720,'stderr':'pipe'}),_0x2797b2=new Client({'name':_0x3f01ca(0x1a0),'version':_0x3f01ca(0x1ac)},{'capabilities':{}});return await _0x2797b2[_0x3f01ca(0x19a)](_0x46073e),_0x2797b2;}catch(_0x3ec5fe){return a9_0x380fa7['error']('Failed\x20to\x20connect\x20to\x20stdio\x20MCP\x20server\x20\x27'+_0x58f94c+_0x3f01ca(0x196)+_0x3ec5fe),null;}}async function connectHttpServer(_0x5cee23,_0x5c70b3){const _0x545053=a9_0x5296;try{const _0x2e6679=new StreamableHTTPClientTransport(new URL(_0x5c70b3)),_0x2edb84=new Client({'name':_0x545053(0x1a0),'version':_0x545053(0x1ac)},{'capabilities':{}});return await _0x2edb84[_0x545053(0x19a)](_0x2e6679),_0x2edb84;}catch(_0xe40047){return a9_0x380fa7[_0x545053(0x19d)](_0x545053(0x190)+_0x5cee23+_0x545053(0x196)+_0xe40047),null;}}export async function connectToMcpServers(){const _0x13999f=a9_0x5296,_0x189121=getMcpServers(),_0x2b922f=Object['keys'](_0x189121);if(_0x2b922f['length']===0x0)return;a9_0x380fa7[_0x13999f(0x199)]('Connecting\x20to\x20MCP\x20servers...');for(const _0x51dae0 of _0x2b922f){if(clients[_0x13999f(0x1a8)](_0x51dae0))continue;const _0x43aa2f=_0x189121[_0x51dae0];let _0xf0b828=null;_0x43aa2f[_0x13999f(0x197)]===_0x13999f(0x18d)?_0xf0b828=await connectHttpServer(_0x51dae0,_0x43aa2f['url']):_0xf0b828=await connectStdioServer(_0x51dae0,_0x43aa2f),_0xf0b828&&clients[_0x13999f(0x192)](_0x51dae0,_0xf0b828);}}export async function getMcpTools(){const _0x4eab4e=a9_0x5296,_0xe9925a=[];for(const [_0x45b481,_0x4ccae7]of clients['entries']()){try{const _0xc76849=await _0x4ccae7['listTools'](),_0x1560fd=_0xc76849[_0x4eab4e(0x1b0)][_0x4eab4e(0x19f)](_0x45899d=>({'name':_0x45899d[_0x4eab4e(0x1ad)],'description':_0x45899d['description'],'inputSchema':_0x45899d[_0x4eab4e(0x1a9)],'serverName':_0x45b481}));_0xe9925a[_0x4eab4e(0x194)](..._0x1560fd);}catch(_0x477496){a9_0x380fa7[_0x4eab4e(0x19d)](_0x4eab4e(0x191)+_0x45b481+_0x4eab4e(0x196)+_0x477496);}}return _0xe9925a;}export async function executeMcpTool(_0x3341a6,_0xe60be0,_0x4fe188){const _0x4b13c8=a9_0x5296,_0x75bb40=clients[_0x4b13c8(0x1a6)](_0x3341a6);if(!_0x75bb40)throw new Error('MCP\x20server\x20\x27'+_0x3341a6+_0x4b13c8(0x1a2));try{const _0x23a29e=await _0x75bb40['callTool']({'name':_0xe60be0,'arguments':_0x4fe188});return _0x23a29e;}catch(_0x53a6cb){throw new Error('MCP\x20tool\x20execution\x20failed:\x20'+_0x53a6cb);}}export function closeMcpClients(){const _0x24b5d1=a9_0x5296;for(const _0x584297 of clients[_0x24b5d1(0x1aa)]()){try{_0x584297[_0x24b5d1(0x19e)]();}catch(_0x4e44a6){}}clients[_0x24b5d1(0x18f)]();}function a9_0x4183(){const _0x341a40=['tools','streamable-http','args','clear','Failed\x20to\x20connect\x20to\x20HTTP\x20MCP\x20server\x20\x27','Failed\x20to\x20list\x20tools\x20for\x20\x27','set','command','push','3756066ZSshFv','\x27:\x20','type','75957mthSwM','info','connect','1149597wFtZav','148748XHOnYj','error','close','map','woozlit-cli','7ACcDMc','\x27\x20not\x20connected','2909466vFgrgm','forEach','env','get','keys','has','inputSchema','values','1197360tOLRIL','1.0.0','name','1333040OWXVlu','8nGZZGA'];a9_0x4183=function(){return _0x341a40;};return a9_0x4183();}
@@ -1 +1 @@
1
- (function(_0x2cc1ad,_0x577288){const _0x4511fa=a10_0x454d,_0x55ef74=_0x2cc1ad();while(!![]){try{const _0x52026e=-parseInt(_0x4511fa(0x1c5))/0x1+parseInt(_0x4511fa(0x1cb))/0x2+parseInt(_0x4511fa(0x1c9))/0x3+-parseInt(_0x4511fa(0x1cd))/0x4*(-parseInt(_0x4511fa(0x1d7))/0x5)+parseInt(_0x4511fa(0x1db))/0x6+-parseInt(_0x4511fa(0x1c1))/0x7+-parseInt(_0x4511fa(0x1d4))/0x8;if(_0x52026e===_0x577288)break;else _0x55ef74['push'](_0x55ef74['shift']());}catch(_0x88faf2){_0x55ef74['push'](_0x55ef74['shift']());}}}(a10_0x473f,0x80797));import*as a10_0x45ea1b from'fs';import*as a10_0x57edea from'path';const changes=[];export function trackFileCreate(_0x8c85b6){const _0x56d862=a10_0x454d;changes[_0x56d862(0x1c2)]({'path':a10_0x57edea[_0x56d862(0x1c6)](_0x8c85b6),'type':_0x56d862(0x1ce),'previousContent':null,'timestamp':Date[_0x56d862(0x1d2)]()});}export function trackFileModify(_0x5ea0f7,_0xad84e2){const _0x1c2e4e=a10_0x454d;changes[_0x1c2e4e(0x1c2)]({'path':a10_0x57edea[_0x1c2e4e(0x1c6)](_0x5ea0f7),'type':_0x1c2e4e(0x1d8),'previousContent':_0xad84e2,'timestamp':Date[_0x1c2e4e(0x1d2)]()});}export function trackFileDelete(_0x56fb63,_0x4b81ce){const _0x218846=a10_0x454d;changes['push']({'path':a10_0x57edea[_0x218846(0x1c6)](_0x56fb63),'type':'delete','previousContent':_0x4b81ce,'timestamp':Date[_0x218846(0x1d2)]()});}export function getChanges(){return[...changes];}function a10_0x473f(){const _0x1e1d75=['now','Rollback\x20failed:\x20','7251896ApKluU','unlinkSync','type','825UXqNzN','modify','path','Deleted:\x20','5596806ExAgOQ','5090715nffDDV','push','Restored:\x20','length','676293yHBgDK','resolve','previousContent','writeFileSync','1921002lMAPGq','No\x20changes\x20to\x20rollback','570002GuAfoF','pop','23712xoanMw','create','delete','existsSync','Unknown\x20change\x20type'];a10_0x473f=function(){return _0x1e1d75;};return a10_0x473f();}export function rollbackLast(){const _0x33958a=a10_0x454d;if(changes['length']===0x0)return{'success':![],'message':_0x33958a(0x1ca)};const _0x488cf3=changes[_0x33958a(0x1cc)]();try{switch(_0x488cf3[_0x33958a(0x1d6)]){case _0x33958a(0x1ce):a10_0x45ea1b[_0x33958a(0x1d0)](_0x488cf3[_0x33958a(0x1d9)])&&a10_0x45ea1b[_0x33958a(0x1d5)](_0x488cf3['path']);return{'success':!![],'message':_0x33958a(0x1da)+_0x488cf3[_0x33958a(0x1d9)]};case _0x33958a(0x1d8):_0x488cf3[_0x33958a(0x1c7)]!==null&&a10_0x45ea1b[_0x33958a(0x1c8)](_0x488cf3[_0x33958a(0x1d9)],_0x488cf3[_0x33958a(0x1c7)]);return{'success':!![],'message':_0x33958a(0x1c3)+_0x488cf3[_0x33958a(0x1d9)]};case _0x33958a(0x1cf):_0x488cf3[_0x33958a(0x1c7)]!==null&&a10_0x45ea1b[_0x33958a(0x1c8)](_0x488cf3[_0x33958a(0x1d9)],_0x488cf3[_0x33958a(0x1c7)]);return{'success':!![],'message':'Restored:\x20'+_0x488cf3[_0x33958a(0x1d9)]};default:return{'success':![],'message':_0x33958a(0x1d1)};}}catch(_0x1efec2){return{'success':![],'message':_0x33958a(0x1d3)+_0x1efec2};}}function a10_0x454d(_0x19c94b,_0x18ec2f){_0x19c94b=_0x19c94b-0x1c1;const _0x473f3b=a10_0x473f();let _0x454da0=_0x473f3b[_0x19c94b];return _0x454da0;}export function rollbackAll(){const _0x3e4443=a10_0x454d,_0x173c4d=[];let _0x522c96=0x0;while(changes[_0x3e4443(0x1c4)]>0x0){const _0x16be24=rollbackLast();_0x16be24['success']&&(_0x522c96++,_0x173c4d['push'](_0x16be24['message']));}return{'success':_0x522c96>0x0,'count':_0x522c96,'messages':_0x173c4d};}export function clearChanges(){const _0xc66c16=a10_0x454d;changes[_0xc66c16(0x1c4)]=0x0;}
1
+ (function(_0x354965,_0x8d4c8a){const _0x26735d=a10_0x23c9,_0x386132=_0x354965();while(!![]){try{const _0x294d8d=-parseInt(_0x26735d(0x186))/0x1*(-parseInt(_0x26735d(0x189))/0x2)+-parseInt(_0x26735d(0x18d))/0x3*(parseInt(_0x26735d(0x182))/0x4)+-parseInt(_0x26735d(0x18a))/0x5+parseInt(_0x26735d(0x18f))/0x6*(parseInt(_0x26735d(0x17d))/0x7)+parseInt(_0x26735d(0x180))/0x8*(parseInt(_0x26735d(0x181))/0x9)+-parseInt(_0x26735d(0x191))/0xa+parseInt(_0x26735d(0x188))/0xb;if(_0x294d8d===_0x8d4c8a)break;else _0x386132['push'](_0x386132['shift']());}catch(_0x30ae9e){_0x386132['push'](_0x386132['shift']());}}}(a10_0x5215,0xdb07d));import*as a10_0x52c652 from'fs';import*as a10_0x1a166d from'path';const changes=[];export function trackFileCreate(_0x123595){const _0x536a21=a10_0x23c9;changes[_0x536a21(0x198)]({'path':a10_0x1a166d[_0x536a21(0x18e)](_0x123595),'type':'create','previousContent':null,'timestamp':Date[_0x536a21(0x17e)]()});}export function trackFileModify(_0x5d3901,_0x11276d){const _0x14350d=a10_0x23c9;changes[_0x14350d(0x198)]({'path':a10_0x1a166d['resolve'](_0x5d3901),'type':_0x14350d(0x18b),'previousContent':_0x11276d,'timestamp':Date['now']()});}export function trackFileDelete(_0x3b1583,_0x3b8cc7){const _0x116269=a10_0x23c9;changes[_0x116269(0x198)]({'path':a10_0x1a166d[_0x116269(0x18e)](_0x3b1583),'type':_0x116269(0x187),'previousContent':_0x3b8cc7,'timestamp':Date[_0x116269(0x17e)]()});}function a10_0x23c9(_0x13dc3b,_0x35683c){_0x13dc3b=_0x13dc3b-0x17d;const _0x521551=a10_0x5215();let _0x23c905=_0x521551[_0x13dc3b];return _0x23c905;}export function getChanges(){return[...changes];}function a10_0x5215(){const _0x53d7cf=['existsSync','10525410pgbIjB','pop','writeFileSync','message','Restored:\x20','Rollback\x20failed:\x20','path','push','7wDjacG','now','Unknown\x20change\x20type','8VSCLKN','8129799ZsFTkQ','4kbeUba','success','create','length','14cUsAcF','delete','32279599yvqUzP','45686HPDXGI','7167345IxKMnH','modify','previousContent','4588347OVlRlK','resolve','4529916xzQSxG'];a10_0x5215=function(){return _0x53d7cf;};return a10_0x5215();}export function rollbackLast(){const _0x1cf888=a10_0x23c9;if(changes[_0x1cf888(0x185)]===0x0)return{'success':![],'message':'No\x20changes\x20to\x20rollback'};const _0x3a70a4=changes[_0x1cf888(0x192)]();try{switch(_0x3a70a4['type']){case _0x1cf888(0x184):a10_0x52c652[_0x1cf888(0x190)](_0x3a70a4[_0x1cf888(0x197)])&&a10_0x52c652['unlinkSync'](_0x3a70a4[_0x1cf888(0x197)]);return{'success':!![],'message':'Deleted:\x20'+_0x3a70a4[_0x1cf888(0x197)]};case _0x1cf888(0x18b):_0x3a70a4[_0x1cf888(0x18c)]!==null&&a10_0x52c652['writeFileSync'](_0x3a70a4[_0x1cf888(0x197)],_0x3a70a4[_0x1cf888(0x18c)]);return{'success':!![],'message':'Restored:\x20'+_0x3a70a4['path']};case _0x1cf888(0x187):_0x3a70a4['previousContent']!==null&&a10_0x52c652[_0x1cf888(0x193)](_0x3a70a4[_0x1cf888(0x197)],_0x3a70a4['previousContent']);return{'success':!![],'message':_0x1cf888(0x195)+_0x3a70a4[_0x1cf888(0x197)]};default:return{'success':![],'message':_0x1cf888(0x17f)};}}catch(_0x2a4b88){return{'success':![],'message':_0x1cf888(0x196)+_0x2a4b88};}}export function rollbackAll(){const _0x3daad3=a10_0x23c9,_0x5e6f39=[];let _0x238f7c=0x0;while(changes[_0x3daad3(0x185)]>0x0){const _0x55b334=rollbackLast();_0x55b334[_0x3daad3(0x183)]&&(_0x238f7c++,_0x5e6f39['push'](_0x55b334[_0x3daad3(0x194)]));}return{'success':_0x238f7c>0x0,'count':_0x238f7c,'messages':_0x5e6f39};}export function clearChanges(){const _0x47b17d=a10_0x23c9;changes[_0x47b17d(0x185)]=0x0;}
@@ -1 +1 @@
1
- (function(_0x24ab3c,_0x37ff8c){const _0x1d0bf2=a11_0xf1bc,_0x1d157d=_0x24ab3c();while(!![]){try{const _0x162342=-parseInt(_0x1d0bf2(0x75))/0x1*(parseInt(_0x1d0bf2(0x70))/0x2)+-parseInt(_0x1d0bf2(0x6f))/0x3*(parseInt(_0x1d0bf2(0x68))/0x4)+-parseInt(_0x1d0bf2(0x6c))/0x5+-parseInt(_0x1d0bf2(0x73))/0x6*(-parseInt(_0x1d0bf2(0x71))/0x7)+-parseInt(_0x1d0bf2(0x6b))/0x8*(parseInt(_0x1d0bf2(0x6a))/0x9)+parseInt(_0x1d0bf2(0x69))/0xa+-parseInt(_0x1d0bf2(0x74))/0xb*(-parseInt(_0x1d0bf2(0x67))/0xc);if(_0x162342===_0x37ff8c)break;else _0x1d157d['push'](_0x1d157d['shift']());}catch(_0xecac6f){_0x1d157d['push'](_0x1d157d['shift']());}}}(a11_0x442e,0x98ab9));import{getRules,addRule as a11_0x50801f,clearRules as a11_0x1e3915}from'../utils/storage.js';function a11_0x442e(){const _0xbcb7e9=['9ztQIqq','23302ZTRJNl','7437437nKjfff','length','6hazuYh','94006LoMVlE','101biKapO','3324DFWpvj','778060AXVOje','5176640CMLaGG','2447379HOqtfh','24GseDMa','3729855lvxOUG','join','\x0a\x0aUser-defined\x20rules:\x0a'];a11_0x442e=function(){return _0xbcb7e9;};return a11_0x442e();}function a11_0xf1bc(_0x4645e,_0x4d7730){_0x4645e=_0x4645e-0x67;const _0x442ee6=a11_0x442e();let _0xf1bcad=_0x442ee6[_0x4645e];return _0xf1bcad;}export function listRules(){return getRules();}export function addRule(_0x327062){a11_0x50801f(_0x327062);}export function clearRules(){a11_0x1e3915();}export function formatRulesForSystem(){const _0x21946d=a11_0xf1bc,_0x504080=getRules();if(_0x504080[_0x21946d(0x72)]===0x0)return'';return _0x21946d(0x6e)+_0x504080['map']((_0x4d20ad,_0x49415a)=>_0x49415a+0x1+'.\x20'+_0x4d20ad)[_0x21946d(0x6d)]('\x0a');}
1
+ function a11_0x56c6(){const _0x2efca0=['\x0a\x0aUser-defined\x20rules:\x0a','115650GpxMwr','1845104ZNbiHI','529571UeZueO','947640BcvgrE','500840TQmDaq','8MJvdft','520YaxpQl','6OJncsL','3864qIWxJt','length','2237193dFdZwl','map'];a11_0x56c6=function(){return _0x2efca0;};return a11_0x56c6();}function a11_0x2aba(_0x26aa2b,_0x549eb5){_0x26aa2b=_0x26aa2b-0xa7;const _0x56c67e=a11_0x56c6();let _0x2abad3=_0x56c67e[_0x26aa2b];return _0x2abad3;}(function(_0x39d361,_0x1e4b78){const _0x5d46ab=a11_0x2aba,_0x5bb130=_0x39d361();while(!![]){try{const _0x34b127=parseInt(_0x5d46ab(0xa9))/0x1*(-parseInt(_0x5d46ab(0xb1))/0x2)+-parseInt(_0x5d46ab(0xac))/0x3*(-parseInt(_0x5d46ab(0xaa))/0x4)+parseInt(_0x5d46ab(0xa8))/0x5+parseInt(_0x5d46ab(0xab))/0x6*(-parseInt(_0x5d46ab(0xb3))/0x7)+parseInt(_0x5d46ab(0xb2))/0x8+parseInt(_0x5d46ab(0xae))/0x9+parseInt(_0x5d46ab(0xa7))/0xa;if(_0x34b127===_0x1e4b78)break;else _0x5bb130['push'](_0x5bb130['shift']());}catch(_0x247c3f){_0x5bb130['push'](_0x5bb130['shift']());}}}(a11_0x56c6,0x4a0e6));import{getRules,addRule as a11_0x27435b,clearRules as a11_0xe962a6}from'../utils/storage.js';export function listRules(){return getRules();}export function addRule(_0x2c8f67){a11_0x27435b(_0x2c8f67);}export function clearRules(){a11_0xe962a6();}export function formatRulesForSystem(){const _0x1e1984=a11_0x2aba,_0x3ce7f9=getRules();if(_0x3ce7f9[_0x1e1984(0xad)]===0x0)return'';return _0x1e1984(0xb0)+_0x3ce7f9[_0x1e1984(0xaf)]((_0x4bd035,_0x263d77)=>_0x263d77+0x1+'.\x20'+_0x4bd035)['join']('\x0a');}
package/dist/ui/output.js CHANGED
@@ -1 +1 @@
1
- function a12_0x509e(_0x39f193,_0x237ac4){_0x39f193=_0x39f193-0x1d6;const _0x20685e=a12_0x2068();let _0x509e74=_0x20685e[_0x39f193];return _0x509e74;}const a12_0x56d09b=a12_0x509e;(function(_0x2b0144,_0x19a01c){const _0xc0fa3d=a12_0x509e,_0x3042e5=_0x2b0144();while(!![]){try{const _0x1f70a7=-parseInt(_0xc0fa3d(0x1dd))/0x1+parseInt(_0xc0fa3d(0x1f8))/0x2+-parseInt(_0xc0fa3d(0x1eb))/0x3*(parseInt(_0xc0fa3d(0x1f6))/0x4)+parseInt(_0xc0fa3d(0x1fc))/0x5+parseInt(_0xc0fa3d(0x1ea))/0x6*(parseInt(_0xc0fa3d(0x20a))/0x7)+-parseInt(_0xc0fa3d(0x1d7))/0x8+parseInt(_0xc0fa3d(0x1f1))/0x9;if(_0x1f70a7===_0x19a01c)break;else _0x3042e5['push'](_0x3042e5['shift']());}catch(_0x29ed35){_0x3042e5['push'](_0x3042e5['shift']());}}}(a12_0x2068,0x6e500));import a12_0x54a312 from'chalk';import a12_0x3542bf from'ora';const LOGO='\x0a'+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x200))(a12_0x56d09b(0x201))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e2))(a12_0x56d09b(0x206))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e5))('███████╗██╗\x20\x20\x20\x20\x20')+a12_0x54a312['hex'](a12_0x56d09b(0x1f2))(a12_0x56d09b(0x202))+'\x0a'+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x200))(a12_0x56d09b(0x1f9))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e2))(a12_0x56d09b(0x1e1))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e5))(a12_0x56d09b(0x1f3))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1f2))(a12_0x56d09b(0x1fa))+'\x0a'+a12_0x54a312['hex'](a12_0x56d09b(0x200))(a12_0x56d09b(0x210))+a12_0x54a312[a12_0x56d09b(0x208)]('#60a5fa')(a12_0x56d09b(0x221))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e5))(a12_0x56d09b(0x1ee))+a12_0x54a312['hex'](a12_0x56d09b(0x1f2))(a12_0x56d09b(0x1e9))+'\x0a'+a12_0x54a312['hex'](a12_0x56d09b(0x200))(a12_0x56d09b(0x21a))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e2))(a12_0x56d09b(0x221))+a12_0x54a312[a12_0x56d09b(0x208)]('#3b82f6')('\x20███╔╝\x20\x20██║\x20\x20\x20\x20\x20')+a12_0x54a312['hex']('#2563eb')(a12_0x56d09b(0x1e9))+'\x0a'+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x200))('╚███╔███╔╝')+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e2))('╚██████╔╝╚██████╔╝')+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e5))(a12_0x56d09b(0x219))+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1f2))(a12_0x56d09b(0x1e9))+'\x0a'+a12_0x54a312[a12_0x56d09b(0x208)]('#93c5fd')('\x20╚══╝╚══╝\x20')+a12_0x54a312[a12_0x56d09b(0x208)](a12_0x56d09b(0x1e2))(a12_0x56d09b(0x205))+a12_0x54a312['hex'](a12_0x56d09b(0x1e5))(a12_0x56d09b(0x1de))+a12_0x54a312[a12_0x56d09b(0x208)]('#2563eb')(a12_0x56d09b(0x217))+'\x0a';export function showLogo(){const _0x217405=a12_0x56d09b;process[_0x217405(0x1e0)][_0x217405(0x21e)](LOGO+'\x0a');}export function createSpinner(_0x183b0d){const _0x40ce17=a12_0x56d09b;return a12_0x3542bf({'text':_0x183b0d,'color':_0x40ce17(0x1e7),'spinner':'dots'});}export function success(_0x33dd51){const _0x4155ef=a12_0x56d09b;process[_0x4155ef(0x1e0)][_0x4155ef(0x21e)](a12_0x54a312[_0x4155ef(0x208)](_0x4155ef(0x1e5))('\x20\x20')+_0x33dd51+'\x0a');}export function error(_0x76a9b9){const _0x2626c0=a12_0x56d09b;process[_0x2626c0(0x1e0)][_0x2626c0(0x21e)](a12_0x54a312['red']('\x20\x20')+_0x76a9b9+'\x0a');}export function info(_0x302b48){const _0x2d1895=a12_0x56d09b;process['stdout'][_0x2d1895(0x21e)](a12_0x54a312['hex'](_0x2d1895(0x1e2))('\x20\x20')+_0x302b48+'\x0a');}export function warn(_0x21cf9e){const _0x9647f2=a12_0x56d09b;process[_0x9647f2(0x1e0)]['write'](a12_0x54a312[_0x9647f2(0x20b)]('\x20\x20')+_0x21cf9e+'\x0a');}export function dim(_0x2a4d5c){const _0x4360d8=a12_0x56d09b;process[_0x4360d8(0x1e0)][_0x4360d8(0x21e)](a12_0x54a312[_0x4360d8(0x1f4)]('\x20\x20'+_0x2a4d5c)+'\x0a');}export function header(_0x58b6de){const _0x27cdf4=a12_0x56d09b;process['stdout'][_0x27cdf4(0x21e)]('\x0a'+a12_0x54a312[_0x27cdf4(0x20c)][_0x27cdf4(0x208)](_0x27cdf4(0x1e5))(_0x58b6de)+'\x0a');}export function divider(){const _0x68f36=a12_0x56d09b;process[_0x68f36(0x1e0)][_0x68f36(0x21e)](a12_0x54a312[_0x68f36(0x1f4)]('\x20\x20'+'-'[_0x68f36(0x1e6)](0x32))+'\x0a');}export function tip(_0x11f4b3,_0x1e6d00){const _0x4f162a=a12_0x56d09b;process[_0x4f162a(0x1e0)][_0x4f162a(0x21e)](a12_0x54a312['dim']('\x20\x20')+a12_0x54a312[_0x4f162a(0x1ec)](_0x11f4b3)+a12_0x54a312['dim']('\x20'+_0x1e6d00)+'\x0a');}export function userMessage(_0x3126e3){const _0x204fd3=a12_0x56d09b;process[_0x204fd3(0x1e0)][_0x204fd3(0x21e)](a12_0x54a312[_0x204fd3(0x20c)][_0x204fd3(0x208)](_0x204fd3(0x1e2))(_0x204fd3(0x1ef))+_0x3126e3+'\x0a');}export function aiMessage(_0x32a2fc){const _0x2a6d5c=a12_0x56d09b;process[_0x2a6d5c(0x1e0)][_0x2a6d5c(0x21e)](_0x2a6d5c(0x218)+_0x32a2fc);}export function aiMessageEnd(){const _0x18c962=a12_0x56d09b;process['stdout'][_0x18c962(0x21e)]('\x0a');}export function toolCall(_0x17bc00,_0x1f4d85){const _0x107d9f=a12_0x56d09b;process['stdout']['write'](a12_0x54a312[_0x107d9f(0x1f4)]('\x20\x20\x20\x20->\x20')+a12_0x54a312[_0x107d9f(0x208)]('#60a5fa')(_0x17bc00)+a12_0x54a312[_0x107d9f(0x1f4)](':\x20'+_0x1f4d85)+'\x0a');}export function statusBar(_0x3d29f9,_0x2eafcb){const _0x954f0e=a12_0x56d09b,_0x163d6c=_0x3d29f9[_0x954f0e(0x213)]('/')[_0x954f0e(0x21b)]()?.[_0x954f0e(0x1fe)](':free','')||_0x3d29f9,_0x8c280f=a12_0x54a312[_0x954f0e(0x208)]('#3b82f6')(_0x163d6c),_0x33784f=a12_0x54a312[_0x954f0e(0x1f4)](_0x2eafcb+_0x954f0e(0x1d6));process['stdout'][_0x954f0e(0x21e)]('\x20\x20'+_0x8c280f+'\x20\x20'+a12_0x54a312[_0x954f0e(0x1f4)]('|')+'\x20\x20'+_0x33784f+'\x0a');}export function prompt(){const _0x31413e=a12_0x56d09b;process[_0x31413e(0x1e0)][_0x31413e(0x21e)](a12_0x54a312[_0x31413e(0x208)](_0x31413e(0x1e5))('\x20\x20>\x20'));}function lerpColor(_0x5ba12b,_0x35ef1e,_0x47ce1c){const _0x1fac9b=a12_0x56d09b,_0x4ea2f2=parseInt(_0x5ba12b[_0x1fac9b(0x1fe)]('#',''),0x10),_0x510d8f=parseInt(_0x35ef1e[_0x1fac9b(0x1fe)]('#',''),0x10),_0x4b3490=_0x4ea2f2>>0x10&0xff,_0x143413=_0x4ea2f2>>0x8&0xff,_0x1b6492=_0x4ea2f2&0xff,_0x41ce0=_0x510d8f>>0x10&0xff,_0x1044e0=_0x510d8f>>0x8&0xff,_0x400b55=_0x510d8f&0xff,_0xeb06e1=Math[_0x1fac9b(0x214)](_0x4b3490+(_0x41ce0-_0x4b3490)*_0x47ce1c),_0x3cfc0c=Math[_0x1fac9b(0x214)](_0x143413+(_0x1044e0-_0x143413)*_0x47ce1c),_0x5392f1=Math['round'](_0x1b6492+(_0x400b55-_0x1b6492)*_0x47ce1c);return'#'+((0x1<<0x18)+(_0xeb06e1<<0x10)+(_0x3cfc0c<<0x8)+_0x5392f1)[_0x1fac9b(0x1dc)](0x10)[_0x1fac9b(0x1d8)](0x1);}export function gradientText(_0x512d13,_0x215ca4,_0x48c077){const _0x6814d1=a12_0x56d09b,_0x101354=_0x512d13[_0x6814d1(0x213)]('');return _0x101354[_0x6814d1(0x215)]((_0x4023dc,_0x3d2c40)=>{const _0x1421d2=_0x6814d1,_0x133ded=_0x3d2c40/Math[_0x1421d2(0x1e4)](_0x101354[_0x1421d2(0x1f5)]-0x1,0x1);return a12_0x54a312[_0x1421d2(0x208)](lerpColor(_0x215ca4,_0x48c077,_0x133ded))(_0x4023dc);})['join']('');}export function loggedInBox(_0x2109f3){const _0x47a327=a12_0x56d09b,_0x48a67b=_0x47a327(0x216),_0x35806e=_0x2109f3[_0x47a327(0x20e)](),_0x53315d=_0x48a67b['length']+_0x35806e[_0x47a327(0x1f5)]+0x4,_0x40f3b1=a12_0x54a312[_0x47a327(0x208)](_0x47a327(0x1e5))('─'['repeat'](_0x53315d)),_0x218723=a12_0x54a312[_0x47a327(0x208)](_0x47a327(0x1e5))('╭'+_0x40f3b1+'╮'),_0x28851d=a12_0x54a312[_0x47a327(0x208)](_0x47a327(0x1e5))('╰'+_0x40f3b1+'╯'),_0x6f30cb=gradientText(_0x35806e,_0x47a327(0x1e2),_0x47a327(0x1f2));process[_0x47a327(0x1e0)][_0x47a327(0x21e)](_0x47a327(0x218)+_0x218723+'\x0a'),process[_0x47a327(0x1e0)][_0x47a327(0x21e)]('\x20\x20'+a12_0x54a312[_0x47a327(0x208)](_0x47a327(0x1e5))(_0x47a327(0x1e8))+a12_0x54a312['dim'](_0x48a67b)+_0x6f30cb+a12_0x54a312['hex'](_0x47a327(0x1e5))(_0x47a327(0x20d))+'\x0a'),process[_0x47a327(0x1e0)][_0x47a327(0x21e)]('\x20\x20'+_0x28851d+'\x0a');}export function actionSpinner(_0x18a163){const _0x2c5e22=a12_0x56d09b;return a12_0x3542bf({'text':a12_0x54a312[_0x2c5e22(0x208)]('#60a5fa')(_0x18a163),'color':'blue','spinner':'dots'});}export function toolActivity(_0x1f0d86,_0x2e79e3){const _0x181be9=a12_0x56d09b,_0x48be4b={'create_file':'Creating','read_file':'Reading','edit_file':_0x181be9(0x222),'list_directory':'Listing','search_file':_0x181be9(0x1d9),'find_files':'Finding','search_directory':_0x181be9(0x1d9),'run_command':_0x181be9(0x21c)},_0x51cc6f=_0x48be4b[_0x1f0d86]||_0x1f0d86;let _0x26e593='';if(_0x1f0d86===_0x181be9(0x1e3)&&_0x2e79e3[_0x181be9(0x1df)])_0x26e593=_0x2e79e3['command']['substring'](0x0,0x32);else{if(_0x2e79e3[_0x181be9(0x1db)])_0x26e593=_0x2e79e3[_0x181be9(0x1db)];else _0x2e79e3[_0x181be9(0x1fd)]&&(_0x26e593='\x22'+_0x2e79e3[_0x181be9(0x1fd)]+'\x22');}process[_0x181be9(0x1e0)][_0x181be9(0x21e)](a12_0x54a312['dim']('\x20\x20'+_0x51cc6f+'\x20'+_0x26e593+'\x0a'));}function a12_0x2068(){const _0x142d23=['floor','██║\x20█╗\x20██║','green','\x20/\x20','split','round','map','Logged\x20in\x20as:\x20','╚═╝\x20\x20\x20╚═╝\x20\x20\x20','\x0a\x20\x20','███████╗███████╗','██║███╗██║','pop','Running','\x20tokens','write','Unlimited','toLocaleString','██║\x20\x20\x20██║██║\x20\x20\x20██║','Editing','%\x20context\x20left','5326952UfCeML','slice','Searching','\x20\x20Limit\x20Reached\x0a','path','toString','773796PNzqoq','╚══════╝╚══════╝','command','stdout','██╔═══██╗██╔═══██╗','#60a5fa','run_command','max','#3b82f6','repeat','blue','│\x20\x20','██║\x20\x20\x20██║\x20\x20\x20','12xrEbQU','1149jOsSQF','white','forEach','\x20\x20███╔╝\x20██║\x20\x20\x20\x20\x20','\x0a\x20\x20You:\x20','toFixed','5263155mbYpCJ','#2563eb','╚══███╔╝██║\x20\x20\x20\x20\x20','dim','length','212wLHPGk','\x20connected\x20(','1066920SKxWha','██║\x20\x20\x20\x20██║','██║╚══██╔══╝','\x20\x20Token\x20Usage\x0a','631335mjVNtw','pattern','replace','server','#93c5fd','██╗\x20\x20\x20\x20██╗','██╗████████╗','red','\x20\x20Done\x20in\x20','\x20╚═════╝\x20\x20╚═════╝\x20','\x20██████╗\x20\x20██████╗\x20','min','hex','\x20MCP\x20','2335487oEyUDi','yellow','bold','\x20\x20│','trim'];a12_0x2068=function(){return _0x142d23;};return a12_0x2068();}export function commandOutput(_0xbb73ac){const _0x161fb7=a12_0x56d09b,_0x4c02c3=_0xbb73ac[_0x161fb7(0x213)]('\x0a');_0x4c02c3[_0x161fb7(0x1ed)](_0x4a837c=>{const _0x280013=_0x161fb7;_0x4a837c[_0x280013(0x20e)]()&&process['stdout'][_0x280013(0x21e)](a12_0x54a312[_0x280013(0x1f4)]('\x20\x20\x20')+a12_0x54a312[_0x280013(0x1f4)](_0x4a837c)+'\x0a');});}export function usageBox(_0x3c2278,_0x453137,_0x3e4d84){const _0x27e0a5=a12_0x56d09b,_0x51a14a=_0x453137>0x0?Math[_0x27e0a5(0x207)](Math['round'](_0x3c2278/_0x453137*0x64),0x64):0x0,_0x14175d=0x1e,_0x38302e=Math[_0x27e0a5(0x214)](_0x51a14a/0x64*_0x14175d),_0x526f42=_0x14175d-_0x38302e,_0x5c92fe=_0x3e4d84?a12_0x54a312[_0x27e0a5(0x203)]:_0x51a14a>0x50?a12_0x54a312['yellow']:a12_0x54a312[_0x27e0a5(0x211)],_0x1332db=_0x5c92fe('█'[_0x27e0a5(0x1e6)](_0x38302e))+a12_0x54a312[_0x27e0a5(0x1f4)]('░'[_0x27e0a5(0x1e6)](_0x526f42)),_0x5d00c7=_0x453137>=0x3b9ac9ff?_0x27e0a5(0x21f):_0x453137['toLocaleString'](),_0x131fe3=_0x3c2278[_0x27e0a5(0x220)]()+_0x27e0a5(0x212)+_0x5d00c7+_0x27e0a5(0x21d);process[_0x27e0a5(0x1e0)]['write']('\x0a'),process[_0x27e0a5(0x1e0)][_0x27e0a5(0x21e)](a12_0x54a312[_0x27e0a5(0x20c)]['hex'](_0x27e0a5(0x1e2))(_0x27e0a5(0x1fb))),process[_0x27e0a5(0x1e0)][_0x27e0a5(0x21e)]('\x20\x20'+_0x1332db+'\x20'+a12_0x54a312[_0x27e0a5(0x1f4)](_0x51a14a+'%')+'\x0a'),process[_0x27e0a5(0x1e0)]['write'](a12_0x54a312[_0x27e0a5(0x1f4)]('\x20\x20'+_0x131fe3+'\x0a')),_0x3e4d84&&process[_0x27e0a5(0x1e0)][_0x27e0a5(0x21e)](a12_0x54a312[_0x27e0a5(0x203)](_0x27e0a5(0x1da))),process['stdout'][_0x27e0a5(0x21e)]('\x0a');}export function mcpConnected(_0xfaae3c,_0x12f678){const _0x46f4b1=a12_0x56d09b,_0x283ecf=_0xfaae3c===0x1?_0x46f4b1(0x1ff):'servers';process[_0x46f4b1(0x1e0)][_0x46f4b1(0x21e)](a12_0x54a312['dim']('\x20\x20'+a12_0x54a312[_0x46f4b1(0x208)](_0x46f4b1(0x1e5))(_0xfaae3c['toString']())+_0x46f4b1(0x209)+_0x283ecf+_0x46f4b1(0x1f7)+_0x12f678+'\x20tools)\x0a'));}export function elapsedTime(_0x46c108){const _0x389eb3=a12_0x56d09b,_0x51e249=_0x46c108<0x3c?_0x46c108[_0x389eb3(0x1f0)](0x1)+'s':Math[_0x389eb3(0x20f)](_0x46c108/0x3c)+'m\x20'+(_0x46c108%0x3c)[_0x389eb3(0x1f0)](0x0)+'s';process[_0x389eb3(0x1e0)][_0x389eb3(0x21e)](a12_0x54a312[_0x389eb3(0x1f4)](_0x389eb3(0x204)+_0x51e249+'\x0a'));}export function currentDir(_0x3e3c20){const _0x330578=a12_0x56d09b;process[_0x330578(0x1e0)]['write'](a12_0x54a312[_0x330578(0x1f4)]('\x20\x20Working\x20in:\x20')+a12_0x54a312[_0x330578(0x208)]('#60a5fa')(_0x3e3c20)+'\x0a');}
1
+ const a12_0x2a2bc8=a12_0x1dcb;(function(_0x16399e,_0x1ba958){const _0x14838e=a12_0x1dcb,_0x438fe2=_0x16399e();while(!![]){try{const _0x5600b0=parseInt(_0x14838e(0xd1))/0x1*(parseInt(_0x14838e(0xad))/0x2)+parseInt(_0x14838e(0xae))/0x3*(parseInt(_0x14838e(0xee))/0x4)+-parseInt(_0x14838e(0xa4))/0x5*(-parseInt(_0x14838e(0xb9))/0x6)+-parseInt(_0x14838e(0xec))/0x7+parseInt(_0x14838e(0xa1))/0x8*(-parseInt(_0x14838e(0xaf))/0x9)+parseInt(_0x14838e(0xe0))/0xa+-parseInt(_0x14838e(0xb4))/0xb*(parseInt(_0x14838e(0xbc))/0xc);if(_0x5600b0===_0x1ba958)break;else _0x438fe2['push'](_0x438fe2['shift']());}catch(_0x1a95a9){_0x438fe2['push'](_0x438fe2['shift']());}}}(a12_0x909b,0xacd25));import a12_0x3a43a0 from'chalk';import a12_0x4ca978 from'ora';const LOGO='\x0a'+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#93c5fd')(a12_0x2a2bc8(0xdd))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xb7))(a12_0x2a2bc8(0xbb))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#3b82f6')(a12_0x2a2bc8(0xdb))+a12_0x3a43a0['hex'](a12_0x2a2bc8(0xd8))('██╗████████╗')+'\x0a'+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xc0))(a12_0x2a2bc8(0xe1))+a12_0x3a43a0['hex'](a12_0x2a2bc8(0xb7))(a12_0x2a2bc8(0xdc))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xa3))(a12_0x2a2bc8(0xe9))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#2563eb')(a12_0x2a2bc8(0xb3))+'\x0a'+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xc0))('██║\x20█╗\x20██║')+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#60a5fa')(a12_0x2a2bc8(0xc9))+a12_0x3a43a0['hex']('#3b82f6')('\x20\x20███╔╝\x20██║\x20\x20\x20\x20\x20')+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xd8))(a12_0x2a2bc8(0xc8))+'\x0a'+a12_0x3a43a0['hex'](a12_0x2a2bc8(0xc0))(a12_0x2a2bc8(0xa6))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#60a5fa')(a12_0x2a2bc8(0xc9))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xa3))(a12_0x2a2bc8(0xb6))+a12_0x3a43a0['hex']('#2563eb')('██║\x20\x20\x20██║\x20\x20\x20')+'\x0a'+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xc0))(a12_0x2a2bc8(0xdf))+a12_0x3a43a0['hex'](a12_0x2a2bc8(0xb7))('╚██████╔╝╚██████╔╝')+a12_0x3a43a0[a12_0x2a2bc8(0xa7)]('#3b82f6')(a12_0x2a2bc8(0xba))+a12_0x3a43a0['hex']('#2563eb')(a12_0x2a2bc8(0xc8))+'\x0a'+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xc0))(a12_0x2a2bc8(0xac))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xb7))(a12_0x2a2bc8(0xc4))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xa3))(a12_0x2a2bc8(0xd2))+a12_0x3a43a0[a12_0x2a2bc8(0xa7)](a12_0x2a2bc8(0xd8))(a12_0x2a2bc8(0xc7))+'\x0a';export function showLogo(){const _0x5c5320=a12_0x2a2bc8;process[_0x5c5320(0xd0)]['write'](LOGO+'\x0a');}export function createSpinner(_0x23d9cc){const _0x57d595=a12_0x2a2bc8;return a12_0x4ca978({'text':_0x23d9cc,'color':_0x57d595(0xe3),'spinner':_0x57d595(0xe2)});}export function success(_0x1f6b04){const _0x510a05=a12_0x2a2bc8;process['stdout'][_0x510a05(0xf0)](a12_0x3a43a0[_0x510a05(0xa7)](_0x510a05(0xa3))('\x20\x20')+_0x1f6b04+'\x0a');}export function error(_0x300a46){const _0x1cfd92=a12_0x2a2bc8;process[_0x1cfd92(0xd0)]['write'](a12_0x3a43a0[_0x1cfd92(0xe4)]('\x20\x20')+_0x300a46+'\x0a');}export function info(_0x3c8ad2){const _0x402fef=a12_0x2a2bc8;process['stdout'][_0x402fef(0xf0)](a12_0x3a43a0['hex']('#60a5fa')('\x20\x20')+_0x3c8ad2+'\x0a');}function a12_0x909b(){const _0x5a9e5c=['\x20██████╗\x20\x20██████╗\x20','376476mkPInD','floor','slice','Listing','#93c5fd','run_command','\x20\x20Done\x20in\x20','replace','\x20╚═════╝\x20\x20╚═════╝\x20','pop','round','╚═╝\x20\x20\x20╚═╝\x20\x20\x20','██║\x20\x20\x20██║\x20\x20\x20','██║\x20\x20\x20██║██║\x20\x20\x20██║','toLocaleString','\x0a\x20\x20You:\x20','%\x20context\x20left','map','min','│\x20\x20','stdout','197KhpFUK','╚══════╝╚══════╝','repeat','server','toString','Logged\x20in\x20as:\x20','split','#2563eb','\x20tokens','pattern','███████╗██╗\x20\x20\x20\x20\x20','██╔═══██╗██╔═══██╗','██╗\x20\x20\x20\x20██╗','dim','╚███╔███╔╝','8816220yNrxoi','██║\x20\x20\x20\x20██║','dots','blue','red','forEach','\x20\x20\x20','Finding','\x20tools)\x0a','╚══███╔╝██║\x20\x20\x20\x20\x20','Reading','green','3891867Tpcsod','white','12YHZcuL','toFixed','write','servers','1552vDlUaL','command','#3b82f6','7630vNmvIZ','\x0a\x20\x20','██║███╗██║','hex','\x20\x20Limit\x20Reached\x0a','yellow','\x20MCP\x20','\x20/\x20','\x20╚══╝╚══╝\x20','7674xElcwf','896094kSYnan','52461FpjlsN','path','Unlimited','bold','██║╚══██╔══╝','473TGtAen','Searching','\x20███╔╝\x20\x20██║\x20\x20\x20\x20\x20','#60a5fa','length','4758OlbhqA','███████╗███████╗'];a12_0x909b=function(){return _0x5a9e5c;};return a12_0x909b();}export function warn(_0x410152){const _0x15fd75=a12_0x2a2bc8;process['stdout'][_0x15fd75(0xf0)](a12_0x3a43a0[_0x15fd75(0xa9)]('\x20\x20')+_0x410152+'\x0a');}export function dim(_0x19287b){const _0x24da1f=a12_0x2a2bc8;process[_0x24da1f(0xd0)][_0x24da1f(0xf0)](a12_0x3a43a0[_0x24da1f(0xde)]('\x20\x20'+_0x19287b)+'\x0a');}export function header(_0x155afe){const _0x392dac=a12_0x2a2bc8;process[_0x392dac(0xd0)][_0x392dac(0xf0)]('\x0a'+a12_0x3a43a0[_0x392dac(0xb2)]['hex'](_0x392dac(0xa3))(_0x155afe)+'\x0a');}export function divider(){const _0x297053=a12_0x2a2bc8;process['stdout'][_0x297053(0xf0)](a12_0x3a43a0['dim']('\x20\x20'+'-'[_0x297053(0xd3)](0x32))+'\x0a');}export function tip(_0x52fd75,_0x1123d0){const _0x54e8c8=a12_0x2a2bc8;process[_0x54e8c8(0xd0)]['write'](a12_0x3a43a0['dim']('\x20\x20')+a12_0x3a43a0[_0x54e8c8(0xed)](_0x52fd75)+a12_0x3a43a0[_0x54e8c8(0xde)]('\x20'+_0x1123d0)+'\x0a');}export function userMessage(_0x4bd199){const _0x5ec8de=a12_0x2a2bc8;process[_0x5ec8de(0xd0)]['write'](a12_0x3a43a0[_0x5ec8de(0xb2)][_0x5ec8de(0xa7)]('#60a5fa')(_0x5ec8de(0xcb))+_0x4bd199+'\x0a');}export function aiMessage(_0x1d6b91){const _0x564c21=a12_0x2a2bc8;process[_0x564c21(0xd0)][_0x564c21(0xf0)]('\x0a\x20\x20'+_0x1d6b91);}export function aiMessageEnd(){process['stdout']['write']('\x0a');}export function toolCall(_0x316ec9,_0x2ab61b){const _0x1b880a=a12_0x2a2bc8;process[_0x1b880a(0xd0)]['write'](a12_0x3a43a0[_0x1b880a(0xde)]('\x20\x20\x20\x20->\x20')+a12_0x3a43a0[_0x1b880a(0xa7)]('#60a5fa')(_0x316ec9)+a12_0x3a43a0[_0x1b880a(0xde)](':\x20'+_0x2ab61b)+'\x0a');}export function statusBar(_0x3e5ac5,_0x567298){const _0x1467c2=a12_0x2a2bc8,_0xd6c7c9=_0x3e5ac5[_0x1467c2(0xd7)]('/')[_0x1467c2(0xc5)]()?.[_0x1467c2(0xc3)](':free','')||_0x3e5ac5,_0x78a2d1=a12_0x3a43a0[_0x1467c2(0xa7)](_0x1467c2(0xa3))(_0xd6c7c9),_0x2a94dd=a12_0x3a43a0[_0x1467c2(0xde)](_0x567298+_0x1467c2(0xcc));process[_0x1467c2(0xd0)][_0x1467c2(0xf0)]('\x20\x20'+_0x78a2d1+'\x20\x20'+a12_0x3a43a0[_0x1467c2(0xde)]('|')+'\x20\x20'+_0x2a94dd+'\x0a');}export function prompt(){const _0x49999c=a12_0x2a2bc8;process[_0x49999c(0xd0)]['write'](a12_0x3a43a0[_0x49999c(0xa7)]('#3b82f6')('\x20\x20>\x20'));}function lerpColor(_0x4a0c50,_0x1189e4,_0x5aa007){const _0x51b669=a12_0x2a2bc8,_0x3b39a3=parseInt(_0x4a0c50[_0x51b669(0xc3)]('#',''),0x10),_0x8a4c68=parseInt(_0x1189e4[_0x51b669(0xc3)]('#',''),0x10),_0x4e14ba=_0x3b39a3>>0x10&0xff,_0x179e60=_0x3b39a3>>0x8&0xff,_0x3f8b80=_0x3b39a3&0xff,_0x31b71e=_0x8a4c68>>0x10&0xff,_0x239495=_0x8a4c68>>0x8&0xff,_0x137627=_0x8a4c68&0xff,_0x4e5e94=Math[_0x51b669(0xc6)](_0x4e14ba+(_0x31b71e-_0x4e14ba)*_0x5aa007),_0x8a642d=Math[_0x51b669(0xc6)](_0x179e60+(_0x239495-_0x179e60)*_0x5aa007),_0x182350=Math['round'](_0x3f8b80+(_0x137627-_0x3f8b80)*_0x5aa007);return'#'+((0x1<<0x18)+(_0x4e5e94<<0x10)+(_0x8a642d<<0x8)+_0x182350)[_0x51b669(0xd5)](0x10)[_0x51b669(0xbe)](0x1);}function a12_0x1dcb(_0x48660a,_0x5c8b52){_0x48660a=_0x48660a-0xa1;const _0x909b2f=a12_0x909b();let _0x1dcb42=_0x909b2f[_0x48660a];return _0x1dcb42;}export function gradientText(_0xf0b8b9,_0x31e519,_0x3cdfa4){const _0x24d694=a12_0x2a2bc8,_0x3815cf=_0xf0b8b9[_0x24d694(0xd7)]('');return _0x3815cf[_0x24d694(0xcd)]((_0x2a3c46,_0x24e729)=>{const _0x288f3f=_0x24d694,_0x51208e=_0x24e729/Math['max'](_0x3815cf[_0x288f3f(0xb8)]-0x1,0x1);return a12_0x3a43a0['hex'](lerpColor(_0x31e519,_0x3cdfa4,_0x51208e))(_0x2a3c46);})['join']('');}export function loggedInBox(_0x410666){const _0x1f152f=a12_0x2a2bc8,_0x27d147=_0x1f152f(0xd6),_0x54ce63=_0x410666['trim'](),_0xc6a223=_0x27d147[_0x1f152f(0xb8)]+_0x54ce63[_0x1f152f(0xb8)]+0x4,_0x36e5dd=a12_0x3a43a0['hex'](_0x1f152f(0xa3))('─'[_0x1f152f(0xd3)](_0xc6a223)),_0x148466=a12_0x3a43a0[_0x1f152f(0xa7)]('#3b82f6')('╭'+_0x36e5dd+'╮'),_0x155179=a12_0x3a43a0[_0x1f152f(0xa7)](_0x1f152f(0xa3))('╰'+_0x36e5dd+'╯'),_0x3634fe=gradientText(_0x54ce63,_0x1f152f(0xb7),'#2563eb');process[_0x1f152f(0xd0)][_0x1f152f(0xf0)](_0x1f152f(0xa5)+_0x148466+'\x0a'),process[_0x1f152f(0xd0)]['write']('\x20\x20'+a12_0x3a43a0[_0x1f152f(0xa7)](_0x1f152f(0xa3))(_0x1f152f(0xcf))+a12_0x3a43a0[_0x1f152f(0xde)](_0x27d147)+_0x3634fe+a12_0x3a43a0[_0x1f152f(0xa7)](_0x1f152f(0xa3))('\x20\x20│')+'\x0a'),process['stdout']['write']('\x20\x20'+_0x155179+'\x0a');}export function actionSpinner(_0x1c066a){const _0xe9516d=a12_0x2a2bc8;return a12_0x4ca978({'text':a12_0x3a43a0['hex']('#60a5fa')(_0x1c066a),'color':_0xe9516d(0xe3),'spinner':'dots'});}export function toolActivity(_0xc03d74,_0xb60ae5){const _0x28d2bb=a12_0x2a2bc8,_0x30912d={'create_file':'Creating','read_file':_0x28d2bb(0xea),'edit_file':'Editing','list_directory':_0x28d2bb(0xbf),'search_file':_0x28d2bb(0xb5),'find_files':_0x28d2bb(0xe7),'search_directory':_0x28d2bb(0xb5),'run_command':'Running'},_0x1768a8=_0x30912d[_0xc03d74]||_0xc03d74;let _0xc1d177='';if(_0xc03d74===_0x28d2bb(0xc1)&&_0xb60ae5['command'])_0xc1d177=_0xb60ae5[_0x28d2bb(0xa2)];else{if(_0xb60ae5[_0x28d2bb(0xb0)])_0xc1d177=_0xb60ae5[_0x28d2bb(0xb0)];else _0xb60ae5[_0x28d2bb(0xda)]&&(_0xc1d177='\x22'+_0xb60ae5[_0x28d2bb(0xda)]+'\x22');}process[_0x28d2bb(0xd0)][_0x28d2bb(0xf0)](a12_0x3a43a0[_0x28d2bb(0xde)]('\x20\x20'+_0x1768a8+'\x20'+_0xc1d177+'\x0a'));}export function commandOutput(_0x413962){const _0x51f632=a12_0x2a2bc8,_0x1c1303=_0x413962['split']('\x0a');_0x1c1303[_0x51f632(0xe5)](_0x189955=>{const _0x291f46=_0x51f632;_0x189955['trim']()&&process['stdout']['write'](a12_0x3a43a0[_0x291f46(0xde)](_0x291f46(0xe6))+a12_0x3a43a0[_0x291f46(0xde)](_0x189955)+'\x0a');});}export function usageBox(_0x28f581,_0x1225b7,_0x574787){const _0x1f241e=a12_0x2a2bc8,_0x53d838=_0x1225b7>0x0?Math[_0x1f241e(0xce)](Math[_0x1f241e(0xc6)](_0x28f581/_0x1225b7*0x64),0x64):0x0,_0x4884e5=0x1e,_0x1a9f14=Math[_0x1f241e(0xc6)](_0x53d838/0x64*_0x4884e5),_0x42255c=_0x4884e5-_0x1a9f14,_0x2afdbd=_0x574787?a12_0x3a43a0[_0x1f241e(0xe4)]:_0x53d838>0x50?a12_0x3a43a0[_0x1f241e(0xa9)]:a12_0x3a43a0[_0x1f241e(0xeb)],_0x97c3a7=_0x2afdbd('█'['repeat'](_0x1a9f14))+a12_0x3a43a0[_0x1f241e(0xde)]('░'[_0x1f241e(0xd3)](_0x42255c)),_0x221f90=_0x1225b7>=0x3b9ac9ff?_0x1f241e(0xb1):_0x1225b7['toLocaleString'](),_0xe16112=_0x28f581[_0x1f241e(0xca)]()+_0x1f241e(0xab)+_0x221f90+_0x1f241e(0xd9);process[_0x1f241e(0xd0)][_0x1f241e(0xf0)]('\x0a'),process[_0x1f241e(0xd0)][_0x1f241e(0xf0)](a12_0x3a43a0[_0x1f241e(0xb2)][_0x1f241e(0xa7)]('#60a5fa')('\x20\x20Token\x20Usage\x0a')),process['stdout'][_0x1f241e(0xf0)]('\x20\x20'+_0x97c3a7+'\x20'+a12_0x3a43a0[_0x1f241e(0xde)](_0x53d838+'%')+'\x0a'),process['stdout'][_0x1f241e(0xf0)](a12_0x3a43a0[_0x1f241e(0xde)]('\x20\x20'+_0xe16112+'\x0a')),_0x574787&&process['stdout']['write'](a12_0x3a43a0[_0x1f241e(0xe4)](_0x1f241e(0xa8))),process['stdout']['write']('\x0a');}export function mcpConnected(_0x58651a,_0x2f739a){const _0x17ed20=a12_0x2a2bc8,_0x32873b=_0x58651a===0x1?_0x17ed20(0xd4):_0x17ed20(0xf1);process[_0x17ed20(0xd0)][_0x17ed20(0xf0)](a12_0x3a43a0[_0x17ed20(0xde)]('\x20\x20'+a12_0x3a43a0['hex'](_0x17ed20(0xa3))(_0x58651a[_0x17ed20(0xd5)]())+_0x17ed20(0xaa)+_0x32873b+'\x20connected\x20('+_0x2f739a+_0x17ed20(0xe8)));}export function elapsedTime(_0xe9cc8d){const _0x3d966f=a12_0x2a2bc8,_0x23306e=_0xe9cc8d<0x3c?_0xe9cc8d['toFixed'](0x1)+'s':Math[_0x3d966f(0xbd)](_0xe9cc8d/0x3c)+'m\x20'+(_0xe9cc8d%0x3c)[_0x3d966f(0xef)](0x0)+'s';process[_0x3d966f(0xd0)][_0x3d966f(0xf0)](a12_0x3a43a0['dim'](_0x3d966f(0xc2)+_0x23306e+'\x0a'));}export function currentDir(_0x148341){const _0x5e3828=a12_0x2a2bc8;process[_0x5e3828(0xd0)][_0x5e3828(0xf0)](a12_0x3a43a0['dim']('\x20\x20Working\x20in:\x20')+a12_0x3a43a0[_0x5e3828(0xa7)](_0x5e3828(0xb7))(_0x148341)+'\x0a');}
package/dist/ui/select.js CHANGED
@@ -1 +1 @@
1
- (function(_0x350755,_0x56f757){const _0x1e50c3=a13_0x288c,_0x1b0e9d=_0x350755();while(!![]){try{const _0x3f38e1=-parseInt(_0x1e50c3(0x121))/0x1+-parseInt(_0x1e50c3(0x129))/0x2+parseInt(_0x1e50c3(0x123))/0x3*(parseInt(_0x1e50c3(0x120))/0x4)+parseInt(_0x1e50c3(0x126))/0x5*(parseInt(_0x1e50c3(0x125))/0x6)+parseInt(_0x1e50c3(0x127))/0x7+parseInt(_0x1e50c3(0x122))/0x8+-parseInt(_0x1e50c3(0x12a))/0x9*(parseInt(_0x1e50c3(0x11f))/0xa);if(_0x3f38e1===_0x56f757)break;else _0x1b0e9d['push'](_0x1b0e9d['shift']());}catch(_0x35f7f0){_0x1b0e9d['push'](_0x1b0e9d['shift']());}}}(a13_0x47d1,0xd9b5b));function a13_0x288c(_0x3c572c,_0x47646b){_0x3c572c=_0x3c572c-0x11d;const _0x47d114=a13_0x47d1();let _0x288c54=_0x47d114[_0x3c572c];return _0x288c54;}import{select}from'@inquirer/prompts';import{MODELS}from'../config/settings.js';function a13_0x47d1(){const _0x53ab99=['410IvxbUm','12WcKlEJ','1045347SdGaur','6431408BLUgxC','57153VWZHuf','name','6jOuXeG','2841025eGmvas','11396343DoqWWp','description','96932FuZAQw','235269PnaNLU','Select\x20AI\x20Model','\x20(current)'];a13_0x47d1=function(){return _0x53ab99;};return a13_0x47d1();}import{getSelectedModel,setSelectedModel}from'../utils/storage.js';export async function selectModel(){const _0x3454d5=a13_0x288c,_0x291d79=getSelectedModel(),_0x5c27f7=MODELS['map'](_0x3d8a93=>({'name':''+_0x3d8a93[_0x3454d5(0x124)]+(_0x3d8a93['id']===_0x291d79?_0x3454d5(0x11e):''),'value':_0x3d8a93['id'],'description':_0x3d8a93[_0x3454d5(0x128)]})),_0x8db316=await select({'message':_0x3454d5(0x11d),'choices':_0x5c27f7,'default':_0x291d79});return setSelectedModel(_0x8db316),_0x8db316;}export{getSelectedModel,setSelectedModel};
1
+ (function(_0xdeaa1c,_0x152782){const _0x46e070=a13_0x5aa9,_0x3ee4b5=_0xdeaa1c();while(!![]){try{const _0x2a1c3f=-parseInt(_0x46e070(0x1af))/0x1+parseInt(_0x46e070(0x1b1))/0x2*(parseInt(_0x46e070(0x1ad))/0x3)+-parseInt(_0x46e070(0x1ab))/0x4+parseInt(_0x46e070(0x1aa))/0x5+parseInt(_0x46e070(0x1ae))/0x6+-parseInt(_0x46e070(0x1b2))/0x7*(parseInt(_0x46e070(0x1a5))/0x8)+parseInt(_0x46e070(0x1a9))/0x9*(parseInt(_0x46e070(0x1ac))/0xa);if(_0x2a1c3f===_0x152782)break;else _0x3ee4b5['push'](_0x3ee4b5['shift']());}catch(_0x4ff03c){_0x3ee4b5['push'](_0x3ee4b5['shift']());}}}(a13_0x3538,0x784ac));import{select}from'@inquirer/prompts';function a13_0x5aa9(_0xcbb19b,_0x48ac5e){_0xcbb19b=_0xcbb19b-0x1a4;const _0x3538cc=a13_0x3538();let _0x5aa941=_0x3538cc[_0xcbb19b];return _0x5aa941;}import{MODELS}from'../config/settings.js';function a13_0x3538(){const _0x50cc0f=['44612jyFilG','Select\x20AI\x20Model','52YuHQcI','1183rxFuGw','name','21096ofarzt','\x20(current)','map','description','496809lZHIqF','2173915yFjprZ','3143904xAWLxR','210HvgxVi','1113JOMbcy','991842ZXJpWU'];a13_0x3538=function(){return _0x50cc0f;};return a13_0x3538();}import{getSelectedModel,setSelectedModel}from'../utils/storage.js';export async function selectModel(){const _0x122576=a13_0x5aa9,_0x43f4fd=getSelectedModel(),_0x3e1e73=MODELS[_0x122576(0x1a7)](_0x49c70f=>({'name':''+_0x49c70f[_0x122576(0x1a4)]+(_0x49c70f['id']===_0x43f4fd?_0x122576(0x1a6):''),'value':_0x49c70f['id'],'description':_0x49c70f[_0x122576(0x1a8)]})),_0x420624=await select({'message':_0x122576(0x1b0),'choices':_0x3e1e73,'default':_0x43f4fd});return setSelectedModel(_0x420624),_0x420624;}export{getSelectedModel,setSelectedModel};
@@ -10,7 +10,7 @@ interface ToolCall {
10
10
  name: string;
11
11
  arguments: Record<string, unknown>;
12
12
  }
13
- export declare function sendChatMessage(model: string, messages: ChatMessage[], onChunk?: (chunk: string) => void): Promise<ChatResponse>;
13
+ export declare function sendChatMessage(model: string, messages: ChatMessage[], onChunk?: (chunk: string) => void, signal?: AbortSignal): Promise<ChatResponse>;
14
14
  export declare function checkAuth(): Promise<boolean>;
15
15
  export interface UserUsage {
16
16
  tokensUsed: number;
package/dist/utils/api.js CHANGED
@@ -1 +1 @@
1
- (function(_0x2f701b,_0x5d7053){const _0x3cb281=a14_0x2ac2,_0x57a8be=_0x2f701b();while(!![]){try{const _0x222af4=-parseInt(_0x3cb281(0x184))/0x1*(parseInt(_0x3cb281(0x186))/0x2)+parseInt(_0x3cb281(0x17b))/0x3*(parseInt(_0x3cb281(0x1ae))/0x4)+parseInt(_0x3cb281(0x1b1))/0x5*(parseInt(_0x3cb281(0x1a9))/0x6)+-parseInt(_0x3cb281(0x187))/0x7*(parseInt(_0x3cb281(0x18d))/0x8)+-parseInt(_0x3cb281(0x1a2))/0x9*(-parseInt(_0x3cb281(0x1a3))/0xa)+-parseInt(_0x3cb281(0x1a4))/0xb+parseInt(_0x3cb281(0x1b2))/0xc;if(_0x222af4===_0x5d7053)break;else _0x57a8be['push'](_0x57a8be['shift']());}catch(_0x1b8813){_0x57a8be['push'](_0x57a8be['shift']());}}}(a14_0xafba,0x65ccb));import{getApiUrl}from'../config/settings.js';import{getToken,getUser}from'./storage.js';import a14_0x591841 from'crypto';import a14_0x308644 from'fs';function a14_0x2ac2(_0x47328d,_0x2fd2fd){_0x47328d=_0x47328d-0x17b;const _0xafba2=a14_0xafba();let _0x2ac2dd=_0xafba2[_0x47328d];return _0x2ac2dd;}import a14_0x2257d1 from'path';import{dirname}from'path';import{fileURLToPath}from'url';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function getDecryptedSecret(){const _0x52a1db=a14_0x2ac2;try{const _0x3438ea=[a14_0x2257d1[_0x52a1db(0x1aa)](__dirname,_0x52a1db(0x17c)),a14_0x2257d1['join'](__dirname,_0x52a1db(0x1b0)),a14_0x2257d1[_0x52a1db(0x1aa)](__dirname,_0x52a1db(0x17d)),a14_0x2257d1[_0x52a1db(0x1aa)](process['cwd'](),'env.woozlit')];let _0x4cdb07='';for(const _0x31fa02 of _0x3438ea){if(a14_0x308644[_0x52a1db(0x190)](_0x31fa02)){_0x4cdb07=a14_0x308644[_0x52a1db(0x185)](_0x31fa02,_0x52a1db(0x198))[_0x52a1db(0x18b)]();break;}}if(!_0x4cdb07)return reconstructSecret();const [_0x4d781a,_0x10b6e6]=_0x4cdb07[_0x52a1db(0x183)](':');if(!_0x4d781a||!_0x10b6e6)return reconstructSecret();const _0x4324cb=Buffer[_0x52a1db(0x1a7)](_0x4d781a,_0x52a1db(0x1a5)),_0x2ad42d=a14_0x591841[_0x52a1db(0x192)](_0x52a1db(0x19b))[_0x52a1db(0x188)](_0x52a1db(0x191))[_0x52a1db(0x1b4)](),_0x134acd=a14_0x591841[_0x52a1db(0x17e)](_0x52a1db(0x193),_0x2ad42d,_0x4324cb);let _0x5cb257=_0x134acd['update'](_0x10b6e6,_0x52a1db(0x1a5),'utf8');return _0x5cb257+=_0x134acd[_0x52a1db(0x1b3)](_0x52a1db(0x198)),_0x5cb257;}catch(_0x1f3a0c){return reconstructSecret();}}function reconstructSecret(){const _0xcd2096=a14_0x2ac2,_0x7ea7b7=[0x77,0x7a,0x5f,0x63,0x6c,0x69,0x5f,0x70,0x72,0x6f,0x64,0x5f]['map'](_0x17f0a7=>String['fromCharCode'](_0x17f0a7))[_0xcd2096(0x1aa)](''),_0x263f33=String['fromCharCode'](0x73,0x33,0x63,0x72,0x33,0x74,0x5f,0x78,0x39,0x32,0x5f),_0x21706a=(0x8*0x186a0+0x26610+0x190+0x32+0x6)['toString'](0x10)+'e5c'+(0x4*0xa+0x3)['toString'](0x10)+_0xcd2096(0x18a),_0x5ce8bc=['s','e','c','u','r','e','_','h','a','s','h'][_0xcd2096(0x1aa)]('');return _0x7ea7b7+_0x263f33+_0xcd2096(0x1a0)+_0x21706a[_0xcd2096(0x195)](0x5)+_0x5ce8bc;}export async function sendChatMessage(_0x598ebb,_0x586eaf,_0x182f0b){const _0x1c9f20=a14_0x2ac2,_0xc4cc9c=getToken(),_0x232765=getApiUrl(),{userId:_0x2e9e9f}=getUser();if(!_0xc4cc9c||!_0x2e9e9f)throw new Error('Not\x20authenticated.\x20Please\x20run\x20\x27woozlit\x20login\x27\x20first.');const _0x50fc0c=_0x1c9f20(0x1a1)+Date[_0x1c9f20(0x196)]()+'-'+Math[_0x1c9f20(0x19a)]()[_0x1c9f20(0x19c)](0x24)[_0x1c9f20(0x195)](0x2,0x9),_0x274016=process[_0x1c9f20(0x17f)]+'-'+process['arch']+'-'+process[_0x1c9f20(0x1ad)],_0x233873=getDecryptedSecret(),_0x187702=await fetch(_0x232765+_0x1c9f20(0x180),{'method':_0x1c9f20(0x19f),'headers':{'Content-Type':_0x1c9f20(0x1b5),'X-Woozlit-CLI':'true','X-Woozlit-CLI-Version':_0x1c9f20(0x182),'X-Request-ID':_0x50fc0c,'X-Device-Fingerprint':_0x274016,'Authorization':_0x1c9f20(0x18e)+_0xc4cc9c,'X-Woozlit-Token':'Bearer\x20'+_0xc4cc9c,'Origin':'https://woozlit.com','X-Woozlit-App-Secret':_0x233873},'body':JSON[_0x1c9f20(0x199)]({'model':_0x598ebb,'messages':_0x586eaf,'stream':!![],'userId':_0x2e9e9f})});if(!_0x187702['ok']){const _0x34433c=await _0x187702[_0x1c9f20(0x1ac)]();throw new Error(_0x1c9f20(0x18f)+_0x187702['status']+_0x1c9f20(0x181)+_0x34433c);}if(!_0x187702[_0x1c9f20(0x1a8)])throw new Error('No\x20response\x20body');const _0x27f4a0=_0x187702[_0x1c9f20(0x1a8)]['getReader'](),_0x32ecb4=new TextDecoder();let _0x46cd64='';const _0x385891=[];while(!![]){const {done:_0x50cf71,value:_0x3eb3f1}=await _0x27f4a0[_0x1c9f20(0x19e)]();if(_0x50cf71)break;const _0xe43ea6=_0x32ecb4[_0x1c9f20(0x194)](_0x3eb3f1,{'stream':!![]});if(_0xe43ea6[_0x1c9f20(0x1ab)]('0:')){const _0x129fd8=_0xe43ea6[_0x1c9f20(0x183)]('\x0a');for(const _0x1c0ace of _0x129fd8){if(_0x1c0ace[_0x1c9f20(0x19d)]('0:')){const _0x456dab=_0x1c0ace[_0x1c9f20(0x1af)](0x2)[_0x1c9f20(0x18b)]();if(_0x456dab[_0x1c9f20(0x19d)]('\x22')&&_0x456dab[_0x1c9f20(0x1a6)]('\x22'))try{const _0x48fdbb=JSON[_0x1c9f20(0x189)](_0x456dab);_0x46cd64+=_0x48fdbb;if(_0x182f0b)_0x182f0b(_0x48fdbb);}catch{}}}}else{_0x46cd64+=_0xe43ea6;if(_0x182f0b)_0x182f0b(_0xe43ea6);}}return{'content':_0x46cd64,'toolCalls':_0x385891};}export async function checkAuth(){const _0x21c86d=a14_0x2ac2,_0x45aca0=getToken();if(!_0x45aca0)return![];try{const _0x2c071c=getApiUrl(),_0x4ec38d=await fetch(_0x2c071c+_0x21c86d(0x18c),{'headers':{'Authorization':_0x21c86d(0x18e)+_0x45aca0}});return _0x4ec38d['ok'];}catch{return![];}}export async function getUserUsage(){const _0x586fdb=a14_0x2ac2,_0x3c941e=getToken();if(!_0x3c941e)return null;try{const _0x104b93=getApiUrl(),_0xfe8333=await fetch(_0x104b93+'/api/user/usage',{'headers':{'Authorization':_0x586fdb(0x18e)+_0x3c941e}});if(!_0xfe8333['ok'])return null;return await _0xfe8333[_0x586fdb(0x197)]();}catch(_0x1767a2){return null;}}function a14_0xafba(){const _0x5729b5=['body','11058eHNYdW','join','includes','text','version','60628CTdBtx','slice','../../../env.woozlit','1585VXaATZ','734952Dgdcuq','final','digest','application/json','6NRKOIT','../../env.woozlit','../env.woozlit','createDecipheriv','platform','/api/chat','\x20-\x20','1.1.0','split','50729OAdtJm','readFileSync','2OHIJGE','2954NmYwIc','update','parse','3a2_','trim','/api/auth/verify','1520NsfRQc','Bearer\x20','API\x20error:\x20','existsSync','woozlit_internal_secure_key_2026_v2_!!!','createHash','aes-256-cbc','decode','substring','now','json','utf8','stringify','random','sha256','toString','startsWith','read','POST','8f7d6','cli-','2856069UfhiWg','20IrodKg','8388523AGyrXa','hex','endsWith','from'];a14_0xafba=function(){return _0x5729b5;};return a14_0xafba();}
1
+ (function(_0x496415,_0x2c3e27){const _0x46860c=a14_0x329d,_0x2c0ff5=_0x496415();while(!![]){try{const _0x10927e=-parseInt(_0x46860c(0xf5))/0x1+parseInt(_0x46860c(0x113))/0x2+-parseInt(_0x46860c(0xfb))/0x3*(-parseInt(_0x46860c(0x111))/0x4)+parseInt(_0x46860c(0xef))/0x5+parseInt(_0x46860c(0x108))/0x6+parseInt(_0x46860c(0x106))/0x7+parseInt(_0x46860c(0x109))/0x8*(-parseInt(_0x46860c(0xff))/0x9);if(_0x10927e===_0x2c3e27)break;else _0x2c0ff5['push'](_0x2c0ff5['shift']());}catch(_0x54f02f){_0x2c0ff5['push'](_0x2c0ff5['shift']());}}}(a14_0x3ca6,0xa6ed9));import{getApiUrl}from'../config/settings.js';import{getToken,getUser}from'./storage.js';import a14_0x2593a5 from'crypto';import a14_0x3c01bd from'fs';import a14_0x17d970 from'path';import{dirname}from'path';import{fileURLToPath}from'url';function a14_0x329d(_0x12ff1c,_0x4ce0ac){_0x12ff1c=_0x12ff1c-0xe8;const _0x3ca629=a14_0x3ca6();let _0x329ddd=_0x3ca629[_0x12ff1c];return _0x329ddd;}const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function getDecryptedSecret(){const _0x5b59e2=a14_0x329d;try{const _0x356519=[a14_0x17d970['join'](__dirname,_0x5b59e2(0x10a)),a14_0x17d970[_0x5b59e2(0x104)](__dirname,_0x5b59e2(0x11b)),a14_0x17d970[_0x5b59e2(0x104)](__dirname,'../env.woozlit'),a14_0x17d970['join'](process[_0x5b59e2(0xf7)](),_0x5b59e2(0x101))];let _0x330a64='';for(const _0x25f198 of _0x356519){if(a14_0x3c01bd[_0x5b59e2(0xf3)](_0x25f198)){_0x330a64=a14_0x3c01bd[_0x5b59e2(0x100)](_0x25f198,'utf8')[_0x5b59e2(0xee)]();break;}}if(!_0x330a64)return reconstructSecret();const [_0xb5b833,_0x495caf]=_0x330a64[_0x5b59e2(0x103)](':');if(!_0xb5b833||!_0x495caf)return reconstructSecret();const _0x4f665d=Buffer[_0x5b59e2(0xf9)](_0xb5b833,_0x5b59e2(0x10c)),_0x482319=a14_0x2593a5[_0x5b59e2(0xec)](_0x5b59e2(0x10d))['update'](_0x5b59e2(0xf1))['digest'](),_0x2b51d6=a14_0x2593a5['createDecipheriv'](_0x5b59e2(0xf6),_0x482319,_0x4f665d);let _0x373a42=_0x2b51d6[_0x5b59e2(0xea)](_0x495caf,_0x5b59e2(0x10c),_0x5b59e2(0x102));return _0x373a42+=_0x2b51d6[_0x5b59e2(0x114)](_0x5b59e2(0x102)),_0x373a42;}catch(_0x5d81bd){return reconstructSecret();}}function reconstructSecret(){const _0x173a12=a14_0x329d,_0x370bcb=[0x77,0x7a,0x5f,0x63,0x6c,0x69,0x5f,0x70,0x72,0x6f,0x64,0x5f][_0x173a12(0x116)](_0x24249d=>String[_0x173a12(0x115)](_0x24249d))[_0x173a12(0x104)](''),_0x23a41b=String[_0x173a12(0x115)](0x73,0x33,0x63,0x72,0x33,0x74,0x5f,0x78,0x39,0x32,0x5f),_0x31c3ca=(0x8*0x186a0+0x26610+0x190+0x32+0x6)['toString'](0x10)+_0x173a12(0xeb)+(0x4*0xa+0x3)[_0x173a12(0xfc)](0x10)+_0x173a12(0x117),_0x1f168f=['s','e','c','u','r','e','_','h','a','s','h'][_0x173a12(0x104)]('');return _0x370bcb+_0x23a41b+_0x173a12(0xf8)+_0x31c3ca[_0x173a12(0x10f)](0x5)+_0x1f168f;}export async function sendChatMessage(_0x2df677,_0x58742e,_0x5bc229,_0x4f05f9){const _0x4e251a=a14_0x329d,_0x22a008=getToken(),_0x1ec4fa=getApiUrl(),{userId:_0x3f6e58}=getUser();if(!_0x22a008||!_0x3f6e58)throw new Error(_0x4e251a(0x11a));const _0x53f1e7=_0x4e251a(0xf0)+Date[_0x4e251a(0x11c)]()+'-'+Math[_0x4e251a(0x119)]()[_0x4e251a(0xfc)](0x24)[_0x4e251a(0x10f)](0x2,0x9),_0x61afa0=process[_0x4e251a(0xf2)]+'-'+process[_0x4e251a(0x105)]+'-'+process['version'],_0x4c546d=getDecryptedSecret(),_0x510a96=await fetch(_0x1ec4fa+_0x4e251a(0x11d),{'method':'POST','headers':{'Content-Type':_0x4e251a(0x118),'X-Woozlit-CLI':_0x4e251a(0xfa),'X-Woozlit-CLI-Version':_0x4e251a(0x10e),'X-Request-ID':_0x53f1e7,'X-Device-Fingerprint':_0x61afa0,'Authorization':_0x4e251a(0x110)+_0x22a008,'X-Woozlit-Token':_0x4e251a(0x110)+_0x22a008,'Origin':_0x4e251a(0xf4),'X-Woozlit-App-Secret':_0x4c546d},'body':JSON[_0x4e251a(0xe9)]({'model':_0x2df677,'messages':_0x58742e,'stream':!![],'userId':_0x3f6e58}),'signal':_0x4f05f9});if(!_0x510a96['ok']){const _0x31aff3=await _0x510a96['text']();throw new Error(_0x4e251a(0x120)+_0x510a96[_0x4e251a(0x10b)]+'\x20-\x20'+_0x31aff3);}if(!_0x510a96['body'])throw new Error(_0x4e251a(0xfd));const _0x521e81=_0x510a96['body']['getReader'](),_0x43f4b0=new TextDecoder();let _0x52ee19='';const _0x183de2=[];while(!![]){const {done:_0x925bb2,value:_0x44a274}=await _0x521e81['read']();if(_0x925bb2)break;const _0x343964=_0x43f4b0[_0x4e251a(0xfe)](_0x44a274,{'stream':!![]});if(_0x343964[_0x4e251a(0xed)]('0:')){const _0x5f21bd=_0x343964[_0x4e251a(0x103)]('\x0a');for(const _0x2840c9 of _0x5f21bd){if(_0x2840c9['startsWith']('0:')){const _0x327218=_0x2840c9['slice'](0x2)[_0x4e251a(0xee)]();if(_0x327218[_0x4e251a(0x107)]('\x22')&&_0x327218[_0x4e251a(0x112)]('\x22'))try{const _0x1c33d5=JSON['parse'](_0x327218);_0x52ee19+=_0x1c33d5;if(_0x5bc229)_0x5bc229(_0x1c33d5);}catch{}}}}else{_0x52ee19+=_0x343964;if(_0x5bc229)_0x5bc229(_0x343964);}}return{'content':_0x52ee19,'toolCalls':_0x183de2};}export async function checkAuth(){const _0x2514f9=a14_0x329d,_0x2ba7da=getToken();if(!_0x2ba7da)return![];try{const _0x188761=getApiUrl(),_0xf5b480=await fetch(_0x188761+_0x2514f9(0x11f),{'headers':{'Authorization':_0x2514f9(0x110)+_0x2ba7da}});return _0xf5b480['ok'];}catch{return![];}}export async function getUserUsage(){const _0x4d7787=a14_0x329d,_0x183a8d=getToken();if(!_0x183a8d)return null;try{const _0x325e74=getApiUrl(),_0x1df2e9=await fetch(_0x325e74+_0x4d7787(0xe8),{'headers':{'Authorization':_0x4d7787(0x110)+_0x183a8d}});if(!_0x1df2e9['ok'])return null;return await _0x1df2e9[_0x4d7787(0x11e)]();}catch(_0x506f9f){return null;}}function a14_0x3ca6(){const _0x204e41=['random','Not\x20authenticated.\x20Please\x20run\x20\x27woozlit\x20login\x27\x20first.','../../../env.woozlit','now','/api/chat','json','/api/auth/verify','API\x20error:\x20','/api/user/usage','stringify','update','e5c','createHash','includes','trim','1715150DUbXIo','cli-','woozlit_internal_secure_key_2026_v2_!!!','platform','existsSync','https://woozlit.com','1253874rxsmEF','aes-256-cbc','cwd','8f7d6','from','true','240MbRLRL','toString','No\x20response\x20body','decode','63xTLGwW','readFileSync','env.woozlit','utf8','split','join','arch','3993087gYmazY','startsWith','3800328wOQILf','629968KkKzYV','../../env.woozlit','status','hex','sha256','1.1.0','substring','Bearer\x20','38644zdWmWW','endsWith','338188AQcpBL','final','fromCharCode','map','3a2_','application/json'];a14_0x3ca6=function(){return _0x204e41;};return a14_0x3ca6();}
@@ -1 +1 @@
1
- function a15_0x4dbc(){const _0x484306=['get','woozlit-cli-history','104NyRWLT','2569986DhaVPi','50rLUwxu','27706zIFnya','50mqnuFT','7846648TyZhJA','383324fMaJIo','12159588LUwgKL','filter','3027798FknPeb','entries','2184426umIowr','now','lastCleanup','push','set','timestamp','message'];a15_0x4dbc=function(){return _0x484306;};return a15_0x4dbc();}const a15_0x5d1ca5=a15_0x4d5e;(function(_0x2ac6b4,_0x42b74e){const _0x1f26ea=a15_0x4d5e,_0x3619ff=_0x2ac6b4();while(!![]){try{const _0x4659c4=-parseInt(_0x1f26ea(0x7d))/0x1*(parseInt(_0x1f26ea(0x7a))/0x2)+-parseInt(_0x1f26ea(0x83))/0x3+-parseInt(_0x1f26ea(0x80))/0x4*(-parseInt(_0x1f26ea(0x7e))/0x5)+parseInt(_0x1f26ea(0x7b))/0x6+parseInt(_0x1f26ea(0x81))/0x7+-parseInt(_0x1f26ea(0x7f))/0x8+-parseInt(_0x1f26ea(0x71))/0x9*(-parseInt(_0x1f26ea(0x7c))/0xa);if(_0x4659c4===_0x42b74e)break;else _0x3619ff['push'](_0x3619ff['shift']());}catch(_0x469057){_0x3619ff['push'](_0x3619ff['shift']());}}}(a15_0x4dbc,0xdd4f6));import a15_0x3a2138 from'conf';const WEEK_MS=0x7*0x18*0x3c*0x3c*0x3e8,config=new a15_0x3a2138({'projectName':a15_0x5d1ca5(0x79),'defaults':{'entries':[],'lastCleanup':Date['now']()}});function a15_0x4d5e(_0xea6f10,_0x5df33a){_0xea6f10=_0xea6f10-0x70;const _0x4dbcc5=a15_0x4dbc();let _0x4d5ea9=_0x4dbcc5[_0xea6f10];return _0x4d5ea9;}function cleanup(){const _0x16d2e3=a15_0x5d1ca5,_0x195cdc=Date[_0x16d2e3(0x72)](),_0x2c80a5=config[_0x16d2e3(0x78)](_0x16d2e3(0x73));if(_0x195cdc-_0x2c80a5<0x18*0x3c*0x3c*0x3e8)return;const _0x2717eb=config[_0x16d2e3(0x78)](_0x16d2e3(0x70)),_0x54808c=_0x2717eb[_0x16d2e3(0x82)](_0x1052e0=>_0x195cdc-_0x1052e0[_0x16d2e3(0x76)]<WEEK_MS);config[_0x16d2e3(0x75)](_0x16d2e3(0x70),_0x54808c),config[_0x16d2e3(0x75)]('lastCleanup',_0x195cdc);}export function addToHistory(_0x4bd5e7){const _0x45126c=a15_0x5d1ca5;cleanup();const _0x2f7ecd=config['get'](_0x45126c(0x70));_0x2f7ecd[_0x45126c(0x74)]({'message':_0x4bd5e7,'timestamp':Date[_0x45126c(0x72)]()});if(_0x2f7ecd['length']>0x64)_0x2f7ecd['shift']();config[_0x45126c(0x75)](_0x45126c(0x70),_0x2f7ecd);}export function getHistory(){const _0x27aa7e=a15_0x5d1ca5;return cleanup(),config[_0x27aa7e(0x78)](_0x27aa7e(0x70))['map'](_0x454444=>_0x454444[_0x27aa7e(0x77)]);}export function clearHistory(){const _0x3dcf86=a15_0x5d1ca5;config[_0x3dcf86(0x75)]('entries',[]);}
1
+ const a15_0x174f7f=a15_0x45ab;(function(_0x2d3766,_0x51e402){const _0x15f592=a15_0x45ab,_0x1ba1b0=_0x2d3766();while(!![]){try{const _0x18e409=-parseInt(_0x15f592(0xec))/0x1*(parseInt(_0x15f592(0xf5))/0x2)+parseInt(_0x15f592(0xee))/0x3+-parseInt(_0x15f592(0xf6))/0x4+-parseInt(_0x15f592(0xf2))/0x5*(parseInt(_0x15f592(0xfc))/0x6)+parseInt(_0x15f592(0xff))/0x7*(-parseInt(_0x15f592(0xf0))/0x8)+-parseInt(_0x15f592(0xef))/0x9+parseInt(_0x15f592(0xed))/0xa;if(_0x18e409===_0x51e402)break;else _0x1ba1b0['push'](_0x1ba1b0['shift']());}catch(_0x323906){_0x1ba1b0['push'](_0x1ba1b0['shift']());}}}(a15_0x2f75,0x83b74));import a15_0x4cc56a from'conf';const WEEK_MS=0x7*0x18*0x3c*0x3c*0x3e8,config=new a15_0x4cc56a({'projectName':a15_0x174f7f(0xfb),'defaults':{'entries':[],'lastCleanup':Date['now']()}});function cleanup(){const _0x90293=a15_0x174f7f,_0x4cf8cf=Date[_0x90293(0xfe)](),_0x39d89d=config['get'](_0x90293(0xf9));if(_0x4cf8cf-_0x39d89d<0x18*0x3c*0x3c*0x3e8)return;const _0xed8c92=config[_0x90293(0xf3)](_0x90293(0xfa)),_0x134f7e=_0xed8c92[_0x90293(0xf7)](_0x1861f1=>_0x4cf8cf-_0x1861f1[_0x90293(0xf8)]<WEEK_MS);config[_0x90293(0xf1)](_0x90293(0xfa),_0x134f7e),config[_0x90293(0xf1)]('lastCleanup',_0x4cf8cf);}export function addToHistory(_0x5ebf29){const _0x7d92f1=a15_0x174f7f;cleanup();const _0x39f931=config['get'](_0x7d92f1(0xfa));_0x39f931['push']({'message':_0x5ebf29,'timestamp':Date[_0x7d92f1(0xfe)]()});if(_0x39f931['length']>0x64)_0x39f931['shift']();config['set'](_0x7d92f1(0xfa),_0x39f931);}export function getHistory(){const _0x162a13=a15_0x174f7f;return cleanup(),config[_0x162a13(0xf3)]('entries')[_0x162a13(0xf4)](_0x36e8ae=>_0x36e8ae[_0x162a13(0xfd)]);}function a15_0x2f75(){const _0x17bf2e=['lastCleanup','entries','woozlit-cli-history','1608YWEHAb','message','now','42VndOaV','747eyXOhb','14347300YIdEIe','2267187kmXZmP','5473557wujXQC','43528PCNPVT','set','8355QvOJEI','get','map','294mdmQLf','1809980IOnldy','filter','timestamp'];a15_0x2f75=function(){return _0x17bf2e;};return a15_0x2f75();}function a15_0x45ab(_0x23ca84,_0x3aa8f7){_0x23ca84=_0x23ca84-0xec;const _0x2f75e5=a15_0x2f75();let _0x45aba6=_0x2f75e5[_0x23ca84];return _0x45aba6;}export function clearHistory(){const _0xc8701e=a15_0x174f7f;config['set'](_0xc8701e(0xfa),[]);}
@@ -1 +1 @@
1
- function a16_0x9dee(){const _0x3a5ebb=['parse','chrome','slice','Could\x20not\x20auto-detect\x20entry\x20point.\x20Please\x20add\x20the\x20server\x20manually\x20using\x20\x27woozlit\x20mcp\x20add\x27.','tsx','main','Installing\x20mcp-chrome-bridge\x20globally...','homedir','header','1253413MvVHTo','pnpm\x20add\x20-g\x20mcp-chrome-bridge','\x20already\x20exists.\x20Updating...','bin','...','Failed\x20to\x20update\x20repo.\x20Try\x20checking\x20it\x20out\x20manually\x20or\x20deleting\x20the\x20folder.','object','3464585qamRJb','Detected\x20entry\x20point:\x20','build/index.js','3.\x20Click\x20extension\x20icon\x20and\x20\x27Connect\x27','506248RDyctI','node','git\x20pull','1.\x20Download\x20the\x20Chrome\x20Extension:\x20https://github.com/hangwin/mcp-chrome/releases','mcp-chrome','utf-8','2.\x20Load\x20unpacked\x20extension\x20in\x20Chrome\x20Developer\x20Mode','3aRxXaA','error','package.json','11bRQzne','info','existsSync','http://127.0.0.1:12306/mcp','2721012yUDYHs','Directory\x20','Try\x20running\x20with\x20sudo\x20or\x20administrative\x20privileges.','505097WPnLVj','Installing\x20dependencies...','npm\x20install','4.\x20Make\x20sure\x20\x27mcp-chrome-bridge\x27\x20is\x20running\x20(if\x20not\x20started\x20automatically)','scripts','15104970UHiydT','git\x20clone\x20','Building\x20project...','mcp-chrome-bridge','keys','join','Trying\x20npm\x20as\x20fallback...','.ts','Failed\x20to\x20install\x20mcp-chrome-bridge:\x20','dist/index.js','src/index.ts','pnpm-lock.yaml','pnpm','.git','warn','\x20to\x20','index.js','success','length','54kTIJRi','endsWith','\x20run\x20build','Failed\x20to\x20install\x20mcp-chrome-bridge\x20using\x20pnpm:\x20','inherit','build','yarn\x20install','npm','yarn','test','mkdirSync','12GLRdXK','692334MCCgnY'];a16_0x9dee=function(){return _0x3a5ebb;};return a16_0x9dee();}const a16_0x379fb1=a16_0xbf0a;(function(_0x2cb760,_0x5d2c5e){const _0x4ebab3=a16_0xbf0a,_0x30b740=_0x2cb760();while(!![]){try{const _0x1791d0=-parseInt(_0x4ebab3(0xb3))/0x1+parseInt(_0x4ebab3(0x8d))/0x2*(parseInt(_0x4ebab3(0xa9))/0x3)+parseInt(_0x4ebab3(0xb0))/0x4+parseInt(_0x4ebab3(0x9e))/0x5+parseInt(_0x4ebab3(0x8c))/0x6*(parseInt(_0x4ebab3(0x97))/0x7)+-parseInt(_0x4ebab3(0xa2))/0x8*(-parseInt(_0x4ebab3(0x81))/0x9)+-parseInt(_0x4ebab3(0xb8))/0xa*(parseInt(_0x4ebab3(0xac))/0xb);if(_0x1791d0===_0x5d2c5e)break;else _0x30b740['push'](_0x30b740['shift']());}catch(_0x5039e4){_0x30b740['push'](_0x30b740['shift']());}}}(a16_0x9dee,0x6bccb));import{execSync}from'child_process';function a16_0xbf0a(_0x28f318,_0xf55c37){_0x28f318=_0x28f318-0x7f;const _0x9deec6=a16_0x9dee();let _0xbf0a3a=_0x9deec6[_0x28f318];return _0xbf0a3a;}import a16_0x49817e from'path';import a16_0x1d1edb from'fs';import a16_0x5c6b27 from'os';import*as a16_0x360544 from'../ui/output.js';import{addMcpServer,addMcpHttpServer}from'../config/mcp.js';const SERVERS_DIR=a16_0x49817e[a16_0x379fb1(0xbd)](a16_0x5c6b27[a16_0x379fb1(0x95)](),'.woozlit','servers');function ensureServersDir(){const _0x16affb=a16_0x379fb1;!a16_0x1d1edb[_0x16affb(0xae)](SERVERS_DIR)&&a16_0x1d1edb[_0x16affb(0x8b)](SERVERS_DIR,{'recursive':!![]});}function getRepoName(_0x32945d){const _0x23bd0c=a16_0x379fb1,_0x1d4b35=_0x32945d['split']('/');let _0x2ca2fb=_0x1d4b35[_0x1d4b35[_0x23bd0c(0x80)]-0x1];return _0x2ca2fb['endsWith'](_0x23bd0c(0xc5))&&(_0x2ca2fb=_0x2ca2fb[_0x23bd0c(0x90)](0x0,-0x4)),_0x2ca2fb;}async function installFromGithub(_0x6817f1,_0x4fb3d1){const _0x3d6ae2=a16_0x379fb1;ensureServersDir();const _0x29a5cd=_0x4fb3d1||getRepoName(_0x6817f1),_0x3500b0=a16_0x49817e['join'](SERVERS_DIR,_0x29a5cd);a16_0x360544[_0x3d6ae2(0xad)]('Cloning\x20'+_0x6817f1+_0x3d6ae2(0xc7)+_0x3500b0+_0x3d6ae2(0x9b));if(a16_0x1d1edb['existsSync'](_0x3500b0)){a16_0x360544[_0x3d6ae2(0xc6)](_0x3d6ae2(0xb1)+_0x3500b0+_0x3d6ae2(0x99));try{execSync(_0x3d6ae2(0xa4),{'cwd':_0x3500b0,'stdio':_0x3d6ae2(0x85)});}catch(_0x564a80){a16_0x360544[_0x3d6ae2(0xaa)](_0x3d6ae2(0x9c));return;}}else try{execSync(_0x3d6ae2(0xb9)+_0x6817f1+'\x20'+_0x3500b0,{'stdio':'inherit'});}catch(_0x451fab){a16_0x360544[_0x3d6ae2(0xaa)]('Failed\x20to\x20clone\x20repository:\x20'+_0x451fab);return;}a16_0x360544[_0x3d6ae2(0xad)](_0x3d6ae2(0xb4));try{const _0x5aa32a=a16_0x1d1edb[_0x3d6ae2(0xae)](a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0x3d6ae2(0xc3))),_0x28b292=a16_0x1d1edb[_0x3d6ae2(0xae)](a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,'yarn.lock')),_0x3f5297=_0x5aa32a?'pnpm\x20install':_0x28b292?_0x3d6ae2(0x87):_0x3d6ae2(0xb5);execSync(_0x3f5297,{'cwd':_0x3500b0,'stdio':_0x3d6ae2(0x85)});const _0x4f7442=a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0x3d6ae2(0xab));if(a16_0x1d1edb[_0x3d6ae2(0xae)](_0x4f7442)){const _0x1867ac=JSON['parse'](a16_0x1d1edb['readFileSync'](_0x4f7442,_0x3d6ae2(0xa7)));_0x1867ac[_0x3d6ae2(0xb7)]&&_0x1867ac[_0x3d6ae2(0xb7)][_0x3d6ae2(0x86)]&&(a16_0x360544['info'](_0x3d6ae2(0xba)),execSync((_0x5aa32a?_0x3d6ae2(0xc4):_0x28b292?_0x3d6ae2(0x89):_0x3d6ae2(0x88))+_0x3d6ae2(0x83),{'cwd':_0x3500b0,'stdio':_0x3d6ae2(0x85)}));}}catch(_0x5bd6f9){a16_0x360544[_0x3d6ae2(0xaa)]('Failed\x20to\x20install/build:\x20'+_0x5bd6f9);return;}const _0x17b9e8=a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0x3d6ae2(0xab));let _0x5e14e7='';if(a16_0x1d1edb['existsSync'](_0x17b9e8)){const _0xc11bd9=JSON[_0x3d6ae2(0x8e)](a16_0x1d1edb['readFileSync'](_0x17b9e8,_0x3d6ae2(0xa7)));if(_0xc11bd9[_0x3d6ae2(0x9a)]){if(typeof _0xc11bd9[_0x3d6ae2(0x9a)]==='string')_0x5e14e7=a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0xc11bd9['bin']);else{if(typeof _0xc11bd9[_0x3d6ae2(0x9a)]===_0x3d6ae2(0x9d)){const _0x2f6a50=Object[_0x3d6ae2(0xbc)](_0xc11bd9['bin'])[0x0];_0x5e14e7=a16_0x49817e['join'](_0x3500b0,_0xc11bd9[_0x3d6ae2(0x9a)][_0x2f6a50]);}}}else _0xc11bd9[_0x3d6ae2(0x93)]&&(_0x5e14e7=a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0xc11bd9[_0x3d6ae2(0x93)]));}if(!_0x5e14e7){const _0x4630ed=[_0x3d6ae2(0xc1),_0x3d6ae2(0xa0),_0x3d6ae2(0xc2),_0x3d6ae2(0xc8)];for(const _0x5e97b8 of _0x4630ed){if(a16_0x1d1edb[_0x3d6ae2(0xae)](a16_0x49817e[_0x3d6ae2(0xbd)](_0x3500b0,_0x5e97b8))){_0x5e14e7=a16_0x49817e['join'](_0x3500b0,_0x5e97b8);break;}}}if(!_0x5e14e7){a16_0x360544['error'](_0x3d6ae2(0x91));return;}const _0x254e91=_0x5e14e7['endsWith'](_0x3d6ae2(0xbf))?_0x3d6ae2(0x92):_0x3d6ae2(0xa3);a16_0x360544['info'](_0x3d6ae2(0x9f)+_0x5e14e7),addMcpServer(_0x29a5cd,_0x254e91,[_0x5e14e7]),a16_0x360544[_0x3d6ae2(0x7f)]('Successfully\x20installed\x20and\x20added\x20\x27'+_0x29a5cd+'\x27\x20from\x20GitHub!');}async function installMcpChromeBridge(){const _0x2cfa91=a16_0x379fb1;a16_0x360544[_0x2cfa91(0xad)](_0x2cfa91(0x94));try{execSync(_0x2cfa91(0x98),{'stdio':_0x2cfa91(0x85)});}catch(_0x12c6ac){a16_0x360544[_0x2cfa91(0xaa)](_0x2cfa91(0x84)+_0x12c6ac),a16_0x360544['info'](_0x2cfa91(0xbe));try{execSync('npm\x20install\x20-g\x20mcp-chrome-bridge',{'stdio':'inherit'});}catch(_0x3c122a){a16_0x360544[_0x2cfa91(0xaa)](_0x2cfa91(0xc0)+_0x3c122a),a16_0x360544[_0x2cfa91(0xad)](_0x2cfa91(0xb2));return;}}const _0x266173=_0x2cfa91(0xaf);addMcpHttpServer(_0x2cfa91(0xa6),_0x266173),a16_0x360544['success']('Installed\x20mcp-chrome-bridge\x20and\x20added\x20configuration!'),a16_0x360544[_0x2cfa91(0x96)]('Next\x20Steps:'),a16_0x360544['info'](_0x2cfa91(0xa5)),a16_0x360544['info'](_0x2cfa91(0xa8)),a16_0x360544['info'](_0x2cfa91(0xa1)),a16_0x360544[_0x2cfa91(0xad)](_0x2cfa91(0xb6));}export async function installMcpServer(_0x170eda,_0x2fc660){const _0x2caa6a=a16_0x379fb1;if(_0x170eda===_0x2caa6a(0xbb)||_0x170eda===_0x2caa6a(0x8f))return installMcpChromeBridge();if(_0x170eda['includes']('github.com')||_0x170eda[_0x2caa6a(0x82)]('.git'))return installFromGithub(_0x170eda,_0x2fc660);if(/^[a-zA-Z0-9_-]+\/[a-zA-Z0-9_-]+$/[_0x2caa6a(0x8a)](_0x170eda))return installFromGithub('https://github.com/'+_0x170eda+_0x2caa6a(0xc5),_0x2fc660);a16_0x360544[_0x2caa6a(0xaa)]('Unknown\x20installation\x20source.\x20Please\x20provide\x20a\x20GitHub\x20URL\x20or\x20\x27mcp-chrome-bridge\x27.');}
1
+ const a16_0x166daa=a16_0x17e6;(function(_0x2dca49,_0x201532){const _0x11d4b1=a16_0x17e6,_0x2e1d22=_0x2dca49();while(!![]){try{const _0x1c178d=parseInt(_0x11d4b1(0xf2))/0x1*(parseInt(_0x11d4b1(0xd7))/0x2)+-parseInt(_0x11d4b1(0xd6))/0x3*(-parseInt(_0x11d4b1(0xd5))/0x4)+-parseInt(_0x11d4b1(0xc8))/0x5*(-parseInt(_0x11d4b1(0xf0))/0x6)+-parseInt(_0x11d4b1(0xe6))/0x7*(-parseInt(_0x11d4b1(0xf5))/0x8)+parseInt(_0x11d4b1(0xeb))/0x9+-parseInt(_0x11d4b1(0xea))/0xa+parseInt(_0x11d4b1(0xdb))/0xb*(-parseInt(_0x11d4b1(0xb6))/0xc);if(_0x1c178d===_0x201532)break;else _0x2e1d22['push'](_0x2e1d22['shift']());}catch(_0x3a431c){_0x2e1d22['push'](_0x2e1d22['shift']());}}}(a16_0x249c,0x988c6));import{execSync}from'child_process';import a16_0x650b76 from'path';import a16_0x16c704 from'fs';function a16_0x249c(){const _0x486492=['build','Try\x20running\x20with\x20sudo\x20or\x20administrative\x20privileges.','includes','Could\x20not\x20auto-detect\x20entry\x20point.\x20Please\x20add\x20the\x20server\x20manually\x20using\x20\x27woozlit\x20mcp\x20add\x27.','646860FRPfcu','src/index.ts','info','dist/index.js','mcp-chrome-bridge','Installing\x20mcp-chrome-bridge\x20globally...','error','pnpm','keys','git\x20clone\x20','tsx','\x20already\x20exists.\x20Updating...','header','join','inherit','node','yarn\x20install','scripts','5qVxQcN','Unknown\x20installation\x20source.\x20Please\x20provide\x20a\x20GitHub\x20URL\x20or\x20\x27mcp-chrome-bridge\x27.','endsWith','mkdirSync','Building\x20project...','Cloning\x20','object','1.\x20Download\x20the\x20Chrome\x20Extension:\x20https://github.com/hangwin/mcp-chrome/releases','readFileSync','pnpm\x20add\x20-g\x20mcp-chrome-bridge','bin','test','github.com','84092JBRnhA','150eagrBj','675918AHcdqt','parse','yarn.lock','main','473ZRVjek','\x20run\x20build','length','existsSync','Installed\x20mcp-chrome-bridge\x20and\x20added\x20configuration!','Failed\x20to\x20install\x20mcp-chrome-bridge:\x20','npm\x20install\x20-g\x20mcp-chrome-bridge','homedir','npm','pnpm-lock.yaml','pnpm\x20install','5603696IwilsK','2.\x20Load\x20unpacked\x20extension\x20in\x20Chrome\x20Developer\x20Mode','npm\x20install','warn','8210310ruFHQl','3050586EwPqfz','\x20to\x20','Next\x20Steps:','Detected\x20entry\x20point:\x20','Installing\x20dependencies...','7411158cqCDis','mcp-chrome','1bsJUWF','4.\x20Make\x20sure\x20\x27mcp-chrome-bridge\x27\x20is\x20running\x20(if\x20not\x20started\x20automatically)','\x27\x20from\x20GitHub!','8RqPrdb','git\x20pull','.ts','Failed\x20to\x20clone\x20repository:\x20','package.json','.woozlit','index.js','build/index.js','https://github.com/','slice','.git','servers'];a16_0x249c=function(){return _0x486492;};return a16_0x249c();}import a16_0x3eb0c7 from'os';function a16_0x17e6(_0x108dcc,_0x2f5974){_0x108dcc=_0x108dcc-0xb3;const _0x249caa=a16_0x249c();let _0x17e669=_0x249caa[_0x108dcc];return _0x17e669;}import*as a16_0x50fe41 from'../ui/output.js';import{addMcpServer,addMcpHttpServer}from'../config/mcp.js';const SERVERS_DIR=a16_0x650b76[a16_0x166daa(0xc3)](a16_0x3eb0c7[a16_0x166daa(0xe2)](),a16_0x166daa(0xfa),a16_0x166daa(0x100));function ensureServersDir(){const _0x286874=a16_0x166daa;!a16_0x16c704['existsSync'](SERVERS_DIR)&&a16_0x16c704[_0x286874(0xcb)](SERVERS_DIR,{'recursive':!![]});}function getRepoName(_0xff3d4c){const _0x333182=a16_0x166daa,_0xe310d5=_0xff3d4c['split']('/');let _0x7f2c12=_0xe310d5[_0xe310d5[_0x333182(0xdd)]-0x1];return _0x7f2c12[_0x333182(0xca)]('.git')&&(_0x7f2c12=_0x7f2c12[_0x333182(0xfe)](0x0,-0x4)),_0x7f2c12;}async function installFromGithub(_0x313e01,_0x32a2c6){const _0x194421=a16_0x166daa;ensureServersDir();const _0x4d0d83=_0x32a2c6||getRepoName(_0x313e01),_0x2e302b=a16_0x650b76[_0x194421(0xc3)](SERVERS_DIR,_0x4d0d83);a16_0x50fe41['info'](_0x194421(0xcd)+_0x313e01+_0x194421(0xec)+_0x2e302b+'...');if(a16_0x16c704[_0x194421(0xde)](_0x2e302b)){a16_0x50fe41[_0x194421(0xe9)]('Directory\x20'+_0x2e302b+_0x194421(0xc1));try{execSync(_0x194421(0xf6),{'cwd':_0x2e302b,'stdio':_0x194421(0xc4)});}catch(_0x3101ee){a16_0x50fe41['error']('Failed\x20to\x20update\x20repo.\x20Try\x20checking\x20it\x20out\x20manually\x20or\x20deleting\x20the\x20folder.');return;}}else try{execSync(_0x194421(0xbf)+_0x313e01+'\x20'+_0x2e302b,{'stdio':_0x194421(0xc4)});}catch(_0x5778ee){a16_0x50fe41[_0x194421(0xbc)](_0x194421(0xf8)+_0x5778ee);return;}a16_0x50fe41[_0x194421(0xb8)](_0x194421(0xef));try{const _0x59b8d9=a16_0x16c704[_0x194421(0xde)](a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x194421(0xe4))),_0x1a9624=a16_0x16c704['existsSync'](a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x194421(0xd9))),_0x1f0274=_0x59b8d9?_0x194421(0xe5):_0x1a9624?_0x194421(0xc6):_0x194421(0xe8);execSync(_0x1f0274,{'cwd':_0x2e302b,'stdio':_0x194421(0xc4)});const _0x279dc0=a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x194421(0xf9));if(a16_0x16c704[_0x194421(0xde)](_0x279dc0)){const _0x37df49=JSON[_0x194421(0xd8)](a16_0x16c704[_0x194421(0xd0)](_0x279dc0,'utf-8'));_0x37df49[_0x194421(0xc7)]&&_0x37df49[_0x194421(0xc7)][_0x194421(0x101)]&&(a16_0x50fe41['info'](_0x194421(0xcc)),execSync((_0x59b8d9?_0x194421(0xbd):_0x1a9624?'yarn':_0x194421(0xe3))+_0x194421(0xdc),{'cwd':_0x2e302b,'stdio':'inherit'}));}}catch(_0x1f82ce){a16_0x50fe41['error']('Failed\x20to\x20install/build:\x20'+_0x1f82ce);return;}const _0x460a36=a16_0x650b76['join'](_0x2e302b,_0x194421(0xf9));let _0x122058='';if(a16_0x16c704[_0x194421(0xde)](_0x460a36)){const _0x4fe5e6=JSON[_0x194421(0xd8)](a16_0x16c704['readFileSync'](_0x460a36,'utf-8'));if(_0x4fe5e6[_0x194421(0xd2)]){if(typeof _0x4fe5e6[_0x194421(0xd2)]==='string')_0x122058=a16_0x650b76['join'](_0x2e302b,_0x4fe5e6['bin']);else{if(typeof _0x4fe5e6[_0x194421(0xd2)]===_0x194421(0xce)){const _0x23be1b=Object[_0x194421(0xbe)](_0x4fe5e6[_0x194421(0xd2)])[0x0];_0x122058=a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x4fe5e6['bin'][_0x23be1b]);}}}else _0x4fe5e6[_0x194421(0xda)]&&(_0x122058=a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x4fe5e6[_0x194421(0xda)]));}if(!_0x122058){const _0x9739bd=[_0x194421(0xb9),_0x194421(0xfc),_0x194421(0xb7),_0x194421(0xfb)];for(const _0x541e24 of _0x9739bd){if(a16_0x16c704[_0x194421(0xde)](a16_0x650b76[_0x194421(0xc3)](_0x2e302b,_0x541e24))){_0x122058=a16_0x650b76['join'](_0x2e302b,_0x541e24);break;}}}if(!_0x122058){a16_0x50fe41[_0x194421(0xbc)](_0x194421(0xb5));return;}const _0x3c211a=_0x122058[_0x194421(0xca)](_0x194421(0xf7))?_0x194421(0xc0):_0x194421(0xc5);a16_0x50fe41['info'](_0x194421(0xee)+_0x122058),addMcpServer(_0x4d0d83,_0x3c211a,[_0x122058]),a16_0x50fe41['success']('Successfully\x20installed\x20and\x20added\x20\x27'+_0x4d0d83+_0x194421(0xf4));}async function installMcpChromeBridge(){const _0x25358d=a16_0x166daa;a16_0x50fe41[_0x25358d(0xb8)](_0x25358d(0xbb));try{execSync(_0x25358d(0xd1),{'stdio':_0x25358d(0xc4)});}catch(_0x4af754){a16_0x50fe41['error']('Failed\x20to\x20install\x20mcp-chrome-bridge\x20using\x20pnpm:\x20'+_0x4af754),a16_0x50fe41[_0x25358d(0xb8)]('Trying\x20npm\x20as\x20fallback...');try{execSync(_0x25358d(0xe1),{'stdio':_0x25358d(0xc4)});}catch(_0x203de6){a16_0x50fe41['error'](_0x25358d(0xe0)+_0x203de6),a16_0x50fe41[_0x25358d(0xb8)](_0x25358d(0xb3));return;}}const _0x130454='http://127.0.0.1:12306/mcp';addMcpHttpServer(_0x25358d(0xf1),_0x130454),a16_0x50fe41['success'](_0x25358d(0xdf)),a16_0x50fe41[_0x25358d(0xc2)](_0x25358d(0xed)),a16_0x50fe41['info'](_0x25358d(0xcf)),a16_0x50fe41[_0x25358d(0xb8)](_0x25358d(0xe7)),a16_0x50fe41[_0x25358d(0xb8)]('3.\x20Click\x20extension\x20icon\x20and\x20\x27Connect\x27'),a16_0x50fe41['info'](_0x25358d(0xf3));}export async function installMcpServer(_0x17e9f1,_0x4c8f5c){const _0x1344a5=a16_0x166daa;if(_0x17e9f1===_0x1344a5(0xba)||_0x17e9f1==='chrome')return installMcpChromeBridge();if(_0x17e9f1[_0x1344a5(0xb4)](_0x1344a5(0xd4))||_0x17e9f1[_0x1344a5(0xca)](_0x1344a5(0xff)))return installFromGithub(_0x17e9f1,_0x4c8f5c);if(/^[a-zA-Z0-9_-]+\/[a-zA-Z0-9_-]+$/[_0x1344a5(0xd3)](_0x17e9f1))return installFromGithub(_0x1344a5(0xfd)+_0x17e9f1+_0x1344a5(0xff),_0x4c8f5c);a16_0x50fe41[_0x1344a5(0xbc)](_0x1344a5(0xc9));}
@@ -1 +1 @@
1
- function a17_0x2b3c(){const _0x96ebc8=['win32','81mzqYPe','windows','1061920VCVqzH','35674nFHltE','sudo\x20','7071936PTYqBN','linux','10QyTABp','17VjDHtL','3243612hTqsEC','arch','575952djwRVg','platform','21378amHhJZ','2121070hIXbaH','macos','darwin','macOS'];a17_0x2b3c=function(){return _0x96ebc8;};return a17_0x2b3c();}const a17_0x1295e7=a17_0x2bb2;(function(_0x5b1790,_0x28b732){const _0x5fb1b0=a17_0x2bb2,_0x3514ae=_0x5b1790();while(!![]){try{const _0x5627b8=-parseInt(_0x5fb1b0(0x18b))/0x1*(-parseInt(_0x5fb1b0(0x199))/0x2)+parseInt(_0x5fb1b0(0x18e))/0x3+-parseInt(_0x5fb1b0(0x198))/0x4*(-parseInt(_0x5fb1b0(0x19d))/0x5)+parseInt(_0x5fb1b0(0x18c))/0x6+parseInt(_0x5fb1b0(0x190))/0x7+parseInt(_0x5fb1b0(0x19b))/0x8+-parseInt(_0x5fb1b0(0x196))/0x9*(parseInt(_0x5fb1b0(0x191))/0xa);if(_0x5627b8===_0x28b732)break;else _0x3514ae['push'](_0x3514ae['shift']());}catch(_0xd0f33e){_0x3514ae['push'](_0x3514ae['shift']());}}}(a17_0x2b3c,0x8505a));const platform=process[a17_0x1295e7(0x18f)],arch=process[a17_0x1295e7(0x18d)];function a17_0x2bb2(_0xf419fa,_0xfc7ac9){_0xf419fa=_0xf419fa-0x18b;const _0x2b3cf1=a17_0x2b3c();let _0x2bb249=_0x2b3cf1[_0xf419fa];return _0x2bb249;}export function getPlatform(){const _0x718b08=a17_0x1295e7;if(platform===_0x718b08(0x195))return _0x718b08(0x197);if(platform===_0x718b08(0x193))return _0x718b08(0x192);return _0x718b08(0x19c);}export function getArch(){return arch;}export function isWindows(){const _0x390e1f=a17_0x1295e7;return platform===_0x390e1f(0x195);}export function isMac(){return platform==='darwin';}export function isLinux(){const _0x413124=a17_0x1295e7;return platform===_0x413124(0x19c);}export function getShellPrefix(){const _0x233da7=a17_0x1295e7;return isWindows()?'':_0x233da7(0x19a);}export function getPlatformInfo(){const _0x4d158a=a17_0x1295e7,_0x16249b=getPlatform(),_0x4ccaaf=_0x16249b===_0x4d158a(0x197)?'Windows':_0x16249b===_0x4d158a(0x192)?_0x4d158a(0x194):'Linux';return _0x4ccaaf+'\x20('+arch+')';}
1
+ const a17_0x4a36=a17_0x3ca2;(function(_0x3a3b6f,_0x9bc09f){const _0x46b78e=a17_0x3ca2,_0xf590cf=_0x3a3b6f();while(!![]){try{const _0x196102=parseInt(_0x46b78e(0xe1))/0x1*(parseInt(_0x46b78e(0xd7))/0x2)+-parseInt(_0x46b78e(0xd6))/0x3+parseInt(_0x46b78e(0xcf))/0x4+-parseInt(_0x46b78e(0xdd))/0x5*(parseInt(_0x46b78e(0xd4))/0x6)+parseInt(_0x46b78e(0xd9))/0x7*(parseInt(_0x46b78e(0xcd))/0x8)+-parseInt(_0x46b78e(0xd3))/0x9*(-parseInt(_0x46b78e(0xd0))/0xa)+-parseInt(_0x46b78e(0xd2))/0xb;if(_0x196102===_0x9bc09f)break;else _0xf590cf['push'](_0xf590cf['shift']());}catch(_0x17dfc2){_0xf590cf['push'](_0xf590cf['shift']());}}}(a17_0x3fbb,0xd387a));const platform=process['platform'],arch=process[a17_0x4a36(0xd1)];export function getPlatform(){const _0x5570f3=a17_0x4a36;if(platform===_0x5570f3(0xd5))return _0x5570f3(0xe0);if(platform===_0x5570f3(0xce))return _0x5570f3(0xda);return _0x5570f3(0xdc);}export function getArch(){return arch;}export function isWindows(){return platform==='win32';}export function isMac(){const _0x143f47=a17_0x4a36;return platform===_0x143f47(0xce);}export function isLinux(){const _0x1619ec=a17_0x4a36;return platform===_0x1619ec(0xdc);}export function getShellPrefix(){const _0x1930ac=a17_0x4a36;return isWindows()?'':_0x1930ac(0xdb);}function a17_0x3ca2(_0x33c56f,_0x5b6457){_0x33c56f=_0x33c56f-0xcd;const _0x3fbb64=a17_0x3fbb();let _0x3ca295=_0x3fbb64[_0x33c56f];return _0x3ca295;}export function getPlatformInfo(){const _0x2fc585=a17_0x4a36,_0x533741=getPlatform(),_0x18296b=_0x533741===_0x2fc585(0xe0)?_0x2fc585(0xd8):_0x533741==='macos'?_0x2fc585(0xdf):_0x2fc585(0xde);return _0x18296b+'\x20('+arch+')';}function a17_0x3fbb(){const _0x3cd44d=['macos','sudo\x20','linux','717530OJOlHt','Linux','macOS','windows','435771QJWCQH','4208RTyIgZ','darwin','4678944uMkGKD','199440gvvXCT','arch','33915398uvPlMq','549GECzPy','24DEfufS','win32','95508vJWjEo','4YRLsmf','Windows','17269Davvei'];a17_0x3fbb=function(){return _0x3cd44d;};return a17_0x3fbb();}
@@ -1 +1 @@
1
- const a18_0xf9239e=a18_0x1a4c;(function(_0x258926,_0x57b1df){const _0x1e45de=a18_0x1a4c,_0x241488=_0x258926();while(!![]){try{const _0x3d6138=parseInt(_0x1e45de(0x1ae))/0x1+-parseInt(_0x1e45de(0x1a6))/0x2*(-parseInt(_0x1e45de(0x1a7))/0x3)+-parseInt(_0x1e45de(0x1b3))/0x4+parseInt(_0x1e45de(0x1a4))/0x5+parseInt(_0x1e45de(0x1ab))/0x6*(-parseInt(_0x1e45de(0x1ac))/0x7)+-parseInt(_0x1e45de(0x1b0))/0x8+parseInt(_0x1e45de(0x1af))/0x9;if(_0x3d6138===_0x57b1df)break;else _0x241488['push'](_0x241488['shift']());}catch(_0x3fe305){_0x241488['push'](_0x241488['shift']());}}}(a18_0x3d25,0x54378));import a18_0xe26e73 from'conf';const config=new a18_0xe26e73({'projectName':a18_0xf9239e(0x1a9)});export function getToken(){const _0xd838e7=a18_0xf9239e;return config[_0xd838e7(0x1aa)](_0xd838e7(0x1a8));}export function setToken(_0x222e50){const _0x28ff9a=a18_0xf9239e;config['set'](_0x28ff9a(0x1a8),_0x222e50);}export function clearToken(){const _0x276716=a18_0xf9239e;config[_0x276716(0x1a2)](_0x276716(0x1a8));}export function getUser(){const _0x22b477=a18_0xf9239e;return{'userId':config[_0x22b477(0x1aa)]('userId'),'email':config[_0x22b477(0x1aa)](_0x22b477(0x1a5)),'displayName':config[_0x22b477(0x1aa)]('displayName')};}export function setUser(_0x4d1a35,_0x1e2ee5,_0x5c2340){const _0x207b4e=a18_0xf9239e;config[_0x207b4e(0x1b2)](_0x207b4e(0x1a3),_0x4d1a35),config[_0x207b4e(0x1b2)]('email',_0x1e2ee5),config[_0x207b4e(0x1b2)]('displayName',_0x5c2340);}export function clearUser(){const _0x45e384=a18_0xf9239e;config[_0x45e384(0x1a2)](_0x45e384(0x1a3)),config['delete'](_0x45e384(0x1a5)),config[_0x45e384(0x1a2)]('displayName');}export function getSelectedModel(){const _0x3cdedd=a18_0xf9239e;return config[_0x3cdedd(0x1aa)]('selectedModel')||'xiaomi/mimo-v2-flash:free';}export function setSelectedModel(_0x1dfd87){config['set']('selectedModel',_0x1dfd87);}export function getRules(){const _0xf905c7=a18_0xf9239e;return config[_0xf905c7(0x1aa)](_0xf905c7(0x1ad))||[];}function a18_0x3d25(){const _0x2b9535=['set','290060AmUDVf','delete','userId','972495OWYboJ','email','3754LAEPHs','798YsuaWL','token','woozlit-cli','get','468jRUmJO','34643ZhwCEp','rules','166715yMWnoe','4897251bnqBhW','4809168MAtmJg','push'];a18_0x3d25=function(){return _0x2b9535;};return a18_0x3d25();}export function addRule(_0x1e5522){const _0x1a7efa=a18_0xf9239e,_0x4eff17=getRules();_0x4eff17[_0x1a7efa(0x1b1)](_0x1e5522),config[_0x1a7efa(0x1b2)](_0x1a7efa(0x1ad),_0x4eff17);}export function clearRules(){const _0x2813df=a18_0xf9239e;config['set'](_0x2813df(0x1ad),[]);}function a18_0x1a4c(_0x42880d,_0x1efb30){_0x42880d=_0x42880d-0x1a2;const _0x3d25ba=a18_0x3d25();let _0x1a4c5a=_0x3d25ba[_0x42880d];return _0x1a4c5a;}export function isLoggedIn(){const _0x354de4=a18_0xf9239e;return!!config[_0x354de4(0x1aa)](_0x354de4(0x1a8))&&!!config[_0x354de4(0x1aa)]('userId');}export function logout(){clearToken(),clearUser();}
1
+ const a18_0x450a3b=a18_0x1af6;(function(_0x3c5e4d,_0x1bac31){const _0xc9081a=a18_0x1af6,_0x3e9f5a=_0x3c5e4d();while(!![]){try{const _0x447225=parseInt(_0xc9081a(0x1ae))/0x1*(parseInt(_0xc9081a(0x1a9))/0x2)+parseInt(_0xc9081a(0x1b9))/0x3+parseInt(_0xc9081a(0x1bc))/0x4+-parseInt(_0xc9081a(0x1a6))/0x5*(parseInt(_0xc9081a(0x1aa))/0x6)+-parseInt(_0xc9081a(0x1b2))/0x7*(parseInt(_0xc9081a(0x1bb))/0x8)+-parseInt(_0xc9081a(0x1a8))/0x9*(-parseInt(_0xc9081a(0x1ad))/0xa)+parseInt(_0xc9081a(0x1ab))/0xb*(-parseInt(_0xc9081a(0x1b3))/0xc);if(_0x447225===_0x1bac31)break;else _0x3e9f5a['push'](_0x3e9f5a['shift']());}catch(_0x1c8707){_0x3e9f5a['push'](_0x3e9f5a['shift']());}}}(a18_0x6e74,0xc37f3));import a18_0x111085 from'conf';function a18_0x6e74(){const _0x54901e=['866744vXcJrm','2005904fWxhRe','390DTPQzy','userId','1621035nNdIOO','22DMVoeQ','56562Fafyhh','24464VccFBl','delete','40bEIsLc','52435iwdIIU','token','selectedModel','email','7FQHGXP','9456kZGuMj','displayName','set','rules','push','get','4794585DBfpoU','woozlit-cli'];a18_0x6e74=function(){return _0x54901e;};return a18_0x6e74();}const config=new a18_0x111085({'projectName':a18_0x450a3b(0x1ba)});export function getToken(){const _0xadbeba=a18_0x450a3b;return config[_0xadbeba(0x1b8)](_0xadbeba(0x1af));}export function setToken(_0x1fe486){const _0x199f66=a18_0x450a3b;config[_0x199f66(0x1b5)](_0x199f66(0x1af),_0x1fe486);}export function clearToken(){const _0xc77d3b=a18_0x450a3b;config[_0xc77d3b(0x1ac)](_0xc77d3b(0x1af));}export function getUser(){const _0x26dd63=a18_0x450a3b;return{'userId':config['get'](_0x26dd63(0x1a7)),'email':config['get']('email'),'displayName':config[_0x26dd63(0x1b8)](_0x26dd63(0x1b4))};}export function setUser(_0x45df81,_0x2041b2,_0x359099){const _0x4e1e24=a18_0x450a3b;config[_0x4e1e24(0x1b5)]('userId',_0x45df81),config['set']('email',_0x2041b2),config[_0x4e1e24(0x1b5)](_0x4e1e24(0x1b4),_0x359099);}export function clearUser(){const _0xa689ea=a18_0x450a3b;config[_0xa689ea(0x1ac)](_0xa689ea(0x1a7)),config[_0xa689ea(0x1ac)](_0xa689ea(0x1b1)),config['delete']('displayName');}export function getSelectedModel(){const _0x9d31e0=a18_0x450a3b;return config[_0x9d31e0(0x1b8)](_0x9d31e0(0x1b0))||'xiaomi/mimo-v2-flash:free';}export function setSelectedModel(_0x38c6e6){const _0x28efaa=a18_0x450a3b;config['set'](_0x28efaa(0x1b0),_0x38c6e6);}export function getRules(){const _0x29d8ec=a18_0x450a3b;return config[_0x29d8ec(0x1b8)](_0x29d8ec(0x1b6))||[];}function a18_0x1af6(_0x393790,_0x10785f){_0x393790=_0x393790-0x1a6;const _0x6e7440=a18_0x6e74();let _0x1af6b6=_0x6e7440[_0x393790];return _0x1af6b6;}export function addRule(_0x3208d8){const _0x4de8d8=a18_0x450a3b,_0x46e79f=getRules();_0x46e79f[_0x4de8d8(0x1b7)](_0x3208d8),config[_0x4de8d8(0x1b5)](_0x4de8d8(0x1b6),_0x46e79f);}export function clearRules(){const _0x2b980b=a18_0x450a3b;config[_0x2b980b(0x1b5)](_0x2b980b(0x1b6),[]);}export function isLoggedIn(){const _0xf3965e=a18_0x450a3b;return!!config[_0xf3965e(0x1b8)](_0xf3965e(0x1af))&&!!config[_0xf3965e(0x1b8)](_0xf3965e(0x1a7));}export function logout(){clearToken(),clearUser();}
@@ -1 +1 @@
1
- const a19_0x3285b7=a19_0x274c;(function(_0x455f3d,_0x1e56ab){const _0x2a60a5=a19_0x274c,_0x17bc11=_0x455f3d();while(!![]){try{const _0x503611=parseInt(_0x2a60a5(0x81))/0x1+parseInt(_0x2a60a5(0x7a))/0x2+-parseInt(_0x2a60a5(0x7b))/0x3*(-parseInt(_0x2a60a5(0x75))/0x4)+parseInt(_0x2a60a5(0x73))/0x5*(-parseInt(_0x2a60a5(0x85))/0x6)+parseInt(_0x2a60a5(0x76))/0x7*(-parseInt(_0x2a60a5(0x79))/0x8)+-parseInt(_0x2a60a5(0x70))/0x9*(parseInt(_0x2a60a5(0x7d))/0xa)+parseInt(_0x2a60a5(0x6c))/0xb;if(_0x503611===_0x1e56ab)break;else _0x17bc11['push'](_0x17bc11['shift']());}catch(_0x3c09da){_0x17bc11['push'](_0x17bc11['shift']());}}}(a19_0x3720,0x690a1));import a19_0x731f3c from'chalk';const CURRENT_VERSION=a19_0x3285b7(0x80);export async function checkForUpdate(){const _0xc1a67e=a19_0x3285b7;try{const _0x4f5950=await fetch('https://registry.npmjs.org/woozlit',{'headers':{'Accept':_0xc1a67e(0x7f)},'signal':AbortSignal[_0xc1a67e(0x82)](0x5dc)});if(!_0x4f5950['ok'])return;const _0x4ba4d3=await _0x4f5950['json'](),_0x2cd0f3=_0x4ba4d3['dist-tags']?.[_0xc1a67e(0x78)];_0x2cd0f3&&_0x2cd0f3!==CURRENT_VERSION&&(isNewer(_0x2cd0f3,CURRENT_VERSION)&&printUpdateBox(_0x2cd0f3,CURRENT_VERSION));}catch{}}function isNewer(_0x164731,_0x4d41ee){const _0x2fc782=a19_0x3285b7,_0x2ebd53=_0x164731[_0x2fc782(0x7e)]('.')[_0x2fc782(0x6d)](Number),_0x4fcb49=_0x4d41ee[_0x2fc782(0x7e)]('.')[_0x2fc782(0x6d)](Number);for(let _0x18580b=0x0;_0x18580b<0x3;_0x18580b++){if(_0x2ebd53[_0x18580b]>_0x4fcb49[_0x18580b])return!![];if(_0x2ebd53[_0x18580b]<_0x4fcb49[_0x18580b])return![];}return![];}function a19_0x274c(_0x4b508c,_0x2f9894){_0x4b508c=_0x4b508c-0x6c;const _0x3720e4=a19_0x3720();let _0x274c73=_0x3720e4[_0x4b508c];return _0x274c73;}function printUpdateBox(_0x40bd84,_0x34a277){const _0x4c1460=a19_0x3285b7,_0x417d47=a19_0x731f3c['yellow']('─'[_0x4c1460(0x7c)](0x32));console[_0x4c1460(0x6f)](),console[_0x4c1460(0x6f)](_0x417d47),console[_0x4c1460(0x6f)](a19_0x731f3c[_0x4c1460(0x6e)](_0x4c1460(0x83)+a19_0x731f3c['dim'](_0x34a277)+_0x4c1460(0x84)+a19_0x731f3c[_0x4c1460(0x72)](_0x40bd84))),console['log'](a19_0x731f3c[_0x4c1460(0x6e)](_0x4c1460(0x71)+a19_0x731f3c[_0x4c1460(0x77)](_0x4c1460(0x74))+'\x20to\x20update')),console['log'](_0x417d47),console[_0x4c1460(0x6f)]();}function a19_0x3720(){const _0xe0ca70=['1253055pCILHk','npm\x20install\x20-g\x20woozlit','4NUpMeR','24171XZeLsw','cyan','latest','64KzLSYe','444612kuAEzt','731529TOJfmc','repeat','493650IHgqxJ','split','application/json','1.1.2','423685dPoNfu','timeout','\x20\x20Update\x20Available!\x20','\x20→\x20','12UrrcEj','9993038jxHoNr','map','yellow','log','153KLZoGV','\x20\x20Run\x20','green'];a19_0x3720=function(){return _0xe0ca70;};return a19_0x3720();}
1
+ const a19_0x544707=a19_0x37cf;(function(_0x32b386,_0x498c45){const _0x3fa9c1=a19_0x37cf,_0x15eed2=_0x32b386();while(!![]){try{const _0x2b7811=-parseInt(_0x3fa9c1(0x1df))/0x1*(parseInt(_0x3fa9c1(0x1f2))/0x2)+parseInt(_0x3fa9c1(0x1eb))/0x3+parseInt(_0x3fa9c1(0x1e5))/0x4*(parseInt(_0x3fa9c1(0x1e7))/0x5)+-parseInt(_0x3fa9c1(0x1de))/0x6+parseInt(_0x3fa9c1(0x1f6))/0x7+-parseInt(_0x3fa9c1(0x1ef))/0x8*(parseInt(_0x3fa9c1(0x1f0))/0x9)+-parseInt(_0x3fa9c1(0x1e6))/0xa*(parseInt(_0x3fa9c1(0x1fb))/0xb);if(_0x2b7811===_0x498c45)break;else _0x15eed2['push'](_0x15eed2['shift']());}catch(_0x4332c){_0x15eed2['push'](_0x15eed2['shift']());}}}(a19_0x8ede,0x40901));import a19_0x542fa4 from'chalk';const CURRENT_VERSION=a19_0x544707(0x1f5);function a19_0x37cf(_0x51446a,_0x307032){_0x51446a=_0x51446a-0x1dd;const _0x8edee8=a19_0x8ede();let _0x37cf3d=_0x8edee8[_0x51446a];return _0x37cf3d;}function a19_0x8ede(){const _0x5889a5=['2zGCesC','\x20\x20✔\x20Woozlit\x20updated\x20successfully!','green','1.1.4','3634960zDGSVl','error','\x20\x20Update\x20Available!\x20','red','repeat','1309924vvfdFH','application/json','2324988LahFks','139812uDVXGf','gray','map','\x20\x20Please\x20restart\x20the\x20CLI\x20to\x20use\x20the\x20new\x20version.','\x20\x20Auto-updating\x20to\x20version\x20','split','88292tSexuo','10dEnDWD','110MtrqSx','dim','\x20\x20Failed\x20to\x20auto-update.\x20Please\x20run:\x20npm\x20install\x20-g\x20woozlit','\x20→\x20','33819ASVqcO','yellow','log','npm\x20install\x20-g\x20woozlit','3616hHhFlW','2097sXovPW','...'];a19_0x8ede=function(){return _0x5889a5;};return a19_0x8ede();}export async function checkForUpdate(){const _0x55c9c0=a19_0x544707;try{const _0x2d74f7=await fetch('https://registry.npmjs.org/woozlit',{'headers':{'Accept':_0x55c9c0(0x1dd)},'signal':AbortSignal['timeout'](0x5dc)});if(!_0x2d74f7['ok'])return;const _0x4bf8d6=await _0x2d74f7['json'](),_0x1e733f=_0x4bf8d6['dist-tags']?.['latest'];_0x1e733f&&_0x1e733f!==CURRENT_VERSION&&(isNewer(_0x1e733f,CURRENT_VERSION)&&printUpdateBox(_0x1e733f,CURRENT_VERSION));}catch{}}function isNewer(_0x7c118e,_0x2d8500){const _0x5324fd=a19_0x544707,_0xde1c0e=_0x7c118e[_0x5324fd(0x1e4)]('.')[_0x5324fd(0x1e1)](Number),_0x28d7d6=_0x2d8500[_0x5324fd(0x1e4)]('.')[_0x5324fd(0x1e1)](Number);for(let _0x53c4d0=0x0;_0x53c4d0<0x3;_0x53c4d0++){if(_0xde1c0e[_0x53c4d0]>_0x28d7d6[_0x53c4d0])return!![];if(_0xde1c0e[_0x53c4d0]<_0x28d7d6[_0x53c4d0])return![];}return![];}function printUpdateBox(_0x506e80,_0x49edca){const _0x4af1d0=a19_0x544707,_0x59fa1c=a19_0x542fa4[_0x4af1d0(0x1ec)]('─'[_0x4af1d0(0x1fa)](0x32));console[_0x4af1d0(0x1ed)](),console[_0x4af1d0(0x1ed)](_0x59fa1c),console['log'](a19_0x542fa4[_0x4af1d0(0x1ec)](_0x4af1d0(0x1f8)+a19_0x542fa4['dim'](_0x49edca)+_0x4af1d0(0x1ea)+a19_0x542fa4[_0x4af1d0(0x1f4)](_0x506e80))),console['log'](a19_0x542fa4[_0x4af1d0(0x1e0)](_0x4af1d0(0x1e3)+_0x506e80+_0x4af1d0(0x1f1))),console['log'](_0x59fa1c),console[_0x4af1d0(0x1ed)]();try{const {execSync:_0x49be9e}=require('child_process');_0x49be9e(_0x4af1d0(0x1ee),{'stdio':'inherit'}),console['log'](),console[_0x4af1d0(0x1ed)](a19_0x542fa4['green'](_0x4af1d0(0x1f3))),console[_0x4af1d0(0x1ed)](a19_0x542fa4[_0x4af1d0(0x1e8)](_0x4af1d0(0x1e2))),console[_0x4af1d0(0x1ed)](),process['exit'](0x0);}catch(_0x386234){console[_0x4af1d0(0x1f7)](a19_0x542fa4[_0x4af1d0(0x1f9)](_0x4af1d0(0x1e9)));}}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "woozlit",
3
- "version": "1.1.2",
3
+ "version": "1.1.4",
4
4
  "description": "Woozlit AI - Agentic Coding Assistant",
5
5
  "type": "module",
6
6
  "files": [