@myagentroam/node 0.9.40 → 0.9.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* mar-release-protected */
|
|
2
|
-
const _0x31b997=_0x1255;(function(_0x510618,_0x1b370c){const _0x5a8248=_0x1255,_0x9bbd51=_0x510618();while(!![]){try{const _0x49cf07=parseInt(_0x5a8248(0x200))/(0x1*0x983+0x9*-0xe0+-0x1a2)*(parseInt(_0x5a8248(0x285))/(-0x23bf*-0x1+-0x18b0+-0xb0d))+parseInt(_0x5a8248(0x224))/(-0x1ac0+0x5fb*0x5+-0x324)+parseInt(_0x5a8248(0x282))/(0x2c0*-0xb+0x21ce*0x1+0x2*-0x1c5)+-parseInt(_0x5a8248(0x1f1))/(0x1161+0xe*-0x42+-0x40*0x37)*(parseInt(_0x5a8248(0x24e))/(-0x35*0x1+-0x1*0x1ccd+-0x3a1*-0x8))+-parseInt(_0x5a8248(0x1f5))/(0x117d+0x11af+0x3*-0xbb7)*(parseInt(_0x5a8248(0x297))/(0x14c3+0x38*-0x6b+0x2ad))+parseInt(_0x5a8248(0x2ac))/(0x6ac+-0x77*-0x2c+0x1b17*-0x1)+-parseInt(_0x5a8248(0x263))/(0x1270+-0x1d74+0x11b*0xa);if(_0x49cf07===_0x1b370c)break;else _0x9bbd51['push'](_0x9bbd51['shift']());}catch(_0x5641ac){_0x9bbd51['push'](_0x9bbd51['shift']());}}}(_0x14ad,0x62bfb+0x64d9e+0x950c5*-0x1));import{createHash,randomUUID}from'node:crypto';import{chmod,copyFile,lstat,mkdir,readFile,readlink,readdir,realpath,rename,rm,statfs,symlink,writeFile}from'node:fs/promises';import{dirname,isAbsolute,join,relative,resolve,sep}from'node:path';import{conversationTemplateDraftSchema,conversationTemplatePublishJobSchema,conversationTemplatePublishRequestSchema,conversationTemplatePublishResultSchema,conversationTemplatePublishStatusInputSchema,conversationTemplateSourceInspectInputSchema,conversationTemplateSourceInspectionSchema,conversationTemplateVersionSchema}from'@myagentroam/protocol';import{safeErrorCode}from'../util/safe-error.js';const HOST_POLICY_VERSION=0x358*0x6+0x1d55+-0x3164,FORCED_EXCLUDED_NAMES=new Set([_0x31b997(0x276),_0x31b997(0x231),_0x31b997(0x240),_0x31b997(0x288),_0x31b997(0x2ca),_0x31b997(0x295),_0x31b997(0x1f2),_0x31b997(0x1dd)]),ROOT_EXCLUDED_NAMES=new Set([_0x31b997(0x22c),_0x31b997(0x1e8)]),RUNTIME_LINK_ROOTS=[_0x31b997(0x203),_0x31b997(0x29a),_0x31b997(0x249),_0x31b997(0x214),_0x31b997(0x2b7)],RESERVED_SANDBOX_ROOTS=[_0x31b997(0x21d),_0x31b997(0x205),_0x31b997(0x222),_0x31b997(0x203),_0x31b997(0x29a),_0x31b997(0x249),_0x31b997(0x214),_0x31b997(0x2b7),_0x31b997(0x1e4),_0x31b997(0x1c2),_0x31b997(0x2c4)];export class ConversationTemplateNodeService{[_0x31b997(0x27f)];[_0x31b997(0x267)];['id'];[_0x31b997(0x272)]=new Map();constructor(_0x36d711){const _0x38d5d9=_0x31b997;this[_0x38d5d9(0x27f)]=_0x36d711,this[_0x38d5d9(0x267)]=_0x36d711[_0x38d5d9(0x267)]??Date[_0x38d5d9(0x267)],this['id']=_0x36d711['id']??randomUUID;}[_0x31b997(0x2c6)](){const _0x533d11=_0x31b997;return{'conversation.template.source.inspect':_0x6aaeb2=>this[_0x533d11(0x235)](_0x6aaeb2),'conversation.template.publish':_0x3110df=>this[_0x533d11(0x2b4)](_0x3110df),'conversation.template.publish.status':_0x39cfb5=>this[_0x533d11(0x1d9)](_0x39cfb5),'conversation.template.version.inspect':_0x581048=>this[_0x533d11(0x271)](_0x581048)};}async[_0x31b997(0x20e)](){const _0x5b81aa=_0x31b997;for(const _0x5195c3 of await readdir(this[_0x5b81aa(0x27f)][_0x5b81aa(0x216)][_0x5b81aa(0x22a)],{'withFileTypes':!![]})){await writableRemove(join(this[_0x5b81aa(0x27f)][_0x5b81aa(0x216)][_0x5b81aa(0x22a)],_0x5195c3[_0x5b81aa(0x212)]));}const _0x569ca4=new Set(this[_0x5b81aa(0x27f)][_0x5b81aa(0x243)][_0x5b81aa(0x298)][_0x5b81aa(0x26b)](_0x5b81aa(0x1c3))[_0x5b81aa(0x1c7)]()[_0x5b81aa(0x294)](_0x250ae4=>stringValue(_0x250ae4,_0x5b81aa(0x1cf))));for(const _0x5247e3 of await readdir(this[_0x5b81aa(0x27f)][_0x5b81aa(0x216)][_0x5b81aa(0x23d)],{'withFileTypes':!![]})){if(_0x569ca4[_0x5b81aa(0x26d)](_0x5247e3[_0x5b81aa(0x212)]))continue;await writableRemove(join(this[_0x5b81aa(0x27f)][_0x5b81aa(0x216)][_0x5b81aa(0x23d)],_0x5247e3[_0x5b81aa(0x212)]));}await this[_0x5b81aa(0x1d6)](),this[_0x5b81aa(0x27f)][_0x5b81aa(0x243)][_0x5b81aa(0x298)][_0x5b81aa(0x26b)](_0x5b81aa(0x2cb))[_0x5b81aa(0x1f7)](_0x5b81aa(0x21e),this[_0x5b81aa(0x267)]());}async[_0x31b997(0x235)](_0xdb298e){const _0xcad44e=_0x31b997,_0x46d476=conversationTemplateSourceInspectInputSchema[_0xcad44e(0x299)](nodeRequestPayload(_0xdb298e)[_0xcad44e(0x283)]),_0x7903a7=this[_0xcad44e(0x292)](_0x46d476[_0xcad44e(0x234)][_0xcad44e(0x247)]);try{return await this[_0xcad44e(0x1eb)](_0x46d476[_0xcad44e(0x234)]),this[_0xcad44e(0x29f)](_0x46d476[_0xcad44e(0x234)]),conversationTemplateSourceInspectionSchema[_0xcad44e(0x299)]({'valid':!![],'code':null,'message':_0xcad44e(0x27a),'checkedAt':this[_0xcad44e(0x267)](),'mcpServers':_0x7903a7});}catch(_0x3ba23f){const _0x4eb07d=safeErrorCode(_0x3ba23f,_0xcad44e(0x29b));return conversationTemplateSourceInspectionSchema[_0xcad44e(0x299)]({'valid':![],'code':_0x4eb07d,'message':_0xcad44e(0x2bf)+_0x4eb07d+').','checkedAt':this[_0xcad44e(0x267)](),'mcpServers':_0x7903a7});}}async[_0x31b997(0x2b4)](_0xbe9be6){const _0x25f3c7=_0x31b997,_0x351080=nodeRequestPayload(_0xbe9be6),_0x9b50c0=conversationTemplatePublishRequestSchema[_0x25f3c7(0x299)](_0x351080[_0x25f3c7(0x283)]);if(_0x351080[_0x25f3c7(0x226)]!==undefined&&_0x351080[_0x25f3c7(0x226)]!==_0x9b50c0[_0x25f3c7(0x241)])throw new Error(_0x25f3c7(0x1e1));this[_0x25f3c7(0x20d)](_0x9b50c0[_0x25f3c7(0x234)]);const _0x548004=this[_0x25f3c7(0x2c3)](_0x9b50c0[_0x25f3c7(0x2a9)]);if(_0x548004!==undefined){if(numberValue(_0x548004,_0x25f3c7(0x258))!==_0x9b50c0[_0x25f3c7(0x241)])throw new Error(_0x25f3c7(0x1e1));if(stringValue(_0x548004,_0x25f3c7(0x2b1))!==_0x9b50c0[_0x25f3c7(0x2b3)]||numberValue(_0x548004,_0x25f3c7(0x1e2))!==_0x9b50c0[_0x25f3c7(0x234)][_0x25f3c7(0x2b0)]||stringValue(_0x548004,_0x25f3c7(0x234))!==JSON[_0x25f3c7(0x1de)](_0x9b50c0[_0x25f3c7(0x234)]))throw new Error(_0x25f3c7(0x202));return this[_0x25f3c7(0x2be)](_0x548004);}const _0x30ab3a=this[_0x25f3c7(0x267)]();return this[_0x25f3c7(0x27f)][_0x25f3c7(0x243)][_0x25f3c7(0x298)][_0x25f3c7(0x26b)](_0x25f3c7(0x24d))[_0x25f3c7(0x1f7)](_0x9b50c0[_0x25f3c7(0x2a9)],_0x9b50c0[_0x25f3c7(0x2b3)],_0x9b50c0[_0x25f3c7(0x234)][_0x25f3c7(0x2b0)],_0x9b50c0[_0x25f3c7(0x241)],JSON[_0x25f3c7(0x1de)](_0x9b50c0[_0x25f3c7(0x234)]),_0x30ab3a,_0x30ab3a),this[_0x25f3c7(0x1ea)](_0x9b50c0),this[_0x25f3c7(0x2be)](this[_0x25f3c7(0x1cb)](_0x9b50c0[_0x25f3c7(0x2a9)]));}[_0x31b997(0x1ea)](_0x337e09){queueMicrotask(()=>{const _0x347be7=_0x1255,_0x35b09e=this[_0x347be7(0x272)][_0x347be7(0x257)](_0x337e09[_0x347be7(0x2b3)])??Promise[_0x347be7(0x23b)](),_0x743eee=_0x35b09e[_0x347be7(0x245)](()=>undefined)[_0x347be7(0x2a1)](()=>this[_0x347be7(0x1f6)](_0x337e09))[_0x347be7(0x25f)](()=>{const _0x1d55da=_0x347be7;if(this[_0x1d55da(0x272)][_0x1d55da(0x257)](_0x337e09[_0x1d55da(0x2b3)])===_0x743eee)this[_0x1d55da(0x272)][_0x1d55da(0x29e)](_0x337e09[_0x1d55da(0x2b3)]);});this[_0x347be7(0x272)][_0x347be7(0x21a)](_0x337e09[_0x347be7(0x2b3)],_0x743eee);});}[_0x31b997(0x1d9)](_0x3d41db){const _0x4bba91=_0x31b997,_0x44c443=conversationTemplatePublishStatusInputSchema[_0x4bba91(0x299)](nodeRequestPayload(_0x3d41db)[_0x4bba91(0x283)]),_0x3019cf=this[_0x4bba91(0x1cb)](_0x44c443[_0x4bba91(0x2a9)]);if(stringValue(_0x3019cf,_0x4bba91(0x2b1))!==_0x44c443[_0x4bba91(0x2b3)])throw new Error(_0x4bba91(0x287));return this[_0x4bba91(0x2be)](_0x3019cf);}async[_0x31b997(0x271)](_0x11cafc){const _0x359369=_0x31b997;_0x11cafc=nodeRequestPayload(_0x11cafc)[_0x359369(0x283)];if(!record(_0x11cafc)||typeof _0x11cafc[_0x359369(0x2b3)]!==_0x359369(0x20c)||typeof _0x11cafc[_0x359369(0x269)]!==_0x359369(0x20c)||Object[_0x359369(0x284)](_0x11cafc)[_0x359369(0x1f8)]!==0xbd4+0x1aab+-0x1*0x267d)throw new Error(_0x359369(0x2cc));const _0x1a046f=this[_0x359369(0x27f)][_0x359369(0x243)][_0x359369(0x298)][_0x359369(0x26b)](_0x359369(0x2af))[_0x359369(0x257)](_0x11cafc[_0x359369(0x269)],_0x11cafc[_0x359369(0x2b3)]);if(_0x1a046f===undefined)throw new Error(_0x359369(0x1d4));const _0x4a5c11=templateVersion(_0x1a046f);try{await this[_0x359369(0x2ba)](_0x1a046f);if(_0x4a5c11[_0x359369(0x1fe)]===_0x359369(0x220))throw new Error(_0x359369(0x28b));return{'valid':!![],'code':null,'message':_0x359369(0x23c),'checkedAt':this[_0x359369(0x267)](),'version':_0x4a5c11};}catch(_0x10c748){const _0x37e66f=safeErrorCode(_0x10c748,_0x359369(0x28b));return this[_0x359369(0x27f)][_0x359369(0x243)][_0x359369(0x298)][_0x359369(0x26b)](_0x359369(0x210))[_0x359369(0x1f7)](_0x4a5c11['id']),{'valid':![],'code':_0x37e66f,'message':_0x359369(0x274)+_0x37e66f+').','checkedAt':this[_0x359369(0x267)](),'version':{..._0x4a5c11,'status':_0x359369(0x220)}};}}async[_0x31b997(0x1f6)](_0x227fa0){const _0xae2a53=_0x31b997,_0x35a1c0=_0xae2a53(0x239)+createHash(_0xae2a53(0x260))[_0xae2a53(0x2a7)](_0x227fa0[_0xae2a53(0x2a9)])[_0xae2a53(0x252)](_0xae2a53(0x2bb)),_0x211131=this[_0xae2a53(0x27f)][_0xae2a53(0x216)][_0xae2a53(0x23f)](_0x35a1c0);let _0x1e9743,_0x10a37d=_0xae2a53(0x23a);try{await this[_0xae2a53(0x1d6)](_0x227fa0[_0xae2a53(0x2b3)]),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b));const _0x215297=await this[_0xae2a53(0x1eb)](_0x227fa0[_0xae2a53(0x234)]),_0x47be6b=_0x215297[_0xae2a53(0x1c4)],_0x319d57=this[_0xae2a53(0x29f)](_0x227fa0[_0xae2a53(0x234)]),_0x425a2f=hashText(JSON[_0xae2a53(0x1de)](_0x319d57));_0x10a37d=_0xae2a53(0x25a),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b)),await rm(_0x211131,{'recursive':!![],'force':!![]});const _0x32094e=join(_0x211131,_0xae2a53(0x270));await mkdir(_0x32094e,{'recursive':!![],'mode':0x1c0});for(const _0x30ef24 of _0x215297[_0xae2a53(0x20a)])await mkdir(join(_0x32094e,..._0x30ef24[_0xae2a53(0x208)]('/')),{'recursive':!![],'mode':0x1c0});_0x10a37d=_0xae2a53(0x1d5),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b));for(const _0x5e2623 of _0x47be6b){const _0x1fac72=join(_0x32094e,..._0x5e2623[_0xae2a53(0x21c)][_0xae2a53(0x208)]('/'));await mkdir(dirname(_0x1fac72),{'recursive':!![],'mode':0x1c0});if(_0x5e2623[_0xae2a53(0x24f)]===_0xae2a53(0x27c)){const _0x27c69a=await lstat(_0x5e2623[_0xae2a53(0x204)]);if(!_0x27c69a[_0xae2a53(0x24b)]()||await readlink(_0x5e2623[_0xae2a53(0x204)])!==_0x5e2623[_0xae2a53(0x293)])throw new Error(_0xae2a53(0x254));await symlink(_0x5e2623[_0xae2a53(0x293)],_0x1fac72);const _0x338a4d=await readlink(_0x1fac72);if(_0x338a4d!==_0x5e2623[_0xae2a53(0x293)])throw new Error(_0xae2a53(0x254));continue;}await copyFile(_0x5e2623[_0xae2a53(0x204)],_0x1fac72);const _0x25602a=await lstat(_0x1fac72);if(!_0x25602a[_0xae2a53(0x273)]()||_0x25602a[_0xae2a53(0x24b)]()||_0x25602a[_0xae2a53(0x229)]!==-0x2699*0x1+0x2cc*-0x1+0x2*0x14b3)throw new Error(_0xae2a53(0x21f));await chmod(_0x1fac72,_0x5e2623[_0xae2a53(0x2c8)]?0x5bf*-0x3+-0x26cd+0x3977:-0x2f1+0x3e1+0x34);}await Promise[_0xae2a53(0x1c7)]([_0xae2a53(0x1c6),_0xae2a53(0x221)][_0xae2a53(0x294)](_0x478c93=>mkdir(join(_0x32094e,_0x478c93),{'recursive':!![],'mode':0x1c0}))),_0x10a37d=_0xae2a53(0x29c),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b)),await verifyCopiedSnapshot(_0x32094e,_0x215297[_0xae2a53(0x20a)],_0x47be6b);const _0x2e3ea3=this[_0xae2a53(0x26c)](_0x227fa0[_0xae2a53(0x2b3)]),_0x36b51b=this['id'](),_0x3413b4=this[_0xae2a53(0x267)](),_0x193b19=snapshotContentHash(_0x215297[_0xae2a53(0x20a)],_0x47be6b),_0x4994cc={'schemaVersion':0x2,'templateId':_0x227fa0[_0xae2a53(0x2b3)],'versionId':_0x36b51b,'versionNumber':_0x2e3ea3,'draftRevision':_0x227fa0[_0xae2a53(0x234)][_0xae2a53(0x2b0)],'hostPolicyVersion':HOST_POLICY_VERSION,'publishedByUserId':_0x227fa0[_0xae2a53(0x241)],'publishedAt':_0x3413b4,'sourceWorkspacePath':_0x215297[_0xae2a53(0x1e3)],'draft':_0x227fa0[_0xae2a53(0x234)],'directories':_0x215297[_0xae2a53(0x20a)],'entries':_0x47be6b[_0xae2a53(0x294)](_0x528f87=>_0x528f87[_0xae2a53(0x24f)]===_0xae2a53(0x262)?{'kind':_0x528f87[_0xae2a53(0x24f)],'relativePath':_0x528f87[_0xae2a53(0x21c)],'size':_0x528f87[_0xae2a53(0x22e)],'executable':_0x528f87[_0xae2a53(0x2c8)],'sha256':_0x528f87[_0xae2a53(0x260)]}:{'kind':_0x528f87[_0xae2a53(0x24f)],'relativePath':_0x528f87[_0xae2a53(0x21c)],'size':_0x528f87[_0xae2a53(0x22e)],'linkTarget':_0x528f87[_0xae2a53(0x293)],'targetKind':_0x528f87[_0xae2a53(0x279)],'resolvedTarget':_0x528f87[_0xae2a53(0x1c5)]}),'contentHash':_0x193b19,'mcpServers':_0x319d57,'mcpConfigHash':_0x425a2f};_0x10a37d=_0xae2a53(0x217),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b));const _0x4d4118=JSON[_0xae2a53(0x1de)](_0x4994cc),_0x15e3b0=hashText(_0x4d4118);await writeFile(join(_0x211131,_0xae2a53(0x259)),_0x4d4118+'\x0a',{'mode':0x180}),await chmod(join(_0x211131,_0xae2a53(0x259)),-0x2*0x8b2+-0x1f51+0x31d9),await sealDirectories(_0x211131,![]),_0x1e9743=this[_0xae2a53(0x27f)][_0xae2a53(0x216)][_0xae2a53(0x290)](_0x35a1c0),await rename(_0x211131,_0x1e9743),await chmod(_0x1e9743,0x5fd+-0x11f*0x18+0xd*0x1b8),_0x10a37d=_0xae2a53(0x248),this[_0xae2a53(0x2b9)](_0x227fa0[_0xae2a53(0x2a9)],_0x10a37d,_0xae2a53(0x25b));const _0x273f5a=conversationTemplateVersionSchema[_0xae2a53(0x299)]({'id':_0x36b51b,'templateId':_0x227fa0[_0xae2a53(0x2b3)],'version':_0x2e3ea3,'status':_0xae2a53(0x24a),'contentHash':_0x193b19,'manifestHash':_0x15e3b0,'mcpConfigHash':_0x425a2f,'fileCount':_0x47be6b[_0xae2a53(0x1f8)],'totalBytes':_0x47be6b[_0xae2a53(0x22d)]((_0x4b6903,_0x109794)=>_0x4b6903+_0x109794[_0xae2a53(0x22e)],0x1f*-0x137+0x163+0x2446),'hostPolicyVersion':HOST_POLICY_VERSION,'publishedByUserId':_0x227fa0[_0xae2a53(0x241)],'publishedAt':_0x3413b4});this[_0xae2a53(0x28c)](_0x227fa0[_0xae2a53(0x2a9)],_0x35a1c0,_0x4d4118,_0x273f5a),_0x10a37d=_0xae2a53(0x28f),await this[_0xae2a53(0x1e5)](_0x227fa0[_0xae2a53(0x2a9)]);}catch(_0x554487){if(_0x10a37d===_0xae2a53(0x28f))return;await writableRemove(_0x211131);if(_0x1e9743!==undefined)await writableRemove(_0x1e9743);const _0x2f519f=safeErrorCode(_0x554487,_0xae2a53(0x268));this[_0xae2a53(0x27f)][_0xae2a53(0x243)][_0xae2a53(0x298)][_0xae2a53(0x26b)](_0xae2a53(0x27b))[_0xae2a53(0x1f7)](_0x10a37d,_0x2f519f,_0xae2a53(0x215)+_0x2f519f+').',this[_0xae2a53(0x267)](),_0x227fa0[_0xae2a53(0x2a9)]);}}async[_0x31b997(0x1eb)](_0x3f24c1){const _0x5c2534=_0x31b997;this[_0x5c2534(0x20d)](_0x3f24c1);const _0x2139df=this[_0x5c2534(0x27f)][_0x5c2534(0x243)][_0x5c2534(0x275)](_0x3f24c1[_0x5c2534(0x247)]);if(_0x2139df===undefined)throw new Error(_0x5c2534(0x1fd));const _0x4ffdb7=await realpath(_0x2139df[_0x5c2534(0x251)]),_0xa1609a=this[_0x5c2534(0x27f)][_0x5c2534(0x1e3)]?.(_0x4ffdb7)??_0x4ffdb7;validateSourceWorkspacePath(_0xa1609a);const _0x2219ec=new Set(),_0x4a2f4a=new Map();let _0x120f4a=0x3*0x39+0x10bd+-0x1168;const _0x78c81f=await hostedFilesystemAvailableBytes(this[_0x5c2534(0x27f)][_0x5c2534(0x216)][_0x5c2534(0x28e)]);return await walkWorkspace(_0x4ffdb7,'',{'directory':_0x371a5b=>{const _0x35a14b=_0x5c2534;_0x2219ec[_0x35a14b(0x2a4)](_0x371a5b);},'file':async(_0x436132,_0xa8addf,_0x5129a2)=>{const _0xd9fce9=_0x5c2534;if(_0x4a2f4a[_0xd9fce9(0x26d)](_0xa8addf))return;const _0x38033b=Number(_0x5129a2[_0xd9fce9(0x22e)]);_0x120f4a+=_0x38033b;if(!Number[_0xd9fce9(0x27d)](_0x120f4a)||_0x120f4a>_0x78c81f)throw new Error(_0xd9fce9(0x25c));_0x4a2f4a[_0xd9fce9(0x21a)](_0xa8addf,{'kind':_0xd9fce9(0x262),'relativePath':_0xa8addf,'sourcePath':_0x436132,'size':_0x38033b,'executable':(Number(_0x5129a2[_0xd9fce9(0x253)])&0x2327+0x1*-0x113f+0xd*-0x15b)!==-0x2400*-0x1+0x88d+-0x8e9*0x5,'sha256':hashBuffer(await readFile(_0x436132))});},'symlink':async(_0x209502,_0xd9ea81,_0x4cc0da)=>{const _0xfebeb5=_0x5c2534;if(_0x4a2f4a[_0xfebeb5(0x26d)](_0xd9ea81))return;const _0x50608e=await publishedSymlink(_0x4ffdb7,_0x209502,_0xd9ea81,_0x4cc0da);_0x120f4a+=_0x50608e[_0xfebeb5(0x22e)];if(!Number[_0xfebeb5(0x27d)](_0x120f4a)||_0x120f4a>_0x78c81f)throw new Error(_0xfebeb5(0x25c));_0x4a2f4a[_0xfebeb5(0x21a)](_0xd9ea81,_0x50608e);}}),{'sourceWorkspacePath':_0xa1609a,'directories':[..._0x2219ec][_0x5c2534(0x1d1)]((_0x41e2b1,_0x304bdd)=>_0x41e2b1[_0x5c2534(0x1f9)](_0x304bdd,_0x5c2534(0x1d0))),'entries':[..._0x4a2f4a[_0x5c2534(0x1f4)]()][_0x5c2534(0x1d1)]((_0x503081,_0x161061)=>_0x503081[_0x5c2534(0x21c)][_0x5c2534(0x1f9)](_0x161061[_0x5c2534(0x21c)],_0x5c2534(0x1d0)))};}[_0x31b997(0x292)](_0x14180a){const _0x46f4a9=_0x31b997;return this[_0x46f4a9(0x27f)][_0x46f4a9(0x243)][_0x46f4a9(0x1e7)](_0x14180a)[_0x46f4a9(0x294)](_0x518bc2=>({'id':_0x518bc2[_0x46f4a9(0x1fa)],'serverName':_0x518bc2[_0x46f4a9(0x1ce)],'displayName':_0x518bc2[_0x46f4a9(0x1fc)],'transport':_0x518bc2[_0x46f4a9(0x25d)][_0x46f4a9(0x264)],'origin':_0x518bc2[_0x46f4a9(0x279)]}));}[_0x31b997(0x29f)](_0x24d0e7){const _0x1f9ac3=_0x31b997,_0x4684be=new Map(this[_0x1f9ac3(0x27f)][_0x1f9ac3(0x243)][_0x1f9ac3(0x1e7)](_0x24d0e7[_0x1f9ac3(0x247)])[_0x1f9ac3(0x294)](_0x4d1d02=>[_0x4d1d02[_0x1f9ac3(0x1fa)],_0x4d1d02]));return _0x24d0e7[_0x1f9ac3(0x27e)][_0x1f9ac3(0x294)](_0x469d69=>{const _0x4be241=_0x1f9ac3,_0x532590=_0x4684be[_0x4be241(0x257)](_0x469d69);if(_0x532590===undefined||_0x532590[_0x4be241(0x25d)][_0x4be241(0x264)]===_0x4be241(0x278)&&_0x24d0e7[_0x4be241(0x1db)]!==_0x4be241(0x1ca))throw new Error(_0x4be241(0x261));return{'id':_0x532590[_0x4be241(0x1fa)],'serverName':_0x532590[_0x4be241(0x1ce)],'displayName':_0x532590[_0x4be241(0x1fc)],'version':_0x532590[_0x4be241(0x213)],'origin':_0x532590[_0x4be241(0x279)],'transport':_0x532590[_0x4be241(0x25d)][_0x4be241(0x264)],'runtime':_0x532590[_0x4be241(0x25d)],'configuration':_0x532590[_0x4be241(0x2a5)]};});}[_0x31b997(0x20d)](_0x488e8f){const _0x5b5251=_0x31b997,_0x31221c=conversationTemplateDraftSchema[_0x5b5251(0x299)](_0x488e8f);if(_0x31221c[_0x5b5251(0x23e)]!==this[_0x5b5251(0x27f)][_0x5b5251(0x23e)]())throw new Error(_0x5b5251(0x29b));}[_0x31b997(0x26c)](_0x53d881){const _0x5d3f43=_0x31b997,_0x381205=this[_0x5d3f43(0x27f)][_0x5d3f43(0x243)][_0x5d3f43(0x298)][_0x5d3f43(0x26b)](_0x5d3f43(0x2ad))[_0x5d3f43(0x257)](_0x53d881);return numberValue(_0x381205,_0x5d3f43(0x20b))+(-0x310+0x1c4*0xa+0x3*-0x4dd);}[_0x31b997(0x28c)](_0x163cc2,_0x1b66f8,_0x4fec1d,_0x5ac83a){const _0x1397d4=_0x31b997,_0x52c541=this[_0x1397d4(0x27f)][_0x1397d4(0x243)][_0x1397d4(0x298)];_0x52c541[_0x1397d4(0x2c5)](_0x1397d4(0x255));try{const _0x4c1173=this[_0x1397d4(0x1cb)](_0x163cc2);if(stringValue(_0x4c1173,_0x1397d4(0x2b1))!==_0x5ac83a[_0x1397d4(0x2b3)]||stringValue(_0x4c1173,_0x1397d4(0x24c))!==_0x1397d4(0x248)||stringValue(_0x4c1173,_0x1397d4(0x1fe))!==_0x1397d4(0x25b)||_0x4c1173[_0x1397d4(0x2ae)]!==null||numberValue(_0x4c1173,_0x1397d4(0x258))!==_0x5ac83a[_0x1397d4(0x242)])throw new Error(_0x1397d4(0x28b));const _0x559f19=_0x52c541[_0x1397d4(0x26b)](_0x1397d4(0x2a0))[_0x1397d4(0x1f7)](_0x5ac83a['id'],_0x5ac83a[_0x1397d4(0x2b3)],_0x5ac83a[_0x1397d4(0x213)],numberValue(_0x4c1173,_0x1397d4(0x1e2)),_0x5ac83a[_0x1397d4(0x1fe)],_0x1b66f8,_0x4fec1d,_0x5ac83a[_0x1397d4(0x2b2)],_0x5ac83a[_0x1397d4(0x1ee)],_0x5ac83a[_0x1397d4(0x225)],_0x5ac83a[_0x1397d4(0x2a8)],_0x5ac83a[_0x1397d4(0x2c0)],_0x5ac83a[_0x1397d4(0x2c9)],_0x5ac83a[_0x1397d4(0x242)],_0x5ac83a[_0x1397d4(0x207)]);if(Number(_0x559f19[_0x1397d4(0x21b)])!==0x1a*0xd8+-0x4c*0x43+0x1*-0x20b)throw new Error(_0x1397d4(0x28b));const _0x2086a7=_0x52c541[_0x1397d4(0x26b)](_0x1397d4(0x1d7))[_0x1397d4(0x1f7)](_0x5ac83a['id'],_0x5ac83a[_0x1397d4(0x207)],_0x163cc2,_0x5ac83a[_0x1397d4(0x2b3)],numberValue(_0x4c1173,_0x1397d4(0x1e2)),_0x5ac83a[_0x1397d4(0x242)]);if(Number(_0x2086a7[_0x1397d4(0x21b)])!==0x16a7+0x114d+-0x1e7*0x15)throw new Error(_0x1397d4(0x28b));_0x52c541[_0x1397d4(0x2c5)](_0x1397d4(0x277));}catch(_0x9e9b2b){_0x52c541[_0x1397d4(0x2c5)](_0x1397d4(0x280));throw _0x9e9b2b;}}async[_0x31b997(0x1e5)](_0x58020b){const _0x430289=_0x31b997,_0x1371f3=this[_0x430289(0x1cb)](_0x58020b);if(stringValue(_0x1371f3,_0x430289(0x24c))!==_0x430289(0x28f)||stringValue(_0x1371f3,_0x430289(0x1fe))!==_0x430289(0x25b)||_0x1371f3[_0x430289(0x2ae)]===null)throw new Error(_0x430289(0x28b));const _0x8740fe=stringValue(_0x1371f3,_0x430289(0x2ae)),_0x5777aa=this[_0x430289(0x27f)][_0x430289(0x243)][_0x430289(0x298)][_0x430289(0x26b)](_0x430289(0x244))[_0x430289(0x257)](_0x8740fe);if(_0x5777aa===undefined||stringValue(_0x5777aa,_0x430289(0x2b1))!==stringValue(_0x1371f3,_0x430289(0x2b1)))throw new Error(_0x430289(0x28b));const _0x4c94bf=this[_0x430289(0x27f)][_0x430289(0x243)][_0x430289(0x298)][_0x430289(0x26b)](_0x430289(0x2a3))[_0x430289(0x1f7)](this[_0x430289(0x267)](),_0x58020b,_0x8740fe);if(Number(_0x4c94bf[_0x430289(0x21b)])!==0x2*-0xee3+0x51*-0x53+0x380a)throw new Error(_0x430289(0x28b));}async[_0x31b997(0x1d6)](_0x2300c3){const _0x24e436=_0x31b997,_0x1835b9=_0x2300c3===undefined?this[_0x24e436(0x27f)][_0x24e436(0x243)][_0x24e436(0x298)][_0x24e436(0x26b)](_0x24e436(0x2c1))[_0x24e436(0x1c7)]():this[_0x24e436(0x27f)][_0x24e436(0x243)][_0x24e436(0x298)][_0x24e436(0x26b)](_0x24e436(0x289))[_0x24e436(0x1c7)](_0x2300c3);for(const _0x2f856b of _0x1835b9)await this[_0x24e436(0x1e5)](stringValue(_0x2f856b,'id'));}[_0x31b997(0x2b9)](_0x5a4b68,_0x22417d,_0x5b19c4){const _0x35e71c=_0x31b997;this[_0x35e71c(0x27f)][_0x35e71c(0x243)][_0x35e71c(0x298)][_0x35e71c(0x26b)](_0x35e71c(0x236))[_0x35e71c(0x1f7)](_0x22417d,_0x5b19c4,this[_0x35e71c(0x267)](),_0x5a4b68);}[_0x31b997(0x2be)](_0xcdae9){const _0x4089f1=_0x31b997,_0x19c0ae=publishJob(_0xcdae9),_0x46d54b=_0x19c0ae[_0x4089f1(0x1fe)]!==_0x4089f1(0x2b6)||_0x19c0ae[_0x4089f1(0x269)]===undefined?undefined:this[_0x4089f1(0x27f)][_0x4089f1(0x243)][_0x4089f1(0x298)][_0x4089f1(0x26b)](_0x4089f1(0x237))[_0x4089f1(0x257)](_0x19c0ae[_0x4089f1(0x269)]);return conversationTemplatePublishResultSchema[_0x4089f1(0x299)]({'job':_0x19c0ae,..._0x46d54b===undefined?{}:{'version':templateVersion(_0x46d54b)}});}[_0x31b997(0x2c3)](_0x5129dc){const _0x2d704a=_0x31b997;return this[_0x2d704a(0x27f)][_0x2d704a(0x243)][_0x2d704a(0x298)][_0x2d704a(0x26b)](_0x2d704a(0x238))[_0x2d704a(0x257)](_0x5129dc);}[_0x31b997(0x1cb)](_0x303ae1){const _0x3734a2=_0x31b997,_0x1cde27=this[_0x3734a2(0x2c3)](_0x303ae1);if(_0x1cde27===undefined)throw new Error(_0x3734a2(0x287));return _0x1cde27;}async[_0x31b997(0x2ba)](_0x596ff6){const _0x1d6c88=_0x31b997,_0x58a8a4=stringValue(_0x596ff6,_0x1d6c88(0x1cf)),_0x7423e5=this[_0x1d6c88(0x27f)][_0x1d6c88(0x216)][_0x1d6c88(0x290)](_0x58a8a4),_0x552ebc=await readFile(join(_0x7423e5,_0x1d6c88(0x259)),_0x1d6c88(0x26e)),_0x1334f3=_0x552ebc[_0x1d6c88(0x206)]('\x0a')?_0x552ebc[_0x1d6c88(0x250)](-0xf*0x199+0x2229+-0xa32,-(0x1ce3+0x1430+-0x3112)):_0x552ebc;if(hashText(_0x1334f3)!==stringValue(_0x596ff6,_0x1d6c88(0x1f3)))throw new Error(_0x1d6c88(0x28b));const _0x5c823d=templateVersionManifest(JSON[_0x1d6c88(0x299)](_0x1334f3));if(_0x5c823d[_0x1d6c88(0x225)]!==stringValue(_0x596ff6,_0x1d6c88(0x25e))||hashText(JSON[_0x1d6c88(0x1de)](_0x5c823d[_0x1d6c88(0x1ec)]))!==_0x5c823d[_0x1d6c88(0x225)]||_0x5c823d[_0x1d6c88(0x2b2)]!==stringValue(_0x596ff6,_0x1d6c88(0x2c2))||_0x5c823d[_0x1d6c88(0x1c4)][_0x1d6c88(0x1f8)]!==numberValue(_0x596ff6,_0x1d6c88(0x1cc))||_0x5c823d[_0x1d6c88(0x1c4)][_0x1d6c88(0x22d)]((_0x577e33,_0x322150)=>_0x577e33+_0x322150[_0x1d6c88(0x22e)],0x1c0b+0x2342+0x90b*-0x7)!==numberValue(_0x596ff6,_0x1d6c88(0x1c9))||snapshotContentHash(_0x5c823d[_0x1d6c88(0x20a)],_0x5c823d[_0x1d6c88(0x1c4)],_0x5c823d[_0x1d6c88(0x20f)])!==_0x5c823d[_0x1d6c88(0x2b2)])throw new Error(_0x1d6c88(0x28b));const _0x1e3f86=new Map(_0x5c823d[_0x1d6c88(0x1c4)][_0x1d6c88(0x294)](_0x54cda4=>[_0x54cda4[_0x1d6c88(0x21c)],_0x54cda4])),_0x553deb=new Set([..._0x5c823d[_0x1d6c88(0x20a)],_0x1d6c88(0x1c6),_0x1d6c88(0x221)]),_0x5d7931=new Set(),_0xfd1246=await listSnapshotEntries(join(_0x7423e5,_0x1d6c88(0x270)),_0x553deb,_0x5d7931,!![],_0x1d6c88(0x28b));if(_0xfd1246[_0x1d6c88(0x1f8)]!==_0x1e3f86[_0x1d6c88(0x22e)]||_0x5d7931[_0x1d6c88(0x22e)]!==_0x553deb[_0x1d6c88(0x22e)])throw new Error(_0x1d6c88(0x28b));for(const _0x307f51 of _0xfd1246){const _0x2d2d2a=_0x1e3f86[_0x1d6c88(0x257)](_0x307f51[_0x1d6c88(0x21c)]);if(_0x2d2d2a===undefined||_0x2d2d2a[_0x1d6c88(0x24f)]!==_0x307f51[_0x1d6c88(0x24f)])throw new Error(_0x1d6c88(0x28b));if(_0x2d2d2a[_0x1d6c88(0x24f)]===_0x1d6c88(0x262)&&_0x307f51[_0x1d6c88(0x24f)]===_0x1d6c88(0x262)){if(_0x2d2d2a[_0x1d6c88(0x22e)]!==_0x307f51[_0x1d6c88(0x22e)]||_0x2d2d2a[_0x1d6c88(0x2c8)]!==_0x307f51[_0x1d6c88(0x2c8)]||((await lstat(_0x307f51[_0x1d6c88(0x204)]))[_0x1d6c88(0x253)]&-0x11be+-0x1*0x4cf+0x1*0x188c)!==(_0x2d2d2a[_0x1d6c88(0x2c8)]?0x4*-0x2b9+-0x156f+0x21c0:-0x19*0x151+0x26da+-0x4cd)||_0x2d2d2a[_0x1d6c88(0x260)]!==_0x307f51[_0x1d6c88(0x260)])throw new Error(_0x1d6c88(0x28b));continue;}if(_0x2d2d2a[_0x1d6c88(0x24f)]!==_0x1d6c88(0x27c)||_0x307f51[_0x1d6c88(0x24f)]!==_0x1d6c88(0x27c)||_0x2d2d2a[_0x1d6c88(0x22e)]!==_0x307f51[_0x1d6c88(0x22e)]||_0x2d2d2a[_0x1d6c88(0x293)]!==_0x307f51[_0x1d6c88(0x293)])throw new Error(_0x1d6c88(0x28b));await verifySymlinkResolution(join(_0x7423e5,_0x1d6c88(0x270)),_0x2d2d2a,_0x307f51[_0x1d6c88(0x204)],_0x1d6c88(0x28b));}}}function publishJob(_0x15ee78){const _0x5e34e3=_0x31b997;return conversationTemplatePublishJobSchema[_0x5e34e3(0x299)]({'id':stringValue(_0x15ee78,'id'),'templateId':stringValue(_0x15ee78,_0x5e34e3(0x2b1)),'draftRevision':numberValue(_0x15ee78,_0x5e34e3(0x1e2)),'stage':stringValue(_0x15ee78,_0x5e34e3(0x24c)),'status':stringValue(_0x15ee78,_0x5e34e3(0x1fe)),..._0x15ee78[_0x5e34e3(0x2ae)]===null?{}:{'versionId':stringValue(_0x15ee78,_0x5e34e3(0x2ae))},'errorCode':_0x15ee78[_0x5e34e3(0x26a)]===null?null:stringValue(_0x15ee78,_0x5e34e3(0x26a)),..._0x15ee78[_0x5e34e3(0x2a2)]===null?{}:{'errorSummary':stringValue(_0x15ee78,_0x5e34e3(0x2a2))},'createdAt':numberValue(_0x15ee78,_0x5e34e3(0x230)),'updatedAt':numberValue(_0x15ee78,_0x5e34e3(0x26f))});}function templateVersion(_0x29f11f){const _0x48f515=_0x31b997;return conversationTemplateVersionSchema[_0x48f515(0x299)]({'id':stringValue(_0x29f11f,'id'),'templateId':stringValue(_0x29f11f,_0x48f515(0x2b1)),'version':numberValue(_0x29f11f,_0x48f515(0x20b)),'status':stringValue(_0x29f11f,_0x48f515(0x1fe)),'contentHash':stringValue(_0x29f11f,_0x48f515(0x2c2)),'manifestHash':stringValue(_0x29f11f,_0x48f515(0x1f3)),'mcpConfigHash':stringValue(_0x29f11f,_0x48f515(0x25e)),'fileCount':numberValue(_0x29f11f,_0x48f515(0x1cc)),'totalBytes':numberValue(_0x29f11f,_0x48f515(0x1c9)),'hostPolicyVersion':numberValue(_0x29f11f,_0x48f515(0x1ff)),'publishedByUserId':numberValue(_0x29f11f,_0x48f515(0x1c8)),'publishedAt':numberValue(_0x29f11f,_0x48f515(0x1df))});}async function walkWorkspace(_0x130185,_0xd044b7,_0x4c382e){const _0x5dd3d3=_0x31b997,_0x16c843=await lstat(_0x130185)[_0x5dd3d3(0x245)](_0x3c2e90=>{const _0x6b8de1=_0x5dd3d3;if(_0x3c2e90[_0x6b8de1(0x1d3)]===_0x6b8de1(0x201))throw new Error(_0x6b8de1(0x256));throw _0x3c2e90;});if(_0x16c843[_0x5dd3d3(0x24b)]()){if(_0xd044b7[_0x5dd3d3(0x1f8)]===-0x176f+0x2422+0x1*-0xcb3)throw new Error(_0x5dd3d3(0x21f));await _0x4c382e[_0x5dd3d3(0x209)](_0x130185,_0xd044b7,_0x16c843);return;}if(_0x16c843[_0x5dd3d3(0x273)]()){if(_0xd044b7[_0x5dd3d3(0x1f8)]===-0x6*-0x1f2+-0x1e19+0x59*0x35)throw new Error(_0x5dd3d3(0x29b));await _0x4c382e[_0x5dd3d3(0x291)](_0x130185,_0xd044b7,_0x16c843);return;}if(!_0x16c843[_0x5dd3d3(0x29d)]())throw new Error(_0x5dd3d3(0x1e9));if(_0xd044b7[_0x5dd3d3(0x1f8)]>0x1d71*0x1+-0x903*-0x1+0x5c*-0x6b)_0x4c382e[_0x5dd3d3(0x1cd)](_0xd044b7);for(const _0x49db33 of(await readdir(_0x130185,{'withFileTypes':!![]}))[_0x5dd3d3(0x1d1)]((_0x2e6bae,_0xd0e2c6)=>_0x2e6bae[_0x5dd3d3(0x212)][_0x5dd3d3(0x1f9)](_0xd0e2c6[_0x5dd3d3(0x212)],_0x5dd3d3(0x1d0)))){const _0x143b1d=_0xd044b7[_0x5dd3d3(0x1f8)]===0xb*-0x121+0x178*0x8+-0x1*-0xab?_0x49db33[_0x5dd3d3(0x212)]:_0xd044b7+'/'+_0x49db33[_0x5dd3d3(0x212)];if(_0xd044b7[_0x5dd3d3(0x1f8)]===-0x6*-0x48d+0x1642+0xd*-0x3d0&&(_0x49db33[_0x5dd3d3(0x212)]===_0x5dd3d3(0x1c6)||_0x49db33[_0x5dd3d3(0x212)]===_0x5dd3d3(0x221)))throw new Error(_0x5dd3d3(0x1ed));if(forcedExcluded(_0x143b1d))continue;await walkWorkspace(join(_0x130185,_0x49db33[_0x5dd3d3(0x212)]),_0x143b1d,_0x4c382e);}}async function sealDirectories(_0x23d7cc,_0x4b2673=!![]){const _0xc34aa2=_0x31b997,_0x1d3576=await readdir(_0x23d7cc,{'withFileTypes':!![]});for(const _0x483f97 of _0x1d3576)if(_0x483f97[_0xc34aa2(0x29d)]())await sealDirectories(join(_0x23d7cc,_0x483f97[_0xc34aa2(0x212)]));if(_0x4b2673)await chmod(_0x23d7cc,0x263f+0x195c+-0x3e2e);}async function writableRemove(_0x1627a4){const _0x575b42=_0x31b997;await chmodTree(_0x1627a4)[_0x575b42(0x245)](()=>undefined),await rm(_0x1627a4,{'recursive':!![],'force':!![]});}async function chmodTree(_0x5901f4){const _0x28dd76=_0x31b997,_0x2096f7=await lstat(_0x5901f4);if(_0x2096f7[_0x28dd76(0x24b)]())return;if(_0x2096f7[_0x28dd76(0x29d)]()){await chmod(_0x5901f4,-0x1de+-0x1*0x2361+-0x95*-0x43);for(const _0x2aba86 of await readdir(_0x5901f4))await chmodTree(join(_0x5901f4,_0x2aba86));}else await chmod(_0x5901f4,-0x1dd7+-0xbc1+0x2b18);}async function verifyCopiedSnapshot(_0x2aa686,_0x2fbed9,_0x5c24b1){const _0xd93173=_0x31b997,_0x4b4db3=new Map(_0x5c24b1[_0xd93173(0x294)](_0x9e980e=>[_0x9e980e[_0xd93173(0x21c)],_0x9e980e])),_0xe8e1ab=new Set([..._0x2fbed9,_0xd93173(0x1c6),_0xd93173(0x221)]),_0x38e476=new Set(),_0x46bc62=await listSnapshotEntries(_0x2aa686,_0xe8e1ab,_0x38e476,![],_0xd93173(0x254));if(_0x38e476[_0xd93173(0x22e)]!==_0xe8e1ab[_0xd93173(0x22e)])throw new Error(_0xd93173(0x254));if(_0x46bc62[_0xd93173(0x1f8)]!==_0x4b4db3[_0xd93173(0x22e)])throw new Error(_0xd93173(0x254));for(const _0x47a96b of _0x46bc62){const _0x2e8fa1=_0x4b4db3[_0xd93173(0x257)](_0x47a96b[_0xd93173(0x21c)]);if(_0x2e8fa1===undefined||_0x2e8fa1[_0xd93173(0x24f)]!==_0x47a96b[_0xd93173(0x24f)])throw new Error(_0xd93173(0x254));if(_0x2e8fa1[_0xd93173(0x24f)]===_0xd93173(0x262)&&_0x47a96b[_0xd93173(0x24f)]===_0xd93173(0x262)){if(_0x2e8fa1[_0xd93173(0x22e)]!==_0x47a96b[_0xd93173(0x22e)]||_0x2e8fa1[_0xd93173(0x2c8)]!==_0x47a96b[_0xd93173(0x2c8)]||_0x2e8fa1[_0xd93173(0x260)]!==_0x47a96b[_0xd93173(0x260)])throw new Error(_0xd93173(0x254));continue;}if(_0x2e8fa1[_0xd93173(0x24f)]!==_0xd93173(0x27c)||_0x47a96b[_0xd93173(0x24f)]!==_0xd93173(0x27c)||_0x2e8fa1[_0xd93173(0x22e)]!==_0x47a96b[_0xd93173(0x22e)]||_0x2e8fa1[_0xd93173(0x293)]!==_0x47a96b[_0xd93173(0x293)])throw new Error(_0xd93173(0x254));await verifySymlinkResolution(_0x2aa686,_0x2e8fa1,_0x47a96b[_0xd93173(0x204)],_0xd93173(0x254));}}async function verifySymlinkResolution(_0x379014,_0x46626f,_0x4f1208,_0x288ed1){const _0x2f0961=_0x31b997;let _0x3441e7;try{_0x3441e7=await realpath(_0x4f1208);}catch{throw new Error(_0x288ed1);}if(_0x46626f[_0x2f0961(0x279)]===_0x2f0961(0x22f)){if(_0x3441e7!==_0x46626f[_0x2f0961(0x1c5)])throw new Error(_0x288ed1);return;}let _0x3a8e2c;try{_0x3a8e2c=await realpath(join(_0x379014,..._0x46626f[_0x2f0961(0x1c5)][_0x2f0961(0x208)]('/')));}catch{throw new Error(_0x288ed1);}if(_0x3441e7!==_0x3a8e2c||!within(await realpath(_0x379014),_0x3441e7))throw new Error(_0x288ed1);}function _0x1255(_0x4a7733,_0x176907){_0x4a7733=_0x4a7733-(0x1bb0+-0xf16+-0xad8);const _0x4b8f27=_0x14ad();let _0x3e1f17=_0x4b8f27[_0x4a7733];if(_0x1255['WRNVFj']===undefined){var _0x50fc92=function(_0x4046e8){const _0x4b55cf='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x44ce64='',_0xc682ad='';for(let _0x250248=0x1*-0x4ff+0xfb*-0xc+0x10c3*0x1,_0x4e9cb5,_0x128c07,_0xb59f6a=0x1d5f+0xed1*-0x2+0x43;_0x128c07=_0x4046e8['charAt'](_0xb59f6a++);~_0x128c07&&(_0x4e9cb5=_0x250248%(-0xa20+0x18ca+-0xea6)?_0x4e9cb5*(0xa3c*0x2+0xb*-0x2b9+0x9bb)+_0x128c07:_0x128c07,_0x250248++%(-0x2b*0xe7+0x1315+0x13bc))?_0x44ce64+=String['fromCharCode'](0x3e1+-0x2180+0x1e9e&_0x4e9cb5>>(-(-0x1f51+0x1ab8+0x49b)*_0x250248&0x5fd+-0x11f*0x18+0x1*0x14f1)):0x1f*-0x137+0x163+0x2446){_0x128c07=_0x4b55cf['indexOf'](_0x128c07);}for(let _0xfa25b4=0x3*0x39+0x10bd+-0x1168,_0x5bf3d0=_0x44ce64['length'];_0xfa25b4<_0x5bf3d0;_0xfa25b4++){_0xc682ad+='%'+('00'+_0x44ce64['charCodeAt'](_0xfa25b4)['toString'](0x2327+0x1*-0x113f+0x8*-0x23b))['slice'](-(-0x2400*-0x1+0x88d+-0x21f*0x15));}return decodeURIComponent(_0xc682ad);};_0x1255['OkJJhP']=_0x50fc92,_0x1255['JiblRG']={},_0x1255['WRNVFj']=!![];}const _0x148b5c=_0x4b8f27[-0x310+0x1c4*0xa+0x2*-0x74c];_0x1255['OwPBjv']!==_0x148b5c&&(_0x1255['JiblRG']={},_0x1255['OwPBjv']=_0x148b5c);const _0x443e1f=_0x1255['JiblRG'][_0x4a7733];return _0x443e1f===undefined?(_0x3e1f17=_0x1255['OkJJhP'](_0x3e1f17),_0x1255['JiblRG'][_0x4a7733]=_0x3e1f17):_0x3e1f17=_0x443e1f,_0x3e1f17;}async function listSnapshotEntries(_0xe2d30,_0xcb212b,_0x13881f,_0x1d3d99,_0x3502a4,_0x219cce=''){const _0x2c3bda=_0x31b997,_0x1a3626=await lstat(_0xe2d30);if(!_0x1a3626[_0x2c3bda(0x29d)]()||_0x1a3626[_0x2c3bda(0x24b)]()||_0x1d3d99&&(_0x1a3626[_0x2c3bda(0x253)]&0x17f*0x14+0xe6*0x1d+-0x35fb)!==0x2*-0x1387+-0x2143+0x49be)throw new Error(_0x3502a4);const _0x110da6=[];for(const _0x493030 of await readdir(_0xe2d30,{'withFileTypes':!![]})){const _0x49d4d0=join(_0xe2d30,_0x493030[_0x2c3bda(0x212)]),_0xef9e86=_0x219cce[_0x2c3bda(0x1f8)]===-0x2538+-0x106f+-0x5*-0xabb?_0x493030[_0x2c3bda(0x212)]:_0x219cce+'/'+_0x493030[_0x2c3bda(0x212)],_0x5636c1=await lstat(_0x49d4d0);if(_0x5636c1[_0x2c3bda(0x24b)]()){const _0x107901=await readlink(_0x49d4d0);_0x110da6[_0x2c3bda(0x2bd)]({'kind':_0x2c3bda(0x27c),'relativePath':_0xef9e86,'sourcePath':_0x49d4d0,'size':Buffer[_0x2c3bda(0x1d8)](_0x107901),'linkTarget':_0x107901});continue;}if(_0x5636c1[_0x2c3bda(0x29d)]()){if(!_0xcb212b[_0x2c3bda(0x26d)](_0xef9e86))throw new Error(_0x3502a4);_0x13881f[_0x2c3bda(0x2a4)](_0xef9e86),_0x110da6[_0x2c3bda(0x2bd)](...await listSnapshotEntries(_0x49d4d0,_0xcb212b,_0x13881f,_0x1d3d99,_0x3502a4,_0xef9e86));continue;}if(!_0x5636c1[_0x2c3bda(0x273)]()||_0x5636c1[_0x2c3bda(0x229)]!==-0x8c0+0x2e3*-0x2+0xe87)throw new Error(_0x3502a4);_0x110da6[_0x2c3bda(0x2bd)]({'kind':_0x2c3bda(0x262),'relativePath':_0xef9e86,'sourcePath':_0x49d4d0,'size':Number(_0x5636c1[_0x2c3bda(0x22e)]),'executable':(_0x5636c1[_0x2c3bda(0x253)]&-0x11*-0x2b+0xbb+0x1*-0x34d)!==-0x1*0x257f+-0x47*-0x11+0x20c8*0x1,'sha256':hashBuffer(await readFile(_0x49d4d0))});}return _0x110da6;}function legacyPublishedDirectories(_0xb71615){const _0x2f5f36=_0x31b997,_0xf7e1f2=new Set([_0x2f5f36(0x1c6),_0x2f5f36(0x221)]);for(const _0x37bc19 of _0xb71615){const _0x2eded3=_0x37bc19[_0x2f5f36(0x21c)][_0x2f5f36(0x208)]('/');for(let _0x13b533=-0x56e+-0x1d77*-0x1+-0x1808;_0x13b533<_0x2eded3[_0x2f5f36(0x1f8)];_0x13b533+=-0x15eb+0xdc5+0x1*0x827)_0xf7e1f2[_0x2f5f36(0x2a4)](_0x2eded3[_0x2f5f36(0x250)](-0x8*-0x22d+-0x2500+-0x8*-0x273,_0x13b533)[_0x2f5f36(0x246)]('/'));}return _0xf7e1f2[_0x2f5f36(0x29e)](_0x2f5f36(0x1c6)),_0xf7e1f2[_0x2f5f36(0x29e)](_0x2f5f36(0x221)),[..._0xf7e1f2][_0x2f5f36(0x1d1)]((_0x57a9a4,_0x46e0e2)=>_0x57a9a4[_0x2f5f36(0x1f9)](_0x46e0e2,_0x2f5f36(0x1d0)));}function forcedExcluded(_0x58fc00){const _0x2c2ba2=_0x31b997,_0x13f2f5=_0x58fc00[_0x2c2ba2(0x208)]('/');if(_0x13f2f5[_0x2c2ba2(0x1ef)](_0xa4dac5=>{const _0x2cb240=_0x2c2ba2,_0x2b96a5=_0xa4dac5[_0x2cb240(0x2a6)](_0x2cb240(0x1d0));return FORCED_EXCLUDED_NAMES[_0x2cb240(0x26d)](_0x2b96a5)||_0x2b96a5[_0x2cb240(0x2bc)](_0x2cb240(0x231));}))return!![];const _0x502bd3=_0x13f2f5['at'](-(-0x229+0x10*0x112+-0xef6))?.[_0x2c2ba2(0x2a6)](_0x2c2ba2(0x1d0))??'';return _0x13f2f5[_0x2c2ba2(0x1f8)]===0x1*-0x1005+0x84a*0x3+-0x8d8&&(ROOT_EXCLUDED_NAMES[_0x2c2ba2(0x26d)](_0x502bd3)||_0x502bd3[_0x2c2ba2(0x206)](_0x2c2ba2(0x286))||_0x502bd3[_0x2c2ba2(0x206)](_0x2c2ba2(0x228))||_0x502bd3===_0x2c2ba2(0x265)||_0x502bd3===_0x2c2ba2(0x2c7))||_0x502bd3[_0x2c2ba2(0x206)](_0x2c2ba2(0x2b5));}async function publishedSymlink(_0x51f2db,_0xfaaba8,_0x196ed1,_0x7907e7){const _0x3d0e49=_0x31b997;if(!_0x7907e7[_0x3d0e49(0x24b)]())throw new Error(_0x3d0e49(0x21f));const _0x3f0e94=await readlink(_0xfaaba8);let _0xfa489d;try{_0xfa489d=await realpath(_0xfaaba8);}catch{throw new Error(_0x3d0e49(0x21f));}if(_0xfa489d===_0x51f2db||within(_0x51f2db,_0xfa489d)){const _0x346463=await lstat(_0xfa489d)[_0x3d0e49(0x245)](()=>undefined);if(_0x346463===undefined||_0x346463[_0x3d0e49(0x29d)]()&&(_0xfa489d===_0x51f2db||within(_0xfa489d,_0xfaaba8)))throw new Error(_0x3d0e49(0x21f));const _0x2cebf6=relative(_0x51f2db,_0xfa489d)[_0x3d0e49(0x208)](sep)[_0x3d0e49(0x246)]('/');if(_0x2cebf6[_0x3d0e49(0x1f8)]===-0x56+-0x1052*0x1+0x215*0x8||forcedExcluded(_0x2cebf6))throw new Error(_0x3d0e49(0x21f));return{'kind':_0x3d0e49(0x27c),'relativePath':_0x196ed1,'sourcePath':_0xfaaba8,'size':Buffer[_0x3d0e49(0x1d8)](_0x3f0e94),'linkTarget':_0x3f0e94,'targetKind':_0x3d0e49(0x1fb),'resolvedTarget':_0x2cebf6};}const _0x1988bf=RUNTIME_LINK_ROOTS[_0x3d0e49(0x233)](_0x29f9f1=>_0xfa489d===_0x29f9f1||within(_0x29f9f1,_0xfa489d));if(_0x1988bf===undefined)throw new Error(_0x3d0e49(0x21f));return{'kind':_0x3d0e49(0x27c),'relativePath':_0x196ed1,'sourcePath':_0xfaaba8,'size':Buffer[_0x3d0e49(0x1d8)](_0x3f0e94),'linkTarget':_0x3f0e94,'targetKind':_0x3d0e49(0x22f),'resolvedTarget':_0xfa489d};}function templateVersionManifest(_0x29abec){const _0xf2729b=_0x31b997;if(!record(_0x29abec))throw new Error(_0xf2729b(0x28b));const _0x4103a7=Array[_0xf2729b(0x1f0)](_0x29abec[_0xf2729b(0x1ec)])?_0x29abec[_0xf2729b(0x1ec)]:undefined;if(_0x4103a7===undefined||typeof _0x29abec[_0xf2729b(0x225)]!==_0xf2729b(0x20c)||typeof _0x29abec[_0xf2729b(0x2b2)]!==_0xf2729b(0x20c))throw new Error(_0xf2729b(0x28b));if(_0x29abec[_0xf2729b(0x20f)]===0x18fb+0x1*-0x1ab+-0x174f){if(!Array[_0xf2729b(0x1f0)](_0x29abec[_0xf2729b(0x266)]))throw new Error(_0xf2729b(0x28b));const _0x15e60d=_0x29abec[_0xf2729b(0x266)][_0xf2729b(0x294)](_0x1f34bc=>manifestFile(_0x1f34bc));return{'schemaVersion':0x1,'directories':legacyPublishedDirectories(_0x15e60d),'entries':_0x15e60d,'contentHash':_0x29abec[_0xf2729b(0x2b2)],'mcpServers':_0x4103a7,'mcpConfigHash':_0x29abec[_0xf2729b(0x225)]};}if(_0x29abec[_0xf2729b(0x20f)]!==0x2f6*-0x2+-0x1a3d*-0x1+-0x144f||typeof _0x29abec[_0xf2729b(0x1e3)]!==_0xf2729b(0x20c)||!Array[_0xf2729b(0x1f0)](_0x29abec[_0xf2729b(0x20a)])||!Array[_0xf2729b(0x1f0)](_0x29abec[_0xf2729b(0x1c4)]))throw new Error(_0xf2729b(0x28b));validateSourceWorkspacePath(_0x29abec[_0xf2729b(0x1e3)]);const _0x5adcee=_0x29abec[_0xf2729b(0x20a)][_0xf2729b(0x294)](_0x1972e0=>safeManifestRelativePath(_0x1972e0));if(new Set(_0x5adcee)[_0xf2729b(0x22e)]!==_0x5adcee[_0xf2729b(0x1f8)]||_0x5adcee[_0xf2729b(0x1e6)](_0xf2729b(0x1c6))||_0x5adcee[_0xf2729b(0x1e6)](_0xf2729b(0x221)))throw new Error(_0xf2729b(0x28b));const _0x163aae=_0x29abec[_0xf2729b(0x1c4)][_0xf2729b(0x294)](_0xf51923=>manifestEntry(_0xf51923));if(new Set(_0x163aae[_0xf2729b(0x294)](_0x313f77=>_0x313f77[_0xf2729b(0x21c)]))[_0xf2729b(0x22e)]!==_0x163aae[_0xf2729b(0x1f8)])throw new Error(_0xf2729b(0x28b));return{'schemaVersion':0x2,'sourceWorkspacePath':_0x29abec[_0xf2729b(0x1e3)],'directories':_0x5adcee,'entries':_0x163aae,'contentHash':_0x29abec[_0xf2729b(0x2b2)],'mcpServers':_0x4103a7,'mcpConfigHash':_0x29abec[_0xf2729b(0x225)]};}function manifestEntry(_0x4cfdc6){const _0x34f1fa=_0x31b997;if(!record(_0x4cfdc6))throw new Error(_0x34f1fa(0x28b));if(_0x4cfdc6[_0x34f1fa(0x24f)]===_0x34f1fa(0x262))return manifestFile(_0x4cfdc6,!![]);if(_0x4cfdc6[_0x34f1fa(0x24f)]!==_0x34f1fa(0x27c)||typeof _0x4cfdc6[_0x34f1fa(0x293)]!==_0x34f1fa(0x20c)||_0x4cfdc6[_0x34f1fa(0x293)][_0x34f1fa(0x1f8)]===-0xf45+-0x1*0x397+-0x2*-0x96e||_0x4cfdc6[_0x34f1fa(0x293)][_0x34f1fa(0x1e6)]('\x00')||_0x4cfdc6[_0x34f1fa(0x279)]!==_0x34f1fa(0x1fb)&&_0x4cfdc6[_0x34f1fa(0x279)]!==_0x34f1fa(0x22f)||typeof _0x4cfdc6[_0x34f1fa(0x1c5)]!==_0x34f1fa(0x20c))throw new Error(_0x34f1fa(0x28b));const _0x3c6214=safeManifestRelativePath(_0x4cfdc6[_0x34f1fa(0x21c)]),_0x321f3b=safeNonNegativeInteger(_0x4cfdc6[_0x34f1fa(0x22e)]),_0x5ee56e=_0x4cfdc6[_0x34f1fa(0x293)],_0x4f6a91=_0x4cfdc6[_0x34f1fa(0x279)],_0x329a5f=_0x4cfdc6[_0x34f1fa(0x1c5)];if(_0x321f3b!==Buffer[_0x34f1fa(0x1d8)](_0x5ee56e))throw new Error(_0x34f1fa(0x28b));if(_0x4f6a91===_0x34f1fa(0x1fb))safeManifestRelativePath(_0x329a5f);else{if(!isAbsolute(_0x329a5f)||!RUNTIME_LINK_ROOTS[_0x34f1fa(0x1ef)](_0xe24b27=>_0x329a5f===_0xe24b27||within(_0xe24b27,_0x329a5f)))throw new Error(_0x34f1fa(0x28b));}return{'kind':_0x34f1fa(0x27c),'relativePath':_0x3c6214,'size':_0x321f3b,'linkTarget':_0x5ee56e,'targetKind':_0x4f6a91,'resolvedTarget':_0x329a5f};}function manifestFile(_0x42299f,_0x4c3f8c=![]){const _0x188b10=_0x31b997;if(!record(_0x42299f)||_0x4c3f8c&&_0x42299f[_0x188b10(0x24f)]!==_0x188b10(0x262)||typeof _0x42299f[_0x188b10(0x2c8)]!==_0x188b10(0x22b)||typeof _0x42299f[_0x188b10(0x260)]!==_0x188b10(0x20c)||!/^[a-f0-9]{64}$/u[_0x188b10(0x1dc)](_0x42299f[_0x188b10(0x260)]))throw new Error(_0x188b10(0x28b));return{'kind':_0x188b10(0x262),'relativePath':safeManifestRelativePath(_0x42299f[_0x188b10(0x21c)]),'size':safeNonNegativeInteger(_0x42299f[_0x188b10(0x22e)]),'executable':_0x42299f[_0x188b10(0x2c8)],'sha256':_0x42299f[_0x188b10(0x260)]};}function safeManifestRelativePath(_0x9e2ea7){const _0x5422eb=_0x31b997;if(typeof _0x9e2ea7!==_0x5422eb(0x20c)||_0x9e2ea7[_0x5422eb(0x1f8)]===0x1458+0x528+0x1980*-0x1||_0x9e2ea7[_0x5422eb(0x2bc)]('/')||_0x9e2ea7[_0x5422eb(0x1e6)]('\x5c')||_0x9e2ea7[_0x5422eb(0x208)]('/')[_0x5422eb(0x1ef)](_0x57aab4=>_0x57aab4[_0x5422eb(0x1f8)]===-0x231+-0x2c*0xce+-0x36b*-0xb||_0x57aab4==='.'||_0x57aab4==='..'))throw new Error(_0x5422eb(0x28b));return _0x9e2ea7;}function safeNonNegativeInteger(_0x2f3eb7){const _0x4aec7d=_0x31b997;if(!Number[_0x4aec7d(0x27d)](_0x2f3eb7)||_0x2f3eb7<-0x596+0x1b9a*-0x1+0x2130)throw new Error(_0x4aec7d(0x28b));return _0x2f3eb7;}function snapshotContentHash(_0x16be91,_0x201c54,_0x4cc836=0x7f1+-0x1381+0xb92){const _0xf3254b=_0x31b997;if(_0x4cc836===-0x24e3+-0x915+0x2df9)return hashText(_0x201c54[_0xf3254b(0x294)](_0x518b9c=>{const _0x427b15=_0xf3254b;if(_0x518b9c[_0x427b15(0x24f)]!==_0x427b15(0x262))throw new Error(_0x427b15(0x28b));return _0x518b9c[_0x427b15(0x21c)]+'\x00'+_0x518b9c[_0x427b15(0x22e)]+'\x00'+_0x518b9c[_0x427b15(0x260)];})[_0xf3254b(0x246)]('\x0a'));return hashText([..._0x16be91[_0xf3254b(0x294)](_0x5ef1cb=>_0xf3254b(0x223)+_0x5ef1cb),..._0x201c54[_0xf3254b(0x294)](_0x332e0f=>_0x332e0f[_0xf3254b(0x24f)]===_0xf3254b(0x262)?_0x332e0f[_0xf3254b(0x24f)]+'\x00'+_0x332e0f[_0xf3254b(0x21c)]+'\x00'+_0x332e0f[_0xf3254b(0x22e)]+'\x00'+(_0x332e0f[_0xf3254b(0x2c8)]?0xee1*0x2+0x182c+-0x35ed:0x21*-0x9b+0xaa2+0x959)+'\x00'+_0x332e0f[_0xf3254b(0x260)]:_0x332e0f[_0xf3254b(0x24f)]+'\x00'+_0x332e0f[_0xf3254b(0x21c)]+'\x00'+_0x332e0f[_0xf3254b(0x22e)]+'\x00'+_0x332e0f[_0xf3254b(0x293)]+'\x00'+_0x332e0f[_0xf3254b(0x279)]+'\x00'+_0x332e0f[_0xf3254b(0x1c5)])][_0xf3254b(0x246)]('\x0a'));}async function hostedFilesystemAvailableBytes(_0x3ebad7){const _0x31683a=_0x31b997;try{const _0x53c5e1=await statfs(_0x3ebad7),_0x5b60b0=Number(_0x53c5e1[_0x31683a(0x2aa)])*Number(_0x53c5e1[_0x31683a(0x28d)]);if(!Number[_0x31683a(0x296)](_0x5b60b0)||_0x5b60b0<-0x3*-0x755+-0xdc1*0x2+0x583)throw new Error(_0x31683a(0x1d2));return Math[_0x31683a(0x28a)](Math[_0x31683a(0x227)](_0x5b60b0),Number[_0x31683a(0x1e0)]);}catch(_0x11d647){if(_0x11d647 instanceof Error&&_0x11d647[_0x31683a(0x232)]===_0x31683a(0x1d2))throw _0x11d647;throw new Error(_0x31683a(0x1d2));}}function validateSourceWorkspacePath(_0x2d7e0d){const _0x526c4e=_0x31b997;if(!isAbsolute(_0x2d7e0d)||resolve(_0x2d7e0d)!==_0x2d7e0d||_0x2d7e0d==='/'||_0x2d7e0d===_0x526c4e(0x2b8))throw new Error(_0x526c4e(0x29b));if(RESERVED_SANDBOX_ROOTS[_0x526c4e(0x1ef)](_0x164f19=>_0x2d7e0d===_0x164f19||within(_0x164f19,_0x2d7e0d)||within(_0x2d7e0d,_0x164f19)))throw new Error(_0x526c4e(0x29b));}function within(_0x26ac8e,_0x2cc13a){const _0x37dc52=_0x31b997,_0xd04d1a=relative(_0x26ac8e,_0x2cc13a);return _0xd04d1a[_0x37dc52(0x1f8)]>0x91d+-0x12d9+-0x2*-0x4de&&_0xd04d1a!=='..'&&!_0xd04d1a[_0x37dc52(0x2bc)]('..'+sep);}function hashText(_0x42817d){const _0x48df56=_0x31b997;return createHash(_0x48df56(0x260))[_0x48df56(0x2a7)](_0x42817d)[_0x48df56(0x252)](_0x48df56(0x1da));}function hashBuffer(_0x31bdc0){const _0x52ea9c=_0x31b997;return createHash(_0x52ea9c(0x260))[_0x52ea9c(0x2a7)](_0x31bdc0)[_0x52ea9c(0x252)](_0x52ea9c(0x1da));}function _0x14ad(){const _0x1c2737=['DgvTCgXHDgvFAwq','y29UDgvUDeHHC2G','DgvTCgXHDgvjza','ChvIBgLZAa','lNnVy2S','u1vdq0vfreve','l2XPyJy0','l3rTCa','DxbKyxrLsM9I','DMvYAwz5vMvYC2LVBG','yMfZzty0DxjS','C3rHCNrZv2L0Aa','ChvZAa','ChvIBgLZAfjLC3vSDa','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsbZB3vYy2uGAxmGAw52ywXPzcaO','Dg90ywXcExrLCW','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaGicaGicbxsevsrsbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCkicaGicaGicaGicaGicaGt1jerviGqLKGy3jLyxrLzf9HDcXPza','y29UDgvUDf9OyxnO','ChvIBgLZAePVyLjVDW','l3j1BG','zxHLyW','B3bLCMf0Aw9UCW','AwrFzwqYntuXoq','zxHLy3v0ywjSzq','Ag9ZDfbVBgLJEvzLCNnPB24','lNnZAa','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGu0vuihn0yxr1CZ0NrKfjtevejYX2zxjZAw9Ux2LKpu5vteWSzxjYB3jFy29Kzt0Nq09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFsu5urvjsvvburuqNlaOGicaGicaGicaGicaGzxjYB3jFC3vTBwfYEt0/lhvWzgf0zwrFyxq9pWOGicaGicaGicbxsevsrsbZDgf0DxmGsu4GkcDrvuvvruqNlcDsvu5osu5hjYKGqu5eihn0ywDLpd4NuKvhsvnurvjfrcC','q09ovKvsu0fusu9ox1rftvbmqvrfx0Loufvux0LovKfmsuq','l2rLDG','u0vmrunuihn0B3jHz2vFA2v5iezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25Z','zw50CMLLCW','CMvZB2X2zwruyxjNzxq','Aw5IB3G','ywXS','ChvIBgLZAgvKx2j5x3vZzxjFAwq','Dg90ywXFyNL0zxm','vu5srvnuuKLdveve','CMvXDwLYzvb1yMXPC2HkB2jsB3C','zMLSzv9JB3vUDa','zgLYzwn0B3j5','C2vYDMvYtMfTzq','C3rVCMfNzv9RzxK','zw4Tvvm','C29YDa','q09ovKvsu0fusu9ox0Hpu1rjtKDFu1rpuKfhrv9vtKfwquLmqujmrq','y29Kzq','q09ovKvsu0fusu9ox1rftvbmqvrfx05pvf9gt1vora','q09qwuLorW','zMLUAxnOuMvNAxn0zxjLzfb1yMXPy2f0Aw9UCW','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGicbtrvqGC3rHz2u9j1jfr0LtvevsruqNlhn0yxr1CZ0NuLvotKLorYCSDMvYC2LVBL9Pzd0/lgvYCM9Yx2nVzgu9tLvmtcXLCNjVCL9ZDw1Tyxj5pu5vteWScIaGicaGicaGicaGicaGihvWzgf0zwrFyxq9pWOGicaGicaGicaGifDirvjfigLKpt8Gqu5eihrLBxbSyxrLx2LKpt8Gqu5eigrYywz0x3jLDMLZAw9Upt8Gqu5eihjLCxvLC3rLzf9IEv91C2vYx2LKpt8kicaGicaGicaGicaGieforcbZDgfNzt0Nu0vbtevejYbbtKqGC3rHDhvZpsDsvu5osu5hjYbbtKqGDMvYC2LVBL9PzcbjuYbovuXm','yNL0zuXLBMD0Aa','ChvIBgLZAfn0yxr1CW','Agv4','BMv0D29YA01Vzgu','DgvZDa','lM1HCG','C3rYAw5NAwz5','ChvIBgLZAgvKx2f0','tufyx1nbrKvFsu5uruDfuG','q09ovKvsu0fusu9ox1rftvbmqvrfx05pvf9bvvrit1jjwKve','zhjHzNrFCMv2AxnPB24','C291CMnLv29YA3nWywnLugf0Aa','l3bYB2m','zMLUAxnOuMvNAxn0zxjLzfb1yMXPy2f0Aw9U','Aw5JBhvKzxm','zwzMzwn0AxzLtwnWsw5ZDgfSBgf0Aw9UCW','C2vJCMv0CW','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9uwvbfx0LovKfmsuq','zw5XDwv1zvb1yMXPC2G','y29SBgvJDfnUyxbZAg90','BwnWu2vYDMvYCW','q09ovKvsu0fusu9ox1rftvbmqvrfx1jfu0vsvKvex1bbveG','BwfUAwzLC3riyxnO','C29Tzq','AxnbCNjHEq','mtblrenUAe0','lMf6DxjL','BwfUAwzLC3rFAgfZAa','DMfSDwvZ','mJfVs3j5s0S','CgvYzM9YBvb1yMXPC2G','CNvU','BgvUz3rO','Bg9JywXLq29TCgfYzq','y2f0ywXVz0vUDhj5swq','u05bufnit1q','zgLZCgXHEu5HBwu','v09ss1nqqunfx05pvf9gt1vora','C3rHDhvZ','Ag9ZDf9WB2XPy3LFDMvYC2LVBG','nJm3ndLmCvHnANq','ru5pru5u','q09ovKvsu0fusu9ox1rftvbmqvrfx1jfvKLtsu9ox0nptKzmsunu','l3vZCG','C291CMnLugf0Aa','l2HVBwuVBwfY','zw5KC1DPDgG','ChvIBgLZAgvKqxq','C3bSAxq','C3LTBgLUAW','zgLYzwn0B3jPzxm','DMvYC2LVBL9UDw1Izxi','C3rYAw5N','yxnZzxj0tg9JywXeCMfMDa','CMvJB3zLCKLUDgvYCNvWDgvKuhvIBgLJyxrPB25Z','C2nOzw1HvMvYC2LVBG','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv92zxjZAw9UCYbtrvqGC3rHDhvZpsDdt1jsvvburuqNifDirvjfigLKpt8','B2jQzwn0','BMfTzq','DMvYC2LVBG','l2XPyG','vgHLihb1yMXPC2GGCMvXDwvZDcbMywLSzwqGka','C3rVCMu','tufosuzfu1q','refuqujbu0vFvKfmvuvFsu5wquXjrdO','yMLNAw50','C2v0','y2HHBMDLCW','CMvSyxrPDMvqyxrO','l3DVCMTZCgfJzq','vgHLihb1yMXPC2GGCMvXDwvZDcb3yxmGAw50zxjYDxb0zwqGyMvMB3jLihrOzsb0zw1WBgf0zsb2zxjZAw9UihDHCYbYzwDPC3rLCMvKlG','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9msu5lx0LovKfmsuq','q09suLvqveve','B3v0Chv0','l3j1BNrPBwu','reLsrunut1jzaa','mJy2odGWCgzwseTW','BwnWq29UzMLNsgfZAa','CMvXDwvZDfvZzxjjza','zMXVB3i','lMTLEq','BMXPBMS','DgvTCgXHDgvZuhvIBgLZAgLUz0rPCMvJDg9YEq','yM9VBgvHBG','y3jLzgvUDgLHBhm','CMvKDwnL','C2L6zq','uLvoveLnrq','y3jLyxrLzf9HDa','lMvUDG','BwvZC2fNzq','zMLUza','zhjHzNq','Aw5ZCgvJDfnVDxjJzq','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmGu0vuihn0ywDLpt8SC3rHDhvZpt8SDxbKyxrLzf9HDd0/ifDirvjfigLKpt8','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pW','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFChvIBgLZAf9QB2jZifDirvjfigLKpt8','DgvTCgXHDgvF','vKfmsurbveLorW','CMvZB2X2zq','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb2zxjZAw9UigLZihzHBgLKlG','DgvTCgXHDgvZvMvYC2LVBNneAxjLy3rVCNK','BM9KzuLK','DgvTCgXHDgvqDwjSAxnOAw5NrgLYzwn0B3j5','lM5WBxjJ','CMvXDwvZDgvKqNLvC2vYswq','ChvIBgLZAgvKqNLvC2vYswq','zgf0ywjHC2u','u0vmrunuihrLBxbSyxrLx2LKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZifDirvjfigLKpt8','y2f0y2G','AM9PBG','D29YA3nWywnLswq','u0vbteve','l3nIAw4','qvzbsuXbqKXf','AxntEw1IB2XPy0XPBMS','C3rHz2u','su5trvjuieLove8Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaOAwqSDgvTCgXHDgvFAwqSzhjHzNrFCMv2AxnPB24SC3rHz2uSC3rHDhvZlhzLCNnPB25FAwqSzxjYB3jFy29KzsXLCNjVCL9ZDw1Tyxj5laOGicaGicaGicaGCMvXDwvZDgvKx2j5x3vZzxjFAwqSzhjHzNqSy3jLyxrLzf9HDcX1CgrHDgvKx2f0kqOGicaGicaGicbwquXvrvmGkd8SpYW/lcDwquXjrefusu5hjYWNuvvfvuvejYXovuXmle5vteWStLvmtcW/ld8SpYW/kq','mtqZodi2BePtD0n1','A2LUza','C2XPy2u','Cgf0Aa','zgLNzxn0','Bw9Kzq','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9dsefor0ve','qKvhsu4Gsu1nrurjqvrf','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9nsvntsu5h','z2v0','CMvXDwvZDgvKx2j5x3vZzxjFAwq','BwfUAwzLC3qUANnVBG','ru5vtuvsqvrjtKC','uLvotKLorW','q09ovKvsu0fusu9ox0Hpu1rjtKDFu1rpuKfhrv9gvuXm','CNvUDgLTzq','BwnWx2nVBMzPz19OyxnO','zMLUywXSEq','C2HHmJu2','q09ovKvsu0fusu9ox1rftvbmqvrfx01duf9jtLzbteLe','rKLmrq','ndmYmJyYmgzMtwPjBW','DhjHBNnWB3j0','AwrFCNnH','zMLSzxm','BM93','q09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFrKfjteve','DMvYC2LVBKLK','zxjYB3jFy29Kzq','ChjLCgfYzq','BMv4DfzLCNnPB25oDw1Izxi','AgfZ','DxrMoa','DxbKyxrLzf9HDa','y29UDgvUDa','Aw5ZCgvJDfzLCNnPB24','ChvIBgLZAff1zxvLCW','AxngAwXL','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb2zxjZAw9UigLZigLUDMfSAwqGka','z2v0v29YA3nWywnL','lMDPDa','q09ntuLu','sfruua','DgfYz2v0s2LUza','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsbZB3vYy2uGAxmGDMfSAwqU','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGicbtrvqGC3rHz2u9pYXZDgf0Dxm9j0zbsuXfrcCSDMvYC2LVBL9Pzd1ovuXmlgvYCM9Yx2nVzgu9pYXLCNjVCL9ZDw1Tyxj5pt8SDxbKyxrLzf9HDd0/ifDirvjfigLKpt8','u1LnteLosW','AxntywzLsw50zwDLCG','BwnWswrZ','B3b0Aw9UCW','uK9mtejbq0S','BNvTyMvY','mtiZmtyYohbsCfLHAq','zgf0yq','A2v5CW','mtbruxvWvM0','lNbLBq','q09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFsK9cx05pvf9gt1vora','lNb5CgLYyW','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaGicaGicbxsevsrsb0zw1WBgf0zv9Pzd0/ieforcbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCkicaGicaGicaGicaGicaGt1jerviGqLKGy3jLyxrLzf9HDcXPza','BwLU','q09ovKvsu0fusu9ox1rftvbmqvrfx1zfuLnjt05Fq09suLvqveve','CMvNAxn0zxjwzxjZAw9U','yNnPEMu','CM9VDerPCMvJDg9YEq','uKvhsvnurvjfra','DgvTCgXHDgvwzxjZAw9UrgLYzwn0B3j5','zMLSzq','BwnWt3b0Aw9UCW','BgLUA1rHCMDLDa','BwfW','lMf3CW','AxngAw5PDgu','mZm5nda4suzIBhr0','CMf3','CgfYC2u','l2jPBG','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9jtLzbteLe','u0nbtK5jtKC','AxneAxjLy3rVCNK','zgvSzxrL','C2vSzwn0zwrny3btzxj2zxjZ','su5trvjuieLove8Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZcIaGicaGicaGicaGkgLKlhrLBxbSyxrLx2LKlhzLCNnPB25FBNvTyMvYlgrYywz0x3jLDMLZAw9Ulhn0yxr1CYXZDg9YywDLx2TLEsXTyw5PzMvZDcXJB250zw50x2HHC2GScIaGicaGicaGicaGig1HBMLMzxn0x2HHC2GSBwnWx2nVBMzPz19OyxnOlgzPBgvFy291BNqSDg90ywXFyNL0zxmSAg9ZDf9WB2XPy3LFDMvYC2LVBIWkicaGicaGicaGicaGChvIBgLZAgvKx2j5x3vZzxjFAwqSChvIBgLZAgvKx2f0lhjLzMvYzw5Jzv9JB3vUDcKkicaGicaGicaGicbwquXvrvmGkd8SpYW/ld8SpYW/ld8SpYW/ld8SpYW/ld8SpYW/ldaP','DgHLBG','zxjYB3jFC3vTBwfYEq','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGu0vuihn0yxr1CZ0Nu1vdq0vfrevejYXLCNjVCL9JB2rLpu5vteWSzxjYB3jFC3vTBwfYEt1ovuXmlhvWzgf0zwrFyxq9pWOGicaGicaGicbxsevsrsbPzd0/ieforcbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCGqu5eihzLCNnPB25FAwq9pW','ywrK','y29UzMLNDxjHDgLVBG','Dg9mB2nHBgvmB3DLCKnHC2u','DxbKyxrL','zMLSzunVDw50','AM9Iswq','yMf2ywLS','x193B3jRC3bHy2vxyxrJAfnLC3nPB25iyxnO','odKWmZCWEvzZAuj3','u0vmrunuienpquXfu0nfke1bwcH2zxjZAw9Ux251BwjLCIKSmcKGqvmGDMvYC2LVBL9UDw1IzxiGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGDgvTCgXHDgvFAwq9pW','DMvYC2LVBL9Pza','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pYbbtKqGDgvTCgXHDgvFAwq9pW','CMv2AxnPB24'];_0x14ad=function(){return _0x1c2737;};return _0x14ad();}function stringValue(_0x5db81f,_0x40fbfd){const _0xb9bd60=_0x31b997,_0x1d737c=_0x5db81f[_0x40fbfd];if(typeof _0x1d737c!==_0xb9bd60(0x20c))throw new Error(_0xb9bd60(0x218)+_0x40fbfd);return _0x1d737c;}function numberValue(_0xb8bb5a,_0x52ea05){const _0x531d34=_0x31b997,_0x3785dc=_0xb8bb5a[_0x52ea05];if(typeof _0x3785dc!==_0x531d34(0x281)&&typeof _0x3785dc!==_0x531d34(0x219))throw new Error(_0x531d34(0x218)+_0x52ea05);const _0x21ba48=Number(_0x3785dc);if(!Number[_0x531d34(0x27d)](_0x21ba48))throw new Error(_0x531d34(0x218)+_0x52ea05);return _0x21ba48;}function nodeRequestPayload(_0x119c70){const _0x1506a5=_0x31b997;if(!record(_0x119c70))return{'data':_0x119c70};const {__requestUserId:_0x5df656,..._0x1f551c}=_0x119c70;delete _0x1f551c[_0x1506a5(0x2ab)];if(_0x5df656===undefined)return{'data':_0x1f551c};if(typeof _0x5df656!==_0x1506a5(0x281)||!Number[_0x1506a5(0x27d)](_0x5df656)||_0x5df656<=0x107*-0x11+-0x2*0x705+0x1f81)throw new Error(_0x1506a5(0x1e1));return{'data':_0x1f551c,'requestUserId':_0x5df656};}function record(_0x4c9e60){const _0x30e8a5=_0x31b997;return typeof _0x4c9e60===_0x30e8a5(0x211)&&_0x4c9e60!==null&&!Array[_0x30e8a5(0x1f0)](_0x4c9e60);}
|
|
2
|
+
const _0x49bd4c=_0x305a;(function(_0x141c4d,_0x5f422f){const _0xca8713=_0x305a,_0x4086db=_0x141c4d();while(!![]){try{const _0x54f629=parseInt(_0xca8713(0x17d))/(0x10*0x37+0x1a4d+0x2c*-0xad)+parseInt(_0xca8713(0xbb))/(0x1*-0xacc+-0x1a6+0x1*0xc74)*(-parseInt(_0xca8713(0x1aa))/(0x70c+-0x1*-0xd42+-0x144b))+-parseInt(_0xca8713(0x119))/(0x1*0xc5+0x7*-0x445+-0x9b6*-0x3)*(-parseInt(_0xca8713(0xe4))/(0x5d3+0xb66+0x16f*-0xc))+parseInt(_0xca8713(0x14e))/(-0x1dfb+-0x1a*-0x69+0x1*0x1357)+parseInt(_0xca8713(0x155))/(-0x6*0x290+0x1a*0x13f+-0x1*0x10ff)+-parseInt(_0xca8713(0xde))/(-0x1339+-0x8f5+-0x1c36*-0x1)+-parseInt(_0xca8713(0xf8))/(0x6f*-0x2+-0x1*0x1465+0x154c);if(_0x54f629===_0x5f422f)break;else _0x4086db['push'](_0x4086db['shift']());}catch(_0x2cdbab){_0x4086db['push'](_0x4086db['shift']());}}}(_0x3489,-0x40225+-0x81dcd+-0xd021*-0x19));import{createHash,randomUUID}from'node:crypto';import{chmod,copyFile,lstat,mkdir,readFile,readlink,readdir,realpath,rename,rm,statfs,symlink,writeFile}from'node:fs/promises';import{dirname,isAbsolute,join,relative,resolve,sep}from'node:path';import{conversationTemplateDraftSchema,conversationTemplatePublishJobSchema,conversationTemplatePublishRequestSchema,conversationTemplatePublishResultSchema,conversationTemplatePublishStatusInputSchema,conversationTemplateSourceInspectInputSchema,conversationTemplateSourceInspectionSchema,conversationTemplateVersionSchema}from'@myagentroam/protocol';import{safeErrorCode}from'../util/safe-error.js';const HOST_POLICY_VERSION=-0x19c5*-0x1+0x1d8*0x5+-0x22fc,FORCED_EXCLUDED_NAMES=new Set([_0x49bd4c(0x156),_0x49bd4c(0x113),_0x49bd4c(0x167),_0x49bd4c(0x10a),_0x49bd4c(0x10e),_0x49bd4c(0x1b1),_0x49bd4c(0x125),_0x49bd4c(0xcd)]),ROOT_EXCLUDED_NAMES=new Set([_0x49bd4c(0x18a),_0x49bd4c(0xcb)]),RUNTIME_LINK_ROOTS=[_0x49bd4c(0x12f),_0x49bd4c(0xc6),_0x49bd4c(0x1ad),_0x49bd4c(0xb3),_0x49bd4c(0xfc)],RESERVED_SANDBOX_ROOTS=[_0x49bd4c(0xd0),_0x49bd4c(0x172),_0x49bd4c(0x115),_0x49bd4c(0x12f),_0x49bd4c(0xc6),_0x49bd4c(0x1ad),_0x49bd4c(0xb3),_0x49bd4c(0xfc),_0x49bd4c(0x1a2),_0x49bd4c(0x18d),_0x49bd4c(0x1b7)];export class ConversationTemplateNodeService{[_0x49bd4c(0x169)];[_0x49bd4c(0x175)];['id'];[_0x49bd4c(0x138)]=new Map();constructor(_0x1ebc5d){const _0x326eae=_0x49bd4c;this[_0x326eae(0x169)]=_0x1ebc5d,this[_0x326eae(0x175)]=_0x1ebc5d[_0x326eae(0x175)]??Date[_0x326eae(0x175)],this['id']=_0x1ebc5d['id']??randomUUID;}[_0x49bd4c(0x12d)](){const _0x663617=_0x49bd4c;return{'conversation.template.source.inspect':_0x3eeaca=>this[_0x663617(0x143)](_0x3eeaca),'conversation.template.publish':_0x2f4cbd=>this[_0x663617(0x195)](_0x2f4cbd),'conversation.template.publish.status':_0x3f93f7=>this[_0x663617(0x13d)](_0x3f93f7),'conversation.template.version.inspect':_0x2f024b=>this[_0x663617(0x1af)](_0x2f024b)};}async[_0x49bd4c(0x126)](){const _0x427a88=_0x49bd4c;for(const _0x3a3eb1 of await readdir(this[_0x427a88(0x169)][_0x427a88(0x114)][_0x427a88(0x153)],{'withFileTypes':!![]})){await writableRemove(join(this[_0x427a88(0x169)][_0x427a88(0x114)][_0x427a88(0x153)],_0x3a3eb1[_0x427a88(0xce)]));}const _0x4118a8=new Set(this[_0x427a88(0x169)][_0x427a88(0xc3)][_0x427a88(0x19d)][_0x427a88(0x12a)](_0x427a88(0x166))[_0x427a88(0x17a)]()[_0x427a88(0xfd)](_0x2236cb=>stringValue(_0x2236cb,_0x427a88(0xba))));for(const _0x30ac7b of await readdir(this[_0x427a88(0x169)][_0x427a88(0x114)][_0x427a88(0x1a8)],{'withFileTypes':!![]})){if(_0x4118a8[_0x427a88(0x1a6)](_0x30ac7b[_0x427a88(0xce)]))continue;await writableRemove(join(this[_0x427a88(0x169)][_0x427a88(0x114)][_0x427a88(0x1a8)],_0x30ac7b[_0x427a88(0xce)]));}await this[_0x427a88(0xb0)](),this[_0x427a88(0x169)][_0x427a88(0xc3)][_0x427a88(0x19d)][_0x427a88(0x12a)](_0x427a88(0x176))[_0x427a88(0x104)](_0x427a88(0xae),this[_0x427a88(0x175)]());}async[_0x49bd4c(0x143)](_0x39526a){const _0x3f4740=_0x49bd4c,_0x544e57=conversationTemplateSourceInspectInputSchema[_0x3f4740(0x17c)](nodeRequestPayload(_0x39526a)[_0x3f4740(0xe0)]),_0x17cfed=this[_0x3f4740(0x142)](_0x544e57[_0x3f4740(0x1a5)][_0x3f4740(0x108)]);try{return await this[_0x3f4740(0x183)](_0x544e57[_0x3f4740(0x1a5)]),this[_0x3f4740(0x107)](_0x544e57[_0x3f4740(0x1a5)]),conversationTemplateSourceInspectionSchema[_0x3f4740(0x17c)]({'valid':!![],'code':null,'message':_0x3f4740(0x179),'checkedAt':this[_0x3f4740(0x175)](),'mcpServers':_0x17cfed});}catch(_0x13a8b8){const _0x596d64=safeErrorCode(_0x13a8b8,_0x3f4740(0x15f));return conversationTemplateSourceInspectionSchema[_0x3f4740(0x17c)]({'valid':![],'code':_0x596d64,'message':_0x3f4740(0xbc)+_0x596d64+').','checkedAt':this[_0x3f4740(0x175)](),'mcpServers':_0x17cfed});}}async[_0x49bd4c(0x195)](_0x528393){const _0x38a801=_0x49bd4c,_0x1b018d=nodeRequestPayload(_0x528393),_0x496a8f=conversationTemplatePublishRequestSchema[_0x38a801(0x17c)](_0x1b018d[_0x38a801(0xe0)]);if(_0x1b018d[_0x38a801(0xe5)]!==undefined&&_0x1b018d[_0x38a801(0xe5)]!==_0x496a8f[_0x38a801(0x182)])throw new Error(_0x38a801(0xca));this[_0x38a801(0x1ae)](_0x496a8f[_0x38a801(0x1a5)]);const _0x45a6f6=this[_0x38a801(0xb8)](_0x496a8f[_0x38a801(0x117)]);if(_0x45a6f6!==undefined){if(numberValue(_0x45a6f6,_0x38a801(0x13e))!==_0x496a8f[_0x38a801(0x182)])throw new Error(_0x38a801(0xca));if(stringValue(_0x45a6f6,_0x38a801(0x136))!==_0x496a8f[_0x38a801(0x112)]||numberValue(_0x45a6f6,_0x38a801(0xb1))!==_0x496a8f[_0x38a801(0x1a5)][_0x38a801(0xe9)]||stringValue(_0x45a6f6,_0x38a801(0x1a5))!==JSON[_0x38a801(0x111)](_0x496a8f[_0x38a801(0x1a5)]))throw new Error(_0x38a801(0x141));return this[_0x38a801(0x16e)](_0x45a6f6);}const _0x2ff8e5=this[_0x38a801(0x175)]();return this[_0x38a801(0x169)][_0x38a801(0xc3)][_0x38a801(0x19d)][_0x38a801(0x12a)](_0x38a801(0x157))[_0x38a801(0x104)](_0x496a8f[_0x38a801(0x117)],_0x496a8f[_0x38a801(0x112)],_0x496a8f[_0x38a801(0x1a5)][_0x38a801(0xe9)],_0x496a8f[_0x38a801(0x182)],JSON[_0x38a801(0x111)](_0x496a8f[_0x38a801(0x1a5)]),_0x2ff8e5,_0x2ff8e5),this[_0x38a801(0x1b2)](_0x496a8f),this[_0x38a801(0x16e)](this[_0x38a801(0xda)](_0x496a8f[_0x38a801(0x117)]));}[_0x49bd4c(0x1b2)](_0x1d239f){queueMicrotask(()=>{const _0x2cb4d7=_0x305a,_0x4d799d=this[_0x2cb4d7(0x138)][_0x2cb4d7(0xf7)](_0x1d239f[_0x2cb4d7(0x112)])??Promise[_0x2cb4d7(0x1a3)](),_0x332227=_0x4d799d[_0x2cb4d7(0x10b)](()=>undefined)[_0x2cb4d7(0xed)](()=>this[_0x2cb4d7(0x15a)](_0x1d239f))[_0x2cb4d7(0x131)](()=>{const _0x56e145=_0x2cb4d7;if(this[_0x56e145(0x138)][_0x56e145(0xf7)](_0x1d239f[_0x56e145(0x112)])===_0x332227)this[_0x56e145(0x138)][_0x56e145(0xd1)](_0x1d239f[_0x56e145(0x112)]);});this[_0x2cb4d7(0x138)][_0x2cb4d7(0xd3)](_0x1d239f[_0x2cb4d7(0x112)],_0x332227);});}[_0x49bd4c(0x13d)](_0x47452a){const _0x4c9b18=_0x49bd4c,_0x4d896b=conversationTemplatePublishStatusInputSchema[_0x4c9b18(0x17c)](nodeRequestPayload(_0x47452a)[_0x4c9b18(0xe0)]),_0x418798=this[_0x4c9b18(0xda)](_0x4d896b[_0x4c9b18(0x117)]);if(stringValue(_0x418798,_0x4c9b18(0x136))!==_0x4d896b[_0x4c9b18(0x112)])throw new Error(_0x4c9b18(0xe2));return this[_0x4c9b18(0x16e)](_0x418798);}async[_0x49bd4c(0x1af)](_0x58ea64){const _0x58094a=_0x49bd4c;_0x58ea64=nodeRequestPayload(_0x58ea64)[_0x58094a(0xe0)];if(!record(_0x58ea64)||typeof _0x58ea64[_0x58094a(0x112)]!==_0x58094a(0xec)||typeof _0x58ea64[_0x58094a(0x16b)]!==_0x58094a(0xec)||Object[_0x58094a(0x1b5)](_0x58ea64)[_0x58094a(0xee)]!==0x2*-0x6c8+-0xd2c+-0x6*-0x475)throw new Error(_0x58094a(0x139));const _0x2b6139=this[_0x58094a(0x169)][_0x58094a(0xc3)][_0x58094a(0x19d)][_0x58094a(0x12a)](_0x58094a(0x10d))[_0x58094a(0xf7)](_0x58ea64[_0x58094a(0x16b)],_0x58ea64[_0x58094a(0x112)]);if(_0x2b6139===undefined)throw new Error(_0x58094a(0xf9));const _0x554ce8=templateVersion(_0x2b6139);try{await this[_0x58094a(0x12e)](_0x2b6139);if(_0x554ce8[_0x58094a(0x10c)]===_0x58094a(0x17b))throw new Error(_0x58094a(0x188));return{'valid':!![],'code':null,'message':_0x58094a(0x16a),'checkedAt':this[_0x58094a(0x175)](),'version':_0x554ce8};}catch(_0x12f01b){const _0x2bc27b=safeErrorCode(_0x12f01b,_0x58094a(0x188));return this[_0x58094a(0x169)][_0x58094a(0xc3)][_0x58094a(0x19d)][_0x58094a(0x12a)](_0x58094a(0xdf))[_0x58094a(0x104)](_0x554ce8['id']),{'valid':![],'code':_0x2bc27b,'message':_0x58094a(0x187)+_0x2bc27b+').','checkedAt':this[_0x58094a(0x175)](),'version':{..._0x554ce8,'status':_0x58094a(0x17b)}};}}async[_0x49bd4c(0x15a)](_0x9867a){const _0x4830d6=_0x49bd4c,_0xa94b60=_0x4830d6(0xea)+createHash(_0x4830d6(0x1a0))[_0x4830d6(0x198)](_0x9867a[_0x4830d6(0x117)])[_0x4830d6(0x152)](_0x4830d6(0xdd)),_0x2d4bba=this[_0x4830d6(0x169)][_0x4830d6(0x114)][_0x4830d6(0x137)](_0xa94b60);let _0x37e671,_0x5a9da1=_0x4830d6(0x13c);try{await this[_0x4830d6(0xb0)](_0x9867a[_0x4830d6(0x112)]),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c));const _0x48fe14=await this[_0x4830d6(0x183)](_0x9867a[_0x4830d6(0x1a5)]),_0xa0071=_0x48fe14[_0x4830d6(0x132)],_0x2b21ff=this[_0x4830d6(0x107)](_0x9867a[_0x4830d6(0x1a5)]),_0x4ebc5b=hashText(JSON[_0x4830d6(0x111)](_0x2b21ff));_0x5a9da1=_0x4830d6(0x12c),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c)),await rm(_0x2d4bba,{'recursive':!![],'force':!![]});const _0x4c36ed=join(_0x2d4bba,_0x4830d6(0x11e));await mkdir(_0x4c36ed,{'recursive':!![],'mode':0x1c0});for(const _0xf6f691 of _0x48fe14[_0x4830d6(0xaf)])await mkdir(join(_0x4c36ed,..._0xf6f691[_0x4830d6(0x178)]('/')),{'recursive':!![],'mode':0x1c0});_0x5a9da1=_0x4830d6(0x11f),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c));for(const _0x3cb504 of _0xa0071){const _0x4eb3f4=join(_0x4c36ed,..._0x3cb504[_0x4830d6(0xf2)][_0x4830d6(0x178)]('/'));await mkdir(dirname(_0x4eb3f4),{'recursive':!![],'mode':0x1c0});if(_0x3cb504[_0x4830d6(0x1b6)]===_0x4830d6(0xbe)){const _0x10a69c=await lstat(_0x3cb504[_0x4830d6(0xdc)]);if(!_0x10a69c[_0x4830d6(0x171)]()||await readlink(_0x3cb504[_0x4830d6(0xdc)])!==_0x3cb504[_0x4830d6(0x144)])throw new Error(_0x4830d6(0x15c));await symlink(_0x3cb504[_0x4830d6(0x144)],_0x4eb3f4);const _0x3d659d=await readlink(_0x4eb3f4);if(_0x3d659d!==_0x3cb504[_0x4830d6(0x144)])throw new Error(_0x4830d6(0x15c));continue;}await copyFile(_0x3cb504[_0x4830d6(0xdc)],_0x4eb3f4);const _0xe842e6=await lstat(_0x4eb3f4);if(!_0xe842e6[_0x4830d6(0x1ab)]()||_0xe842e6[_0x4830d6(0x171)]()||_0xe842e6[_0x4830d6(0x1ac)]!==-0x1*-0x59+-0x13*0x109+0x1353)throw new Error(_0x4830d6(0x140));await chmod(_0x4eb3f4,_0x3cb504[_0x4830d6(0x13f)]?-0x1239+-0xd92+0x2138:-0x268e+-0x1*0xa5b+0x320d);}await Promise[_0x4830d6(0x17a)]([_0x4830d6(0x14d),_0x4830d6(0xc5)][_0x4830d6(0xfd)](_0x3be9b1=>mkdir(join(_0x4c36ed,_0x3be9b1),{'recursive':!![],'mode':0x1c0}))),await sealDirectories(_0x4c36ed),_0x5a9da1=_0x4830d6(0x186),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c)),await verifyCopiedSnapshot(_0x4c36ed,_0x48fe14[_0x4830d6(0xaf)],_0xa0071,!![]);const _0x4e97ac=this[_0x4830d6(0xf4)](_0x9867a[_0x4830d6(0x112)]),_0x3e1834=this['id'](),_0x168417=this[_0x4830d6(0x175)](),_0x5a9fb6=snapshotContentHash(_0x48fe14[_0x4830d6(0xaf)],_0xa0071),_0x5036ae={'schemaVersion':0x2,'templateId':_0x9867a[_0x4830d6(0x112)],'versionId':_0x3e1834,'versionNumber':_0x4e97ac,'draftRevision':_0x9867a[_0x4830d6(0x1a5)][_0x4830d6(0xe9)],'hostPolicyVersion':HOST_POLICY_VERSION,'publishedByUserId':_0x9867a[_0x4830d6(0x182)],'publishedAt':_0x168417,'sourceWorkspacePath':_0x48fe14[_0x4830d6(0x17f)],'draft':_0x9867a[_0x4830d6(0x1a5)],'directories':_0x48fe14[_0x4830d6(0xaf)],'entries':_0xa0071[_0x4830d6(0xfd)](_0x4720c8=>_0x4720c8[_0x4830d6(0x1b6)]===_0x4830d6(0x1a9)?{'kind':_0x4720c8[_0x4830d6(0x1b6)],'relativePath':_0x4720c8[_0x4830d6(0xf2)],'size':_0x4720c8[_0x4830d6(0x168)],'executable':_0x4720c8[_0x4830d6(0x13f)],'sha256':_0x4720c8[_0x4830d6(0x1a0)]}:{'kind':_0x4720c8[_0x4830d6(0x1b6)],'relativePath':_0x4720c8[_0x4830d6(0xf2)],'size':_0x4720c8[_0x4830d6(0x168)],'linkTarget':_0x4720c8[_0x4830d6(0x144)],'targetKind':_0x4720c8[_0x4830d6(0x1b3)],'resolvedTarget':_0x4720c8[_0x4830d6(0xc0)]}),'contentHash':_0x5a9fb6,'mcpServers':_0x2b21ff,'mcpConfigHash':_0x4ebc5b};_0x5a9da1=_0x4830d6(0x18b),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c));const _0xdff2c4=JSON[_0x4830d6(0x111)](_0x5036ae),_0x2c5fcd=hashText(_0xdff2c4);await writeFile(join(_0x2d4bba,_0x4830d6(0x127)),_0xdff2c4+'\x0a',{'mode':0x180}),await chmod(join(_0x2d4bba,_0x4830d6(0x127)),-0x337*-0x1+-0x1*0x1b9b+0x1988),_0x37e671=this[_0x4830d6(0x169)][_0x4830d6(0x114)][_0x4830d6(0x158)](_0xa94b60),await rename(_0x2d4bba,_0x37e671),await chmod(_0x37e671,0x5*-0x13d+0x17*0xd5+-0x3*0x3d7),_0x5a9da1=_0x4830d6(0xc9),this[_0x4830d6(0x147)](_0x9867a[_0x4830d6(0x117)],_0x5a9da1,_0x4830d6(0x11c));const _0x5e7875=conversationTemplateVersionSchema[_0x4830d6(0x17c)]({'id':_0x3e1834,'templateId':_0x9867a[_0x4830d6(0x112)],'version':_0x4e97ac,'status':_0x4830d6(0xb5),'contentHash':_0x5a9fb6,'manifestHash':_0x2c5fcd,'mcpConfigHash':_0x4ebc5b,'fileCount':_0xa0071[_0x4830d6(0xee)],'totalBytes':_0xa0071[_0x4830d6(0x14b)]((_0x51cf9a,_0x4c4422)=>_0x51cf9a+_0x4c4422[_0x4830d6(0x168)],-0x131c+0xfaf+0x36d),'hostPolicyVersion':HOST_POLICY_VERSION,'publishedByUserId':_0x9867a[_0x4830d6(0x182)],'publishedAt':_0x168417});this[_0x4830d6(0xfa)](_0x9867a[_0x4830d6(0x117)],_0xa94b60,_0xdff2c4,_0x5e7875),_0x5a9da1=_0x4830d6(0x1a1),await this[_0x4830d6(0x11d)](_0x9867a[_0x4830d6(0x117)]);}catch(_0x58ad99){if(_0x5a9da1===_0x4830d6(0x1a1))return;await writableRemove(_0x2d4bba);if(_0x37e671!==undefined)await writableRemove(_0x37e671);const _0x35430f=safeErrorCode(_0x58ad99,_0x4830d6(0xf1));this[_0x4830d6(0x169)][_0x4830d6(0xc3)][_0x4830d6(0x19d)][_0x4830d6(0x12a)](_0x4830d6(0x11b))[_0x4830d6(0x104)](_0x5a9da1,_0x35430f,_0x4830d6(0x10f)+_0x35430f+').',this[_0x4830d6(0x175)](),_0x9867a[_0x4830d6(0x117)]);}}async[_0x49bd4c(0x183)](_0x1730c3){const _0x49c2a5=_0x49bd4c;this[_0x49c2a5(0x1ae)](_0x1730c3);const _0x255629=this[_0x49c2a5(0x169)][_0x49c2a5(0xc3)][_0x49c2a5(0x1a7)](_0x1730c3[_0x49c2a5(0x108)]);if(_0x255629===undefined)throw new Error(_0x49c2a5(0xbd));const _0x42277e=await realpath(_0x255629[_0x49c2a5(0x19e)]),_0x3a12fc=this[_0x49c2a5(0x169)][_0x49c2a5(0x17f)]?.(_0x42277e)??_0x42277e;validateSourceWorkspacePath(_0x3a12fc);const _0xb6c13f=new Set(),_0xab2bf2=new Map();let _0x2eeda7=-0x2626*-0x1+-0x2291+0x83*-0x7;const _0x3d9a8f=await hostedFilesystemAvailableBytes(this[_0x49c2a5(0x169)][_0x49c2a5(0x114)][_0x49c2a5(0x122)]);return await walkWorkspace(_0x42277e,'',{'directory':_0x5928ce=>{const _0x54f093=_0x49c2a5;_0xb6c13f[_0x54f093(0xe7)](_0x5928ce);},'file':async(_0x4b4169,_0x4e07b5,_0x39ab80)=>{const _0x52268e=_0x49c2a5;if(_0xab2bf2[_0x52268e(0x1a6)](_0x4e07b5))return;const _0x169760=Number(_0x39ab80[_0x52268e(0x168)]);_0x2eeda7+=_0x169760;if(!Number[_0x52268e(0x17e)](_0x2eeda7)||_0x2eeda7>_0x3d9a8f)throw new Error(_0x52268e(0x133));_0xab2bf2[_0x52268e(0xd3)](_0x4e07b5,{'kind':_0x52268e(0x1a9),'relativePath':_0x4e07b5,'sourcePath':_0x4b4169,'size':_0x169760,'executable':(Number(_0x39ab80[_0x52268e(0x134)])&0x1cd2+0x1cf6+-0x29*0x167)!==0x195*0x1+-0x1c35+0x20*0xd5,'sha256':hashBuffer(await readFile(_0x4b4169))});},'symlink':async(_0x64b8ff,_0x4cbbb6,_0x4af68e)=>{const _0x4768b9=_0x49c2a5;if(_0xab2bf2[_0x4768b9(0x1a6)](_0x4cbbb6))return;const _0x4d0858=await publishedSymlink(_0x42277e,_0x64b8ff,_0x4cbbb6,_0x4af68e);_0x2eeda7+=_0x4d0858[_0x4768b9(0x168)];if(!Number[_0x4768b9(0x17e)](_0x2eeda7)||_0x2eeda7>_0x3d9a8f)throw new Error(_0x4768b9(0x133));_0xab2bf2[_0x4768b9(0xd3)](_0x4cbbb6,_0x4d0858);}}),{'sourceWorkspacePath':_0x3a12fc,'directories':[..._0xb6c13f][_0x49c2a5(0xd2)]((_0x2fbb70,_0x2932a1)=>_0x2fbb70[_0x49c2a5(0x149)](_0x2932a1,_0x49c2a5(0xbf))),'entries':[..._0xab2bf2[_0x49c2a5(0x106)]()][_0x49c2a5(0xd2)]((_0x39c6b3,_0x4145f5)=>_0x39c6b3[_0x49c2a5(0xf2)][_0x49c2a5(0x149)](_0x4145f5[_0x49c2a5(0xf2)],_0x49c2a5(0xbf)))};}[_0x49bd4c(0x142)](_0xdafda){const _0x52b599=_0x49bd4c;return this[_0x52b599(0x169)][_0x52b599(0xc3)][_0x52b599(0xe3)](_0xdafda)[_0x52b599(0xfd)](_0x5adf76=>({'id':_0x5adf76[_0x52b599(0x163)],'serverName':_0x5adf76[_0x52b599(0xef)],'displayName':_0x5adf76[_0x52b599(0x100)],'transport':_0x5adf76[_0x52b599(0x121)][_0x52b599(0x124)],'origin':_0x5adf76[_0x52b599(0x1b3)]}));}[_0x49bd4c(0x107)](_0x4c707d){const _0xed4346=_0x49bd4c,_0x36c57c=new Map(this[_0xed4346(0x169)][_0xed4346(0xc3)][_0xed4346(0xe3)](_0x4c707d[_0xed4346(0x108)])[_0xed4346(0xfd)](_0x3f87f2=>[_0x3f87f2[_0xed4346(0x163)],_0x3f87f2]));return _0x4c707d[_0xed4346(0xb4)][_0xed4346(0xfd)](_0x329ee6=>{const _0x354fc7=_0xed4346,_0x46cb53=_0x36c57c[_0x354fc7(0xf7)](_0x329ee6);if(_0x46cb53===undefined||_0x46cb53[_0x354fc7(0x121)][_0x354fc7(0x124)]===_0x354fc7(0xd6)&&_0x4c707d[_0x354fc7(0x146)]!==_0x354fc7(0x102))throw new Error(_0x354fc7(0xf6));return{'id':_0x46cb53[_0x354fc7(0x163)],'serverName':_0x46cb53[_0x354fc7(0xef)],'displayName':_0x46cb53[_0x354fc7(0x100)],'version':_0x46cb53[_0x354fc7(0x103)],'origin':_0x46cb53[_0x354fc7(0x1b3)],'transport':_0x46cb53[_0x354fc7(0x121)][_0x354fc7(0x124)],'runtime':_0x46cb53[_0x354fc7(0x121)],'configuration':_0x46cb53[_0x354fc7(0x190)]};});}[_0x49bd4c(0x1ae)](_0x15e46a){const _0x574903=_0x49bd4c,_0x4d25b7=conversationTemplateDraftSchema[_0x574903(0x17c)](_0x15e46a);if(_0x4d25b7[_0x574903(0x170)]!==this[_0x574903(0x169)][_0x574903(0x170)]())throw new Error(_0x574903(0x15f));}[_0x49bd4c(0xf4)](_0x5dcfa){const _0x54f2cd=_0x49bd4c,_0x16fa00=this[_0x54f2cd(0x169)][_0x54f2cd(0xc3)][_0x54f2cd(0x19d)][_0x54f2cd(0x12a)](_0x54f2cd(0xfb))[_0x54f2cd(0xf7)](_0x5dcfa);return numberValue(_0x16fa00,_0x54f2cd(0x148))+(0x2*0x237+0xe8e+-0x12fb);}[_0x49bd4c(0xfa)](_0x558d6a,_0x5df7b7,_0x3ef5a7,_0x324f71){const _0x10b660=_0x49bd4c,_0x92f9a4=this[_0x10b660(0x169)][_0x10b660(0xc3)][_0x10b660(0x19d)];_0x92f9a4[_0x10b660(0x189)](_0x10b660(0x19c));try{const _0x130f01=this[_0x10b660(0xda)](_0x558d6a);if(stringValue(_0x130f01,_0x10b660(0x136))!==_0x324f71[_0x10b660(0x112)]||stringValue(_0x130f01,_0x10b660(0xfe))!==_0x10b660(0xc9)||stringValue(_0x130f01,_0x10b660(0x10c))!==_0x10b660(0x11c)||_0x130f01[_0x10b660(0x109)]!==null||numberValue(_0x130f01,_0x10b660(0x13e))!==_0x324f71[_0x10b660(0x110)])throw new Error(_0x10b660(0x188));const _0x83a7a5=_0x92f9a4[_0x10b660(0x12a)](_0x10b660(0x181))[_0x10b660(0x104)](_0x324f71['id'],_0x324f71[_0x10b660(0x112)],_0x324f71[_0x10b660(0x103)],numberValue(_0x130f01,_0x10b660(0xb1)),_0x324f71[_0x10b660(0x10c)],_0x5df7b7,_0x3ef5a7,_0x324f71[_0x10b660(0x160)],_0x324f71[_0x10b660(0x130)],_0x324f71[_0x10b660(0xe8)],_0x324f71[_0x10b660(0x19b)],_0x324f71[_0x10b660(0xdb)],_0x324f71[_0x10b660(0x13a)],_0x324f71[_0x10b660(0x110)],_0x324f71[_0x10b660(0x180)]);if(Number(_0x83a7a5[_0x10b660(0xc2)])!==0x3*-0x661+0x112*0x9+0x982)throw new Error(_0x10b660(0x188));const _0x7d17d5=_0x92f9a4[_0x10b660(0x12a)](_0x10b660(0xeb))[_0x10b660(0x104)](_0x324f71['id'],_0x324f71[_0x10b660(0x180)],_0x558d6a,_0x324f71[_0x10b660(0x112)],numberValue(_0x130f01,_0x10b660(0xb1)),_0x324f71[_0x10b660(0x110)]);if(Number(_0x7d17d5[_0x10b660(0xc2)])!==-0x796*-0x4+-0x2100+-0x1*-0x2a9)throw new Error(_0x10b660(0x188));_0x92f9a4[_0x10b660(0x189)](_0x10b660(0xd5));}catch(_0x26d4c1){_0x92f9a4[_0x10b660(0x189)](_0x10b660(0x19a));throw _0x26d4c1;}}async[_0x49bd4c(0x11d)](_0x4258d8){const _0x1094cf=_0x49bd4c,_0x5c0e02=this[_0x1094cf(0xda)](_0x4258d8);if(stringValue(_0x5c0e02,_0x1094cf(0xfe))!==_0x1094cf(0x1a1)||stringValue(_0x5c0e02,_0x1094cf(0x10c))!==_0x1094cf(0x11c)||_0x5c0e02[_0x1094cf(0x109)]===null)throw new Error(_0x1094cf(0x188));const _0x2f98a9=stringValue(_0x5c0e02,_0x1094cf(0x109)),_0x5de2d2=this[_0x1094cf(0x169)][_0x1094cf(0xc3)][_0x1094cf(0x19d)][_0x1094cf(0x12a)](_0x1094cf(0xc7))[_0x1094cf(0xf7)](_0x2f98a9);if(_0x5de2d2===undefined||stringValue(_0x5de2d2,_0x1094cf(0x136))!==stringValue(_0x5c0e02,_0x1094cf(0x136)))throw new Error(_0x1094cf(0x188));const _0x34eb1e=this[_0x1094cf(0x169)][_0x1094cf(0xc3)][_0x1094cf(0x19d)][_0x1094cf(0x12a)](_0x1094cf(0xd8))[_0x1094cf(0x104)](this[_0x1094cf(0x175)](),_0x4258d8,_0x2f98a9);if(Number(_0x34eb1e[_0x1094cf(0xc2)])!==0x1cd0+-0xb52+-0xb*0x197)throw new Error(_0x1094cf(0x188));}async[_0x49bd4c(0xb0)](_0x4babd2){const _0x20ffcf=_0x49bd4c,_0x472fa7=_0x4babd2===undefined?this[_0x20ffcf(0x169)][_0x20ffcf(0xc3)][_0x20ffcf(0x19d)][_0x20ffcf(0x12a)](_0x20ffcf(0xd4))[_0x20ffcf(0x17a)]():this[_0x20ffcf(0x169)][_0x20ffcf(0xc3)][_0x20ffcf(0x19d)][_0x20ffcf(0x12a)](_0x20ffcf(0x116))[_0x20ffcf(0x17a)](_0x4babd2);for(const _0x104faf of _0x472fa7)await this[_0x20ffcf(0x11d)](stringValue(_0x104faf,'id'));}[_0x49bd4c(0x147)](_0xc8f695,_0x399365,_0x1e4d41){const _0x1a8dfd=_0x49bd4c;this[_0x1a8dfd(0x169)][_0x1a8dfd(0xc3)][_0x1a8dfd(0x19d)][_0x1a8dfd(0x12a)](_0x1a8dfd(0x199))[_0x1a8dfd(0x104)](_0x399365,_0x1e4d41,this[_0x1a8dfd(0x175)](),_0xc8f695);}[_0x49bd4c(0x16e)](_0x2ff3fc){const _0x22cba8=_0x49bd4c,_0x1d0cc2=publishJob(_0x2ff3fc),_0x30e531=_0x1d0cc2[_0x22cba8(0x10c)]!==_0x22cba8(0xe6)||_0x1d0cc2[_0x22cba8(0x16b)]===undefined?undefined:this[_0x22cba8(0x169)][_0x22cba8(0xc3)][_0x22cba8(0x19d)][_0x22cba8(0x12a)](_0x22cba8(0x154))[_0x22cba8(0xf7)](_0x1d0cc2[_0x22cba8(0x16b)]);return conversationTemplatePublishResultSchema[_0x22cba8(0x17c)]({'job':_0x1d0cc2,..._0x30e531===undefined?{}:{'version':templateVersion(_0x30e531)}});}[_0x49bd4c(0xb8)](_0x3fd486){const _0x46ee25=_0x49bd4c;return this[_0x46ee25(0x169)][_0x46ee25(0xc3)][_0x46ee25(0x19d)][_0x46ee25(0x12a)](_0x46ee25(0x15b))[_0x46ee25(0xf7)](_0x3fd486);}[_0x49bd4c(0xda)](_0x11e615){const _0x4ad644=_0x49bd4c,_0x1da776=this[_0x4ad644(0xb8)](_0x11e615);if(_0x1da776===undefined)throw new Error(_0x4ad644(0xe2));return _0x1da776;}async[_0x49bd4c(0x12e)](_0x39ddc4){const _0x310411=_0x49bd4c,_0x180d80=stringValue(_0x39ddc4,_0x310411(0xba)),_0x49cfde=this[_0x310411(0x169)][_0x310411(0x114)][_0x310411(0x158)](_0x180d80),_0x5f56f9=await readFile(join(_0x49cfde,_0x310411(0x127)),_0x310411(0x174)),_0x1190d0=_0x5f56f9[_0x310411(0x101)]('\x0a')?_0x5f56f9[_0x310411(0x14c)](0x4fd+-0x12ef+0xdf2,-(-0xdcd+-0x22d*-0x5+-0x7*-0x6b)):_0x5f56f9;if(hashText(_0x1190d0)!==stringValue(_0x39ddc4,_0x310411(0x191)))throw new Error(_0x310411(0x188));const _0x1d1448=templateVersionManifest(JSON[_0x310411(0x17c)](_0x1190d0));if(_0x1d1448[_0x310411(0xe8)]!==stringValue(_0x39ddc4,_0x310411(0xf0))||hashText(JSON[_0x310411(0x111)](_0x1d1448[_0x310411(0x14f)]))!==_0x1d1448[_0x310411(0xe8)]||_0x1d1448[_0x310411(0x160)]!==stringValue(_0x39ddc4,_0x310411(0x185))||_0x1d1448[_0x310411(0x132)][_0x310411(0xee)]!==numberValue(_0x39ddc4,_0x310411(0x16f))||_0x1d1448[_0x310411(0x132)][_0x310411(0x14b)]((_0x3bcf5f,_0x4cc90e)=>_0x3bcf5f+_0x4cc90e[_0x310411(0x168)],0x19b*0x12+-0x11bc*0x1+-0xb2a)!==numberValue(_0x39ddc4,_0x310411(0xcf))||snapshotContentHash(_0x1d1448[_0x310411(0xaf)],_0x1d1448[_0x310411(0x132)],_0x1d1448[_0x310411(0x192)])!==_0x1d1448[_0x310411(0x160)])throw new Error(_0x310411(0x188));const _0x4fcb43=new Map(_0x1d1448[_0x310411(0x132)][_0x310411(0xfd)](_0x424517=>[_0x424517[_0x310411(0xf2)],_0x424517])),_0x5ec6cf=new Set([..._0x1d1448[_0x310411(0xaf)],_0x310411(0x14d),_0x310411(0xc5)]),_0x1684c8=new Set(),_0xf8493e=await listSnapshotEntries(join(_0x49cfde,_0x310411(0x11e)),_0x5ec6cf,_0x1684c8,!![],_0x310411(0x188));if(_0xf8493e[_0x310411(0xee)]!==_0x4fcb43[_0x310411(0x168)]||_0x1684c8[_0x310411(0x168)]!==_0x5ec6cf[_0x310411(0x168)])throw new Error(_0x310411(0x188));for(const _0x2b234e of _0xf8493e){const _0x390e00=_0x4fcb43[_0x310411(0xf7)](_0x2b234e[_0x310411(0xf2)]);if(_0x390e00===undefined||_0x390e00[_0x310411(0x1b6)]!==_0x2b234e[_0x310411(0x1b6)])throw new Error(_0x310411(0x188));if(_0x390e00[_0x310411(0x1b6)]===_0x310411(0x1a9)&&_0x2b234e[_0x310411(0x1b6)]===_0x310411(0x1a9)){if(_0x390e00[_0x310411(0x168)]!==_0x2b234e[_0x310411(0x168)]||_0x390e00[_0x310411(0x13f)]!==_0x2b234e[_0x310411(0x13f)]||((await lstat(_0x2b234e[_0x310411(0xdc)]))[_0x310411(0x134)]&0x1b7+0x10ab+-0x1063)!==(_0x390e00[_0x310411(0x13f)]?0x1*-0xcdf+0x46e*0x4+-0x36c:-0x118a*-0x1+0x7e1*0x1+0x235*-0xb)||_0x390e00[_0x310411(0x1a0)]!==_0x2b234e[_0x310411(0x1a0)])throw new Error(_0x310411(0x188));continue;}if(_0x390e00[_0x310411(0x1b6)]!==_0x310411(0xbe)||_0x2b234e[_0x310411(0x1b6)]!==_0x310411(0xbe)||_0x390e00[_0x310411(0x168)]!==_0x2b234e[_0x310411(0x168)]||_0x390e00[_0x310411(0x144)]!==_0x2b234e[_0x310411(0x144)])throw new Error(_0x310411(0x188));await verifySymlinkResolution(join(_0x49cfde,_0x310411(0x11e)),_0x390e00,_0x2b234e[_0x310411(0xdc)],_0x310411(0x188));}}}function publishJob(_0x38d5ca){const _0x56e5ca=_0x49bd4c;return conversationTemplatePublishJobSchema[_0x56e5ca(0x17c)]({'id':stringValue(_0x38d5ca,'id'),'templateId':stringValue(_0x38d5ca,_0x56e5ca(0x136)),'draftRevision':numberValue(_0x38d5ca,_0x56e5ca(0xb1)),'stage':stringValue(_0x38d5ca,_0x56e5ca(0xfe)),'status':stringValue(_0x38d5ca,_0x56e5ca(0x10c)),..._0x38d5ca[_0x56e5ca(0x109)]===null?{}:{'versionId':stringValue(_0x38d5ca,_0x56e5ca(0x109))},'errorCode':_0x38d5ca[_0x56e5ca(0x18c)]===null?null:stringValue(_0x38d5ca,_0x56e5ca(0x18c)),..._0x38d5ca[_0x56e5ca(0x151)]===null?{}:{'errorSummary':stringValue(_0x38d5ca,_0x56e5ca(0x151))},'createdAt':numberValue(_0x38d5ca,_0x56e5ca(0x105)),'updatedAt':numberValue(_0x38d5ca,_0x56e5ca(0x162))});}function templateVersion(_0x257f17){const _0x5da402=_0x49bd4c;return conversationTemplateVersionSchema[_0x5da402(0x17c)]({'id':stringValue(_0x257f17,'id'),'templateId':stringValue(_0x257f17,_0x5da402(0x136)),'version':numberValue(_0x257f17,_0x5da402(0x148)),'status':stringValue(_0x257f17,_0x5da402(0x10c)),'contentHash':stringValue(_0x257f17,_0x5da402(0x185)),'manifestHash':stringValue(_0x257f17,_0x5da402(0x191)),'mcpConfigHash':stringValue(_0x257f17,_0x5da402(0xf0)),'fileCount':numberValue(_0x257f17,_0x5da402(0x16f)),'totalBytes':numberValue(_0x257f17,_0x5da402(0xcf)),'hostPolicyVersion':numberValue(_0x257f17,_0x5da402(0xe1)),'publishedByUserId':numberValue(_0x257f17,_0x5da402(0x193)),'publishedAt':numberValue(_0x257f17,_0x5da402(0xc8))});}async function walkWorkspace(_0xb033c4,_0x211eaa,_0x18bb41){const _0x41b2f7=_0x49bd4c,_0x4396b1=await lstat(_0xb033c4)[_0x41b2f7(0x10b)](_0xaee9ad=>{const _0x5ab8be=_0x41b2f7;if(_0xaee9ad[_0x5ab8be(0xf5)]===_0x5ab8be(0x164))throw new Error(_0x5ab8be(0xb6));throw _0xaee9ad;});if(_0x4396b1[_0x41b2f7(0x171)]()){if(_0x211eaa[_0x41b2f7(0xee)]===0xb50+0xee4+-0x1a34)throw new Error(_0x41b2f7(0x140));await _0x18bb41[_0x41b2f7(0xd7)](_0xb033c4,_0x211eaa,_0x4396b1);return;}if(_0x4396b1[_0x41b2f7(0x1ab)]()){if(_0x211eaa[_0x41b2f7(0xee)]===0x159c+0x5dd*0x1+-0x1b79)throw new Error(_0x41b2f7(0x15f));await _0x18bb41[_0x41b2f7(0x161)](_0xb033c4,_0x211eaa,_0x4396b1);return;}if(!_0x4396b1[_0x41b2f7(0x1b4)]())throw new Error(_0x41b2f7(0x128));if(_0x211eaa[_0x41b2f7(0xee)]>-0x34b*-0x9+-0x4b3+-0x18f0)_0x18bb41[_0x41b2f7(0x184)](_0x211eaa);for(const _0x2c4455 of(await readdir(_0xb033c4,{'withFileTypes':!![]}))[_0x41b2f7(0xd2)]((_0x33bc12,_0x15d1f2)=>_0x33bc12[_0x41b2f7(0xce)][_0x41b2f7(0x149)](_0x15d1f2[_0x41b2f7(0xce)],_0x41b2f7(0xbf)))){const _0x1daa70=_0x211eaa[_0x41b2f7(0xee)]===-0xd78+-0xeda+0xfa*0x1d?_0x2c4455[_0x41b2f7(0xce)]:_0x211eaa+'/'+_0x2c4455[_0x41b2f7(0xce)];if(_0x211eaa[_0x41b2f7(0xee)]===-0xf5d+-0xc25+0x2*0xdc1&&(_0x2c4455[_0x41b2f7(0xce)]===_0x41b2f7(0x14d)||_0x2c4455[_0x41b2f7(0xce)]===_0x41b2f7(0xc5)))throw new Error(_0x41b2f7(0x14a));if(forcedExcluded(_0x1daa70))continue;await walkWorkspace(join(_0xb033c4,_0x2c4455[_0x41b2f7(0xce)]),_0x1daa70,_0x18bb41);}}async function sealDirectories(_0x49d875,_0x1b680e=!![]){const _0x3e9246=_0x49bd4c,_0x14fb1d=await readdir(_0x49d875,{'withFileTypes':!![]});for(const _0x1c5ac7 of _0x14fb1d)if(_0x1c5ac7[_0x3e9246(0x1b4)]())await sealDirectories(join(_0x49d875,_0x1c5ac7[_0x3e9246(0xce)]));if(_0x1b680e)await chmod(_0x49d875,-0x598*-0x5+-0x17*0x12a+-0x3b*-0x1);}async function writableRemove(_0x35e3b9){const _0x8a88e5=_0x49bd4c;await chmodTree(_0x35e3b9)[_0x8a88e5(0x10b)](()=>undefined),await rm(_0x35e3b9,{'recursive':!![],'force':!![]});}async function chmodTree(_0x466241){const _0x1f7f95=_0x49bd4c,_0x1b0d73=await lstat(_0x466241);if(_0x1b0d73[_0x1f7f95(0x171)]())return;if(_0x1b0d73[_0x1f7f95(0x1b4)]()){await chmod(_0x466241,0x1837+0x17*-0xef+-0xfe);for(const _0x38a86e of await readdir(_0x466241))await chmodTree(join(_0x466241,_0x38a86e));}else await chmod(_0x466241,0x1443+0x149c*0x1+-0x275f*0x1);}async function verifyCopiedSnapshot(_0x1e84b1,_0xeb2b41,_0x1f0027,_0x55203e){const _0xd0c036=_0x49bd4c,_0xc6590d=new Map(_0x1f0027[_0xd0c036(0xfd)](_0xe67068=>[_0xe67068[_0xd0c036(0xf2)],_0xe67068])),_0x304810=new Set([..._0xeb2b41,_0xd0c036(0x14d),_0xd0c036(0xc5)]),_0x4171c9=new Set(),_0x4a2c7d=await listSnapshotEntries(_0x1e84b1,_0x304810,_0x4171c9,_0x55203e,_0xd0c036(0x15c));if(_0x4171c9[_0xd0c036(0x168)]!==_0x304810[_0xd0c036(0x168)])throw new Error(_0xd0c036(0x15c));if(_0x4a2c7d[_0xd0c036(0xee)]!==_0xc6590d[_0xd0c036(0x168)])throw new Error(_0xd0c036(0x15c));for(const _0x2999dc of _0x4a2c7d){const _0x11c9a3=_0xc6590d[_0xd0c036(0xf7)](_0x2999dc[_0xd0c036(0xf2)]);if(_0x11c9a3===undefined||_0x11c9a3[_0xd0c036(0x1b6)]!==_0x2999dc[_0xd0c036(0x1b6)])throw new Error(_0xd0c036(0x15c));if(_0x11c9a3[_0xd0c036(0x1b6)]===_0xd0c036(0x1a9)&&_0x2999dc[_0xd0c036(0x1b6)]===_0xd0c036(0x1a9)){if(_0x11c9a3[_0xd0c036(0x168)]!==_0x2999dc[_0xd0c036(0x168)]||_0x11c9a3[_0xd0c036(0x13f)]!==_0x2999dc[_0xd0c036(0x13f)]||_0x11c9a3[_0xd0c036(0x1a0)]!==_0x2999dc[_0xd0c036(0x1a0)])throw new Error(_0xd0c036(0x15c));continue;}if(_0x11c9a3[_0xd0c036(0x1b6)]!==_0xd0c036(0xbe)||_0x2999dc[_0xd0c036(0x1b6)]!==_0xd0c036(0xbe)||_0x11c9a3[_0xd0c036(0x168)]!==_0x2999dc[_0xd0c036(0x168)]||_0x11c9a3[_0xd0c036(0x144)]!==_0x2999dc[_0xd0c036(0x144)])throw new Error(_0xd0c036(0x15c));await verifySymlinkResolution(_0x1e84b1,_0x11c9a3,_0x2999dc[_0xd0c036(0xdc)],_0xd0c036(0x15c));}}async function verifySymlinkResolution(_0x1317ce,_0x323b5e,_0x3deb77,_0xdc3d41){const _0xeccab5=_0x49bd4c;let _0x18442c;try{_0x18442c=await realpath(_0x3deb77);}catch{throw new Error(_0xdc3d41);}if(_0x323b5e[_0xeccab5(0x1b3)]===_0xeccab5(0x145)){if(_0x18442c!==_0x323b5e[_0xeccab5(0xc0)])throw new Error(_0xdc3d41);return;}let _0xea3fae;try{_0xea3fae=await realpath(join(_0x1317ce,..._0x323b5e[_0xeccab5(0xc0)][_0xeccab5(0x178)]('/')));}catch{throw new Error(_0xdc3d41);}if(_0x18442c!==_0xea3fae||!within(await realpath(_0x1317ce),_0x18442c))throw new Error(_0xdc3d41);}async function listSnapshotEntries(_0x52b149,_0x766fe,_0x2a1f46,_0x4d0477,_0x144b46,_0x21203b=''){const _0x5d1c0d=_0x49bd4c,_0x321c8e=await lstat(_0x52b149);if(!_0x321c8e[_0x5d1c0d(0x1b4)]()||_0x321c8e[_0x5d1c0d(0x171)]()||_0x4d0477&&(_0x321c8e[_0x5d1c0d(0x134)]&0x15*-0x97+-0xb4b+0x88f*0x3)!==0x4*-0x8d7+-0x1*0x131+0x25fa*0x1)throw new Error(_0x144b46);const _0x24d971=[];for(const _0x40e171 of await readdir(_0x52b149,{'withFileTypes':!![]})){const _0x20e3f1=join(_0x52b149,_0x40e171[_0x5d1c0d(0xce)]),_0x271615=_0x21203b[_0x5d1c0d(0xee)]===-0x1*-0x1d17+0x19be+-0x36d5?_0x40e171[_0x5d1c0d(0xce)]:_0x21203b+'/'+_0x40e171[_0x5d1c0d(0xce)],_0x23ca25=await lstat(_0x20e3f1);if(_0x23ca25[_0x5d1c0d(0x171)]()){const _0x3726ce=await readlink(_0x20e3f1);_0x24d971[_0x5d1c0d(0x194)]({'kind':_0x5d1c0d(0xbe),'relativePath':_0x271615,'sourcePath':_0x20e3f1,'size':Buffer[_0x5d1c0d(0x165)](_0x3726ce),'linkTarget':_0x3726ce});continue;}if(_0x23ca25[_0x5d1c0d(0x1b4)]()){if(!_0x766fe[_0x5d1c0d(0x1a6)](_0x271615))throw new Error(_0x144b46);_0x2a1f46[_0x5d1c0d(0xe7)](_0x271615),_0x24d971[_0x5d1c0d(0x194)](...await listSnapshotEntries(_0x20e3f1,_0x766fe,_0x2a1f46,_0x4d0477,_0x144b46,_0x271615));continue;}if(!_0x23ca25[_0x5d1c0d(0x1ab)]()||_0x23ca25[_0x5d1c0d(0x1ac)]!==0x15*-0x37+-0x2669+0x2aed||_0x4d0477&&(_0x23ca25[_0x5d1c0d(0x134)]&-0x53d+0x96c*-0x1+-0x2*-0x854)!==(_0x23ca25[_0x5d1c0d(0x134)]&0x12ba+0x1353+0x25c4*-0x1?0x153b+0x1211+-0x25df:-0x335+0x1b6+0x2a3))throw new Error(_0x144b46);_0x24d971[_0x5d1c0d(0x194)]({'kind':_0x5d1c0d(0x1a9),'relativePath':_0x271615,'sourcePath':_0x20e3f1,'size':Number(_0x23ca25[_0x5d1c0d(0x168)]),'executable':(_0x23ca25[_0x5d1c0d(0x134)]&-0x271*-0xf+0xc5*-0x25+-0x7dd)!==0x2500+0xc80+0x4*-0xc60,'sha256':hashBuffer(await readFile(_0x20e3f1))});}return _0x24d971;}function legacyPublishedDirectories(_0x20a921){const _0x5d5588=_0x49bd4c,_0x34c1a9=new Set([_0x5d5588(0x14d),_0x5d5588(0xc5)]);for(const _0x2e4fad of _0x20a921){const _0x458e96=_0x2e4fad[_0x5d5588(0xf2)][_0x5d5588(0x178)]('/');for(let _0xe121f1=0x3*0xba2+-0x1*0x1754+-0xb91;_0xe121f1<_0x458e96[_0x5d5588(0xee)];_0xe121f1+=-0x22b2+-0x45f+0x2712)_0x34c1a9[_0x5d5588(0xe7)](_0x458e96[_0x5d5588(0x14c)](-0x7a*-0x1d+-0x4*-0x39+-0xeb6,_0xe121f1)[_0x5d5588(0xd9)]('/'));}return _0x34c1a9[_0x5d5588(0xd1)](_0x5d5588(0x14d)),_0x34c1a9[_0x5d5588(0xd1)](_0x5d5588(0xc5)),[..._0x34c1a9][_0x5d5588(0xd2)]((_0x2a59d4,_0x771af7)=>_0x2a59d4[_0x5d5588(0x149)](_0x771af7,_0x5d5588(0xbf)));}function forcedExcluded(_0x342104){const _0x3cd17f=_0x49bd4c,_0x3df3cf=_0x342104[_0x3cd17f(0x178)]('/');if(_0x3df3cf[_0x3cd17f(0x177)](_0x5e8003=>{const _0x241b6f=_0x3cd17f,_0x3de4c5=_0x5e8003[_0x241b6f(0xb2)](_0x241b6f(0xbf));return FORCED_EXCLUDED_NAMES[_0x241b6f(0x1a6)](_0x3de4c5)||_0x3de4c5[_0x241b6f(0x129)](_0x241b6f(0x113));}))return!![];const _0x490f7d=_0x3df3cf['at'](-(0x38f*0x9+0x14a7*0x1+0x1b3*-0x1f))?.[_0x3cd17f(0xb2)](_0x3cd17f(0xbf))??'';return _0x3df3cf[_0x3cd17f(0xee)]===0x4e4*0x5+-0x12be+-0x5b5*0x1&&(ROOT_EXCLUDED_NAMES[_0x3cd17f(0x1a6)](_0x490f7d)||_0x490f7d[_0x3cd17f(0x101)](_0x3cd17f(0x13b))||_0x490f7d[_0x3cd17f(0x101)](_0x3cd17f(0x1a4))||_0x490f7d===_0x3cd17f(0x16d)||_0x490f7d===_0x3cd17f(0x18e))||_0x490f7d[_0x3cd17f(0x101)](_0x3cd17f(0x159));}async function publishedSymlink(_0x1f0d62,_0x1c6614,_0x33f64f,_0x1af4cf){const _0x4227ac=_0x49bd4c;if(!_0x1af4cf[_0x4227ac(0x171)]())throw new Error(_0x4227ac(0x140));const _0x3bc454=await readlink(_0x1c6614);let _0x58777c;try{_0x58777c=await realpath(_0x1c6614);}catch{throw new Error(_0x4227ac(0x140));}if(_0x58777c===_0x1f0d62||within(_0x1f0d62,_0x58777c)){const _0x341ec4=await lstat(_0x58777c)[_0x4227ac(0x10b)](()=>undefined);if(_0x341ec4===undefined||_0x341ec4[_0x4227ac(0x1b4)]()&&(_0x58777c===_0x1f0d62||within(_0x58777c,_0x1c6614)))throw new Error(_0x4227ac(0x140));const _0x141d52=relative(_0x1f0d62,_0x58777c)[_0x4227ac(0x178)](sep)[_0x4227ac(0xd9)]('/');if(_0x141d52[_0x4227ac(0xee)]===0x26f9+0x1a2d+-0x4126||forcedExcluded(_0x141d52))throw new Error(_0x4227ac(0x140));return{'kind':_0x4227ac(0xbe),'relativePath':_0x33f64f,'sourcePath':_0x1c6614,'size':Buffer[_0x4227ac(0x165)](_0x3bc454),'linkTarget':_0x3bc454,'targetKind':_0x4227ac(0x15e),'resolvedTarget':_0x141d52};}const _0x2ae3a2=RUNTIME_LINK_ROOTS[_0x4227ac(0x173)](_0x31a51e=>_0x58777c===_0x31a51e||within(_0x31a51e,_0x58777c));if(_0x2ae3a2===undefined)throw new Error(_0x4227ac(0x140));return{'kind':_0x4227ac(0xbe),'relativePath':_0x33f64f,'sourcePath':_0x1c6614,'size':Buffer[_0x4227ac(0x165)](_0x3bc454),'linkTarget':_0x3bc454,'targetKind':_0x4227ac(0x145),'resolvedTarget':_0x58777c};}function templateVersionManifest(_0x59cfec){const _0x540861=_0x49bd4c;if(!record(_0x59cfec))throw new Error(_0x540861(0x188));const _0x310dc0=Array[_0x540861(0xf3)](_0x59cfec[_0x540861(0x14f)])?_0x59cfec[_0x540861(0x14f)]:undefined;if(_0x310dc0===undefined||typeof _0x59cfec[_0x540861(0xe8)]!==_0x540861(0xec)||typeof _0x59cfec[_0x540861(0x160)]!==_0x540861(0xec))throw new Error(_0x540861(0x188));if(_0x59cfec[_0x540861(0x192)]===0x1996+0x158+0x1aed*-0x1){if(!Array[_0x540861(0xf3)](_0x59cfec[_0x540861(0x135)]))throw new Error(_0x540861(0x188));const _0x3d9059=_0x59cfec[_0x540861(0x135)][_0x540861(0xfd)](_0x5ce74e=>manifestFile(_0x5ce74e));return{'schemaVersion':0x1,'directories':legacyPublishedDirectories(_0x3d9059),'entries':_0x3d9059,'contentHash':_0x59cfec[_0x540861(0x160)],'mcpServers':_0x310dc0,'mcpConfigHash':_0x59cfec[_0x540861(0xe8)]};}if(_0x59cfec[_0x540861(0x192)]!==0x1d8+0x2*-0x12c6+0x23b6||typeof _0x59cfec[_0x540861(0x17f)]!==_0x540861(0xec)||!Array[_0x540861(0xf3)](_0x59cfec[_0x540861(0xaf)])||!Array[_0x540861(0xf3)](_0x59cfec[_0x540861(0x132)]))throw new Error(_0x540861(0x188));validateSourceWorkspacePath(_0x59cfec[_0x540861(0x17f)]);const _0x4ffc12=_0x59cfec[_0x540861(0xaf)][_0x540861(0xfd)](_0x22e3d4=>safeManifestRelativePath(_0x22e3d4));if(new Set(_0x4ffc12)[_0x540861(0x168)]!==_0x4ffc12[_0x540861(0xee)]||_0x4ffc12[_0x540861(0x16c)](_0x540861(0x14d))||_0x4ffc12[_0x540861(0x16c)](_0x540861(0xc5)))throw new Error(_0x540861(0x188));const _0x41ac6b=_0x59cfec[_0x540861(0x132)][_0x540861(0xfd)](_0x4eb0e6=>manifestEntry(_0x4eb0e6));if(new Set(_0x41ac6b[_0x540861(0xfd)](_0x49cdc7=>_0x49cdc7[_0x540861(0xf2)]))[_0x540861(0x168)]!==_0x41ac6b[_0x540861(0xee)])throw new Error(_0x540861(0x188));return{'schemaVersion':0x2,'sourceWorkspacePath':_0x59cfec[_0x540861(0x17f)],'directories':_0x4ffc12,'entries':_0x41ac6b,'contentHash':_0x59cfec[_0x540861(0x160)],'mcpServers':_0x310dc0,'mcpConfigHash':_0x59cfec[_0x540861(0xe8)]};}function manifestEntry(_0x3623b7){const _0x5ab431=_0x49bd4c;if(!record(_0x3623b7))throw new Error(_0x5ab431(0x188));if(_0x3623b7[_0x5ab431(0x1b6)]===_0x5ab431(0x1a9))return manifestFile(_0x3623b7,!![]);if(_0x3623b7[_0x5ab431(0x1b6)]!==_0x5ab431(0xbe)||typeof _0x3623b7[_0x5ab431(0x144)]!==_0x5ab431(0xec)||_0x3623b7[_0x5ab431(0x144)][_0x5ab431(0xee)]===0xdbb+0x559+-0x1314||_0x3623b7[_0x5ab431(0x144)][_0x5ab431(0x16c)]('\x00')||_0x3623b7[_0x5ab431(0x1b3)]!==_0x5ab431(0x15e)&&_0x3623b7[_0x5ab431(0x1b3)]!==_0x5ab431(0x145)||typeof _0x3623b7[_0x5ab431(0xc0)]!==_0x5ab431(0xec))throw new Error(_0x5ab431(0x188));const _0x1cc66c=safeManifestRelativePath(_0x3623b7[_0x5ab431(0xf2)]),_0xf7ac0a=safeNonNegativeInteger(_0x3623b7[_0x5ab431(0x168)]),_0x2d2f69=_0x3623b7[_0x5ab431(0x144)],_0x159680=_0x3623b7[_0x5ab431(0x1b3)],_0x5d1adf=_0x3623b7[_0x5ab431(0xc0)];if(_0xf7ac0a!==Buffer[_0x5ab431(0x165)](_0x2d2f69))throw new Error(_0x5ab431(0x188));if(_0x159680===_0x5ab431(0x15e))safeManifestRelativePath(_0x5d1adf);else{if(!isAbsolute(_0x5d1adf)||!RUNTIME_LINK_ROOTS[_0x5ab431(0x177)](_0x2990b1=>_0x5d1adf===_0x2990b1||within(_0x2990b1,_0x5d1adf)))throw new Error(_0x5ab431(0x188));}return{'kind':_0x5ab431(0xbe),'relativePath':_0x1cc66c,'size':_0xf7ac0a,'linkTarget':_0x2d2f69,'targetKind':_0x159680,'resolvedTarget':_0x5d1adf};}function manifestFile(_0x169abd,_0x2d7290=![]){const _0x3b3dba=_0x49bd4c;if(!record(_0x169abd)||_0x2d7290&&_0x169abd[_0x3b3dba(0x1b6)]!==_0x3b3dba(0x1a9)||typeof _0x169abd[_0x3b3dba(0x13f)]!==_0x3b3dba(0x1b0)||typeof _0x169abd[_0x3b3dba(0x1a0)]!==_0x3b3dba(0xec)||!/^[a-f0-9]{64}$/u[_0x3b3dba(0x123)](_0x169abd[_0x3b3dba(0x1a0)]))throw new Error(_0x3b3dba(0x188));return{'kind':_0x3b3dba(0x1a9),'relativePath':safeManifestRelativePath(_0x169abd[_0x3b3dba(0xf2)]),'size':safeNonNegativeInteger(_0x169abd[_0x3b3dba(0x168)]),'executable':_0x169abd[_0x3b3dba(0x13f)],'sha256':_0x169abd[_0x3b3dba(0x1a0)]};}function safeManifestRelativePath(_0x36c7a2){const _0x9b726d=_0x49bd4c;if(typeof _0x36c7a2!==_0x9b726d(0xec)||_0x36c7a2[_0x9b726d(0xee)]===0x177f+-0x1*0xa87+0xcf8*-0x1||_0x36c7a2[_0x9b726d(0x129)]('/')||_0x36c7a2[_0x9b726d(0x16c)]('\x5c')||_0x36c7a2[_0x9b726d(0x178)]('/')[_0x9b726d(0x177)](_0x358974=>_0x358974[_0x9b726d(0xee)]===0x91d*0x1+0x3*-0x87d+-0x256*-0x7||_0x358974==='.'||_0x358974==='..'))throw new Error(_0x9b726d(0x188));return _0x36c7a2;}function safeNonNegativeInteger(_0x551fe9){const _0x1e4e2e=_0x49bd4c;if(!Number[_0x1e4e2e(0x17e)](_0x551fe9)||_0x551fe9<-0xc37*0x1+-0x95*0x1+0xccc)throw new Error(_0x1e4e2e(0x188));return _0x551fe9;}function _0x305a(_0x185531,_0x3b71de){_0x185531=_0x185531-(0x1*-0x1a74+-0x14bd+0x2fdf);const _0x5a17db=_0x3489();let _0x37ce9a=_0x5a17db[_0x185531];if(_0x305a['zCddzP']===undefined){var _0x5c4e0a=function(_0x54b8ad){const _0x7692e3='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x443154='',_0xf1e8a7='';for(let _0x1b3008=-0x221b*-0x1+0x1*-0xe81+-0x139a*0x1,_0x52477a,_0x27b877,_0x52db22=0x18d0+0x1db0+-0x3680;_0x27b877=_0x54b8ad['charAt'](_0x52db22++);~_0x27b877&&(_0x52477a=_0x1b3008%(0x1cbe+-0x2*-0x18b+-0x1fd*0x10)?_0x52477a*(-0x43*-0x8e+-0x215+-0x22d5)+_0x27b877:_0x27b877,_0x1b3008++%(-0xd92+-0x1fbb+0x2d51))?_0x443154+=String['fromCharCode'](-0x1*0xa5b+-0x15c7+-0x303*-0xb&_0x52477a>>(-(-0x8*-0x2d9+-0x17f8+0x132)*_0x1b3008&0x1323*0x1+0xa87*0x2+-0x282b)):-0x131c+0xfaf+0x36d){_0x27b877=_0x7692e3['indexOf'](_0x27b877);}for(let _0x21dec4=-0x2626*-0x1+-0x2291+0x83*-0x7,_0x76ebdc=_0x443154['length'];_0x21dec4<_0x76ebdc;_0x21dec4++){_0xf1e8a7+='%'+('00'+_0x443154['charCodeAt'](_0x21dec4)['toString'](0x1cd2+0x1cf6+-0x8*0x737))['slice'](-(0x195*0x1+-0x1c35+0xe*0x1e7));}return decodeURIComponent(_0xf1e8a7);};_0x305a['sUvSyK']=_0x5c4e0a,_0x305a['wPLPhg']={},_0x305a['zCddzP']=!![];}const _0x4f2b9f=_0x5a17db[0x2*0x237+0xe8e+-0x12fc];_0x305a['MRBSmx']!==_0x4f2b9f&&(_0x305a['wPLPhg']={},_0x305a['MRBSmx']=_0x4f2b9f);const _0x88743=_0x305a['wPLPhg'][_0x185531];return _0x88743===undefined?(_0x37ce9a=_0x305a['sUvSyK'](_0x37ce9a),_0x305a['wPLPhg'][_0x185531]=_0x37ce9a):_0x37ce9a=_0x88743,_0x37ce9a;}function snapshotContentHash(_0x4565a0,_0x36a324,_0x1ad18e=-0x187*-0xe+-0x21c4+-0x4*-0x319){const _0x33beed=_0x49bd4c;if(_0x1ad18e===0x1a72+0x111c+-0x2b8d*0x1)return hashText(_0x36a324[_0x33beed(0xfd)](_0x510d7c=>{const _0x34b5cd=_0x33beed;if(_0x510d7c[_0x34b5cd(0x1b6)]!==_0x34b5cd(0x1a9))throw new Error(_0x34b5cd(0x188));return _0x510d7c[_0x34b5cd(0xf2)]+'\x00'+_0x510d7c[_0x34b5cd(0x168)]+'\x00'+_0x510d7c[_0x34b5cd(0x1a0)];})[_0x33beed(0xd9)]('\x0a'));return hashText([..._0x4565a0[_0x33beed(0xfd)](_0x4a72d0=>_0x33beed(0x120)+_0x4a72d0),..._0x36a324[_0x33beed(0xfd)](_0x36b9fe=>_0x36b9fe[_0x33beed(0x1b6)]===_0x33beed(0x1a9)?_0x36b9fe[_0x33beed(0x1b6)]+'\x00'+_0x36b9fe[_0x33beed(0xf2)]+'\x00'+_0x36b9fe[_0x33beed(0x168)]+'\x00'+(_0x36b9fe[_0x33beed(0x13f)]?-0x47f*0x2+-0x16f*0xc+-0x1*-0x1a33:-0x3*0xc61+-0x622+0x2b45)+'\x00'+_0x36b9fe[_0x33beed(0x1a0)]:_0x36b9fe[_0x33beed(0x1b6)]+'\x00'+_0x36b9fe[_0x33beed(0xf2)]+'\x00'+_0x36b9fe[_0x33beed(0x168)]+'\x00'+_0x36b9fe[_0x33beed(0x144)]+'\x00'+_0x36b9fe[_0x33beed(0x1b3)]+'\x00'+_0x36b9fe[_0x33beed(0xc0)])][_0x33beed(0xd9)]('\x0a'));}async function hostedFilesystemAvailableBytes(_0xb2519a){const _0x35b76e=_0x49bd4c;try{const _0x68b9d5=await statfs(_0xb2519a),_0x279915=Number(_0x68b9d5[_0x35b76e(0xb9)])*Number(_0x68b9d5[_0x35b76e(0x197)]);if(!Number[_0x35b76e(0xcc)](_0x279915)||_0x279915<0x15c5*-0x1+-0xf85+0x254a)throw new Error(_0x35b76e(0x150));return Math[_0x35b76e(0x196)](Math[_0x35b76e(0x18f)](_0x279915),Number[_0x35b76e(0xff)]);}catch(_0x47f3df){if(_0x47f3df instanceof Error&&_0x47f3df[_0x35b76e(0x15d)]===_0x35b76e(0x150))throw _0x47f3df;throw new Error(_0x35b76e(0x150));}}function validateSourceWorkspacePath(_0x2f0edf){const _0x537503=_0x49bd4c;if(!isAbsolute(_0x2f0edf)||resolve(_0x2f0edf)!==_0x2f0edf||_0x2f0edf==='/'||_0x2f0edf===_0x537503(0x11a))throw new Error(_0x537503(0x15f));if(RESERVED_SANDBOX_ROOTS[_0x537503(0x177)](_0x25335a=>_0x2f0edf===_0x25335a||within(_0x25335a,_0x2f0edf)||within(_0x2f0edf,_0x25335a)))throw new Error(_0x537503(0x15f));}function within(_0xa412a4,_0x4c5780){const _0x167bff=_0x49bd4c,_0x238aca=relative(_0xa412a4,_0x4c5780);return _0x238aca[_0x167bff(0xee)]>-0x1087*0x1+-0xf77+0x1ffe&&_0x238aca!=='..'&&!_0x238aca[_0x167bff(0x129)]('..'+sep);}function hashText(_0x4b5932){const _0x2583b3=_0x49bd4c;return createHash(_0x2583b3(0x1a0))[_0x2583b3(0x198)](_0x4b5932)[_0x2583b3(0x152)](_0x2583b3(0x12b));}function hashBuffer(_0x3050e9){const _0x18d892=_0x49bd4c;return createHash(_0x18d892(0x1a0))[_0x18d892(0x198)](_0x3050e9)[_0x18d892(0x152)](_0x18d892(0x12b));}function _0x3489(){const _0x4733db=['q09ovKvsu0fusu9ox0Hpu1rjtKDFu1rpuKfhrv9gvuXm','Bw9Kzq','zMLSzxm','DgvTCgXHDgvFAwq','DgvTCgXHDgvqDwjSAxnOAw5NrgLYzwn0B3j5','ChvIBgLZAff1zxvLCW','q09ovKvsu0fusu9ox1rftvbmqvrfx0Loufvux0LovKfmsuq','Ag9ZDfbVBgLJEvzLCNnPB24','lNbLBq','vKfmsurbveLorW','ChvIBgLZAfn0yxr1CW','CMvXDwvZDgvKx2j5x3vZzxjFAwq','zxHLy3v0ywjSzq','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9msu5lx0LovKfmsuq','q09ovKvsu0fusu9ox1rftvbmqvrfx1jfvKLtsu9ox0nptKzmsunu','BwnWt3b0Aw9UCW','Aw5ZCgvJDfnVDxjJzq','BgLUA1rHCMDLDa','uLvoveLnrq','BMv0D29YA01Vzgu','DxbKyxrLsM9I','DMvYC2LVBL9UDw1Izxi','Bg9JywXLq29TCgfYzq','q09ovKvsu0fusu9ox1rftvbmqvrfx1jfu0vsvKvex1bbveG','CMvKDwnL','C2XPy2u','Aw5IB3G','mJK4ody5mfnwEKffAG','BwnWu2vYDMvYCW','q09ovKvsu0fusu9ox0Hpu1rjtKDFu1rpuKfhrv9vtKfwquLmqujmrq','zxjYB3jFC3vTBwfYEq','zgLNzxn0','DgvTCgXHDgvZuhvIBgLZAgLUz0rPCMvJDg9YEq','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pW','mJC2mtq3ouXRvufArW','lMDPDa','su5trvjuieLove8Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaOAwqSDgvTCgXHDgvFAwqSzhjHzNrFCMv2AxnPB24SC3rHz2uSC3rHDhvZlhzLCNnPB25FAwqSzxjYB3jFy29KzsXLCNjVCL9ZDw1Tyxj5laOGicaGicaGicaGCMvXDwvZDgvKx2j5x3vZzxjFAwqSzhjHzNqSy3jLyxrLzf9HDcX1CgrHDgvKx2f0kqOGicaGicaGicbwquXvrvmGkd8SpYW/lcDwquXjrefusu5hjYWNuvvfvuvejYXovuXmle5vteWStLvmtcW/ld8SpYW/kq','DgvTCgXHDgvwzxjZAw9UrgLYzwn0B3j5','lNnVy2S','CgvYzM9YBvb1yMXPC2G','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFChvIBgLZAf9QB2jZifDirvjfigLKpt8','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9dsefor0ve','BwvZC2fNzq','u05bufnit1q','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9jtLzbteLe','y29UDgvUDeHHC2G','zMLSzq','DxbKyxrLzf9HDa','y2f0ywXVz0vUDhj5swq','ru5pru5u','yNL0zuXLBMD0Aa','u0vmrunuihn0B3jHz2vFA2v5iezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25Z','lM5WBxjJ','C2L6zq','B3b0Aw9UCW','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb2zxjZAw9UigLZihzHBgLKlG','DMvYC2LVBKLK','Aw5JBhvKzxm','AwrFCNnH','ChvIBgLZAfjLC3vSDa','zMLSzv9JB3vUDa','BM9KzuLK','AxntEw1IB2XPy0XPBMS','l2HVBwuVBwfY','zMLUza','DxrMoa','BM93','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGu0vuihn0yxr1CZ0NrKfjtevejYX2zxjZAw9Ux2LKpu5vteWSzxjYB3jFy29Kzt0Nq09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFsu5urvjsvvburuqNlaOGicaGicaGicaGicaGzxjYB3jFC3vTBwfYEt0/lhvWzgf0zwrFyxq9pWOGicaGicaGicbxsevsrsbZDgf0DxmGsu4GkcDrvuvvruqNlcDsvu5osu5hjYKGqu5eihn0ywDLpd4NuKvhsvnurvjfrcC','C29Tzq','C3bSAxq','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsbZB3vYy2uGAxmGDMfSAwqU','ywXS','q09suLvqveve','CgfYC2u','ntaWmta4s3btAK9h','AxntywzLsw50zwDLCG','C291CMnLv29YA3nWywnLugf0Aa','ChvIBgLZAgvKqxq','su5trvjuieLove8Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZcIaGicaGicaGicaGkgLKlhrLBxbSyxrLx2LKlhzLCNnPB25FBNvTyMvYlgrYywz0x3jLDMLZAw9Ulhn0yxr1CYXZDg9YywDLx2TLEsXTyw5PzMvZDcXJB250zw50x2HHC2GScIaGicaGicaGicaGig1HBMLMzxn0x2HHC2GSBwnWx2nVBMzPz19OyxnOlgzPBgvFy291BNqSDg90ywXFyNL0zxmSAg9ZDf9WB2XPy3LFDMvYC2LVBIWkicaGicaGicaGicaGChvIBgLZAgvKx2j5x3vZzxjFAwqSChvIBgLZAgvKx2f0lhjLzMvYzw5Jzv9JB3vUDcKkicaGicaGicaGicbwquXvrvmGkd8SpYW/ld8SpYW/ld8SpYW/ld8SpYW/ld8SpYW/ldaP','CMvXDwvZDgvKqNLvC2vYswq','y29SBgvJDfnUyxbZAg90','zgLYzwn0B3j5','y29UDgvUDf9OyxnO','u0nbtK5jtKC','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb2zxjZAw9UigLZigLUDMfSAwqGka','q09ovKvsu0fusu9ox1rftvbmqvrfx1zfuLnjt05Fq09suLvqveve','zxHLyW','y3jLzgvUDgLHBhm','tufosuzfu1q','zxjYB3jFy29Kzq','l2rLDG','AwrFzwqYntuXoq','zMXVB3i','y29UzMLNDxjHDgLVBG','BwfUAwzLC3rFAgfZAa','C2nOzw1HvMvYC2LVBG','ChvIBgLZAgvKx2j5x3vZzxjFAwq','ChvZAa','ChvIBgLZAa','BwLU','yNnPEMu','DxbKyxrL','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmGu0vuihn0ywDLpt8SC3rHDhvZpt8SDxbKyxrLzf9HDd0/ifDirvjfigLKpt8','uK9mtejbq0S','zMLSzunVDw50','qKvhsu4Gsu1nrurjqvrf','CMf3','Cgf0Aa','x193B3jRC3bHy2vxyxrJAfnLC3nPB25iyxnO','C2HHmJu2','uKvhsvnurvjfra','l3bYB2m','CMvZB2X2zq','lMTLEq','zhjHzNq','AgfZ','z2v0v29YA3nWywnL','DgvTCgXHDgvZvMvYC2LVBNneAxjLy3rVCNK','rKLmrq','mtC5mJH2EhjdtLe','AxngAwXL','BMXPBMS','l3nIAw4','yxnZzxj0tg9JywXeCMfMDa','Aw5ZCgvJDfzLCNnPB24','yM9VBgvHBG','lMf3CW','zw5XDwv1zvb1yMXPC2G','DgfYz2v0s2LUza','AxneAxjLy3rVCNK','A2v5CW','A2LUza','l3j1BG','vgHLihb1yMXPC2GGCMvXDwvZDcb3yxmGAw50zxjYDxb0zwqGyMvMB3jLihrOzsb0zw1WBgf0zsb2zxjZAw9UihDHCYbYzwDPC3rLCMvKlG','zgLYzwn0B3jPzxm','zMLUAxnOuMvNAxn0zxjLzfb1yMXPy2f0Aw9UCW','zhjHzNrFCMv2AxnPB24','Dg9mB2nHBgvmB3DLCKnHC2u','l2XPyG','BwnWswrZ','qvzbsuXbqKXf','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9nsvntsu5h','refuqujbu0vFvKfmvuvFsu5wquXjrdO','ChvIBgLZAePVyLjVDW','yMf2ywLS','C3rVCMfNzv9RzxK','mZjlsuXlzLG','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsbZB3vYy2uGAxmGAw52ywXPzcaO','v09ss1nqqunfx05pvf9gt1vora','u1LnteLosW','zw4Tvvm','CMvZB2X2zwruyxjNzxq','yMLNAw50','y2HHBMDLCW','zgf0ywjHC2u','BNvTyMvY','B3v0Chv0','l2jPBG','u0vmrunuihrLBxbSyxrLx2LKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZifDirvjfigLKpt8','ChvIBgLZAgvKx2f0','u0vbteve','q09ovKvsu0fusu9ox1rftvbmqvrfx05pvf9bvvrit1jjwKve','C2vJCMv0CW','AxngAw5PDgu','lM1HCG','BMfTzq','Dg90ywXFyNL0zxm','l3DVCMTZCgfJzq','zgvSzxrL','C29YDa','C2v0','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaGicaGicbxsevsrsbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCkicaGicaGicaGicaGicaGt1jerviGqLKGy3jLyxrLzf9HDcXPza','q09ntuLu','sfruua','C3LTBgLUAW','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGu0vuihn0yxr1CZ0Nu1vdq0vfrevejYXLCNjVCL9JB2rLpu5vteWSzxjYB3jFC3vTBwfYEt1ovuXmlhvWzgf0zwrFyxq9pWOGicaGicaGicbxsevsrsbPzd0/ieforcbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCGqu5eihzLCNnPB25FAwq9pW','AM9PBG','CMvXDwLYzvb1yMXPC2HkB2jsB3C','Dg90ywXcExrLCW','C291CMnLugf0Aa','yMfZzty0DxjS','ntqWndK5mLDYBLrNyG','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv92zxjZAw9UCYbtrvqGC3rHDhvZpsDdt1jsvvburuqNifDirvjfigLKpt8','zgf0yq','Ag9ZDf9WB2XPy3LFDMvYC2LVBG','q09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFsK9cx05pvf9gt1vora','zwzMzwn0AxzLtwnWsw5ZDgfSBgf0Aw9UCW','ody0nda1yxn5u0PM','CMvXDwvZDfvZzxjjza','u1vdq0vfreve','ywrK','BwnWq29UzMLNsgfZAa','CMv2AxnPB24','DgvTCgXHDgvF','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGicbtrvqGC3rHz2u9j1jfr0LtvevsruqNlhn0yxr1CZ0NuLvotKLorYCSDMvYC2LVBL9Pzd0/lgvYCM9Yx2nVzgu9tLvmtcXLCNjVCL9ZDw1Tyxj5pu5vteWScIaGicaGicaGicaGicaGihvWzgf0zwrFyxq9pWOGicaGicaGicaGifDirvjfigLKpt8Gqu5eihrLBxbSyxrLx2LKpt8Gqu5eigrYywz0x3jLDMLZAw9Upt8Gqu5eihjLCxvLC3rLzf9IEv91C2vYx2LKpt8kicaGicaGicaGicaGieforcbZDgfNzt0Nu0vbtevejYbbtKqGC3rHDhvZpsDsvu5osu5hjYbbtKqGDMvYC2LVBL9PzcbjuYbovuXm','C3rYAw5N','DgHLBG','BgvUz3rO','C2vYDMvYtMfTzq','BwnWx2nVBMzPz19OyxnO','q09ovKvsu0fusu9ox1rftvbmqvrfx1bvqKXju0HFrKfjteve','CMvSyxrPDMvqyxrO','AxnbCNjHEq','BMv4DfzLCNnPB25oDw1Izxi','y29Kzq','q09ovKvsu0fusu9ox1rftvbmqvrfx01duf9jtLzbteLe','z2v0','mtaWotiXntLdzefryKm','q09ovKvsu0fusu9ox1rftvbmqvrfx05pvf9gt1vora','CMvNAxn0zxjwzxjZAw9U','u0vmrunuienpquXfu0nfke1bwcH2zxjZAw9Ux251BwjLCIKSmcKGqvmGDMvYC2LVBL9UDw1IzxiGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGDgvTCgXHDgvFAwq9pW','l2XPyJy0','BwfW','C3rHz2u','tufyx1nbrKvFsu5uruDfuG','zgLZCgXHEu5HBwu','zw5KC1DPDgG','vu5srvnuuKLdveve','DMvYC2LVBG','CNvU','y3jLyxrLzf9HDa','DMfSDwvZ','C2vSzwn0zwrny3btzxj2zxjZ','D29YA3nWywnLswq','DMvYC2LVBL9Pza','lNb5CgLYyW','y2f0y2G','C3rHDhvZ','u0vmrunuicOGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pYbbtKqGDgvTCgXHDgvFAwq9pW','lNnZAa','vgHLihb1yMXPC2GGCMvXDwvZDcbMywLSzwqGka','ChvIBgLZAgvKqNLvC2vYswq','C3rYAw5NAwz5','DgvTCgXHDgvjza','lMvUDG','C3rVCMu','l3j1BNrPBwu','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3b1yMXPC2HFAM9ICWOGicaGicaGicaGicaGicbxsevsrsb0zw1WBgf0zv9Pzd0/ieforcbZDgfNzt0NuKvhsvnurvjfrcCGqu5eihn0yxr1CZ0NuLvotKLorYCkicaGicaGicaGicaGicaGt1jerviGqLKGy3jLyxrLzf9HDcXPza','AM9Iswq','B2jQzwn0','mJrIDfjzEhO','l3rTCa','vvbeqvrfignVBNzLCNnHDgLVBL90zw1WBgf0zv9WDwjSAxnOx2PVyNmkicaGicaGicaGicbtrvqGC3rHz2u9pYXZDgf0Dxm9j0zbsuXfrcCSDMvYC2LVBL9Pzd1ovuXmlgvYCM9Yx2nVzgu9pYXLCNjVCL9ZDw1Tyxj5pt8SDxbKyxrLzf9HDd0/ifDirvjfigLKpt8','uLvotKLorW','zMLUAxnOuMvNAxn0zxjLzfb1yMXPy2f0Aw9U','y29UDgvUDa','q09qwuLorW','reLsrunut1jzaa','CNvUDgLTzq','CM9VDerPCMvJDg9YEq','DgvZDa','DhjHBNnWB3j0','lMf6DxjL','CMvJB3zLCKLUDgvYCNvWDgvKuhvIBgLJyxrPB25Z','BwfUAwzLC3qUANnVBG','q09ovKvsu0fusu9ox1rftvbmqvrfx1npvvjdrv9uwvbfx0LovKfmsuq','C3rHCNrZv2L0Aa','ChjLCgfYzq','Agv4','ru5vtuvsqvrjtKC','B3bLCMf0Aw9UCW','DMvYAwz5vMvYC2LVBG','l3vZCG','BwfUAwzLC3riyxnO','zMLUywXSEq','zw50CMLLCW'];_0x3489=function(){return _0x4733db;};return _0x3489();}function stringValue(_0x75fc6,_0x4fc1a7){const _0x580be1=_0x49bd4c,_0x199090=_0x75fc6[_0x4fc1a7];if(typeof _0x199090!==_0x580be1(0xec))throw new Error(_0x580be1(0xb7)+_0x4fc1a7);return _0x199090;}function numberValue(_0x3839a3,_0x1cf7f1){const _0x477382=_0x49bd4c,_0x26eca4=_0x3839a3[_0x1cf7f1];if(typeof _0x26eca4!==_0x477382(0xc4)&&typeof _0x26eca4!==_0x477382(0xc1))throw new Error(_0x477382(0xb7)+_0x1cf7f1);const _0x1c7c9e=Number(_0x26eca4);if(!Number[_0x477382(0x17e)](_0x1c7c9e))throw new Error(_0x477382(0xb7)+_0x1cf7f1);return _0x1c7c9e;}function nodeRequestPayload(_0x273d58){const _0x2079ea=_0x49bd4c;if(!record(_0x273d58))return{'data':_0x273d58};const {__requestUserId:_0x264e74,..._0x5b0958}=_0x273d58;delete _0x5b0958[_0x2079ea(0x19f)];if(_0x264e74===undefined)return{'data':_0x5b0958};if(typeof _0x264e74!==_0x2079ea(0xc4)||!Number[_0x2079ea(0x17e)](_0x264e74)||_0x264e74<=-0x2380+-0x125*0x3+0x26ef)throw new Error(_0x2079ea(0xca));return{'data':_0x5b0958,'requestUserId':_0x264e74};}function record(_0x3ab6a2){const _0x11322c=_0x49bd4c;return typeof _0x3ab6a2===_0x11322c(0x118)&&_0x3ab6a2!==null&&!Array[_0x11322c(0xf3)](_0x3ab6a2);}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* mar-release-protected */
|
|
2
|
-
const _0x132f42=_0x1c9a;(function(_0x6c40e1,_0x23b77d){const _0x56f56a=_0x1c9a,_0x5b6e9b=_0x6c40e1();while(!![]){try{const _0x174f2b=parseInt(_0x56f56a(0x244))/(-0x121f*-0x2+-0x16a4+-0xd99*0x1)*(parseInt(_0x56f56a(0x26a))/(0x1a45+-0x1825+-0x21e))+-parseInt(_0x56f56a(0xf2))/(-0x7ed*0x1+-0x5df+0xdcf)+parseInt(_0x56f56a(0x251))/(0x7ab+-0x116a+0x9c3)*(parseInt(_0x56f56a(0x246))/(-0x75a*0x4+-0x1*-0x1edf+-0x172))+-parseInt(_0x56f56a(0x215))/(-0xa7d+0xfbc+0xbf*-0x7)+-parseInt(_0x56f56a(0x128))/(0x1f8+-0x1f30+0x1d3f)*(parseInt(_0x56f56a(0x1a4))/(-0x22e8*0x1+0x10a9*-0x2+-0x1*-0x4442))+-parseInt(_0x56f56a(0x1de))/(0xab5*-0x1+0x12cb+-0x80d)*(parseInt(_0x56f56a(0x11f))/(-0x1ded+-0x2a2+-0x685*-0x5))+parseInt(_0x56f56a(0x284))/(0x2*0xf44+0x20c7*-0x1+0x24a);if(_0x174f2b===_0x23b77d)break;else _0x5b6e9b['push'](_0x5b6e9b['shift']());}catch(_0x1107cf){_0x5b6e9b['push'](_0x5b6e9b['shift']());}}}(_0x5676,0x2*0x15f67+0xb2*-0x631+0x1e4f3*0x4));import{createHash,randomUUID}from'node:crypto';import{lstat,mkdir,open,readFile,readlink,readdir,realpath,rename,rm,utimes}from'node:fs/promises';import{isAbsolute,join,relative,resolve,sep}from'node:path';import{conversationTemplateDraftSchema,conversationTemplateSummarySchema,hostedConversationConfigUpdateInputSchema,hostedConversationCreateInputSchema,hostedConversationDeleteResultSchema,hostedConversationFileDeleteInputSchema,hostedConversationFileDeleteResultSchema,hostedConversationFileReadInputSchema,hostedConversationFileReadResultSchema,hostedConversationFilesSchema,hostedConversationIdInputSchema,hostedConversationImageReadInputSchema,hostedConversationListInputSchema,hostedConversationListPageSchema,hostedConversationMessageInputSchema,hostedConversationMetadataUpdateInputSchema,hostedConversationSnapshotSchema,hostedConversationSummarySchema,hostedConversationUnwatchInputSchema,hostedConversationUploadChunkInputSchema,hostedConversationUploadControlInputSchema,hostedConversationUploadCreateInputSchema,hostedConversationUploadPreflightInputSchema,hostedConversationUploadPreflightResultSchema,hostedConversationUploadSchema,hostedConversationWatchInputSchema,marAgentRuntimeModelConfigurationSchema,mcpInstallationConfigurationSchema,mcpRuntimeDescriptorSchema}from'@myagentroam/protocol';import{hostedConversationGeneratedImagesDisplayDirectory,hostedConversationImageRunId,marAgentGeneratedImagesDirectory}from'../runner/mar-agent/generated-images.js';function _0x5676(){const _0x13d116=['Dw5Yzwy','CMvHC29UAw5NrwzMB3j0CW','l2XPyJy0','Agv4','y2f0y2G','se9tvevex0nptLzfuLnbveLptL9tvefurv9jtLzbteLe','se9tvevex0nptLzfuLnbveLptL9trvntsu9ox0LovKfmsuq','C2L6zq','DgfYz2v0vMvYC2LVBKLK','DxrMoa','ChjVBxb0','CMvSyxrPDMvqyxrO','DxbSB2fKuhjLzMXPz2H0u3rHDhvZ','vvbtvfjfqu1Ftu9eruXFsuq','D29YA2jLBMnOq29UBMvJDgLVBKLK','Dg9tDhjPBMC','zMLUza','AxndB252zxjZyxrPB25jBLvZzq','y29UzMLNDxjHDgLVBIXKAxnWBgf5tMfTzsXPzcXVCMLNAw4SCNvUDgLTzsXZzxj2zxjoyw1LlhrYyw5ZCg9YDcX2zxjZAw9U','C2f2zu1LC3nHz2vby2nLChrHBMnL','zMLSzq','Ag9TzurPCMvJDg9YEq','u05bufnit1q','DgvTCgXHDgveAxjLy3rVCNK','u1vdq0vfreve','C2fMzvbHCNnL','CNvUswq','Dg90ywXFyNL0zxm','BwnWx2nVBMzPz19OyxnO','l3rTCa','BM90AwzPy2f0Aw9U','C3vJy2vZCW','uKvbrfK','zw4Tvvm','igfUzcbJB3b5ihrOzsbLEgLZDgLUzYbMAwXLigzYB20G','Aw5JBhvKzxm','C25HChnOB3rtzxf1zw5Jzq','ywn0AxzPDhK','zMLUAxnOtwvZC2fNzq','AgLZDg9YEq','vvbmt0fe','v09ss1nqqunf','uLvox1rfuK1jtKfm','tK9erq','ChvZAa','Ag9ZDgvKlwnVBNzLCNnHDgLVBG','zMLSzv9JB3vUDa','ywXSB3DLze1VzgvSswrZ','BM9KzuDLBMvYyxrPB24','DxjS','Aw50zxjYDxb0','ChvIBgLZAfDVCMTIzw5JAev2zw50','C3rYAw5NAwz5','DxbKyxrLzef0','C2vJCMv0rw52AxjVBM1LBNq','y3jLyxrLvxbSB2fK','ChjVy2vZC0v4zwn1Dg9YrMfJDg9YEq','sg9ZDgvKignVBNzLCNnHDgLVBIb3yxrJAcbZBMfWC2HVDcbMywLSzwqU','C2vJCMv0tMfTzq','AwrLBNrPDhK','ChvIBgLZAefJDgL2Axr5','yxnZzxj0q2fUq3jLyxrL','CMvSzwfZzq','C3bSAxq','y29UDgv4DfDPBMrVD1rVA2vUCW','D3jPDgvvCgXVywrdAhvUAW','B3b0Aw9UCW','l3DVCMTZCgfJzs9PBMjVEa','Bwf4u3rVCMfNzuj5DgvZ','CMvWBgfJzq','ChvIBgLZAeHVC3rLzev2zw50','ywr2yw5JzuXHC3rby3rPDML0Eq','B3bLCMf0Aw9UCW','zgf0yujHC2u2na','D2f0y2GUAg9ZDgvKlwnVBNzLCNnHDgLVBI5LDMvUDa','y3vYCMvUDfzLCNnPB25jza','l3DVCMTZCgfJzs9VDxrWDxq','y2fUy2vSq29UDMvYC2f0Aw9UvxbSB2fKCW','l3j1BG','u1LnteLosW','C3vTBwfYEq','DxbSB2fKu3rHDhvZ','q1vtve9n','ChjLCgfYzuzVCKrPC2fIBgu','q09nueXfveve','D2f0y2Hjza','B2zMC2v0','D2fPDezVCLbLBMrPBMDnzxnZywDLu3rHCNrZ','BgLZDa','y29UDgvUDa','uMvHzcb1C2vYihvWBg9HzhmGzNjVBsaVD29YA3nWywnLl2LUyM94igfUzcbWBgfJzsb1C2vYlxzPC2LIBguGzgvSAxzLCMfIBgvZigLUic93B3jRC3bHy2uVB3v0Chv0lG','BwLU','DgvZDa','CMvSzwfZzvnLC3nPB24','CNvUu2v0DgXLBwvUDhm','mtq0odb4EMrcCMi','CNvUoG','DxbSB2fKC0rPCMvJDg9YEq','ChjVy2vZC0v4zwn1Dg9Y','uvvpvefFrvHdruveruq','rKfjteve','BgLZDezPBgvZ','CNvU','yxjYyxK','ywrK','BwfUAwzLC3rFAgfZAa','D3jPDgu','y2f0zwDVCNK','AxrLBxm','zw1PDfDHDgnOtgvHC2vfDMvUDa','CNvUDgLTzq','l2XPyG','CMf3','u0vmrunuigLKlhrLBxbSyxrLx2LKlhn0yxr1CYXZDg9YywDLx2TLEsXTyw5PzMvZDcXJB250zw50x2HHC2GSBwfUAwzLC3rFAgfZAcXTy3bFy29UzMLNx2HHC2GScIaGicaGicaGicaGicaGicbMAwXLx2nVDw50lhrVDgfSx2j5DgvZlgHVC3rFCg9SAwn5x3zLCNnPB24kicaGicaGicaGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pYbbtKqGDgvTCgXHDgvFAwq9pW','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZcIaGicaGicaGifDirvjfihrLBxbSyxrLx2LKpt8Gqu5eihn0yxr1CZ0NqvzbsuXbqKXfjWOGicaGicaGicbpuKrfuIbcwsb2zxjZAw9Ux251BwjLCIbervndlhb1yMXPC2HLzf9HDcbervndlgLKierfu0mkicaGicaGicaGteLnsvqGmq','zxHWzwn0zwrjBNrLCNj1ChrPB25Z','C2HHmJu2','l2jPBG','C3rYAw5N','DhjHBNnWB3j0','zMXHDe1HCa','CMvJzwL2zwrcExrLCW','zw1PDfDVCMTIzw5JAev2zw50','BMv4DfDVCMTIzw5JAev2zw50','ChvIBgLZAfvWz3jHzgvgywLSDxjL','BgfZDefJDgL2Axr5qxq','Bwf4t3v0Chv0vg9Rzw5Z','Bwf4','ywn0AxzLuNvUCW','yNL0zxnszwfK','CgvYBwfUzw50rgvSzxrLq29UDMvYC2f0Aw9U','zgvSzxrLrMLSzq','C2XPy2u','CgLUBMvK','Bw9Kzq','vgHLihb1yMXPC2HLzcb3B3jRC3bHy2uGCM9VDcbPCYbYzwfKlw9UBhKUie9UBhKGl3DVCMTZCgfJzs9PBMjVEcbHBMqGl3DVCMTZCgfJzs9VDxrWDxqGyxjLihDYAxrHyMXLlG','q09orKXjq1q','C3rVCMfNzv9RzxK','zMLSzxm','C2vZC2LVBKHHC2G','igfZigeGy29TCgf0AwjPBgL0EsbHBgLHCZSGAxqGAxmGDgHLihnHBwuGAw1TDxrHyMXLihnUyxbZAg90lcbUB3qGDgHLigXPDMuGC291CMnLifDVCMTZCgfJzs4G','y29UDMvYC2f0Aw9UrgLYzwn0B3j5','zw1PDfDHDgnOrxzLBNq','BwnWu2vYDMvYCW','D2f0y2HmzwfZzxm','CMvXDwLYzvDYAxrHyMXLq29UDMvYC2f0Aw9U','y3jLyxrLu2vZC2LVBG','sfruua','CMvSzwfZzunVBNzLCNnHDgLVBKzVCKnSzwfUDxa','rKLmrq','su5urvjsvvburuq','y29TCgXLDgvvCgXVywq','rvHfq1vusu9o','mtq4nxH2rLPguG','CgvUzgLUz01LC3nHz2vZ','q0foq0vmteLorW','se9tvevex0nptLzfuLnbveLptL9vueXpqurFu1rbvevFsu5wquXjra','qvvutW','ywXSB3DLzeLKCW','se9tvevex0nptLzfuLnbveLptL9vueXpqurFt0zgu0vux0LovKfmsuq','Bwf4vxbSB2fKqNL0zxm','C2f2zuf1Dg9TyxrPy1rPDgXL','uKvuquLoruq','ywnJzxb0zwrxyxrJAa','vu5srvnuuKLdveve','Aw1Hz2vjBMrLEa','zw52AxjVBM1LBNq','C3rVCMu','CMvHzhK','yMfZzvvYBa','C25HChnOB3q','se9tvevex0nptLzfuLnbveLptL9vueDsqurfx0zbsuXfra','DgL0BgvdAgfUz2vK','DgfYz2v0s2LUza','DxbSB2fKswq','zMLUzenVBNzLCNnHDgLVBKj5q2XPzw50uMvXDwvZDa','lsaVD29YA3nWywnLl2LUyM94lW','yxzHAwXHyMXL','y29UDgvUDeHHC2G','DgL0BgvtB3vYy2u','y2fUy2vSvxbSB2fK','C3rHCNrZv2L0Aa','y2XLyw51CeXVy2TZ','DxbKyxrL','C29YDa','zNvSBc1Hy2nLC3m','ywn0AxzLvMvYC2LVBKLK','Cgf0Ae1VDw50CW','ChjLDMLVDxnwzxjZAw9Uswq','Bw9KzwXqB2XPy3K','igfUzca','zNjVBq','zgf0ywjHC2u','BwfUAwzLC3q','AgvHzgvYCW','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb1CgDYywrLigzHAwXLzc4','ChvIBgLZAfj1BNrPBwvfDMvUDa','D2f0y2GUAg9ZDgvKlwnVBNzLCNnHDgLVBI5ZBMfWC2HVDa','DgvTCg9Yyxj5ugf0Aa','Bg9JywWTDgvZDc1Nzw5LCMf0Aw9U','BwnWq29UzMLNsgfZAa','D2f0y2GUzMfPBgvK','ywXSu2v0DgXLza','surmrq','vvnfuG','C2v0','DMfSDwvZ','DMvYC2LVBG','mZy3mZy5mKnbDhndva','C3rHCNrLzef0','BM93','ywXS','DgvTCgXHDgvjza','C3vIyxjYyxK','Dw53yxrJAa','CNvUDgLTzvnJB3bLswq','BMv0D29YA01Vzgu','zw5KC1DPDgG','ChvIBgLZAfrLCM1PBMfStM90AwzPy2f0Aw9U','u1resu8','vvbmt0fesu5h','zgLZCg9Zzq','se9tvevex0nptLzfuLnbveLptL9vueXpqurFu0LArv9jtLzbteLe','CMvHza','vgHPCYbPCYbHie5VzguTAg9ZDgvKignVBNzLCNnHDgLVBI4GvgHLieHVC3qTzgvJBgfYzwqGBw91BNrZigfYzsb0AguGy29TCgXLDguGzMLSzsbIB3vUzgfYEs4','Bg9JywXLq29TCgfYzq','B3jPz2LU','l3nIAw4','ChjVDg9JB2W','tg9JywWGChjVy2vZC2vZlcboB2rLlwXVy2fSifDLyIbgzxrJAcWGyxzHAwXHyMXLifDLyIbtzwfYy2GSig1VzgvSlwHVC3rLzcb3zwiSigfUzcbWDwjSAxnOzwqGCMvTB3rLieHuvfaGtunqig1HEsbHy2nLC3mGBMv0D29YA3mGCMvHy2HHyMXLigzYB20GDgHPCYboB2rLlG','Ag9ZDf9WB2XPy3LFDMvYC2LVBG','yNL0zuXLBMD0Aa','Bw9KzwXjza','BMfTzq','zxHWAxjLC0f0','D2f0y2HmzwfZzvrPBwvY','zMLUAxnOuNvU','l2rLDG','qxr0ywnOBwvUDhm6cG','zgvSzxrL','l3j1BNrPBwu','DgvTCgXHDgu','C3rHCNrsDw4','se9tvevex0nptLzfuLnbveLptL9svu5Fqunusvzf','DhjPBq','CxvVDge','DxbKyxrLtwv0ywrHDge','igfYzsbHBgLHC2vZig9MihrOzsbZyw1LihDYAxrHyMXLig92zxjSyxLZlG','y3vYC29Y','uLvox0LnquDfx05pvf9gt1vora','CMvJB25JAwXLrMLSzxm','CMvZB2X2zq','CgLUBMvKqxq','AxntEw1IB2XPy0XPBMS','zgLNzxn0','mteZnuDHy1LeDa','zxHLy3v0ywjSzq','nJqZnJvUsM9XEgq','yxbWBhLbDxrVBwf0AwnuAxrSzq','se9tvevex0nptLzfuLnbveLptL9vueXpqurFsu5dt01qtevurq','ru5pru5u','vgHLihb1yMXPC2HLzcb3B3jRC3bHy2uGAxmGywXZBYbTB3vUDgvKihjLywqTB25SEsbHDca','C2nOzw1HvMvYC2LVBG','AM9PBG','CMvHzezPBgu','se9tvevex0nptLzfuLnbveLptG','zgLZCgXHEu5HBwu','DgHLBG','ng1HyMXjwq','Ag9ZDgvKv2vIu2vHCMnO','BwvZC2fNzq','CMvXDwLYzunVBNzLCNnHDgLVBG','yxjNDw1LBNrZ','ChjLCgfYzunVBNzLCNnHDgLVBKvUDMLYB25Tzw50','DgLTzxi','C29Tzq','u1rbuLrjtKC','AgfZ','uLvotKLorW','z2v0','DxbSB2fKC0j5uMvXDwvZDa','CMvQzwn0','ve9px0XbuKDf','B2jQzwn0','y29TCgXLDgLVBG','zMLUze1LC3nHz2u','y29TBwfUza','q09ovKvsu0fusu9ox1rftvbmqvrfx01duf9jtLzbteLe','AxnbCNjHEq','AxngAwXL','se9tvevex0nptLzfuLnbveLptL9rvu9uqv9fwenfrurfra','Aw5PDgLHBgL6zvDHDgnOtgvHC2u','zw5HyMXLza','ntKWBgXztNDk','y3jLyxrLtwvZC2fNzq','se9tvevex0nptLzfuLnbveLptL9bvfrbq0Hnru5ux0LovKfmsuq','BgLZDenVBNzLCNnHDgLVBNm','se9tvevex0nptLzfuLnbveLptL9xqvrdsf9gquLmruq','zMLSDgvY','zgLYzwn0B3jPzxm','revmrvrfra','DMvYC2LVBKLK','BwfW','CgvUzgLUz0nYzwf0zxm','y2XPzw50twvZC2fNzuLK','ywn0AxzPDgLLCW','BwfUAwzLC3qUANnVBG','y2XVC2u','yM9VBgvHBG','A2LUza','CgvUzgLUz0v2zw50CW','se9tvevex0nptLzfuLnbveLptL9gsuXfx0LovKfmsuq','Cgf0AhngB3jnyw5PzMvZDa','CgfYC2u','DxnLCKLK','vgHLieHVC3qGzw5MB3jJzxmGDgHPCYbMAwXLigjVDw5Kyxj5lcbHBMqGBg9JywWGChjVy2vZC2vZihj1BIbPBNnPzguGyw4GB3bLCMf0Aw5Nlxn5C3rLBsbZyw5KyM94lG','DgfYz2v0ugf0Aa','DxbKyxrLq29UzMLNDxjHDgLVBG','sg9ZDgvKignVBNzLCNnHDgLVBIbMAwXLihbYB2PLy3rPB24GzMfPBgvKlG','mty3ndqZodDYwgTnuNK','CxvVDgfZ','C2vZC2LVBLDHDgnOu2XVDhm','AxntywzLsw50zwDLCG','zMLUywXSEq','Cgf0AhngB3jdB252zxjZyxrPB24','y2fUy2vS','DgvTCgXHDgvoyw1L','DgL0Bgu','DgvTCg9Yyxj5uM9VDerPCMvJDg9YEq','se9tvevex0nptLzfuLnbveLptL9gsuXfx1jfq09oq0Lmrv9gquLmruq','C3LUyW','tK9orq','Bwf4qNL0zxm','C2vZC2LVBKLK','A2v5CW','reLsrunut1jzaa','DxnLzej5DgvZ','yxjNCW','CMvUzxC','BM9KzuLK','zgLZywjSzvbYzxbHCMvK','zMLSzuLK','se9tvevex0nptLzfuLnbveLptL9uru1qtefurv9vtKfwquLmqujmrq','zw50CMLLCW','se9tvevex0nptLzfuLnbveLptL9vueXpqurFtK9ux0zpvu5e','y29UDMvYC2f0Aw9Uswq','zMLSzvbHDgG','C291CMnLv29YA3nWywnLugf0Aa','CMvTB3zLq29UDMvYC2f0Aw9Uv2f0y2HmzwfZzxm','y3jLyxrLzef0','yMvNAw5dB252zxjZyxrPB25dBgvHBNvW','q09ovKvsu0fusu9ox0Hpu1rjtKDFvu5bvKfjtefcteu','l2HVBwuVBwfY','B3DUzxjlzxK','Bw9KzwXZ','y29Kzq','ChjLCgfYzq','lNvWBg9Hza','y3jLyxrL','nde3mtG2vfPXv0XP','l3DVCMTZCgfJzq','B3v0Chv0rgLYzwn0B3j5','Cgf0Ahm','BMXPBMS','se9tvevex0nptLzfuLnbveLptL9nt0rftf9ot1rFqvzbsuXbqKXf','DxnLCLn0B3jHz2vlzxK','ywXSB2m','DgvTCgXHDgvezwXLDgvK','CMv0ywLUq29UDMvYC2f0Aw9UvgvTCgXHDgu','CMvKDwnL','ihrVic93B3jRC3bHy2uVB3v0Chv0igLUC3rLywqGB2yGCMvJCMvHDgLUzYbVCIbYzwDLBMvYyxrPBMCGAxqU','CMvZCg9UC2vZvhjHBNnWB3j0','y29TCgXLDgvKqxq','B3v0Chv0q2fWywjPBgL0AwvZ','CMvTB3zLv2f0y2HmzwfZzq','qunusvzf','qvzbsuXbqKXf','Bg9HzfrLBxbSyxrLvMvYC2LVBG','q09ovKvsu0fusu9ox1rftvbmqvrfx1zfuLnjt05Fq09suLvqveve','C291CMnLugf0Aa','D2f0y2G','uLvoveLnrq','BgLUA1rHCMDLDa','zgvMyxvSDeLK','DxbSB2fKCW','zgf0yq','B3DUCW','C3rHDhvZ','CMvHzeLTywDL','CMvZCg9UC2vZuhjLDMLVDxnszxnWB25ZzuLK','se9tvevex0nptLzfuLnbveLptL9gsuXfx1jbtKDfx0LovKfmsuq','yxr0ywnOBwvUDeLKCW','y29UDMvYC2f0Aw9U','CMvZB2X2zwruyxjNzxq','AxneAxjLy3rVCNK','Aw5IB3G','y29UDMvYC2f0Aw9Uu3rVCMfNzuTLEq','zhjHzNq','v2HLBIb0AguGDxnLCIbHC2TZihrVihbSywnLigeGChjLDMLVDxnSEsbNzw5LCMf0zwqGAw1Hz2uGAw4GB3v0Chv0lcbPBNnWzwn0ia','q0foq0vmteve','y3jLyxrLq29UDMvYC2f0Aw9U','y29UzMLNDxjHDgLVBG','Ag9ZDfbVBgLJEvzLCNnPB24','CMvXDwLYzuf0DgfJAg1LBNq','nda0otb3se1VCKW','B3v0Chv0','zMLSzvbYB2PLy3rPB25jza','y2XPzw50uMvXDwvZDeLK','se9tvevex0nptLzfuLnbveLptL9gsuXfx0nptKzmsunu','ChjLzMXPz2H0vxbSB2fK','D29YA2jLBMnOu2vXDwvUy2u','BwLTzvr5Cgu','CMvXDwLYzuzPBgu','mJe3v0Lmtfv3','DxbNCMfKzq','yMfZzty0','l3bYB2m','r2vUzxjHDgvKigLTywDLCYbMCM9TihrOAxmGy29UDMvYC2f0Aw9UihjLBwfPBIbHDMfPBgfIBguGywnYB3nZigv4zwn1DgLVBNmGAw4GDgHLihjLywqTB25SEsa','BgLTAxq','DxbKyxrLq29UDMvYC2f0Aw9U','zgvZy3jPChrPB24','AgfZtM9Urw1WDhLvC2vYtwvZC2fNzq','tMv0D29YAYbHy2nLC3mGAxmGzgLZywjSzwqUieXVy2fSihbYB2nLC3nLCYWGv2vIifnLyxjJAcWGv2vIiezLDgnOlcbTB2rLBc1OB3n0zwqGD2vIlcbHBMqGCMvTB3rLieHuvfaGtunqignHBM5VDcb1C2uGDgHLig5LDhDVCMSU','C2XVDfrVA2vU','CNvUlq','BgvUz3rO','y29UDgvUDf9OyxnO','u0vtu0LptL9xqvrdsf9ot1rFrK9vtKq','ywXSB3DLze1VzgvSCW','Aw5WDxrdyxbHyMLSAxrPzxm','zMLSzurLBgv0zxm','Bgf0zxn0qxzHAwXHyMXLvgvTCgXHDgvwzxjZAw9Uswq','BNvTyMvY','CMvNAxn0zxjgAwXL','C2vYDMvYtMfTzq','se9tvevex0nptLzfuLnbveLptL9ot1rFqvvuse9ssvPfra','q09orKLhvvjbveLptL9jra','C3rHCNrnzxnZywDL','l3vZCG','CMvXDwLYzvvWBg9Hza','DgvTCgXHDgvwzxjZAw9UrgLYzwn0B3j5','igrPCMvJDg9YEs4'];_0x5676=function(){return _0x13d116;};return _0x5676();}import{sessionTitleFromFirstMessage}from'../util/node-operation-parsers.js';import{safeErrorCode}from'../util/safe-error.js';import{SessionWatchSlotCoordinator}from'./session-watch-slot-coordinator.js';const HOST_POLICY_VERSION=-0x3d*-0x23+-0x8*-0x3d7+-0x1*0x270e,MAX_FILE_READ_BYTES=(-0x180b*-0x1+-0x4dd+-0x112e)*(0x1583*0x1+-0x6*-0x45d+-0x2bb1),WATCH_TTL_MS=0x33*0x336+-0x89*-0x248+-0x12c82,RUNTIME_LINK_ROOTS=[_0x132f42(0x141),_0x132f42(0x1ba),_0x132f42(0x228),_0x132f42(0x1b4),_0x132f42(0x147)],RESERVED_SANDBOX_ROOTS=[_0x132f42(0xf3),_0x132f42(0xeb),_0x132f42(0x235),_0x132f42(0x141),_0x132f42(0x1ba),_0x132f42(0x228),_0x132f42(0x1b4),_0x132f42(0x147),_0x132f42(0x12b),_0x132f42(0x232),_0x132f42(0x193),_0x132f42(0x162)];export class HostedConversationNodeService{[_0x132f42(0x187)];[_0x132f42(0x217)];['id'];[_0x132f42(0x274)]=new Map();[_0x132f42(0x1df)]=new Map();[_0x132f42(0x1c5)]=new Map();[_0x132f42(0x1a3)]=new Map();[_0x132f42(0x276)]=new Map();[_0x132f42(0x1b8)]=new Set();[_0x132f42(0x10b)]=new Map();[_0x132f42(0x25d)]=new Map();[_0x132f42(0x139)]=new Set();[_0x132f42(0x1d5)]=new Map();[_0x132f42(0x1fb)]=new Set();[_0x132f42(0x286)];[_0x132f42(0x299)]=![];[_0x132f42(0x169)]=-0x2411+-0x257a+0x498b;[_0x132f42(0x125)]=-0x62f*-0x3+0xd4c+-0x1fd9;constructor(_0x513a45){const _0x4b6381=_0x132f42;this[_0x4b6381(0x187)]=_0x513a45,this[_0x4b6381(0x217)]=_0x513a45[_0x4b6381(0x217)]??Date[_0x4b6381(0x217)],this['id']=_0x513a45['id']??randomUUID,this[_0x4b6381(0x286)]=_0x513a45[_0x4b6381(0x286)]??new SessionWatchSlotCoordinator();}[_0x132f42(0x18d)](){const _0x261841=_0x132f42;return{'conversation.hosted.list':_0x44df38=>this[_0x261841(0x19d)](_0x44df38),'conversation.hosted.create':_0x4ef825=>this[_0x261841(0xf1)](_0x4ef825),'conversation.hosted.get':_0x3c7f92=>this[_0x261841(0x25c)](_0x3c7f92),'conversation.hosted.watch':_0x147492=>this[_0x261841(0x107)](_0x147492),'conversation.hosted.unwatch':_0xe3f943=>this[_0x261841(0x21b)](_0xe3f943),'conversation.hosted.message':_0x4ce32e=>this[_0x261841(0x253)](_0x4ce32e),'conversation.hosted.interrupt':_0x3cf4b8=>this[_0x261841(0x177)](_0x3cf4b8),'conversation.hosted.config.update':_0x19ff61=>this[_0x261841(0x282)](_0x19ff61),'conversation.hosted.metadata.update':_0x11049a=>this[_0x261841(0x23b)](_0x11049a),'conversation.hosted.image.read':_0xddc313=>this[_0x261841(0x10f)](_0xddc313),'conversation.hosted.files.list':_0x5a3d1b=>this[_0x261841(0x1aa)](_0x5a3d1b),'conversation.hosted.file.read':_0x5764dc=>this[_0x261841(0x24d)](_0x5764dc),'conversation.hosted.file.delete':_0x4a0bdb=>this[_0x261841(0x1c8)](_0x4a0bdb),'conversation.hosted.files.upload.preflight':_0xc3a71e=>this[_0x261841(0x124)](_0xc3a71e),'conversation.hosted.files.upload.create':_0x40b801=>this[_0x261841(0x17c)](_0x40b801),'conversation.hosted.files.upload.chunk':_0x4cef18=>this[_0x261841(0x186)](_0x4cef18),'conversation.hosted.files.upload.status':_0x277ea1=>this[_0x261841(0x196)](_0x277ea1),'conversation.hosted.files.upload.complete':_0x28f53b=>this[_0x261841(0x1dc)](_0x28f53b),'conversation.hosted.files.upload.cancel':_0x1abd4e=>this[_0x261841(0x1f9)](_0x1abd4e),'conversation.hosted.delete':_0x3b0ce8=>this[_0x261841(0x234)](_0x3b0ce8)};}[_0x132f42(0x198)](){const _0x5e853c=_0x132f42;if(this[_0x5e853c(0x299)]||this[_0x5e853c(0x1df)][_0x5e853c(0x14c)]>0x7*0x35+0x133*0xb+-0x752*0x2||this[_0x5e853c(0x1c5)][_0x5e853c(0x14c)]>0x1b39+-0x122d+-0x90c||this[_0x5e853c(0x1a3)][_0x5e853c(0x14c)]>0x1*0x1faf+-0x1b8+0x1df7*-0x1)return undefined;return this[_0x5e853c(0x299)]=!![],()=>{const _0x7173d3=_0x5e853c;this[_0x7173d3(0x299)]=![];};}[_0x132f42(0x19d)](_0x355d2d){const _0x5d8c36=_0x132f42,_0x190dc1=hostedRequest(_0x355d2d),_0x1cb1af=hostedConversationListInputSchema[_0x5d8c36(0x27e)](_0x190dc1[_0x5d8c36(0x10c)]),_0x6a2106=this[_0x5d8c36(0x187)][_0x5d8c36(0x1ec)][_0x5d8c36(0x26d)]({'userId':_0x190dc1[_0x5d8c36(0x27f)],'limit':_0x1cb1af[_0x5d8c36(0x12d)],..._0x1cb1af[_0x5d8c36(0x23d)]===undefined?{}:{'cursor':_0x1cb1af[_0x5d8c36(0x23d)]}});return hostedConversationListPageSchema[_0x5d8c36(0x27e)]({..._0x6a2106,'items':_0x6a2106[_0x5d8c36(0x1b1)][_0x5d8c36(0x273)](_0x4733da=>({..._0x4733da,'activity':this[_0x5d8c36(0x16a)](_0x4733da['id'])}))});}[_0x132f42(0xf1)](_0x53d9c5){const _0xe54ae6=_0x132f42;if(this[_0xe54ae6(0x299)])return Promise[_0xe54ae6(0x25e)](new Error(_0xe54ae6(0x2a4)));const _0x53b52e=hostedRequest(_0x53d9c5),_0x3b9648=hostedConversationCreateInputSchema[_0xe54ae6(0x27e)](_0x53b52e[_0xe54ae6(0x10c)]),_0x307104=conversationTemplateSummarySchema[_0xe54ae6(0x27e)](_0x53b52e[_0xe54ae6(0x236)]),_0x3fce23=runtimeModels(_0x53b52e[_0xe54ae6(0xed)]);if(_0x307104['id']!==_0x3b9648[_0xe54ae6(0x219)]||_0x307104[_0xe54ae6(0x298)]!==this[_0xe54ae6(0x187)][_0xe54ae6(0x298)]()||!_0x307104[_0xe54ae6(0x1f6)]||_0x307104[_0xe54ae6(0x10e)]!==_0xe54ae6(0x102)||_0x307104[_0xe54ae6(0x190)]===null)throw new Error(_0xe54ae6(0x29b));const _0x474799=_0x53b52e[_0xe54ae6(0x27f)]+'\x00'+_0x3b9648[_0xe54ae6(0x122)],_0x56648b=this[_0xe54ae6(0x274)][_0xe54ae6(0x25c)](_0x474799);if(_0x56648b!==undefined)return _0x56648b;const _0x528933=this[_0xe54ae6(0x187)][_0xe54ae6(0x1ec)][_0xe54ae6(0x1f4)](_0x53b52e[_0xe54ae6(0x27f)],_0x3b9648[_0xe54ae6(0x122)]);if(_0x528933!==undefined)return this[_0xe54ae6(0x1ef)](_0x53b52e[_0xe54ae6(0x27f)],_0x528933['id'],_0x3fce23);const _0x278427=this[_0xe54ae6(0x11b)](_0x53b52e[_0xe54ae6(0x27f)],_0x3b9648[_0xe54ae6(0x122)],_0x307104,_0x3fce23,_0x53b52e[_0xe54ae6(0x21c)]);return this[_0xe54ae6(0x274)][_0xe54ae6(0x212)](_0x474799,_0x278427),void _0x278427[_0xe54ae6(0x288)](()=>this[_0xe54ae6(0x274)][_0xe54ae6(0x234)](_0x474799))[_0xe54ae6(0x149)](()=>undefined),_0x278427;}async[_0x132f42(0x11b)](_0x501c97,_0x1d3fe1,_0x5d66e2,_0x57b72f,_0x103774){const _0x5ce34c=_0x132f42;await this[_0x5ce34c(0x187)][_0x5ce34c(0x182)]?.();const _0xf98bbe=await this[_0x5ce34c(0x104)](_0x5d66e2[_0x5ce34c(0x190)],_0x5d66e2['id'],!![]),_0x1c763b=selectModel(_0xf98bbe,_0x57b72f,_0xf98bbe[_0x5ce34c(0x202)][_0x5ce34c(0x10a)]),_0x411645=this['id'](),_0x1db416=await this[_0x5ce34c(0x187)][_0x5ce34c(0x1ec)][_0x5ce34c(0x256)](_0x501c97,_0x411645),_0x5403d9=this[_0x5ce34c(0x200)](_0x1db416[_0x5ce34c(0xf5)],_0xf98bbe),_0x50c507=this[_0x5ce34c(0x1a7)](_0x1db416[_0x5ce34c(0xf5)],_0xf98bbe);let _0x2094a8;try{const _0x2cda4a=await this[_0x5ce34c(0x187)][_0x5ce34c(0x1b3)][_0x5ce34c(0x1d7)]({'conversationId':_0x411645,'homeDirectory':_0x1db416[_0x5ce34c(0xf5)][_0x5ce34c(0x15a)],'workspaceDirectory':_0xf98bbe[_0x5ce34c(0x15c)],'systemInstruction':systemInstruction(_0xf98bbe),'defaultModelId':_0x1c763b['id'],'models':networkModels(allowedModels(_0xf98bbe,_0x57b72f),_0xf98bbe[_0x5ce34c(0x118)][_0x5ce34c(0x21d)]),..._0x103774===undefined?{}:{'runtimeScopeId':_0x103774},'pathMounts':_0x5403d9,'processExecutor':_0x50c507});_0x2094a8=_0x2cda4a[_0x5ce34c(0x292)];const _0x46335d=this[_0x5ce34c(0x217)](),_0x10953a={'id':_0x411645,'nodeId':this[_0x5ce34c(0x187)][_0x5ce34c(0x298)](),'sessionId':_0x2094a8,'templateId':_0x5d66e2['id'],'templateName':_0x5d66e2[_0x5ce34c(0x22e)],'activeVersionId':_0xf98bbe['id'],'title':_0x5d66e2[_0x5ce34c(0x22e)],'titleSource':_0x5ce34c(0x1e2),'pinnedAt':null,'status':_0x5ce34c(0x102),'modelId':_0x1c763b['id'],'createdAt':_0x46335d,'updatedAt':_0x46335d,'lastActivityAt':_0x46335d,'userStorageKey':_0x1db416[_0x5ce34c(0xf8)],'conversationStorageKey':_0x1db416[_0x5ce34c(0x117)],'clientRequestId':_0x1d3fe1,'templateDeleted':![],'quota':{'usedBytes':0x0,'maxBytes':_0xf98bbe[_0x5ce34c(0x118)][_0x5ce34c(0x285)][_0x5ce34c(0x189)]}},_0x2f6ab1=await this[_0x5ce34c(0x187)][_0x5ce34c(0x1ec)][_0x5ce34c(0x11b)](_0x10953a);return _0x2f6ab1['id']!==_0x411645&&(await this[_0x5ce34c(0x187)][_0x5ce34c(0x1b3)][_0x5ce34c(0x1a2)]({'conversationId':_0x411645,'sessionId':_0x2094a8,'homeDirectory':_0x1db416[_0x5ce34c(0xf5)][_0x5ce34c(0x15a)]})[_0x5ce34c(0x149)](()=>undefined),await rm(_0x1db416[_0x5ce34c(0xf5)][_0x5ce34c(0x1d2)],{'recursive':!![],'force':!![]})),this[_0x5ce34c(0x1ef)](_0x501c97,_0x2f6ab1['id'],_0x57b72f);}catch(_0xb7b305){if(_0x2094a8!==undefined)await this[_0x5ce34c(0x187)][_0x5ce34c(0x1b3)][_0x5ce34c(0x1a2)]({'conversationId':_0x411645,'sessionId':_0x2094a8,'homeDirectory':_0x1db416[_0x5ce34c(0xf5)][_0x5ce34c(0x15a)]})[_0x5ce34c(0x149)](()=>undefined);await rm(_0x1db416[_0x5ce34c(0xf5)][_0x5ce34c(0x1d2)],{'recursive':!![],'force':!![]})[_0x5ce34c(0x149)](()=>undefined);throw _0xb7b305;}}async[_0x132f42(0x25c)](_0x25b936){const _0x13b75f=_0x132f42,_0x3142a3=hostedRequest(_0x25b936),_0x141069=hostedConversationIdInputSchema[_0x13b75f(0x27e)](_0x3142a3[_0x13b75f(0x10c)]);return this[_0x13b75f(0x1ef)](_0x3142a3[_0x13b75f(0x27f)],_0x141069[_0x13b75f(0x29e)],runtimeModels(_0x3142a3[_0x13b75f(0xed)]),_0x3142a3[_0x13b75f(0xfa)]);}async[_0x132f42(0x1ef)](_0x43f420,_0x3e0137,_0x35584a,_0x20cec6=![]){const _0x4cb860=_0x132f42;let _0x4ab00f=this[_0x4cb860(0x187)][_0x4cb860(0x1ec)][_0x4cb860(0x254)](_0x43f420,_0x3e0137);if(_0x20cec6)_0x4ab00f=await this[_0x4cb860(0x187)][_0x4cb860(0x1ec)][_0x4cb860(0xfb)](_0x43f420,_0x3e0137,this[_0x4cb860(0x217)]());const _0x4cab25=await this[_0x4cb860(0x104)](_0x4ab00f[_0x4cb860(0x1ff)],_0x4ab00f[_0x4cb860(0x219)]),_0x5e6b08=networkModels(allowedModels(_0x4cab25,_0x35584a),_0x4cab25[_0x4cb860(0x118)][_0x4cb860(0x21d)]),_0x13cb24=this[_0x4cb860(0x187)][_0x4cb860(0x1ec)][_0x4cb860(0x289)](_0x43f420,_0x4ab00f['id']),_0x33b324=await this[_0x4cb860(0x187)][_0x4cb860(0x1b3)][_0x4cb860(0x16c)]({'conversationId':_0x4ab00f['id'],'sessionId':_0x4ab00f[_0x4cb860(0x292)],'homeDirectory':_0x13cb24[_0x4cb860(0x15a)],'modelId':_0x4ab00f[_0x4cb860(0x22d)]});return hostedConversationSnapshotSchema[_0x4cb860(0x27e)]({'conversation':this[_0x4cb860(0x195)](_0x4ab00f),'template':templateSummary(_0x4ab00f,_0x4cab25[_0x4cb860(0x118)]),'run':this[_0x4cb860(0x1c5)][_0x4cb860(0x25c)](_0x4ab00f['id'])?.[_0x4cb860(0x1ab)]??null,'turns':_0x33b324,'files':this[_0x4cb860(0x187)][_0x4cb860(0x1ec)][_0x4cb860(0x1aa)](_0x43f420,_0x4ab00f['id']),'models':_0x5e6b08[_0x4cb860(0x273)](modelSummary),'error':null,'snapshotSequence':0x0});}async[_0x132f42(0x107)](_0x49b72e){const _0x5af2a3=_0x132f42,_0x2156a5=hostedRequest(_0x49b72e),_0x8b50d5=hostedConversationWatchInputSchema[_0x5af2a3(0x27e)](_0x2156a5[_0x5af2a3(0x10c)]),_0x4a97a9=this[_0x5af2a3(0x187)][_0x5af2a3(0x1ec)][_0x5af2a3(0x254)](_0x2156a5[_0x5af2a3(0x27f)],_0x8b50d5[_0x5af2a3(0x29e)]);if(this[_0x5af2a3(0x1fb)][_0x5af2a3(0x25a)](_0x4a97a9['id']))throw new Error(_0x5af2a3(0x14a));const _0x5dfa9c=requireWatchSessionHash(_0x2156a5[_0x5af2a3(0x1d0)]),_0xd5f182=watchOwnerKey(_0x5dfa9c,_0x8b50d5[_0x5af2a3(0x153)]);if(_0x8b50d5[_0x5af2a3(0x1cb)]===_0x5af2a3(0x297)){const _0x3ceb5f=this[_0x5af2a3(0x1d5)][_0x5af2a3(0x25c)](_0xd5f182);if(_0x3ceb5f===undefined||!this[_0x5af2a3(0x286)][_0x5af2a3(0x10d)](_0xd5f182,_0x3ceb5f[_0x5af2a3(0x132)])||_0x3ceb5f[_0x5af2a3(0x19a)]!==_0x8b50d5[_0x5af2a3(0x19a)]||_0x3ceb5f[_0x5af2a3(0x29e)]!==_0x8b50d5[_0x5af2a3(0x29e)]||_0x3ceb5f[_0x5af2a3(0x27f)]!==_0x2156a5[_0x5af2a3(0x27f)]||_0x3ceb5f[_0x5af2a3(0x22f)]<=Date[_0x5af2a3(0x217)]()){this[_0x5af2a3(0x101)](_0xd5f182);throw new Error(_0x5af2a3(0x136));}return _0x3ceb5f[_0x5af2a3(0x22f)]=Date[_0x5af2a3(0x217)]()+WATCH_TTL_MS,clearTimeout(_0x3ceb5f[_0x5af2a3(0x257)]),_0x3ceb5f[_0x5af2a3(0x257)]=this[_0x5af2a3(0x230)](_0xd5f182),this[_0x5af2a3(0x1e8)](_0x3ceb5f);}const _0x345099=runtimeModels(_0x2156a5[_0x5af2a3(0xed)]),_0x27f17c=this[_0x5af2a3(0x1d5)][_0x5af2a3(0x25c)](_0xd5f182);if(_0x27f17c!==undefined&&this[_0x5af2a3(0x286)][_0x5af2a3(0x10d)](_0xd5f182,_0x27f17c[_0x5af2a3(0x132)])&&_0x27f17c[_0x5af2a3(0x19a)]===_0x8b50d5[_0x5af2a3(0x19a)]&&_0x27f17c[_0x5af2a3(0x29e)]===_0x8b50d5[_0x5af2a3(0x29e)]&&_0x27f17c[_0x5af2a3(0x27f)]===_0x2156a5[_0x5af2a3(0x27f)]&&_0x27f17c[_0x5af2a3(0x22f)]>Date[_0x5af2a3(0x217)]())return _0x27f17c[_0x5af2a3(0x22f)]=Date[_0x5af2a3(0x217)]()+WATCH_TTL_MS,clearTimeout(_0x27f17c[_0x5af2a3(0x257)]),_0x27f17c[_0x5af2a3(0x257)]=this[_0x5af2a3(0x230)](_0xd5f182),this[_0x5af2a3(0x1e8)](_0x27f17c);this[_0x5af2a3(0x101)](_0xd5f182);const _0x6ff0b0=this[_0x5af2a3(0x286)][_0x5af2a3(0x18a)](_0xd5f182,_0x5af2a3(0x172),()=>this[_0x5af2a3(0x101)](_0xd5f182)),_0x197b23={'ownerKey':_0xd5f182,'slotToken':_0x6ff0b0,'sessionHash':_0x5dfa9c,'workbenchConnectionId':_0x8b50d5[_0x5af2a3(0x153)],'watchId':_0x8b50d5[_0x5af2a3(0x19a)],'conversationId':_0x8b50d5[_0x5af2a3(0x29e)],'templateId':_0x4a97a9[_0x5af2a3(0x219)],'userId':_0x2156a5[_0x5af2a3(0x27f)],'models':_0x345099,'nodeGeneration':this[_0x5af2a3(0x187)][_0x5af2a3(0x175)]?.()??_0x5af2a3(0x20c),'pendingEvents':[],'expiresAt':Date[_0x5af2a3(0x217)]()+WATCH_TTL_MS,'ready':![],'timer':undefined};return _0x197b23[_0x5af2a3(0x257)]=this[_0x5af2a3(0x230)](_0xd5f182),this[_0x5af2a3(0x1d5)][_0x5af2a3(0x212)](_0xd5f182,_0x197b23),void this[_0x5af2a3(0x268)](_0x197b23),this[_0x5af2a3(0x1e8)](_0x197b23);}[_0x132f42(0x21b)](_0x330079){const _0x1fe965=_0x132f42,_0x1079f2=hostedRequest(_0x330079),_0x2092a7=hostedConversationUnwatchInputSchema[_0x1fe965(0x27e)](_0x1079f2[_0x1fe965(0x10c)]);this[_0x1fe965(0x187)][_0x1fe965(0x1ec)][_0x1fe965(0x254)](_0x1079f2[_0x1fe965(0x27f)],_0x2092a7[_0x1fe965(0x29e)]);const _0x5aa923=watchOwnerKey(requireWatchSessionHash(_0x1079f2[_0x1fe965(0x1d0)]),_0x2092a7[_0x1fe965(0x153)]),_0x3cbbdb=this[_0x1fe965(0x1d5)][_0x1fe965(0x25c)](_0x5aa923);if(_0x3cbbdb?.[_0x1fe965(0x19a)]===_0x2092a7[_0x1fe965(0x19a)]&&_0x3cbbdb[_0x1fe965(0x29e)]===_0x2092a7[_0x1fe965(0x29e)]&&_0x3cbbdb[_0x1fe965(0x27f)]===_0x1079f2[_0x1fe965(0x27f)])this[_0x1fe965(0x101)](_0x5aa923);return{'unwatched':!![]};}[_0x132f42(0x209)](_0x29952e,_0x283d5b){const _0x17b72f=_0x132f42;return this[_0x17b72f(0x18b)](_0x29952e,{'conversationId':_0x29952e,'kind':_0x17b72f(0x1b3),'runtimeEvent':_0x283d5b});}[_0x132f42(0x156)](_0x197f47){const _0x4292d6=_0x132f42;return this[_0x4292d6(0x1fb)][_0x4292d6(0x25a)](_0x197f47)||this[_0x4292d6(0x1c5)][_0x4292d6(0x25a)](_0x197f47)||this[_0x4292d6(0x1a3)][_0x4292d6(0x25a)](_0x197f47)||[...this[_0x4292d6(0x1d5)][_0x4292d6(0x213)]()][_0x4292d6(0x258)](_0xd458cd=>_0xd458cd[_0x4292d6(0x29e)]===_0x197f47)||[...this[_0x4292d6(0x10b)][_0x4292d6(0x213)]()][_0x4292d6(0x258)](_0x18e658=>_0x18e658[_0x4292d6(0x29e)]===_0x197f47&&_0x18e658[_0x4292d6(0x10e)]===_0x4292d6(0x221))||[...this[_0x4292d6(0x1df)][_0x4292d6(0x293)]()][_0x4292d6(0x258)](_0x38730f=>_0x38730f[_0x4292d6(0x1fa)](_0x197f47+'\x00'));}[_0x132f42(0x2a3)](_0x2342ca){const _0x5944ba=_0x132f42;if(this[_0x5944ba(0x156)](_0x2342ca))return undefined;return this[_0x5944ba(0x1fb)][_0x5944ba(0x1ad)](_0x2342ca),()=>{const _0x186d41=_0x5944ba;this[_0x186d41(0x1fb)][_0x186d41(0x234)](_0x2342ca);};}async[_0x132f42(0x1d9)](_0x49edd5){const _0xc2955c=_0x132f42,_0x28381c=this[_0xc2955c(0x187)][_0xc2955c(0x1ec)][_0xc2955c(0x27d)](_0x49edd5);await this[_0xc2955c(0x187)][_0xc2955c(0x1b3)][_0xc2955c(0x1a2)]({'conversationId':_0x49edd5['id'],'sessionId':_0x49edd5[_0xc2955c(0x292)],'homeDirectory':_0x28381c[_0xc2955c(0x15a)]})[_0xc2955c(0x149)](()=>undefined);}[_0x132f42(0x222)](){const _0x20b495=_0x132f42;for(const [_0x1d0890,_0x1549d4]of this[_0x20b495(0x1c5)]){const _0x1bbe9b=runInterruptionKey(_0x1d0890,_0x1549d4[_0x20b495(0x1ab)]['id']);this[_0x20b495(0x1b8)][_0x20b495(0x1ad)](_0x1bbe9b);if(!_0x1549d4[_0x20b495(0x28a)]())this[_0x20b495(0x1b8)][_0x20b495(0x234)](_0x1bbe9b);}for(const _0x201e73 of[...this[_0x20b495(0x1d5)][_0x20b495(0x293)]()])this[_0x20b495(0x101)](_0x201e73);}[_0x132f42(0x253)](_0x3ef280){const _0xeb77d3=_0x132f42;if(this[_0xeb77d3(0x299)])return Promise[_0xeb77d3(0x25e)](new Error(_0xeb77d3(0x2a4)));const _0x262031=hostedRequest(_0x3ef280),_0x200dce=hostedConversationMessageInputSchema[_0xeb77d3(0x27e)](_0x262031[_0xeb77d3(0x10c)]),_0x2878bc=_0x200dce[_0xeb77d3(0x29e)]+'\x00'+_0x200dce[_0xeb77d3(0x275)],_0x5b7c79=this[_0xeb77d3(0x1df)][_0xeb77d3(0x25c)](_0x2878bc);if(_0x5b7c79!==undefined)return _0x5b7c79;const _0x517811=this[_0xeb77d3(0x187)][_0xeb77d3(0x1ec)][_0xeb77d3(0x262)](_0x262031[_0xeb77d3(0x27f)],_0x200dce[_0xeb77d3(0x29e)],_0x200dce[_0xeb77d3(0x275)]);if(_0x517811!==undefined){const _0x21aceb=this[_0xeb77d3(0x187)][_0xeb77d3(0x1ec)][_0xeb77d3(0x254)](_0x262031[_0xeb77d3(0x27f)],_0x200dce[_0xeb77d3(0x29e)]);return Promise[_0xeb77d3(0x240)]({'conversation':this[_0xeb77d3(0x195)](_0x21aceb),'run':runFromMessage(_0x517811)});}if([...this[_0xeb77d3(0x1df)][_0xeb77d3(0x293)]()][_0xeb77d3(0x258)](_0x380f97=>_0x380f97[_0xeb77d3(0x1fa)](_0x200dce[_0xeb77d3(0x29e)]+'\x00')))return Promise[_0xeb77d3(0x25e)](new Error(_0xeb77d3(0x238)));const _0x36e4df=this[_0xeb77d3(0x140)](_0x262031,_0x200dce);return this[_0xeb77d3(0x1df)][_0xeb77d3(0x212)](_0x2878bc,_0x36e4df),void _0x36e4df[_0xeb77d3(0x288)](()=>this[_0xeb77d3(0x1df)][_0xeb77d3(0x234)](_0x2878bc))[_0xeb77d3(0x149)](()=>undefined),_0x36e4df;}async[_0x132f42(0x140)](_0x2e342c,_0x585fbb){const _0x443ec4=_0x132f42;let _0x163104=this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x254)](_0x2e342c[_0x443ec4(0x27f)],_0x585fbb[_0x443ec4(0x29e)]);if(this[_0x443ec4(0x1fb)][_0x443ec4(0x25a)](_0x163104['id']))throw new Error(_0x443ec4(0x14a));if(_0x163104[_0x443ec4(0x10e)]!==_0x443ec4(0x102))throw new Error(_0x443ec4(0x14a));if(this[_0x443ec4(0x1c5)][_0x443ec4(0x25a)](_0x163104['id']))throw new Error(_0x443ec4(0x238));const _0x2f211f=sessionTitleFromFirstMessage(_0x585fbb[_0x443ec4(0x14f)]),_0x36df49=_0x2f211f[_0x443ec4(0x134)]>-0x5*0x25a+0x21*0x23+0x35*0x23&&!this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x130)](_0x2e342c[_0x443ec4(0x27f)],_0x163104['id']),_0x53ebb6=runtimeModels(_0x2e342c[_0x443ec4(0xed)]),_0x538799=this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x289)](_0x2e342c[_0x443ec4(0x27f)],_0x163104['id']);let _0x2803e2,_0x4efc01,_0x562da3,_0x321097;const _0x1812a1=_0x163104[_0x443ec4(0xfa)]?undefined:this[_0x443ec4(0x13a)](_0x163104[_0x443ec4(0x219)]);if(_0x1812a1!==undefined&&_0x1812a1!==_0x163104[_0x443ec4(0x1ff)]){const _0x1a7ff1=_0x163104[_0x443ec4(0x1ff)],_0x3f99be=_0x1812a1;try{_0x2803e2=await this[_0x443ec4(0x104)](_0x3f99be,_0x163104[_0x443ec4(0x219)],!![]),_0x4efc01=selectModel(_0x2803e2,_0x53ebb6,_0x585fbb[_0x443ec4(0x22d)]??_0x2803e2[_0x443ec4(0x202)][_0x443ec4(0x10a)]),_0x562da3=resolveMcpServers(_0x2803e2,this[_0x443ec4(0x187)][_0x443ec4(0x17b)]??process.env),this[_0x443ec4(0x200)](_0x538799,_0x2803e2),this[_0x443ec4(0x1a7)](_0x538799,_0x2803e2),_0x321097={'previousVersionId':_0x1a7ff1,'targetVersionId':_0x3f99be};}catch(_0x5aa231){this[_0x443ec4(0x1c1)](_0x163104,_0x1a7ff1,_0x3f99be,_0x5aa231);throw new Error(_0x443ec4(0x1f0));}}else _0x2803e2=await this[_0x443ec4(0x104)](_0x163104[_0x443ec4(0x1ff)],_0x163104[_0x443ec4(0x219)],!![]),_0x4efc01=selectModel(_0x2803e2,_0x53ebb6,_0x585fbb[_0x443ec4(0x22d)]??_0x163104[_0x443ec4(0x22d)]);const _0x548fa4=await Promise[_0x443ec4(0x218)](_0x585fbb[_0x443ec4(0x112)][_0x443ec4(0x273)](_0x1a5970=>this[_0x443ec4(0x11e)](_0x2e342c[_0x443ec4(0x27f)],_0x163104['id'],_0x1a5970))),_0x51c3b0=attachmentPrompt(_0x585fbb[_0x443ec4(0x14f)],_0x548fa4),_0x42df91=marAgentGeneratedImagesDirectory(_0x538799[_0x443ec4(0x15a)],_0x163104[_0x443ec4(0x292)]),_0x47ab8c=hostedConversationGeneratedImagesDisplayDirectory(_0x163104[_0x443ec4(0x292)]);if(_0x42df91===undefined||_0x47ab8c===undefined)throw new Error(_0x443ec4(0x14b));await mkdir(_0x42df91,{'recursive':!![],'mode':0x1c0});const _0x1d06d1=this[_0x443ec4(0x200)](_0x538799,_0x2803e2,_0x42df91,_0x47ab8c),_0xbbd49=join(_0x538799[_0x443ec4(0x28d)],_0x443ec4(0x133)+randomUUID());await mkdir(_0xbbd49,{'mode':0x1c0}),this[_0x443ec4(0x181)](_0x2e342c[_0x443ec4(0x27f)],_0x163104,_0x443ec4(0x259),this[_0x443ec4(0x217)]());const _0x513932=[];let _0x3a3710=![];const _0x20de37=await this[_0x443ec4(0x187)][_0x443ec4(0x1b3)][_0x443ec4(0x237)]({'conversationId':_0x163104['id'],'sessionId':_0x163104[_0x443ec4(0x292)],'clientMessageId':_0x585fbb[_0x443ec4(0x275)],'userPrompt':_0x585fbb[_0x443ec4(0x14f)],'prompt':_0x51c3b0,'attachmentIds':_0x585fbb[_0x443ec4(0x112)],'access':_0x443ec4(0x1fe),'modelId':_0x4efc01['id'],'models':networkModels(allowedModels(_0x2803e2,_0x53ebb6),_0x2803e2[_0x443ec4(0x118)][_0x443ec4(0x21d)]),..._0x2e342c[_0x443ec4(0x21c)]===undefined?{}:{'runtimeScopeId':_0x2e342c[_0x443ec4(0x21c)]},'systemInstruction':systemInstruction(_0x2803e2,_0x47ab8c),'homeDirectory':_0x538799[_0x443ec4(0x15a)],'workspaceDirectory':_0x2803e2[_0x443ec4(0x15c)],'temporaryDirectory':_0xbbd49,'pathMounts':_0x1d06d1,'processExecutor':this[_0x443ec4(0x1a7)](_0x538799,_0x2803e2,_0xbbd49,_0x42df91,_0x47ab8c),'mcpServers':_0x562da3??resolveMcpServers(_0x2803e2,this[_0x443ec4(0x187)][_0x443ec4(0x17b)]??process.env),'webAccess':_0x2803e2[_0x443ec4(0x118)][_0x443ec4(0x21d)]!==_0x443ec4(0x290),'onEvent':_0x5be99d=>{const _0x4ef8cd=_0x443ec4;if(_0x3a3710)this[_0x4ef8cd(0x209)](_0x163104['id'],_0x5be99d);else _0x513932[_0x4ef8cd(0x171)](_0x5be99d);}})[_0x443ec4(0x149)](async _0x4fe199=>{const _0x2c61fd=_0x443ec4;this[_0x2c61fd(0x181)](_0x2e342c[_0x2c61fd(0x27f)],_0x163104,_0x2c61fd(0x210),this[_0x2c61fd(0x217)]()),await rm(_0xbbd49,{'recursive':!![],'force':!![]})[_0x2c61fd(0x149)](()=>undefined);if(_0x321097!==undefined){this[_0x2c61fd(0x1c1)](_0x163104,_0x321097[_0x2c61fd(0x201)],_0x321097[_0x2c61fd(0x14d)],_0x4fe199);throw new Error(_0x2c61fd(0x1f0));}throw _0x4fe199;}),_0x44ee36=_0x20de37[_0x443ec4(0x1ab)][_0x443ec4(0x216)];let _0x34acfb=![],_0x34aced;try{this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x26b)]({'conversationId':_0x163104['id'],'clientMessageId':_0x585fbb[_0x443ec4(0x275)],'runId':_0x20de37[_0x443ec4(0x1ab)]['id'],'userTextPresent':_0x2f211f[_0x443ec4(0x134)]>-0x23fd+0x2112+0x2eb,'status':_0x443ec4(0x25b),'createdAt':_0x44ee36,'updatedAt':_0x44ee36}),_0x34acfb=!![];const _0x3eb4c5=this[_0x443ec4(0x217)]();_0x34aced=await this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x158)]({'conversationId':_0x163104['id'],'modelId':_0x4efc01['id'],'activityAt':_0x3eb4c5,..._0x321097===undefined?{}:{'templateVersion':{'expectedActiveVersionId':_0x321097[_0x443ec4(0x201)],'activeVersionId':_0x321097[_0x443ec4(0x14d)],'maxStorageBytes':_0x2803e2[_0x443ec4(0x118)][_0x443ec4(0x285)][_0x443ec4(0x189)]}},..._0x36df49?{'automaticTitle':_0x2f211f}:{}});}catch(_0x39dcb1){try{_0x20de37[_0x443ec4(0x28a)]();}catch{}const _0x4c19ad=await _0x20de37[_0x443ec4(0x261)][_0x443ec4(0x149)](()=>({'status':_0x443ec4(0x1a9),'completedAt':this[_0x443ec4(0x217)]()}));if(_0x34acfb)try{this[_0x443ec4(0x187)][_0x443ec4(0x1ec)][_0x443ec4(0x16b)](_0x163104['id'],_0x585fbb[_0x443ec4(0x275)],_0x4c19ad[_0x443ec4(0x10e)],_0x4c19ad[_0x443ec4(0xff)]);}catch{}await rm(_0xbbd49,{'recursive':!![],'force':!![]})[_0x443ec4(0x149)](()=>undefined),this[_0x443ec4(0x181)](_0x2e342c[_0x443ec4(0x27f)],_0x163104,_0x443ec4(0x210),_0x4c19ad[_0x443ec4(0xff)]);if(_0x321097!==undefined)this[_0x443ec4(0x1c1)](_0x163104,_0x321097[_0x443ec4(0x201)],_0x321097[_0x443ec4(0x14d)],_0x39dcb1);throw _0x39dcb1;}_0x163104=_0x34aced[_0x443ec4(0x113)];if(_0x321097!==undefined)this[_0x443ec4(0x18b)](_0x163104['id'],{'conversationId':_0x163104['id'],'kind':_0x443ec4(0x129),'upgrade':{'status':_0x443ec4(0x15d),'previousVersionId':_0x321097[_0x443ec4(0x201)],'targetVersionId':_0x321097[_0x443ec4(0x14d)],'activeVersionId':_0x163104[_0x443ec4(0x1ff)],'conversation':this[_0x443ec4(0x195)](_0x163104),'error':null}});this[_0x443ec4(0x1c5)][_0x443ec4(0x212)](_0x163104['id'],_0x20de37),this[_0x443ec4(0x181)](_0x2e342c[_0x443ec4(0x27f)],_0x163104,_0x443ec4(0x25b),_0x20de37[_0x443ec4(0x1ab)][_0x443ec4(0x216)]);if(_0x34aced[_0x443ec4(0x1f1)])this[_0x443ec4(0x18b)](_0x163104['id'],{'conversationId':_0x163104['id'],'kind':_0x443ec4(0x113),'conversation':this[_0x443ec4(0x195)](_0x163104)});this[_0x443ec4(0x18b)](_0x163104['id'],{'conversationId':_0x163104['id'],'kind':_0x443ec4(0x1ab),'run':_0x20de37[_0x443ec4(0x1ab)]}),_0x3a3710=!![];for(const _0xece8f of _0x513932)this[_0x443ec4(0x209)](_0x163104['id'],_0xece8f);_0x513932[_0x443ec4(0x134)]=0x1*0x98f+-0x1926+0xf97;const _0x5d8111=_0x20de37[_0x443ec4(0x261)][_0x443ec4(0x250)](_0x164859=>this[_0x443ec4(0x231)](_0x2e342c[_0x443ec4(0x27f)],_0x163104['id'],_0x585fbb[_0x443ec4(0x275)],_0x20de37[_0x443ec4(0x1ab)],_0x164859),()=>this[_0x443ec4(0x231)](_0x2e342c[_0x443ec4(0x27f)],_0x163104['id'],_0x585fbb[_0x443ec4(0x275)],_0x20de37[_0x443ec4(0x1ab)],{'status':_0x443ec4(0x1a9),'completedAt':this[_0x443ec4(0x217)]()}))[_0x443ec4(0x149)](()=>undefined)[_0x443ec4(0x288)](async()=>{const _0x44faa5=_0x443ec4;this[_0x44faa5(0x1b8)][_0x44faa5(0x234)](runInterruptionKey(_0x163104['id'],_0x20de37[_0x44faa5(0x1ab)]['id']));if(this[_0x44faa5(0x1c5)][_0x44faa5(0x25c)](_0x163104['id'])===_0x20de37)this[_0x44faa5(0x1c5)][_0x44faa5(0x234)](_0x163104['id']);if(this[_0x44faa5(0x1a3)][_0x44faa5(0x25c)](_0x163104['id'])===_0x5d8111)this[_0x44faa5(0x1a3)][_0x44faa5(0x234)](_0x163104['id']);await rm(_0xbbd49,{'recursive':!![],'force':!![]})[_0x44faa5(0x149)](()=>undefined);});return this[_0x443ec4(0x1a3)][_0x443ec4(0x212)](_0x163104['id'],_0x5d8111),void _0x5d8111,{'conversation':this[_0x443ec4(0x195)](_0x163104),'run':_0x20de37[_0x443ec4(0x1ab)]};}async[_0x132f42(0x231)](_0x201c38,_0x34953f,_0x551639,_0x4652c8,_0x1bbde0){const _0x2c131c=_0x132f42,_0x25df6d=runInterruptionKey(_0x34953f,_0x4652c8['id']),_0x5be224=this[_0x2c131c(0x1b8)][_0x2c131c(0x25a)](_0x25df6d);let _0x282aab;try{this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x16b)](_0x34953f,_0x551639,_0x1bbde0[_0x2c131c(0x10e)],_0x1bbde0[_0x2c131c(0xff)]);try{const _0x5d0172=await this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x23f)](_0x201c38,_0x34953f);this[_0x2c131c(0x18b)](_0x34953f,{'conversationId':_0x34953f,'kind':_0x2c131c(0x1cf),'files':_0x5d0172,'error':null});}catch(_0x3c8eac){this[_0x2c131c(0x18b)](_0x34953f,{'conversationId':_0x34953f,'kind':_0x2c131c(0x1cf),'files':this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x1aa)](_0x201c38,_0x34953f),'error':{'code':safeErrorCode(_0x3c8eac,_0x2c131c(0x28e)),'message':_0x2c131c(0x283)}});}await this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x18c)](_0x34953f,_0x1bbde0[_0x2c131c(0xff)]),this[_0x2c131c(0x18b)](_0x34953f,{'conversationId':_0x34953f,'kind':_0x2c131c(0x1ab),'run':{'id':_0x4652c8['id'],'status':_0x1bbde0[_0x2c131c(0x10e)],'startedAt':_0x4652c8[_0x2c131c(0x216)],'completedAt':_0x1bbde0[_0x2c131c(0xff)]}}),await this[_0x2c131c(0x247)](_0x34953f,_0x1bbde0[_0x2c131c(0x28c)],_0x1bbde0[_0x2c131c(0xff)])[_0x2c131c(0x149)](()=>undefined),_0x282aab=this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x254)](_0x201c38,_0x34953f);}finally{this[_0x2c131c(0x1b8)][_0x2c131c(0x234)](_0x25df6d);if(_0x282aab===undefined)try{_0x282aab=this[_0x2c131c(0x187)][_0x2c131c(0x1ec)][_0x2c131c(0x254)](_0x201c38,_0x34953f);}catch{}if(_0x282aab!==undefined)this[_0x2c131c(0x181)](_0x201c38,_0x282aab,_0x2c131c(0x210),_0x1bbde0[_0x2c131c(0xff)]);}if(_0x282aab!==undefined&&(_0x1bbde0[_0x2c131c(0x10e)]!==_0x2c131c(0x1db)||!_0x5be224))this[_0x2c131c(0x21f)](_0x201c38,_0x282aab,_0x4652c8['id'],_0x1bbde0);}async[_0x132f42(0x247)](_0x19fe37,_0x3efc10,_0x576cee){const _0x34fa04=_0x132f42,_0x164ad4=automaticHostedConversationTitle(_0x3efc10);if(_0x164ad4===undefined)return;const _0x46730a=await this[_0x34fa04(0x187)][_0x34fa04(0x1ec)][_0x34fa04(0x1e6)](_0x19fe37,_0x164ad4,_0x576cee);if(_0x46730a===undefined)return;this[_0x34fa04(0x18b)](_0x19fe37,{'conversationId':_0x19fe37,'kind':_0x34fa04(0x113),'conversation':this[_0x34fa04(0x195)](_0x46730a)});}[_0x132f42(0x177)](_0x567d59){const _0x36b4a3=_0x132f42,_0xab2eac=hostedRequest(_0x567d59),_0x541560=hostedConversationIdInputSchema[_0x36b4a3(0x27e)](_0xab2eac[_0x36b4a3(0x10c)]),_0x4f3b9d=this[_0x36b4a3(0x187)][_0x36b4a3(0x1ec)][_0x36b4a3(0x254)](_0xab2eac[_0x36b4a3(0x27f)],_0x541560[_0x36b4a3(0x29e)]),_0x1a982e=this[_0x36b4a3(0x1c5)][_0x36b4a3(0x25c)](_0x541560[_0x36b4a3(0x29e)]);if(_0x1a982e===undefined)return{'interrupted':![]};const _0x2eb162=runInterruptionKey(_0x4f3b9d['id'],_0x1a982e[_0x36b4a3(0x1ab)]['id']);this[_0x36b4a3(0x1b8)][_0x36b4a3(0x1ad)](_0x2eb162);try{const _0x32952c=_0x1a982e[_0x36b4a3(0x28a)]();if(!_0x32952c)return this[_0x36b4a3(0x1b8)][_0x36b4a3(0x234)](_0x2eb162),{'interrupted':![]};return this[_0x36b4a3(0x181)](_0xab2eac[_0x36b4a3(0x27f)],_0x4f3b9d,_0x36b4a3(0x1e0),this[_0x36b4a3(0x217)]()),{'interrupted':!![]};}catch(_0x2876fd){this[_0x36b4a3(0x1b8)][_0x36b4a3(0x234)](_0x2eb162);throw _0x2876fd;}}async[_0x132f42(0x282)](_0x2a2bda){const _0x2b56f3=_0x132f42,_0x52866a=hostedRequest(_0x2a2bda),_0x2fe35d=hostedConversationConfigUpdateInputSchema[_0x2b56f3(0x27e)](_0x52866a[_0x2b56f3(0x10c)]),_0x28ee83=this[_0x2b56f3(0x187)][_0x2b56f3(0x1ec)][_0x2b56f3(0x254)](_0x52866a[_0x2b56f3(0x27f)],_0x2fe35d[_0x2b56f3(0x29e)]);if(this[_0x2b56f3(0x1fb)][_0x2b56f3(0x25a)](_0x28ee83['id']))throw new Error(_0x2b56f3(0x14a));const _0x548d08=await this[_0x2b56f3(0x104)](_0x28ee83[_0x2b56f3(0x1ff)],_0x28ee83[_0x2b56f3(0x219)]),_0x467aa0=runtimeModels(_0x52866a[_0x2b56f3(0xed)]),_0x582720=selectModel(_0x548d08,_0x467aa0,_0x2fe35d[_0x2b56f3(0x22d)]??_0x28ee83[_0x2b56f3(0x22d)]),_0x29226e=this[_0x2b56f3(0x217)](),_0x210a7f=await this[_0x2b56f3(0x187)][_0x2b56f3(0x1ec)][_0x2b56f3(0x12e)](_0x28ee83['id'],_0x4d457b=>({..._0x4d457b,'modelId':_0x582720['id'],'updatedAt':_0x29226e,'lastActivityAt':_0x29226e}));return this[_0x2b56f3(0x18b)](_0x28ee83['id'],{'conversationId':_0x28ee83['id'],'kind':_0x2b56f3(0x11c),'conversation':this[_0x2b56f3(0x195)](_0x210a7f)}),{'conversation':this[_0x2b56f3(0x195)](_0x210a7f)};}async[_0x132f42(0x23b)](_0x2b3b){const _0x58205b=_0x132f42,_0x138b65=hostedRequest(_0x2b3b),_0xa0c8b6=hostedConversationMetadataUpdateInputSchema[_0x58205b(0x27e)](_0x138b65[_0x58205b(0x10c)]),_0x4dc4fa=this[_0x58205b(0x187)][_0x58205b(0x1ec)][_0x58205b(0x254)](_0x138b65[_0x58205b(0x27f)],_0xa0c8b6[_0x58205b(0x29e)]);if(this[_0x58205b(0x1fb)][_0x58205b(0x25a)](_0x4dc4fa['id']))throw new Error(_0x58205b(0x14a));const _0x2cb75c=this[_0x58205b(0x217)](),_0x1d9e6d=await this[_0x58205b(0x187)][_0x58205b(0x1ec)][_0x58205b(0x12e)](_0x4dc4fa['id'],_0x58b3cb=>({..._0x58b3cb,'title':_0xa0c8b6[_0x58205b(0x28c)]??_0x58b3cb[_0x58205b(0x28c)],'titleSource':_0xa0c8b6[_0x58205b(0x28c)]===undefined?_0x58b3cb[_0x58205b(0x1f8)]:_0x58205b(0x197),'pinnedAt':_0xa0c8b6[_0x58205b(0x1ca)]===undefined?_0x58b3cb[_0x58205b(0x241)]:_0xa0c8b6[_0x58205b(0x1ca)]?_0x2cb75c:null,'updatedAt':_0x2cb75c,'lastActivityAt':_0x58b3cb[_0x58205b(0x1c2)]}));return this[_0x58205b(0x18b)](_0x4dc4fa['id'],{'conversationId':_0x4dc4fa['id'],'kind':_0x58205b(0x11c),'conversation':this[_0x58205b(0x195)](_0x1d9e6d)}),{'conversation':this[_0x58205b(0x195)](_0x1d9e6d)};}async[_0x132f42(0x1aa)](_0x4f15d0){const _0xf4ec12=_0x132f42,_0xfa5b56=hostedRequest(_0x4f15d0),_0x53f95c=hostedConversationIdInputSchema[_0xf4ec12(0x27e)](_0xfa5b56[_0xf4ec12(0x10c)]);return hostedConversationFilesSchema[_0xf4ec12(0x27e)]({'files':this[_0xf4ec12(0x187)][_0xf4ec12(0x1ec)][_0xf4ec12(0x1aa)](_0xfa5b56[_0xf4ec12(0x27f)],_0x53f95c[_0xf4ec12(0x29e)])});}async[_0x132f42(0x10f)](_0x4a0d1b){const _0x35c5b1=_0x132f42,_0x1ee0b0=hostedRequest(_0x4a0d1b),_0x36a4a0=hostedConversationImageReadInputSchema[_0x35c5b1(0x27e)](_0x1ee0b0[_0x35c5b1(0x10c)]);this[_0x35c5b1(0x187)][_0x35c5b1(0x1ec)][_0x35c5b1(0x254)](_0x1ee0b0[_0x35c5b1(0x27f)],_0x36a4a0[_0x35c5b1(0x29e)]);if(_0x36a4a0[_0x35c5b1(0x15f)]!==hostedConversationImageRunId(_0x36a4a0[_0x35c5b1(0x29e)]))throw new Error(_0x35c5b1(0x13e));const _0x10ed57=await this[_0x35c5b1(0x187)][_0x35c5b1(0x10f)](_0x36a4a0[_0x35c5b1(0x15f)],_0x36a4a0[_0x35c5b1(0x1ea)]);if(_0x10ed57===undefined)throw new Error(_0x35c5b1(0x23e));return{'image':_0x10ed57};}async[_0x132f42(0x24d)](_0xf1dc35){const _0x466cc0=_0x132f42,_0x181e6f=hostedRequest(_0xf1dc35),_0x5f23c8=hostedConversationFileReadInputSchema[_0x466cc0(0x27e)](_0x181e6f[_0x466cc0(0x10c)]),_0x2841d4=this[_0x466cc0(0x187)][_0x466cc0(0x1ec)][_0x466cc0(0x127)](_0x181e6f[_0x466cc0(0x27f)],_0x5f23c8[_0x466cc0(0x29e)],_0x5f23c8[_0x466cc0(0x29a)]),_0x430094=this[_0x466cc0(0x187)][_0x466cc0(0x1ec)][_0x466cc0(0x29f)](_0x181e6f[_0x466cc0(0x27f)],_0x2841d4);await assertRegularFile(_0x430094,_0x2841d4[_0x466cc0(0x14c)]);const _0x382dbc=_0x5f23c8[_0x466cc0(0x19b)]??0x4c6*0x7+-0xe98+-0x49*0x42;if(_0x382dbc>_0x2841d4[_0x466cc0(0x14c)])throw new Error(_0x466cc0(0x111));const _0x241f05=Math[_0x466cc0(0x1a0)](_0x5f23c8[_0x466cc0(0x12d)]??MAX_FILE_READ_BYTES,MAX_FILE_READ_BYTES),_0x3d51f1=await open(_0x430094,'r');try{const _0xc6aea4=Buffer[_0x466cc0(0xf9)](Math[_0x466cc0(0x1a0)](_0x241f05,Math[_0x466cc0(0x1c4)](-0x14*-0x1a9+-0x1cb3+-0x481,_0x2841d4[_0x466cc0(0x14c)]-_0x382dbc))),_0x3ab2b1=await _0x3d51f1[_0x466cc0(0x224)](_0xc6aea4,-0x6c5+0x3*-0x57d+0x173c,_0xc6aea4[_0x466cc0(0x134)],_0x382dbc),_0x2a0aad=_0x382dbc+_0x3ab2b1[_0x466cc0(0x1c6)],_0x27e45c=_0x2a0aad>=_0x2841d4[_0x466cc0(0x14c)];return hostedConversationFileReadResultSchema[_0x466cc0(0x27e)]({'file':_0x2841d4,'encoding':_0x466cc0(0x12a),'content':_0xc6aea4[_0x466cc0(0x21a)](-0x1*0x1032+-0xc*0x2ff+0x3426,_0x3ab2b1[_0x466cc0(0x1c6)])[_0x466cc0(0x154)](_0x466cc0(0x12a)),'offset':_0x382dbc,'nextOffset':_0x27e45c?null:_0x2a0aad,'eof':_0x27e45c});}finally{await _0x3d51f1[_0x466cc0(0x278)]();}}async[_0x132f42(0x1c8)](_0x14a156){const _0x486a8a=_0x132f42,_0x320755=hostedRequest(_0x14a156),_0x2d7952=hostedConversationFileDeleteInputSchema[_0x486a8a(0x27e)](_0x320755[_0x486a8a(0x10c)]);this[_0x486a8a(0x1d6)](_0x320755[_0x486a8a(0x27f)],_0x2d7952[_0x486a8a(0x29e)]);const _0x246fe8=_0x2d7952[_0x486a8a(0x29e)]+'\x00'+_0x2d7952[_0x486a8a(0x29a)];if(this[_0x486a8a(0x139)][_0x486a8a(0x25a)](_0x246fe8))throw new Error(_0x486a8a(0x123));this[_0x486a8a(0x139)][_0x486a8a(0x1ad)](_0x246fe8);try{const _0x5731f4=await this[_0x486a8a(0x187)][_0x486a8a(0x1ec)][_0x486a8a(0x1c8)](_0x320755[_0x486a8a(0x27f)],_0x2d7952[_0x486a8a(0x29e)],_0x2d7952[_0x486a8a(0x29a)],this[_0x486a8a(0x217)]()),_0x28df04=hostedConversationFileDeleteResultSchema[_0x486a8a(0x27e)]({'deletedFileId':_0x2d7952[_0x486a8a(0x29a)],'files':_0x5731f4});return this[_0x486a8a(0x18b)](_0x2d7952[_0x486a8a(0x29e)],{'conversationId':_0x2d7952[_0x486a8a(0x29e)],'kind':_0x486a8a(0x1cf),'files':_0x28df04[_0x486a8a(0x1cf)],'error':null}),_0x28df04;}finally{this[_0x486a8a(0x139)][_0x486a8a(0x234)](_0x246fe8);}}async[_0x132f42(0x124)](_0x59e2f6){const _0x445eab=_0x132f42,_0x2ad044=hostedRequest(_0x59e2f6),_0x5600cb=hostedConversationUploadPreflightInputSchema[_0x445eab(0x27e)](_0x2ad044[_0x445eab(0x10c)]),_0x261db5=this[_0x445eab(0x1d6)](_0x2ad044[_0x445eab(0x27f)],_0x5600cb[_0x445eab(0x29e)]),_0x5d1798=await this[_0x445eab(0x104)](_0x261db5[_0x445eab(0x1ff)],_0x261db5[_0x445eab(0x219)]),_0x2425d8=this[_0x445eab(0x187)][_0x445eab(0x1ec)][_0x445eab(0x289)](_0x2ad044[_0x445eab(0x27f)],_0x261db5['id']),_0x1d8b18=await Promise[_0x445eab(0x218)](_0x5600cb[_0x445eab(0x1cf)][_0x445eab(0x273)](async _0x206f98=>({'name':_0x206f98[_0x445eab(0x22e)],'status':await this[_0x445eab(0x151)](_0x2425d8,_0x261db5,_0x5d1798[_0x445eab(0x118)],_0x206f98[_0x445eab(0x22e)],_0x206f98[_0x445eab(0x14c)])})));return hostedConversationUploadPreflightResultSchema[_0x445eab(0x27e)]({'files':_0x1d8b18});}async[_0x132f42(0x17c)](_0x1ce50a){const _0x332733=_0x132f42,_0x136604=hostedRequest(_0x1ce50a),_0x5dd6ac=hostedConversationUploadCreateInputSchema[_0x332733(0x27e)](_0x136604[_0x332733(0x10c)]),_0x37a155=this[_0x332733(0x1d6)](_0x136604[_0x332733(0x27f)],_0x5dd6ac[_0x332733(0x29e)]),_0x193afd=_0x136604[_0x332733(0x27f)]+'\x00'+_0x37a155['id']+'\x00'+_0x5dd6ac[_0x332733(0x122)],_0x5d5962=this[_0x332733(0x25d)][_0x332733(0x25c)](_0x193afd);if(_0x5d5962!==undefined){const _0x2e9411=this[_0x332733(0x10b)][_0x332733(0x25c)](_0x5d5962);if(_0x2e9411!==undefined)return{'upload':hostedConversationUploadSchema[_0x332733(0x27e)](uploadProjection(_0x2e9411))};}const _0x3c31a9=await this[_0x332733(0x104)](_0x37a155[_0x332733(0x1ff)],_0x37a155[_0x332733(0x219)]),_0x2ec5f4=this[_0x332733(0x187)][_0x332733(0x1ec)][_0x332733(0x289)](_0x136604[_0x332733(0x27f)],_0x37a155['id']),_0x357b8f=await this[_0x332733(0x151)](_0x2ec5f4,_0x37a155,_0x3c31a9[_0x332733(0x118)],_0x5dd6ac[_0x332733(0x22e)],_0x5dd6ac[_0x332733(0x14c)]);if(_0x357b8f===_0x332733(0x1a8)||_0x357b8f===_0x332733(0x25f))throw new Error(_0x332733(0x267));if(_0x357b8f!==_0x332733(0x165))throw new Error(_0x332733(0x27c));const _0x5bd451=this['id'](),_0xa76755=join(_0x2ec5f4[_0x332733(0x1a6)],'.'+_0x5bd451+_0x332733(0xf0)),_0x34c03b=join(_0x2ec5f4[_0x332733(0x1a6)],_0x5dd6ac[_0x332733(0x22e)]),_0x9e306c=await open(_0xa76755,'wx',-0x10b2+0x5*0x74d+0x6d*-0x2b);await _0x9e306c[_0x332733(0x278)]();const _0x13c341={'uploadId':_0x5bd451,'conversationId':_0x37a155['id'],'userId':_0x136604[_0x332733(0x27f)],'clientRequestId':_0x5dd6ac[_0x332733(0x122)],'name':_0x5dd6ac[_0x332733(0x22e)],'mimeType':_0x5dd6ac[_0x332733(0x126)],'size':_0x5dd6ac[_0x332733(0x14c)],'temporaryPath':_0xa76755,'targetPath':_0x34c03b,'receivedBytes':0x0,'status':_0x332733(0x221)};return this[_0x332733(0x10b)][_0x332733(0x212)](_0x5bd451,_0x13c341),this[_0x332733(0x25d)][_0x332733(0x212)](_0x193afd,_0x5bd451),{'upload':hostedConversationUploadSchema[_0x332733(0x27e)](uploadProjection(_0x13c341))};}async[_0x132f42(0x186)](_0x5ac9de){const _0x443bfd=_0x132f42,_0x4162a5=hostedRequest(_0x5ac9de),_0x5de368=hostedConversationUploadChunkInputSchema[_0x443bfd(0x27e)](_0x4162a5[_0x443bfd(0x10c)]),_0x489df1=this[_0x443bfd(0x142)](_0x4162a5[_0x443bfd(0x27f)],_0x5de368[_0x443bfd(0x29e)],_0x5de368[_0x443bfd(0x1f3)]);if(_0x489df1[_0x443bfd(0x10e)]!==_0x443bfd(0x221))throw new Error(_0x443bfd(0x1e1));if(_0x5de368[_0x443bfd(0x19b)]!==_0x489df1[_0x443bfd(0x1be)])throw new Error(_0x443bfd(0x1e4));const _0x3bbd00=Buffer[_0x443bfd(0x204)](_0x5de368[_0x443bfd(0x18e)],_0x443bfd(0x12a));if(_0x489df1[_0x443bfd(0x1be)]+_0x3bbd00[_0x443bfd(0x22c)]>_0x489df1[_0x443bfd(0x14c)])throw new Error(_0x443bfd(0x223));await assertUploadTemporaryFile(_0x489df1[_0x443bfd(0x20b)],_0x489df1[_0x443bfd(0x1be)]);const _0x1394db=await open(_0x489df1[_0x443bfd(0x20b)],'r+');try{await _0x1394db[_0x443bfd(0x1af)](_0x3bbd00,0x2*0x1df+0xbf*0x1+-0x47d,_0x3bbd00[_0x443bfd(0x22c)],_0x489df1[_0x443bfd(0x1be)]);}finally{await _0x1394db[_0x443bfd(0x278)]();}return _0x489df1[_0x443bfd(0x1be)]+=_0x3bbd00[_0x443bfd(0x22c)],{'upload':hostedConversationUploadSchema[_0x443bfd(0x27e)](uploadProjection(_0x489df1))};}[_0x132f42(0x196)](_0x2146cc){const _0x274fc5=_0x132f42,_0x9067f4=hostedRequest(_0x2146cc),_0x3b428b=hostedConversationUploadControlInputSchema[_0x274fc5(0x27e)](_0x9067f4[_0x274fc5(0x10c)]),_0x12aae2=this[_0x274fc5(0x142)](_0x9067f4[_0x274fc5(0x27f)],_0x3b428b[_0x274fc5(0x29e)],_0x3b428b[_0x274fc5(0x1f3)]);return{'upload':hostedConversationUploadSchema[_0x274fc5(0x27e)](uploadProjection(_0x12aae2))};}async[_0x132f42(0x1dc)](_0x1dc9ef){const _0x4147de=_0x132f42,_0x1e34a3=hostedRequest(_0x1dc9ef),_0x398a6a=hostedConversationUploadControlInputSchema[_0x4147de(0x27e)](_0x1e34a3[_0x4147de(0x10c)]),_0x37b010=this[_0x4147de(0x142)](_0x1e34a3[_0x4147de(0x27f)],_0x398a6a[_0x4147de(0x29e)],_0x398a6a[_0x4147de(0x1f3)]);if(_0x37b010[_0x4147de(0x10e)]===_0x4147de(0x199))return{'upload':hostedConversationUploadSchema[_0x4147de(0x27e)](uploadProjection(_0x37b010))};if(_0x37b010[_0x4147de(0x10e)]!==_0x4147de(0x221)||_0x37b010[_0x4147de(0x1be)]!==_0x37b010[_0x4147de(0x14c)])throw new Error(_0x4147de(0x248));const _0x565a46=this[_0x4147de(0x1d6)](_0x1e34a3[_0x4147de(0x27f)],_0x37b010[_0x4147de(0x29e)]),_0x2cb745=await this[_0x4147de(0x104)](_0x565a46[_0x4147de(0x1ff)],_0x565a46[_0x4147de(0x219)]);if(_0x37b010[_0x4147de(0x14c)]>_0x2cb745[_0x4147de(0x118)][_0x4147de(0x285)][_0x4147de(0x1e5)]||_0x565a46[_0x4147de(0x23a)][_0x4147de(0x295)]+_0x37b010[_0x4147de(0x14c)]>_0x565a46[_0x4147de(0x23a)][_0x4147de(0x291)])throw new Error(_0x4147de(0x267));await assertUploadTemporaryFile(_0x37b010[_0x4147de(0x20b)],_0x37b010[_0x4147de(0x14c)]);const _0x487f93=await lstat(_0x37b010[_0x4147de(0x281)])[_0x4147de(0x149)](_0x10da75=>{const _0x1f2dfb=_0x4147de;if(_0x10da75[_0x1f2dfb(0xee)]===_0x1f2dfb(0x249))return undefined;throw _0x10da75;});if(_0x487f93!==undefined)throw new Error(_0x4147de(0x27c));const _0x54d313=await open(_0x37b010[_0x4147de(0x20b)],'r+');try{await _0x54d313[_0x4147de(0x28f)]();}finally{await _0x54d313[_0x4147de(0x278)]();}await rename(_0x37b010[_0x4147de(0x20b)],_0x37b010[_0x4147de(0x281)]);const _0x55cfa8=this[_0x4147de(0x217)]();try{await utimes(_0x37b010[_0x4147de(0x281)],new Date(_0x55cfa8),new Date(_0x55cfa8));const _0x50b2f2={'id':this[_0x4147de(0x187)][_0x4147de(0x1ec)][_0x4147de(0x121)](_0x37b010[_0x4147de(0x29e)],_0x4147de(0x16d),_0x37b010[_0x4147de(0x22e)]),'conversationId':_0x37b010[_0x4147de(0x29e)],'category':_0x4147de(0x16d),'relativePath':_0x37b010[_0x4147de(0x22e)],'displayName':_0x37b010[_0x4147de(0x22e)],'mimeType':_0x37b010[_0x4147de(0x126)],'size':_0x37b010[_0x4147de(0x14c)],'source':_0x4147de(0x211),'createdAt':_0x55cfa8,'updatedAt':_0x55cfa8};return _0x37b010[_0x4147de(0x159)]=await this[_0x4147de(0x187)][_0x4147de(0x1ec)][_0x4147de(0x13c)](_0x1e34a3[_0x4147de(0x27f)],_0x50b2f2),_0x37b010[_0x4147de(0x10e)]=_0x4147de(0x199),this[_0x4147de(0x18b)](_0x37b010[_0x4147de(0x29e)],{'conversationId':_0x37b010[_0x4147de(0x29e)],'kind':_0x4147de(0x1cf),'files':this[_0x4147de(0x187)][_0x4147de(0x1ec)][_0x4147de(0x1aa)](_0x1e34a3[_0x4147de(0x27f)],_0x37b010[_0x4147de(0x29e)]),'error':null}),{'upload':hostedConversationUploadSchema[_0x4147de(0x27e)](uploadProjection(_0x37b010))};}catch(_0x39944b){await rename(_0x37b010[_0x4147de(0x281)],_0x37b010[_0x4147de(0x20b)])[_0x4147de(0x149)](()=>undefined);throw _0x39944b;}}async[_0x132f42(0x1f9)](_0x8da9ec){const _0x4b0c71=_0x132f42,_0xfa4e0d=hostedRequest(_0x8da9ec),_0xd18421=hostedConversationUploadControlInputSchema[_0x4b0c71(0x27e)](_0xfa4e0d[_0x4b0c71(0x10c)]),_0x17e3d0=this[_0x4b0c71(0x142)](_0xfa4e0d[_0x4b0c71(0x27f)],_0xd18421[_0x4b0c71(0x29e)],_0xd18421[_0x4b0c71(0x1f3)]);if(_0x17e3d0[_0x4b0c71(0x10e)]===_0x4b0c71(0x199))throw new Error(_0x4b0c71(0x1e1));return _0x17e3d0[_0x4b0c71(0x10e)]=_0x4b0c71(0x11a),await rm(_0x17e3d0[_0x4b0c71(0x20b)],{'force':!![]}),{'upload':hostedConversationUploadSchema[_0x4b0c71(0x27e)](uploadProjection(_0x17e3d0))};}async[_0x132f42(0x234)](_0x3d936b){const _0x43c4d9=_0x132f42,_0x10b9a8=hostedRequest(_0x3d936b),_0x4c1af7=hostedConversationIdInputSchema[_0x43c4d9(0x27e)](_0x10b9a8[_0x43c4d9(0x10c)]),_0x3e5453=this[_0x43c4d9(0x187)][_0x43c4d9(0x1ec)][_0x43c4d9(0x254)](_0x10b9a8[_0x43c4d9(0x27f)],_0x4c1af7[_0x43c4d9(0x29e)]);if(this[_0x43c4d9(0x1fb)][_0x43c4d9(0x25a)](_0x3e5453['id']))throw new Error(_0x43c4d9(0x14a));this[_0x43c4d9(0x1fb)][_0x43c4d9(0x1ad)](_0x3e5453['id']);try{await this[_0x43c4d9(0x19c)](_0x3e5453['id']);const _0xd9a0c8=this[_0x43c4d9(0x1c5)][_0x43c4d9(0x25c)](_0x3e5453['id']);if(_0xd9a0c8!==undefined){const _0x45fcf4=runInterruptionKey(_0x3e5453['id'],_0xd9a0c8[_0x43c4d9(0x1ab)]['id']);this[_0x43c4d9(0x1b8)][_0x43c4d9(0x1ad)](_0x45fcf4);if(!_0xd9a0c8[_0x43c4d9(0x28a)]())this[_0x43c4d9(0x1b8)][_0x43c4d9(0x234)](_0x45fcf4);}await this[_0x43c4d9(0x192)](_0x10b9a8[_0x43c4d9(0x27f)],_0x3e5453['id']);const _0x4b3026=this[_0x43c4d9(0x187)][_0x43c4d9(0x1ec)][_0x43c4d9(0x289)](_0x10b9a8[_0x43c4d9(0x27f)],_0x3e5453['id']);return await this[_0x43c4d9(0x187)][_0x43c4d9(0x1b3)][_0x43c4d9(0x1a2)]({'conversationId':_0x3e5453['id'],'sessionId':_0x3e5453[_0x43c4d9(0x292)],'homeDirectory':_0x4b3026[_0x43c4d9(0x15a)]})[_0x43c4d9(0x149)](()=>undefined),await this[_0x43c4d9(0x1a3)][_0x43c4d9(0x25c)](_0x3e5453['id'])?.[_0x43c4d9(0x149)](()=>undefined),this[_0x43c4d9(0x2a1)](_0x3e5453['id']),await this[_0x43c4d9(0x187)][_0x43c4d9(0x1ec)][_0x43c4d9(0x1c7)](_0x3e5453['id']),this[_0x43c4d9(0x276)][_0x43c4d9(0x234)](_0x3e5453['id']),hostedConversationDeleteResultSchema[_0x43c4d9(0x27e)]({'deletedConversationId':_0x3e5453['id']});}finally{this[_0x43c4d9(0x1fb)][_0x43c4d9(0x234)](_0x3e5453['id']);}}async[_0x132f42(0x19c)](_0x35fee6){const _0x3102c5=_0x132f42,_0x1942ac=_0x35fee6+'\x00',_0x3edcf2=[...this[_0x3102c5(0x1df)][_0x3102c5(0x29c)]()][_0x3102c5(0x26f)](([_0x51116a])=>_0x51116a[_0x3102c5(0x1fa)](_0x1942ac))[_0x3102c5(0x273)](([,_0x455a75])=>_0x455a75);await Promise[_0x3102c5(0x20f)](_0x3edcf2);}async[_0x132f42(0x268)](_0x217f5c){const _0x10cf94=_0x132f42;try{const _0x1f0da1=await this[_0x10cf94(0x25c)]({'conversationId':_0x217f5c[_0x10cf94(0x29e)],'__requestUserId':_0x217f5c[_0x10cf94(0x27f)],'__marAgentModels':_0x217f5c[_0x10cf94(0xed)]});if(this[_0x10cf94(0x1d5)][_0x10cf94(0x25c)](_0x217f5c[_0x10cf94(0xec)])!==_0x217f5c)return;this[_0x10cf94(0x187)][_0x10cf94(0x1d3)]?.({'type':_0x10cf94(0x20a),'workbenchConnectionId':_0x217f5c[_0x10cf94(0x153)],'watchId':_0x217f5c[_0x10cf94(0x19a)],'nodeGeneration':_0x217f5c[_0x10cf94(0x175)],'nodeId':this[_0x10cf94(0x187)][_0x10cf94(0x298)](),'templateId':_0x217f5c[_0x10cf94(0x219)],'conversationId':_0x217f5c[_0x10cf94(0x29e)],'revision':0x1,'snapshotSequence':++this[_0x10cf94(0x169)],'expiresAt':_0x217f5c[_0x10cf94(0x22f)],'payload':_0x1f0da1}),_0x217f5c[_0x10cf94(0x1ed)]=!![];for(const _0xf33ef0 of _0x217f5c[_0x10cf94(0x27b)])this[_0x10cf94(0x1b2)](_0x217f5c,_0xf33ef0);_0x217f5c[_0x10cf94(0x27b)][_0x10cf94(0x134)]=0xbe*0x14+-0x1f9a+0x10c2;}catch(_0x2230c0){if(this[_0x10cf94(0x1d5)][_0x10cf94(0x25c)](_0x217f5c[_0x10cf94(0xec)])!==_0x217f5c)return;this[_0x10cf94(0x187)][_0x10cf94(0x1d3)]?.({'type':_0x10cf94(0x20e),'workbenchConnectionId':_0x217f5c[_0x10cf94(0x153)],'watchType':_0x10cf94(0x172),'watchId':_0x217f5c[_0x10cf94(0x19a)],'nodeGeneration':_0x217f5c[_0x10cf94(0x175)],'nodeId':this[_0x10cf94(0x187)][_0x10cf94(0x298)](),'templateId':_0x217f5c[_0x10cf94(0x219)],'conversationId':_0x217f5c[_0x10cf94(0x29e)],'code':safeErrorCode(_0x2230c0,_0x10cf94(0x26e)),'message':_0x10cf94(0x17e)}),this[_0x10cf94(0x101)](_0x217f5c[_0x10cf94(0xec)]);}}[_0x132f42(0x16a)](_0x234daf){const _0x5c8994=_0x132f42;return this[_0x5c8994(0x276)][_0x5c8994(0x25c)](_0x234daf)??{'status':_0x5c8994(0x210),'version':0x0,'updatedAt':0x0};}[_0x132f42(0x195)](_0x2904b6){const _0x457f60=_0x132f42;return hostedConversationSummary(_0x2904b6,this[_0x457f60(0x16a)](_0x2904b6['id']));}[_0x132f42(0x181)](_0x53d825,_0x2f7319,_0x1573c1,_0x1cad33){const _0x3711b2=_0x132f42,_0xd61f73=this[_0x3711b2(0x16a)](_0x2f7319['id']),_0x1eec62={'status':_0x1573c1,'version':_0xd61f73[_0x3711b2(0x214)]+(-0x1*0x2399+0x13ee+0xfac),'updatedAt':_0x1cad33};this[_0x3711b2(0x276)][_0x3711b2(0x212)](_0x2f7319['id'],_0x1eec62),this[_0x3711b2(0x178)]({'kind':_0x3711b2(0x16a),'userId':_0x53d825,'templateId':_0x2f7319[_0x3711b2(0x219)],'conversationId':_0x2f7319['id'],'activity':_0x1eec62});}[_0x132f42(0x21f)](_0x57c278,_0x23c8ca,_0x210ca8,_0x4eef0d){const _0x248578=_0x132f42;this[_0x248578(0x178)]({'kind':_0x248578(0x163),'event':{'runId':_0x210ca8,'sequence':0x1,'eventType':_0x248578(0x163),'payload':{'targetType':_0x248578(0x24e),'userId':_0x57c278,'templateId':_0x23c8ca[_0x248578(0x219)],'conversationId':_0x23c8ca['id'],'conversationTitle':_0x23c8ca[_0x248578(0x28c)],'runId':_0x210ca8,'notificationId':_0x248578(0x1a5)+this[_0x248578(0x187)][_0x248578(0x298)]()+':'+_0x23c8ca['id']+':'+_0x210ca8,'kind':_0x248578(0x16f),'outcome':_0x4eef0d[_0x248578(0x10e)],'occurredAt':_0x4eef0d[_0x248578(0xff)]},'createdAt':_0x4eef0d[_0x248578(0xff)]}});}[_0x132f42(0x178)](_0x2e6426){const _0x313266=_0x132f42,_0x994539=this[_0x313266(0x187)][_0x313266(0x1c0)]?.(_0x2e6426)??{'sequence':++this[_0x313266(0x125)],'category':_0x313266(0x172),'payload':_0x2e6426};if(_0x994539!==undefined)this[_0x313266(0x187)][_0x313266(0x1bf)]?.(_0x994539);}[_0x132f42(0x1c1)](_0x172d60,_0x3d8719,_0x3b077d,_0x4e2e71){const _0x4409d7=_0x132f42;this[_0x4409d7(0x18b)](_0x172d60['id'],{'conversationId':_0x172d60['id'],'kind':_0x4409d7(0x129),'upgrade':{'status':_0x4409d7(0x1a9),'previousVersionId':_0x3d8719,'targetVersionId':_0x3b077d,'activeVersionId':_0x172d60[_0x4409d7(0x1ff)],'conversation':this[_0x4409d7(0x195)](_0x172d60),'error':{'code':safeErrorCode(_0x4e2e71,_0x4409d7(0x1f0)),'message':_0x4409d7(0x208)}}});}[_0x132f42(0x18b)](_0x559c95,_0x3a8d23){const _0x4e0560=_0x132f42,_0x5e7b75=[...this[_0x4e0560(0x1d5)][_0x4e0560(0x213)]()][_0x4e0560(0x26f)](_0x4707d1=>_0x4707d1[_0x4e0560(0x29e)]===_0x559c95);if(_0x5e7b75[_0x4e0560(0x134)]===0x2*-0x62b+-0x5*0x2b4+0x19da)return![];const _0x4b5c60=this[_0x4e0560(0x187)][_0x4e0560(0x1c0)]?.(_0x3a8d23)??{'sequence':++this[_0x4e0560(0x125)],'category':_0x4e0560(0x172),'payload':_0x3a8d23};if(_0x4b5c60===undefined)return![];for(const _0x34a841 of _0x5e7b75){if(!_0x34a841[_0x4e0560(0x1ed)])_0x34a841[_0x4e0560(0x27b)][_0x4e0560(0x171)](_0x4b5c60);else this[_0x4e0560(0x1b2)](_0x34a841,_0x4b5c60);}return!![];}[_0x132f42(0x1b2)](_0xfbd318,_0x545314){const _0x573a5a=_0x132f42;this[_0x573a5a(0x187)][_0x573a5a(0x1d3)]?.({'type':_0x573a5a(0x18f),'workbenchConnectionId':_0xfbd318[_0x573a5a(0x153)],'watchId':_0xfbd318[_0x573a5a(0x19a)],'nodeGeneration':_0xfbd318[_0x573a5a(0x175)],'nodeId':this[_0x573a5a(0x187)][_0x573a5a(0x298)](),'templateId':_0xfbd318[_0x573a5a(0x219)],'conversationId':_0xfbd318[_0x573a5a(0x29e)],'expiresAt':_0xfbd318[_0x573a5a(0x22f)],'event':_0x545314});}[_0x132f42(0x1e8)](_0x340b50){const _0x522309=_0x132f42;return{'accepted':!![],'watchId':_0x340b50[_0x522309(0x19a)],'nodeGeneration':_0x340b50[_0x522309(0x175)],'expiresAt':_0x340b50[_0x522309(0x22f)]};}[_0x132f42(0x2a1)](_0x3a8344){const _0x34a2cd=_0x132f42;for(const _0x11fcb4 of[...this[_0x34a2cd(0x1d5)][_0x34a2cd(0x213)]()])if(_0x11fcb4[_0x34a2cd(0x29e)]===_0x3a8344)this[_0x34a2cd(0x101)](_0x11fcb4[_0x34a2cd(0xec)]);}[_0x132f42(0x101)](_0x15984b){const _0x1ebf7b=_0x132f42,_0x425123=this[_0x1ebf7b(0x1d5)][_0x1ebf7b(0x25c)](_0x15984b);if(_0x425123===undefined)return;clearTimeout(_0x425123[_0x1ebf7b(0x257)]),this[_0x1ebf7b(0x1d5)][_0x1ebf7b(0x234)](_0x15984b),this[_0x1ebf7b(0x286)][_0x1ebf7b(0x183)](_0x15984b,_0x425123[_0x1ebf7b(0x132)]);}[_0x132f42(0x230)](_0x23757d){const _0x4b9abb=_0x132f42,_0x55e4c2=setTimeout(()=>this[_0x4b9abb(0x101)](_0x23757d),WATCH_TTL_MS);return _0x55e4c2[_0x4b9abb(0x145)](),_0x55e4c2;}[_0x132f42(0x1d6)](_0x5b1f35,_0x23940c){const _0x43822d=_0x132f42,_0xf5c18a=this[_0x43822d(0x187)][_0x43822d(0x1ec)][_0x43822d(0x254)](_0x5b1f35,_0x23940c);if(this[_0x43822d(0x1fb)][_0x43822d(0x25a)](_0xf5c18a['id']))throw new Error(_0x43822d(0x14a));if(_0xf5c18a[_0x43822d(0x10e)]!==_0x43822d(0x102))throw new Error(_0x43822d(0x14a));return _0xf5c18a;}[_0x132f42(0x142)](_0x1f2855,_0x2a4aed,_0xd4e395){const _0x694637=_0x132f42;this[_0x694637(0x187)][_0x694637(0x1ec)][_0x694637(0x254)](_0x1f2855,_0x2a4aed);const _0x50ced6=this[_0x694637(0x10b)][_0x694637(0x25c)](_0xd4e395);if(_0x50ced6===undefined||_0x50ced6[_0x694637(0x27f)]!==_0x1f2855||_0x50ced6[_0x694637(0x29e)]!==_0x2a4aed)throw new Error(_0x694637(0x29d));return _0x50ced6;}async[_0x132f42(0x192)](_0x28f202,_0x151335){const _0x2885ad=_0x132f42;for(const _0x11c8af of this[_0x2885ad(0x10b)][_0x2885ad(0x213)]()){if(_0x11c8af[_0x2885ad(0x27f)]!==_0x28f202||_0x11c8af[_0x2885ad(0x29e)]!==_0x151335)continue;_0x11c8af[_0x2885ad(0x10e)]===_0x2885ad(0x221)&&(_0x11c8af[_0x2885ad(0x10e)]=_0x2885ad(0x11a),await rm(_0x11c8af[_0x2885ad(0x20b)],{'force':!![]})[_0x2885ad(0x149)](()=>undefined));}}async[_0x132f42(0x11e)](_0x1733ae,_0x234498,_0x14957d){const _0x29eb35=_0x132f42,_0x932765=this[_0x29eb35(0x187)][_0x29eb35(0x1ec)][_0x29eb35(0x127)](_0x1733ae,_0x234498,_0x14957d);if(_0x932765[_0x29eb35(0x1b0)]!==_0x29eb35(0x16d))throw new Error(_0x29eb35(0x26c));return await assertRegularFile(this[_0x29eb35(0x187)][_0x29eb35(0x1ec)][_0x29eb35(0x29f)](_0x1733ae,_0x932765),_0x932765[_0x29eb35(0x14c)]),_0x932765;}async[_0x132f42(0x151)](_0x2d11c1,_0x1ff4fe,_0x9e9f18,_0x500567,_0x2ebaac){const _0x41853f=_0x132f42;if(_0x2ebaac>_0x9e9f18[_0x41853f(0x285)][_0x41853f(0x1e5)])return _0x41853f(0x25f);if(_0x1ff4fe[_0x41853f(0x23a)][_0x41853f(0x295)]+_0x2ebaac>_0x1ff4fe[_0x41853f(0x23a)][_0x41853f(0x291)])return _0x41853f(0x1a8);const _0x54be97=await lstat(join(_0x2d11c1[_0x41853f(0x1a6)],_0x500567))[_0x41853f(0x149)](_0x5f229f=>{const _0xd3f411=_0x41853f;if(_0x5f229f[_0xd3f411(0xee)]===_0xd3f411(0x249))return undefined;throw _0x5f229f;});return _0x54be97===undefined?_0x41853f(0x165):_0x41853f(0x1cd);}[_0x132f42(0x200)](_0x9cbc26,_0x453aec,_0x597617,_0x274aa8){const _0x586e6a=_0x132f42,_0x578f67=[{'logicalPath':_0x586e6a(0xf3),'physicalPath':_0x453aec[_0x586e6a(0x15c)],'writable':![]},{'logicalPath':_0x586e6a(0x188),'physicalPath':_0x9cbc26[_0x586e6a(0x1a6)],'writable':!![]},{'logicalPath':_0x586e6a(0x191),'physicalPath':_0x9cbc26[_0x586e6a(0xf4)],'writable':!![]}];if(_0x597617!==undefined&&_0x274aa8!==undefined)_0x578f67[_0x586e6a(0x171)]({'logicalPath':_0x274aa8,'physicalPath':_0x597617,'writable':![]});if(_0x453aec[_0x586e6a(0x2a0)]!==undefined)_0x578f67[_0x586e6a(0x171)]({'logicalPath':_0x453aec[_0x586e6a(0x2a0)],'physicalPath':_0x453aec[_0x586e6a(0x15c)],'writable':![]},{'logicalPath':join(_0x453aec[_0x586e6a(0x2a0)],_0x586e6a(0x116)),'physicalPath':_0x9cbc26[_0x586e6a(0x1a6)],'writable':!![]},{'logicalPath':join(_0x453aec[_0x586e6a(0x2a0)],_0x586e6a(0x120)),'physicalPath':_0x9cbc26[_0x586e6a(0xf4)],'writable':!![]});return _0x578f67;}[_0x132f42(0x1a7)](_0x3aa61c,_0x4c5baf,_0x4e1ce8=_0x3aa61c[_0x132f42(0x28d)],_0x3da755,_0x2829f3){const _0x54fd18=_0x132f42;return this[_0x54fd18(0x187)][_0x54fd18(0x17d)]({'policyVersion':HOST_POLICY_VERSION,'workspaceDirectory':_0x4c5baf[_0x54fd18(0x15c)],..._0x4c5baf[_0x54fd18(0x2a0)]===undefined?{}:{'sourceWorkspacePath':_0x4c5baf[_0x54fd18(0x2a0)]},'inboxDirectory':_0x3aa61c[_0x54fd18(0x1a6)],'outputDirectory':_0x3aa61c[_0x54fd18(0xf4)],..._0x3da755===undefined||_0x2829f3===undefined?{}:{'generatedImagesDirectory':_0x3da755,'generatedImagesLogicalPath':_0x2829f3},'temporaryDirectory':_0x4e1ce8,'networkMode':_0x4c5baf[_0x54fd18(0x118)][_0x54fd18(0x21d)]});}[_0x132f42(0x13a)](_0xb72ea){const _0x3676c0=_0x132f42,_0xa417bc=this[_0x3676c0(0x187)][_0x3676c0(0x205)][_0x3676c0(0x1b5)][_0x3676c0(0xef)](_0x3676c0(0x1b7))[_0x3676c0(0x25c)](_0xb72ea);if(_0xa417bc===undefined)return undefined;if(typeof _0xa417bc['id']!==_0x3676c0(0x1bb))throw new Error(_0x3676c0(0x105));return _0xa417bc['id'];}async[_0x132f42(0x104)](_0x297f5b,_0x4b2393,_0x557f08=![]){const _0x309a66=_0x132f42,_0x115541=this[_0x309a66(0x187)][_0x309a66(0x205)][_0x309a66(0x1b5)][_0x309a66(0xef)](_0x309a66(0x1b6))[_0x309a66(0x25c)](_0x297f5b,_0x4b2393);if(_0x115541===undefined||_0x115541[_0x309a66(0x10e)]!==_0x309a66(0x103)&&_0x115541[_0x309a66(0x10e)]!==_0x309a66(0x1e7)||_0x115541[_0x309a66(0x22b)]!==HOST_POLICY_VERSION||typeof _0x115541[_0x309a66(0x1ce)]!==_0x309a66(0x1bb)||typeof _0x115541[_0x309a66(0x206)]!==_0x309a66(0x1bb)||typeof _0x115541[_0x309a66(0x135)]!==_0x309a66(0x1bb)||typeof _0x115541[_0x309a66(0x1ae)]!==_0x309a66(0x1bb)||typeof _0x115541[_0x309a66(0x161)]!==_0x309a66(0x1bb))throw new Error(_0x309a66(0x105));const _0x2a1fa6=this[_0x309a66(0x187)][_0x309a66(0x1ec)][_0x309a66(0x143)](_0x115541[_0x309a66(0x1ce)]),_0x84e81=join(_0x2a1fa6,_0x309a66(0x277)),_0x2f1a97=join(_0x2a1fa6,_0x309a66(0x19e)),_0x39c0ce=await lstat(_0x84e81)[_0x309a66(0x149)](()=>undefined),_0x59bceb=await lstat(_0x2f1a97)[_0x309a66(0x149)](()=>undefined);if(_0x39c0ce===undefined||!_0x39c0ce[_0x309a66(0x266)]()||_0x39c0ce[_0x309a66(0x242)]()||_0x59bceb===undefined||!_0x59bceb[_0x309a66(0x115)]()||_0x59bceb[_0x309a66(0x242)]())throw new Error(_0x309a66(0x105));let _0x36712e;try{const _0x317050=await readFile(_0x84e81,_0x309a66(0x14e)),_0x5f0795=_0x317050[_0x309a66(0x21e)]('\x0a')?_0x317050[_0x309a66(0x1c9)](-0xcd*-0x16+-0x274*-0x6+0x1*-0x2056,-(0x9e1+0x11ba+-0xdcd*0x2)):_0x317050;if(_0x5f0795!==_0x115541[_0x309a66(0x206)]||createHash(_0x309a66(0x1b9))[_0x309a66(0x1fc)](_0x5f0795)[_0x309a66(0x243)](_0x309a66(0x148))!==_0x115541[_0x309a66(0x1ae)])throw new Error(_0x309a66(0x105));_0x36712e=JSON[_0x309a66(0x27e)](_0x5f0795);}catch{throw new Error(_0x309a66(0x105));}if(!record(_0x36712e))throw new Error(_0x309a66(0x105));const _0x3c7f4b=publishedTemplateSnapshot(_0x36712e),_0x33fd49=publishedTemplateDraft(_0x3c7f4b[_0x309a66(0x24b)],_0x36712e[_0x309a66(0x118)]),_0xc27a06=_0x33fd49[_0x309a66(0x118)],_0x25800a=publishedMcpServers(_0x36712e[_0x309a66(0x1d4)]),_0x1f2244=publishedTemplateContentHash(_0x3c7f4b[_0x309a66(0x270)],_0x3c7f4b[_0x309a66(0x29c)],_0x3c7f4b[_0x309a66(0x24b)]),_0x52c96e=_0x3c7f4b[_0x309a66(0x29c)][_0x309a66(0xfc)]((_0x12bdec,_0x4fadea)=>_0x12bdec+_0x4fadea[_0x309a66(0x14c)],0xcba+0xa7*0x3b+0x751*-0x7);if(_0x36712e[_0x309a66(0x20d)]!==_0x115541[_0x309a66(0x161)]||createHash(_0x309a66(0x1b9))[_0x309a66(0x1fc)](JSON[_0x309a66(0x179)](_0x25800a))[_0x309a66(0x243)](_0x309a66(0x148))!==_0x115541[_0x309a66(0x161)]||_0x36712e[_0x309a66(0x1f7)]!==_0x115541[_0x309a66(0x135)]||_0x1f2244!==_0x115541[_0x309a66(0x135)]||_0x115541[_0x309a66(0x173)]!==_0x3c7f4b[_0x309a66(0x29c)][_0x309a66(0x134)]||_0x115541[_0x309a66(0x160)]!==_0x52c96e)throw new Error(_0x309a66(0x105));if(_0x36712e[_0x309a66(0x272)]!==_0x297f5b||_0x36712e[_0x309a66(0x219)]!==_0x4b2393||_0x36712e[_0x309a66(0x11d)]!==HOST_POLICY_VERSION||_0xc27a06[_0x309a66(0x219)]!==_0x4b2393||_0xc27a06[_0x309a66(0x298)]!==this[_0x309a66(0x187)][_0x309a66(0x298)]())throw new Error(_0x309a66(0x105));if(_0x557f08)await verifyPublishedTemplateContent(_0x2f1a97,_0x3c7f4b[_0x309a66(0x270)],_0x3c7f4b[_0x309a66(0x29c)]);return{'id':_0x297f5b,'templateId':_0x4b2393,'storageKey':_0x115541[_0x309a66(0x1ce)],'templateDirectory':_0x2f1a97,..._0x3c7f4b[_0x309a66(0x2a0)]===undefined?{}:{'sourceWorkspacePath':_0x3c7f4b[_0x309a66(0x2a0)]},'draft':_0xc27a06,'modelPolicy':_0x33fd49[_0x309a66(0x202)],'mcpServers':_0x25800a};}}function hostedRequest(_0x2411a1){const _0x27ccb9=_0x132f42;if(!record(_0x2411a1))throw new Error(_0x27ccb9(0x13e));const {__requestUserId:_0x5bf71e,__template:_0x3cd898,__marAgentModel:_0x1ed00c,__marAgentModels:_0x290083,__marAgentRuntimeScopeId:_0x758d4f,__workspaceWatchSessionHash:_0x308e35,__templateDeleted:_0x4d32a6,..._0x240a4b}=_0x2411a1;if(typeof _0x5bf71e!==_0x27ccb9(0x13b)||!Number[_0x27ccb9(0x287)](_0x5bf71e)||_0x5bf71e<=0x9d1+-0xc7+0x2*-0x485)throw new Error(_0x27ccb9(0x13e));if(_0x4d32a6!==undefined&&_0x4d32a6!==!![])throw new Error(_0x27ccb9(0x13e));if(_0x758d4f!==undefined&&(typeof _0x758d4f!==_0x27ccb9(0x1bb)||_0x758d4f[_0x27ccb9(0x134)]===0xc1a+0x428*0x1+-0x1042))throw new Error(_0x27ccb9(0x13e));return{'data':_0x240a4b,'userId':_0x5bf71e,..._0x3cd898===undefined?{}:{'template':_0x3cd898},..._0x1ed00c===undefined?{}:{'model':_0x1ed00c},..._0x290083===undefined?{}:{'models':_0x290083},..._0x758d4f===undefined?{}:{'runtimeScopeId':_0x758d4f},..._0x308e35===undefined?{}:{'sessionHash':_0x308e35},..._0x4d32a6===!![]?{'templateDeleted':!![]}:{}};}function requireWatchSessionHash(_0x2355cd){const _0x3cf618=_0x132f42;if(typeof _0x2355cd!==_0x3cf618(0x1bb)||_0x2355cd[_0x3cf618(0x134)]===0x1e93+-0x571+-0x2*0xc91)throw new Error(_0x3cf618(0x13e));return _0x2355cd;}function watchOwnerKey(_0x5bdca9,_0x1b2db6){return _0x5bdca9+':'+_0x1b2db6;}function runtimeModels(_0x402ef0){const _0xafc8d9=_0x132f42;return marAgentRuntimeModelConfigurationSchema[_0xafc8d9(0x1ac)]()[_0xafc8d9(0x27e)](_0x402ef0);}function allowedModels(_0x12bc36,_0x34ea21){const _0x2cab11=_0x132f42,_0x310ced=new Set(_0x12bc36[_0x2cab11(0x202)][_0x2cab11(0x1e3)]);return _0x34ea21[_0x2cab11(0x26f)](_0x5b701a=>_0x5b701a[_0x2cab11(0x269)]&&_0x310ced[_0x2cab11(0x25a)](_0x12bc36[_0x2cab11(0x202)][_0x2cab11(0x180)]===_0x2cab11(0x152)?_0x5b701a[_0x2cab11(0x22d)]:_0x5b701a['id']));}function selectModel(_0x3e1260,_0x3dabd1,_0x3dd8c2){const _0x366871=_0x132f42,_0x2bad5f=allowedModels(_0x3e1260,_0x3dabd1),_0x250878=_0x2bad5f[_0x366871(0x155)](_0x3d8b5e=>_0x3d8b5e['id']===_0x3dd8c2);if(_0x250878!==undefined)return _0x250878;const _0x25be7b=_0x2bad5f[_0x366871(0x155)](_0x43c2e8=>(_0x3e1260[_0x366871(0x202)][_0x366871(0x180)]===_0x366871(0x152)?_0x43c2e8[_0x366871(0x22d)]:_0x43c2e8['id'])===_0x3e1260[_0x366871(0x202)][_0x366871(0x10a)]);if(_0x25be7b!==undefined)return _0x25be7b;const _0x4cf494=_0x3e1260[_0x366871(0x202)][_0x366871(0x1e3)][_0x366871(0x273)](_0x555694=>_0x2bad5f[_0x366871(0x155)](_0x1d7172=>(_0x3e1260[_0x366871(0x202)][_0x366871(0x180)]===_0x366871(0x152)?_0x1d7172[_0x366871(0x22d)]:_0x1d7172['id'])===_0x555694))[_0x366871(0x155)](_0x722cfa=>_0x722cfa!==undefined);if(_0x4cf494===undefined)throw new Error(_0x366871(0xf7));return _0x4cf494;}function publishedTemplateDraft(_0x479708,_0x333a77){const _0x1d169a=_0x132f42,_0x30e623=conversationTemplateDraftSchema[_0x1d169a(0x15e)](_0x333a77);if(_0x30e623[_0x1d169a(0x164)]){const {allowedModels:_0x34e0ce,defaultModelId:_0x472bf3,..._0x58fd92}=_0x30e623[_0x1d169a(0x10c)];return{'draft':_0x58fd92,'modelPolicy':{'identity':_0x1d169a(0x152),'allowedIds':_0x34e0ce[_0x1d169a(0x273)](_0x3bf693=>_0x3bf693[_0x1d169a(0x22d)]),'defaultId':_0x472bf3}};}if(_0x479708!==-0x14*-0x1bf+0x2b3*-0x5+-0x156c||!record(_0x333a77)||_0x1d169a(0x137)in _0x333a77||!Array[_0x1d169a(0x265)](_0x333a77[_0x1d169a(0x174)]))throw new Error(_0x1d169a(0x105));const _0x1a610e=_0x333a77[_0x1d169a(0x174)],_0x3554d0={..._0x333a77};delete _0x3554d0[_0x1d169a(0x174)];const _0x12a68d=conversationTemplateDraftSchema[_0x1d169a(0x15e)]({..._0x3554d0,'allowedModels':_0x1a610e[_0x1d169a(0x273)](_0x12dd33=>({'modelId':_0x12dd33,'name':_0x12dd33}))});if(!_0x12a68d[_0x1d169a(0x164)])throw new Error(_0x1d169a(0x105));const {allowedModels:_0x4278fc,defaultModelId:_0x235ea5,..._0x1dc7c6}=_0x12a68d[_0x1d169a(0x10c)];return{'draft':_0x1dc7c6,'modelPolicy':{'identity':_0x1d169a(0x13f),'allowedIds':_0x4278fc[_0x1d169a(0x273)](_0x5397f8=>_0x5397f8[_0x1d169a(0x22d)]),'defaultId':_0x235ea5}};}function networkModels(_0x22f813,_0x58ac1f){const _0x457af4=_0x132f42;if(_0x58ac1f!==_0x457af4(0x290))return _0x22f813;return _0x22f813[_0x457af4(0x273)](_0x77c018=>_0x77c018[_0x457af4(0x252)]?{..._0x77c018,'hostedWebSearch':![]}:_0x77c018);}function publishedMcpServers(_0x166bf7){const _0xd811b2=_0x132f42;if(!Array[_0xd811b2(0x265)](_0x166bf7))throw new Error(_0xd811b2(0x105));return _0x166bf7[_0xd811b2(0x273)](_0x24bdbe=>{const _0xfc2e26=_0xd811b2;if(!record(_0x24bdbe))throw new Error(_0xfc2e26(0x105));const _0x25cae7=Object[_0xfc2e26(0x293)](_0x24bdbe)[_0xfc2e26(0x1fd)]()[_0xfc2e26(0x24c)](',');if(_0x25cae7!==_0xfc2e26(0x157))throw new Error(_0xfc2e26(0x105));const _0xe37cdb=mcpRuntimeDescriptorSchema[_0xfc2e26(0x27e)](_0x24bdbe[_0xfc2e26(0x1b3)]),_0x1e2df7=mcpInstallationConfigurationSchema[_0xfc2e26(0x27e)](_0x24bdbe[_0xfc2e26(0x11c)]);if(typeof _0x24bdbe['id']!==_0xfc2e26(0x1bb)||typeof _0x24bdbe[_0xfc2e26(0x13d)]!==_0xfc2e26(0x1bb)||typeof _0x24bdbe[_0xfc2e26(0x24f)]!==_0xfc2e26(0x1bb)||typeof _0x24bdbe[_0xfc2e26(0x214)]!==_0xfc2e26(0x1bb)||_0x24bdbe[_0xfc2e26(0x227)]!==_0xfc2e26(0x170)&&_0x24bdbe[_0xfc2e26(0x227)]!==_0xfc2e26(0x16e)||_0x24bdbe[_0xfc2e26(0x1bc)]!==_0xe37cdb[_0xfc2e26(0x1bc)])throw new Error(_0xfc2e26(0x105));return{'id':_0x24bdbe['id'],'serverName':_0x24bdbe[_0xfc2e26(0x13d)],'displayName':_0x24bdbe[_0xfc2e26(0x24f)],'version':_0x24bdbe[_0xfc2e26(0x214)],'origin':_0x24bdbe[_0xfc2e26(0x227)],'transport':_0xe37cdb[_0xfc2e26(0x1bc)],'runtime':_0xe37cdb,'configuration':_0x1e2df7};});}function publishedTemplateSnapshot(_0x1b22eb){const _0xd88e60=_0x132f42;if(_0x1b22eb[_0xd88e60(0x24b)]===-0x16ab*-0x1+-0x20b*-0x7+-0x1*0x24f7){const _0x40c8f0=publishedTemplateFiles(_0x1b22eb[_0xd88e60(0x1cf)]);return{'schemaVersion':0x1,'directories':legacyPublishedTemplateDirectories(_0x40c8f0),'entries':_0x40c8f0};}if(_0x1b22eb[_0xd88e60(0x24b)]!==0x18a0+-0x105e+0x30*-0x2c||typeof _0x1b22eb[_0xd88e60(0x2a0)]!==_0xd88e60(0x1bb)||!Array[_0xd88e60(0x265)](_0x1b22eb[_0xd88e60(0x270)])||!Array[_0xd88e60(0x265)](_0x1b22eb[_0xd88e60(0x29c)]))throw new Error(_0xd88e60(0x105));validatePublishedSourceWorkspacePath(_0x1b22eb[_0xd88e60(0x2a0)]);const _0x4377c6=_0x1b22eb[_0xd88e60(0x270)][_0xd88e60(0x273)](safePublishedTemplateRelativePath);if(new Set(_0x4377c6)[_0xd88e60(0x14c)]!==_0x4377c6[_0xd88e60(0x134)]||_0x4377c6[_0xd88e60(0x168)](_0xd88e60(0x116))||_0x4377c6[_0xd88e60(0x168)](_0xd88e60(0x120)))throw new Error(_0xd88e60(0x105));const _0x5d8658=_0x1b22eb[_0xd88e60(0x29c)][_0xd88e60(0x273)](publishedTemplateEntry);if(new Set(_0x5d8658[_0xd88e60(0x273)](_0x254f8f=>_0x254f8f[_0xd88e60(0x150)]))[_0xd88e60(0x14c)]!==_0x5d8658[_0xd88e60(0x134)])throw new Error(_0xd88e60(0x105));return{'schemaVersion':0x2,'sourceWorkspacePath':_0x1b22eb[_0xd88e60(0x2a0)],'directories':_0x4377c6,'entries':_0x5d8658};}function publishedTemplateEntry(_0x188963){const _0x57e00d=_0x132f42;if(!record(_0x188963))throw new Error(_0x57e00d(0x105));if(_0x188963[_0x57e00d(0x27a)]===_0x57e00d(0x1da))return publishedTemplateFile(_0x188963,!![]);if(_0x188963[_0x57e00d(0x27a)]!==_0x57e00d(0x194)||typeof _0x188963[_0x57e00d(0x109)]!==_0x57e00d(0x1bb)||_0x188963[_0x57e00d(0x109)][_0x57e00d(0x134)]===0x10a2*0x1+0x115*-0x3+-0xd63||_0x188963[_0x57e00d(0x109)][_0x57e00d(0x168)]('\x00')||_0x188963[_0x57e00d(0x1f2)]!==_0x57e00d(0x15b)&&_0x188963[_0x57e00d(0x1f2)]!==_0x57e00d(0x108)||typeof _0x188963[_0x57e00d(0x114)]!==_0x57e00d(0x1bb))throw new Error(_0x57e00d(0x105));const _0x2154fb=safePublishedTemplateRelativePath(_0x188963[_0x57e00d(0x150)]),_0x2c33d9=safePublishedTemplateSize(_0x188963[_0x57e00d(0x14c)]),_0x3bd033=_0x188963[_0x57e00d(0x109)],_0x3914b8=_0x188963[_0x57e00d(0x1f2)],_0x30867f=_0x188963[_0x57e00d(0x114)];if(_0x2c33d9!==Buffer[_0x57e00d(0x22c)](_0x3bd033))throw new Error(_0x57e00d(0x105));if(_0x3914b8===_0x57e00d(0x15b))safePublishedTemplateRelativePath(_0x30867f);else{if(!isAbsolute(_0x30867f)||!RUNTIME_LINK_ROOTS[_0x57e00d(0x258)](_0x1ed0e6=>_0x30867f===_0x1ed0e6||within(_0x1ed0e6,_0x30867f)))throw new Error(_0x57e00d(0x105));}return{'kind':_0x57e00d(0x194),'relativePath':_0x2154fb,'size':_0x2c33d9,'linkTarget':_0x3bd033,'targetKind':_0x3914b8,'resolvedTarget':_0x30867f};}function publishedTemplateFiles(_0x872e71){const _0x299daa=_0x132f42;if(!Array[_0x299daa(0x265)](_0x872e71))throw new Error(_0x299daa(0x105));const _0xe74efb=new Set();return _0x872e71[_0x299daa(0x273)](_0x54aa98=>{const _0xe8b2b8=_0x299daa,_0x2ff2f5=publishedTemplateFile(_0x54aa98);if(_0xe74efb[_0xe8b2b8(0x25a)](_0x2ff2f5[_0xe8b2b8(0x150)]))throw new Error(_0xe8b2b8(0x105));return _0xe74efb[_0xe8b2b8(0x1ad)](_0x2ff2f5[_0xe8b2b8(0x150)]),_0x2ff2f5;});}function publishedTemplateFile(_0x425ed5,_0x1a2e16=![]){const _0x1a6ca8=_0x132f42;if(!record(_0x425ed5)||_0x1a2e16&&_0x425ed5[_0x1a6ca8(0x27a)]!==_0x1a6ca8(0x1da)||typeof _0x425ed5[_0x1a6ca8(0x245)]!==_0x1a6ca8(0x279)||typeof _0x425ed5[_0x1a6ca8(0x1b9)]!==_0x1a6ca8(0x1bb)||!/^[a-f0-9]{64}$/u[_0x1a6ca8(0x1a1)](_0x425ed5[_0x1a6ca8(0x1b9)]))throw new Error(_0x1a6ca8(0x105));return{'kind':_0x1a6ca8(0x1da),'relativePath':safePublishedTemplateRelativePath(_0x425ed5[_0x1a6ca8(0x150)]),'size':safePublishedTemplateSize(_0x425ed5[_0x1a6ca8(0x14c)]),'executable':_0x425ed5[_0x1a6ca8(0x245)],'sha256':_0x425ed5[_0x1a6ca8(0x1b9)]};}function safePublishedTemplateRelativePath(_0x2b1bb6){const _0x2bf37a=_0x132f42;if(typeof _0x2b1bb6!==_0x2bf37a(0x1bb)||_0x2b1bb6[_0x2bf37a(0x134)]===-0x17f2+0x29*0x39+-0xed1*-0x1||_0x2b1bb6[_0x2bf37a(0x1fa)]('/')||_0x2b1bb6[_0x2bf37a(0x168)]('\x5c')||_0x2b1bb6[_0x2bf37a(0x184)]('/')[_0x2bf37a(0x258)](_0x2b62f3=>_0x2b62f3[_0x2bf37a(0x134)]===0xebe+0x239d*0x1+-0x325b||_0x2b62f3==='.'||_0x2b62f3==='..'))throw new Error(_0x2bf37a(0x105));return _0x2b1bb6;}function safePublishedTemplateSize(_0x337542){const _0x21bbea=_0x132f42;if(!Number[_0x21bbea(0x287)](_0x337542)||_0x337542<0x72c+0x495+-0xbc1)throw new Error(_0x21bbea(0x105));return _0x337542;}function legacyPublishedTemplateDirectories(_0x1ef060){const _0x484ab2=_0x132f42,_0x3ef86d=new Set();for(const _0x464c3b of _0x1ef060){const _0x1d0eee=_0x464c3b[_0x484ab2(0x150)][_0x484ab2(0x184)]('/');for(let _0x3f97b1=-0x1bf*-0x5+0x2b4*0x4+-0x138a;_0x3f97b1<_0x1d0eee[_0x484ab2(0x134)];_0x3f97b1+=0x7*-0x79+-0x4*0x61+0x4d4)_0x3ef86d[_0x484ab2(0x1ad)](_0x1d0eee[_0x484ab2(0x1c9)](-0x242+0x300+-0xbe,_0x3f97b1)[_0x484ab2(0x24c)]('/'));}return[..._0x3ef86d][_0x484ab2(0x1fd)]((_0x1495f9,_0x7ea03)=>_0x1495f9[_0x484ab2(0x226)](_0x7ea03,_0x484ab2(0x166)));}function publishedTemplateContentHash(_0x5da54f,_0x1db116,_0x5ec27b){const _0x13ee65=_0x132f42,_0xcdbd28=_0x5ec27b===-0x1feb+-0x1*-0x1faf+0x3d*0x1?_0x1db116[_0x13ee65(0x273)](_0x378ee7=>{const _0x1e4543=_0x13ee65;if(_0x378ee7[_0x1e4543(0x27a)]!==_0x1e4543(0x1da))throw new Error(_0x1e4543(0x105));return _0x378ee7[_0x1e4543(0x150)]+'\x00'+_0x378ee7[_0x1e4543(0x14c)]+'\x00'+_0x378ee7[_0x1e4543(0x1b9)];})[_0x13ee65(0x24c)]('\x0a'):[..._0x5da54f[_0x13ee65(0x273)](_0xe475d7=>_0x13ee65(0x294)+_0xe475d7),..._0x1db116[_0x13ee65(0x273)](_0x52b050=>_0x52b050[_0x13ee65(0x27a)]===_0x13ee65(0x1da)?_0x52b050[_0x13ee65(0x27a)]+'\x00'+_0x52b050[_0x13ee65(0x150)]+'\x00'+_0x52b050[_0x13ee65(0x14c)]+'\x00'+(_0x52b050[_0x13ee65(0x245)]?0x21e6+0x1*-0xd87+-0x2*0xa2f:-0x13*-0x108+0x1*-0x1bc5+0x82d)+'\x00'+_0x52b050[_0x13ee65(0x1b9)]:_0x52b050[_0x13ee65(0x27a)]+'\x00'+_0x52b050[_0x13ee65(0x150)]+'\x00'+_0x52b050[_0x13ee65(0x14c)]+'\x00'+_0x52b050[_0x13ee65(0x109)]+'\x00'+_0x52b050[_0x13ee65(0x1f2)]+'\x00'+_0x52b050[_0x13ee65(0x114)])][_0x13ee65(0x24c)]('\x0a');return createHash(_0x13ee65(0x1b9))[_0x13ee65(0x1fc)](_0xcdbd28)[_0x13ee65(0x243)](_0x13ee65(0x148));}function _0x1c9a(_0x4807cf,_0x16023d){_0x4807cf=_0x4807cf-(0x1ea0+-0x1e77+-0x61*-0x2);const _0x583611=_0x5676();let _0xca8a95=_0x583611[_0x4807cf];if(_0x1c9a['tEbnkP']===undefined){var _0x318dc7=function(_0x1f0fef){const _0x276d27='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x1b97bd='',_0x1b4b01='';for(let _0x332007=0x212d+0x1*0x1999+0x1*-0x3ac6,_0x387968,_0x22ccae,_0x1bebeb=-0x141c+-0x1*-0x183+-0x3*-0x633;_0x22ccae=_0x1f0fef['charAt'](_0x1bebeb++);~_0x22ccae&&(_0x387968=_0x332007%(0x110+-0x2611+0x15f*0x1b)?_0x387968*(-0x4*-0x65+0x1da5+0x1ef9*-0x1)+_0x22ccae:_0x22ccae,_0x332007++%(-0x13*-0x7b+0xd47+-0x1664))?_0x1b97bd+=String['fromCharCode'](-0x257a+-0x1c8+0xf*0x2af&_0x387968>>(-(0xf0+-0x1654+0x16*0xf9)*_0x332007&0xa7*0x13+-0x376*-0x4+-0x3*0x8bd)):-0x100+-0x1*0xc47+0xb*0x135){_0x22ccae=_0x276d27['indexOf'](_0x22ccae);}for(let _0x3cead6=-0xb*0x3d+0xb*0xcc+-0x625,_0x51a504=_0x1b97bd['length'];_0x3cead6<_0x51a504;_0x3cead6++){_0x1b4b01+='%'+('00'+_0x1b97bd['charCodeAt'](_0x3cead6)['toString'](0x301*0x9+0x1304+-0x2dfd*0x1))['slice'](-(-0xa39*0x3+0x1*-0xaa2+0x294f));}return decodeURIComponent(_0x1b4b01);};_0x1c9a['eWDsDj']=_0x318dc7,_0x1c9a['hEJBGu']={},_0x1c9a['tEbnkP']=!![];}const _0x222073=_0x583611[-0x1c0f+0x4c6*0x7+-0x55b];_0x1c9a['TPuxWz']!==_0x222073&&(_0x1c9a['hEJBGu']={},_0x1c9a['TPuxWz']=_0x222073);const _0x253817=_0x1c9a['hEJBGu'][_0x4807cf];return _0x253817===undefined?(_0xca8a95=_0x1c9a['eWDsDj'](_0xca8a95),_0x1c9a['hEJBGu'][_0x4807cf]=_0xca8a95):_0xca8a95=_0x253817,_0xca8a95;}async function verifyPublishedTemplateContent(_0x10c5ed,_0x565a21,_0x1e1b7d){const _0x35648c=_0x132f42,_0x21fb23=new Map(_0x1e1b7d[_0x35648c(0x273)](_0x5cf9a6=>[_0x5cf9a6[_0x35648c(0x150)],_0x5cf9a6])),_0x493d80=new Set([..._0x565a21,_0x35648c(0x116),_0x35648c(0x120)]),_0x1ee991=new Set(),_0x1a654b=await listPublishedTemplateEntries(_0x10c5ed,_0x493d80,_0x1ee991);if(_0x1a654b[_0x35648c(0x134)]!==_0x21fb23[_0x35648c(0x14c)]||_0x1ee991[_0x35648c(0x14c)]!==_0x493d80[_0x35648c(0x14c)])throw new Error(_0x35648c(0x105));for(const _0x22a627 of _0x1a654b){const _0x287e98=_0x21fb23[_0x35648c(0x25c)](_0x22a627[_0x35648c(0x150)]);if(_0x287e98===undefined||_0x287e98[_0x35648c(0x27a)]!==_0x22a627[_0x35648c(0x27a)])throw new Error(_0x35648c(0x105));if(_0x287e98[_0x35648c(0x27a)]===_0x35648c(0x1da)&&_0x22a627[_0x35648c(0x27a)]===_0x35648c(0x1da)){if(_0x287e98[_0x35648c(0x14c)]!==_0x22a627[_0x35648c(0x14c)]||_0x287e98[_0x35648c(0x245)]!==_0x22a627[_0x35648c(0x245)]||_0x22a627[_0x35648c(0x1cb)]!==(_0x287e98[_0x35648c(0x245)]?-0x1feb*0x1+-0xa*-0x185+0x1226:0x2*-0xf1+-0xdba+-0x8*-0x218)||_0x287e98[_0x35648c(0x1b9)]!==_0x22a627[_0x35648c(0x1b9)])throw new Error(_0x35648c(0x105));continue;}if(_0x287e98[_0x35648c(0x27a)]!==_0x35648c(0x194)||_0x22a627[_0x35648c(0x27a)]!==_0x35648c(0x194)||_0x287e98[_0x35648c(0x14c)]!==_0x22a627[_0x35648c(0x14c)]||_0x287e98[_0x35648c(0x109)]!==_0x22a627[_0x35648c(0x109)])throw new Error(_0x35648c(0x105));await verifyPublishedSymlinkResolution(_0x10c5ed,_0x287e98,_0x22a627[_0x35648c(0x106)]);}}async function verifyPublishedSymlinkResolution(_0x48871d,_0x11703f,_0x14a53e){const _0x3856b9=_0x132f42;let _0x1cd735;try{_0x1cd735=await realpath(_0x14a53e);}catch{throw new Error(_0x3856b9(0x105));}if(_0x11703f[_0x3856b9(0x1f2)]===_0x3856b9(0x108)){if(_0x1cd735!==_0x11703f[_0x3856b9(0x114)])throw new Error(_0x3856b9(0x105));return;}let _0x2b897e,_0x5b39c6;try{[_0x2b897e,_0x5b39c6]=await Promise[_0x3856b9(0x218)]([realpath(join(_0x48871d,..._0x11703f[_0x3856b9(0x114)][_0x3856b9(0x184)]('/'))),realpath(_0x48871d)]);}catch{throw new Error(_0x3856b9(0x105));}if(_0x1cd735!==_0x2b897e||!within(_0x5b39c6,_0x1cd735))throw new Error(_0x3856b9(0x105));}async function listPublishedTemplateEntries(_0x5ab9f4,_0x109ad2,_0x1d6815,_0xabd821=''){const _0x482123=_0x132f42,_0x53dcb6=await lstat(_0x5ab9f4);if(!_0x53dcb6[_0x482123(0x115)]()||_0x53dcb6[_0x482123(0x242)]()||(_0x53dcb6[_0x482123(0x1cb)]&0xf46+-0x12f0+-0xcf*-0x7)!==-0xbe9*0x2+0x1a32+0x9*-0x1b)throw new Error(_0x482123(0x105));const _0x4217b5=[];for(const _0x3bc733 of await readdir(_0x5ab9f4,{'withFileTypes':!![]})){const _0x21d02d=join(_0x5ab9f4,_0x3bc733[_0x482123(0x22e)]),_0x43b557=_0xabd821[_0x482123(0x134)]===0x1042*-0x1+-0x7*-0x505+-0x12e1?_0x3bc733[_0x482123(0x22e)]:_0xabd821+'/'+_0x3bc733[_0x482123(0x22e)],_0x1e89d8=await lstat(_0x21d02d);if(_0x1e89d8[_0x482123(0x242)]()){const _0x4fcc30=await readlink(_0x21d02d);_0x4217b5[_0x482123(0x171)]({'kind':_0x482123(0x194),'relativePath':_0x43b557,'size':Buffer[_0x482123(0x22c)](_0x4fcc30),'linkTarget':_0x4fcc30,'sourcePath':_0x21d02d});continue;}if(_0x1e89d8[_0x482123(0x115)]()){if(!_0x109ad2[_0x482123(0x25a)](_0x43b557))throw new Error(_0x482123(0x105));_0x1d6815[_0x482123(0x1ad)](_0x43b557),_0x4217b5[_0x482123(0x171)](...await listPublishedTemplateEntries(_0x21d02d,_0x109ad2,_0x1d6815,_0x43b557));}else{if(!_0x1e89d8[_0x482123(0x266)]()||_0x1e89d8[_0x482123(0xf6)]!==0xa12+-0x2cc*0x8+0xc4f||!Number[_0x482123(0x287)](_0x1e89d8[_0x482123(0x14c)]))throw new Error(_0x482123(0x105));_0x4217b5[_0x482123(0x171)]({'kind':_0x482123(0x1da),'relativePath':_0x43b557,'size':_0x1e89d8[_0x482123(0x14c)],'executable':(_0x1e89d8[_0x482123(0x1cb)]&-0x9ea+0x7d8+-0x1*-0x25b)!==0xa51+0x1d*0x10f+-0x2904,'mode':_0x1e89d8[_0x482123(0x1cb)]&-0x130a+-0xc*0x20c+0x2d99,'sha256':createHash(_0x482123(0x1b9))[_0x482123(0x1fc)](await readFile(_0x21d02d))[_0x482123(0x243)](_0x482123(0x148))});}}return _0x4217b5;}function validatePublishedSourceWorkspacePath(_0x2e1f11){const _0x36ff20=_0x132f42;if(!isAbsolute(_0x2e1f11)||resolve(_0x2e1f11)!==_0x2e1f11||_0x2e1f11==='/'||RESERVED_SANDBOX_ROOTS[_0x36ff20(0x258)](_0x1bd768=>_0x2e1f11===_0x1bd768||within(_0x1bd768,_0x2e1f11)||within(_0x2e1f11,_0x1bd768)))throw new Error(_0x36ff20(0x105));}function within(_0x38b904,_0x5e7650){const _0x2eecfd=_0x132f42,_0x3df644=relative(_0x38b904,_0x5e7650);return _0x3df644[_0x2eecfd(0x134)]>-0x1*-0x7db+-0x1*0x1817+0x103c&&_0x3df644!=='..'&&!_0x3df644[_0x2eecfd(0x1fa)]('..'+sep);}function resolveMcpServers(_0x590753,_0x5e7b6c){const _0x10b2b7=_0x132f42,_0x360a69=_0x1d2b40=>{const _0x1354c5=_0x1c9a,_0x220f3b={};for(const [_0x572dad,_0x20edbe]of Object[_0x1354c5(0x29c)](_0x1d2b40??{})){const _0x1f2518=_0x5e7b6c[_0x20edbe[_0x1354c5(0x17f)]];if(_0x1f2518===undefined)throw new Error(_0x1354c5(0x264));_0x220f3b[_0x572dad]=_0x1f2518;}return _0x220f3b;};return _0x590753[_0x10b2b7(0x1d4)][_0x10b2b7(0x1bd)](_0x838011=>{const _0x1ae800=_0x10b2b7;if(_0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x1bc)]===_0x1ae800(0x1d8)){if(_0x590753[_0x1ae800(0x118)][_0x1ae800(0x21d)]!==_0x1ae800(0x1e9))return[];return[{'name':_0x838011[_0x1ae800(0x13d)],'lifecycle':_0x1ae800(0x1dd),'transport':_0x1ae800(0x1d8),'url':_0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x176)],'headers':{..._0x360a69(_0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x207)]),..._0x360a69(_0x838011[_0x1ae800(0x11c)][_0x1ae800(0x207)])}}];}return[{'name':_0x838011[_0x1ae800(0x13d)],'lifecycle':_0x1ae800(0x1dd),'transport':_0x1ae800(0x220),'command':_0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x263)],'args':[..._0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x296)],..._0x838011[_0x1ae800(0x11c)][_0x1ae800(0x255)]??[]],'environment':{..._0x360a69(_0x838011[_0x1ae800(0x1b3)][_0x1ae800(0x1eb)]),..._0x360a69(_0x838011[_0x1ae800(0x11c)][_0x1ae800(0x1eb)])}}];});}function hostedConversationSummary(_0x5499af,_0x396b6b){const _0x3a0cd7=_0x132f42;return hostedConversationSummarySchema[_0x3a0cd7(0x27e)]({'id':_0x5499af['id'],'nodeId':_0x5499af[_0x3a0cd7(0x298)],'sessionId':_0x5499af[_0x3a0cd7(0x292)],'templateId':_0x5499af[_0x3a0cd7(0x219)],'templateName':_0x5499af[_0x3a0cd7(0x28b)],'activeVersionId':_0x5499af[_0x3a0cd7(0x1ff)],'title':_0x5499af[_0x3a0cd7(0x28c)],'pinnedAt':_0x5499af[_0x3a0cd7(0x241)],'status':_0x5499af[_0x3a0cd7(0x10e)],'modelId':_0x5499af[_0x3a0cd7(0x22d)],'createdAt':_0x5499af[_0x3a0cd7(0x2a2)],'updatedAt':_0x5499af[_0x3a0cd7(0x17a)],'lastActivityAt':_0x5499af[_0x3a0cd7(0x1c2)],..._0x396b6b===undefined?{}:{'activity':_0x396b6b}});}function templateSummary(_0x28ae3a,_0x1dde76){const _0x57b8ee=_0x132f42;return conversationTemplateSummarySchema[_0x57b8ee(0x27e)]({'id':_0x28ae3a[_0x57b8ee(0x219)],'nodeId':_0x28ae3a[_0x57b8ee(0x298)],'name':_0x28ae3a[_0x57b8ee(0x28b)],'description':_0x1dde76[_0x57b8ee(0x12f)],'status':_0x28ae3a[_0x57b8ee(0xfa)]?_0x57b8ee(0x271):_0x57b8ee(0x102),'currentVersionId':_0x28ae3a[_0x57b8ee(0x1ff)],'available':!_0x28ae3a[_0x57b8ee(0xfa)],'createdAt':_0x28ae3a[_0x57b8ee(0x2a2)],'updatedAt':_0x1dde76[_0x57b8ee(0x17a)]});}function modelSummary(_0x172b3a,_0x1639a9){const _0xc3d6e4=_0x132f42;return{'id':_0x172b3a['id'],'name':_0x172b3a[_0xc3d6e4(0x22e)],'protocol':_0x172b3a[_0xc3d6e4(0x229)],'baseUrl':_0x172b3a[_0xc3d6e4(0x1ee)],'modelId':_0x172b3a[_0xc3d6e4(0x22d)],'contextWindowTokens':_0x172b3a[_0xc3d6e4(0x185)],'maxOutputTokens':_0x172b3a[_0xc3d6e4(0x1c3)],'inputCapabilities':_0x172b3a[_0xc3d6e4(0x138)],'outputCapabilities':_0x172b3a[_0xc3d6e4(0x100)],'reasoningEfforts':_0x172b3a[_0xc3d6e4(0x146)],'hostedWebSearch':_0x172b3a[_0xc3d6e4(0x252)],..._0x172b3a[_0xc3d6e4(0xfe)]===undefined?{}:{'responsesTransport':_0x172b3a[_0xc3d6e4(0xfe)]},'responsesPreviousResponseId':_0x172b3a[_0xc3d6e4(0x110)],'enabled':_0x172b3a[_0xc3d6e4(0x269)],'sortOrder':_0x1639a9,'apiKeyConfigured':!![]};}function systemInstruction(_0x4a4d6d,_0x2aefc4){const _0x212c94=_0x132f42,_0x5cddf6=_0x4a4d6d[_0x212c94(0x118)],_0x4e3545=_0x5cddf6[_0x212c94(0x21d)]===_0x212c94(0x290)?_0x212c94(0x131):_0x212c94(0x22a);return[_0x212c94(0x225),_0x212c94(0x280),_0x212c94(0x1cc),..._0x2aefc4===undefined?[]:[_0x212c94(0x12c)+_0x2aefc4+_0x212c94(0x144),_0x212c94(0x119)+_0x2aefc4+_0x212c94(0x167)+_0x2aefc4+_0x212c94(0xfd)],..._0x4a4d6d[_0x212c94(0x2a0)]===undefined?[]:[_0x212c94(0x24a)+_0x4a4d6d[_0x212c94(0x2a0)]+_0x212c94(0x1d1)+join(_0x4a4d6d[_0x212c94(0x2a0)],_0x212c94(0x116))+_0x212c94(0x203)+join(_0x4a4d6d[_0x212c94(0x2a0)],_0x212c94(0x120))+_0x212c94(0x23c)],_0x212c94(0x19f),_0x4e3545][_0x212c94(0x24c)]('\x0a');}function attachmentPrompt(_0x5cff0e,_0x276522){const _0x5c811c=_0x132f42;if(_0x276522[_0x5c811c(0x134)]===0x8d1+0x12b*-0x1a+0x158d)return _0x5cff0e;const _0x1cece1=_0x276522[_0x5c811c(0x273)](_0xbc7bc2=>_0x5c811c(0x1f5)+_0xbc7bc2[_0x5c811c(0x150)])[_0x5c811c(0x24c)]('\x0a');return''+_0x5cff0e+(_0x5cff0e[_0x5c811c(0x239)]()[_0x5c811c(0x134)]===0x2*0xd1+0x324*-0x5+0x2*0x709?'':'\x0a\x0a')+_0x5c811c(0x233)+_0x1cece1;}function automaticHostedConversationTitle(_0x21ca45){const _0x1a59f0=_0x132f42;if(_0x21ca45===undefined)return undefined;const _0x130e79=sessionTitleFromFirstMessage(_0x21ca45);if(_0x130e79[_0x1a59f0(0x134)]===0x347+0x571*0x1+0x24*-0x3e||/^(?:new|untitled) session(?:\s*[-–—:]\s*\d{4}-\d{2}-\d{2}.*)?$/iu[_0x1a59f0(0x1a1)](_0x130e79))return undefined;return _0x130e79;}function runFromMessage(_0x59d47d){const _0x54d8ec=_0x132f42;return{'id':_0x59d47d[_0x54d8ec(0x15f)],'status':_0x59d47d[_0x54d8ec(0x10e)],'startedAt':_0x59d47d[_0x54d8ec(0x2a2)],'completedAt':_0x59d47d[_0x54d8ec(0x10e)]===_0x54d8ec(0x25b)?null:_0x59d47d[_0x54d8ec(0x17a)]};}function runInterruptionKey(_0x2fbd11,_0x406cbc){return _0x2fbd11+'\x00'+_0x406cbc;}function uploadProjection(_0x41cf2e){const _0x4891c3=_0x132f42;return{'uploadId':_0x41cf2e[_0x4891c3(0x1f3)],'conversationId':_0x41cf2e[_0x4891c3(0x29e)],'name':_0x41cf2e[_0x4891c3(0x22e)],'mimeType':_0x41cf2e[_0x4891c3(0x126)],'receivedBytes':_0x41cf2e[_0x4891c3(0x1be)],'size':_0x41cf2e[_0x4891c3(0x14c)],'status':_0x41cf2e[_0x4891c3(0x10e)],..._0x41cf2e[_0x4891c3(0x159)]===undefined?{}:{'file':_0x41cf2e[_0x4891c3(0x159)]}};}async function assertRegularFile(_0xe02c18,_0x2e3eb1){const _0x379561=_0x132f42,_0x4d9091=await lstat(_0xe02c18)[_0x379561(0x149)](()=>{const _0x6cd7dc=_0x379561;throw new Error(_0x6cd7dc(0x27c));});if(!_0x4d9091[_0x379561(0x266)]()||_0x4d9091[_0x379561(0x242)]()||_0x4d9091[_0x379561(0xf6)]!==-0x142*-0x5+0x11*0x5f+0x1a*-0x7c||_0x4d9091[_0x379561(0x14c)]!==_0x2e3eb1)throw new Error(_0x379561(0x27c));}async function assertUploadTemporaryFile(_0x462fc9,_0x52e1a1){const _0x1c1eed=_0x132f42,_0x48458f=await lstat(_0x462fc9)[_0x1c1eed(0x149)](()=>{const _0x398f2e=_0x1c1eed;throw new Error(_0x398f2e(0x1e1));});if(!_0x48458f[_0x1c1eed(0x266)]()||_0x48458f[_0x1c1eed(0x242)]()||_0x48458f[_0x1c1eed(0xf6)]!==0x1121*0x2+-0x3*-0x82a+-0x3abf||_0x48458f[_0x1c1eed(0x14c)]!==_0x52e1a1)throw new Error(_0x1c1eed(0x1e1));}function record(_0x5480d1){const _0x5aecf1=_0x132f42;return typeof _0x5480d1===_0x5aecf1(0x260)&&_0x5480d1!==null&&!Array[_0x5aecf1(0x265)](_0x5480d1);}
|
|
2
|
+
const _0x44e8b5=_0x2016;(function(_0x4d70a1,_0x58302a){const _0x5236e8=_0x2016,_0x2a2eae=_0x4d70a1();while(!![]){try{const _0x3ed410=parseInt(_0x5236e8(0x14c))/(-0xc*-0x11c+0x169a+-0x13d*0x1d)+parseInt(_0x5236e8(0x256))/(-0x2340+0x1*0x1b09+-0x1a5*-0x5)*(-parseInt(_0x5236e8(0x174))/(0x169f*0x1+-0x1c5*-0x16+-0x1ec5*0x2))+-parseInt(_0x5236e8(0xe6))/(0x1*0x2565+0x1435+0x17a*-0x27)*(-parseInt(_0x5236e8(0x1cf))/(0x1bb8+0x656+-0x2209))+-parseInt(_0x5236e8(0x226))/(0x1dca+0xd35+-0x2af9)+parseInt(_0x5236e8(0xd5))/(0x2*0xea2+0x941*-0x1+0x9fe*-0x2)*(-parseInt(_0x5236e8(0x214))/(-0x2e2+-0x1654+0x12*0x167))+parseInt(_0x5236e8(0xd9))/(-0x123*0x1+-0x61c*-0x3+0x44a*-0x4)+-parseInt(_0x5236e8(0x201))/(0x1*0x1233+-0xdd2+0xb*-0x65)*(-parseInt(_0x5236e8(0x133))/(-0x130c+0xdc6+-0x551*-0x1));if(_0x3ed410===_0x58302a)break;else _0x2a2eae['push'](_0x2a2eae['shift']());}catch(_0x4824ab){_0x2a2eae['push'](_0x2a2eae['shift']());}}}(_0xed8b,0x1b*-0x221e+-0xd7f*0x32+-0x21b1*-0x3e));import{createHash,randomUUID}from'node:crypto';import{lstat,mkdir,open,readFile,rename,rm,utimes}from'node:fs/promises';import{isAbsolute,join,relative,resolve,sep}from'node:path';import{conversationTemplateDraftSchema,conversationTemplateSummarySchema,hostedConversationConfigUpdateInputSchema,hostedConversationCreateInputSchema,hostedConversationDeleteResultSchema,hostedConversationFileDeleteInputSchema,hostedConversationFileDeleteResultSchema,hostedConversationFileReadInputSchema,hostedConversationFileReadResultSchema,hostedConversationFilesSchema,hostedConversationIdInputSchema,hostedConversationImageReadInputSchema,hostedConversationListInputSchema,hostedConversationListPageSchema,hostedConversationMessageInputSchema,hostedConversationMetadataUpdateInputSchema,hostedConversationSnapshotSchema,hostedConversationSummarySchema,hostedConversationUnwatchInputSchema,hostedConversationUploadChunkInputSchema,hostedConversationUploadControlInputSchema,hostedConversationUploadCreateInputSchema,hostedConversationUploadPreflightInputSchema,hostedConversationUploadPreflightResultSchema,hostedConversationUploadSchema,hostedConversationWatchInputSchema,marAgentRuntimeModelConfigurationSchema,mcpInstallationConfigurationSchema,mcpRuntimeDescriptorSchema}from'@myagentroam/protocol';import{hostedConversationGeneratedImagesDisplayDirectory,hostedConversationImageRunId,marAgentGeneratedImagesDirectory}from'../runner/mar-agent/generated-images.js';import{sessionTitleFromFirstMessage}from'../util/node-operation-parsers.js';import{safeErrorCode}from'../util/safe-error.js';import{SessionWatchSlotCoordinator}from'./session-watch-slot-coordinator.js';const HOST_POLICY_VERSION=-0x2101+-0x187e+-0x398*-0x10,MAX_FILE_READ_BYTES=(-0x22cf+0x5c*-0x3b+0x3a03)*(0x2426+-0x587*-0x5+-0x3bc9),WATCH_TTL_MS=0x7*-0x298b+0x8a99+0x3*0x6d54,RUNTIME_LINK_ROOTS=[_0x44e8b5(0x13a),_0x44e8b5(0x176),_0x44e8b5(0x18d),_0x44e8b5(0x245),_0x44e8b5(0x231)],RESERVED_SANDBOX_ROOTS=[_0x44e8b5(0x1e1),_0x44e8b5(0xe0),_0x44e8b5(0x24b),_0x44e8b5(0x13a),_0x44e8b5(0x176),_0x44e8b5(0x18d),_0x44e8b5(0x245),_0x44e8b5(0x231),_0x44e8b5(0x238),_0x44e8b5(0x168),_0x44e8b5(0x1f4),_0x44e8b5(0x1ec)];export class HostedConversationNodeService{[_0x44e8b5(0x149)];[_0x44e8b5(0x1e4)];['id'];[_0x44e8b5(0x18a)]=new Map();[_0x44e8b5(0x266)]=new Map();[_0x44e8b5(0x10a)]=new Map();[_0x44e8b5(0x24e)]=new Map();[_0x44e8b5(0x145)]=new Map();[_0x44e8b5(0x25f)]=new Set();[_0x44e8b5(0x1ca)]=new Map();[_0x44e8b5(0x1f6)]=new Map();[_0x44e8b5(0x259)]=new Set();[_0x44e8b5(0x13c)]=new Map();[_0x44e8b5(0x1de)]=new Set();[_0x44e8b5(0x155)];[_0x44e8b5(0x1fc)]=![];[_0x44e8b5(0x215)]=0x1086+-0x57b+0xb0b*-0x1;[_0x44e8b5(0x199)]=0xe9*-0x21+0x1*0x24dc+-0x1*0x6d3;constructor(_0x2bb977){const _0xda4ee6=_0x44e8b5;this[_0xda4ee6(0x149)]=_0x2bb977,this[_0xda4ee6(0x1e4)]=_0x2bb977[_0xda4ee6(0x1e4)]??Date[_0xda4ee6(0x1e4)],this['id']=_0x2bb977['id']??randomUUID,this[_0xda4ee6(0x155)]=_0x2bb977[_0xda4ee6(0x155)]??new SessionWatchSlotCoordinator();}[_0x44e8b5(0x1ed)](){const _0x302f6d=_0x44e8b5;return{'conversation.hosted.list':_0x4b56d9=>this[_0x302f6d(0x1a8)](_0x4b56d9),'conversation.hosted.create':_0x2b2fd3=>this[_0x302f6d(0x154)](_0x2b2fd3),'conversation.hosted.get':_0x2e6f2e=>this[_0x302f6d(0x225)](_0x2e6f2e),'conversation.hosted.watch':_0x4ef5e5=>this[_0x302f6d(0x126)](_0x4ef5e5),'conversation.hosted.unwatch':_0x12624b=>this[_0x302f6d(0x114)](_0x12624b),'conversation.hosted.message':_0x512f01=>this[_0x302f6d(0x15f)](_0x512f01),'conversation.hosted.interrupt':_0x1e61a7=>this[_0x302f6d(0x17f)](_0x1e61a7),'conversation.hosted.config.update':_0x3bb78e=>this[_0x302f6d(0x1d9)](_0x3bb78e),'conversation.hosted.metadata.update':_0x2a2410=>this[_0x302f6d(0x21e)](_0x2a2410),'conversation.hosted.image.read':_0x1e40f5=>this[_0x302f6d(0x11f)](_0x1e40f5),'conversation.hosted.files.list':_0x8e2256=>this[_0x302f6d(0x261)](_0x8e2256),'conversation.hosted.file.read':_0x162736=>this[_0x302f6d(0x1a5)](_0x162736),'conversation.hosted.file.delete':_0x5cd959=>this[_0x302f6d(0x170)](_0x5cd959),'conversation.hosted.files.upload.preflight':_0x4e37c1=>this[_0x302f6d(0x177)](_0x4e37c1),'conversation.hosted.files.upload.create':_0x37ef55=>this[_0x302f6d(0x14f)](_0x37ef55),'conversation.hosted.files.upload.chunk':_0x5ce35e=>this[_0x302f6d(0x228)](_0x5ce35e),'conversation.hosted.files.upload.status':_0x425cee=>this[_0x302f6d(0xf2)](_0x425cee),'conversation.hosted.files.upload.complete':_0x1db4a7=>this[_0x302f6d(0x1ba)](_0x1db4a7),'conversation.hosted.files.upload.cancel':_0x6ab029=>this[_0x302f6d(0xd7)](_0x6ab029),'conversation.hosted.delete':_0x240683=>this[_0x302f6d(0xe8)](_0x240683)};}[_0x44e8b5(0x1f5)](){const _0xe41caf=_0x44e8b5;if(this[_0xe41caf(0x1fc)]||this[_0xe41caf(0x266)][_0xe41caf(0x21a)]>0x33*-0x3d+0x192d+-0x1*0xd06||this[_0xe41caf(0x10a)][_0xe41caf(0x21a)]>0xb*-0x33d+-0xb1b*0x3+0x44f0||this[_0xe41caf(0x24e)][_0xe41caf(0x21a)]>-0x175f+0x1237+-0x28*-0x21)return undefined;return this[_0xe41caf(0x1fc)]=!![],()=>{const _0x609a71=_0xe41caf;this[_0x609a71(0x1fc)]=![];};}[_0x44e8b5(0x1a8)](_0x1697d6){const _0x8e4f03=_0x44e8b5,_0x30deea=hostedRequest(_0x1697d6),_0x11da2e=hostedConversationListInputSchema[_0x8e4f03(0x183)](_0x30deea[_0x8e4f03(0x189)]),_0x38a67c=this[_0x8e4f03(0x149)][_0x8e4f03(0x249)][_0x8e4f03(0x1c5)]({'userId':_0x30deea[_0x8e4f03(0x1ea)],'limit':_0x11da2e[_0x8e4f03(0x1b1)],..._0x11da2e[_0x8e4f03(0x120)]===undefined?{}:{'cursor':_0x11da2e[_0x8e4f03(0x120)]}});return hostedConversationListPageSchema[_0x8e4f03(0x183)]({..._0x38a67c,'items':_0x38a67c[_0x8e4f03(0x197)][_0x8e4f03(0x20e)](_0x484758=>({..._0x484758,'activity':this[_0x8e4f03(0x26b)](_0x484758['id'])}))});}[_0x44e8b5(0x154)](_0x59e20d){const _0x1a5ef=_0x44e8b5;if(this[_0x1a5ef(0x1fc)])return Promise[_0x1a5ef(0xcf)](new Error(_0x1a5ef(0x1e0)));const _0x2f1673=hostedRequest(_0x59e20d),_0x47d580=hostedConversationCreateInputSchema[_0x1a5ef(0x183)](_0x2f1673[_0x1a5ef(0x189)]),_0x55b10e=conversationTemplateSummarySchema[_0x1a5ef(0x183)](_0x2f1673[_0x1a5ef(0x1e8)]),_0x26f438=runtimeModels(_0x2f1673[_0x1a5ef(0x182)]);if(_0x55b10e['id']!==_0x47d580[_0x1a5ef(0x1cd)]||_0x55b10e[_0x1a5ef(0x17c)]!==this[_0x1a5ef(0x149)][_0x1a5ef(0x17c)]()||!_0x55b10e[_0x1a5ef(0x106)]||_0x55b10e[_0x1a5ef(0x152)]!==_0x1a5ef(0x15e)||_0x55b10e[_0x1a5ef(0x243)]===null)throw new Error(_0x1a5ef(0xdb));const _0x269ab2=_0x2f1673[_0x1a5ef(0x1ea)]+'\x00'+_0x47d580[_0x1a5ef(0x1c7)],_0x3140e9=this[_0x1a5ef(0x18a)][_0x1a5ef(0x225)](_0x269ab2);if(_0x3140e9!==undefined)return _0x3140e9;const _0x1fb41a=this[_0x1a5ef(0x149)][_0x1a5ef(0x249)][_0x1a5ef(0x26a)](_0x2f1673[_0x1a5ef(0x1ea)],_0x47d580[_0x1a5ef(0x1c7)]);if(_0x1fb41a!==undefined)return this[_0x1a5ef(0x1c0)](_0x2f1673[_0x1a5ef(0x1ea)],_0x1fb41a['id'],_0x26f438);const _0x183b1d=this[_0x1a5ef(0x1f0)](_0x2f1673[_0x1a5ef(0x1ea)],_0x47d580[_0x1a5ef(0x1c7)],_0x55b10e,_0x26f438,_0x2f1673[_0x1a5ef(0xe2)]);return this[_0x1a5ef(0x18a)][_0x1a5ef(0xfc)](_0x269ab2,_0x183b1d),void _0x183b1d[_0x1a5ef(0x19d)](()=>this[_0x1a5ef(0x18a)][_0x1a5ef(0xe8)](_0x269ab2))[_0x1a5ef(0x196)](()=>undefined),_0x183b1d;}async[_0x44e8b5(0x1f0)](_0x2ed075,_0x230902,_0x2f14a8,_0x4c44b9,_0x459c01){const _0x1cffca=_0x44e8b5;await this[_0x1cffca(0x149)][_0x1cffca(0x1ac)]?.();const _0x47da43=await this[_0x1cffca(0x19a)](_0x2f14a8[_0x1cffca(0x243)],_0x2f14a8['id']),_0x588609=selectModel(_0x47da43,_0x4c44b9,_0x47da43[_0x1cffca(0xec)][_0x1cffca(0xdd)]),_0x7f5646=this['id'](),_0x518b28=await this[_0x1cffca(0x149)][_0x1cffca(0x249)][_0x1cffca(0x101)](_0x2ed075,_0x7f5646),_0xa90231=this[_0x1cffca(0x187)](_0x518b28[_0x1cffca(0x1da)],_0x47da43),_0xdf8d16=this[_0x1cffca(0xe4)](_0x518b28[_0x1cffca(0x1da)],_0x47da43);let _0xfe8332;try{const _0x339c58=await this[_0x1cffca(0x149)][_0x1cffca(0x1ce)][_0x1cffca(0x157)]({'conversationId':_0x7f5646,'homeDirectory':_0x518b28[_0x1cffca(0x1da)][_0x1cffca(0x264)],'workspaceDirectory':_0x47da43[_0x1cffca(0x200)],'systemInstruction':systemInstruction(_0x47da43),'defaultModelId':_0x588609['id'],'models':networkModels(allowedModels(_0x47da43,_0x4c44b9),_0x47da43[_0x1cffca(0xf3)][_0x1cffca(0x1a3)]),..._0x459c01===undefined?{}:{'runtimeScopeId':_0x459c01},'pathMounts':_0xa90231,'processExecutor':_0xdf8d16});_0xfe8332=_0x339c58[_0x1cffca(0x1d1)];const _0x58a413=this[_0x1cffca(0x1e4)](),_0x13e5e0={'id':_0x7f5646,'nodeId':this[_0x1cffca(0x149)][_0x1cffca(0x17c)](),'sessionId':_0xfe8332,'templateId':_0x2f14a8['id'],'templateName':_0x2f14a8[_0x1cffca(0x26c)],'activeVersionId':_0x47da43['id'],'title':_0x2f14a8[_0x1cffca(0x26c)],'titleSource':_0x1cffca(0x212),'pinnedAt':null,'status':_0x1cffca(0x15e),'modelId':_0x588609['id'],'createdAt':_0x58a413,'updatedAt':_0x58a413,'lastActivityAt':_0x58a413,'userStorageKey':_0x518b28[_0x1cffca(0x104)],'conversationStorageKey':_0x518b28[_0x1cffca(0x204)],'clientRequestId':_0x230902,'templateDeleted':![],'quota':{'usedBytes':0x0,'maxBytes':_0x47da43[_0x1cffca(0xf3)][_0x1cffca(0x11b)][_0x1cffca(0xd4)]}},_0x3c7375=await this[_0x1cffca(0x149)][_0x1cffca(0x249)][_0x1cffca(0x1f0)](_0x13e5e0);return _0x3c7375['id']!==_0x7f5646&&(await this[_0x1cffca(0x149)][_0x1cffca(0x1ce)][_0x1cffca(0x1b6)]({'conversationId':_0x7f5646,'sessionId':_0xfe8332,'homeDirectory':_0x518b28[_0x1cffca(0x1da)][_0x1cffca(0x264)]})[_0x1cffca(0x196)](()=>undefined),await rm(_0x518b28[_0x1cffca(0x1da)][_0x1cffca(0xbd)],{'recursive':!![],'force':!![]})),this[_0x1cffca(0x1c0)](_0x2ed075,_0x3c7375['id'],_0x4c44b9);}catch(_0x50c178){if(_0xfe8332!==undefined)await this[_0x1cffca(0x149)][_0x1cffca(0x1ce)][_0x1cffca(0x1b6)]({'conversationId':_0x7f5646,'sessionId':_0xfe8332,'homeDirectory':_0x518b28[_0x1cffca(0x1da)][_0x1cffca(0x264)]})[_0x1cffca(0x196)](()=>undefined);await rm(_0x518b28[_0x1cffca(0x1da)][_0x1cffca(0xbd)],{'recursive':!![],'force':!![]})[_0x1cffca(0x196)](()=>undefined);throw _0x50c178;}}async[_0x44e8b5(0x225)](_0xf21cdd){const _0x5221bc=_0x44e8b5,_0x92467b=hostedRequest(_0xf21cdd),_0x15db86=hostedConversationIdInputSchema[_0x5221bc(0x183)](_0x92467b[_0x5221bc(0x189)]);return this[_0x5221bc(0x1c0)](_0x92467b[_0x5221bc(0x1ea)],_0x15db86[_0x5221bc(0x153)],runtimeModels(_0x92467b[_0x5221bc(0x182)]),_0x92467b[_0x5221bc(0x1c8)]);}async[_0x44e8b5(0x1c0)](_0x55565e,_0x3ab8b8,_0x78f0ff,_0x4eb54c=![]){const _0x403160=_0x44e8b5;let _0x48a0e8=this[_0x403160(0x149)][_0x403160(0x249)][_0x403160(0xc4)](_0x55565e,_0x3ab8b8);if(_0x4eb54c)_0x48a0e8=await this[_0x403160(0x149)][_0x403160(0x249)][_0x403160(0x1cc)](_0x55565e,_0x3ab8b8,this[_0x403160(0x1e4)]());const _0x4a49e7=await this[_0x403160(0x19a)](_0x48a0e8[_0x403160(0x23a)],_0x48a0e8[_0x403160(0x1cd)]),_0x20f0b7=networkModels(allowedModels(_0x4a49e7,_0x78f0ff),_0x4a49e7[_0x403160(0xf3)][_0x403160(0x1a3)]),_0x3096ff=this[_0x403160(0x149)][_0x403160(0x249)][_0x403160(0x222)](_0x55565e,_0x48a0e8['id']),_0x19ea06=await this[_0x403160(0x149)][_0x403160(0x1ce)][_0x403160(0x255)]({'conversationId':_0x48a0e8['id'],'sessionId':_0x48a0e8[_0x403160(0x1d1)],'homeDirectory':_0x3096ff[_0x403160(0x264)],'modelId':_0x48a0e8[_0x403160(0x111)]});return hostedConversationSnapshotSchema[_0x403160(0x183)]({'conversation':this[_0x403160(0x1c3)](_0x48a0e8),'template':templateSummary(_0x48a0e8,_0x4a49e7[_0x403160(0xf3)]),'run':this[_0x403160(0x10a)][_0x403160(0x225)](_0x48a0e8['id'])?.[_0x403160(0xc1)]??null,'turns':_0x19ea06,'files':this[_0x403160(0x149)][_0x403160(0x249)][_0x403160(0x261)](_0x55565e,_0x48a0e8['id']),'models':_0x20f0b7[_0x403160(0x20e)](modelSummary),'error':null,'snapshotSequence':0x0});}async[_0x44e8b5(0x126)](_0x2ded14){const _0x5b6b7a=_0x44e8b5,_0x5c6d9f=hostedRequest(_0x2ded14),_0x53d553=hostedConversationWatchInputSchema[_0x5b6b7a(0x183)](_0x5c6d9f[_0x5b6b7a(0x189)]),_0x455bc0=this[_0x5b6b7a(0x149)][_0x5b6b7a(0x249)][_0x5b6b7a(0xc4)](_0x5c6d9f[_0x5b6b7a(0x1ea)],_0x53d553[_0x5b6b7a(0x153)]);if(this[_0x5b6b7a(0x1de)][_0x5b6b7a(0x102)](_0x455bc0['id']))throw new Error(_0x5b6b7a(0xbf));const _0x4f1df5=requireWatchSessionHash(_0x5c6d9f[_0x5b6b7a(0x16f)]),_0x1551a3=watchOwnerKey(_0x4f1df5,_0x53d553[_0x5b6b7a(0x22c)]);if(_0x53d553[_0x5b6b7a(0x263)]===_0x5b6b7a(0x13e)){const _0x4752c9=this[_0x5b6b7a(0x13c)][_0x5b6b7a(0x225)](_0x1551a3);if(_0x4752c9===undefined||!this[_0x5b6b7a(0x155)][_0x5b6b7a(0x1d4)](_0x1551a3,_0x4752c9[_0x5b6b7a(0x10d)])||_0x4752c9[_0x5b6b7a(0x19b)]!==_0x53d553[_0x5b6b7a(0x19b)]||_0x4752c9[_0x5b6b7a(0x153)]!==_0x53d553[_0x5b6b7a(0x153)]||_0x4752c9[_0x5b6b7a(0x1ea)]!==_0x5c6d9f[_0x5b6b7a(0x1ea)]||_0x4752c9[_0x5b6b7a(0x127)]<=Date[_0x5b6b7a(0x1e4)]()){this[_0x5b6b7a(0x181)](_0x1551a3);throw new Error(_0x5b6b7a(0x246));}return _0x4752c9[_0x5b6b7a(0x127)]=Date[_0x5b6b7a(0x1e4)]()+WATCH_TTL_MS,clearTimeout(_0x4752c9[_0x5b6b7a(0x22d)]),_0x4752c9[_0x5b6b7a(0x22d)]=this[_0x5b6b7a(0x10b)](_0x1551a3),this[_0x5b6b7a(0x17a)](_0x4752c9);}const _0x3198ad=runtimeModels(_0x5c6d9f[_0x5b6b7a(0x182)]),_0x35f89a=this[_0x5b6b7a(0x13c)][_0x5b6b7a(0x225)](_0x1551a3);if(_0x35f89a!==undefined&&this[_0x5b6b7a(0x155)][_0x5b6b7a(0x1d4)](_0x1551a3,_0x35f89a[_0x5b6b7a(0x10d)])&&_0x35f89a[_0x5b6b7a(0x19b)]===_0x53d553[_0x5b6b7a(0x19b)]&&_0x35f89a[_0x5b6b7a(0x153)]===_0x53d553[_0x5b6b7a(0x153)]&&_0x35f89a[_0x5b6b7a(0x1ea)]===_0x5c6d9f[_0x5b6b7a(0x1ea)]&&_0x35f89a[_0x5b6b7a(0x127)]>Date[_0x5b6b7a(0x1e4)]())return _0x35f89a[_0x5b6b7a(0x127)]=Date[_0x5b6b7a(0x1e4)]()+WATCH_TTL_MS,clearTimeout(_0x35f89a[_0x5b6b7a(0x22d)]),_0x35f89a[_0x5b6b7a(0x22d)]=this[_0x5b6b7a(0x10b)](_0x1551a3),this[_0x5b6b7a(0x17a)](_0x35f89a);this[_0x5b6b7a(0x181)](_0x1551a3);const _0x16360e=this[_0x5b6b7a(0x155)][_0x5b6b7a(0x150)](_0x1551a3,_0x5b6b7a(0x1b2),()=>this[_0x5b6b7a(0x181)](_0x1551a3)),_0x1e74d7={'ownerKey':_0x1551a3,'slotToken':_0x16360e,'sessionHash':_0x4f1df5,'workbenchConnectionId':_0x53d553[_0x5b6b7a(0x22c)],'watchId':_0x53d553[_0x5b6b7a(0x19b)],'conversationId':_0x53d553[_0x5b6b7a(0x153)],'templateId':_0x455bc0[_0x5b6b7a(0x1cd)],'userId':_0x5c6d9f[_0x5b6b7a(0x1ea)],'models':_0x3198ad,'nodeGeneration':this[_0x5b6b7a(0x149)][_0x5b6b7a(0xca)]?.()??_0x5b6b7a(0xd0),'pendingEvents':[],'expiresAt':Date[_0x5b6b7a(0x1e4)]()+WATCH_TTL_MS,'ready':![],'timer':undefined};return _0x1e74d7[_0x5b6b7a(0x22d)]=this[_0x5b6b7a(0x10b)](_0x1551a3),this[_0x5b6b7a(0x13c)][_0x5b6b7a(0xfc)](_0x1551a3,_0x1e74d7),void this[_0x5b6b7a(0x22e)](_0x1e74d7),this[_0x5b6b7a(0x17a)](_0x1e74d7);}[_0x44e8b5(0x114)](_0x10371b){const _0x2df757=_0x44e8b5,_0x442dff=hostedRequest(_0x10371b),_0x500d41=hostedConversationUnwatchInputSchema[_0x2df757(0x183)](_0x442dff[_0x2df757(0x189)]);this[_0x2df757(0x149)][_0x2df757(0x249)][_0x2df757(0xc4)](_0x442dff[_0x2df757(0x1ea)],_0x500d41[_0x2df757(0x153)]);const _0x238f22=watchOwnerKey(requireWatchSessionHash(_0x442dff[_0x2df757(0x16f)]),_0x500d41[_0x2df757(0x22c)]),_0x6247a=this[_0x2df757(0x13c)][_0x2df757(0x225)](_0x238f22);if(_0x6247a?.[_0x2df757(0x19b)]===_0x500d41[_0x2df757(0x19b)]&&_0x6247a[_0x2df757(0x153)]===_0x500d41[_0x2df757(0x153)]&&_0x6247a[_0x2df757(0x1ea)]===_0x442dff[_0x2df757(0x1ea)])this[_0x2df757(0x181)](_0x238f22);return{'unwatched':!![]};}[_0x44e8b5(0x216)](_0x4f90ea,_0x136a55){const _0x11e183=_0x44e8b5;return this[_0x11e183(0x10e)](_0x4f90ea,{'conversationId':_0x4f90ea,'kind':_0x11e183(0x1ce),'runtimeEvent':_0x136a55});}[_0x44e8b5(0xff)](_0x502b2e){const _0x134f27=_0x44e8b5;return this[_0x134f27(0x1de)][_0x134f27(0x102)](_0x502b2e)||this[_0x134f27(0x10a)][_0x134f27(0x102)](_0x502b2e)||this[_0x134f27(0x24e)][_0x134f27(0x102)](_0x502b2e)||[...this[_0x134f27(0x13c)][_0x134f27(0x1c1)]()][_0x134f27(0xc8)](_0x564094=>_0x564094[_0x134f27(0x153)]===_0x502b2e)||[...this[_0x134f27(0x1ca)][_0x134f27(0x1c1)]()][_0x134f27(0xc8)](_0x2c7ab2=>_0x2c7ab2[_0x134f27(0x153)]===_0x502b2e&&_0x2c7ab2[_0x134f27(0x152)]===_0x134f27(0x1e9))||[...this[_0x134f27(0x266)][_0x134f27(0x233)]()][_0x134f27(0xc8)](_0x1714df=>_0x1714df[_0x134f27(0x22f)](_0x502b2e+'\x00'));}[_0x44e8b5(0xbe)](_0x509471){const _0x578f46=_0x44e8b5;if(this[_0x578f46(0xff)](_0x509471))return undefined;return this[_0x578f46(0x1de)][_0x578f46(0x185)](_0x509471),()=>{const _0x54edeb=_0x578f46;this[_0x54edeb(0x1de)][_0x54edeb(0xe8)](_0x509471);};}async[_0x44e8b5(0x239)](_0x5cd74f){const _0x43a9b4=_0x44e8b5,_0x90fb97=this[_0x43a9b4(0x149)][_0x43a9b4(0x249)][_0x43a9b4(0x25c)](_0x5cd74f);await this[_0x43a9b4(0x149)][_0x43a9b4(0x1ce)][_0x43a9b4(0x1b6)]({'conversationId':_0x5cd74f['id'],'sessionId':_0x5cd74f[_0x43a9b4(0x1d1)],'homeDirectory':_0x90fb97[_0x43a9b4(0x264)]})[_0x43a9b4(0x196)](()=>undefined);}[_0x44e8b5(0xf4)](){const _0x344a57=_0x44e8b5;for(const [_0x349d3b,_0x339ede]of this[_0x344a57(0x10a)]){const _0x4205d9=runInterruptionKey(_0x349d3b,_0x339ede[_0x344a57(0xc1)]['id']);this[_0x344a57(0x25f)][_0x344a57(0x185)](_0x4205d9);if(!_0x339ede[_0x344a57(0x143)]())this[_0x344a57(0x25f)][_0x344a57(0xe8)](_0x4205d9);}for(const _0x130597 of[...this[_0x344a57(0x13c)][_0x344a57(0x233)]()])this[_0x344a57(0x181)](_0x130597);}[_0x44e8b5(0x15f)](_0x42e428){const _0x194d2d=_0x44e8b5;if(this[_0x194d2d(0x1fc)])return Promise[_0x194d2d(0xcf)](new Error(_0x194d2d(0x1e0)));const _0x1bc918=hostedRequest(_0x42e428),_0x157b46=hostedConversationMessageInputSchema[_0x194d2d(0x183)](_0x1bc918[_0x194d2d(0x189)]),_0x53ee22=_0x157b46[_0x194d2d(0x153)]+'\x00'+_0x157b46[_0x194d2d(0xbc)],_0x44a7f9=this[_0x194d2d(0x266)][_0x194d2d(0x225)](_0x53ee22);if(_0x44a7f9!==undefined)return _0x44a7f9;const _0x431688=this[_0x194d2d(0x149)][_0x194d2d(0x249)][_0x194d2d(0x1fa)](_0x1bc918[_0x194d2d(0x1ea)],_0x157b46[_0x194d2d(0x153)],_0x157b46[_0x194d2d(0xbc)]);if(_0x431688!==undefined){const _0xa3a05b=this[_0x194d2d(0x149)][_0x194d2d(0x249)][_0x194d2d(0xc4)](_0x1bc918[_0x194d2d(0x1ea)],_0x157b46[_0x194d2d(0x153)]);return Promise[_0x194d2d(0x1a6)]({'conversation':this[_0x194d2d(0x1c3)](_0xa3a05b),'run':runFromMessage(_0x431688)});}if([...this[_0x194d2d(0x266)][_0x194d2d(0x233)]()][_0x194d2d(0xc8)](_0x522846=>_0x522846[_0x194d2d(0x22f)](_0x157b46[_0x194d2d(0x153)]+'\x00')))return Promise[_0x194d2d(0xcf)](new Error(_0x194d2d(0x234)));const _0x258136=this[_0x194d2d(0x191)](_0x1bc918,_0x157b46);return this[_0x194d2d(0x266)][_0x194d2d(0xfc)](_0x53ee22,_0x258136),void _0x258136[_0x194d2d(0x19d)](()=>this[_0x194d2d(0x266)][_0x194d2d(0xe8)](_0x53ee22))[_0x194d2d(0x196)](()=>undefined),_0x258136;}async[_0x44e8b5(0x191)](_0x4fd2bc,_0x430397){const _0x2e5970=_0x44e8b5;let _0x3c3ac4=this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0xc4)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x430397[_0x2e5970(0x153)]);if(this[_0x2e5970(0x1de)][_0x2e5970(0x102)](_0x3c3ac4['id']))throw new Error(_0x2e5970(0xbf));if(_0x3c3ac4[_0x2e5970(0x152)]!==_0x2e5970(0x15e))throw new Error(_0x2e5970(0xbf));if(this[_0x2e5970(0x10a)][_0x2e5970(0x102)](_0x3c3ac4['id']))throw new Error(_0x2e5970(0x234));const _0x173485=sessionTitleFromFirstMessage(_0x430397[_0x2e5970(0x16d)]),_0x20a337=_0x173485[_0x2e5970(0x254)]>-0x12fb*0x1+0x1*-0x21f5+0x134*0x2c&&!this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0x193)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4['id']),_0x5156fe=runtimeModels(_0x4fd2bc[_0x2e5970(0x182)]),_0x3c69aa=this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0x222)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4['id']);let _0x4f810a,_0x42dcdf,_0x4c58aa,_0x451649;const _0x4abc93=_0x3c3ac4[_0x2e5970(0x1c8)]?undefined:this[_0x2e5970(0xe9)](_0x3c3ac4[_0x2e5970(0x1cd)]);if(_0x4abc93!==undefined&&_0x4abc93!==_0x3c3ac4[_0x2e5970(0x23a)]){const _0x59dcb4=_0x3c3ac4[_0x2e5970(0x23a)],_0x11065b=_0x4abc93;try{_0x4f810a=await this[_0x2e5970(0x19a)](_0x11065b,_0x3c3ac4[_0x2e5970(0x1cd)]),_0x42dcdf=selectModel(_0x4f810a,_0x5156fe,_0x430397[_0x2e5970(0x111)]??_0x4f810a[_0x2e5970(0xec)][_0x2e5970(0xdd)]),_0x4c58aa=resolveMcpServers(_0x4f810a,this[_0x2e5970(0x149)][_0x2e5970(0x166)]??process.env),this[_0x2e5970(0x187)](_0x3c69aa,_0x4f810a),this[_0x2e5970(0xe4)](_0x3c69aa,_0x4f810a),_0x451649={'previousVersionId':_0x59dcb4,'targetVersionId':_0x11065b};}catch(_0x500a64){this[_0x2e5970(0x227)](_0x3c3ac4,_0x59dcb4,_0x11065b,_0x500a64);throw new Error(_0x2e5970(0x248));}}else _0x4f810a=await this[_0x2e5970(0x19a)](_0x3c3ac4[_0x2e5970(0x23a)],_0x3c3ac4[_0x2e5970(0x1cd)]),_0x42dcdf=selectModel(_0x4f810a,_0x5156fe,_0x430397[_0x2e5970(0x111)]??_0x3c3ac4[_0x2e5970(0x111)]);const _0x281be5=await Promise[_0x2e5970(0x23b)](_0x430397[_0x2e5970(0x205)][_0x2e5970(0x20e)](_0x6b788c=>this[_0x2e5970(0x1df)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4['id'],_0x6b788c))),_0x2dd657=attachmentPrompt(_0x430397[_0x2e5970(0x16d)],_0x281be5),_0x517ec9=marAgentGeneratedImagesDirectory(_0x3c69aa[_0x2e5970(0x264)],_0x3c3ac4[_0x2e5970(0x1d1)]),_0x578426=hostedConversationGeneratedImagesDisplayDirectory(_0x3c3ac4[_0x2e5970(0x1d1)]);if(_0x517ec9===undefined||_0x578426===undefined)throw new Error(_0x2e5970(0x186));await mkdir(_0x517ec9,{'recursive':!![],'mode':0x1c0});const _0x3bd016=this[_0x2e5970(0x187)](_0x3c69aa,_0x4f810a,_0x517ec9,_0x578426),_0x50f264=join(_0x3c69aa[_0x2e5970(0x17e)],_0x2e5970(0xb9)+randomUUID());await mkdir(_0x50f264,{'mode':0x1c0}),this[_0x2e5970(0x240)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4,_0x2e5970(0x1b3),this[_0x2e5970(0x1e4)]());const _0x425f2d=[];let _0x483760=![];const _0x294e21=await this[_0x2e5970(0x149)][_0x2e5970(0x1ce)][_0x2e5970(0x192)]({'conversationId':_0x3c3ac4['id'],'sessionId':_0x3c3ac4[_0x2e5970(0x1d1)],'clientMessageId':_0x430397[_0x2e5970(0xbc)],'userPrompt':_0x430397[_0x2e5970(0x16d)],'prompt':_0x2dd657,'attachmentIds':_0x430397[_0x2e5970(0x205)],'access':_0x2e5970(0xf6),'modelId':_0x42dcdf['id'],'models':networkModels(allowedModels(_0x4f810a,_0x5156fe),_0x4f810a[_0x2e5970(0xf3)][_0x2e5970(0x1a3)]),..._0x4fd2bc[_0x2e5970(0xe2)]===undefined?{}:{'runtimeScopeId':_0x4fd2bc[_0x2e5970(0xe2)]},'systemInstruction':systemInstruction(_0x4f810a,_0x578426),'homeDirectory':_0x3c69aa[_0x2e5970(0x264)],'workspaceDirectory':_0x4f810a[_0x2e5970(0x200)],'temporaryDirectory':_0x50f264,'pathMounts':_0x3bd016,'processExecutor':this[_0x2e5970(0xe4)](_0x3c69aa,_0x4f810a,_0x50f264,_0x517ec9,_0x578426),'mcpServers':_0x4c58aa??resolveMcpServers(_0x4f810a,this[_0x2e5970(0x149)][_0x2e5970(0x166)]??process.env),'webAccess':_0x4f810a[_0x2e5970(0xf3)][_0x2e5970(0x1a3)]!==_0x2e5970(0x195),'onEvent':_0x3caecc=>{const _0x3ec2d6=_0x2e5970;if(_0x483760)this[_0x3ec2d6(0x216)](_0x3c3ac4['id'],_0x3caecc);else _0x425f2d[_0x3ec2d6(0x1bf)](_0x3caecc);}})[_0x2e5970(0x196)](async _0x7bd3b2=>{const _0x2291bf=_0x2e5970;this[_0x2291bf(0x240)](_0x4fd2bc[_0x2291bf(0x1ea)],_0x3c3ac4,_0x2291bf(0x21b),this[_0x2291bf(0x1e4)]()),await rm(_0x50f264,{'recursive':!![],'force':!![]})[_0x2291bf(0x196)](()=>undefined);if(_0x451649!==undefined){this[_0x2291bf(0x227)](_0x3c3ac4,_0x451649[_0x2291bf(0x100)],_0x451649[_0x2291bf(0x12c)],_0x7bd3b2);throw new Error(_0x2291bf(0x248));}throw _0x7bd3b2;}),_0x208595=_0x294e21[_0x2e5970(0xc1)][_0x2e5970(0x10f)];let _0x1466ab=![],_0x560039;try{this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0x237)]({'conversationId':_0x3c3ac4['id'],'clientMessageId':_0x430397[_0x2e5970(0xbc)],'runId':_0x294e21[_0x2e5970(0xc1)]['id'],'userTextPresent':_0x173485[_0x2e5970(0x254)]>-0x1*0x2129+0xd76*-0x2+0x6ad*0x9,'status':_0x2e5970(0x138),'createdAt':_0x208595,'updatedAt':_0x208595}),_0x1466ab=!![];const _0x3332c7=this[_0x2e5970(0x1e4)]();_0x560039=await this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0x18b)]({'conversationId':_0x3c3ac4['id'],'modelId':_0x42dcdf['id'],'activityAt':_0x3332c7,..._0x451649===undefined?{}:{'templateVersion':{'expectedActiveVersionId':_0x451649[_0x2e5970(0x100)],'activeVersionId':_0x451649[_0x2e5970(0x12c)],'maxStorageBytes':_0x4f810a[_0x2e5970(0xf3)][_0x2e5970(0x11b)][_0x2e5970(0xd4)]}},..._0x20a337?{'automaticTitle':_0x173485}:{}});}catch(_0x19c161){try{_0x294e21[_0x2e5970(0x143)]();}catch{}const _0x3f21f9=await _0x294e21[_0x2e5970(0x1d0)][_0x2e5970(0x196)](()=>({'status':_0x2e5970(0x12f),'completedAt':this[_0x2e5970(0x1e4)]()}));if(_0x1466ab)try{this[_0x2e5970(0x149)][_0x2e5970(0x249)][_0x2e5970(0x20b)](_0x3c3ac4['id'],_0x430397[_0x2e5970(0xbc)],_0x3f21f9[_0x2e5970(0x152)],_0x3f21f9[_0x2e5970(0xd6)]);}catch{}await rm(_0x50f264,{'recursive':!![],'force':!![]})[_0x2e5970(0x196)](()=>undefined),this[_0x2e5970(0x240)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4,_0x2e5970(0x21b),_0x3f21f9[_0x2e5970(0xd6)]);if(_0x451649!==undefined)this[_0x2e5970(0x227)](_0x3c3ac4,_0x451649[_0x2e5970(0x100)],_0x451649[_0x2e5970(0x12c)],_0x19c161);throw _0x19c161;}_0x3c3ac4=_0x560039[_0x2e5970(0x220)];if(_0x451649!==undefined)this[_0x2e5970(0x10e)](_0x3c3ac4['id'],{'conversationId':_0x3c3ac4['id'],'kind':_0x2e5970(0x1e5),'upgrade':{'status':_0x2e5970(0x115),'previousVersionId':_0x451649[_0x2e5970(0x100)],'targetVersionId':_0x451649[_0x2e5970(0x12c)],'activeVersionId':_0x3c3ac4[_0x2e5970(0x23a)],'conversation':this[_0x2e5970(0x1c3)](_0x3c3ac4),'error':null}});this[_0x2e5970(0x10a)][_0x2e5970(0xfc)](_0x3c3ac4['id'],_0x294e21),this[_0x2e5970(0x240)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4,_0x2e5970(0x138),_0x294e21[_0x2e5970(0xc1)][_0x2e5970(0x10f)]);if(_0x560039[_0x2e5970(0x230)])this[_0x2e5970(0x10e)](_0x3c3ac4['id'],{'conversationId':_0x3c3ac4['id'],'kind':_0x2e5970(0x220),'conversation':this[_0x2e5970(0x1c3)](_0x3c3ac4)});this[_0x2e5970(0x10e)](_0x3c3ac4['id'],{'conversationId':_0x3c3ac4['id'],'kind':_0x2e5970(0xc1),'run':_0x294e21[_0x2e5970(0xc1)]}),_0x483760=!![];for(const _0x34551d of _0x425f2d)this[_0x2e5970(0x216)](_0x3c3ac4['id'],_0x34551d);_0x425f2d[_0x2e5970(0x254)]=-0x1c89+0x2*-0x676+0x2975;const _0xcc400=_0x294e21[_0x2e5970(0x1d0)][_0x2e5970(0x1eb)](_0x28c251=>this[_0x2e5970(0x15b)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4['id'],_0x430397[_0x2e5970(0xbc)],_0x294e21[_0x2e5970(0xc1)],_0x28c251),()=>this[_0x2e5970(0x15b)](_0x4fd2bc[_0x2e5970(0x1ea)],_0x3c3ac4['id'],_0x430397[_0x2e5970(0xbc)],_0x294e21[_0x2e5970(0xc1)],{'status':_0x2e5970(0x12f),'completedAt':this[_0x2e5970(0x1e4)]()}))[_0x2e5970(0x196)](()=>undefined)[_0x2e5970(0x19d)](async()=>{const _0x4d3888=_0x2e5970;this[_0x4d3888(0x25f)][_0x4d3888(0xe8)](runInterruptionKey(_0x3c3ac4['id'],_0x294e21[_0x4d3888(0xc1)]['id']));if(this[_0x4d3888(0x10a)][_0x4d3888(0x225)](_0x3c3ac4['id'])===_0x294e21)this[_0x4d3888(0x10a)][_0x4d3888(0xe8)](_0x3c3ac4['id']);if(this[_0x4d3888(0x24e)][_0x4d3888(0x225)](_0x3c3ac4['id'])===_0xcc400)this[_0x4d3888(0x24e)][_0x4d3888(0xe8)](_0x3c3ac4['id']);await rm(_0x50f264,{'recursive':!![],'force':!![]})[_0x4d3888(0x196)](()=>undefined);});return this[_0x2e5970(0x24e)][_0x2e5970(0xfc)](_0x3c3ac4['id'],_0xcc400),void _0xcc400,{'conversation':this[_0x2e5970(0x1c3)](_0x3c3ac4),'run':_0x294e21[_0x2e5970(0xc1)]};}async[_0x44e8b5(0x15b)](_0x137ef3,_0x2d13f8,_0x596104,_0x5c04ff,_0x5f356e){const _0x1014e0=_0x44e8b5,_0xef08d0=runInterruptionKey(_0x2d13f8,_0x5c04ff['id']),_0x6b80a0=this[_0x1014e0(0x25f)][_0x1014e0(0x102)](_0xef08d0);let _0x68386e;try{this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0x20b)](_0x2d13f8,_0x596104,_0x5f356e[_0x1014e0(0x152)],_0x5f356e[_0x1014e0(0xd6)]);try{const _0x4c12e6=await this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0x16e)](_0x137ef3,_0x2d13f8);this[_0x1014e0(0x10e)](_0x2d13f8,{'conversationId':_0x2d13f8,'kind':_0x1014e0(0x171),'files':_0x4c12e6,'error':null});}catch(_0x2b9710){this[_0x1014e0(0x10e)](_0x2d13f8,{'conversationId':_0x2d13f8,'kind':_0x1014e0(0x171),'files':this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0x261)](_0x137ef3,_0x2d13f8),'error':{'code':safeErrorCode(_0x2b9710,_0x1014e0(0x162)),'message':_0x1014e0(0xc7)}});}await this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0x268)](_0x2d13f8,_0x5f356e[_0x1014e0(0xd6)]),this[_0x1014e0(0x10e)](_0x2d13f8,{'conversationId':_0x2d13f8,'kind':_0x1014e0(0xc1),'run':{'id':_0x5c04ff['id'],'status':_0x5f356e[_0x1014e0(0x152)],'startedAt':_0x5c04ff[_0x1014e0(0x10f)],'completedAt':_0x5f356e[_0x1014e0(0xd6)]}}),await this[_0x1014e0(0xb7)](_0x2d13f8,_0x5f356e[_0x1014e0(0x163)],_0x5f356e[_0x1014e0(0xd6)])[_0x1014e0(0x196)](()=>undefined),_0x68386e=this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0xc4)](_0x137ef3,_0x2d13f8);}finally{this[_0x1014e0(0x25f)][_0x1014e0(0xe8)](_0xef08d0);if(_0x68386e===undefined)try{_0x68386e=this[_0x1014e0(0x149)][_0x1014e0(0x249)][_0x1014e0(0xc4)](_0x137ef3,_0x2d13f8);}catch{}if(_0x68386e!==undefined)this[_0x1014e0(0x240)](_0x137ef3,_0x68386e,_0x1014e0(0x21b),_0x5f356e[_0x1014e0(0xd6)]);}if(_0x68386e!==undefined&&(_0x5f356e[_0x1014e0(0x152)]!==_0x1014e0(0x267)||!_0x6b80a0))this[_0x1014e0(0x1d5)](_0x137ef3,_0x68386e,_0x5c04ff['id'],_0x5f356e);}async[_0x44e8b5(0xb7)](_0x25adf7,_0x5ef5b9,_0x91713b){const _0x5174bc=_0x44e8b5,_0x29d0a8=automaticHostedConversationTitle(_0x5ef5b9);if(_0x29d0a8===undefined)return;const _0x6fe844=await this[_0x5174bc(0x149)][_0x5174bc(0x249)][_0x5174bc(0x1fe)](_0x25adf7,_0x29d0a8,_0x91713b);if(_0x6fe844===undefined)return;this[_0x5174bc(0x10e)](_0x25adf7,{'conversationId':_0x25adf7,'kind':_0x5174bc(0x220),'conversation':this[_0x5174bc(0x1c3)](_0x6fe844)});}[_0x44e8b5(0x17f)](_0x1cb516){const _0x49cd14=_0x44e8b5,_0x20cb81=hostedRequest(_0x1cb516),_0xbfbd43=hostedConversationIdInputSchema[_0x49cd14(0x183)](_0x20cb81[_0x49cd14(0x189)]),_0x1a5a78=this[_0x49cd14(0x149)][_0x49cd14(0x249)][_0x49cd14(0xc4)](_0x20cb81[_0x49cd14(0x1ea)],_0xbfbd43[_0x49cd14(0x153)]),_0x5e4195=this[_0x49cd14(0x10a)][_0x49cd14(0x225)](_0xbfbd43[_0x49cd14(0x153)]);if(_0x5e4195===undefined)return{'interrupted':![]};const _0x2d09b0=runInterruptionKey(_0x1a5a78['id'],_0x5e4195[_0x49cd14(0xc1)]['id']);this[_0x49cd14(0x25f)][_0x49cd14(0x185)](_0x2d09b0);try{const _0x54b1df=_0x5e4195[_0x49cd14(0x143)]();if(!_0x54b1df)return this[_0x49cd14(0x25f)][_0x49cd14(0xe8)](_0x2d09b0),{'interrupted':![]};return this[_0x49cd14(0x240)](_0x20cb81[_0x49cd14(0x1ea)],_0x1a5a78,_0x49cd14(0x164),this[_0x49cd14(0x1e4)]()),{'interrupted':!![]};}catch(_0x3d670c){this[_0x49cd14(0x25f)][_0x49cd14(0xe8)](_0x2d09b0);throw _0x3d670c;}}async[_0x44e8b5(0x1d9)](_0x58d16a){const _0x157f0b=_0x44e8b5,_0x22b03e=hostedRequest(_0x58d16a),_0x2e2b22=hostedConversationConfigUpdateInputSchema[_0x157f0b(0x183)](_0x22b03e[_0x157f0b(0x189)]),_0x3fb7d6=this[_0x157f0b(0x149)][_0x157f0b(0x249)][_0x157f0b(0xc4)](_0x22b03e[_0x157f0b(0x1ea)],_0x2e2b22[_0x157f0b(0x153)]);if(this[_0x157f0b(0x1de)][_0x157f0b(0x102)](_0x3fb7d6['id']))throw new Error(_0x157f0b(0xbf));const _0x3162c5=await this[_0x157f0b(0x19a)](_0x3fb7d6[_0x157f0b(0x23a)],_0x3fb7d6[_0x157f0b(0x1cd)]),_0x35d8c7=runtimeModels(_0x22b03e[_0x157f0b(0x182)]),_0x58d4a1=selectModel(_0x3162c5,_0x35d8c7,_0x2e2b22[_0x157f0b(0x111)]??_0x3fb7d6[_0x157f0b(0x111)]),_0x2ced38=this[_0x157f0b(0x1e4)](),_0x2b28f1=await this[_0x157f0b(0x149)][_0x157f0b(0x249)][_0x157f0b(0x172)](_0x3fb7d6['id'],_0x4f7088=>({..._0x4f7088,'modelId':_0x58d4a1['id'],'updatedAt':_0x2ced38,'lastActivityAt':_0x2ced38}));return this[_0x157f0b(0x10e)](_0x3fb7d6['id'],{'conversationId':_0x3fb7d6['id'],'kind':_0x157f0b(0x20f),'conversation':this[_0x157f0b(0x1c3)](_0x2b28f1)}),{'conversation':this[_0x157f0b(0x1c3)](_0x2b28f1)};}async[_0x44e8b5(0x21e)](_0x1d0342){const _0x176658=_0x44e8b5,_0x41e0a5=hostedRequest(_0x1d0342),_0x10a19e=hostedConversationMetadataUpdateInputSchema[_0x176658(0x183)](_0x41e0a5[_0x176658(0x189)]),_0x4d3980=this[_0x176658(0x149)][_0x176658(0x249)][_0x176658(0xc4)](_0x41e0a5[_0x176658(0x1ea)],_0x10a19e[_0x176658(0x153)]);if(this[_0x176658(0x1de)][_0x176658(0x102)](_0x4d3980['id']))throw new Error(_0x176658(0xbf));const _0x4344c9=this[_0x176658(0x1e4)](),_0x4eab18=await this[_0x176658(0x149)][_0x176658(0x249)][_0x176658(0x172)](_0x4d3980['id'],_0x1d8aac=>({..._0x1d8aac,'title':_0x10a19e[_0x176658(0x163)]??_0x1d8aac[_0x176658(0x163)],'titleSource':_0x10a19e[_0x176658(0x163)]===undefined?_0x1d8aac[_0x176658(0x1ee)]:_0x176658(0x208),'pinnedAt':_0x10a19e[_0x176658(0x24c)]===undefined?_0x1d8aac[_0x176658(0x229)]:_0x10a19e[_0x176658(0x24c)]?_0x4344c9:null,'updatedAt':_0x4344c9,'lastActivityAt':_0x1d8aac[_0x176658(0x137)]}));return this[_0x176658(0x10e)](_0x4d3980['id'],{'conversationId':_0x4d3980['id'],'kind':_0x176658(0x20f),'conversation':this[_0x176658(0x1c3)](_0x4eab18)}),{'conversation':this[_0x176658(0x1c3)](_0x4eab18)};}async[_0x44e8b5(0x261)](_0x280820){const _0x5af129=_0x44e8b5,_0x218977=hostedRequest(_0x280820),_0x7b8e92=hostedConversationIdInputSchema[_0x5af129(0x183)](_0x218977[_0x5af129(0x189)]);return hostedConversationFilesSchema[_0x5af129(0x183)]({'files':this[_0x5af129(0x149)][_0x5af129(0x249)][_0x5af129(0x261)](_0x218977[_0x5af129(0x1ea)],_0x7b8e92[_0x5af129(0x153)])});}async[_0x44e8b5(0x11f)](_0x108070){const _0x1e4128=_0x44e8b5,_0x29a9aa=hostedRequest(_0x108070),_0x11b293=hostedConversationImageReadInputSchema[_0x1e4128(0x183)](_0x29a9aa[_0x1e4128(0x189)]);this[_0x1e4128(0x149)][_0x1e4128(0x249)][_0x1e4128(0xc4)](_0x29a9aa[_0x1e4128(0x1ea)],_0x11b293[_0x1e4128(0x153)]);if(_0x11b293[_0x1e4128(0x123)]!==hostedConversationImageRunId(_0x11b293[_0x1e4128(0x153)]))throw new Error(_0x1e4128(0x17d));const _0x483504=await this[_0x1e4128(0x149)][_0x1e4128(0x11f)](_0x11b293[_0x1e4128(0x123)],_0x11b293[_0x1e4128(0xfa)]);if(_0x483504===undefined)throw new Error(_0x1e4128(0x211));return{'image':_0x483504};}async[_0x44e8b5(0x1a5)](_0x2be47a){const _0x463294=_0x44e8b5,_0x4c4f93=hostedRequest(_0x2be47a),_0x33209b=hostedConversationFileReadInputSchema[_0x463294(0x183)](_0x4c4f93[_0x463294(0x189)]),_0x3322ac=this[_0x463294(0x149)][_0x463294(0x249)][_0x463294(0x252)](_0x4c4f93[_0x463294(0x1ea)],_0x33209b[_0x463294(0x153)],_0x33209b[_0x463294(0x175)]),_0x442c8a=this[_0x463294(0x149)][_0x463294(0x249)][_0x463294(0x1d7)](_0x4c4f93[_0x463294(0x1ea)],_0x3322ac);await assertRegularFile(_0x442c8a,_0x3322ac[_0x463294(0x21a)]);const _0xa44f86=_0x33209b[_0x463294(0xcd)]??-0x9*-0x39b+0x474+-0x24e7;if(_0xa44f86>_0x3322ac[_0x463294(0x21a)])throw new Error(_0x463294(0x1be));const _0x533149=Math[_0x463294(0x11d)](_0x33209b[_0x463294(0x1b1)]??MAX_FILE_READ_BYTES,MAX_FILE_READ_BYTES),_0x3502c0=await open(_0x442c8a,'r');try{const _0x55b24e=Buffer[_0x463294(0xe1)](Math[_0x463294(0x11d)](_0x533149,Math[_0x463294(0xea)](-0x1d3+-0x8d2+0xaa5,_0x3322ac[_0x463294(0x21a)]-_0xa44f86))),_0x4501a2=await _0x3502c0[_0x463294(0x158)](_0x55b24e,0x1*-0x16ab+0xd*-0xc7+-0x5*-0x68e,_0x55b24e[_0x463294(0x254)],_0xa44f86),_0xd98d6d=_0xa44f86+_0x4501a2[_0x463294(0xdf)],_0x41e826=_0xd98d6d>=_0x3322ac[_0x463294(0x21a)];return hostedConversationFileReadResultSchema[_0x463294(0x183)]({'file':_0x3322ac,'encoding':_0x463294(0x22a),'content':_0x55b24e[_0x463294(0x26e)](-0x472+-0x227*0x4+0x2*0x687,_0x4501a2[_0x463294(0xdf)])[_0x463294(0x1a7)](_0x463294(0x22a)),'offset':_0xa44f86,'nextOffset':_0x41e826?null:_0xd98d6d,'eof':_0x41e826});}finally{await _0x3502c0[_0x463294(0x159)]();}}async[_0x44e8b5(0x170)](_0x3fd31f){const _0x2b4126=_0x44e8b5,_0x3d2ba3=hostedRequest(_0x3fd31f),_0x7e5751=hostedConversationFileDeleteInputSchema[_0x2b4126(0x183)](_0x3d2ba3[_0x2b4126(0x189)]);this[_0x2b4126(0x1a1)](_0x3d2ba3[_0x2b4126(0x1ea)],_0x7e5751[_0x2b4126(0x153)]);const _0x51f359=_0x7e5751[_0x2b4126(0x153)]+'\x00'+_0x7e5751[_0x2b4126(0x175)];if(this[_0x2b4126(0x259)][_0x2b4126(0x102)](_0x51f359))throw new Error(_0x2b4126(0x141));this[_0x2b4126(0x259)][_0x2b4126(0x185)](_0x51f359);try{const _0x33c484=await this[_0x2b4126(0x149)][_0x2b4126(0x249)][_0x2b4126(0x170)](_0x3d2ba3[_0x2b4126(0x1ea)],_0x7e5751[_0x2b4126(0x153)],_0x7e5751[_0x2b4126(0x175)],this[_0x2b4126(0x1e4)]()),_0x44e400=hostedConversationFileDeleteResultSchema[_0x2b4126(0x183)]({'deletedFileId':_0x7e5751[_0x2b4126(0x175)],'files':_0x33c484});return this[_0x2b4126(0x10e)](_0x7e5751[_0x2b4126(0x153)],{'conversationId':_0x7e5751[_0x2b4126(0x153)],'kind':_0x2b4126(0x171),'files':_0x44e400[_0x2b4126(0x171)],'error':null}),_0x44e400;}finally{this[_0x2b4126(0x259)][_0x2b4126(0xe8)](_0x51f359);}}async[_0x44e8b5(0x177)](_0x4778b2){const _0x113fe5=_0x44e8b5,_0x1b427f=hostedRequest(_0x4778b2),_0x34292f=hostedConversationUploadPreflightInputSchema[_0x113fe5(0x183)](_0x1b427f[_0x113fe5(0x189)]),_0x21fb41=this[_0x113fe5(0x1a1)](_0x1b427f[_0x113fe5(0x1ea)],_0x34292f[_0x113fe5(0x153)]),_0x2c50e6=await this[_0x113fe5(0x19a)](_0x21fb41[_0x113fe5(0x23a)],_0x21fb41[_0x113fe5(0x1cd)]),_0x443d2f=this[_0x113fe5(0x149)][_0x113fe5(0x249)][_0x113fe5(0x222)](_0x1b427f[_0x113fe5(0x1ea)],_0x21fb41['id']),_0x499856=await Promise[_0x113fe5(0x23b)](_0x34292f[_0x113fe5(0x171)][_0x113fe5(0x20e)](async _0xbeed2d=>({'name':_0xbeed2d[_0x113fe5(0x26c)],'status':await this[_0x113fe5(0x1c6)](_0x443d2f,_0x21fb41,_0x2c50e6[_0x113fe5(0xf3)],_0xbeed2d[_0x113fe5(0x26c)],_0xbeed2d[_0x113fe5(0x21a)])})));return hostedConversationUploadPreflightResultSchema[_0x113fe5(0x183)]({'files':_0x499856});}async[_0x44e8b5(0x14f)](_0x4d391c){const _0x4f8d32=_0x44e8b5,_0x1340f8=hostedRequest(_0x4d391c),_0x1dde3b=hostedConversationUploadCreateInputSchema[_0x4f8d32(0x183)](_0x1340f8[_0x4f8d32(0x189)]),_0x5dc893=this[_0x4f8d32(0x1a1)](_0x1340f8[_0x4f8d32(0x1ea)],_0x1dde3b[_0x4f8d32(0x153)]),_0x5b0017=_0x1340f8[_0x4f8d32(0x1ea)]+'\x00'+_0x5dc893['id']+'\x00'+_0x1dde3b[_0x4f8d32(0x1c7)],_0x472d77=this[_0x4f8d32(0x1f6)][_0x4f8d32(0x225)](_0x5b0017);if(_0x472d77!==undefined){const _0x119a53=this[_0x4f8d32(0x1ca)][_0x4f8d32(0x225)](_0x472d77);if(_0x119a53!==undefined)return{'upload':hostedConversationUploadSchema[_0x4f8d32(0x183)](uploadProjection(_0x119a53))};}const _0x261a07=await this[_0x4f8d32(0x19a)](_0x5dc893[_0x4f8d32(0x23a)],_0x5dc893[_0x4f8d32(0x1cd)]),_0x3617b7=this[_0x4f8d32(0x149)][_0x4f8d32(0x249)][_0x4f8d32(0x222)](_0x1340f8[_0x4f8d32(0x1ea)],_0x5dc893['id']),_0x83d019=await this[_0x4f8d32(0x1c6)](_0x3617b7,_0x5dc893,_0x261a07[_0x4f8d32(0xf3)],_0x1dde3b[_0x4f8d32(0x26c)],_0x1dde3b[_0x4f8d32(0x21a)]);if(_0x83d019===_0x4f8d32(0x1f3)||_0x83d019===_0x4f8d32(0x25d))throw new Error(_0x4f8d32(0x269));if(_0x83d019!==_0x4f8d32(0x11c))throw new Error(_0x4f8d32(0x202));const _0x32bc95=this['id'](),_0x22a111=join(_0x3617b7[_0x4f8d32(0x103)],'.'+_0x32bc95+_0x4f8d32(0x194)),_0x1ac4a0=join(_0x3617b7[_0x4f8d32(0x103)],_0x1dde3b[_0x4f8d32(0x26c)]),_0xb50889=await open(_0x22a111,'wx',0x37*0x4f+-0x12f1+0x378);await _0xb50889[_0x4f8d32(0x159)]();const _0x35d298={'uploadId':_0x32bc95,'conversationId':_0x5dc893['id'],'userId':_0x1340f8[_0x4f8d32(0x1ea)],'clientRequestId':_0x1dde3b[_0x4f8d32(0x1c7)],'name':_0x1dde3b[_0x4f8d32(0x26c)],'mimeType':_0x1dde3b[_0x4f8d32(0x1e3)],'size':_0x1dde3b[_0x4f8d32(0x21a)],'temporaryPath':_0x22a111,'targetPath':_0x1ac4a0,'receivedBytes':0x0,'status':_0x4f8d32(0x1e9)};return this[_0x4f8d32(0x1ca)][_0x4f8d32(0xfc)](_0x32bc95,_0x35d298),this[_0x4f8d32(0x1f6)][_0x4f8d32(0xfc)](_0x5b0017,_0x32bc95),{'upload':hostedConversationUploadSchema[_0x4f8d32(0x183)](uploadProjection(_0x35d298))};}async[_0x44e8b5(0x228)](_0x291f24){const _0x5351ad=_0x44e8b5,_0x37d221=hostedRequest(_0x291f24),_0x5c3109=hostedConversationUploadChunkInputSchema[_0x5351ad(0x183)](_0x37d221[_0x5351ad(0x189)]),_0x5cd7d9=this[_0x5351ad(0xb6)](_0x37d221[_0x5351ad(0x1ea)],_0x5c3109[_0x5351ad(0x153)],_0x5c3109[_0x5351ad(0x1a2)]);if(_0x5cd7d9[_0x5351ad(0x152)]!==_0x5351ad(0x1e9))throw new Error(_0x5351ad(0x26d));if(_0x5c3109[_0x5351ad(0xcd)]!==_0x5cd7d9[_0x5351ad(0xba)])throw new Error(_0x5351ad(0x251));const _0x53467b=Buffer[_0x5351ad(0x25a)](_0x5c3109[_0x5351ad(0x247)],_0x5351ad(0x22a));if(_0x5cd7d9[_0x5351ad(0xba)]+_0x53467b[_0x5351ad(0xd8)]>_0x5cd7d9[_0x5351ad(0x21a)])throw new Error(_0x5351ad(0x241));await assertUploadTemporaryFile(_0x5cd7d9[_0x5351ad(0x218)],_0x5cd7d9[_0x5351ad(0xba)]);const _0x3f5ca3=await open(_0x5cd7d9[_0x5351ad(0x218)],'r+');try{await _0x3f5ca3[_0x5351ad(0x1d2)](_0x53467b,-0x2659+0x11*-0x202+0x487b,_0x53467b[_0x5351ad(0xd8)],_0x5cd7d9[_0x5351ad(0xba)]);}finally{await _0x3f5ca3[_0x5351ad(0x159)]();}return _0x5cd7d9[_0x5351ad(0xba)]+=_0x53467b[_0x5351ad(0xd8)],{'upload':hostedConversationUploadSchema[_0x5351ad(0x183)](uploadProjection(_0x5cd7d9))};}[_0x44e8b5(0xf2)](_0x82af9f){const _0x21779d=_0x44e8b5,_0x1d1ba3=hostedRequest(_0x82af9f),_0x3a4119=hostedConversationUploadControlInputSchema[_0x21779d(0x183)](_0x1d1ba3[_0x21779d(0x189)]),_0x34b33e=this[_0x21779d(0xb6)](_0x1d1ba3[_0x21779d(0x1ea)],_0x3a4119[_0x21779d(0x153)],_0x3a4119[_0x21779d(0x1a2)]);return{'upload':hostedConversationUploadSchema[_0x21779d(0x183)](uploadProjection(_0x34b33e))};}async[_0x44e8b5(0x1ba)](_0x3a6c80){const _0x23482a=_0x44e8b5,_0x44b19a=hostedRequest(_0x3a6c80),_0x1baca2=hostedConversationUploadControlInputSchema[_0x23482a(0x183)](_0x44b19a[_0x23482a(0x189)]),_0x23b80f=this[_0x23482a(0xb6)](_0x44b19a[_0x23482a(0x1ea)],_0x1baca2[_0x23482a(0x153)],_0x1baca2[_0x23482a(0x1a2)]);if(_0x23b80f[_0x23482a(0x152)]===_0x23482a(0x23f))return{'upload':hostedConversationUploadSchema[_0x23482a(0x183)](uploadProjection(_0x23b80f))};if(_0x23b80f[_0x23482a(0x152)]!==_0x23482a(0x1e9)||_0x23b80f[_0x23482a(0xba)]!==_0x23b80f[_0x23482a(0x21a)])throw new Error(_0x23482a(0x14e));const _0xeb4582=this[_0x23482a(0x1a1)](_0x44b19a[_0x23482a(0x1ea)],_0x23b80f[_0x23482a(0x153)]),_0x51ead6=await this[_0x23482a(0x19a)](_0xeb4582[_0x23482a(0x23a)],_0xeb4582[_0x23482a(0x1cd)]);if(_0x23b80f[_0x23482a(0x21a)]>_0x51ead6[_0x23482a(0xf3)][_0x23482a(0x11b)][_0x23482a(0x14a)]||_0xeb4582[_0x23482a(0x242)][_0x23482a(0x112)]+_0x23b80f[_0x23482a(0x21a)]>_0xeb4582[_0x23482a(0x242)][_0x23482a(0x151)])throw new Error(_0x23482a(0x269));await assertUploadTemporaryFile(_0x23b80f[_0x23482a(0x218)],_0x23b80f[_0x23482a(0x21a)]);const _0x5c5bb5=await lstat(_0x23b80f[_0x23482a(0xdc)])[_0x23482a(0x196)](_0x5af7f0=>{const _0x3928ed=_0x23482a;if(_0x5af7f0[_0x3928ed(0xb8)]===_0x3928ed(0x209))return undefined;throw _0x5af7f0;});if(_0x5c5bb5!==undefined)throw new Error(_0x23482a(0x202));const _0x5d72a0=await open(_0x23b80f[_0x23482a(0x218)],'r+');try{await _0x5d72a0[_0x23482a(0x1a4)]();}finally{await _0x5d72a0[_0x23482a(0x159)]();}await rename(_0x23b80f[_0x23482a(0x218)],_0x23b80f[_0x23482a(0xdc)]);const _0x1fdc16=this[_0x23482a(0x1e4)]();try{await utimes(_0x23b80f[_0x23482a(0xdc)],new Date(_0x1fdc16),new Date(_0x1fdc16));const _0x2d2ce8={'id':this[_0x23482a(0x149)][_0x23482a(0x249)][_0x23482a(0x144)](_0x23b80f[_0x23482a(0x153)],_0x23482a(0x219),_0x23b80f[_0x23482a(0x26c)]),'conversationId':_0x23b80f[_0x23482a(0x153)],'category':_0x23482a(0x219),'relativePath':_0x23b80f[_0x23482a(0x26c)],'displayName':_0x23b80f[_0x23482a(0x26c)],'mimeType':_0x23b80f[_0x23482a(0x1e3)],'size':_0x23b80f[_0x23482a(0x21a)],'source':_0x23482a(0x203),'createdAt':_0x1fdc16,'updatedAt':_0x1fdc16};return _0x23b80f[_0x23482a(0x198)]=await this[_0x23482a(0x149)][_0x23482a(0x249)][_0x23482a(0x1ae)](_0x44b19a[_0x23482a(0x1ea)],_0x2d2ce8),_0x23b80f[_0x23482a(0x152)]=_0x23482a(0x23f),this[_0x23482a(0x10e)](_0x23b80f[_0x23482a(0x153)],{'conversationId':_0x23b80f[_0x23482a(0x153)],'kind':_0x23482a(0x171),'files':this[_0x23482a(0x149)][_0x23482a(0x249)][_0x23482a(0x261)](_0x44b19a[_0x23482a(0x1ea)],_0x23b80f[_0x23482a(0x153)]),'error':null}),{'upload':hostedConversationUploadSchema[_0x23482a(0x183)](uploadProjection(_0x23b80f))};}catch(_0x452828){await rename(_0x23b80f[_0x23482a(0xdc)],_0x23b80f[_0x23482a(0x218)])[_0x23482a(0x196)](()=>undefined);throw _0x452828;}}async[_0x44e8b5(0xd7)](_0x419f03){const _0x1c2051=_0x44e8b5,_0xe10262=hostedRequest(_0x419f03),_0x32d43b=hostedConversationUploadControlInputSchema[_0x1c2051(0x183)](_0xe10262[_0x1c2051(0x189)]),_0x59e28c=this[_0x1c2051(0xb6)](_0xe10262[_0x1c2051(0x1ea)],_0x32d43b[_0x1c2051(0x153)],_0x32d43b[_0x1c2051(0x1a2)]);if(_0x59e28c[_0x1c2051(0x152)]===_0x1c2051(0x23f))throw new Error(_0x1c2051(0x26d));return _0x59e28c[_0x1c2051(0x152)]=_0x1c2051(0x146),await rm(_0x59e28c[_0x1c2051(0x218)],{'force':!![]}),{'upload':hostedConversationUploadSchema[_0x1c2051(0x183)](uploadProjection(_0x59e28c))};}async[_0x44e8b5(0xe8)](_0x4f8469){const _0x4bb1e8=_0x44e8b5,_0x2ffa1f=hostedRequest(_0x4f8469),_0x363e88=hostedConversationIdInputSchema[_0x4bb1e8(0x183)](_0x2ffa1f[_0x4bb1e8(0x189)]),_0x44cbde=this[_0x4bb1e8(0x149)][_0x4bb1e8(0x249)][_0x4bb1e8(0xc4)](_0x2ffa1f[_0x4bb1e8(0x1ea)],_0x363e88[_0x4bb1e8(0x153)]);if(this[_0x4bb1e8(0x1de)][_0x4bb1e8(0x102)](_0x44cbde['id']))throw new Error(_0x4bb1e8(0xbf));this[_0x4bb1e8(0x1de)][_0x4bb1e8(0x185)](_0x44cbde['id']);try{await this[_0x4bb1e8(0x210)](_0x44cbde['id']);const _0x4fd3bf=this[_0x4bb1e8(0x10a)][_0x4bb1e8(0x225)](_0x44cbde['id']);if(_0x4fd3bf!==undefined){const _0x182144=runInterruptionKey(_0x44cbde['id'],_0x4fd3bf[_0x4bb1e8(0xc1)]['id']);this[_0x4bb1e8(0x25f)][_0x4bb1e8(0x185)](_0x182144);if(!_0x4fd3bf[_0x4bb1e8(0x143)]())this[_0x4bb1e8(0x25f)][_0x4bb1e8(0xe8)](_0x182144);}await this[_0x4bb1e8(0xfe)](_0x2ffa1f[_0x4bb1e8(0x1ea)],_0x44cbde['id']);const _0x12e224=this[_0x4bb1e8(0x149)][_0x4bb1e8(0x249)][_0x4bb1e8(0x222)](_0x2ffa1f[_0x4bb1e8(0x1ea)],_0x44cbde['id']);return await this[_0x4bb1e8(0x149)][_0x4bb1e8(0x1ce)][_0x4bb1e8(0x1b6)]({'conversationId':_0x44cbde['id'],'sessionId':_0x44cbde[_0x4bb1e8(0x1d1)],'homeDirectory':_0x12e224[_0x4bb1e8(0x264)]})[_0x4bb1e8(0x196)](()=>undefined),await this[_0x4bb1e8(0x24e)][_0x4bb1e8(0x225)](_0x44cbde['id'])?.[_0x4bb1e8(0x196)](()=>undefined),this[_0x4bb1e8(0xc6)](_0x44cbde['id']),await this[_0x4bb1e8(0x149)][_0x4bb1e8(0x249)][_0x4bb1e8(0x16b)](_0x44cbde['id']),this[_0x4bb1e8(0x145)][_0x4bb1e8(0xe8)](_0x44cbde['id']),hostedConversationDeleteResultSchema[_0x4bb1e8(0x183)]({'deletedConversationId':_0x44cbde['id']});}finally{this[_0x4bb1e8(0x1de)][_0x4bb1e8(0xe8)](_0x44cbde['id']);}}async[_0x44e8b5(0x210)](_0x5e5c0a){const _0x3e8e1b=_0x44e8b5,_0x32bfdf=_0x5e5c0a+'\x00',_0x19e0f1=[...this[_0x3e8e1b(0x266)][_0x3e8e1b(0x25e)]()][_0x3e8e1b(0x124)](([_0x5a5ec0])=>_0x5a5ec0[_0x3e8e1b(0x22f)](_0x32bfdf))[_0x3e8e1b(0x20e)](([,_0x1769df])=>_0x1769df);await Promise[_0x3e8e1b(0x265)](_0x19e0f1);}async[_0x44e8b5(0x22e)](_0xd62978){const _0x2b38b2=_0x44e8b5;try{const _0x3bf2a6=await this[_0x2b38b2(0x225)]({'conversationId':_0xd62978[_0x2b38b2(0x153)],'__requestUserId':_0xd62978[_0x2b38b2(0x1ea)],'__marAgentModels':_0xd62978[_0x2b38b2(0x182)]});if(this[_0x2b38b2(0x13c)][_0x2b38b2(0x225)](_0xd62978[_0x2b38b2(0xcb)])!==_0xd62978)return;this[_0x2b38b2(0x149)][_0x2b38b2(0x1f8)]?.({'type':_0x2b38b2(0xcc),'workbenchConnectionId':_0xd62978[_0x2b38b2(0x22c)],'watchId':_0xd62978[_0x2b38b2(0x19b)],'nodeGeneration':_0xd62978[_0x2b38b2(0xca)],'nodeId':this[_0x2b38b2(0x149)][_0x2b38b2(0x17c)](),'templateId':_0xd62978[_0x2b38b2(0x1cd)],'conversationId':_0xd62978[_0x2b38b2(0x153)],'revision':0x1,'snapshotSequence':++this[_0x2b38b2(0x215)],'expiresAt':_0xd62978[_0x2b38b2(0x127)],'payload':_0x3bf2a6}),_0xd62978[_0x2b38b2(0x140)]=!![];for(const _0xbf2663 of _0xd62978[_0x2b38b2(0xf9)])this[_0x2b38b2(0x1b9)](_0xd62978,_0xbf2663);_0xd62978[_0x2b38b2(0xf9)][_0x2b38b2(0x254)]=0xb5b+0x1841*-0x1+0xce6;}catch(_0x3cc1c9){if(this[_0x2b38b2(0x13c)][_0x2b38b2(0x225)](_0xd62978[_0x2b38b2(0xcb)])!==_0xd62978)return;this[_0x2b38b2(0x149)][_0x2b38b2(0x1f8)]?.({'type':_0x2b38b2(0xef),'workbenchConnectionId':_0xd62978[_0x2b38b2(0x22c)],'watchType':_0x2b38b2(0x1b2),'watchId':_0xd62978[_0x2b38b2(0x19b)],'nodeGeneration':_0xd62978[_0x2b38b2(0xca)],'nodeId':this[_0x2b38b2(0x149)][_0x2b38b2(0x17c)](),'templateId':_0xd62978[_0x2b38b2(0x1cd)],'conversationId':_0xd62978[_0x2b38b2(0x153)],'code':safeErrorCode(_0x3cc1c9,_0x2b38b2(0x25b)),'message':_0x2b38b2(0x260)}),this[_0x2b38b2(0x181)](_0xd62978[_0x2b38b2(0xcb)]);}}[_0x44e8b5(0x26b)](_0x42b0ed){const _0x261bdb=_0x44e8b5;return this[_0x261bdb(0x145)][_0x261bdb(0x225)](_0x42b0ed)??{'status':_0x261bdb(0x21b),'version':0x0,'updatedAt':0x0};}[_0x44e8b5(0x1c3)](_0x41ba65){const _0x37c35b=_0x44e8b5;return hostedConversationSummary(_0x41ba65,this[_0x37c35b(0x26b)](_0x41ba65['id']));}[_0x44e8b5(0x240)](_0x913da0,_0x22f3e2,_0x226503,_0x3da3a0){const _0x41c05c=_0x44e8b5,_0x18ee57=this[_0x41c05c(0x26b)](_0x22f3e2['id']),_0xfd9926={'status':_0x226503,'version':_0x18ee57[_0x41c05c(0x165)]+(0x26a3+0x1724+-0x3dc6*0x1),'updatedAt':_0x3da3a0};this[_0x41c05c(0x145)][_0x41c05c(0xfc)](_0x22f3e2['id'],_0xfd9926),this[_0x41c05c(0x13f)]({'kind':_0x41c05c(0x26b),'userId':_0x913da0,'templateId':_0x22f3e2[_0x41c05c(0x1cd)],'conversationId':_0x22f3e2['id'],'activity':_0xfd9926});}[_0x44e8b5(0x1d5)](_0x5a9e8b,_0x1f9cb,_0x13e439,_0x4442ab){const _0x138103=_0x44e8b5;this[_0x138103(0x13f)]({'kind':_0x138103(0x109),'event':{'runId':_0x13e439,'sequence':0x1,'eventType':_0x138103(0x109),'payload':{'targetType':_0x138103(0x224),'userId':_0x5a9e8b,'templateId':_0x1f9cb[_0x138103(0x1cd)],'conversationId':_0x1f9cb['id'],'conversationTitle':_0x1f9cb[_0x138103(0x163)],'runId':_0x13e439,'notificationId':_0x138103(0x12b)+this[_0x138103(0x149)][_0x138103(0x17c)]()+':'+_0x1f9cb['id']+':'+_0x13e439,'kind':_0x138103(0x173),'outcome':_0x4442ab[_0x138103(0x152)],'occurredAt':_0x4442ab[_0x138103(0xd6)]},'createdAt':_0x4442ab[_0x138103(0xd6)]}});}[_0x44e8b5(0x13f)](_0x550f94){const _0x85bb2e=_0x44e8b5,_0x33aef4=this[_0x85bb2e(0x149)][_0x85bb2e(0x23c)]?.(_0x550f94)??{'sequence':++this[_0x85bb2e(0x199)],'category':_0x85bb2e(0x1b2),'payload':_0x550f94};if(_0x33aef4!==undefined)this[_0x85bb2e(0x149)][_0x85bb2e(0xf7)]?.(_0x33aef4);}[_0x44e8b5(0x227)](_0x23dc6b,_0x3eb8f5,_0x57cbd3,_0x1faa2b){const _0x3ed2b4=_0x44e8b5;this[_0x3ed2b4(0x10e)](_0x23dc6b['id'],{'conversationId':_0x23dc6b['id'],'kind':_0x3ed2b4(0x1e5),'upgrade':{'status':_0x3ed2b4(0x12f),'previousVersionId':_0x3eb8f5,'targetVersionId':_0x57cbd3,'activeVersionId':_0x23dc6b[_0x3ed2b4(0x23a)],'conversation':this[_0x3ed2b4(0x1c3)](_0x23dc6b),'error':{'code':safeErrorCode(_0x1faa2b,_0x3ed2b4(0x248)),'message':_0x3ed2b4(0x1b5)}}});}[_0x44e8b5(0x10e)](_0x49ae4f,_0x270e43){const _0x25ab54=_0x44e8b5,_0x1619ed=[...this[_0x25ab54(0x13c)][_0x25ab54(0x1c1)]()][_0x25ab54(0x124)](_0x52f65e=>_0x52f65e[_0x25ab54(0x153)]===_0x49ae4f);if(_0x1619ed[_0x25ab54(0x254)]===-0x1256+0xd9a+0x4bc)return![];const _0x48fbc9=this[_0x25ab54(0x149)][_0x25ab54(0x23c)]?.(_0x270e43)??{'sequence':++this[_0x25ab54(0x199)],'category':_0x25ab54(0x1b2),'payload':_0x270e43};if(_0x48fbc9===undefined)return![];for(const _0xff08e0 of _0x1619ed){if(!_0xff08e0[_0x25ab54(0x140)])_0xff08e0[_0x25ab54(0xf9)][_0x25ab54(0x1bf)](_0x48fbc9);else this[_0x25ab54(0x1b9)](_0xff08e0,_0x48fbc9);}return!![];}[_0x44e8b5(0x1b9)](_0xc6d82f,_0x51e309){const _0x4b2538=_0x44e8b5;this[_0x4b2538(0x149)][_0x4b2538(0x1f8)]?.({'type':_0x4b2538(0x105),'workbenchConnectionId':_0xc6d82f[_0x4b2538(0x22c)],'watchId':_0xc6d82f[_0x4b2538(0x19b)],'nodeGeneration':_0xc6d82f[_0x4b2538(0xca)],'nodeId':this[_0x4b2538(0x149)][_0x4b2538(0x17c)](),'templateId':_0xc6d82f[_0x4b2538(0x1cd)],'conversationId':_0xc6d82f[_0x4b2538(0x153)],'expiresAt':_0xc6d82f[_0x4b2538(0x127)],'event':_0x51e309});}[_0x44e8b5(0x17a)](_0x52f10e){const _0x40a109=_0x44e8b5;return{'accepted':!![],'watchId':_0x52f10e[_0x40a109(0x19b)],'nodeGeneration':_0x52f10e[_0x40a109(0xca)],'expiresAt':_0x52f10e[_0x40a109(0x127)]};}[_0x44e8b5(0xc6)](_0x33068c){const _0x4b4613=_0x44e8b5;for(const _0x38a035 of[...this[_0x4b4613(0x13c)][_0x4b4613(0x1c1)]()])if(_0x38a035[_0x4b4613(0x153)]===_0x33068c)this[_0x4b4613(0x181)](_0x38a035[_0x4b4613(0xcb)]);}[_0x44e8b5(0x181)](_0x478d80){const _0x450b1b=_0x44e8b5,_0x55bc20=this[_0x450b1b(0x13c)][_0x450b1b(0x225)](_0x478d80);if(_0x55bc20===undefined)return;clearTimeout(_0x55bc20[_0x450b1b(0x22d)]),this[_0x450b1b(0x13c)][_0x450b1b(0xe8)](_0x478d80),this[_0x450b1b(0x155)][_0x450b1b(0x24a)](_0x478d80,_0x55bc20[_0x450b1b(0x10d)]);}[_0x44e8b5(0x10b)](_0x462f37){const _0xdca71e=_0x44e8b5,_0x5960af=setTimeout(()=>this[_0xdca71e(0x181)](_0x462f37),WATCH_TTL_MS);return _0x5960af[_0xdca71e(0xe3)](),_0x5960af;}[_0x44e8b5(0x1a1)](_0x177a13,_0x11ae5c){const _0x3024e6=_0x44e8b5,_0x2df67c=this[_0x3024e6(0x149)][_0x3024e6(0x249)][_0x3024e6(0xc4)](_0x177a13,_0x11ae5c);if(this[_0x3024e6(0x1de)][_0x3024e6(0x102)](_0x2df67c['id']))throw new Error(_0x3024e6(0xbf));if(_0x2df67c[_0x3024e6(0x152)]!==_0x3024e6(0x15e))throw new Error(_0x3024e6(0xbf));return _0x2df67c;}[_0x44e8b5(0xb6)](_0x1b908f,_0x4116e0,_0x28b2cc){const _0x5e6167=_0x44e8b5;this[_0x5e6167(0x149)][_0x5e6167(0x249)][_0x5e6167(0xc4)](_0x1b908f,_0x4116e0);const _0x8aa403=this[_0x5e6167(0x1ca)][_0x5e6167(0x225)](_0x28b2cc);if(_0x8aa403===undefined||_0x8aa403[_0x5e6167(0x1ea)]!==_0x1b908f||_0x8aa403[_0x5e6167(0x153)]!==_0x4116e0)throw new Error(_0x5e6167(0x118));return _0x8aa403;}async[_0x44e8b5(0xfe)](_0x53b63d,_0x39f3c3){const _0x8a0dde=_0x44e8b5;for(const _0xd85df2 of this[_0x8a0dde(0x1ca)][_0x8a0dde(0x1c1)]()){if(_0xd85df2[_0x8a0dde(0x1ea)]!==_0x53b63d||_0xd85df2[_0x8a0dde(0x153)]!==_0x39f3c3)continue;_0xd85df2[_0x8a0dde(0x152)]===_0x8a0dde(0x1e9)&&(_0xd85df2[_0x8a0dde(0x152)]=_0x8a0dde(0x146),await rm(_0xd85df2[_0x8a0dde(0x218)],{'force':!![]})[_0x8a0dde(0x196)](()=>undefined));}}async[_0x44e8b5(0x1df)](_0x47bc2a,_0x5401d2,_0x2f07c6){const _0x4ddc92=_0x44e8b5,_0x483989=this[_0x4ddc92(0x149)][_0x4ddc92(0x249)][_0x4ddc92(0x252)](_0x47bc2a,_0x5401d2,_0x2f07c6);if(_0x483989[_0x4ddc92(0x13b)]!==_0x4ddc92(0x219))throw new Error(_0x4ddc92(0x1e6));return await assertRegularFile(this[_0x4ddc92(0x149)][_0x4ddc92(0x249)][_0x4ddc92(0x1d7)](_0x47bc2a,_0x483989),_0x483989[_0x4ddc92(0x21a)]),_0x483989;}async[_0x44e8b5(0x1c6)](_0x1a79f2,_0x47ee03,_0x3c7f9d,_0x24e5e9,_0x5db34f){const _0x5a431a=_0x44e8b5;if(_0x5db34f>_0x3c7f9d[_0x5a431a(0x11b)][_0x5a431a(0x14a)])return _0x5a431a(0x25d);if(_0x47ee03[_0x5a431a(0x242)][_0x5a431a(0x112)]+_0x5db34f>_0x47ee03[_0x5a431a(0x242)][_0x5a431a(0x151)])return _0x5a431a(0x1f3);const _0x28c6c9=await lstat(join(_0x1a79f2[_0x5a431a(0x103)],_0x24e5e9))[_0x5a431a(0x196)](_0x3f1fb3=>{const _0x4eafcc=_0x5a431a;if(_0x3f1fb3[_0x4eafcc(0xb8)]===_0x4eafcc(0x209))return undefined;throw _0x3f1fb3;});return _0x28c6c9===undefined?_0x5a431a(0x11c):_0x5a431a(0x1d3);}[_0x44e8b5(0x187)](_0x346d7f,_0x43f37f,_0xae1251,_0x1bb891){const _0x53cd3c=_0x44e8b5,_0x5eba35=[{'logicalPath':_0x53cd3c(0x1e1),'physicalPath':_0x43f37f[_0x53cd3c(0x200)],'writable':![]},{'logicalPath':_0x53cd3c(0x179),'physicalPath':_0x346d7f[_0x53cd3c(0x103)],'writable':!![]},{'logicalPath':_0x53cd3c(0x18c),'physicalPath':_0x346d7f[_0x53cd3c(0x262)],'writable':!![]}];if(_0xae1251!==undefined&&_0x1bb891!==undefined)_0x5eba35[_0x53cd3c(0x1bf)]({'logicalPath':_0x1bb891,'physicalPath':_0xae1251,'writable':![]});if(_0x43f37f[_0x53cd3c(0x1dd)]!==undefined)_0x5eba35[_0x53cd3c(0x1bf)]({'logicalPath':_0x43f37f[_0x53cd3c(0x1dd)],'physicalPath':_0x43f37f[_0x53cd3c(0x200)],'writable':![]},{'logicalPath':join(_0x43f37f[_0x53cd3c(0x1dd)],_0x53cd3c(0x1aa)),'physicalPath':_0x346d7f[_0x53cd3c(0x103)],'writable':!![]},{'logicalPath':join(_0x43f37f[_0x53cd3c(0x1dd)],_0x53cd3c(0x11e)),'physicalPath':_0x346d7f[_0x53cd3c(0x262)],'writable':!![]});return _0x5eba35;}[_0x44e8b5(0xe4)](_0xc96a88,_0x5cc400,_0x4a97a7=_0xc96a88[_0x44e8b5(0x17e)],_0x840bee,_0x4f7164){const _0x1fba86=_0x44e8b5;return this[_0x1fba86(0x149)][_0x1fba86(0xf1)]({'policyVersion':HOST_POLICY_VERSION,'workspaceDirectory':_0x5cc400[_0x1fba86(0x200)],..._0x5cc400[_0x1fba86(0x1dd)]===undefined?{}:{'sourceWorkspacePath':_0x5cc400[_0x1fba86(0x1dd)]},'inboxDirectory':_0xc96a88[_0x1fba86(0x103)],'outputDirectory':_0xc96a88[_0x1fba86(0x262)],..._0x840bee===undefined||_0x4f7164===undefined?{}:{'generatedImagesDirectory':_0x840bee,'generatedImagesLogicalPath':_0x4f7164},'temporaryDirectory':_0x4a97a7,'networkMode':_0x5cc400[_0x1fba86(0xf3)][_0x1fba86(0x1a3)]});}[_0x44e8b5(0xe9)](_0x4967da){const _0x5858d0=_0x44e8b5,_0x2778c4=this[_0x5858d0(0x149)][_0x5858d0(0x19f)][_0x5858d0(0xfd)][_0x5858d0(0x190)](_0x5858d0(0x244))[_0x5858d0(0x225)](_0x4967da);if(_0x2778c4===undefined)return undefined;if(typeof _0x2778c4['id']!==_0x5858d0(0x116))throw new Error(_0x5858d0(0x17b));return _0x2778c4['id'];}async[_0x44e8b5(0x19a)](_0x2727ae,_0x3e2ba5){const _0x25fde7=_0x44e8b5,_0x41f9c1=this[_0x25fde7(0x149)][_0x25fde7(0x19f)][_0x25fde7(0xfd)][_0x25fde7(0x190)](_0x25fde7(0x136))[_0x25fde7(0x225)](_0x2727ae,_0x3e2ba5);if(_0x41f9c1===undefined||_0x41f9c1[_0x25fde7(0x152)]!==_0x25fde7(0x217)&&_0x41f9c1[_0x25fde7(0x152)]!==_0x25fde7(0x1ef)||_0x41f9c1[_0x25fde7(0x15d)]!==HOST_POLICY_VERSION||typeof _0x41f9c1[_0x25fde7(0xc9)]!==_0x25fde7(0x116)||typeof _0x41f9c1[_0x25fde7(0x1b0)]!==_0x25fde7(0x116)||typeof _0x41f9c1[_0x25fde7(0x213)]!==_0x25fde7(0x116)||typeof _0x41f9c1[_0x25fde7(0x131)]!==_0x25fde7(0x116)||typeof _0x41f9c1[_0x25fde7(0x235)]!==_0x25fde7(0x116))throw new Error(_0x25fde7(0x17b));const _0x4d9a8c=this[_0x25fde7(0x149)][_0x25fde7(0x249)][_0x25fde7(0xd3)](_0x41f9c1[_0x25fde7(0xc9)]),_0x4e49c2=join(_0x4d9a8c,_0x25fde7(0xfb)),_0x571898=join(_0x4d9a8c,_0x25fde7(0x188)),_0x3a4386=await lstat(_0x4e49c2)[_0x25fde7(0x196)](()=>undefined),_0x447e29=await lstat(_0x571898)[_0x25fde7(0x196)](()=>undefined);if(_0x3a4386===undefined||!_0x3a4386[_0x25fde7(0x184)]()||_0x3a4386[_0x25fde7(0x125)]()||_0x447e29===undefined||!_0x447e29[_0x25fde7(0x250)]()||_0x447e29[_0x25fde7(0x125)]()||(_0x447e29[_0x25fde7(0x263)]&0x45*0x25+0x185b+0x3*-0xac7)!==0xb*-0xad+-0x2*-0x11ea+-0x1af8)throw new Error(_0x25fde7(0x17b));let _0x3a0ce9;try{const _0x4b5466=await readFile(_0x4e49c2,_0x25fde7(0x1cb)),_0x35d7f2=_0x4b5466[_0x25fde7(0x20d)]('\x0a')?_0x4b5466[_0x25fde7(0x20a)](-0x923*-0x3+0x101*0xe+-0x2977,-(0x3*-0x69d+0x28*0x16+0x1068)):_0x4b5466;if(_0x35d7f2!==_0x41f9c1[_0x25fde7(0x1b0)]||createHash(_0x25fde7(0x1c2))[_0x25fde7(0x160)](_0x35d7f2)[_0x25fde7(0x14b)](_0x25fde7(0x21f))!==_0x41f9c1[_0x25fde7(0x131)])throw new Error(_0x25fde7(0x17b));_0x3a0ce9=JSON[_0x25fde7(0x183)](_0x35d7f2);}catch{throw new Error(_0x25fde7(0x17b));}if(!record(_0x3a0ce9))throw new Error(_0x25fde7(0x17b));const _0x2a471f=publishedTemplateSnapshot(_0x3a0ce9),_0x35bb3e=publishedTemplateDraft(_0x2a471f[_0x25fde7(0x19e)],_0x3a0ce9[_0x25fde7(0xf3)]),_0x33c91=_0x35bb3e[_0x25fde7(0xf3)],_0x3f937d=publishedMcpServers(_0x3a0ce9[_0x25fde7(0x1d8)]),_0x1d5f15=publishedTemplateContentHash(_0x2a471f[_0x25fde7(0x221)],_0x2a471f[_0x25fde7(0x25e)],_0x2a471f[_0x25fde7(0x19e)]),_0x5e7588=_0x2a471f[_0x25fde7(0x25e)][_0x25fde7(0x134)]((_0x267ef4,_0x82113c)=>_0x267ef4+_0x82113c[_0x25fde7(0x21a)],0x9b9*-0x2+-0x317+0x1689);if(_0x3a0ce9[_0x25fde7(0xd2)]!==_0x41f9c1[_0x25fde7(0x235)]||createHash(_0x25fde7(0x1c2))[_0x25fde7(0x160)](JSON[_0x25fde7(0x128)](_0x3f937d))[_0x25fde7(0x14b)](_0x25fde7(0x21f))!==_0x41f9c1[_0x25fde7(0x235)]||_0x3a0ce9[_0x25fde7(0x1b4)]!==_0x41f9c1[_0x25fde7(0x213)]||_0x1d5f15!==_0x41f9c1[_0x25fde7(0x213)]||_0x41f9c1[_0x25fde7(0x1f7)]!==_0x2a471f[_0x25fde7(0x25e)][_0x25fde7(0x254)]||_0x41f9c1[_0x25fde7(0x1e7)]!==_0x5e7588)throw new Error(_0x25fde7(0x17b));if(_0x3a0ce9[_0x25fde7(0x148)]!==_0x2727ae||_0x3a0ce9[_0x25fde7(0x1cd)]!==_0x3e2ba5||_0x3a0ce9[_0x25fde7(0x206)]!==HOST_POLICY_VERSION||_0x33c91[_0x25fde7(0x1cd)]!==_0x3e2ba5||_0x33c91[_0x25fde7(0x17c)]!==this[_0x25fde7(0x149)][_0x25fde7(0x17c)]())throw new Error(_0x25fde7(0x17b));return{'id':_0x2727ae,'templateId':_0x3e2ba5,'storageKey':_0x41f9c1[_0x25fde7(0xc9)],'templateDirectory':_0x571898,..._0x2a471f[_0x25fde7(0x1dd)]===undefined?{}:{'sourceWorkspacePath':_0x2a471f[_0x25fde7(0x1dd)]},'draft':_0x33c91,'modelPolicy':_0x35bb3e[_0x25fde7(0xec)],'mcpServers':_0x3f937d};}}function hostedRequest(_0x114f6c){const _0x1b3f5b=_0x44e8b5;if(!record(_0x114f6c))throw new Error(_0x1b3f5b(0x17d));const {__requestUserId:_0x555a0c,__template:_0x3e0956,__marAgentModel:_0x345cb1,__marAgentModels:_0x219440,__marAgentRuntimeScopeId:_0x5ee1d6,__workspaceWatchSessionHash:_0x1dd536,__templateDeleted:_0x4f83f7,..._0x4447af}=_0x114f6c;if(typeof _0x555a0c!==_0x1b3f5b(0x1af)||!Number[_0x1b3f5b(0x232)](_0x555a0c)||_0x555a0c<=-0x1e1c+0x7c2+0xb2d*0x2)throw new Error(_0x1b3f5b(0x17d));if(_0x4f83f7!==undefined&&_0x4f83f7!==!![])throw new Error(_0x1b3f5b(0x17d));if(_0x5ee1d6!==undefined&&(typeof _0x5ee1d6!==_0x1b3f5b(0x116)||_0x5ee1d6[_0x1b3f5b(0x254)]===-0xd*-0x15d+-0xdc1+0x3f8*-0x1))throw new Error(_0x1b3f5b(0x17d));return{'data':_0x4447af,'userId':_0x555a0c,..._0x3e0956===undefined?{}:{'template':_0x3e0956},..._0x345cb1===undefined?{}:{'model':_0x345cb1},..._0x219440===undefined?{}:{'models':_0x219440},..._0x5ee1d6===undefined?{}:{'runtimeScopeId':_0x5ee1d6},..._0x1dd536===undefined?{}:{'sessionHash':_0x1dd536},..._0x4f83f7===!![]?{'templateDeleted':!![]}:{}};}function requireWatchSessionHash(_0xc446eb){const _0x45528d=_0x44e8b5;if(typeof _0xc446eb!==_0x45528d(0x116)||_0xc446eb[_0x45528d(0x254)]===-0x3*0xa59+-0x3*-0xb9c+-0x3c9)throw new Error(_0x45528d(0x17d));return _0xc446eb;}function watchOwnerKey(_0x3d285a,_0x3d3415){return _0x3d285a+':'+_0x3d3415;}function runtimeModels(_0x308ef9){const _0x4d024f=_0x44e8b5;return marAgentRuntimeModelConfigurationSchema[_0x4d024f(0x15c)]()[_0x4d024f(0x183)](_0x308ef9);}function allowedModels(_0x5c5de8,_0x470442){const _0x4c59a1=_0x44e8b5,_0x366742=new Set(_0x5c5de8[_0x4c59a1(0xec)][_0x4c59a1(0x142)]);return _0x470442[_0x4c59a1(0x124)](_0x1d0436=>_0x1d0436[_0x4c59a1(0x180)]&&_0x366742[_0x4c59a1(0x102)](_0x5c5de8[_0x4c59a1(0xec)][_0x4c59a1(0x1ab)]===_0x4c59a1(0x22b)?_0x1d0436[_0x4c59a1(0x111)]:_0x1d0436['id']));}function selectModel(_0x2198d4,_0x4a8565,_0x4c1bdc){const _0x367ca8=_0x44e8b5,_0x8e633d=allowedModels(_0x2198d4,_0x4a8565),_0x417ba2=_0x8e633d[_0x367ca8(0x1d6)](_0x865c7=>_0x865c7['id']===_0x4c1bdc);if(_0x417ba2!==undefined)return _0x417ba2;const _0x3682cd=_0x8e633d[_0x367ca8(0x1d6)](_0x5b873a=>(_0x2198d4[_0x367ca8(0xec)][_0x367ca8(0x1ab)]===_0x367ca8(0x22b)?_0x5b873a[_0x367ca8(0x111)]:_0x5b873a['id'])===_0x2198d4[_0x367ca8(0xec)][_0x367ca8(0xdd)]);if(_0x3682cd!==undefined)return _0x3682cd;const _0x39ae99=_0x2198d4[_0x367ca8(0xec)][_0x367ca8(0x142)][_0x367ca8(0x20e)](_0x487fad=>_0x8e633d[_0x367ca8(0x1d6)](_0x3ce7a9=>(_0x2198d4[_0x367ca8(0xec)][_0x367ca8(0x1ab)]===_0x367ca8(0x22b)?_0x3ce7a9[_0x367ca8(0x111)]:_0x3ce7a9['id'])===_0x487fad))[_0x367ca8(0x1d6)](_0x5050b1=>_0x5050b1!==undefined);if(_0x39ae99===undefined)throw new Error(_0x367ca8(0x122));return _0x39ae99;}function publishedTemplateDraft(_0x481801,_0x5b0d8d){const _0x1578f0=_0x44e8b5,_0x5d9e7c=conversationTemplateDraftSchema[_0x1578f0(0x1c9)](_0x5b0d8d);if(_0x5d9e7c[_0x1578f0(0x207)]){const {allowedModels:_0x17509e,defaultModelId:_0x535454,..._0x34d5aa}=_0x5d9e7c[_0x1578f0(0x189)];return{'draft':_0x34d5aa,'modelPolicy':{'identity':_0x1578f0(0x22b),'allowedIds':_0x17509e[_0x1578f0(0x20e)](_0x5b54d6=>_0x5b54d6[_0x1578f0(0x111)]),'defaultId':_0x535454}};}if(_0x481801!==0x1*-0xe99+-0xa7*-0x35+-0x13f9||!record(_0x5b0d8d)||_0x1578f0(0x132)in _0x5b0d8d||!Array[_0x1578f0(0x10c)](_0x5b0d8d[_0x1578f0(0x169)]))throw new Error(_0x1578f0(0x17b));const _0x3d2413=_0x5b0d8d[_0x1578f0(0x169)],_0x16715e={..._0x5b0d8d};delete _0x16715e[_0x1578f0(0x169)];const _0x3c4962=conversationTemplateDraftSchema[_0x1578f0(0x1c9)]({..._0x16715e,'allowedModels':_0x3d2413[_0x1578f0(0x20e)](_0x568026=>({'modelId':_0x568026,'name':_0x568026}))});if(!_0x3c4962[_0x1578f0(0x207)])throw new Error(_0x1578f0(0x17b));const {allowedModels:_0x35259d,defaultModelId:_0x518658,..._0x2bcf6a}=_0x3c4962[_0x1578f0(0x189)];return{'draft':_0x2bcf6a,'modelPolicy':{'identity':_0x1578f0(0x1fd),'allowedIds':_0x35259d[_0x1578f0(0x20e)](_0x27b6e4=>_0x27b6e4[_0x1578f0(0x111)]),'defaultId':_0x518658}};}function networkModels(_0x37addb,_0x3649ea){const _0x42db84=_0x44e8b5;if(_0x3649ea!==_0x42db84(0x195))return _0x37addb;return _0x37addb[_0x42db84(0x20e)](_0x5c6967=>_0x5c6967[_0x42db84(0x113)]?{..._0x5c6967,'hostedWebSearch':![]}:_0x5c6967);}function _0xed8b(){const _0x1af476=['C3vJy2vZCW','q1vtve9n','ru5pru5u','C2XPy2u','zMLUAxnOtwvZC2fNzq','Aw5JBhvKzxm','zw5KC1DPDgG','BwfW','y29UzMLNDxjHDgLVBG','D2fPDezVCLbLBMrPBMDnzxnZywDLu3rHCNrZ','uLvox0LnquDfx05pvf9gt1vora','qvvutW','y29UDgvUDf9OyxnO','mtmYmtm1mKrTsgXqsG','C25HChnOB3rtzxf1zw5Jzq','ChvIBgLZAfj1BNrPBwvfDMvUDa','qvzbsuXbqKXf','DgvTCg9Yyxj5ugf0Aa','vvbmt0fe','C2L6zq','surmrq','igrPCMvJDg9YEs4','yM9VBgvHBG','DxbKyxrLtwv0ywrHDge','Agv4','y29UDMvYC2f0Aw9U','zgLYzwn0B3jPzxm','Cgf0AhngB3jdB252zxjZyxrPB24','yxjNCW','se9tvevex0nptLzfuLnbveLptG','z2v0','mtmXnJuXnhrLz2vota','ChvIBgLZAfvWz3jHzgvgywLSDxjL','D3jPDgvvCgXVywrdAhvUAW','CgLUBMvKqxq','yMfZzty0','vvbtvfjfqu1Ftu9eruXFsuq','D29YA2jLBMnOq29UBMvJDgLVBKLK','DgLTzxi','Aw5PDgLHBgL6zvDHDgnOtgvHC2u','C3rHCNrZv2L0Aa','DgL0BgvdAgfUz2vK','l2XPyJy0','AxntywzLsw50zwDLCG','A2v5CW','se9tvevex0nptLzfuLnbveLptL9svu5Fqunusvzf','BwnWx2nVBMzPz19OyxnO','B2jQzwn0','y3jLyxrLtwvZC2fNzq','l3bYB2m','CMvSzwfZzunVBNzLCNnHDgLVBKzVCKnSzwfUDxa','ywn0AxzLvMvYC2LVBKLK','ywXS','BMv4DfDVCMTIzw5JAev2zw50','Bg9JywXLq29TCgfYzq','CMvHC29UAw5NrwzMB3j0CW','q09nueXfveve','ChvIBgLZAefJDgL2Axr5','se9tvevex0nptLzfuLnbveLptL9vueXpqurFu0LArv9jtLzbteLe','CxvVDge','y3vYCMvUDfzLCNnPB25jza','u0vmrunuigLKiezst00Gy29UDMvYC2f0Aw9Ux3rLBxbSyxrLx3zLCNnPB25ZcIaGicaGicaGifDirvjfihrLBxbSyxrLx2LKpt8Gqu5eihn0yxr1CZ0NqvzbsuXbqKXfjWOGicaGicaGicbpuKrfuIbcwsb2zxjZAw9Ux251BwjLCIbervndlhb1yMXPC2HLzf9HDcbervndlgLKierfu0mkicaGicaGicaGteLnsvqGmq','l2XPyG','u0vtu0LptL9xqvrdsf9ot1rFrK9vtKq','zgf0yujHC2u2na','se9tvevex0nptLzfuLnbveLptL9vueDsqurfx0zbsuXfra','C3rVCMu','CMvSzwfZzq','l3j1BNrPBwu','CgLUBMvK','CMvSyxrPDMvqyxrO','CNvUu2v0DgXLBwvUDhm','vgHLihb1yMXPC2HLzcb3B3jRC3bHy2uGAxmGywXZBYbTB3vUDgvKihjLywqTB25SEsbHDca','AxneAxjLy3rVCNK','se9tvevex0nptLzfuLnbveLptL9vueXpqurFt0zgu0vux0LovKfmsuq','CMvXDwLYzuzPBgu','DhjPBq','BgvUz3rO','AgLZDg9YEq','mtuZnJa2qLnmDeX6','lsaVD29YA3nWywnLl2LUyM94lW','vgHLihb1yMXPC2HLzcb3B3jRC3bHy2uGCM9VDcbPCYbYzwfKlw9UBhKUie9UBhKGl3DVCMTZCgfJzs9PBMjVEcbHBMqGl3DVCMTZCgfJzs9VDxrWDxqGyxjLihDYAxrHyMXLlG','zMLSzurLBgv0zxm','zNjVBq','se9tvevex0nptLzfuLnbveLptL9xqvrdsf9gquLmruq','Cgf0AhngB3jnyw5PzMvZDa','ve9px0XbuKDf','zw50CMLLCW','zxHWzwn0zwrjBNrLCNj1ChrPB25Z','sg9ZDgvKignVBNzLCNnHDgLVBIb3yxrJAcbZBMfWC2HVDcbMywLSzwqU','BgLZDezPBgvZ','B3v0Chv0rgLYzwn0B3j5','Bw9Kzq','Ag9TzurPCMvJDg9YEq','ywXSu2v0DgXLza','CgvUzgLUz01LC3nHz2vZ','su5urvjsvvburuq','ywr2yw5JzuXHC3rby3rPDML0Eq','se9tvevex0nptLzfuLnbveLptL9rvu9uqv9fwenfrurfra','zMLUzenVBNzLCNnHDgLVBKj5q2XPzw50uMvXDwvZDa','ywn0AxzPDhK','BMfTzq','se9tvevex0nptLzfuLnbveLptL9vueXpqurFu1rbvevFsu5wquXjra','C3vIyxjYyxK','CMvXDwLYzvvWBg9Hza','yxbWBhLbDxrVBwf0AwnuAxrSzq','y29Kzq','CNvUlq','CMvJzwL2zwrcExrLCW','AgvHzgvYCW','y2XPzw50twvZC2fNzuLK','y29UDMvYC2f0Aw9UrgLYzwn0B3j5','yMvNAw5dB252zxjZyxrPB25dBgvHBNvW','se9tvevex0nptLzfuLnbveLptL9tvefurv9jtLzbteLe','tMv0D29YAYbHy2nLC3mGAxmGzgLZywjSzwqUieXVy2fSihbYB2nLC3nLCYWGv2vIifnLyxjJAcWGv2vIiezLDgnOlcbTB2rLBc1OB3n0zwqGD2vIlcbHBMqGCMvTB3rLieHuvfaGtunqignHBM5VDcb1C2uGDgHLig5LDhDVCMSU','CNvU','zxHLy3v0ywjSzq','DxjS','CMvXDwLYzunVBNzLCNnHDgLVBG','C3bSAxq','CMvTB3zLq29UDMvYC2f0Aw9Uv2f0y2HmzwfZzxm','sg9ZDgvKignVBNzLCNnHDgLVBIbMAwXLihbYB2PLy3rPB24GzMfPBgvKlG','C29Tzq','C3rVCMfNzv9RzxK','BM9KzuDLBMvYyxrPB24','B3DUzxjlzxK','D2f0y2GUAg9ZDgvKlwnVBNzLCNnHDgLVBI5ZBMfWC2HVDa','B2zMC2v0','y29TBwfUza','CMvQzwn0','Bg9JywWTDgvZDc1Nzw5LCMf0Aw9U','DgvTCgXHDgvoyw1L','BwnWq29UzMLNsgfZAa','DgvTCgXHDgvwzxjZAw9UrgLYzwn0B3j5','Bwf4u3rVCMfNzuj5DgvZ','n3HJEKvvrq','y29TCgXLDgvKqxq','y2fUy2vSvxbSB2fK','yNL0zuXLBMD0Aa','mtCZmJi5m2HzuMvfAa','vgHPCYbPCYbHie5VzguTAg9ZDgvKignVBNzLCNnHDgLVBI4GvgHLieHVC3qTzgvJBgfYzwqGBw91BNrZigfYzsb0AguGy29TCgXLDguGzMLSzsbIB3vUzgfYEs4','se9tvevex0nptLzfuLnbveLptL9uru1qtefurv9vtKfwquLmqujmrq','DgfYz2v0ugf0Aa','zgvMyxvSDeLK','tK9erq','yNL0zxnszwfK','l2HVBwuVBwfY','ywXSB2m','CNvUDgLTzvnJB3bLswq','Dw5Yzwy','ChjVy2vZC0v4zwn1Dg9Y','DhjHBNnWB3j0','mtG4rKHwy1zd','uLvoveLnrq','zgvSzxrL','Bgf0zxn0qxzHAwXHyMXLvgvTCgXHDgvwzxjZAw9Uswq','Bwf4','zw52AxjVBM1LBNq','Bw9KzwXqB2XPy3K','AM9PBG','igfYzsbHBgLHC2vZig9MihrOzsbZyw1LihDYAxrHyMXLig92zxjSyxLZlG','D2f0y2GUzMfPBgvK','yxjNDw1LBNrZ','ChjVy2vZC0v4zwn1Dg9YrMfJDg9YEq','DxbSB2fKu3rHDhvZ','zhjHzNq','zgLZCg9Zzq','Aw5WDxrdyxbHyMLSAxrPzxm','zNvSBc1Hy2nLC3m','zw1PDfDVCMTIzw5JAev2zw50','CMvZCg9UC2vZuhjLDMLVDxnszxnWB25ZzuLK','CgvUzgLUz0v2zw50CW','Aw1Hz2vjBMrLEa','BwfUAwzLC3qUANnVBG','C2v0','CMf3','y2fUy2vSq29UDMvYC2f0Aw9UvxbSB2fKCW','AxndB252zxjZyxrPB25jBLvZzq','ChjLDMLVDxnwzxjZAw9Uswq','ChjLCgfYzunVBNzLCNnHDgLVBKvUDMLYB25Tzw50','AgfZ','DxbSB2fKC0rPCMvJDg9YEq','DxnLCLn0B3jHz2vlzxK','D2f0y2GUAg9ZDgvKlwnVBNzLCNnHDgLVBI5LDMvUDa','yxzHAwXHyMXL','DgvZDa','vu5srvnuuKLdveve','BM90AwzPy2f0Aw9U','ywn0AxzLuNvUCW','D2f0y2HmzwfZzvrPBwvY','AxnbCNjHEq','C2XVDfrVA2vU','ChvIBgLZAeHVC3rLzev2zw50','C3rHCNrLzef0','zgvZy3jPChrPB24','Bw9KzwXjza','DxnLzej5DgvZ','Ag9ZDgvKv2vIu2vHCMnO','Dw53yxrJAa','u1vdq0vfreve','C3rYAw5N','revmrvrfra','se9tvevex0nptLzfuLnbveLptL9vueXpqurFtK9ux0zpvu5e','BgLUA1rHCMDLDa','v2HLBIb0AguGDxnLCIbHC2TZihrVihbSywnLigeGChjLDMLVDxnSEsbNzw5LCMf0zwqGAw1Hz2uGAw4GB3v0Chv0lcbPBNnWzwn0ia','CxvVDgfZ','uKvbrfK','BwLU','B3v0Chv0','CMvHzeLTywDL','y3vYC29Y','igfUzcbJB3b5ihrOzsbLEgLZDgLUzYbMAwXLigzYB20G','se9tvevex0nptLzfuLnbveLptL9nt0rftf9ot1rFqvzbsuXbqKXf','CNvUswq','zMLSDgvY','AxntEw1IB2XPy0XPBMS','D2f0y2G','zxHWAxjLC0f0','C3rYAw5NAwz5','y3jLyxrLzef0','sfruua','CNvUoG','DgfYz2v0vMvYC2LVBKLK','BMXPBMS','y29UzMLNDxjHDgLVBIXKAxnWBgf5tMfTzsXPzcXVCMLNAw4SCNvUDgLTzsXZzxj2zxjoyw1LlhrYyw5ZCg9YDcX2zxjZAw9U','rKfjteve','yMfZzvvYBa','BwfUAwzLC3rFAgfZAa','ywXSB3DLze1VzgvSCW','mJjeshrlqMW','CMvKDwnL','ChjVDg9JB2W','u0vmrunuigLKlhrLBxbSyxrLx2LKlhn0yxr1CYXZDg9YywDLx2TLEsXTyw5PzMvZDcXJB250zw50x2HHC2GSBwfUAwzLC3rFAgfZAcXTy3bFy29UzMLNx2HHC2GScIaGicaGicaGicaGicaGicbMAwXLx2nVDw50lhrVDgfSx2j5DgvZlgHVC3rFCg9SAwn5x3zLCNnPB24kicaGicaGicaGrLjptsbJB252zxjZyxrPB25FDgvTCgXHDgvFDMvYC2LVBNmGv0HfuKuGAwq9pYbbtKqGDgvTCgXHDgvFAwq9pW','BgfZDefJDgL2Axr5qxq','uLvotKLorW','Bwf4t3v0Chv0vg9Rzw5Z','l3vZCG','y2f0zwDVCNK','D2f0y2HmzwfZzxm','u1LnteLosW','CMvUzxC','ChvIBgLZAfDVCMTIzw5JAev2zw50','CMvHzhK','se9tvevex0nptLzfuLnbveLptL9gsuXfx0nptKzmsunu','ywXSB3DLzeLKCW','y2fUy2vS','zMLSzvbYB2PLy3rPB25jza','ywn0AxzPDgLLCW','q0foq0vmteve','u05bufnit1q','DMvYC2LVBKLK','B3b0Aw9UCW','Bwf4vxbSB2fKqNL0zxm','zgLNzxn0','mJqWmJm3tLHYDMfu','rKLmrq','se9tvevex0nptLzfuLnbveLptL9vueXpqurFsu5dt01qtevurq','y3jLyxrLvxbSB2fK','CMvWBgfJzq','Bwf4qNL0zxm','C3rHDhvZ','y29UDMvYC2f0Aw9Uswq','y3jLyxrL','C2vZC2LVBLDHDgnOu2XVDhm','igfUzca','y3jLyxrLu2vZC2LVBG','CMvHza','y2XVC2u','C2vYDMvYtMfTzq','zMLUAxnOuNvU','yxjYyxK','Ag9ZDf9WB2XPy3LFDMvYC2LVBG','qunusvzf','BwvZC2fNzq','DxbKyxrL','B3v0Chv0q2fWywjPBgL0AwvZ','se9tvevex0nptLzfuLnbveLptL9gsuXfx1jfq09oq0Lmrv9gquLmruq','DgL0Bgu','q0foq0vmteLorW','DMvYC2LVBG','C2vJCMv0rw52AxjVBM1LBNq','DxbKyxrLzef0','l2rLDG','ywXSB3DLze1VzgvSswrZ','igfZigeGy29TCgf0AwjPBgL0EsbHBgLHCZSGAxqGAxmGDgHLihnHBwuGAw1TDxrHyMXLihnUyxbZAg90lcbUB3qGDgHLigXPDMuGC291CMnLifDVCMTZCgfJzs4G','CgvYBwfUzw50rgvSzxrLq29UDMvYC2f0Aw9U','C2vJCMv0tMfTzq','ChjVBxb0','CMvJB25JAwXLrMLSzxm','C2vZC2LVBKHHC2G','zgvSzxrLrMLSzq','zMLSzxm','DxbKyxrLq29UDMvYC2f0Aw9U','uLvox1rfuK1jtKfm','m1rNr1L5uW','zMLSzuLK','l2jPBG','ChjLzMXPz2H0vxbSB2fK','q09ovKvsu0fusu9ox1rftvbmqvrfx01duf9jtLzbteLe','l3DVCMTZCgfJzs9PBMjVEa','ywnJzxb0zwrxyxrJAa','q09ovKvsu0fusu9ox1rftvbmqvrfx1zfuLnjt05Fq09suLvqveve','BM9KzuLK','se9tvevex0nptLzfuLnbveLptL9ot1rFqvvuse9ssvPfra','DgvTCg9Yyxj5uM9VDerPCMvJDg9YEq','Aw50zxjYDxb0','zw5HyMXLza','CMvTB3zLv2f0y2HmzwfZzq','Bw9KzwXZ','CgfYC2u','AxngAwXL','ywrK','se9tvevex0nptLzfuLnbveLptL9trvntsu9ox0LovKfmsuq','Cgf0Ae1VDw50CW','y29UDgvUDa','zgf0yq','CgvUzgLUz0nYzwf0zxm','C2f2zu1LC3nHz2vby2nLChrHBMnL','l3DVCMTZCgfJzs9VDxrWDxq','l3nIAw4','zgLZCgXHEu5HBwu','uMvHzcb1C2vYihvWBg9HzhmGzNjVBsaVD29YA3nWywnLl2LUyM94igfUzcbWBgfJzsb1C2vYlxzPC2LIBguGzgvSAxzLCMfIBgvZigLUic93B3jRC3bHy2uVB3v0Chv0lG','ChjLCgfYzq','C3rHCNrnzxnZywDL','C3rHCNrsDw4','AgfZtM9Urw1WDhLvC2vYtwvZC2fNzq','lNvWBg9Hza','tK9orq','y2f0y2G','AxrLBxm','zMLSzq','D29YA2jLBMnOu2vXDwvUy2u','Bg9HzfrLBxbSyxrLvMvYC2LVBG','D2f0y2Hjza','C29YDa','zMLUywXSEq','C2nOzw1HvMvYC2LVBG','zgf0ywjHC2u','vgHLieHVC3qGzw5MB3jJzxmGDgHPCYbMAwXLigjVDw5Kyxj5lcbHBMqGBg9JywWGChjVy2vZC2vZihj1BIbPBNnPzguGyw4GB3bLCMf0Aw5Nlxn5C3rLBsbZyw5KyM94lG','CMvXDwLYzvDYAxrHyMXLq29UDMvYC2f0Aw9U','DxbSB2fKswq','BMv0D29YA01Vzgu','C3LUyW','CMvHzezPBgu','CMvZB2X2zq','Dg9tDhjPBMC','BgLZDa','DgfYz2v0s2LUza','Aw5IB3G','AwrLBNrPDhK','yxnZzxj0q2fUq3jLyxrL','v09ss1nqqunf','CMvNAxn0zxjgAwXL','BNvTyMvY','BwfUAwzLC3q','BgLTAxq','Ag9ZDgvKlwnVBNzLCNnHDgLVBG','u1rbuLrjtKC','y29UDgvUDeHHC2G','vgHLignVBNzLCNnHDgLVBIb0zw1WBgf0zsb1CgDYywrLigzHAwXLzc4','CMvSzwfZzvnLC3nPB24','zMXHDe1HCa','CMvZB2X2zwruyxjNzxq','zw1PDfDHDgnOtgvHC2vfDMvUDa','y29TCgXLDgvvCgXVywq','rvHfq1vusu9o','y29UDgv4DfDPBMrVD1rVA2vUCW','tg9JywWGChjVy2vZC2vZlcboB2rLlwXVy2fSifDLyIbgzxrJAcWGyxzHAwXHyMXLifDLyIbtzwfYy2GSig1VzgvSlwHVC3rLzcb3zwiSigfUzcbWDwjSAxnOzwqGCMvTB3rLieHuvfaGtunqig1HEsbHy2nLC3mGBMv0D29YA3mGCMvHy2HHyMXLigzYB20GDgHPCYboB2rLlG','se9tvevex0nptLzfuLnbveLptL9gsuXfx1jbtKDfx0LovKfmsuq','ChvZAa','C25HChnOB3q','DMfSDwvZ','C2HHmJu2','C3vTBwfYEq','qxr0ywnOBwvUDhm6cG','BgLZDenVBNzLCNnHDgLVBNm','DxbSB2fKuhjLzMXPz2H0u3rHDhvZ','y2XPzw50uMvXDwvZDeLK','DgvTCgXHDgvezwXLDgvK','C2fMzvbHCNnL','DxbSB2fKCW','DxrMoa','CMv0ywLUq29UDMvYC2f0Aw9UvgvTCgXHDgu','DgvTCgXHDgvjza','CNvUDgLTzq','ntKZnwz1sKvMyW','y29TCgXLDgLVBG','C2vZC2LVBKLK','D3jPDgu','q09orKXjq1q','B3DUCW','ChvIBgLZAfrLCM1PBMfStM90AwzPy2f0Aw9U','zMLUza','zMLSzvbHDgG','BwnWu2vYDMvYCW','DxbKyxrLq29UzMLNDxjHDgLVBG','Cgf0Ahm','zw4Tvvm','u1resu8','C291CMnLv29YA3nWywnLugf0Aa','y2XLyw51CeXVy2TZ','CMvXDwLYzuf0DgfJAg1LBNq','q09ovKvsu0fusu9ox0Hpu1rjtKDFvu5bvKfjtefcteu','l3DVCMTZCgfJzq','CMvZCg9UC2vZvhjHBNnWB3j0','BwLTzvr5Cgu','BM93','DxbNCMfKzq','se9tvevex0nptLzfuLnbveLptL9bvfrbq0Hnru5ux0LovKfmsuq','Dg90ywXFyNL0zxm','DgvTCgXHDgu','vvbmt0fesu5h','DxnLCKLK','DgHLBG','l3rTCa','B3bLCMf0Aw9UCW','DgL0BgvtB3vYy2u','uKvuquLoruq','y3jLyxrLq29UDMvYC2f0Aw9U','reLsrunut1jzaa','ihrVic93B3jRC3bHy2uVB3v0Chv0igLUC3rLywqGB2yGCMvJCMvHDgLUzYbVCIbYzwDLBMvYyxrPBMCGAxqU','uvvpvefFrvHdruveruq','l3j1BG','ChjLCgfYzuzVCKrPC2fIBgu','DxbSB2fKC0j5uMvXDwvZDa','zMLSzv9JB3vUDa','zw1PDfDHDgnOrxzLBNq','r2vUzxjHDgvKigLTywDLCYbMCM9TihrOAxmGy29UDMvYC2f0Aw9UihjLBwfPBIbHDMfPBgfIBguGywnYB3nZigv4zwn1DgLVBNmGAw4GDgHLihjLywqTB25SEsa','zMLUze1LC3nHz2u','B3jPz2LU','zgLZywjSzvbYzxbHCMvK','q09orKLhvvjbveLptL9jra','C2f2zuf1Dg9TyxrPy1rPDgXL','A2LUza','DgvTCgXHDgveAxjLy3rVCNK','ndK1mZuWshjWquvM','se9tvevex0nptLzfuLnbveLptL9gsuXfx0LovKfmsuq','vvnfuG','y29UDMvYC2f0Aw9Uu3rVCMfNzuTLEq','yxr0ywnOBwvUDeLKCW','Ag9ZDfbVBgLJEvzLCNnPB24'];_0xed8b=function(){return _0x1af476;};return _0xed8b();}function publishedMcpServers(_0x3f74d7){const _0x26d9ad=_0x44e8b5;if(!Array[_0x26d9ad(0x10c)](_0x3f74d7))throw new Error(_0x26d9ad(0x17b));return _0x3f74d7[_0x26d9ad(0x20e)](_0x4e16a5=>{const _0x1510f0=_0x26d9ad;if(!record(_0x4e16a5))throw new Error(_0x1510f0(0x17b));const _0x288b5c=Object[_0x1510f0(0x233)](_0x4e16a5)[_0x1510f0(0x19c)]()[_0x1510f0(0xed)](',');if(_0x288b5c!==_0x1510f0(0x12e))throw new Error(_0x1510f0(0x17b));const _0x17ba1c=mcpRuntimeDescriptorSchema[_0x1510f0(0x183)](_0x4e16a5[_0x1510f0(0x1ce)]),_0x3dea5a=mcpInstallationConfigurationSchema[_0x1510f0(0x183)](_0x4e16a5[_0x1510f0(0x20f)]);if(typeof _0x4e16a5['id']!==_0x1510f0(0x116)||typeof _0x4e16a5[_0x1510f0(0x15a)]!==_0x1510f0(0x116)||typeof _0x4e16a5[_0x1510f0(0x18e)]!==_0x1510f0(0x116)||typeof _0x4e16a5[_0x1510f0(0x165)]!==_0x1510f0(0x116)||_0x4e16a5[_0x1510f0(0x1fb)]!==_0x1510f0(0xde)&&_0x4e16a5[_0x1510f0(0x1fb)]!==_0x1510f0(0x1ad)||_0x4e16a5[_0x1510f0(0xe5)]!==_0x17ba1c[_0x1510f0(0xe5)])throw new Error(_0x1510f0(0x17b));return{'id':_0x4e16a5['id'],'serverName':_0x4e16a5[_0x1510f0(0x15a)],'displayName':_0x4e16a5[_0x1510f0(0x18e)],'version':_0x4e16a5[_0x1510f0(0x165)],'origin':_0x4e16a5[_0x1510f0(0x1fb)],'transport':_0x17ba1c[_0x1510f0(0xe5)],'runtime':_0x17ba1c,'configuration':_0x3dea5a};});}function publishedTemplateSnapshot(_0x54de59){const _0x68fa44=_0x44e8b5;if(_0x54de59[_0x68fa44(0x19e)]===0x4*-0x62e+-0x1a6e+-0x1e5*-0x1b){const _0x1a7136=publishedTemplateFiles(_0x54de59[_0x68fa44(0x171)]);return{'schemaVersion':0x1,'directories':legacyPublishedTemplateDirectories(_0x1a7136),'entries':_0x1a7136};}if(_0x54de59[_0x68fa44(0x19e)]!==-0x1c28+0xe9b+0xd8f||typeof _0x54de59[_0x68fa44(0x1dd)]!==_0x68fa44(0x116)||!Array[_0x68fa44(0x10c)](_0x54de59[_0x68fa44(0x221)])||!Array[_0x68fa44(0x10c)](_0x54de59[_0x68fa44(0x25e)]))throw new Error(_0x68fa44(0x17b));validatePublishedSourceWorkspacePath(_0x54de59[_0x68fa44(0x1dd)]);const _0x1f910a=_0x54de59[_0x68fa44(0x221)][_0x68fa44(0x20e)](safePublishedTemplateRelativePath);if(new Set(_0x1f910a)[_0x68fa44(0x21a)]!==_0x1f910a[_0x68fa44(0x254)]||_0x1f910a[_0x68fa44(0x20c)](_0x68fa44(0x1aa))||_0x1f910a[_0x68fa44(0x20c)](_0x68fa44(0x11e)))throw new Error(_0x68fa44(0x17b));const _0x1b888c=_0x54de59[_0x68fa44(0x25e)][_0x68fa44(0x20e)](publishedTemplateEntry);if(new Set(_0x1b888c[_0x68fa44(0x20e)](_0x1c57b2=>_0x1c57b2[_0x68fa44(0x24d)]))[_0x68fa44(0x21a)]!==_0x1b888c[_0x68fa44(0x254)])throw new Error(_0x68fa44(0x17b));return{'schemaVersion':0x2,'sourceWorkspacePath':_0x54de59[_0x68fa44(0x1dd)],'directories':_0x1f910a,'entries':_0x1b888c};}function publishedTemplateEntry(_0x2a32fd){const _0x2ba4af=_0x44e8b5;if(!record(_0x2a32fd))throw new Error(_0x2ba4af(0x17b));if(_0x2a32fd[_0x2ba4af(0x1ff)]===_0x2ba4af(0x14d))return publishedTemplateFile(_0x2a32fd,!![]);if(_0x2a32fd[_0x2ba4af(0x1ff)]!==_0x2ba4af(0x13d)||typeof _0x2a32fd[_0x2ba4af(0x119)]!==_0x2ba4af(0x116)||_0x2a32fd[_0x2ba4af(0x119)][_0x2ba4af(0x254)]===-0x13d8+0x2199+-0xdc1||_0x2a32fd[_0x2ba4af(0x119)][_0x2ba4af(0x20c)]('\x00')||_0x2a32fd[_0x2ba4af(0x1a9)]!==_0x2ba4af(0x147)&&_0x2a32fd[_0x2ba4af(0x1a9)]!==_0x2ba4af(0xe7)||typeof _0x2a32fd[_0x2ba4af(0x1b8)]!==_0x2ba4af(0x116))throw new Error(_0x2ba4af(0x17b));const _0x488785=safePublishedTemplateRelativePath(_0x2a32fd[_0x2ba4af(0x24d)]),_0xa88812=safePublishedTemplateSize(_0x2a32fd[_0x2ba4af(0x21a)]),_0x301750=_0x2a32fd[_0x2ba4af(0x119)],_0xccf311=_0x2a32fd[_0x2ba4af(0x1a9)],_0x14784b=_0x2a32fd[_0x2ba4af(0x1b8)];if(_0xa88812!==Buffer[_0x2ba4af(0xd8)](_0x301750))throw new Error(_0x2ba4af(0x17b));if(_0xccf311===_0x2ba4af(0x147))safePublishedTemplateRelativePath(_0x14784b);else{if(!isAbsolute(_0x14784b)||!RUNTIME_LINK_ROOTS[_0x2ba4af(0xc8)](_0x3e63dc=>_0x14784b===_0x3e63dc||within(_0x3e63dc,_0x14784b)))throw new Error(_0x2ba4af(0x17b));}return{'kind':_0x2ba4af(0x13d),'relativePath':_0x488785,'size':_0xa88812,'linkTarget':_0x301750,'targetKind':_0xccf311,'resolvedTarget':_0x14784b};}function publishedTemplateFiles(_0x55f431){const _0x3a1550=_0x44e8b5;if(!Array[_0x3a1550(0x10c)](_0x55f431))throw new Error(_0x3a1550(0x17b));const _0x10b99a=new Set();return _0x55f431[_0x3a1550(0x20e)](_0x3aa7a9=>{const _0x3d6569=_0x3a1550,_0x5b766e=publishedTemplateFile(_0x3aa7a9);if(_0x10b99a[_0x3d6569(0x102)](_0x5b766e[_0x3d6569(0x24d)]))throw new Error(_0x3d6569(0x17b));return _0x10b99a[_0x3d6569(0x185)](_0x5b766e[_0x3d6569(0x24d)]),_0x5b766e;});}function _0x2016(_0x574b38,_0x352024){_0x574b38=_0x574b38-(0x24cc+-0x1540+0x3*-0x4f2);const _0x44571f=_0xed8b();let _0x264192=_0x44571f[_0x574b38];if(_0x2016['vjfYUN']===undefined){var _0x27ba87=function(_0x24ecaa){const _0x202210='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x212908='',_0x18d4c0='';for(let _0x140540=-0x9d*0x25+-0x1367+0x2a18,_0x235acf,_0x3932e1,_0x337b20=-0x892*0x2+-0x11b6+0x22da;_0x3932e1=_0x24ecaa['charAt'](_0x337b20++);~_0x3932e1&&(_0x235acf=_0x140540%(-0xb*0x2bf+0x25b1*0x1+-0x778)?_0x235acf*(0x2bc+-0x1c8a+0x5*0x536)+_0x3932e1:_0x3932e1,_0x140540++%(0x3*0x2bb+-0x1*0x1481+0xc54))?_0x212908+=String['fromCharCode'](-0x23db*0x1+0x717*0x3+0x1*0xf95&_0x235acf>>(-(0x31d+0x1eee+0x2209*-0x1)*_0x140540&-0x1*-0x1035+-0x1d5f+0xd30)):-0x3c*-0x34+0xe3e+-0x1a6e){_0x3932e1=_0x202210['indexOf'](_0x3932e1);}for(let _0x52a8ab=0x1237+-0x54*0x4a+0x611,_0x46cca5=_0x212908['length'];_0x52a8ab<_0x46cca5;_0x52a8ab++){_0x18d4c0+='%'+('00'+_0x212908['charCodeAt'](_0x52a8ab)['toString'](-0x21f5+0x2*0xf35+0x47*0xd))['slice'](-(-0x1*0x2129+0xd76*-0x2+0x3c17*0x1));}return decodeURIComponent(_0x18d4c0);};_0x2016['DoIliI']=_0x27ba87,_0x2016['jODafg']={},_0x2016['vjfYUN']=!![];}const _0x100b78=_0x44571f[-0x1c89+0x2*-0x676+0x2975];_0x2016['JeGACS']!==_0x100b78&&(_0x2016['jODafg']={},_0x2016['JeGACS']=_0x100b78);const _0x2d7690=_0x2016['jODafg'][_0x574b38];return _0x2d7690===undefined?(_0x264192=_0x2016['DoIliI'](_0x264192),_0x2016['jODafg'][_0x574b38]=_0x264192):_0x264192=_0x2d7690,_0x264192;}function publishedTemplateFile(_0x2e95b3,_0x5bf6a4=![]){const _0x4eb67e=_0x44e8b5;if(!record(_0x2e95b3)||_0x5bf6a4&&_0x2e95b3[_0x4eb67e(0x1ff)]!==_0x4eb67e(0x14d)||typeof _0x2e95b3[_0x4eb67e(0xc2)]!==_0x4eb67e(0x21d)||typeof _0x2e95b3[_0x4eb67e(0x1c2)]!==_0x4eb67e(0x116)||!/^[a-f0-9]{64}$/u[_0x4eb67e(0x107)](_0x2e95b3[_0x4eb67e(0x1c2)]))throw new Error(_0x4eb67e(0x17b));return{'kind':_0x4eb67e(0x14d),'relativePath':safePublishedTemplateRelativePath(_0x2e95b3[_0x4eb67e(0x24d)]),'size':safePublishedTemplateSize(_0x2e95b3[_0x4eb67e(0x21a)]),'executable':_0x2e95b3[_0x4eb67e(0xc2)],'sha256':_0x2e95b3[_0x4eb67e(0x1c2)]};}function safePublishedTemplateRelativePath(_0x11c0c1){const _0x466afc=_0x44e8b5;if(typeof _0x11c0c1!==_0x466afc(0x116)||_0x11c0c1[_0x466afc(0x254)]===-0xad3+-0x7a*0x4e+0x2fff||_0x11c0c1[_0x466afc(0x22f)]('/')||_0x11c0c1[_0x466afc(0x20c)]('\x5c')||_0x11c0c1[_0x466afc(0xc5)]('/')[_0x466afc(0xc8)](_0x3eeea6=>_0x3eeea6[_0x466afc(0x254)]===-0x1*-0x5e4+-0x187f*-0x1+-0xa21*0x3||_0x3eeea6==='.'||_0x3eeea6==='..'))throw new Error(_0x466afc(0x17b));return _0x11c0c1;}function safePublishedTemplateSize(_0x438b90){const _0x41691e=_0x44e8b5;if(!Number[_0x41691e(0x232)](_0x438b90)||_0x438b90<-0xc13*0x1+0xf*-0x8d+-0x89*-0x26)throw new Error(_0x41691e(0x17b));return _0x438b90;}function legacyPublishedTemplateDirectories(_0x36d205){const _0x296e0b=_0x44e8b5,_0x5b885a=new Set();for(const _0x5c4c14 of _0x36d205){const _0x49b9df=_0x5c4c14[_0x296e0b(0x24d)][_0x296e0b(0xc5)]('/');for(let _0x40c27b=-0x12a5+0xd67+0x4f*0x11;_0x40c27b<_0x49b9df[_0x296e0b(0x254)];_0x40c27b+=-0x340+-0x43*0x35+0x89*0x20)_0x5b885a[_0x296e0b(0x185)](_0x49b9df[_0x296e0b(0x20a)](-0x11c2+-0x16c8+0x1*0x288a,_0x40c27b)[_0x296e0b(0xed)]('/'));}return[..._0x5b885a][_0x296e0b(0x19c)]((_0x278874,_0x2cca67)=>_0x278874[_0x296e0b(0x23d)](_0x2cca67,_0x296e0b(0x1db)));}function publishedTemplateContentHash(_0x59adeb,_0xfce112,_0x2e6f3f){const _0x5be9a1=_0x44e8b5,_0xaa11a6=_0x2e6f3f===0x2367+0x254b+0x3*-0x183b?_0xfce112[_0x5be9a1(0x20e)](_0x1c303f=>{const _0x1ba26a=_0x5be9a1;if(_0x1c303f[_0x1ba26a(0x1ff)]!==_0x1ba26a(0x14d))throw new Error(_0x1ba26a(0x17b));return _0x1c303f[_0x1ba26a(0x24d)]+'\x00'+_0x1c303f[_0x1ba26a(0x21a)]+'\x00'+_0x1c303f[_0x1ba26a(0x1c2)];})[_0x5be9a1(0xed)]('\x0a'):[..._0x59adeb[_0x5be9a1(0x20e)](_0x98cd32=>_0x5be9a1(0x1f1)+_0x98cd32),..._0xfce112[_0x5be9a1(0x20e)](_0x1aeaa3=>_0x1aeaa3[_0x5be9a1(0x1ff)]===_0x5be9a1(0x14d)?_0x1aeaa3[_0x5be9a1(0x1ff)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x24d)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x21a)]+'\x00'+(_0x1aeaa3[_0x5be9a1(0xc2)]?0xe43+0x1424+0x77*-0x4a:-0xc90+-0x166a+0x22fa)+'\x00'+_0x1aeaa3[_0x5be9a1(0x1c2)]:_0x1aeaa3[_0x5be9a1(0x1ff)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x24d)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x21a)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x119)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x1a9)]+'\x00'+_0x1aeaa3[_0x5be9a1(0x1b8)])][_0x5be9a1(0xed)]('\x0a');return createHash(_0x5be9a1(0x1c2))[_0x5be9a1(0x160)](_0xaa11a6)[_0x5be9a1(0x14b)](_0x5be9a1(0x21f));}function validatePublishedSourceWorkspacePath(_0x334d72){const _0x305992=_0x44e8b5;if(!isAbsolute(_0x334d72)||resolve(_0x334d72)!==_0x334d72||_0x334d72==='/'||RESERVED_SANDBOX_ROOTS[_0x305992(0xc8)](_0x5ebee2=>_0x334d72===_0x5ebee2||within(_0x5ebee2,_0x334d72)||within(_0x334d72,_0x5ebee2)))throw new Error(_0x305992(0x17b));}function within(_0x3a4b6f,_0x1b9b12){const _0x4dcd62=_0x44e8b5,_0x4d8aa9=relative(_0x3a4b6f,_0x1b9b12);return _0x4d8aa9[_0x4dcd62(0x254)]>-0x14db+0x1*0xf21+0x5ba*0x1&&_0x4d8aa9!=='..'&&!_0x4d8aa9[_0x4dcd62(0x22f)]('..'+sep);}function resolveMcpServers(_0x3d9a6c,_0x154225){const _0x5558c5=_0x44e8b5,_0x25a567=_0x139b93=>{const _0x5d868e=_0x2016,_0x1f17b0={};for(const [_0x5e63f5,_0x4d11f0]of Object[_0x5d868e(0x25e)](_0x139b93??{})){const _0xda9de4=_0x154225[_0x4d11f0[_0x5d868e(0x16c)]];if(_0xda9de4===undefined)throw new Error(_0x5d868e(0x178));_0x1f17b0[_0x5e63f5]=_0xda9de4;}return _0x1f17b0;};return _0x3d9a6c[_0x5558c5(0x1d8)][_0x5558c5(0x1b7)](_0x11bf46=>{const _0x545a2f=_0x5558c5;if(_0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0xe5)]===_0x545a2f(0x12a)){if(_0x3d9a6c[_0x545a2f(0xf3)][_0x545a2f(0x1a3)]!==_0x545a2f(0x108))return[];return[{'name':_0x11bf46[_0x545a2f(0x15a)],'lifecycle':_0x545a2f(0x1bb),'transport':_0x545a2f(0x12a),'url':_0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0xc3)],'headers':{..._0x25a567(_0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0xbb)]),..._0x25a567(_0x11bf46[_0x545a2f(0x20f)][_0x545a2f(0xbb)])}}];}return[{'name':_0x11bf46[_0x545a2f(0x15a)],'lifecycle':_0x545a2f(0x1bb),'transport':_0x545a2f(0x1dc),'command':_0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0xce)],'args':[..._0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0x223)],..._0x11bf46[_0x545a2f(0x20f)][_0x545a2f(0xf0)]??[]],'environment':{..._0x25a567(_0x11bf46[_0x545a2f(0x1ce)][_0x545a2f(0xeb)]),..._0x25a567(_0x11bf46[_0x545a2f(0x20f)][_0x545a2f(0xeb)])}}];});}function hostedConversationSummary(_0x14aac9,_0x544428){const _0x554bee=_0x44e8b5;return hostedConversationSummarySchema[_0x554bee(0x183)]({'id':_0x14aac9['id'],'nodeId':_0x14aac9[_0x554bee(0x17c)],'sessionId':_0x14aac9[_0x554bee(0x1d1)],'templateId':_0x14aac9[_0x554bee(0x1cd)],'templateName':_0x14aac9[_0x554bee(0xd1)],'activeVersionId':_0x14aac9[_0x554bee(0x23a)],'title':_0x14aac9[_0x554bee(0x163)],'pinnedAt':_0x14aac9[_0x554bee(0x229)],'status':_0x14aac9[_0x554bee(0x152)],'modelId':_0x14aac9[_0x554bee(0x111)],'createdAt':_0x14aac9[_0x554bee(0x129)],'updatedAt':_0x14aac9[_0x554bee(0x167)],'lastActivityAt':_0x14aac9[_0x554bee(0x137)],..._0x544428===undefined?{}:{'activity':_0x544428}});}function templateSummary(_0x29f9d4,_0x3ecd3d){const _0x1034dc=_0x44e8b5;return conversationTemplateSummarySchema[_0x1034dc(0x183)]({'id':_0x29f9d4[_0x1034dc(0x1cd)],'nodeId':_0x29f9d4[_0x1034dc(0x17c)],'name':_0x29f9d4[_0x1034dc(0xd1)],'description':_0x3ecd3d[_0x1034dc(0x110)],'status':_0x29f9d4[_0x1034dc(0x1c8)]?_0x1034dc(0x117):_0x1034dc(0x15e),'currentVersionId':_0x29f9d4[_0x1034dc(0x23a)],'available':!_0x29f9d4[_0x1034dc(0x1c8)],'createdAt':_0x29f9d4[_0x1034dc(0x129)],'updatedAt':_0x3ecd3d[_0x1034dc(0x167)]});}function modelSummary(_0x5c2e91,_0x3740e7){const _0x254767=_0x44e8b5;return{'id':_0x5c2e91['id'],'name':_0x5c2e91[_0x254767(0x26c)],'protocol':_0x5c2e91[_0x254767(0x135)],'baseUrl':_0x5c2e91[_0x254767(0x130)],'modelId':_0x5c2e91[_0x254767(0x111)],'contextWindowTokens':_0x5c2e91[_0x254767(0x1bc)],'maxOutputTokens':_0x5c2e91[_0x254767(0x139)],'inputCapabilities':_0x5c2e91[_0x254767(0xf5)],'outputCapabilities':_0x5c2e91[_0x254767(0x161)],'reasoningEfforts':_0x5c2e91[_0x254767(0x23e)],'hostedWebSearch':_0x5c2e91[_0x254767(0x113)],..._0x5c2e91[_0x254767(0x1e2)]===undefined?{}:{'responsesTransport':_0x5c2e91[_0x254767(0x1e2)]},'responsesPreviousResponseId':_0x5c2e91[_0x254767(0xf8)],'enabled':_0x5c2e91[_0x254767(0x180)],'sortOrder':_0x3740e7,'apiKeyConfigured':!![]};}function systemInstruction(_0x527aec,_0x119ec5){const _0x101516=_0x44e8b5,_0x3a4ae4=_0x527aec[_0x101516(0xf3)],_0x497a63=_0x3a4ae4[_0x101516(0x1a3)]===_0x101516(0x195)?_0x101516(0xc0):_0x101516(0x1bd);return[_0x101516(0xda),_0x101516(0x1a0),_0x101516(0x258),..._0x119ec5===undefined?[]:[_0x101516(0x1f9)+_0x119ec5+_0x101516(0x21c),_0x101516(0x11a)+_0x119ec5+_0x101516(0x121)+_0x119ec5+_0x101516(0x1f2)],..._0x527aec[_0x101516(0x1dd)]===undefined?[]:[_0x101516(0x24f)+_0x527aec[_0x101516(0x1dd)]+_0x101516(0x16a)+join(_0x527aec[_0x101516(0x1dd)],_0x101516(0x1aa))+_0x101516(0x156)+join(_0x527aec[_0x101516(0x1dd)],_0x101516(0x11e))+_0x101516(0xee)],_0x101516(0x18f),_0x497a63][_0x101516(0xed)]('\x0a');}function attachmentPrompt(_0x16edee,_0x260ff3){const _0x54ad6c=_0x44e8b5;if(_0x260ff3[_0x54ad6c(0x254)]===0x245+0x22d*0x3+-0x8cc)return _0x16edee;const _0x2badfb=_0x260ff3[_0x54ad6c(0x20e)](_0x27ffbc=>_0x54ad6c(0x257)+_0x27ffbc[_0x54ad6c(0x24d)])[_0x54ad6c(0xed)]('\x0a');return''+_0x16edee+(_0x16edee[_0x54ad6c(0x253)]()[_0x54ad6c(0x254)]===-0x1bd5+-0x1bb0+0x3785?'':'\x0a\x0a')+_0x54ad6c(0x1c4)+_0x2badfb;}function automaticHostedConversationTitle(_0x4f3b1a){const _0x3bdd7c=_0x44e8b5;if(_0x4f3b1a===undefined)return undefined;const _0xb5ba49=sessionTitleFromFirstMessage(_0x4f3b1a);if(_0xb5ba49[_0x3bdd7c(0x254)]===0x1d*0x143+-0x2eb+0x10d6*-0x2||/^(?:new|untitled) session(?:\s*[-–—:]\s*\d{4}-\d{2}-\d{2}.*)?$/iu[_0x3bdd7c(0x107)](_0xb5ba49))return undefined;return _0xb5ba49;}function runFromMessage(_0x582bbf){const _0x4e38a1=_0x44e8b5;return{'id':_0x582bbf[_0x4e38a1(0x123)],'status':_0x582bbf[_0x4e38a1(0x152)],'startedAt':_0x582bbf[_0x4e38a1(0x129)],'completedAt':_0x582bbf[_0x4e38a1(0x152)]===_0x4e38a1(0x138)?null:_0x582bbf[_0x4e38a1(0x167)]};}function runInterruptionKey(_0x400f83,_0x496b26){return _0x400f83+'\x00'+_0x496b26;}function uploadProjection(_0x731d5f){const _0x26d2eb=_0x44e8b5;return{'uploadId':_0x731d5f[_0x26d2eb(0x1a2)],'conversationId':_0x731d5f[_0x26d2eb(0x153)],'name':_0x731d5f[_0x26d2eb(0x26c)],'mimeType':_0x731d5f[_0x26d2eb(0x1e3)],'receivedBytes':_0x731d5f[_0x26d2eb(0xba)],'size':_0x731d5f[_0x26d2eb(0x21a)],'status':_0x731d5f[_0x26d2eb(0x152)],..._0x731d5f[_0x26d2eb(0x198)]===undefined?{}:{'file':_0x731d5f[_0x26d2eb(0x198)]}};}async function assertRegularFile(_0x805337,_0x2fd8f9){const _0x5a7890=_0x44e8b5,_0x2bc6c2=await lstat(_0x805337)[_0x5a7890(0x196)](()=>{const _0x417962=_0x5a7890;throw new Error(_0x417962(0x202));});if(!_0x2bc6c2[_0x5a7890(0x184)]()||_0x2bc6c2[_0x5a7890(0x125)]()||_0x2bc6c2[_0x5a7890(0x12d)]!==0xc20+-0xb95+-0x8a||_0x2bc6c2[_0x5a7890(0x21a)]!==_0x2fd8f9)throw new Error(_0x5a7890(0x202));}async function assertUploadTemporaryFile(_0x157b04,_0x258911){const _0x1c85ca=_0x44e8b5,_0x3ec79f=await lstat(_0x157b04)[_0x1c85ca(0x196)](()=>{const _0x422ef0=_0x1c85ca;throw new Error(_0x422ef0(0x26d));});if(!_0x3ec79f[_0x1c85ca(0x184)]()||_0x3ec79f[_0x1c85ca(0x125)]()||_0x3ec79f[_0x1c85ca(0x12d)]!==-0x6*0x3d6+0xb2*0x2+-0x1*-0x15a1||_0x3ec79f[_0x1c85ca(0x21a)]!==_0x258911)throw new Error(_0x1c85ca(0x26d));}function record(_0x4bfd7a){const _0x34e907=_0x44e8b5;return typeof _0x4bfd7a===_0x34e907(0x236)&&_0x4bfd7a!==null&&!Array[_0x34e907(0x10c)](_0x4bfd7a);}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@myagentroam/node",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.41",
|
|
4
4
|
"description": "MyAgentRoam Node runtime CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
"node-pty": "1.1.0",
|
|
26
26
|
"ws": "^8.21.3",
|
|
27
27
|
"zod": "4.4.3",
|
|
28
|
-
"@myagentroam/agent": "^0.9.
|
|
29
|
-
"@myagentroam/protocol": "^0.9.
|
|
28
|
+
"@myagentroam/agent": "^0.9.41",
|
|
29
|
+
"@myagentroam/protocol": "^0.9.41"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@types/ws": "^8.18.1"
|