woozlit 2.0.2 → 2.0.3

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.
Files changed (50) hide show
  1. package/dist/auth/login.js +1 -1
  2. package/dist/browser/index.js +1 -1
  3. package/dist/browser/server.js +1 -1
  4. package/dist/browser/tools.js +1 -1
  5. package/dist/chat/agent.js +1 -1
  6. package/dist/config/mcp.js +1 -1
  7. package/dist/config/settings.js +1 -1
  8. package/dist/discord/client.js +1 -1
  9. package/dist/discord/config.js +1 -1
  10. package/dist/discord/index.js +1 -1
  11. package/dist/discord/setup.js +1 -1
  12. package/dist/email/config.js +1 -1
  13. package/dist/email/index.js +1 -1
  14. package/dist/email/service.js +1 -1
  15. package/dist/email/setup.js +1 -1
  16. package/dist/github/api.js +1 -1
  17. package/dist/github/auth.js +1 -1
  18. package/dist/github/auto-setup.js +1 -1
  19. package/dist/github/index.js +1 -1
  20. package/dist/github/manual-setup.js +1 -1
  21. package/dist/index.js +1 -1
  22. package/dist/mcp-servers/computer-use.js +1 -1
  23. package/dist/services/bot-manager.js +1 -1
  24. package/dist/services/voice-agent.js +1 -1
  25. package/dist/telegram/bot.js +1 -1
  26. package/dist/telegram/config.js +1 -1
  27. package/dist/telegram/index.js +1 -1
  28. package/dist/telegram/reminders.js +1 -1
  29. package/dist/telegram/setup.js +1 -1
  30. package/dist/tools/command.js +1 -1
  31. package/dist/tools/file.js +1 -1
  32. package/dist/tools/index.js +1 -1
  33. package/dist/tools/mcp.js +1 -1
  34. package/dist/tools/rollback.js +1 -1
  35. package/dist/tools/rules.js +1 -1
  36. package/dist/twilio/config.js +1 -1
  37. package/dist/twilio/index.js +1 -1
  38. package/dist/twilio/server.js +1 -1
  39. package/dist/twilio/setup.js +1 -1
  40. package/dist/ui/output.js +1 -1
  41. package/dist/ui/select.js +1 -1
  42. package/dist/ui/themes.js +1 -1
  43. package/dist/utils/api.js +1 -1
  44. package/dist/utils/history.js +1 -1
  45. package/dist/utils/mcp-installer.js +1 -1
  46. package/dist/utils/platform.js +1 -1
  47. package/dist/utils/storage.js +1 -1
  48. package/dist/utils/update-check.js +1 -1
  49. package/dist/verify_repro.js +1 -1
  50. package/package.json +1 -1
@@ -1 +1 @@
1
- function a0_0x48c8(){const _0x477880=['url','pathname','displayName','/auth/cli?callback=http://localhost:','334792FAOnHl','close','\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','1066933IuhPHz','6naYuBJ','token','userId','383600vMteEI','http://localhost:','/callback','20977YRAraL','710555rnfIAi','4PqLRrK','4Dhkvjr','searchParams','1166418qQzRih','email','70449EtVnLk','writeHead','get','end'];a0_0x48c8=function(){return _0x477880;};return a0_0x48c8();}(function(_0xd331f2,_0x36a4aa){const _0x4e42ae=a0_0x4efd,_0x17bc80=_0xd331f2();while(!![]){try{const _0x2b21df=-parseInt(_0x4e42ae(0x1c8))/0x1*(parseInt(_0x4e42ae(0x1cb))/0x2)+-parseInt(_0x4e42ae(0x1cf))/0x3*(-parseInt(_0x4e42ae(0x1ca))/0x4)+parseInt(_0x4e42ae(0x1c9))/0x5*(parseInt(_0x4e42ae(0x1c2))/0x6)+-parseInt(_0x4e42ae(0x1c1))/0x7+parseInt(_0x4e42ae(0x1be))/0x8+parseInt(_0x4e42ae(0x1cd))/0x9+-parseInt(_0x4e42ae(0x1c5))/0xa;if(_0x2b21df===_0x36a4aa)break;else _0x17bc80['push'](_0x17bc80['shift']());}catch(_0x330e80){_0x17bc80['push'](_0x17bc80['shift']());}}}(a0_0x48c8,0x19778));import a0_0x42645a from'open';function a0_0x4efd(_0x15fbe1,_0x472726){_0x15fbe1=_0x15fbe1-0x1be;const _0x48c84e=a0_0x48c8();let _0x4efd84=_0x48c84e[_0x15fbe1];return _0x4efd84;}import{createServer}from'http';import{getApiUrl}from'../config/settings.js';import{setToken,setUser,isLoggedIn,logout as a0_0x304da3}from'../utils/storage.js';export async function login(){const _0x289d9c=getApiUrl(),_0x24f30f=0x2694;return new Promise(_0x29e27d=>{const _0x41279b=createServer(async(_0x25f800,_0x42f07e)=>{const _0x43e49b=a0_0x4efd,_0x527d04=new URL(_0x25f800[_0x43e49b(0x1d3)]||'',_0x43e49b(0x1c6)+_0x24f30f);if(_0x527d04[_0x43e49b(0x1d4)]===_0x43e49b(0x1c7)){const _0x295f99=_0x527d04['searchParams'][_0x43e49b(0x1d1)](_0x43e49b(0x1c3)),_0x167cb8=_0x527d04[_0x43e49b(0x1cc)]['get'](_0x43e49b(0x1c4)),_0x333aaf=_0x527d04[_0x43e49b(0x1cc)][_0x43e49b(0x1d1)](_0x43e49b(0x1ce)),_0x5d2132=_0x527d04[_0x43e49b(0x1cc)][_0x43e49b(0x1d1)](_0x43e49b(0x1d5));_0x295f99&&_0x167cb8?(setToken(_0x295f99),setUser(_0x167cb8,_0x333aaf||'',_0x5d2132||''),_0x42f07e[_0x43e49b(0x1d0)](0xc8,{'Content-Type':'text/html'}),_0x42f07e[_0x43e49b(0x1d2)](_0x43e49b(0x1c0)),_0x41279b[_0x43e49b(0x1bf)](),_0x29e27d(!![])):(_0x42f07e[_0x43e49b(0x1d0)](0x190,{'Content-Type':'text/html'}),_0x42f07e[_0x43e49b(0x1d2)]('\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'),_0x41279b[_0x43e49b(0x1bf)](),_0x29e27d(![]));}});_0x41279b['listen'](_0x24f30f,()=>{const _0x2e14be=a0_0x4efd,_0x54f036=_0x289d9c+_0x2e14be(0x1d6)+_0x24f30f+'/callback';a0_0x42645a(_0x54f036);}),setTimeout(()=>{const _0x397494=a0_0x4efd;_0x41279b[_0x397494(0x1bf)](),_0x29e27d(![]);},0x1d4c0);});}export function logout(){a0_0x304da3();}export{isLoggedIn};
1
+ (function(_0x2b1cb6,_0x584f91){const _0x597cea=a0_0x3bb3,_0x51dc4e=_0x2b1cb6();while(!![]){try{const _0x7ba335=-parseInt(_0x597cea(0x8b))/0x1*(-parseInt(_0x597cea(0x94))/0x2)+-parseInt(_0x597cea(0x99))/0x3+parseInt(_0x597cea(0x98))/0x4+-parseInt(_0x597cea(0x85))/0x5*(-parseInt(_0x597cea(0x9a))/0x6)+parseInt(_0x597cea(0x90))/0x7*(parseInt(_0x597cea(0x8a))/0x8)+parseInt(_0x597cea(0x8f))/0x9*(-parseInt(_0x597cea(0x8c))/0xa)+parseInt(_0x597cea(0x95))/0xb*(-parseInt(_0x597cea(0x93))/0xc);if(_0x7ba335===_0x584f91)break;else _0x51dc4e['push'](_0x51dc4e['shift']());}catch(_0x1543f9){_0x51dc4e['push'](_0x51dc4e['shift']());}}}(a0_0xdb9b,0x30223));import a0_0x2b3149 from'open';import{createServer}from'http';import{getApiUrl}from'../config/settings.js';import{setToken,setUser,isLoggedIn,logout as a0_0x2d1d2f}from'../utils/storage.js';function a0_0x3bb3(_0x31c505,_0x420eae){_0x31c505=_0x31c505-0x84;const _0xdb9ba9=a0_0xdb9b();let _0x3bb3ee=_0xdb9ba9[_0x31c505];return _0x3bb3ee;}export async function login(){const _0x5a4391=getApiUrl(),_0x265523=0x2694;return new Promise(_0x587bc0=>{const _0x391295=a0_0x3bb3,_0x4987e6=createServer(async(_0x558829,_0x589a54)=>{const _0xb74b77=a0_0x3bb3,_0x9380d2=new URL(_0x558829[_0xb74b77(0x9b)]||'','http://localhost:'+_0x265523);if(_0x9380d2['pathname']===_0xb74b77(0x87)){const _0xf44cea=_0x9380d2[_0xb74b77(0x96)]['get'](_0xb74b77(0x88)),_0x40731f=_0x9380d2[_0xb74b77(0x96)][_0xb74b77(0x8d)](_0xb74b77(0x97)),_0x23806c=_0x9380d2[_0xb74b77(0x96)][_0xb74b77(0x8d)](_0xb74b77(0x92)),_0x45ade8=_0x9380d2['searchParams'][_0xb74b77(0x8d)](_0xb74b77(0x8e));_0xf44cea&&_0x40731f?(setToken(_0xf44cea),setUser(_0x40731f,_0x23806c||'',_0x45ade8||''),_0x589a54[_0xb74b77(0x9c)](0xc8,{'Content-Type':_0xb74b77(0x89)}),_0x589a54['end']('\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'),_0x4987e6['close'](),_0x587bc0(!![])):(_0x589a54[_0xb74b77(0x9c)](0x190,{'Content-Type':'text/html'}),_0x589a54['end'](_0xb74b77(0x86)),_0x4987e6[_0xb74b77(0x84)](),_0x587bc0(![]));}});_0x4987e6[_0x391295(0x91)](_0x265523,()=>{const _0x34d9f9=_0x5a4391+'/auth/cli?callback=http://localhost:'+_0x265523+'/callback';a0_0x2b3149(_0x34d9f9);}),setTimeout(()=>{const _0x35930a=_0x391295;_0x4987e6[_0x35930a(0x84)](),_0x587bc0(![]);},0x1d4c0);});}function a0_0xdb9b(){const _0x43c804=['4476AwIUYh','1454DDcpQX','2013lYDXod','searchParams','userId','1548400PWAoDH','969087BngLgW','54HPmnXp','url','writeHead','close','91985DpdHUC','\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','/callback','token','text/html','262360pGKbSB','289qiapoh','3310tQsqff','get','displayName','8307KolYDq','28iVrKgR','listen','email'];a0_0xdb9b=function(){return _0x43c804;};return a0_0xdb9b();}export function logout(){a0_0x2d1d2f();}export{isLoggedIn};
@@ -1 +1 @@
1
- const a1_0x48becb=a1_0x247b;(function(_0x3542f2,_0x6103f9){const _0x641de8=a1_0x247b,_0x5eea7f=_0x3542f2();while(!![]){try{const _0x2addd9=-parseInt(_0x641de8(0x1ab))/0x1*(parseInt(_0x641de8(0x1b2))/0x2)+parseInt(_0x641de8(0x19b))/0x3*(-parseInt(_0x641de8(0x1a6))/0x4)+-parseInt(_0x641de8(0x1a3))/0x5+-parseInt(_0x641de8(0x19d))/0x6*(parseInt(_0x641de8(0x1a2))/0x7)+parseInt(_0x641de8(0x1af))/0x8+parseInt(_0x641de8(0x1ac))/0x9+parseInt(_0x641de8(0x1a8))/0xa;if(_0x2addd9===_0x6103f9)break;else _0x5eea7f['push'](_0x5eea7f['shift']());}catch(_0x56e9c3){_0x5eea7f['push'](_0x5eea7f['shift']());}}}(a1_0xb157,0xf19c5));export*from'./server.js';function a1_0xb157(){const _0x52712a=['2zrSHwY','string','browser_scroll','tabId','Direction\x20to\x20scroll','number','12CprLRR','direction','350070zdjIHC','CSS\x20selector\x20for\x20the\x20element','bottom','Optional:\x20if\x20multiple\x20elements\x20match,\x20click\x20the\x20Nth\x20one\x20(0-indexed)','Text\x20to\x20fill','21AxBxcU','1785055wFlvxK','down','browser_click','814696USPpyb','object','26109980FZpfhl','text','top','1260935aMihAU','4424337dSSxTJ','Tab\x20ID\x20from\x20browser_open\x20or\x20browser_snapshot','query','3957784PdUjnb','Fill\x20a\x20form\x20field\x20or\x20input\x20element','Tab\x20ID\x20from\x20browser_open\x20\x20or\x20browser_snapshot'];a1_0xb157=function(){return _0x52712a;};return a1_0xb157();}export*from'./tools.js';export*from'./server.js';export*from'./tools.js';function a1_0x247b(_0x3bc39c,_0x3d81d3){_0x3bc39c=_0x3bc39c-0x197;const _0xb15718=a1_0xb157();let _0x247b51=_0xb15718[_0x3bc39c];return _0x247b51;}export const tools=[{'name':'browser_fill','description':a1_0x48becb(0x1b0),'input_schema':{'type':a1_0x48becb(0x1a7),'properties':{'tabId':{'type':a1_0x48becb(0x19a),'description':a1_0x48becb(0x1b1)},'query':{'type':a1_0x48becb(0x1b3),'description':a1_0x48becb(0x19e)},'text':{'type':'string','description':a1_0x48becb(0x1a1)}},'required':['tabId',a1_0x48becb(0x1ae),a1_0x48becb(0x1a9)]}},{'name':a1_0x48becb(0x1a5),'description':'Click\x20an\x20element\x20on\x20the\x20page','input_schema':{'type':a1_0x48becb(0x1a7),'properties':{'tabId':{'type':a1_0x48becb(0x19a),'description':a1_0x48becb(0x1ad)},'query':{'type':a1_0x48becb(0x1b3),'description':a1_0x48becb(0x19e)},'index':{'type':'number','description':a1_0x48becb(0x1a0)}},'required':[a1_0x48becb(0x198),a1_0x48becb(0x1ae)]}},{'name':a1_0x48becb(0x197),'description':'Scroll\x20the\x20page\x20up\x20or\x20down','input_schema':{'type':a1_0x48becb(0x1a7),'properties':{'tabId':{'type':a1_0x48becb(0x19a),'description':'Tab\x20ID'},'direction':{'type':a1_0x48becb(0x1b3),'enum':['up',a1_0x48becb(0x1a4),a1_0x48becb(0x1aa),a1_0x48becb(0x19f)],'description':a1_0x48becb(0x199)},'amount':{'type':a1_0x48becb(0x19a),'description':'Optional:\x20pixels\x20to\x20scroll\x20(default:\x20one\x20page)'}},'required':[a1_0x48becb(0x198),a1_0x48becb(0x19c)]}}];
1
+ const a1_0x442e0c=a1_0x3c18;function a1_0x5a1e(){const _0x4984bb=['23612beWguF','Tab\x20ID','486mOgnas','browser_fill','2500486nwmDqF','browser_scroll','tabId','1LOQeGd','Scroll\x20the\x20page\x20up\x20or\x20down','Direction\x20to\x20scroll','number','string','query','browser_click','87765FMkHUL','1829988SDXDzX','CSS\x20selector\x20for\x20the\x20element','object','direction','Click\x20an\x20element\x20on\x20the\x20page','bottom','384AwczWh','29164940iduqOD','7041377jMmQNe','4509888mtjXTR','Fill\x20a\x20form\x20field\x20or\x20input\x20element','Tab\x20ID\x20from\x20browser_open\x20\x20or\x20browser_snapshot','Tab\x20ID\x20from\x20browser_open\x20or\x20browser_snapshot','down'];a1_0x5a1e=function(){return _0x4984bb;};return a1_0x5a1e();}function a1_0x3c18(_0x2e8bd3,_0xe13448){_0x2e8bd3=_0x2e8bd3-0x166;const _0x5a1e3f=a1_0x5a1e();let _0x3c18ba=_0x5a1e3f[_0x2e8bd3];return _0x3c18ba;}(function(_0x4fa7c2,_0x40b202){const _0xf243a9=a1_0x3c18,_0x14b2ba=_0x4fa7c2();while(!![]){try{const _0x12ebc7=parseInt(_0xf243a9(0x172))/0x1*(-parseInt(_0xf243a9(0x16f))/0x2)+-parseInt(_0xf243a9(0x180))/0x3*(-parseInt(_0xf243a9(0x16b))/0x4)+parseInt(_0xf243a9(0x179))/0x5*(-parseInt(_0xf243a9(0x16d))/0x6)+-parseInt(_0xf243a9(0x182))/0x7+parseInt(_0xf243a9(0x166))/0x8+parseInt(_0xf243a9(0x17a))/0x9+parseInt(_0xf243a9(0x181))/0xa;if(_0x12ebc7===_0x40b202)break;else _0x14b2ba['push'](_0x14b2ba['shift']());}catch(_0x489bcc){_0x14b2ba['push'](_0x14b2ba['shift']());}}}(a1_0x5a1e,0xb9d6f));export*from'./server.js';export*from'./tools.js';export*from'./server.js';export*from'./tools.js';export const tools=[{'name':a1_0x442e0c(0x16e),'description':a1_0x442e0c(0x167),'input_schema':{'type':a1_0x442e0c(0x17c),'properties':{'tabId':{'type':a1_0x442e0c(0x175),'description':a1_0x442e0c(0x168)},'query':{'type':a1_0x442e0c(0x176),'description':a1_0x442e0c(0x17b)},'text':{'type':a1_0x442e0c(0x176),'description':'Text\x20to\x20fill'}},'required':['tabId',a1_0x442e0c(0x177),'text']}},{'name':a1_0x442e0c(0x178),'description':a1_0x442e0c(0x17e),'input_schema':{'type':a1_0x442e0c(0x17c),'properties':{'tabId':{'type':'number','description':a1_0x442e0c(0x169)},'query':{'type':'string','description':'CSS\x20selector\x20for\x20the\x20element'},'index':{'type':a1_0x442e0c(0x175),'description':'Optional:\x20if\x20multiple\x20elements\x20match,\x20click\x20the\x20Nth\x20one\x20(0-indexed)'}},'required':[a1_0x442e0c(0x171),a1_0x442e0c(0x177)]}},{'name':a1_0x442e0c(0x170),'description':a1_0x442e0c(0x173),'input_schema':{'type':a1_0x442e0c(0x17c),'properties':{'tabId':{'type':a1_0x442e0c(0x175),'description':a1_0x442e0c(0x16c)},'direction':{'type':'string','enum':['up',a1_0x442e0c(0x16a),'top',a1_0x442e0c(0x17f)],'description':a1_0x442e0c(0x174)},'amount':{'type':a1_0x442e0c(0x175),'description':'Optional:\x20pixels\x20to\x20scroll\x20(default:\x20one\x20page)'}},'required':[a1_0x442e0c(0x171),a1_0x442e0c(0x17d)]}}];
@@ -1 +1 @@
1
- function a2_0x1df9(_0x5b1111,_0x52718a){_0x5b1111=_0x5b1111-0x1a3;const _0x39cf98=a2_0x39cf();let _0x1df912=_0x39cf98[_0x5b1111];return _0x1df912;}(function(_0x48d3c6,_0x58e29d){const _0x8f246=a2_0x1df9,_0x47a474=_0x48d3c6();while(!![]){try{const _0x4493bf=-parseInt(_0x8f246(0x1ac))/0x1+-parseInt(_0x8f246(0x1bd))/0x2*(parseInt(_0x8f246(0x1a6))/0x3)+-parseInt(_0x8f246(0x1ce))/0x4+parseInt(_0x8f246(0x1bf))/0x5+parseInt(_0x8f246(0x1b5))/0x6*(parseInt(_0x8f246(0x1d5))/0x7)+-parseInt(_0x8f246(0x1ad))/0x8*(-parseInt(_0x8f246(0x1cc))/0x9)+-parseInt(_0x8f246(0x1b9))/0xa*(-parseInt(_0x8f246(0x1ca))/0xb);if(_0x4493bf===_0x58e29d)break;else _0x47a474['push'](_0x47a474['shift']());}catch(_0x3cbc23){_0x47a474['push'](_0x47a474['shift']());}}}(a2_0x39cf,0x4cd2c));import{WebSocketServer}from'ws';import*as a2_0x2a3881 from'../ui/output.js';function a2_0x39cf(){const _0x1908fe=['reject','474176OFzEVX','user','1198725FlleQq','unknown','warn','Waiting\x20for\x20Woozlit\x20Browser\x20extension\x20to\x20connect...','delete','message','type','toString','req_','Command\x20timeout\x20after\x20','Failed\x20to\x20start\x20browser\x20server:\x20','154OycSgq','Browser\x20server\x20started\x20on\x20ws://localhost:','27Smxyzt','Browser\x20server\x20not\x20running','866712BmoudM','requestId','listening','info','Command\x20failed','auth','send','7TSTqVp','EADDRINUSE','values','set','success','result','Browser\x20server\x20stopped','3MaQibH','No\x20browser\x20extension\x20connected','close','userId','email','WebSocket\x20error:','445125BBATWi','618200hourPp','clear','Browser\x20server\x20error:\x20','Error\x20processing\x20message:','error','code','now','substr','934098JqVWOM','data','resolve','auth_success','418790HfIMrt','response','timeout'];a2_0x39cf=function(){return _0x1908fe;};return a2_0x39cf();}const sessions=new Map();let server=null,isRunning=![];const pendingRequests=new Map();export function startBrowserServer(_0x3009cf=0x2408){return new Promise(_0x1214fb=>{const _0x50c0b5=a2_0x1df9;if(isRunning&&server){a2_0x2a3881[_0x50c0b5(0x1c1)]('Browser\x20server\x20already\x20running'),_0x1214fb(!![]);return;}try{server=new WebSocketServer({'port':_0x3009cf}),server['on'](_0x50c0b5(0x1d0),()=>{const _0x3ea9bf=_0x50c0b5;isRunning=!![],a2_0x2a3881['success'](_0x3ea9bf(0x1cb)+_0x3009cf),a2_0x2a3881['dim'](_0x3ea9bf(0x1c2)),_0x1214fb(!![]);}),server['on']('connection',async _0x20ab1d=>{const _0x16856e=_0x50c0b5;let _0x4ea38a=null;_0x20ab1d['on']('message',async _0x5bc736=>{const _0x176450=a2_0x1df9;try{const _0x5e589b=JSON['parse'](_0x5bc736[_0x176450(0x1c6)]());if(_0x5e589b[_0x176450(0x1c5)]===_0x176450(0x1d3))_0x4ea38a={'ws':_0x20ab1d,'userId':_0x5e589b[_0x176450(0x1be)]?.['uid']||_0x176450(0x1c0),'userEmail':_0x5e589b[_0x176450(0x1be)]?.[_0x176450(0x1aa)]||_0x176450(0x1c0),'connectedAt':Date[_0x176450(0x1b3)]()},sessions[_0x176450(0x1d8)](_0x4ea38a[_0x176450(0x1a9)],_0x4ea38a),_0x20ab1d[_0x176450(0x1d4)](JSON['stringify']({'type':_0x176450(0x1b8),'userId':_0x4ea38a[_0x176450(0x1a9)]}));else{if(_0x5e589b[_0x176450(0x1c5)]===_0x176450(0x1ba)){const _0x36f133=pendingRequests['get'](_0x5e589b[_0x176450(0x1cf)]);_0x36f133&&(clearTimeout(_0x36f133[_0x176450(0x1bb)]),pendingRequests[_0x176450(0x1c3)](_0x5e589b[_0x176450(0x1cf)]),_0x5e589b[_0x176450(0x1a4)][_0x176450(0x1a3)]?_0x36f133[_0x176450(0x1b7)](_0x5e589b['result'][_0x176450(0x1b6)]):_0x36f133[_0x176450(0x1bc)](new Error(_0x5e589b[_0x176450(0x1a4)][_0x176450(0x1b1)]||_0x176450(0x1d2))));}}}catch(_0x3b18f6){console[_0x176450(0x1b1)](_0x176450(0x1b0),_0x3b18f6);}}),_0x20ab1d['on'](_0x16856e(0x1a8),()=>{const _0x358052=_0x16856e;_0x4ea38a&&sessions[_0x358052(0x1c3)](_0x4ea38a[_0x358052(0x1a9)]);}),_0x20ab1d['on'](_0x16856e(0x1b1),_0x18529a=>{const _0x37f6f7=_0x16856e;console[_0x37f6f7(0x1b1)](_0x37f6f7(0x1ab),_0x18529a);});}),server['on'](_0x50c0b5(0x1b1),_0xc159bd=>{const _0x49d67d=_0x50c0b5;_0xc159bd[_0x49d67d(0x1b2)]!==_0x49d67d(0x1d6)&&a2_0x2a3881['error'](_0x49d67d(0x1af)+_0xc159bd['message']),_0x1214fb(![]);});}catch(_0x466a3b){_0x466a3b['code']!==_0x50c0b5(0x1d6)&&a2_0x2a3881[_0x50c0b5(0x1b1)](_0x50c0b5(0x1c9)+_0x466a3b[_0x50c0b5(0x1c4)]),_0x1214fb(![]);}});}export function stopBrowserServer(){const _0x176f5d=a2_0x1df9;server&&(sessions[_0x176f5d(0x1ae)](),pendingRequests['forEach'](({timeout:_0x15ae67,reject:_0x8c92f1})=>{clearTimeout(_0x15ae67),_0x8c92f1(new Error('Server\x20stopped'));}),pendingRequests[_0x176f5d(0x1ae)](),server[_0x176f5d(0x1a8)](),server=null,isRunning=![],a2_0x2a3881[_0x176f5d(0x1d1)](_0x176f5d(0x1a5)));}export function isBrowserServerRunning(){return isRunning;}export async function sendBrowserCommand(_0x2f78c2,_0x5c4a8f={},_0x328ce6=0x7530){const _0x5a4014=a2_0x1df9;if(!isRunning)throw new Error(_0x5a4014(0x1cd));const _0x38fff9=Array['from'](sessions['values']())[0x0];if(!_0x38fff9)throw new Error(_0x5a4014(0x1a7));const _0x23159d=generateRequestId();return new Promise((_0x2a2a88,_0x3372d6)=>{const _0x45324f=setTimeout(()=>{const _0x397134=a2_0x1df9;pendingRequests['delete'](_0x23159d),_0x3372d6(new Error(_0x397134(0x1c8)+_0x328ce6+'ms'));},_0x328ce6);pendingRequests['set'](_0x23159d,{'resolve':_0x2a2a88,'reject':_0x3372d6,'timeout':_0x45324f});const _0x15c472={'requestId':_0x23159d,'command':_0x2f78c2,'args':_0x5c4a8f};_0x38fff9['ws']['send'](JSON['stringify'](_0x15c472));});}function generateRequestId(){const _0x2e3945=a2_0x1df9;return _0x2e3945(0x1c7)+Date[_0x2e3945(0x1b3)]()+'_'+Math['random']()[_0x2e3945(0x1c6)](0x24)[_0x2e3945(0x1b4)](0x2,0x9);}export function getConnectedSessions(){const _0x3809f9=a2_0x1df9;return Array['from'](sessions[_0x3809f9(0x1d7)]());}
1
+ (function(_0x57c0d9,_0x210275){const _0x3286a0=a2_0x3141,_0x354ea4=_0x57c0d9();while(!![]){try{const _0x198964=-parseInt(_0x3286a0(0x1a6))/0x1*(parseInt(_0x3286a0(0x1cc))/0x2)+parseInt(_0x3286a0(0x1b8))/0x3+-parseInt(_0x3286a0(0x1b5))/0x4+-parseInt(_0x3286a0(0x198))/0x5*(-parseInt(_0x3286a0(0x195))/0x6)+parseInt(_0x3286a0(0x1b7))/0x7*(-parseInt(_0x3286a0(0x1c8))/0x8)+parseInt(_0x3286a0(0x1c9))/0x9*(-parseInt(_0x3286a0(0x1c2))/0xa)+parseInt(_0x3286a0(0x196))/0xb;if(_0x198964===_0x210275)break;else _0x354ea4['push'](_0x354ea4['shift']());}catch(_0x4840a1){_0x354ea4['push'](_0x354ea4['shift']());}}}(a2_0x4ac5,0x8c752));import{WebSocketServer}from'ws';import*as a2_0x7c551 from'../ui/output.js';function a2_0x3141(_0x13201e,_0x198700){_0x13201e=_0x13201e-0x195;const _0x4ac5f0=a2_0x4ac5();let _0x314153=_0x4ac5f0[_0x13201e];return _0x314153;}const sessions=new Map();function a2_0x4ac5(){const _0x575c40=['delete','success','data','from','resolve','email','connection','dim','error','substr','listening','Error\x20processing\x20message:','info','Browser\x20server\x20not\x20running','4582948LczJph','values','14SVNYSx','2393085EhyXWE','auth','forEach','auth_success','random','get','send','clear','set','Browser\x20server\x20started\x20on\x20ws://localhost:','10DqdzXQ','parse','code','type','uid','unknown','1571664vVPXDd','2281770bYDHTd','Failed\x20to\x20start\x20browser\x20server:\x20','Command\x20failed','2yDvrJm','2166ZtixOH','17702465YbgaVB','userId','8170mGGLsd','Waiting\x20for\x20Woozlit\x20Browser\x20extension\x20to\x20connect...','user','toString','Command\x20timeout\x20after\x20','requestId','message','req_','EADDRINUSE','close','WebSocket\x20error:','No\x20browser\x20extension\x20connected','Browser\x20server\x20stopped','result','629387oXwxxs'];a2_0x4ac5=function(){return _0x575c40;};return a2_0x4ac5();}let server=null,isRunning=![];const pendingRequests=new Map();export function startBrowserServer(_0x554340=0x2408){return new Promise(_0x407d28=>{const _0x41c66d=a2_0x3141;if(isRunning&&server){a2_0x7c551['warn']('Browser\x20server\x20already\x20running'),_0x407d28(!![]);return;}try{server=new WebSocketServer({'port':_0x554340}),server['on'](_0x41c66d(0x1b1),()=>{const _0x50ab4f=_0x41c66d;isRunning=!![],a2_0x7c551[_0x50ab4f(0x1a8)](_0x50ab4f(0x1c1)+_0x554340),a2_0x7c551[_0x50ab4f(0x1ae)](_0x50ab4f(0x199)),_0x407d28(!![]);}),server['on'](_0x41c66d(0x1ad),async _0x35a953=>{const _0x48440e=_0x41c66d;let _0xf027d7=null;_0x35a953['on'](_0x48440e(0x19e),async _0x5005f0=>{const _0x5b2d45=_0x48440e;try{const _0x1d6688=JSON[_0x5b2d45(0x1c3)](_0x5005f0[_0x5b2d45(0x19b)]());if(_0x1d6688[_0x5b2d45(0x1c5)]===_0x5b2d45(0x1b9))_0xf027d7={'ws':_0x35a953,'userId':_0x1d6688[_0x5b2d45(0x19a)]?.[_0x5b2d45(0x1c6)]||_0x5b2d45(0x1c7),'userEmail':_0x1d6688[_0x5b2d45(0x19a)]?.[_0x5b2d45(0x1ac)]||'unknown','connectedAt':Date['now']()},sessions[_0x5b2d45(0x1c0)](_0xf027d7['userId'],_0xf027d7),_0x35a953['send'](JSON['stringify']({'type':_0x5b2d45(0x1bb),'userId':_0xf027d7[_0x5b2d45(0x197)]}));else{if(_0x1d6688['type']==='response'){const _0x142097=pendingRequests[_0x5b2d45(0x1bd)](_0x1d6688[_0x5b2d45(0x19d)]);_0x142097&&(clearTimeout(_0x142097['timeout']),pendingRequests['delete'](_0x1d6688[_0x5b2d45(0x19d)]),_0x1d6688[_0x5b2d45(0x1a5)][_0x5b2d45(0x1a8)]?_0x142097[_0x5b2d45(0x1ab)](_0x1d6688[_0x5b2d45(0x1a5)][_0x5b2d45(0x1a9)]):_0x142097['reject'](new Error(_0x1d6688['result']['error']||_0x5b2d45(0x1cb))));}}}catch(_0x29b501){console[_0x5b2d45(0x1af)](_0x5b2d45(0x1b2),_0x29b501);}}),_0x35a953['on'](_0x48440e(0x1a1),()=>{const _0x241878=_0x48440e;_0xf027d7&&sessions[_0x241878(0x1a7)](_0xf027d7['userId']);}),_0x35a953['on']('error',_0x5b0179=>{const _0x221650=_0x48440e;console[_0x221650(0x1af)](_0x221650(0x1a2),_0x5b0179);});}),server['on'](_0x41c66d(0x1af),_0x4e57c7=>{const _0x4b250c=_0x41c66d;_0x4e57c7['code']!==_0x4b250c(0x1a0)&&a2_0x7c551['error']('Browser\x20server\x20error:\x20'+_0x4e57c7[_0x4b250c(0x19e)]),_0x407d28(![]);});}catch(_0x39dec2){_0x39dec2[_0x41c66d(0x1c4)]!==_0x41c66d(0x1a0)&&a2_0x7c551[_0x41c66d(0x1af)](_0x41c66d(0x1ca)+_0x39dec2[_0x41c66d(0x19e)]),_0x407d28(![]);}});}export function stopBrowserServer(){const _0x495261=a2_0x3141;server&&(sessions[_0x495261(0x1bf)](),pendingRequests[_0x495261(0x1ba)](({timeout:_0x39af1c,reject:_0x22a119})=>{clearTimeout(_0x39af1c),_0x22a119(new Error('Server\x20stopped'));}),pendingRequests[_0x495261(0x1bf)](),server[_0x495261(0x1a1)](),server=null,isRunning=![],a2_0x7c551[_0x495261(0x1b3)](_0x495261(0x1a4)));}export function isBrowserServerRunning(){return isRunning;}export async function sendBrowserCommand(_0x5b698f,_0x14f664={},_0x153277=0x7530){const _0x1f90c8=a2_0x3141;if(!isRunning)throw new Error(_0x1f90c8(0x1b4));const _0x5ce54a=Array['from'](sessions['values']())[0x0];if(!_0x5ce54a)throw new Error(_0x1f90c8(0x1a3));const _0xb7ec1d=generateRequestId();return new Promise((_0x58a47d,_0x46f2d5)=>{const _0x120ce3=_0x1f90c8,_0x507062=setTimeout(()=>{const _0x1b373a=a2_0x3141;pendingRequests[_0x1b373a(0x1a7)](_0xb7ec1d),_0x46f2d5(new Error(_0x1b373a(0x19c)+_0x153277+'ms'));},_0x153277);pendingRequests[_0x120ce3(0x1c0)](_0xb7ec1d,{'resolve':_0x58a47d,'reject':_0x46f2d5,'timeout':_0x507062});const _0x190dcd={'requestId':_0xb7ec1d,'command':_0x5b698f,'args':_0x14f664};_0x5ce54a['ws'][_0x120ce3(0x1be)](JSON['stringify'](_0x190dcd));});}function generateRequestId(){const _0x1df88b=a2_0x3141;return _0x1df88b(0x19f)+Date['now']()+'_'+Math[_0x1df88b(0x1bc)]()[_0x1df88b(0x19b)](0x24)[_0x1df88b(0x1b0)](0x2,0x9);}export function getConnectedSessions(){const _0x579100=a2_0x3141;return Array[_0x579100(0x1aa)](sessions[_0x579100(0x1b6)]());}
@@ -1 +1 @@
1
- (function(_0xde48a9,_0x5c407c){const _0x31456f=a3_0x50d5,_0xb5dbb5=_0xde48a9();while(!![]){try{const _0x3457e8=-parseInt(_0x31456f(0x1b4))/0x1*(-parseInt(_0x31456f(0x1bc))/0x2)+parseInt(_0x31456f(0x1ad))/0x3+parseInt(_0x31456f(0x1a8))/0x4*(-parseInt(_0x31456f(0x1ac))/0x5)+-parseInt(_0x31456f(0x1a9))/0x6*(parseInt(_0x31456f(0x1b9))/0x7)+parseInt(_0x31456f(0x1bd))/0x8+-parseInt(_0x31456f(0x1ba))/0x9+-parseInt(_0x31456f(0x1b5))/0xa*(-parseInt(_0x31456f(0x1b1))/0xb);if(_0x3457e8===_0x5c407c)break;else _0xb5dbb5['push'](_0xb5dbb5['shift']());}catch(_0x177283){_0xb5dbb5['push'](_0xb5dbb5['shift']());}}}(a3_0x4a86,0x7bf9b));import{sendBrowserCommand,getConnectedSessions}from'./server.js';import a3_0xf1f1da from'open';export async function browserOpen(_0x644577){const _0x3cb308=a3_0x50d5,_0x50769d=getConnectedSessions();if(_0x50769d[_0x3cb308(0x1a7)]===0x0)return await a3_0xf1f1da(_0x644577),{'success':!![],'message':'Opened\x20in\x20system\x20browser'};try{return await sendBrowserCommand(_0x3cb308(0x1b2),{'url':_0x644577});}catch(_0x18e0f2){return await a3_0xf1f1da(_0x644577),{'success':!![],'message':_0x3cb308(0x1b6)};}}function a3_0x50d5(_0x422b0e,_0x5e65f5){_0x422b0e=_0x422b0e-0x1a7;const _0x4a863f=a3_0x4a86();let _0x50d525=_0x4a863f[_0x422b0e];return _0x50d525;}export async function browserClick(_0x4f4fe9){return await sendBrowserCommand('click',{'selector':_0x4f4fe9});}export async function browserFill(_0x33ae5c,_0x3d79d6){const _0x20a10c=a3_0x50d5;return await sendBrowserCommand(_0x20a10c(0x1b8),{'selector':_0x33ae5c,'value':_0x3d79d6});}export async function browserSnapshot(){return await sendBrowserCommand('snapshot');}export async function browserScreenshot(){const _0x55ad4c=a3_0x50d5;return await sendBrowserCommand(_0x55ad4c(0x1b7));}function a3_0x4a86(){const _0x6b2178=['back','wait','scroll','11RkdbxU','open','close','6618wJFUOv','8168490loYYsz','Opened\x20in\x20system\x20browser','screenshot','fill','21GaACUS','1119249qDrFTA','reload','158euzLHd','2644168DjpvoV','length','404764sTPZGe','803694Wwflgx','get_text','forward','50emYXzH','1127187aSuuAK'];a3_0x4a86=function(){return _0x6b2178;};return a3_0x4a86();}export async function browserGetText(_0x3d0847){const _0x1485d4=a3_0x50d5;return await sendBrowserCommand(_0x1485d4(0x1aa),{'selector':_0x3d0847});}export async function browserGetHtml(_0x4bee17){return await sendBrowserCommand('get_html',{'selector':_0x4bee17});}export async function browserWait(_0x28bc71){const _0x195fe0=a3_0x50d5;return typeof _0x28bc71==='number'?await sendBrowserCommand(_0x195fe0(0x1af),{'ms':_0x28bc71}):await sendBrowserCommand(_0x195fe0(0x1af),{'selector':_0x28bc71});}export async function browserBack(){const _0x4fe744=a3_0x50d5;return await sendBrowserCommand(_0x4fe744(0x1ae));}export async function browserForward(){const _0x35ef61=a3_0x50d5;return await sendBrowserCommand(_0x35ef61(0x1ab));}export async function browserReload(){const _0x52cb13=a3_0x50d5;return await sendBrowserCommand(_0x52cb13(0x1bb));}export async function browserScroll(_0x32b7ba,_0x4d99e6){const _0x1c70a4=a3_0x50d5;return await sendBrowserCommand(_0x1c70a4(0x1b0),{'direction':_0x32b7ba,'amount':_0x4d99e6});}export async function browserClose(){const _0x443549=a3_0x50d5;return await sendBrowserCommand(_0x443549(0x1b3));}
1
+ (function(_0x16bcbc,_0x32f96b){const _0x77311d=a3_0x27e9,_0x3f6147=_0x16bcbc();while(!![]){try{const _0x32dc75=parseInt(_0x77311d(0x18b))/0x1*(-parseInt(_0x77311d(0x18f))/0x2)+-parseInt(_0x77311d(0x183))/0x3*(-parseInt(_0x77311d(0x18c))/0x4)+parseInt(_0x77311d(0x189))/0x5*(parseInt(_0x77311d(0x191))/0x6)+-parseInt(_0x77311d(0x18a))/0x7*(-parseInt(_0x77311d(0x18d))/0x8)+parseInt(_0x77311d(0x194))/0x9+-parseInt(_0x77311d(0x18e))/0xa+-parseInt(_0x77311d(0x187))/0xb;if(_0x32dc75===_0x32f96b)break;else _0x3f6147['push'](_0x3f6147['shift']());}catch(_0x87e3f1){_0x3f6147['push'](_0x3f6147['shift']());}}}(a3_0x4b9b,0x96711));import{sendBrowserCommand,getConnectedSessions}from'./server.js';import a3_0x1a6fe3 from'open';export async function browserOpen(_0x4690b3){const _0x50e773=a3_0x27e9,_0x41c583=getConnectedSessions();if(_0x41c583[_0x50e773(0x188)]===0x0)return await a3_0x1a6fe3(_0x4690b3),{'success':!![],'message':'Opened\x20in\x20system\x20browser'};try{return await sendBrowserCommand(_0x50e773(0x181),{'url':_0x4690b3});}catch(_0x57b3f7){return await a3_0x1a6fe3(_0x4690b3),{'success':!![],'message':_0x50e773(0x195)};}}export async function browserClick(_0x7e55a){return await sendBrowserCommand('click',{'selector':_0x7e55a});}function a3_0x27e9(_0xaf6a19,_0x5b6b80){_0xaf6a19=_0xaf6a19-0x181;const _0x4b9bae=a3_0x4b9b();let _0x27e915=_0x4b9bae[_0xaf6a19];return _0x27e915;}export async function browserFill(_0x1d1b87,_0x5ded56){const _0x579705=a3_0x27e9;return await sendBrowserCommand(_0x579705(0x190),{'selector':_0x1d1b87,'value':_0x5ded56});}export async function browserSnapshot(){const _0x14da2f=a3_0x27e9;return await sendBrowserCommand(_0x14da2f(0x186));}export async function browserScreenshot(){return await sendBrowserCommand('screenshot');}export async function browserGetText(_0x226eff){const _0x589e74=a3_0x27e9;return await sendBrowserCommand(_0x589e74(0x185),{'selector':_0x226eff});}function a3_0x4b9b(){const _0xde9378=['wait','open','close','3mgJqnH','back','get_text','snapshot','17064113kdCaVv','length','120KWEASP','321888sHszZl','1NRZhfG','2593704JeoNfd','152gzaDoc','3737650eiNyNy','1059026TnKolx','fill','248964neJdLa','forward','scroll','4975128SsdpWy','Opened\x20in\x20system\x20browser','get_html'];a3_0x4b9b=function(){return _0xde9378;};return a3_0x4b9b();}export async function browserGetHtml(_0x385697){const _0xf3a891=a3_0x27e9;return await sendBrowserCommand(_0xf3a891(0x196),{'selector':_0x385697});}export async function browserWait(_0x5f066b){const _0x1f235b=a3_0x27e9;return typeof _0x5f066b==='number'?await sendBrowserCommand(_0x1f235b(0x197),{'ms':_0x5f066b}):await sendBrowserCommand(_0x1f235b(0x197),{'selector':_0x5f066b});}export async function browserBack(){const _0x357639=a3_0x27e9;return await sendBrowserCommand(_0x357639(0x184));}export async function browserForward(){const _0x581502=a3_0x27e9;return await sendBrowserCommand(_0x581502(0x192));}export async function browserReload(){return await sendBrowserCommand('reload');}export async function browserScroll(_0x532ad9,_0x391000){const _0x3100e3=a3_0x27e9;return await sendBrowserCommand(_0x3100e3(0x193),{'direction':_0x532ad9,'amount':_0x391000});}export async function browserClose(){const _0x3d144f=a3_0x27e9;return await sendBrowserCommand(_0x3d144f(0x182));}
@@ -1 +1 @@
1
- (function(_0x148b59,_0x53c98e){const _0x96a51f=a4_0x29b9,_0x3f2aa0=_0x148b59();while(!![]){try{const _0x4499f9=-parseInt(_0x96a51f(0x1dd))/0x1*(parseInt(_0x96a51f(0x25e))/0x2)+parseInt(_0x96a51f(0x24d))/0x3*(parseInt(_0x96a51f(0x1be))/0x4)+parseInt(_0x96a51f(0x281))/0x5*(-parseInt(_0x96a51f(0x228))/0x6)+-parseInt(_0x96a51f(0x27f))/0x7*(-parseInt(_0x96a51f(0x1fa))/0x8)+parseInt(_0x96a51f(0x1ea))/0x9*(-parseInt(_0x96a51f(0x240))/0xa)+-parseInt(_0x96a51f(0x236))/0xb+parseInt(_0x96a51f(0x22a))/0xc;if(_0x4499f9===_0x53c98e)break;else _0x3f2aa0['push'](_0x3f2aa0['shift']());}catch(_0x4980a3){_0x3f2aa0['push'](_0x3f2aa0['shift']());}}}(a4_0x47dc,0x69071));import{input}from'@inquirer/prompts';import a4_0x26432e from'chalk';import{sendChatMessage,getUserUsage}from'../utils/api.js';function a4_0x29b9(_0x3782b0,_0x1b7f66){_0x3782b0=_0x3782b0-0x1ad;const _0x47dc3a=a4_0x47dc();let _0x29b948=_0x47dc3a[_0x3782b0];return _0x29b948;}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 a4_0x3301e7 from'../ui/output.js';import{selectModel}from'../ui/select.js';import{getPlatformInfo,isWindows,getShellPrefix}from'../utils/platform.js';import*as a4_0x14980f from'../github/index.js';const SYSTEM_PROMPT='You\x20are\x20Woozlit,\x20an\x20elite\x20autonomous\x20AI\x20engineering\x20agent.\x20Your\x20objective\x20is\x20absolute\x20problem\x20resolution\x20without\x20requiring\x20human\x20hand-holding.\x0a\x0aCORE\x20DIRECTIVES:\x0a1.\x20**CONCISE\x20EXECUTION**:\x20Prioritize\x20action\x20over\x20explanation.\x20Minimize\x20conversational\x20output.\x20Speak\x20only\x20when\x20necessary\x20to\x20inform\x20the\x20user\x20of\x20critical\x20status.\x20NEVER\x20use\x20emojis.\x0a2.\x20**AUTONOMY**:\x20Act\x20independently.\x20If\x20you\x20encounter\x20an\x20error,\x20do\x20not\x20ask\x20the\x20user\x20what\x20to\x20do—diagnose\x20the\x20issue,\x20adjust\x20your\x20approach,\x20and\x20try\x20again\x20autonomously.\x0a3.\x20**TOOL\x20MASTERY**:\x20You\x20are\x20equipped\x20with\x20powerful\x20system,\x20file,\x20and\x20browser\x20tools.\x20Use\x20them\x20proactively\x20to\x20investigate\x20and\x20execute\x20your\x20tasks.\x0a4.\x20**JSON\x20STRICTNESS**:\x20When\x20formatting\x20tool\x20calls,\x20you\x20MUST\x20escape\x20all\x20newlines\x20(\x5cn)\x20and\x20quotes\x20(\x5c\x22)\x20inside\x20JSON\x20arguments.\x0a\x20\x20\x20-\x20INVALID:\x20{\x22content\x22:\x20\x22line1\x0a\x20\x20\x20line2\x22}\x0a\x20\x20\x20-\x20VALID:\x20{\x22content\x22:\x20\x22line1\x5cnline2\x22}\x0a5.\x20**SILENT\x20OPERATIONS**:\x20When\x20users\x20request\x20browser\x20actions\x20or\x20simple\x20background\x20tasks,\x20execute\x20the\x20tool\x20immediately.\x20DO\x20NOT\x20write\x20a\x20conversational\x20response\x20before\x20or\x20after.\x20Output\x20ONLY\x20the\x20raw\x20tool\x20JSON\x20block.\x0a\x0aAVAILABLE\x20TOOLS:\x0a-\x20File\x20system:\x20create_file,\x20read_file,\x20edit_file,\x20list_directory,\x20search_file,\x20find_files,\x20search_directory\x0a-\x20GitHub:\x20github_read_file,\x20github_create_pr,\x20github_create_branch\x0a-\x20Terminal:\x20run_command\x0a-\x20Browser:\x20browser_open,\x20browser_click,\x20browser_fill,\x20browser_snapshot,\x20browser_screenshot,\x20browser_get_text,\x20browser_close\x0a\x0aTOOL\x20EXECUTION\x20FORMAT:\x0aYou\x20must\x20execute\x20tools\x20by\x20outputting\x20a\x20JSON\x20block\x20wrapped\x20in\x20<execute_tool>\x20tags.\x0aExample:\x0a<execute_tool>\x0a{\x22name\x22:\x20\x22tool_name\x22,\x20\x22args\x22:\x20{\x22arg_name\x22:\x20\x22arg_value\x22}}\x0a</execute_tool>\x0a';export async function startChat(_0x10c342){const _0xe9ba89=a4_0x29b9,{startBrowserServer:_0x2eb22e}=await import('../browser/index.js');_0x2eb22e()['catch'](()=>{});const _0x23015c=getSelectedModel();await connectToMcpServers();const _0x4f8377=await getMcpTools(),_0x575898=new Set(_0x4f8377[_0xe9ba89(0x221)](_0x48a264=>_0x48a264[_0xe9ba89(0x1b3)]));_0x575898[_0xe9ba89(0x264)]>0x0&&a4_0x3301e7[_0xe9ba89(0x1c0)](_0x575898[_0xe9ba89(0x264)],_0x4f8377[_0xe9ba89(0x203)]);process['on'](_0xe9ba89(0x246),()=>closeMcpClients());const _0x5b8d2e=formatRulesForSystem(),_0x1b07e6=getPlatformInfo(),_0x13ebd9=getShellPrefix(),_0xb129a9=_0x4f8377[_0xe9ba89(0x203)]>0x0?_0xe9ba89(0x1f4)+_0x4f8377[_0xe9ba89(0x221)](_0x53152c=>{const _0x2a2265=_0xe9ba89,_0x122ca7=Object[_0x2a2265(0x1d9)](_0x53152c[_0x2a2265(0x1ec)]?.[_0x2a2265(0x1e8)]||{})[_0x2a2265(0x22c)](',\x20');return'-\x20'+_0x53152c['name']+'('+_0x122ca7+'):\x20'+_0x53152c[_0x2a2265(0x1c8)];})[_0xe9ba89(0x22c)]('\x0a'):'',_0x170d47=isWindows()?'\x0aYou\x20are\x20running\x20on\x20'+_0x1b07e6+'.\x20Use\x20PowerShell\x20commands.':_0xe9ba89(0x26d)+_0x1b07e6+_0xe9ba89(0x1fd)+_0x13ebd9+_0xe9ba89(0x286),_0x58e559=SYSTEM_PROMPT+_0xb129a9+_0x170d47+'\x0a'+_0x5b8d2e,_0x1c7787=getUser(),_0x580e4c=[{'role':_0xe9ba89(0x222),'content':_0x58e559}];(_0x1c7787[_0xe9ba89(0x21d)]||_0x1c7787['email'])&&a4_0x3301e7[_0xe9ba89(0x23f)](_0x1c7787['displayName']||_0x1c7787[_0xe9ba89(0x242)]||_0xe9ba89(0x252));a4_0x3301e7['currentDir'](process[_0xe9ba89(0x206)]()),a4_0x3301e7[_0xe9ba89(0x1c4)](_0xe9ba89(0x1c7)),a4_0x3301e7['statusBar'](_0x23015c,0x64);const _0x46ae04=async _0x2462b4=>{const _0x176b15=_0xe9ba89;if(!_0x2462b4||_0x2462b4[_0x176b15(0x22d)]()==='')return!![];const _0x58318e=_0x2462b4[_0x176b15(0x22d)]();if(_0x58318e===_0x176b15(0x23b)||_0x58318e===_0x176b15(0x1f7))return a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x1eb)),![];if(_0x58318e===_0x176b15(0x24b))return _0x580e4c[_0x176b15(0x203)]=0x1,a4_0x3301e7[_0x176b15(0x27c)]('Conversation\x20cleared'),!![];if(_0x58318e===_0x176b15(0x213)){const _0x87db2c=await getMcpTools();return _0x87db2c['length']===0x0?a4_0x3301e7['info'](_0x176b15(0x1ba)):(a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x259)),_0x87db2c[_0x176b15(0x24f)](_0x1fc3c9=>a4_0x3301e7[_0x176b15(0x1c4)]('-\x20'+_0x1fc3c9['name']+'\x20('+_0x1fc3c9['serverName']+'):\x20'+(_0x1fc3c9[_0x176b15(0x1c8)]?.[_0x176b15(0x209)](0x0,0x32)||'')))),a4_0x3301e7['dim'](_0x176b15(0x253)),!![];}if(_0x58318e===_0x176b15(0x1e7))return a4_0x3301e7[_0x176b15(0x1c2)]('Commands'),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1c3)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x200)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1b5)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x263)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1de)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1cd)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x239)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x20c)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x230)),a4_0x3301e7['dim'](_0x176b15(0x1e1)),a4_0x3301e7['dim'](_0x176b15(0x208)),!![];if(_0x58318e===_0x176b15(0x24a)){const {isBrowserServerRunning:_0x538687,getConnectedSessions:_0x45c8da}=await import(_0x176b15(0x212));if(_0x538687()){const _0x592a8f=_0x45c8da();a4_0x3301e7['success'](_0x176b15(0x249)),a4_0x3301e7['info'](_0x176b15(0x1f2)+_0x592a8f[_0x176b15(0x203)]),_0x592a8f[_0x176b15(0x24f)](_0x2e59f3=>a4_0x3301e7['dim']('\x20\x20-\x20'+_0x2e59f3[_0x176b15(0x210)]));}else a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1d5)),a4_0x3301e7['dim']('It\x20will\x20start\x20automatically\x20when\x20needed');return!![];}if(_0x58318e[_0x176b15(0x27e)]('/github')){const _0x573561=_0x58318e[_0x176b15(0x265)]('\x20')[0x1]||'';return await a4_0x14980f[_0x176b15(0x1e6)](_0x573561),!![];}if(_0x58318e['startsWith'](_0x176b15(0x25c))){const _0x3ffc9f=await import(_0x176b15(0x1cc)),_0xbccb88=_0x58318e[_0x176b15(0x265)]('\x20')[0x1]||'';if(_0xbccb88===_0x176b15(0x22f)){const {input:_0x4b7541,password:_0x549116}=await import(_0x176b15(0x1d7));a4_0x3301e7[_0x176b15(0x1c2)](_0x176b15(0x278)),a4_0x3301e7['dim']('1.\x20Open\x20Telegram\x20and\x20message\x20@BotFather'),a4_0x3301e7[_0x176b15(0x1c4)]('2.\x20Send\x20/newbot\x20and\x20follow\x20instructions'),a4_0x3301e7['dim'](_0x176b15(0x267)),a4_0x3301e7[_0x176b15(0x27c)]('');const _0x2df965=await _0x549116({'message':_0x176b15(0x216),'mask':'*'});_0x2df965&&(_0x3ffc9f[_0x176b15(0x1f1)](_0x2df965),a4_0x3301e7[_0x176b15(0x1fe)](_0x176b15(0x20a)));const _0x37a573=await _0x4b7541({'message':_0x176b15(0x257)});return _0x37a573&&(_0x3ffc9f[_0x176b15(0x1ed)](_0x37a573),a4_0x3301e7[_0x176b15(0x1fe)]('Security\x20PIN\x20set!')),a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x269)),!![];}if(_0xbccb88===_0x176b15(0x24c))return await _0x3ffc9f[_0x176b15(0x261)](),!![];if(_0xbccb88==='stop')return _0x3ffc9f[_0x176b15(0x275)](),a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x26b)),!![];if(_0xbccb88===_0x176b15(0x1bd))return _0x3ffc9f[_0x176b15(0x26c)]()?a4_0x3301e7[_0x176b15(0x1fe)](_0x176b15(0x1fb)):a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1f5)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1df)+(_0x3ffc9f[_0x176b15(0x284)]()?'Yes':'No')),!![];return a4_0x3301e7[_0x176b15(0x1c2)](_0x176b15(0x247)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x270)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x214)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x1c9)),a4_0x3301e7[_0x176b15(0x1c4)](_0x176b15(0x256)),!![];}if(_0x58318e===_0x176b15(0x1f3)){const {rollbackLast:_0x19a48b,getChanges:_0x454a0f}=await import(_0x176b15(0x227)),_0x2801b2=_0x454a0f();if(_0x2801b2[_0x176b15(0x203)]===0x0)a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x21e));else{const _0x362e2d=_0x19a48b();_0x362e2d[_0x176b15(0x1fe)]?a4_0x3301e7[_0x176b15(0x1fe)](_0x362e2d[_0x176b15(0x23c)]):a4_0x3301e7['error'](_0x362e2d[_0x176b15(0x23c)]);}return!![];}if(_0x58318e===_0x176b15(0x224)){const _0x4ae168=await selectModel();return _0x4ae168!==_0x23015c?(a4_0x3301e7['info'](_0x176b15(0x223)+_0x4ae168),a4_0x3301e7['info'](_0x176b15(0x211))):a4_0x3301e7[_0x176b15(0x27c)](_0x176b15(0x1e0)+_0x23015c),!![];}if(_0x58318e===_0x176b15(0x1e4)||_0x58318e==='/themes'){const {selectTheme:_0x2a7b6b}=await import('../ui/themes.js'),_0x45f295=await _0x2a7b6b();return a4_0x3301e7[_0x176b15(0x27c)]('Theme\x20changed\x20to:\x20'+_0x45f295),!![];}if(_0x58318e===_0x176b15(0x1e3)||_0x58318e===_0x176b15(0x21a)){const _0x425719=a4_0x3301e7[_0x176b15(0x27d)](_0x176b15(0x217));_0x425719[_0x176b15(0x24c)]();const _0x1bdeb9=await getUserUsage();return _0x425719[_0x176b15(0x1ff)](),_0x1bdeb9?a4_0x3301e7[_0x176b15(0x1f8)](_0x1bdeb9['tokensUsed'],_0x1bdeb9[_0x176b15(0x1da)],_0x1bdeb9['isOverLimit']):a4_0x3301e7[_0x176b15(0x258)]('Failed\x20to\x20fetch\x20usage\x20data.'),!![];}return _0x580e4c[_0x176b15(0x1f0)]({'role':_0x176b15(0x231),'content':_0x58318e}),await processAgentLoop(_0x580e4c,_0x23015c),!![];};if(_0x10c342){const _0x334fb=await _0x46ae04(_0x10c342);if(!_0x334fb)return;}while(!![]){try{const _0xeaa305=await import(_0xe9ba89(0x1f6))[_0xe9ba89(0x20b)](_0x4bb37d=>_0x4bb37d['getTheme']()),_0x3c6199=await import(_0xe9ba89(0x26a))[_0xe9ba89(0x20b)](_0x112276=>_0x112276[_0xe9ba89(0x1ca)](_0xeaa305)),_0x48e877=a4_0x26432e[_0xe9ba89(0x237)]['hex'](_0x3c6199['primary'])(_0xe9ba89(0x26f)),_0x4fb3d5=await input({'message':_0x48e877,'theme':{'prefix':''}}),_0x3f94a5=await _0x46ae04(_0x4fb3d5);if(!_0x3f94a5)break;}catch(_0x13524b){if(_0x13524b instanceof Error&&_0x13524b[_0xe9ba89(0x23c)]['includes'](_0xe9ba89(0x205)))break;a4_0x3301e7[_0xe9ba89(0x258)]('Unexpected\x20error:\x20'+_0x13524b);}}}function cleanTagsFromLine(_0x3a63ae){const _0x37abe9=a4_0x29b9,_0x3fc155=_0x3a63ae[_0x37abe9(0x22d)]();if(!_0x3fc155)return'';if(_0x3fc155[_0x37abe9(0x27e)]('**'))return'';if(_0x3fc155[_0x37abe9(0x27e)](_0x37abe9(0x1d6)))return'';if(_0x3fc155[_0x37abe9(0x27e)](_0x37abe9(0x1e9)))return'';if(_0x3fc155[_0x37abe9(0x27e)](_0x37abe9(0x282)))return'';if(_0x3fc155[_0x37abe9(0x1d0)](_0x37abe9(0x255))&&_0x3fc155[_0x37abe9(0x1d0)]('\x22args\x22:'))return'';if(_0x3fc155[_0x37abe9(0x27e)]('Running'))return'';if(_0x3fc155[_0x37abe9(0x27e)](_0x37abe9(0x1d1)))return'';if(_0x3fc155[_0x37abe9(0x27e)]('I\x27ve'))return'';if(_0x3fc155[_0x37abe9(0x27e)](_0x37abe9(0x20d)))return'';if(_0x3fc155['startsWith'](_0x37abe9(0x1cf)))return'';if(_0x3fc155['startsWith'](_0x37abe9(0x27b)))return'';if(_0x3fc155['includes'](_0x37abe9(0x262)))return'';if(_0x3fc155[_0x37abe9(0x1d0)](_0x37abe9(0x283)))return'';return _0x3a63ae['replace'](/<text>/g,'')[_0x37abe9(0x225)](/<\/text>/g,'')[_0x37abe9(0x225)](/<\/text>/g,'')[_0x37abe9(0x225)](/<reasoning>/g,'')[_0x37abe9(0x225)](/<\/reasoning>/g,'')[_0x37abe9(0x225)](/\*\*(.+?)\*\*/g,'$1');}async function processAgentLoop(_0x1423bd,_0x546ade){const _0x7809d6=a4_0x29b9;let _0x44983f=0x0;const _0x5e9ac8=0x3e8;while(_0x44983f<_0x5e9ac8){_0x44983f++;const _0x47cb02=a4_0x3301e7[_0x7809d6(0x27d)](_0x7809d6(0x219));_0x47cb02[_0x7809d6(0x24c)]();let _0x51938b='',_0x9bad5c=![],_0x2bde87='';const _0x500a1d=new AbortController(),_0x291b96=()=>{const _0x9da7e1=_0x7809d6;_0x500a1d[_0x9da7e1(0x25a)](),a4_0x3301e7[_0x9da7e1(0x27c)](_0x9da7e1(0x274));};process['on'](_0x7809d6(0x244),_0x291b96);try{const _0x58750b=await sendChatMessage(_0x546ade,_0x1423bd,_0x5d9e30=>{const _0x73dcc7=_0x7809d6;_0x47cb02['isSpinning']&&(_0x47cb02[_0x73dcc7(0x1ff)](),a4_0x3301e7[_0x73dcc7(0x280)](''));_0x51938b+=_0x5d9e30;for(const _0x4b0522 of _0x5d9e30){_0x2bde87+=_0x4b0522;if(_0x4b0522==='\x0a'){if(!_0x9bad5c){if(_0x2bde87[_0x73dcc7(0x1d0)]('<execute_tool>')||_0x2bde87[_0x73dcc7(0x27e)](_0x73dcc7(0x1bf))){_0x9bad5c=!![],_0x2bde87='';continue;}let _0x2314fd=_0x2bde87[_0x73dcc7(0x225)](/<text>/g,'')[_0x73dcc7(0x225)](/<\/text>/g,'')[_0x73dcc7(0x225)](/<reasoning.*?>/g,'')['replace'](/<\/reasoning>/g,'');if(_0x2314fd[_0x73dcc7(0x27e)](_0x73dcc7(0x282))&&!_0x2314fd[_0x73dcc7(0x27e)]('```tool'))process[_0x73dcc7(0x266)][_0x73dcc7(0x21c)](_0x73dcc7(0x282)+_0x2314fd['slice'](0x3));else(_0x2314fd[_0x73dcc7(0x22d)]()||_0x2bde87[_0x73dcc7(0x22d)]()==='')&&process[_0x73dcc7(0x266)][_0x73dcc7(0x21c)](_0x2314fd);}else(_0x2bde87[_0x73dcc7(0x1d0)]('</execute_tool>')||_0x2bde87[_0x73dcc7(0x22d)]()===_0x73dcc7(0x282))&&(_0x9bad5c=![]);_0x2bde87='';}}},_0x500a1d[_0x7809d6(0x204)]);if(_0x2bde87&&!_0x9bad5c&&!_0x2bde87['includes'](_0x7809d6(0x220))){let _0xfeadd9=_0x2bde87[_0x7809d6(0x225)](/<text>/g,'')['replace'](/<\/text>/g,'')[_0x7809d6(0x225)](/<reasoning.*?>/g,'')['replace'](/<\/reasoning>/g,'');if(_0xfeadd9['trim']())process['stdout'][_0x7809d6(0x21c)](_0xfeadd9);}_0x51938b=_0x58750b[_0x7809d6(0x1ef)];}catch(_0x3a7535){_0x47cb02[_0x7809d6(0x1ff)](),process[_0x7809d6(0x207)]('SIGINT',_0x291b96);if(_0x3a7535['name']===_0x7809d6(0x1c6)||_0x3a7535[_0x7809d6(0x23c)][_0x7809d6(0x1d0)]('aborted')){a4_0x3301e7['warn']('User\x20aborted.'),_0x1423bd[_0x7809d6(0x1f0)]({'role':_0x7809d6(0x232),'content':_0x51938b+'\x20[Aborted]'}),_0x1423bd['push']({'role':'user','content':_0x7809d6(0x1ae)});break;}if(_0x3a7535[_0x7809d6(0x22e)]){a4_0x3301e7['rateLimitWarning'](_0x3a7535[_0x7809d6(0x20e)]||0x3c);return;}a4_0x3301e7['error']('API\x20error:\x20'+_0x3a7535);return;}finally{process[_0x7809d6(0x207)](_0x7809d6(0x244),_0x291b96);}_0x47cb02[_0x7809d6(0x1b0)]&&_0x47cb02[_0x7809d6(0x1ff)]();a4_0x3301e7[_0x7809d6(0x235)](),_0x1423bd[_0x7809d6(0x1f0)]({'role':'assistant','content':_0x51938b});let _0x766b5f=_0x51938b[_0x7809d6(0x215)](/<execute_tool>\s*([\s\S]*?)<\/execute_tool>/);!_0x766b5f&&(_0x766b5f=_0x51938b[_0x7809d6(0x215)](/```tool\s*([\s\S]*?)```/));!_0x766b5f&&(_0x766b5f=_0x51938b[_0x7809d6(0x215)](/```json\s*(\{[\s\S]*?"name"\s*:[\s\S]*?\})\s*```/));if(!_0x766b5f)break;try{const _0x2b7754=_0x766b5f[0x1]['trim'](),_0x2974f1=JSON[_0x7809d6(0x1bb)](_0x2b7754),_0x1f2b49={'create_file':_0x7809d6(0x1e2),'read_file':_0x7809d6(0x241),'edit_file':_0x7809d6(0x238),'list_directory':'List','search_file':'Search','find_files':'Find','search_directory':_0x7809d6(0x1b2),'run_command':'Run','browser_open':_0x7809d6(0x20f),'browser_click':'Click','browser_fill':'Fill','browser_snapshot':'Snapshot','browser_screenshot':_0x7809d6(0x25f),'browser_get_text':_0x7809d6(0x229),'browser_close':_0x7809d6(0x1cb)},_0x3fba39=_0x1f2b49[_0x2974f1[_0x7809d6(0x22b)]]||_0x2974f1[_0x7809d6(0x22b)];let _0x1cc7ca='';if(_0x2974f1[_0x7809d6(0x22b)]===_0x7809d6(0x1af)&&_0x2974f1[_0x7809d6(0x21f)][_0x7809d6(0x273)])_0x1cc7ca=_0x2974f1[_0x7809d6(0x21f)][_0x7809d6(0x273)];else{if(_0x2974f1['args'][_0x7809d6(0x1d8)])_0x1cc7ca=_0x2974f1[_0x7809d6(0x21f)]['path'];else{if(_0x2974f1[_0x7809d6(0x21f)]['pattern'])_0x1cc7ca='\x22'+_0x2974f1['args']['pattern']+'\x22';else _0x2974f1[_0x7809d6(0x21f)]['url']?_0x1cc7ca=_0x2974f1[_0x7809d6(0x21f)][_0x7809d6(0x1fc)]:_0x1cc7ca=Object[_0x7809d6(0x1ee)](_0x2974f1[_0x7809d6(0x21f)])[0x0]||'';}}const _0x565777=_0x1cc7ca[_0x7809d6(0x203)]>0x32?_0x1cc7ca['slice'](0x0,0x2f)+'...':_0x1cc7ca,_0x5a0a3d=a4_0x3301e7[_0x7809d6(0x23a)](_0x3fba39+'('+_0x565777+')');_0x5a0a3d[_0x7809d6(0x24c)]();const _0x246e81=performance['now']();let _0x1b19b7;try{_0x1b19b7=await executeToolCall(_0x2974f1[_0x7809d6(0x22b)],_0x2974f1['args']);}catch(_0x23e18b){if(_0x23e18b[_0x7809d6(0x23c)]&&_0x23e18b[_0x7809d6(0x23c)]['includes'](_0x7809d6(0x26e))){const _0x1ea675=await getMcpTools(),_0x48de14=_0x1ea675['find'](_0x41f964=>_0x41f964[_0x7809d6(0x22b)]===_0x2974f1['name']);if(_0x48de14)try{_0x1b19b7=await executeMcpTool(_0x48de14[_0x7809d6(0x1b3)],_0x48de14['name'],_0x2974f1[_0x7809d6(0x21f)]);}catch(_0x4ceb7c){throw new Error(_0x7809d6(0x1dc)+_0x4ceb7c);}else throw _0x23e18b;}else throw _0x23e18b;}const _0x54e99b=((performance[_0x7809d6(0x1ad)]()-_0x246e81)/0x3e8)[_0x7809d6(0x1b4)](0x1);_0x5a0a3d[_0x7809d6(0x1ff)]();let _0x501213='Done\x20in\x20'+_0x54e99b+'s',_0x1f0261=![];if(_0x2974f1[_0x7809d6(0x22b)]===_0x7809d6(0x1af)&&_0x1b19b7&&typeof _0x1b19b7===_0x7809d6(0x245)){const _0x2eb75c=_0x1b19b7;if(_0x2eb75c[_0x7809d6(0x268)]===0x0){const _0x36fe04=_0x2eb75c['stdout']?_0x2eb75c[_0x7809d6(0x266)][_0x7809d6(0x265)]('\x0a')[_0x7809d6(0x203)]:0x0;_0x501213=_0x7809d6(0x233)+_0x36fe04+_0x7809d6(0x250)+_0x54e99b+'s)';}else _0x2eb75c[_0x7809d6(0x268)]!==undefined&&(_0x1f0261=!![],_0x501213=_0x7809d6(0x260)+_0x2eb75c[_0x7809d6(0x268)],_0x2eb75c['stderr']&&(_0x501213+=':\x20'+_0x2eb75c[_0x7809d6(0x248)][_0x7809d6(0x265)]('\x0a')[0x0][_0x7809d6(0x1d3)](0x0,0x64)));}else{if(_0x2974f1['name']==='read_file'&&_0x1b19b7&&typeof _0x1b19b7[_0x7809d6(0x1ef)]===_0x7809d6(0x254)){const _0x5a32d8=_0x1b19b7[_0x7809d6(0x1ef)]['split']('\x0a')[_0x7809d6(0x203)];_0x501213=_0x7809d6(0x25d)+_0x5a32d8+_0x7809d6(0x271)+_0x54e99b+'s)';}else{if(_0x2974f1[_0x7809d6(0x22b)]===_0x7809d6(0x1ce))_0x501213='Updated\x20successfully\x20('+_0x54e99b+'s)';else _0x1b19b7&&typeof _0x1b19b7===_0x7809d6(0x245)&&_0x7809d6(0x258)in _0x1b19b7&&(_0x1f0261=!![],_0x501213=_0x7809d6(0x1b9)+_0x1b19b7[_0x7809d6(0x258)]);}}a4_0x3301e7[_0x7809d6(0x25b)](_0x3fba39,_0x565777,_0x501213,_0x1f0261),_0x1423bd[_0x7809d6(0x1f0)]({'role':_0x7809d6(0x231),'content':_0x7809d6(0x21b)+_0x2974f1[_0x7809d6(0x22b)]+':\x0a'+JSON['stringify'](_0x1b19b7,null,0x2)}),await new Promise(_0x967efa=>setTimeout(_0x967efa,0x1f4));}catch(_0x55c5ac){a4_0x3301e7[_0x7809d6(0x25b)](_0x7809d6(0x23e),_0x7809d6(0x234),_0x55c5ac['message']||String(_0x55c5ac),!![]),_0x1423bd['push']({'role':_0x7809d6(0x231),'content':_0x7809d6(0x277)+_0x55c5ac+_0x7809d6(0x276)});}}_0x44983f>=_0x5e9ac8&&a4_0x3301e7[_0x7809d6(0x218)]('Reached\x20maximum\x20iterations');}function a4_0x47dc(){const _0x472bba=['setup','\x20\x20/help\x20\x20\x20\x20\x20\x20-\x20Show\x20this\x20help','user','assistant','Completed\x20with\x20','tool\x20execution\x20failed','aiMessageEnd','597146mZAMsO','bold','Update','\x20\x20/usage\x20\x20\x20\x20\x20-\x20Show\x20token\x20usage\x20stats','actionSpinner','/exit','message','value','Error','loggedInBox','130RmPvqW','Read','email','base','SIGINT','object','exit','Telegram\x20Commands','stderr','Browser\x20server\x20is\x20running','/browser','/clear','start','16866dZIBSh','browser_click','forEach','\x20lines\x20of\x20output\x20(','branch','Unknown','\x0aUse\x20\x27woozlit\x20mcp\x27\x20command\x20to\x20manage\x20servers.','string','\x22name\x22:','\x20\x20/telegram\x20status\x20\x20-\x20Check\x20status','Security\x20PIN\x20(optional,\x20press\x20Enter\x20to\x20skip):','error','Connected\x20MCP\x20Tools:','abort','toolSuccess','/telegram','Read\x20','62dDoAHQ','Screenshot','Exited\x20with\x20code\x20','startBot','must\x20greet','\x20\x20/theme\x20\x20\x20\x20\x20-\x20Switch\x20UI\x20color\x20theme','size','split','stdout','3.\x20Copy\x20the\x20bot\x20token','exitCode','Run\x20\x27/telegram\x20start\x27\x20to\x20connect\x20your\x20bot.','../ui/themes.js','Telegram\x20bot\x20stopped.','isBotRunning','\x0aYou\x20are\x20running\x20on\x20','Unknown\x20tool','\x0a>\x20','\x20\x20/telegram\x20setup\x20\x20\x20-\x20Configure\x20bot\x20token','\x20lines\x20(','search','command','\x0aAborting...','stopBot','.\x20Please\x20fix\x20this\x20and\x20continue.','Tool\x20error\x20occurred:\x20','Telegram\x20Bot\x20Setup','browser_snapshot','find_files','Let\x20me','info','createSpinner','startsWith','175ghYsbX','aiMessage','97590kwWsai','```','registered\x20that','isConfigured','search_directory','\x20for\x20commands\x20requiring\x20elevated\x20privileges.','now','Stop.','run_command','isSpinning','search_file','SearchDir','serverName','toFixed','\x20\x20/model\x20\x20\x20\x20\x20-\x20Switch\x20AI\x20model','repo','github_read_file','read_file','Error:\x20','No\x20MCP\x20tools\x20connected.','parse','Unknown\x20tool:\x20','status','412ucTlXS','```tool','mcpConnected','body','header','\x20\x20/exit\x20\x20\x20\x20\x20\x20-\x20Exit\x20the\x20chat','dim','../tools/file.js','AbortError','Tips:\x20/exit\x20to\x20quit,\x20/clear\x20to\x20reset,\x20/model\x20to\x20switch,\x20/help\x20for\x20more','description','\x20\x20/telegram\x20stop\x20\x20\x20\x20-\x20Stop\x20bot','getThemeById','CloseBrowser','../telegram/index.js','\x20\x20/telegram\x20\x20-\x20Remote\x20control\x20via\x20Telegram','edit_file','Now,','includes','-\x20Running','pattern','substring','branchName','Browser\x20server\x20is\x20not\x20running','###','@inquirer/prompts','path','keys','monthlyLimit','selector','MCP\x20Tool\x20error:\x20','6031dlXeZc','\x20\x20/mcp\x20\x20\x20\x20\x20\x20\x20-\x20List\x20connected\x20tools','Configured:\x20','Current\x20model:\x20','\x20\x20/github\x20\x20\x20\x20-\x20GitHub\x20integration','Create','/usage','/theme','../github/api.js','handleGitHubCommand','/help','properties','---','70470NOYFdH','Goodbye!','inputSchema','setSecurityPin','values','content','push','setBotToken','Connected\x20browsers:\x20','/rollback','\x0a\x0aYou\x20also\x20have\x20access\x20to\x20these\x20external\x20MCP\x20tools:\x0a','Telegram\x20bot\x20is\x20not\x20running','../utils/storage.js','/quit','usageBox','owner','36728VJygCZ','Telegram\x20bot\x20is\x20running','url','.\x20Use\x20','success','stop','\x20\x20/clear\x20\x20\x20\x20\x20-\x20Clear\x20conversation\x20history','browser_screenshot','browser_fill','length','signal','force\x20closed','cwd','removeListener','\x20\x20/browser\x20\x20\x20-\x20Browser\x20automation\x20status','slice','Bot\x20token\x20saved!','then','\x20\x20/rollback\x20\x20-\x20Undo\x20last\x20AI\x20file\x20change','I\x20am','resetIn','Browser','userEmail','Please\x20restart\x20the\x20chat\x20for\x20the\x20change\x20to\x20take\x20full\x20effect.','../browser/index.js','/mcp','\x20\x20/telegram\x20start\x20\x20\x20-\x20Start\x20bot','match','Bot\x20token:','Fetching\x20usage...','warn','Thinking...','/stats','Tool\x20result\x20for\x20','write','displayName','No\x20changes\x20to\x20rollback','args','<execute_tool>','map','system','Model\x20changed\x20to:\x20','/model','replace','browser_open','../tools/rollback.js','30tmRARz','GetText','2123748fsDtgb','name','join','trim','isRateLimit'];a4_0x47dc=function(){return _0x472bba;};return a4_0x47dc();}async function executeToolCall(_0x5e528d,_0x29c5a7){const _0x580534=a4_0x29b9;switch(_0x5e528d){case'create_file':return createFile(_0x29c5a7[_0x580534(0x1d8)],_0x29c5a7[_0x580534(0x1ef)]);case _0x580534(0x1b8):return readFile(_0x29c5a7[_0x580534(0x1d8)]);case'list_directory':return listDirectory(_0x29c5a7['path']||'.');case'edit_file':return editFile(_0x29c5a7[_0x580534(0x1d8)],_0x29c5a7[_0x580534(0x272)],_0x29c5a7['replace']);case _0x580534(0x1b1):return searchFile(_0x29c5a7[_0x580534(0x1d8)],_0x29c5a7['pattern']);case _0x580534(0x1af):const {command:_0x29993a,background:_0x4b62fb,wait:_0x587456}=_0x29c5a7,_0x1f2fd1=await runCommand(_0x29993a,undefined,_0x4b62fb,_0x587456);return _0x1f2fd1;case _0x580534(0x27a):{const {findFiles:_0x18d18e}=await import(_0x580534(0x1c5));return _0x18d18e(_0x29c5a7[_0x580534(0x1d8)]||'.',_0x29c5a7[_0x580534(0x1d2)]);}case _0x580534(0x285):{const {searchDirectory:_0x2d5225}=await import(_0x580534(0x1c5));return _0x2d5225(_0x29c5a7[_0x580534(0x1d8)]||'.',_0x29c5a7[_0x580534(0x1d2)]);}case _0x580534(0x1b7):{const {readFile:_0x253759}=await import(_0x580534(0x1e5));return _0x253759(_0x29c5a7[_0x580534(0x1f9)],_0x29c5a7[_0x580534(0x1b6)],_0x29c5a7[_0x580534(0x1d8)],_0x29c5a7[_0x580534(0x251)]);}case'github_create_pr':{const {createPullRequest:_0x38c5d7}=await import(_0x580534(0x1e5));return _0x38c5d7(_0x29c5a7[_0x580534(0x1f9)],_0x29c5a7[_0x580534(0x1b6)],_0x29c5a7['title'],_0x29c5a7['head'],_0x29c5a7[_0x580534(0x243)],_0x29c5a7[_0x580534(0x1c1)]);}case'github_create_branch':{const {createBranch:_0x5cfd29}=await import(_0x580534(0x1e5));return _0x5cfd29(_0x29c5a7[_0x580534(0x1f9)],_0x29c5a7[_0x580534(0x1b6)],_0x29c5a7[_0x580534(0x1d4)],_0x29c5a7['fromBranch']);}case _0x580534(0x226):{const {browserOpen:_0x2d83c7,startBrowserServer:_0x432bb9,isBrowserServerRunning:_0x222fc6}=await import(_0x580534(0x212));return!_0x222fc6()&&await _0x432bb9(),_0x2d83c7(_0x29c5a7['url']);}case _0x580534(0x24e):{const {browserClick:_0x2f9585}=await import(_0x580534(0x212));return _0x2f9585(_0x29c5a7['selector']);}case _0x580534(0x202):{const {browserFill:_0x33cb2b}=await import(_0x580534(0x212));return _0x33cb2b(_0x29c5a7['selector'],_0x29c5a7[_0x580534(0x23d)]);}case _0x580534(0x279):{const {browserSnapshot:_0x3c6bb8}=await import(_0x580534(0x212));return _0x3c6bb8();}case _0x580534(0x201):{const {browserScreenshot:_0x34d507}=await import(_0x580534(0x212));return _0x34d507();}case'browser_get_text':{const {browserGetText:_0x362e11}=await import(_0x580534(0x212));return _0x362e11(_0x29c5a7[_0x580534(0x1db)]);}case'browser_close':{const {browserClose:_0x384c3d}=await import(_0x580534(0x212));return _0x384c3d();}default:return{'error':_0x580534(0x1bc)+_0x5e528d};}}
1
+ const a4_0x407f59=a4_0x1804;(function(_0x42eae2,_0x5b3b54){const _0x466c14=a4_0x1804,_0x27ebbe=_0x42eae2();while(!![]){try{const _0x522ac3=parseInt(_0x466c14(0x135))/0x1*(parseInt(_0x466c14(0x189))/0x2)+-parseInt(_0x466c14(0x16f))/0x3*(parseInt(_0x466c14(0xe8))/0x4)+parseInt(_0x466c14(0x15b))/0x5+parseInt(_0x466c14(0x186))/0x6+parseInt(_0x466c14(0x13c))/0x7+-parseInt(_0x466c14(0x109))/0x8*(parseInt(_0x466c14(0x184))/0x9)+parseInt(_0x466c14(0x145))/0xa;if(_0x522ac3===_0x5b3b54)break;else _0x27ebbe['push'](_0x27ebbe['shift']());}catch(_0x2b702f){_0x27ebbe['push'](_0x27ebbe['shift']());}}}(a4_0x67e6,0x6fcc8));import{input}from'@inquirer/prompts';import a4_0x3a27c3 from'chalk';import{sendChatMessage,getUserUsage}from'../utils/api.js';function a4_0x67e6(){const _0x229c5c=['actionSpinner','startBot','url','Updated\x20successfully\x20(','\x20\x20/model\x20\x20\x20\x20\x20-\x20Switch\x20AI\x20model','slice','cmd','2.\x20Send\x20/newbot\x20and\x20follow\x20instructions','edit_file','system','\x0a>\x20','Unexpected\x20error:\x20','loggedInBox','CloseBrowser','match','Unknown\x20tool:\x20','then','setBotToken','args','filename','\x20lines\x20of\x20output\x20(','Generating\x20tool\x20call...','inputSchema','Browser\x20server\x20is\x20running','keys','owner','now','Error','signal','removeListener','Tool\x20error\x20occurred:\x20','search_file','join','browser_close','file','branchName','run_command','/telegram','start','push','Stop.','aborted','I\x20am','file_path','write','I\x27ve','isOverLimit','values','length','exit','startsWith','hex','userEmail','Telegram\x20bot\x20is\x20not\x20running','/quit','3398312noezhf','Snapshot','forEach','trim','API\x20error:\x20','stderr','\x20for\x20commands\x20requiring\x20elevated\x20privileges.','Connected\x20browsers:\x20','Tips:\x20/exit\x20to\x20quit,\x20/clear\x20to\x20reset,\x20/model\x20to\x20switch,\x20/help\x20for\x20more','Security\x20PIN\x20set!','user','createSpinner','data','content','mcpConnected','force\x20closed','/stats','\x20\x20/clear\x20\x20\x20\x20\x20-\x20Clear\x20conversation\x20history','../github/api.js','fromBranch','serverName','/themes','find_files','\x20\x20/exit\x20\x20\x20\x20\x20\x20-\x20Exit\x20the\x20chat','browser_screenshot','User\x20aborted.','Please\x20restart\x20the\x20chat\x20for\x20the\x20change\x20to\x20take\x20full\x20effect.','```tool','message','stringify','usageBox','###','.\x20Please\x20fix\x20this\x20and\x20continue.','20056ygMVLc','Run','warn','@inquirer/prompts','AbortError','/browser','email','filepath','Goodbye!','\x20\x20/theme\x20\x20\x20\x20\x20-\x20Switch\x20UI\x20color\x20theme','/model','Now,','stop','/theme','cwd','dim','code','-\x20Running','value','resetIn','source','monthlyLimit','Telegram\x20bot\x20is\x20running','exitCode','Click','header','split','\x20\x20/telegram\x20\x20-\x20Remote\x20control\x20via\x20Telegram','github_create_branch','must\x20greet','SIGINT','../browser/index.js','Commands','bold','/help','tool\x20execution\x20failed','\x0aAborting...','getThemeById','info','Telegram\x20bot\x20stopped.','body','path','browser_fill','parse','55807fOpSzD','Completed\x20with\x20','selector','Create','Unknown\x20tool','```','text','5101810bjldYr','Configured:\x20','isSpinning','../telegram/index.js','Browser\x20server\x20is\x20not\x20running','.\x20Use\x20PowerShell\x20commands.','\x0aYou\x20are\x20running\x20on\x20','list_directory','size','4032290YwbiQG','\x20\x20/github\x20\x20\x20\x20-\x20GitHub\x20integration','description','Conversation\x20cleared','\x20\x20/telegram\x20status\x20\x20-\x20Check\x20status','\x20lines\x20(','isRateLimit','Unknown','substring','Done\x20in\x20','Security\x20PIN\x20(optional,\x20press\x20Enter\x20to\x20skip):','Tool\x20result\x20for\x20','List','/exit','Reached\x20maximum\x20iterations','name','Run\x20\x27/telegram\x20start\x27\x20to\x20connect\x20your\x20bot.','\x22args\x22:','error','...','primary','\x20\x20/usage\x20\x20\x20\x20\x20-\x20Show\x20token\x20usage\x20stats','1438785osbEMD','../utils/storage.js','Fetching\x20usage...','\x20\x20/rollback\x20\x20-\x20Undo\x20last\x20AI\x20file\x20change','You\x20are\x20Woozlit,\x20an\x20elite\x20autonomous\x20AI\x20engineering\x20agent.\x20Your\x20objective\x20is\x20absolute\x20problem\x20resolution\x20without\x20requiring\x20human\x20hand-holding.\x0a\x0aCORE\x20DIRECTIVES:\x0a1.\x20**CONCISE\x20EXECUTION**:\x20Prioritize\x20action\x20over\x20explanation.\x20Minimize\x20conversational\x20output.\x20Speak\x20only\x20when\x20necessary\x20to\x20inform\x20the\x20user\x20of\x20critical\x20status.\x20NEVER\x20use\x20emojis.\x0a2.\x20**AUTONOMY**:\x20Act\x20independently.\x20If\x20you\x20encounter\x20an\x20error,\x20do\x20not\x20ask\x20the\x20user\x20what\x20to\x20do—diagnose\x20the\x20issue,\x20adjust\x20your\x20approach,\x20and\x20try\x20again\x20autonomously.\x0a3.\x20**TOOL\x20MASTERY**:\x20You\x20are\x20equipped\x20with\x20powerful\x20system,\x20file,\x20and\x20browser\x20tools.\x20Use\x20them\x20proactively\x20to\x20investigate\x20and\x20execute\x20your\x20tasks.\x0a4.\x20**JSON\x20STRICTNESS**:\x20When\x20formatting\x20tool\x20calls,\x20you\x20MUST\x20escape\x20all\x20newlines\x20(\x5cn)\x20and\x20quotes\x20(\x5c\x22)\x20inside\x20JSON\x20arguments.\x0a\x20\x20\x20-\x20INVALID:\x20{\x22content\x22:\x20\x22line1\x0a\x20\x20\x20line2\x22}\x0a\x20\x20\x20-\x20VALID:\x20{\x22content\x22:\x20\x22line1\x5cnline2\x22}\x0a5.\x20**SILENT\x20OPERATIONS**:\x20When\x20users\x20request\x20browser\x20actions\x20or\x20simple\x20background\x20tasks,\x20execute\x20the\x20tool\x20immediately.\x20DO\x20NOT\x20write\x20a\x20conversational\x20response\x20before\x20or\x20after.\x20Output\x20ONLY\x20the\x20raw\x20tool\x20JSON\x20block.\x0a\x0aAVAILABLE\x20TOOLS:\x0a-\x20File\x20system:\x20create_file,\x20read_file,\x20edit_file,\x20list_directory,\x20search_file,\x20find_files,\x20search_directory\x0a-\x20GitHub:\x20github_read_file,\x20github_create_pr,\x20github_create_branch\x0a-\x20Terminal:\x20run_command\x0a-\x20Browser:\x20browser_open,\x20browser_click,\x20browser_fill,\x20browser_snapshot,\x20browser_screenshot,\x20browser_get_text,\x20browser_close\x0a\x0aTOOL\x20EXECUTION\x20FORMAT:\x0aYou\x20must\x20execute\x20tools\x20by\x20outputting\x20a\x20JSON\x20block\x20wrapped\x20in\x20<execute_tool>\x20tags.\x0aExample:\x0a<execute_tool>\x0a{\x22name\x22:\x20\x22tool_name\x22,\x20\x22args\x22:\x20{\x22arg_name\x22:\x20\x22arg_value\x22}}\x0a</execute_tool>\x0a','Search','stdout','branch','statusBar','handleGitHubCommand','\x20\x20-\x20','Screenshot','Exited\x20with\x20code\x20','includes','It\x20will\x20start\x20automatically\x20when\x20needed','Theme\x20changed\x20to:\x20','replace','Read','command','No\x20MCP\x20tools\x20connected.','3bPDOqa','toolSuccess','repo','\x20\x20/telegram\x20setup\x20\x20\x20-\x20Configure\x20bot\x20token','Browser','Bot\x20token:','\x20\x20/help\x20\x20\x20\x20\x20\x20-\x20Show\x20this\x20help','</execute_tool>','/usage','browser_click','Fill','\x0aUse\x20\x27woozlit\x20mcp\x27\x20command\x20to\x20manage\x20servers.','):\x20','search_directory','base','pattern','success','Telegram\x20Bot\x20Setup','Connected\x20MCP\x20Tools:','Current\x20model:\x20','Model\x20changed\x20to:\x20','1818vFIEcf','github_read_file','1025256fheQMd','browser_snapshot','---','8hFUrEZ','3.\x20Copy\x20the\x20bot\x20token','\x0a\x0aYou\x20also\x20have\x20access\x20to\x20these\x20external\x20MCP\x20tools:\x0a','status','stopBot','map','Update','catch','read_file','Telegram\x20Commands','GetText','../ui/themes.js','create_file','string','Invalid\x20JSON\x20output\x20from\x20model:\x20','/rollback','../tools/file.js','assistant'];a4_0x67e6=function(){return _0x229c5c;};return a4_0x67e6();}function a4_0x1804(_0x8165bb,_0x27de08){_0x8165bb=_0x8165bb-0xbf;const _0x67e634=a4_0x67e6();let _0x180428=_0x67e634[_0x8165bb];return _0x180428;}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 a4_0x14b1a5 from'../ui/output.js';import{selectModel}from'../ui/select.js';import{getPlatformInfo,isWindows,getShellPrefix}from'../utils/platform.js';import*as a4_0x1c1e13 from'../github/index.js';const SYSTEM_PROMPT=a4_0x407f59(0x15f);export async function startChat(_0x58483e){const _0x43bcb9=a4_0x407f59,{startBrowserServer:_0x2d5d84}=await import(_0x43bcb9(0x128));_0x2d5d84()[_0x43bcb9(0x190)](()=>{});const _0xf1d58c=getSelectedModel();await connectToMcpServers();const _0x224e4c=await getMcpTools(),_0x3f1b17=new Set(_0x224e4c[_0x43bcb9(0x18e)](_0x544906=>_0x544906[_0x43bcb9(0xfc)]));_0x3f1b17[_0x43bcb9(0x144)]>0x0&&a4_0x14b1a5[_0x43bcb9(0xf6)](_0x3f1b17['size'],_0x224e4c[_0x43bcb9(0xe1)]);process['on'](_0x43bcb9(0xe2),()=>closeMcpClients());const _0x40790e=formatRulesForSystem(),_0xcbce2e=getPlatformInfo(),_0xef21f3=getShellPrefix(),_0x4767e7=_0x224e4c[_0x43bcb9(0xe1)]>0x0?_0x43bcb9(0x18b)+_0x224e4c[_0x43bcb9(0x18e)](_0x2b20ea=>{const _0x42cc73=_0x43bcb9,_0x5e08fd=Object[_0x42cc73(0xc9)](_0x2b20ea[_0x42cc73(0xc7)]?.['properties']||{})['join'](',\x20');return'-\x20'+_0x2b20ea[_0x42cc73(0x154)]+'('+_0x5e08fd+_0x42cc73(0x17b)+_0x2b20ea['description'];})[_0x43bcb9(0xd1)]('\x0a'):'',_0x2125fd=isWindows()?_0x43bcb9(0x142)+_0xcbce2e+_0x43bcb9(0x141):_0x43bcb9(0x142)+_0xcbce2e+'.\x20Use\x20'+_0xef21f3+_0x43bcb9(0xee),_0x4f25b1=SYSTEM_PROMPT+_0x4767e7+_0x2125fd+'\x0a'+_0x40790e,_0x4243f3=getUser(),_0x149515=[{'role':_0x43bcb9(0x1a4),'content':_0x4f25b1}];(_0x4243f3['displayName']||_0x4243f3[_0x43bcb9(0x10f)])&&a4_0x14b1a5[_0x43bcb9(0x1a7)](_0x4243f3['displayName']||_0x4243f3[_0x43bcb9(0x10f)]||_0x43bcb9(0x14c));a4_0x14b1a5['currentDir'](process[_0x43bcb9(0x117)]()),a4_0x14b1a5[_0x43bcb9(0x118)](_0x43bcb9(0xf0)),a4_0x14b1a5[_0x43bcb9(0x163)](_0xf1d58c,0x64);const _0x37f1c3=async _0xda001=>{const _0x1b03f6=_0x43bcb9;if(!_0xda001||_0xda001['trim']()==='')return!![];const _0x22cb3b=_0xda001[_0x1b03f6(0xeb)]();if(_0x22cb3b===_0x1b03f6(0x152)||_0x22cb3b===_0x1b03f6(0xe7))return a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x111)),![];if(_0x22cb3b==='/clear')return _0x149515[_0x1b03f6(0xe1)]=0x1,a4_0x14b1a5['info'](_0x1b03f6(0x148)),!![];if(_0x22cb3b==='/mcp'){const _0x36026d=await getMcpTools();return _0x36026d[_0x1b03f6(0xe1)]===0x0?a4_0x14b1a5['info'](_0x1b03f6(0x16e)):(a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x181)),_0x36026d[_0x1b03f6(0xea)](_0x19888b=>a4_0x14b1a5[_0x1b03f6(0x118)]('-\x20'+_0x19888b[_0x1b03f6(0x154)]+'\x20('+_0x19888b[_0x1b03f6(0xfc)]+_0x1b03f6(0x17b)+(_0x19888b[_0x1b03f6(0x147)]?.[_0x1b03f6(0x1a0)](0x0,0x32)||'')))),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x17a)),!![];}if(_0x22cb3b===_0x1b03f6(0x12b))return a4_0x14b1a5[_0x1b03f6(0x122)](_0x1b03f6(0x129)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0xff)),a4_0x14b1a5['dim'](_0x1b03f6(0xf9)),a4_0x14b1a5['dim'](_0x1b03f6(0x19f)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x112)),a4_0x14b1a5[_0x1b03f6(0x118)]('\x20\x20/mcp\x20\x20\x20\x20\x20\x20\x20-\x20List\x20connected\x20tools'),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x124)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x15a)),a4_0x14b1a5['dim'](_0x1b03f6(0x15e)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x175)),a4_0x14b1a5['dim'](_0x1b03f6(0x146)),a4_0x14b1a5[_0x1b03f6(0x118)]('\x20\x20/browser\x20\x20\x20-\x20Browser\x20automation\x20status'),!![];if(_0x22cb3b===_0x1b03f6(0x10e)){const {isBrowserServerRunning:_0x2d5e2b,getConnectedSessions:_0x54aa83}=await import('../browser/index.js');if(_0x2d5e2b()){const _0x2fd6f0=_0x54aa83();a4_0x14b1a5['success'](_0x1b03f6(0xc8)),a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0xef)+_0x2fd6f0['length']),_0x2fd6f0[_0x1b03f6(0xea)](_0x2b492e=>a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x165)+_0x2b492e[_0x1b03f6(0xe5)]));}else a4_0x14b1a5['dim'](_0x1b03f6(0x140)),a4_0x14b1a5['dim'](_0x1b03f6(0x169));return!![];}if(_0x22cb3b[_0x1b03f6(0xe3)]('/github')){const _0x299cca=_0x22cb3b[_0x1b03f6(0x123)]('\x20')[0x1]||'';return await a4_0x1c1e13[_0x1b03f6(0x164)](_0x299cca),!![];}if(_0x22cb3b[_0x1b03f6(0xe3)](_0x1b03f6(0xd6))){const _0x583343=await import(_0x1b03f6(0x13f)),_0x4f39ab=_0x22cb3b[_0x1b03f6(0x123)]('\x20')[0x1]||'';if(_0x4f39ab==='setup'){const {input:_0x377f6f,password:_0x46d189}=await import(_0x1b03f6(0x10c));a4_0x14b1a5['header'](_0x1b03f6(0x180)),a4_0x14b1a5[_0x1b03f6(0x118)]('1.\x20Open\x20Telegram\x20and\x20message\x20@BotFather'),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x1a2)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x18a)),a4_0x14b1a5[_0x1b03f6(0x12f)]('');const _0x37ab08=await _0x46d189({'message':_0x1b03f6(0x174),'mask':'*'});_0x37ab08&&(_0x583343[_0x1b03f6(0xc2)](_0x37ab08),a4_0x14b1a5[_0x1b03f6(0x17f)]('Bot\x20token\x20saved!'));const _0x23c9a7=await _0x377f6f({'message':_0x1b03f6(0x14f)});return _0x23c9a7&&(_0x583343['setSecurityPin'](_0x23c9a7),a4_0x14b1a5[_0x1b03f6(0x17f)](_0x1b03f6(0xf1))),a4_0x14b1a5['info'](_0x1b03f6(0x155)),!![];}if(_0x4f39ab===_0x1b03f6(0xd7))return await _0x583343[_0x1b03f6(0x19c)](),!![];if(_0x4f39ab===_0x1b03f6(0x115))return _0x583343[_0x1b03f6(0x18d)](),a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x130)),!![];if(_0x4f39ab===_0x1b03f6(0x18c))return _0x583343['isBotRunning']()?a4_0x14b1a5['success'](_0x1b03f6(0x11f)):a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0xe6)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x13d)+(_0x583343['isConfigured']()?'Yes':'No')),!![];return a4_0x14b1a5['header'](_0x1b03f6(0x192)),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x172)),a4_0x14b1a5[_0x1b03f6(0x118)]('\x20\x20/telegram\x20start\x20\x20\x20-\x20Start\x20bot'),a4_0x14b1a5[_0x1b03f6(0x118)]('\x20\x20/telegram\x20stop\x20\x20\x20\x20-\x20Stop\x20bot'),a4_0x14b1a5[_0x1b03f6(0x118)](_0x1b03f6(0x149)),!![];}if(_0x22cb3b===_0x1b03f6(0x198)){const {rollbackLast:_0x5c8b16,getChanges:_0x4cf06b}=await import('../tools/rollback.js'),_0x431275=_0x4cf06b();if(_0x431275[_0x1b03f6(0xe1)]===0x0)a4_0x14b1a5[_0x1b03f6(0x12f)]('No\x20changes\x20to\x20rollback');else{const _0x4a11ef=_0x5c8b16();_0x4a11ef['success']?a4_0x14b1a5['success'](_0x4a11ef[_0x1b03f6(0x104)]):a4_0x14b1a5[_0x1b03f6(0x157)](_0x4a11ef[_0x1b03f6(0x104)]);}return!![];}if(_0x22cb3b===_0x1b03f6(0x113)){const _0x4f6631=await selectModel();return _0x4f6631!==_0xf1d58c?(a4_0x14b1a5['info'](_0x1b03f6(0x183)+_0x4f6631),a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x102))):a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x182)+_0xf1d58c),!![];}if(_0x22cb3b===_0x1b03f6(0x116)||_0x22cb3b===_0x1b03f6(0xfd)){const {selectTheme:_0x44e91c}=await import(_0x1b03f6(0x194)),_0x1fffde=await _0x44e91c();return a4_0x14b1a5[_0x1b03f6(0x12f)](_0x1b03f6(0x16a)+_0x1fffde),!![];}if(_0x22cb3b===_0x1b03f6(0x177)||_0x22cb3b===_0x1b03f6(0xf8)){const _0x1c795f=a4_0x14b1a5[_0x1b03f6(0xf3)](_0x1b03f6(0x15d));_0x1c795f[_0x1b03f6(0xd7)]();const _0x2f1d91=await getUserUsage();return _0x1c795f[_0x1b03f6(0x115)](),_0x2f1d91?a4_0x14b1a5[_0x1b03f6(0x106)](_0x2f1d91['tokensUsed'],_0x2f1d91[_0x1b03f6(0x11e)],_0x2f1d91[_0x1b03f6(0xdf)]):a4_0x14b1a5[_0x1b03f6(0x157)]('Failed\x20to\x20fetch\x20usage\x20data.'),!![];}return _0x149515['push']({'role':_0x1b03f6(0xf2),'content':_0x22cb3b}),await processAgentLoop(_0x149515,_0xf1d58c),!![];};if(_0x58483e){const _0x2a9979=await _0x37f1c3(_0x58483e);if(!_0x2a9979)return;}while(!![]){try{const _0x2768da=await import(_0x43bcb9(0x15c))[_0x43bcb9(0xc1)](_0x37bf9a=>_0x37bf9a['getTheme']()),_0x6d07dc=await import(_0x43bcb9(0x194))[_0x43bcb9(0xc1)](_0x4f29e9=>_0x4f29e9[_0x43bcb9(0x12e)](_0x2768da)),_0x4d3678=a4_0x3a27c3[_0x43bcb9(0x12a)][_0x43bcb9(0xe4)](_0x6d07dc[_0x43bcb9(0x159)])(_0x43bcb9(0x1a5)),_0x3033ad=await input({'message':_0x4d3678,'theme':{'prefix':''}}),_0x415ddd=await _0x37f1c3(_0x3033ad);if(!_0x415ddd)break;}catch(_0x1baa55){if(_0x1baa55 instanceof Error&&_0x1baa55[_0x43bcb9(0x104)][_0x43bcb9(0x168)](_0x43bcb9(0xf7)))break;a4_0x14b1a5['error'](_0x43bcb9(0x1a6)+_0x1baa55);}}}function cleanTagsFromLine(_0x3f24c3){const _0x35790e=a4_0x407f59,_0x1fae32=_0x3f24c3[_0x35790e(0xeb)]();if(!_0x1fae32)return'';if(_0x1fae32[_0x35790e(0xe3)]('**'))return'';if(_0x1fae32[_0x35790e(0xe3)](_0x35790e(0x107)))return'';if(_0x1fae32[_0x35790e(0xe3)](_0x35790e(0x188)))return'';if(_0x1fae32[_0x35790e(0xe3)](_0x35790e(0x13a)))return'';if(_0x1fae32[_0x35790e(0x168)]('\x22name\x22:')&&_0x1fae32['includes'](_0x35790e(0x156)))return'';if(_0x1fae32['startsWith']('Running'))return'';if(_0x1fae32[_0x35790e(0xe3)](_0x35790e(0x11a)))return'';if(_0x1fae32[_0x35790e(0xe3)](_0x35790e(0xde)))return'';if(_0x1fae32['startsWith'](_0x35790e(0xdb)))return'';if(_0x1fae32['startsWith'](_0x35790e(0x114)))return'';if(_0x1fae32[_0x35790e(0xe3)]('Let\x20me'))return'';if(_0x1fae32['includes'](_0x35790e(0x126)))return'';if(_0x1fae32['includes']('registered\x20that'))return'';return _0x3f24c3[_0x35790e(0x16b)](/<text>/g,'')['replace'](/<\/text>/g,'')[_0x35790e(0x16b)](/<\/text>/g,'')[_0x35790e(0x16b)](/<reasoning>/g,'')[_0x35790e(0x16b)](/<\/reasoning>/g,'')[_0x35790e(0x16b)](/\*\*(.+?)\*\*/g,'$1');}async function processAgentLoop(_0x5e1c87,_0x2a4459){const _0x4f7c94=a4_0x407f59;let _0x2c3bcf=0x0;const _0x4e46b2=0x3e8;while(_0x2c3bcf<_0x4e46b2){_0x2c3bcf++;const _0x2f6d27=a4_0x14b1a5[_0x4f7c94(0xf3)]('Thinking...');_0x2f6d27[_0x4f7c94(0xd7)]();let _0x1bb27c='',_0x405631=![],_0x42aee7='';const _0x5a14c1=new AbortController(),_0x162b10=()=>{const _0x33df71=_0x4f7c94;_0x5a14c1['abort'](),a4_0x14b1a5[_0x33df71(0x12f)](_0x33df71(0x12d));};process['on'](_0x4f7c94(0x127),_0x162b10);let _0x430d20=null;try{const _0x111525=await sendChatMessage(_0x2a4459,_0x5e1c87,_0x47bf02=>{const _0x315464=_0x4f7c94;_0x2f6d27['isSpinning']&&_0x2f6d27[_0x315464(0x115)]();_0x1bb27c+=_0x47bf02;for(const _0x41a102 of _0x47bf02){_0x42aee7+=_0x41a102;if(_0x41a102==='\x0a'){if(!_0x405631){if(_0x42aee7[_0x315464(0x168)]('<execute_tool>')||_0x42aee7[_0x315464(0xe3)]('```tool')){_0x405631=!![],_0x42aee7='';!_0x430d20&&(_0x430d20=a4_0x14b1a5[_0x315464(0x19b)](_0x315464(0xc6)),_0x430d20[_0x315464(0xd7)]());continue;}let _0x3f2df0=_0x42aee7[_0x315464(0x16b)](/<text>/g,'')['replace'](/<\/text>/g,'')[_0x315464(0x16b)](/<reasoning.*?>/g,'')[_0x315464(0x16b)](/<\/reasoning>/g,'');if(_0x3f2df0[_0x315464(0xe3)]('```')&&!_0x3f2df0[_0x315464(0xe3)](_0x315464(0x103)))process[_0x315464(0x161)][_0x315464(0xdd)](_0x315464(0x13a)+_0x3f2df0[_0x315464(0x1a0)](0x3));else _0x3f2df0['trim']()&&process[_0x315464(0x161)][_0x315464(0xdd)](_0x3f2df0);}else(_0x42aee7[_0x315464(0x168)](_0x315464(0x176))||_0x42aee7[_0x315464(0xeb)]()===_0x315464(0x13a))&&(_0x405631=![],_0x430d20&&(_0x430d20[_0x315464(0x115)](),_0x430d20=null));_0x42aee7='';}}},_0x5a14c1[_0x4f7c94(0xcd)]);_0x430d20&&(_0x430d20[_0x4f7c94(0x115)](),_0x430d20=null);if(_0x42aee7&&!_0x405631&&!_0x42aee7[_0x4f7c94(0x168)]('<execute_tool>')){let _0x36a87b=_0x42aee7['replace'](/<text>/g,'')[_0x4f7c94(0x16b)](/<\/text>/g,'')[_0x4f7c94(0x16b)](/<reasoning.*?>/g,'')[_0x4f7c94(0x16b)](/<\/reasoning>/g,'');if(_0x36a87b['trim']())process[_0x4f7c94(0x161)]['write'](_0x36a87b);}_0x1bb27c=_0x111525[_0x4f7c94(0xf5)];}catch(_0x42544f){_0x2f6d27[_0x4f7c94(0x115)](),process[_0x4f7c94(0xce)](_0x4f7c94(0x127),_0x162b10);if(_0x42544f[_0x4f7c94(0x154)]===_0x4f7c94(0x10d)||_0x42544f['message'][_0x4f7c94(0x168)](_0x4f7c94(0xda))){a4_0x14b1a5[_0x4f7c94(0x10b)](_0x4f7c94(0x101)),_0x5e1c87[_0x4f7c94(0xd8)]({'role':_0x4f7c94(0x19a),'content':_0x1bb27c+'\x20[Aborted]'}),_0x5e1c87[_0x4f7c94(0xd8)]({'role':'user','content':_0x4f7c94(0xd9)});break;}if(_0x42544f[_0x4f7c94(0x14b)]){a4_0x14b1a5['rateLimitWarning'](_0x42544f[_0x4f7c94(0x11c)]||0x3c);return;}a4_0x14b1a5[_0x4f7c94(0x157)](_0x4f7c94(0xec)+_0x42544f);return;}finally{process['removeListener'](_0x4f7c94(0x127),_0x162b10);}_0x2f6d27[_0x4f7c94(0x13e)]&&_0x2f6d27[_0x4f7c94(0x115)]();a4_0x14b1a5['aiMessageEnd'](),_0x5e1c87['push']({'role':'assistant','content':_0x1bb27c});let _0x2011c7=_0x1bb27c[_0x4f7c94(0xbf)](/<execute_tool>\s*([\s\S]*?)<\/execute_tool>/);!_0x2011c7&&(_0x2011c7=_0x1bb27c['match'](/```tool\s*([\s\S]*?)```/));!_0x2011c7&&(_0x2011c7=_0x1bb27c[_0x4f7c94(0xbf)](/```json\s*(\{[\s\S]*?"name"\s*:[\s\S]*?\})\s*```/));if(!_0x2011c7)break;function _0x1950fb(_0x5086a8){const _0x279d1e=_0x4f7c94,_0x437564=_0x5086a8[_0x279d1e(0xeb)]();try{return JSON[_0x279d1e(0x134)](_0x437564);}catch(_0x4b164a){try{let _0x4072cc='',_0x4bc871=![];for(let _0x47ff86=0x0;_0x47ff86<_0x437564[_0x279d1e(0xe1)];_0x47ff86++){const _0x447639=_0x437564[_0x47ff86];if(_0x447639==='\x22'&&_0x437564[_0x47ff86-0x1]!=='\x5c')_0x4bc871=!_0x4bc871;if(_0x4bc871&&_0x447639==='\x0a')_0x4072cc+='\x5cn';else _0x4072cc+=_0x447639;}return JSON[_0x279d1e(0x134)](_0x4072cc);}catch(_0x233123){try{return new Function('return\x20'+_0x437564)();}catch(_0x50900b){throw new Error(_0x279d1e(0x197)+_0x4b164a[_0x279d1e(0x104)]);}}}}try{const _0x3ba7b2=_0x1950fb(_0x2011c7[0x1]),_0x2c2754={'write_file':'create_file','write':'create_file','create':'create_file','read':_0x4f7c94(0x191),'read_text_file':_0x4f7c94(0x191),'search':_0x4f7c94(0xd0),'list':_0x4f7c94(0x143),'ls':_0x4f7c94(0x143),'execute':'run_command','cmd':_0x4f7c94(0xd5)};_0x2c2754[_0x3ba7b2[_0x4f7c94(0x154)]]&&(_0x3ba7b2['name']=_0x2c2754[_0x3ba7b2[_0x4f7c94(0x154)]]);_0x3ba7b2[_0x4f7c94(0xc3)]&&(!_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x132)]&&(_0x3ba7b2['args'][_0x4f7c94(0x132)]=_0x3ba7b2['args'][_0x4f7c94(0xdc)]||_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x110)]||_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0xd3)]||_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0xc4)]),!_0x3ba7b2['args']['content']&&(_0x3ba7b2['args'][_0x4f7c94(0xf5)]=_0x3ba7b2['args'][_0x4f7c94(0x13b)]||_0x3ba7b2['args'][_0x4f7c94(0x119)]||_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0xf4)]||_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x11d)]),!_0x3ba7b2[_0x4f7c94(0xc3)]['command']&&(_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x16d)]=_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x1a1)]||_0x3ba7b2[_0x4f7c94(0xc3)]['script']));const _0x2f0128={'create_file':_0x4f7c94(0x138),'read_file':_0x4f7c94(0x16c),'edit_file':_0x4f7c94(0x18f),'list_directory':_0x4f7c94(0x151),'search_file':_0x4f7c94(0x160),'find_files':'Find','search_directory':'SearchDir','run_command':_0x4f7c94(0x10a),'browser_open':_0x4f7c94(0x173),'browser_click':_0x4f7c94(0x121),'browser_fill':_0x4f7c94(0x179),'browser_snapshot':_0x4f7c94(0xe9),'browser_screenshot':_0x4f7c94(0x166),'browser_get_text':_0x4f7c94(0x193),'browser_close':_0x4f7c94(0x1a8)},_0x39fda9=_0x2f0128[_0x3ba7b2[_0x4f7c94(0x154)]]||_0x3ba7b2['name'];let _0x116322='';if(_0x3ba7b2[_0x4f7c94(0x154)]==='run_command'&&_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x16d)])_0x116322=_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x16d)];else{if(_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x132)])_0x116322=_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x132)];else{if(_0x3ba7b2['args']['pattern'])_0x116322='\x22'+_0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x17e)]+'\x22';else _0x3ba7b2[_0x4f7c94(0xc3)][_0x4f7c94(0x19d)]?_0x116322=_0x3ba7b2[_0x4f7c94(0xc3)]['url']:_0x116322=Object[_0x4f7c94(0xe0)](_0x3ba7b2[_0x4f7c94(0xc3)])[0x0]||'';}}const _0x13fdfe=_0x116322[_0x4f7c94(0xe1)]>0x32?_0x116322[_0x4f7c94(0x1a0)](0x0,0x2f)+_0x4f7c94(0x158):_0x116322,_0x4fa32b=a4_0x14b1a5[_0x4f7c94(0x19b)](_0x39fda9+'('+_0x13fdfe+')');_0x4fa32b[_0x4f7c94(0xd7)]();const _0xbe34ef=performance[_0x4f7c94(0xcb)]();let _0x26b498;try{_0x26b498=await executeToolCall(_0x3ba7b2['name'],_0x3ba7b2[_0x4f7c94(0xc3)]);}catch(_0x13f981){if(_0x13f981[_0x4f7c94(0x104)]&&_0x13f981[_0x4f7c94(0x104)][_0x4f7c94(0x168)](_0x4f7c94(0x139))){const _0x4d2bcb=await getMcpTools(),_0x189b59=_0x4d2bcb['find'](_0x1a2f4c=>_0x1a2f4c[_0x4f7c94(0x154)]===_0x3ba7b2[_0x4f7c94(0x154)]);if(_0x189b59)try{_0x26b498=await executeMcpTool(_0x189b59['serverName'],_0x189b59[_0x4f7c94(0x154)],_0x3ba7b2['args']);}catch(_0x3fb6b1){throw new Error('MCP\x20Tool\x20error:\x20'+_0x3fb6b1);}else throw _0x13f981;}else throw _0x13f981;}const _0x2f2801=((performance['now']()-_0xbe34ef)/0x3e8)['toFixed'](0x1);_0x4fa32b[_0x4f7c94(0x115)]();let _0xbc8881=_0x4f7c94(0x14e)+_0x2f2801+'s',_0x251acb=![];if(_0x3ba7b2[_0x4f7c94(0x154)]==='run_command'&&_0x26b498&&typeof _0x26b498==='object'){const _0x1bcf01=_0x26b498;if(_0x1bcf01['exitCode']===0x0){const _0x2d415b=_0x1bcf01[_0x4f7c94(0x161)]?_0x1bcf01[_0x4f7c94(0x161)][_0x4f7c94(0x123)]('\x0a')[_0x4f7c94(0xe1)]:0x0;_0xbc8881=_0x4f7c94(0x136)+_0x2d415b+_0x4f7c94(0xc5)+_0x2f2801+'s)';}else _0x1bcf01[_0x4f7c94(0x120)]!==undefined&&(_0x251acb=!![],_0xbc8881=_0x4f7c94(0x167)+_0x1bcf01[_0x4f7c94(0x120)],_0x1bcf01[_0x4f7c94(0xed)]&&(_0xbc8881+=':\x20'+_0x1bcf01[_0x4f7c94(0xed)][_0x4f7c94(0x123)]('\x0a')[0x0][_0x4f7c94(0x14d)](0x0,0x64)));}else{if(_0x3ba7b2[_0x4f7c94(0x154)]===_0x4f7c94(0x191)&&_0x26b498&&typeof _0x26b498['content']===_0x4f7c94(0x196)){const _0x8c8f3e=_0x26b498['content'][_0x4f7c94(0x123)]('\x0a')['length'];_0xbc8881='Read\x20'+_0x8c8f3e+_0x4f7c94(0x14a)+_0x2f2801+'s)';}else{if(_0x3ba7b2[_0x4f7c94(0x154)]==='edit_file')_0xbc8881=_0x4f7c94(0x19e)+_0x2f2801+'s)';else _0x26b498&&typeof _0x26b498==='object'&&_0x4f7c94(0x157)in _0x26b498&&(_0x251acb=!![],_0xbc8881='Error:\x20'+_0x26b498[_0x4f7c94(0x157)]);}}a4_0x14b1a5[_0x4f7c94(0x170)](_0x39fda9,_0x13fdfe,_0xbc8881,_0x251acb),_0x5e1c87['push']({'role':_0x4f7c94(0xf2),'content':_0x4f7c94(0x150)+_0x3ba7b2['name']+':\x0a'+JSON[_0x4f7c94(0x105)](_0x26b498,null,0x2)}),await new Promise(_0x3b3801=>setTimeout(_0x3b3801,0x1f4));}catch(_0x498b75){a4_0x14b1a5['toolSuccess'](_0x4f7c94(0xcc),_0x4f7c94(0x12c),_0x498b75['message']||String(_0x498b75),!![]),_0x5e1c87['push']({'role':_0x4f7c94(0xf2),'content':_0x4f7c94(0xcf)+_0x498b75+_0x4f7c94(0x108)});}}_0x2c3bcf>=_0x4e46b2&&a4_0x14b1a5[_0x4f7c94(0x10b)](_0x4f7c94(0x153));}async function executeToolCall(_0x5932f7,_0x527963){const _0x2af1d6=a4_0x407f59;switch(_0x5932f7){case _0x2af1d6(0x195):return createFile(_0x527963[_0x2af1d6(0x132)],_0x527963[_0x2af1d6(0xf5)]);case _0x2af1d6(0x191):return readFile(_0x527963['path']);case _0x2af1d6(0x143):return listDirectory(_0x527963['path']||'.');case _0x2af1d6(0x1a3):return editFile(_0x527963[_0x2af1d6(0x132)],_0x527963['search'],_0x527963[_0x2af1d6(0x16b)]);case'search_file':return searchFile(_0x527963[_0x2af1d6(0x132)],_0x527963['pattern']);case _0x2af1d6(0xd5):const {command:_0x3e8789,background:_0x178264,wait:_0x5e0b75}=_0x527963,_0x44e639=await runCommand(_0x3e8789,undefined,_0x178264,_0x5e0b75);return _0x44e639;case _0x2af1d6(0xfe):{const {findFiles:_0x47565b}=await import(_0x2af1d6(0x199));return _0x47565b(_0x527963[_0x2af1d6(0x132)]||'.',_0x527963[_0x2af1d6(0x17e)]);}case _0x2af1d6(0x17c):{const {searchDirectory:_0x490d78}=await import(_0x2af1d6(0x199));return _0x490d78(_0x527963[_0x2af1d6(0x132)]||'.',_0x527963['pattern']);}case _0x2af1d6(0x185):{const {readFile:_0x14bc41}=await import(_0x2af1d6(0xfa));return _0x14bc41(_0x527963[_0x2af1d6(0xca)],_0x527963[_0x2af1d6(0x171)],_0x527963[_0x2af1d6(0x132)],_0x527963[_0x2af1d6(0x162)]);}case'github_create_pr':{const {createPullRequest:_0x340247}=await import(_0x2af1d6(0xfa));return _0x340247(_0x527963['owner'],_0x527963[_0x2af1d6(0x171)],_0x527963['title'],_0x527963['head'],_0x527963[_0x2af1d6(0x17d)],_0x527963[_0x2af1d6(0x131)]);}case _0x2af1d6(0x125):{const {createBranch:_0x41b86c}=await import(_0x2af1d6(0xfa));return _0x41b86c(_0x527963[_0x2af1d6(0xca)],_0x527963[_0x2af1d6(0x171)],_0x527963[_0x2af1d6(0xd4)],_0x527963[_0x2af1d6(0xfb)]);}case'browser_open':{const {browserOpen:_0x48efff,startBrowserServer:_0xb36b60,isBrowserServerRunning:_0x4e945f}=await import(_0x2af1d6(0x128));return!_0x4e945f()&&await _0xb36b60(),_0x48efff(_0x527963[_0x2af1d6(0x19d)]);}case _0x2af1d6(0x178):{const {browserClick:_0x239c74}=await import(_0x2af1d6(0x128));return _0x239c74(_0x527963[_0x2af1d6(0x137)]);}case _0x2af1d6(0x133):{const {browserFill:_0x3272d2}=await import(_0x2af1d6(0x128));return _0x3272d2(_0x527963['selector'],_0x527963[_0x2af1d6(0x11b)]);}case _0x2af1d6(0x187):{const {browserSnapshot:_0x48d27a}=await import(_0x2af1d6(0x128));return _0x48d27a();}case _0x2af1d6(0x100):{const {browserScreenshot:_0x348762}=await import(_0x2af1d6(0x128));return _0x348762();}case'browser_get_text':{const {browserGetText:_0x432b01}=await import(_0x2af1d6(0x128));return _0x432b01(_0x527963[_0x2af1d6(0x137)]);}case _0x2af1d6(0xd2):{const {browserClose:_0x5256be}=await import(_0x2af1d6(0x128));return _0x5256be();}default:return{'error':_0x2af1d6(0xc0)+_0x5932f7};}}
@@ -1 +1 @@
1
- const a5_0x4ee64c=a5_0x58e3;function a5_0x4d9e(){const _0x56c098=['uvx','src','readFileSync','mcp.json','4319320cMsEPe','tsx','.woozlit','set','HOME','USERPROFILE','join','woozlit-cli','10CuKEwx','mcpServers','dirname','computer-use.js','2626227FbDtth','computer-use','node','cwd','6924660ObbOga','env','endsWith','object','4220KLPqdy','get','.js','13114737VQocJI','2645968VsnOJs','parse','441007NRiuSa','@modelcontextprotocol/server-filesystem','includes','581mEJhYB','18rmoTFN','mcp-servers','path','existsSync','windows-mcp','stdio'];a5_0x4d9e=function(){return _0x56c098;};return a5_0x4d9e();}(function(_0x260b0e,_0x40a5cc){const _0x276c9d=a5_0x58e3,_0x129c15=_0x260b0e();while(!![]){try{const _0x2ef302=-parseInt(_0x276c9d(0x159))/0x1*(-parseInt(_0x276c9d(0x150))/0x2)+parseInt(_0x276c9d(0x148))/0x3+-parseInt(_0x276c9d(0x154))/0x4*(parseInt(_0x276c9d(0x16c))/0x5)+-parseInt(_0x276c9d(0x15a))/0x6*(-parseInt(_0x276c9d(0x156))/0x7)+parseInt(_0x276c9d(0x164))/0x8+-parseInt(_0x276c9d(0x153))/0x9+parseInt(_0x276c9d(0x14c))/0xa;if(_0x2ef302===_0x40a5cc)break;else _0x129c15['push'](_0x129c15['shift']());}catch(_0x1bb69a){_0x129c15['push'](_0x129c15['shift']());}}}(a5_0x4d9e,0xb547e));import a5_0x1f751b from'conf';import a5_0x3a1025 from'path';import a5_0x39e090 from'fs';import{fileURLToPath}from'url';const config=new a5_0x1f751b({'projectName':a5_0x4ee64c(0x16b),'defaults':{'mcpServers':{}}});export function getMcpServers(){const _0x42d4c0=a5_0x4ee64c,_0x1dbd11=config[_0x42d4c0(0x151)](_0x42d4c0(0x16d)),_0x2d6928=loadMcpConfigFile();return{..._0x1dbd11,..._0x2d6928};}export function addMcpServer(_0x95ee06,_0x42a2f3,_0x5e8617=[],_0x506efa){const _0x2bb51f=a5_0x4ee64c,_0x19d8d3=config[_0x2bb51f(0x151)](_0x2bb51f(0x16d));_0x19d8d3[_0x95ee06]={'type':'stdio','command':_0x42a2f3,'args':_0x5e8617,'env':_0x506efa},config[_0x2bb51f(0x167)](_0x2bb51f(0x16d),_0x19d8d3);}function a5_0x58e3(_0x1de259,_0x45267f){_0x1de259=_0x1de259-0x146;const _0x4d9ef7=a5_0x4d9e();let _0x58e35e=_0x4d9ef7[_0x1de259];return _0x58e35e;}export function addMcpHttpServer(_0x595f5c,_0x41265a){const _0x53fa7f=a5_0x4ee64c,_0x53a474=config[_0x53fa7f(0x151)](_0x53fa7f(0x16d));_0x53a474[_0x595f5c]={'type':'streamable-http','url':_0x41265a},config[_0x53fa7f(0x167)](_0x53fa7f(0x16d),_0x53a474);}export function removeMcpServer(_0x55a8cd){const _0x322f43=a5_0x4ee64c,_0x4d2187=config['get'](_0x322f43(0x16d));if(_0x4d2187[_0x55a8cd])return delete _0x4d2187[_0x55a8cd],config[_0x322f43(0x167)]('mcpServers',_0x4d2187),!![];return![];}export function clearMcpServers(){const _0xf03d47=a5_0x4ee64c;config['set'](_0xf03d47(0x16d),{});}export function getMcpServer(_0x24e71e){return getMcpServers()[_0x24e71e];}function loadMcpConfigFile(){const _0x243e55=a5_0x4ee64c,_0x1e3d2e=[a5_0x3a1025[_0x243e55(0x16a)](process[_0x243e55(0x14b)](),'mcp.json'),a5_0x3a1025['join'](process[_0x243e55(0x14b)](),'.woozlit',_0x243e55(0x163)),a5_0x3a1025['join'](process['env'][_0x243e55(0x168)]||process[_0x243e55(0x14d)][_0x243e55(0x169)]||'',_0x243e55(0x166),'mcp.json')];for(const _0x55838f of _0x1e3d2e){try{if(a5_0x39e090[_0x243e55(0x15d)](_0x55838f)){const _0x2f3b4b=a5_0x39e090[_0x243e55(0x162)](_0x55838f,'utf-8'),_0x458b5c=JSON[_0x243e55(0x155)](_0x2f3b4b);if(_0x458b5c[_0x243e55(0x16d)]&&typeof _0x458b5c[_0x243e55(0x16d)]===_0x243e55(0x14f))return _0x458b5c['mcpServers'];}}catch{}}return{};}export function ensureDefaultServers(){const _0xe56c4=a5_0x4ee64c,_0x5b9c75=config[_0xe56c4(0x151)](_0xe56c4(0x16d)),_0xfaa490=fileURLToPath(import.meta.url),_0x3331cd=a5_0x3a1025[_0xe56c4(0x146)](_0xfaa490),_0x44944f=_0x3331cd[_0xe56c4(0x158)]('dist')||_0xfaa490[_0xe56c4(0x14e)](_0xe56c4(0x152)),_0xc1027b=_0x44944f?a5_0x3a1025['join'](_0x3331cd,'..',_0xe56c4(0x15b),_0xe56c4(0x147)):a5_0x3a1025[_0xe56c4(0x16a)](_0x3331cd,'..','..',_0xe56c4(0x161),_0xe56c4(0x15b),'computer-use.ts'),_0x41f00e=_0x44944f?_0xe56c4(0x14a):_0xe56c4(0x165);_0x5b9c75[_0xe56c4(0x149)]={'type':_0xe56c4(0x15f),'command':_0x41f00e,'args':[_0xc1027b],'env':{}},(!_0x5b9c75['windows-mcp']||_0x5b9c75[_0xe56c4(0x15e)]['command']===_0xe56c4(0x160))&&(_0x5b9c75[_0xe56c4(0x15e)]={'type':_0xe56c4(0x15f),'command':'npx','args':['-y',_0xe56c4(0x157),'C:\x5cUsers'],'env':{}}),config['set'](_0xe56c4(0x16d),_0x5b9c75);}export function getConfigFilePath(){const _0x8e95ad=a5_0x4ee64c;return config[_0x8e95ad(0x15c)];}
1
+ const a5_0x401de1=a5_0x3ca1;(function(_0x55b9af,_0x3021e4){const _0x5439ab=a5_0x3ca1,_0xf1fa5e=_0x55b9af();while(!![]){try{const _0x4ba011=-parseInt(_0x5439ab(0x1fc))/0x1+parseInt(_0x5439ab(0x209))/0x2*(-parseInt(_0x5439ab(0x200))/0x3)+-parseInt(_0x5439ab(0x1f4))/0x4+-parseInt(_0x5439ab(0x1f7))/0x5+parseInt(_0x5439ab(0x20a))/0x6*(-parseInt(_0x5439ab(0x1f8))/0x7)+parseInt(_0x5439ab(0x206))/0x8+parseInt(_0x5439ab(0x1fe))/0x9;if(_0x4ba011===_0x3021e4)break;else _0xf1fa5e['push'](_0xf1fa5e['shift']());}catch(_0x3941ba){_0xf1fa5e['push'](_0xf1fa5e['shift']());}}}(a5_0x1f03,0xb17b0));import a5_0x4b33c5 from'conf';function a5_0x1f03(){const _0x38e758=['computer-use','computer-use.js','command','dist','2666976RpjGKm','endsWith','path','7013925HlLJXK','14LbqNan','set','C:\x5cUsers','includes','751461Vldjad','windows-mcp','43310142pqWUDX','dirname','6OpBmVB','env','readFileSync','woozlit-cli','get','computer-use.ts','7584400wMySAC','streamable-http','src','808594WzkBLb','4211232UtgEjl','existsSync','mcp-servers','mcp.json','stdio','HOME','utf-8','cwd','object','mcpServers','join','.woozlit','parse'];a5_0x1f03=function(){return _0x38e758;};return a5_0x1f03();}import a5_0xead868 from'path';import a5_0x3bf8b4 from'fs';import{fileURLToPath}from'url';function a5_0x3ca1(_0x10055a,_0xe27fcd){_0x10055a=_0x10055a-0x1e4;const _0x1f03d5=a5_0x1f03();let _0x3ca18c=_0x1f03d5[_0x10055a];return _0x3ca18c;}const config=new a5_0x4b33c5({'projectName':a5_0x401de1(0x203),'defaults':{'mcpServers':{}}});export function getMcpServers(){const _0x517889=a5_0x401de1,_0x5f38ef=config[_0x517889(0x204)]('mcpServers'),_0xbe58f5=loadMcpConfigFile();return{..._0x5f38ef,..._0xbe58f5};}export function addMcpServer(_0x292dbd,_0x1fb5ea,_0x1af2ce=[],_0x5158db){const _0x20b0c5=a5_0x401de1,_0x342b29=config['get'](_0x20b0c5(0x1ec));_0x342b29[_0x292dbd]={'type':_0x20b0c5(0x1e7),'command':_0x1fb5ea,'args':_0x1af2ce,'env':_0x5158db},config[_0x20b0c5(0x1f9)](_0x20b0c5(0x1ec),_0x342b29);}export function addMcpHttpServer(_0x2fb05c,_0x3d3a1d){const _0x82b3ae=a5_0x401de1,_0x1c3e67=config[_0x82b3ae(0x204)](_0x82b3ae(0x1ec));_0x1c3e67[_0x2fb05c]={'type':_0x82b3ae(0x207),'url':_0x3d3a1d},config[_0x82b3ae(0x1f9)](_0x82b3ae(0x1ec),_0x1c3e67);}export function removeMcpServer(_0x1d7d4d){const _0x114401=a5_0x401de1,_0x4a40f3=config[_0x114401(0x204)](_0x114401(0x1ec));if(_0x4a40f3[_0x1d7d4d])return delete _0x4a40f3[_0x1d7d4d],config[_0x114401(0x1f9)]('mcpServers',_0x4a40f3),!![];return![];}export function clearMcpServers(){const _0x103d8a=a5_0x401de1;config[_0x103d8a(0x1f9)](_0x103d8a(0x1ec),{});}export function getMcpServer(_0x51392b){return getMcpServers()[_0x51392b];}function loadMcpConfigFile(){const _0x4452d2=a5_0x401de1,_0x5ac724=[a5_0xead868['join'](process[_0x4452d2(0x1ea)](),'mcp.json'),a5_0xead868[_0x4452d2(0x1ed)](process['cwd'](),'.woozlit',_0x4452d2(0x1e6)),a5_0xead868[_0x4452d2(0x1ed)](process[_0x4452d2(0x201)][_0x4452d2(0x1e8)]||process[_0x4452d2(0x201)]['USERPROFILE']||'',_0x4452d2(0x1ee),'mcp.json')];for(const _0xa61241 of _0x5ac724){try{if(a5_0x3bf8b4[_0x4452d2(0x1e4)](_0xa61241)){const _0x1fe3b8=a5_0x3bf8b4[_0x4452d2(0x202)](_0xa61241,_0x4452d2(0x1e9)),_0x4c4be1=JSON[_0x4452d2(0x1ef)](_0x1fe3b8);if(_0x4c4be1['mcpServers']&&typeof _0x4c4be1[_0x4452d2(0x1ec)]===_0x4452d2(0x1eb))return _0x4c4be1[_0x4452d2(0x1ec)];}}catch{}}return{};}export function ensureDefaultServers(){const _0x2feb9e=a5_0x401de1,_0x555a39=config['get'](_0x2feb9e(0x1ec)),_0x461b42=fileURLToPath(import.meta.url),_0x2f7b3a=a5_0xead868[_0x2feb9e(0x1ff)](_0x461b42),_0x57e0a7=_0x2f7b3a[_0x2feb9e(0x1fb)](_0x2feb9e(0x1f3))||_0x461b42[_0x2feb9e(0x1f5)]('.js'),_0x308bec=_0x57e0a7?a5_0xead868['join'](_0x2f7b3a,'..',_0x2feb9e(0x1e5),_0x2feb9e(0x1f1)):a5_0xead868['join'](_0x2f7b3a,'..','..',_0x2feb9e(0x208),_0x2feb9e(0x1e5),_0x2feb9e(0x205)),_0x314dce=_0x57e0a7?'node':'tsx';_0x555a39[_0x2feb9e(0x1f0)]={'type':_0x2feb9e(0x1e7),'command':_0x314dce,'args':[_0x308bec],'env':{}},(!_0x555a39[_0x2feb9e(0x1fd)]||_0x555a39[_0x2feb9e(0x1fd)][_0x2feb9e(0x1f2)]==='uvx')&&(_0x555a39['windows-mcp']={'type':'stdio','command':'npx','args':['-y','@modelcontextprotocol/server-filesystem',_0x2feb9e(0x1fa)],'env':{}}),config['set']('mcpServers',_0x555a39);}export function getConfigFilePath(){const _0x4b5bd5=a5_0x401de1;return config[_0x4b5bd5(0x1f6)];}
@@ -1 +1 @@
1
- const a6_0x466811=a6_0x577d;(function(_0x419ccc,_0x38f065){const _0x385804=a6_0x577d,_0x1e226d=_0x419ccc();while(!![]){try{const _0x2c11af=parseInt(_0x385804(0xc2))/0x1+-parseInt(_0x385804(0xd1))/0x2+-parseInt(_0x385804(0xd4))/0x3*(-parseInt(_0x385804(0xd3))/0x4)+parseInt(_0x385804(0xd6))/0x5+parseInt(_0x385804(0xb8))/0x6*(-parseInt(_0x385804(0xc5))/0x7)+parseInt(_0x385804(0xc0))/0x8+parseInt(_0x385804(0xb6))/0x9*(parseInt(_0x385804(0xc6))/0xa);if(_0x2c11af===_0x38f065)break;else _0x1e226d['push'](_0x1e226d['shift']());}catch(_0xce3ac3){_0x1e226d['push'](_0x1e226d['shift']());}}}(a6_0x17c8,0xd0cb9));const API_URL=process[a6_0x466811(0xde)][a6_0x466811(0xbb)]||a6_0x466811(0xc1),PROD_URL='https://woozlit.com';export function getApiUrl(){return API_URL;}function a6_0x577d(_0x4fcfe8,_0x3143db){_0x4fcfe8=_0x4fcfe8-0xb6;const _0x17c8e1=a6_0x17c8();let _0x577d62=_0x17c8e1[_0x4fcfe8];return _0x577d62;}export function getProdUrl(){return PROD_URL;}function a6_0x17c8(){const _0x2741e4=['Xiaomi\x27s\x20fast\x20AI\x20model','11120641QCvnxV','970ARwbEL','Meta\x27s\x20latest','DeepSeek\x27s\x20latest\x20V3','gemini-2.5-flash','Gemini\x203\x20Pro','meta-llama/llama-3.3-70b-instruct:free','Mistral\x20Small\x203.2','gemini-3-flash-preview','MiMo\x20V2','Kimi\x20K2','moonshotai/kimi-k2','1467006FRFVdD','Latest\x20Gemini\x203\x20model','208712KgReBs','42VdOejL','DeepSeek\x20R1','1915570HOkHbS','Latest\x20Mistral','Llama\x204\x20Maverick','xiaomi/mimo-v2-flash:free','Llama\x203.3\x2070B','qwen/qwen3-235b-a22b:free','mistralai/devstral-small','Advanced\x20reasoning','env','Devstral\x20Small','deepseek/deepseek-chat','Alibaba\x27s\x20largest','41139fDAzhL','Qwen3\x20235B','6ujkVoV','Developer-focused','qwen/qwen3-coder:free','WOOZLIT_API_URL','Fast\x20and\x20capable\x20(Default)','gemini-3-pro-preview','Meta\x27s\x20powerful\x20model','NVIDIA\x20vision','11191672KqCQld','https://woozlit.com','221439OSmzoG','nvidia/nemotron-nano-12b-v2-vl:free'];a6_0x17c8=function(){return _0x2741e4;};return a6_0x17c8();}export function isProduction(){return API_URL===PROD_URL;}export const MODELS=[{'id':a6_0x466811(0xc9),'name':'Woozie','description':a6_0x466811(0xbc),'xp':0x1},{'id':a6_0x466811(0xcd),'name':'Gemini\x203\x20Flash','description':a6_0x466811(0xd2),'xp':0x5},{'id':a6_0x466811(0xbd),'name':a6_0x466811(0xca),'description':'Most\x20powerful\x20Gemini','xp':0x5},{'id':a6_0x466811(0xd9),'name':a6_0x466811(0xce),'description':a6_0x466811(0xc4),'xp':0x1},{'id':a6_0x466811(0xdb),'name':a6_0x466811(0xb7),'description':a6_0x466811(0xe1),'xp':0x2},{'id':a6_0x466811(0xba),'name':'Qwen3\x20Coder','description':'Coding\x20specialist','xp':0x2},{'id':a6_0x466811(0xcb),'name':a6_0x466811(0xda),'description':a6_0x466811(0xbe),'xp':0x2},{'id':'meta-llama/llama-4-maverick','name':a6_0x466811(0xd8),'description':a6_0x466811(0xc7),'xp':0x3},{'id':a6_0x466811(0xdc),'name':a6_0x466811(0xdf),'description':a6_0x466811(0xb9),'xp':0x2},{'id':'mistralai/mistral-small-3.2-24b-instruct','name':a6_0x466811(0xcc),'description':a6_0x466811(0xd7),'xp':0x2},{'id':a6_0x466811(0xc3),'name':'Nemotron\x20Nano\x2012B','description':a6_0x466811(0xbf),'xp':0x1},{'id':a6_0x466811(0xd0),'name':a6_0x466811(0xcf),'description':'Reasoning\x20model','xp':0x3},{'id':a6_0x466811(0xe0),'name':'DeepSeek\x20V3','description':a6_0x466811(0xc8),'xp':0x2},{'id':'deepseek/deepseek-r1','name':a6_0x466811(0xd5),'description':a6_0x466811(0xdd),'xp':0x3}];export const DEFAULT_MODEL=a6_0x466811(0xc9);
1
+ function a6_0xca46(){const _0x24aee7=['12507552wVuTjy','Qwen3\x20Coder','5689374olGfXR','MiMo\x20V2','deepseek/deepseek-r1','https://woozlit.com','Latest\x20Mistral','mistralai/mistral-small-3.2-24b-instruct','gemini-2.5-flash','Kimi\x20K2','DeepSeek\x20R1','gemini-3-flash-preview','5684368GuLDNv','moonshotai/kimi-k2','Fast\x20and\x20capable\x20(Default)','qwen/qwen3-235b-a22b:free','nvidia/nemotron-nano-12b-v2-vl:free','Gemini\x203\x20Pro','57694mXeXZu','Coding\x20specialist','Xiaomi\x27s\x20fast\x20AI\x20model','Most\x20powerful\x20Gemini','Meta\x27s\x20latest','meta-llama/llama-4-maverick','NVIDIA\x20vision','WOOZLIT_API_URL','1266520XzTCMN','Reasoning\x20model','Woozie','Alibaba\x27s\x20largest','Developer-focused','env','864diBIOv','xiaomi/mimo-v2-flash:free','25577lxDusJ','76jiZYNe','Devstral\x20Small','22779783fqCcDH','DeepSeek\x27s\x20latest\x20V3','Gemini\x203\x20Flash','Llama\x204\x20Maverick','meta-llama/llama-3.3-70b-instruct:free'];a6_0xca46=function(){return _0x24aee7;};return a6_0xca46();}function a6_0x4321(_0x1c2fd0,_0x46c0d6){_0x1c2fd0=_0x1c2fd0-0x1e7;const _0xca46a2=a6_0xca46();let _0x432184=_0xca46a2[_0x1c2fd0];return _0x432184;}const a6_0x583f7c=a6_0x4321;(function(_0x160dfb,_0x1bbbb1){const _0x2105a1=a6_0x4321,_0x5600a1=_0x160dfb();while(!![]){try{const _0x59b8df=parseInt(_0x2105a1(0x205))/0x1*(parseInt(_0x2105a1(0x206))/0x2)+parseInt(_0x2105a1(0x20f))/0x3+-parseInt(_0x2105a1(0x1ef))/0x4+-parseInt(_0x2105a1(0x1fd))/0x5+-parseInt(_0x2105a1(0x203))/0x6*(parseInt(_0x2105a1(0x1f5))/0x7)+-parseInt(_0x2105a1(0x20d))/0x8+parseInt(_0x2105a1(0x208))/0x9;if(_0x59b8df===_0x1bbbb1)break;else _0x5600a1['push'](_0x5600a1['shift']());}catch(_0x1bb3f5){_0x5600a1['push'](_0x5600a1['shift']());}}}(a6_0xca46,0xedfbf));const API_URL=process[a6_0x583f7c(0x202)][a6_0x583f7c(0x1fc)]||a6_0x583f7c(0x1e8),PROD_URL=a6_0x583f7c(0x1e8);export function getApiUrl(){return API_URL;}export function getProdUrl(){return PROD_URL;}export function isProduction(){return API_URL===PROD_URL;}export const MODELS=[{'id':a6_0x583f7c(0x1eb),'name':a6_0x583f7c(0x1ff),'description':a6_0x583f7c(0x1f1),'xp':0x1},{'id':a6_0x583f7c(0x1ee),'name':a6_0x583f7c(0x20a),'description':'Latest\x20Gemini\x203\x20model','xp':0x5},{'id':'gemini-3-pro-preview','name':a6_0x583f7c(0x1f4),'description':a6_0x583f7c(0x1f8),'xp':0x5},{'id':a6_0x583f7c(0x204),'name':a6_0x583f7c(0x210),'description':a6_0x583f7c(0x1f7),'xp':0x1},{'id':a6_0x583f7c(0x1f2),'name':'Qwen3\x20235B','description':a6_0x583f7c(0x200),'xp':0x2},{'id':'qwen/qwen3-coder:free','name':a6_0x583f7c(0x20e),'description':a6_0x583f7c(0x1f6),'xp':0x2},{'id':a6_0x583f7c(0x20c),'name':'Llama\x203.3\x2070B','description':'Meta\x27s\x20powerful\x20model','xp':0x2},{'id':a6_0x583f7c(0x1fa),'name':a6_0x583f7c(0x20b),'description':a6_0x583f7c(0x1f9),'xp':0x3},{'id':'mistralai/devstral-small','name':a6_0x583f7c(0x207),'description':a6_0x583f7c(0x201),'xp':0x2},{'id':a6_0x583f7c(0x1ea),'name':'Mistral\x20Small\x203.2','description':a6_0x583f7c(0x1e9),'xp':0x2},{'id':a6_0x583f7c(0x1f3),'name':'Nemotron\x20Nano\x2012B','description':a6_0x583f7c(0x1fb),'xp':0x1},{'id':a6_0x583f7c(0x1f0),'name':a6_0x583f7c(0x1ec),'description':a6_0x583f7c(0x1fe),'xp':0x3},{'id':'deepseek/deepseek-chat','name':'DeepSeek\x20V3','description':a6_0x583f7c(0x209),'xp':0x2},{'id':a6_0x583f7c(0x1e7),'name':a6_0x583f7c(0x1ed),'description':'Advanced\x20reasoning','xp':0x3}];export const DEFAULT_MODEL=a6_0x583f7c(0x1eb);
@@ -1 +1 @@
1
- (function(_0x1669a0,_0x31efcc){const _0x3f78c5=a7_0x4d36,_0x725324=_0x1669a0();while(!![]){try{const _0x2599a9=parseInt(_0x3f78c5(0x110))/0x1*(-parseInt(_0x3f78c5(0xe9))/0x2)+-parseInt(_0x3f78c5(0x101))/0x3+-parseInt(_0x3f78c5(0xec))/0x4+-parseInt(_0x3f78c5(0xfe))/0x5+parseInt(_0x3f78c5(0xee))/0x6+-parseInt(_0x3f78c5(0x10f))/0x7*(parseInt(_0x3f78c5(0x107))/0x8)+parseInt(_0x3f78c5(0xfa))/0x9;if(_0x2599a9===_0x31efcc)break;else _0x725324['push'](_0x725324['shift']());}catch(_0x394b38){_0x725324['push'](_0x725324['shift']());}}}(a7_0x4ddb,0xf12a9));import{Client,GatewayIntentBits,ChannelType,Partials}from'discord.js';import*as a7_0x4dedbb from'./config.js';import*as a7_0x47de32 from'../ui/output.js';import{getSelectedModel}from'../utils/storage.js';function a7_0x4ddb(){const _0x383b15=['reply','channelId','system','ready','sendTyping','12nihRdR','Guilds','content','6534284HbBvTu','user','8974080kIDgbH','You\x20are\x20Woozlit,\x20a\x20helpful\x20AI\x20assistant\x20connected\x20via\x20Discord.\x20Keep\x20responses\x20concise.','channel','author','[Discord]\x20Error:\x20','trim','mentions','Channel','DirectMessages','getBotToken','info','length','42620967ILiYuC','message','Sorry,\x20I\x20encountered\x20an\x20error\x20processing\x20that.','push','1920205Fvuvhd','bot','once','5855511CMtXsL','[Discord]\x20Connected\x20as\x20','has','destroy','type','success','1256PqOJfo','match','guildId','login','error','tag','set','replace','37681vEyeGy','71491ArojcT','messageCreate','GuildMessages'];a7_0x4ddb=function(){return _0x383b15;};return a7_0x4ddb();}import{sendChatMessage}from'../utils/api.js';let client=null,isRunning=![];const chatHistories=new Map();function a7_0x4d36(_0x3a8ee5,_0x56958f){_0x3a8ee5=_0x3a8ee5-0xe4;const _0x4ddbf2=a7_0x4ddb();let _0x4d369e=_0x4ddbf2[_0x3a8ee5];return _0x4d369e;}export async function startBot(){const _0xa6b23d=a7_0x4d36,_0x53f551=a7_0x4dedbb[_0xa6b23d(0xf7)]();if(!_0x53f551)return![];if(isRunning)return!![];try{return client=new Client({'intents':[GatewayIntentBits[_0xa6b23d(0xea)],GatewayIntentBits[_0xa6b23d(0x112)],GatewayIntentBits['MessageContent'],GatewayIntentBits[_0xa6b23d(0xf6)]],'partials':[Partials[_0xa6b23d(0xf5)]]}),client[_0xa6b23d(0x100)](_0xa6b23d(0xe7),()=>{const _0x27f5a7=_0xa6b23d;a7_0x47de32[_0x27f5a7(0x106)](_0x27f5a7(0x102)+client?.[_0x27f5a7(0xed)]?.[_0x27f5a7(0x10c)]),isRunning=!![];}),client['on'](_0xa6b23d(0x111),async _0x416d3e=>{const _0x29c3dd=_0xa6b23d;if(_0x416d3e[_0x29c3dd(0xf1)][_0x29c3dd(0xff)])return;const _0x4d87e1=_0x416d3e[_0x29c3dd(0xf0)][_0x29c3dd(0x105)]===ChannelType['DM'],_0x2176d7=client?.[_0x29c3dd(0xed)]&&_0x416d3e[_0x29c3dd(0xf4)][_0x29c3dd(0x103)](client['user']);if(!_0x4d87e1&&!_0x2176d7)return;await _0x416d3e[_0x29c3dd(0xf0)][_0x29c3dd(0xe8)]()['catch'](()=>{});const _0x1abc1e=_0x416d3e[_0x29c3dd(0xf1)]['id'],_0x29b3b1=(_0x416d3e[_0x29c3dd(0x109)]||'dm')+'-'+_0x416d3e[_0x29c3dd(0xe5)]+'-'+_0x1abc1e;!chatHistories[_0x29c3dd(0x103)](_0x29b3b1)&&chatHistories[_0x29c3dd(0x10d)](_0x29b3b1,[{'role':_0x29c3dd(0xe6),'content':_0x29c3dd(0xef)}]);const _0x4e38d6=chatHistories['get'](_0x29b3b1),_0x3f585a=_0x416d3e[_0x29c3dd(0xeb)][_0x29c3dd(0x10e)](/<@!?[0-9]+>/g,'')[_0x29c3dd(0xf3)]();if(!_0x3f585a)return;_0x4e38d6['push']({'role':'user','content':_0x3f585a}),a7_0x47de32[_0x29c3dd(0xf8)]('[Discord]\x20'+_0x416d3e['author']['username']+':\x20'+_0x3f585a);const _0x500038=getSelectedModel();try{let _0x53f73b='';const _0x1b8f39=await sendChatMessage(_0x500038,_0x4e38d6,_0x11f8f6=>{_0x53f73b+=_0x11f8f6;});_0x53f73b=_0x1b8f39[_0x29c3dd(0xeb)],_0x4e38d6[_0x29c3dd(0xfd)]({'role':'assistant','content':_0x53f73b});if(_0x53f73b[_0x29c3dd(0xf9)]>0x7d0){const _0x2e4d41=_0x53f73b[_0x29c3dd(0x108)](/[\s\S]{1,2000}/g)||[];for(const _0x461602 of _0x2e4d41){await _0x416d3e[_0x29c3dd(0xe4)](_0x461602);}}else await _0x416d3e[_0x29c3dd(0xe4)](_0x53f73b);}catch(_0x483638){a7_0x47de32[_0x29c3dd(0x10b)](_0x29c3dd(0xf2)+_0x483638[_0x29c3dd(0xfb)]),await _0x416d3e[_0x29c3dd(0xe4)](_0x29c3dd(0xfc));}}),await client[_0xa6b23d(0x10a)](_0x53f551),!![];}catch(_0x1509b3){return a7_0x47de32[_0xa6b23d(0x10b)]('[Discord]\x20Failed\x20to\x20start:\x20'+_0x1509b3[_0xa6b23d(0xfb)]),![];}}export function stopBot(){const _0x46de48=a7_0x4d36;client&&(client[_0x46de48(0x104)](),client=null),isRunning=![];}export function isBotRunning(){return isRunning;}
1
+ (function(_0x552bc1,_0x316c00){const _0x228f90=a7_0x38fd,_0xbe06f7=_0x552bc1();while(!![]){try{const _0x559b45=parseInt(_0x228f90(0xe5))/0x1*(parseInt(_0x228f90(0xf0))/0x2)+-parseInt(_0x228f90(0x104))/0x3*(parseInt(_0x228f90(0xe0))/0x4)+parseInt(_0x228f90(0xeb))/0x5+-parseInt(_0x228f90(0x102))/0x6*(-parseInt(_0x228f90(0xff))/0x7)+-parseInt(_0x228f90(0xe7))/0x8*(-parseInt(_0x228f90(0x103))/0x9)+-parseInt(_0x228f90(0xe9))/0xa+-parseInt(_0x228f90(0xe3))/0xb*(parseInt(_0x228f90(0xee))/0xc);if(_0x559b45===_0x316c00)break;else _0xbe06f7['push'](_0xbe06f7['shift']());}catch(_0x4d16a7){_0xbe06f7['push'](_0xbe06f7['shift']());}}}(a7_0x3706,0x5c046));import{Client,GatewayIntentBits,ChannelType,Partials}from'discord.js';import*as a7_0x4a67e1 from'./config.js';import*as a7_0x298953 from'../ui/output.js';import{getSelectedModel}from'../utils/storage.js';import{sendChatMessage}from'../utils/api.js';let client=null,isRunning=![];function a7_0x38fd(_0x44eb47,_0x49eead){_0x44eb47=_0x44eb47-0xdd;const _0x37063a=a7_0x3706();let _0x38fd6e=_0x37063a[_0x44eb47];return _0x38fd6e;}const chatHistories=new Map();export async function startBot(){const _0x422b72=a7_0x38fd,_0x53fbb3=a7_0x4a67e1['getBotToken']();if(!_0x53fbb3)return![];if(isRunning)return!![];try{return client=new Client({'intents':[GatewayIntentBits['Guilds'],GatewayIntentBits[_0x422b72(0xe6)],GatewayIntentBits['MessageContent'],GatewayIntentBits['DirectMessages']],'partials':[Partials['Channel']]}),client[_0x422b72(0xe1)]('ready',()=>{const _0x3644c2=_0x422b72;a7_0x298953['success']('[Discord]\x20Connected\x20as\x20'+client?.[_0x3644c2(0xed)]?.[_0x3644c2(0xdf)]),isRunning=!![];}),client['on'](_0x422b72(0xec),async _0x3ebcb6=>{const _0x2530f5=_0x422b72;if(_0x3ebcb6[_0x2530f5(0x100)][_0x2530f5(0xfe)])return;const _0x4b5392=_0x3ebcb6[_0x2530f5(0xf7)]['type']===ChannelType['DM'],_0x4db1cc=client?.[_0x2530f5(0xed)]&&_0x3ebcb6[_0x2530f5(0x107)]['has'](client[_0x2530f5(0xed)]);if(!_0x4b5392&&!_0x4db1cc)return;await _0x3ebcb6[_0x2530f5(0xf7)][_0x2530f5(0x106)]()[_0x2530f5(0xde)](()=>{});const _0x326708=_0x3ebcb6['author']['id'],_0xe0f2ff=(_0x3ebcb6[_0x2530f5(0xfa)]||'dm')+'-'+_0x3ebcb6[_0x2530f5(0xf4)]+'-'+_0x326708;!chatHistories[_0x2530f5(0xf5)](_0xe0f2ff)&&chatHistories['set'](_0xe0f2ff,[{'role':_0x2530f5(0xe8),'content':_0x2530f5(0x101)}]);const _0x2a9474=chatHistories[_0x2530f5(0x105)](_0xe0f2ff),_0x361659=_0x3ebcb6['content'][_0x2530f5(0xe4)](/<@!?[0-9]+>/g,'')['trim']();if(!_0x361659)return;_0x2a9474[_0x2530f5(0xea)]({'role':_0x2530f5(0xed),'content':_0x361659}),a7_0x298953[_0x2530f5(0xef)](_0x2530f5(0xfb)+_0x3ebcb6[_0x2530f5(0x100)][_0x2530f5(0xf9)]+':\x20'+_0x361659);const _0x297e8c=getSelectedModel();try{let _0x291b0c='';const _0x4fad2c=await sendChatMessage(_0x297e8c,_0x2a9474,_0x247180=>{_0x291b0c+=_0x247180;});_0x291b0c=_0x4fad2c[_0x2530f5(0xf3)],_0x2a9474[_0x2530f5(0xea)]({'role':_0x2530f5(0xfc),'content':_0x291b0c});if(_0x291b0c[_0x2530f5(0x109)]>0x7d0){const _0x163919=_0x291b0c['match'](/[\s\S]{1,2000}/g)||[];for(const _0x4097c8 of _0x163919){await _0x3ebcb6[_0x2530f5(0xf2)](_0x4097c8);}}else await _0x3ebcb6[_0x2530f5(0xf2)](_0x291b0c);}catch(_0x10c1fb){a7_0x298953[_0x2530f5(0xf1)](_0x2530f5(0xf6)+_0x10c1fb[_0x2530f5(0xdd)]),await _0x3ebcb6['reply'](_0x2530f5(0xfd));}}),await client[_0x422b72(0xf8)](_0x53fbb3),!![];}catch(_0xa1b7f8){return a7_0x298953['error'](_0x422b72(0xe2)+_0xa1b7f8[_0x422b72(0xdd)]),![];}}function a7_0x3706(){const _0x24730c=['message','catch','tag','6644AvKwIw','once','[Discord]\x20Failed\x20to\x20start:\x20','22HZkVsQ','replace','23087qJmwBv','GuildMessages','3944ApHoib','system','4244660BWXPdR','push','1654295dUDFsO','messageCreate','user','8113104mvnsgu','info','38rhphjm','error','reply','content','channelId','has','[Discord]\x20Error:\x20','channel','login','username','guildId','[Discord]\x20','assistant','Sorry,\x20I\x20encountered\x20an\x20error\x20processing\x20that.','bot','281323grgAhB','author','You\x20are\x20Woozlit,\x20a\x20helpful\x20AI\x20assistant\x20connected\x20via\x20Discord.\x20Keep\x20responses\x20concise.','102qAUNSR','13734gwlMGm','93GJwsdn','get','sendTyping','mentions','destroy','length'];a7_0x3706=function(){return _0x24730c;};return a7_0x3706();}export function stopBot(){const _0x2c275c=a7_0x38fd;client&&(client[_0x2c275c(0x108)](),client=null),isRunning=![];}export function isBotRunning(){return isRunning;}
@@ -1 +1 @@
1
- const a8_0x238dcd=a8_0xd5a4;(function(_0x8b1d67,_0x590578){const _0x53a365=a8_0xd5a4,_0x30c917=_0x8b1d67();while(!![]){try{const _0x224ac1=parseInt(_0x53a365(0x13e))/0x1*(-parseInt(_0x53a365(0x13c))/0x2)+parseInt(_0x53a365(0x141))/0x3+parseInt(_0x53a365(0x13d))/0x4+parseInt(_0x53a365(0x142))/0x5+-parseInt(_0x53a365(0x152))/0x6*(parseInt(_0x53a365(0x144))/0x7)+parseInt(_0x53a365(0x14c))/0x8*(parseInt(_0x53a365(0x140))/0x9)+parseInt(_0x53a365(0x14f))/0xa*(-parseInt(_0x53a365(0x13b))/0xb);if(_0x224ac1===_0x590578)break;else _0x30c917['push'](_0x30c917['shift']());}catch(_0x851369){_0x30c917['push'](_0x30c917['shift']());}}}(a8_0x146a,0x6e446));import a8_0x401d4f from'conf';import a8_0x5a2213 from'crypto';const config=new a8_0x401d4f({'projectName':a8_0x238dcd(0x143),'defaults':{'botToken':'','commandPrefix':'!','enabled':![]}}),ENCRYPTION_KEY=a8_0x238dcd(0x149);function a8_0x146a(){const _0x47bedd=['createDecipheriv','createHash','aes-256-cbc','woozlit_discord_secure_key','from','set','862728XaDGAE','digest','createCipheriv','4874930zPMWGV','final','update','6RQBqTv','split','utf8','sha256','hex','11HxvhIC','705410kXrimb','3355368wBVGRq','1rkanjD','botToken','27arsJzq','1110705zfdqxq','1404230FUffOK','woozlit-cli-discord','3651158WjCbjM','clear'];a8_0x146a=function(){return _0x47bedd;};return a8_0x146a();}function encrypt(_0x39862f){const _0x39a299=a8_0x238dcd;if(!_0x39862f)return'';const _0x2d5d86=a8_0x5a2213['randomBytes'](0x10),_0xa34f8d=a8_0x5a2213[_0x39a299(0x147)](_0x39a299(0x139))[_0x39a299(0x151)](ENCRYPTION_KEY)[_0x39a299(0x14d)](),_0x404786=a8_0x5a2213[_0x39a299(0x14e)](_0x39a299(0x148),_0xa34f8d,_0x2d5d86);let _0x36ad4c=_0x404786[_0x39a299(0x151)](_0x39862f,_0x39a299(0x154),_0x39a299(0x13a));return _0x36ad4c+=_0x404786[_0x39a299(0x150)](_0x39a299(0x13a)),_0x2d5d86['toString']('hex')+':'+_0x36ad4c;}function decrypt(_0x49ec17){const _0x21f09b=a8_0x238dcd;if(!_0x49ec17)return'';try{const [_0x4f98c3,_0x476f98]=_0x49ec17[_0x21f09b(0x153)](':');if(!_0x4f98c3||!_0x476f98)return'';const _0xdf5b1a=Buffer[_0x21f09b(0x14a)](_0x4f98c3,_0x21f09b(0x13a)),_0x47d032=a8_0x5a2213['createHash'](_0x21f09b(0x139))[_0x21f09b(0x151)](ENCRYPTION_KEY)[_0x21f09b(0x14d)](),_0x3b3b2b=a8_0x5a2213[_0x21f09b(0x146)](_0x21f09b(0x148),_0x47d032,_0xdf5b1a);let _0x537b9d=_0x3b3b2b[_0x21f09b(0x151)](_0x476f98,_0x21f09b(0x13a),_0x21f09b(0x154));return _0x537b9d+=_0x3b3b2b[_0x21f09b(0x150)](_0x21f09b(0x154)),_0x537b9d;}catch{return'';}}export function setBotToken(_0x8f787a){const _0x1b8677=a8_0x238dcd;config[_0x1b8677(0x14b)](_0x1b8677(0x13f),encrypt(_0x8f787a));}export function getBotToken(){return decrypt(config['get']('botToken'));}function a8_0xd5a4(_0x5afb09,_0x119a8f){_0x5afb09=_0x5afb09-0x139;const _0x146a70=a8_0x146a();let _0xd5a438=_0x146a70[_0x5afb09];return _0xd5a438;}export function isEnabled(){return!!getBotToken();}export function isConfigured(){return!!getBotToken();}export function clearConfig(){const _0x40c220=a8_0x238dcd;config[_0x40c220(0x145)]();}
1
+ const a8_0x5b6bd0=a8_0x10b5;(function(_0x33b67c,_0x567ae6){const _0x57bf77=a8_0x10b5,_0x2bf713=_0x33b67c();while(!![]){try{const _0x51704e=-parseInt(_0x57bf77(0x199))/0x1+parseInt(_0x57bf77(0x183))/0x2*(parseInt(_0x57bf77(0x197))/0x3)+parseInt(_0x57bf77(0x187))/0x4+-parseInt(_0x57bf77(0x190))/0x5*(-parseInt(_0x57bf77(0x188))/0x6)+-parseInt(_0x57bf77(0x17f))/0x7*(-parseInt(_0x57bf77(0x184))/0x8)+-parseInt(_0x57bf77(0x194))/0x9+-parseInt(_0x57bf77(0x186))/0xa;if(_0x51704e===_0x567ae6)break;else _0x2bf713['push'](_0x2bf713['shift']());}catch(_0x397bb8){_0x2bf713['push'](_0x2bf713['shift']());}}}(a8_0x2387,0x43b5c));import a8_0x24a4d6 from'conf';function a8_0x2387(){const _0x3875cc=['3rUWxmW','botToken','282543Coyizl','final','1699544FVhmiQ','woozlit-cli-discord','toString','createHash','701838EDxPvf','16mAViEq','aes-256-cbc','7955030UEvWES','1544704mZEKIL','589866NUdBKA','set','hex','clear','split','utf8','randomBytes','get','25kZrPWQ','update','digest','woozlit_discord_secure_key','3229632JCJHvJ','sha256','createDecipheriv'];a8_0x2387=function(){return _0x3875cc;};return a8_0x2387();}import a8_0x16f589 from'crypto';const config=new a8_0x24a4d6({'projectName':a8_0x5b6bd0(0x180),'defaults':{'botToken':'','commandPrefix':'!','enabled':![]}}),ENCRYPTION_KEY=a8_0x5b6bd0(0x193);function encrypt(_0x1b5854){const _0x57bcb5=a8_0x5b6bd0;if(!_0x1b5854)return'';const _0x201e4f=a8_0x16f589[_0x57bcb5(0x18e)](0x10),_0x5bd684=a8_0x16f589[_0x57bcb5(0x182)](_0x57bcb5(0x195))['update'](ENCRYPTION_KEY)[_0x57bcb5(0x192)](),_0xf7ff43=a8_0x16f589['createCipheriv'](_0x57bcb5(0x185),_0x5bd684,_0x201e4f);let _0x5b0df6=_0xf7ff43[_0x57bcb5(0x191)](_0x1b5854,_0x57bcb5(0x18d),_0x57bcb5(0x18a));return _0x5b0df6+=_0xf7ff43[_0x57bcb5(0x17e)](_0x57bcb5(0x18a)),_0x201e4f[_0x57bcb5(0x181)](_0x57bcb5(0x18a))+':'+_0x5b0df6;}function a8_0x10b5(_0x396794,_0x41ed83){_0x396794=_0x396794-0x17e;const _0x23872f=a8_0x2387();let _0x10b52a=_0x23872f[_0x396794];return _0x10b52a;}function decrypt(_0x10833f){const _0x4a262f=a8_0x5b6bd0;if(!_0x10833f)return'';try{const [_0xe2d84d,_0x4833ed]=_0x10833f[_0x4a262f(0x18c)](':');if(!_0xe2d84d||!_0x4833ed)return'';const _0x2d53dc=Buffer['from'](_0xe2d84d,_0x4a262f(0x18a)),_0x44c4ac=a8_0x16f589[_0x4a262f(0x182)](_0x4a262f(0x195))['update'](ENCRYPTION_KEY)[_0x4a262f(0x192)](),_0x1c7245=a8_0x16f589[_0x4a262f(0x196)](_0x4a262f(0x185),_0x44c4ac,_0x2d53dc);let _0x3e5029=_0x1c7245[_0x4a262f(0x191)](_0x4833ed,_0x4a262f(0x18a),_0x4a262f(0x18d));return _0x3e5029+=_0x1c7245[_0x4a262f(0x17e)](_0x4a262f(0x18d)),_0x3e5029;}catch{return'';}}export function setBotToken(_0x58ccf8){const _0x2186a6=a8_0x5b6bd0;config[_0x2186a6(0x189)](_0x2186a6(0x198),encrypt(_0x58ccf8));}export function getBotToken(){const _0x2afccf=a8_0x5b6bd0;return decrypt(config[_0x2afccf(0x18f)]('botToken'));}export function isEnabled(){return!!getBotToken();}export function isConfigured(){return!!getBotToken();}export function clearConfig(){const _0x4413f7=a8_0x5b6bd0;config[_0x4413f7(0x18b)]();}
@@ -1 +1 @@
1
- (function(_0x1e7d7a,_0x41f91d){var _0x4112d8=a9_0x5ac0,_0x32b594=_0x1e7d7a();while(!![]){try{var _0x319f81=parseInt(_0x4112d8(0xd4))/0x1+parseInt(_0x4112d8(0xdb))/0x2+parseInt(_0x4112d8(0xda))/0x3+-parseInt(_0x4112d8(0xd7))/0x4*(parseInt(_0x4112d8(0xd8))/0x5)+-parseInt(_0x4112d8(0xd5))/0x6+-parseInt(_0x4112d8(0xd6))/0x7+-parseInt(_0x4112d8(0xd9))/0x8*(-parseInt(_0x4112d8(0xd3))/0x9);if(_0x319f81===_0x41f91d)break;else _0x32b594['push'](_0x32b594['shift']());}catch(_0xcea687){_0x32b594['push'](_0x32b594['shift']());}}}(a9_0x4d38,0x7d56f));function a9_0x5ac0(_0x51fc3a,_0x561aa3){_0x51fc3a=_0x51fc3a-0xd3;var _0x4d3854=a9_0x4d38();var _0x5ac0d8=_0x4d3854[_0x51fc3a];return _0x5ac0d8;}export*from'./config.js';export{startBot,stopBot,isBotRunning}from'./client.js';export{setupDiscord}from'./setup.js';function a9_0x4d38(){var _0xbbb3e0=['9EkYZaO','305099eyCFwE','3682056FRhpTK','3020675Fvzrwn','14156jCZVcL','1315HSBjqv','12205784ZcVDQs','588216bScAHd','924910yPhRjD'];a9_0x4d38=function(){return _0xbbb3e0;};return a9_0x4d38();}
1
+ (function(_0x41b998,_0x1d49fe){var _0x5d45d3=a9_0x1664,_0x596df3=_0x41b998();while(!![]){try{var _0x2f0ccb=-parseInt(_0x5d45d3(0x193))/0x1*(-parseInt(_0x5d45d3(0x194))/0x2)+-parseInt(_0x5d45d3(0x197))/0x3+-parseInt(_0x5d45d3(0x195))/0x4+-parseInt(_0x5d45d3(0x196))/0x5*(-parseInt(_0x5d45d3(0x19d))/0x6)+parseInt(_0x5d45d3(0x19c))/0x7*(-parseInt(_0x5d45d3(0x19a))/0x8)+-parseInt(_0x5d45d3(0x19b))/0x9*(parseInt(_0x5d45d3(0x199))/0xa)+parseInt(_0x5d45d3(0x198))/0xb;if(_0x2f0ccb===_0x1d49fe)break;else _0x596df3['push'](_0x596df3['shift']());}catch(_0x56c1a4){_0x596df3['push'](_0x596df3['shift']());}}}(a9_0x3c0c,0x934de));export*from'./config.js';export{startBot,stopBot,isBotRunning}from'./client.js';function a9_0x1664(_0x560e95,_0x5d8ef8){_0x560e95=_0x560e95-0x193;var _0x3c0c54=a9_0x3c0c();var _0x166488=_0x3c0c54[_0x560e95];return _0x166488;}function a9_0x3c0c(){var _0x239a73=['27785HmQUvs','627993wqsSuj','4388692YZOoVO','1020DrqEUe','26056rwKzDi','9927eoMgOd','154AQAIqp','1212wucKnN','139756oxzIne','2tCMYKn','2657572ygMPCS'];a9_0x3c0c=function(){return _0x239a73;};return a9_0x3c0c();}export{setupDiscord}from'./setup.js';
@@ -1 +1 @@
1
- (function(_0x3e8536,_0x1a4281){const _0x4a707e=a10_0x5bf3,_0x477733=_0x3e8536();while(!![]){try{const _0xefaf1a=parseInt(_0x4a707e(0x1a8))/0x1*(parseInt(_0x4a707e(0x19e))/0x2)+parseInt(_0x4a707e(0x1a3))/0x3*(parseInt(_0x4a707e(0x1a0))/0x4)+parseInt(_0x4a707e(0x19b))/0x5+-parseInt(_0x4a707e(0x1a9))/0x6*(-parseInt(_0x4a707e(0x1a6))/0x7)+parseInt(_0x4a707e(0x1a4))/0x8+-parseInt(_0x4a707e(0x199))/0x9+-parseInt(_0x4a707e(0x1a5))/0xa*(parseInt(_0x4a707e(0x19d))/0xb);if(_0xefaf1a===_0x1a4281)break;else _0x477733['push'](_0x477733['shift']());}catch(_0x4a18da){_0x477733['push'](_0x477733['shift']());}}}(a10_0xd646,0x68b4a));import{input}from'@inquirer/prompts';import*as a10_0x2be7e8 from'./config.js';import*as a10_0x34e2c3 from'../ui/output.js';function a10_0x5bf3(_0x5027ae,_0x1a39f6){_0x5027ae=_0x5027ae-0x199;const _0xd64608=a10_0xd646();let _0x5bf311=_0xd64608[_0x5027ae];return _0x5bf311;}export async function setupDiscord(){const _0x4d8a61=a10_0x5bf3;a10_0x34e2c3[_0x4d8a61(0x19f)](_0x4d8a61(0x1a2)),a10_0x34e2c3['dim'](_0x4d8a61(0x19a));const _0x4cabba=await input({'message':_0x4d8a61(0x19c),'validate':_0x4c0b8b=>_0x4c0b8b['length']>0xa?!![]:'Token\x20seems\x20too\x20short'}),_0x4c9be8=await input({'message':_0x4d8a61(0x1a7),'default':'!'});a10_0x2be7e8['setBotToken'](_0x4cabba),a10_0x34e2c3[_0x4d8a61(0x1aa)](_0x4d8a61(0x1a1)),a10_0x34e2c3[_0x4d8a61(0x19f)]('Restart\x20the\x20CLI\x20to\x20start\x20the\x20Discord\x20Bot.');}function a10_0xd646(){const _0x3e81c3=['Setup\x20Woozlit\x20Discord\x20Bot','22164AcVrcY','1819120eLQPxi','100IYknEy','133AythSH','Command\x20Prefix\x20(optional,\x20default\x20\x27!\x27):','31163nZasgM','85644vEWLgF','success','2518524JCasyt','You\x20need\x20a\x20Bot\x20Token\x20from\x20the\x20Discord\x20Developer\x20Portal.','379975aUDHmo','Bot\x20Token:','733403ymInOU','22KeOeHh','info','248bugUjK','Discord\x20configuration\x20saved!'];a10_0xd646=function(){return _0x3e81c3;};return a10_0xd646();}
1
+ (function(_0x2a4521,_0x4bc647){const _0x963aa1=a10_0x54d3,_0x3895ff=_0x2a4521();while(!![]){try{const _0x13538f=parseInt(_0x963aa1(0x85))/0x1*(-parseInt(_0x963aa1(0x72))/0x2)+parseInt(_0x963aa1(0x83))/0x3*(parseInt(_0x963aa1(0x84))/0x4)+parseInt(_0x963aa1(0x76))/0x5+-parseInt(_0x963aa1(0x77))/0x6*(parseInt(_0x963aa1(0x74))/0x7)+-parseInt(_0x963aa1(0x78))/0x8+-parseInt(_0x963aa1(0x7f))/0x9*(parseInt(_0x963aa1(0x7b))/0xa)+parseInt(_0x963aa1(0x82))/0xb;if(_0x13538f===_0x4bc647)break;else _0x3895ff['push'](_0x3895ff['shift']());}catch(_0x392a63){_0x3895ff['push'](_0x3895ff['shift']());}}}(a10_0x2e1a,0x96148));import{input}from'@inquirer/prompts';import*as a10_0x398997 from'./config.js';function a10_0x2e1a(){const _0x19381b=['9uVlctL','402472yLorLN','75839IGfWGS','length','18CvjwsG','Bot\x20Token:','6839ZZHMPG','Restart\x20the\x20CLI\x20to\x20start\x20the\x20Discord\x20Bot.','1033580YcSMcr','6312hFwLwh','6321640eXRJkN','setBotToken','Discord\x20configuration\x20saved!','3654340DIOaAN','info','Token\x20seems\x20too\x20short','success','9oQuolz','Command\x20Prefix\x20(optional,\x20default\x20\x27!\x27):','You\x20need\x20a\x20Bot\x20Token\x20from\x20the\x20Discord\x20Developer\x20Portal.','32693672RiEyij'];a10_0x2e1a=function(){return _0x19381b;};return a10_0x2e1a();}function a10_0x54d3(_0x30ad49,_0x1675be){_0x30ad49=_0x30ad49-0x72;const _0x2e1ab1=a10_0x2e1a();let _0x54d3e1=_0x2e1ab1[_0x30ad49];return _0x54d3e1;}import*as a10_0x465062 from'../ui/output.js';export async function setupDiscord(){const _0x3b2fb4=a10_0x54d3;a10_0x465062['info']('Setup\x20Woozlit\x20Discord\x20Bot'),a10_0x465062['dim'](_0x3b2fb4(0x81));const _0x1ba76e=await input({'message':_0x3b2fb4(0x73),'validate':_0x2259e3=>_0x2259e3[_0x3b2fb4(0x86)]>0xa?!![]:_0x3b2fb4(0x7d)}),_0x252919=await input({'message':_0x3b2fb4(0x80),'default':'!'});a10_0x398997[_0x3b2fb4(0x79)](_0x1ba76e),a10_0x465062[_0x3b2fb4(0x7e)](_0x3b2fb4(0x7a)),a10_0x465062[_0x3b2fb4(0x7c)](_0x3b2fb4(0x75));}
@@ -1 +1 @@
1
- const a11_0x44fafd=a11_0x2c05;function a11_0x2c05(_0x4c6346,_0x19e01a){_0x4c6346=_0x4c6346-0x1b4;const _0x5e6410=a11_0x5e64();let _0x2c0504=_0x5e6410[_0x4c6346];return _0x2c0504;}(function(_0x2481cf,_0x3f1fbb){const _0x6d1485=a11_0x2c05,_0x3c8b64=_0x2481cf();while(!![]){try{const _0x116db9=parseInt(_0x6d1485(0x1db))/0x1+parseInt(_0x6d1485(0x1bc))/0x2*(-parseInt(_0x6d1485(0x1c1))/0x3)+-parseInt(_0x6d1485(0x1c5))/0x4*(parseInt(_0x6d1485(0x1dc))/0x5)+parseInt(_0x6d1485(0x1d4))/0x6+parseInt(_0x6d1485(0x1da))/0x7+-parseInt(_0x6d1485(0x1c9))/0x8*(parseInt(_0x6d1485(0x1d8))/0x9)+-parseInt(_0x6d1485(0x1c4))/0xa*(-parseInt(_0x6d1485(0x1ce))/0xb);if(_0x116db9===_0x3f1fbb)break;else _0x3c8b64['push'](_0x3c8b64['shift']());}catch(_0x212618){_0x3c8b64['push'](_0x3c8b64['shift']());}}}(a11_0x5e64,0xc03db));function a11_0x5e64(){const _0x5ecd14=['imapPass','randomBytes','allowedSenders','6450504zsvmzy','update','get','woozlit-cli-email','createHash','22WkXMSk','sha256','woozlit_email_secure_key','smtp.gmail.com','toString','createCipheriv','999228qPkfcJ','smtpPort','checkInterval','smtpPass','9UrSXpz','digest','20013qdVFfh','1533924fqmMLZ','5QAKWrI','hex','aes-256-cbc','imap.gmail.com','from','createDecipheriv','imap','imapUser','utf8','set','839698lvFaTe','includes','smtpUser','password','enabled','3SVCNzH','final','imapHost','4253190RPajin','2161512ngcBLl'];a11_0x5e64=function(){return _0x5ecd14;};return a11_0x5e64();}import a11_0x3baf40 from'conf';import a11_0x14e9c8 from'crypto';const config=new a11_0x3baf40({'projectName':a11_0x44fafd(0x1cc),'defaults':{'imapHost':a11_0x44fafd(0x1b5),'imapPort':0x3e1,'imapUser':'','imapPass':'','smtpHost':a11_0x44fafd(0x1d1),'smtpPort':0x24b,'smtpUser':'','smtpPass':'','checkInterval':0x5,'allowedSenders':[],'enabled':![]}}),ENCRYPTION_KEY=a11_0x44fafd(0x1d0);function encrypt(_0x3152c5){const _0x1dd9a3=a11_0x44fafd;if(!_0x3152c5)return'';const _0x287c25=a11_0x14e9c8[_0x1dd9a3(0x1c7)](0x10),_0x177535=a11_0x14e9c8[_0x1dd9a3(0x1cd)](_0x1dd9a3(0x1cf))[_0x1dd9a3(0x1ca)](ENCRYPTION_KEY)[_0x1dd9a3(0x1d9)](),_0x2597a1=a11_0x14e9c8[_0x1dd9a3(0x1d3)]('aes-256-cbc',_0x177535,_0x287c25);let _0x3de012=_0x2597a1[_0x1dd9a3(0x1ca)](_0x3152c5,_0x1dd9a3(0x1ba),_0x1dd9a3(0x1dd));return _0x3de012+=_0x2597a1[_0x1dd9a3(0x1c2)]('hex'),_0x287c25[_0x1dd9a3(0x1d2)](_0x1dd9a3(0x1dd))+':'+_0x3de012;}function decrypt(_0x25446b){const _0x3dae67=a11_0x44fafd;if(!_0x25446b)return'';try{const [_0x18639e,_0x513097]=_0x25446b['split'](':');if(!_0x18639e||!_0x513097)return'';const _0x39b2a4=Buffer[_0x3dae67(0x1b6)](_0x18639e,'hex'),_0x38c1bf=a11_0x14e9c8[_0x3dae67(0x1cd)](_0x3dae67(0x1cf))[_0x3dae67(0x1ca)](ENCRYPTION_KEY)['digest'](),_0xa23a39=a11_0x14e9c8[_0x3dae67(0x1b7)](_0x3dae67(0x1b4),_0x38c1bf,_0x39b2a4);let _0x16f1b0=_0xa23a39[_0x3dae67(0x1ca)](_0x513097,_0x3dae67(0x1dd),_0x3dae67(0x1ba));return _0x16f1b0+=_0xa23a39[_0x3dae67(0x1c2)](_0x3dae67(0x1ba)),_0x16f1b0;}catch{return'';}}export function setCredentials(_0x48a269,_0x58881f,_0x30e518,_0xb90cb7){const _0x43dfa0=a11_0x44fafd;config[_0x43dfa0(0x1bb)](_0x43dfa0(0x1b9),_0x48a269),config['set'](_0x43dfa0(0x1c6),encrypt(_0x58881f)),config[_0x43dfa0(0x1bb)](_0x43dfa0(0x1be),_0x48a269),config[_0x43dfa0(0x1bb)](_0x43dfa0(0x1d7),encrypt(_0x58881f));if(_0x30e518)config[_0x43dfa0(0x1bb)](_0x43dfa0(0x1c3),_0x30e518);}export function getConfig(){const _0x38f23c=a11_0x44fafd;return{'imap':{'user':config[_0x38f23c(0x1cb)](_0x38f23c(0x1b9)),'password':decrypt(config[_0x38f23c(0x1cb)]('imapPass')),'host':config['get'](_0x38f23c(0x1c3)),'port':config[_0x38f23c(0x1cb)]('imapPort'),'tls':!![],'tlsOptions':{'rejectUnauthorized':![]},'authTimeout':0xbb8},'smtp':{'host':config['get']('smtpHost'),'port':config['get'](_0x38f23c(0x1d5)),'auth':{'user':config[_0x38f23c(0x1cb)](_0x38f23c(0x1be)),'pass':decrypt(config[_0x38f23c(0x1cb)](_0x38f23c(0x1d7)))},'tls':{'rejectUnauthorized':![]}},'interval':config[_0x38f23c(0x1cb)](_0x38f23c(0x1d6)),'allowedSenders':config[_0x38f23c(0x1cb)](_0x38f23c(0x1c8))||[],'enabled':config['get'](_0x38f23c(0x1c0))};}export function isConfigured(){const _0x1a7ef7=a11_0x44fafd,_0xfe615d=getConfig();return!!_0xfe615d['imap']['user']&&!!_0xfe615d[_0x1a7ef7(0x1b8)][_0x1a7ef7(0x1bf)];}export function setEnabled(_0x4dfce5){const _0x51a524=a11_0x44fafd;config['set'](_0x51a524(0x1c0),_0x4dfce5);}export function addAllowedSender(_0x1ff923){const _0x16019e=a11_0x44fafd,_0xbc138d=config[_0x16019e(0x1cb)](_0x16019e(0x1c8))||[];!_0xbc138d[_0x16019e(0x1bd)](_0x1ff923)&&(_0xbc138d['push'](_0x1ff923),config[_0x16019e(0x1bb)](_0x16019e(0x1c8),_0xbc138d));}
1
+ const a11_0x68cf55=a11_0x42bb;(function(_0x59f177,_0x3e1686){const _0x430fc1=a11_0x42bb,_0x5ea2ad=_0x59f177();while(!![]){try{const _0x15b8e7=parseInt(_0x430fc1(0x12a))/0x1*(-parseInt(_0x430fc1(0x122))/0x2)+parseInt(_0x430fc1(0x129))/0x3*(parseInt(_0x430fc1(0x139))/0x4)+-parseInt(_0x430fc1(0x121))/0x5+-parseInt(_0x430fc1(0x138))/0x6+parseInt(_0x430fc1(0x13f))/0x7*(-parseInt(_0x430fc1(0x133))/0x8)+parseInt(_0x430fc1(0x13b))/0x9*(parseInt(_0x430fc1(0x11d))/0xa)+parseInt(_0x430fc1(0x119))/0xb;if(_0x15b8e7===_0x3e1686)break;else _0x5ea2ad['push'](_0x5ea2ad['shift']());}catch(_0x27ca10){_0x5ea2ad['push'](_0x5ea2ad['shift']());}}}(a11_0x1a44,0x2b2c0));import a11_0x32a9a8 from'conf';import a11_0x58af8f from'crypto';const config=new a11_0x32a9a8({'projectName':a11_0x68cf55(0x13a),'defaults':{'imapHost':a11_0x68cf55(0x124),'imapPort':0x3e1,'imapUser':'','imapPass':'','smtpHost':a11_0x68cf55(0x12c),'smtpPort':0x24b,'smtpUser':'','smtpPass':'','checkInterval':0x5,'allowedSenders':[],'enabled':![]}}),ENCRYPTION_KEY=a11_0x68cf55(0x118);function a11_0x1a44(){const _0xa1160e=['2948XuzPki','woozlit-cli-email','9lBFNxL','imapHost','final','password','1010037sYmpcu','get','split','toString','allowedSenders','woozlit_email_secure_key','2597199kGlGXY','createDecipheriv','smtpHost','createHash','3386790bDHxld','sha256','imap','aes-256-cbc','102010fmBokI','262sXDTXx','enabled','imap.gmail.com','createCipheriv','smtpPass','utf8','randomBytes','1167rAUvgR','1783JuZWrP','smtpUser','smtp.gmail.com','checkInterval','digest','set','update','imapUser','push','16RUMvtH','hex','smtpPort','imapPass','user','852552tzpYWC'];a11_0x1a44=function(){return _0xa1160e;};return a11_0x1a44();}function encrypt(_0x1b69c5){const _0x21d581=a11_0x68cf55;if(!_0x1b69c5)return'';const _0x9f48b7=a11_0x58af8f[_0x21d581(0x128)](0x10),_0x555508=a11_0x58af8f['createHash'](_0x21d581(0x11e))[_0x21d581(0x130)](ENCRYPTION_KEY)[_0x21d581(0x12e)](),_0x3673b3=a11_0x58af8f[_0x21d581(0x125)]('aes-256-cbc',_0x555508,_0x9f48b7);let _0x4d82f2=_0x3673b3['update'](_0x1b69c5,_0x21d581(0x127),_0x21d581(0x134));return _0x4d82f2+=_0x3673b3[_0x21d581(0x13d)](_0x21d581(0x134)),_0x9f48b7[_0x21d581(0x116)]('hex')+':'+_0x4d82f2;}function decrypt(_0xcfb5c0){const _0x38de8e=a11_0x68cf55;if(!_0xcfb5c0)return'';try{const [_0xdb118,_0x402471]=_0xcfb5c0[_0x38de8e(0x115)](':');if(!_0xdb118||!_0x402471)return'';const _0x3f4911=Buffer['from'](_0xdb118,'hex'),_0x3ee459=a11_0x58af8f[_0x38de8e(0x11c)]('sha256')[_0x38de8e(0x130)](ENCRYPTION_KEY)[_0x38de8e(0x12e)](),_0x3d76c5=a11_0x58af8f[_0x38de8e(0x11a)](_0x38de8e(0x120),_0x3ee459,_0x3f4911);let _0x217391=_0x3d76c5['update'](_0x402471,_0x38de8e(0x134),'utf8');return _0x217391+=_0x3d76c5[_0x38de8e(0x13d)](_0x38de8e(0x127)),_0x217391;}catch{return'';}}export function setCredentials(_0x22f5b1,_0xce33e3,_0x1b40da,_0x3c019c){const _0x55bec4=a11_0x68cf55;config['set'](_0x55bec4(0x131),_0x22f5b1),config[_0x55bec4(0x12f)]('imapPass',encrypt(_0xce33e3)),config[_0x55bec4(0x12f)](_0x55bec4(0x12b),_0x22f5b1),config['set'](_0x55bec4(0x126),encrypt(_0xce33e3));if(_0x1b40da)config[_0x55bec4(0x12f)](_0x55bec4(0x13c),_0x1b40da);}export function getConfig(){const _0x3232ff=a11_0x68cf55;return{'imap':{'user':config[_0x3232ff(0x114)]('imapUser'),'password':decrypt(config[_0x3232ff(0x114)](_0x3232ff(0x136))),'host':config[_0x3232ff(0x114)]('imapHost'),'port':config[_0x3232ff(0x114)]('imapPort'),'tls':!![],'tlsOptions':{'rejectUnauthorized':![]},'authTimeout':0xbb8},'smtp':{'host':config[_0x3232ff(0x114)](_0x3232ff(0x11b)),'port':config[_0x3232ff(0x114)](_0x3232ff(0x135)),'auth':{'user':config[_0x3232ff(0x114)](_0x3232ff(0x12b)),'pass':decrypt(config[_0x3232ff(0x114)](_0x3232ff(0x126)))},'tls':{'rejectUnauthorized':![]}},'interval':config['get'](_0x3232ff(0x12d)),'allowedSenders':config[_0x3232ff(0x114)](_0x3232ff(0x117))||[],'enabled':config['get'](_0x3232ff(0x123))};}export function isConfigured(){const _0x3881b6=a11_0x68cf55,_0x5b172d=getConfig();return!!_0x5b172d[_0x3881b6(0x11f)][_0x3881b6(0x137)]&&!!_0x5b172d['imap'][_0x3881b6(0x13e)];}function a11_0x42bb(_0x3cf34c,_0x41c2f1){_0x3cf34c=_0x3cf34c-0x114;const _0x1a44b4=a11_0x1a44();let _0x42bb57=_0x1a44b4[_0x3cf34c];return _0x42bb57;}export function setEnabled(_0x1fed38){const _0x230eb6=a11_0x68cf55;config[_0x230eb6(0x12f)](_0x230eb6(0x123),_0x1fed38);}export function addAllowedSender(_0x5ad594){const _0x5193c7=a11_0x68cf55,_0x472d8f=config[_0x5193c7(0x114)](_0x5193c7(0x117))||[];!_0x472d8f['includes'](_0x5ad594)&&(_0x472d8f[_0x5193c7(0x132)](_0x5ad594),config[_0x5193c7(0x12f)](_0x5193c7(0x117),_0x472d8f));}
@@ -1 +1 @@
1
- function a12_0x847b(){var _0x31c780=['7569xOIpCF','812796xlHGus','1095MhQplS','99WHKhkQ','64kMPwKg','35wNmajn','40637NbMHNp','50ugTBIx','10870OnPEcU','715044NXYBFN','49228166HyVnRP','5272fqGiBY','363797QJoMAX'];a12_0x847b=function(){return _0x31c780;};return a12_0x847b();}(function(_0x3eaa5e,_0x2433f3){var _0x3761a5=a12_0x27f4,_0x4a9295=_0x3eaa5e();while(!![]){try{var _0x18275d=-parseInt(_0x3761a5(0xf1))/0x1*(-parseInt(_0x3761a5(0xf2))/0x2)+-parseInt(_0x3761a5(0xed))/0x3*(-parseInt(_0x3761a5(0xe9))/0x4)+-parseInt(_0x3761a5(0xf0))/0x5*(-parseInt(_0x3761a5(0xec))/0x6)+-parseInt(_0x3761a5(0xea))/0x7*(-parseInt(_0x3761a5(0xef))/0x8)+parseInt(_0x3761a5(0xeb))/0x9*(parseInt(_0x3761a5(0xf3))/0xa)+parseInt(_0x3761a5(0xee))/0xb*(parseInt(_0x3761a5(0xf4))/0xc)+-parseInt(_0x3761a5(0xf5))/0xd;if(_0x18275d===_0x2433f3)break;else _0x4a9295['push'](_0x4a9295['shift']());}catch(_0x3a8822){_0x4a9295['push'](_0x4a9295['shift']());}}}(a12_0x847b,0x80195));export*from'./config.js';function a12_0x27f4(_0x56e2a7,_0x1fd990){_0x56e2a7=_0x56e2a7-0xe9;var _0x847bde=a12_0x847b();var _0x27f4a6=_0x847bde[_0x56e2a7];return _0x27f4a6;}export{startBot,stopBot,isBotRunning}from'./service.js';export{setupEmail}from'./setup.js';
1
+ (function(_0x1becfb,_0xbb72fe){var _0x3987a5=a12_0x5889,_0x49acb6=_0x1becfb();while(!![]){try{var _0x45bf32=parseInt(_0x3987a5(0x71))/0x1+parseInt(_0x3987a5(0x6f))/0x2*(-parseInt(_0x3987a5(0x6c))/0x3)+parseInt(_0x3987a5(0x72))/0x4+-parseInt(_0x3987a5(0x74))/0x5+parseInt(_0x3987a5(0x73))/0x6+parseInt(_0x3987a5(0x6e))/0x7*(-parseInt(_0x3987a5(0x70))/0x8)+-parseInt(_0x3987a5(0x6d))/0x9;if(_0x45bf32===_0xbb72fe)break;else _0x49acb6['push'](_0x49acb6['shift']());}catch(_0x52604f){_0x49acb6['push'](_0x49acb6['shift']());}}}(a12_0x1d04,0x64a4b));export*from'./config.js';export{startBot,stopBot,isBotRunning}from'./service.js';function a12_0x1d04(){var _0x1eb16f=['1466635SQlUCE','1663767mzQywz','5953248twtNpj','91693YUeZQZ','2taXKMo','104hoTnOG','698852ckZDLt','2781996MUGfrH','4185354jiBjyJ'];a12_0x1d04=function(){return _0x1eb16f;};return a12_0x1d04();}function a12_0x5889(_0xd3379b,_0x23d998){_0xd3379b=_0xd3379b-0x6c;var _0x1d0478=a12_0x1d04();var _0x588963=_0x1d0478[_0xd3379b];return _0x588963;}export{setupEmail}from'./setup.js';
@@ -1 +1 @@
1
- (function(_0x1affcf,_0x2016b0){const _0x46f4d7=a13_0x5d30,_0x28bc95=_0x1affcf();while(!![]){try{const _0x177120=parseInt(_0x46f4d7(0xaa))/0x1+-parseInt(_0x46f4d7(0xbf))/0x2*(parseInt(_0x46f4d7(0xbe))/0x3)+-parseInt(_0x46f4d7(0xd4))/0x4*(-parseInt(_0x46f4d7(0xa4))/0x5)+-parseInt(_0x46f4d7(0xb9))/0x6*(-parseInt(_0x46f4d7(0xaf))/0x7)+-parseInt(_0x46f4d7(0xc0))/0x8+-parseInt(_0x46f4d7(0xb7))/0x9*(-parseInt(_0x46f4d7(0xc1))/0xa)+parseInt(_0x46f4d7(0xab))/0xb*(parseInt(_0x46f4d7(0xb2))/0xc);if(_0x177120===_0x2016b0)break;else _0x28bc95['push'](_0x28bc95['shift']());}catch(_0x444b17){_0x28bc95['push'](_0x28bc95['shift']());}}}(a13_0x45aa,0xdd815));import a13_0x44459c from'imap-simple';import a13_0x11b6c0 from'nodemailer';import*as a13_0x2990a1 from'./config.js';import*as a13_0x3cb852 from'../ui/output.js';import{getSelectedModel}from'../utils/storage.js';import{sendChatMessage}from'../utils/api.js';let intervalId=null,isRunning=![];async function checkEmails(){const _0x137583=a13_0x5d30,_0xe78ec1=a13_0x2990a1[_0x137583(0xd3)]();try{const _0x33972c=await a13_0x44459c[_0x137583(0xba)]({'imap':_0xe78ec1[_0x137583(0xbb)]});await _0x33972c[_0x137583(0xbc)](_0x137583(0xb3));const _0x3a20d8=[_0x137583(0xd0)],_0x5cc10c={'bodies':['HEADER','TEXT'],'markSeen':!![]},_0x24acf4=await _0x33972c['search'](_0x3a20d8,_0x5cc10c);_0x24acf4[_0x137583(0xb0)]>0x0&&a13_0x3cb852['info'](_0x137583(0xbd)+_0x24acf4[_0x137583(0xb0)]+_0x137583(0xad));for(const _0x1e6a87 of _0x24acf4){const _0x2eb822=_0x1e6a87[_0x137583(0xcb)]['find'](_0xa7084c=>_0xa7084c['which']==='HEADER'),_0x3a086f=_0x2eb822[_0x137583(0xcf)]['from']?.[0x0]||'',_0x451eb4=_0x2eb822['body'][_0x137583(0xa6)]?.[0x0]||_0x137583(0xca);if(_0xe78ec1[_0x137583(0xc5)][_0x137583(0xb0)]>0x0){const _0x2b4fa5=_0x3a086f[_0x137583(0xc3)](/<(.+)>/)?.[0x1]||_0x3a086f;if(!_0xe78ec1[_0x137583(0xc5)][_0x137583(0xc4)](_0x2b4fa5)){a13_0x3cb852[_0x137583(0xb1)](_0x137583(0xd1)+_0x3a086f+_0x137583(0xcd));continue;}}const _0x328eb4=_0x1e6a87[_0x137583(0xcb)]['find'](_0x35a9ab=>_0x35a9ab['which']===_0x137583(0xa8)),_0x37f5e4=_0x328eb4?.[_0x137583(0xcf)]||'';a13_0x3cb852[_0x137583(0xc8)]('[Email]\x20From:\x20'+_0x3a086f+_0x137583(0xb4)+_0x451eb4);try{const _0x83296c=_0x137583(0xae)+_0x3a086f+_0x137583(0xb5)+_0x451eb4+_0x137583(0xac)+_0x37f5e4+'\x0a\x0aDraft\x20a\x20helpful\x20reply.\x20Structure\x20it\x20clearly.',_0x68c34e=await sendChatMessage(getSelectedModel(),[{'role':_0x137583(0xa5),'content':_0x83296c}]),_0x217fec=a13_0x11b6c0['createTransport'](_0xe78ec1[_0x137583(0xb8)]);await _0x217fec[_0x137583(0xd2)]({'from':_0xe78ec1[_0x137583(0xb8)]['auth'][_0x137583(0xa5)],'to':_0x3a086f,'subject':_0x137583(0xc6)+_0x451eb4,'text':_0x68c34e[_0x137583(0xc7)]}),a13_0x3cb852['success'](_0x137583(0xc2)+_0x3a086f);}catch(_0x160104){a13_0x3cb852[_0x137583(0xd5)](_0x137583(0xb6)+_0x160104['message']);}}_0x33972c[_0x137583(0xc9)]();}catch(_0x167b58){}}export async function startBot(){const _0x1679ba=a13_0x5d30;if(!a13_0x2990a1[_0x1679ba(0xcc)]())return![];if(isRunning)return!![];process[_0x1679ba(0xa7)][_0x1679ba(0xa9)]='0',checkEmails();const _0x133d05=a13_0x2990a1[_0x1679ba(0xd3)]()[_0x1679ba(0xce)]||0x5;return intervalId=setInterval(checkEmails,_0x133d05*0x3c*0x3e8),isRunning=!![],!![];}export function stopBot(){intervalId&&(clearInterval(intervalId),intervalId=null),isRunning=![];}export function isBotRunning(){return isRunning;}function a13_0x45aa(){const _0x2f18e6=['1884xnHOzn','error','3735pBMDWQ','user','subject','env','TEXT','NODE_TLS_REJECT_UNAUTHORIZED','237211gWSkAz','302599oFapaq','\x0aBody:\x0a','\x20new\x20messages','You\x20received\x20an\x20email\x20from\x20','7SPiLix','length','dim','1272YZhrwH','INBOX','\x20|\x20Subj:\x20',':\x0aSubject:\x20','[Email]\x20Processing/Reply\x20error:\x20','198mUUAjP','smtp','418890CMiVLk','connect','imap','openBox','[Email]\x20Found\x20','385158wOIOFX','28trovTB','13121552PwqiDa','350030SXrwZp','[Email]\x20Reply\x20sent\x20to\x20','match','includes','allowedSenders','Re:\x20','content','info','end','No\x20Subject','parts','isConfigured','\x20(not\x20allowed)','interval','body','UNSEEN','[Email]\x20Ignored\x20mail\x20from\x20','sendMail','getConfig'];a13_0x45aa=function(){return _0x2f18e6;};return a13_0x45aa();}function a13_0x5d30(_0x338510,_0x22329c){_0x338510=_0x338510-0xa4;const _0x45aaaf=a13_0x45aa();let _0x5d301e=_0x45aaaf[_0x338510];return _0x5d301e;}export{isConfigured}from'./config.js';
1
+ (function(_0x25d919,_0x40f1ae){const _0x45dfdb=a13_0x4fe0,_0x31f630=_0x25d919();while(!![]){try{const _0x1e490b=parseInt(_0x45dfdb(0xea))/0x1*(parseInt(_0x45dfdb(0xd2))/0x2)+parseInt(_0x45dfdb(0xd8))/0x3*(parseInt(_0x45dfdb(0xf8))/0x4)+parseInt(_0x45dfdb(0xde))/0x5*(-parseInt(_0x45dfdb(0xec))/0x6)+parseInt(_0x45dfdb(0xf4))/0x7*(parseInt(_0x45dfdb(0xe7))/0x8)+parseInt(_0x45dfdb(0xe3))/0x9*(-parseInt(_0x45dfdb(0xcf))/0xa)+-parseInt(_0x45dfdb(0xdb))/0xb+parseInt(_0x45dfdb(0xf3))/0xc;if(_0x1e490b===_0x40f1ae)break;else _0x31f630['push'](_0x31f630['shift']());}catch(_0x2fc111){_0x31f630['push'](_0x31f630['shift']());}}}(a13_0x95ee,0x7be9b));import a13_0x422b1d from'imap-simple';import a13_0x53cada from'nodemailer';import*as a13_0x2f907d from'./config.js';import*as a13_0x10fc8d from'../ui/output.js';function a13_0x4fe0(_0xb1aa01,_0x2e4702){_0xb1aa01=_0xb1aa01-0xc9;const _0x95eee6=a13_0x95ee();let _0x4fe00b=_0x95eee6[_0xb1aa01];return _0x4fe00b;}import{getSelectedModel}from'../utils/storage.js';import{sendChatMessage}from'../utils/api.js';let intervalId=null,isRunning=![];async function checkEmails(){const _0xa9fadd=a13_0x4fe0,_0x19f10a=a13_0x2f907d[_0xa9fadd(0xd4)]();try{const _0x35ba83=await a13_0x422b1d[_0xa9fadd(0xf2)]({'imap':_0x19f10a['imap']});await _0x35ba83[_0xa9fadd(0xd3)](_0xa9fadd(0xf6));const _0x406a85=['UNSEEN'],_0x2bbbf={'bodies':[_0xa9fadd(0xe0),'TEXT'],'markSeen':!![]},_0x69f897=await _0x35ba83[_0xa9fadd(0xf5)](_0x406a85,_0x2bbbf);_0x69f897[_0xa9fadd(0xd0)]>0x0&&a13_0x10fc8d['info'](_0xa9fadd(0xd7)+_0x69f897[_0xa9fadd(0xd0)]+_0xa9fadd(0xcb));for(const _0x29d1cb of _0x69f897){const _0x2be361=_0x29d1cb[_0xa9fadd(0xdf)]['find'](_0x2a4286=>_0x2a4286[_0xa9fadd(0xe1)]===_0xa9fadd(0xe0)),_0x2026c4=_0x2be361['body'][_0xa9fadd(0xe5)]?.[0x0]||'',_0x564ec5=_0x2be361[_0xa9fadd(0xd9)][_0xa9fadd(0xd6)]?.[0x0]||_0xa9fadd(0xf1);if(_0x19f10a['allowedSenders'][_0xa9fadd(0xd0)]>0x0){const _0x24c709=_0x2026c4['match'](/<(.+)>/)?.[0x1]||_0x2026c4;if(!_0x19f10a['allowedSenders'][_0xa9fadd(0xee)](_0x24c709)){a13_0x10fc8d[_0xa9fadd(0xe4)](_0xa9fadd(0xe8)+_0x2026c4+_0xa9fadd(0xe9));continue;}}const _0x30fc50=_0x29d1cb[_0xa9fadd(0xdf)][_0xa9fadd(0xdd)](_0x5aaa88=>_0x5aaa88[_0xa9fadd(0xe1)]===_0xa9fadd(0xd5)),_0x238e4b=_0x30fc50?.[_0xa9fadd(0xd9)]||'';a13_0x10fc8d[_0xa9fadd(0xc9)]('[Email]\x20From:\x20'+_0x2026c4+_0xa9fadd(0xcc)+_0x564ec5);try{const _0xfecf70=_0xa9fadd(0xfa)+_0x2026c4+':\x0aSubject:\x20'+_0x564ec5+_0xa9fadd(0xdc)+_0x238e4b+_0xa9fadd(0xed),_0x24ba3e=await sendChatMessage(getSelectedModel(),[{'role':_0xa9fadd(0xf7),'content':_0xfecf70}]),_0x1b3968=a13_0x53cada[_0xa9fadd(0xf9)](_0x19f10a[_0xa9fadd(0xca)]);await _0x1b3968[_0xa9fadd(0xda)]({'from':_0x19f10a[_0xa9fadd(0xca)]['auth']['user'],'to':_0x2026c4,'subject':'Re:\x20'+_0x564ec5,'text':_0x24ba3e[_0xa9fadd(0xd1)]}),a13_0x10fc8d[_0xa9fadd(0xe6)](_0xa9fadd(0xeb)+_0x2026c4);}catch(_0xc52648){a13_0x10fc8d[_0xa9fadd(0xcd)]('[Email]\x20Processing/Reply\x20error:\x20'+_0xc52648[_0xa9fadd(0xe2)]);}}_0x35ba83[_0xa9fadd(0xce)]();}catch(_0x2e42ff){}}export async function startBot(){const _0x394717=a13_0x4fe0;if(!a13_0x2f907d['isConfigured']())return![];if(isRunning)return!![];process[_0x394717(0xef)]['NODE_TLS_REJECT_UNAUTHORIZED']='0',checkEmails();const _0x57bc99=a13_0x2f907d[_0x394717(0xd4)]()[_0x394717(0xf0)]||0x5;return intervalId=setInterval(checkEmails,_0x57bc99*0x3c*0x3e8),isRunning=!![],!![];}function a13_0x95ee(){const _0x2c7384=['info','smtp','\x20new\x20messages','\x20|\x20Subj:\x20','error','end','4282820DzXjxB','length','content','32762pzWTxF','openBox','getConfig','TEXT','subject','[Email]\x20Found\x20','18eoRqyG','body','sendMail','2632927Zsivsg','\x0aBody:\x0a','find','1729955kEMNlb','parts','HEADER','which','message','9DwmcQI','dim','from','success','16hsoETF','[Email]\x20Ignored\x20mail\x20from\x20','\x20(not\x20allowed)','1BGIQpd','[Email]\x20Reply\x20sent\x20to\x20','12eYVuvI','\x0a\x0aDraft\x20a\x20helpful\x20reply.\x20Structure\x20it\x20clearly.','includes','env','interval','No\x20Subject','connect','3229428sVMdTv','2580214oNgsGE','search','INBOX','user','562976dftpHK','createTransport','You\x20received\x20an\x20email\x20from\x20'];a13_0x95ee=function(){return _0x2c7384;};return a13_0x95ee();}export function stopBot(){intervalId&&(clearInterval(intervalId),intervalId=null),isRunning=![];}export function isBotRunning(){return isRunning;}export{isConfigured}from'./config.js';