@nuvin/agent-core 0.2.0-rc.12 → 0.2.0-rc.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- (function(_0xc60831,_0xd2af0e){var _0x4a2b28={_0x752bc4:0x498,_0x360fca:0x4a4,_0x33afa2:0x49d,_0x50f212:0x49d,_0x5b6e48:0x49c,_0x12fa33:0x49b,_0x1921a4:0x395,_0x2a1719:0x39a,_0x2689cb:0x393,_0x56a15d:0x38e,_0x1d0c51:0x388,_0x1c094d:0x399,_0x4d879e:0x396,_0x3031c2:0x397,_0x540cb2:0x384,_0x33ecbe:0x38a,_0x3a637a:0x49a,_0x1e1e4f:0x49a,_0x516ea0:0x497,_0x14732f:0x39a,_0x2523b9:0x384,_0x39a1b3:0x389};function _0x35322d(_0x19e617,_0x130e24,_0x1bcac2,_0xe83c7f){return _0x4a6f(_0x130e24-0x2af,_0x19e617);}var _0x409a80=_0xc60831();function _0x1265ed(_0x3c1999,_0x14d88b,_0x6b47d9,_0x186be6){return _0x4a6f(_0x186be6-0x3bb,_0x6b47d9);}while(!![]){try{var _0x2f7961=-parseInt(_0x1265ed(0x49a,0x49f,_0x4a2b28._0x752bc4,0x498))/0x1*(parseInt(_0x1265ed(_0x4a2b28._0x360fca,_0x4a2b28._0x33afa2,0x498,_0x4a2b28._0x33afa2))/0x2)+parseInt(_0x1265ed(0x4a2,_0x4a2b28._0x50f212,_0x4a2b28._0x5b6e48,0x49e))/0x3*(-parseInt(_0x1265ed(0x49b,_0x4a2b28._0x12fa33,0x499,0x497))/0x4)+-parseInt(_0x35322d(0x391,_0x4a2b28._0x1921a4,_0x4a2b28._0x2a1719,_0x4a2b28._0x2689cb))/0x5*(-parseInt(_0x35322d(_0x4a2b28._0x56a15d,_0x4a2b28._0x1d0c51,0x390,0x38b))/0x6)+parseInt(_0x35322d(_0x4a2b28._0x1c094d,_0x4a2b28._0x4d879e,_0x4a2b28._0x3031c2,_0x4a2b28._0x2a1719))/0x7*(-parseInt(_0x35322d(_0x4a2b28._0x540cb2,_0x4a2b28._0x33ecbe,0x386,0x383))/0x8)+parseInt(_0x1265ed(_0x4a2b28._0x3a637a,0x499,0x49d,_0x4a2b28._0x1e1e4f))/0x9*(parseInt(_0x1265ed(0x4a0,_0x4a2b28._0x516ea0,0x493,0x499))/0xa)+-parseInt(_0x35322d(0x398,0x394,_0x4a2b28._0x14732f,0x39a))/0xb+parseInt(_0x35322d(_0x4a2b28._0x2523b9,_0x4a2b28._0x39a1b3,0x382,0x387))/0xc;if(_0x2f7961===_0xd2af0e)break;else _0x409a80['push'](_0x409a80['shift']());}catch(_0x2c30c5){_0x409a80['push'](_0x409a80['shift']());}}}(_0x3642,0x1d41e));function resolveAnthropicReasoningConfig(_0x204667){var _0x3be1de={_0x4d7721:0x10d,_0x27ac24:0x106};function _0x4b7224(_0x49872e,_0x3ea0bf,_0x1ad587,_0x112eac){return _0x4a6f(_0x1ad587- -0x1e6,_0x112eac);}return _0x204667?.[_0x4b7224(-_0x3be1de._0x4d7721,-0x109,-_0x3be1de._0x27ac24,-0x105)]?structuredClone(_0x204667['anthropic']):void 0x0;}function resolveOpenAiReasoningConfig(_0x1ea9ad){var _0x42a5d9={_0x5b1875:0xa0,_0x18a02d:0xa8,_0x438639:0xa1,_0x251dee:0x159,_0x3a4375:0x160,_0x1597ee:0x9e,_0x521bb4:0xa4,_0x2dfb52:0xa4},_0x2eec88={_0x5f4fa9:0x40},_0x2b53ff={_0x55de01:0x7f};function _0x173917(_0x48a4fb,_0x284d54,_0x552ea3,_0x6b43bc){return _0x4a6f(_0x284d54-_0x2b53ff._0x55de01,_0x48a4fb);}if(_0x1ea9ad?.[_0x23f055(_0x42a5d9._0x5b1875,0x9b,_0x42a5d9._0x18a02d,_0x42a5d9._0x438639)])return structuredClone(_0x1ea9ad[_0x173917(_0x42a5d9._0x251dee,_0x42a5d9._0x3a4375,0x160,0x165)]);function _0x23f055(_0x253cc6,_0x420113,_0x20564f,_0x2bca26){return _0x4a6f(_0x2bca26- -_0x2eec88._0x5f4fa9,_0x20564f);}return _0x1ea9ad?.[_0x23f055(0xa2,_0x42a5d9._0x1597ee,_0x42a5d9._0x521bb4,_0x42a5d9._0x2dfb52)]?structuredClone(_0x1ea9ad['openai']):void 0x0;}export{resolveAnthropicReasoningConfig,resolveOpenAiReasoningConfig};function _0x4a6f(_0x4088e4,_0x3175f1){_0x4088e4=_0x4088e4-0xd9;var _0x3642bd=_0x3642();var _0x4a6fc5=_0x3642bd[_0x4088e4];if(_0x4a6f['LWTNVc']===undefined){var _0x40bdf7=function(_0x9088fd){var _0x2508f1='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var _0x204667='',_0x1ea9ad='';for(var _0x21c885=0x0,_0x20fd45,_0xfd87e7,_0x560ba6=0x0;_0xfd87e7=_0x9088fd['charAt'](_0x560ba6++);~_0xfd87e7&&(_0x20fd45=_0x21c885%0x4?_0x20fd45*0x40+_0xfd87e7:_0xfd87e7,_0x21c885++%0x4)?_0x204667+=String['fromCharCode'](0xff&_0x20fd45>>(-0x2*_0x21c885&0x6)):0x0){_0xfd87e7=_0x2508f1['indexOf'](_0xfd87e7);}for(var _0x3ef801=0x0,_0x533f52=_0x204667['length'];_0x3ef801<_0x533f52;_0x3ef801++){_0x1ea9ad+='%'+('00'+_0x204667['charCodeAt'](_0x3ef801)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x1ea9ad);};_0x4a6f['ZEtDKp']=_0x40bdf7,_0x4a6f['PKQBwy']={},_0x4a6f['LWTNVc']=!![];}var _0x312960=_0x3642bd[0x0],_0x2e942e=_0x4088e4+_0x312960,_0x3617b4=_0x4a6f['PKQBwy'][_0x2e942e];return!_0x3617b4?(_0x4a6fc5=_0x4a6f['ZEtDKp'](_0x4a6fc5),_0x4a6f['PKQBwy'][_0x2e942e]=_0x4a6fc5):_0x4a6fc5=_0x3617b4,_0x4a6fc5;}function _0x3642(){var _0x3cae47=['mZHHre5wrfC','mtvXDLPltxq','B3bLBMfP','mtu5mtC2nNr3CeDrBa','mtiWDNDlA3fA','mtuZotu4n2fOz01eAW','ndGYmdrbBMPAreq','nde2mJu2mfHSuMPHCq','oeLItNP3tW','mti4mdu2qKLhuKfW','mZG4ovLTEMDlwq','mJG2meDpvvnxqG','ntyYnwfOy3PoDG','yw50AhjVCgLJ','y29KzxG'];_0x3642=function(){return _0x3cae47;};return _0x3642();}
1
+ (function(_0x2b2484,_0x56ab98){var _0x58dfb5={_0x2372fd:0x228,_0x416331:0x222,_0x5aa8d4:0xb7,_0x2bd3b1:0xb7,_0x22c21d:0xb9,_0x2c6e90:0x229,_0x55f4dd:0x22b,_0x1f5946:0xb2,_0x1367dc:0x226,_0x4bfec0:0x22f,_0x26f428:0x226,_0x5c9172:0xb0,_0x1ae307:0xb4},_0x5b43e4={_0x516322:0x14e};function _0x4adc8f(_0x9b37a8,_0xa69c52,_0x3bc0bf,_0x19f3c6){return _0x5c2b(_0x3bc0bf-_0x5b43e4._0x516322,_0x9b37a8);}var _0x793fad=_0x2b2484();function _0x3a2029(_0x34c7d1,_0x3145c6,_0x4e79d0,_0x109acc){return _0x5c2b(_0x34c7d1- -0x20,_0x3145c6);}while(!![]){try{var _0x20134b=-parseInt(_0x4adc8f(_0x58dfb5._0x2372fd,_0x58dfb5._0x416331,0x227,0x225))/0x1*(parseInt(_0x3a2029(_0x58dfb5._0x5aa8d4,_0x58dfb5._0x2bd3b1,0xbe,_0x58dfb5._0x22c21d))/0x2)+parseInt(_0x4adc8f(_0x58dfb5._0x2c6e90,_0x58dfb5._0x55f4dd,0x22c,0x232))/0x3+-parseInt(_0x3a2029(0xb3,0xb0,0xba,0xb4))/0x4*(parseInt(_0x4adc8f(0x225,0x226,0x22b,0x226))/0x5)+-parseInt(_0x3a2029(0xb4,0xb3,_0x58dfb5._0x1f5946,0xb9))/0x6+parseInt(_0x4adc8f(_0x58dfb5._0x1367dc,0x223,0x228,_0x58dfb5._0x4bfec0))/0x7+parseInt(_0x4adc8f(0x22d,0x22c,0x226,0x224))/0x8*(parseInt(_0x4adc8f(_0x58dfb5._0x55f4dd,_0x58dfb5._0x26f428,0x229,0x228))/0x9)+-parseInt(_0x3a2029(0xb5,_0x58dfb5._0x5c9172,_0x58dfb5._0x1ae307,0xb7))/0xa;if(_0x20134b===_0x56ab98)break;else _0x793fad['push'](_0x793fad['shift']());}catch(_0x33af6a){_0x793fad['push'](_0x793fad['shift']());}}}(_0x2b9a,0x92787));function _0x2b9a(){var _0x57d223=['y29KzxG','mte1nduXnxrou0TpzW','mJi3nty3nhPZAKjAuG','yw50AhjVCgLJ','nfb6C0HeAa','nZa0nZK2yMTtshPY','ntK4mdeYmeXSDKP2ua','B3bLBMfP','nfvfv0npza','mJi5mti4vvbHAeHX','nde5odC4sMPvCM5u','nZK4ndm3nxryyuvJAG','mtuZtw1YA0vm'];_0x2b9a=function(){return _0x57d223;};return _0x2b9a();}function resolveAnthropicReasoningConfig(_0x5acd2){var _0x3e503a={_0x5067cc:0x365,_0x1134a1:0x36e,_0x1ec31c:0x36c,_0x1c8cd7:0x36b,_0x14312d:0x373},_0x5bf8fa={_0x2d63fb:0x1e1};function _0x2640de(_0x2cf8fd,_0xa4c7ea,_0x41961d,_0x1cf97d){return _0x5c2b(_0x41961d-_0x5bf8fa._0x2d63fb,_0x1cf97d);}function _0x5b42eb(_0xe498e9,_0x9c4c2b,_0x3fb829,_0x3bb7e2){return _0x5c2b(_0x9c4c2b-0x28d,_0x3bb7e2);}return _0x5acd2?.[_0x5b42eb(0x369,0x36c,_0x3e503a._0x5067cc,_0x3e503a._0x5067cc)]?structuredClone(_0x5acd2[_0x5b42eb(_0x3e503a._0x1134a1,_0x3e503a._0x1ec31c,_0x3e503a._0x1c8cd7,_0x3e503a._0x14312d)]):void 0x0;}function _0x5c2b(_0x479482,_0x4b62bf){_0x479482=_0x479482-0xd3;var _0x2b9a48=_0x2b9a();var _0x5c2b02=_0x2b9a48[_0x479482];if(_0x5c2b['IszTuS']===undefined){var _0x348524=function(_0x7fdbea){var _0x27175c='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var _0x5acd2='',_0x49e552='';for(var _0x34fae5=0x0,_0xe51db3,_0x4dd4a9,_0x268364=0x0;_0x4dd4a9=_0x7fdbea['charAt'](_0x268364++);~_0x4dd4a9&&(_0xe51db3=_0x34fae5%0x4?_0xe51db3*0x40+_0x4dd4a9:_0x4dd4a9,_0x34fae5++%0x4)?_0x5acd2+=String['fromCharCode'](0xff&_0xe51db3>>(-0x2*_0x34fae5&0x6)):0x0){_0x4dd4a9=_0x27175c['indexOf'](_0x4dd4a9);}for(var _0x2b0554=0x0,_0x5d033b=_0x5acd2['length'];_0x2b0554<_0x5d033b;_0x2b0554++){_0x49e552+='%'+('00'+_0x5acd2['charCodeAt'](_0x2b0554)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x49e552);};_0x5c2b['DaVqiQ']=_0x348524,_0x5c2b['IfNEMv']={},_0x5c2b['IszTuS']=!![];}var _0x14173a=_0x2b9a48[0x0],_0x45f819=_0x479482+_0x14173a,_0x5ee310=_0x5c2b['IfNEMv'][_0x45f819];return!_0x5ee310?(_0x5c2b02=_0x5c2b['DaVqiQ'](_0x5c2b02),_0x5c2b['IfNEMv'][_0x45f819]=_0x5c2b02):_0x5c2b02=_0x5ee310,_0x5c2b02;}function resolveOpenAiReasoningConfig(_0x49e552){var _0x3505a6={_0x563396:0x141,_0x54c69f:0x141,_0x56d0bd:0x13c,_0x12c32d:0x35,_0x4448b5:0x39,_0x3ec243:0x147,_0x5057e9:0x143,_0x4514de:0x31},_0xd47f2a={_0x26e2f2:0xa7};function _0x14e2b6(_0x3d7d60,_0x572137,_0x1185bc,_0x37fa3){return _0x5c2b(_0x3d7d60- -_0xd47f2a._0x26e2f2,_0x37fa3);}function _0x5e40dc(_0x2df12c,_0x2f103e,_0x56a9b9,_0xc9bf24){return _0x5c2b(_0x2df12c- -0x21d,_0x2f103e);}if(_0x49e552?.[_0x5e40dc(-_0x3505a6._0x563396,-_0x3505a6._0x54c69f,-_0x3505a6._0x56d0bd,-0x143)])return structuredClone(_0x49e552[_0x14e2b6(_0x3505a6._0x12c32d,0x36,_0x3505a6._0x4448b5,0x2f)]);return _0x49e552?.[_0x5e40dc(-_0x3505a6._0x3ec243,-_0x3505a6._0x5057e9,-_0x3505a6._0x3ec243,-0x141)]?structuredClone(_0x49e552[_0x14e2b6(0x2f,_0x3505a6._0x4514de,_0x3505a6._0x4514de,0x35)]):void 0x0;}export{resolveAnthropicReasoningConfig,resolveOpenAiReasoningConfig};
@@ -1 +1 @@
1
- (function(_0x4ce751,_0x55b4e4){const _0x49ae3e={_0x28154f:0x2f1,_0x1f3485:0x2c3,_0x403d2f:0x253,_0x41bf5c:0x2ab,_0x1ecbfc:0x268,_0x141c1d:0x340,_0x45275f:0x2d6,_0x2e2dc3:0x2f0,_0x5e4879:0x274,_0x34c146:0x2cf,_0x50e5df:0x315,_0x56f53e:0x28f,_0x2683ae:0x2b0,_0x5e61b7:0x2c7,_0x269f17:0x237,_0x3b12ed:0x2c0,_0x44bac5:0x2e6,_0x6977f5:0x355,_0x2bc95b:0x2f8,_0x555771:0x29e,_0x49dc50:0x336},_0xad5a0d={_0x61b742:0xd8},_0x2e460a={_0x230a5e:0xe6};function _0x442f21(_0x4fb36b,_0x1caeec,_0x498348,_0x52ccf5){return _0x41f4(_0x498348-_0x2e460a._0x230a5e,_0x1caeec);}function _0x4870e5(_0x46f21a,_0x28fd2a,_0x1565b2,_0x540aa9){return _0x41f4(_0x46f21a-_0xad5a0d._0x61b742,_0x1565b2);}const _0xe9aff6=_0x4ce751();while(!![]){try{const _0x4ff45b=parseInt(_0x4870e5(0x28d,_0x49ae3e._0x28154f,_0x49ae3e._0x1f3485,0x271))/0x1*(parseInt(_0x4870e5(_0x49ae3e._0x403d2f,_0x49ae3e._0x41bf5c,_0x49ae3e._0x1ecbfc,0x24d))/0x2)+-parseInt(_0x4870e5(0x317,0x2aa,0x2c8,_0x49ae3e._0x141c1d))/0x3+-parseInt(_0x4870e5(_0x49ae3e._0x45275f,0x27f,_0x49ae3e._0x2e2dc3,0x30f))/0x4*(-parseInt(_0x442f21(0x241,0x24c,_0x49ae3e._0x5e4879,_0x49ae3e._0x34c146))/0x5)+-parseInt(_0x442f21(0x39b,0x312,0x328,_0x49ae3e._0x50e5df))/0x6*(parseInt(_0x442f21(0x287,0x22d,_0x49ae3e._0x56f53e,0x261))/0x7)+parseInt(_0x442f21(_0x49ae3e._0x2683ae,0x2b9,0x2f2,0x31a))/0x8*(-parseInt(_0x442f21(0x2f3,0x2f1,_0x49ae3e._0x5e61b7,0x2a3))/0x9)+parseInt(_0x4870e5(0x299,_0x49ae3e._0x269f17,_0x49ae3e._0x3b12ed,0x2ca))/0xa+parseInt(_0x442f21(_0x49ae3e._0x44bac5,_0x49ae3e._0x6977f5,_0x49ae3e._0x2bc95b,0x296))/0xb*(parseInt(_0x442f21(0x2c2,_0x49ae3e._0x555771,_0x49ae3e._0x44bac5,_0x49ae3e._0x49dc50))/0xc);if(_0x4ff45b===_0x55b4e4)break;else _0xe9aff6['push'](_0xe9aff6['shift']());}catch(_0x3df898){_0xe9aff6['push'](_0xe9aff6['shift']());}}}(_0x4ea0,0xc30fd));import{withEstimatedModelCost}from'./chunk-GAZGO6N7.js';import{createAssistantTextMessage,createReasoningMessage,createToolResultUserMessage,createToolUseMessage,getToolUseBlocks,normalizeMessage,normalizeSystem,responseToAssistantMessage,synthesizeMissingToolResults}from'./chunk-YNOIG4FD.js';import{TurnFailedError}from'./chunk-FFIZ6TKW.js';import{addAbortListener,isAbortError,throwIfAborted,toAbortError}from'./chunk-X7VAACWY.js';function isJsonObject(_0x49290f){return typeof _0x49290f==='object'&&_0x49290f!==null&&!Array['isArray'](_0x49290f);}function isToolOutputEnvelope(_0x18b697){const _0x585877={_0x5303e0:0x123,_0x257808:0xbd,_0x41dff5:0x3ee,_0x14e7bb:0x3d9,_0x2ae42c:0x412,_0x1525cc:0x13a,_0x4252b3:0x8c},_0x450c15={_0x3adc0a:0x210},_0x25cbb3={_0x45091a:0xbc};if(typeof _0x18b697!==_0x10f20f(0x14b,_0x585877._0x5303e0,0x115,_0x585877._0x257808)||_0x18b697===null||Array[_0x33b000(_0x585877._0x41dff5,_0x585877._0x14e7bb,0x445,_0x585877._0x2ae42c)](_0x18b697))return![];if(typeof _0x18b697['output']!==_0x10f20f(_0x585877._0x1525cc,0xce,_0x585877._0x4252b3,0xbe))return![];function _0x10f20f(_0x36af4e,_0x2456d9,_0x4233f5,_0x13c553){return _0x41f4(_0x2456d9- -_0x25cbb3._0x45091a,_0x36af4e);}function _0x33b000(_0x6b5621,_0x2968e5,_0x194292,_0x4234f4){return _0x41f4(_0x194292-_0x450c15._0x3adc0a,_0x4234f4);}const _0x812f85=_0x18b697['structured'];return _0x812f85===void 0x0||isJsonObject(_0x812f85);}function _0x4ea0(){const _0x8f4dbe=['y29TCgXLDgu','BwLZC2LUz01VzgvSq2fSBenVDw50','Dg90ywXdB3n0vxnKvgLJA3m','y2HHDe1VzgvS','yxnZAxn0yw50x21LC3nHz2u','zxH0zw5ZAw9UCW','DhjHBNnMB3jTzxi','CMvQzwn0','ywX3yxLZlwnVBMzPCM0','B3bLBMfPx3jLyxnVBMLUz19KzwX0yq','BM93','mZGWrMH2CgjQ','Bwf4vg9Rzw5Z','mJrovgDJs0W','DxnLCG','Dg9VBf91C2vFBwvZC2fNzq','CMvHC29UAw5Nu3rHCNrLzef0','oIbLEhbLy3rLzcb2ywX1zsbTyxrJAgLUzYbHBNLpzIbZy2HLBwe','Dg9VBf9JB21WBgv0zwq','C2v0q2HHDe1VzgvS','y29UDgvUDeLUzgv4','BwvZC2fNzq','Dg9VBenHBgXdB3vUDa','Dg90ywXfC3rPBwf0zwrdB3n0vxnKvgLJA3m','yw55t2y','nZmXnZzjqxDptKO','Aw5KzxG','yMvMB3jLtw9KzwXszxf1zxn0','DhvYBKLUzgv4','C2vZC2LVBKLK','ywz0zxjnB2rLBfjLC3bVBNnL','mJqXmZGWn1Pcz0H1rq','Dg9VBfj1BNrPBwu','BgLZDfrVB2Xty2HLBwfZ','ywjVCNq','DxnHz2u','zMLUywXnzxnZywDL','ywn0Aw9U','C3rYDwn0DxjLza','yxnZAxn0yw50x2nODw5R','C3LZDgvTuhjVBxb0','oNjLyxnVBMLUzW','ywXS','zgvZy3jPChrPB24','C2v0vg9VBhm','oIbTAxnZAw5NihjLCxvPCMvKigzPzwXKici','AgfZt3DU','B3bLBMfPx3jLyxnVBMLUz19ZDw1Tyxj5x2rLBhrH','ChvZAa','ywrKrxzLBNrmAxn0zw5LCG','zw5HyMXLza','C29Tzq','DhvYBI0','C3rHz2u','DhvYBLn0yxj0zwrbDa','CMvJB3jKrxzLBNq','sw52ywXPzcb0B29SigLUChv0igf0ia','CMvNAxn0CNK','Dg90ywXjBNb1DfrVA2vUCW','B25fDMvUDa','CMfJzq','zw50CMLLCW','ywnXDwLYzq','C3rHDhvZ','yM9VBgvHBG','y29UDgv4DfDPBMrVD0XPBwL0','AxnbCNjHEq','CMvHza','yw50AhjVCgLJx3rOAw5RAw5Nx2rLBhrH','B3v0Chv0','C29YDa','oIbLEhbLy3rLzcbVBMuGB2yG','oIbLEhbLy3rLzcbIB29SzwfU','C2vUza','DhvYBKnVBxbSzxrLzef0','BNvTyMvY','mZC2odGXnKXutNf1EG','AxrLBuLK','zMLSDgvY','mtHlrK1os3C','BwvZC2fNzxm','CNvUvhjHBNnMB3jTzxjZ','zxHLy3v0Aw9Uqxv0Ag9YAxPHDgLVBG','oMfZC2LZDgfUDdO','oIbLEhbLy3rLzcbHCNjHEq','BgvUz3rO','ywrKAxrPB25HBfbYB3bLCNrPzxm','zgvMyxvSDe1LC3nHz2u','ywrK','C3rYAw5NAwz5','ywjVCNrLza','BwfW','C2v0','Bw9KzwXdywXSq291BNq','C2LNBMfS','z2v0vg9VBhm','B3v0Chv0sw5KzxG','yMvMB3jLvg9VBev4zwn1DgLVBG','ywz0zxjuDxjUq29TCgXLDgu','CMvHC29UAw5Nx21LC3nHz2u','C3rHDgu','BMv4Da','vg9VBcbLEgvJDxrPB24GCMvQzwn0zwqGzM9Yia','AxrLBxm','CMvXDwLYzwq','BgLZDa','y29UDgvUDa','Bw9KzwXFCMvZCg9UC2u','zxjYB3i','CMvXDwvZDenVDw50','Dg9VBf9JywXS','CMvXDwvZDa','Dw5WCMLJzwrnB2rLBenHBgXdB3vUDa','C2v0u3LZDgvTuhjVBxb0','ywz0zxjnzxnZywDLqxbWzw5K','mti1neT3BePzsW','oIbLEhbLy3rLzcbUDw1Izxi','CMvNAxn0zxi','C3rYzwfT','CMvHC29UAw5NtwvZC2fNzuLK','zgvWCW','yMvMB3jLqxnZAxn0yw50qxbWzw5K','Aw5WDxq','BgfZDfjLC3bVBNnL','C2vZC2LVBKrPCG','CMvHC29UAw5Nx2nODw5R','ChjVDMLKzxi','qwDLBNqUC2vUzcbYzxf1AxjLCYbHig1LC3nHz2uGD2HLBIbUBYbKzwzHDwX0ig1LC3nHz2uGAxmGy29UzMLNDxjLza','DgHLBG','zMLUywXFBwvZC2fNzq','C3rYAw5N','CMvZzxrnzxnZywDLCW','y2f0y2G','Dg90ywXnB2rLBfrPBwvnCW','nJm5odvQrM1rCKS','Aw5WDxrty2HLBwe','zgvSzxrL','oIb0zxjTAw5HBcbVyNnLCNzLCIaI','Dg9VBhncEu5HBwu','CMvTB3zLrxzLBNrmAxn0zw5LCG','Bw9KzwXdywXSCW','DMfSDwu','BMfTzq','Dgv4Da','oIbLEhbLy3rLzcbVyMPLy3q','CMvZCg9UC2u','C2v0vg9WAwm','ChjVCgvYDgLLCW','CMvHC29UAw5Nq29TCgXLDgvKqxq','Dg90ywXpDxrWDxruB2TLBNm','yw1VDw50vxnKvgLJA3m','zMLUza','AM9PBG','Aw50zxjUywXmAwzLy3LJBgu','DhjPBq','x3n5C3rLBvbYB21WDa','B25vC2vYtwvZC2fNzq','zgvSDge','CNvUt2jZzxj2zxjZ','Dg9VBf9VDxrWDxrFy2H1BMS','Aw5WDxrezwX0yq','mtK1otiYm2L0B0PgvG','A2v5CW','Dw5RBM93BL90B29S','zhjHAw5tDgvLCMLUzW','DhLWzq','ChjVDMLKzxjtDgf0zq','yxnRvxnLCG','zNvUy3rPB24','B3v0Chv0rM9YBwf0','CNvU','C2XPy2u','Bwv0yq','mtu0nxbuswTwuG','zxn0Aw1HDgvKq29ZDenHBgXdB3vUDa','DxnLCL9TzxnZywDL','iIbMB3iG','Bw9KzwXFCMvXDwvZDa','Bw9KzwXuAw1Ltxm','CgvYBwLZC2LVBKnSyxnZ','DhvYBKLK','oIb1BMv4CgvJDgvKigzPzwXKici','ChjVDMLKzxjFCMv0CNK','DgHPBMTPBMC','Bw9KzwW','mta2nZm5nZbot0jRC0O','C3rYzwfTAw5N','oIbLEhbLy3rLzcbZDhjPBMC','C3vTBwfYEuLUzgv4','C3LZDgvT','C2v0u2vZC2LVBKLK','B25uB29Sq2fSBa','CMv0DxjU','ywz0zxjuB29SuMvZDwX0','vg9VBev4zwn1DgLVBKvYCM9Y','iIbPCYbHBhjLywr5igvUywjSzwq','Dg90ywXszxbVCNrLzenVC3rvC2ruAwnRCW','B2jZzxj2zxi','CMvHC29U','yxnZAxn0yw50twvZC2fNzuLK','y2f1C2u','yMvMB3jLvg9VBfjLC3vSDefWCgvUza','Dg9VBf91C2vFzgvSDge','z2v0','CMvWB3j0zwrdB3n0q2fSBenVDw50','Dg9VBf9YzwPLy3rLza','ChjVDMLKzxjFC3rYzwfTx3jLC2v0','y29UDgvUDf9KzwX0yq','CMvWB3j0zwrdB3n0','qwDLBNqGCMvXDwLYzxmGysbJAgf0tw9KzwW','C2vZC2LVBI0','Bw9KzwXjzgvUDgL0Eq','B3jKzxi','Dg9tDhjPBMC','zxn0Aw1HDgvKq29ZDa','B2jQzwn0','CMvHC29UAw5Nvg9Rzw5Z','nZGZuwHfChrj','Dg9VBf9Yzxn1BhrFBwvZC2fNzq','Bwv0ywrHDge','CMvZB2X2zq','DgvYBwLUywW','Bwv0CMLJCW','Dg9VBf9ZDgfYDgvK','zw51Bq','Dg9VBf91C2vFy2H1BMS','Dg9VBfjLC3vSDhm','Dg9VBf91C2u','DhvYBL9JB21WBgv0zq','zg9Uzq','q2fUBM90ihjLz2LZDgvYihrLCM1PBMfSig9IC2vYDMvYici','yxjYyxK','ChjPy2LUz1bYB3zPzgvYswq','A2LUza','y29TCgXLDgvK'];_0x4ea0=function(){return _0x8f4dbe;};return _0x4ea0();}function validateAgainstSchema(_0x3f8560,_0x4934bc,_0x5f2ca3){const _0x3e45fe={_0x2bf0e5:0x77,_0x18285e:0xbd,_0x124d3d:0x11b,_0xc4f73a:0x18b,_0x347586:0xd9,_0x3827c0:0xfa,_0x3a2d96:0x6a,_0x841578:0x5b,_0x3b51e5:0x11,_0x5a32f5:0x3c,_0x22813c:0xaf,_0xad7715:0x9e,_0x549660:0xe0,_0x200268:0x2f,_0x25631e:0xd4,_0x30ee14:0xdd,_0x4171b4:0x89,_0x3752e3:0xff,_0x18c192:0x86,_0x40116f:0xec,_0xc4032e:0x148,_0x4c3255:0x20,_0x487914:0x126,_0x58464a:0x133,_0x217a58:0xca,_0x39ab6d:0x14e,_0x6dfbc7:0x12e,_0x3935e6:0x2,_0x4f0a27:0xb8,_0x4552c6:0xe4,_0x569e8d:0x122,_0x56cb04:0xdd,_0x4875de:0xd7,_0x19f89f:0xe0,_0x26442c:0xb5,_0x552f6a:0x136,_0x403fd1:0x85,_0x1e289d:0x113,_0x5afaa9:0x120,_0x279c21:0x108,_0x2d1d9b:0xf9,_0xbffcb5:0x106,_0x3b3f02:0xa5,_0x39165f:0xcb,_0x1d1622:0xd8,_0x10466b:0x14a,_0x877ec7:0x130,_0x288f63:0x115,_0x4216e4:0x13a,_0x49b43f:0x183,_0x591dc1:0xca,_0x1deb9e:0x9f,_0x4ea511:0x96,_0x179be5:0x51,_0x2b1166:0x6f,_0x337829:0xc9,_0x2e640d:0x7a,_0x492a8d:0xe2,_0x34f4c1:0x10d,_0x101471:0xb9,_0x405df3:0xa2},_0x2ab6dc={_0x5f4a2a:0x123,_0x4ad2e1:0x152,_0x368da5:0x16a,_0xd51fdc:0x18d},_0x373b35={_0x1c1406:0x10b};function _0x2edc47(_0xff1a75,_0x414188,_0xa714c7,_0x7cfd78){return _0x41f4(_0x414188- -_0x373b35._0x1c1406,_0x7cfd78);}if('anyOf'in _0x5f2ca3){const _0x208724=_0x5f2ca3[_0x192a74(0x113,_0x3e45fe._0x2bf0e5,_0x3e45fe._0x18285e,0x4e)][_0x2edc47(0xcf,_0x3e45fe._0x124d3d,_0x3e45fe._0xc4f73a,0xd9)](_0x4800fe=>{try{return validateAgainstSchema(_0x3f8560,_0x4934bc,_0x4800fe),!![];}catch{return![];}});if(!_0x208724)throw new Error(_0x2edc47(_0x3e45fe._0x347586,0x120,_0x3e45fe._0x3827c0,0xc3)+_0x3f8560+_0x192a74(_0x3e45fe._0x3a2d96,0x12a,0xb6,0x4b));return;}function _0x192a74(_0x46533c,_0x23bd25,_0x3ca289,_0x159424){return _0x41f4(_0x3ca289- -0x14e,_0x46533c);}switch(_0x5f2ca3[_0x2edc47(0x8a,0xa2,0x76,0xa2)]){case _0x192a74(_0x3e45fe._0x841578,-_0x3e45fe._0x3b51e5,_0x3e45fe._0x5a32f5,0x26):if(typeof _0x4934bc!=='string')throw new Error(_0x2edc47(_0x3e45fe._0x22813c,0x120,0x170,0xd0)+_0x3f8560+_0x192a74(_0x3e45fe._0xad7715,_0x3e45fe._0x549660,0x75,_0x3e45fe._0x200268));if(_0x5f2ca3['enum']!==void 0x0&&!_0x5f2ca3[_0x2edc47(_0x3e45fe._0x25631e,_0x3e45fe._0x30ee14,_0x3e45fe._0x4171b4,_0x3e45fe._0x3752e3)]['includes'](_0x4934bc))throw new Error('Invalid\x20tool\x20input\x20at\x20'+_0x3f8560+_0x192a74(0x83,_0x3e45fe._0x18c192,_0x3e45fe._0x40116f,0xb8)+_0x5f2ca3[_0x2edc47(0xfd,0xdd,_0x3e45fe._0xc4032e,0x139)][_0x2edc47(0x7d,0x95,_0x3e45fe._0x4c3255,0x26)](',\x20'));return;case _0x2edc47(_0x3e45fe._0x487914,_0x3e45fe._0x58464a,0x16a,0x131):if(typeof _0x4934bc!==_0x2edc47(0x120,0x133,0x16b,_0x3e45fe._0x217a58))throw new Error(_0x192a74(0xcf,_0x3e45fe._0x39ab6d,0xdd,_0x3e45fe._0x6dfbc7)+_0x3f8560+_0x192a74(_0x3e45fe._0x3935e6,-0x2d,0x2e,0x21));return;case _0x2edc47(_0x3e45fe._0x4f0a27,0x128,0xc8,_0x3e45fe._0x4552c6):if(typeof _0x4934bc!==_0x192a74(0x125,0x9e,0xe5,_0x3e45fe._0x569e8d))throw new Error(_0x192a74(0x136,0x71,_0x3e45fe._0x56cb04,_0x3e45fe._0x4875de)+_0x3f8560+_0x2edc47(0xe4,0x130,0xd8,_0x3e45fe._0x19f89f));return;case _0x2edc47(0x104,0xe4,_0x3e45fe._0x26442c,0x74):if(!Array[_0x192a74(_0x3e45fe._0x552f6a,0xea,0xe7,_0x3e45fe._0x403fd1)](_0x4934bc))throw new Error(_0x2edc47(_0x3e45fe._0x1e289d,_0x3e45fe._0x5afaa9,0x16c,0x112)+_0x3f8560+_0x192a74(0xc9,_0x3e45fe._0x279c21,_0x3e45fe._0x2d1d9b,0xd9));_0x4934bc['forEach']((_0x56d1fd,_0x3c1cd0)=>{const _0x42ea09={_0x515a0d:0x4b};function _0x5c5605(_0x5ae733,_0xb7f88a,_0x52fe6d,_0x2d0874){return _0x2edc47(_0x5ae733-0xd9,_0x5ae733- -0x272,_0x52fe6d-_0x42ea09._0x515a0d,_0x52fe6d);}validateAgainstSchema(_0x3f8560+'['+_0x3c1cd0+']',_0x56d1fd,_0x5f2ca3[_0x5c5605(-_0x2ab6dc._0x5f4a2a,-_0x2ab6dc._0x4ad2e1,-_0x2ab6dc._0x368da5,-_0x2ab6dc._0xd51fdc)]);});return;case _0x2edc47(0xf7,0xd4,_0x3e45fe._0xbffcb5,0xd9):if(!isJsonObject(_0x4934bc))throw new Error('Invalid\x20tool\x20input\x20at\x20'+_0x3f8560+_0x192a74(0x31,0x45,0x4a,_0x3e45fe._0x3b3f02));for(const _0x46bbf9 of _0x5f2ca3[_0x192a74(0xa1,0xbc,0x10d,0x11d)]??[]){if(!Object[_0x192a74(_0x3e45fe._0x39165f,_0x3e45fe._0x1d1622,0xd3,0x116)](_0x4934bc,_0x46bbf9))throw new Error(_0x192a74(_0x3e45fe._0x10466b,0x13c,0xdd,_0x3e45fe._0x877ec7)+_0x3f8560+_0x2edc47(0xf6,_0x3e45fe._0x288f63,0x15b,_0x3e45fe._0x4216e4)+_0x46bbf9+'\x22');}if(_0x5f2ca3[_0x2edc47(0x143,0x13e,0x157,_0x3e45fe._0x49b43f)]===![]){const _0x37ed8b=Object[_0x2edc47(_0x3e45fe._0x591dc1,_0x3e45fe._0x1deb9e,_0x3e45fe._0x4ea511,_0x3e45fe._0xbffcb5)](_0x4934bc)[_0x192a74(0x61,0xa2,_0x3e45fe._0x179be5,-0x1e)](_0x166609=>!Object[_0x192a74(0xa1,0x12b,0xd3,0xfd)](_0x5f2ca3[_0x192a74(0xa0,0x94,0x4d,0x8f)],_0x166609));if(_0x37ed8b!==void 0x0)throw new Error(_0x2edc47(0x134,0x120,0xc1,0x17a)+_0x3f8560+_0x192a74(0x94,0xd8,_0x3e45fe._0x2b1166,_0x3e45fe._0x337829)+_0x37ed8b+'\x22');}for(const [_0x5ba866,_0x325091]of Object[_0x192a74(0x12e,_0x3e45fe._0x2e640d,_0x3e45fe._0x492a8d,_0x3e45fe._0x34f4c1)](_0x5f2ca3[_0x192a74(0xbc,_0x3e45fe._0x101471,0x4d,_0x3e45fe._0x405df3)])){Object['hasOwn'](_0x4934bc,_0x5ba866)&&validateAgainstSchema(_0x3f8560+'.'+_0x5ba866,_0x4934bc[_0x5ba866],_0x325091);}}}function normalizeToolOutputValue(_0x52244f){const _0x42f1c5={_0x57b065:0x135,_0x36e5fc:0xd1,_0x2681c8:0x105,_0x295060:0x12a,_0x5b7ecf:0x1cb,_0x409b21:0x237,_0x20afb2:0x3d4,_0x409dce:0x427,_0x13c168:0x46b,_0x10e7bf:0x400,_0x3313fe:0x395,_0x517414:0x15e,_0x578622:0x108,_0x49fb5f:0x13c,_0x32bbb2:0xad,_0x53fed1:0xf1,_0xe524cb:0x532,_0x2e6fff:0x4c2},_0x2c94d7={_0x50951f:0x33d};function _0xa8c70c(_0x2a3c58,_0x550d75,_0x5934a2,_0x521551){return _0x41f4(_0x2a3c58- -_0x2c94d7._0x50951f,_0x550d75);}if(isToolOutputEnvelope(_0x52244f))return{'output':_0x52244f['output'],'structured':_0x52244f[_0xa8c70c(-0x124,-0xf8,-_0x42f1c5._0x57b065,-_0x42f1c5._0x36e5fc)]??{'value':_0x52244f[_0xa8c70c(-_0x42f1c5._0x2681c8,-_0x42f1c5._0x295060,-0x169,-0x96)]},..._0x52244f[_0xa8c70c(-_0x42f1c5._0x5b7ecf,-_0x42f1c5._0x409b21,-0x1a1,-0x1fb)]!==void 0x0?{'content':_0x52244f[_0x3da2c5(0x389,_0x42f1c5._0x20afb2,0x3e8,_0x42f1c5._0x409dce)]}:{}};if(typeof _0x52244f===_0x3da2c5(_0x42f1c5._0x13c168,0x418,_0x42f1c5._0x10e7bf,_0x42f1c5._0x3313fe))return{'output':_0x52244f,'structured':{'value':_0x52244f}};if(typeof _0x52244f===_0xa8c70c(-_0x42f1c5._0x517414,-0x108,-0x168,-0x117)&&_0x52244f!==null&&!Array[_0xa8c70c(-_0x42f1c5._0x578622,-0x147,-_0x42f1c5._0x49fb5f,-_0x42f1c5._0x32bbb2)](_0x52244f))return{'output':JSON[_0xa8c70c(-_0x42f1c5._0x53fed1,-0x9b,-0x95,-0x11e)](_0x52244f,null,0x2),'structured':_0x52244f};function _0x3da2c5(_0x50325e,_0x2f5d32,_0x24134a,_0xa7112c){return _0x41f4(_0x24134a-0x276,_0x50325e);}return{'output':JSON[_0x3da2c5(0x50c,_0x42f1c5._0xe524cb,_0x42f1c5._0x2e6fff,0x51f)](_0x52244f,null,0x2),'structured':{'value':_0x52244f}};}function createToolOutput(_0x1dc312,_0x31b3d6={'value':_0x1dc312},_0xe07ca6){return{'output':_0x1dc312,'structured':_0x31b3d6,..._0xe07ca6!==void 0x0?{'content':_0xe07ca6}:{}};}var ToolExecutionError=class extends Error{[_0x249222(0x29a,0x2a8,0x235,0x2a7)];constructor(_0x45f54c,_0x4dc1b9={}){const _0x4dfe0c={_0x33f204:0x1bf,_0x5d7bc3:0x1af,_0x15bd26:0x192},_0xebdfb1={_0x1c5760:0x11f,_0xaa24e7:0x408};super(_0x45f54c),this['name']=_0x53208c(-0x184,-_0x4dfe0c._0x33f204,-_0x4dfe0c._0x5d7bc3,-_0x4dfe0c._0x15bd26);function _0x53208c(_0xa89a7,_0x4b661d,_0x4e0721,_0xa8ff5e){return _0x249222(_0xa89a7-_0xebdfb1._0x1c5760,_0x4e0721- -_0xebdfb1._0xaa24e7,_0xa89a7,_0xa8ff5e-0x18);}this['structured']=_0x4dc1b9;}};function defineTool(_0x22ea23){return _0x22ea23;}function resolveToolPermissionClass(_0x373123){const _0x5ab923={_0x2f4546:0x15c,_0x1acb87:0x10c,_0xa04a4:0xec,_0x10d0cd:0x178,_0x669d7c:0x1f7,_0xbde200:0x186,_0x1e720c:0x193,_0x33731e:0x6c},_0x337e51={_0x10619a:0x5a},_0x53fa95=_0x373123?.[_0x4a3f9d(-_0x5ab923._0x2f4546,-_0x5ab923._0x1acb87,-0xc3,-_0x5ab923._0xa04a4)];function _0x4a3f9d(_0x50b47d,_0x58af99,_0x4be97a,_0x1b9629){return _0x249222(_0x50b47d-_0x337e51._0x10619a,_0x1b9629- -0x336,_0x58af99,_0x1b9629-0x9b);}if(_0x53fa95===_0x1d1a4e(0x171,_0x5ab923._0x10d0cd,_0x5ab923._0x669d7c,_0x5ab923._0xbde200)||_0x53fa95==='write'||_0x53fa95===_0x1d1a4e(_0x5ab923._0x1e720c,0x1bc,0x162,0x14b))return _0x53fa95;function _0x1d1a4e(_0x2754ff,_0x594193,_0x31108e,_0x9ad7f9){return _0x249222(_0x2754ff-0x3b,_0x9ad7f9- -0x13f,_0x594193,_0x9ad7f9-0xe3);}return _0x4a3f9d(-0xdd,-0x94,-_0x5ab923._0x33731e,-0xac);}var ToolRegistry=class{[_0x4c1020(0xe3,0x15d,0x110,0x13f)]=new Map();constructor(_0x54b43c=[]){const _0xdd7b2e={_0x5e74dc:0x18b,_0x7a8b2d:0x162,_0x1fa9b7:0x11d,_0x1b40e1:0x200},_0x47c39e={_0x205b70:0xd6};function _0x55c444(_0x150c74,_0x22f981,_0xc1de47,_0x4c34ca){return _0x4c1020(_0xc1de47,_0x22f981-0x34,_0xc1de47-_0x47c39e._0x205b70,_0x150c74- -0x2b5);}for(const _0x157482 of _0x54b43c){this[_0x55c444(-_0xdd7b2e._0x5e74dc,-_0xdd7b2e._0x7a8b2d,-_0xdd7b2e._0x1fa9b7,-_0xdd7b2e._0x1b40e1)](_0x157482);}}[_0x4c1020(0x19f,0x12c,0xde,0x12a)](_0x266632){const _0x18fa07={_0x1eca45:0x312,_0x2422f2:0x2a5,_0x433f10:0x27b},_0x217966={_0x9c2769:0x8b,_0x2196e1:0x7b},_0x5831a2={_0x467b39:0x91};function _0x36bf0d(_0x43ac6d,_0x41fcc0,_0x588851,_0x173123){return _0x249222(_0x43ac6d-0x1d7,_0x588851-0x80,_0x41fcc0,_0x173123-_0x5831a2._0x467b39);}function _0x19971f(_0x1d494a,_0x156e2e,_0xa7bf87,_0x150d1e){return _0x249222(_0x1d494a-0x192,_0x156e2e-_0x217966._0x9c2769,_0x1d494a,_0x150d1e-_0x217966._0x2196e1);}this['toolsByName'][_0x36bf0d(0x332,0x333,0x35e,_0x18fa07._0x1eca45)](_0x266632[_0x36bf0d(0x260,0x2ea,_0x18fa07._0x2422f2,_0x18fa07._0x433f10)],_0x266632);}[_0x4c1020(0x166,0x1f6,0x176,0x180)](_0x15cc5f){const _0x579543={_0x1c2fbf:0x2ac,_0x428d6c:0x2d3,_0x4b20f8:0x2c2,_0x433e98:0x2c8},_0x3123d1={_0x7449c0:0x6f},_0x7f1254={_0x86948a:0xcb,_0x14314d:0x1b5,_0x5ceff9:0x9};function _0x49a2da(_0x2cfb6e,_0x74b7b6,_0x61a76d,_0x17e678){return _0x249222(_0x2cfb6e-_0x7f1254._0x86948a,_0x61a76d-_0x7f1254._0x14314d,_0x74b7b6,_0x17e678-_0x7f1254._0x5ceff9);}function _0x318911(_0x3cf124,_0x3885e8,_0x59ce88,_0x7d696f){return _0x249222(_0x3cf124-0xfa,_0x3885e8-0xb2,_0x7d696f,_0x7d696f-_0x3123d1._0x7449c0);}return this[_0x318911(_0x579543._0x1c2fbf,_0x579543._0x428d6c,0x271,_0x579543._0x4b20f8)][_0x318911(0x2bc,0x314,_0x579543._0x433e98,0x2cc)](_0x15cc5f);}[_0x249222(0x2dc,0x2eb,0x35d,0x33e)](){const _0xda96d={_0x29dd00:0x18d,_0x74bd4f:0x153},_0x293ab7={_0x5f20bb:0x3ae};function _0x246ffc(_0x426e9e,_0x1ffb84,_0x537857,_0x4ced27){return _0x249222(_0x426e9e-0xf6,_0x1ffb84- -_0x293ab7._0x5f20bb,_0x537857,_0x4ced27-0x17d);}return[...this[_0x246ffc(-0x11a,-_0xda96d._0x29dd00,-_0xda96d._0x74bd4f,-0x151)]['values']()];}['listToolSchemas'](){const _0x1ffeff={_0x4329fa:0x11c,_0x48a86a:0x191,_0xed5f3b:0x480,_0xb93afb:0x47f,_0x5709fb:0x4dd},_0x1f4d49={_0x2903cf:0x107,_0x52f776:0x197},_0x53f970={_0x444bfc:0x34a,_0x505c34:0x7b,_0x344da9:0x185},_0x34fdd3={_0x408d96:0xe4,_0x353819:0x325},_0x3ecf9e={_0x4210b9:0x1ee,_0x37cf57:0x1a2};function _0x2ac6fe(_0x1529f7,_0x321e37,_0xac3926,_0x3a3606){return _0x249222(_0x1529f7-_0x3ecf9e._0x4210b9,_0xac3926-_0x3ecf9e._0x37cf57,_0x3a3606,_0x3a3606-0x3b);}function _0x75c754(_0x2609ad,_0x240ec9,_0x73c3b0,_0x5b7aac){return _0x4c1020(_0x2609ad,_0x240ec9-_0x34fdd3._0x408d96,_0x73c3b0-0x5b,_0x240ec9- -_0x34fdd3._0x353819);}return this[_0x75c754(-0xe9,-_0x1ffeff._0x4329fa,-_0x1ffeff._0x48a86a,-0x131)]()[_0x2ac6fe(_0x1ffeff._0xed5f3b,0x410,_0x1ffeff._0xb93afb,_0x1ffeff._0x5709fb)](_0x249eb5=>{function _0xba5b60(_0x5ee12e,_0x26a057,_0x501d6b,_0x33cdf7){return _0x2ac6fe(_0x5ee12e-0x1f4,_0x26a057-0xd7,_0x33cdf7-0x78,_0x501d6b);}function _0xcc6b96(_0x4e9c66,_0x2677d5,_0xcedac0,_0x4dd892){return _0x75c754(_0xcedac0,_0x4e9c66-_0x53f970._0x444bfc,_0xcedac0-_0x53f970._0x505c34,_0x4dd892-_0x53f970._0x344da9);}return{'name':_0x249eb5[_0xcc6b96(0x168,0x113,_0x1f4d49._0x2903cf,0x16d)],'description':_0x249eb5[_0xcc6b96(0x1f0,0x1d1,0x1de,_0x1f4d49._0x52f776)],'input_schema':_0x249eb5['inputSchema']};});}};function validateToolInput(_0x57b3cc,_0x43eef0){const _0x741177={_0x5aac29:0x36a,_0x24cd1d:0x366,_0x5a22e0:0x3a0};validateAgainstSchema(_0x239762(_0x741177._0x5aac29,_0x741177._0x24cd1d,0x32a,_0x741177._0x5a22e0),_0x57b3cc,_0x43eef0);function _0x239762(_0xcce1ff,_0x29a98e,_0x1d28d8,_0xf2199b){return _0x249222(_0xcce1ff-0xa7,_0x1d28d8-0x119,_0x29a98e,_0xf2199b-0x3a);}return _0x57b3cc;}function deriveFinalToolOutput(_0x156817){const _0x4a6f78={_0x467b0c:0xbf,_0x212431:0xe8,_0x210f90:0xc4,_0x349cd7:0x1e,_0x2c06c9:0xa8,_0x1c3bdf:0x77,_0x358f75:0x2d9,_0x29fcff:0x338,_0x33df2c:0x2c9,_0x59aa71:0x244,_0x4bfe2b:0x335,_0x459fcc:0x395,_0x2e3075:0x34b,_0x2691be:0xb6,_0x2e23ff:0x8c,_0x1a56bf:0x4f},_0x45beae={_0x11f2db:0x1dd},_0x53e34f={_0x53fbca:0x16e};if(_0x156817[_0x20a13d(0xf3,_0x4a6f78._0x467b0c,0x87,_0x4a6f78._0x212431)]===0x0)return{'output':'','structured':{}};if(_0x156817[_0x20a13d(_0x4a6f78._0x210f90,_0x4a6f78._0x349cd7,0x87,0xc7)]===0x1)return{'output':_0x156817[0x0][_0x20a13d(0xa0,_0x4a6f78._0x2c06c9,_0x4a6f78._0x1c3bdf,0x1a)],'structured':_0x156817[0x0][_0xb9051d(_0x4a6f78._0x358f75,0x300,_0x4a6f78._0x29fcff,_0x4a6f78._0x33df2c)],..._0x156817[0x0][_0xb9051d(_0x4a6f78._0x59aa71,0x259,0x226,0x227)]!==void 0x0?{'content':_0x156817[0x0]['content']}:{}};function _0x20a13d(_0x460482,_0x38a580,_0x46dff0,_0x57a295){return _0x4c1020(_0x57a295,_0x38a580-0xea,_0x46dff0-0x19b,_0x46dff0- -_0x53e34f._0x53fbca);}function _0xb9051d(_0x24b834,_0x316c8c,_0x1ad180,_0x1ed994){return _0x249222(_0x24b834-0xe6,_0x316c8c-0x58,_0x1ed994,_0x1ed994-_0x45beae._0x11f2db);}const _0x20f7df=_0x156817['filter'](_0x1bfc44=>_0x1bfc44[_0x20a13d(-0x77,-0xa3,-0x4f,-0x4)]!==void 0x0);return{'output':_0x156817['map'](_0x34204e=>_0x34204e[_0x20a13d(0x36,0x91,0x77,0x31)])['join'](''),'structured':{'chunks':_0x156817[_0xb9051d(0x34e,_0x4a6f78._0x4bfe2b,_0x4a6f78._0x459fcc,_0x4a6f78._0x2e3075)](_0x3df658=>_0x3df658['structured'])},..._0x20f7df['length']===0x1?{'content':_0x20f7df[0x0][_0x20a13d(-_0x4a6f78._0x2691be,-_0x4a6f78._0x2e23ff,-_0x4a6f78._0x1a56bf,-0x91)]}:{}};}function createToolMeta(){return{'transforms':[]};}function createErrorToolResult(_0x2303e7,_0x43df1d,_0x3768b9,_0x146c25=[]){const _0x2ba0b9={_0x1fc322:0x9,_0x11571d:0xf},_0x1e8430={_0x468733:0x5b,_0x1493df:0x216},_0xd7bee0={_0x2f231e:0x1ec,_0x2fd213:0x103};function _0x825cf0(_0x32b440,_0x512ca1,_0x2a48f8,_0x3e1537){return _0x4c1020(_0x3e1537,_0x512ca1-0xb,_0x2a48f8-_0xd7bee0._0x2f231e,_0x32b440-_0xd7bee0._0x2fd213);}function _0x22b867(_0x5e337b,_0x13b384,_0x24180b,_0x182982){return _0x249222(_0x5e337b-_0x1e8430._0x468733,_0x182982- -_0x1e8430._0x1493df,_0x24180b,_0x182982-0xe2);}return{'callId':_0x2303e7['id'],'toolName':_0x2303e7[_0x22b867(0x6e,-0x44,-_0x2ba0b9._0x1fc322,_0x2ba0b9._0x11571d)],'status':_0x22b867(0x57,0x13,-0x4d,-0x13),'output':_0x43df1d,'structured':_0x3768b9,'chunks':_0x146c25,'meta':createToolMeta()};}function createRejectedToolResult(_0x75c9e2,_0x3c14bc){const _0x2284b0={_0x1510be:0x530,_0x56339a:0x532,_0x3b7d33:0x612,_0x1fbbc9:0x5ae,_0xf95a15:0x608,_0x4ce8e9:0x4bd,_0x1daa24:0x504,_0x426d2d:0x491,_0x5a8562:0x5d9},_0x2daeaf={_0x2de660:0x19},_0x1cb4e7={_0x5e00a8:0x184,_0x1f381a:0x137};function _0x3c3e84(_0x13fb46,_0x4a3492,_0x49a40d,_0x5b8e73){return _0x249222(_0x13fb46-_0x1cb4e7._0x5e00a8,_0x4a3492-0x2d3,_0x13fb46,_0x5b8e73-_0x1cb4e7._0x1f381a);}const _0x1f4d8f=_0x3c14bc?.[_0x3c3e84(_0x2284b0._0x1510be,0x504,_0x2284b0._0x56339a,0x4d2)]()[_0x5c1a8d(_0x2284b0._0x3b7d33,_0x2284b0._0x1fbbc9,0x5f7,0x60c)]?_0x3c14bc:_0x5c1a8d(0x61a,0x625,_0x2284b0._0xf95a15,0x5a0)+_0x75c9e2['name'];function _0x5c1a8d(_0x139373,_0x25db1c,_0x19cb97,_0x6e6400){return _0x249222(_0x139373-_0x2daeaf._0x2de660,_0x19cb97-0x320,_0x25db1c,_0x6e6400-0x35);}return createErrorToolResult(_0x75c9e2,_0x1f4d8f,{'error':'tool_rejected',..._0x3c14bc?.[_0x3c3e84(_0x2284b0._0x4ce8e9,_0x2284b0._0x1daa24,0x49f,_0x2284b0._0x426d2d)]()[_0x5c1a8d(_0x2284b0._0x5a8562,0x65e,0x5f7,_0x2284b0._0x3b7d33)]?{'reason':_0x3c14bc}:{}});}function createAbortedToolResult(_0x1b6d75,_0x3413c8,_0x1b6082=[]){const _0x429885=toAbortError(_0x3413c8);return createErrorToolResult(_0x1b6d75,_0x429885['message'],{'error':_0x429885['message'],'aborted':!![]},_0x1b6082);}function createSuccessToolResult(_0x540b77,_0x31c1e5,_0x533c45){const _0x248180={_0x95fa14:0x2ca,_0x553454:0x330,_0x208a6e:0x182,_0x416414:0x16c},_0x32d089={_0x527b11:0xe3},_0x24db34={_0x31419b:0x4d};function _0x287bd7(_0x2739c0,_0x299122,_0x1a8384,_0x5d2407){return _0x4c1020(_0x299122,_0x299122-0x47,_0x1a8384-0x34,_0x5d2407-_0x24db34._0x31419b);}function _0x23d6f1(_0x5bd0eb,_0xd7174e,_0x1713ee,_0x1f03c1){return _0x249222(_0x5bd0eb-_0x32d089._0x527b11,_0xd7174e-0x10b,_0x5bd0eb,_0x1f03c1-0xbb);}return{'callId':_0x540b77['id'],'toolName':_0x540b77[_0x23d6f1(_0x248180._0x95fa14,_0x248180._0x553454,0x350,0x2e9)],'status':'ok','output':_0x31c1e5[_0x287bd7(0x1fe,0x1ea,0x269,0x232)],'structured':_0x31c1e5['structured'],..._0x31c1e5[_0x287bd7(0x1a5,_0x248180._0x208a6e,0x17d,_0x248180._0x416414)]!==void 0x0?{'content':_0x31c1e5['content']}:{},'chunks':_0x533c45,'meta':createToolMeta()};}function createUnknownToolResult(_0x11589d){const _0xde1312={_0x423830:0x1d0,_0x1806bf:0x293,_0x3e436f:0x259},_0x2ca220={_0xfcd52a:0x1d3},_0x1bae15={_0x38715d:0x135};function _0x13df4b(_0x5e0cab,_0x1ac003,_0x446311,_0x34314b){return _0x249222(_0x5e0cab-0x43,_0x1ac003- -0x333,_0x446311,_0x34314b-_0x1bae15._0x38715d);}function _0x53f645(_0x4d8a2c,_0x5d9dfb,_0x4e1865,_0x4eb8d9){return _0x249222(_0x4d8a2c-0x1e7,_0x4eb8d9-0x7,_0x4d8a2c,_0x4eb8d9-_0x2ca220._0xfcd52a);}return createErrorToolResult(_0x11589d,'Unknown\x20tool:\x20'+_0x11589d[_0x53f645(_0xde1312._0x423830,_0xde1312._0x1806bf,_0xde1312._0x3e436f,0x22c)],{'error':_0x53f645(0x204,0x234,0x214,0x241)});}function isDispatchDecision(_0x4b8926){const _0x1b8d15={_0x43e0c1:0x4ac,_0x39d32a:0x467,_0x4f6c17:0x493,_0x32a67f:0x4ac,_0x50377a:0x4e0},_0xc6b979={_0x3800cd:0x239},_0x122197={_0x3e3182:0xf6};function _0x3742b3(_0xe0de1a,_0x531dea,_0xb803d4,_0x42dfe4){return _0x249222(_0xe0de1a-0x157,_0x531dea- -_0x122197._0x3e3182,_0x42dfe4,_0x42dfe4-0x1f);}if(typeof _0x4b8926!==_0x369ced(_0x1b8d15._0x43e0c1,_0x1b8d15._0x39d32a,0x48f,0x4a7)||_0x4b8926===null)return![];function _0x369ced(_0x32be06,_0x561250,_0x58d39d,_0x470ae7){return _0x249222(_0x32be06-0x40,_0x470ae7-_0xc6b979._0x3800cd,_0x32be06,_0x470ae7-0x84);}return _0x4b8926[_0x369ced(_0x1b8d15._0x4f6c17,_0x1b8d15._0x32a67f,0x4f7,_0x1b8d15._0x50377a)]==='reject'||_0x4b8926[_0x3742b3(0x1c7,0x1b1,0x1f6,0x204)]==='run';}function normalizeExecutionError(_0x526c45){const _0x3f0276={_0x2a8713:0x192,_0x461691:0x146,_0x236f4c:0x192,_0x591f5b:0x14a,_0x1ed8ff:0x12a,_0x45755e:0x157,_0x5982d7:0xb,_0x1e505a:0x4e,_0x44cdbc:0x99,_0x4acb97:0x3f,_0x34d489:0x1c,_0x2aabd9:0x31,_0x5e7c70:0x16,_0x51b592:0x27,_0x2b1a6c:0x13,_0x3529f3:0x50,_0x3c1702:0xe1,_0x230166:0x46},_0x10c772={_0x344178:0xbd,_0x99d1fe:0x3,_0x140e8c:0x19f},_0x2fd35c={_0x543082:0x23};if(_0x526c45 instanceof ToolExecutionError)return{'errorMessage':_0x526c45[_0x15af9c(_0x3f0276._0x2a8713,_0x3f0276._0x461691,0x206,0x1c4)],'structured':{'error':_0x526c45[_0x15af9c(_0x3f0276._0x236f4c,_0x3f0276._0x591f5b,_0x3f0276._0x1ed8ff,_0x3f0276._0x45755e)],..._0x526c45[_0x311e2c(-_0x3f0276._0x5982d7,-_0x3f0276._0x1e505a,_0x3f0276._0x44cdbc,0x27)]}};if(_0x526c45 instanceof Error)return{'errorMessage':_0x526c45[_0x311e2c(_0x3f0276._0x4acb97,0x60,_0x3f0276._0x34d489,0x16)],'structured':{'error':_0x526c45[_0x311e2c(-0x59,-0x4,-_0x3f0276._0x2aabd9,_0x3f0276._0x5e7c70)]}};function _0x15af9c(_0x4a21db,_0x21615f,_0x59e130,_0x9b8ee9){return _0x4c1020(_0x59e130,_0x21615f-0x121,_0x59e130-0x35,_0x4a21db- -_0x2fd35c._0x543082);}if(typeof _0x526c45===_0x311e2c(0xf,0x21,_0x3f0276._0x51b592,-_0x3f0276._0x2b1a6c)&&_0x526c45!==null&&'message'in _0x526c45&&typeof _0x526c45[_0x311e2c(-0x1f,0x6c,-_0x3f0276._0x3529f3,0x16)]===_0x15af9c(0x114,_0x3f0276._0x3c1702,0x13e,0x9f))return{'errorMessage':_0x526c45[_0x311e2c(-0x6,_0x3f0276._0x4acb97,_0x3f0276._0x230166,0x16)],'structured':{'error':_0x526c45['message']}};function _0x311e2c(_0x5123ce,_0x2f8ca9,_0x14858b,_0x1b9dea){return _0x4c1020(_0x5123ce,_0x2f8ca9-_0x10c772._0x344178,_0x14858b-_0x10c772._0x99d1fe,_0x1b9dea- -_0x10c772._0x140e8c);}const _0x335579=String(_0x526c45);return{'errorMessage':_0x335579,'structured':{'error':_0x335579}};}async function emitEvent(_0x4da7a8,_0x4b1988,_0x4d2604){await _0x4da7a8?.(_0x4b1988,_0x4d2604);}async function resolveDispatchDecision(_0x30a072,_0x25b0e2,_0x3dfd53){const _0x4b28f6={_0x798e16:0x3bb,_0x39c81f:0x365,_0x5c1cfc:0x35b,_0x21a3a8:0x3a2,_0x1ad59c:0x34e,_0x2a00ac:0x36a,_0x4f630d:0x32d,_0x446c48:0x4be,_0x3f3417:0x3eb,_0x404ea7:0x366,_0x66c936:0x41a},_0x279d26={_0x15add:0x4ae,_0x34008a:0x4c8,_0x771e93:0x4f7,_0x12deca:0x4b6,_0x2ed185:0x62,_0x57ae90:0x5a,_0x418d0a:0x70,_0x5d40d2:0x86,_0x1fa3b8:0xb2},_0x33dfb4={_0x581e32:0x37,_0x3f5bf6:0x1f},_0x4bf7c2={_0x3e9c31:0x78,_0x41f12e:0x150};if(!_0x30a072)return{'action':_0x1ce615(_0x4b28f6._0x798e16,0x3f7,_0x4b28f6._0x39c81f,_0x4b28f6._0x5c1cfc)};function _0xd876ad(_0x1b4d66,_0x2d960f,_0x275f44,_0x26030e){return _0x4c1020(_0x2d960f,_0x2d960f-_0x4bf7c2._0x3e9c31,_0x275f44-_0x4bf7c2._0x41f12e,_0x26030e-0x202);}const _0x3c872d=Promise[_0xd876ad(_0x4b28f6._0x21a3a8,0x3d0,_0x4b28f6._0x1ad59c,0x393)]()[_0xd876ad(0x363,_0x4b28f6._0x2a00ac,_0x4b28f6._0x4f630d,0x337)](()=>_0x30a072(_0x25b0e2,_0x3dfd53));function _0x1ce615(_0x38fd95,_0x2d0d95,_0x335061,_0x31d768){return _0x4c1020(_0x335061,_0x2d0d95-_0x33dfb4._0x581e32,_0x335061-_0x33dfb4._0x3f5bf6,_0x38fd95-0x25c);}if(!_0x3dfd53[_0x1ce615(0x45a,0x48d,0x4bf,_0x4b28f6._0x446c48)]){const _0x16d0a9=await _0x3c872d;return isDispatchDecision(_0x16d0a9)?_0x16d0a9:{'action':'run'};}const _0x18e680=new Promise((_0x57ac0d,_0x433611)=>{const _0x29c008={_0x2b583c:0xe0},_0x3b9989={_0x4f7a9d:0xb2},_0x2bf095={_0x4aa363:0x15c,_0x1792eb:0xf0,_0x5d820b:0x8d,_0x222923:0x78,_0x22f775:0x45,_0x4ab3f6:0x58c},_0x3d5c44=()=>{const _0x254bc5={_0x44d053:0x3be};function _0x45c357(_0x37fc1c,_0x349ee8,_0x40bc48,_0x3a93cd){return _0x41f4(_0x349ee8-_0x254bc5._0x44d053,_0x40bc48);}_0x3dfd53[_0x3996e5(-0x3e,-0x41,0x2,-0x4c)]?.[_0x3996e5(-_0x2bf095._0x4aa363,-0xff,-0x11c,-_0x2bf095._0x1792eb)](_0x3996e5(-_0x2bf095._0x5d820b,-0x7d,-0x19,-0x51),_0x3d5c44);function _0x3996e5(_0x47195e,_0x6cd542,_0x229132,_0x3924bc){return _0x41f4(_0x6cd542- -0x292,_0x3924bc);}_0x433611(toAbortError(_0x3dfd53[_0x3996e5(-_0x2bf095._0x222923,-0x41,-_0x2bf095._0x22f775,-0x79)]?.[_0x45c357(0x5d6,_0x2bf095._0x4ab3f6,0x601,0x588)]));};function _0x52ea1c(_0x1a5a68,_0xa7d815,_0x272d4b,_0x188abc){return _0xd876ad(_0x1a5a68-0x157,_0x272d4b,_0x272d4b-0x1b8,_0x1a5a68-_0x3b9989._0x4f7a9d);}function _0x1a45cc(_0x21ba12,_0x22bc1b,_0x224136,_0x38301a){return _0x1ce615(_0x22bc1b- -0x3d4,_0x22bc1b-0xc8,_0x38301a,_0x38301a-_0x29c008._0x2b583c);}if(_0x3dfd53['signal']?.[_0x52ea1c(_0x279d26._0x15add,_0x279d26._0x34008a,_0x279d26._0x771e93,_0x279d26._0x12deca)]){_0x433611(toAbortError(_0x3dfd53[_0x1a45cc(_0x279d26._0x2ed185,0x86,0x83,0x2b)][_0x1a45cc(0x69,0x3,_0x279d26._0x57ae90,-_0x279d26._0x418d0a)]));return;}_0x3dfd53[_0x1a45cc(0xf1,_0x279d26._0x5d40d2,_0x279d26._0x1fa3b8,0x35)]?.[_0x1a45cc(0x1b,0x59,0xc4,0x7e)]('abort',_0x3d5c44,{'once':!![]});}),_0x6857a=await Promise[_0xd876ad(_0x4b28f6._0x3f3417,0x3ff,0x3cb,0x3de)]([_0x3c872d,_0x18e680]);return isDispatchDecision(_0x6857a)?_0x6857a:{'action':_0x1ce615(_0x4b28f6._0x798e16,0x3d0,_0x4b28f6._0x404ea7,_0x4b28f6._0x66c936)};}async function executeCapturedToolCall(_0x24c5c6,_0x57b4cc,_0x49f3ca,_0x1aa4c4,_0x1dc7c9){const _0x566a34={_0x3c2fd3:0x154,_0x4be10c:0x1ca,_0x4a80e9:0x1c8,_0x4b5796:0x179,_0x29cfaf:0x10e,_0x50c731:0xbc,_0x23f70f:0x160,_0x3c5ea5:0x138,_0x5cecc4:0x19c,_0x272b36:0x149,_0x2012d8:0x1fb,_0x1761b3:0x136,_0x121fb3:0x124,_0x3e9318:0x178,_0x5ebff0:0x1a3,_0x56d7fc:0x19f,_0x6fc938:0x24d,_0x34da88:0x26c,_0x9660b4:0x1e0,_0x90b2fe:0x1d0,_0x2ce420:0x1e8,_0x129f25:0x1dd,_0x353f21:0x18d,_0x590907:0x172,_0x4e79e6:0x120,_0x1be1c4:0x125,_0x4cca53:0x17e,_0x1f2934:0x13c,_0x4154c4:0x1af,_0x5c9a02:0xd5,_0xd1f954:0x1ce,_0x4e8643:0x1e4,_0x2b6c5f:0x17f,_0x51962f:0x1b9,_0x132fb4:0x17b,_0xe010a4:0x23d,_0x4eed86:0x23a,_0x232eb4:0x1c4,_0x131736:0x12d,_0x4dcf81:0x14e,_0x368abc:0x15a,_0x58cc1d:0x12c,_0x1afba4:0x21e,_0x2a20a6:0x1ca,_0x5e5ff1:0x1d5,_0x88e66d:0x181,_0x236dee:0x1ca,_0x34e1d6:0x168,_0x3c5e7f:0x22b},_0x94acd2={_0x8119bd:0x4e9,_0x5f57ac:0x583,_0xccfe0a:0x51b,_0x4afa37:0x2b2},_0x1f972f={_0x3266f2:0x526,_0x5e2853:0x1ce},_0x55254f={_0x3e60c1:0x149,_0x43f73b:0x143},_0x4bdafd={_0x77ec05:0x4b},_0x49a768={_0x4ccff3:0xb8,_0x1f44c9:0x30c},_0x123f8d={..._0x49f3ca,'toolCallId':_0x57b4cc['id'],'permissionClass':resolveToolPermissionClass(_0x24c5c6),'executionAuthorization':void 0x0};throwIfAborted(_0x123f8d[_0x2335f5(-0x17e,-0x110,-0x162,-_0x566a34._0x3c2fd3)]);let _0x13c914;try{_0x13c914=await resolveDispatchDecision(_0x1aa4c4,_0x57b4cc,_0x123f8d);}catch(_0x2b025a){if(isAbortError(_0x2b025a)){const _0x5be984=createAbortedToolResult(_0x57b4cc,_0x2b025a);return await emitEvent(_0x1dc7c9,{'type':_0x2335f5(-_0x566a34._0x4be10c,-_0x566a34._0x4a80e9,-_0x566a34._0x4b5796,-0x219),'toolCall':_0x57b4cc,'result':_0x5be984},_0x123f8d),_0x5be984;}const {errorMessage:_0x1baca4,structured:_0x6e05ae}=normalizeExecutionError(_0x2b025a),_0x56fa0d=createErrorToolResult(_0x57b4cc,_0x1baca4,_0x6e05ae);return await emitEvent(_0x1dc7c9,{'type':_0x45b219(-0x15a,-0x1b9,-0x138,-0x12e),'toolCall':_0x57b4cc,'result':_0x56fa0d},_0x123f8d),_0x56fa0d;}throwIfAborted(_0x123f8d[_0x45b219(-_0x566a34._0x29cfaf,-_0x566a34._0x50c731,-0x12b,-0x172)]);if(_0x13c914['action']===_0x45b219(-0x165,-0x1cc,-_0x566a34._0x23f70f,-_0x566a34._0x3c5ea5)){const _0x469295=createRejectedToolResult(_0x57b4cc,_0x13c914[_0x45b219(-0x191,-0x1cf,-_0x566a34._0x5cecc4,-0x19d)]);return await emitEvent(_0x1dc7c9,{'type':_0x45b219(-0x18a,-_0x566a34._0x272b36,-_0x566a34._0x2012d8,-0x124),'toolCall':_0x57b4cc,'result':_0x469295},_0x123f8d),_0x469295;}if(!_0x24c5c6){const _0x1ae126=createUnknownToolResult(_0x57b4cc);return await emitEvent(_0x1dc7c9,{'type':'tool_completed','toolCall':_0x57b4cc,'result':_0x1ae126},_0x123f8d),_0x1ae126;}const _0x22b15d={..._0x123f8d,'executionAuthorization':_0x13c914[_0x45b219(-0x11a,-0xb4,-_0x566a34._0x1761b3,-0x118)]};function _0x45b219(_0x87709e,_0x31ea0d,_0x1007ab,_0x2a8e6f){return _0x4c1020(_0x1007ab,_0x31ea0d-_0x49a768._0x4ccff3,_0x1007ab-0xf4,_0x87709e- -_0x49a768._0x1f44c9);}throwIfAborted(_0x22b15d[_0x2335f5(-0x17e,-0x187,-_0x566a34._0x121fb3,-0x123)]),await emitEvent(_0x1dc7c9,{'type':_0x45b219(-_0x566a34._0x3e9318,-_0x566a34._0x5ebff0,-_0x566a34._0x56d7fc,-0x19f),'toolCall':_0x57b4cc},_0x22b15d);function _0x2335f5(_0x10e85e,_0xde1e73,_0x277d15,_0x4dccd4){return _0x249222(_0x10e85e-_0x4bdafd._0x77ec05,_0x10e85e- -0x45e,_0xde1e73,_0x4dccd4-0x2);}try{throwIfAborted(_0x22b15d[_0x45b219(-0x10e,-0xd7,-0x12f,-0xba)]);const _0x3b87d4=validateToolInput(_0x57b4cc[_0x2335f5(-_0x566a34._0x6fc938,-_0x566a34._0x34da88,-_0x566a34._0x9660b4,-0x242)],_0x24c5c6[_0x45b219(-_0x566a34._0x90b2fe,-_0x566a34._0x2ce420,-_0x566a34._0x129f25,-0x20a)]),_0x3f98fd=await _0x24c5c6['execute'](_0x3b87d4,_0x22b15d),_0x44207b=[],_0x41cac1=addAbortListener(_0x22b15d['signal'],()=>{function _0x4a0e66(_0x3e9d97,_0x402d58,_0x4e41b2,_0x4b5977){return _0x2335f5(_0x4b5977-0x722,_0x3e9d97,_0x4e41b2-_0x55254f._0x3e60c1,_0x4b5977-_0x55254f._0x43f73b);}function _0x488021(_0x39cfb4,_0x40f816,_0x2714eb,_0x28b271){return _0x2335f5(_0x40f816-_0x1f972f._0x3266f2,_0x39cfb4,_0x2714eb-_0x1f972f._0x5e2853,_0x28b271-0x2b);}void _0x3f98fd[_0x4a0e66(0x501,_0x94acd2._0x8119bd,_0x94acd2._0x5f57ac,_0x94acd2._0xccfe0a)](void 0x0)[_0x488021(0x26f,0x2e3,_0x94acd2._0x4afa37,0x33c)](()=>{});});try{throwIfAborted(_0x22b15d['signal']);let _0x504399=await _0x3f98fd[_0x2335f5(-0x177,-0x1b3,-_0x566a34._0x353f21,-0x184)]();while(!_0x504399[_0x45b219(-_0x566a34._0x590907,-0x127,-_0x566a34._0x4e79e6,-_0x566a34._0x1be1c4)]){throwIfAborted(_0x22b15d[_0x2335f5(-_0x566a34._0x4cca53,-0x1c0,-0x1a9,-0x13b)]);const _0x33eaab=normalizeToolOutputValue(_0x504399['value']);_0x44207b[_0x45b219(-_0x566a34._0x1f2934,-0x16e,-_0x566a34._0x4154c4,-_0x566a34._0x5c9a02)](_0x33eaab),await emitEvent(_0x1dc7c9,{'type':_0x45b219(-0x1b8,-_0x566a34._0xd1f954,-_0x566a34._0x4e8643,-_0x566a34._0x2b6c5f),'toolCall':_0x57b4cc,'chunk':_0x33eaab},_0x22b15d),throwIfAborted(_0x22b15d[_0x2335f5(-0x17e,-0x13d,-_0x566a34._0x51962f,-0x1f2)]),_0x504399=await _0x3f98fd['next']();}throwIfAborted(_0x22b15d['signal']);const _0x226944=_0x504399[_0x45b219(-0x1ca,-_0x566a34._0x132fb4,-_0x566a34._0xe010a4,-0x212)]===void 0x0?deriveFinalToolOutput(_0x44207b):normalizeToolOutputValue(_0x504399[_0x2335f5(-_0x566a34._0x4eed86,-0x251,-0x271,-_0x566a34._0x232eb4)]),_0x488903=createSuccessToolResult(_0x57b4cc,_0x226944,_0x44207b);return await emitEvent(_0x1dc7c9,{'type':_0x45b219(-0x15a,-_0x566a34._0x131736,-0x13c,-_0x566a34._0x4dcf81),'toolCall':_0x57b4cc,'result':_0x488903},_0x22b15d),_0x488903;}catch(_0x140d41){if(isAbortError(_0x140d41)){const _0x19958f=createAbortedToolResult(_0x57b4cc,_0x140d41,_0x44207b);return await emitEvent(_0x1dc7c9,{'type':_0x45b219(-_0x566a34._0x368abc,-0x1cf,-0x1bf,-_0x566a34._0x58cc1d),'toolCall':_0x57b4cc,'result':_0x19958f},_0x22b15d),_0x19958f;}const {errorMessage:_0x15c80c,structured:_0x387443}=normalizeExecutionError(_0x140d41),_0x4ab3c6=createErrorToolResult(_0x57b4cc,_0x15c80c,_0x387443,_0x44207b);return await emitEvent(_0x1dc7c9,{'type':_0x2335f5(-0x1ca,-0x1bb,-_0x566a34._0x1afba4,-0x1c2),'toolCall':_0x57b4cc,'result':_0x4ab3c6},_0x22b15d),_0x4ab3c6;}finally{_0x41cac1();}}catch(_0x286146){if(isAbortError(_0x286146)){const _0x26089e=createAbortedToolResult(_0x57b4cc,_0x286146);return await emitEvent(_0x1dc7c9,{'type':_0x2335f5(-_0x566a34._0x2a20a6,-0x17c,-_0x566a34._0x5e5ff1,-_0x566a34._0x88e66d),'toolCall':_0x57b4cc,'result':_0x26089e},_0x22b15d),_0x26089e;}const {errorMessage:_0x4fc11d,structured:_0x51c8ca}=normalizeExecutionError(_0x286146),_0xba06fd=createErrorToolResult(_0x57b4cc,_0x4fc11d,_0x51c8ca);return await emitEvent(_0x1dc7c9,{'type':_0x2335f5(-_0x566a34._0x236dee,-_0x566a34._0x34e1d6,-_0x566a34._0x3c5e7f,-0x1f6),'toolCall':_0x57b4cc,'result':_0xba06fd},_0x22b15d),_0xba06fd;}}async function executeToolCall(_0x4f8b60,_0x2385e5,_0x55f75d,_0x2ef274,_0x4a7eb1){const _0x41dd0b={_0xaedabc:0x1bc,_0x5804bc:0x16f,_0x945a7f:0x14b,_0x481647:0x51,_0x443bf1:0x89,_0x5e532e:0x1dc,_0x164894:0xec},_0x1ca4cb={_0xf03913:0x65,_0x469dbe:0x41e,_0x59cca3:0x4};function _0x205c34(_0x5cb598,_0x5e8f40,_0x3ac66b,_0x390862){return _0x249222(_0x5cb598-_0x1ca4cb._0xf03913,_0x5e8f40- -_0x1ca4cb._0x469dbe,_0x3ac66b,_0x390862-_0x1ca4cb._0x59cca3);}function _0x12e53b(_0xd8c784,_0x53e223,_0x35c544,_0x509df4){return _0x4c1020(_0x509df4,_0x53e223-0x125,_0x35c544-0x9c,_0x53e223- -0xf2);}const _0xd163be=_0x4f8b60[_0x205c34(-0x223,-_0x41dd0b._0xaedabc,-_0x41dd0b._0x5804bc,-_0x41dd0b._0x945a7f)](_0x2385e5[_0x12e53b(0x47,_0x41dd0b._0x481647,_0x41dd0b._0x443bf1,0xa1)]),_0x8e2591=_0xd163be?.[_0x205c34(-_0x41dd0b._0x5e532e,-0x1ee,-0x1ea,-0x215)]?.[_0x12e53b(0xe0,_0x41dd0b._0x164894,0x128,0x9d)]();try{return await executeCapturedToolCall(_0xd163be,_0x2385e5,_0x55f75d,_0x2ef274,_0x4a7eb1);}finally{_0x8e2591?.();}}function createInternalToolRuntime(_0x353462=[],_0x559645={}){const _0xebb144={_0x1404b6:0x3e,_0x4aeb8f:0x2e8,_0xcdb8e8:0x2a4,_0x1089a7:0x2ac},_0x568816={_0x49c5a1:0x63,_0x2d064b:0x6c,_0x3fc8fe:0x120,_0x74b76e:0x128},_0x8c7290={_0x27a7ae:0x56},_0x1d3ba3={_0x263a29:0x42c,_0xb769ce:0x413},_0x2844b4={_0x5419ca:0x1a6};let _0x4cc77e=new ToolRegistry(_0x353462);return{'listToolSchemas'(){function _0x30f1f7(_0x2e50ba,_0x2dd0eb,_0x4f89dd,_0x1b6414){return _0x41f4(_0x2dd0eb-_0x2844b4._0x5419ca,_0x2e50ba);}return _0x4cc77e[_0x30f1f7(0x357,0x3ba,_0x1d3ba3._0x263a29,_0x1d3ba3._0xb769ce)]();},'setTools'(_0x416be6){_0x4cc77e=new ToolRegistry(_0x416be6);},async 'executeCalls'(_0x3c5213,_0xec3c16){function _0xd3cbf(_0x5b6792,_0x5cc788,_0x2509bc,_0x2fa604){return _0x41f4(_0x5cc788-_0x8c7290._0x27a7ae,_0x5b6792);}function _0x4e479a(_0x29f934,_0x45a99c,_0x5da838,_0x2c784e){return _0x41f4(_0x29f934- -0x1ef,_0x2c784e);}return await Promise[_0x4e479a(0x2e,-0x1f,-_0xebb144._0x1404b6,0x4a)](_0x3c5213[_0xd3cbf(_0xebb144._0x4aeb8f,_0xebb144._0xcdb8e8,_0xebb144._0x1089a7,0x284)](async _0x57dc80=>{const _0x4cc844={_0xe99c9b:0x1ba,_0x42cd09:0x9a,_0xbad639:0x105},_0x527aea={_0x55a72e:0xfc};function _0x181488(_0x5a05ed,_0x3a5a71,_0x2249e6,_0x3cf654){return _0xd3cbf(_0x5a05ed,_0x3a5a71- -0x3ac,_0x2249e6-0x144,_0x3cf654-_0x527aea._0x55a72e);}function _0x153afa(_0x33edd1,_0x126c33,_0x2668ed,_0x2dd122){return _0xd3cbf(_0x2668ed,_0x33edd1- -_0x4cc844._0xe99c9b,_0x2668ed-_0x4cc844._0x42cd09,_0x2dd122-_0x4cc844._0xbad639);}return await executeToolCall(_0x4cc77e,_0x57dc80,_0xec3c16,_0x559645[_0x153afa(_0x568816._0x49c5a1,0xbc,_0x568816._0x2d064b,0x31)],_0x559645[_0x181488(-_0x568816._0x3fc8fe,-_0x568816._0x74b76e,-0x10a,-0xcb)]);}));},async 'execute'(_0x1350b7,_0x5091ec){const [_0xd134f]=await this['executeCalls']([_0x1350b7],_0x5091ec);return _0xd134f;}};}function getOrderedObserverExtensions(_0x161f8d,_0xecea3e){const _0x2979ca={_0x3f59c3:0x624,_0x2ef662:0x5e5},_0x8a260={_0x12453f:0x566,_0x5ef658:0x537,_0x4f1aec:0x573,_0x2cae19:0x5be,_0x283044:0x5c0,_0x241546:0x55,_0x2bc921:0x544,_0x4c1038:0x3c,_0x3f14b0:0x15,_0x5652c8:0x87},_0x27a68b={_0x18b0e2:0x53d,_0x471213:0xc3},_0x254730={_0x31e838:0x5a6,_0x4046e2:0x554,_0x147fc6:0x530,_0x165f32:0x521,_0x3d6f9f:0x4d3},_0x1f53a0={_0x13f2c0:0x56,_0x5cca21:0x4c,_0x4b5321:0x3f0};function _0x52ccd3(_0x4b9f7c,_0x30b78f,_0x3c469b,_0x4dba34){return _0x4c1020(_0x4b9f7c,_0x30b78f-_0x1f53a0._0x13f2c0,_0x3c469b-_0x1f53a0._0x5cca21,_0x3c469b-_0x1f53a0._0x4b5321);}return _0x161f8d[_0x52ccd3(0x613,_0x2979ca._0x3f59c3,0x5de,_0x2979ca._0x2ef662)](_0x3c409b=>{const _0x2cdad2={_0x51fba1:0x46},_0x3ac7f7={_0x4729c5:0x5c,_0x2370e4:0x169};function _0xec8db1(_0x5d9525,_0x37b0c4,_0x4ffa6d,_0xee629e){return _0x52ccd3(_0xee629e,_0x37b0c4-_0x3ac7f7._0x4729c5,_0x37b0c4- -0x3a,_0xee629e-_0x3ac7f7._0x2370e4);}function _0x1b5108(_0x4d3a6b,_0x13da8c,_0x229201,_0x38e441){return _0x52ccd3(_0x13da8c,_0x13da8c-0x3b,_0x4d3a6b-_0x2cdad2._0x51fba1,_0x38e441-0xe6);}return _0x3c409b[_0xec8db1(0x537,0x588,0x579,_0x254730._0x31e838)]!==![]&&_0x3c409b['stage']===_0xecea3e&&_0x3c409b[_0xec8db1(0x4ef,_0x254730._0x4046e2,_0x254730._0x147fc6,0x521)]===_0xec8db1(_0x254730._0x165f32,0x530,0x4d4,_0x254730._0x3d6f9f);})['sort']((_0xfcde21,_0x7c5485)=>{const _0x356abc={_0x275f94:0x11f};function _0x7b27e6(_0x119017,_0x49aa50,_0x197373,_0x7c5a6f){return _0x52ccd3(_0x49aa50,_0x49aa50-0x18c,_0x119017- -_0x27a68b._0x18b0e2,_0x7c5a6f-_0x27a68b._0x471213);}if(_0xfcde21[_0x2a180e(0x5b6,_0x8a260._0x12453f,_0x8a260._0x5ef658,0x54d)]===!![]&&_0x7c5485['terminal']!==!![])return 0x1;function _0x2a180e(_0x5254bf,_0x49ad28,_0x1a8470,_0x1dae2c){return _0x52ccd3(_0x1a8470,_0x49ad28-0x18e,_0x1dae2c- -0x35,_0x1dae2c-_0x356abc._0x275f94);}if(_0xfcde21[_0x2a180e(_0x8a260._0x4f1aec,_0x8a260._0x2cae19,_0x8a260._0x283044,0x54d)]!==!![]&&_0x7c5485[_0x7b27e6(0x45,0xa7,0x6,_0x8a260._0x241546)]===!![])return-0x1;return _0xfcde21[_0x2a180e(_0x8a260._0x12453f,0x57d,0x4eb,_0x8a260._0x2bc921)]-_0x7c5485[_0x7b27e6(_0x8a260._0x4c1038,-_0x8a260._0x3f14b0,0x66,_0x8a260._0x5652c8)];});}function getOrderedTransformerExtensions(_0x5e8f75,_0x14667b){const _0x3be9a9={_0x45a4df:0x403,_0x41fee4:0x43b,_0x327eb8:0x282,_0x1fde92:0x297},_0x4bb28a={_0x131088:0xe,_0x14311f:0x7b,_0x1ca0d2:0x10,_0x5d7b69:0x61},_0x303ca0={_0x185f63:0x95},_0x3fa3a5={_0x2ba80a:0x184},_0x179505={_0x18d7a3:0x10e};function _0x4941ce(_0x45d607,_0x4811a6,_0x3390be,_0x3a0ef3){return _0x4c1020(_0x4811a6,_0x4811a6-_0x179505._0x18d7a3,_0x3390be-0x1d6,_0x45d607-0x9c);}function _0x586672(_0x5b7464,_0x30c029,_0x1324be,_0xf65d68){return _0x249222(_0x5b7464-0x7d,_0x1324be-_0x3fa3a5._0x2ba80a,_0x30c029,_0xf65d68-0x26);}return _0x5e8f75[_0x586672(0x3de,_0x3be9a9._0x45a4df,0x454,_0x3be9a9._0x41fee4)](_0x101b1f=>{const _0x124d4b={_0x2e93b7:0xdc};function _0x420115(_0x396062,_0x45bce2,_0x157c77,_0x1c62b6){return _0x586672(_0x396062-_0x124d4b._0x2e93b7,_0x1c62b6,_0x45bce2- -0x3fc,_0x1c62b6-0x107);}function _0x4edde3(_0xd307ac,_0x132174,_0x21acd8,_0x393407){return _0x586672(_0xd307ac-_0x303ca0._0x185f63,_0x132174,_0x393407- -0x449,_0x393407-0x120);}return _0x101b1f['enabled']!==![]&&_0x101b1f[_0x4edde3(-0x54,0x7,-0x3f,-_0x4bb28a._0x131088)]===_0x14667b&&_0x101b1f[_0x420115(0x55,0x8,_0x4bb28a._0x14311f,-0x3f)]===_0x420115(0x6,_0x4bb28a._0x1ca0d2,_0x4bb28a._0x5d7b69,0x16);})[_0x4941ce(_0x3be9a9._0x327eb8,_0x3be9a9._0x1fde92,_0x3be9a9._0x1fde92,0x233)]((_0x20d155,_0x172e8a)=>_0x20d155[_0x4941ce(0x225,0x262,0x22f,0x22f)]-_0x172e8a[_0x586672(0x41f,0x413,0x3ef,0x40e)]);}function createExtensionRegistry(){const _0x42de25={_0x3437ea:0x458,_0x4344c8:0x45c,_0x330e5c:0x4c5},_0x5db61f={_0x50f178:0x2aa},_0x4b4284={_0x5e54e1:0x59,_0x50011c:0x32},_0x1c8b48={_0x4c1e40:0x9d,_0x2cbd5f:0x7e,_0x4e1197:0x1cc,_0x10f460:0x1bf,_0x468bc9:0xe,_0x500fb6:0x68,_0x1baf27:0x4,_0x27bbf7:0x15,_0x1130e7:0xb7,_0x4933a4:0x81,_0x315fdd:0x62,_0x572344:0x8d,_0x533bdd:0x22d,_0x558a62:0x24c,_0x3c5463:0x17e,_0xb1be42:0x196,_0x4c3532:0x183,_0x2fbb95:0x1b1,_0x314bf7:0x1bd,_0x4b4a70:0x1f0,_0x52eb82:0x162,_0x48e810:0x102},_0x4588c4={_0x3e4e9c:0x5},_0x204215=[];return{'register'(_0x526946){const _0x293a81={_0x1e31ce:0x137};if(_0x526946[_0x4b7feb(0x67,0xba,_0x1c8b48._0x4c1e40,_0x1c8b48._0x2cbd5f)]===_0x7b8912(_0x1c8b48._0x4e1197,0x1d2,0x18a,_0x1c8b48._0x10f460)&&_0x526946['enabled']!==![]&&_0x526946['terminal']===!![]){const _0x2a1db6=_0x204215[_0x4b7feb(-_0x1c8b48._0x468bc9,_0x1c8b48._0x500fb6,_0x1c8b48._0x1baf27,_0x1c8b48._0x27bbf7)](_0xa6d4d2=>_0xa6d4d2[_0x7b8912(0x1f7,0x1f6,0x216,0x256)]===_0x7b8912(0x243,0x1d2,0x197,0x18b)&&_0xa6d4d2['enabled']!==![]&&_0xa6d4d2[_0x4b7feb(0x152,0xf1,0x116,0xf4)]===_0x526946[_0x7b8912(0x201,0x22d,0x1d5,0x217)]&&_0xa6d4d2[_0x4b7feb(0xbe,0xae,0xce,0xd9)]===!![]);if(_0x2a1db6)throw new Error(_0x4b7feb(0x11e,_0x1c8b48._0x1130e7,0x97,0x10e)+_0x526946['id']+_0x4b7feb(0x7c,_0x1c8b48._0x4933a4,_0x1c8b48._0x315fdd,_0x1c8b48._0x572344)+_0x526946[_0x7b8912(0x1e8,_0x1c8b48._0x533bdd,_0x1c8b48._0x558a62,0x287)]+_0x7b8912(_0x1c8b48._0x3c5463,_0x1c8b48._0xb1be42,_0x1c8b48._0x4c3532,_0x1c8b48._0x2fbb95)+_0x2a1db6['id']+_0x7b8912(_0x1c8b48._0x314bf7,0x1d0,_0x1c8b48._0x4b4a70,_0x1c8b48._0x52eb82));}function _0x4b7feb(_0xb07f98,_0x35306c,_0x2d3266,_0x29568d){return _0x41f4(_0x35306c- -_0x293a81._0x1e31ce,_0x29568d);}function _0x7b8912(_0x421615,_0xf89b0b,_0x401526,_0x1b5478){return _0x41f4(_0xf89b0b-_0x4588c4._0x3e4e9c,_0x401526);}_0x204215[_0x4b7feb(0x79,0xec,_0x1c8b48._0x48e810,0xb9)]({..._0x526946});},async 'runTransformers'(_0x373f34,_0x251ae8,_0x2814ec){const _0xf852e5={_0x1f54a7:0x15f};function _0x564497(_0x508758,_0x225e5e,_0x51ca55,_0x18723c){return _0x41f4(_0x51ca55- -_0xf852e5._0x1f54a7,_0x18723c);}let _0x916801=_0x251ae8;for(const _0x5c13ff of getOrderedTransformerExtensions(_0x204215,_0x373f34)){_0x916801=await _0x5c13ff[_0x564497(0x5f,_0x4b4284._0x5e54e1,0x53,_0x4b4284._0x50011c)](_0x916801,_0x2814ec);}return _0x916801;},async 'runObservers'(_0x24856c,_0x28720b,_0x556395){function _0x2d3587(_0x31837d,_0x1752f4,_0x3bec8a,_0x17fac9){return _0x41f4(_0x3bec8a-_0x5db61f._0x50f178,_0x31837d);}for(const _0x34751d of getOrderedObserverExtensions(_0x204215,_0x24856c)){await _0x34751d[_0x2d3587(0x442,_0x42de25._0x3437ea,_0x42de25._0x4344c8,_0x42de25._0x330e5c)](_0x28720b,_0x556395);}}};}function createEmptySnapshot(){return{'totalTokens':0x0,'totalInputTokens':0x0,'totalOutputTokens':0x0,'totalReasoningTokens':0x0,'requestCount':0x0,'modelCallCount':0x0,'toolCallCount':0x0,'totalModelTimeMs':0x0,'currentTokens':0x0,'currentInputTokens':0x0,'currentOutputTokens':0x0,'currentReasoningTokens':0x0,'currentModelTimeMs':0x0,'totalCostUsdTicks':0x0,'totalReportedCostUsdTicks':0x0,'totalEstimatedCostUsdTicks':0x0,'reportedCostCallCount':0x0,'estimatedCostCallCount':0x0,'unpricedModelCallCount':0x0,'historicalMetricsComplete':!![],'missingHistoricalModelCallCount':0x0};}function _0x249222(_0x53dc23,_0x3a8412,_0x53a0aa,_0x222d85){return _0x41f4(_0x3a8412-0x8f,_0x53a0aa);}function applyModelCall(_0x104ae4,_0x7a6c60){const _0x428778={_0x5f4e7c:0x196,_0x29837c:0xff,_0x20af32:0x100,_0x4186d4:0x15e,_0x445d2c:0x150,_0x8b0327:0x1ab,_0x21c8b1:0x137,_0x2169dd:0x176,_0x2b6412:0x2a,_0xe15786:0x1,_0x570888:0x5c,_0x109957:0x8c,_0xae500d:0xe5,_0xd7ce63:0x11c,_0x4a7ce1:0x6b,_0x2163ec:0xc8,_0x36af52:0x8a,_0x5a388b:0x221,_0x8f24f0:0x1bc,_0x437d7d:0x4e,_0xbb3cc1:0x30,_0x5db66f:0x116,_0x2074c9:0x115,_0x15aec2:0x17f,_0x274c0c:0x130,_0x3857ae:0x13,_0x4b4b1b:0x38,_0x42c499:0x73,_0x53055b:0x2d,_0x3291d3:0x196,_0x28afdc:0x17d,_0x2c8c8d:0x10e,_0x56d8c1:0x2,_0x4a95f6:0x42,_0x405ae2:0x175,_0x2cc0e6:0x12a,_0xae4e27:0x1b6,_0x3cbf63:0x16a,_0x24f667:0x1ae,_0x58af6a:0x168,_0x5e22ff:0x1d1,_0x5c2b9a:0x245,_0x36fb26:0x179},_0x4cf2a4={_0x23964c:0x1b5},_0x55a963={_0x539102:0x50},_0x230f43=_0x7a6c60[_0x565c9f(-_0x428778._0x5f4e7c,-_0x428778._0x29837c,-_0x428778._0x20af32,-0x133)],_0x4f3c23=_0x230f43['inputTokens'],_0x342dd7=_0x230f43['outputTokens'],_0xc6df69=_0x230f43[_0x565c9f(-0x145,-_0x428778._0x4186d4,-0x1d3,-0x169)]??0x0,_0x14e6de=_0x4f3c23+_0x342dd7,_0x755c9b=_0x230f43[_0x565c9f(-_0x428778._0x445d2c,-0x16e,-_0x428778._0x8b0327,-0x171)]?.[_0x565c9f(-_0x428778._0x21c8b1,-0x1ac,-_0x428778._0x2169dd,-0x1ab)],_0x52eaa7=_0x230f43[_0x479985(-_0x428778._0x2b6412,-_0x428778._0xe15786,-_0x428778._0x570888,-_0x428778._0x109957)]?.['amountUsdTicks'];function _0x565c9f(_0x98c2f9,_0x59a99b,_0x2f5d19,_0x9fd05d){return _0x249222(_0x98c2f9-_0x55a963._0x539102,_0x9fd05d- -0x3d8,_0x59a99b,_0x9fd05d-0xe);}const _0x5d17e5=_0x755c9b??_0x52eaa7,{currentReportedCostUsdTicks:_0x301f61,currentEstimatedCostUsdTicks:_0x5aa88f,..._0x590157}=_0x104ae4;function _0x479985(_0xe9a1ab,_0x5b85fd,_0x2993ca,_0x25fbc5){return _0x4c1020(_0x5b85fd,_0x5b85fd-0x38,_0x2993ca-0x2a,_0xe9a1ab- -_0x4cf2a4._0x23964c);}return{..._0x590157,'totalTokens':_0x590157['totalTokens']+_0x14e6de,'totalInputTokens':_0x590157[_0x565c9f(-0x181,-0xc0,-_0x428778._0xae500d,-_0x428778._0xd7ce63)]+_0x4f3c23,'totalOutputTokens':_0x590157[_0x479985(-_0x428778._0x4a7ce1,-0x4f,-0x27,-0x61)]+_0x342dd7,'totalReasoningTokens':_0x590157['totalReasoningTokens']+_0xc6df69,'modelCallCount':_0x590157[_0x565c9f(-_0x428778._0x2163ec,-0x9d,-_0x428778._0x36af52,-0xf9)]+0x1,'totalModelTimeMs':_0x590157[_0x565c9f(-0x18f,-0x14e,-_0x428778._0x5a388b,-_0x428778._0x8f24f0)]+_0x7a6c60[_0x479985(-_0x428778._0x437d7d,-_0x428778._0xbb3cc1,-0x69,-0x69)],'currentTokens':_0x14e6de,'currentInputTokens':_0x4f3c23,'currentOutputTokens':_0x342dd7,'currentReasoningTokens':_0xc6df69,'currentModelTimeMs':_0x7a6c60['modelTimeMs'],..._0x590157[_0x565c9f(-0xdc,-_0x428778._0x5db66f,-0x177,-_0x428778._0x2074c9)]&&_0x14e6de>0x0?{'contextWindowUsage':_0x14e6de/_0x590157[_0x565c9f(-0x12d,-_0x428778._0x15aec2,-_0x428778._0x274c0c,-0x115)]}:{},'totalCostUsdTicks':_0x5d17e5===void 0x0?_0x590157[_0x479985(-_0x428778._0x3857ae,_0x428778._0x4b4b1b,-0xe,-_0x428778._0x42c499)]:_0x590157[_0x479985(-0x13,0x28,0x37,_0x428778._0x53055b)]+_0x5d17e5,'totalReportedCostUsdTicks':_0x755c9b===void 0x0?_0x590157[_0x565c9f(-_0x428778._0x3291d3,-0x138,-0x17c,-_0x428778._0x28afdc)]:_0x590157['totalReportedCostUsdTicks']+_0x755c9b,'totalEstimatedCostUsdTicks':_0x52eaa7===void 0x0?_0x590157[_0x565c9f(-_0x428778._0x2074c9,-0x15b,-_0x428778._0x2c8c8d,-0x13f)]:_0x590157[_0x479985(_0x428778._0x56d8c1,0x5d,-0x15,_0x428778._0x4a95f6)]+_0x52eaa7,'reportedCostCallCount':_0x755c9b===void 0x0?_0x590157[_0x565c9f(-0x1d0,-0x1b0,-0x116,-_0x428778._0x405ae2)]:_0x590157[_0x565c9f(-_0x428778._0x2cc0e6,-_0x428778._0xae4e27,-0x1e9,-0x175)]+0x1,'estimatedCostCallCount':_0x52eaa7===void 0x0?_0x590157['estimatedCostCallCount']:_0x590157[_0x565c9f(-_0x428778._0x3cbf63,-0x160,-0x1df,-0x193)]+0x1,'unpricedModelCallCount':_0x755c9b===void 0x0&&_0x52eaa7===void 0x0?_0x590157[_0x565c9f(-0x170,-_0x428778._0x24f667,-_0x428778._0x58af6a,-_0x428778._0x5e22ff)]+0x1:_0x590157[_0x565c9f(-_0x428778._0x5c2b9a,-0x161,-_0x428778._0x36fb26,-_0x428778._0x5e22ff)],..._0x755c9b!==void 0x0?{'currentReportedCostUsdTicks':_0x755c9b}:{},..._0x52eaa7!==void 0x0?{'currentEstimatedCostUsdTicks':_0x52eaa7}:{}};}function createAgentMetrics(_0x2f2afa={}){const _0x46de24={_0x27665a:0x25d,_0x387f7c:0x20d},_0x228591={_0x22751a:0x2a,_0xb5305c:0xa2,_0x3f4ccb:0x42,_0x24614a:0x4fc,_0x3bd4da:0x508,_0x461064:0x566,_0x3deb57:0x5d7,_0x344420:0x4d0,_0x2a10cf:0x5af,_0x3cb91e:0x591,_0x4a8c4f:0x54b,_0x56ed80:0x582,_0x7ed05d:0x526,_0x56ed17:0x521,_0x30f678:0x4ef},_0x54a48d={_0x47153a:0x329,_0x508236:0x341,_0x2bd38f:0x378,_0x4e968a:0x375,_0x4d1e48:0x331,_0x47ed7e:0x1fa,_0x4c417d:0x2bf,_0x170c58:0x2f7,_0xef0f42:0x2b3,_0x580fe4:0x28b,_0x3052c1:0x1c0,_0x53b022:0x1be,_0x421115:0x289,_0x25b385:0x1dd,_0x3d1cbe:0x1d5,_0xf4952a:0x217,_0x3b5f91:0x27a,_0x47b9aa:0x236,_0x33930f:0x2b2,_0x50c722:0x355,_0x44db5c:0x16a,_0x443b83:0x1c8,_0x5a67ad:0x1b7,_0x141eed:0x184,_0x304b98:0x26d,_0x4ecf95:0x224,_0x454d02:0x2bd};let _0x311594=createEmptySnapshot();const _0x5aa5c6=new Set();let _0x4d37f0;const _0x5477e9=()=>{const _0x4f0b33={..._0x311594};for(const _0x45590d of _0x5aa5c6)_0x45590d(_0x4f0b33);};return{'getSnapshot'(){return{..._0x311594};},'recordEvent'(_0x577884){const _0xa907ec={_0x4f0a89:0x3d1};if(_0x577884[_0x1b9884(_0x54a48d._0x47153a,0x351,_0x54a48d._0x508236,0x311)]==='model_request'){_0x4d37f0=Date[_0x1b9884(_0x54a48d._0x2bd38f,_0x54a48d._0x4e968a,0x391,_0x54a48d._0x4d1e48)]();const _0x3ad863=_0x2f2afa['getContextWindowLimit']?.(_0x577884[_0x11d476(-_0x54a48d._0x47ed7e,-0x25a,-0x269,-_0x54a48d._0x4c417d)]);_0x3ad863!==void 0x0&&(_0x311594={..._0x311594,'contextWindowLimit':_0x3ad863},_0x5477e9());return;}if(_0x577884[_0x1b9884(_0x54a48d._0x170c58,0x371,_0x54a48d._0x508236,0x385)]===_0x11d476(-_0x54a48d._0xef0f42,-0x25e,-_0x54a48d._0x580fe4,-0x27d)){const _0x2cf476=_0x4d37f0===void 0x0?0x0:Date[_0x11d476(-_0x54a48d._0x3052c1,-0x1d4,-0x200,-_0x54a48d._0x53b022)]()-_0x4d37f0;_0x4d37f0=void 0x0,_0x311594=applyModelCall(_0x311594,{'usage':_0x577884[_0x11d476(-_0x54a48d._0x421115,-0x238,-_0x54a48d._0x25b385,-_0x54a48d._0x3d1cbe)]['usage'],'modelTimeMs':_0x577884[_0x11d476(-0x1ca,-_0x54a48d._0xf4952a,-0x1b3,-_0x54a48d._0x3b5f91)]??_0x2cf476}),_0x5477e9();return;}function _0x11d476(_0x46de5a,_0x48da5e,_0x381279,_0x4a00ce){return _0x41f4(_0x48da5e- -_0xa907ec._0x4f0a89,_0x4a00ce);}if(_0x577884[_0x11d476(-0x266,-0x224,-_0x54a48d._0x47b9aa,-0x1ba)]===_0x1b9884(_0x54a48d._0x33930f,0x30b,0x30a,_0x54a48d._0x50c722)){_0x311594={..._0x311594,'toolCallCount':_0x311594[_0x11d476(-_0x54a48d._0x44db5c,-_0x54a48d._0x443b83,-_0x54a48d._0x5a67ad,-_0x54a48d._0x141eed)]+0x1},_0x5477e9();return;}function _0x1b9884(_0x155716,_0xdac556,_0x7beafc,_0x546f42){return _0x41f4(_0x7beafc-0x194,_0x546f42);}_0x577884[_0x11d476(-_0x54a48d._0x304b98,-_0x54a48d._0x4ecf95,-0x264,-0x1fa)]===_0x1b9884(0x313,0x35a,0x31d,0x2df)&&(_0x311594={..._0x311594,'requestCount':_0x311594[_0x11d476(-_0x54a48d._0x454d02,-0x25c,-0x1fd,-0x2b8)]+0x1},_0x5477e9());},'reset'(){_0x311594=createEmptySnapshot(),_0x4d37f0=void 0x0,_0x5477e9();},'restore'(_0x3f8fa4){const _0x1075f1={_0xbcbb48:0x350};let _0x23b6e8=createEmptySnapshot();for(const _0x59eafe of _0x3f8fa4[_0x196dd2(_0x228591._0x22751a,_0x228591._0xb5305c,-0x2a,_0x228591._0x3f4ccb)]){_0x23b6e8=applyModelCall(_0x23b6e8,{'usage':_0x59eafe[_0x3f281c(_0x228591._0x24614a,_0x228591._0x3bd4da,_0x228591._0x461064,_0x228591._0x3deb57)],'modelTimeMs':_0x59eafe[_0x3f281c(0x518,0x4af,0x50a,_0x228591._0x344420)]});}function _0x3f281c(_0x585e51,_0x513497,_0x36185f,_0x514043){return _0x41f4(_0x36185f-_0x1075f1._0xbcbb48,_0x585e51);}_0x311594={..._0x23b6e8,'requestCount':_0x3f8fa4['modelCalls'][_0x3f281c(_0x228591._0x2a10cf,0x556,_0x228591._0x3cb91e,_0x228591._0x4a8c4f)](_0x32f8d6=>_0x32f8d6['completesRequest'])['length'],'toolCallCount':_0x3f8fa4[_0x3f281c(_0x228591._0x56ed80,0x591,0x559,_0x228591._0x7ed05d)],'historicalMetricsComplete':_0x3f8fa4['missingModelCallCount']===0x0,'missingHistoricalModelCallCount':_0x3f8fa4[_0x3f281c(_0x228591._0x56ed17,_0x228591._0x30f678,0x544,0x51e)]};function _0x196dd2(_0x29ab35,_0xe03b50,_0x5599d7,_0x4d1cf9){return _0x41f4(_0x4d1cf9- -0x152,_0xe03b50);}_0x4d37f0=void 0x0,_0x5477e9();},'subscribe'(_0x16a590){_0x5aa5c6[_0x544bd4(_0x46de24._0x27665a,0x217,_0x46de24._0x387f7c,0x26f)](_0x16a590);function _0x544bd4(_0x5901c4,_0x444ab4,_0x374e0d,_0x9624f2){return _0x41f4(_0x5901c4-0x12,_0x9624f2);}return()=>{const _0x52ec99={_0x42c178:0xa,_0x12a762:0xc1};function _0x474aaf(_0x16f5da,_0x466bb9,_0x380248,_0x38b2ef){return _0x544bd4(_0x16f5da-0x138,_0x466bb9-_0x52ec99._0x42c178,_0x380248-_0x52ec99._0x12a762,_0x380248);}_0x5aa5c6[_0x474aaf(0x2da,0x31c,0x265,0x331)](_0x16a590);};}};}function makeExtensionContext(_0x544622){return{'state':_0x544622};}async function runStage(_0x55d93e,_0x4b34f0,_0x3a4992,_0x9baf6){const _0xebf001={_0x449eeb:0x195,_0x147d29:0x175},_0x39274e={_0x3343d1:0x45c};function _0x1e6d6f(_0x20eb3f,_0x4a9ede,_0x75c46,_0x5d11d3){return _0x249222(_0x20eb3f-0x1ee,_0x5d11d3- -_0x39274e._0x3343d1,_0x20eb3f,_0x5d11d3-0x114);}const _0x2ec11b=await _0x55d93e[_0x1e6d6f(-0x113,-_0xebf001._0x449eeb,-_0xebf001._0x147d29,-0x189)](_0x4b34f0,_0x3a4992,_0x9baf6);return await _0x55d93e['runObservers'](_0x4b34f0,_0x2ec11b,_0x9baf6),_0x2ec11b;}async function emitEvent2(_0xd5ccef,_0x26a96a,_0x5c38c2){await _0xd5ccef?.(_0x26a96a,_0x5c38c2);}function _0x41f4(_0x178b05,_0x51bd20){_0x178b05=_0x178b05-0x172;const _0x4ea00d=_0x4ea0();let _0x41f417=_0x4ea00d[_0x178b05];if(_0x41f4['RlXaso']===undefined){var _0x3c3fe7=function(_0x4c9987){const _0x1dfc97='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x49290f='',_0x18b697='';for(let _0x812f85=0x0,_0x3f8560,_0x4934bc,_0x5f2ca3=0x0;_0x4934bc=_0x4c9987['charAt'](_0x5f2ca3++);~_0x4934bc&&(_0x3f8560=_0x812f85%0x4?_0x3f8560*0x40+_0x4934bc:_0x4934bc,_0x812f85++%0x4)?_0x49290f+=String['fromCharCode'](0xff&_0x3f8560>>(-0x2*_0x812f85&0x6)):0x0){_0x4934bc=_0x1dfc97['indexOf'](_0x4934bc);}for(let _0x208724=0x0,_0x4800fe=_0x49290f['length'];_0x208724<_0x4800fe;_0x208724++){_0x18b697+='%'+('00'+_0x49290f['charCodeAt'](_0x208724)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x18b697);};_0x41f4['TmGFLm']=_0x3c3fe7,_0x41f4['lxzWyO']={},_0x41f4['RlXaso']=!![];}const _0x137f99=_0x4ea00d[0x0],_0x41e972=_0x178b05+_0x137f99,_0x1d2414=_0x41f4['lxzWyO'][_0x41e972];return!_0x1d2414?(_0x41f417=_0x41f4['TmGFLm'](_0x41f417),_0x41f4['lxzWyO'][_0x41e972]=_0x41f417):_0x41f417=_0x1d2414,_0x41f417;}function replaceToolUseBlocks(_0x124cc1,_0x38e9dd){const _0x5ce953={_0x460586:0xde,_0x74c9d6:0x4e,_0x143349:0x78},_0x4e236c={_0x90895c:0x1cf,_0x63d92f:0x96};let _0xa7785e=0x0;function _0x1743b9(_0x13e227,_0x183c94,_0x1cd320,_0x4673a6){return _0x4c1020(_0x183c94,_0x183c94-_0x4e236c._0x90895c,_0x1cd320-0x10f,_0x1cd320- -_0x4e236c._0x63d92f);}return{..._0x124cc1,'content':_0x124cc1[_0x1743b9(_0x5ce953._0x460586,_0x5ce953._0x74c9d6,0x89,_0x5ce953._0x143349)]['map'](_0x279fed=>{if(_0x279fed['type']!==_0xffd23(0x476,0x4f6,0x484,0x41d))return _0x279fed;const _0x163a33=_0x38e9dd[_0xa7785e];function _0xffd23(_0x3ada6b,_0x5c4dc7,_0x3f4a44,_0x2e83a7){return _0x1743b9(_0x3ada6b-0x90,_0x5c4dc7,_0x3f4a44-0x382,_0x2e83a7-0x182);}return _0xa7785e+=0x1,structuredClone(_0x163a33);})};}function createAssistantMessageId(_0x195a7f,_0x2cd70b){const _0x283cd9={_0x488b5e:0x40e,_0x2a7d98:0x414},_0xb444ff={_0x1e13c7:0xe4,_0x5ea10e:0x13f};function _0x21494d(_0x8469f5,_0x5a70ca,_0x137817,_0x216020){return _0x249222(_0x8469f5-_0xb444ff._0x1e13c7,_0x216020-_0xb444ff._0x5ea10e,_0x5a70ca,_0x216020-0x137);}return _0x195a7f+_0x21494d(0x3b1,0x44a,_0x283cd9._0x488b5e,_0x283cd9._0x2a7d98)+_0x2cd70b;}function createReasoningMessageId(_0x3b8cc7){const _0x134ca2={_0x2f2532:0xdb};function _0x2a2264(_0x504d3c,_0x3ec369,_0x5a0d9e,_0x50b2e9){return _0x249222(_0x504d3c-_0x134ca2._0x2f2532,_0x5a0d9e-0x285,_0x504d3c,_0x50b2e9-0x16b);}return _0x3b8cc7+_0x2a2264(0x4f8,0x542,0x530,0x539);}function withMessageId(_0x529542,_0x555d40){if(_0x529542['id']===_0x555d40)return _0x529542;return{..._0x529542,'id':_0x555d40};}function createAssistantChunkEvent(_0x10d306,_0x275103){const _0x3444e7={_0x23a9b3:0x1b3,_0x292e48:0x1f4,_0x594bbd:0x1d8,_0x4b8159:0x1f0,_0x2f17c2:0x250,_0x139185:0x246,_0x1d5674:0x28c,_0x470ebf:0x2a6,_0x25937a:0x230,_0x360e90:0x1be,_0x1d001a:0x23f,_0x52016a:0x270,_0x4c33c5:0x266,_0x2df031:0x2af},_0x506702={_0x3132f2:0xac},_0x5cfb9f={_0x1cd0a3:0x191,_0x575294:0x430,_0x469604:0x1dd};function _0x4866fe(_0x2a7174,_0x437453,_0x22ae4d,_0x1f29dc){return _0x249222(_0x2a7174-_0x5cfb9f._0x1cd0a3,_0x22ae4d- -_0x5cfb9f._0x575294,_0x2a7174,_0x1f29dc-_0x5cfb9f._0x469604);}if(_0x10d306[_0x4866fe(-_0x3444e7._0x23a9b3,-0x25e,-_0x3444e7._0x292e48,-_0x3444e7._0x594bbd)]!=='content_delta')return void 0x0;if(_0x10d306[_0x513a2d(0x1d0,_0x3444e7._0x4b8159,0x24b,_0x3444e7._0x2f17c2)]===void 0x0)return void 0x0;function _0x513a2d(_0x627840,_0x2e416e,_0xb647c,_0x1ce2e1){return _0x4c1020(_0xb647c,_0x2e416e-0xe6,_0xb647c-0xaf,_0x2e416e-_0x506702._0x3132f2);}return{'type':_0x513a2d(_0x3444e7._0x139185,0x273,_0x3444e7._0x1d5674,_0x3444e7._0x470ebf),'index':_0x10d306['index']??0x0,'messageId':_0x275103,'chunk':{'type':_0x513a2d(0x271,_0x3444e7._0x25937a,_0x3444e7._0x360e90,_0x3444e7._0x1d001a),'index':_0x10d306[_0x513a2d(_0x3444e7._0x52016a,_0x3444e7._0x4c33c5,_0x3444e7._0x2df031,0x269)]??0x0,'text':_0x10d306['text']}};}function createToolUseChunkEvent(_0x121020,_0x2b6e4a){const _0x3034a1={_0x17831c:0x28b,_0x2f3bf0:0x27f,_0x3f937b:0x304,_0x52d590:0x2ed,_0x57beba:0x296,_0x12e34e:0x32e,_0x6cc212:0x323,_0x4d3bda:0x2ba,_0x789781:0x53f,_0x41a3fc:0x28e,_0x331b50:0x5b4,_0x224508:0x551},_0x40e3dc={_0xc6b616:0x1ba,_0x4480cd:0x40,_0x8cdd67:0x3fc};function _0x4a0bc2(_0x43781d,_0x4a3767,_0x30be69,_0x17c120){return _0x4c1020(_0x17c120,_0x4a3767-_0x40e3dc._0xc6b616,_0x30be69-_0x40e3dc._0x4480cd,_0x4a3767-_0x40e3dc._0x8cdd67);}function _0x13206e(_0x5909a1,_0x4af790,_0x386a53,_0x411849){return _0x4c1020(_0x386a53,_0x4af790-0x136,_0x386a53-0x59,_0x411849-0x100);}if(_0x121020['type']!==_0x13206e(0x286,_0x3034a1._0x17831c,0x2da,_0x3034a1._0x2f3bf0))return void 0x0;return{'type':_0x13206e(0x2e6,_0x3034a1._0x3f937b,_0x3034a1._0x52d590,_0x3034a1._0x57beba),'index':_0x121020['index']??0x0,'messageId':_0x2b6e4a,'chunk':{'type':'tool_use_delta','id':_0x121020['id']??'','index':_0x121020[_0x13206e(_0x3034a1._0x12e34e,0x2a3,_0x3034a1._0x6cc212,_0x3034a1._0x4d3bda)]??0x0,..._0x121020[_0x4a0bc2(0x4fc,_0x3034a1._0x789781,0x4d4,0x5a9)]!==void 0x0?{'name':_0x121020[_0x13206e(0x245,_0x3034a1._0x41a3fc,0x247,0x243)]}:{},..._0x121020[_0x4a0bc2(_0x3034a1._0x331b50,_0x3034a1._0x224508,0x52c,0x5a3)]!==void 0x0?{'inputDelta':_0x121020['inputDelta']}:{}}};}function createReasoningChunkEvent(_0x34194d,_0x1c30c9){const _0x2534a7={_0x52c293:0x4ef,_0x1c966f:0x5e,_0x2eacb2:0x1,_0x4c5c79:0xd6,_0x52115a:0x562,_0x5837ad:0x86,_0xdf6e33:0x75,_0x4bcca7:0x45,_0x520315:0x99,_0x5221d0:0x3e,_0x1db6a3:0x8e,_0x582c87:0x43,_0x26bb19:0xe8,_0x26f7a8:0x57a,_0x524969:0x4e0,_0x50f36c:0x53e,_0x5ee66b:0x55d,_0x355c77:0x55e,_0xacfde5:0x549,_0x2e4d25:0x111,_0x1ff91a:0xf0,_0x3d9228:0x7e,_0x8d0579:0x160,_0xbf2a73:0x570,_0x3b7a80:0x595,_0x3bd1ec:0x592,_0x5bdee9:0x564,_0x2d2f58:0x10b,_0x1988b1:0xa0,_0x389d69:0x8d,_0xe8da5c:0x68,_0x47ff02:0x20,_0x2b3203:0xa6,_0xfe7df8:0xd1,_0xb3e8c0:0x124,_0x2d4ede:0xc6},_0xdb4df7={_0x1480e2:0xfd,_0x5379f8:0x395},_0x44042d={_0x2a16bf:0x324};function _0x33b51b(_0x196ec2,_0xc17b55,_0x1de275,_0x236a99){return _0x249222(_0x196ec2-0x168,_0xc17b55- -_0x44042d._0x2a16bf,_0x196ec2,_0x236a99-0xf2);}function _0x391181(_0x7f0c5c,_0x1f0ebb,_0x13afe9,_0x1a2cf7){return _0x4c1020(_0x1f0ebb,_0x1f0ebb-0x38,_0x13afe9-_0xdb4df7._0x1480e2,_0x13afe9-_0xdb4df7._0x5379f8);}switch(_0x34194d[_0x391181(0x527,0x4cb,_0x2534a7._0x52c293,0x4d5)]){case _0x33b51b(-0x47,-_0x2534a7._0x1c966f,-_0x2534a7._0x2eacb2,-0x8a):return{'type':_0x33b51b(-0x101,-0x110,-0x174,-_0x2534a7._0x4c5c79),'index':_0x34194d['index'],'messageId':_0x1c30c9,'chunk':{'type':_0x33b51b(-0x4b,-_0x2534a7._0x1c966f,-0x4b,-0x9e),'index':_0x34194d[_0x391181(0x57c,0x4f7,0x54f,_0x2534a7._0x52115a)]??0x0,'thinking':_0x34194d['thinking']??''},'text':_0x34194d[_0x33b51b(-_0x2534a7._0x5837ad,-0xd6,-_0x2534a7._0xdf6e33,-0x141)]??''};case _0x33b51b(-_0x2534a7._0x4bcca7,-_0x2534a7._0x520315,-0xa2,-_0x2534a7._0x5221d0):return{'type':'reasoning_chunk','index':_0x34194d[_0x33b51b(-0x69,-_0x2534a7._0x1db6a3,-_0x2534a7._0x582c87,-_0x2534a7._0x26bb19)],'messageId':_0x1c30c9,'chunk':{'type':_0x391181(_0x2534a7._0x26f7a8,_0x2534a7._0x524969,_0x2534a7._0x50f36c,_0x2534a7._0x5ee66b),'contentIndex':_0x34194d[_0x391181(_0x2534a7._0x355c77,0x4d5,_0x2534a7._0xacfde5,0x4e3)]??0x0,'delta':_0x34194d[_0x33b51b(-_0x2534a7._0x2e4d25,-_0x2534a7._0x1ff91a,-_0x2534a7._0x3d9228,-_0x2534a7._0x8d0579)]??'','itemId':_0x34194d[_0x33b51b(-0xac,-0x55,-0x80,-0x2f)]??'','outputIndex':_0x34194d[_0x391181(0x5a3,_0x2534a7._0xbf2a73,_0x2534a7._0x3b7a80,0x5cc)]??0x0},'text':_0x34194d[_0x33b51b(-0xcd,-0xf0,-0xdd,-0xbe)]??''};case _0x391181(0x581,_0x2534a7._0x3bd1ec,_0x2534a7._0x5bdee9,0x4ff):return{'type':'reasoning_chunk','index':_0x34194d[_0x33b51b(-0xd6,-0xd1,-_0x2534a7._0x2d2f58,-_0x2534a7._0x1988b1)],'messageId':_0x1c30c9,'chunk':{'type':'openai_reasoning_summary_delta','delta':_0x34194d[_0x33b51b(-0x7e,-0xf0,-_0x2534a7._0x389d69,-0xc8)]??'','itemId':_0x34194d[_0x33b51b(-0x3d,-0x55,-_0x2534a7._0xe8da5c,-_0x2534a7._0x47ff02)]??'','outputIndex':_0x34194d[_0x391181(0x56a,0x5d3,0x595,0x5a7)]??0x0,'summaryIndex':_0x34194d[_0x33b51b(-_0x2534a7._0x2b3203,-_0x2534a7._0xfe7df8,-_0x2534a7._0xb3e8c0,-_0x2534a7._0x2d4ede)]??0x0},'text':_0x34194d['delta']??''};default:return void 0x0;}}function isAbortedToolResult(_0x242044){const _0x2179ed={_0x238122:0x31f,_0x573062:0x3d7,_0x3ab29f:0x376,_0x579f8e:0x32f,_0x48aab5:0x37b,_0x2471e1:0x3db,_0x3d6c6c:0x3a7},_0x226a2b={_0x3f5bb5:0xbd,_0x5c8406:0xce},_0x2111e9={_0x4f3080:0xd,_0x6c820d:0x2a};function _0x65bc65(_0x2304c6,_0x433c69,_0xd9c399,_0x57d564){return _0x249222(_0x2304c6-_0x2111e9._0x4f3080,_0x2304c6- -0x363,_0xd9c399,_0x57d564-_0x2111e9._0x6c820d);}function _0x348479(_0x57482c,_0x405cee,_0x91a69a,_0x24f4e4){return _0x249222(_0x57482c-_0x226a2b._0x3f5bb5,_0x405cee-_0x226a2b._0x5c8406,_0x57482c,_0x24f4e4-0x1e5);}return _0x242044[_0x348479(_0x2179ed._0x238122,0x38f,0x3cd,_0x2179ed._0x573062)]==='error'&&_0x242044[_0x348479(0x395,_0x2179ed._0x3ab29f,_0x2179ed._0x579f8e,_0x2179ed._0x48aab5)][_0x348479(0x393,0x3aa,_0x2179ed._0x2471e1,_0x2179ed._0x3d6c6c)]===!![];}function _0x4c1020(_0x33aa5d,_0x1c9b15,_0x3332b6,_0x5de3fb){return _0x41f4(_0x5de3fb- -0x53,_0x33aa5d);}async function executeModelRequest(_0x3aa691,_0x167f39,_0x1762a8,_0x2bd934,_0x1f7618,_0x4d77c6){const _0x5872ea={_0x3f8fcc:0x51c,_0x465bdb:0x3ca,_0x3bdc72:0x42d,_0x37d8ee:0x1a1,_0x5bb2a6:0x190,_0x3bba0d:0x15a,_0x17f699:0x3ed,_0x2db131:0x534,_0x1446f6:0x547,_0x30a4e3:0x500,_0x3c9b4e:0x234,_0x302821:0x24d,_0x305725:0x24f,_0x37e809:0x24a,_0x2860e0:0x260,_0x3dbff1:0x2a0,_0x52146e:0x43e,_0x2ee9fb:0x400,_0x150764:0x463,_0x36ab03:0x24e,_0xb5dcb2:0x1e2,_0x4abe5f:0x24b,_0x4e3dfe:0x195,_0x2a6835:0x4a9,_0x19c596:0x4ce,_0x425225:0x45c,_0x1849b1:0x20b,_0x570bc1:0x1cc,_0x5dea78:0x1c9,_0x4c5509:0x246,_0x467606:0x4df,_0x5bc58d:0x419,_0x1841c0:0x47e,_0x40e6d7:0x42e,_0x3990f4:0x4a3,_0x5544a2:0x230,_0x16b0ef:0x1de,_0x45ba23:0x220,_0x2d0420:0x492,_0x2fa1de:0x400,_0xfbbc95:0x463,_0x100bf:0x4bd,_0xd9b0b6:0x44b,_0x1197ba:0x223,_0x3b6e7b:0x1e5,_0x2168e7:0x1b3,_0x5f0429:0x1bf,_0x448677:0x45b,_0x3fbe70:0x2c4,_0x57a862:0x290,_0x37e788:0x493,_0xf83ade:0x45c,_0x3a4497:0x475,_0x507b7d:0x427,_0x2d78d8:0x41a,_0x7385fe:0x441,_0x36bf6e:0x446,_0x57d847:0x4a4,_0x50b212:0x495,_0x14e745:0x22d,_0x23b17b:0x26c,_0x5dd155:0x4ec,_0x2158db:0x44a,_0x2d2612:0x4b2,_0x116eb6:0x1e4,_0x1db11e:0x23d,_0x16bf6d:0x235,_0x146f12:0x49f,_0x5230ce:0x45d,_0x44c46a:0x1de,_0x712294:0x171,_0x4e2055:0x1d0,_0xef2d42:0x495,_0x10ce31:0x436,_0x2ab764:0x466,_0x42709e:0x3f1,_0x23179c:0x46b,_0x7fe7e:0x4b1,_0x15892f:0x44b,_0x18b3bb:0x14e,_0x590c66:0x466,_0x52c0d0:0x1b3},_0x14fe69={_0x4f15ff:0x96,_0x607ff1:0x470},_0x3cec0a={_0x593c27:0x3a};throwIfAborted(_0x167f39[_0x252c58(0x4fe,_0x5872ea._0x3f8fcc,0x4ce,0x500)]);function _0x252c58(_0x5600fe,_0x492320,_0x12c69c,_0x24dda0){return _0x4c1020(_0x12c69c,_0x492320-0x165,_0x12c69c-_0x3cec0a._0x593c27,_0x24dda0-0x302);}if(!_0x167f39['streaming']||!_0x1762a8[_0x252c58(_0x5872ea._0x465bdb,0x3ca,0x438,_0x5872ea._0x3bdc72)])return await _0x1762a8[_0xe4c2df(-0x1ee,-0x1b8,-_0x5872ea._0x37d8ee,-0x180)](_0x3aa691,{'signal':_0x167f39[_0xe4c2df(-_0x5872ea._0x5bb2a6,-0x205,-0x15b,-_0x5872ea._0x3bba0d)]});let _0x1ff0c4;for await(const _0x202b84 of _0x1762a8[_0x252c58(0x3f1,0x44f,_0x5872ea._0x17f699,_0x5872ea._0x3bdc72)](_0x3aa691,{'signal':_0x167f39['signal']})){throwIfAborted(_0x167f39[_0x252c58(0x524,_0x5872ea._0x2db131,_0x5872ea._0x1446f6,_0x5872ea._0x30a4e3)]);if(_0x202b84[_0xe4c2df(-_0x5872ea._0x3c9b4e,-0x1ff,-_0x5872ea._0x302821,-0x251)]===_0xe4c2df(-0x1f4,-_0x5872ea._0x305725,-_0x5872ea._0x37e809,-0x217)){_0x4d77c6[_0xe4c2df(-0x22d,-0x1df,-_0x5872ea._0x2860e0,-_0x5872ea._0x3dbff1)]['reasoningStartedAt']!==void 0x0&&_0x4d77c6[_0x252c58(_0x5872ea._0x52146e,0x477,_0x5872ea._0x2ee9fb,_0x5872ea._0x150764)]['reasoningCompletedAt']===void 0x0&&(_0x4d77c6[_0xe4c2df(-0x22d,-0x1d2,-0x227,-0x27d)][_0xe4c2df(-0x245,-_0x5872ea._0x36ab03,-_0x5872ea._0xb5dcb2,-_0x5872ea._0x4abe5f)]=Date[_0xe4c2df(-0x1e4,-_0x5872ea._0x4e3dfe,-0x1ed,-0x18e)]());_0x1ff0c4=_0x202b84['response'];continue;}if(_0x202b84[_0x252c58(_0x5872ea._0x2a6835,0x410,_0x5872ea._0x19c596,_0x5872ea._0x425225)]===_0xe4c2df(-_0x5872ea._0x1849b1,-0x234,-0x1d8,-0x26a)){await emitEvent2(_0x2bd934[_0xe4c2df(-0x1b3,-0x1f1,-_0x5872ea._0x570bc1,-_0x5872ea._0x5dea78)],{'type':_0xe4c2df(-0x20b,-0x1df,-0x236,-_0x5872ea._0x4c5509),'assistantMessageId':_0x4d77c6[_0x252c58(_0x5872ea._0x467606,0x42c,_0x5872ea._0x5bc58d,_0x5872ea._0x1841c0)],'reasoningMessageId':_0x4d77c6[_0x252c58(0x3e6,_0x5872ea._0x40e6d7,_0x5872ea._0x3990f4,0x42e)]},_0x1f7618),delete _0x4d77c6[_0xe4c2df(-0x22d,-0x215,-0x1cb,-_0x5872ea._0x5544a2)][_0xe4c2df(-_0x5872ea._0x16b0ef,-0x197,-0x1f4,-_0x5872ea._0x45ba23)],delete _0x4d77c6[_0x252c58(0x421,_0x5872ea._0x2d0420,_0x5872ea._0x2fa1de,_0x5872ea._0xfbbc95)][_0x252c58(0x3ea,0x48d,_0x5872ea._0x100bf,_0x5872ea._0xd9b0b6)];continue;}if(_0x202b84['type']===_0xe4c2df(-_0x5872ea._0x1197ba,-0x25b,-0x268,-_0x5872ea._0x3b6e7b)){await emitEvent2(_0x2bd934[_0xe4c2df(-_0x5872ea._0x2168e7,-0x1a2,-0x145,-_0x5872ea._0x5f0429)],{..._0x202b84,'assistantMessageId':_0x4d77c6[_0x252c58(_0x5872ea._0x448677,0x499,0x483,0x47e)]},_0x1f7618);continue;}const _0x39f745=createReasoningChunkEvent(_0x202b84,_0x4d77c6[_0xe4c2df(-0x262,-_0x5872ea._0x3fbe70,-0x2c8,-_0x5872ea._0x57a862)]);if(_0x39f745&&_0x39f745[_0x252c58(0x3ed,_0x5872ea._0x37e788,0x469,_0x5872ea._0xf83ade)]===_0x252c58(0x4a1,_0x5872ea._0x3a4497,_0x5872ea._0x507b7d,0x434)&&_0x39f745[_0x252c58(0x47e,_0x5872ea._0x2d78d8,_0x5872ea._0x7385fe,_0x5872ea._0x36bf6e)][_0x252c58(0x4e6,_0x5872ea._0x57d847,_0x5872ea._0x50b212,0x4f7)]>0x0){_0x4d77c6[_0xe4c2df(-_0x5872ea._0x14e745,-_0x5872ea._0x23b17b,-0x281,-0x221)][_0x252c58(0x50d,0x508,_0x5872ea._0x5dd155,0x4b2)]===void 0x0&&(_0x4d77c6['meta'][_0x252c58(0x45e,_0x5872ea._0x2158db,0x498,_0x5872ea._0x2d2612)]=Date[_0xe4c2df(-_0x5872ea._0x116eb6,-_0x5872ea._0x1db11e,-_0x5872ea._0x16bf6d,-0x187)]());await emitEvent2(_0x2bd934['onEvent'],_0x39f745,_0x1f7618);continue;}const _0x1ca969=createAssistantChunkEvent(_0x202b84,_0x4d77c6['assistantMessageId']);if(_0x1ca969){_0x4d77c6[_0x252c58(_0x5872ea._0x146f12,_0x5872ea._0x5230ce,_0x5872ea._0x37e788,0x463)][_0xe4c2df(-_0x5872ea._0x44c46a,-0x199,-_0x5872ea._0x712294,-_0x5872ea._0x4e2055)]!==void 0x0&&_0x4d77c6[_0x252c58(0x4ba,_0x5872ea._0xef2d42,_0x5872ea._0x10ce31,0x463)][_0x252c58(_0x5872ea._0x2ab764,_0x5872ea._0x42709e,0x430,0x44b)]===void 0x0&&(_0x4d77c6[_0x252c58(0x459,0x4b2,_0x5872ea._0x23179c,0x463)][_0x252c58(0x3fa,_0x5872ea._0x7fe7e,0x4c1,_0x5872ea._0x15892f)]=Date['now']());await emitEvent2(_0x2bd934[_0xe4c2df(-_0x5872ea._0x2168e7,-_0x5872ea._0x18b3bb,-_0x5872ea._0x570bc1,-0x205)],_0x1ca969,_0x1f7618);continue;}const _0x1ffb0f=createToolUseChunkEvent(_0x202b84,_0x4d77c6[_0x252c58(_0x5872ea._0x590c66,0x479,0x4df,0x47e)]);_0x1ffb0f&&await emitEvent2(_0x2bd934[_0xe4c2df(-_0x5872ea._0x52c0d0,-0x17e,-0x17e,-0x228)],_0x1ffb0f,_0x1f7618);}function _0xe4c2df(_0x2ee2f1,_0x3a7520,_0x2e9cb1,_0x19a2b2){return _0x249222(_0x2ee2f1-_0x14fe69._0x4f15ff,_0x2ee2f1- -_0x14fe69._0x607ff1,_0x3a7520,_0x19a2b2-0x145);}if(!_0x1ff0c4)throw new Error('Model\x20stream\x20ended\x20without\x20a\x20final\x20response');return _0x1ff0c4;}function makeTurnGuards(_0x25f986,_0x4839ac,_0x2041fb,_0x2f5467,_0x5ee62c){return{async 'stage'(_0x49987a,_0x2d7273){return throwIfAborted(_0x25f986),await runStage(_0x4839ac,_0x49987a,_0x2d7273,_0x2f5467);},async 'emit'(_0xa51b0c){throwIfAborted(_0x25f986),await emitEvent2(_0x2041fb,_0xa51b0c,_0x5ee62c);},async 'stageUnchecked'(_0x29f877,_0x53c1a7){return await runStage(_0x4839ac,_0x29f877,_0x53c1a7,_0x2f5467);},async 'emitUnchecked'(_0x1865b1){await emitEvent2(_0x2041fb,_0x1865b1,_0x5ee62c);}};}async function runTurn(_0xb903e,_0x5728f9){const _0x307413={_0x1d7f78:0x30d,_0x494ac0:0x2ea,_0x409d54:0x157,_0x2e96d5:0x1f2,_0x1acae1:0x20a,_0x32c199:0x195,_0x4c9d4a:0x18e,_0x1e240b:0x13c,_0x10c74d:0xcb,_0x4766cc:0x176,_0x48b51c:0x309,_0x40e775:0x300,_0x578e93:0xf3,_0x45a537:0xf7,_0x4e4f3b:0x114,_0x82ca7b:0x125,_0x55d259:0x123,_0x36ecce:0x137,_0x2df072:0x23f,_0x50d3d8:0x24a,_0x3a210f:0x236,_0x4638eb:0x249,_0x6b0683:0x263,_0x22f84a:0x183,_0x3f6c11:0x233,_0x11a018:0xf2,_0x59d746:0x10d,_0x4efd2e:0xae,_0x56a3be:0x255,_0x39943b:0x1ee,_0xc77834:0x213,_0x3d7c30:0x1ec,_0x2a4692:0x25f,_0x4753e8:0x238,_0x32d817:0x1aa,_0x5c6a64:0x1c5,_0x634370:0x17b,_0x32c869:0x105,_0x262a57:0x272,_0x3200ff:0x24b,_0x260a23:0x299,_0xf7ddb9:0x12f,_0x3a83a6:0x178,_0x4aed01:0xca,_0x50e7f4:0x133,_0xc9bec9:0x19e,_0x30defd:0x2a8,_0x3aa4c5:0x2b4,_0x2ac8cb:0x241,_0x235ffd:0x228,_0x36d3c0:0x270,_0x2e2cbb:0x27b,_0x49ff41:0x2ee,_0x517d5e:0x2a4,_0x8bcfcb:0x172,_0x4fac47:0x18b,_0x17a0f6:0x132,_0x5bea5c:0x298,_0x26a07c:0x2ba,_0x60b10d:0x26b,_0x3f80d1:0x308,_0x5d80dc:0x27d,_0x33a5b5:0x2cf,_0x14be41:0x2f7,_0x1dc51f:0x2cb,_0x497942:0x325,_0x336923:0x104,_0x162c9b:0x14e,_0x2fe59f:0x1b8,_0x50618f:0x12a,_0x3ab12e:0x124,_0x3b5788:0x144,_0x5b3556:0x140,_0x93ccb5:0xcf,_0x5f54fe:0x1b9,_0x4e8b86:0x1ef,_0x15b9b2:0x140,_0x143ff1:0x156,_0x2032e5:0x1c6,_0x4e9ecd:0x187,_0x44728d:0x12c,_0x1d922a:0x10f,_0x42847b:0x1b2,_0x32c268:0x170,_0x18e217:0x12e,_0x323f88:0x17d,_0x24fd9f:0x181,_0x326383:0x179,_0x358c05:0x1ba,_0x1a0795:0x1c1,_0x8e8ca5:0x184,_0x2ebd67:0x269,_0x2b46ca:0x202,_0x4b37db:0x149,_0x168041:0x14e,_0x4b3776:0xff,_0x4f199a:0x189,_0x2da6c8:0x19a,_0x4f8b95:0x204,_0xf969c8:0x231,_0x36bfda:0xf4,_0x24876c:0xc5,_0x8b54db:0x2c3,_0x5edff9:0x201,_0x230695:0x20f,_0x50e38c:0x378,_0x21d25b:0x1dc,_0x402bad:0x175,_0x3b63d4:0x2fe,_0x4940ee:0x321,_0x1578f6:0x2e1,_0x1983ac:0x2c9,_0x1029b0:0x2cd,_0x22b693:0x1e1,_0x581cbe:0x303,_0x4a5d59:0x290,_0x229fab:0x159,_0x5921f8:0x1a4,_0x2aca44:0x197,_0x1b789b:0x21a,_0x44a3fe:0x21e,_0x1827e2:0x17e,_0x34a927:0xf6,_0x111ae9:0x165,_0xbb4e08:0x1c8,_0x465954:0x189,_0x43ebe6:0x2a7,_0x322bb4:0x2ba,_0x5e0497:0x232,_0x3322fa:0x2ad,_0x44487c:0x30c,_0x21bc32:0x28a,_0xc26f4f:0x2c9,_0x273a40:0x16e,_0x1f94db:0x2a5,_0x43a266:0x2bb,_0x3c399e:0x316,_0xa45c7d:0x2af,_0x31e968:0xf9,_0xa61f42:0x144,_0x46e2a9:0x13b,_0x5b99d5:0x162,_0x41ec93:0x183,_0x58bff3:0x1c0,_0x3cf5fe:0x1f3,_0x45fd6d:0x1fc,_0x37c9df:0x222},_0x1d2b9b={_0x1dcb47:0x1ee,_0x20011c:0x191,_0x4750ed:0x1aa,_0x1ad307:0x128,_0x57638e:0x15c,_0x3e91d7:0xef,_0x25783a:0xa0,_0x1cfc32:0x1d4,_0xa6432f:0x246,_0x25ef56:0xfe,_0x4613a1:0x166,_0x55b1ca:0x182,_0x34c814:0x1b5,_0x2edbe5:0x2a4,_0x117320:0x272},_0x1ba6d9={_0x4b1da4:0x183,_0xf9d92b:0x30},_0x167b6d={_0x308ffc:0x183},_0x5568af={_0xc8f6fb:0x584,_0xc2319a:0x5ab,_0xf91a4d:0x562,_0x15cdb8:0x12a,_0x292409:0xcf},_0x19e026={_0x26bd13:0x1c3,_0x226a25:0x1d1},_0x1feb3c={_0x262b2a:0x11c,_0x827b80:0x185},_0x3700d5={_0xe87fef:0x2c},_0x50db18=_0x5728f9[_0x475fc0(0x2b1,0x2fb,_0x307413._0x1d7f78,_0x307413._0x494ac0)],_0x5d68bc=_0xb903e[_0x5ead59(_0x307413._0x409d54,0x198,0x1c4,0x1ba)]??new AbortController()[_0x5ead59(_0x307413._0x2e96d5,_0x307413._0x1acae1,0x1c4,_0x307413._0x32c199)];function _0x475fc0(_0x581eed,_0x461735,_0x5ee7ab,_0x495c2b){return _0x249222(_0x581eed-0x89,_0x581eed-_0x3700d5._0xe87fef,_0x5ee7ab,_0x495c2b-0x59);}function _0x5ead59(_0x334098,_0x59cae4,_0x114412,_0x47231a){return _0x249222(_0x334098-0x1f,_0x114412- -_0x1feb3c._0x262b2a,_0x334098,_0x47231a-_0x1feb3c._0x827b80);}const _0x357c43={'sessionId':_0xb903e[_0x5ead59(_0x307413._0x4c9d4a,0x133,0x183,0x1c2)],'turnId':_0xb903e[_0x5ead59(_0x307413._0x1e240b,_0x307413._0x10c74d,0x12f,0x12f)],'system':normalizeSystem(_0xb903e[_0x475fc0(0x280,0x27e,0x2f6,0x2a6)]),'messages':(_0xb903e[_0x5ead59(0x1b5,0x1c9,0x1b6,_0x307413._0x4766cc)]??[])[_0x475fc0(_0x307413._0x48b51c,0x32c,0x2bb,_0x307413._0x40e775)](normalizeMessage),'lastResponse':void 0x0,'toolResults':[],'finalMessage':void 0x0,'sessionDir':typeof _0x5728f9[_0x5ead59(_0x307413._0x578e93,0xfc,_0x307413._0x45a537,_0x307413._0x4e4f3b)]===_0x5ead59(0xc3,_0x307413._0x82ca7b,_0x307413._0x55d259,_0x307413._0x36ecce)?_0x5728f9[_0x475fc0(_0x307413._0x2df072,_0x307413._0x50d3d8,_0x307413._0x3a210f,0x25d)]():_0x5728f9[_0x475fc0(_0x307413._0x2df072,_0x307413._0x4638eb,0x22f,_0x307413._0x6b0683)]},_0x48e76f=makeExtensionContext(_0x357c43),_0x335026={'sessionId':_0x357c43[_0x5ead59(0x1a2,0x185,_0x307413._0x22f84a,0x1b8)],'turnId':_0x357c43[_0x475fc0(0x277,0x248,0x2b0,_0x307413._0x3f6c11)],'state':_0x357c43,'signal':_0x5d68bc,..._0x5728f9[_0x475fc0(0x26a,0x29d,0x286,0x205)]?{'askUser':_0x5728f9['askUser']}:{},..._0x5728f9[_0x5ead59(0x169,_0x307413._0x11a018,_0x307413._0x59d746,_0x307413._0x4efd2e)]?{'setTopic':_0x5728f9[_0x475fc0(_0x307413._0x56a3be,_0x307413._0x39943b,_0x307413._0xc77834,_0x307413._0x3d7c30)]}:{}},{stage:_0x2063ba,emit:_0x132676,stageUnchecked:_0x53fafe,emitUnchecked:_0x197acb}=makeTurnGuards(_0x5d68bc,_0x5728f9['registry'],_0x5728f9[_0x475fc0(0x2e9,0x2a9,0x289,0x340)],_0x48e76f,_0x335026),_0x5a0799=async(_0x24eae6,_0x18b4f4)=>{const _0x146cda={_0x56c2bc:0x301};function _0x82bce5(_0x2f5cf6,_0x59c771,_0x377a1e,_0x2a2005){return _0x5ead59(_0x2f5cf6,_0x59c771-_0x19e026._0x26bd13,_0x59c771- -0x1ce,_0x2a2005-_0x19e026._0x226a25);}const _0x377593=_0x18b4f4?{..._0x48e76f,'turnMeta':_0x18b4f4}:_0x48e76f;function _0xef2f9c(_0x33031f,_0x494025,_0x3a66dc,_0x302d2b){return _0x475fc0(_0x302d2b-_0x146cda._0x56c2bc,_0x494025-0x1e9,_0x494025,_0x302d2b-0x109);}await _0x5728f9['registry'][_0xef2f9c(_0x5568af._0xc8f6fb,_0x5568af._0xc2319a,0x569,_0x5568af._0xf91a4d)](_0x82bce5(-_0x5568af._0x15cdb8,-0xe1,-0x139,-_0x5568af._0x292409),structuredClone(_0x24eae6),_0x377593);},_0x6351d=async _0x29405f=>{if(!_0xb903e[_0x4281fd(_0x1d2b9b._0x1dcb47,_0x1d2b9b._0x20011c,_0x1d2b9b._0x4750ed,0x193)])return 0x0;const _0x16589b=await _0xb903e[_0xb0d700(_0x1d2b9b._0x1ad307,_0x1d2b9b._0x57638e,_0x1d2b9b._0x3e91d7,_0x1d2b9b._0x25783a)]();throwIfAborted(_0x5d68bc);if(_0x16589b[_0x4281fd(0x2bb,_0x1d2b9b._0x1cfc32,_0x1d2b9b._0xa6432f,0x23f)]===0x0)return 0x0;function _0x4281fd(_0x4c8436,_0x38db87,_0x44132b,_0x466d2f){return _0x475fc0(_0x44132b- -0xbd,_0x38db87-_0x167b6d._0x308ffc,_0x4c8436,_0x466d2f-0x102);}await _0x29405f?.();for(const _0x408250 of _0x16589b){const _0x3fcb95=await _0x2063ba(_0xb0d700(_0x1d2b9b._0x25ef56,0xbe,0xe7,0x12a),normalizeMessage(_0x408250));throwIfAborted(_0x5d68bc),_0x357c43['messages'][_0xb0d700(0x17e,0x1bf,_0x1d2b9b._0x4613a1,_0x1d2b9b._0x55b1ca)](_0x3fcb95),await _0x5a0799(_0x3fcb95),await _0x132676({'type':_0x4281fd(0x225,0x1dd,_0x1d2b9b._0x34c814,0x1a6),'message':_0x3fcb95});}function _0xb0d700(_0x2ad8b9,_0x3d9e33,_0x1e2b61,_0x1ac28f){return _0x5ead59(_0x2ad8b9,_0x3d9e33-_0x1ba6d9._0x4b1da4,_0x1e2b61- -_0x1ba6d9._0xf9d92b,_0x1ac28f-0x35);}return _0x16589b[_0x4281fd(_0x1d2b9b._0x2edbe5,0x21d,0x246,_0x1d2b9b._0x117320)];};let _0x365a77=0x0;try{const _0xe1072d=await _0x2063ba(_0x475fc0(_0x307413._0x2a4692,_0x307413._0x4753e8,0x296,0x1f7),normalizeMessage(_0xb903e[_0x5ead59(_0x307413._0x32d817,_0x307413._0x5c6a64,_0x307413._0x634370,_0x307413._0x32c869)]));_0x357c43['messages']['push'](_0xe1072d),await _0x5a0799(_0xe1072d),await _0x132676({'type':_0x475fc0(_0x307413._0x262a57,_0x307413._0x3200ff,_0x307413._0x260a23,0x246),'message':_0xe1072d});while(!![]){throwIfAborted(_0x5d68bc),_0x365a77+=0x1;const _0x28434a=createAssistantMessageId(_0x357c43[_0x5ead59(0xc7,0xf4,_0x307413._0xf7ddb9,_0x307413._0x3a83a6)],_0x365a77),_0x5c9445=createReasoningMessageId(_0x28434a),_0x552909={'model':_0x50db18[_0x5ead59(_0x307413._0x4aed01,0x126,_0x307413._0x50e7f4,_0x307413._0xc9bec9)],'modelIdentity':_0x50db18['modelIdentity'],..._0x50db18[_0x475fc0(0x241,0x263,_0x307413._0x30defd,_0x307413._0x3aa4c5)]?{'provider':_0x50db18[_0x475fc0(_0x307413._0x2ac8cb,0x25c,_0x307413._0x235ffd,_0x307413._0x36d3c0)]}:{}};let _0x3e6d1e={'model':_0x50db18[_0x475fc0(_0x307413._0x2e2cbb,0x26c,_0x307413._0x49ff41,_0x307413._0x517d5e)],..._0x50db18['maxTokens']!==void 0x0?{'maxTokens':_0x50db18[_0x5ead59(0x15d,0x173,_0x307413._0x8bcfcb,0x1cb)]}:{},'system':structuredClone(_0x357c43[_0x5ead59(_0x307413._0x4fac47,_0x307413._0x17a0f6,0x138,0x14d)]),'messages':structuredClone(_0x357c43[_0x475fc0(0x2fe,0x2d5,_0x307413._0x5bea5c,_0x307413._0x26a07c)]),'tools':_0x5728f9[_0x475fc0(0x2ce,_0x307413._0x60b10d,_0x307413._0x3f80d1,_0x307413._0x5d80dc)][_0x475fc0(_0x307413._0x33a5b5,0x273,_0x307413._0x14be41,_0x307413._0x30defd)](),'metadata':{'sessionId':_0x357c43[_0x475fc0(_0x307413._0x1dc51f,_0x307413._0x1dc51f,_0x307413._0x497942,_0x307413._0x517d5e)],'turnId':_0x357c43['turnId'],'modelIdentity':_0x50db18[_0x5ead59(0x116,_0x307413._0x336923,_0x307413._0x162c9b,_0x307413._0x2fe59f)],..._0x50db18['pricingProviderId']!==void 0x0?{'pricingProviderId':_0x50db18['pricingProviderId']}:{}},..._0x5728f9[_0x5ead59(_0x307413._0x50618f,0x14d,_0x307413._0x3ab12e,0xeb)]?{'outputFormat':_0x5728f9[_0x5ead59(_0x307413._0x3b5788,_0x307413._0x5b3556,_0x307413._0x3ab12e,_0x307413._0x93ccb5)]}:{}};_0x3e6d1e=await _0x2063ba(_0x5ead59(_0x307413._0x5f54fe,_0x307413._0x4e8b86,0x181,_0x307413._0x15b9b2),_0x3e6d1e);{const {pricingProviderId:_0x2b91e6,..._0xf9c5b5}=_0x3e6d1e[_0x5ead59(0x198,0xe3,_0x307413._0x143ff1,_0x307413._0x2032e5)];_0x3e6d1e={..._0x3e6d1e,'metadata':{..._0xf9c5b5,..._0x50db18['pricingProviderId']!==void 0x0?{'pricingProviderId':_0x50db18[_0x5ead59(0x1a3,_0x307413._0x11a018,0x163,0x1d3)]}:{}}};}await _0x132676({'type':_0x5ead59(0x16c,_0x307413._0x4e9ecd,_0x307413._0x44728d,_0x307413._0x1d922a),'request':_0x3e6d1e});const _0x56a7e8=Date[_0x5ead59(_0x307413._0x42847b,0x175,_0x307413._0x32c268,0x103)]();_0x552909[_0x5ead59(0x20d,_0x307413._0x18e217,0x19c,0x1e8)]=_0x56a7e8;let _0x20e9de=await executeModelRequest(_0x3e6d1e,_0xb903e,_0x50db18,_0x5728f9,_0x335026,{'assistantMessageId':_0x28434a,'reasoningMessageId':_0x5c9445,'meta':_0x552909});const _0x28dcf9=Date[_0x5ead59(_0x307413._0x323f88,0x11a,_0x307413._0x32c268,_0x307413._0x24fd9f)]();_0x552909[_0x5ead59(_0x307413._0x326383,0x1f5,0x1b0,_0x307413._0x358c05)]=_0x28dcf9,_0x20e9de=await _0x2063ba(_0x5ead59(_0x307413._0x1a0795,0x1c5,_0x307413._0x8e8ca5,0x152),_0x20e9de);_0x20e9de[_0x475fc0(_0x307413._0x2ebd67,0x2ca,_0x307413._0x2b46ca,0x200)]&&(_0x20e9de={..._0x20e9de,'providerState':{..._0x20e9de[_0x5ead59(0x126,0x172,0x121,0x13d)],'originModelIdentity':_0x50db18[_0x5ead59(_0x307413._0x4b37db,0x189,_0x307413._0x168041,_0x307413._0x4b3776)]}});_0x20e9de=withEstimatedModelCost(_0x3e6d1e,_0x20e9de);const _0x2c4d09=Math['max'](0x0,_0x28dcf9-_0x56a7e8),_0x20f309={'version':0x1,'usage':structuredClone(_0x20e9de[_0x5ead59(0x17e,0x1a4,_0x307413._0x4f199a,_0x307413._0x2da6c8)]),'modelTimeMs':_0x2c4d09},_0x3d70a8=_0x395f6d=>({..._0x552909,'metrics':{..._0x20f309,'usage':structuredClone(_0x20f309[_0x475fc0(0x2d1,0x264,0x2e1,0x28d)]),'completesRequest':_0x395f6d}});await _0x132676({'type':'model_response','response':_0x20e9de,'modelTimeMs':_0x2c4d09}),_0x357c43[_0x475fc0(0x23e,_0x307413._0x4f8b95,0x2a2,_0x307413._0xf969c8)]=_0x20e9de;let _0x4ac2de=await _0x2063ba(_0x5ead59(0x149,0x9c,_0x307413._0x36bfda,_0x307413._0x24876c),withMessageId(responseToAssistantMessage(_0x20e9de),_0x28434a));_0x4ac2de=withMessageId(_0x4ac2de,_0x28434a);const _0x572d45=getToolUseBlocks(_0x4ac2de),_0x424f2c=await Promise[_0x475fc0(0x2d8,_0x307413._0x8b54db,0x34e,0x2d3)](_0x572d45[_0x5ead59(_0x307413._0x5edff9,_0x307413._0x230695,0x1c1,0x226)](_0x1a5ca3=>_0x2063ba(_0x5ead59(0x219,0x1e9,0x1c7,0x184),_0x1a5ca3)));_0x424f2c['length']>0x0&&(_0x4ac2de=replaceToolUseBlocks(_0x4ac2de,_0x424f2c));const _0x4ba891=withMessageId(_0x4ac2de,_0x28434a);_0x4ac2de=_0x4ba891;const _0x183ed5=createReasoningMessage(_0x4ac2de),_0x583fc2=createAssistantTextMessage(_0x4ac2de),_0x1e84b3=createToolUseMessage(_0x4ac2de);_0x183ed5&&await _0x132676({'type':_0x475fc0(0x311,0x2e3,0x2a5,_0x307413._0x50e38c),'message':withMessageId(_0x183ed5,_0x5c9445)});_0x583fc2&&await _0x132676({'type':_0x475fc0(0x2b2,0x2b2,_0x307413._0x50d3d8,0x2d9),'message':withMessageId(_0x583fc2,_0x28434a)});_0x1e84b3&&await _0x132676({'type':_0x5ead59(_0x307413._0x21d25b,0x15c,_0x307413._0x402bad,0x117),'message':withMessageId(_0x1e84b3,_0x28434a)});_0x357c43[_0x475fc0(_0x307413._0x3b63d4,0x2e9,_0x307413._0x4940ee,0x306)][_0x475fc0(0x2de,_0x307413._0x1578f6,_0x307413._0x1983ac,_0x307413._0x1029b0)](_0x4ba891);_0x424f2c['length']>0x0&&await _0x5a0799(_0x4ba891,_0x3d70a8(![]));for(const _0x537cb6 of _0x424f2c){await _0x132676({'type':_0x475fc0(0x231,0x29a,0x239,_0x307413._0x22b693),'toolCall':_0x537cb6});}if(_0x424f2c[_0x475fc0(_0x307413._0x581cbe,0x36c,0x2f9,0x35b)]===0x0){const _0xf73ee2=await _0x6351d(async()=>{await _0x5a0799(_0x4ba891,_0x3d70a8(![]));});if(_0xf73ee2>0x0)continue;const _0x59a16e=await _0x2063ba('beforeFinalOutput',_0x4ac2de),_0xf95f8b=withMessageId(_0x59a16e,_0x28434a);return _0x357c43[_0x5ead59(0x186,0x173,0x18a,0x169)]=_0xf95f8b,_0x357c43[_0x475fc0(0x2fe,_0x307413._0x4a5d59,0x2f8,0x34c)][_0x357c43[_0x5ead59(_0x307413._0x229fab,_0x307413._0x5921f8,0x1b6,0x182)][_0x5ead59(_0x307413._0x2aca44,_0x307413._0x1b789b,0x1bb,_0x307413._0x44a3fe)]-0x1]=_0xf95f8b,await _0x5a0799(_0xf95f8b,_0x3d70a8(!![])),await _0x197acb({'type':'final_message','message':_0xf95f8b}),throwIfAborted(_0x5d68bc),await _0x5728f9['registry'][_0x5ead59(_0x307413._0x1827e2,_0x307413._0x34a927,0x119,0x172)](_0x5ead59(0x17a,_0x307413._0x111ae9,_0x307413._0xbb4e08,_0x307413._0x465954),_0x357c43,_0x48e76f),await _0x132676({'type':_0x475fc0(_0x307413._0x43ebe6,0x301,_0x307413._0x322bb4,_0x307413._0x5e0497),'state':_0x357c43}),{'status':_0x475fc0(_0x307413._0x3322fa,0x2c8,0x2ae,_0x307413._0x44487c),'finalMessage':_0xf95f8b,'state':_0x357c43};}let _0x37ae76=await _0x5728f9[_0x475fc0(0x2ce,_0x307413._0x21bc32,_0x307413._0xc26f4f,0x2ed)]['executeCalls'](_0x424f2c,_0x335026);const _0x16d041=_0x37ae76[_0x5ead59(0x1ac,0x1f7,0x199,_0x307413._0x273a40)](isAbortedToolResult),_0x559c43=_0x16d041?_0x53fafe:_0x2063ba,_0x116719=_0x16d041?_0x197acb:_0x132676;_0x37ae76=await Promise[_0x5ead59(0x1fb,0x15a,0x190,0x171)](_0x37ae76[_0x475fc0(_0x307413._0x48b51c,0x34b,0x2a0,0x34d)](_0x310df1=>_0x559c43(_0x475fc0(0x284,0x211,0x27a,0x2b7),_0x310df1))),_0x357c43[_0x475fc0(_0x307413._0x1f94db,0x2d4,_0x307413._0x43a266,0x307)][_0x475fc0(0x2de,_0x307413._0x3c399e,0x324,_0x307413._0xa45c7d)](..._0x37ae76);for(const _0x51ed17 of _0x37ae76){await _0x116719({'type':'tool_result','result':_0x51ed17});}const _0x5920d4=await _0x559c43(_0x5ead59(_0x307413._0x31e968,0x13c,_0x307413._0xa61f42,0x112),createToolResultUserMessage(_0x37ae76));await _0x116719({'type':_0x5ead59(0x11b,_0x307413._0x46e2a9,0x155,0x1a9),'message':_0x5920d4}),_0x357c43['messages'][_0x475fc0(0x2de,0x348,0x333,0x313)](_0x5920d4),await _0x5a0799(_0x5920d4);if(_0x16d041)return{'status':'aborted','state':_0x357c43};await _0x6351d();}}catch(_0x330993){if(!_0x5d68bc[_0x5ead59(_0x307413._0x5b99d5,_0x307413._0x41ec93,_0x307413._0x58bff3,0x185)])throw new TurnFailedError(_0x330993,_0x357c43);return{'status':_0x5ead59(_0x307413._0x3cf5fe,_0x307413._0x45fd6d,0x1c0,_0x307413._0x37c9df),'state':_0x357c43};}}function createSessionId(){const _0x4fbcbe={_0x54ba78:0xc2,_0x5b8ace:0x70,_0x238ece:0x23,_0x452f28:0x146,_0x39c31d:0xf1,_0xd0417d:0x4a,_0x316a0c:0x7b},_0x24ba48={_0x563f60:0x86,_0x37367d:0x1f8,_0x3bd457:0x4a},_0x27b513={_0x1b5851:0x126};function _0x7f95b7(_0x5b3116,_0x5e1882,_0x1fb4f8,_0xd7227f){return _0x249222(_0x5b3116-0xca,_0x1fb4f8- -_0x27b513._0x1b5851,_0x5e1882,_0xd7227f-0x16d);}function _0x3f76de(_0x3989de,_0x3419f2,_0x3a4767,_0x242d0f){return _0x249222(_0x3989de-_0x24ba48._0x563f60,_0x3419f2- -_0x24ba48._0x37367d,_0x3989de,_0x242d0f-_0x24ba48._0x3bd457);}return _0x3f76de(_0x4fbcbe._0x54ba78,0x71,_0x4fbcbe._0x5b8ace,_0x4fbcbe._0x238ece)+Date['now']()+'-'+Math['random']()[_0x7f95b7(0xff,0x153,_0x4fbcbe._0x452f28,_0x4fbcbe._0x39c31d)](0x10)[_0x3f76de(0x50,_0x4fbcbe._0xd0417d,0x9e,_0x4fbcbe._0x316a0c)](0x2,0xa);}function createTurnId(_0x477ab9){const _0x3f6a88={_0x2d4e48:0x3b,_0x11f8a0:0x6a,_0x27f6e2:0x35,_0x1481b5:0xf},_0xc2c3a3={_0x13837f:0x6c,_0x2cc096:0x24,_0x3b1b67:0x20f};function _0x57b8ee(_0x28d125,_0x442221,_0x52c710,_0x133d27){return _0x4c1020(_0x52c710,_0x442221-_0xc2c3a3._0x13837f,_0x52c710-_0xc2c3a3._0x2cc096,_0x28d125- -_0xc2c3a3._0x3b1b67);}return _0x57b8ee(-_0x3f6a88._0x2d4e48,-_0x3f6a88._0x11f8a0,_0x3f6a88._0x27f6e2,_0x3f6a88._0x1481b5)+_0x477ab9;}function createDefaultMessage(_0x39409d){if(_0x39409d===void 0x0)return void 0x0;return normalizeUserInput(_0x39409d);}function normalizeUserInput(_0x23fff3){const _0x51b53f={_0x598fa2:0x349,_0x3acd22:0x381,_0x37a690:0x3e0,_0x118251:0x3df,_0xf7de08:0x386},_0x535d9f={_0x3b8156:0x1eb,_0x5ce28b:0x66,_0x2a8752:0x69};if(typeof _0x23fff3===_0x2bcb42(0x369,_0x51b53f._0x598fa2,0x385,_0x51b53f._0x3acd22))return{'role':_0x2bcb42(_0x51b53f._0x37a690,_0x51b53f._0x118251,0x420,0x3f8),'content':[{'type':_0x2bcb42(0x376,_0x51b53f._0xf7de08,0x388,0x3ad),'text':_0x23fff3}]};function _0x4d0fce(_0x20515b,_0xed9b01,_0x1ebb69,_0x11924f){return _0x4c1020(_0x11924f,_0xed9b01-_0x535d9f._0x3b8156,_0x1ebb69-_0x535d9f._0x5ce28b,_0x20515b- -_0x535d9f._0x2a8752);}function _0x2bcb42(_0x1223c9,_0x36ae3c,_0x4e8e8e,_0x55c2f1){return _0x249222(_0x1223c9-0xee,_0x1223c9-0x150,_0x4e8e8e,_0x55c2f1-0x2c);}return normalizeMessage(_0x23fff3);}function resolveChatModel(_0x47af67){const _0x344b47={_0x499f06:0xb8,_0x406875:0xb2,_0x4a184d:0x9b,_0x190b20:0x4b,_0x3d23d5:0xfc,_0x57f285:0x67},_0x25b617={_0x1f8044:0x99},_0x3abf80={_0x2cf2c8:0x70,_0x19c52f:0xeb};if(!_0x47af67[_0x1ed3e5(_0x344b47._0x499f06,0x83,_0x344b47._0x406875,0xcb)])throw new Error(_0x1ed3e5(_0x344b47._0x4a184d,0x100,_0x344b47._0x190b20,_0x344b47._0x3d23d5));function _0x1ed3e5(_0x482e7d,_0x8ad28f,_0x71bf0d,_0x2ec94e){return _0x4c1020(_0x2ec94e,_0x8ad28f-_0x3abf80._0x2cf2c8,_0x71bf0d-0x1a1,_0x482e7d- -_0x3abf80._0x19c52f);}function _0x3d4894(_0x4dcd88,_0x5b2824,_0x5b4750,_0x48b611){return _0x4c1020(_0x5b2824,_0x5b2824-0x2e,_0x5b4750-_0x25b617._0x1f8044,_0x48b611-0x120);}return _0x47af67[_0x1ed3e5(0xb8,0xe1,_0x344b47._0x57f285,0x11d)];}function createRegistry(_0x3d39bf){const _0x4df146={_0x3a419b:0x95,_0x5e62be:0x40,_0xdf5d32:0x70,_0x5e70e2:0x40,_0x53e580:0x2d,_0x1da440:0x74,_0x4c94d4:0x9c},_0x8dad18={_0x4b9ac9:0x8d,_0x171be0:0x15f},_0x53326b={_0xff18c4:0x187,_0x2b4f46:0x31f};if(_0x3d39bf[_0x2c33fc(-_0x4df146._0x3a419b,-0x6a,-_0x4df146._0x5e62be,-0x21)])return _0x3d39bf[_0x2c33fc(-0x93,-_0x4df146._0xdf5d32,-_0x4df146._0x5e70e2,_0x4df146._0x53e580)];const _0x432787=createExtensionRegistry();function _0x413712(_0x38143b,_0x19c65d,_0x225f78,_0x248b05){return _0x4c1020(_0x248b05,_0x19c65d-_0x53326b._0xff18c4,_0x225f78-0xbc,_0x19c65d- -_0x53326b._0x2b4f46);}const _0x4128f8=_0x3d39bf[_0x2c33fc(-0x33,-0xd5,-_0x4df146._0x1da440,-_0x4df146._0x4c94d4)]??[];for(const _0x3443f2 of _0x4128f8){_0x432787['register'](_0x3443f2);}function _0x2c33fc(_0x1992c8,_0x5e05a5,_0x369340,_0x5df790){return _0x249222(_0x1992c8-_0x8dad18._0x4b9ac9,_0x369340- -0x2fb,_0x5e05a5,_0x5df790-_0x8dad18._0x171be0);}return _0x432787;}var Agent=class{['_systemPrompt'];['deps'];['metrics'];['sessionId'];['messages'];[_0x4c1020(0x252,0x214,0x1c2,0x1f7)];['turnIndex'];constructor(_0x1e2c32={}){const _0x4b1b4d={_0x45e8ae:0x375,_0x1865de:0x35f,_0x354c49:0x35b,_0x4d2811:0x3fa,_0x702743:0x323,_0x3a9d7a:0x374,_0x3abe9d:0x33e,_0x4fca3d:0x3ca,_0x306d14:0x34f,_0x251f0a:0x2e7,_0xb8cf87:0x355,_0x55e535:0x3c6,_0x51849b:0x3ef,_0x201aeb:0x3d1,_0x22e23a:0x3ac,_0x3461a7:0x3b0,_0x32e59c:0x36d,_0x19ed39:0x3a5,_0x2c7889:0x3a2,_0x5e57fa:0x339,_0x2643ac:0x393,_0x4f33f8:0x39d,_0x20fba8:0x32e,_0x38ac82:0x3b1,_0x76a02:0x3ad,_0x3397da:0x30b,_0xd7d409:0x358,_0x13d063:0x2d9,_0x2adda0:0x335,_0x2f125a:0x31d,_0x25b6cd:0x30b,_0x2c55e9:0x353},_0x16845d={_0x48addd:0x1a7,_0x52bc47:0x1a3,_0x51d920:0x5ec,_0x1ba600:0x5e5},_0x1f89ea={_0x45513b:0x1a8,_0x2f8027:0x99},_0x448f92={_0x55c16d:0xf4},_0xf82bec={_0x274350:0x1e7,_0x58955d:0xd6,_0x57df2a:0x1d};function _0x538f08(_0x5c6614,_0x22d029,_0x276efd,_0x40477d){return _0x249222(_0x5c6614-_0xf82bec._0x274350,_0x22d029-_0xf82bec._0x58955d,_0x40477d,_0x40477d-_0xf82bec._0x57df2a);}this[_0x538f08(0x308,_0x4b1b4d._0x45e8ae,0x370,_0x4b1b4d._0x1865de)]=_0x1e2c32[_0x219f16(_0x4b1b4d._0x354c49,0x393,0x38f,_0x4b1b4d._0x4d2811)]??createSessionId();function _0x219f16(_0x2529ec,_0x891b82,_0x1c1412,_0x343487){return _0x249222(_0x2529ec-0xc5,_0x891b82-_0x448f92._0x55c16d,_0x1c1412,_0x343487-0x1d2);}this[_0x538f08(_0x4b1b4d._0x702743,_0x4b1b4d._0x3a9d7a,_0x4b1b4d._0x3abe9d,_0x4b1b4d._0x4fca3d)]=0x0,this[_0x219f16(_0x4b1b4d._0x306d14,0x326,_0x4b1b4d._0x251f0a,0x33a)]=_0x1e2c32[_0x538f08(0x365,0x380,0x3f0,_0x4b1b4d._0xb8cf87)]??'',this[_0x219f16(0x401,_0x4b1b4d._0x55e535,0x3db,0x3c1)]=(_0x1e2c32[_0x219f16(0x410,0x3c6,_0x4b1b4d._0x51849b,0x3a6)]??[])[_0x219f16(0x397,_0x4b1b4d._0x201aeb,_0x4b1b4d._0x22e23a,_0x4b1b4d._0x3461a7)](normalizeMessage),this['defaultMessage']=createDefaultMessage(_0x1e2c32[_0x538f08(0x39e,_0x4b1b4d._0x32e59c,_0x4b1b4d._0x19ed39,0x340)]),this[_0x219f16(0x38d,0x369,0x37f,_0x4b1b4d._0x2c7889)]=createAgentMetrics({'getContextWindowLimit':_0x1e2c32['getContextWindowLimit']});const _0x103d02=_0x1e2c32[_0x538f08(_0x4b1b4d._0x5e57fa,_0x4b1b4d._0x2643ac,_0x4b1b4d._0x4f33f8,_0x4b1b4d._0x20fba8)],_0x5a11c7=async(_0x29882a,_0x4eeafc)=>{const _0x12195b={_0x38cd82:0x1a3,_0x3ae647:0x24a,_0x4df49c:0x176};function _0x4ea4bf(_0x46b57b,_0xf37497,_0x50dd8b,_0x198f3c){return _0x538f08(_0x46b57b-_0x12195b._0x38cd82,_0x198f3c-_0x12195b._0x3ae647,_0x50dd8b-_0x12195b._0x4df49c,_0x46b57b);}function _0x4891f2(_0x4fa641,_0x56a56f,_0x4e957c,_0x5ea591){return _0x538f08(_0x4fa641-0x188,_0x5ea591- -_0x1f89ea._0x45513b,_0x4e957c-_0x1f89ea._0x2f8027,_0x4fa641);}this[_0x4891f2(0x137,0x1f9,_0x16845d._0x48addd,_0x16845d._0x52bc47)][_0x4ea4bf(_0x16845d._0x51d920,_0x16845d._0x1ba600,0x60e,0x5d9)](_0x29882a),await _0x103d02?.(_0x29882a,_0x4eeafc);},_0x4da763=createInternalToolRuntime(_0x1e2c32['tools']??[],{'onEvent':_0x5a11c7,'onToolCall':_0x1e2c32[_0x219f16(_0x4b1b4d._0x38ac82,0x34a,_0x4b1b4d._0x76a02,_0x4b1b4d._0x3397da)]});this['deps']={'registry':createRegistry(_0x1e2c32),'chatModel':resolveChatModel(_0x1e2c32),'toolRuntime':_0x4da763,'askUser':_0x1e2c32[_0x219f16(_0x4b1b4d._0xd7d409,0x332,0x36e,_0x4b1b4d._0x13d063)],'setTopic':_0x1e2c32[_0x219f16(_0x4b1b4d._0x2adda0,_0x4b1b4d._0x2f125a,_0x4b1b4d._0x25b6cd,_0x4b1b4d._0x2c55e9)],'onEvent':_0x5a11c7,'sessionDir':_0x1e2c32['sessionDir'],'outputFormat':_0x1e2c32['outputFormat']};}get[_0x4c1020(0x15a,0x195,0x179,0x1c8)](){const _0x8f9056={_0x50b0c4:0x4ed,_0x3356e4:0x4f7},_0x4ce08f={_0x5488a9:0x7f,_0x3524e6:0x2c5,_0x5b3c5e:0xc4};function _0x3c2a01(_0x10546a,_0x15e9d7,_0x2d6a3b,_0x2f8e41){return _0x249222(_0x10546a-_0x4ce08f._0x5488a9,_0x2d6a3b-_0x4ce08f._0x3524e6,_0x2f8e41,_0x2f8e41-_0x4ce08f._0x5b3c5e);}return this[_0x3c2a01(0x54d,_0x8f9056._0x50b0c4,_0x8f9056._0x3356e4,0x4f5)];}[_0x249222(0x2ff,0x2ae,0x261,0x29f)](_0x657713=[]){const _0x57af02={_0xf8a11d:0x4ea,_0x53c725:0x55d,_0x3e9caa:0x8e,_0x662626:0x7b,_0x29cab7:0x52},_0x547345={_0x66e3e2:0x16,_0x4e4460:0x212};function _0x35f9ed(_0x481341,_0x933b9a,_0x78139b,_0x5b53d5){return _0x249222(_0x481341-0x19c,_0x481341-0x31b,_0x5b53d5,_0x5b53d5-0x114);}function _0x5093d2(_0x3bfa43,_0x2de39a,_0x2182b0,_0x45024c){return _0x4c1020(_0x3bfa43,_0x2de39a-_0x547345._0x66e3e2,_0x2182b0-0x175,_0x45024c- -_0x547345._0x4e4460);}this[_0x35f9ed(0x52a,_0x57af02._0xf8a11d,0x4cb,_0x57af02._0x53c725)][_0x5093d2(-_0x57af02._0x3e9caa,-_0x57af02._0x662626,-0x25,-_0x57af02._0x29cab7)]['setTools'](_0x657713);}[_0x4c1020(0x219,0x1c0,0x26b,0x1ff)](){const _0x549ff7={_0x15d17f:0x9f,_0x4ef23f:0x49,_0x565936:0x11f,_0x37b158:0x119,_0x3bfe8a:0x12d},_0x20be30={_0x4b6d27:0x27,_0x305255:0x8e},_0x192a33={_0x499d65:0x195,_0x539c7a:0x1d7};function _0x28189a(_0x46b253,_0x4764df,_0x5b2460,_0x27c05c){return _0x4c1020(_0x27c05c,_0x4764df-_0x192a33._0x499d65,_0x5b2460-_0x192a33._0x539c7a,_0x46b253- -0xa1);}function _0x2ab675(_0x3b3cc5,_0x17f405,_0x2f9731,_0xd5aade){return _0x4c1020(_0x2f9731,_0x17f405-_0x20be30._0x4b6d27,_0x2f9731-0xbc,_0x3b3cc5- -_0x20be30._0x305255);}return this[_0x2ab675(_0x549ff7._0x15d17f,0x107,_0x549ff7._0x4ef23f,0x61)][_0x28189a(_0x549ff7._0x565936,_0x549ff7._0x37b158,_0x549ff7._0x3bfe8a,0x11e)]['listToolSchemas']();}[_0x4c1020(0x108,0xd9,0xd7,0x126)](_0x4defdc,_0x54ee4d={}){const _0x28e42c={_0x384f04:0xbf,_0x4db112:0xa1,_0x49b5c4:0xff,_0x5c04ef:0x44,_0x5027cf:0x7b,_0x10bea6:0xf1,_0x58e71d:0x76,_0x43df3a:0x15d,_0x2326a4:0x133},_0xaf15bb={_0x3b3fdd:0x74,_0x197388:0x2db},_0x469832={_0x41d149:0x16,_0x5793f9:0x1eb,_0x418c3a:0x91};function _0x215d91(_0x3053ac,_0x43efe3,_0x2846f1,_0x361cfd){return _0x4c1020(_0x361cfd,_0x43efe3-_0x469832._0x41d149,_0x2846f1-_0x469832._0x5793f9,_0x3053ac- -_0x469832._0x418c3a);}function _0x415b4b(_0x3d5020,_0x208e7f,_0x477879,_0x5c20f3){return _0x4c1020(_0x5c20f3,_0x208e7f-_0xaf15bb._0x3b3fdd,_0x477879-0x13,_0x208e7f- -_0xaf15bb._0x197388);}this[_0x215d91(_0x28e42c._0x384f04,0x72,_0x28e42c._0x4db112,_0x28e42c._0x49b5c4)]=_0x4defdc,_0x54ee4d[_0x215d91(0xa7,0x7f,_0x28e42c._0x5c04ef,0xad)]===!![]&&(this[_0x415b4b(-_0x28e42c._0x5027cf,-0xeb,-_0x28e42c._0x10bea6,-_0x28e42c._0x58e71d)]=[],this[_0x415b4b(-_0x28e42c._0x43df3a,-0x11f,-0xd9,-_0x28e42c._0x2326a4)]=0x0);}[_0x4c1020(0x1aa,0x149,0x1e3,0x173)](_0x384b8a){this['sessionId']=_0x384b8a;}[_0x4c1020(0x1fe,0x21c,0x203,0x1b3)](_0xec1ca0){const _0x23987b={_0x3bc79e:0x24b,_0x461baf:0x25e},_0x2030dd={_0x1c2b7e:0x7c},_0x3b37b3={_0x52013b:0x29};function _0x1d35e0(_0x7d1310,_0x111359,_0x2597fe,_0x17da0a){return _0x4c1020(_0x111359,_0x111359-0x1cb,_0x2597fe-_0x3b37b3._0x52013b,_0x7d1310- -0x1a7);}function _0x348ea5(_0x6adcc6,_0xa163ef,_0x1f243b,_0x3fe873){return _0x249222(_0x6adcc6-0xe0,_0x6adcc6-_0x2030dd._0x1c2b7e,_0x1f243b,_0x3fe873-0x1c1);}this[_0x348ea5(0x28b,_0x23987b._0x3bc79e,_0x23987b._0x461baf,0x236)][_0x1d35e0(-0x4,0x4,-0xf,-0x11)]=_0xec1ca0;}async[_0x4c1020(0x1df,0x1a0,0x1b7,0x1e9)](_0x3ef115=this['defaultMessage'],_0x4501f2={}){const _0x327bd9={_0x5c4c69:0x207,_0x3f26cf:0x1d6,_0x1b18bb:0x501,_0x144a16:0x4ba,_0x1bfcfc:0x4f2,_0xefb38d:0x50d,_0x374635:0x52c,_0x33ad86:0x4de,_0x2509f7:0x48f,_0xedca19:0x234,_0x438c87:0x29a,_0x9ef14c:0x59b,_0x270b60:0x4fe,_0x184f17:0x5a2,_0x315fc5:0x25c,_0x44fed5:0x29e,_0x6d538c:0x270,_0x19dd15:0x28f,_0x12d0ff:0x2c7,_0xb429ba:0x297,_0x38be73:0x1f3,_0x43e02c:0x21f,_0x25bc5e:0x1e9,_0x31e5c4:0x215},_0x4611c7={_0x2d8660:0x0},_0x597eef={_0x5dfc2d:0x1cc};function _0x14d983(_0xc80b15,_0x1af88b,_0x4f9ba4,_0x52cd8a){return _0x249222(_0xc80b15-_0x597eef._0x5dfc2d,_0x4f9ba4-0x26e,_0x1af88b,_0x52cd8a-0x62);}if(!_0x3ef115)throw new Error(_0xfad2be(0x1a0,0x1c1,0x1d0,_0x327bd9._0x5c4c69));this[_0xfad2be(0x228,_0x327bd9._0x3f26cf,0x1f2,0x206)]+=0x1;const _0x46707f=_0x4501f2[_0x14d983(_0x327bd9._0x1b18bb,0x433,0x4a9,0x491)];function _0xfad2be(_0x22c465,_0xeedfe4,_0x4f129d,_0x6927da){return _0x249222(_0x22c465-0x158,_0x22c465- -0x76,_0x4f129d,_0x6927da-_0x4611c7._0x2d8660);}try{const _0x2885ed=await runTurn({'sessionId':this[_0x14d983(_0x327bd9._0x144a16,_0x327bd9._0x1bfcfc,_0x327bd9._0xefb38d,_0x327bd9._0x374635)],'turnId':createTurnId(this[_0x14d983(0x4a9,_0x327bd9._0x33ad86,0x50c,0x4ba)]),'streaming':_0x4501f2[_0x14d983(0x4a0,_0x327bd9._0x2509f7,0x4bf,0x49b)],'signal':_0x4501f2[_0xfad2be(0x26a,0x29c,0x216,0x2ab)],'system':this[_0xfad2be(_0x327bd9._0xedca19,0x24e,0x23d,_0x327bd9._0x438c87)],'messages':this['messages'],'message':normalizeUserInput(_0x3ef115),..._0x46707f?{'drainSteering':async()=>(await _0x46707f())[_0xfad2be(0x267,0x2b4,0x252,0x282)](normalizeUserInput)}:{}},this['deps']);return this[_0x14d983(_0x327bd9._0x9ef14c,_0x327bd9._0x270b60,0x540,0x573)]=_0x2885ed['state'][_0x14d983(0x51b,0x50c,0x540,_0x327bd9._0x184f17)]['map'](normalizeMessage),_0x2885ed;}catch(_0x35b27a){if(_0x35b27a instanceof TurnFailedError){this[_0xfad2be(_0x327bd9._0x315fc5,0x234,_0x327bd9._0x44fed5,0x2a6)]=synthesizeMissingToolResults(_0x35b27a[_0xfad2be(_0x327bd9._0x6d538c,_0x327bd9._0x19dd15,_0x327bd9._0x12d0ff,_0x327bd9._0xb429ba)][_0xfad2be(0x25c,_0x327bd9._0x38be73,_0x327bd9._0x43e02c,0x2b2)]['map'](normalizeMessage));throw _0x35b27a[_0xfad2be(_0x327bd9._0x25bc5e,0x252,0x244,_0x327bd9._0x31e5c4)];}throw _0x35b27a;}}};export{normalizeToolOutputValue,createToolOutput,ToolExecutionError,defineTool,resolveToolPermissionClass,ToolRegistry,validateToolInput,deriveFinalToolOutput,createInternalToolRuntime,createExtensionRegistry,createAgentMetrics,runTurn,Agent};
1
+ (function(_0x482ce9,_0x54af5d){const _0x20ae14={_0x13954f:0x1fc,_0x43ed97:0x1b0,_0x10b289:0x199,_0x2bc1a5:0x1d6,_0x181a97:0x1ae,_0x186bee:0x36f,_0x3909b0:0x2dc,_0x447f09:0x198,_0x3a2638:0x18d,_0x4e332f:0x176,_0x204114:0xe5,_0x3130ca:0x13a,_0x48d5a0:0x10f,_0x557c12:0xea,_0x19fd07:0x251,_0x5ee3fe:0x2cb,_0x27e76b:0x15e,_0x35b7b5:0x360,_0x5d58c0:0x315,_0x4d8b6e:0x1d8,_0xef8a55:0x1d3,_0x1c4141:0x1dc,_0x4410a5:0x2b1,_0x4396b8:0x312,_0x59c349:0x290},_0x42d4a0={_0x46d6e0:0x275};function _0x5ad8f0(_0x230dc4,_0x5a7d09,_0x643bba,_0x4b93b8){return _0x17cd(_0x643bba- -_0x42d4a0._0x46d6e0,_0x4b93b8);}function _0x545934(_0x247145,_0x1c385e,_0x57a1f5,_0x4fbee2){return _0x17cd(_0x1c385e- -0x3d1,_0x4fbee2);}const _0x442a96=_0x482ce9();while(!![]){try{const _0x2e2169=-parseInt(_0x5ad8f0(-0x15e,-_0x20ae14._0x13954f,-_0x20ae14._0x43ed97,-0x1e4))/0x1*(-parseInt(_0x5ad8f0(-_0x20ae14._0x10b289,-0x187,-_0x20ae14._0x2bc1a5,-_0x20ae14._0x181a97))/0x2)+parseInt(_0x545934(-0x2c6,-0x300,-_0x20ae14._0x186bee,-_0x20ae14._0x3909b0))/0x3*(parseInt(_0x5ad8f0(-_0x20ae14._0x447f09,-_0x20ae14._0x3a2638,-_0x20ae14._0x4e332f,-0x139))/0x4)+parseInt(_0x5ad8f0(-_0x20ae14._0x204114,-_0x20ae14._0x3130ca,-_0x20ae14._0x48d5a0,-_0x20ae14._0x557c12))/0x5*(parseInt(_0x545934(-0x2d8,-0x275,-_0x20ae14._0x19fd07,-_0x20ae14._0x5ee3fe))/0x6)+parseInt(_0x5ad8f0(-0x1b4,-0x1be,-_0x20ae14._0x27e76b,-0x17d))/0x7+-parseInt(_0x545934(-_0x20ae14._0x35b7b5,-0x344,-0x2f5,-_0x20ae14._0x5d58c0))/0x8+-parseInt(_0x5ad8f0(-0x193,-0x16a,-0x194,-0x1d8))/0x9*(parseInt(_0x5ad8f0(-0x22e,-_0x20ae14._0x4d8b6e,-_0x20ae14._0xef8a55,-_0x20ae14._0x1c4141))/0xa)+-parseInt(_0x545934(-0x343,-0x2e8,-0x2a2,-0x311))/0xb*(parseInt(_0x545934(-_0x20ae14._0x4410a5,-0x2bb,-_0x20ae14._0x4396b8,-_0x20ae14._0x59c349))/0xc);if(_0x2e2169===_0x54af5d)break;else _0x442a96['push'](_0x442a96['shift']());}catch(_0x195d58){_0x442a96['push'](_0x442a96['shift']());}}}(_0x5168,0x88ebf));import{withEstimatedModelCost}from'./chunk-GAZGO6N7.js';import{createAssistantTextMessage,createReasoningMessage,createToolResultUserMessage,createToolUseMessage,getToolUseBlocks,normalizeMessage,normalizeSystem,responseToAssistantMessage,synthesizeMissingToolResults}from'./chunk-YNOIG4FD.js';import{TurnFailedError}from'./chunk-FFIZ6TKW.js';import{addAbortListener,isAbortError,throwIfAborted,toAbortError}from'./chunk-X7VAACWY.js';function _0x17cd(_0x54642f,_0x2f0c8b){_0x54642f=_0x54642f-0x8a;const _0x5168ad=_0x5168();let _0x17cd7a=_0x5168ad[_0x54642f];if(_0x17cd['vgSqau']===undefined){var _0x12dc12=function(_0x4922e5){const _0x7b7680='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x48b440='',_0x3b94bf='';for(let _0x5ed594=0x0,_0x240539,_0x4e261,_0xc9410b=0x0;_0x4e261=_0x4922e5['charAt'](_0xc9410b++);~_0x4e261&&(_0x240539=_0x5ed594%0x4?_0x240539*0x40+_0x4e261:_0x4e261,_0x5ed594++%0x4)?_0x48b440+=String['fromCharCode'](0xff&_0x240539>>(-0x2*_0x5ed594&0x6)):0x0){_0x4e261=_0x7b7680['indexOf'](_0x4e261);}for(let _0x217389=0x0,_0x551682=_0x48b440['length'];_0x217389<_0x551682;_0x217389++){_0x3b94bf+='%'+('00'+_0x48b440['charCodeAt'](_0x217389)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x3b94bf);};_0x17cd['jGQGMD']=_0x12dc12,_0x17cd['dxpmXb']={},_0x17cd['vgSqau']=!![];}const _0x2911f4=_0x5168ad[0x0],_0x245bb9=_0x54642f+_0x2911f4,_0x32c4f5=_0x17cd['dxpmXb'][_0x245bb9];return!_0x32c4f5?(_0x17cd7a=_0x17cd['jGQGMD'](_0x17cd7a),_0x17cd['dxpmXb'][_0x245bb9]=_0x17cd7a):_0x17cd7a=_0x32c4f5,_0x17cd7a;}function isJsonObject(_0x48b440){const _0x1993b1={_0x2df9fa:0x14f,_0x323ad1:0x152,_0x470584:0x203},_0xddbd63={_0x2ee812:0x14c};function _0x571555(_0x42d451,_0x4365d2,_0x383868,_0x5d901c){return _0x17cd(_0x42d451-_0xddbd63._0x2ee812,_0x383868);}function _0x3cab6a(_0x40f4d9,_0x28e27b,_0x1dcc9a,_0x1db780){return _0x17cd(_0x40f4d9- -0x253,_0x28e27b);}return typeof _0x48b440===_0x3cab6a(-_0x1993b1._0x2df9fa,-0x125,-_0x1993b1._0x323ad1,-0x157)&&_0x48b440!==null&&!Array[_0x571555(_0x1993b1._0x470584,0x1fc,0x245,0x25d)](_0x48b440);}function isToolOutputEnvelope(_0x3b94bf){const _0x2f4a34={_0x253c66:0x310,_0x58e66d:0x2eb,_0x24842d:0x310,_0xa32839:0x2ac,_0x59b579:0x29e,_0x24a6d7:0x312,_0x4822fb:0x353,_0x4f3436:0x418};if(typeof _0x3b94bf!==_0xd13712(_0x2f4a34._0x253c66,_0x2f4a34._0x58e66d,_0x2f4a34._0x24842d,_0x2f4a34._0xa32839)||_0x3b94bf===null||Array[_0xd13712(0x245,_0x2f4a34._0x59b579,0x238,0x309)](_0x3b94bf))return![];function _0x4a128e(_0xd1eabf,_0x595227,_0x5bf837,_0x2e7dc8){return _0x17cd(_0x5bf837-0x2c1,_0xd1eabf);}if(typeof _0x3b94bf[_0xd13712(0x338,0x2f7,0x2fc,0x28e)]!==_0x4a128e(_0x2f4a34._0x24a6d7,0x381,0x34c,0x2dd))return![];function _0xd13712(_0x3747f2,_0x33d98d,_0x5da4e9,_0x8b1873){return _0x17cd(_0x33d98d-0x1e7,_0x8b1873);}const _0x5ed594=_0x3b94bf[_0x4a128e(_0x2f4a34._0x4822fb,0x39c,0x3b5,_0x2f4a34._0x4f3436)];return _0x5ed594===void 0x0||isJsonObject(_0x5ed594);}function validateAgainstSchema(_0x240539,_0x4e261,_0xc9410b){const _0x121c18={_0x3529f8:0x96,_0x2ea3ab:0x6a,_0x2d777c:0x7,_0x478259:0x46,_0x23c359:0x2b,_0x45c2e6:0x436,_0x621779:0x44f,_0x336443:0x427,_0x1a8ccc:0x431,_0xa7ff2c:0x397,_0x5194ca:0x74,_0x2e9d4f:0x1d,_0x17dd14:0x4d,_0x2262c0:0x57,_0x98367a:0x1e,_0x1bf198:0x48b,_0x119f03:0x4d3,_0x5ea1dc:0x488,_0x16d8cd:0x4cb,_0x12981c:0x4ea,_0x491953:0x4a1,_0x453060:0x4e0,_0x55e926:0x440,_0x5ca778:0x3f6,_0x559033:0x424,_0x1401d1:0x3f7,_0x3bae47:0x13,_0x5290d5:0x31,_0x2f31de:0x495,_0x2431b7:0x45c,_0x425454:0xd,_0x83e457:0x3d,_0x457290:0x409,_0x52533f:0x44,_0x5921ad:0x44,_0x5f000d:0x8f,_0x4a5d57:0x3eb,_0x41fc76:0x38c,_0x39dc9c:0x436,_0x51cee9:0x3fc,_0x414f18:0x428,_0x5bfc61:0x3a,_0x271014:0x56,_0x4acf4a:0x3c8,_0x38f614:0x395,_0x4388a1:0x15,_0x54047f:0x6,_0x4a0571:0x4c6,_0x246f61:0x4ec,_0x2befc2:0x4b,_0x303ad9:0x50,_0x36c202:0x45,_0x74c1a:0xa0,_0x2aa935:0x41,_0x459c3a:0x4,_0x36e9f5:0x7b,_0x4a9db7:0x49,_0x5e06ac:0x74,_0x2ee002:0xa3,_0x59be77:0x434,_0x4258cc:0x3fa,_0xdc07f2:0x6f,_0x1e23d7:0x43,_0x515feb:0x19},_0x37f768={_0x56fa0c:0x366};function _0x491808(_0x23c1c7,_0xf1a236,_0xba5c0e,_0x505b4c){return _0x17cd(_0xba5c0e-_0x37f768._0x56fa0c,_0xf1a236);}function _0x51589b(_0x2d7f49,_0x5a4c28,_0x3215b6,_0x5c189c){return _0x17cd(_0x3215b6- -0x104,_0x5a4c28);}if(_0x51589b(-_0x121c18._0x3529f8,0x28,-0x46,-0x9b)in _0xc9410b){const _0x217389=_0xc9410b[_0x51589b(-_0x121c18._0x2ea3ab,-_0x121c18._0x2d777c,-_0x121c18._0x478259,-0x1a)][_0x51589b(-0x3a,_0x121c18._0x23c359,0x2e,0x10)](_0x551682=>{try{return validateAgainstSchema(_0x240539,_0x4e261,_0x551682),!![];}catch{return![];}});if(!_0x217389)throw new Error('Invalid\x20tool\x20input\x20at\x20'+_0x240539+_0x491808(_0x121c18._0x45c2e6,0x423,0x43a,0x3d9));return;}switch(_0xc9410b[_0x491808(_0x121c18._0x621779,_0x121c18._0x336443,0x471,_0x121c18._0x1a8ccc)]){case _0x491808(_0x121c18._0xa7ff2c,0x395,0x3f1,0x3a7):if(typeof _0x4e261!==_0x491808(0x427,0x3a9,0x3f1,0x45a))throw new Error(_0x51589b(-0xcb,-0xa0,-_0x121c18._0x5194ca,-0x93)+_0x240539+_0x51589b(0xf,-_0x121c18._0x2e9d4f,0x2b,_0x121c18._0x17dd14));if(_0xc9410b[_0x51589b(-0xd,_0x121c18._0x2262c0,_0x121c18._0x98367a,0x1c)]!==void 0x0&&!_0xc9410b[_0x491808(_0x121c18._0x1bf198,_0x121c18._0x119f03,_0x121c18._0x5ea1dc,_0x121c18._0x16d8cd)][_0x491808(_0x121c18._0x12981c,0x50d,_0x121c18._0x491953,_0x121c18._0x453060)](_0x4e261))throw new Error(_0x491808(_0x121c18._0x55e926,0x389,_0x121c18._0x5ca778,0x3a3)+_0x240539+':\x20expected\x20one\x20of\x20'+_0xc9410b[_0x491808(0x429,0x4f2,0x488,0x4ed)][_0x491808(_0x121c18._0x5ca778,_0x121c18._0x559033,_0x121c18._0x1401d1,0x439)](',\x20'));return;case _0x51589b(_0x121c18._0x3bae47,-_0x121c18._0x5290d5,-0xe,0x43):if(typeof _0x4e261!==_0x491808(_0x121c18._0x2f31de,0x48f,_0x121c18._0x2431b7,_0x121c18._0x1a8ccc))throw new Error(_0x51589b(-_0x121c18._0x425454,-0x56,-_0x121c18._0x5194ca,-0x3b)+_0x240539+_0x51589b(-0x12,-0x69,-_0x121c18._0x83e457,-0x55));return;case _0x491808(_0x121c18._0x457290,0x47f,0x412,0x443):if(typeof _0x4e261!==_0x51589b(-0x75,-_0x121c18._0x52533f,-0x58,0x7))throw new Error('Invalid\x20tool\x20input\x20at\x20'+_0x240539+_0x51589b(-0x6e,0x3b,-0xa,_0x121c18._0x5921ad));return;case'array':if(!Array[_0x51589b(-0x3d,-0x26,-0x4d,-_0x121c18._0x5f000d)](_0x4e261))throw new Error(_0x491808(_0x121c18._0x4a5d57,_0x121c18._0x41fc76,0x3f6,_0x121c18._0x39dc9c)+_0x240539+':\x20expected\x20array');_0x4e261[_0x491808(0x44f,0x45f,_0x121c18._0x51cee9,_0x121c18._0x414f18)]((_0x3f1467,_0x1579f2)=>{validateAgainstSchema(_0x240539+'['+_0x1579f2+']',_0x3f1467,_0xc9410b['items']);});return;case _0x51589b(-0x6d,_0x121c18._0x5bfc61,0x0,_0x121c18._0x271014):if(!isJsonObject(_0x4e261))throw new Error(_0x491808(_0x121c18._0x4acf4a,_0x121c18._0x38f614,0x3f6,0x41b)+_0x240539+_0x51589b(0x24,-_0x121c18._0x4388a1,-_0x121c18._0x54047f,-0x56));for(const _0x4d524a of _0xc9410b[_0x491808(0x47d,0x52a,_0x121c18._0x4a0571,_0x121c18._0x246f61)]??[]){if(!Object[_0x51589b(_0x121c18._0x2befc2,-0x5,_0x121c18._0x303ad9,0x7)](_0x4e261,_0x4d524a))throw new Error(_0x51589b(-_0x121c18._0x36c202,-0xdb,-_0x121c18._0x5194ca,-_0x121c18._0x74c1a)+_0x240539+_0x51589b(-_0x121c18._0x4388a1,-0x8d,-0x51,-0xb6)+_0x4d524a+'\x22');}if(_0xc9410b['additionalProperties']===![]){const _0x166c2a=Object['keys'](_0x4e261)[_0x51589b(_0x121c18._0x2aa935,0x3,-_0x121c18._0x459c3a,0x34)](_0x2b143e=>!Object[_0x491808(0x51a,0x49d,0x4ba,0x451)](_0xc9410b[_0x51589b(-0xd,-0x7b,-0x61,-0xca)],_0x2b143e));if(_0x166c2a!==void 0x0)throw new Error(_0x51589b(-_0x121c18._0x36e9f5,-_0x121c18._0x4a9db7,-_0x121c18._0x5e06ac,-0xd7)+_0x240539+_0x51589b(-0x73,-0x66,-_0x121c18._0x52533f,-_0x121c18._0x2ee002)+_0x166c2a+'\x22');}for(const [_0x23fce1,_0x21b1cb]of Object[_0x491808(_0x121c18._0x1a8ccc,0x427,_0x121c18._0x59be77,_0x121c18._0x4258cc)](_0xc9410b[_0x51589b(-0x31,-_0x121c18._0xdc07f2,-0x61,-_0x121c18._0x1e23d7)])){Object[_0x51589b(0x4e,-_0x121c18._0x515feb,_0x121c18._0x303ad9,0x8d)](_0x4e261,_0x23fce1)&&validateAgainstSchema(_0x240539+'.'+_0x23fce1,_0x4e261[_0x23fce1],_0x21b1cb);}}}function normalizeToolOutputValue(_0x3a81d1){const _0x25bb3d={_0x393e0e:0x117,_0x7f8d30:0xc8,_0x1902dd:0x18,_0x849dbe:0x113,_0x425c3c:0x195,_0x8825fd:0x117,_0x24e3ac:0x9f,_0x1c5eb4:0x6c,_0x1f622a:0x22,_0x1ac0a1:0x73,_0x67ef8:0x44,_0x3a281a:0xaf},_0x6c1c44={_0x498d7a:0x227},_0x202f49={_0x5c074a:0x12a};function _0x385656(_0x44a9f2,_0x56c9c1,_0xd21a47,_0x270136){return _0x17cd(_0x56c9c1- -_0x202f49._0x5c074a,_0x270136);}if(isToolOutputEnvelope(_0x3a81d1))return{'output':_0x3a81d1[_0xcd107f(-0x178,-_0x25bb3d._0x393e0e,-_0x25bb3d._0x7f8d30,-0xc7)],'structured':_0x3a81d1[_0x385656(-_0x25bb3d._0x1902dd,-0x36,0x7,-0x5f)]??{'value':_0x3a81d1[_0xcd107f(-0x142,-_0x25bb3d._0x393e0e,-0xb9,-0xc8)]},..._0x3a81d1[_0xcd107f(-_0x25bb3d._0x849dbe,-0x177,-_0x25bb3d._0x425c3c,-_0x25bb3d._0x8825fd)]!==void 0x0?{'content':_0x3a81d1[_0xcd107f(-0x1b8,-0x177,-0x111,-0x16e)]}:{}};if(typeof _0x3a81d1===_0x385656(-0xa9,-_0x25bb3d._0x24e3ac,-_0x25bb3d._0x1c5eb4,-0x74))return{'output':_0x3a81d1,'structured':{'value':_0x3a81d1}};function _0xcd107f(_0x5a979f,_0x27f652,_0x27e9e6,_0x304a27){return _0x17cd(_0x27f652- -_0x6c1c44._0x498d7a,_0x304a27);}if(typeof _0x3a81d1==='object'&&_0x3a81d1!==null&&!Array[_0x385656(-0x81,-0x73,-_0x25bb3d._0x1f622a,-_0x25bb3d._0x1ac0a1)](_0x3a81d1))return{'output':JSON['stringify'](_0x3a81d1,null,0x2),'structured':_0x3a81d1};return{'output':JSON[_0x385656(0x20,-_0x25bb3d._0x67ef8,0x26,-_0x25bb3d._0x3a281a)](_0x3a81d1,null,0x2),'structured':{'value':_0x3a81d1}};}function createToolOutput(_0x5e404a,_0x32e935={'value':_0x5e404a},_0x14e416){return{'output':_0x5e404a,'structured':_0x32e935,..._0x14e416!==void 0x0?{'content':_0x14e416}:{}};}var ToolExecutionError=class extends Error{[_0x3b29bd(0x336,0x323,0x32b,0x32c)];constructor(_0xf2999d,_0x4265f7={}){super(_0xf2999d),this['name']='ToolExecutionError',this['structured']=_0x4265f7;}};function _0x3b29bd(_0x5c5954,_0x19bf1a,_0x22c8f3,_0x3e9d98){const _0xd4e10a={_0x45278b:0x238};return _0x17cd(_0x3e9d98-_0xd4e10a._0x45278b,_0x19bf1a);}function defineTool(_0xe1386c){return _0xe1386c;}function resolveToolPermissionClass(_0xcde63f){const _0x53c6a5={_0x37a604:0x24c,_0x426230:0x250,_0x11daea:0x3c4,_0x15c896:0x35f,_0x17885c:0x376,_0x276c1b:0x37b,_0x5c1191:0x278},_0x32e619={_0x15d5b8:0x7f,_0x2581aa:0x1bd},_0x28a125={_0x2c892a:0x55},_0x344709=_0xcde63f?.[_0x66565(0x20a,_0x53c6a5._0x37a604,0x214,_0x53c6a5._0x426230)];if(_0x344709===_0x3fdbe5(0x35a,0x32f,0x3b6,0x35e)||_0x344709===_0x3fdbe5(_0x53c6a5._0x11daea,_0x53c6a5._0x15c896,_0x53c6a5._0x17885c,_0x53c6a5._0x276c1b)||_0x344709===_0x66565(_0x53c6a5._0x5c1191,0x2db,0x275,0x248))return _0x344709;function _0x3fdbe5(_0x2b4c5b,_0x4f3eb2,_0x23445c,_0x5bc71a){return _0x3b29bd(_0x2b4c5b-0x7d,_0x5bc71a,_0x23445c-0xe4,_0x2b4c5b-_0x28a125._0x2c892a);}function _0x66565(_0x316c3d,_0x6b4e6,_0x1991da,_0x3c49aa){return _0x3b29bd(_0x316c3d-_0x32e619._0x15d5b8,_0x3c49aa,_0x1991da-_0x32e619._0x2581aa,_0x1991da- -0x120);}return'always-confirm';}var ToolRegistry=class{[_0x1f4b8d(-0x1e7,-0x244,-0x23c,-0x207)]=new Map();constructor(_0x357c81=[]){const _0xe784f4={_0x2d59d7:0x254,_0x326aaf:0x1f2},_0x229fa7={_0xdfcdb8:0x573};function _0x3fdec5(_0x5666fd,_0x298d6e,_0x2e0e9f,_0x1e3902){return _0x3b29bd(_0x5666fd-0x3a,_0x5666fd,_0x2e0e9f-0x56,_0x298d6e- -_0x229fa7._0xdfcdb8);}for(const _0x5ca413 of _0x357c81){this[_0x3fdec5(-_0xe784f4._0x2d59d7,-_0xe784f4._0x326aaf,-0x256,-0x1b0)](_0x5ca413);}}[_0x1f4b8d(-0x1d2,-0x1e0,-0x182,-0x16a)](_0x5a457c){const _0x1c3458={_0x3b904b:0x13e,_0x253c39:0x1bc,_0x385f46:0xa9,_0x5ce19b:0x76,_0x218e87:0x61,_0x4cd63b:0x24c,_0x38c2d8:0x23d,_0x4c22b3:0x2ae},_0x2a714c={_0x5dfa7b:0x16d,_0x441d5a:0xd8},_0x489cff={_0x45bb30:0x14a,_0x18b95d:0x3c6,_0x482ba6:0x1aa};function _0x426f36(_0x3706de,_0x41be39,_0x536127,_0x4e289f){return _0x1f4b8d(_0x536127,_0x41be39-_0x489cff._0x45bb30,_0x3706de-_0x489cff._0x18b95d,_0x4e289f-_0x489cff._0x482ba6);}function _0x4ba5e4(_0x590fc0,_0x1f252b,_0x443250,_0x38e329){return _0x1f4b8d(_0x443250,_0x1f252b-_0x2a714c._0x5dfa7b,_0x1f252b-_0x2a714c._0x441d5a,_0x38e329-0x182);}this[_0x4ba5e4(-0x1a0,-0x164,-_0x1c3458._0x3b904b,-_0x1c3458._0x253c39)][_0x4ba5e4(-0x10a,-_0x1c3458._0x385f46,-_0x1c3458._0x5ce19b,-_0x1c3458._0x218e87)](_0x5a457c[_0x426f36(_0x1c3458._0x4cd63b,0x2b1,_0x1c3458._0x38c2d8,_0x1c3458._0x4c22b3)],_0x5a457c);}['get'](_0x2ca77d){const _0x5f02da={_0x5022f8:0x93},_0xcce628={_0x3a1491:0x18d,_0x489eba:0x35a};function _0x559991(_0x5c1ce3,_0x42dd91,_0x26a4e0,_0x5bc4b9){return _0x3b29bd(_0x5c1ce3-0x153,_0x5bc4b9,_0x26a4e0-_0xcce628._0x3a1491,_0x5c1ce3- -_0xcce628._0x489eba);}return this[_0x559991(-_0x5f02da._0x5022f8,-0xc4,-0x3c,-0xca)]['get'](_0x2ca77d);}[_0x1f4b8d(-0x24c,-0x1db,-0x22d,-0x1c4)](){return[...this['toolsByName']['values']()];}['listToolSchemas'](){const _0xb9ff41={_0x4b467b:0x21f,_0x26259e:0x253,_0x1ec454:0x219,_0x14e492:0x23c},_0x9a0acd={_0x18032f:0xc4,_0x22f28b:0x30,_0x67b29e:0x3b,_0x1ac275:0x1,_0x111f9a:0x1c},_0x55d3cb={_0x23590d:0x1ca};function _0x103534(_0x555534,_0x5c284d,_0x39111e,_0x3b2fd3){return _0x3b29bd(_0x555534-0x130,_0x555534,_0x39111e-_0x55d3cb._0x23590d,_0x3b2fd3-0x76);}function _0x5674ba(_0x2750f9,_0x1eb330,_0x55807a,_0x365820){return _0x1f4b8d(_0x55807a,_0x1eb330-0xbd,_0x365820-0x3e3,_0x365820-0x168);}return this[_0x5674ba(0x181,_0xb9ff41._0x4b467b,0x21f,0x1b6)]()[_0x5674ba(_0xb9ff41._0x26259e,0x29b,_0xb9ff41._0x1ec454,_0xb9ff41._0x14e492)](_0x4c63a4=>{const _0x2b67ee={_0x460796:0x1b2};function _0x238393(_0x668b46,_0x54cefe,_0x296369,_0xb33bed){return _0x5674ba(_0x668b46-0xf5,_0x54cefe-0x147,_0xb33bed,_0x296369- -0x222);}function _0x378381(_0x5a637e,_0x42b113,_0x51aa17,_0x4d926e){return _0x103534(_0x5a637e,_0x42b113-0x7d,_0x51aa17-_0x2b67ee._0x460796,_0x4d926e- -0x4f1);}return{'name':_0x4c63a4['name'],'description':_0x4c63a4[_0x378381(-_0x9a0acd._0x18032f,-0xd8,-0x178,-0x110)],'input_schema':_0x4c63a4[_0x238393(-_0x9a0acd._0x22f28b,-_0x9a0acd._0x67b29e,-_0x9a0acd._0x1ac275,-_0x9a0acd._0x111f9a)]};});}};function validateToolInput(_0x3b7fc4,_0x481d99){const _0x29c6cd={_0x522fcb:0x95};function _0x10f428(_0x5a55cd,_0x20125c,_0x467c9c,_0x2c9f49){return _0x3b29bd(_0x5a55cd-0x18,_0x20125c,_0x467c9c-_0x29c6cd._0x522fcb,_0x2c9f49- -0x2be);}return validateAgainstSchema(_0x10f428(0x56,0x47,0xe1,0x7b),_0x3b7fc4,_0x481d99),_0x3b7fc4;}function deriveFinalToolOutput(_0x2f9b5d){const _0x2628a2={_0x29e7e2:0xc0,_0x5a6273:0x93,_0x5331af:0x1b,_0x51f6d4:0xbc,_0x50a43b:0x4b,_0xef555c:0xb,_0x4e042a:0x3f,_0x3cfbd3:0x2d,_0x412cc2:0x53,_0x13252d:0xa0,_0x243149:0xec,_0x48cda4:0x2,_0x275a4d:0x4c,_0x3a8b93:0x137,_0x23dea2:0x39},_0x3edb84={_0x557ca4:0x11b},_0x169241={_0xd8935b:0x17,_0x314fb8:0x1d0,_0x18f00d:0x1ae};if(_0x2f9b5d[_0x141a1a(-0x159,-0xec,-_0x2628a2._0x29e7e2,-0xca)]===0x0)return{'output':'','structured':{}};function _0x131127(_0x569434,_0x373f86,_0xea0e1a,_0x36f5f0){return _0x1f4b8d(_0x373f86,_0x373f86-_0x169241._0xd8935b,_0x569434-_0x169241._0x314fb8,_0x36f5f0-_0x169241._0x18f00d);}if(_0x2f9b5d[_0x131127(-0x37,0x31,-_0x2628a2._0x5a6273,_0x2628a2._0x5331af)]===0x1)return{'output':_0x2f9b5d[0x0]['output'],'structured':_0x2f9b5d[0x0][_0x141a1a(-0xdb,-_0x2628a2._0x51f6d4,-0xab,-0xcb)],..._0x2f9b5d[0x0]['content']!==void 0x0?{'content':_0x2f9b5d[0x0][_0x131127(-_0x2628a2._0x50a43b,-0xb9,-_0x2628a2._0xef555c,-0x78)]}:{}};function _0x141a1a(_0x33f20d,_0x42d3f0,_0x1ee42,_0x40f139){return _0x1f4b8d(_0x1ee42,_0x42d3f0-0x125,_0x42d3f0-_0x3edb84._0x557ca4,_0x40f139-0x13c);}const _0x2f4664=_0x2f9b5d[_0x131127(-_0x2628a2._0x4e042a,-0xa8,-0x2b,-_0x2628a2._0x3cfbd3)](_0x3424b0=>_0x3424b0[_0x131127(-0x4b,-0x82,-0x36,-0x3e)]!==void 0x0);return{'output':_0x2f9b5d[_0x141a1a(-_0x2628a2._0x412cc2,-0x8c,-_0x2628a2._0x13252d,-_0x2628a2._0x243149)](_0x3724e7=>_0x3724e7[_0x131127(0x15,0x34,0x4a,-0x5)])['join'](''),'structured':{'chunks':_0x2f9b5d[_0x131127(0x29,_0x2628a2._0x48cda4,-0x2e,_0x2628a2._0x275a4d)](_0x11c858=>_0x11c858[_0x141a1a(-0x64,-0xbc,-0xcc,-0x81)])},..._0x2f4664[_0x141a1a(-0xaf,-0xec,-0x117,-_0x2628a2._0x3a8b93)]===0x1?{'content':_0x2f4664[0x0][_0x131127(-0x4b,-0x10,-0x54,-_0x2628a2._0x23dea2)]}:{}};}function createToolMeta(){return{'transforms':[]};}function createErrorToolResult(_0x5a74c7,_0x557868,_0x3ae02f,_0x5a0c85=[]){const _0x505541={_0x4bd806:0x2fd,_0x2ee9fb:0x305,_0x3a74df:0x2f0,_0x5036a1:0x2b5,_0x5254ab:0x24b},_0x6abfb0={_0x13e4c9:0xa6,_0x267979:0x2c,_0x370f52:0x113},_0x2f5a27={_0x334b8e:0x6,_0xd4155:0x86};function _0xba6972(_0x33a64e,_0x4f82aa,_0x1a616c,_0x1088fd){return _0x3b29bd(_0x33a64e-_0x2f5a27._0x334b8e,_0x4f82aa,_0x1a616c-0x1b,_0x1a616c- -_0x2f5a27._0xd4155);}function _0x1d2539(_0x40a719,_0x29e9f7,_0xc84390,_0x53a0cc){return _0x1f4b8d(_0x53a0cc,_0x29e9f7-_0x6abfb0._0x13e4c9,_0x40a719-_0x6abfb0._0x267979,_0x53a0cc-_0x6abfb0._0x370f52);}return{'callId':_0x5a74c7['id'],'toolName':_0x5a74c7[_0xba6972(_0x505541._0x4bd806,_0x505541._0x2ee9fb,0x303,_0x505541._0x3a74df)],'status':_0xba6972(_0x505541._0x5036a1,0x260,_0x505541._0x5254ab,0x27c),'output':_0x557868,'structured':_0x3ae02f,'chunks':_0x5a0c85,'meta':createToolMeta()};}function createRejectedToolResult(_0x20a0ec,_0x4bb2e3){const _0x45479b={_0x1f02f8:0x3c8,_0x140a1b:0x389,_0x4ae4af:0x421,_0x254d2a:0x3a9,_0x8b8b4:0x34e,_0x2528b5:0x385,_0xed8e8d:0x415,_0xed4fdd:0x3f7,_0x532db4:0x3a9,_0x560441:0x403},_0x187831={_0x554800:0x5e8},_0x5e52bb=_0x4bb2e3?.[_0x93f009(_0x45479b._0x1f02f8,_0x45479b._0x140a1b,_0x45479b._0x4ae4af,0x3f2)]()[_0x5a6ce9(_0x45479b._0x254d2a,0x3c9,_0x45479b._0x8b8b4,0x33a)]?_0x4bb2e3:_0x5a6ce9(_0x45479b._0x2528b5,0x320,0x338,0x386)+_0x20a0ec['name'];function _0x5a6ce9(_0x176f06,_0x479988,_0x40fbf8,_0x4d5f46){return _0x1f4b8d(_0x40fbf8,_0x479988-0x1e2,_0x176f06-0x5b0,_0x4d5f46-0xc6);}function _0x93f009(_0xb05b65,_0x431b89,_0x5693af,_0x5afb32){return _0x1f4b8d(_0x431b89,_0x431b89-0xc9,_0x5afb32-_0x187831._0x554800,_0x5afb32-0x9f);}return createErrorToolResult(_0x20a0ec,_0x5e52bb,{'error':_0x5a6ce9(0x39e,0x3dc,0x3a4,0x334),..._0x4bb2e3?.[_0x5a6ce9(0x3ba,_0x45479b._0xed8e8d,_0x45479b._0xed4fdd,0x36c)]()[_0x5a6ce9(_0x45479b._0x532db4,0x3b4,0x407,_0x45479b._0x560441)]?{'reason':_0x4bb2e3}:{}});}function createAbortedToolResult(_0x92be65,_0x19d7c8,_0x13b479=[]){const _0x3920d8={_0x280e81:0x255},_0x17175f={_0x51f149:0x64,_0x464d11:0x383,_0x47cbf9:0x10f},_0x3ea8c0=toAbortError(_0x19d7c8);function _0x36ca17(_0x3efb7e,_0x348766,_0x3a5670,_0x38c0d0){return _0x1f4b8d(_0x3efb7e,_0x348766-_0x17175f._0x51f149,_0x38c0d0-_0x17175f._0x464d11,_0x38c0d0-_0x17175f._0x47cbf9);}return createErrorToolResult(_0x92be65,_0x3ea8c0[_0x36ca17(0x1b5,_0x3920d8._0x280e81,0x197,0x1fa)],{'error':_0x3ea8c0['message'],'aborted':!![]},_0x13b479);}function createSuccessToolResult(_0x55091a,_0xb4e3e9,_0x680e74){const _0x5eee56={_0xfb5f3d:0x2fb,_0x58fbe3:0x32c,_0x3ff5b4:0x2cf,_0x3336c7:0x2e4,_0x9d2cdb:0x2df,_0xa306a0:0x3a9,_0x4c381f:0x3df,_0x193cce:0x374,_0x2c1be8:0x2cd,_0x258c10:0x2d9},_0x1456e4={_0xb9bc1:0x1e5,_0x385333:0x10c,_0x19e76a:0x8e},_0x4dc42c={_0x66e87a:0xef,_0x463bdd:0xbb,_0x4bad0d:0x51};function _0x1f99f3(_0x4915de,_0x9b2058,_0x38d571,_0x16d488){return _0x3b29bd(_0x4915de-_0x4dc42c._0x66e87a,_0x38d571,_0x38d571-_0x4dc42c._0x463bdd,_0x16d488-_0x4dc42c._0x4bad0d);}function _0x4f6c21(_0x28a0d2,_0x32a247,_0x563294,_0x330d20){return _0x3b29bd(_0x28a0d2-_0x1456e4._0xb9bc1,_0x32a247,_0x563294-_0x1456e4._0x385333,_0x28a0d2- -_0x1456e4._0x19e76a);}return{'callId':_0x55091a['id'],'toolName':_0x55091a[_0x4f6c21(_0x5eee56._0xfb5f3d,0x313,_0x5eee56._0x58fbe3,_0x5eee56._0x3ff5b4)],'status':'ok','output':_0xb4e3e9[_0x4f6c21(0x2ba,0x327,_0x5eee56._0x3336c7,_0x5eee56._0x9d2cdb)],'structured':_0xb4e3e9[_0x1f99f3(_0x5eee56._0xa306a0,0x3e0,_0x5eee56._0x4c381f,0x37d)],..._0xb4e3e9[_0x1f99f3(_0x5eee56._0x193cce,_0x5eee56._0x2c1be8,_0x5eee56._0x258c10,0x339)]!==void 0x0?{'content':_0xb4e3e9['content']}:{},'chunks':_0x680e74,'meta':createToolMeta()};}function createUnknownToolResult(_0x2c8e98){const _0x2d3528={_0x3f3c83:0x199,_0x1f6f81:0x13b,_0xdc8e4f:0x174},_0x324ec5={_0x1724a8:0x319},_0x3087f6={_0x1265e9:0xd,_0x54bbe2:0xe4};function _0x41e098(_0x23bda4,_0x5447a3,_0x239776,_0x17c476){return _0x1f4b8d(_0x5447a3,_0x5447a3-_0x3087f6._0x1265e9,_0x17c476-0x34b,_0x17c476-_0x3087f6._0x54bbe2);}function _0x53e804(_0x473c93,_0x2b516e,_0x336447,_0x53a64){return _0x1f4b8d(_0x336447,_0x2b516e-0x75,_0x2b516e-_0x324ec5._0x1724a8,_0x53a64-0xa4);}return createErrorToolResult(_0x2c8e98,_0x53e804(0x12a,_0x2d3528._0x3f3c83,0x1f5,0x179)+_0x2c8e98['name'],{'error':_0x53e804(0x142,_0x2d3528._0x1f6f81,_0x2d3528._0xdc8e4f,0x19a)});}function isDispatchDecision(_0x243faa){const _0x4a30d3={_0x7e1548:0x49,_0x529822:0xc7,_0x470fdd:0x85,_0x61cee1:0x65,_0x7a9e1e:0x83,_0x1dfde5:0x2b},_0x231d32={_0x27475c:0x36,_0x521038:0x385},_0x5c863b={_0x3c8422:0x1a9,_0x5a135d:0xa7};if(typeof _0x243faa!==_0xc4df44(-0x1a,-_0x4a30d3._0x7e1548,-0x4e,0x1)||_0x243faa===null)return![];function _0x4977e7(_0x46334b,_0x28bec1,_0x1803fd,_0x4bd7){return _0x1f4b8d(_0x1803fd,_0x28bec1-_0x5c863b._0x3c8422,_0x4bd7- -_0x5c863b._0x5a135d,_0x4bd7-0x137);}function _0xc4df44(_0x3b0478,_0x267616,_0x293ca3,_0x3359ef){return _0x3b29bd(_0x3b0478-0x41,_0x3359ef,_0x293ca3-_0x231d32._0x27475c,_0x267616- -_0x231d32._0x521038);}return _0x243faa['action']===_0xc4df44(-_0x4a30d3._0x529822,-_0x4a30d3._0x470fdd,-_0x4a30d3._0x61cee1,-0x48)||_0x243faa['action']===_0xc4df44(-0xb0,-_0x4a30d3._0x7a9e1e,-0x63,-_0x4a30d3._0x1dfde5);}function normalizeExecutionError(_0x28b505){const _0x194aa5={_0x5f0dba:0xcc,_0x526d11:0x125,_0x5123e3:0xd3,_0x2cf5bf:0xed,_0xf692eb:0x18f,_0xeeae19:0x179,_0x3f0d46:0xfa,_0x595915:0xeb,_0x4c13dc:0x121,_0x1a9e31:0x1c8,_0x228915:0x1b9,_0x1d9252:0x124,_0x1c9d11:0x18e,_0x1c4704:0x193,_0x2b01f1:0x14d},_0x34431a={_0x18357e:0x1c8},_0x230b4b={_0x4a78ac:0x171,_0x15876d:0xed,_0x579330:0xb3};if(_0x28b505 instanceof ToolExecutionError)return{'errorMessage':_0x28b505[_0x1ede02(-0xc4,-0x124,-_0x194aa5._0x5f0dba,-_0x194aa5._0x526d11)],'structured':{'error':_0x28b505[_0x1ede02(-_0x194aa5._0x5123e3,-0x124,-_0x194aa5._0x2cf5bf,-_0x194aa5._0xf692eb)],..._0x28b505[_0x1ede02(-_0x194aa5._0xeeae19,-0x172,-0x13d,-0x14c)]}};if(_0x28b505 instanceof Error)return{'errorMessage':_0x28b505['message'],'structured':{'error':_0x28b505[_0x1ede02(-_0x194aa5._0x3f0d46,-0x124,-_0x194aa5._0x595915,-0x153)]}};if(typeof _0x28b505===_0x1ede02(-_0x194aa5._0x4c13dc,-0x162,-_0x194aa5._0x1a9e31,-_0x194aa5._0x228915)&&_0x28b505!==null&&'message'in _0x28b505&&typeof _0x28b505[_0x1ede02(-0x13b,-_0x194aa5._0x1d9252,-_0x194aa5._0x1c9d11,-0x185)]===_0x1ede02(-0x1aa,-0x1db,-_0x194aa5._0x1c4704,-0x246))return{'errorMessage':_0x28b505[_0x1ede02(-0x167,-_0x194aa5._0x1d9252,-_0x194aa5._0x2b01f1,-0x18d)],'structured':{'error':_0x28b505['message']}};const _0x47ec6d=String(_0x28b505);function _0x24e6ab(_0x54efb3,_0x1e41d6,_0x29f7d6,_0x186508){return _0x3b29bd(_0x54efb3-_0x230b4b._0x4a78ac,_0x1e41d6,_0x29f7d6-_0x230b4b._0x15876d,_0x29f7d6- -_0x230b4b._0x579330);}function _0x1ede02(_0x26cc6f,_0x591fbb,_0x31dd89,_0x1d5483){return _0x3b29bd(_0x26cc6f-0x17e,_0x31dd89,_0x31dd89-_0x34431a._0x18357e,_0x591fbb- -0x49e);}return{'errorMessage':_0x47ec6d,'structured':{'error':_0x47ec6d}};}async function emitEvent(_0x49f28a,_0x1d8b3d,_0x213c64){await _0x49f28a?.(_0x1d8b3d,_0x213c64);}async function resolveDispatchDecision(_0x26f6a8,_0x1b7d84,_0x1b24af){const _0x126ce8={_0x4da227:0x10f,_0x277713:0x104,_0x183833:0x111,_0x2f2129:0x3e,_0x2a0b80:0x90,_0x1a9d5b:0x92,_0x54da85:0xb1,_0x50be6f:0xd0,_0x3e66f7:0x110,_0x32b136:0xb9,_0x2208fe:0xc7},_0x28db75={_0x570690:0x1b2,_0x556590:0x208,_0x46a5a5:0x3,_0x1eb86f:0x26,_0x52f976:0x3f,_0x396793:0x79,_0x519809:0x37},_0x32f51d={_0x4fe5c1:0x42c,_0x152e05:0x48f,_0x181dad:0x494,_0x3b7d31:0x2e0,_0x483891:0x4c5},_0x5f10e7={_0x56d251:0x1ed,_0x198ec8:0x300},_0x731f54={_0xc0d9a2:0x1e4};if(!_0x26f6a8)return{'action':_0x1390b9(-_0x126ce8._0x4da227,-0x123,-0x11a,-0xd0)};const _0x1ddb71=Promise[_0x572be9(_0x126ce8._0x277713,0x9a,_0x126ce8._0x183833,0x135)]()[_0x1390b9(-0xbd,-0xc8,-_0x126ce8._0x2f2129,-_0x126ce8._0x2a0b80)](()=>_0x26f6a8(_0x1b7d84,_0x1b24af));if(!_0x1b24af[_0x1390b9(-0xaa,-0xe7,-0x131,-0xed)]){const _0xbf7dc4=await _0x1ddb71;return isDispatchDecision(_0xbf7dc4)?_0xbf7dc4:{'action':_0x1390b9(-_0x126ce8._0x1a9d5b,-_0x126ce8._0x54da85,-0x7e,-_0x126ce8._0x50be6f)};}function _0x1390b9(_0x56a66a,_0x27c8b3,_0x33712e,_0x2d50b6){return _0x1f4b8d(_0x56a66a,_0x27c8b3-_0x731f54._0xc0d9a2,_0x2d50b6-0x131,_0x2d50b6-0xe);}function _0x572be9(_0x18bb41,_0x532dbc,_0x2e48e0,_0x16eb84){return _0x1f4b8d(_0x532dbc,_0x532dbc-_0x5f10e7._0x56d251,_0x18bb41-_0x5f10e7._0x198ec8,_0x16eb84-0xcb);}const _0x1a89aa=new Promise((_0x16a3d5,_0x2bfe4a)=>{const _0x449ddf={_0x428a1f:0x3d1},_0xd8098e={_0x169721:0x33b},_0x6a84f2={_0x3ab2a0:0x168};function _0x2b61a7(_0x2aee3a,_0x9704a2,_0x1f270d,_0x1d6cd1){return _0x1390b9(_0x1f270d,_0x9704a2-0x1a4,_0x1f270d-0x125,_0x2aee3a- -_0x6a84f2._0x3ab2a0);}const _0x22025e=()=>{function _0x73d250(_0x3064b9,_0x42a7c7,_0x4c1781,_0x618ccf){return _0x17cd(_0x42a7c7- -_0xd8098e._0x169721,_0x618ccf);}function _0x40aa02(_0xc372a,_0x3e4635,_0x59b328,_0x446b7e){return _0x17cd(_0x3e4635-_0x449ddf._0x428a1f,_0x59b328);}_0x1b24af[_0x40aa02(_0x32f51d._0x4fe5c1,0x47e,_0x32f51d._0x152e05,_0x32f51d._0x181dad)]?.['removeEventListener']('abort',_0x22025e),_0x2bfe4a(toAbortError(_0x1b24af[_0x73d250(-0x2d4,-0x28e,-_0x32f51d._0x3b7d31,-0x286)]?.[_0x40aa02(0x4ee,0x4ac,_0x32f51d._0x483891,0x4de)]));};function _0x147f18(_0x493467,_0x27879e,_0x15baaa,_0x173da1){return _0x572be9(_0x493467- -0xe5,_0x27879e,_0x15baaa-0x16e,_0x173da1-0x8f);}if(_0x1b24af['signal']?.[_0x2b61a7(-0x1c3,-0x22b,-_0x28db75._0x570690,-0x159)]){_0x2bfe4a(toAbortError(_0x1b24af['signal'][_0x2b61a7(-0x227,-_0x28db75._0x556590,-0x237,-0x1f4)]));return;}_0x1b24af[_0x147f18(-_0x28db75._0x46a5a5,-0x3,_0x28db75._0x1eb86f,0x4f)]?.[_0x147f18(_0x28db75._0x52f976,0xc,0xa0,-0xd)](_0x147f18(0x2f,_0x28db75._0x396793,0x90,_0x28db75._0x519809),_0x22025e,{'once':!![]});}),_0x248ee6=await Promise[_0x1390b9(-0x60,-_0x126ce8._0x3e66f7,-_0x126ce8._0x32b136,-0xb5)]([_0x1ddb71,_0x1a89aa]);return isDispatchDecision(_0x248ee6)?_0x248ee6:{'action':_0x572be9(0xff,0x15b,0x13f,_0x126ce8._0x2208fe)};}async function executeCapturedToolCall(_0x5ce63d,_0x3f42ca,_0x53d79e,_0x2948c0,_0x51d566){const _0x1161b4={_0x2683d8:0x41c,_0x5fed97:0x469,_0xf8f6bc:0x3c,_0x4eb012:0xed,_0x5dcaa4:0x412,_0x211d70:0xc4,_0x3b7cc0:0xf9,_0x112c40:0x11f,_0x59be87:0x96,_0x42581e:0x9b,_0x2c9495:0xe5,_0x58cd02:0x4e7,_0x1599aa:0x474,_0x5034f4:0xa8,_0x5149d7:0x6a,_0x3f683e:0x5c,_0x537e95:0x6c,_0x4fd622:0x93,_0x1f37c8:0x43c,_0x3ad09f:0x4f2,_0x7bd02a:0x4e3,_0x3e1348:0x74,_0x233c7c:0x68,_0xad1c43:0x81,_0x57d375:0x5a,_0x10f3aa:0x415,_0x5c380e:0x4a8,_0x32939d:0x3dc,_0x4a71c9:0x447,_0x3f7782:0x43b,_0x50566d:0x4a6,_0x2b85a4:0x85,_0x4f61b2:0xb6,_0x5b323c:0x14,_0x5d5a73:0x19,_0x17db5e:0x41,_0x4ce8b6:0xac,_0x20823b:0xe3,_0x4d6fbd:0xf1,_0x7ac23d:0x114,_0x59e31a:0xb4,_0x40f2e0:0x105,_0x2432ef:0x4e5,_0x2d52b7:0x4a2,_0x2665fc:0x44a,_0x961e1f:0x99,_0x5f555c:0xb6,_0x2eaca5:0x499,_0xbe733d:0x43f,_0x3b96e8:0x3f1,_0x2cf76f:0x457,_0x3530ce:0x41e,_0x1c4cab:0x63,_0x33270a:0xb9,_0x175f12:0x8d},_0x325f29={_0x3fafbc:0x665},_0x2f33e3={_0x997083:0x2f,_0x29753e:0x93},_0x14c788={..._0x53d79e,'toolCallId':_0x3f42ca['id'],'permissionClass':resolveToolPermissionClass(_0x5ce63d),'executionAuthorization':void 0x0};throwIfAborted(_0x14c788[_0x4727bc(_0x1161b4._0x2683d8,0x42d,_0x1161b4._0x5fed97,0x447)]);let _0x5d63de;try{_0x5d63de=await resolveDispatchDecision(_0x2948c0,_0x3f42ca,_0x14c788);}catch(_0x1ce56f){if(isAbortError(_0x1ce56f)){const _0x5e4d6c=createAbortedToolResult(_0x3f42ca,_0x1ce56f);return await emitEvent(_0x51d566,{'type':_0x853dc4(-0x37,-0x8d,-_0x1161b4._0xf8f6bc,-_0x1161b4._0x4eb012),'toolCall':_0x3f42ca,'result':_0x5e4d6c},_0x14c788),_0x5e4d6c;}const {errorMessage:_0x1fea19,structured:_0x2c4350}=normalizeExecutionError(_0x1ce56f),_0x5dbcf3=createErrorToolResult(_0x3f42ca,_0x1fea19,_0x2c4350);return await emitEvent(_0x51d566,{'type':_0x4727bc(0x412,0x4b8,_0x1161b4._0x5dcaa4,0x47e),'toolCall':_0x3f42ca,'result':_0x5dbcf3},_0x14c788),_0x5dbcf3;}throwIfAborted(_0x14c788[_0x853dc4(-0x5a,-_0x1161b4._0x211d70,-_0x1161b4._0x3b7cc0,-_0x1161b4._0x112c40)]);if(_0x5d63de['action']==='reject'){const _0x5f5106=createRejectedToolResult(_0x3f42ca,_0x5d63de[_0x853dc4(-0xb6,-_0x1161b4._0x59be87,-_0x1161b4._0x42581e,-_0x1161b4._0x2c9495)]);return await emitEvent(_0x51d566,{'type':'tool_rejected','toolCall':_0x3f42ca,'result':_0x5f5106},_0x14c788),_0x5f5106;}if(!_0x5ce63d){const _0x4ee295=createUnknownToolResult(_0x3f42ca);return await emitEvent(_0x51d566,{'type':_0x4727bc(_0x1161b4._0x58cd02,_0x1161b4._0x1599aa,0x4dc,0x47e),'toolCall':_0x3f42ca,'result':_0x4ee295},_0x14c788),_0x4ee295;}function _0x853dc4(_0x4361ca,_0x5cfcca,_0x59da69,_0x999ad5){return _0x1f4b8d(_0x59da69,_0x5cfcca-_0x2f33e3._0x997083,_0x5cfcca-0x15a,_0x999ad5-_0x2f33e3._0x29753e);}const _0x33517f={..._0x14c788,'executionAuthorization':_0x5d63de['executionAuthorization']};throwIfAborted(_0x33517f[_0x853dc4(-0xfb,-_0x1161b4._0x211d70,-0x108,-_0x1161b4._0x5034f4)]),await emitEvent(_0x51d566,{'type':_0x853dc4(-_0x1161b4._0x5149d7,-0x53,-_0x1161b4._0x3f683e,-0xc),'toolCall':_0x3f42ca},_0x33517f);function _0x4727bc(_0x3d749a,_0x58a4bd,_0x2ae5fa,_0x4b21a0){return _0x1f4b8d(_0x2ae5fa,_0x58a4bd-0xcc,_0x4b21a0-_0x325f29._0x3fafbc,_0x4b21a0-0x1b1);}try{throwIfAborted(_0x33517f[_0x853dc4(-_0x1161b4._0x537e95,-0xc4,-_0x1161b4._0x4fd622,-0xfe)]);const _0x52798a=validateToolInput(_0x3f42ca[_0x4727bc(_0x1161b4._0x1f37c8,_0x1161b4._0x3ad09f,_0x1161b4._0x7bd02a,0x49b)],_0x5ce63d[_0x853dc4(-_0x1161b4._0x3e1348,-_0x1161b4._0x233c7c,-_0x1161b4._0xad1c43,0x7)]),_0x55bf2e=await _0x5ce63d[_0x853dc4(-0x66,-0xc8,-0xa2,-_0x1161b4._0x57d375)](_0x52798a,_0x33517f),_0x3c78c7=[],_0x31e33a=addAbortListener(_0x33517f[_0x4727bc(_0x1161b4._0x10f3aa,_0x1161b4._0x5c380e,_0x1161b4._0x32939d,_0x1161b4._0x4a71c9)],()=>{void _0x55bf2e['return'](void 0x0)['catch'](()=>{});});try{throwIfAborted(_0x33517f[_0x4727bc(_0x1161b4._0x3f7782,0x404,_0x1161b4._0x50566d,0x447)]);let _0x55c1e2=await _0x55bf2e[_0x853dc4(-_0x1161b4._0x2b85a4,-_0x1161b4._0x4f61b2,-0xd6,-0x4e)]();while(!_0x55c1e2[_0x853dc4(_0x1161b4._0x5b323c,-_0x1161b4._0x5d5a73,-_0x1161b4._0x17db5e,-0x3e)]){throwIfAborted(_0x33517f[_0x853dc4(-_0x1161b4._0x4ce8b6,-0xc4,-_0x1161b4._0x20823b,-_0x1161b4._0x4d6fbd)]);const _0x3345d1=normalizeToolOutputValue(_0x55c1e2[_0x853dc4(-_0x1161b4._0x7ac23d,-_0x1161b4._0x59e31a,-0x52,-_0x1161b4._0x40f2e0)]);_0x3c78c7[_0x4727bc(0x50a,_0x1161b4._0x2432ef,_0x1161b4._0x2d52b7,0x4f9)](_0x3345d1),await emitEvent(_0x51d566,{'type':_0x4727bc(0x417,0x4a8,_0x1161b4._0x2665fc,0x47a),'toolCall':_0x3f42ca,'chunk':_0x3345d1},_0x33517f),throwIfAborted(_0x33517f[_0x853dc4(-0xb5,-_0x1161b4._0x211d70,-0x10d,-0x107)]),_0x55c1e2=await _0x55bf2e[_0x853dc4(-_0x1161b4._0x961e1f,-_0x1161b4._0x5f555c,-0x66,-0xbf)]();}throwIfAborted(_0x33517f['signal']);const _0x29ff8b=_0x55c1e2[_0x4727bc(_0x1161b4._0x2eaca5,_0x1161b4._0xbe733d,_0x1161b4._0x3b96e8,_0x1161b4._0x2cf76f)]===void 0x0?deriveFinalToolOutput(_0x3c78c7):normalizeToolOutputValue(_0x55c1e2[_0x4727bc(0x481,_0x1161b4._0x3530ce,0x476,_0x1161b4._0x2cf76f)]),_0x1a93ec=createSuccessToolResult(_0x3f42ca,_0x29ff8b,_0x3c78c7);return await emitEvent(_0x51d566,{'type':'tool_completed','toolCall':_0x3f42ca,'result':_0x1a93ec},_0x33517f),_0x1a93ec;}catch(_0xfd34c8){if(isAbortError(_0xfd34c8)){const _0x1b5069=createAbortedToolResult(_0x3f42ca,_0xfd34c8,_0x3c78c7);return await emitEvent(_0x51d566,{'type':'tool_completed','toolCall':_0x3f42ca,'result':_0x1b5069},_0x33517f),_0x1b5069;}const {errorMessage:_0x5bbc97,structured:_0x2fdc08}=normalizeExecutionError(_0xfd34c8),_0x15e640=createErrorToolResult(_0x3f42ca,_0x5bbc97,_0x2fdc08,_0x3c78c7);return await emitEvent(_0x51d566,{'type':_0x853dc4(-0xae,-0x8d,-_0x1161b4._0x1c4cab,-0xcd),'toolCall':_0x3f42ca,'result':_0x15e640},_0x33517f),_0x15e640;}finally{_0x31e33a();}}catch(_0x116c4a){if(isAbortError(_0x116c4a)){const _0x26b1e7=createAbortedToolResult(_0x3f42ca,_0x116c4a);return await emitEvent(_0x51d566,{'type':'tool_completed','toolCall':_0x3f42ca,'result':_0x26b1e7},_0x33517f),_0x26b1e7;}const {errorMessage:_0x43137e,structured:_0x39eabc}=normalizeExecutionError(_0x116c4a),_0x3d805d=createErrorToolResult(_0x3f42ca,_0x43137e,_0x39eabc);return await emitEvent(_0x51d566,{'type':_0x853dc4(-_0x1161b4._0x33270a,-_0x1161b4._0x175f12,-0xcf,-0xe2),'toolCall':_0x3f42ca,'result':_0x3d805d},_0x33517f),_0x3d805d;}}async function executeToolCall(_0x18b501,_0x1092bc,_0x4ce293,_0x1f521b,_0x3f0c12){const _0x22b108={_0x5efe42:0x50,_0x4ad4c9:0x26,_0x1fd7e7:0x467,_0xe48dc:0x4e3,_0x47a84c:0x50e,_0x52cefe:0x53f},_0xd9c3c1={_0x2253fe:0x1e2},_0x15d450={_0x54dde9:0x88,_0x5554ce:0x208};function _0x522d40(_0x57c59d,_0x4b3177,_0x311f54,_0x22ec4a){return _0x1f4b8d(_0x4b3177,_0x4b3177-_0x15d450._0x54dde9,_0x311f54-_0x15d450._0x5554ce,_0x22ec4a-0x16);}const _0x275779=_0x18b501[_0x522d40(_0x22b108._0x5efe42,0xa,0x17,_0x22b108._0x4ad4c9)](_0x1092bc['name']),_0x5ad385=_0x275779?.[_0x5e4716(_0x22b108._0x1fd7e7,0x455,0x417,0x49b)]?.[_0x5e4716(_0x22b108._0xe48dc,0x4fb,_0x22b108._0x47a84c,_0x22b108._0x52cefe)]();function _0x5e4716(_0x25f0db,_0x3b0d84,_0x5cd91b,_0x1eca44){return _0x1f4b8d(_0x5cd91b,_0x3b0d84-_0xd9c3c1._0x2253fe,_0x25f0db-0x688,_0x1eca44-0xd1);}try{return await executeCapturedToolCall(_0x275779,_0x1092bc,_0x4ce293,_0x1f521b,_0x3f0c12);}finally{_0x5ad385?.();}}function createInternalToolRuntime(_0x3bee40=[],_0x252612={}){const _0x4dce89={_0x54c4bc:0x1ba,_0x598fa4:0x1e3},_0x2743bc={_0x7fb564:0x224,_0x27db5c:0x2cb,_0x5eb218:0x2f4,_0x397261:0x2b6,_0xe1eb5e:0x288},_0x5b75af={_0x48822c:0x342},_0x4b38be={_0x4d5662:0x3ac},_0x25c3af={_0x514d1f:0x1ef,_0x39b2e5:0x260},_0x1f850f={_0x387444:0x33f};let _0x852ad2=new ToolRegistry(_0x3bee40);return{'listToolSchemas'(){function _0x52c08b(_0x3b5d69,_0x531611,_0x46691b,_0x4d8e63){return _0x17cd(_0x46691b- -_0x1f850f._0x387444,_0x4d8e63);}return _0x852ad2[_0x52c08b(-_0x25c3af._0x514d1f,-0x1df,-0x22b,-_0x25c3af._0x39b2e5)]();},'setTools'(_0x345bbb){_0x852ad2=new ToolRegistry(_0x345bbb);},async 'executeCalls'(_0x15dcb7,_0x5bfb6c){const _0x309757={_0x517912:0x4f,_0x306d40:0x4e};function _0x6e87c7(_0x311623,_0x8e316,_0x2fd3fc,_0x1c79e0){return _0x17cd(_0x1c79e0- -_0x4b38be._0x4d5662,_0x8e316);}function _0x5d386b(_0x1c49d1,_0x319a91,_0xc7fdd5,_0x990d8c){return _0x17cd(_0xc7fdd5- -_0x5b75af._0x48822c,_0x319a91);}return await Promise[_0x6e87c7(-_0x2743bc._0x7fb564,-_0x2743bc._0x27db5c,-0x20c,-0x276)](_0x15dcb7[_0x6e87c7(-_0x2743bc._0x5eb218,-_0x2743bc._0x397261,-0x2b4,-_0x2743bc._0xe1eb5e)](async _0x737171=>{const _0x3bbc97={_0x29d16b:0x137,_0x2448d6:0x43,_0xfa719a:0x2bf};function _0xf7a147(_0x396aff,_0x496c42,_0x3a8df1,_0x8f8334){return _0x6e87c7(_0x396aff-_0x3bbc97._0x29d16b,_0x3a8df1,_0x3a8df1-_0x3bbc97._0x2448d6,_0x396aff-_0x3bbc97._0xfa719a);}return await executeToolCall(_0x852ad2,_0x737171,_0x5bfb6c,_0x252612[_0xf7a147(_0x309757._0x517912,0x58,_0x309757._0x306d40,0x63)],_0x252612['onEvent']);}));},async 'execute'(_0x25ee07,_0x3818b1){function _0x25bf39(_0x46cf96,_0x589d48,_0x386ef1,_0x5edc70){return _0x17cd(_0x5edc70- -0x31c,_0x46cf96);}const [_0xafe077]=await this[_0x25bf39(-0x1b2,-0x223,-_0x4dce89._0x54c4bc,-_0x4dce89._0x598fa4)]([_0x25ee07],_0x3818b1);return _0xafe077;}};}function getOrderedObserverExtensions(_0x18642a,_0x5443e2){const _0x10534e={_0x5c8d64:0xb3,_0x2978cd:0x79,_0x5f48fb:0x10a,_0x276f0b:0xe3},_0x559b30={_0x4eaaa1:0x28c,_0x2f4f79:0x21b,_0x3bf686:0x21e,_0x449353:0x27b,_0x5dc971:0x1f0,_0x48248c:0x343,_0x28c341:0x362,_0x18c7b4:0x2f6,_0x1469e0:0x2db,_0xcae5e3:0x339,_0x4601aa:0x33d,_0x2f0b6e:0x34e,_0x36898f:0x291},_0x51a38e={_0x5d2337:0x3cf,_0x2c1b5f:0x40d,_0x290e22:0x3b3,_0x7ad87f:0xed,_0x39e175:0x131,_0x21a32a:0xc8},_0x1eafd2={_0x1ee9bc:0x6,_0x576863:0x276};function _0x3f9382(_0x503b81,_0x41e72c,_0x11e6e6,_0x5c5f21){return _0x3b29bd(_0x503b81-_0x1eafd2._0x1ee9bc,_0x503b81,_0x11e6e6-0x198,_0x5c5f21- -_0x1eafd2._0x576863);}return _0x18642a['filter'](_0x2d2968=>{const _0x777086={_0x493d32:0x2df};function _0x18eb50(_0x24ee01,_0x4a152e,_0x5b6145,_0x1f10eb){return _0x17cd(_0x24ee01- -0x191,_0x5b6145);}function _0x673633(_0x86fe75,_0x208c1d,_0x4ac040,_0x1999dd){return _0x17cd(_0x86fe75-_0x777086._0x493d32,_0x208c1d);}return _0x2d2968[_0x673633(_0x51a38e._0x5d2337,_0x51a38e._0x2c1b5f,_0x51a38e._0x290e22,0x407)]!==![]&&_0x2d2968['stage']===_0x5443e2&&_0x2d2968[_0x18eb50(-_0x51a38e._0x7ad87f,-0xd0,-0xa1,-_0x51a38e._0x39e175)]===_0x18eb50(-0x71,-_0x51a38e._0x21a32a,-0xdd,-0x60);})[_0x3f9382(_0x10534e._0x5c8d64,_0x10534e._0x2978cd,_0x10534e._0x5f48fb,_0x10534e._0x276f0b)]((_0xfee2ff,_0x55263a)=>{const _0x4a1fd3={_0x45e764:0x1c7,_0x1da920:0x34d},_0x59d1f3={_0x175e7a:0x7a,_0x2e102f:0x1e5,_0x5c2919:0x263};function _0x2c3158(_0x4ef736,_0xc5f555,_0x4344c3,_0x41d969){return _0x3f9382(_0x4ef736,_0xc5f555-_0x59d1f3._0x175e7a,_0x4344c3-_0x59d1f3._0x2e102f,_0x4344c3-_0x59d1f3._0x5c2919);}function _0xd7dab9(_0x280de8,_0x3bcf75,_0x3dbda4,_0x50ad36){return _0x3f9382(_0x3bcf75,_0x3bcf75-0x162,_0x3dbda4-_0x4a1fd3._0x45e764,_0x280de8- -_0x4a1fd3._0x1da920);}if(_0xfee2ff[_0xd7dab9(-0x24e,-_0x559b30._0x4eaaa1,-_0x559b30._0x2f4f79,-_0x559b30._0x3bf686)]===!![]&&_0x55263a[_0xd7dab9(-0x24e,-0x214,-0x297,-_0x559b30._0x449353)]!==!![])return 0x1;if(_0xfee2ff[_0xd7dab9(-0x24e,-_0x559b30._0x5dc971,-0x25d,-0x2b2)]!==!![]&&_0x55263a[_0x2c3158(0x31b,_0x559b30._0x48248c,_0x559b30._0x28c341,_0x559b30._0x18c7b4)]===!![])return-0x1;return _0xfee2ff[_0x2c3158(_0x559b30._0x1469e0,_0x559b30._0xcae5e3,0x2e6,_0x559b30._0x4601aa)]-_0x55263a[_0x2c3158(_0x559b30._0x2f0b6e,0x2f3,0x2e6,_0x559b30._0x36898f)];});}function getOrderedTransformerExtensions(_0x135ce0,_0x382f70){const _0x569a49={_0x48fbdf:0x462,_0x5f0e5a:0x4bf,_0x5ac365:0x4a6},_0x26361e={_0x436c86:0x34a,_0x35791a:0x3a4,_0x286f81:0x349,_0x1ef11b:0x2fc,_0x27dd05:0x2fe,_0x3ebcbe:0x266,_0x2390ee:0x295,_0x5e60ad:0x2f4,_0x3816f5:0x257},_0x4706b3={_0x5c5004:0x12f,_0x1f55d7:0x650},_0x51a231={_0x121ba4:0x1c2,_0x74824:0x5bd};function _0x5c48d4(_0x43c83d,_0x542247,_0x44ad9d,_0x43f86f){return _0x3b29bd(_0x43c83d-0x6d,_0x43c83d,_0x44ad9d-_0x51a231._0x121ba4,_0x43f86f- -_0x51a231._0x74824);}function _0x11fc5c(_0x31da38,_0x5aac48,_0x109897,_0x1c51c8){return _0x1f4b8d(_0x5aac48,_0x5aac48-_0x4706b3._0x5c5004,_0x1c51c8-_0x4706b3._0x1f55d7,_0x1c51c8-0x16b);}return _0x135ce0[_0x5c48d4(-0x312,-0x288,-0x272,-0x2c9)](_0x330ef4=>{const _0x59b23a={_0x31dc06:0x100,_0x1a4044:0x57},_0x48bd3a={_0x475baa:0x5df};function _0x518565(_0xf1002,_0x205d76,_0x261c46,_0x43698b){return _0x5c48d4(_0xf1002,_0x205d76-0x10b,_0x261c46-0xb0,_0x205d76-_0x48bd3a._0x475baa);}function _0x274d30(_0x4588a7,_0x3e0419,_0x4b83d9,_0x4a7cad){return _0x5c48d4(_0x4588a7,_0x3e0419-_0x59b23a._0x31dc06,_0x4b83d9-0x5e,_0x3e0419- -_0x59b23a._0x1a4044);}return _0x330ef4[_0x518565(0x383,_0x26361e._0x436c86,_0x26361e._0x35791a,0x310)]!==![]&&_0x330ef4[_0x274d30(-0x31e,-_0x26361e._0x286f81,-_0x26361e._0x1ef11b,-0x383)]===_0x382f70&&_0x330ef4[_0x518565(0x2ae,_0x26361e._0x27dd05,0x33b,0x2bc)]===_0x274d30(-_0x26361e._0x3ebcbe,-_0x26361e._0x2390ee,-_0x26361e._0x5e60ad,-_0x26361e._0x3816f5);})[_0x11fc5c(_0x569a49._0x48fbdf,0x4e0,_0x569a49._0x5f0e5a,_0x569a49._0x5ac365)]((_0x209b2d,_0x1451f8)=>_0x209b2d[_0x5c48d4(-0x26d,-0x2b8,-0x28a,-0x2c4)]-_0x1451f8[_0x11fc5c(0x3de,0x3dd,0x4a5,0x446)]);}function createExtensionRegistry(){const _0x33184a={_0x2ab248:0x2ca,_0x4b9995:0x30e},_0x134aa5={_0x39ead0:0x401},_0x4463ce={_0x34ff25:0x30c},_0x1083f5={_0x54c13b:0x1d2,_0x203cef:0x209,_0x34c202:0x22d,_0x5b0a6b:0xb0,_0x35cd88:0x110,_0x261ed9:0x93,_0x30d215:0xef,_0x29a538:0x299,_0x2e19cf:0x2a8,_0x22f8f7:0x173,_0x48ef9f:0x2ce,_0x141173:0x2b4,_0x584565:0x260,_0x44d2d2:0x2d5,_0x330c78:0x2c4,_0x2038be:0x2dc,_0x3e8181:0x32b,_0x2d551b:0x2e8},_0x52b1bf=[];return{'register'(_0x5e97dc){function _0x361f51(_0x4994dd,_0x4d91c5,_0x34a32b,_0x2bb4be){return _0x17cd(_0x4994dd- -0x1d0,_0x4d91c5);}if(_0x5e97dc[_0x42d5ae(0x234,_0x1083f5._0x54c13b,_0x1083f5._0x203cef,_0x1083f5._0x34c202)]===_0x361f51(-_0x1083f5._0x5b0a6b,-_0x1083f5._0x35cd88,-0x45,-0xce)&&_0x5e97dc['enabled']!==![]&&_0x5e97dc[_0x361f51(-_0x1083f5._0x261ed9,-0x71,-0xb6,-_0x1083f5._0x30d215)]===!![]){const _0x25fd70=_0x52b1bf['find'](_0x227843=>_0x227843[_0x42d5ae(0x28c,0x23c,0x278,0x22d)]===_0x361f51(-0xb0,-0xab,-0x69,-0x6e)&&_0x227843['enabled']!==![]&&_0x227843[_0x42d5ae(0x26f,0x269,0x229,0x21c)]===_0x5e97dc['stage']&&_0x227843[_0x42d5ae(0x25f,0x304,0x270,0x2c6)]===!![]);if(_0x25fd70)throw new Error('Cannot\x20register\x20terminal\x20observer\x20\x22'+_0x5e97dc['id']+_0x42d5ae(0x28e,_0x1083f5._0x29a538,0x28f,_0x1083f5._0x2e19cf)+_0x5e97dc[_0x361f51(-0x13d,-_0x1083f5._0x22f8f7,-0x164,-0xeb)]+_0x42d5ae(_0x1083f5._0x48ef9f,_0x1083f5._0x141173,_0x1083f5._0x584565,0x291)+_0x25fd70['id']+_0x42d5ae(_0x1083f5._0x44d2d2,0x317,_0x1083f5._0x330c78,0x2ce));}function _0x42d5ae(_0x321f72,_0x407b15,_0x2604bc,_0x22a476){return _0x17cd(_0x22a476-0x189,_0x321f72);}_0x52b1bf[_0x42d5ae(0x2c7,_0x1083f5._0x2038be,_0x1083f5._0x3e8181,_0x1083f5._0x2d551b)]({..._0x5e97dc});},async 'runTransformers'(_0x28a926,_0x4374fd,_0x56742c){function _0x1a381b(_0x4e21c3,_0x4490e2,_0x282aa1,_0x4ae293){return _0x17cd(_0x4490e2-_0x4463ce._0x34ff25,_0x282aa1);}let _0x2b592e=_0x4374fd;for(const _0x55bcf4 of getOrderedTransformerExtensions(_0x52b1bf,_0x28a926)){_0x2b592e=await _0x55bcf4[_0x1a381b(0x3bf,0x3d6,_0x134aa5._0x39ead0,0x42b)](_0x2b592e,_0x56742c);}return _0x2b592e;},async 'runObservers'(_0x1db3b0,_0x2a5b04,_0x15ddc4){const _0x5c82ef={_0x12e99b:0x227};function _0x4ffd8c(_0x52e0a6,_0x2685e8,_0x5571df,_0xc2d2f1){return _0x17cd(_0xc2d2f1-_0x5c82ef._0x12e99b,_0x5571df);}for(const _0x455a5f of getOrderedObserverExtensions(_0x52b1bf,_0x1db3b0)){await _0x455a5f[_0x4ffd8c(0x2dd,_0x33184a._0x2ab248,_0x33184a._0x4b9995,0x2f1)](_0x2a5b04,_0x15ddc4);}}};}function createEmptySnapshot(){return{'totalTokens':0x0,'totalInputTokens':0x0,'totalOutputTokens':0x0,'totalReasoningTokens':0x0,'requestCount':0x0,'modelCallCount':0x0,'toolCallCount':0x0,'totalModelTimeMs':0x0,'currentTokens':0x0,'currentInputTokens':0x0,'currentOutputTokens':0x0,'currentReasoningTokens':0x0,'currentModelTimeMs':0x0,'totalCostUsdTicks':0x0,'totalReportedCostUsdTicks':0x0,'totalEstimatedCostUsdTicks':0x0,'reportedCostCallCount':0x0,'estimatedCostCallCount':0x0,'unpricedModelCallCount':0x0,'historicalMetricsComplete':!![],'missingHistoricalModelCallCount':0x0};}function applyModelCall(_0x4e0d1a,_0x48001a){const _0xb98bea={_0x35049f:0x234,_0x1860cb:0x1ef,_0x3ba96e:0xa3,_0xba0aa5:0xf8,_0x1b7547:0x1c6,_0x4895ad:0x178,_0x4824b1:0x170,_0x5ca3ca:0x17b,_0x582b2d:0x144,_0x4718af:0xfa,_0xa38cd:0xbc,_0x2d728a:0xf0,_0x5e3335:0xae,_0x19aba4:0x1f7,_0x1df6a9:0x266,_0x4d37a8:0x1f2,_0x4dcbdf:0x1be,_0x56e042:0x1fe,_0x2c0ae7:0x124,_0x1e91dc:0x1f9,_0xce2b60:0x25f,_0x150f07:0x152,_0x5f253b:0x129,_0xaaaed5:0x170,_0x5a31ce:0x17e,_0x605149:0x1c9,_0xeaca78:0x1f3,_0x45a9f6:0x224,_0x33e8df:0x165,_0x3c393d:0x1a8,_0x3ede0f:0x204,_0x365e50:0x1d4,_0x22083b:0xd9,_0x24f70d:0x105,_0xf4dacd:0x175,_0x39ad1a:0x1af,_0x40c7e8:0x1e4,_0x58579f:0xa2,_0x58e504:0xf5,_0x113827:0xe2,_0x344534:0xec,_0x4b6b04:0xe3,_0x3509e9:0x147,_0x1e21ad:0x14f,_0x46d065:0x208,_0x57c76f:0x13b},_0x4d7236={_0x22bd66:0xa6},_0x3efcc9={_0x13b81e:0x2,_0x294446:0x103},_0x2d6873=_0x48001a['usage'],_0x21624c=_0x2d6873[_0x356729(-_0xb98bea._0x35049f,-0x1d8,-0x1ef,-0x18d)],_0x34b3ea=_0x2d6873[_0x356729(-_0xb98bea._0x1860cb,-0x22f,-0x1cf,-0x28a)],_0x90043a=_0x2d6873[_0x217dd4(-0x11d,-_0xb98bea._0x3ba96e,-_0xb98bea._0xba0aa5,-0xf5)]??0x0,_0x35a46a=_0x21624c+_0x34b3ea,_0x2c7dd0=_0x2d6873[_0x217dd4(-0x122,-0x1e2,-0x17d,-_0xb98bea._0x1b7547)]?.[_0x217dd4(-0x135,-_0xb98bea._0x4895ad,-_0xb98bea._0x4824b1,-0x1b4)],_0x429ac9=_0x2d6873[_0x217dd4(-0x149,-0x143,-0xdf,-0x140)]?.['amountUsdTicks'],_0x21c44e=_0x2c7dd0??_0x429ac9;function _0x356729(_0x2425d9,_0xf8599,_0x5e8ac0,_0x4b4c01){return _0x1f4b8d(_0x4b4c01,_0xf8599-0x11,_0xf8599-_0x3efcc9._0x13b81e,_0x4b4c01-_0x3efcc9._0x294446);}function _0x217dd4(_0x2ef588,_0x2f7ea7,_0x1f1658,_0x5cf1fb){return _0x1f4b8d(_0x5cf1fb,_0x2f7ea7-0x16,_0x1f1658-_0x4d7236._0x22bd66,_0x5cf1fb-0x185);}const {currentReportedCostUsdTicks:_0xcdab40,currentEstimatedCostUsdTicks:_0x7acd30,..._0x2911ec}=_0x4e0d1a;return{..._0x2911ec,'totalTokens':_0x2911ec[_0x217dd4(-_0xb98bea._0x5ca3ca,-0x1e4,-0x17e,-_0xb98bea._0x582b2d)]+_0x35a46a,'totalInputTokens':_0x2911ec[_0x217dd4(-_0xb98bea._0x4718af,-_0xb98bea._0xa38cd,-_0xb98bea._0x2d728a,-_0xb98bea._0x5e3335)]+_0x21624c,'totalOutputTokens':_0x2911ec[_0x356729(-0x241,-_0xb98bea._0x19aba4,-_0xb98bea._0x1df6a9,-0x221)]+_0x34b3ea,'totalReasoningTokens':_0x2911ec[_0x356729(-0x1ee,-_0xb98bea._0x4d37a8,-_0xb98bea._0x4dcbdf,-_0xb98bea._0x56e042)]+_0x90043a,'modelCallCount':_0x2911ec[_0x217dd4(-0x11a,-0x1b6,-0x17f,-_0xb98bea._0x2c0ae7)]+0x1,'totalModelTimeMs':_0x2911ec[_0x356729(-0x228,-_0xb98bea._0x1e91dc,-0x18b,-_0xb98bea._0xce2b60)]+_0x48001a[_0x356729(-_0xb98bea._0x150f07,-0x170,-0x194,-_0xb98bea._0x5f253b)],'currentTokens':_0x35a46a,'currentInputTokens':_0x21624c,'currentOutputTokens':_0x34b3ea,'currentReasoningTokens':_0x90043a,'currentModelTimeMs':_0x48001a[_0x356729(-0x1cb,-_0xb98bea._0xaaaed5,-0x158,-_0xb98bea._0x5a31ce)],..._0x2911ec[_0x356729(-_0xb98bea._0x605149,-0x224,-0x1c9,-_0xb98bea._0xeaca78)]&&_0x35a46a>0x0?{'contextWindowUsage':_0x35a46a/_0x2911ec[_0x356729(-0x219,-_0xb98bea._0x45a9f6,-0x20b,-0x22d)]}:{},'totalCostUsdTicks':_0x21c44e===void 0x0?_0x2911ec[_0x356729(-0x1ab,-0x1d4,-_0xb98bea._0x33e8df,-_0xb98bea._0x3c393d)]:_0x2911ec[_0x356729(-_0xb98bea._0x3ede0f,-_0xb98bea._0x365e50,-0x1a3,-0x1b3)]+_0x21c44e,'totalReportedCostUsdTicks':_0x2c7dd0===void 0x0?_0x2911ec[_0x217dd4(-0x125,-_0xb98bea._0x22083b,-0x10b,-_0xb98bea._0x24f70d)]:_0x2911ec[_0x356729(-_0xb98bea._0xf4dacd,-_0xb98bea._0x39ad1a,-0x18e,-_0xb98bea._0x40c7e8)]+_0x2c7dd0,'totalEstimatedCostUsdTicks':_0x429ac9===void 0x0?_0x2911ec[_0x217dd4(-_0xb98bea._0x58579f,-_0xb98bea._0x58e504,-0xe2,-0x101)]:_0x2911ec[_0x217dd4(-0xf5,-_0xb98bea._0x58e504,-_0xb98bea._0x113827,-_0xb98bea._0x344534)]+_0x429ac9,'reportedCostCallCount':_0x2c7dd0===void 0x0?_0x2911ec[_0x217dd4(-_0xb98bea._0x4b6b04,-0x1ae,-_0xb98bea._0x3509e9,-_0xb98bea._0x1e21ad)]:_0x2911ec[_0x356729(-0x1d5,-0x1eb,-_0xb98bea._0x46d065,-0x1e9)]+0x1,'estimatedCostCallCount':_0x429ac9===void 0x0?_0x2911ec[_0x217dd4(-0xf2,-0x119,-0xe5,-0xbe)]:_0x2911ec['estimatedCostCallCount']+0x1,'unpricedModelCallCount':_0x2c7dd0===void 0x0&&_0x429ac9===void 0x0?_0x2911ec['unpricedModelCallCount']+0x1:_0x2911ec[_0x217dd4(-0xcf,-0xd8,-_0xb98bea._0x57c76f,-0x181)],..._0x2c7dd0!==void 0x0?{'currentReportedCostUsdTicks':_0x2c7dd0}:{},..._0x429ac9!==void 0x0?{'currentEstimatedCostUsdTicks':_0x429ac9}:{}};}function createAgentMetrics(_0xd7c18f={}){const _0x49b40c={_0x1e147:0xde,_0x3bf7e5:0x5e,_0x3855dd:0x8b},_0x37ea7b={_0x5b97eb:0x45,_0x5930cb:0x2f,_0xed60b2:0x17,_0x145fc0:0x3a,_0x16c376:0xf,_0x2819dc:0x35e,_0x4f5eb8:0x3fa,_0x394348:0x397,_0x2cb3d2:0x3d,_0x3bbdad:0x4b,_0x1e66b7:0x22,_0x33f946:0xa3},_0x20bcf0={_0x3bb2f6:0x49f,_0x343333:0x46c,_0x2930fc:0x198,_0x2b4261:0x140,_0x5e729a:0x183,_0xaeb522:0x113,_0x2d604b:0x16d,_0x4e6069:0x460,_0x48bbfb:0x14d,_0x8bc0fe:0x3b0,_0x18524a:0x1d7,_0x9a036:0xe1,_0x51cf50:0x144,_0x32a02e:0x1b3,_0x53f7ba:0x11a,_0x55e1aa:0x1b1,_0x4a51c2:0xfc,_0x2526c6:0x1d8,_0x4191aa:0x19f,_0xbeab56:0x42e,_0xcb973d:0x3f9,_0x1a3b0b:0x430,_0x52fa52:0x1a5,_0x4b0e6b:0x155,_0x1edd9a:0x16e,_0x31d480:0x1fa,_0xb9c1ae:0x215};let _0x141157=createEmptySnapshot();const _0x1560b7=new Set();let _0x4baa8d;const _0xe4c25d=()=>{const _0x3a69c2={..._0x141157};for(const _0x3ddb46 of _0x1560b7)_0x3ddb46(_0x3a69c2);};return{'getSnapshot'(){return{..._0x141157};},'recordEvent'(_0x354fb4){const _0x9a384b={_0x36d356:0x2ee};if(_0x354fb4['type']===_0x5d9cc0(_0x20bcf0._0x3bb2f6,0x43a,0x4a9,_0x20bcf0._0x343333)){_0x4baa8d=Date[_0x1632f6(-0x190,-_0x20bcf0._0x2930fc,-_0x20bcf0._0x2b4261,-_0x20bcf0._0x5e729a)]();const _0x3044d5=_0xd7c18f[_0x1632f6(-_0x20bcf0._0xaeb522,-0x146,-_0x20bcf0._0x2d604b,-0x11a)]?.(_0x354fb4[_0x1632f6(-0x21b,-0x20a,-0x1b3,-0x1a3)]);_0x3044d5!==void 0x0&&(_0x141157={..._0x141157,'contextWindowLimit':_0x3044d5},_0xe4c25d());return;}function _0x5d9cc0(_0x2d24cc,_0x2dcf92,_0xc77594,_0xb46657){return _0x17cd(_0x2dcf92-_0x9a384b._0x36d356,_0xb46657);}if(_0x354fb4['type']===_0x5d9cc0(0x458,0x44c,0x3f1,_0x20bcf0._0x4e6069)){const _0x27b3b4=_0x4baa8d===void 0x0?0x0:Date[_0x1632f6(-0x16e,-0x14c,-_0x20bcf0._0x2b4261,-_0x20bcf0._0x48bbfb)]()-_0x4baa8d;_0x4baa8d=void 0x0,_0x141157=applyModelCall(_0x141157,{'usage':_0x354fb4[_0x5d9cc0(_0x20bcf0._0x8bc0fe,0x401,0x457,0x395)][_0x1632f6(-0x197,-0x1e4,-_0x20bcf0._0x18524a,-0x1c0)],'modelTimeMs':_0x354fb4[_0x1632f6(-_0x20bcf0._0x9a036,-0x160,-0x13d,-0x13b)]??_0x27b3b4}),_0xe4c25d();return;}if(_0x354fb4[_0x1632f6(-0x1f8,-_0x20bcf0._0x51cf50,-0x18b,-_0x20bcf0._0x32a02e)]===_0x1632f6(-_0x20bcf0._0x53f7ba,-_0x20bcf0._0x55e1aa,-0x166,-_0x20bcf0._0x4a51c2)){_0x141157={..._0x141157,'toolCallCount':_0x141157[_0x1632f6(-0x1cf,-_0x20bcf0._0x2526c6,-_0x20bcf0._0x4191aa,-0x1be)]+0x1},_0xe4c25d();return;}function _0x1632f6(_0x38458a,_0x213540,_0x3cd26e,_0x2dcdc1){return _0x17cd(_0x3cd26e- -0x296,_0x2dcdc1);}_0x354fb4[_0x5d9cc0(_0x20bcf0._0xbeab56,_0x20bcf0._0xcb973d,_0x20bcf0._0x1a3b0b,_0x20bcf0._0x4e6069)]===_0x1632f6(-0x1af,-_0x20bcf0._0x52fa52,-_0x20bcf0._0x4b0e6b,-_0x20bcf0._0x1edd9a)&&(_0x141157={..._0x141157,'requestCount':_0x141157[_0x1632f6(-0x24b,-0x1c9,-_0x20bcf0._0x31d480,-_0x20bcf0._0xb9c1ae)]+0x1},_0xe4c25d());},'reset'(){_0x141157=createEmptySnapshot(),_0x4baa8d=void 0x0,_0xe4c25d();},'restore'(_0x56841a){let _0x7546fb=createEmptySnapshot();for(const _0x1f66dd of _0x56841a[_0xc57af8(-0x1,0xe,_0x37ea7b._0x5b97eb,_0x37ea7b._0x5930cb)]){_0x7546fb=applyModelCall(_0x7546fb,{'usage':_0x1f66dd[_0xc988ea(0x40b,0x3c1,0x3cd,0x3d5)],'modelTimeMs':_0x1f66dd[_0xc57af8(0xb,_0x37ea7b._0xed60b2,-_0x37ea7b._0x145fc0,-_0x37ea7b._0x16c376)]});}function _0xc57af8(_0x1b80ed,_0x3e7aac,_0x4c48e4,_0x1c99df){return _0x17cd(_0x3e7aac- -0x142,_0x1b80ed);}_0x141157={..._0x7546fb,'requestCount':_0x56841a['modelCalls'][_0xc988ea(_0x37ea7b._0x2819dc,0x3be,_0x37ea7b._0x4f5eb8,_0x37ea7b._0x394348)](_0x57c88b=>_0x57c88b[_0xc57af8(0x83,0x20,0xd,0x76)])[_0xc57af8(-0xc9,-0x7e,-_0x37ea7b._0x2cb3d2,-0x44)],'toolCallCount':_0x56841a[_0xc57af8(0xb,-_0x37ea7b._0x3bbdad,_0x37ea7b._0x1e66b7,-_0x37ea7b._0x33f946)],'historicalMetricsComplete':_0x56841a['missingModelCallCount']===0x0,'missingHistoricalModelCallCount':_0x56841a['missingModelCallCount']};function _0xc988ea(_0x48fffd,_0x3b15dc,_0xb486e,_0x4429f1){return _0x17cd(_0x3b15dc-0x302,_0xb486e);}_0x4baa8d=void 0x0,_0xe4c25d();},'subscribe'(_0x273084){const _0x1409da={_0x256839:0xc2};function _0x2e56c8(_0x2f11d5,_0x1597d1,_0x426b8a,_0x34fa7f){return _0x17cd(_0x426b8a- -_0x1409da._0x256839,_0x34fa7f);}return _0x1560b7[_0x2e56c8(_0x49b40c._0x1e147,_0x49b40c._0x3bf7e5,_0x49b40c._0x3855dd,0xc4)](_0x273084),()=>{_0x1560b7['delete'](_0x273084);};}};}function makeExtensionContext(_0x3a6bd0){return{'state':_0x3a6bd0};}async function runStage(_0x263b30,_0x26b630,_0x170b73,_0x28107f){const _0x3c5d5d={_0x160d93:0x58},_0x152938={_0x144f19:0x116,_0x454cbd:0x181},_0xde65b2=await _0x263b30['runTransformers'](_0x26b630,_0x170b73,_0x28107f);await _0x263b30[_0x5066f9(-0xd,0x14,-0x39,-_0x3c5d5d._0x160d93)](_0x26b630,_0xde65b2,_0x28107f);function _0x5066f9(_0x18c78d,_0x4a1993,_0x98683b,_0x15e69b){return _0x1f4b8d(_0x4a1993,_0x4a1993-_0x152938._0x144f19,_0x98683b-0x16f,_0x15e69b-_0x152938._0x454cbd);}return _0xde65b2;}async function emitEvent2(_0x1738d4,_0x39a306,_0x246843){await _0x1738d4?.(_0x39a306,_0x246843);}function replaceToolUseBlocks(_0x5d2dd7,_0x42d51a){const _0x5bffbe={_0x251ef6:0x142,_0x4668f9:0x146,_0x22ad2c:0x9c,_0x4d3288:0xb3},_0xb92f74={_0x159f36:0x3e2},_0x4cb1a4={_0x2b6b3e:0xd3,_0x4e478f:0xd9},_0x311c86={_0x38ece1:0x15a,_0x408093:0x1d7,_0x131554:0x3ce};function _0x4626d7(_0x5f4372,_0x1a3f86,_0x36c025,_0x1086d){return _0x3b29bd(_0x5f4372-_0x311c86._0x38ece1,_0x5f4372,_0x36c025-_0x311c86._0x408093,_0x1086d- -_0x311c86._0x131554);}function _0x1a7378(_0x52855b,_0x254865,_0x4bd34c,_0x52e4cf){return _0x1f4b8d(_0x52855b,_0x254865-_0x4cb1a4._0x2b6b3e,_0x254865-_0x4cb1a4._0x4e478f,_0x52e4cf-0x61);}let _0xbd22e9=0x0;return{..._0x5d2dd7,'content':_0x5d2dd7[_0x1a7378(-0x11f,-_0x5bffbe._0x251ef6,-0x177,-_0x5bffbe._0x4668f9)][_0x1a7378(-_0x5bffbe._0x22ad2c,-0xce,-_0x5bffbe._0x4d3288,-0xec)](_0xd92cfb=>{const _0x42630b={_0x1fef73:0x18f,_0x5bf1ce:0x136};function _0x4b366b(_0x3ea528,_0x712ff0,_0x3c07f7,_0x262b7a){return _0x4626d7(_0x3c07f7,_0x712ff0-_0x42630b._0x1fef73,_0x3c07f7-_0x42630b._0x5bf1ce,_0x262b7a-0x254);}if(_0xd92cfb[_0x4b366b(0x1b6,0x19e,0x1cb,0x1c9)]!==_0x553164(0x400,0x41b,0x3cd,_0xb92f74._0x159f36))return _0xd92cfb;const _0x23797e=_0x42d51a[_0xbd22e9];function _0x553164(_0x2cc594,_0x2b0359,_0x353c87,_0x330919){return _0x1a7378(_0x353c87,_0x2cc594-0x560,_0x353c87-0xa3,_0x330919-0x110);}return _0xbd22e9+=0x1,structuredClone(_0x23797e);})};}function createAssistantMessageId(_0xa8ed78,_0x100f9a){const _0x35ed9c={_0x3be80e:0x20e},_0x3969ff={_0x284713:0x3e,_0x29e03f:0x86};function _0x578050(_0x1f4367,_0x43bbe3,_0x300cee,_0x17a831){return _0x3b29bd(_0x1f4367-_0x3969ff._0x284713,_0x1f4367,_0x300cee-_0x3969ff._0x29e03f,_0x300cee- -0x532);}return _0xa8ed78+_0x578050(-0x1de,-0x1a9,-_0x35ed9c._0x3be80e,-0x26b)+_0x100f9a;}function createReasoningMessageId(_0x461b5b){const _0x39e589={_0x5766de:0x583},_0x54e894={_0x1dcafd:0x149,_0x1b3ef3:0x6aa};function _0xdf9d87(_0x18d00a,_0x3407a3,_0x33e761,_0x42eb56){return _0x1f4b8d(_0x18d00a,_0x3407a3-_0x54e894._0x1dcafd,_0x33e761-_0x54e894._0x1b3ef3,_0x42eb56-0xe4);}return _0x461b5b+_0xdf9d87(0x4ff,_0x39e589._0x5766de,0x517,0x52f);}function withMessageId(_0x497e36,_0x94c184){if(_0x497e36['id']===_0x94c184)return _0x497e36;return{..._0x497e36,'id':_0x94c184};}function createAssistantChunkEvent(_0xc5764f,_0x505259){const _0xbade93={_0x4abc18:0x36d,_0x3dcf08:0x381,_0x2a4f80:0x189,_0x4b3611:0x17a,_0x588b43:0x228,_0x1c42cb:0x1f4,_0x3a9e0b:0x131,_0x37905c:0x110,_0x4f95e4:0x1d5,_0x326903:0x1fb},_0x4ded05={_0x401d92:0x60},_0xbb6a8e={_0x56e342:0x541};if(_0xc5764f[_0x187c36(0x365,0x32d,_0xbade93._0x4abc18,_0xbade93._0x3dcf08)]!=='content_delta')return void 0x0;function _0x187c36(_0x3f1275,_0x44fa20,_0x2dd10d,_0xbf0df9){return _0x1f4b8d(_0x3f1275,_0x44fa20-0xb7,_0xbf0df9-_0xbb6a8e._0x56e342,_0xbf0df9-0x177);}function _0x392e5b(_0x49d69f,_0x268ec0,_0x498b2e,_0x1ac3e7){return _0x1f4b8d(_0x498b2e,_0x268ec0-0x11,_0x1ac3e7- -0x10,_0x1ac3e7-_0x4ded05._0x401d92);}if(_0xc5764f[_0x392e5b(-_0xbade93._0x2a4f80,-0x1f3,-_0xbade93._0x4b3611,-0x1e8)]===void 0x0)return void 0x0;return{'type':_0x392e5b(-0x1db,-0x1c0,-_0xbade93._0x588b43,-_0xbade93._0x1c42cb),'index':_0xc5764f[_0x392e5b(-_0xbade93._0x3a9e0b,-0x16d,-_0xbade93._0x37905c,-0x178)]??0x0,'messageId':_0x505259,'chunk':{'type':_0x392e5b(-0x1eb,-_0xbade93._0x4f95e4,-_0xbade93._0x326903,-0x1bf),'index':_0xc5764f['index']??0x0,'text':_0xc5764f[_0x187c36(0x302,0x33f,0x336,0x369)]}};}function createToolUseChunkEvent(_0x39a3f1,_0x28ddc6){const _0x4b9b06={_0x42c726:0x173,_0x2e954c:0x181,_0x28bee2:0x129,_0x5b8725:0x19c,_0x4aad86:0x202,_0x39ac36:0x1fb,_0x4b5b1b:0x19d,_0x2051ff:0x1c5,_0x36617d:0x2ab,_0x1512ea:0x300,_0x25d3ea:0x2a4,_0x4741db:0x3bd,_0x141c7f:0x381,_0x5a712c:0x348,_0x4f5188:0x1f0,_0x9eb8cc:0x21f,_0x5299a9:0x178,_0x29b9c8:0x16d,_0x329742:0x172,_0x459042:0x178,_0xe705ec:0x121},_0x15e527={_0x3e19cd:0xed},_0x2ac3e8={_0x4d758f:0x14c};function _0x524294(_0x4660c0,_0x306028,_0x210084,_0x2a74de){return _0x1f4b8d(_0x306028,_0x306028-0xcf,_0x4660c0-0x36a,_0x2a74de-_0x2ac3e8._0x4d758f);}function _0x6b13cd(_0x1f65f0,_0x43e22f,_0x285463,_0x5bec16){return _0x3b29bd(_0x1f65f0-0x67,_0x285463,_0x285463-_0x15e527._0x3e19cd,_0x43e22f- -0x1a);}if(_0x39a3f1[_0x524294(0x1aa,0x1f5,0x1ba,_0x4b9b06._0x42c726)]!==_0x524294(_0x4b9b06._0x2e954c,0x1a9,_0x4b9b06._0x28bee2,_0x4b9b06._0x5b8725))return void 0x0;return{'type':'tool_use_chunk','index':_0x39a3f1[_0x524294(_0x4b9b06._0x4aad86,_0x4b9b06._0x39ac36,_0x4b9b06._0x4b5b1b,_0x4b9b06._0x2051ff)]??0x0,'messageId':_0x28ddc6,'chunk':{'type':_0x6b13cd(_0x4b9b06._0x36617d,_0x4b9b06._0x1512ea,0x325,_0x4b9b06._0x25d3ea),'id':_0x39a3f1['id']??'','index':_0x39a3f1[_0x6b13cd(_0x4b9b06._0x4741db,_0x4b9b06._0x141c7f,0x313,_0x4b9b06._0x5a712c)]??0x0,..._0x39a3f1[_0x524294(_0x4b9b06._0x4f5188,0x1c6,0x221,_0x4b9b06._0x9eb8cc)]!==void 0x0?{'name':_0x39a3f1['name']}:{},..._0x39a3f1[_0x524294(_0x4b9b06._0x5299a9,0x154,_0x4b9b06._0x29b9c8,_0x4b9b06._0x329742)]!==void 0x0?{'inputDelta':_0x39a3f1[_0x524294(_0x4b9b06._0x459042,0x176,0x169,_0x4b9b06._0xe705ec)]}:{}}};}function _0x1f4b8d(_0x48f53e,_0x436b58,_0x44758b,_0x1132d4){const _0x5a0782={_0x4c1ed8:0x2cb};return _0x17cd(_0x44758b- -_0x5a0782._0x4c1ed8,_0x48f53e);}function createReasoningChunkEvent(_0x3ce9de,_0x283bf0){const _0x97569b={_0x7afe82:0x444,_0x3d4bc5:0x4e3,_0x282ee6:0x492,_0x1a6126:0x51e,_0x236817:0x4c5,_0xbbcfaa:0x4d3,_0x1dce0c:0x311,_0x51d05d:0x38d,_0x1b3ecc:0x327,_0xbfc2d1:0x4df,_0x3ec38d:0x4b3,_0x5f2e3e:0x458,_0x474ed3:0x44b,_0x14fb78:0x48c,_0x2f703c:0x47c,_0x2a5d03:0x4e7,_0x1eba5f:0x54f,_0x59355c:0x489,_0x3daa18:0x52b,_0x2e6e59:0x4f8,_0x524188:0x2cf,_0x2f39ef:0x33e,_0x1bc50b:0x4f3,_0x2b4107:0x487,_0x2713c8:0x2f8,_0x3a0104:0x29c,_0x2b00af:0x2bc,_0x43e9de:0x411,_0x1345f4:0x470,_0x10ee2d:0x45d,_0x83242b:0x4ca,_0x53722b:0x4a1,_0x170a60:0x42f,_0x3a82f0:0x418,_0x33590d:0x4d9},_0x1499b1={_0x1a03b7:0x10d},_0x580988={_0x46d87b:0xde,_0x1d9af9:0x42};function _0x6fb16b(_0x2c914d,_0x4e40c8,_0x59f64b,_0x1a19a4){return _0x3b29bd(_0x2c914d-_0x580988._0x46d87b,_0x2c914d,_0x59f64b-0xec,_0x1a19a4- -_0x580988._0x1d9af9);}function _0x26e9b8(_0x4ab79c,_0x5ef76d,_0x1bc36d,_0x59b197){return _0x3b29bd(_0x4ab79c-_0x1499b1._0x1a03b7,_0x4ab79c,_0x1bc36d-0xae,_0x5ef76d-0x14a);}switch(_0x3ce9de[_0x26e9b8(0x465,0x48d,_0x97569b._0x7afe82,0x48d)]){case _0x26e9b8(0x491,_0x97569b._0x3d4bc5,_0x97569b._0x282ee6,0x4a7):return{'type':'reasoning_chunk','index':_0x3ce9de['index'],'messageId':_0x283bf0,'chunk':{'type':_0x26e9b8(_0x97569b._0x1a6126,_0x97569b._0x3d4bc5,_0x97569b._0x236817,_0x97569b._0xbbcfaa),'index':_0x3ce9de['index']??0x0,'thinking':_0x3ce9de[_0x6fb16b(_0x97569b._0x1dce0c,_0x97569b._0x51d05d,0x36d,_0x97569b._0x1b3ecc)]??''},'text':_0x3ce9de[_0x26e9b8(_0x97569b._0xbfc2d1,_0x97569b._0x3ec38d,_0x97569b._0x5f2e3e,0x51e)]??''};case'openai_reasoning_delta':return{'type':_0x26e9b8(_0x97569b._0x474ed3,0x448,0x447,_0x97569b._0x14fb78),'index':_0x3ce9de[_0x26e9b8(_0x97569b._0x2f703c,_0x97569b._0x2a5d03,0x4b4,_0x97569b._0x1eba5f)],'messageId':_0x283bf0,'chunk':{'type':_0x26e9b8(0x4cd,_0x97569b._0x59355c,0x4be,0x4a2),'contentIndex':_0x3ce9de[_0x26e9b8(_0x97569b._0x3daa18,_0x97569b._0x2a5d03,_0x97569b._0x2e6e59,0x519)]??0x0,'delta':_0x3ce9de['delta']??'','itemId':_0x3ce9de[_0x6fb16b(0x398,0x35e,_0x97569b._0x524188,_0x97569b._0x2f39ef)]??'','outputIndex':_0x3ce9de['outputIndex']??0x0},'text':_0x3ce9de['delta']??''};case _0x26e9b8(_0x97569b._0x1bc50b,_0x97569b._0x2b4107,0x49f,0x4c2):return{'type':_0x6fb16b(_0x97569b._0x2713c8,_0x97569b._0x3a0104,0x263,_0x97569b._0x2b00af),'index':_0x3ce9de['summaryIndex'],'messageId':_0x283bf0,'chunk':{'type':'openai_reasoning_summary_delta','delta':_0x3ce9de[_0x26e9b8(_0x97569b._0x43e9de,_0x97569b._0x1345f4,0x44b,_0x97569b._0x10ee2d)]??'','itemId':_0x3ce9de[_0x26e9b8(0x505,_0x97569b._0x83242b,0x49f,_0x97569b._0x53722b)]??'','outputIndex':_0x3ce9de['outputIndex']??0x0,'summaryIndex':_0x3ce9de[_0x26e9b8(0x491,0x433,_0x97569b._0x170a60,_0x97569b._0x3a82f0)]??0x0},'text':_0x3ce9de[_0x26e9b8(0x4d4,0x470,0x495,_0x97569b._0x33590d)]??''};default:return void 0x0;}}function isAbortedToolResult(_0x24cac4){const _0x2f6d4a={_0x498e9a:0x107,_0x1b6607:0x12d,_0x4db4ae:0x2d2,_0x2633c0:0x319},_0x48b7c3={_0x5769c2:0x16,_0x1d934a:0x4a5},_0x543837={_0xdde800:0x162};function _0x3d7025(_0x482497,_0x11b7b0,_0x294166,_0xfb36f1){return _0x3b29bd(_0x482497-0xb5,_0x11b7b0,_0x294166-_0x543837._0xdde800,_0x294166- -0x1ca);}function _0x6b07ad(_0x43664d,_0x36dccb,_0x22630f,_0x5c694d){return _0x1f4b8d(_0x22630f,_0x36dccb-_0x48b7c3._0x5769c2,_0x5c694d-_0x48b7c3._0x1d934a,_0x5c694d-0x70);}return _0x24cac4['status']===_0x3d7025(0x176,0x9d,_0x2f6d4a._0x498e9a,_0x2f6d4a._0x1b6607)&&_0x24cac4['structured'][_0x6b07ad(0x308,0x2fe,_0x2f6d4a._0x4db4ae,_0x2f6d4a._0x2633c0)]===!![];}async function executeModelRequest(_0x28872a,_0x33d514,_0x3919d9,_0x48eb3c,_0x56e6d9,_0x3a9c88){const _0x709d40={_0x4179b0:0x3fd,_0x3cc6dc:0x430,_0x3270a4:0x3ea,_0x5b4f5f:0x3f4,_0xd280d9:0x3d2,_0x58f040:0x2ec,_0x412d04:0x2b7,_0x2c1cd9:0x2d1,_0x3ee97a:0x318,_0x2ad282:0x340,_0x6eac7a:0x370,_0x1222a5:0x396,_0x53680a:0x42f,_0x3b5a2c:0x36c,_0x2621d7:0x327,_0x3142a8:0x446,_0x360d5d:0x349,_0x4e8eff:0x313,_0x3fc181:0x37d,_0xc80ef6:0x318,_0x6b4396:0x32d,_0x479388:0x482,_0x4f1923:0x4bb,_0x224e90:0x4ee,_0x58e6cc:0x48b,_0x2936d1:0x45f,_0x50d27d:0x448,_0x5b85f8:0x377,_0x4e9f63:0x3bf,_0xd5f43b:0x2fb,_0x88f3e8:0x2c9,_0x4d2036:0x415,_0x43c26e:0x44b,_0x1fc642:0x3a3,_0x1a18fa:0x418,_0x3d382f:0x3d3,_0xb3b1fe:0x440,_0x3de4a5:0x3de,_0x5d8f65:0x417,_0x17095b:0x390,_0x58d63f:0x3bd,_0x26a5af:0x41d,_0x5c5420:0x470,_0xb7750a:0x376,_0x506c0b:0x426,_0x15e933:0x420,_0x125525:0x34f,_0x22e9e0:0x45d,_0x248ca5:0x464,_0x4d00a2:0x48b,_0x4d8a6b:0x469,_0x59cf77:0x423,_0x46b358:0x2ea,_0x341a02:0x304,_0x263f2e:0x38c,_0x12888b:0x43c,_0xcd9e6c:0x390,_0x5f3928:0x495,_0x48655a:0x425,_0x5f4acc:0x45a,_0x3d7f9b:0x4a1,_0x3ec957:0x3ab,_0x1fc351:0x3c9,_0x1b22d9:0x38a},_0x3d9f7b={_0x598071:0x600,_0xbe6dfb:0xfb},_0xcd00e2={_0x139248:0x7d};function _0x20b86b(_0x3d6ee8,_0x11b88c,_0x232ddb,_0x53381f){return _0x1f4b8d(_0x232ddb,_0x11b88c-0x13b,_0x53381f-0x536,_0x53381f-_0xcd00e2._0x139248);}throwIfAborted(_0x33d514[_0x20b86b(0x36b,0x35c,0x331,0x318)]);function _0x14e846(_0xac577c,_0x2dd28a,_0x53e979,_0x4a85c4){return _0x1f4b8d(_0x4a85c4,_0x2dd28a-0x14a,_0x2dd28a-_0x3d9f7b._0x598071,_0x4a85c4-_0x3d9f7b._0xbe6dfb);}if(!_0x33d514[_0x14e846(_0x709d40._0x4179b0,_0x709d40._0x3cc6dc,0x3dc,0x495)]||!_0x3919d9[_0x20b86b(_0x709d40._0x3270a4,_0x709d40._0x5b4f5f,0x3ac,_0x709d40._0xd280d9)])return await _0x3919d9['complete'](_0x28872a,{'signal':_0x33d514[_0x20b86b(0x315,0x2cd,_0x709d40._0x58f040,0x318)]});let _0x176fd5;for await(const _0x594bdd of _0x3919d9['stream'](_0x28872a,{'signal':_0x33d514['signal']})){throwIfAborted(_0x33d514[_0x20b86b(0x30e,_0x709d40._0x412d04,_0x709d40._0x2c1cd9,_0x709d40._0x3ee97a)]);if(_0x594bdd[_0x20b86b(_0x709d40._0x2ad282,0x387,0x340,0x376)]===_0x20b86b(_0x709d40._0x6eac7a,_0x709d40._0x1222a5,_0x709d40._0x53680a,0x3c3)){_0x3a9c88[_0x20b86b(_0x709d40._0x3b5a2c,0x383,_0x709d40._0x2621d7,0x32d)][_0x14e846(0x3dc,_0x709d40._0x3142a8,0x466,0x47e)]!==void 0x0&&_0x3a9c88['meta'][_0x20b86b(0x376,0x419,_0x709d40._0x360d5d,0x3af)]===void 0x0&&(_0x3a9c88[_0x20b86b(_0x709d40._0x4e8eff,_0x709d40._0x3fc181,_0x709d40._0xc80ef6,_0x709d40._0x6b4396)][_0x14e846(_0x709d40._0x479388,0x479,0x49d,_0x709d40._0x4f1923)]=Date[_0x14e846(_0x709d40._0x224e90,_0x709d40._0x58e6cc,_0x709d40._0x2936d1,0x4d6)]());_0x176fd5=_0x594bdd[_0x14e846(0x421,_0x709d40._0x50d27d,0x450,0x48e)];continue;}if(_0x594bdd['type']===_0x20b86b(0x329,_0x709d40._0x5b85f8,_0x709d40._0x4e9f63,0x395)){await emitEvent2(_0x48eb3c[_0x20b86b(0x30d,_0x709d40._0xd5f43b,_0x709d40._0x88f3e8,0x2ff)],{'type':_0x20b86b(0x35f,0x3af,_0x709d40._0x3270a4,0x395),'assistantMessageId':_0x3a9c88['assistantMessageId'],'reasoningMessageId':_0x3a9c88['reasoningMessageId']},_0x56e6d9),delete _0x3a9c88['meta'][_0x14e846(0x49a,_0x709d40._0x3142a8,_0x709d40._0x4d2036,_0x709d40._0x43c26e)],delete _0x3a9c88[_0x14e846(0x3c9,0x3f7,_0x709d40._0x1fc642,_0x709d40._0x1a18fa)]['reasoningCompletedAt'];continue;}if(_0x594bdd[_0x14e846(_0x709d40._0x3d382f,_0x709d40._0xb3b1fe,_0x709d40._0x3de4a5,_0x709d40._0x5d8f65)]===_0x20b86b(_0x709d40._0x17095b,0x351,0x406,_0x709d40._0x58d63f)){await emitEvent2(_0x48eb3c['onEvent'],{..._0x594bdd,'assistantMessageId':_0x3a9c88[_0x14e846(0x3b6,_0x709d40._0x26a5af,0x417,_0x709d40._0x5c5420)]},_0x56e6d9);continue;}const _0x222082=createReasoningChunkEvent(_0x594bdd,_0x3a9c88['reasoningMessageId']);if(_0x222082&&_0x222082[_0x20b86b(_0x709d40._0x3de4a5,0x389,0x390,_0x709d40._0xb7750a)]==='reasoning_chunk'&&_0x222082[_0x14e846(_0x709d40._0x506c0b,0x428,0x475,_0x709d40._0x15e933)]['length']>0x0){_0x3a9c88['meta'][_0x20b86b(0x30f,0x38f,_0x709d40._0x125525,0x37c)]===void 0x0&&(_0x3a9c88['meta'][_0x14e846(0x44c,0x446,0x434,_0x709d40._0x22e9e0)]=Date[_0x14e846(_0x709d40._0x248ca5,_0x709d40._0x4d00a2,_0x709d40._0x4d8a6b,0x4b8)]());await emitEvent2(_0x48eb3c[_0x14e846(0x40c,0x3c9,_0x709d40._0x59cf77,0x3d9)],_0x222082,_0x56e6d9);continue;}const _0xf5abf9=createAssistantChunkEvent(_0x594bdd,_0x3a9c88[_0x14e846(0x483,_0x709d40._0x26a5af,0x3e0,0x3c9)]);if(_0xf5abf9){_0x3a9c88['meta']['reasoningStartedAt']!==void 0x0&&_0x3a9c88[_0x20b86b(_0x709d40._0x46b358,_0x709d40._0x341a02,_0x709d40._0x263f2e,_0x709d40._0x6b4396)]['reasoningCompletedAt']===void 0x0&&(_0x3a9c88[_0x14e846(0x401,0x3f7,_0x709d40._0x12888b,_0x709d40._0xcd9e6c)][_0x14e846(_0x709d40._0x5f3928,0x479,_0x709d40._0x48655a,0x436)]=Date[_0x14e846(_0x709d40._0x5f4acc,0x48b,0x429,_0x709d40._0x3d7f9b)]());await emitEvent2(_0x48eb3c[_0x14e846(_0x709d40._0x3ec957,_0x709d40._0x1fc351,0x3b6,_0x709d40._0x1b22d9)],_0xf5abf9,_0x56e6d9);continue;}const _0x3fa806=createToolUseChunkEvent(_0x594bdd,_0x3a9c88[_0x14e846(0x3b5,_0x709d40._0x26a5af,0x3b4,0x3b7)]);_0x3fa806&&await emitEvent2(_0x48eb3c['onEvent'],_0x3fa806,_0x56e6d9);}if(!_0x176fd5)throw new Error('Model\x20stream\x20ended\x20without\x20a\x20final\x20response');return _0x176fd5;}function makeTurnGuards(_0x2aa882,_0x2a7b23,_0x305d79,_0x279b18,_0x2acb54){return{async 'stage'(_0x3581ef,_0x409c82){return throwIfAborted(_0x2aa882),await runStage(_0x2a7b23,_0x3581ef,_0x409c82,_0x279b18);},async 'emit'(_0x24e04c){throwIfAborted(_0x2aa882),await emitEvent2(_0x305d79,_0x24e04c,_0x2acb54);},async 'stageUnchecked'(_0x4ddcab,_0x1f6b5f){return await runStage(_0x2a7b23,_0x4ddcab,_0x1f6b5f,_0x279b18);},async 'emitUnchecked'(_0x57c26f){await emitEvent2(_0x305d79,_0x57c26f,_0x2acb54);}};}async function runTurn(_0xe8b94f,_0x21bb5c){const _0x2daf3a={_0x1b5061:0x24d,_0x2dbb23:0x262,_0x91cc5a:0x165,_0x8b9b4:0x24b,_0x110d94:0x1e8,_0x2489f7:0x21b,_0x328f70:0x100,_0x28e174:0xbf,_0x513e41:0x1ab,_0x3b25be:0x17e,_0x44cde1:0x125,_0x4c99cc:0x94,_0x448be7:0x83,_0x3f4f1a:0xb0,_0x5276d6:0x11e,_0x19a3a4:0x170,_0x1f9be0:0x30,_0x1c4b25:0xbf,_0x35f3dc:0x6f,_0x1d948c:0x18d,_0x530e40:0x13e,_0x38564e:0x121,_0x4ba8a1:0x124,_0x30e8e8:0x1d3,_0x1767da:0x17f,_0x4bc69c:0xf4,_0xe9b28a:0x57,_0x3151b2:0xb4,_0x5b8e6f:0x5e,_0x34e37a:0x1e6,_0x474f02:0x1ed,_0x2d63b4:0xb8,_0x39ac1d:0x200,_0x66dd15:0x1cd,_0x379e9a:0x69,_0x3f3166:0x79,_0x27b027:0x1d0,_0xa443d1:0x18e,_0x588a8b:0x15d,_0x43a709:0x10d,_0x112e6f:0xf9,_0x1e6e15:0x8f,_0x1935f9:0x9a,_0x46ef88:0x236,_0x196884:0x256,_0x54f593:0xc8,_0x15b3d6:0x22d,_0x3ec311:0x1da,_0x171369:0x1e4,_0x29eb70:0x1d7,_0x393daf:0x22a,_0x7ab80a:0xd6,_0x47f4e8:0x9d,_0x55b1db:0x8,_0x31d187:0x67,_0x4bcb04:0x157,_0x1d7250:0x19d,_0x1c15a8:0x1e8,_0x1fce84:0x1df,_0x432513:0x2a,_0x12222e:0x152,_0x321e38:0x19,_0x5b6a98:0x67,_0xee30f:0x98,_0x4a902d:0x218,_0x4713df:0x1a2,_0x52410f:0x163,_0x3b9806:0x1d4,_0x163858:0x1dd,_0xe32244:0x1a1,_0x1efaa9:0x1c9,_0x1b020e:0x23e,_0x469bbd:0xe7,_0x38d2e5:0x86,_0x2d6181:0x239,_0x1eaff8:0x198,_0x3da1b3:0x23e,_0x470c19:0x2ae,_0xf81f2f:0x261,_0x1d80d4:0x223,_0x2d3117:0x240,_0x3972ec:0x133,_0x3ffbfe:0xbf,_0x6e7f57:0x1cf,_0x33338d:0x15a,_0x29db51:0xde,_0x3394e2:0x193,_0x4f41cf:0x290,_0x538e10:0x249,_0x4390b0:0x1fb,_0x3bdea2:0x230,_0x110032:0x1e7,_0x8ca130:0x216,_0x5dbdd1:0xa3,_0x31025b:0x53,_0x335e02:0x92,_0x106e2e:0x234,_0x27e8cd:0x1ee,_0x470e0a:0x187,_0x13402d:0x122,_0x33d6da:0xef,_0x2cc129:0x90,_0x51b519:0x11a,_0x583e91:0x64,_0x14a997:0xec,_0x11dd4f:0x252,_0x51b7e9:0x1c5,_0x10171d:0x1b7,_0x976aaf:0x14c,_0x15ec0f:0x215,_0xa06a1a:0x21f,_0x7e64d4:0x186,_0x366b0f:0x16e,_0x1249bf:0x84,_0x25bf68:0xdd,_0x4bb6cf:0x1cf,_0x491675:0x1d1,_0x32d736:0x16b,_0x2c7e9d:0x177,_0x4b5da9:0xaa,_0x17e61f:0x118,_0x532f43:0x173,_0x2d235e:0x1bf,_0x2a51cb:0x1ef,_0x4fe13a:0x204,_0x6ad07d:0x168,_0x3808f1:0x8c,_0x19ca1b:0x1d5,_0x57db98:0x1db,_0x3d61bf:0x16f,_0x199c2f:0x171,_0xdc7e3d:0x6a,_0x437e09:0x17,_0x2d62df:0x6b,_0x4bfa57:0x18f,_0x3d8835:0x1e6,_0xdd9327:0x212,_0x216460:0x222,_0x54611b:0x8c,_0x1e842f:0x1b9,_0xbd3af3:0x17d,_0x443487:0x25,_0xe69c34:0x79},_0x36a010={_0x3bf2a5:0x3d9,_0x39b752:0x39b,_0x34e9d4:0x404,_0x1a851d:0x3d2,_0x7132ab:0x41a,_0x5c6cab:0x3cf,_0x79130:0x432,_0x4cc043:0x454,_0x1590db:0x1ce,_0x299f75:0x1db,_0x52661e:0x457},_0x3bd728={_0x364e96:0x16a,_0x5ee8b8:0x11e},_0x1a4f43={_0x5368dd:0xaa},_0x2a6381={_0x36b30d:0x45},_0x527982={_0x923534:0x1d7},_0x387d6b={_0x159436:0x1d},_0x7e75f7={_0x526d84:0x176,_0x15f198:0x1aa},_0xf933d4=_0x21bb5c[_0x41785e(-_0x2daf3a._0x1b5061,-0x260,-_0x2daf3a._0x2dbb23,-0x253)],_0x33505c=_0xe8b94f[_0x4689c5(-0x138,-0x163,-0x115,-_0x2daf3a._0x91cc5a)]??new AbortController()[_0x41785e(-0x222,-_0x2daf3a._0x8b9b4,-_0x2daf3a._0x110d94,-_0x2daf3a._0x2489f7)],_0x4e2551={'sessionId':_0xe8b94f[_0x4689c5(-_0x2daf3a._0x328f70,-_0x2daf3a._0x28e174,-0xb3,-0x7a)],'turnId':_0xe8b94f[_0x41785e(-_0x2daf3a._0x513e41,-0x1d3,-0x1a4,-0x1a5)],'system':normalizeSystem(_0xe8b94f[_0x4689c5(-0xdf,-_0x2daf3a._0x3b25be,-_0x2daf3a._0x44cde1,-0x145)]),'messages':(_0xe8b94f[_0x4689c5(-_0x2daf3a._0x4c99cc,-_0x2daf3a._0x448be7,-_0x2daf3a._0x3f4f1a,-_0x2daf3a._0x5276d6)]??[])[_0x41785e(-0x1e3,-0x1d4,-0x189,-_0x2daf3a._0x19a3a4)](normalizeMessage),'lastResponse':void 0x0,'toolResults':[],'finalMessage':void 0x0,'sessionDir':typeof _0x21bb5c[_0x4689c5(-_0x2daf3a._0x1f9be0,-_0x2daf3a._0x1c4b25,-_0x2daf3a._0x35f3dc,-0xae)]===_0x4689c5(-_0x2daf3a._0x1d948c,-_0x2daf3a._0x530e40,-_0x2daf3a._0x38564e,-_0x2daf3a._0x4ba8a1)?_0x21bb5c['sessionDir']():_0x21bb5c['sessionDir']};function _0x4689c5(_0x3ec162,_0x241122,_0x4683d9,_0x2b6e96){return _0x1f4b8d(_0x2b6e96,_0x241122-_0x7e75f7._0x526d84,_0x4683d9-0x109,_0x2b6e96-_0x7e75f7._0x15f198);}const _0x2497f0=makeExtensionContext(_0x4e2551),_0x475e34={'sessionId':_0x4e2551['sessionId'],'turnId':_0x4e2551[_0x41785e(-0x234,-_0x2daf3a._0x30e8e8,-_0x2daf3a._0x1767da,-0x213)],'state':_0x4e2551,'signal':_0x33505c,..._0x21bb5c['askUser']?{'askUser':_0x21bb5c[_0x4689c5(-0x113,-0xcc,-0xb6,-_0x2daf3a._0x4bc69c)]}:{},..._0x21bb5c['setTopic']?{'setTopic':_0x21bb5c['setTopic']}:{}},{stage:_0x1c9d67,emit:_0x1e984d,stageUnchecked:_0x4deb03,emitUnchecked:_0x5ab86d}=makeTurnGuards(_0x33505c,_0x21bb5c[_0x4689c5(-_0x2daf3a._0xe9b28a,-0x11a,-_0x2daf3a._0x3151b2,-_0x2daf3a._0x5b8e6f)],_0x21bb5c['onEvent'],_0x2497f0,_0x475e34);function _0x41785e(_0x9b7e2b,_0x51a961,_0x228028,_0x276fb8){return _0x1f4b8d(_0x276fb8,_0x51a961-0x53,_0x51a961- -0x2d,_0x276fb8-_0x387d6b._0x159436);}const _0x1fd085=async(_0x22dc77,_0x248f40)=>{function _0x24c33d(_0x1899ee,_0x1ed563,_0x2dfbca,_0x89349){return _0x4689c5(_0x1899ee-_0x527982._0x923534,_0x1ed563-0xb2,_0x2dfbca-0x150,_0x89349);}const _0x39de83=_0x248f40?{..._0x2497f0,'turnMeta':_0x248f40}:_0x2497f0;await _0x21bb5c['registry']['runObservers'](_0x24c33d(0x4e,-0x1b,0x18,-_0x2a6381._0x36b30d),structuredClone(_0x22dc77),_0x39de83);},_0x80442c=async _0x400a9b=>{if(!_0xe8b94f[_0x1b4198(0x397,_0x36a010._0x3bf2a5,0x3fe,0x3d0)])return 0x0;const _0xf62f92=await _0xe8b94f[_0x1b4198(_0x36a010._0x39b752,_0x36a010._0x34e9d4,0x3fe,_0x36a010._0x1a851d)]();function _0x1b4198(_0x2b9f84,_0x537194,_0x49f417,_0x5ac6b1){return _0x4689c5(_0x2b9f84-0x18c,_0x537194-_0x1a4f43._0x5368dd,_0x49f417-0x4ba,_0x5ac6b1);}throwIfAborted(_0x33505c);function _0x52fe21(_0xb51318,_0x3c66b0,_0x138577,_0x3cc7fa){return _0x4689c5(_0xb51318-0xb6,_0x3c66b0-_0x3bd728._0x364e96,_0xb51318- -_0x3bd728._0x5ee8b8,_0x3c66b0);}if(_0xf62f92[_0x1b4198(0x428,0x399,0x3bc,0x3de)]===0x0)return 0x0;await _0x400a9b?.();for(const _0x3120bf of _0xf62f92){const _0x2c9090=await _0x1c9d67(_0x1b4198(_0x36a010._0x7132ab,_0x36a010._0x5c6cab,_0x36a010._0x79130,_0x36a010._0x4cc043),normalizeMessage(_0x3120bf));throwIfAborted(_0x33505c),_0x4e2551[_0x52fe21(-_0x36a010._0x1590db,-_0x36a010._0x299f75,-0x1c9,-0x207)][_0x1b4198(0x464,0x4be,_0x36a010._0x52661e,0x48b)](_0x2c9090),await _0x1fd085(_0x2c9090),await _0x1e984d({'type':'user_message','message':_0x2c9090});}return _0xf62f92['length'];};let _0x182994=0x0;try{const _0x575728=await _0x1c9d67('onUserMessage',normalizeMessage(_0xe8b94f['message']));_0x4e2551[_0x41785e(-0x185,-_0x2daf3a._0x34e37a,-0x1d8,-_0x2daf3a._0x474f02)][_0x4689c5(-0x89,-_0x2daf3a._0x2d63b4,-0x63,-0xe)](_0x575728),await _0x1fd085(_0x575728),await _0x1e984d({'type':_0x41785e(-0x1a6,-_0x2daf3a._0x39ac1d,-0x24f,-_0x2daf3a._0x66dd15),'message':_0x575728});while(!![]){throwIfAborted(_0x33505c),_0x182994+=0x1;const _0x353f43=createAssistantMessageId(_0x4e2551[_0x4689c5(-_0x2daf3a._0x379e9a,-0x64,-0x9d,-_0x2daf3a._0x3f3166)],_0x182994),_0x435d4f=createReasoningMessageId(_0x353f43),_0x2d981f={'model':_0xf933d4[_0x41785e(-0x164,-_0x2daf3a._0x27b027,-_0x2daf3a._0xa443d1,-0x1b3)],'modelIdentity':_0xf933d4['modelIdentity'],..._0xf933d4[_0x4689c5(-_0x2daf3a._0x588a8b,-0xfc,-0xf9,-0xdd)]?{'provider':_0xf933d4[_0x4689c5(-0x144,-_0x2daf3a._0x43a709,-_0x2daf3a._0x112e6f,-0xc2)]}:{}};let _0xca3b91={'model':_0xf933d4[_0x4689c5(-_0x2daf3a._0x1e6e15,-0x85,-_0x2daf3a._0x1935f9,-0x5e)],..._0xf933d4[_0x4689c5(-0x60,-0x31,-0x5e,-0x92)]!==void 0x0?{'maxTokens':_0xf933d4['maxTokens']}:{},'system':structuredClone(_0x4e2551[_0x41785e(-_0x2daf3a._0x46ef88,-0x25b,-0x287,-_0x2daf3a._0x196884)]),'messages':structuredClone(_0x4e2551[_0x4689c5(-_0x2daf3a._0x54f593,-0x5c,-_0x2daf3a._0x3f4f1a,-0x104)]),'tools':_0x21bb5c[_0x41785e(-_0x2daf3a._0x15b3d6,-0x23e,-_0x2daf3a._0x3ec311,-0x261)][_0x41785e(-0x1ef,-_0x2daf3a._0x171369,-_0x2daf3a._0x29eb70,-_0x2daf3a._0x8b9b4)](),'metadata':{'sessionId':_0x4e2551[_0x41785e(-0x1d6,-0x1e9,-0x252,-_0x2daf3a._0x393daf)],'turnId':_0x4e2551[_0x4689c5(-_0x2daf3a._0x7ab80a,-0xda,-_0x2daf3a._0x47f4e8,-0x85)],'modelIdentity':_0xf933d4[_0x41785e(-0x20e,-0x20d,-0x24f,-0x241)],..._0xf933d4[_0x4689c5(-_0x2daf3a._0x55b1db,-0x95,-_0x2daf3a._0x31d187,-0x14)]!==void 0x0?{'pricingProviderId':_0xf933d4[_0x41785e(-_0x2daf3a._0x4bcb04,-_0x2daf3a._0x1d7250,-0x14e,-_0x2daf3a._0x1c15a8)]}:{}},..._0x21bb5c[_0x41785e(-0x200,-0x1cc,-_0x2daf3a._0xa443d1,-_0x2daf3a._0x1fce84)]?{'outputFormat':_0x21bb5c[_0x4689c5(-_0x2daf3a._0x432513,-0x49,-0x96,-0x75)]}:{}};_0xca3b91=await _0x1c9d67(_0x4689c5(-0x10c,-0x12b,-0x10e,-_0x2daf3a._0x12222e),_0xca3b91);{const {pricingProviderId:_0xdb0a10,..._0x455387}=_0xca3b91['metadata'];_0xca3b91={..._0xca3b91,'metadata':{..._0x455387,..._0xf933d4['pricingProviderId']!==void 0x0?{'pricingProviderId':_0xf933d4[_0x4689c5(-_0x2daf3a._0x321e38,0x0,-_0x2daf3a._0x5b6a98,-_0x2daf3a._0xee30f)]}:{}}};}await _0x1e984d({'type':'model_request','request':_0xca3b91});const _0x2b304c=Date['now']();_0x2d981f[_0x41785e(-_0x2daf3a._0x4a902d,-0x1ca,-0x1f3,-0x1d7)]=_0x2b304c;let _0x3c2da4=await executeModelRequest(_0xca3b91,_0xe8b94f,_0xf933d4,_0x21bb5c,_0x475e34,{'assistantMessageId':_0x353f43,'reasoningMessageId':_0x435d4f,'meta':_0x2d981f});const _0x302d7f=Date[_0x41785e(-0x181,-_0x2daf3a._0x4713df,-_0x2daf3a._0x52410f,-_0x2daf3a._0x3b9806)]();_0x2d981f[_0x41785e(-0x1b5,-0x206,-_0x2daf3a._0x163858,-_0x2daf3a._0xe32244)]=_0x302d7f,_0x3c2da4=await _0x1c9d67(_0x41785e(-_0x2daf3a._0x1efaa9,-0x1db,-0x1cc,-_0x2daf3a._0x1b020e),_0x3c2da4);_0x3c2da4[_0x4689c5(-_0x2daf3a._0x469bbd,-0x115,-0xa9,-_0x2daf3a._0x38d2e5)]&&(_0x3c2da4={..._0x3c2da4,'providerState':{..._0x3c2da4[_0x41785e(-_0x2daf3a._0x2d6181,-0x1df,-_0x2daf3a._0x1eaff8,-0x1e7)],'originModelIdentity':_0xf933d4[_0x41785e(-0x23f,-0x20d,-0x1b7,-_0x2daf3a._0x3da1b3)]}});_0x3c2da4=withEstimatedModelCost(_0xca3b91,_0x3c2da4);const _0x3e34fa=Math[_0x41785e(-_0x2daf3a._0x470c19,-_0x2daf3a._0xf81f2f,-_0x2daf3a._0x1d80d4,-_0x2daf3a._0x2d3117)](0x0,_0x302d7f-_0x2b304c),_0x8193d2={'version':0x1,'usage':structuredClone(_0x3c2da4[_0x4689c5(-_0x2daf3a._0x3972ec,-_0x2daf3a._0x3ffbfe,-0x103,-0xa7)]),'modelTimeMs':_0x3e34fa},_0xc5d2fb=_0x2240b2=>({..._0x2d981f,'metrics':{..._0x8193d2,'usage':structuredClone(_0x8193d2[_0x4689c5(-0x16f,-0x147,-0x103,-0x123)]),'completesRequest':_0x2240b2}});await _0x1e984d({'type':'model_response','response':_0x3c2da4,'modelTimeMs':_0x3e34fa}),_0x4e2551[_0x41785e(-0x1ac,-0x21b,-0x1c2,-_0x2daf3a._0x6e7f57)]=_0x3c2da4;let _0x378f9e=await _0x1c9d67(_0x4689c5(-0xab,-_0x2daf3a._0x33338d,-0xec,-_0x2daf3a._0x29db51),withMessageId(responseToAssistantMessage(_0x3c2da4),_0x353f43));_0x378f9e=withMessageId(_0x378f9e,_0x353f43);const _0x80e7df=getToolUseBlocks(_0x378f9e),_0x5b8dc1=await Promise[_0x41785e(-0x17e,-0x1c2,-_0x2daf3a._0x3394e2,-0x197)](_0x80e7df[_0x41785e(-0x1ce,-0x1d4,-0x1fe,-0x220)](_0x1d52d8=>_0x1c9d67('beforeToolExecution',_0x1d52d8)));_0x5b8dc1['length']>0x0&&(_0x378f9e=replaceToolUseBlocks(_0x378f9e,_0x5b8dc1));const _0x26f3af=withMessageId(_0x378f9e,_0x353f43);_0x378f9e=_0x26f3af;const _0x2ac97a=createReasoningMessage(_0x378f9e),_0x4023dc=createAssistantTextMessage(_0x378f9e),_0x560605=createToolUseMessage(_0x378f9e);_0x2ac97a&&await _0x1e984d({'type':_0x41785e(-_0x2daf3a._0x4f41cf,-_0x2daf3a._0x538e10,-0x287,-_0x2daf3a._0x4390b0),'message':withMessageId(_0x2ac97a,_0x435d4f)});_0x4023dc&&await _0x1e984d({'type':'assistant_message','message':withMessageId(_0x4023dc,_0x353f43)});_0x560605&&await _0x1e984d({'type':_0x41785e(-0x186,-0x1dd,-0x1fa,-_0x2daf3a._0x3bdea2),'message':withMessageId(_0x560605,_0x353f43)});_0x4e2551[_0x41785e(-0x1b2,-_0x2daf3a._0x34e37a,-0x22e,-0x1c0)]['push'](_0x26f3af);_0x5b8dc1[_0x41785e(-0x1e5,-0x234,-_0x2daf3a._0x110032,-_0x2daf3a._0x8ca130)]>0x0&&await _0x1fd085(_0x26f3af,_0xc5d2fb(![]));for(const _0x156049 of _0x5b8dc1){await _0x1e984d({'type':_0x4689c5(-_0x2daf3a._0x5dbdd1,-_0x2daf3a._0x31025b,-_0x2daf3a._0x335e02,-0xa9),'toolCall':_0x156049});}if(_0x5b8dc1[_0x41785e(-_0x2daf3a._0x474f02,-_0x2daf3a._0x106e2e,-0x200,-0x296)]===0x0){const _0x50fd2c=await _0x80442c(async()=>{await _0x1fd085(_0x26f3af,_0xc5d2fb(![]));});if(_0x50fd2c>0x0)continue;const _0x45a208=await _0x1c9d67(_0x41785e(-_0x2daf3a._0x39ac1d,-0x1f6,-_0x2daf3a._0x27e8cd,-_0x2daf3a._0x470e0a),_0x378f9e),_0x17dd71=withMessageId(_0x45a208,_0x353f43);return _0x4e2551[_0x4689c5(-0x97,-_0x2daf3a._0x13402d,-_0x2daf3a._0x33d6da,-_0x2daf3a._0x2cc129)]=_0x17dd71,_0x4e2551[_0x4689c5(-_0x2daf3a._0x51b519,-_0x2daf3a._0x583e91,-0xb0,-_0x2daf3a._0x14a997)][_0x4e2551[_0x41785e(-_0x2daf3a._0x11dd4f,-0x1e6,-_0x2daf3a._0x51b7e9,-0x236)]['length']-0x1]=_0x17dd71,await _0x1fd085(_0x17dd71,_0xc5d2fb(!![])),await _0x5ab86d({'type':_0x41785e(-0x20c,-_0x2daf3a._0x10171d,-0x1db,-_0x2daf3a._0x976aaf),'message':_0x17dd71}),throwIfAborted(_0x33505c),await _0x21bb5c[_0x41785e(-_0x2daf3a._0x15ec0f,-0x1ea,-_0x2daf3a._0xa06a1a,-_0x2daf3a._0x7e64d4)][_0x41785e(-_0x2daf3a._0x366b0f,-0x1d5,-0x189,-0x1ca)](_0x4689c5(-_0x2daf3a._0x1249bf,-_0x2daf3a._0x25bf68,-0xe6,-0x139),_0x4e2551,_0x2497f0),await _0x1e984d({'type':_0x41785e(-_0x2daf3a._0x4bb6cf,-_0x2daf3a._0x491675,-_0x2daf3a._0x32d736,-_0x2daf3a._0x2c7e9d),'state':_0x4e2551}),{'status':_0x4689c5(-0x8e,-0xc6,-_0x2daf3a._0x4b5da9,-0x71),'finalMessage':_0x17dd71,'state':_0x4e2551};}let _0x331d03=await _0x21bb5c[_0x4689c5(-_0x2daf3a._0x17e61f,-0x139,-0x108,-_0x2daf3a._0x532f43)][_0x41785e(-0x213,-_0x2daf3a._0x2d235e,-_0x2daf3a._0x2a51cb,-0x1d0)](_0x5b8dc1,_0x475e34);const _0x527ec7=_0x331d03[_0x41785e(-_0x2daf3a._0x4fe13a,-0x1c6,-_0x2daf3a._0x6ad07d,-0x177)](isAbortedToolResult),_0x467b69=_0x527ec7?_0x4deb03:_0x1c9d67,_0x340b61=_0x527ec7?_0x5ab86d:_0x1e984d;_0x331d03=await Promise[_0x4689c5(-_0x2daf3a._0x1c4b25,-_0x2daf3a._0x432513,-_0x2daf3a._0x3808f1,-0x7b)](_0x331d03[_0x41785e(-_0x2daf3a._0x19ca1b,-0x1d4,-_0x2daf3a._0xe32244,-_0x2daf3a._0x57db98)](_0x99342e=>_0x467b69(_0x4689c5(-0xa5,-0x84,-0xb5,-0x76),_0x99342e))),_0x4e2551[_0x41785e(-0x1eb,-0x22c,-0x271,-0x1cd)][_0x41785e(-0x207,-0x199,-0x147,-0x1ea)](..._0x331d03);for(const _0x20dab6 of _0x331d03){await _0x340b61({'type':_0x4689c5(-_0x2daf3a._0x3d61bf,-_0x2daf3a._0x199c2f,-0x10c,-0xa3),'result':_0x20dab6});}const _0x3c5ea8=await _0x467b69(_0x4689c5(-_0x2daf3a._0xdc7e3d,-_0x2daf3a._0x437e09,-_0x2daf3a._0x2d62df,-0x41),createToolResultUserMessage(_0x331d03));await _0x340b61({'type':'tool_result_message','message':_0x3c5ea8}),_0x4e2551[_0x41785e(-_0x2daf3a._0x4bfa57,-_0x2daf3a._0x3d8835,-_0x2daf3a._0xdd9327,-_0x2daf3a._0x216460)][_0x41785e(-0x1a7,-0x199,-_0x2daf3a._0x1eaff8,-0x171)](_0x3c5ea8),await _0x1fd085(_0x3c5ea8);if(_0x527ec7)return{'status':_0x4689c5(-_0x2daf3a._0x54611b,-0x55,-0x83,-0xca),'state':_0x4e2551};await _0x80442c();}}catch(_0x33ba38){if(!_0x33505c[_0x41785e(-0x1e2,-_0x2daf3a._0x1e842f,-0x206,-_0x2daf3a._0xbd3af3)])throw new TurnFailedError(_0x33ba38,_0x4e2551);return{'status':_0x4689c5(-0xaf,-_0x2daf3a._0x443487,-0x83,-_0x2daf3a._0xe69c34),'state':_0x4e2551};}}function createSessionId(){const _0x5166e6={_0x37dadf:0x1b9,_0x5ecfca:0x1bd,_0x17b77a:0x13a,_0x37fc80:0xd8,_0x5e900b:0x102},_0x2bf362={_0x5f342e:0xce,_0x53e198:0x227};function _0x5ada59(_0x1afbba,_0x4e2359,_0x13fad9,_0x31de86){return _0x1f4b8d(_0x13fad9,_0x4e2359-0x150,_0x1afbba-0x330,_0x31de86-0x138);}function _0xc949ed(_0x475a57,_0x1a162a,_0x32dcdf,_0x9dfb10){return _0x3b29bd(_0x475a57-_0x2bf362._0x5f342e,_0x9dfb10,_0x32dcdf-0xee,_0x1a162a- -_0x2bf362._0x53e198);}return _0x5ada59(0x1ba,0x195,0x154,_0x5166e6._0x37dadf)+Date[_0xc949ed(0x1be,0x167,_0x5166e6._0x5ecfca,_0x5166e6._0x17b77a)]()+'-'+Math[_0xc949ed(0x137,0x10a,0x157,0xe6)]()[_0xc949ed(0x121,0xc3,0xbe,0xc0)](0x10)[_0xc949ed(_0x5166e6._0x37fc80,0x145,0xd6,_0x5166e6._0x5e900b)](0x2,0xa);}function createTurnId(_0x9bf9e5){return'turn-'+_0x9bf9e5;}function createDefaultMessage(_0x49c5b0){if(_0x49c5b0===void 0x0)return void 0x0;return normalizeUserInput(_0x49c5b0);}function normalizeUserInput(_0x44bb86){const _0x45eac2={_0x36d776:0x2eb,_0x24938a:0x247,_0x47539c:0x2b3,_0x53153c:0x258,_0x54275d:0x285},_0x2a19d7={_0x56aa75:0x14e,_0x5bce89:0xd3},_0x2737c0={_0x523a5b:0x1d4,_0x4a431e:0x595};function _0x5e0c2c(_0x3dea90,_0x517dfb,_0x25ae40,_0x5be0b4){return _0x1f4b8d(_0x3dea90,_0x517dfb-_0x2737c0._0x523a5b,_0x5be0b4-_0x2737c0._0x4a431e,_0x5be0b4-0x6d);}function _0x360a81(_0x75a2d7,_0x4cd7af,_0x33361e,_0x1b5b5b){return _0x3b29bd(_0x75a2d7-0xc5,_0x1b5b5b,_0x33361e-_0x2a19d7._0x56aa75,_0x33361e- -_0x2a19d7._0x5bce89);}if(typeof _0x44bb86==='string')return{'role':_0x360a81(_0x45eac2._0x36d776,_0x45eac2._0x24938a,_0x45eac2._0x47539c,0x321),'content':[{'type':_0x360a81(0x21e,0x222,_0x45eac2._0x53153c,_0x45eac2._0x54275d),'text':_0x44bb86}]};return normalizeMessage(_0x44bb86);}function resolveChatModel(_0x4dc578){const _0x44fa86={_0x1b9102:0xbd,_0x476617:0x104,_0x39d6a2:0x12f},_0x12c0cc={_0x209b1a:0xdd,_0x26f33d:0x151,_0x51bfe2:0x3b8};function _0x5414da(_0x547eff,_0x4e168d,_0xa02531,_0x29d567){return _0x3b29bd(_0x547eff-_0x12c0cc._0x209b1a,_0x547eff,_0xa02531-_0x12c0cc._0x26f33d,_0x4e168d- -_0x12c0cc._0x51bfe2);}function _0x5a1efb(_0x3a6467,_0x1cce7f,_0x477efb,_0x481417){return _0x3b29bd(_0x3a6467-0x80,_0x3a6467,_0x477efb-0x3c,_0x1cce7f-0x110);}if(!_0x4dc578['chatModel'])throw new Error(_0x5414da(-0x7f,-_0x44fa86._0x1b9102,-_0x44fa86._0x476617,-0xd4));return _0x4dc578[_0x5414da(-0xe2,-0xe8,-0x14c,-_0x44fa86._0x39d6a2)];}function _0x5168(){const _0x10a8cc=['B3v0Chv0vg9Rzw5Z','qwDLBNqUC2vUzcbYzxf1AxjLCYbHig1LC3nHz2uGD2HLBIbUBYbKzwzHDwX0ig1LC3nHz2uGAxmGy29UzMLNDxjLza','CMvXDwvZDenVDw50','C3LZDgvT','BgLZDa','nduYofHkqMDuCG','vg9VBcbLEgvJDxrPB24GCMvQzwn0zwqGzM9Yia','zNvUy3rPB24','mtbRBxLdB0G','ChjVCgvYDgLLCW','A2LUza','y29UDgv4DfDPBMrVD0XPBwL0','Bw9KzwXdywXSq291BNq','Dg90ywXuB2TLBNm','CMvWB3j0zwrdB3n0','zxHLy3v0zq','Aw50zxjUywXmAwzLy3LJBgu','C3LZDgvTuhjVBxb0','yM9VBgvHBG','C2LNBMfS','y2f1C2u','CMvHC29UAw5Nx21LC3nHz2u','y29UDgvUDa','C3vTBwfYEuLUzgv4','Dg9tDhjPBMC','oIbTAxnZAw5NihjLCxvPCMvKigzPzwXKici','yMvMB3jLtw9KzwXszxf1zxn0','yw1VDw50vxnKvgLJA3m','Dg9VBf9Yzxn1Bhq','AxnbCNjHEq','Bwv0CMLJCW','Dg9VBf9YzwPLy3rLza','Dg9VBfj1BNrPBwu','BMv4Da','zMLSDgvY','DMfSDwu','yw55t2y','DxnHz2u','oIb1BMv4CgvJDgvKigzPzwXKici','B3jKzxi','Bwv0yq','qwDLBNqGCMvXDwLYzxmGysbJAgf0tw9KzwW','BgvUz3rO','mtm3uNbVyMDV','CMvHC29UAw5Nx2nODw5R','oIbLEhbLy3rLzcbUDw1Izxi','CMvQzwn0','ChjVDMLKzxi','CNvU','Dg9VBhm','Dg9VBfjLC3vSDhm','CMvHza','zw50CMLLCW','CMvZB2X2zq','Dg90ywXnB2rLBfrPBwvnCW','mtyYnJC1senPBgXA','Dg90ywXpDxrWDxruB2TLBNm','zMLUywXnzxnZywDL','oIbLEhbLy3rLzcb2ywX1zsbTyxrJAgLUzYbHBNLpzIbZy2HLBwe','DhjPBq','yMvMB3jLqxnZAxn0yw50qxbWzw5K','Dg90ywXszwfZB25PBMDuB2TLBNm','C2v0u3LZDgvTuhjVBxb0','Aw5WDxrezwX0yq','z2v0','CMvHC29U','ywz0zxjuDxjUq29TCgXLDgu','BgfZDfjLC3bVBNnL','CMvWB3j0zwrdB3n0q2fSBenVDw50','ywjVCNq','Dg9VBf9VDxrWDxrFy2H1BMS','mte5odC0nMLxzvnODW','Dg9VBf91C2vFzgvSDge','CMvXDwvZDa','Dg9VBf9JB21WBgv0zwq','CMfJzq','C3rYAw5NAwz5','yxnZAxn0yw50x2nODw5R','yxnZAxn0yw50twvZC2fNzuLK','odCYmtLvz0LnuK0','Dw5WCMLJzwrnB2rLBenHBgXdB3vUDa','Bw9KzwXjzgvUDgL0Eq','oMfZC2LZDgfUDdO','Dw5RBM93BL90B29S','zgvSDge','ywrKrxzLBNrmAxn0zw5LCG','zw5HyMXLza','Aw5WDxruB2TLBNm','DhvYBKnVBxbSzxrLzef0','Dgv4Da','C3rYDwn0DxjLza','Dg90ywXdB3n0vxnKvgLJA3m','BNvTyMvY','Dg9VBenHBgXdB3vUDa','DxnLCL9TzxnZywDL','CMfUzg9T','oIbLEhbLy3rLzcbIB29SzwfU','C3rYzwfTAw5N','CgvYBwLZC2LVBKnSyxnZ','zgvWCW','oIbLEhbLy3rLzcbVyMPLy3q','mZzTrNrhsNi','zMLUza','Aw5WDxq','yMvMB3jLrMLUywXpDxrWDxq','zgvMyxvSDe1LC3nHz2u','B2jQzwn0','B3bLBMfPx3jLyxnVBMLUz19ZDw1Tyxj5x2rLBhrH','zhjHAw5tDgvLCMLUzW','B3bLBMfPx3jLyxnVBMLUz19KzwX0yq','oIb0zxjTAw5HBcbVyNnLCNzLCIaI','Aw5WDxrty2HLBwe','DgHLBG','DhLWzq','yxnRvxnLCG','ywz0zxjuB29SuMvZDwX0','CMvNAxn0CNK','C2vZC2LVBKLK','B3v0Chv0','CMvHC29UAw5Nu3rHCNrLzef0','BwvZC2fNzxm','CMvZCg9UC2u','BgLZDfrVB2Xty2HLBwfZ','CMvZzxrnzxnZywDLCW','mtGZnLH1AfjvyW','nte3odyWmfLUENfpvq','y29TCgXLDgvK','ChjVDMLKzxjtDgf0zq','Dg90ywXszxbVCNrLzenVC3rvC2ruAwnRCW','Dg9VBf91C2vFBwvZC2fNzq','y29UDgvUDf9KzwX0yq','ywz0zxjnB2rLBfjLC3bVBNnL','Dg9VBf9ZDgfYDgvK','iIbMB3iG','B2jZzxj2zxi','C29YDa','zw51Bq','CNvUt2jZzxj2zxjZ','BwfW','DhvYBKLK','ywnXDwLYzq','DhvYBL9JB21WBgv0zq','Bw9KzwW','z2v0q29UDgv4DfDPBMrVD0XPBwL0','ChjVDMLKzxjFC3rYzwfTx3jLC2v0','C2v0vg9VBhm','B3v0Chv0rM9YBwf0','CMvHC29UAw5Nvg9Rzw5Z','DhvYBLn0yxj0zwrbDa','oIbLEhbLy3rLzcbZDhjPBMC','Dg9VBf9JywXS','DgHPBMTPBMC','C29Tzq','zgvZy3jPChrPB24','C2XPy2u','Dg90ywXjBNb1DfrVA2vUCW','ywXS','D3jPDgu','oNjLyxnVBMLUzW','zxHLy3v0zunHBgXZ','B25vC2vYtwvZC2fNzq','Aw5JBhvKzxm','B25uB29Sq2fSBa','DgvYBwLUywW','C2v0u2vZC2LVBKLK','ywjVCNrLza','zxn0Aw1HDgvKq29ZDenHBgXdB3vUDa','zMLUywXFBwvZC2fNzq','BwvZC2fNzq','Dg90ywXfC3rPBwf0zwrdB3n0vxnKvgLJA3m','CMvHC29UAw5Nq29TCgXLDgvKqxq','iIbPCYbHBhjLywr5igvUywjSzwq','zxn0Aw1HDgvKq29ZDa','DhjHBNnMB3jTzxi','AxrLBuLK','CMvNAxn0zxi','C2v0','vw5RBM93BIb0B29SoIa','Bw9KzwXFCMvXDwvZDa','ywrK','DxnLCG','x3n5C3rLBvbYB21WDa','Bw9KzwXdywXSCW','BMfTzq','ChjVDMLKzxjFCMv0CNK','C2vZC2LVBKrPCG','AgfZt3DU','C2vZC2LVBI0','BM93','yMvMB3jLvg9VBfjLC3vSDefWCgvUza','zg9Uzq','Bw9KzwXuAw1Ltxm','C2vUza','ChjPy2LUz1bYB3zPzgvYswq','ndjusfzJAhO','ywX3yxLZlwnVBMzPCM0','Bw9KzwXFCMvZCg9UC2u','ChvZAa','CMvXDwLYzwq','yw50AhjVCgLJx3rOAw5RAw5Nx2rLBhrH','y29TCgXLDgvZuMvXDwvZDa','Aw5KzxG','Bwf4vg9Rzw5Z','y29UDgvUDeLUzgv4','mZu0nda1B0D4s3P4','C3rYzwfT','ywz0zxjnzxnZywDLqxbWzw5K','C3rYAw5N','C2v0q2HHDe1VzgvS','mtaXntK4nhn6qvjhvq','zxH0zw5ZAw9UCW','Dg9VBhncEu5HBwu','sw52ywXPzcb0B29SigLUChv0igf0ia','AM9PBG','Dg9VBf91C2u','C3rHz2u','B25fDMvUDa','DhvYBKLUzgv4','zM9YrwfJAa','Bwf4','y2HHDe1VzgvS','zxjYB3i'];_0x5168=function(){return _0x10a8cc;};return _0x5168();}function createRegistry(_0x53c600){const _0x370aad={_0x35a91b:0x533,_0x3b04e2:0x4ed,_0x583d59:0x461,_0x54865f:0x42b,_0x2b414a:0x52c,_0x30503c:0x533},_0x5a3c39={_0x445a78:0x49,_0x33007d:0x279},_0xf78270={_0x339ce9:0x1bf,_0x50ac3a:0x6aa,_0x575308:0xe3};if(_0x53c600['registry'])return _0x53c600[_0xa6ed06(0x52e,_0x370aad._0x35a91b,0x51f,_0x370aad._0x3b04e2)];const _0x15aace=createExtensionRegistry();function _0xa6ed06(_0x5a0e79,_0x150016,_0x3d5a84,_0x408491){return _0x1f4b8d(_0x5a0e79,_0x150016-_0xf78270._0x339ce9,_0x408491-_0xf78270._0x50ac3a,_0x408491-_0xf78270._0x575308);}function _0x24a0cb(_0x28aa6b,_0x2a1e9a,_0x31c3ba,_0x2ae875){return _0x3b29bd(_0x28aa6b-0x41,_0x31c3ba,_0x31c3ba-_0x5a3c39._0x445a78,_0x2ae875- -_0x5a3c39._0x33007d);}const _0xaa8cea=_0x53c600[_0xa6ed06(0x4c6,_0x370aad._0x583d59,_0x370aad._0x54865f,0x46d)]??[];for(const _0x5567a6 of _0xaa8cea){_0x15aace[_0xa6ed06(_0x370aad._0x2b414a,_0x370aad._0x30503c,0x4d6,0x528)](_0x5567a6);}return _0x15aace;}var Agent=class{['_systemPrompt'];[_0x1f4b8d(-0x1e5,-0x1b6,-0x1ce,-0x185)];[_0x3b29bd(0x2fa,0x350,0x2c8,0x2f0)];[_0x3b29bd(0x2fd,0x321,0x310,0x347)];[_0x3b29bd(0x366,0x3a3,0x2de,0x34a)];['defaultMessage'];[_0x3b29bd(0x2ff,0x291,0x2d8,0x2cd)];constructor(_0x4a6bc6={}){const _0x377f61={_0x59d5cf:0x1d8,_0x2f0e9f:0x204,_0x48f4c0:0x1ff,_0x5926a9:0x1bb,_0x2de6ac:0x16,_0x2ba014:0x1ce,_0x44ae86:0x21e,_0x220004:0xa8,_0x4286cb:0xa5,_0x18fb88:0xb,_0x235b9b:0x29,_0x22f60c:0x255,_0x3e1f47:0x1b0,_0x5843b6:0x1f6,_0x40ecd3:0xb,_0x2ab789:0x7e,_0x208472:0xac,_0x59b2c8:0x4c,_0x26f4d8:0xb3,_0x2ad24f:0x7e,_0x13b934:0x268,_0x3a701e:0x228,_0x3bc80e:0xdf,_0x10e145:0xd4},_0x71f0a7={_0x5f0f1b:0x4e3,_0x35126f:0x47a,_0x1790d9:0x447},_0x15165d={_0x1337b6:0x19d,_0x52e040:0x133};this[_0x51da68(_0x377f61._0x59d5cf,_0x377f61._0x2f0e9f,0x1c3,_0x377f61._0x48f4c0)]=_0x4a6bc6[_0x51da68(_0x377f61._0x5926a9,0x204,0x214,0x1e6)]??createSessionId(),this[_0xb66ea6(-0x3b,0x30,-0x3d,_0x377f61._0x2de6ac)]=0x0,this['_systemPrompt']=_0x4a6bc6[_0x51da68(0x1b1,0x1a0,0x17a,0x133)]??'',this[_0x51da68(0x210,0x207,_0x377f61._0x2ba014,_0x377f61._0x44ae86)]=(_0x4a6bc6['messages']??[])[_0xb66ea6(_0x377f61._0x220004,0x82,0xa1,_0x377f61._0x4286cb)](normalizeMessage),this['defaultMessage']=createDefaultMessage(_0x4a6bc6['message']),this[_0xb66ea6(_0x377f61._0x18fb88,0x51,_0x377f61._0x235b9b,0x39)]=createAgentMetrics({'getContextWindowLimit':_0x4a6bc6[_0x51da68(_0x377f61._0x22f60c,0x21e,_0x377f61._0x3e1f47,_0x377f61._0x5843b6)]});const _0x3853cb=_0x4a6bc6[_0xb66ea6(_0x377f61._0x40ecd3,0x82,0x6b,0x15)];function _0xb66ea6(_0x5cf5de,_0x32ac5e,_0x454ee7,_0x84de50){return _0x3b29bd(_0x5cf5de-_0x15165d._0x1337b6,_0x32ac5e,_0x454ee7-_0x15165d._0x52e040,_0x84de50- -0x2b7);}const _0x1338b5=async(_0x1fe374,_0x231821)=>{this[_0x4aae72(_0x71f0a7._0x5f0f1b,_0x71f0a7._0x35126f,0x41b,_0x71f0a7._0x1790d9)]['recordEvent'](_0x1fe374);function _0x4aae72(_0x4d408f,_0x14c2dc,_0x1363b2,_0x30b477){return _0x51da68(_0x1363b2,_0x14c2dc-0x2cd,_0x1363b2-0x118,_0x30b477-0x19b);}await _0x3853cb?.(_0x1fe374,_0x231821);},_0x3e7c25=createInternalToolRuntime(_0x4a6bc6[_0xb66ea6(_0x377f61._0x2ab789,_0x377f61._0x208472,0x33,_0x377f61._0x59b2c8)]??[],{'onEvent':_0x1338b5,'onToolCall':_0x4a6bc6['onToolCall']});function _0x51da68(_0x5d4697,_0x452ea5,_0x44dcf2,_0x52de04){return _0x3b29bd(_0x5d4697-0x48,_0x5d4697,_0x44dcf2-0x19f,_0x452ea5- -0x143);}this[_0xb66ea6(0x10,_0x377f61._0x26f4d8,0x99,_0x377f61._0x2ad24f)]={'registry':createRegistry(_0x4a6bc6),'chatModel':resolveChatModel(_0x4a6bc6),'toolRuntime':_0x3e7c25,'askUser':_0x4a6bc6[_0x51da68(0x217,0x201,_0x377f61._0x13b934,_0x377f61._0x3a701e)],'setTopic':_0x4a6bc6['setTopic'],'onEvent':_0x1338b5,'sessionDir':_0x4a6bc6[_0xb66ea6(0xa1,0xb3,_0x377f61._0x3bc80e,_0x377f61._0x10e145)],'outputFormat':_0x4a6bc6['outputFormat']};}get[_0x1f4b8d(-0x20f,-0x238,-0x220,-0x1c0)](){return this['_systemPrompt'];}['setTools'](_0x42f672=[]){const _0x4de208={_0xe75d77:0x2d7,_0x7d7560:0x2af,_0x5b3bd4:0x6e,_0x5b7cd1:0x5,_0x444bb7:0x25,_0x6c5c09:0x3b},_0x28200f={_0x32a3a1:0x42},_0x54d918={_0x237b64:0x17};function _0x52c5d1(_0x661a44,_0x334746,_0xd6fee5,_0x4dffa2){return _0x3b29bd(_0x661a44-0x26,_0x661a44,_0xd6fee5-_0x54d918._0x237b64,_0xd6fee5- -0x33e);}function _0x3997a8(_0x12a101,_0x336601,_0x20746e,_0x4b236d){return _0x1f4b8d(_0x336601,_0x336601-0x7a,_0x20746e- -0x109,_0x4b236d-_0x28200f._0x32a3a1);}this[_0x3997a8(-0x28a,-0x2a9,-_0x4de208._0xe75d77,-_0x4de208._0x7d7560)]['toolRuntime'][_0x52c5d1(_0x4de208._0x5b3bd4,_0x4de208._0x5b7cd1,_0x4de208._0x444bb7,_0x4de208._0x6c5c09)](_0x42f672);}['getTools'](){const _0x10b07d={_0x37dfe2:0x168,_0x4722e5:0xfd,_0x221ed9:0x448},_0x4f51dc={_0x3508e3:0x18b},_0x32eb0f={_0x2df9bc:0xf3};function _0x299172(_0x353d9f,_0x2270c7,_0x700ff3,_0xfa1ee3){return _0x1f4b8d(_0xfa1ee3,_0x2270c7-0xe8,_0x700ff3-0xbf,_0xfa1ee3-_0x32eb0f._0x2df9bc);}function _0x32665e(_0x327ca3,_0xbbd507,_0xf28b75,_0x4037fa){return _0x1f4b8d(_0x327ca3,_0xbbd507-_0x4f51dc._0x3508e3,_0x4037fa-0x63e,_0x4037fa-0x1dd);}return this[_0x299172(-_0x10b07d._0x37dfe2,-_0x10b07d._0x4722e5,-0x10f,-0xb5)][_0x32665e(_0x10b07d._0x221ed9,0x430,0x413,0x42d)][_0x299172(-0x130,-0xd7,-0xf8,-0x116)]();}[_0x1f4b8d(-0x242,-0x204,-0x1f3,-0x1d1)](_0x208beb,_0x30e437={}){const _0x593023={_0x43b0be:0x18d,_0x4ea812:0x221,_0x2278d8:0x226,_0x283946:0x1e7,_0x2b666e:0x224,_0x4e62e8:0x1ea,_0xb88cc9:0x11,_0x5b12f8:0x3},_0x1fcbab={_0x4d149c:0x48},_0x2ddd81={_0x4a6724:0xa8,_0x1ac70c:0x60,_0x472e76:0x56e};function _0x2cf81b(_0x26d069,_0x1a6616,_0x524c2d,_0x1ffc52){return _0x3b29bd(_0x26d069-_0x2ddd81._0x4a6724,_0x26d069,_0x524c2d-_0x2ddd81._0x1ac70c,_0x524c2d- -_0x2ddd81._0x472e76);}function _0x5376ba(_0x5bab86,_0xf07f09,_0x3baa9b,_0x65156b){return _0x3b29bd(_0x5bab86-_0x1fcbab._0x4d149c,_0xf07f09,_0x3baa9b-0xc6,_0x3baa9b- -0x2bc);}this[_0x2cf81b(-0x184,-0x188,-0x1e7,-_0x593023._0x43b0be)]=_0x208beb,_0x30e437[_0x2cf81b(-0x26c,-0x1d2,-_0x593023._0x4ea812,-_0x593023._0x2278d8)]===!![]&&(this[_0x2cf81b(-0x239,-_0x593023._0x283946,-_0x593023._0x2b666e,-_0x593023._0x4e62e8)]=[],this[_0x5376ba(-0x1c,-0x5a,_0x593023._0xb88cc9,-_0x593023._0x5b12f8)]=0x0);}[_0x1f4b8d(-0x1e5,-0x192,-0x18d,-0x190)](_0x35d23b){const _0x3370c0={_0xde77b7:0x47c,_0x4944e3:0x4fd},_0x492485={_0x4fd846:0x687,_0x38f3c1:0x102};function _0x4cd88b(_0xec5282,_0x1e5014,_0x24a2d7,_0x53e52e){return _0x1f4b8d(_0x24a2d7,_0x1e5014-0xc3,_0x53e52e-_0x492485._0x4fd846,_0x53e52e-_0x492485._0x38f3c1);}this[_0x4cd88b(_0x3370c0._0xde77b7,_0x3370c0._0x4944e3,0x50d,0x4cb)]=_0x35d23b;}[_0x1f4b8d(-0x24b,-0x232,-0x23f,-0x1fe)](_0x34be40){const _0x3a0395={_0x43aafa:0x26};function _0xb14e07(_0x516e52,_0x3fc7ce,_0x447a3a,_0x196b1e){return _0x1f4b8d(_0x516e52,_0x3fc7ce-0x48,_0x196b1e-0x1e1,_0x196b1e-0x122);}this[_0xb14e07(-_0x3a0395._0x43aafa,0x66,0x22,0x13)]['chatModel']=_0x34be40;}async[_0x1f4b8d(-0x125,-0x180,-0x171,-0x12a)](_0x34d90f=this[_0x1f4b8d(-0x1c8,-0x19f,-0x1c8,-0x18b)],_0x5a0f34={}){const _0x15e2ce={_0x3a657c:0x31a,_0xc277f0:0x3a7,_0x5202e4:0x3c9,_0x4b5ea6:0x443,_0x28a07d:0x8a,_0x523941:0xa0,_0x112c4e:0x66,_0x47418b:0xd8,_0x593b82:0x3d0,_0x56c1df:0x3da,_0x31f3ea:0x43d,_0x14879e:0x107,_0x32c671:0x10d,_0x550592:0x3ec,_0x49c4d6:0x43a,_0x399adb:0xb0,_0x3f2390:0xa9,_0x52b760:0xca,_0x27fc4b:0x151,_0x5f4d6b:0xa3},_0xb46f86={_0x219ebc:0x593,_0x770e05:0x1ce},_0x140eed={_0x2037e9:0x13a};if(!_0x34d90f)throw new Error(_0x55d8f4(0x32b,_0x15e2ce._0x3a657c,0x363,0x38b));this['turnIndex']+=0x1;function _0x8c843f(_0x4d4077,_0x3fa3ed,_0x46f49c,_0x4b79e9){return _0x1f4b8d(_0x4b79e9,_0x3fa3ed-_0x140eed._0x2037e9,_0x4d4077-0x2c0,_0x4b79e9-0x21);}function _0x55d8f4(_0x5e58aa,_0xe334bc,_0xf9ec48,_0xf3eca7){return _0x1f4b8d(_0xe334bc,_0xe334bc-0x177,_0xf9ec48-_0xb46f86._0x219ebc,_0xf3eca7-_0xb46f86._0x770e05);}const _0x509434=_0x5a0f34[_0x55d8f4(_0x15e2ce._0xc277f0,0x420,0x3ce,_0x15e2ce._0x5202e4)];try{const _0x4c5941=await runTurn({'sessionId':this[_0x55d8f4(0x42d,_0x15e2ce._0x4b5ea6,0x3d7,0x3a1)],'turnId':createTurnId(this[_0x8c843f(_0x15e2ce._0x28a07d,0xca,0x5e,0x47)]),'streaming':_0x5a0f34['streaming'],'signal':_0x5a0f34['signal'],'system':this[_0x8c843f(_0x15e2ce._0x523941,_0x15e2ce._0x112c4e,0x6e,_0x15e2ce._0x47418b)],'messages':this['messages'],'message':normalizeUserInput(_0x34d90f),..._0x509434?{'drainSteering':async()=>(await _0x509434())[_0x8c843f(0x119,0x169,0x13b,0xee)](normalizeUserInput)}:{}},this['deps']);return this[_0x55d8f4(_0x15e2ce._0x593b82,0x397,_0x15e2ce._0x56c1df,_0x15e2ce._0x31f3ea)]=_0x4c5941['state'][_0x8c843f(_0x15e2ce._0x14879e,0x10a,0x10c,_0x15e2ce._0x32c671)][_0x55d8f4(0x436,0x399,_0x15e2ce._0x550592,_0x15e2ce._0x49c4d6)](normalizeMessage),_0x4c5941;}catch(_0x19f2b2){if(_0x19f2b2 instanceof TurnFailedError){this[_0x8c843f(0x107,0x160,_0x15e2ce._0x14879e,0xe2)]=synthesizeMissingToolResults(_0x19f2b2['state'][_0x8c843f(_0x15e2ce._0x14879e,0xc2,_0x15e2ce._0x399adb,_0x15e2ce._0x3f2390)][_0x8c843f(0x119,_0x15e2ce._0x52b760,_0x15e2ce._0x27fc4b,0x153)](normalizeMessage));throw _0x19f2b2[_0x8c843f(_0x15e2ce._0x5f4d6b,0xfb,0x44,0xd4)];}throw _0x19f2b2;}}};export{normalizeToolOutputValue,createToolOutput,ToolExecutionError,defineTool,resolveToolPermissionClass,ToolRegistry,validateToolInput,deriveFinalToolOutput,createInternalToolRuntime,createExtensionRegistry,createAgentMetrics,runTurn,Agent};