@nuvin/agent-core 0.0.0-rc.7 → 0.0.0-rc.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/VERSION CHANGED
@@ -1,4 +1,4 @@
1
1
  {
2
- "version": "0.0.0-rc.7",
3
- "commit": "df565a1"
2
+ "version": "0.0.0-rc.8",
3
+ "commit": "76ab606"
4
4
  }
@@ -1,5 +1,5 @@
1
- import { A as AgentEvent, C as ChatRequest, R as RunTurnDeps, M as Message, a as AgentOptions, b as AgentInput, c as AgentSendOptions, T as TurnResult, E as ExtensionRegistry, d as TurnInput } from '../types-Dpf5wjPw.js';
2
- export { e as TurnState } from '../types-Dpf5wjPw.js';
1
+ import { A as AgentEvent, C as ChatRequest, R as RunTurnDeps, M as Message, a as AgentOptions, b as AgentInput, c as AgentSendOptions, T as TurnResult, E as EngineChatModel, d as ExtensionRegistry, e as TurnInput } from '../types-mpqTRf_e.js';
2
+ export { f as TurnState } from '../types-mpqTRf_e.js';
3
3
 
4
4
  type AgentMetricsSnapshot = {
5
5
  totalTokens: number;
@@ -54,8 +54,15 @@ declare class Agent {
54
54
  send(input?: AgentInput | undefined, options?: AgentSendOptions): Promise<TurnResult>;
55
55
  }
56
56
 
57
+ declare const SUMMARY_SYSTEM_PROMPT = "You are a session-continuity summarizer for a CLI coding assistant. The conversation you are summarizing is an in-progress coding session that was interrupted because the context window is full. Your summary will be injected into a fresh session so the assistant can resume work without losing progress.\n\nProduce a structured summary using the following sections. Omit any section that has no relevant content.\n\n### Session Goal\nState the user's original request or objective in 1-2 sentences.\n\n### Work Completed\nList what has already been done, with specifics:\n- Files created, modified, or deleted (include paths)\n- Key implementation decisions made and their rationale\n- Commands run and their outcomes (pass/fail)\n- Tests written or executed and their results\n\n### Current State\nDescribe where things stand right now:\n- What was the assistant doing when the session ended?\n- Any in-progress file edits or partially completed steps\n- Error messages, failing tests, or blockers encountered\n- The current branch, working directory, or environment state if mentioned\n\n### Remaining Work\nList what still needs to be done to complete the original goal:\n- Specific next steps, in order if sequence matters\n- Known issues or edge cases still unaddressed\n- Any pending user decisions or questions that were unanswered\n\n### Key Context\nPreserve critical details that would be expensive to re-derive:\n- Architecture or design patterns being followed\n- Important variable names, function signatures, or API shapes\n- File paths and line numbers referenced repeatedly\n- Constraints or requirements the user specified\n- Todo list items and their status (pending/in_progress/completed)\n\nRules:\n- Be precise and specific. Use exact file paths, function names, and error messages \u2014 not vague references.\n- Do NOT include conversational pleasantries, repeated back-and-forth, or exploratory dead ends that were abandoned.\n- Do NOT summarize tool calls verbatim. Capture their outcomes and decisions, not the mechanics.\n- Keep the total summary under 1500 tokens. Prioritize actionable state over narrative.\n- Write for a coding agent that will read this summary and immediately resume work, not for a human reader.";
58
+ declare const SUMMARY_MESSAGE_PREFIX = "Previous conversation summary:";
59
+ declare function summarizeMessages(messages: Message[], chatModel: EngineChatModel, options?: {
60
+ signal?: AbortSignal;
61
+ }): Promise<string>;
62
+ declare function buildSummaryMessage(summary: string): Message;
63
+
57
64
  declare function createExtensionRegistry(): ExtensionRegistry;
58
65
 
59
66
  declare function runTurn(input: TurnInput, deps: RunTurnDeps): Promise<TurnResult>;
60
67
 
61
- export { Agent, AgentInput, type AgentMetrics, type AgentMetricsChangeHandler, type AgentMetricsOptions, type AgentMetricsSnapshot, AgentOptions, AgentSendOptions, ExtensionRegistry, RunTurnDeps, TurnInput, TurnResult, createAgentMetrics, createExtensionRegistry, runTurn };
68
+ export { Agent, AgentInput, type AgentMetrics, type AgentMetricsChangeHandler, type AgentMetricsOptions, type AgentMetricsSnapshot, AgentOptions, AgentSendOptions, ExtensionRegistry, RunTurnDeps, SUMMARY_MESSAGE_PREFIX, SUMMARY_SYSTEM_PROMPT, TurnInput, TurnResult, buildSummaryMessage, createAgentMetrics, createExtensionRegistry, runTurn, summarizeMessages };
@@ -1 +1 @@
1
- (function(_0x41b94a,_0x35ab58){var _0x3a1886={_0x228ae4:0x2a4,_0xd1da59:0x2a4,_0x274473:0x2a0,_0x38f81b:0x43e,_0x999982:0x43a,_0x6a2f6:0x440,_0x35b47b:0x445,_0xd7b04f:0x444,_0x115f36:0x29c,_0x3fb8b5:0x29d,_0x2c1e9a:0x2a1,_0xf0b8f6:0x2a1,_0x359f63:0x2a3,_0x173346:0x29a,_0x5f1a38:0x29d,_0x30933a:0x29d,_0x3b6bee:0x29a,_0x1e74cc:0x29f,_0x190757:0x438,_0x6d0f0d:0x439,_0x39186b:0x434},_0x4f60f3={_0x590e31:0x30b},_0x2e87ee={_0x531f63:0x3d1};function _0x56ab7e(_0x51bc8f,_0x19142d,_0x2d12ea,_0x2a6391){return _0x3f6f(_0x2a6391- -_0x2e87ee._0x531f63,_0x19142d);}function _0x261213(_0x59f9d3,_0x5f3600,_0x198739,_0x13b785){return _0x3f6f(_0x59f9d3-_0x4f60f3._0x590e31,_0x13b785);}var _0x37af2e=_0x41b94a();while(!![]){try{var _0x19d5d2=parseInt(_0x56ab7e(-0x2a5,-_0x3a1886._0x228ae4,-_0x3a1886._0xd1da59,-0x2a2))/0x1+parseInt(_0x56ab7e(-0x29f,-0x29e,-0x2a4,-_0x3a1886._0x274473))/0x2+parseInt(_0x261213(_0x3a1886._0x38f81b,_0x3a1886._0x38f81b,0x43c,_0x3a1886._0x999982))/0x3*(parseInt(_0x261213(0x441,_0x3a1886._0x6a2f6,_0x3a1886._0x35b47b,_0x3a1886._0xd7b04f))/0x4)+parseInt(_0x56ab7e(-_0x3a1886._0x115f36,-_0x3a1886._0x3fb8b5,-_0x3a1886._0x3fb8b5,-_0x3a1886._0x2c1e9a))/0x5*(-parseInt(_0x56ab7e(-0x2a7,-0x2a2,-_0x3a1886._0xf0b8f6,-_0x3a1886._0x359f63))/0x6)+parseInt(_0x56ab7e(-0x29d,-0x29d,-_0x3a1886._0x274473,-0x29d))/0x7+parseInt(_0x56ab7e(-_0x3a1886._0x173346,-_0x3a1886._0x5f1a38,-0x297,-0x29c))/0x8+-parseInt(_0x56ab7e(-0x29e,-_0x3a1886._0x30933a,-_0x3a1886._0x3b6bee,-_0x3a1886._0x1e74cc))/0x9*(parseInt(_0x261213(_0x3a1886._0x190757,0x43c,_0x3a1886._0x6d0f0d,_0x3a1886._0x39186b))/0xa);if(_0x19d5d2===_0x35ab58)break;else _0x37af2e['push'](_0x37af2e['shift']());}catch(_0x2ae5db){_0x37af2e['push'](_0x37af2e['shift']());}}}(_0x334e,0x9f470));function _0x3f6f(_0x4da192,_0x56d291){_0x4da192=_0x4da192-0x12d;var _0x334e8a=_0x334e();var _0x3f6f0d=_0x334e8a[_0x4da192];if(_0x3f6f['fnXEiA']===undefined){var _0x15cbd8=function(_0x49830e){var _0x59a005='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';var _0x3a89c1='',_0x52d892='';for(var _0x40e37c=0x0,_0x388b34,_0x195627,_0x5e2c8b=0x0;_0x195627=_0x49830e['charAt'](_0x5e2c8b++);~_0x195627&&(_0x388b34=_0x40e37c%0x4?_0x388b34*0x40+_0x195627:_0x195627,_0x40e37c++%0x4)?_0x3a89c1+=String['fromCharCode'](0xff&_0x388b34>>(-0x2*_0x40e37c&0x6)):0x0){_0x195627=_0x59a005['indexOf'](_0x195627);}for(var _0x39c3ad=0x0,_0x32d691=_0x3a89c1['length'];_0x39c3ad<_0x32d691;_0x39c3ad++){_0x52d892+='%'+('00'+_0x3a89c1['charCodeAt'](_0x39c3ad)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x52d892);};_0x3f6f['wQfdwb']=_0x15cbd8,_0x3f6f['SmppSZ']={},_0x3f6f['fnXEiA']=!![];}var _0x33815c=_0x334e8a[0x0],_0x185448=_0x4da192+_0x33815c,_0xf9b3d8=_0x3f6f['SmppSZ'][_0x185448];return!_0xf9b3d8?(_0x3f6f0d=_0x3f6f['wQfdwb'](_0x3f6f0d),_0x3f6f['SmppSZ'][_0x185448]=_0x3f6f0d):_0x3f6f0d=_0xf9b3d8,_0x3f6f0d;}function _0x334e(){var _0x2b07b9=['mty2meDvCfvfyG','mZy3mde1mK90rgP5Aa','otyYmtm0zgrKuMvb','nuPlywvpyq','otqXndeWq1LvvuDO','mta2mJa5r3HyA0Pr','ovLesu55zW','odKWndK4n3D0uhDtwG','mJiWntKYogjHu2nQua','mZiZmte2ver6yMvr'];_0x334e=function(){return _0x2b07b9;};return _0x334e();}import{Agent,createAgentMetrics,createExtensionRegistry,runTurn}from'../chunk-KVFXQ7HW.js';import'../chunk-G2FR4UGO.js';import'../chunk-X7VAACWY.js';export{Agent,createAgentMetrics,createExtensionRegistry,runTurn};
1
+ function _0xff84(_0x120768,_0x1058cb){_0x120768=_0x120768-0xf7;const _0x3be42f=_0x3be4();let _0xff841d=_0x3be42f[_0x120768];if(_0xff84['Cwbrby']===undefined){var _0x5eae84=function(_0x40dbfc){const _0x2409d8='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x11832b='',_0x3abad5='';for(let _0x5ed264=0x0,_0x2fe64f,_0xf1aa89,_0x55187f=0x0;_0xf1aa89=_0x40dbfc['charAt'](_0x55187f++);~_0xf1aa89&&(_0x2fe64f=_0x5ed264%0x4?_0x2fe64f*0x40+_0xf1aa89:_0xf1aa89,_0x5ed264++%0x4)?_0x11832b+=String['fromCharCode'](0xff&_0x2fe64f>>(-0x2*_0x5ed264&0x6)):0x0){_0xf1aa89=_0x2409d8['indexOf'](_0xf1aa89);}for(let _0x387aa2=0x0,_0x2828f9=_0x11832b['length'];_0x387aa2<_0x2828f9;_0x387aa2++){_0x3abad5+='%'+('00'+_0x11832b['charCodeAt'](_0x387aa2)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x3abad5);};_0xff84['icrnZW']=_0x5eae84,_0xff84['EJOihB']={},_0xff84['Cwbrby']=!![];}const _0x4c6a6f=_0x3be42f[0x0],_0x2ac901=_0x120768+_0x4c6a6f,_0x3acf03=_0xff84['EJOihB'][_0x2ac901];return!_0x3acf03?(_0xff841d=_0xff84['icrnZW'](_0xff841d),_0xff84['EJOihB'][_0x2ac901]=_0xff841d):_0xff841d=_0x3acf03,_0xff841d;}(function(_0x232ae4,_0x4d897d){const _0x2ca679={_0x3bf866:0x2d5,_0x11cdca:0x2eb,_0x437340:0x2e0,_0x2af085:0xd3,_0xfc3476:0xe9,_0x3934c7:0x2e4,_0x5608a1:0x2ef,_0x21aaff:0xdd,_0x3dfe1a:0xe4,_0x299c9:0x2ea,_0x3f1ceb:0x2e2,_0x52d21b:0xe0,_0x4ef787:0xec,_0x50b7c0:0xe8,_0x51ed24:0xe6,_0x349840:0xec,_0x1bab88:0xe5,_0x1fa1cb:0xe6,_0x4b4a6b:0xfa},_0x3daf7d={_0x259242:0x1ed};function _0x1b622c(_0x171d23,_0x54d738,_0x49d0d2,_0x45cc83){return _0xff84(_0x49d0d2- -_0x3daf7d._0x259242,_0x54d738);}function _0x5a7864(_0x2383bf,_0x220a07,_0x17f9a8,_0x48200c){return _0xff84(_0x220a07-0x1d8,_0x2383bf);}const _0x4158cf=_0x232ae4();while(!![]){try{const _0xdd274e=-parseInt(_0x5a7864(0x2dd,0x2ea,0x2db,0x2f5))/0x1*(parseInt(_0x5a7864(_0x2ca679._0x3bf866,0x2e3,_0x2ca679._0x11cdca,_0x2ca679._0x437340))/0x2)+parseInt(_0x1b622c(-_0x2ca679._0x2af085,-0xe5,-0xdd,-_0x2ca679._0xfc3476))/0x3*(-parseInt(_0x5a7864(0x2e1,0x2de,_0x2ca679._0x437340,0x2dc))/0x4)+parseInt(_0x5a7864(0x2d5,_0x2ca679._0x3934c7,0x2ed,_0x2ca679._0x5608a1))/0x5*(parseInt(_0x1b622c(-0xdf,-_0x2ca679._0x21aaff,-_0x2ca679._0x3dfe1a,-0xd9))/0x6)+-parseInt(_0x5a7864(_0x2ca679._0x299c9,_0x2ca679._0x3f1ceb,0x2d5,0x2d6))/0x7*(parseInt(_0x1b622c(-0xe9,-_0x2ca679._0x52d21b,-0xe0,-_0x2ca679._0x4ef787))/0x8)+parseInt(_0x1b622c(-_0x2ca679._0x50b7c0,-_0x2ca679._0xfc3476,-0xe5,-0xe5))/0x9+-parseInt(_0x1b622c(-0xe9,-_0x2ca679._0x51ed24,-_0x2ca679._0x349840,-0xe3))/0xa+parseInt(_0x1b622c(-_0x2ca679._0x1bab88,-_0x2ca679._0x1fa1cb,-0xf0,-_0x2ca679._0x4b4a6b))/0xb;if(_0xdd274e===_0x4d897d)break;else _0x4158cf['push'](_0x4158cf['shift']());}catch(_0xfba0ee){_0x4158cf['push'](_0x4158cf['shift']());}}}(_0x3be4,0xe9468));import{Agent,createAgentMetrics,createExtensionRegistry,runTurn}from'../chunk-KVFXQ7HW.js';import{getTextFromMessage}from'../chunk-G2FR4UGO.js';import'../chunk-X7VAACWY.js';function _0x9f335a(_0x1900d7,_0x165a54,_0x353673,_0x3d2650){const _0x49e3ea={_0x37af38:0x322};return _0xff84(_0x353673-_0x49e3ea._0x37af38,_0x165a54);}function roleLabel(_0x11832b){const _0x2eddf0={_0x1fd267:0xeb,_0x39b8b6:0xf7,_0x53aef6:0xec,_0x45e721:0xf1,_0x28ad4:0x106,_0x118ca8:0xf6,_0x1e8c8a:0x103,_0x4fca16:0x50},_0xed2639={_0x1f20a7:0x1ff};function _0x10e4a3(_0x379fdf,_0x4c2a1a,_0x254920,_0x99c3e1){return _0xff84(_0x99c3e1- -_0xed2639._0x1f20a7,_0x254920);}if(_0x11832b==='user')return'User';if(_0x11832b===_0x10e4a3(-_0x2eddf0._0x1fd267,-_0x2eddf0._0x39b8b6,-_0x2eddf0._0x53aef6,-_0x2eddf0._0x45e721))return _0x10e4a3(-_0x2eddf0._0x28ad4,-0xfe,-_0x2eddf0._0x118ca8,-_0x2eddf0._0x1e8c8a);function _0x65b42d(_0x20c1ef,_0x692686,_0x22b64d,_0x455136){return _0xff84(_0x20c1ef- -0xb6,_0x22b64d);}return _0x65b42d(0x49,0x46,_0x2eddf0._0x4fca16,0x4c);}function _0x317fc9(_0x55c0e1,_0x1ea22b,_0x11721c,_0x10e359){return _0xff84(_0x10e359- -0xb6,_0x55c0e1);}function messagesToText(_0x3abad5){const _0x4c28a5={_0x4004f6:0x2b1,_0x17c013:0x2a7,_0x2e128e:0x265,_0xae6be2:0x25b,_0x1b3419:0x271,_0xb49307:0x2b9,_0x1ec87e:0x2b0},_0x5a815c={_0x221f40:0x25,_0x589987:0x24,_0x42f3f6:0x30,_0x1266b2:0x40a,_0x448340:0x3f5},_0x3a7bdf={_0x3dfcfb:0x69d},_0x13a464={_0x4de18b:0x157};function _0x55cdfe(_0x354f89,_0x265e01,_0x2206b7,_0x5a801c){return _0xff84(_0x354f89-_0x13a464._0x4de18b,_0x265e01);}function _0x597b58(_0x2e2336,_0x334c40,_0x3e241d,_0x1513e3){return _0xff84(_0x1513e3- -0x3a7,_0x3e241d);}return _0x3abad5[_0x597b58(-_0x4c28a5._0x4004f6,-0x2b6,-_0x4c28a5._0x17c013,-0x2ad)](_0x5ed264=>{const _0x1dcb10={_0x57d06e:0x1c6},_0x2fe64f=getTextFromMessage(_0x5ed264)[_0x345a91(0x3b,_0x5a815c._0x221f40,_0x5a815c._0x589987,_0x5a815c._0x42f3f6)]();function _0x298cea(_0x2b0008,_0x472cbb,_0x8e6a6a,_0x31cefc){return _0x597b58(_0x2b0008-0x27,_0x472cbb-0x6b,_0x8e6a6a,_0x31cefc-_0x3a7bdf._0x3dfcfb);}function _0x345a91(_0x462040,_0x10cc1c,_0x2c07eb,_0x2526e0){return _0x597b58(_0x462040-0x94,_0x10cc1c-_0x1dcb10._0x57d06e,_0x10cc1c,_0x2526e0-0x2d2);}return _0x2fe64f?roleLabel(_0x5ed264[_0x298cea(_0x5a815c._0x1266b2,_0x5a815c._0x448340,0x3fc,0x3fd)])+':\x20'+_0x2fe64f:'';})[_0x55cdfe(0x268,_0x4c28a5._0x2e128e,_0x4c28a5._0xae6be2,_0x4c28a5._0x1b3419)](_0xf1aa89=>_0xf1aa89[_0x597b58(-0x2b3,-0x2ab,-0x29f,-0x2a9)]>0x0)[_0x597b58(-_0x4c28a5._0xb49307,-0x2a5,-0x2a5,-_0x4c28a5._0x1ec87e)]('\x0a\x0a');}var SUMMARY_SYSTEM_PROMPT=_0x317fc9(0x46,0x4c,0x44,0x43),NO_HISTORY=_0x317fc9(0x4c,0x43,0x49,0x42),SUMMARY_MESSAGE_PREFIX=_0x317fc9(0x4a,0x5d,0x49,0x4e);async function summarizeMessages(_0x55187f,_0x387aa2,_0x2828f9={}){const _0x131c74={_0x2ba6e5:0x45f,_0x35dcdf:0x45,_0x2697cf:0x39,_0x55bb68:0x4e,_0x536365:0x3c,_0x28906f:0x37,_0x32d453:0x51,_0x65cd5f:0x45e,_0x1de474:0x45c,_0x22731f:0x45b,_0x66a564:0x2d,_0x3beb94:0x22,_0x37e4f5:0x2e,_0x44e194:0x35,_0x692229:0x27,_0x2b6a8f:0x464,_0x12a85a:0x459,_0x3eca0a:0x45f,_0x17b134:0x34,_0x3ec39f:0x26,_0x534cf9:0x3f,_0x4e543f:0x462},_0x16bdc5={_0x11e393:0x144,_0x37c917:0x18},_0x55f8e1={_0x4a6f6a:0x3f};if(_0x55187f[_0x12f33e(0x454,_0x131c74._0x2ba6e5,0x460,_0x131c74._0x2ba6e5)]===0x0)return NO_HISTORY;const _0x4af3c2=messagesToText(_0x55187f),_0x46b701={'model':_0x387aa2[_0x1337aa(_0x131c74._0x35dcdf,_0x131c74._0x2697cf,_0x131c74._0x55bb68,_0x131c74._0x536365)],'maxTokens':_0x387aa2[_0x1337aa(0x46,_0x131c74._0x28906f,0x53,_0x131c74._0x32d453)]??0x1000,'system':[{'type':_0x12f33e(_0x131c74._0x65cd5f,_0x131c74._0x1de474,0x458,_0x131c74._0x22731f),'text':SUMMARY_SYSTEM_PROMPT}],'messages':[{'role':'user','content':[{'type':_0x1337aa(_0x131c74._0x66a564,_0x131c74._0x3beb94,_0x131c74._0x37e4f5,0x21),'text':_0x4af3c2}]}],'tools':[],'metadata':{'sessionId':_0x1337aa(_0x131c74._0x44e194,_0x131c74._0x692229,0x31,0x3b),'turnId':_0x12f33e(0x45f,_0x131c74._0x2b6a8f,_0x131c74._0x12a85a,_0x131c74._0x3eca0a)}};function _0x12f33e(_0x13c84e,_0x224a7a,_0x266043,_0x37fc20){return _0x9f335a(_0x13c84e-0xc8,_0x13c84e,_0x224a7a-_0x55f8e1._0x4a6f6a,_0x37fc20-0x24);}const _0x2406a5=await _0x387aa2['complete'](_0x46b701,{'signal':_0x2828f9['signal']});function _0x1337aa(_0x493b37,_0xf8372,_0x512c06,_0x19bd53){return _0x317fc9(_0x19bd53,_0xf8372-_0x16bdc5._0x11e393,_0x512c06-0x20,_0x493b37- -_0x16bdc5._0x37c917);}return _0x2406a5[_0x1337aa(_0x131c74._0x17b134,_0x131c74._0x3ec39f,0x3d,0x43)][_0x1337aa(0x43,0x3f,_0x131c74._0x55bb68,_0x131c74._0x534cf9)](_0x174110=>_0x174110[_0x12f33e(0x46c,0x461,0x46e,0x470)]===_0x1337aa(0x2d,0x2e,0x29,0x39))[_0x12f33e(0x45a,0x45b,_0x131c74._0x4e543f,0x458)](_0x259a87=>_0x259a87[_0x12f33e(0x46a,0x45c,0x46b,0x45e)])['join']('')['trim']();}function _0x3be4(){const _0x4b64f9=['tM8Gy29UDMvYC2f0Aw9UigHPC3rVCNKGDg8GC3vTBwfYAxPLlG','ww91igfYzsbHihnLC3nPB24Ty29UDgLUDwL0EsbZDw1TyxjPEMvYigzVCIbHienmssbJB2rPBMCGyxnZAxn0yw50lIbuAguGy29UDMvYC2f0Aw9UihLVDsbHCMuGC3vTBwfYAxPPBMCGAxmGyw4GAw4TChjVz3jLC3mGy29KAw5NihnLC3nPB24GDgHHDcb3yxmGAw50zxjYDxb0zwqGyMvJyxvZzsb0AguGy29UDgv4Dcb3Aw5KB3CGAxmGzNvSBc4Gww91CIbZDw1Tyxj5ihDPBgWGyMuGAw5Qzwn0zwqGAw50BYbHigzYzxnOihnLC3nPB24GC28GDgHLigfZC2LZDgfUDcbJyw4GCMvZDw1LihDVCMSGD2L0Ag91DcbSB3nPBMCGChjVz3jLC3mUcGPqCM9KDwnLigeGC3rYDwn0DxjLzcbZDw1Tyxj5ihvZAw5NihrOzsbMB2XSB3DPBMCGC2vJDgLVBNmUie9TAxqGyw55ihnLy3rPB24GDgHHDcbOyxmGBM8GCMvSzxzHBNqGy29UDgvUDc4kcImJiYbtzxnZAw9UieDVywWku3rHDguGDgHLihvZzxiNCYbVCMLNAw5HBcbYzxf1zxn0ig9Yig9IAMvJDgL2zsbPBIaXltiGC2vUDgvUy2vZlGOkiYmJifDVCMSGq29TCgXLDgvKcKXPC3qGD2HHDcbOyxmGywXYzwfKEsbIzwvUigrVBMuSihDPDgGGC3bLy2LMAwnZoGOTiezPBgvZignYzwf0zwqSig1VzgLMAwvKlcbVCIbKzwXLDgvKicHPBMnSDwrLihbHDgHZkqOTieTLEsbPBxbSzw1LBNrHDgLVBIbKzwnPC2LVBNmGBwfKzsbHBMqGDgHLAxiGCMf0Aw9UywXLcI0Gq29TBwfUzhmGCNvUigfUzcb0AgvPCIbVDxrJB21LCYaOCgfZCY9MywLSkqOTifrLC3rZihDYAxr0zw4GB3iGzxHLy3v0zwqGyw5KihrOzwLYihjLC3vSDhmkcImJiYbdDxjYzw50ifn0yxrLcKrLC2nYAwjLihDOzxjLihrOAw5NCYbZDgfUzcbYAwDODcbUB3C6cI0Gv2HHDcb3yxmGDgHLigfZC2LZDgfUDcbKB2LUzYb3AgvUihrOzsbZzxnZAw9UigvUzgvKpWOTiefUEsbPBI1WCM9NCMvZCYbMAwXLigvKAxrZig9YihbHCNrPywXSEsbJB21WBgv0zwqGC3rLChmklsbfCNjVCIbTzxnZywDLCYWGzMfPBgLUzYb0zxn0CYWGB3iGyMXVy2TLCNmGzw5JB3vUDgvYzwqklsbuAguGy3vYCMvUDcbICMfUy2GSihDVCMTPBMCGzgLYzwn0B3j5lcbVCIbLBNzPCM9UBwvUDcbZDgf0zsbPzIbTzw50Aw9UzwqkcImJiYbszw1HAw5PBMCGv29YAWPmAxn0ihDOyxqGC3rPBgWGBMvLzhmGDg8GyMuGzg9Uzsb0BYbJB21WBgv0zsb0AguGB3jPz2LUywWGz29HBdOklsbtCgvJAwzPyYbUzxH0ihn0zxbZlcbPBIbVCMrLCIbPzIbZzxf1zw5JzsbTyxr0zxjZcI0Gs25VD24GAxnZDwvZig9YigvKz2uGy2fZzxmGC3rPBgWGDw5HzgrYzxnZzwqklsbbBNKGCgvUzgLUzYb1C2vYigrLy2LZAw9UCYbVCIbXDwvZDgLVBNmGDgHHDcb3zxjLihvUyw5ZD2vYzwqkcImJiYblzxKGq29UDgv4DaPqCMvZzxj2zsbJCML0AwnHBcbKzxrHAwXZihrOyxqGD291BgqGyMuGzxHWzw5ZAxzLihrVihjLlwrLCML2ztOklsbbCMnOAxrLy3r1CMuGB3iGzgvZAwDUihbHDhrLCM5ZigjLAw5NigzVBgXVD2vKcI0Gsw1WB3j0yw50ihzHCMLHyMXLig5HBwvZlcbMDw5JDgLVBIbZAwDUyxr1CMvZlcbVCIbbueKGC2HHCgvZcI0GrMLSzsbWyxrOCYbHBMqGBgLUzsbUDw1IzxjZihjLzMvYzw5JzwqGCMvWzwf0zwrSEqOTienVBNn0CMfPBNrZig9YihjLCxvPCMvTzw50CYb0AguGDxnLCIbZCgvJAwzPzwqklsbuB2rVigXPC3qGAxrLBxmGyw5KihrOzwLYihn0yxr1CYaOCgvUzgLUzY9PBL9WCM9NCMvZCY9JB21WBgv0zwqPcGPsDwXLCZOklsbczsbWCMvJAxnLigfUzcbZCgvJAwzPyY4GvxnLigv4ywn0igzPBguGCgf0AhmSigz1BMn0Aw9Uig5HBwvZlcbHBMqGzxjYB3iGBwvZC2fNzxmG4Ocuig5VDcb2ywD1zsbYzwzLCMvUy2vZlGOTierVie5pvcbPBMnSDwrLignVBNzLCNnHDgLVBMfSihbSzwfZyw50CMLLCYWGCMvWzwf0zwqGyMfJAY1HBMqTzM9YDgGSig9Yigv4CgXVCMf0B3j5igrLywqGzw5KCYb0Agf0ihDLCMuGywjHBMrVBMvKlGOTierVie5pvcbZDw1TyxjPEMuGDg9VBcbJywXSCYb2zxjIyxrPBs4Gq2fWDhvYzsb0AgvPCIbVDxrJB21LCYbHBMqGzgvJAxnPB25ZlcbUB3qGDgHLig1Ly2HHBMLJCY4klsblzwvWihrOzsb0B3rHBcbZDw1Tyxj5ihvUzgvYide1mdaGDg9Rzw5ZlIbqCMLVCML0AxPLigfJDgLVBMfIBguGC3rHDguGB3zLCIbUyxjYyxrPDMuUcI0Gv3jPDguGzM9YigeGy29KAw5NigfNzw50ihrOyxqGD2LSBcbYzwfKihrOAxmGC3vTBwfYEsbHBMqGAw1TzwrPyxrLBhKGCMvZDw1LihDVCMSSig5VDcbMB3iGysbODw1HBIbYzwfKzxiU','BwfW','Dgv4Da','qxnZAxn0yw50','ndGZndqWnJviD2fxrw8','BgvUz3rO','vg9VBa','DhLWzq','mtC4nta3mfjhq0flrW','y29UDgvUDa','C3vTBwfYEq','uhjLDMLVDxmGy29UDMvYC2f0Aw9Uihn1Bw1HCNK6','DhjPBq','mtG4mJi4mgr3quLMAW','CM9Szq','mta2otmXnJfts0PMt1G','mtmYodrNAgLStva','n1H4vND3zG','mtCXndiYDM5WzM5r','mtKXnvDLqvDMra','mtiYmZi2ndHWC05IsLO','yxnZAxn0yw50','DxnLCG','mtjUs3bOCMK','zMLSDgvY','mJj3ExbdDve','Bw9KzwW','Bwf4vg9Rzw5Z','AM9PBG'];_0x3be4=function(){return _0x4b64f9;};return _0x3be4();}function buildSummaryMessage(_0x3f66ef){const _0x333ed3={_0x23b149:0x2fe,_0x3262b5:0x2f3,_0x10804a:0x2f2,_0x3bc500:0x2ea,_0x4d1d43:0x2e9,_0x1ba330:0x2df},_0xc6572c={_0x3e4b9c:0x485},_0x3480e7={_0x2e90b7:0x6e};function _0x531339(_0x538a69,_0x5a4710,_0x5064c8,_0x371a04){return _0x9f335a(_0x538a69-0xb8,_0x5a4710,_0x538a69- -0x133,_0x371a04-_0x3480e7._0x2e90b7);}function _0x2e7ac4(_0x49183f,_0x449404,_0x16aa56,_0x4229f3){return _0x317fc9(_0x4229f3,_0x449404-0x11e,_0x16aa56-0x14a,_0x49183f-_0xc6572c._0x3e4b9c);}return{'role':_0x531339(_0x333ed3._0x23b149,_0x333ed3._0x3262b5,0x303,_0x333ed3._0x10804a),'content':[{'type':_0x531339(_0x333ed3._0x3bc500,_0x333ed3._0x4d1d43,_0x333ed3._0x1ba330,0x2f8),'text':SUMMARY_MESSAGE_PREFIX+'\x0a\x0a'+_0x3f66ef}]};}export{Agent,SUMMARY_MESSAGE_PREFIX,SUMMARY_SYSTEM_PROMPT,buildSummaryMessage,createAgentMetrics,createExtensionRegistry,runTurn,summarizeMessages};
@@ -1 +1 @@
1
- (function(_0x3af254,_0x1bbd38){const _0x1fb0f0={_0x420635:0x197,_0xbb1b8a:0x1ac,_0x19cbe2:0x7b,_0x405821:0x7a,_0x1ac82b:0x90,_0x23b6e5:0x78,_0x5829e0:0x79,_0x27e364:0x6b,_0x26fb76:0x184,_0x2ecfdf:0x194,_0x118cf3:0x196,_0x14d309:0x174,_0x2b3beb:0x198,_0x35d765:0x16f,_0x4bd42c:0x167,_0x2b2cd5:0x16e,_0x1914ea:0x18a,_0x2a901d:0x1a1,_0x1a7020:0x1a4,_0x274aac:0x18c,_0x364181:0x8d,_0xb8ec65:0xac,_0x2ce1d8:0xa2,_0x3af844:0x195,_0x55c584:0x17a};function _0x5e1b9b(_0x49771a,_0x20680d,_0x44a4a3,_0x5eb796){return _0x3161(_0x44a4a3- -0xc2,_0x49771a);}function _0x132001(_0x144ddc,_0x2f6e5a,_0x191866,_0x415ce3){return _0x3161(_0x415ce3- -0x2e3,_0x2f6e5a);}const _0x406612=_0x3af254();while(!![]){try{const _0x13d27e=parseInt(_0x132001(-0x171,-_0x1fb0f0._0x420635,-_0x1fb0f0._0xbb1b8a,-0x18f))/0x1*(-parseInt(_0x5e1b9b(_0x1fb0f0._0x19cbe2,0x66,_0x1fb0f0._0x405821,_0x1fb0f0._0x1ac82b))/0x2)+parseInt(_0x5e1b9b(_0x1fb0f0._0x23b6e5,0x78,0x89,_0x1fb0f0._0x5829e0))/0x3*(parseInt(_0x5e1b9b(0x8f,_0x1fb0f0._0x27e364,0x7e,0x69))/0x4)+-parseInt(_0x132001(-_0x1fb0f0._0x26fb76,-0x19d,-_0x1fb0f0._0x2ecfdf,-0x192))/0x5*(parseInt(_0x132001(-_0x1fb0f0._0x118cf3,-_0x1fb0f0._0x14d309,-_0x1fb0f0._0x2b3beb,-0x18d))/0x6)+parseInt(_0x5e1b9b(0x8d,0x8f,_0x1fb0f0._0x5829e0,0x84))/0x7+-parseInt(_0x132001(-0x15b,-_0x1fb0f0._0x35d765,-_0x1fb0f0._0x4bd42c,-_0x1fb0f0._0x2b2cd5))/0x8*(parseInt(_0x132001(-_0x1fb0f0._0x1914ea,-0x19f,-0x189,-_0x1fb0f0._0x2a901d))/0x9)+parseInt(_0x132001(-0x17b,-_0x1fb0f0._0x1a7020,-0x195,-_0x1fb0f0._0x274aac))/0xa*(-parseInt(_0x5e1b9b(0x8c,0x98,0xa1,0x87))/0xb)+-parseInt(_0x5e1b9b(_0x1fb0f0._0x364181,_0x1fb0f0._0xb8ec65,_0x1fb0f0._0x2ce1d8,0x96))/0xc*(-parseInt(_0x132001(-_0x1fb0f0._0x1914ea,-_0x1fb0f0._0x3af844,-0x197,-_0x1fb0f0._0x55c584))/0xd);if(_0x13d27e===_0x1bbd38)break;else _0x406612['push'](_0x406612['shift']());}catch(_0x2c5600){_0x406612['push'](_0x406612['shift']());}}}(_0x4a51,0x7a3c7));import{resolveOpenAiReasoningConfig}from'./chunk-NYZR4XKO.js';import{normalizeContent}from'./chunk-G2FR4UGO.js';function systemToInstructions(_0x18a9c3){const _0x1ae6fb={_0x4531a6:0xab,_0x3ac3ac:0x11b,_0x3fd3c8:0x120,_0x4925e2:0x103},_0x3bd503={_0x586e6c:0xa1};function _0x2f0e74(_0x38217d,_0x5d0b63,_0x3a16bb,_0x34c75a){return _0x3161(_0x5d0b63- -0x26a,_0x38217d);}function _0x4e9d56(_0x17cc84,_0x44e93b,_0x375135,_0x258f13){return _0x3161(_0x258f13- -_0x3bd503._0x586e6c,_0x44e93b);}return normalizeContent(_0x18a9c3)['filter'](_0xe00869=>_0xe00869['type']===_0x2f0e74(-0xec,-0x109,-0xf5,-0xf6))[_0x4e9d56(0xbb,0xca,0xc4,_0x1ae6fb._0x4531a6)](_0x5dc1ab=>_0x5dc1ab[_0x2f0e74(-0x125,-0x109,-0xeb,-0x110)])[_0x2f0e74(-0x12f,-_0x1ae6fb._0x3ac3ac,-_0x1ae6fb._0x3fd3c8,-_0x1ae6fb._0x4925e2)]('\x0a\x0a');}function _0x4a51(){const _0x341807=['BMfTzq','C3LZDgvT','yxnZAxn0yw50','C3vTBwfYEq','zgvZy3jPChrPB24','Dgv4Da','B3bLBMfPuMvZCg9UC2vZt3v0Chv0','mJjKA3vbqxC','mte0mZzfAfnUEMe','C291CMnL','DxnLCI12AxnPyMXL','AxnbCNjHEq','yxv0BW','odG3owLzC2fvyG','BgvUz3rO','DMLZAwjPBgL0Eq','B2jQzwn0','Aw5WDxrFC2nOzw1H','ChvZAa','zgf0yq','zNvUy3rPB24','o2jHC2u2ncW','C3rYAw5N','DhjPBq','ChjVDMLKzxjtDgf0zq','mta1mdG4ohvSyKXdqW','Aw5JBhvKzuvUy3j5ChrLzenVBNrLBNq','zgf0ytO','CMvHC29UAw5NlMvUy3j5ChrLzf9JB250zw50','nti2mdKWnLzOzLbyqq','mtC0vefnvgjI','CMvHC29UAw5N','y29UDgvUDa','Bw9KzwW','nergthjAsW','zwzMB3j0','owHQzgfzCq','CM9Szq','zMLSDgvY','A2v5CW','DhLWzq','sw1Hz2uGCMv0DxjUzwqGyNKGvMLLD0zPBguGzM9YihrVB2WGCMvZDwX0ia','Aw5WDxq','Aw5WDxrFDgv4Da','vg9VBcbYzxr1CM5LzcbPBwfNzsbJB250zw50lG','mtC4ndm2mwH2wMvczG','BwfW','Dg9VBf91C2vFAwq','C3bSAwnL','AM9PBG','Dg9VBf9Yzxn1Bhq','mJvsq3Durfm','Dg9VBf91C2u','zNvUy3rPB25Fy2fSBf9VDxrWDxq','mtaWmtLmv25kBNG','Aw5WDxrFAw1Hz2u','mZq4mJK0wfzmCejT','mtaXnJuZmgXyt3rZDW','Aw1Hz2u','Dg9VBhm','BwvZC2fNzxm','BwvKAwfFDhLWzq'];_0x4a51=function(){return _0x341807;};return _0x4a51();}function pushUserContentMessage(_0x23a093,_0x1a5ff6,_0x5ea4c){const _0x520b38={_0x516d98:0x2d0,_0x5b69eb:0x2e3},_0x2c8555={_0x1d5508:0x166};function _0x1987fd(_0x1d9ff0,_0x56addf,_0x5c378d,_0x3a8818){return _0x3161(_0x56addf-_0x2c8555._0x1d5508,_0x1d9ff0);}function _0x50112d(_0xc582ec,_0x39588a,_0x6a1936,_0x5f04f1){return _0x3161(_0xc582ec- -0x23a,_0x39588a);}if(_0x5ea4c[_0x1987fd(0x2ee,_0x520b38._0x516d98,_0x520b38._0x5b69eb,0x2de)]===0x0)return;_0x23a093[_0x50112d(-0xcc,-0xb7,-0xde,-0xd6)]({'type':'message','role':_0x1a5ff6,'content':_0x5ea4c});}function hasSerializableToolUse(_0x203656){const _0x47588f={_0x2acbde:0x536,_0x52715f:0x54d,_0x3c78b1:0x552,_0x3cd5e9:0x538,_0x413b9d:0x53b,_0x532906:0x559,_0x67dedc:0x55a,_0x867984:0x56f,_0x2c7e45:0x544,_0x153632:0x55a},_0x4182a6={_0x488d53:0x3dc},_0x35c345={_0x26f333:0x3e8};function _0x549ce8(_0x597cec,_0x4be82d,_0x172f4f,_0x5885a5){return _0x3161(_0x5885a5-_0x35c345._0x26f333,_0x597cec);}function _0x57b2e8(_0x58efa5,_0x4bfc24,_0x1ca639,_0xa0d5ec){return _0x3161(_0x4bfc24-_0x4182a6._0x488d53,_0x1ca639);}return _0x203656['id']['trim']()[_0x549ce8(_0x47588f._0x2acbde,0x54e,_0x47588f._0x52715f,_0x47588f._0x3c78b1)]>0x0&&_0x203656[_0x57b2e8(0x51c,_0x47588f._0x3cd5e9,_0x47588f._0x413b9d,0x532)][_0x549ce8(_0x47588f._0x532906,_0x47588f._0x67dedc,_0x47588f._0x867984,0x55b)]()[_0x57b2e8(_0x47588f._0x2c7e45,0x546,0x54e,_0x47588f._0x153632)]>0x0;}function hasSerializableToolResult(_0x124a89){const _0x3528f5={_0x2b37a0:0x15e,_0x5bb495:0x16d},_0x793819={_0x438fdf:0x6};function _0x13c058(_0x42e8a0,_0x2e75c9,_0x52f9b0,_0x52e4d1){return _0x3161(_0x52e4d1-_0x793819._0x438fdf,_0x2e75c9);}return _0x124a89['tool_use_id']['trim']()[_0x13c058(_0x3528f5._0x2b37a0,0x177,_0x3528f5._0x5bb495,0x170)]>0x0;}function isResponseInputObject(_0x13d1ce){const _0x5daad6={_0x15d1a6:0x1fb,_0x3f47d7:0x1e5,_0x532adb:0x68,_0x3fc9eb:0x6d,_0x41bff6:0x5b,_0x4ef4aa:0x6c};function _0x50ae9d(_0x41b7d5,_0x5d7c19,_0x3f6be6,_0x3f45c0){return _0x3161(_0x5d7c19- -0x1b3,_0x3f6be6);}function _0xc97d36(_0x2e4cde,_0x1849bc,_0xea8cff,_0x2ee3e2){return _0x3161(_0x1849bc- -0x365,_0x2ee3e2);}if(typeof _0x13d1ce!=='object'||_0x13d1ce===null||Array[_0xc97d36(-_0x5daad6._0x15d1a6,-0x1fe,-0x1e5,-_0x5daad6._0x3f47d7)](_0x13d1ce))return![];const _0x6424fc=_0x13d1ce;return typeof _0x6424fc[_0x50ae9d(-_0x5daad6._0x532adb,-_0x5daad6._0x3fc9eb,-_0x5daad6._0x41bff6,-_0x5daad6._0x4ef4aa)]==='string';}function isImageToolResultBlock(_0x2e9cd7){const _0x350209={_0x163758:0x367,_0x4fd23a:0x35f,_0x12a9a3:0x37a,_0x2c078f:0x370,_0x7b1c06:0x362,_0x696a62:0x359,_0x4e9b65:0x34f,_0x59a958:0x11b,_0x5e5075:0x341,_0x421d0f:0x342,_0x39033e:0x32e,_0x49edcc:0x134,_0x355fbc:0x10d,_0x448e2a:0x37d,_0x3a6638:0x371,_0x211ea9:0x360,_0x41e5db:0x347,_0x1e59db:0x366,_0x4f0c90:0x36a,_0x22f1e3:0x356,_0x539fd8:0x386,_0x174a42:0x13c},_0x2f5c06={_0x44f610:0x4a};if(typeof _0x2e9cd7!==_0x14c9d3(_0x350209._0x163758,_0x350209._0x4fd23a,_0x350209._0x12a9a3,_0x350209._0x2c078f)||_0x2e9cd7===null||Array[_0x14c9d3(_0x350209._0x7b1c06,_0x350209._0x696a62,0x371,0x343)](_0x2e9cd7))return![];const _0x52fdfd=_0x2e9cd7;function _0x46c18e(_0xe09cdf,_0x5ea781,_0xe69177,_0x538c8b){return _0x3161(_0xe09cdf- -_0x2f5c06._0x44f610,_0x538c8b);}function _0x14c9d3(_0x32063d,_0x450777,_0x1e82cf,_0x39185a){return _0x3161(_0x32063d-0x1fb,_0x39185a);}return _0x52fdfd['type']===_0x14c9d3(0x353,_0x350209._0x4e9b65,0x34b,0x368)&&_0x52fdfd[_0x46c18e(_0x350209._0x59a958,0x115,0x125,0x124)]?.[_0x14c9d3(_0x350209._0x5e5075,0x32b,_0x350209._0x421d0f,_0x350209._0x39033e)]==='base64'&&typeof _0x52fdfd[_0x46c18e(0x11b,_0x350209._0x49edcc,_0x350209._0x355fbc,0x12a)]['media_type']===_0x14c9d3(0x36d,_0x350209._0x448e2a,_0x350209._0x3a6638,0x37e)&&typeof _0x52fdfd[_0x14c9d3(_0x350209._0x211ea9,_0x350209._0x41e5db,_0x350209._0x1e59db,0x34a)][_0x14c9d3(_0x350209._0x4f0c90,_0x350209._0x22f1e3,_0x350209._0x539fd8,0x365)]===_0x46c18e(0x128,0x13b,0x10b,_0x350209._0x174a42);}function _0x3161(_0x43adf3,_0x177185){_0x43adf3=_0x43adf3-0x13b;const _0x4a51cc=_0x4a51();let _0x3161b6=_0x4a51cc[_0x43adf3];if(_0x3161['lFksqO']===undefined){var _0x5bd27e=function(_0x2620c3){const _0x9ba2d='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x18a9c3='',_0xe00869='';for(let _0x5dc1ab=0x0,_0x23a093,_0x1a5ff6,_0x5ea4c=0x0;_0x1a5ff6=_0x2620c3['charAt'](_0x5ea4c++);~_0x1a5ff6&&(_0x23a093=_0x5dc1ab%0x4?_0x23a093*0x40+_0x1a5ff6:_0x1a5ff6,_0x5dc1ab++%0x4)?_0x18a9c3+=String['fromCharCode'](0xff&_0x23a093>>(-0x2*_0x5dc1ab&0x6)):0x0){_0x1a5ff6=_0x9ba2d['indexOf'](_0x1a5ff6);}for(let _0x203656=0x0,_0x124a89=_0x18a9c3['length'];_0x203656<_0x124a89;_0x203656++){_0xe00869+='%'+('00'+_0x18a9c3['charCodeAt'](_0x203656)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0xe00869);};_0x3161['sVmTnt']=_0x5bd27e,_0x3161['zsCyRF']={},_0x3161['lFksqO']=!![];}const _0x25b8fc=_0x4a51cc[0x0],_0x3f0fb3=_0x43adf3+_0x25b8fc,_0xd95e6f=_0x3161['zsCyRF'][_0x3f0fb3];return!_0xd95e6f?(_0x3161b6=_0x3161['sVmTnt'](_0x3161b6),_0x3161['zsCyRF'][_0x3f0fb3]=_0x3161b6):_0x3161b6=_0xd95e6f,_0x3161b6;}function getToolResultText(_0x221775){const _0x4816ef={_0x478bc2:0x1d7,_0x5e5532:0x1f2,_0x4c4546:0x14a,_0x31f8d8:0x21e,_0x549f11:0x1e5,_0x4335f3:0x208,_0x3802cb:0x233},_0x40a1a6={_0x577ce8:0x50d},_0x4bc4ba={_0x59226d:0xb};if(typeof _0x221775===_0x927456(-0x206,-_0x4816ef._0x478bc2,-0x1ec,-_0x4816ef._0x5e5532))return _0x221775;function _0x54bfdb(_0x36b201,_0x5e7397,_0x581c28,_0x5cf004){return _0x3161(_0x581c28- -_0x4bc4ba._0x59226d,_0x5e7397);}const _0x5e0c81=_0x221775[_0x54bfdb(0x134,0x14a,0x139,_0x4816ef._0x4c4546)](_0x3e6ad6=>{const _0x33f9e8={_0x53db4f:0x70a};function _0x3d3dc0(_0x92a641,_0x1bdd6a,_0x5874df,_0x33a7b6){return _0x927456(_0x33a7b6,_0x1bdd6a-0x1ec,_0x5874df-_0x33f9e8._0x53db4f,_0x33a7b6-0xfe);}return typeof _0x3e6ad6==='object'&&_0x3e6ad6!==null&&_0x3e6ad6['type']===_0x3d3dc0(0x51a,0x50f,_0x40a1a6._0x577ce8,0x501);})[_0x927456(-0x1f8,-0x1f7,-0x212,-_0x4816ef._0x31f8d8)](_0x1cb003=>_0x1cb003[_0x927456(-0x1e5,-0x1f9,-0x1fd,-0x1f5)])['join']('\x0a\x0a')[_0x927456(-_0x4816ef._0x549f11,-0x1fc,-0x1eb,-_0x4816ef._0x4335f3)]();function _0x927456(_0x5e8d5a,_0x6c6a2e,_0x89a815,_0x319427){return _0x3161(_0x89a815- -0x35e,_0x5e8d5a);}return _0x5e0c81['length']>0x0?_0x5e0c81:_0x927456(-_0x4816ef._0x3802cb,-0x208,-0x214,-0x224);}function getToolResultImages(_0x4e719b){const _0x3f5e93={_0x2bfc0e:0x91},_0x1721b8={_0x65482e:0x99};function _0x553ad0(_0x4e7aeb,_0x425fe6,_0x5d490f,_0x7b6825){return _0x3161(_0x7b6825-0x3b1,_0x425fe6);}function _0x5a0f21(_0x5b7985,_0x490603,_0x4fc670,_0x2b951c){return _0x3161(_0x5b7985- -_0x1721b8._0x65482e,_0x2b951c);}return Array[_0x553ad0(0x528,0x51f,0x52a,0x518)](_0x4e719b)?_0x4e719b[_0x5a0f21(0xab,0xc1,_0x3f5e93._0x2bfc0e,0x9d)](isImageToolResultBlock):[];}function resolveReasoningVisibility(_0x3b4a5a){const _0x20414d={_0x1a5b39:0x143,_0x1502fe:0x142,_0x2201d9:0x1c2,_0x2215b4:0x1ac,_0x1ed36d:0x1a7,_0x22867e:0x1a6},_0x3b5a4a={_0x19f5f3:0x41};function _0x343376(_0x1509bc,_0x3db8f3,_0x2eefd7,_0x66f37d){return _0x3161(_0x2eefd7-_0x3b5a4a._0x19f5f3,_0x1509bc);}function _0x2d0d7e(_0x131316,_0x25b056,_0x3cedc8,_0x35370f){return _0x3161(_0x25b056- -0x29,_0x3cedc8);}return _0x3b4a5a['reasoning']?.[_0x2d0d7e(_0x20414d._0x1a5b39,_0x20414d._0x1502fe,_0x20414d._0x1502fe,0x12c)]??_0x343376(_0x20414d._0x2201d9,_0x20414d._0x2215b4,_0x20414d._0x1ed36d,_0x20414d._0x22867e);}function createOpenAiResponsesReasoning(_0x2cd550){const _0x24e5ef={_0x1ab57b:0x7,_0x2d1785:0x2f,_0x2f732c:0x16,_0x4aed99:0x30,_0x32f4b8:0x19,_0x2e8c2f:0x21,_0x2a3981:0x3f,_0xd3e81b:0x4d,_0x387ebb:0x93,_0xe5c105:0x7f,_0xd45639:0x8e,_0x7db0e6:0x91,_0x5297b7:0x65,_0x2e5cd4:0x3a,_0x5b1fed:0x3c,_0x2c2e88:0x66,_0x7bc554:0x52,_0x1567a6:0x84,_0x1df8f2:0x23,_0x539277:0x1e,_0xf272af:0x2d},_0x3a020f={_0x58a898:0x1de},_0x2d2f8d={_0x280a9a:0x127},_0x22c26e=resolveOpenAiReasoningConfig(_0x2cd550[_0x18bd05(-_0x24e5ef._0x1ab57b,_0x24e5ef._0x2d1785,_0x24e5ef._0x2f732c,0x22)]);if(!_0x22c26e)return{};function _0x18bd05(_0x3ebbfd,_0x408f7f,_0x423b67,_0xe22b6b){return _0x3161(_0x423b67- -_0x2d2f8d._0x280a9a,_0xe22b6b);}const _0x34d933={},_0x1be0f3=_0x22c26e[_0x18bd05(0x53,_0x24e5ef._0x4aed99,0x38,_0x24e5ef._0x32f4b8)]??(resolveReasoningVisibility(_0x2cd550)===_0x18bd05(0x27,_0x24e5ef._0x2e8c2f,_0x24e5ef._0x2a3981,_0x24e5ef._0xd3e81b)?_0x18bd05(0x3f,0x54,0x41,0x52):void 0x0);function _0x3e2956(_0x5b211c,_0x4221a7,_0x112091,_0x25fba0){return _0x3161(_0x5b211c- -_0x3a020f._0x58a898,_0x25fba0);}return _0x22c26e['effort']&&(_0x34d933['effort']=_0x22c26e[_0x3e2956(-0x9d,-_0x24e5ef._0x387ebb,-_0x24e5ef._0xe5c105,-_0x24e5ef._0xd45639)]),_0x1be0f3&&(_0x34d933[_0x3e2956(-0x7f,-_0x24e5ef._0x7db0e6,-_0x24e5ef._0x5297b7,-0x6f)]=_0x1be0f3),{..._0x22c26e[_0x18bd05(0x58,_0x24e5ef._0x2e5cd4,0x4f,_0x24e5ef._0x5b1fed)]===![]?{}:{'include':[_0x3e2956(-_0x24e5ef._0x2c2e88,-0x58,-_0x24e5ef._0x7bc554,-_0x24e5ef._0x1567a6)]},...Object[_0x18bd05(_0x24e5ef._0x1df8f2,0x5,_0x24e5ef._0x539277,0x1)](_0x34d933)[_0x18bd05(0x47,0x5b,0x43,_0x24e5ef._0xf272af)]>0x0?{'reasoning':_0x34d933}:{}};}function pushAssistantProviderState(_0x5daf04,_0xa7f8f){const _0x9a006c={_0x1cb6db:0x1d4,_0x48e562:0x1f2,_0x582572:0x1ec,_0x3c09ec:0x20d,_0x3d52e6:0x1fc,_0x20ec3c:0x89,_0xda07cf:0x1f5,_0xb46af3:0x219,_0x4a1413:0x225},_0x4a6d1d={_0x55e0b9:0xaf};function _0x228544(_0x1eeae7,_0x20621e,_0x5d25c8,_0x9ef640){return _0x3161(_0x20621e- -0x21b,_0x5d25c8);}if(_0xa7f8f[_0x4ecda2(_0x9a006c._0x1cb6db,_0x9a006c._0x48e562,0x203,_0x9a006c._0x582572)]!==_0x4ecda2(0x1f6,_0x9a006c._0x3c09ec,0x1ff,_0x9a006c._0x3d52e6))return![];const _0x13ed9e=_0xa7f8f[_0x228544(-_0x9a006c._0x20ec3c,-0xa7,-0xa1,-0xb2)]?.[_0x4ecda2(0x22b,0x211,_0x9a006c._0xda07cf,0x22f)]??[];if(_0x13ed9e[_0x4ecda2(0x217,_0x9a006c._0xb46af3,0x204,_0x9a006c._0x4a1413)]===0x0)return![];for(const _0x5f417a of _0x13ed9e){isResponseInputObject(_0x5f417a)&&_0x5daf04['push'](structuredClone(_0x5f417a));}function _0x4ecda2(_0x3e7c08,_0x31801d,_0x3781b8,_0x1191ab){return _0x3161(_0x31801d-_0x4a6d1d._0x55e0b9,_0x1191ab);}return!![];}function toOpenAiResponsesRequest(_0x4e915b){const _0x5f3355={_0x50df9d:0x173,_0x12d60b:0x18a,_0x2d3071:0x29f,_0x3f2f5c:0x281,_0x23f619:0x28d,_0x51e8c1:0x196,_0x392d81:0x1be,_0x77ca23:0x294,_0x3f4645:0x2a7,_0x2c7689:0x262,_0x168b33:0x275,_0x217347:0x172,_0x7c5ad5:0x1a6,_0x50469f:0x18d,_0x38a750:0x278,_0x380c1e:0x282,_0x4222c0:0x296,_0x3709b6:0x268,_0x217dc8:0x282,_0x187058:0x274,_0x4d6496:0x1a8,_0x2f1e22:0x1a4,_0x5eb964:0x187,_0x37d4dd:0x1a5,_0x5984f5:0x169,_0x2df8fa:0x178,_0x32c6ec:0x28f,_0x1e0a00:0x2a5,_0x1e6e16:0x297,_0xabf8bc:0x28b,_0x5025ef:0x2a8,_0x5ddc8e:0x2a8,_0x55c5b8:0x27b,_0x102216:0x17d,_0x24b08e:0x179,_0x24d26a:0x19e,_0xed6b5d:0x17c,_0x4305ec:0x15c,_0x2db61c:0x173,_0x18882e:0x171,_0x48e85b:0x191,_0x14a1c7:0x188,_0x25d4e0:0x16c,_0x2b7f74:0x156,_0x4b2e40:0x18b,_0x42f72:0x173,_0x141086:0x28c,_0x41119b:0x287,_0xfce4cb:0x271,_0x40f8de:0x19d,_0xc45a07:0x192,_0x50994f:0x1a3,_0x4d1492:0x27f,_0x1a60ee:0x176,_0xeffe9f:0x28d,_0x4bce81:0x2a6,_0xb17c9b:0x16e,_0x28bd6b:0x190,_0x31cb08:0x181,_0x215758:0x174,_0x3d7ea4:0x284,_0x4199d0:0x270,_0x5da21c:0x291,_0xefed32:0x28d},_0xb59939={_0x17a283:0x1b8,_0x37a923:0x1b0,_0x4a4de1:0x1a9,_0x458d65:0x1d2,_0x1ca79c:0x1a5,_0x1eaf06:0x1b7,_0x5d0f40:0x1af,_0xfdb071:0x190,_0x1eaa89:0x372,_0x29f443:0x373},_0x2a0816={_0x3fa83e:0x95,_0x5604fa:0x43,_0x54bc71:0x1ce},_0x515fe8={_0x5541a7:0x1ba,_0x31826e:0x344},_0x4ad013={_0x4fac96:0x3dd},_0x5cbf9f={_0xa94afa:0x35};function _0x2ba18d(_0x27b05a,_0x1bdd2a,_0x313e5a,_0x2f4a37){return _0x3161(_0x2f4a37-_0x5cbf9f._0xa94afa,_0x313e5a);}function _0x42dcf0(_0x35aba2,_0x4327e5,_0x328666,_0x446cb0){return _0x3161(_0x35aba2- -_0x4ad013._0x4fac96,_0x4327e5);}const _0x334411=[];for(const _0x595fdf of _0x4e915b[_0x2ba18d(_0x5f3355._0x50df9d,_0x5f3355._0x12d60b,0x18e,0x18f)]){if(pushAssistantProviderState(_0x334411,_0x595fdf))continue;const _0x2d6016=[];for(const _0x51e27d of normalizeContent(_0x595fdf[_0x42dcf0(-_0x5f3355._0x2d3071,-_0x5f3355._0x3f2f5c,-0x294,-_0x5f3355._0x23f619)])){if(_0x51e27d[_0x42dcf0(-0x297,-0x279,-0x2a9,-0x28f)]==='text'){_0x2d6016[_0x2ba18d(_0x5f3355._0x51e8c1,_0x5f3355._0x392d81,0x1bf,0x1a3)]({'type':_0x42dcf0(-_0x5f3355._0x77ca23,-0x2ac,-0x295,-_0x5f3355._0x3f4645),'text':_0x51e27d[_0x42dcf0(-0x27c,-0x27d,-_0x5f3355._0x2c7689,-_0x5f3355._0x168b33)]});continue;}if(_0x51e27d['type']===_0x2ba18d(_0x5f3355._0x217347,0x170,_0x5f3355._0x7c5ad5,_0x5f3355._0x50469f)){_0x2d6016['push']({'type':_0x42dcf0(-0x288,-0x27d,-0x29f,-0x287),'image_url':'data:'+_0x51e27d[_0x42dcf0(-_0x5f3355._0x38a750,-_0x5f3355._0x380c1e,-_0x5f3355._0x4222c0,-_0x5f3355._0x3709b6)][_0x42dcf0(-_0x5f3355._0x217dc8,-0x29c,-_0x5f3355._0x187058,-_0x5f3355._0x380c1e)]+_0x2ba18d(0x19c,_0x5f3355._0x4d6496,_0x5f3355._0x2f1e22,0x1a6)+_0x51e27d[_0x2ba18d(_0x5f3355._0x5eb964,_0x5f3355._0x37d4dd,0x19b,0x19a)]['data']});continue;}pushUserContentMessage(_0x334411,_0x595fdf[_0x2ba18d(0x17e,0x16f,_0x5f3355._0x5984f5,_0x5f3355._0x2df8fa)],_0x2d6016[_0x42dcf0(-_0x5f3355._0x32c6ec,-0x27d,-0x294,-_0x5f3355._0x1e0a00)](0x0));if(_0x51e27d[_0x42dcf0(-_0x5f3355._0x1e6e16,-0x294,-0x2a8,-0x2af)]===_0x42dcf0(-_0x5f3355._0xabf8bc,-_0x5f3355._0x5025ef,-0x284,-_0x5f3355._0x5ddc8e)){if(!hasSerializableToolUse(_0x51e27d))continue;_0x334411[_0x2ba18d(0x1bd,0x19d,0x19d,0x1a3)]({'type':'function_call','call_id':_0x51e27d['id'],'name':_0x51e27d[_0x42dcf0(-0x281,-0x273,-_0x5f3355._0x55c5b8,-0x279)],'arguments':JSON['stringify'](_0x51e27d[_0x2ba18d(0x164,0x17d,0x183,_0x5f3355._0x102216)]??{})});continue;}if(_0x51e27d[_0x42dcf0(-_0x5f3355._0x1e6e16,-0x29d,-0x297,-0x2b0)]===_0x2ba18d(_0x5f3355._0x24b08e,_0x5f3355._0x24d26a,0x17f,0x185)){if(!hasSerializableToolResult(_0x51e27d))continue;const _0x1bc315=getToolResultText(_0x51e27d[_0x2ba18d(_0x5f3355._0xed6b5d,0x175,_0x5f3355._0x4305ec,_0x5f3355._0x2db61c)]);_0x334411['push']({'type':_0x2ba18d(_0x5f3355._0x18882e,_0x5f3355._0x48e85b,0x17f,_0x5f3355._0x14a1c7),'call_id':_0x51e27d[_0x2ba18d(0x173,_0x5f3355._0x25d4e0,0x199,0x182)],'output':_0x1bc315});const _0x189c62=getToolResultImages(_0x51e27d[_0x2ba18d(_0x5f3355._0x2b7f74,0x171,_0x5f3355._0x4b2e40,_0x5f3355._0x42f72)]);_0x189c62[_0x42dcf0(-0x273,-_0x5f3355._0x141086,-_0x5f3355._0x41119b,-_0x5f3355._0xfce4cb)]>0x0&&_0x334411[_0x2ba18d(0x1ac,_0x5f3355._0x40f8de,_0x5f3355._0xc45a07,_0x5f3355._0x50994f)]({'type':'message','role':'user','content':[{'type':_0x42dcf0(-_0x5f3355._0x77ca23,-0x286,-_0x5f3355._0x4d1492,-_0x5f3355._0x3f4645),'text':_0x2ba18d(0x186,_0x5f3355._0x1a60ee,0x16e,_0x5f3355._0xed6b5d)+_0x51e27d[_0x42dcf0(-0x290,-_0x5f3355._0xeffe9f,-_0x5f3355._0x4bce81,-0x27b)]+'.'},..._0x189c62[_0x2ba18d(_0x5f3355._0xb17c9b,_0x5f3355._0x28bd6b,0x169,_0x5f3355._0x31cb08)](_0x13988b=>({'type':'input_image','image_url':_0x2ba18d(0x1bd,0x19f,0x199,0x1ac)+_0x13988b[_0x2ba18d(0x180,0x187,0x19f,0x19a)][_0x42dcf0(-0x282,-0x28b,-0x29f,-0x266)]+_0x42dcf0(-0x26c,-0x255,-0x27f,-0x289)+_0x13988b[_0x2ba18d(0x186,0x19f,0x19f,0x19a)][_0x2ba18d(0x19e,0x1a9,0x1a8,0x1a4)]}))]});}}pushUserContentMessage(_0x334411,_0x595fdf['role'],_0x2d6016);}return{...createOpenAiResponsesReasoning(_0x4e915b),'model':_0x4e915b[_0x2ba18d(0x190,0x163,_0x5f3355._0x50469f,_0x5f3355._0x215758)],'instructions':systemToInstructions(_0x4e915b[_0x42dcf0(-0x280,-0x267,-0x265,-0x29e)]),'input':_0x334411,'max_output_tokens':_0x4e915b['maxTokens'],'tools':_0x4e915b[_0x42dcf0(-_0x5f3355._0x3d7ea4,-_0x5f3355._0x4199d0,-0x289,-0x26f)][_0x42dcf0(-_0x5f3355._0x5da21c,-_0x5f3355._0xefed32,-0x2ab,-0x290)](_0x6e9971=>{function _0x754662(_0x39ff6e,_0x43c815,_0x5a5458,_0x356661){return _0x2ba18d(_0x39ff6e-_0x515fe8._0x5541a7,_0x43c815-0x4b,_0x43c815,_0x39ff6e- -_0x515fe8._0x31826e);}function _0xa75526(_0x470175,_0x44a215,_0x48505c,_0x1412e6){return _0x2ba18d(_0x470175-_0x2a0816._0x3fa83e,_0x44a215-_0x2a0816._0x5604fa,_0x1412e6,_0x470175-_0x2a0816._0x54bc71);}return{'type':_0x754662(-0x19f,-_0xb59939._0x17a283,-_0xb59939._0x37a923,-_0xb59939._0x4a4de1),'name':_0x6e9971[_0x754662(-0x1b3,-_0xb59939._0x458d65,-_0xb59939._0x1ca79c,-_0xb59939._0x1eaf06)],'description':_0x6e9971[_0x754662(-_0xb59939._0x5d0f40,-0x1cd,-0x19d,-_0xb59939._0xfdb071)],'parameters':_0x6e9971[_0xa75526(0x370,0x37b,_0xb59939._0x1eaa89,_0xb59939._0x29f443)]};})};}export{toOpenAiResponsesRequest};
1
+ (function(_0x5c4391,_0x3c2056){const _0x557f82={_0x1151bb:0x2b4,_0x1b2190:0x2c9,_0x1e299c:0x2b6,_0x34524c:0x2c2,_0x1b3f8c:0x2d1,_0x714d3:0x2d6,_0x52f647:0x2c4,_0x2cacd3:0x2e5,_0x3e25c3:0xa8,_0x4b3587:0xa2,_0x39d34c:0x8e,_0x2ae60f:0x76,_0x183911:0x74,_0x336331:0x64,_0x44a875:0xa4,_0x1a797f:0x9b,_0x1bb7a7:0x91,_0x544913:0x2b7,_0xdd4a47:0x2b2,_0xc15ea1:0x2cd,_0x2189ac:0x2c5,_0x236dc7:0x2ec,_0x3a2c34:0xcc,_0x2f817c:0x8f,_0x26b5ba:0x92,_0x5144d4:0x82,_0x2c705d:0x81},_0x40f62e=_0x5c4391();function _0x218ec3(_0xb951e8,_0x271f64,_0x14860b,_0xffa460){return _0x43c4(_0x271f64- -0x1b2,_0x14860b);}function _0x6d52f6(_0x3836f0,_0x254546,_0x5a02df,_0xe7d175){return _0x43c4(_0x3836f0-0x1b9,_0x254546);}while(!![]){try{const _0xf4522d=parseInt(_0x6d52f6(0x2b8,0x2cc,_0x557f82._0x1151bb,0x2c8))/0x1+parseInt(_0x6d52f6(_0x557f82._0x1b2190,_0x557f82._0x1e299c,_0x557f82._0x34524c,_0x557f82._0x1b3f8c))/0x2*(-parseInt(_0x6d52f6(0x2ce,_0x557f82._0x714d3,_0x557f82._0x52f647,_0x557f82._0x2cacd3))/0x3)+-parseInt(_0x218ec3(-0x89,-0xa3,-_0x557f82._0x3e25c3,-0x8f))/0x4*(-parseInt(_0x218ec3(-_0x557f82._0x4b3587,-0x88,-_0x557f82._0x39d34c,-_0x557f82._0x2ae60f))/0x5)+parseInt(_0x218ec3(-0x74,-0x81,-_0x557f82._0x183911,-_0x557f82._0x336331))/0x6*(parseInt(_0x218ec3(-_0x557f82._0x44a875,-_0x557f82._0x1a797f,-_0x557f82._0x1bb7a7,-0xa2))/0x7)+parseInt(_0x6d52f6(_0x557f82._0x544913,_0x557f82._0xdd4a47,_0x557f82._0xc15ea1,0x299))/0x8+-parseInt(_0x6d52f6(0x2d3,0x2bd,_0x557f82._0x2189ac,_0x557f82._0x236dc7))/0x9*(parseInt(_0x218ec3(-_0x557f82._0x3a2c34,-0xb1,-0xb9,-0xba))/0xa)+-parseInt(_0x218ec3(-0x8a,-_0x557f82._0x2f817c,-0x84,-0x78))/0xb*(parseInt(_0x218ec3(-_0x557f82._0x26b5ba,-0x80,-_0x557f82._0x5144d4,-_0x557f82._0x2c705d))/0xc);if(_0xf4522d===_0x3c2056)break;else _0x40f62e['push'](_0x40f62e['shift']());}catch(_0x437f23){_0x40f62e['push'](_0x40f62e['shift']());}}}(_0x1f0f,0xc2a99));import{resolveOpenAiReasoningConfig}from'./chunk-NYZR4XKO.js';function _0x1f0f(){const _0x7c9552=['Dgv4Da','zNvUy3rPB25Fy2fSBf9VDxrWDxq','vg9VBcbYzxr1CM5LzcbPBwfNzsbJB250zw50lG','Aw5JBhvKzuvUy3j5ChrLzenVBNrLBNq','zMLSDgvY','odGWng1SB0zHEa','ndjuz0Psv1m','C3bSAwnL','y29UDgvUDa','zwzMB3j0','zNvUy3rPB24','nda0mdDmCxvuBhK','AM9PBG','ndq1ntG3og9qyMn4rW','C3vTBwfYEq','Aw5WDxrFC2nOzw1H','mJqYmvHxwKXHBG','ChjVDMLKzxjtDgf0zq','Aw5WDxq','Aw5WDxrFAw1Hz2u','o2jHC2u2ncW','BgvUz3rO','BwvZC2fNzq','DxnLCI12AxnPyMXL','Aw5WDxrFDgv4Da','nZD1r2fhsKq','DxnLCG','yxv0BW','DhjPBq','BwfW','A2v5CW','ChvZAa','mJG1nvPSzhvgAa','CM9Szq','DhLWzq','BwvKAwfFDhLWzq','C291CMnL','yxnZAxn0yw50','Dg9VBf91C2u','mtjHqKDWDuS','mZy2ndG2mhPlrMHKDa','DMLZAwjPBgL0Eq','sw1Hz2uGCMv0DxjUzwqGyNKGvMLLD0zPBguGzM9YihrVB2WGCMvZDwX0ia','B3bLBMfPuMvZCg9UC2vZt3v0Chv0','C3LZDgvT','BMfTzq','Dg9VBf9Yzxn1Bhq','zgf0yq','ndaZndrMvvfvB2i','mtm5mJq1mKnqDwT2uW','yMfZzty0','mJyZnZb4zhfKB3m','B2jQzwn0','CMvHC29UAw5N','Aw1Hz2u','C3rYAw5N','AxnbCNjHEq','Bw9KzwW','Dg9VBhm','Dg9VBf91C2vFAwq'];_0x1f0f=function(){return _0x7c9552;};return _0x1f0f();}import{normalizeContent}from'./chunk-G2FR4UGO.js';function systemToInstructions(_0x28b838){const _0x40daea={_0x3f66c2:0x38d,_0xe43d5a:0x394,_0x2855a3:0x3a6,_0x2fc16f:0x47f,_0xb1fa01:0x452},_0x5e6314={_0x1ec421:0x26d};function _0x27f6e7(_0x2035be,_0x828105,_0x118086,_0x12e64f){return _0x43c4(_0x12e64f-0x352,_0x118086);}function _0x154a96(_0x4dcef0,_0x4892af,_0x540cc0,_0x2ee151){return _0x43c4(_0x4892af-_0x5e6314._0x1ec421,_0x2ee151);}return normalizeContent(_0x28b838)['filter'](_0x1f1efb=>_0x1f1efb[_0x27f6e7(0x487,0x472,0x460,0x47e)]==='text')[_0x154a96(_0x40daea._0x3f66c2,_0x40daea._0xe43d5a,_0x40daea._0x2855a3,0x37b)](_0x12c25b=>_0x12c25b[_0x154a96(0x386,0x377,0x38e,0x38e)])[_0x27f6e7(0x46e,_0x40daea._0x2fc16f,_0x40daea._0xb1fa01,0x468)]('\x0a\x0a');}function _0x43c4(_0x29fc0c,_0x291a19){_0x29fc0c=_0x29fc0c-0xfb;const _0x1f0f33=_0x1f0f();let _0x43c455=_0x1f0f33[_0x29fc0c];if(_0x43c4['GBlbXH']===undefined){var _0x170d33=function(_0xdd3131){const _0x42b9b1='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x28b838='',_0x1f1efb='';for(let _0x12c25b=0x0,_0x5ecbac,_0x1b144f,_0x3d95cb=0x0;_0x1b144f=_0xdd3131['charAt'](_0x3d95cb++);~_0x1b144f&&(_0x5ecbac=_0x12c25b%0x4?_0x5ecbac*0x40+_0x1b144f:_0x1b144f,_0x12c25b++%0x4)?_0x28b838+=String['fromCharCode'](0xff&_0x5ecbac>>(-0x2*_0x12c25b&0x6)):0x0){_0x1b144f=_0x42b9b1['indexOf'](_0x1b144f);}for(let _0x50a464=0x0,_0x39d3dd=_0x28b838['length'];_0x50a464<_0x39d3dd;_0x50a464++){_0x1f1efb+='%'+('00'+_0x28b838['charCodeAt'](_0x50a464)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x1f1efb);};_0x43c4['VaWnBb']=_0x170d33,_0x43c4['zxMOjx']={},_0x43c4['GBlbXH']=!![];}const _0x13014d=_0x1f0f33[0x0],_0x4a8cbc=_0x29fc0c+_0x13014d,_0x282231=_0x43c4['zxMOjx'][_0x4a8cbc];return!_0x282231?(_0x43c455=_0x43c4['VaWnBb'](_0x43c455),_0x43c4['zxMOjx'][_0x4a8cbc]=_0x43c455):_0x43c455=_0x282231,_0x43c455;}function pushUserContentMessage(_0x5ecbac,_0x1b144f,_0x3d95cb){if(_0x3d95cb['length']===0x0)return;_0x5ecbac['push']({'type':'message','role':_0x1b144f,'content':_0x3d95cb});}function hasSerializableToolUse(_0x50a464){const _0x44e821={_0x5daf2c:0x2b8,_0x5d4216:0x17e,_0xba555c:0x174,_0x44f91d:0x16d,_0x49c21a:0x2f8,_0x2834a5:0x2e5,_0xf77d39:0x2c0,_0x4aaddf:0x2b0,_0x2927c8:0x2c1},_0x4b78df={_0x557da4:0x3e0};function _0x7f229a(_0x2e3b36,_0x44b01a,_0x178f69,_0x2ccb15){return _0x43c4(_0x2ccb15- -_0x4b78df._0x557da4,_0x44b01a);}function _0x2e8360(_0x52ed56,_0x29e9f0,_0x43313e,_0x49820d){return _0x43c4(_0x52ed56- -0x29d,_0x49820d);}return _0x50a464['id'][_0x7f229a(-0x2c5,-_0x44e821._0x5daf2c,-0x2c9,-0x2ba)]()[_0x2e8360(-_0x44e821._0x5d4216,-_0x44e821._0xba555c,-_0x44e821._0x44f91d,-0x19a)]>0x0&&_0x50a464[_0x7f229a(-_0x44e821._0x49c21a,-0x302,-0x2ff,-_0x44e821._0x2834a5)]['trim']()[_0x7f229a(-0x2ca,-_0x44e821._0xf77d39,-_0x44e821._0x4aaddf,-_0x44e821._0x2927c8)]>0x0;}function hasSerializableToolResult(_0x39d3dd){const _0x4b88db={_0x7cdba3:0x23c,_0x2d4648:0x228};function _0x2082f1(_0x46a336,_0x11594d,_0x59c27e,_0x6bde28){return _0x43c4(_0x46a336-0x18b,_0x6bde28);}function _0x9e6d5e(_0x5b3810,_0x1d45dc,_0x4db843,_0x13a65f){return _0x43c4(_0x5b3810-0x133,_0x1d45dc);}return _0x39d3dd[_0x9e6d5e(_0x4b88db._0x7cdba3,_0x4b88db._0x2d4648,0x24e,0x22c)][_0x2082f1(0x2b1,0x29d,0x2bd,0x2b2)]()['length']>0x0;}function isResponseInputObject(_0x3f98f9){const _0x588dc9={_0x2a5ece:0x3d1,_0x462255:0x19d,_0x6fcf8b:0x19c},_0x1a72c0={_0x4843f1:0x2cf};if(typeof _0x3f98f9!==_0x44e265(0x3e9,0x3b5,0x3cb,_0x588dc9._0x2a5ece)||_0x3f98f9===null||Array['isArray'](_0x3f98f9))return![];function _0x2214ae(_0x33dc1a,_0x2f0798,_0x558b97,_0x4386a3){return _0x43c4(_0x4386a3-0x6c,_0x558b97);}const _0x2fdf8b=_0x3f98f9;function _0x44e265(_0xf0d463,_0x47cd75,_0xaf22fc,_0x2acbd2){return _0x43c4(_0x2acbd2-_0x1a72c0._0x4843f1,_0xf0d463);}return typeof _0x2fdf8b[_0x2214ae(_0x588dc9._0x462255,0x17c,_0x588dc9._0x6fcf8b,0x198)]===_0x2214ae(0x15e,0x163,0x18f,0x171);}function isImageToolResultBlock(_0x9771d2){const _0x551560={_0x4774b5:0x268,_0x404004:0x252,_0x8ca1ff:0x264,_0x317e03:0x253,_0x4ecc67:0x250,_0x2a3f11:0x233,_0x28d560:0x273,_0x1dd8cf:0x267,_0x2fb6d9:0x285,_0xcea1e:0x271,_0x4ab75d:0x250,_0x5339e0:0x254,_0x45130a:0x239,_0x3f06d5:0x27a,_0x17b32f:0x27b,_0xba6a11:0x277,_0x2a0552:0x279,_0x43ca0d:0x28e,_0x4604e2:0x24a,_0x235b48:0x251,_0x1c0848:0x248,_0xaadad5:0x26a,_0x4a1489:0x267,_0x218f12:0x22c,_0x122469:0x234,_0x6e39c7:0x247,_0x4f5632:0x24c,_0x44cfc8:0x221,_0x1e56d2:0x23e},_0x1f01ef={_0x356359:0x139};function _0x1e1805(_0x48fe13,_0x1e488f,_0x2d63c2,_0x120f94){return _0x43c4(_0x120f94-_0x1f01ef._0x356359,_0x2d63c2);}if(typeof _0x9771d2!=='object'||_0x9771d2===null||Array[_0x63a48f(_0x551560._0x4774b5,_0x551560._0x404004,_0x551560._0x8ca1ff,_0x551560._0x317e03)](_0x9771d2))return![];function _0x63a48f(_0x23979c,_0x49c31a,_0xab086b,_0x4e9906){return _0x43c4(_0x49c31a-0x14c,_0x23979c);}const _0x19e219=_0x9771d2;return _0x19e219[_0x63a48f(0x27c,0x278,0x262,0x292)]===_0x63a48f(0x234,_0x551560._0x4ecc67,0x265,_0x551560._0x2a3f11)&&_0x19e219[_0x1e1805(_0x551560._0x28d560,0x263,0x27f,_0x551560._0x1dd8cf)]?.[_0x63a48f(0x295,0x278,_0x551560._0x2fb6d9,_0x551560._0xcea1e)]===_0x1e1805(0x226,_0x551560._0x4ab75d,_0x551560._0x5339e0,_0x551560._0x45130a)&&typeof _0x19e219[_0x63a48f(0x285,_0x551560._0x3f06d5,0x292,_0x551560._0x17b32f)][_0x63a48f(_0x551560._0xba6a11,_0x551560._0x2a0552,_0x551560._0x43ca0d,0x26c)]===_0x63a48f(_0x551560._0x4604e2,_0x551560._0x235b48,0x265,_0x551560._0x1c0848)&&typeof _0x19e219[_0x1e1805(0x276,_0x551560._0x4ecc67,_0x551560._0xaadad5,_0x551560._0x4a1489)][_0x63a48f(_0x551560._0x218f12,0x249,_0x551560._0x122469,0x259)]===_0x1e1805(_0x551560._0x6e39c7,_0x551560._0x4f5632,_0x551560._0x44cfc8,_0x551560._0x1e56d2);}function getToolResultText(_0x48bcd2){const _0x35bd7d={_0x14529c:0xb9,_0x889517:0x8d,_0x2d26d7:0x29d,_0xb6899b:0x2a9,_0x3662f7:0x2c6,_0x8a68d8:0x28a,_0x221450:0x280,_0x3d091a:0x289,_0x473454:0x2a9,_0x4103b3:0x28f,_0x4b1069:0x2a0,_0x5da4ec:0x283,_0x3ec050:0x99,_0x3bde0b:0x95,_0x28b00a:0xae,_0x60532d:0x7d,_0x62c963:0x79},_0x37818d={_0x3dd648:0x13b,_0x4db0e2:0x13f,_0x11a5c3:0x9b,_0x51bf7c:0xac,_0x1436f2:0xb1},_0x4c3d78={_0x52c9bf:0x168,_0x437630:0x200},_0x344e42={_0x310a05:0x1cb},_0x2a0757={_0x5efc18:0x1a1},_0x4e36b3={_0x4158dd:0x3b6};function _0xb0bf69(_0x398183,_0xe87b06,_0x1c95ea,_0x3c29e5){return _0x43c4(_0x1c95ea- -_0x4e36b3._0x4158dd,_0x3c29e5);}if(typeof _0x48bcd2===_0x142cbe(-0x9c,-_0x35bd7d._0x14529c,-_0x35bd7d._0x889517,-0x91))return _0x48bcd2;function _0x142cbe(_0xd5e20,_0x404950,_0x5bfb22,_0x4c791d){return _0x43c4(_0xd5e20- -_0x2a0757._0x5efc18,_0x5bfb22);}const _0x790114=_0x48bcd2[_0xb0bf69(-_0x35bd7d._0x2d26d7,-_0x35bd7d._0xb6899b,-0x2a8,-_0x35bd7d._0x3662f7)](_0x3526e4=>{function _0x290dce(_0x10a7b7,_0x40b19d,_0x313c62,_0x2229bd){return _0x142cbe(_0x40b19d-_0x344e42._0x310a05,_0x40b19d-0x21,_0x10a7b7,_0x2229bd-0xba);}function _0x10fa3e(_0x216c6c,_0x365061,_0x249088,_0x39a122){return _0xb0bf69(_0x216c6c-0x151,_0x365061-_0x4c3d78._0x52c9bf,_0x365061-_0x4c3d78._0x437630,_0x39a122);}return typeof _0x3526e4===_0x290dce(0x118,0x12c,_0x37818d._0x3dd648,0x144)&&_0x3526e4!==null&&_0x3526e4[_0x290dce(_0x37818d._0x4db0e2,0x156,0x152,0x15c)]===_0x10fa3e(-_0x37818d._0x11a5c3,-_0x37818d._0x51bf7c,-0xac,-_0x37818d._0x1436f2);})[_0xb0bf69(-_0x35bd7d._0x8a68d8,-_0x35bd7d._0x221450,-0x28f,-_0x35bd7d._0x3d091a)](_0x2316ee=>_0x2316ee[_0xb0bf69(-0x2a8,-0x297,-0x2ac,-0x2b6)])[_0xb0bf69(-_0x35bd7d._0x473454,-_0x35bd7d._0x4103b3,-_0x35bd7d._0x4b1069,-_0x35bd7d._0x5da4ec)]('\x0a\x0a')[_0x142cbe(-0x7b,-0x71,-_0x35bd7d._0x3ec050,-0x7b)]();return _0x790114['length']>0x0?_0x790114:_0x142cbe(-_0x35bd7d._0x3bde0b,-_0x35bd7d._0x28b00a,-_0x35bd7d._0x60532d,-_0x35bd7d._0x62c963);}function getToolResultImages(_0x5b7494){const _0x101b4d={_0x4dabee:0x4d6,_0x55ce01:0x4f9,_0x555d20:0x4cc,_0x37b65b:0x4df};function _0x219565(_0x572b63,_0x1ce9c5,_0xdf0096,_0x592701){return _0x43c4(_0x592701-0x3d1,_0x572b63);}return Array['isArray'](_0x5b7494)?_0x5b7494[_0x219565(_0x101b4d._0x4dabee,_0x101b4d._0x55ce01,_0x101b4d._0x555d20,_0x101b4d._0x37b65b)](isImageToolResultBlock):[];}function resolveReasoningVisibility(_0x5b02a6){const _0x19b6c0={_0x2677e3:0x55,_0x22133f:0x75,_0x19f39c:0x69,_0x53bb13:0xac,_0x2c7964:0x9a,_0x30cdb5:0x42},_0x5b6285={_0x5555da:0x1cd};function _0xc07f8b(_0x18774b,_0x41e760,_0x5b446a,_0x56840e){return _0x43c4(_0x5b446a- -_0x5b6285._0x5555da,_0x18774b);}function _0x3332e6(_0x208d3c,_0x334207,_0x14122e,_0x52034e){return _0x43c4(_0x14122e- -0x16c,_0x52034e);}return _0x5b02a6[_0x3332e6(-_0x19b6c0._0x2677e3,-_0x19b6c0._0x22133f,-_0x19b6c0._0x19f39c,-0x4d)]?.[_0xc07f8b(-0xa8,-_0x19b6c0._0x53bb13,-_0x19b6c0._0x2c7964,-0xa2)]??_0x3332e6(-0x42,-_0x19b6c0._0x30cdb5,-0x4b,-0x5c);}function createOpenAiResponsesReasoning(_0x5a23d4){const _0x184d98={_0x1f6ce8:0x2ca,_0x259867:0x2c3,_0x506cbf:0x29a,_0x3cf58a:0x2c1,_0x4a3daa:0x2b6,_0x3810e7:0x2a6,_0x276a15:0x290,_0x9f10c2:0x162,_0xa41e6:0x2a7,_0x18f895:0x2c8,_0x1b8b23:0x291,_0x5968f7:0x2a8,_0x1d6ebc:0x2af,_0x2c5cf2:0x299,_0x1f1657:0x2ba,_0x5f4bd5:0x2c5,_0x5d1c47:0x29f,_0x46f0fe:0x29f},_0x175eaa=resolveOpenAiReasoningConfig(_0x5a23d4[_0x1ec062(-_0x184d98._0x1f6ce8,-0x2c2,-0x2c4,-_0x184d98._0x259867)]);if(!_0x175eaa)return{};function _0x1ec062(_0x567f2c,_0x337ed4,_0x32146b,_0x55d4a4){return _0x43c4(_0x32146b- -0x3c7,_0x567f2c);}const _0x19290e={},_0x3230e1=_0x175eaa[_0x1ec062(-0x2c7,-_0x184d98._0x506cbf,-0x2af,-0x296)]??(resolveReasoningVisibility(_0x5a23d4)===_0x1ec062(-_0x184d98._0x3cf58a,-_0x184d98._0x4a3daa,-_0x184d98._0x3810e7,-_0x184d98._0x276a15)?_0x41ed4f(-_0x184d98._0x9f10c2,-0x16b,-0x181,-0x150):void 0x0);_0x175eaa['effort']&&(_0x19290e[_0x1ec062(-_0x184d98._0xa41e6,-0x297,-0x2b4,-0x29a)]=_0x175eaa[_0x1ec062(-0x297,-0x2b5,-0x2b4,-_0x184d98._0x18f895)]);_0x3230e1&&(_0x19290e[_0x1ec062(-_0x184d98._0x1b8b23,-_0x184d98._0x5968f7,-_0x184d98._0x1d6ebc,-_0x184d98._0x2c5cf2)]=_0x3230e1);function _0x41ed4f(_0x14c3ec,_0x117096,_0x29817e,_0x30b298){return _0x43c4(_0x117096- -0x290,_0x14c3ec);}return{..._0x175eaa[_0x1ec062(-_0x184d98._0x4a3daa,-0x2cf,-_0x184d98._0x1f1657,-_0x184d98._0x5f4bd5)]===![]?{}:{'include':['reasoning.encrypted_content']},...Object[_0x1ec062(-0x2a3,-_0x184d98._0x5d1c47,-_0x184d98._0x46f0fe,-0x286)](_0x19290e)['length']>0x0?{'reasoning':_0x19290e}:{}};}function pushAssistantProviderState(_0x1b462b,_0x225be0){const _0x5785d6={_0x36d415:0x3b9,_0x4503bc:0x3b9,_0x324436:0x3b5,_0x2a598c:0x3bd,_0x2d8fdc:0x3d8,_0x52b19e:0x3da,_0x123e0b:0x496,_0x5e688a:0x4ac,_0x5419d9:0x3c3,_0x2f74df:0x3cc,_0xb3daf0:0x3c8,_0x2183f5:0x394,_0x2fb008:0x3b7,_0x480299:0x3b4,_0x13a7ab:0x3a6};function _0x200bb1(_0x43435c,_0x5b5b9c,_0x28bf19,_0xa54ed5){return _0x43c4(_0x43435c-0x28e,_0x5b5b9c);}if(_0x225be0[_0x200bb1(_0x5785d6._0x36d415,_0x5785d6._0x4503bc,_0x5785d6._0x324436,0x3c1)]!==_0x200bb1(_0x5785d6._0x2a598c,_0x5785d6._0x2d8fdc,0x3bc,_0x5785d6._0x52b19e))return![];function _0x5d5d95(_0x5f2449,_0xfe1cd1,_0x1d3d7d,_0x3aeb19){return _0x43c4(_0x5f2449-0x37c,_0x1d3d7d);}const _0x4ac8a1=_0x225be0[_0x5d5d95(0x497,_0x5785d6._0x123e0b,0x47c,_0x5785d6._0x5e688a)]?.[_0x200bb1(_0x5785d6._0x5419d9,_0x5785d6._0x2f74df,_0x5785d6._0xb3daf0,0x3a5)]??[];if(_0x4ac8a1[_0x200bb1(0x3ad,0x3af,_0x5785d6._0x2183f5,0x395)]===0x0)return![];for(const _0x27c8ea of _0x4ac8a1){isResponseInputObject(_0x27c8ea)&&_0x1b462b[_0x200bb1(_0x5785d6._0x2fb008,_0x5785d6._0x480299,0x3c7,_0x5785d6._0x13a7ab)](structuredClone(_0x27c8ea));}return!![];}function toOpenAiResponsesRequest(_0x4d5053){const _0x4f1307={_0x45cae5:0x16,_0x5a4610:0x2d,_0x12a5b1:0x15,_0x21a8fe:0x289,_0x19796e:0x293,_0x53213e:0x29d,_0xb49b76:0x2a0,_0x5fd075:0x26,_0x343ff3:0x24,_0x4c6c90:0x292,_0x465c2e:0x2a8,_0x2d69a2:0x2b8,_0x22c79a:0x280,_0x244cb3:0x3b,_0xb002ed:0x21,_0x57a854:0x11,_0xd70be8:0x32,_0xb95c53:0x14,_0x287a90:0x27e,_0x29f25d:0x26c,_0x13a239:0x9,_0x82a438:0x1b,_0x40c81f:0x27e,_0x43f988:0x285,_0x122b86:0x1c,_0x17016a:0x4,_0x487c2f:0x22,_0x5f4d6d:0x34,_0x318db5:0x23,_0x2c37af:0x2b9,_0x40f44d:0x2bb,_0x23452d:0x290,_0x10ed8c:0x27d,_0x3f24a6:0x28d,_0x181576:0x288,_0x45c202:0x2b0,_0x3289e3:0x2be,_0x5ef257:0x2c1,_0x1ea5d8:0x16,_0x51d974:0x1,_0x406306:0x21,_0x5ed6f5:0x31,_0xb6668c:0x5,_0x5b8279:0x3,_0x3d8467:0x26,_0x4b4dea:0x2a3,_0x474f8d:0x2b4,_0x275047:0x2bd,_0x30b920:0x17,_0x100949:0xd,_0x3d44a4:0x28,_0x480094:0xa,_0x139608:0x28b,_0x347c64:0x25b,_0x540d4f:0x297,_0x88b4c9:0x287,_0x50c2a2:0x285,_0x158d1e:0x4,_0x38453e:0x25c,_0x4edf86:0x9,_0x18f4aa:0xe,_0x5a084a:0x2b},_0x6c2035={_0x331fb6:0x136,_0x4826cc:0x109,_0x2d7a5f:0x109,_0x472c98:0x18a,_0x2202e1:0x173},_0x34df72={_0x3d8c38:0x198,_0x3ffcce:0x10a,_0x118887:0x1c0},_0x29f1c8={_0x228308:0x3ac},_0x596972={_0x16bae7:0xfc},_0x286ae6=[];for(const _0x71b2d8 of _0x4d5053['messages']){if(pushAssistantProviderState(_0x286ae6,_0x71b2d8))continue;const _0x1a2f21=[];for(const _0x33b9a0 of normalizeContent(_0x71b2d8[_0x4e0bde(-0x1,0x6,_0x4f1307._0x45cae5,_0x4f1307._0x5a4610)])){if(_0x33b9a0[_0x4e0bde(_0x4f1307._0x12a5b1,0x4e,0x30,0x40)]===_0x4f63cf(-0x2a2,-_0x4f1307._0x21a8fe,-_0x4f1307._0x19796e,-_0x4f1307._0x53213e)){_0x1a2f21[_0x4f63cf(-0x283,-_0x4f1307._0xb49b76,-0x284,-0x28a)]({'type':_0x4e0bde(0x25,0x18,_0x4f1307._0x5fd075,_0x4f1307._0x343ff3),'text':_0x33b9a0[_0x4f63cf(-0x2a2,-0x284,-_0x4f1307._0x4c6c90,-0x29a)]});continue;}if(_0x33b9a0['type']===_0x4f63cf(-_0x4f1307._0x465c2e,-_0x4f1307._0x2d69a2,-0x28b,-0x28e)){_0x1a2f21[_0x4f63cf(-0x283,-0x29d,-0x280,-_0x4f1307._0x22c79a)]({'type':_0x4e0bde(0x1b,_0x4f1307._0x244cb3,_0x4f1307._0xb002ed,_0x4f1307._0x57a854),'image_url':'data:'+_0x33b9a0[_0x4e0bde(0x25,0x45,_0x4f1307._0xd70be8,0x45)][_0x4e0bde(_0x4f1307._0xb95c53,0x45,0x31,0x28)]+';base64,'+_0x33b9a0[_0x4f63cf(-_0x4f1307._0x287a90,-_0x4f1307._0x29f25d,-0x27e,-0x265)][_0x4e0bde(_0x4f1307._0x13a239,0x1b,0x1,_0x4f1307._0x82a438)]});continue;}pushUserContentMessage(_0x286ae6,_0x71b2d8[_0x4f63cf(-0x281,-_0x4f1307._0x40c81f,-0x263,-_0x4f1307._0x43f988)],_0x1a2f21[_0x4e0bde(0x0,_0x4f1307._0x122b86,0x15,-_0x4f1307._0x17016a)](0x0));if(_0x33b9a0['type']===_0x4e0bde(0x45,_0x4f1307._0x487c2f,_0x4f1307._0x5f4d6d,_0x4f1307._0x318db5)){if(!hasSerializableToolUse(_0x33b9a0))continue;_0x286ae6['push']({'type':'function_call','call_id':_0x33b9a0['id'],'name':_0x33b9a0[_0x4f63cf(-0x2b1,-_0x4f1307._0x2c37af,-_0x4f1307._0x40f44d,-0x2b8)],'arguments':JSON['stringify'](_0x33b9a0[_0x4f63cf(-_0x4f1307._0x23452d,-_0x4f1307._0x10ed8c,-0x293,-_0x4f1307._0x287a90)]??{})});continue;}if(_0x33b9a0[_0x4f63cf(-0x280,-0x26d,-_0x4f1307._0x3f24a6,-_0x4f1307._0x181576)]===_0x4f63cf(-_0x4f1307._0x45c202,-_0x4f1307._0x3289e3,-_0x4f1307._0x5ef257,-0x2a8)){if(!hasSerializableToolResult(_0x33b9a0))continue;const _0xd9e25=getToolResultText(_0x33b9a0[_0x4e0bde(0x29,-0x1,_0x4f1307._0x1ea5d8,-_0x4f1307._0x51d974)]);_0x286ae6[_0x4e0bde(0x21,_0x4f1307._0x406306,0x2d,_0x4f1307._0x5ed6f5)]({'type':_0x4e0bde(_0x4f1307._0xb6668c,-_0x4f1307._0x5b8279,0xf,_0x4f1307._0x3d8467),'call_id':_0x33b9a0[_0x4f63cf(-_0x4f1307._0x4b4dea,-_0x4f1307._0x474f8d,-_0x4f1307._0x275047,-0x2b5)],'output':_0xd9e25});const _0x21b16e=getToolResultImages(_0x33b9a0[_0x4e0bde(_0x4f1307._0x30b920,0x13,0x16,_0x4f1307._0x487c2f)]);_0x21b16e['length']>0x0&&_0x286ae6['push']({'type':_0x4e0bde(0x27,_0x4f1307._0x100949,0x24,0x1d),'role':_0x4e0bde(0x37,0xe,_0x4f1307._0x3d44a4,_0x4f1307._0x480094),'content':[{'type':_0x4f63cf(-0x28a,-0x289,-0x2a2,-0x281),'text':_0x4f63cf(-0x278,-0x25d,-_0x4f1307._0x139608,-_0x4f1307._0x347c64)+_0x33b9a0[_0x4f63cf(-0x2a3,-0x2a7,-_0x4f1307._0x540d4f,-_0x4f1307._0x88b4c9)]+'.'},..._0x21b16e['map'](_0x12229e=>({'type':_0x4f63cf(-0x28f,-0x290,-0x280,-0x29f),'image_url':'data:'+_0x12229e[_0x4f63cf(-0x27e,-0x269,-0x265,-0x28d)]['media_type']+_0x4f63cf(-0x28e,-0x287,-0x2a8,-0x279)+_0x12229e[_0x4e0bde(0x23,0x2c,0x32,0x1a)]['data']}))]});}}pushUserContentMessage(_0x286ae6,_0x71b2d8[_0x4f63cf(-0x281,-_0x4f1307._0x43f988,-0x27d,-_0x4f1307._0x50c2a2)],_0x1a2f21);}function _0x4e0bde(_0x5c76f3,_0xfb14fe,_0x2a8af4,_0x1c5840){return _0x43c4(_0x2a8af4- -_0x596972._0x16bae7,_0x5c76f3);}function _0x4f63cf(_0x4f7603,_0xef96f6,_0x4324e9,_0x2f768e){return _0x43c4(_0x4f7603- -_0x29f1c8._0x228308,_0x4324e9);}return{...createOpenAiResponsesReasoning(_0x4d5053),'model':_0x4d5053[_0x4e0bde(_0x4f1307._0x158d1e,0x17,0xb,0x25)],'instructions':systemToInstructions(_0x4d5053[_0x4f63cf(-0x276,-0x262,-_0x4f1307._0x38453e,-0x259)]),'input':_0x286ae6,'max_output_tokens':_0x4d5053['maxTokens'],'tools':_0x4d5053[_0x4e0bde(_0x4f1307._0x4edf86,-_0x4f1307._0x18f4aa,0xc,0x12)][_0x4e0bde(_0x4f1307._0x5a084a,_0x4f1307._0xb95c53,0x2b,0x47)](_0x3929ed=>{const _0x3ff613={_0x2b66e5:0x39,_0x408568:0x10};function _0x14b7ec(_0x1db9bc,_0x544634,_0x12d5c7,_0x253c22){return _0x4f63cf(_0x1db9bc-0x109,_0x544634-_0x3ff613._0x2b66e5,_0x544634,_0x253c22-_0x3ff613._0x408568);}function _0x26dad8(_0x10fa18,_0xf5f51f,_0x5774cb,_0x579a57){return _0x4e0bde(_0x579a57,_0xf5f51f-_0x34df72._0x3d8c38,_0xf5f51f-_0x34df72._0x3ffcce,_0x579a57-_0x34df72._0x118887);}return{'type':_0x26dad8(_0x6c2035._0x331fb6,0x122,0x135,_0x6c2035._0x4826cc),'name':_0x3929ed[_0x26dad8(0x120,_0x6c2035._0x2d7a5f,0x125,0x118)],'description':_0x3929ed['description'],'parameters':_0x3929ed[_0x14b7ec(-_0x6c2035._0x472c98,-0x17d,-0x191,-_0x6c2035._0x2202e1)]};})};}export{toOpenAiResponsesRequest};
@@ -1 +1 @@
1
- (function(_0x56e05b,_0x59c654){const _0x248a3d={_0x593ce7:0x2ef,_0x11cae6:0x2e9,_0x44f4bb:0x2df,_0x2b989c:0x309,_0x18cba7:0x303,_0xb922f6:0x2ed,_0x49c206:0x2e4,_0x321411:0x285,_0x574160:0x304,_0x1b3d92:0x2f8,_0x2b6c16:0x27d,_0x53f458:0x25e,_0x1b9fa0:0x2ee,_0x1c3462:0x2fe,_0x1ca74c:0x2fa},_0xa239d6={_0x500a36:0x1f6},_0x419de6=_0x56e05b();function _0x237bb1(_0x391c32,_0x50a001,_0x40e14e,_0x440c44){return _0xd770(_0x50a001- -0x38c,_0x440c44);}function _0xc195b0(_0x331204,_0x569982,_0x199067,_0x53d341){return _0xd770(_0x53d341-_0xa239d6._0x500a36,_0x331204);}while(!![]){try{const _0x4f6a1b=-parseInt(_0x237bb1(-0x271,-0x27f,-0x291,-0x26c))/0x1*(parseInt(_0xc195b0(_0x248a3d._0x593ce7,_0x248a3d._0x11cae6,_0x248a3d._0x44f4bb,0x2e2))/0x2)+-parseInt(_0xc195b0(_0x248a3d._0x2b989c,0x30f,0x2f1,0x309))/0x3*(-parseInt(_0xc195b0(_0x248a3d._0x18cba7,0x30c,0x306,0x302))/0x4)+-parseInt(_0xc195b0(0x2ec,0x2f2,_0x248a3d._0xb922f6,_0x248a3d._0x49c206))/0x5+-parseInt(_0x237bb1(-_0x248a3d._0x321411,-0x291,-0x278,-0x27c))/0x6*(parseInt(_0xc195b0(0x2f3,_0x248a3d._0x574160,_0x248a3d._0x1b3d92,0x2fe))/0x7)+-parseInt(_0x237bb1(-_0x248a3d._0x2b6c16,-0x276,-0x25d,-_0x248a3d._0x53f458))/0x8+-parseInt(_0xc195b0(_0x248a3d._0x1b9fa0,_0x248a3d._0x1c3462,_0x248a3d._0x1c3462,_0x248a3d._0x1ca74c))/0x9+parseInt(_0xc195b0(0x2fb,0x2e7,0x2fa,_0x248a3d._0x1b9fa0))/0xa;if(_0x4f6a1b===_0x59c654)break;else _0x419de6['push'](_0x419de6['shift']());}catch(_0xf0c1){_0x419de6['push'](_0x419de6['shift']());}}}(_0x2d20,0xd0cb8));function createTextBlock(_0x9fe33b){return{'type':'text','text':_0x9fe33b};}function normalizeTextBlock(_0x232eaf){const _0x4d1380={_0x50ed0b:0x238,_0xc057e:0x229},_0x4f813e={_0x4d06c1:0x128};function _0x6d3380(_0xacf58b,_0x42c1ae,_0x4f1fb1,_0x214584){return _0xd770(_0x214584-_0x4f813e._0x4d06c1,_0xacf58b);}return createTextBlock(_0x232eaf[_0x6d3380(_0x4d1380._0x50ed0b,0x234,_0x4d1380._0xc057e,0x23d)]??'');}function normalizeContent(_0x39e78b){const _0x212bc5={_0x3d0547:0xba,_0x36f1ad:0x306,_0x4e3493:0x2f2,_0x24f292:0x2dd},_0x5021a8={_0x5e7bfc:0x6c};function _0x8af56b(_0x2b50aa,_0x54c5d4,_0x2a5ab9,_0x4a9bbc){return _0xd770(_0x2a5ab9-0x1e7,_0x2b50aa);}if(typeof _0x39e78b===_0x2a5de0(0xb8,0xad,0xac,_0x212bc5._0x3d0547))return[createTextBlock(_0x39e78b)];function _0x2a5de0(_0x531f75,_0x4fef42,_0xc7b72c,_0x43cca3){return _0xd770(_0x4fef42- -_0x5021a8._0x5e7bfc,_0x531f75);}if(!Array[_0x2a5de0(0xb3,0x9a,0x93,0xa4)](_0x39e78b))return[];return _0x39e78b[_0x8af56b(0x2ee,_0x212bc5._0x36f1ad,_0x212bc5._0x4e3493,_0x212bc5._0x24f292)](_0x16e69f=>{if(_0x16e69f['type']==='text')return normalizeTextBlock(_0x16e69f);return structuredClone(_0x16e69f);});}function normalizeSystem(_0x414e6b=[]){function _0x339a34(_0x386bff,_0x2d412f,_0x2ed531,_0x129410){return _0xd770(_0x2d412f-0x1c,_0x386bff);}return normalizeContent(_0x414e6b)['filter'](_0x7e4302=>_0x7e4302[_0x339a34(0x106,0x113,0x103,0x11d)]==='text');}function normalizeMessage(_0x875bd8){const _0x23f43c={_0x26337f:0x192,_0x496a6e:0x18b,_0x500d01:0x467,_0x3182b0:0x450,_0x7f7b48:0x169,_0x1e21b3:0x44b,_0x1da75f:0x471,_0x4b0cae:0x458},_0x22e210={_0xf76864:0x355};function _0x312fdc(_0x262b4b,_0x5eb1ff,_0x1b1eaf,_0x54d474){return _0xd770(_0x262b4b-0x64,_0x5eb1ff);}function _0x28279c(_0x566952,_0x18dd25,_0x46a4e5,_0x1ea1b6){return _0xd770(_0x46a4e5-_0x22e210._0xf76864,_0x18dd25);}return{...typeof _0x875bd8['id']===_0x312fdc(0x17d,_0x23f43c._0x26337f,0x18f,_0x23f43c._0x496a6e)?{'id':_0x875bd8['id']}:{},'role':_0x875bd8[_0x28279c(0x44d,_0x23f43c._0x500d01,0x452,_0x23f43c._0x3182b0)],'content':normalizeContent(_0x875bd8['content']),..._0x875bd8[_0x312fdc(0x167,0x181,0x157,_0x23f43c._0x7f7b48)]?{'providerState':structuredClone(_0x875bd8[_0x28279c(_0x23f43c._0x1e21b3,_0x23f43c._0x1da75f,_0x23f43c._0x4b0cae,0x45c)])}:{}};}function compileRequest(_0x5197e8){const _0x32576c={_0x50cedd:0x47b,_0x24e6d7:0x492,_0x3aa81d:0x467,_0x50c707:0x46e,_0x44ec8a:0x482,_0x3b1e70:0x480,_0x3bcf20:0x460,_0x55469e:0x29c,_0x39cab3:0x266,_0x2aada0:0x289,_0x3237c0:0x27f,_0x57e528:0x270,_0x1d1577:0x49c,_0x2f328a:0x48d},_0x7442bc={_0xd5c8b4:0x387},_0x3d6033={_0x58493c:0x36e};function _0x5804ad(_0x233c59,_0x24e0b9,_0x1075f4,_0x4c314d){return _0xd770(_0x1075f4-_0x3d6033._0x58493c,_0x233c59);}function _0x20c4fc(_0x4aa294,_0x3ef424,_0xdfaa85,_0x101a12){return _0xd770(_0xdfaa85- -_0x7442bc._0xd5c8b4,_0x3ef424);}return{'model':_0x5197e8['model']??_0x5804ad(0x485,_0x32576c._0x50cedd,0x47d,_0x32576c._0x24e6d7),'max_tokens':_0x5197e8[_0x5804ad(0x483,_0x32576c._0x3aa81d,_0x32576c._0x50c707,0x45c)]??0x400,..._0x5197e8[_0x5804ad(_0x32576c._0x44ec8a,_0x32576c._0x3b1e70,0x46a,_0x32576c._0x3bcf20)]?{'reasoning':structuredClone(_0x5197e8[_0x20c4fc(-_0x32576c._0x55469e,-0x2a2,-0x28b,-0x281)])}:{},'system':normalizeSystem(_0x5197e8['system']),'messages':_0x5197e8['messages'][_0x20c4fc(-_0x32576c._0x39cab3,-0x273,-0x27c,-0x270)](normalizeMessage),'tools':structuredClone(_0x5197e8[_0x20c4fc(-_0x32576c._0x2aada0,-_0x32576c._0x3237c0,-_0x32576c._0x57e528,-0x25a)]??[]),'metadata':{'session_id':_0x5197e8['sessionId'],'turn_id':_0x5197e8[_0x5804ad(_0x32576c._0x1d1577,0x493,0x489,_0x32576c._0x2f328a)]}};}function toChatRequest(_0x51dd2b){const _0x3bcb3b={_0x5e5945:0x213,_0x3be0a0:0x20d,_0x3f578f:0x1ef,_0x17375f:0x202,_0x21067e:0xf5,_0x11a0fc:0x109,_0x25e5fe:0x1e5,_0x22f5ed:0x1fb,_0x40f362:0x1de,_0x3a26cf:0x203,_0x448998:0x1ee,_0x4ebc3a:0x11a,_0x12c031:0x104,_0x55d6ef:0x1d5};function _0xa6f6ea(_0xda6109,_0x387b6a,_0x58b2ff,_0x356c29){return _0xd770(_0x58b2ff- -0x205,_0x356c29);}function _0xd674bc(_0x57b6fb,_0x1bd01e,_0x4836c6,_0x4be61d){return _0xd770(_0x4be61d- -0x2fe,_0x4836c6);}return{'model':_0x51dd2b['model'],'maxTokens':_0x51dd2b[_0xd674bc(-0x203,-_0x3bcb3b._0x5e5945,-_0x3bcb3b._0x3be0a0,-0x1fe)],..._0x51dd2b[_0xd674bc(-0x20c,-_0x3bcb3b._0x3f578f,-0x204,-_0x3bcb3b._0x17375f)]?{'reasoning':structuredClone(_0x51dd2b[_0xa6f6ea(-_0x3bcb3b._0x21067e,-0x115,-_0x3bcb3b._0x11a0fc,-0x10d)])}:{},'system':structuredClone(_0x51dd2b['system']),'messages':structuredClone(_0x51dd2b['messages']),'tools':structuredClone(_0x51dd2b[_0xd674bc(-_0x3bcb3b._0x25e5fe,-0x1ee,-0x1cd,-0x1e7)]),'metadata':{'sessionId':_0x51dd2b[_0xd674bc(-_0x3bcb3b._0x22f5ed,-_0x3bcb3b._0x40f362,-_0x3bcb3b._0x3a26cf,-_0x3bcb3b._0x448998)][_0xa6f6ea(-_0x3bcb3b._0x4ebc3a,-0xf3,-_0x3bcb3b._0x12c031,-0x104)],'turnId':_0x51dd2b[_0xd674bc(-_0x3bcb3b._0x55d6ef,-0x1f9,-0x1d4,-0x1ee)]['turn_id']}};}function _0x2d20(){const _0xb89d59=['C3LZDgvT','Bwf4x3rVA2vUCW','C2vZC2LVBL9Pza','Bwf4vg9Rzw5Z','ChjVDMLKzxjtDgf0zq','mJCZnJuXm2joDgDiAq','AM9PBG','AxnbCNjHEq','yw50AhjVCgLJx3jLzgfJDgvKx3rOAw5RAw5N','mtG2mZr6C2rsCha','B3v0Chv0vg9Rzw5Z','Dg9VBf9Yzxn1Bhq','BwfW','mtjyB21dCg4','nZK3Ewjty0PI','Aw5WDxrFDg9Rzw5Z','y2XHDwrLlxnVBM5LDc00ltiWmJuWnte0','Bwv0ywrHDge','CMvHC29UAw5Nvg9Rzw5Z','B3v0Chv0','mteZmJm4ovHzzwjpsG','Dg9VBf91C2u','Dgv4Da','otaWnduZnLrLuejfEq','Dg9VBhm','Bw9KzwW','C3rYAw5N','yw50AhjVCgLJx3rOAw5RAw5N','DhvYBKLK','DxnLCG','khjLzgfJDgvKihjLyxnVBMLUzYK','yxnZAxn0yw50','zMLSDgvY','mZy3ngH6uhLwuG','DxnHz2u','nJqXmJu3nwjczxH1Ba','DhjPBq','B3bLBMfPx3jLyxnVBMLUzW','C2vZC2LVBKLK','y2fSBeLK','BgvUz3rO','BwvZC2fNzxm','C3rVCfjLyxnVBG','zMXHDe1HCa','DhLWzq','nde1ndyXntbZEgnjvuO','DgHPBMTPBMC','C3rHDhvZ','ntC2B0L5surQ','CMvHC29UAw5N','CM9Szq','y29UDgvUDa'];_0x2d20=function(){return _0xb89d59;};return _0x2d20();}function toModelRequest(_0x352455){const _0x32ff18={_0x54a6c1:0x2d3,_0x454f0c:0x2ec,_0x5d7b36:0x2c3,_0x4d749c:0x2bf,_0x5846fd:0x2c0,_0x5c2553:0x2f6,_0x1f4b57:0x2d9,_0x477da4:0x2e7,_0x135505:0x2e4,_0x1f203c:0x304};function _0x24ae33(_0x30dd87,_0x1d514f,_0xca634c,_0x567b9b){return _0xd770(_0x1d514f-0x190,_0xca634c);}function _0x258e8d(_0x211e42,_0x399ad3,_0xf19f2c,_0x59497c){return _0xd770(_0x211e42-0x1d7,_0x59497c);}return{'model':_0x352455[_0x258e8d(0x2ef,0x301,0x2d6,0x2db)],'max_tokens':_0x352455['maxTokens'],..._0x352455[_0x258e8d(_0x32ff18._0x54a6c1,0x2cc,_0x32ff18._0x454f0c,_0x32ff18._0x5d7b36)]?{'reasoning':structuredClone(_0x352455['reasoning'])}:{},'system':structuredClone(_0x352455[_0x258e8d(0x2d6,0x2c8,0x2e1,0x2d6)]),'messages':structuredClone(_0x352455[_0x258e8d(0x2cb,_0x32ff18._0x4d749c,0x2d8,0x2bf)]),'tools':structuredClone(_0x352455[_0x24ae33(_0x32ff18._0x5846fd,0x2a7,0x2a8,0x28e)]),'metadata':{'session_id':_0x352455[_0x258e8d(0x2e7,0x2e9,0x2e1,_0x32ff18._0x5c2553)][_0x258e8d(0x2c8,0x2df,0x2d3,0x2b3)],'turn_id':_0x352455[_0x258e8d(0x2e7,0x2f9,_0x32ff18._0x1f4b57,_0x32ff18._0x477da4)][_0x258e8d(0x2f2,_0x32ff18._0x135505,0x2fd,_0x32ff18._0x1f203c)]}};}function toProviderModelRequest(_0x3cace3){const _0x485bfb={_0x44de2a:0x3d2,_0x10ccfe:0x3eb,_0x14a0e6:0x3bf,_0x1c8e45:0x3cf,_0x3cf6fc:0x3c3,_0x5ee597:0x3be,_0x8f6b8e:0x3cc,_0x3c760f:0x3d8,_0x564d82:0x3e4};function _0x380e24(_0x25fbbb,_0x4131fe,_0x44aa55,_0x3e6b35){return _0xd770(_0x3e6b35-0x2cd,_0x25fbbb);}function _0x24cd14(_0x46d1b5,_0x1a6039,_0x1ebdb7,_0x3a07d4){return _0xd770(_0x46d1b5- -0x1de,_0x1ebdb7);}return{'model':_0x3cace3[_0x380e24(_0x485bfb._0x44de2a,_0x485bfb._0x10ccfe,0x3f8,0x3e5)],'max_tokens':_0x3cace3[_0x380e24(_0x485bfb._0x14a0e6,0x3c9,0x3cc,_0x485bfb._0x1c8e45)],'system':structuredClone(_0x3cace3[_0x380e24(_0x485bfb._0x3cf6fc,0x3cf,_0x485bfb._0x5ee597,_0x485bfb._0x8f6b8e)]),'messages':structuredClone(_0x3cace3['messages']),'tools':structuredClone(_0x3cace3[_0x380e24(0x3ee,0x3ea,_0x485bfb._0x3c760f,_0x485bfb._0x564d82)])};}function toChatResponse(_0x3252b7){const _0x414bde={_0x433774:0x5a,_0x36ccdd:0x4f,_0x33867b:0x6b,_0x5ba355:0x46a,_0x2b3587:0x484,_0x5c6d99:0x59,_0x47e108:0x457,_0x4d8122:0x482,_0x1d97b6:0x46a,_0x3b251e:0x465,_0x5955fa:0x58,_0x1d5255:0x77,_0x44b0a2:0x55,_0x58939f:0x4a,_0x18ce8f:0x3e,_0x398a6a:0x45,_0x4618f8:0x4e},_0x1f3489={_0x277314:0x37d},_0x471946={_0x54d5bf:0x158};function _0x39a649(_0x2bb948,_0x4f832e,_0x24d7b6,_0x425025){return _0xd770(_0x2bb948- -_0x471946._0x54d5bf,_0x425025);}function _0x1d4cea(_0x3f5394,_0x2180d6,_0x96c4a,_0x411f9a){return _0xd770(_0x3f5394-_0x1f3489._0x277314,_0x411f9a);}return{'id':_0x3252b7['id'],'content':structuredClone(_0x3252b7[_0x39a649(-_0x414bde._0x433774,-_0x414bde._0x36ccdd,-0x56,-_0x414bde._0x33867b)]),'stopReason':_0x3252b7['stop_reason'],'usage':{'inputTokens':_0x3252b7[_0x1d4cea(_0x414bde._0x5ba355,0x457,0x464,_0x414bde._0x2b3587)][_0x39a649(-0x4a,-_0x414bde._0x5c6d99,-0x34,-_0x414bde._0x433774)],'outputTokens':_0x3252b7[_0x1d4cea(0x46a,_0x414bde._0x47e108,_0x414bde._0x4d8122,_0x414bde._0x1d97b6)]['output_tokens'],..._0x3252b7[_0x1d4cea(0x46a,_0x414bde._0x3b251e,0x453,0x454)]['reasoning_tokens']!==void 0x0?{'reasoningTokens':_0x3252b7[_0x39a649(-0x6b,-0x59,-_0x414bde._0x5955fa,-_0x414bde._0x1d5255)]['reasoning_tokens']}:{}},..._0x3252b7[_0x39a649(-_0x414bde._0x44b0a2,-_0x414bde._0x58939f,-0x57,-0x58)]?{'providerState':structuredClone(_0x3252b7[_0x39a649(-_0x414bde._0x44b0a2,-_0x414bde._0x18ce8f,-_0x414bde._0x398a6a,-_0x414bde._0x4618f8)])}:{}};}function toModelResponse(_0x57d85f){const _0x323855={_0x10f28e:0x73,_0x10341d:0x71,_0x642339:0x4c8,_0x5c11f0:0x4d7,_0x1692d2:0x4df,_0x3460cb:0x7b,_0x12db29:0xa9,_0x4606c9:0x8d,_0xe4eb7e:0xa9,_0x50c3e7:0x90,_0x2c892d:0xa0,_0x1cf685:0x7c,_0xb5ec75:0x60,_0x59754b:0x74,_0x3bd551:0x7d,_0xe944fb:0x4b7,_0x38361:0x4bf,_0x33fed0:0x6e,_0x1ac775:0x5c,_0x5406e6:0xa7,_0x5d397a:0x7c,_0x2a1f98:0x90,_0x3e06e4:0x4ee,_0x2f4868:0x4e0,_0x4b75fe:0x7b,_0x329474:0x7a,_0x49a772:0x67};function _0xcbba46(_0x3497c0,_0x55bc65,_0x4388c8,_0x44e859){return _0xd770(_0x3497c0-0x3ca,_0x44e859);}function _0x2283f9(_0x272296,_0x25a2d6,_0x1f7355,_0x39dc64){return _0xd770(_0x1f7355- -0x17d,_0x25a2d6);}return{'id':_0x57d85f['id'],'type':'message','role':_0x2283f9(-0x57,-_0x323855._0x10f28e,-0x5f,-_0x323855._0x10341d),'content':structuredClone(_0x57d85f[_0xcbba46(_0x323855._0x642339,0x4b9,_0x323855._0x5c11f0,_0x323855._0x1692d2)]),'stop_reason':_0x57d85f[_0x2283f9(-_0x323855._0x3460cb,-0xa2,-0x88,-0x9b)],'stop_sequence':null,'usage':{'input_tokens':_0x57d85f[_0x2283f9(-_0x323855._0x12db29,-0x98,-0x90,-_0x323855._0x4606c9)]['inputTokens'],'output_tokens':_0x57d85f[_0x2283f9(-_0x323855._0xe4eb7e,-0x98,-_0x323855._0x50c3e7,-_0x323855._0x2c892d)][_0x2283f9(-_0x323855._0x1cf685,-_0x323855._0xb5ec75,-_0x323855._0x59754b,-_0x323855._0x3bd551)],..._0x57d85f[_0xcbba46(_0x323855._0xe944fb,0x4ba,_0x323855._0x38361,0x4bb)][_0x2283f9(-_0x323855._0x33fed0,-0x5f,-0x6c,-_0x323855._0x1ac775)]!==void 0x0?{'reasoning_tokens':_0x57d85f[_0x2283f9(-_0x323855._0x5406e6,-_0x323855._0x5d397a,-_0x323855._0x2a1f98,-0x92)][_0xcbba46(0x4db,_0x323855._0x3e06e4,_0x323855._0x2f4868,0x4c1)]}:{}},..._0x57d85f['providerState']?{'providerState':structuredClone(_0x57d85f[_0x2283f9(-_0x323855._0x4b75fe,-0x6f,-_0x323855._0x329474,-_0x323855._0x49a772)])}:{}};}function responseToAssistantMessage(_0xaa5795){const _0x264ff3={_0x4113c5:0x22,_0xf6c6be:0x32,_0x4cb2d0:0x23,_0x282a60:0x64,_0x58a0b5:0x60,_0x1ea1f3:0x50},_0xe6e54={_0x3cd0f2:0xae};function _0x2f184b(_0x276471,_0x7f658c,_0x2efd31,_0x3ad680){return _0xd770(_0x2efd31- -_0xe6e54._0x3cd0f2,_0x7f658c);}function _0x102b62(_0x27cd92,_0x4ddfc8,_0x27cc10,_0x1c99a4){return _0xd770(_0x27cc10- -0x141,_0x27cd92);}return{'role':_0x102b62(-_0x264ff3._0x4113c5,-_0x264ff3._0xf6c6be,-_0x264ff3._0x4cb2d0,-0x20),'content':normalizeContent(_0xaa5795[_0x2f184b(_0x264ff3._0x282a60,_0x264ff3._0x58a0b5,_0x264ff3._0x1ea1f3,0x4b)]),..._0xaa5795['providerState']?{'providerState':structuredClone(_0xaa5795['providerState'])}:{}};}function createReasoningMessage(_0x256978){const _0x765537={_0x12335a:0x31,_0x395135:0x3e,_0x1df354:0x5d,_0x43baa0:0x295,_0x3dc471:0x2a7},_0x2e7b42={_0xc9eb31:0x2da,_0x31f109:0x2d9,_0x49b362:0x2c6,_0x3a6898:0x2be,_0x45f70f:0x2ac,_0xc79935:0x2c2},_0x3cd0c9={_0x382053:0x42,_0x323b72:0xda},_0x2fe3d9={_0x3a3e4f:0x388};function _0x2e46b7(_0x5e2498,_0x246ced,_0x58a141,_0x192c86){return _0xd770(_0x58a141- -_0x2fe3d9._0x3a3e4f,_0x246ced);}const _0x102235=normalizeContent(_0x256978?.[_0x4bd28f(0x25,_0x765537._0x12335a,0x4b,_0x765537._0x395135)])[_0x4bd28f(0x69,_0x765537._0x1df354,0x54,0x5f)](_0x48b507=>{const _0x434e04={_0x48b64a:0x697,_0x584e51:0x18b};function _0x547f66(_0x30eca2,_0x3cc76b,_0x54e736,_0x11a01f){return _0x2e46b7(_0x30eca2-0x3,_0x11a01f,_0x30eca2-_0x434e04._0x48b64a,_0x11a01f-_0x434e04._0x584e51);}function _0x182503(_0x3a2f3e,_0x376da8,_0x44e400,_0x2aa161){return _0x2e46b7(_0x3a2f3e-0x16b,_0x2aa161,_0x44e400- -_0x3cd0c9._0x382053,_0x2aa161-_0x3cd0c9._0x323b72);}return _0x48b507['type']===_0x182503(-_0x2e7b42._0xc9eb31,-_0x2e7b42._0x31f109,-0x2c3,-0x2bb)||_0x48b507['type']===_0x182503(-_0x2e7b42._0x49b362,-_0x2e7b42._0x3a6898,-0x2b0,-_0x2e7b42._0x45f70f)||_0x48b507[_0x182503(-_0x2e7b42._0xc79935,-0x2e0,-0x2d3,-0x2e4)]==='openai_reasoning';});if(_0x102235[_0x2e46b7(-0x2ac,-0x288,-_0x765537._0x43baa0,-_0x765537._0x3dc471)]===0x0)return void 0x0;function _0x4bd28f(_0x3f529b,_0x2056a3,_0x55eb0e,_0x282a41){return _0xd770(_0x282a41- -0xc0,_0x3f529b);}return{'role':_0x4bd28f(0x4c,0x6e,0x46,0x5e),'content':_0x102235};}function _0xd770(_0x4fb7af,_0xc97000){_0x4fb7af=_0x4fb7af-0xec;const _0x2d201e=_0x2d20();let _0xd7705f=_0x2d201e[_0x4fb7af];if(_0xd770['llmSTJ']===undefined){var _0x216c97=function(_0x1ac628){const _0xd39e5b='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x9fe33b='',_0x232eaf='';for(let _0x39e78b=0x0,_0x16e69f,_0x414e6b,_0x7e4302=0x0;_0x414e6b=_0x1ac628['charAt'](_0x7e4302++);~_0x414e6b&&(_0x16e69f=_0x39e78b%0x4?_0x16e69f*0x40+_0x414e6b:_0x414e6b,_0x39e78b++%0x4)?_0x9fe33b+=String['fromCharCode'](0xff&_0x16e69f>>(-0x2*_0x39e78b&0x6)):0x0){_0x414e6b=_0xd39e5b['indexOf'](_0x414e6b);}for(let _0x875bd8=0x0,_0x5197e8=_0x9fe33b['length'];_0x875bd8<_0x5197e8;_0x875bd8++){_0x232eaf+='%'+('00'+_0x9fe33b['charCodeAt'](_0x875bd8)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x232eaf);};_0xd770['cQwAHD']=_0x216c97,_0xd770['arPJUF']={},_0xd770['llmSTJ']=!![];}const _0x1438b6=_0x2d201e[0x0],_0x5e76e9=_0x4fb7af+_0x1438b6,_0x2eb14e=_0xd770['arPJUF'][_0x5e76e9];return!_0x2eb14e?(_0xd7705f=_0xd770['cQwAHD'](_0xd7705f),_0xd770['arPJUF'][_0x5e76e9]=_0xd7705f):_0xd7705f=_0x2eb14e,_0xd7705f;}function createAssistantTextMessage(_0x4ad27c){const _0x62eae0={_0x566ed1:0x1ae,_0x55e39d:0x1e9,_0x3fba0f:0x3a7,_0x125694:0x3a8,_0x43a8ca:0x3d1,_0x4f703f:0x3bd,_0x2d70a0:0x3d3},_0x2c46e9={_0xc1cca2:0x11a,_0x3207b8:0x12f,_0x41f200:0x2bd,_0x3e6186:0x2cd},_0xcd7d74={_0x5e4475:0x9d},_0x4dbe17=normalizeContent(_0x4ad27c?.[_0x4104b6(0x1bc,0x1c9,_0x62eae0._0x566ed1,0x1c3)])[_0x4104b6(0x1dd,0x1c8,0x1ef,_0x62eae0._0x55e39d)](_0x3e7ce5=>{const _0x3d6ae9={_0x706c32:0x10b};function _0x48e990(_0x4b2629,_0xa30b9b,_0x55932d,_0x405e93){return _0x39ad93(_0x55932d,_0xa30b9b-0xdf,_0x55932d-_0xcd7d74._0x5e4475,_0xa30b9b- -0x4d5);}function _0x1726fb(_0x5ac4c9,_0x2a57fd,_0x5477cc,_0x298cd1){return _0x39ad93(_0x5ac4c9,_0x2a57fd-0xda,_0x5477cc-0x1bd,_0x2a57fd- -_0x3d6ae9._0x706c32);}return _0x3e7ce5[_0x48e990(-0x112,-0x129,-_0x2c46e9._0xc1cca2,-_0x2c46e9._0x3207b8)]===_0x1726fb(_0x2c46e9._0x41f200,0x2bf,0x2d3,_0x2c46e9._0x3e6186);});function _0x4104b6(_0x32b78e,_0x3acad7,_0x4366c9,_0x53fa7f){return _0xd770(_0x32b78e-0xbe,_0x4366c9);}if(_0x4dbe17[_0x39ad93(0x390,_0x62eae0._0x3fba0f,0x3b9,_0x62eae0._0x125694)]===0x0)return void 0x0;function _0x39ad93(_0x33a9d0,_0x3902af,_0x49bf0b,_0x178801){return _0xd770(_0x178801-0x2b5,_0x33a9d0);}return{'role':_0x39ad93(0x3e7,_0x62eae0._0x43a8ca,_0x62eae0._0x4f703f,_0x62eae0._0x2d70a0),'content':_0x4dbe17};}function createToolUseMessage(_0x27e365){const _0x278439={_0x4849c8:0x161,_0x120274:0x15c,_0x4ce5a8:0x149,_0x3a217e:0x1fc,_0x301d76:0x206},_0x593b73={_0x581cc8:0x321},_0x263933={_0x2c7e4a:0x24f},_0x4b01df={_0x3a71ed:0x1d7},_0x364dd8=normalizeContent(_0x27e365?.[_0x184f1d(-_0x278439._0x4849c8,-0x15c,-0x151,-_0x278439._0x120274)])[_0x184f1d(-0x13f,-_0x278439._0x4ce5a8,-0x130,-0x11d)](_0x5d9bc1=>{const _0x1e9759={_0x5bfc9e:0x24,_0x152c43:0x335,_0x35f494:0xfe};function _0x50c7f7(_0x4fb1e3,_0xd196fd,_0x5ace41,_0x5c3561){return _0x184f1d(_0x4fb1e3-_0x1e9759._0x5bfc9e,_0x5ace41,_0x4fb1e3-_0x1e9759._0x152c43,_0x5c3561-_0x1e9759._0x35f494);}function _0x5cc2ae(_0x2cbaeb,_0xd7809c,_0x119c0b,_0x235c9e){return _0x4d8628(_0x2cbaeb-0x15b,_0x235c9e- -0x51,_0x119c0b,_0x235c9e-0x1b2);}return _0x5d9bc1[_0x50c7f7(0x1dd,0x1f6,0x1cc,_0x4b01df._0x3a71ed)]===_0x50c7f7(0x1fa,0x1f6,0x20f,0x1f7);});function _0x184f1d(_0xdd4512,_0x3f1731,_0x382813,_0x1ec3fd){return _0xd770(_0x382813- -_0x263933._0x2c7e4a,_0x3f1731);}function _0x4d8628(_0x248f8b,_0x441b35,_0x12300e,_0x342d91){return _0xd770(_0x441b35- -_0x593b73._0x581cc8,_0x12300e);}if(_0x364dd8['length']===0x0)return void 0x0;return{'role':_0x4d8628(-_0x278439._0x3a217e,-0x203,-0x1ff,-_0x278439._0x301d76),'content':_0x364dd8};}function getTextFromMessage(_0x2d0d43){const _0x1d4afb={_0x26455c:0x116,_0x17987b:0xfd},_0x5dabc4={_0x389040:0xb};function _0x469114(_0x2c0199,_0x3e8f69,_0x529352,_0x259025){return _0xd770(_0x2c0199-_0x5dabc4._0x389040,_0x529352);}function _0x440272(_0x4087e3,_0x4f360e,_0x2f8358,_0x4529a5){return _0xd770(_0x4529a5-0x252,_0x4087e3);}return normalizeContent(_0x2d0d43?.['content'])['filter'](_0xe2e5d1=>_0xe2e5d1[_0x440272(0x338,0x34b,0x340,0x349)]===_0x469114(0x120,0x132,0x12b,0x139))[_0x469114(_0x1d4afb._0x26455c,0x11b,0x102,_0x1d4afb._0x17987b)](_0x566106=>_0x566106['text'])['join']('\x0a');}function getReasoningTextFromMessage(_0xa9d5e2){const _0x3c2324={_0x1c3ac1:0x2dc,_0x1db1bd:0x2d1,_0x525d53:0x2e1,_0x43911e:0x2d0,_0x597224:0x2cf,_0x483878:0x2d2,_0x2b027d:0x2c8},_0x44396d={_0x400d1b:0x148,_0x46a3fc:0x12b,_0x2b2e48:0x143,_0x3f3286:0x15a,_0x2cf133:0x12f,_0xbf1f20:0x133,_0x5ac5bf:0x133,_0x464ee8:0x2d8,_0x45a82c:0x2c1,_0x3b2efe:0x2ae,_0x57bee5:0x297,_0x42d58e:0x2d4,_0x190c3f:0x2d9,_0x1c5993:0x2f3,_0x33652a:0x2d3,_0x40ec36:0x14e,_0x158c23:0x176,_0x36ecc0:0x153,_0x15848b:0x145,_0x59c385:0x139,_0x55cdb2:0x155,_0x4b93a6:0x2ba,_0x50a8d2:0x29c,_0x88fde6:0x2b0,_0xfce894:0x2b5,_0x228bc5:0x2b6,_0x2e9c70:0x2a0},_0x1c8f35={_0x2822ee:0x417,_0x2cb0b8:0x37},_0x1685fb={_0x3c2915:0x3d7};function _0x251e85(_0x262ad3,_0xd47cd1,_0xe708a8,_0x26e1e3){return _0xd770(_0x262ad3- -_0x1685fb._0x3c2915,_0xe708a8);}function _0x583ab5(_0x23d8a9,_0x326298,_0x3b06c2,_0x2eb5f5){return _0xd770(_0x3b06c2- -0x272,_0x23d8a9);}return normalizeContent(_0xa9d5e2?.[_0x251e85(-0x2d9,-_0x3c2324._0x1c3ac1,-_0x3c2324._0x1db1bd,-0x2f2)])[_0x251e85(-_0x3c2324._0x525d53,-_0x3c2324._0x43911e,-_0x3c2324._0x597224,-0x2dc)](_0xcf2f48=>{const _0x73be39={_0x15f967:0x17e};function _0x198ac6(_0x57cd6c,_0x5493c9,_0x2db2cb,_0x2e8ac3){return _0x251e85(_0x5493c9-0xc,_0x5493c9-_0x73be39._0x15f967,_0x2db2cb,_0x2e8ac3-0xf2);}function _0x56ef96(_0x482727,_0x11b737,_0x251d48,_0x3ce574){return _0x251e85(_0x251d48-_0x1c8f35._0x2822ee,_0x11b737-_0x1c8f35._0x2cb0b8,_0x482727,_0x3ce574-0x94);}if(_0xcf2f48[_0x56ef96(_0x44396d._0x400d1b,_0x44396d._0x46a3fc,0x137,_0x44396d._0x2b2e48)]===_0x56ef96(0x172,0x170,_0x44396d._0x3f3286,0x14e))return _0xcf2f48['thinking'][_0x56ef96(0x12a,0x138,_0x44396d._0x2cf133,0x119)]()[_0x56ef96(_0x44396d._0xbf1f20,0x12f,_0x44396d._0x5ac5bf,0x13b)]>0x0?[_0xcf2f48[_0x198ac6(-0x2dd,-0x2d2,-_0x44396d._0x464ee8,-_0x44396d._0x45a82c)]]:[];if(_0xcf2f48['type']==='anthropic_redacted_thinking')return[_0x198ac6(-0x2c2,-_0x44396d._0x3b2efe,-0x2ab,-_0x44396d._0x57bee5)];if(_0xcf2f48[_0x198ac6(-0x2dc,-_0x44396d._0x42d58e,-0x2d4,-_0x44396d._0x190c3f)]!==_0x198ac6(-_0x44396d._0x1c5993,-0x2db,-_0x44396d._0x33652a,-0x2cb))return[];const _0x273a6c=_0xcf2f48['summary']['map'](_0xf15c48=>_0xf15c48[_0x56ef96(0x157,0x15c,0x155,0x153)])[_0x56ef96(_0x44396d._0x40ec36,_0x44396d._0x158c23,0x15f,0x172)](_0x2f581a=>_0x2f581a[_0x198ac6(-0x2d8,-0x2dc,-0x2dc,-0x2ea)]()['length']>0x0)[_0x56ef96(_0x44396d._0x36ecc0,0x15f,_0x44396d._0x15848b,0x130)]('\x0a\x0a');if(_0x273a6c[_0x56ef96(0x11e,_0x44396d._0x59c385,0x133,0x134)]>0x0)return[_0x273a6c];if(_0xcf2f48[_0x56ef96(0x142,0x154,_0x44396d._0x55cdb2,0x140)]&&_0xcf2f48[_0x198ac6(-_0x44396d._0x4b93a6,-0x2b6,-_0x44396d._0x50a8d2,-_0x44396d._0x88fde6)]['trim']()[_0x56ef96(0x13c,_0x44396d._0x400d1b,0x133,0x140)]>0x0)return[_0xcf2f48[_0x198ac6(-_0x44396d._0xfce894,-_0x44396d._0x228bc5,-_0x44396d._0x2e9c70,-0x2d0)]];return _0xcf2f48['encryptedContent']?['(encrypted\x20reasoning)']:[];})[_0x251e85(-_0x3c2324._0x483878,-0x2c5,-_0x3c2324._0x2b027d,-0x2dd)]('\x0a\x0a');}function getToolUseBlocks(_0x3b4258){const _0x1c80a4={_0x5ed878:0x39,_0x4e1d20:0x28,_0x3c1df5:0x25,_0x1eac88:0x49,_0x4fa727:0x2f,_0xadd146:0x3b},_0x28c246={_0xe4db3b:0x3d9};function _0x814b79(_0x219d31,_0x123a52,_0x5b1e9b,_0x3bec5e){return _0xd770(_0x3bec5e-_0x28c246._0xe4db3b,_0x219d31);}function _0x5916ca(_0x2a9785,_0x255e40,_0x7669ce,_0x46dec4){return _0xd770(_0x255e40- -0xd6,_0x46dec4);}return normalizeContent(_0x3b4258?.[_0x5916ca(_0x1c80a4._0x5ed878,_0x1c80a4._0x4e1d20,_0x1c80a4._0x3c1df5,0x37)])[_0x5916ca(0x55,_0x1c80a4._0x1eac88,_0x1c80a4._0x4fa727,_0x1c80a4._0xadd146)](_0x15c663=>_0x15c663[_0x814b79(0x4c1,0x4ce,0x4db,0x4d0)]==='tool_use');}function getToolResultBlocks(_0x26058c){const _0x13e837={_0x545afa:0x79,_0x2538c4:0x93},_0x23aa69={_0x44984f:0x1b2},_0x1de572={_0xb6c6d9:0x83};function _0x58c2f1(_0x33633d,_0x4f6212,_0x192226,_0x5245a6){return _0xd770(_0x192226-_0x1de572._0xb6c6d9,_0x33633d);}function _0x1805d3(_0x14a294,_0x131b2e,_0xaf7c5b,_0x4ed328){return _0xd770(_0xaf7c5b- -_0x23aa69._0x44984f,_0x14a294);}return normalizeContent(_0x26058c?.['content'])[_0x1805d3(-0x89,-_0x13e837._0x545afa,-_0x13e837._0x2538c4,-0x8e)](_0x58bd36=>_0x58bd36[_0x58c2f1(0x187,0x189,0x17a,0x182)]===_0x58c2f1(0x185,0x176,0x18d,0x17a));}function createToolResultUserMessage(_0x3eb91e){const _0x8d747b={_0x2bd97f:0x4c1,_0x5e2724:0x4ab,_0x59be46:0xc3,_0x5018eb:0x95,_0x15489f:0xc2},_0x3239fd={_0x1a2454:0xcc,_0x2243a1:0xc8,_0x1b4666:0x23,_0x2ce8a8:0x3d,_0x5624ab:0x23,_0x101378:0xa8,_0x8dfae7:0x4a,_0x37ab2c:0x41,_0x3ee78c:0x3e},_0x20dd31={_0x3a9e36:0x40};function _0x5eadc4(_0x38a70d,_0x3ec471,_0x25ac3d,_0x411362){return _0xd770(_0x411362-0x38b,_0x3ec471);}function _0xc147f0(_0xc58099,_0xaf6073,_0x290fd0,_0x8c9d1b){return _0xd770(_0x8c9d1b- -0x60,_0xc58099);}return{'role':_0x5eadc4(_0x8d747b._0x2bd97f,0x4aa,_0x8d747b._0x5e2724,0x4a7),'content':_0x3eb91e[_0xc147f0(_0x8d747b._0x59be46,_0x8d747b._0x5018eb,_0x8d747b._0x15489f,0xab)](_0x10c1c6=>{const _0x21eb72={_0x1a161f:0x58};function _0x582182(_0x2525ee,_0x398f16,_0x2cec4a,_0xb83c7c){return _0xc147f0(_0xb83c7c,_0x398f16-_0x21eb72._0x1a161f,_0x2cec4a-0xf6,_0x2cec4a- -0xdb);}function _0x15cc63(_0x32ca8d,_0x448604,_0x2fe26b,_0x3abf92){return _0x5eadc4(_0x32ca8d-0x140,_0x2fe26b,_0x2fe26b-_0x20dd31._0x3a9e36,_0x3abf92- -0x545);}return{'type':_0x15cc63(-0xb3,-0xbb,-0xc6,-0xb0),'tool_use_id':_0x10c1c6[_0x15cc63(-0xc1,-_0x3239fd._0x1a2454,-0xd9,-_0x3239fd._0x2243a1)],'content':_0x10c1c6[_0x582182(-0x4a,-_0x3239fd._0x1b4666,-_0x3239fd._0x2ce8a8,-_0x3239fd._0x5624ab)]??_0x10c1c6[_0x15cc63(-0xa2,-0x93,-0xb7,-_0x3239fd._0x101378)],'is_error':_0x10c1c6[_0x582182(-0x37,-_0x3239fd._0x8dfae7,-_0x3239fd._0x37ab2c,-_0x3239fd._0x3ee78c)]==='error'};})};}export{createTextBlock,normalizeTextBlock,normalizeContent,normalizeSystem,normalizeMessage,compileRequest,toChatRequest,toModelRequest,toProviderModelRequest,toChatResponse,toModelResponse,responseToAssistantMessage,createReasoningMessage,createAssistantTextMessage,createToolUseMessage,getTextFromMessage,getReasoningTextFromMessage,getToolUseBlocks,getToolResultBlocks,createToolResultUserMessage};
1
+ (function(_0x3c388d,_0xf0cbf5){const _0x100a71={_0xf54a8a:0x239,_0x2533b9:0x22d,_0x5999b4:0x230,_0x4d71b3:0xa,_0x528707:0x2f,_0x432e9c:0x240,_0x317c0c:0x239,_0x19d2cb:0x23e,_0x591680:0x251,_0x331d86:0x251,_0x2d9566:0x15,_0x5e4ae8:0x25,_0x5ebad5:0x37,_0xef0c33:0x30,_0x5a1bc6:0x29,_0x22311c:0x238,_0x5ecd44:0x24f,_0x5b2a52:0x24e,_0x211f72:0x257,_0x144a93:0x229,_0x37157a:0x229,_0x2af85e:0x5e,_0x3c7884:0x241},_0x21d85f={_0x42bca6:0x12e};function _0xb2d9e1(_0x415773,_0x32274e,_0x45062c,_0x7bccdf){return _0x584d(_0x415773-0xd9,_0x7bccdf);}const _0x42c202=_0x3c388d();function _0x5ab78b(_0x1fe330,_0x10d2c3,_0x3ca648,_0x262fc7){return _0x584d(_0x3ca648- -_0x21d85f._0x42bca6,_0x262fc7);}while(!![]){try{const _0x2ccd3b=-parseInt(_0xb2d9e1(_0x100a71._0xf54a8a,_0x100a71._0x2533b9,_0x100a71._0x5999b4,0x21c))/0x1+parseInt(_0x5ab78b(0x36,_0x100a71._0x4d71b3,0x1f,_0x100a71._0x528707))/0x2+-parseInt(_0xb2d9e1(_0x100a71._0x432e9c,0x258,_0x100a71._0x317c0c,_0x100a71._0x19d2cb))/0x3*(-parseInt(_0xb2d9e1(_0x100a71._0x591680,_0x100a71._0x331d86,0x252,0x26c))/0x4)+parseInt(_0x5ab78b(0x2c,_0x100a71._0x2d9566,_0x100a71._0x5e4ae8,0x36))/0x5*(parseInt(_0x5ab78b(_0x100a71._0x5ebad5,0x39,_0x100a71._0xef0c33,_0x100a71._0x5a1bc6))/0x6)+-parseInt(_0x5ab78b(0x44,0x2d,0x2d,0x3f))/0x7*(parseInt(_0xb2d9e1(_0x100a71._0x22311c,0x22e,_0x100a71._0x5ecd44,0x252))/0x8)+parseInt(_0xb2d9e1(_0x100a71._0x5b2a52,_0x100a71._0x22311c,0x24d,_0x100a71._0x211f72))/0x9*(parseInt(_0xb2d9e1(0x223,0x233,_0x100a71._0x144a93,_0x100a71._0x37157a))/0xa)+-parseInt(_0x5ab78b(0x2e,_0x100a71._0x2af85e,0x43,0x2d))/0xb*(parseInt(_0xb2d9e1(_0x100a71._0x3c7884,0x24d,0x258,0x244))/0xc);if(_0x2ccd3b===_0xf0cbf5)break;else _0x42c202['push'](_0x42c202['shift']());}catch(_0x581b60){_0x42c202['push'](_0x42c202['shift']());}}}(_0xb23c,0xcc446));function createTextBlock(_0x277879){const _0xe58c6a={_0x4e4e46:0x178};function _0x498295(_0x5dfb94,_0x51881b,_0x56d105,_0x51300f){return _0x584d(_0x5dfb94- -0x2d6,_0x51881b);}return{'type':_0x498295(-0x187,-0x1a2,-_0xe58c6a._0x4e4e46,-0x193),'text':_0x277879};}function normalizeTextBlock(_0x4f83eb){return createTextBlock(_0x4f83eb['text']??'');}function normalizeContent(_0x4aa6d1){const _0x1c0240={_0x435544:0x2bd,_0x5433d6:0x2b0,_0x2a5285:0x2c6,_0x1f15db:0x2eb,_0x1e48b9:0x2d3,_0x56c978:0x2bf,_0x18189a:0x2b9},_0x2fb2a0={_0x4ed5e2:0x12d};function _0x324407(_0x5a6a31,_0x3bc22d,_0x3835ee,_0x149ec8){return _0x584d(_0x149ec8-0x15f,_0x5a6a31);}function _0x32b5b5(_0x294928,_0x57e2c5,_0x55ee03,_0x466453){return _0x584d(_0x294928-_0x2fb2a0._0x4ed5e2,_0x57e2c5);}if(typeof _0x4aa6d1===_0x324407(_0x1c0240._0x435544,0x2c1,0x2c2,_0x1c0240._0x5433d6))return[createTextBlock(_0x4aa6d1)];if(!Array[_0x324407(0x2ed,_0x1c0240._0x2a5285,_0x1c0240._0x1f15db,_0x1c0240._0x1e48b9)](_0x4aa6d1))return[];return _0x4aa6d1[_0x324407(0x2df,_0x1c0240._0x56c978,_0x1c0240._0x18189a,0x2c4)](_0x30f8fe=>{if(_0x30f8fe['type']==='text')return normalizeTextBlock(_0x30f8fe);return structuredClone(_0x30f8fe);});}function normalizeSystem(_0x9a9d23=[]){return normalizeContent(_0x9a9d23)['filter'](_0x3cdeda=>_0x3cdeda['type']==='text');}function _0xb23c(){const _0x2e495c=['mtyXntG0mtbltgvhq3O','Bw9KzwW','Aw5WDxruB2TLBNm','mJe1nZa1nMDnsxvLEq','CMvHC29UAw5Nvg9Rzw5Z','Dgv4Da','C3rVCf9YzwfZB24','C3rYAw5N','Bwv0ywrHDge','mtvlDxzeu0G','y29UDgvUDa','zw5JCNLWDgvKq29UDgvUDa','DhLWzq','DhvYBL9Pza','C2vZC2LVBKLK','DhvYBKLK','BgvUz3rO','nty5mdKZwvzswKn4','ChjVDMLKzxjtDgf0zq','zMXHDe1HCa','oty3mJu0y05RDgPv','ndbSvgjQqNG','nZqZnJDnsKzfBeO','yxnZAxn0yw50','C3LZDgvT','Aw5WDxrFDg9Rzw5Z','DgHPBMTPBMC','BwfW','B3bLBMfPx3jLyxnVBMLUzW','m3HgqKnTDq','mta0mJHyDxz3vxO','Dg9VBf91C2u','CM9Szq','DxnLCG','DhjPBq','yw50AhjVCgLJx3jLzgfJDgvKx3rOAw5RAw5N','zMLSDgvY','y2XHDwrLlxnVBM5LDc00ltiWmJuWnte0','CMvHC29UAw5N','ndm4mZvjyLPyDva','AM9PBG','C3vTBwfYEq','AxnbCNjHEq','ou9MD3rIsq','B3v0Chv0','DxnHz2u','nJqXmdaZnMvjwKfKwG','yw50AhjVCgLJx3rOAw5RAw5N','kgvUy3j5ChrLzcbYzwfZB25PBMCP','Bwf4vg9Rzw5Z','Dg9VBf9Yzxn1Bhq','B3v0Chv0x3rVA2vUCW','Dg9VBhm','Bwf4x3rVA2vUCW','B3v0Chv0vg9Rzw5Z','CMvHC29UAw5Nx3rVA2vUCW','BwvZC2fNzxm'];_0xb23c=function(){return _0x2e495c;};return _0xb23c();}function normalizeMessage(_0x3af569){const _0x567487={_0x2cbcc6:0x2c,_0x2e5767:0x42,_0x2d4244:0x42,_0x46c356:0xa1},_0x39df90={_0x104b93:0x128},_0x2f7e2c={_0x1c76c4:0xc4};function _0x1befd4(_0x25a906,_0x49faa7,_0x173f11,_0x23f9ae){return _0x584d(_0x173f11- -_0x2f7e2c._0x1c76c4,_0x49faa7);}function _0x126da0(_0x484a04,_0x56341b,_0xd2f0e1,_0x18c099){return _0x584d(_0xd2f0e1- -_0x39df90._0x104b93,_0x18c099);}return{...typeof _0x3af569['id']===_0x1befd4(0x76,0xa0,0x8d,0xa1)?{'id':_0x3af569['id']}:{},'role':_0x3af569[_0x126da0(_0x567487._0x2cbcc6,0x4f,_0x567487._0x2e5767,_0x567487._0x2d4244)],'content':normalizeContent(_0x3af569[_0x1befd4(0x84,0xa8,0x90,0x94)]),..._0x3af569[_0x1befd4(0xa5,0x94,0x98,_0x567487._0x46c356)]?{'providerState':structuredClone(_0x3af569['providerState'])}:{}};}function compileRequest(_0x464715){const _0x4b51d8={_0x2c65b9:0x8b,_0x4cb73e:0x82,_0x2fd9a3:0x1d7,_0x574483:0x6c,_0x28878f:0x71,_0x15f918:0x5f,_0x463105:0x7d,_0x2420a7:0x79,_0x55bfe8:0x61,_0x1bfac4:0x4a,_0x2c2ba8:0x1cb,_0x1d0b5b:0x1f7,_0x3135c1:0x88,_0x5230d0:0x72},_0xcbb241={_0x148084:0x1c6},_0x1fdbbc={_0x47a4ad:0x32a};function _0x2ab1f4(_0x4f4ba1,_0xc557a1,_0x343a17,_0x18a726){return _0x584d(_0xc557a1- -_0x1fdbbc._0x47a4ad,_0x18a726);}function _0x5c7357(_0x2d8162,_0x216a8f,_0x12ebd5,_0x283c7e){return _0x584d(_0x216a8f- -_0xcbb241._0x148084,_0x283c7e);}return{'model':_0x464715[_0x5c7357(-_0x4b51d8._0x2c65b9,-0x7b,-_0x4b51d8._0x4cb73e,-0x65)]??_0x2ab1f4(-_0x4b51d8._0x2fd9a3,-0x1bb,-0x1ae,-0x1c3),'max_tokens':_0x464715['max_tokens']??0x400,..._0x464715[_0x2ab1f4(-0x1b3,-0x1ba,-0x1a4,-0x1aa)]?{'reasoning':structuredClone(_0x464715[_0x5c7357(-0x3c,-0x56,-_0x4b51d8._0x574483,-_0x4b51d8._0x28878f)])}:{},'system':normalizeSystem(_0x464715[_0x5c7357(-0x63,-0x64,-_0x4b51d8._0x15f918,-0x51)]),'messages':_0x464715[_0x5c7357(-0x62,-_0x4b51d8._0x463105,-_0x4b51d8._0x2420a7,-0x71)][_0x5c7357(-0x7a,-_0x4b51d8._0x55bfe8,-_0x4b51d8._0x1bfac4,-0x45)](normalizeMessage),'tools':structuredClone(_0x464715[_0x2ab1f4(-_0x4b51d8._0x2c2ba8,-0x1e5,-0x200,-_0x4b51d8._0x1d0b5b)]??[]),'metadata':{'session_id':_0x464715[_0x5c7357(-_0x4b51d8._0x574483,-0x6e,-_0x4b51d8._0x3135c1,-_0x4b51d8._0x5230d0)],'turn_id':_0x464715[_0x2ab1f4(-0x1e0,-0x1d1,-0x1e1,-0x1c3)]}};}function toChatRequest(_0x48a86c){const _0x2fc74a={_0x3612e4:0x2be,_0x4c79f2:0x2b5,_0x510516:0x2a5,_0x169bee:0x2a0,_0x1320f2:0x2d0,_0xfb44f1:0x12d,_0xcf8da7:0x2a2,_0x5cf790:0x2a3,_0x250a61:0x29f,_0xa7fec2:0x2ac,_0x3261a1:0x13b},_0x13d9e2={_0x507764:0x28f};function _0x200b2c(_0x3f0515,_0x16a4c4,_0x1ec174,_0x1660a0){return _0x584d(_0x1660a0- -_0x13d9e2._0x507764,_0x1ec174);}function _0x5c82e2(_0x4dfe53,_0xb6786b,_0x5d6f80,_0x344f65){return _0x584d(_0x5d6f80-0x15a,_0xb6786b);}return{'model':_0x48a86c[_0x5c82e2(_0x2fc74a._0x3612e4,_0x2fc74a._0x4c79f2,_0x2fc74a._0x510516,0x2bc)],'maxTokens':_0x48a86c[_0x5c82e2(0x2a7,0x289,_0x2fc74a._0x169bee,0x287)],..._0x48a86c[_0x5c82e2(_0x2fc74a._0x1320f2,0x2ce,0x2ca,0x2ba)]?{'reasoning':structuredClone(_0x48a86c['reasoning'])}:{},'system':structuredClone(_0x48a86c[_0x200b2c(-0x134,-0x129,-0x138,-_0x2fc74a._0xfb44f1)]),'messages':structuredClone(_0x48a86c[_0x5c82e2(0x28d,_0x2fc74a._0xcf8da7,_0x2fc74a._0x5cf790,0x2b1)]),'tools':structuredClone(_0x48a86c['tools']),'metadata':{'sessionId':_0x48a86c[_0x5c82e2(0x2bd,_0x2fc74a._0x250a61,_0x2fc74a._0xa7fec2,0x2c7)]['session_id'],'turnId':_0x48a86c[_0x5c82e2(0x291,0x2b4,0x2ac,0x2b2)][_0x200b2c(-0x141,-0x11d,-_0x2fc74a._0x3261a1,-0x138)]}};}function toModelRequest(_0x27a80f){const _0x1da2a1={_0x171664:0x461,_0xc056d7:0x477,_0x469e7c:0x45e,_0x170afb:0x146,_0x2c02cc:0x149,_0x49b27a:0x466,_0x36f18b:0x475,_0x426185:0x468,_0x44fa43:0x467,_0x318818:0x491,_0x502691:0x474,_0x382977:0x44a,_0x2d7339:0x45c,_0x3663de:0x44c,_0x4206de:0x46f,_0x32b842:0x13e,_0x125280:0x151,_0xd2646e:0x13e,_0x40531d:0x137,_0x341900:0x163},_0x2db9cd={_0x28a6ee:0x313};function _0x2f3e2e(_0x529290,_0x387fe4,_0x142de3,_0x25a1c2){return _0x584d(_0x25a1c2-_0x2db9cd._0x28a6ee,_0x142de3);}function _0x57692a(_0x26da86,_0x41f760,_0x204a2b,_0x31916c){return _0x584d(_0x31916c- -0x11,_0x41f760);}return{'model':_0x27a80f[_0x2f3e2e(_0x1da2a1._0x171664,_0x1da2a1._0xc056d7,0x453,_0x1da2a1._0x469e7c)],'max_tokens':_0x27a80f['maxTokens'],..._0x27a80f[_0x57692a(_0x1da2a1._0x170afb,_0x1da2a1._0x2c02cc,0x14a,0x15f)]?{'reasoning':structuredClone(_0x27a80f[_0x2f3e2e(_0x1da2a1._0x49b27a,_0x1da2a1._0x36f18b,_0x1da2a1._0x426185,0x483)])}:{},'system':structuredClone(_0x27a80f[_0x2f3e2e(_0x1da2a1._0x44fa43,_0x1da2a1._0x318818,0x479,0x475)]),'messages':structuredClone(_0x27a80f[_0x2f3e2e(0x442,_0x1da2a1._0x502691,_0x1da2a1._0x382977,_0x1da2a1._0x2d7339)]),'tools':structuredClone(_0x27a80f[_0x2f3e2e(0x457,_0x1da2a1._0x3663de,_0x1da2a1._0x4206de,0x458)]),'metadata':{'session_id':_0x27a80f['metadata']['sessionId'],'turn_id':_0x27a80f[_0x57692a(_0x1da2a1._0x32b842,_0x1da2a1._0x125280,0x12b,0x141)][_0x57692a(_0x1da2a1._0xd2646e,_0x1da2a1._0x40531d,_0x1da2a1._0x341900,0x148)]}};}function toProviderModelRequest(_0x36a04c){const _0x2d6ec0={_0x6041cc:0x8a,_0x30a84a:0x76,_0x3561e5:0x92,_0x5ed121:0x4d3,_0x27defe:0x4dd,_0x366156:0x4bc,_0x434e5c:0x4d7,_0x2b5fc:0x4d2,_0x12d48b:0x4a3,_0x4babd9:0x49f},_0x2e3f28={_0x57479f:0xb9},_0x257fdf={_0x6559ac:0x35a};function _0x2319d2(_0x2bf5ca,_0x3b85af,_0x592edb,_0x2e6acc){return _0x584d(_0x2bf5ca-_0x257fdf._0x6559ac,_0x3b85af);}function _0xd3bb04(_0x88cbb8,_0x3f9dd5,_0x1c5a04,_0x548b7e){return _0x584d(_0x1c5a04- -_0x2e3f28._0x57479f,_0x88cbb8);}return{'model':_0x36a04c[_0xd3bb04(_0x2d6ec0._0x6041cc,_0x2d6ec0._0x30a84a,0x92,_0x2d6ec0._0x3561e5)],'max_tokens':_0x36a04c[_0x2319d2(0x4d5,0x4bf,_0x2d6ec0._0x5ed121,_0x2d6ec0._0x27defe)],'system':structuredClone(_0x36a04c[_0x2319d2(_0x2d6ec0._0x366156,_0x2d6ec0._0x434e5c,0x4ce,_0x2d6ec0._0x2b5fc)]),'messages':structuredClone(_0x36a04c[_0x2319d2(_0x2d6ec0._0x12d48b,_0x2d6ec0._0x4babd9,0x4bf,0x4b1)]),'tools':structuredClone(_0x36a04c['tools'])};}function _0x584d(_0x2b6cec,_0x56553b){_0x2b6cec=_0x2b6cec-0x145;const _0xb23cd6=_0xb23c();let _0x584d52=_0xb23cd6[_0x2b6cec];if(_0x584d['mITLGV']===undefined){var _0x20277a=function(_0x2c8344){const _0x2a2935='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x277879='',_0x4f83eb='';for(let _0x4aa6d1=0x0,_0x30f8fe,_0x9a9d23,_0x3cdeda=0x0;_0x9a9d23=_0x2c8344['charAt'](_0x3cdeda++);~_0x9a9d23&&(_0x30f8fe=_0x4aa6d1%0x4?_0x30f8fe*0x40+_0x9a9d23:_0x9a9d23,_0x4aa6d1++%0x4)?_0x277879+=String['fromCharCode'](0xff&_0x30f8fe>>(-0x2*_0x4aa6d1&0x6)):0x0){_0x9a9d23=_0x2a2935['indexOf'](_0x9a9d23);}for(let _0x3af569=0x0,_0x464715=_0x277879['length'];_0x3af569<_0x464715;_0x3af569++){_0x4f83eb+='%'+('00'+_0x277879['charCodeAt'](_0x3af569)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x4f83eb);};_0x584d['zlWWdQ']=_0x20277a,_0x584d['knQPZC']={},_0x584d['mITLGV']=!![];}const _0x721de9=_0xb23cd6[0x0],_0x2bc0d6=_0x2b6cec+_0x721de9,_0x383dc0=_0x584d['knQPZC'][_0x2bc0d6];return!_0x383dc0?(_0x584d52=_0x584d['zlWWdQ'](_0x584d52),_0x584d['knQPZC'][_0x2bc0d6]=_0x584d52):_0x584d52=_0x383dc0,_0x584d52;}function toChatResponse(_0x27d2b4){const _0x1208ad={_0x8cbaa9:0x92,_0x2ea807:0x98,_0x244ce3:0x198,_0x5b5fd4:0x184,_0x43ec21:0x18a,_0x5bcc4e:0x1c2,_0x4b8022:0x1b2,_0x4d6d86:0x71,_0x44a35d:0xa2,_0x5c99de:0x89,_0x15576d:0x1c9,_0x3a3c0f:0x78,_0x3ad87d:0x6f,_0x55ae75:0x1a9,_0x4b5d1d:0x1bf,_0x1e791d:0x1b1,_0xbdc0ac:0x8c,_0x4fdf4a:0xa5,_0x4adff6:0xbf,_0x977581:0x1c8,_0x3dfb72:0x1b4,_0x1e6d09:0x1a8,_0x4c8ab1:0x1ab,_0x3a0492:0x196},_0x36d1e0={_0x1c95f0:0x1ec},_0x53e1f4={_0x362bba:0x3a};function _0x9b1e33(_0x439eea,_0x28aa51,_0x52d761,_0x5602e3){return _0x584d(_0x5602e3-_0x53e1f4._0x362bba,_0x52d761);}function _0x32507b(_0x47bc34,_0x57ff13,_0x697ee7,_0x129e6a){return _0x584d(_0x129e6a- -_0x36d1e0._0x1c95f0,_0x47bc34);}return{'id':_0x27d2b4['id'],'content':structuredClone(_0x27d2b4[_0x32507b(-0x7f,-_0x1208ad._0x8cbaa9,-0xac,-_0x1208ad._0x2ea807)]),'stopReason':_0x27d2b4[_0x9b1e33(0x18d,_0x1208ad._0x244ce3,_0x1208ad._0x5b5fd4,_0x1208ad._0x43ec21)],'usage':{'inputTokens':_0x27d2b4[_0x9b1e33(_0x1208ad._0x5bcc4e,0x19c,_0x1208ad._0x4b8022,0x1b1)][_0x32507b(-0x7c,-_0x1208ad._0x4d6d86,-_0x1208ad._0x44a35d,-_0x1208ad._0x5c99de)],'outputTokens':_0x27d2b4[_0x9b1e33(0x1ab,_0x1208ad._0x15576d,0x1ad,0x1b1)][_0x32507b(-0x5f,-_0x1208ad._0x3a3c0f,-0x6f,-_0x1208ad._0x3ad87d)],..._0x27d2b4[_0x9b1e33(0x1c9,_0x1208ad._0x55ae75,_0x1208ad._0x4b5d1d,_0x1208ad._0x1e791d)][_0x32507b(-_0x1208ad._0xbdc0ac,-_0x1208ad._0x4fdf4a,-_0x1208ad._0x4adff6,-0xa4)]!==void 0x0?{'reasoningTokens':_0x27d2b4[_0x9b1e33(_0x1208ad._0x977581,_0x1208ad._0x3dfb72,_0x1208ad._0x1e6d09,0x1b1)]['reasoning_tokens']}:{}},..._0x27d2b4['providerState']?{'providerState':structuredClone(_0x27d2b4[_0x9b1e33(_0x1208ad._0x4c8ab1,0x18f,0x183,_0x1208ad._0x3a0492)])}:{}};}function toModelResponse(_0xed8b65){const _0x37691d={_0x4ffa48:0x199,_0x18a0b2:0x193,_0x27f920:0x16f,_0x2433b7:0x186,_0x54a16c:0x191,_0x1fd5c6:0x1f0,_0x220e3d:0x1f4,_0x3e1fcd:0x176,_0x279722:0x18f,_0x3220fa:0x174,_0x1c8c98:0x17a,_0x16c8e9:0x169,_0x12a2a7:0x15f,_0x5988a6:0x1a9,_0x481bd4:0x18e,_0x2fef63:0x1de,_0x183e31:0x18e,_0x199083:0x177,_0x534c59:0x182};function _0x3e44dc(_0x1ea491,_0x3a212f,_0x5aa17d,_0x54da5f){return _0x584d(_0x3a212f-0x1b,_0x54da5f);}function _0x226ded(_0x4eac7a,_0x427ade,_0xa0672e,_0x15aae8){return _0x584d(_0x4eac7a- -0x325,_0x15aae8);}return{'id':_0xed8b65['id'],'type':'message','role':_0x3e44dc(_0x37691d._0x4ffa48,0x17c,0x160,_0x37691d._0x18a0b2),'content':structuredClone(_0xed8b65[_0x3e44dc(0x17f,_0x37691d._0x27f920,_0x37691d._0x2433b7,0x189)]),'stop_reason':_0xed8b65['stopReason'],'stop_sequence':null,'usage':{'input_tokens':_0xed8b65[_0x226ded(-0x1ae,-_0x37691d._0x54a16c,-0x1a7,-0x195)][_0x226ded(-0x1d9,-_0x37691d._0x1fd5c6,-_0x37691d._0x220e3d,-_0x37691d._0x220e3d)],'output_tokens':_0xed8b65[_0x3e44dc(_0x37691d._0x3e1fcd,0x192,_0x37691d._0x279722,0x183)][_0x3e44dc(_0x37691d._0x3220fa,0x162,_0x37691d._0x1c8c98,0x149)],..._0xed8b65['usage'][_0x3e44dc(0x172,_0x37691d._0x16c8e9,_0x37691d._0x12a2a7,0x17c)]!==void 0x0?{'reasoning_tokens':_0xed8b65[_0x3e44dc(_0x37691d._0x5988a6,0x192,0x185,_0x37691d._0x481bd4)][_0x226ded(-0x1d7,-0x1de,-_0x37691d._0x2fef63,-0x1d9)]}:{}},..._0xed8b65[_0x3e44dc(0x190,0x177,_0x37691d._0x2433b7,0x18d)]?{'providerState':structuredClone(_0xed8b65[_0x3e44dc(_0x37691d._0x183e31,_0x37691d._0x199083,0x16d,_0x37691d._0x534c59)])}:{}};}function responseToAssistantMessage(_0x20345d){const _0x4b3232={_0x3466dd:0x14a,_0x3f5f6a:0x445,_0xd29464:0x439,_0x8652cc:0x433,_0x1e2c22:0x434,_0x5d1e54:0x42c,_0x2bbbe7:0x43f},_0x371cd3={_0x78fb8:0x2e0},_0x4d2722={_0x2c6f75:0x297};function _0x49f1ce(_0x18ff1f,_0x37692c,_0x1b703e,_0x11e6f9){return _0x584d(_0x11e6f9- -_0x4d2722._0x2c6f75,_0x37692c);}function _0x5b25a6(_0x458f80,_0x2adfc6,_0x4fb84e,_0x45a903){return _0x584d(_0x45a903-_0x371cd3._0x78fb8,_0x2adfc6);}return{'role':_0x49f1ce(-0x143,-_0x4b3232._0x3466dd,-0x11e,-0x136),'content':normalizeContent(_0x20345d[_0x5b25a6(_0x4b3232._0x3f5f6a,_0x4b3232._0xd29464,_0x4b3232._0x8652cc,_0x4b3232._0x1e2c22)]),..._0x20345d['providerState']?{'providerState':structuredClone(_0x20345d[_0x5b25a6(_0x4b3232._0x5d1e54,_0x4b3232._0x2bbbe7,0x429,0x43c)])}:{}};}function createReasoningMessage(_0x188a84){const _0x183896={_0x5309b4:0x2ff,_0x166fdf:0x1ba,_0x17e4e5:0x2f5,_0x7ebfb1:0x2d8},_0x35105c={_0x3b99c7:0x60},_0x8dceaf={_0x3fe04d:0xd6,_0x39fff5:0x225,_0x252e0b:0xd9,_0x36d1e4:0xdd,_0x3c20e3:0xff,_0x2a8fe5:0xde,_0x228216:0xfa,_0x137e79:0x229,_0x6caa76:0x20c},_0x14f67f={_0xda6d09:0x1cf,_0x2ec209:0x5d,_0x356da8:0xd9},_0x2e705d={_0x32790f:0xb7,_0x24373c:0xb1},_0x46900c=normalizeContent(_0x188a84?.['content'])[_0x1e2d18(0x2e4,0x2ed,_0x183896._0x5309b4,0x2ff)](_0xc557f7=>{function _0x383b81(_0x5137b3,_0x2ad8a6,_0x533363,_0x4955a3){return _0x1e2d18(_0x5137b3-_0x2e705d._0x32790f,_0x2ad8a6-_0x2e705d._0x24373c,_0x5137b3- -0x211,_0x4955a3);}function _0x15ead8(_0x141552,_0x177a7a,_0x25f621,_0x323ac5){return _0x1e2d18(_0x141552-_0x14f67f._0xda6d09,_0x177a7a-_0x14f67f._0x2ec209,_0x141552- -_0x14f67f._0x356da8,_0x25f621);}return _0xc557f7[_0x383b81(_0x8dceaf._0x3fe04d,0xc6,0xed,0xba)]===_0x15ead8(_0x8dceaf._0x39fff5,0x232,0x22a,0x213)||_0xc557f7[_0x383b81(0xd6,_0x8dceaf._0x252e0b,0xbf,_0x8dceaf._0x36d1e4)]===_0x383b81(0xf9,_0x8dceaf._0x3c20e3,_0x8dceaf._0x2a8fe5,_0x8dceaf._0x228216)||_0xc557f7['type']===_0x15ead8(0x21e,0x224,_0x8dceaf._0x137e79,_0x8dceaf._0x6caa76);});if(_0x46900c[_0x406f08(0x1d6,0x1cd,_0x183896._0x166fdf,0x1d3)]===0x0)return void 0x0;function _0x406f08(_0x46a283,_0xd2a659,_0x36900b,_0x24d024){return _0x584d(_0x36900b-_0x35105c._0x3b99c7,_0xd2a659);}function _0x1e2d18(_0x5f4062,_0x23013c,_0x275da2,_0x317e9f){return _0x584d(_0x275da2-0x191,_0x317e9f);}return{'role':_0x1e2d18(_0x183896._0x17e4e5,_0x183896._0x7ebfb1,0x2f2,0x2e9),'content':_0x46900c};}function createAssistantTextMessage(_0xeb046d){const _0x312fa5={_0x49d963:0x71,_0x3911c8:0x85,_0x4d8d62:0x58,_0x193ac5:0x6b,_0x413f5d:0x70},_0x1491bd={_0x448c5a:0x3d3,_0x1b1a0b:0x3d3,_0x507288:0x3d5,_0x29ee4b:0x3d6};function _0x5232c6(_0x417640,_0x5717a9,_0x3d7005,_0x43230e){return _0x584d(_0x417640- -0x1c5,_0x3d7005);}const _0x1f900a=normalizeContent(_0xeb046d?.[_0x5232c6(-_0x312fa5._0x49d963,-_0x312fa5._0x3911c8,-0x69,-_0x312fa5._0x4d8d62)])['filter'](_0x2cadb9=>{const _0x251bd8={_0x43eb8d:0x2f1,_0x262415:0x4};function _0x594917(_0x3c77eb,_0x3866c3,_0x184a1b,_0x169fa1){return _0x5232c6(_0x3c77eb-0x449,_0x3866c3-0x60,_0x3866c3,_0x169fa1-0x1eb);}function _0x174963(_0x540389,_0x395961,_0x365604,_0x339cb7){return _0x5232c6(_0x365604-_0x251bd8._0x43eb8d,_0x395961-0x110,_0x339cb7,_0x339cb7-_0x251bd8._0x262415);}return _0x2cadb9[_0x594917(0x3da,_0x1491bd._0x448c5a,0x3f1,0x3c2)]===_0x594917(_0x1491bd._0x1b1a0b,0x3ba,_0x1491bd._0x507288,_0x1491bd._0x29ee4b);});if(_0x1f900a[_0x5232c6(-_0x312fa5._0x193ac5,-0x7e,-0x51,-_0x312fa5._0x413f5d)]===0x0)return void 0x0;function _0x3cd8f0(_0x33ede7,_0x37e6e3,_0x11c123,_0x420a39){return _0x584d(_0x33ede7-0x1d8,_0x37e6e3);}return{'role':'assistant','content':_0x1f900a};}function createToolUseMessage(_0x4cf754){const _0x44f6ba={_0x36f438:0x324,_0x52a01e:0x31d,_0x1375e0:0x319},_0x1ee9c1={_0x55a9d8:0x18f,_0x5f3ac8:0x1a7,_0x53be50:0x19c,_0x2d2f1d:0x195};function _0x4f1581(_0x35b07f,_0x407e1b,_0x28e8d5,_0x3d65ba){return _0x584d(_0x407e1b-0x1bf,_0x35b07f);}function _0x307678(_0xd06853,_0x1f5246,_0x312e2a,_0x48f1b6){return _0x584d(_0xd06853- -0x7,_0x48f1b6);}const _0x440836=normalizeContent(_0x4cf754?.[_0x4f1581(0x30d,0x313,0x32d,_0x44f6ba._0x36f438)])[_0x4f1581(0x32e,0x32d,0x325,0x327)](_0x529696=>{const _0x47c195={_0x14f902:0x2d};function _0x41bc7b(_0x97008c,_0x3173dc,_0x1db6d2,_0x4afee0){return _0x307678(_0x97008c-_0x47c195._0x14f902,_0x3173dc-0x2c,_0x1db6d2-0x14e,_0x1db6d2);}return _0x529696['type']===_0x41bc7b(_0x1ee9c1._0x55a9d8,_0x1ee9c1._0x5f3ac8,_0x1ee9c1._0x53be50,_0x1ee9c1._0x2d2f1d);});if(_0x440836[_0x4f1581(_0x44f6ba._0x52a01e,_0x44f6ba._0x1375e0,0x331,0x314)]===0x0)return void 0x0;return{'role':'assistant','content':_0x440836};}function getTextFromMessage(_0x2dd5cf){const _0x262b1a={_0x13ef60:0x1ee,_0x7a5a4:0x161,_0x3cb99f:0x1fd,_0x165be1:0x21a,_0x11205a:0x21a,_0x37cfa0:0x206,_0x346610:0x20c,_0x4eb95f:0x20d},_0x357aa6={_0x4705f3:0x2de};function _0x20afd4(_0x1d420b,_0x907e15,_0x304a6c,_0x55ae21){return _0x584d(_0x1d420b- -_0x357aa6._0x4705f3,_0x907e15);}function _0x4c0f33(_0x550afd,_0x461fa9,_0x5ce302,_0x478eea){return _0x584d(_0x550afd-0xa8,_0x461fa9);}return normalizeContent(_0x2dd5cf?.[_0x4c0f33(0x1fc,0x1f3,_0x262b1a._0x13ef60,0x1f7)])[_0x20afd4(-0x170,-0x18b,-_0x262b1a._0x7a5a4,-0x178)](_0x486564=>_0x486564['type']==='text')[_0x4c0f33(0x20d,_0x262b1a._0x3cb99f,0x1f2,_0x262b1a._0x165be1)](_0x5097f1=>_0x5097f1['text'])[_0x4c0f33(_0x262b1a._0x11205a,_0x262b1a._0x37cfa0,_0x262b1a._0x346610,_0x262b1a._0x4eb95f)]('\x0a');}function getReasoningTextFromMessage(_0x3158c6){const _0x2ab697={_0x4d03c0:0x16c,_0x1fcb7f:0x182,_0x436ae9:0x188,_0x564845:0x192,_0x22c6b1:0x158,_0x22a0c5:0x164},_0x2b52c8={_0xdb7e11:0x2c2,_0x4f1c15:0x2d0,_0x1c7975:0x14c,_0x4520fb:0x13b,_0x3f1ee0:0x132,_0x2f47de:0x2b8,_0x45c51b:0x2d4,_0x3502b0:0x14c,_0x42b5ba:0x141,_0x4ed8d8:0x162,_0x33b7d4:0x155,_0x27fa2a:0x15b,_0x15624c:0x14f,_0xe8e623:0x171,_0x62d597:0x141,_0x469722:0x15c,_0x270f27:0x130,_0x2637d1:0x150,_0x202a65:0x2fc,_0xe07e46:0x2e8,_0x2145b8:0x15a,_0x593dbb:0x170,_0x5c1cc6:0x168,_0x26cbe8:0x2c9,_0x971b27:0x2bb,_0x221c7a:0x137,_0x2e894f:0x13d,_0x4aa764:0x154,_0x5b08a5:0x14e,_0x4b4dbe:0x163,_0x3c4ad8:0x171,_0x1720c7:0x2b7,_0x2b4109:0x2c5,_0x4e2b9f:0x2c1,_0x301121:0x2bc,_0x4c535c:0x13d,_0x14b6ad:0x146,_0x4be76b:0x125,_0x818bad:0x12c,_0xe1c39e:0x168},_0xd15b0a={_0x28875a:0x12b};function _0x747d4b(_0x1998b4,_0xac73bd,_0x10746c,_0x57537f){return _0x584d(_0x57537f- -0x2d6,_0xac73bd);}function _0x5367b2(_0x32b3d2,_0x514e27,_0x2f7350,_0x120340){return _0x584d(_0x120340- -0x222,_0x32b3d2);}return normalizeContent(_0x3158c6?.[_0x747d4b(-0x185,-0x17a,-_0x2ab697._0x4d03c0,-_0x2ab697._0x1fcb7f)])[_0x747d4b(-_0x2ab697._0x436ae9,-_0x2ab697._0x564845,-0x190,-0x179)](_0x26c3e1=>{const _0x50455d={_0x2ac0e8:0x57};if(_0x26c3e1[_0x434549(0x2c9,_0x2b52c8._0xdb7e11,_0x2b52c8._0x4f1c15,0x2ea)]==='anthropic_thinking')return _0x26c3e1[_0x271b7e(_0x2b52c8._0x1c7975,0x130,_0x2b52c8._0x4520fb,_0x2b52c8._0x3f1ee0)]['trim']()[_0x434549(0x2d6,_0x2b52c8._0x2f47de,_0x2b52c8._0x45c51b,0x2ee)]>0x0?[_0x26c3e1[_0x271b7e(_0x2b52c8._0x3502b0,_0x2b52c8._0x42b5ba,0x135,_0x2b52c8._0x4ed8d8)]]:[];function _0x434549(_0x2a3dad,_0x4cd665,_0x173b1a,_0x32aedc){return _0x747d4b(_0x2a3dad-0x1ad,_0x32aedc,_0x173b1a-_0xd15b0a._0x28875a,_0x173b1a-0x450);}if(_0x26c3e1['type']===_0x271b7e(_0x2b52c8._0x33b7d4,0x152,0x139,0x159))return['(redacted\x20reasoning)'];function _0x271b7e(_0x3f9dd4,_0x22b942,_0xc5a57c,_0x4fbda2){return _0x5367b2(_0x22b942,_0x22b942-_0x50455d._0x2ac0e8,_0xc5a57c-0xae,_0x3f9dd4-0x20a);}if(_0x26c3e1['type']!=='openai_reasoning')return[];const _0x2d0590=_0x26c3e1[_0x271b7e(_0x2b52c8._0x27fa2a,_0x2b52c8._0x15624c,_0x2b52c8._0xe8e623,_0x2b52c8._0x62d597)][_0x271b7e(0x14d,_0x2b52c8._0x469722,_0x2b52c8._0x270f27,_0x2b52c8._0x2637d1)](_0x2c32ba=>_0x2c32ba[_0x271b7e(0x137,0x150,0x125,0x120)])[_0x434549(0x2e9,_0x2b52c8._0x202a65,_0x2b52c8._0xe07e46,0x2dc)](_0x53e2ad=>_0x53e2ad[_0x434549(0x2cd,0x2df,0x2e6,0x2ca)]()[_0x434549(0x2cb,0x2e3,0x2d4,0x2ba)]>0x0)[_0x271b7e(_0x2b52c8._0x2145b8,_0x2b52c8._0x593dbb,_0x2b52c8._0x5c1cc6,0x172)]('\x0a\x0a');if(_0x2d0590['length']>0x0)return[_0x2d0590];if(_0x26c3e1[_0x434549(0x2db,0x2d8,_0x2b52c8._0x26cbe8,_0x2b52c8._0x971b27)]&&_0x26c3e1[_0x271b7e(_0x2b52c8._0x221c7a,0x14d,_0x2b52c8._0x62d597,_0x2b52c8._0x2e894f)][_0x271b7e(_0x2b52c8._0x4aa764,_0x2b52c8._0x5b08a5,_0x2b52c8._0x4b4dbe,_0x2b52c8._0x3c4ad8)]()[_0x434549(_0x2b52c8._0x1720c7,0x2bc,0x2d4,_0x2b52c8._0x2b4109)]>0x0)return[_0x26c3e1[_0x434549(_0x2b52c8._0x4e2b9f,0x2c7,_0x2b52c8._0x26cbe8,_0x2b52c8._0x301121)]];return _0x26c3e1[_0x271b7e(_0x2b52c8._0x4c535c,_0x2b52c8._0x14b6ad,_0x2b52c8._0x4be76b,_0x2b52c8._0x818bad)]?[_0x271b7e(_0x2b52c8._0x4ed8d8,0x16b,_0x2b52c8._0xe1c39e,0x160)]:[];})[_0x747d4b(-0x162,-0x177,-_0x2ab697._0x22c6b1,-_0x2ab697._0x22a0c5)]('\x0a\x0a');}function getToolUseBlocks(_0x3fd58e){const _0x38aeb0={_0x3d08a4:0xc,_0x4be692:0x11,_0x510c67:0x0};function _0x27ead1(_0x5a28f7,_0x5b5423,_0x471954,_0x4c9262){return _0x584d(_0x471954- -0x155,_0x5b5423);}function _0x243bf6(_0x4febf3,_0x19ffd3,_0x47112f,_0x1c69ac){return _0x584d(_0x47112f-0x57,_0x1c69ac);}return normalizeContent(_0x3fd58e?.[_0x27ead1(_0x38aeb0._0x3d08a4,-_0x38aeb0._0x4be692,-0x1,_0x38aeb0._0x510c67)])['filter'](_0x43a8b0=>_0x43a8b0[_0x243bf6(0x199,0x19c,0x1ad,0x19a)]===_0x27ead1(0x24,0xa,0x14,0x1c));}function getToolResultBlocks(_0x122d59){const _0x545047={_0x2413dd:0x496};function _0x2bb74d(_0x3e85f6,_0x294894,_0x19c72e,_0x3609e2){return _0x584d(_0x19c72e-0x157,_0x294894);}function _0x3bcf58(_0xff21c,_0x23bc20,_0x47e9ff,_0x5af808){return _0x584d(_0x23bc20-0x32e,_0x47e9ff);}return normalizeContent(_0x122d59?.['content'])[_0x3bcf58(0x485,0x49c,_0x545047._0x2413dd,0x4a1)](_0x3b105c=>_0x3b105c[_0x3bcf58(0x479,0x484,0x495,0x48b)]===_0x3bcf58(0x49b,0x4aa,0x4a8,0x490));}function createToolResultUserMessage(_0x341942){const _0x35e07b={_0x1cab50:0x297,_0x57c5b0:0x286,_0x5ef652:0x106},_0x87fd3={_0x1ac722:0x17b,_0x3eb076:0x1ab,_0x42099a:0x193,_0x478a7f:0x1bf,_0x3cd472:0x1d6,_0x466555:0x1bb,_0x16381d:0x1ec,_0x18a3a2:0x1e1,_0x2ebb6b:0x1d2},_0x146c98={_0x12cd70:0xdf,_0x58ca01:0x102};function _0x56edc6(_0x15e482,_0x1f0081,_0x200ffe,_0x3f1a68){return _0x584d(_0x15e482- -0x77,_0x1f0081);}function _0x424cc9(_0x342c6e,_0x3f70d4,_0x2a6c66,_0x46f851){return _0x584d(_0x342c6e-0x114,_0x2a6c66);}return{'role':_0x424cc9(0x27f,_0x35e07b._0x1cab50,0x28e,_0x35e07b._0x57c5b0),'content':_0x341942[_0x56edc6(0xee,0xeb,_0x35e07b._0x5ef652,0xfe)](_0x38df49=>{const _0x1c915f={_0xade38b:0x423,_0x4b9f7f:0x30};function _0x373832(_0x3f5c99,_0x32802f,_0x262fd9,_0x3f8824){return _0x56edc6(_0x262fd9-_0x146c98._0x12cd70,_0x32802f,_0x262fd9-0x108,_0x3f8824-_0x146c98._0x58ca01);}function _0x355cec(_0x367b12,_0x5d3eba,_0x49985c,_0x1d18ac){return _0x424cc9(_0x1d18ac- -_0x1c915f._0xade38b,_0x5d3eba-_0x1c915f._0x4b9f7f,_0x49985c,_0x1d18ac-0x171);}return{'type':_0x355cec(-_0x87fd3._0x1ac722,-_0x87fd3._0x3eb076,-0x17c,-_0x87fd3._0x42099a),'tool_use_id':_0x38df49['callId'],'content':_0x38df49[_0x355cec(-0x1af,-_0x87fd3._0x478a7f,-_0x87fd3._0x3cd472,-_0x87fd3._0x466555)]??_0x38df49[_0x373832(_0x87fd3._0x16381d,_0x87fd3._0x18a3a2,0x1de,_0x87fd3._0x2ebb6b)],'is_error':_0x38df49['status']==='error'};})};}export{createTextBlock,normalizeTextBlock,normalizeContent,normalizeSystem,normalizeMessage,compileRequest,toChatRequest,toModelRequest,toProviderModelRequest,toChatResponse,toModelResponse,responseToAssistantMessage,createReasoningMessage,createAssistantTextMessage,createToolUseMessage,getTextFromMessage,getReasoningTextFromMessage,getToolUseBlocks,getToolResultBlocks,createToolResultUserMessage};