@tangle-network/sandbox 0.9.2 → 0.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/index.js +1026 -1
- package/dist/auth/index.js +273 -1
- package/dist/client-BBZ7YLmq.js +2193 -1
- package/dist/collaboration/index.js +2 -1
- package/dist/collaboration-BxlfZ2Uh.js +201 -1
- package/dist/core.js +4 -1
- package/dist/errors-DZsfJUuc.js +262 -1
- package/dist/index.js +1180 -1
- package/dist/intelligence/index.js +225 -1
- package/dist/openai/index.js +1760 -1
- package/dist/sandbox-joKtQ5y3.js +4457 -1
- package/dist/session-gateway/index.js +667 -1
- package/dist/tangle/index.js +2 -1
- package/dist/tangle-DM0o66lW.js +831 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1 +1,1180 @@
|
|
|
1
|
-
const a0_0x5244d4=a0_0x43aa;function a0_0x3d79(){const _0x470ff1=['\x74\x75\x48\x5a\x71\x33\x79','\x42\x77\x66\x57','\x79\x32\x4c\x30\x79\x78\x72\x50\x42\x32\x35\x5a','\x76\x65\x76\x66\x69\x67\x66\x30\x44\x67\x76\x5a\x44\x67\x66\x30\x41\x77\x39\x55\x69\x67\x48\x4c\x79\x78\x6a\x30\x79\x4d\x76\x48\x44\x63\x62\x50\x43\x59\x62\x5a\x44\x67\x39\x57\x43\x67\x76\x4b','\x44\x67\x76\x5a\x44\x61','\x79\x4d\x39\x4b\x45\x76\x39\x30\x7a\x77\x31\x57\x42\x67\x66\x30\x7a\x71','\x43\x33\x72\x4b\x42\x33\x76\x30','\x79\x4d\x66\x5a\x7a\x77\x58\x50\x42\x4d\x75','\x7a\x4e\x6a\x56\x42\x71','\x7a\x78\x48\x50\x44\x65\x6e\x56\x7a\x67\x75','\x72\x4d\x66\x50\x42\x67\x76\x4b\x69\x68\x72\x56\x69\x67\x6a\x31\x41\x77\x58\x4b\x69\x67\x4c\x54\x79\x77\x44\x4c\x6f\x49\x61','\x75\x30\x58\x70\x43\x75\x43','\x79\x75\x7a\x6f\x76\x75\x79','\x79\x32\x58\x48\x44\x77\x72\x4c\x6c\x77\x6e\x56\x7a\x67\x75','\x43\x4d\x76\x4a\x42\x32\x35\x4a\x41\x77\x58\x4c\x76\x32\x39\x59\x41\x33\x6e\x57\x79\x77\x6e\x4c','\x69\x63\x61\x47\x69\x67\x66\x4b\x7a\x63\x31\x48\x43\x68\x71\x54\x43\x4d\x76\x57\x42\x33\x6e\x50\x44\x67\x39\x59\x45\x73\x61\x54\x45\x73\x62\x57\x43\x67\x65\x36\x7a\x67\x76\x48\x7a\x68\x6e\x55\x79\x77\x54\x4c\x43\x59\x39\x57\x43\x67\x65\x47\x6a\x49\x79\x47\x78\x61','\x71\x4c\x76\x69\x75\x75\x65','\x6d\x74\x79\x57\x6d\x74\x4b\x31\x6f\x67\x6e\x76\x45\x67\x4c\x4a\x7a\x47','\x43\x32\x35\x48\x43\x68\x6e\x4f\x42\x33\x72\x6a\x7a\x61','\x43\x67\x58\x48\x71\x31\x65','\x42\x32\x35\x74\x44\x77\x6e\x4a\x7a\x78\x6e\x5a','\x79\x77\x72\x4b\x75\x67\x66\x4a\x41\x32\x66\x4e\x7a\x78\x6d','\x74\x31\x44\x4d\x72\x30\x79','\x71\x76\x6a\x68\x69\x61','\x43\x68\x76\x5a\x41\x61','\x6c\x33\x79\x58\x6c\x33\x6e\x4c\x79\x78\x6a\x4a\x41\x63\x39\x4a\x42\x32\x35\x4d\x41\x77\x43','\x69\x59\x62\x6a\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x66\x62\x35\x44\x67\x48\x56\x42\x49\x61','\x7a\x67\x76\x53\x7a\x78\x72\x4c','\x43\x67\x58\x48\x44\x67\x7a\x56\x43\x4d\x30','\x74\x4d\x58\x68\x75\x4b\x30','\x76\x30\x76\x6d\x44\x77\x38','\x71\x4b\x6a\x6a\x76\x31\x6d','\x73\x77\x35\x32\x79\x77\x58\x50\x7a\x63\x62\x75\x79\x77\x35\x4e\x42\x67\x75\x47\x75\x4d\x39\x31\x44\x67\x76\x59\x69\x68\x6e\x4c\x79\x78\x6a\x4a\x41\x63\x62\x4a\x42\x32\x35\x4d\x41\x77\x43\x47\x43\x4d\x76\x5a\x43\x67\x39\x55\x43\x32\x75','\x42\x77\x66\x55\x41\x77\x7a\x4c\x43\x33\x71','\x42\x78\x72\x67\x75\x77\x65','\x79\x32\x39\x55\x44\x67\x76\x55\x44\x63\x31\x30\x45\x78\x62\x4c','\x71\x4d\x76\x48\x43\x4d\x76\x59\x69\x61','\x73\x4c\x48\x50\x41\x68\x61','\x69\x63\x61\x47\x69\x67\x31\x50\x79\x33\x6a\x56\x42\x77\x66\x54\x79\x4d\x65\x47\x43\x32\x48\x4c\x42\x67\x57\x47\x41\x77\x35\x50\x44\x63\x61\x54\x43\x59\x62\x49\x79\x78\x6e\x4f\x69\x63\x31\x57\x69\x63\x39\x56\x43\x68\x71\x56\x79\x32\x39\x55\x7a\x67\x65','\x43\x33\x76\x49\x44\x67\x58\x4c','\x44\x67\x66\x55\x7a\x32\x58\x4c\x6c\x78\x6a\x56\x44\x78\x72\x4c\x43\x49\x31\x33\x7a\x77\x69\x54\x43\x32\x76\x48\x43\x4d\x6e\x4f','\x41\x68\x72\x30\x43\x68\x6d\x36\x6c\x59\x39\x59\x42\x33\x76\x30\x7a\x78\x69\x55\x44\x67\x66\x55\x7a\x32\x58\x4c\x6c\x4e\x72\x56\x42\x32\x58\x5a','\x44\x67\x76\x5a\x44\x68\x6e\x71\x79\x78\x6e\x5a\x7a\x77\x71','\x41\x32\x35\x4f\x76\x30\x38','\x43\x32\x76\x4a\x43\x4d\x76\x30\x43\x57','\x7a\x78\x7a\x48\x42\x63\x30','\x69\x63\x79\x4d\x69\x66\x57','\x72\x75\x35\x77\x69\x61','\x44\x67\x76\x34\x44\x63\x39\x4c\x44\x4d\x76\x55\x44\x63\x31\x5a\x44\x68\x6a\x4c\x79\x77\x30','\x79\x32\x39\x5a\x44\x66\x76\x5a\x7a\x61','\x72\x75\x7a\x4a\x44\x65\x4f','\x45\x66\x72\x6f\x44\x75\x79','\x43\x32\x58\x69\x42\x4c\x4b','\x75\x75\x66\x53\x71\x4c\x47','\x43\x32\x58\x50\x79\x32\x75','\x7a\x4d\x58\x4c\x7a\x78\x72\x6a\x7a\x61','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x66\x6a\x4c\x43\x33\x76\x53\x44\x61','\x72\x4c\x76\x6b\x79\x4c\x6d','\x69\x64\x65\x47\x6a\x49\x79\x47\x78\x61','\x69\x59\x62\x64\x44\x78\x6e\x30\x42\x32\x30\x47\x79\x32\x39\x54\x42\x77\x66\x55\x7a\x68\x6d','\x79\x4d\x48\x6d\x75\x75\x65','\x41\x77\x35\x30\x7a\x77\x58\x53\x41\x77\x44\x4c\x42\x4d\x6e\x4c','\x44\x77\x6a\x31\x42\x4e\x72\x31','\x41\x4b\x58\x68\x7a\x68\x61','\x6e\x64\x43\x35\x6e\x74\x6d\x59\x6d\x65\x44\x62\x41\x30\x7a\x6c\x73\x47','\x44\x67\x4c\x54\x7a\x77\x39\x31\x44\x61','\x7a\x67\x4c\x4e\x7a\x78\x6e\x30','\x79\x4e\x76\x50\x42\x67\x72\x62\x43\x4d\x44\x5a','\x7a\x32\x76\x55\x7a\x78\x6a\x48\x44\x67\x76\x65\x42\x32\x6e\x52\x7a\x78\x6a\x4d\x41\x77\x58\x4c','\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a\x69\x67\x6e\x59\x7a\x77\x66\x30\x7a\x73\x62\x59\x7a\x78\x66\x31\x41\x78\x6a\x4c\x43\x59\x62\x48\x69\x67\x48\x56\x43\x33\x71\x54\x42\x33\x44\x55\x7a\x77\x71\x47\x43\x67\x39\x53\x41\x77\x6e\x35','\x7a\x78\x7a\x48\x42\x66\x38','\x72\x4d\x66\x50\x42\x67\x76\x4b\x69\x68\x72\x56\x69\x67\x58\x56\x79\x77\x71\x47\x76\x67\x66\x55\x7a\x32\x58\x4c\x69\x66\x6a\x56\x44\x78\x72\x4c\x43\x49\x62\x5a\x7a\x77\x66\x59\x79\x32\x47\x47\x79\x32\x39\x55\x7a\x4d\x4c\x4e\x6f\x49\x61','\x41\x78\x4c\x70\x77\x4c\x4f','\x42\x67\x66\x49\x7a\x77\x58\x5a','\x6d\x74\x75\x35\x6e\x64\x75\x31\x6d\x64\x72\x52\x42\x76\x50\x79\x44\x30\x34','\x43\x32\x76\x5a\x43\x32\x4c\x56\x42\x47','\x43\x32\x76\x48\x43\x4d\x6e\x4f','\x79\x78\x76\x30\x41\x66\x72\x56\x41\x32\x76\x55','\x41\x68\x48\x4b\x71\x32\x53','\x6c\x78\x7a\x4c\x42\x4e\x79\x47\x43\x68\x4c\x30\x41\x67\x39\x55','\x7a\x77\x35\x30\x43\x4d\x4c\x4c\x43\x57','\x73\x77\x31\x48\x7a\x32\x75\x47\x79\x4e\x76\x50\x42\x67\x71\x47\x44\x67\x4c\x54\x7a\x77\x71\x47\x42\x33\x76\x30\x69\x67\x66\x4d\x44\x67\x76\x59\x69\x61','\x44\x67\x39\x74\x43\x67\x76\x4a','\x79\x4d\x76\x55\x79\x32\x48\x54\x79\x78\x6a\x52','\x7a\x32\x76\x30\x75\x4d\x66\x55\x7a\x67\x39\x54\x76\x4d\x66\x53\x44\x77\x76\x5a','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x65\x6a\x48\x79\x32\x54\x4c\x42\x4d\x71','\x41\x77\x35\x57\x44\x78\x72\x75\x42\x32\x54\x4c\x42\x4e\x6d','\x69\x63\x61\x47\x69\x67\x31\x32\x69\x67\x6a\x50\x42\x49\x39\x54\x41\x77\x6e\x59\x42\x32\x31\x48\x42\x77\x6a\x48\x69\x63\x39\x31\x43\x33\x69\x56\x42\x67\x39\x4a\x79\x77\x57\x56\x79\x4d\x4c\x55\x6c\x59\x61\x4d\x6a\x49\x62\x43','\x44\x68\x6a\x48\x42\x4e\x6e\x57\x42\x33\x6a\x30','\x44\x67\x39\x56\x42\x65\x6e\x48\x42\x67\x58\x5a','\x79\x32\x39\x55\x44\x67\x4c\x55\x44\x77\x76\x70\x42\x4b\x7a\x48\x41\x77\x58\x31\x43\x4d\x75','\x76\x32\x50\x71\x74\x67\x6d','\x75\x4e\x48\x52\x71\x32\x6d','\x79\x78\x62\x57\x42\x67\x4c\x4a\x79\x78\x72\x50\x42\x32\x34\x56\x41\x4e\x6e\x56\x42\x47','\x41\x4b\x7a\x30\x44\x31\x47','\x79\x32\x58\x50\x7a\x77\x35\x30\x71\x32\x39\x55\x7a\x4d\x4c\x4e','\x75\x4c\x76\x6f\x69\x67\x66\x57\x44\x63\x31\x4e\x7a\x78\x71\x47\x44\x78\x62\x4b\x79\x78\x72\x4c\x69\x63\x79\x4d\x69\x66\x57','\x41\x32\x31\x35\x73\x65\x4f','\x79\x78\x62\x50\x78\x32\x54\x4c\x45\x76\x39\x4c\x42\x4e\x79','\x44\x78\x62\x4b\x79\x78\x72\x4c','\x43\x68\x4c\x30\x41\x67\x39\x55','\x44\x32\x76\x49\x75\x32\x76\x48\x43\x4d\x6e\x4f','\x74\x77\x4c\x5a\x43\x32\x4c\x55\x7a\x59\x62\x59\x42\x33\x76\x30\x7a\x78\x69\x47\x7a\x78\x7a\x48\x42\x63\x62\x30\x79\x78\x6e\x52\x69\x67\x66\x30\x69\x67\x4c\x55\x7a\x67\x76\x34\x69\x61','\x73\x77\x31\x48\x7a\x32\x75\x47\x79\x4e\x76\x50\x42\x67\x71\x47\x7a\x4d\x66\x50\x42\x67\x76\x4b','\x43\x68\x6a\x56\x44\x4d\x4c\x4b\x7a\x78\x69','\x43\x4b\x6e\x70\x72\x4b\x57','\x6d\x5a\x75\x34\x6e\x4a\x75\x5a\x6d\x67\x4c\x6b\x73\x78\x76\x69\x76\x61','\x79\x32\x66\x57\x79\x77\x6a\x50\x42\x67\x4c\x30\x41\x77\x76\x5a','\x41\x4d\x39\x58\x74\x78\x61','\x77\x66\x6a\x4b\x7a\x67\x79','\x72\x76\x62\x30\x43\x4e\x71','\x42\x4d\x39\x33','\x45\x75\x7a\x35\x41\x77\x71','\x79\x32\x39\x55\x79\x33\x76\x59\x43\x4d\x76\x55\x79\x33\x4b','\x41\x4d\x50\x54\x71\x76\x4f','\x7a\x78\x6a\x59\x42\x33\x69','\x7a\x4e\x76\x55\x79\x33\x72\x50\x42\x32\x34','\x75\x65\x39\x74\x76\x61','\x79\x78\x62\x50\x73\x32\x76\x35\x72\x77\x35\x32','\x7a\x32\x76\x30','\x42\x77\x6e\x7a\x75\x4c\x69','\x69\x63\x61\x47\x69\x67\x66\x57\x44\x63\x31\x4e\x7a\x78\x71\x47\x79\x32\x58\x4c\x79\x77\x34\x47\x6a\x49\x79\x47\x43\x4d\x30\x47\x6c\x78\x6a\x4d\x69\x63\x39\x32\x79\x78\x69\x56\x42\x67\x4c\x49\x6c\x32\x66\x57\x44\x63\x39\x53\x41\x78\x6e\x30\x43\x59\x38\x51','\x43\x67\x39\x53\x41\x77\x6e\x35','\x79\x77\x6e\x30\x41\x77\x39\x55','\x44\x78\x6e\x48\x7a\x32\x75','\x76\x30\x39\x30\x41\x77\x65','\x41\x4e\x6e\x56\x42\x47','\x75\x76\x4c\x52\x74\x4b\x65','\x6e\x5a\x65\x35\x6d\x76\x62\x5a\x42\x30\x39\x5a\x44\x61','\x43\x77\x7a\x7a\x42\x4d\x71','\x79\x4d\x39\x4b\x45\x71','\x72\x4b\x72\x79\x77\x4e\x4f','\x72\x68\x62\x32\x73\x4b\x43','\x45\x4d\x44\x74\x41\x30\x65','\x79\x4e\x7a\x77\x45\x65\x4b','\x42\x67\x76\x55\x7a\x33\x72\x4f','\x43\x68\x6a\x56\x44\x4d\x4c\x4b\x7a\x78\x6a\x70\x43\x68\x72\x50\x42\x32\x35\x5a','\x42\x33\x62\x4c\x42\x4d\x6e\x56\x7a\x67\x75','\x76\x32\x7a\x6c\x44\x67\x4f','\x42\x77\x66\x4a\x41\x67\x4c\x55\x7a\x75\x4c\x4b','\x7a\x76\x62\x4c\x41\x78\x79','\x7a\x32\x4c\x30\x71\x4e\x6a\x48\x42\x4d\x6e\x4f','\x42\x77\x76\x5a\x43\x32\x66\x4e\x7a\x71','\x79\x4e\x72\x4e\x79\x4d\x43','\x43\x32\x76\x48\x43\x4d\x6e\x4f\x75\x4d\x76\x58\x44\x77\x76\x5a\x44\x68\x6d','\x42\x77\x39\x4b\x7a\x77\x57','\x42\x77\x66\x30\x43\x4d\x4c\x34','\x43\x32\x44\x4a\x45\x77\x57','\x43\x68\x6a\x56\x7a\x4d\x4c\x53\x7a\x75\x4c\x4b','\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a\x69\x68\x6a\x4c\x43\x78\x76\x50\x43\x4d\x76\x5a\x69\x67\x31\x48\x79\x32\x48\x50\x42\x4d\x75','\x75\x4d\x44\x57\x44\x67\x57','\x43\x68\x4c\x30\x41\x67\x39\x55\x76\x4d\x76\x59\x43\x32\x4c\x56\x42\x47','\x44\x78\x6a\x53\x78\x32\x6e\x50\x44\x67\x66\x30\x41\x77\x39\x55','\x42\x32\x6a\x51\x7a\x77\x6e\x30','\x76\x67\x76\x59\x42\x77\x4c\x55\x79\x77\x57\x47\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x59\x7a\x78\x6e\x31\x42\x68\x71\x47\x42\x32\x6a\x5a\x7a\x78\x6a\x32\x7a\x77\x71','\x43\x4d\x76\x5a\x43\x67\x39\x55\x43\x32\x75','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x66\x76\x59\x42\x61','\x43\x32\x76\x5a\x43\x32\x4c\x56\x42\x4b\x4c\x4b\x75\x68\x6a\x4c\x7a\x4d\x4c\x34','\x41\x67\x76\x34','\x76\x76\x6e\x66\x75\x49\x61','\x79\x33\x6a\x4c\x79\x78\x72\x4c','\x79\x78\x72\x30\x7a\x78\x6e\x30\x79\x78\x72\x50\x42\x32\x35\x6f\x42\x32\x35\x4a\x7a\x71','\x43\x33\x72\x48\x44\x68\x76\x5a','\x79\x77\x35\x48\x79\x32\x39\x55\x7a\x67\x65','\x7a\x4b\x54\x53\x75\x4b\x4b','\x7a\x77\x35\x32\x76\x4d\x66\x59\x43\x57','\x73\x31\x50\x66\x75\x4b\x4f','\x79\x4e\x76\x50\x42\x67\x72\x74\x79\x77\x35\x4b\x79\x4d\x39\x34\x74\x77\x6e\x57\x71\x32\x39\x55\x7a\x4d\x4c\x4e\x6f\x49\x62\x5a\x79\x77\x35\x4b\x79\x4d\x39\x34\x76\x78\x6a\x53\x69\x67\x4c\x5a\x69\x68\x6a\x4c\x43\x78\x76\x50\x43\x4d\x76\x4b','\x79\x4e\x76\x50\x42\x67\x71','\x79\x32\x4c\x30\x79\x78\x72\x50\x42\x32\x35\x64\x42\x33\x76\x55\x44\x61','\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a\x69\x68\x6a\x4c\x43\x78\x76\x50\x43\x4d\x76\x5a\x69\x67\x39\x57\x44\x67\x4c\x56\x42\x4e\x6d','\x42\x33\x62\x30\x41\x77\x39\x55\x43\x57','\x79\x33\x6a\x4c\x79\x78\x72\x4c\x76\x32\x39\x59\x41\x33\x6e\x57\x79\x77\x6e\x4c\x75\x32\x35\x48\x43\x68\x6e\x4f\x42\x33\x71','\x41\x77\x35\x30\x7a\x78\x6a\x32\x79\x77\x58\x6e\x43\x57','\x6c\x49\x34\x55','\x43\x32\x76\x59\x44\x4d\x76\x59\x74\x4d\x66\x54\x7a\x71','\x7a\x32\x76\x30\x76\x67\x76\x4c\x71\x78\x72\x30\x7a\x78\x6e\x30\x79\x78\x72\x50\x42\x32\x34','\x43\x4c\x48\x50\x75\x67\x47','\x42\x77\x6a\x75\x71\x33\x69','\x76\x30\x39\x73\x73\x30\x72\x6a\x75\x49\x61','\x79\x77\x72\x68\x42\x4c\x6d','\x43\x32\x4c\x4e\x42\x4d\x66\x53','\x43\x4d\x76\x5a\x44\x77\x58\x30','\x73\x75\x48\x59\x71\x4b\x4b','\x43\x77\x35\x6a\x71\x4d\x75','\x43\x33\x72\x4b\x7a\x78\x6a\x59','\x79\x77\x35\x55\x42\x33\x72\x48\x44\x67\x4c\x56\x42\x4e\x6d','\x43\x33\x62\x4c\x79\x57','\x44\x32\x39\x59\x41\x32\x72\x50\x43\x47','\x42\x32\x35\x67\x79\x77\x4c\x53\x44\x78\x6a\x4c','\x75\x4c\x76\x6f\x69\x68\x62\x50\x43\x63\x62\x50\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x63\x30\x54\x42\x4d\x38\x54\x79\x32\x66\x4a\x41\x67\x75\x54\x7a\x67\x4c\x59\x69\x61','\x43\x32\x76\x48\x43\x4d\x6e\x4f\x75\x68\x6a\x56\x44\x4d\x4c\x4b\x7a\x78\x69','\x79\x77\x72\x4b\x75\x67\x66\x4a\x41\x32\x66\x4e\x7a\x78\x6e\x67\x43\x4d\x39\x54\x72\x4d\x4c\x53\x7a\x71','\x43\x67\x58\x48\x44\x67\x7a\x56\x43\x4d\x31\x76\x43\x4d\x57','\x75\x4d\x39\x31\x44\x67\x76\x59\x69\x67\x76\x32\x79\x77\x57\x47\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x4b\x42\x32\x76\x5a\x69\x67\x35\x56\x44\x63\x62\x5a\x44\x78\x62\x57\x42\x33\x6a\x30\x69\x67\x76\x34\x7a\x77\x6d','\x43\x30\x31\x51\x79\x77\x43','\x7a\x77\x35\x32','\x7a\x78\x44\x49\x42\x68\x79','\x79\x78\x62\x30\x75\x67\x66\x4a\x41\x32\x66\x4e\x7a\x78\x6d','\x7a\x4d\x58\x4c\x7a\x78\x72\x5a','\x79\x33\x6a\x35\x43\x68\x72\x56','\x79\x77\x72\x4b\x71\x32\x39\x54\x42\x77\x66\x55\x7a\x68\x6d','\x79\x32\x39\x55\x7a\x4d\x4c\x4e','\x44\x67\x76\x34\x44\x61','\x41\x77\x35\x4a\x42\x68\x76\x4b\x7a\x78\x6d','\x43\x4d\x76\x5a\x44\x67\x39\x59\x7a\x76\x44\x56\x43\x4d\x54\x5a\x43\x67\x66\x4a\x7a\x76\x6e\x55\x79\x78\x62\x5a\x41\x67\x39\x30','\x76\x65\x50\x54\x41\x4d\x47','\x79\x77\x58\x53\x42\x33\x43','\x76\x65\x76\x66\x69\x67\x66\x30\x44\x67\x76\x5a\x44\x67\x66\x30\x41\x77\x39\x55\x69\x68\x6a\x4c\x43\x33\x62\x56\x42\x4e\x6e\x4c\x69\x67\x35\x56\x42\x4d\x6e\x4c\x69\x67\x72\x50\x7a\x63\x62\x55\x42\x33\x71\x47\x42\x77\x66\x30\x79\x32\x47\x47\x79\x32\x48\x48\x42\x67\x58\x4c\x42\x4d\x44\x4c','\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x30\x7a\x78\x6e\x30\x69\x67\x6e\x56\x42\x77\x31\x48\x42\x4d\x71\x47\x7a\x4d\x66\x50\x42\x67\x76\x4b','\x7a\x67\x76\x5a\x44\x68\x6a\x56\x45\x71','\x43\x32\x76\x48\x43\x4d\x6e\x4f\x75\x67\x66\x59\x79\x77\x31\x5a','\x79\x31\x66\x62\x73\x66\x65','\x72\x4c\x6a\x70\x74\x73\x61','\x6e\x74\x75\x30\x6f\x74\x79\x31\x6e\x4e\x50\x75\x44\x66\x72\x6a\x74\x47','\x79\x32\x39\x55\x7a\x4d\x4c\x4b\x7a\x77\x35\x30\x41\x77\x66\x53','\x43\x33\x76\x4a\x79\x32\x76\x5a\x43\x57','\x7a\x77\x35\x4b\x43\x67\x39\x50\x42\x4e\x71','\x43\x32\x76\x5a\x43\x32\x4c\x56\x42\x4b\x4c\x4b','\x78\x4c\x54\x62\x6c\x76\x50\x48\x6c\x78\x4f\x57\x6c\x74\x4c\x44\x77\x30\x65\x54\x77\x4d\x65\x54\x45\x4a\x61\x54\x6f\x73\x35\x46\x6c\x76\x31\x37\x6d\x63\x57\x32\x6d\x33\x30\x4b','\x41\x67\x7a\x63\x76\x75\x43','\x69\x59\x62\x6a\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x67\x31\x50\x79\x33\x6a\x56\x42\x77\x66\x54\x79\x4d\x65\x47\x79\x77\x35\x4b\x69\x67\x6e\x56\x42\x4d\x72\x48\x69\x68\x62\x48\x79\x32\x54\x48\x7a\x32\x76\x5a','\x6c\x77\x72\x50\x43\x33\x72\x31\x44\x67\x4c\x53\x43\x59\x61\x4d\x6a\x49\x62\x43','\x73\x76\x4c\x59\x72\x4e\x61','\x75\x4c\x76\x6f\x69\x61','\x7a\x77\x35\x4a\x42\x32\x72\x4c','\x75\x32\x76\x4a\x44\x78\x6a\x4c\x69\x68\x6a\x48\x42\x4d\x72\x56\x42\x73\x62\x55\x42\x32\x35\x4a\x7a\x73\x62\x4e\x7a\x77\x35\x4c\x43\x4d\x66\x30\x41\x77\x39\x55\x69\x67\x4c\x5a\x69\x67\x35\x56\x44\x63\x62\x48\x44\x4d\x66\x50\x42\x67\x66\x49\x42\x67\x75','\x79\x77\x72\x4b\x71\x78\x62\x30\x75\x67\x66\x4a\x41\x32\x66\x4e\x7a\x78\x6d','\x79\x33\x6a\x4c\x79\x78\x72\x4c\x7a\x65\x66\x30','\x73\x77\x58\x56\x71\x33\x71','\x42\x4d\x66\x54\x7a\x71','\x73\x78\x72\x6d\x73\x4d\x57','\x44\x32\x4c\x30\x41\x65\x6e\x53\x41\x77\x76\x55\x44\x61','\x69\x63\x61\x47\x69\x67\x66\x57\x44\x63\x31\x4e\x7a\x78\x71\x47\x41\x77\x35\x5a\x44\x67\x66\x53\x42\x63\x61\x54\x45\x73\x62\x57\x45\x78\x72\x4f\x42\x32\x34','\x42\x32\x35\x71\x43\x4d\x39\x4e\x43\x4d\x76\x5a\x43\x57','\x45\x76\x4c\x35\x75\x4b\x4b','\x43\x67\x66\x59\x43\x32\x75','\x76\x77\x35\x5a\x44\x78\x62\x57\x42\x33\x6a\x30\x7a\x77\x71\x47\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a\x69\x67\x66\x4a\x44\x67\x4c\x56\x42\x4a\x4f\x47','\x44\x67\x6e\x53\x42\x33\x76\x4b','\x76\x65\x76\x66\x69\x67\x66\x30\x44\x67\x76\x5a\x44\x67\x66\x30\x41\x77\x39\x55\x69\x68\x44\x48\x43\x59\x62\x59\x7a\x78\x66\x31\x41\x78\x6a\x4c\x7a\x63\x62\x49\x44\x78\x71\x47\x42\x4d\x38\x47\x7a\x78\x7a\x50\x7a\x67\x76\x55\x79\x32\x75\x47\x44\x32\x66\x5a\x69\x68\x6a\x4c\x44\x68\x76\x59\x42\x4d\x76\x4b','\x7a\x4e\x6a\x56\x42\x75\x72\x56\x79\x32\x54\x4c\x43\x4d\x7a\x50\x42\x67\x75','\x79\x78\x62\x50\x73\x32\x76\x35','\x43\x67\x4c\x57\x69\x67\x4c\x55\x43\x33\x72\x48\x42\x67\x57\x47\x6c\x78\x69\x47','\x79\x32\x39\x5a\x44\x61','\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x30\x7a\x78\x6e\x30\x69\x67\x6e\x56\x42\x77\x31\x48\x42\x4d\x71\x47\x43\x67\x66\x5a\x43\x32\x76\x4b','\x44\x67\x66\x55\x7a\x32\x58\x4c\x6c\x78\x6a\x56\x44\x78\x72\x4c\x43\x49\x31\x49\x7a\x77\x35\x4a\x41\x67\x31\x48\x43\x4d\x53','\x42\x4e\x76\x54\x79\x4d\x76\x59','\x43\x33\x76\x50\x44\x67\x75','\x44\x68\x4c\x57\x7a\x71','\x75\x30\x48\x62\x6c\x74\x69\x31\x6e\x47','\x42\x77\x66\x34','\x74\x76\x76\x33\x43\x77\x38','\x79\x32\x39\x4b\x7a\x78\x47','\x42\x32\x7a\x4d','\x72\x67\x76\x4b\x45\x4e\x65','\x44\x67\x39\x74\x44\x68\x6a\x50\x42\x4d\x43','\x41\x78\x72\x4c\x43\x4d\x66\x30\x41\x77\x39\x55\x43\x57','\x79\x78\x44\x5a\x42\x65\x69','\x42\x77\x48\x35\x79\x4b\x43','\x43\x33\x72\x59\x41\x77\x35\x4e\x41\x77\x7a\x35','\x43\x4d\x76\x57\x42\x67\x66\x4a\x7a\x71','\x69\x63\x61\x47\x69\x67\x31\x50\x79\x33\x6a\x56\x42\x77\x66\x54\x79\x4d\x65\x47\x79\x32\x58\x4c\x79\x77\x34\x47\x6c\x73\x31\x48\x42\x67\x57\x47\x6c\x73\x31\x35\x7a\x78\x6d','\x42\x33\x62\x4c\x42\x4e\x6a\x56\x44\x78\x72\x4c\x43\x4a\x50\x33\x7a\x77\x6a\x46\x43\x32\x76\x48\x43\x4d\x6e\x4f','\x7a\x78\x48\x4c\x79\x57','\x41\x67\x66\x59\x42\x4d\x76\x5a\x43\x57','\x7a\x67\x76\x4d\x79\x78\x76\x53\x44\x61','\x41\x67\x66\x59\x42\x4d\x76\x5a\x43\x31\x39\x4c\x42\x4e\x79','\x43\x33\x72\x48\x43\x4e\x72\x5a\x76\x32\x4c\x30\x41\x61','\x71\x32\x58\x50\x7a\x77\x35\x30\x69\x67\x6e\x56\x42\x4d\x7a\x50\x7a\x33\x76\x59\x79\x78\x72\x50\x42\x32\x34\x47\x43\x4d\x76\x58\x44\x77\x4c\x59\x7a\x77\x71\x55\x69\x66\x62\x48\x43\x33\x6d\x47\x45\x59\x62\x4a\x42\x67\x4c\x4c\x42\x4e\x71\x36\x69\x68\x53\x47\x79\x4d\x66\x5a\x7a\x76\x76\x59\x42\x63\x57\x47\x79\x78\x62\x50\x73\x32\x76\x35\x69\x68\x30\x47\x46\x73\x62\x30\x42\x59\x62\x49\x44\x77\x4c\x53\x7a\x63\x47\x50\x69\x67\x39\x59\x69\x68\x76\x5a\x7a\x73\x62\x6a\x42\x77\x66\x4e\x7a\x75\x6a\x31\x41\x77\x58\x4b\x7a\x78\x69\x47\x44\x67\x48\x59\x42\x33\x76\x4e\x41\x63\x62\x30\x41\x67\x75\x47\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x4a\x42\x67\x4c\x4c\x42\x4e\x71\x55','\x6d\x74\x61\x34\x42\x31\x7a\x4b\x41\x67\x54\x73','\x69\x63\x61\x47\x69\x67\x66\x57\x44\x63\x31\x4e\x7a\x78\x71\x47\x41\x77\x35\x5a\x44\x67\x66\x53\x42\x63\x61\x54\x45\x73\x61\x54\x6c\x77\x35\x56\x6c\x77\x4c\x55\x43\x33\x72\x48\x42\x67\x57\x54\x43\x4d\x76\x4a\x42\x32\x31\x54\x7a\x77\x35\x4b\x43\x59\x61','\x43\x68\x6a\x56\x7a\x4d\x4c\x53\x7a\x71','\x44\x67\x76\x5a\x44\x65\x6e\x56\x42\x77\x31\x48\x42\x4d\x71','\x79\x32\x39\x55\x7a\x67\x65\x54\x7a\x4d\x39\x59\x7a\x32\x75','\x43\x32\x76\x48\x43\x4d\x6e\x4f\x6c\x4d\x6e\x56\x42\x4d\x7a\x50\x7a\x57','\x7a\x67\x66\x30\x79\x71','\x79\x77\x6a\x56\x43\x4e\x72\x4c\x7a\x61','\x43\x32\x76\x30','\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x5a\x7a\x78\x6e\x5a\x41\x77\x39\x55\x69\x67\x7a\x48\x41\x77\x58\x4c\x7a\x61','\x41\x4d\x39\x50\x42\x47','\x69\x67\x7a\x48\x41\x77\x58\x4c\x7a\x63\x61\x4f','\x44\x78\x6a\x53','\x73\x32\x66\x4d\x7a\x31\x75','\x71\x78\x76\x30\x41\x67\x39\x59\x41\x78\x50\x48\x44\x67\x4c\x56\x42\x47','\x41\x77\x31\x54\x7a\x77\x72\x50\x79\x78\x72\x4c','\x69\x63\x61\x47\x69\x68\x76\x57\x7a\x67\x66\x30\x7a\x73\x31\x48\x42\x68\x72\x4c\x43\x4d\x35\x48\x44\x67\x4c\x32\x7a\x78\x6d\x47\x6c\x73\x31\x50\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x63\x39\x31\x43\x33\x69\x56\x79\x4d\x4c\x55\x6c\x33\x62\x35\x44\x67\x48\x56\x42\x4a\x6d\x47\x43\x68\x4c\x30\x41\x67\x39\x55\x6d\x59\x61\x56\x44\x78\x6e\x59\x6c\x32\x6a\x50\x42\x49\x39\x57\x45\x78\x72\x4f\x42\x32\x34','\x44\x67\x39\x6d\x42\x33\x44\x4c\x43\x4b\x6e\x48\x43\x32\x75','\x41\x67\x76\x48\x7a\x67\x76\x59\x43\x57','\x6c\x33\x79\x58\x6c\x32\x4c\x54\x79\x77\x44\x4c\x43\x57','\x7a\x4d\x4c\x53\x44\x67\x76\x59','\x41\x78\x72\x4c\x43\x4d\x66\x30\x41\x77\x39\x55','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x31\x5a\x7a\x67\x53','\x44\x32\x4c\x30\x41\x66\x6e\x4c\x79\x33\x6a\x4c\x44\x68\x6d','\x42\x68\x66\x77\x7a\x77\x79','\x77\x77\x50\x6c\x41\x77\x38','\x42\x77\x66\x4a\x41\x67\x4c\x55\x7a\x71','\x42\x77\x4c\x55','\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a','\x76\x67\x76\x59\x42\x77\x4c\x55\x79\x77\x57\x47\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x63\x62\x59\x7a\x78\x6e\x31\x42\x68\x71\x47\x79\x77\x35\x4b\x69\x68\x6a\x4c\x43\x78\x76\x50\x43\x4d\x76\x4b\x69\x68\x72\x4c\x43\x33\x72\x5a\x69\x68\x62\x48\x43\x33\x6e\x4c\x7a\x63\x34','\x41\x67\x66\x59\x42\x4d\x76\x5a\x43\x30\x4c\x4b','\x75\x4c\x76\x6f\x69\x67\x31\x50\x79\x33\x6a\x56\x42\x77\x66\x54\x79\x4d\x65\x47\x41\x77\x35\x5a\x44\x67\x66\x53\x42\x63\x61\x54\x45\x73\x61\x54\x42\x49\x62\x49\x79\x78\x6e\x4c\x69\x61','\x43\x32\x6e\x4c\x42\x4d\x66\x59\x41\x77\x38','\x79\x78\x72\x30\x79\x77\x6e\x4f\x74\x77\x66\x4a\x41\x67\x4c\x55\x7a\x71','\x79\x32\x39\x54\x43\x67\x58\x4c\x44\x67\x75','\x75\x32\x4c\x31\x43\x68\x75','\x7a\x4d\x76\x30\x79\x32\x48\x6a\x42\x78\x62\x53','\x43\x32\x48\x48\x6d\x4a\x75\x32\x6f\x47','\x75\x30\x50\x6a\x75\x75\x4f','\x79\x77\x58\x53','\x42\x66\x62\x51\x75\x77\x43','\x71\x76\x48\x33\x45\x4d\x47','\x79\x75\x66\x53\x74\x30\x34','\x72\x75\x39\x30\x44\x75\x75','\x45\x4b\x39\x53\x44\x76\x65','\x42\x4d\x50\x6a\x45\x4e\x65','\x44\x67\x76\x4c\x71\x78\x72\x30\x7a\x78\x6e\x30\x79\x78\x72\x50\x42\x32\x35\x6b\x43\x32\x39\x55','\x42\x4d\x39\x64\x79\x77\x6e\x4f\x7a\x71','\x79\x32\x39\x54\x42\x77\x66\x55\x7a\x68\x6d','\x69\x59\x62\x6a\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x66\x62\x35\x44\x67\x48\x56\x42\x49\x62\x57\x79\x77\x6e\x52\x79\x77\x44\x4c\x43\x57','\x41\x77\x35\x57\x44\x78\x72\x70\x44\x4d\x76\x59\x43\x4d\x4c\x4b\x7a\x78\x6d','\x7a\x67\x76\x30\x79\x77\x6e\x4f\x74\x77\x66\x4a\x41\x67\x4c\x55\x7a\x71','\x79\x77\x44\x4c\x42\x4e\x72\x71\x43\x4d\x39\x4d\x41\x77\x58\x4c\x43\x57','\x6e\x4a\x69\x34\x6d\x4a\x7a\x78\x72\x66\x6e\x35\x79\x33\x75','\x42\x77\x76\x30\x79\x77\x72\x48\x44\x67\x65','\x44\x68\x6a\x48\x79\x32\x76\x6a\x7a\x61','\x79\x78\x6a\x30\x41\x77\x7a\x48\x79\x33\x72\x5a','\x44\x67\x66\x4e','\x69\x59\x62\x6a\x42\x4e\x6e\x30\x79\x77\x58\x53\x69\x68\x6e\x35\x43\x33\x72\x4c\x42\x73\x62\x57\x79\x77\x6e\x52\x79\x77\x44\x4c\x43\x57','\x43\x67\x66\x4a\x41\x32\x66\x4e\x7a\x78\x6d','\x79\x76\x6a\x70\x76\x66\x71','\x6c\x33\x6a\x31\x42\x4e\x6d\x56\x41\x77\x31\x57\x42\x33\x6a\x30','\x79\x33\x6a\x4c\x79\x78\x72\x4c\x76\x32\x4c\x30\x41\x65\x6e\x56\x42\x33\x6a\x4b\x41\x77\x35\x48\x44\x67\x39\x59','\x7a\x67\x4c\x5a\x43\x67\x66\x30\x79\x32\x48\x71\x43\x4d\x39\x54\x43\x68\x71','\x44\x68\x6a\x48\x79\x32\x75','\x72\x75\x35\x77\x69\x66\x62\x62\x76\x65\x47\x39\x69\x49\x39\x56\x43\x68\x71\x56\x79\x32\x39\x55\x7a\x67\x65\x56\x79\x4d\x4c\x55\x6f\x49\x72\x71\x71\x76\x72\x69\x69\x47','\x44\x4d\x76\x59\x41\x77\x7a\x35','\x43\x68\x6a\x56\x42\x78\x62\x30','\x75\x4e\x6a\x4b\x77\x76\x71','\x43\x33\x72\x59\x7a\x77\x66\x54\x79\x77\x6a\x53\x7a\x76\x39\x4f\x44\x68\x72\x57\x78\x33\x76\x59\x42\x61','\x69\x63\x61\x47\x69\x67\x66\x57\x44\x63\x31\x4e\x7a\x78\x71\x47\x41\x77\x35\x5a\x44\x67\x66\x53\x42\x63\x61\x54\x45\x73\x62\x5a\x42\x32\x7a\x30\x44\x32\x66\x59\x7a\x73\x31\x57\x43\x4d\x39\x57\x7a\x78\x6a\x30\x41\x77\x76\x5a\x6c\x77\x6e\x56\x42\x77\x31\x56\x42\x49\x61\x4d\x6a\x49\x62\x43','\x43\x4b\x50\x35\x7a\x4d\x71','\x42\x77\x4c\x55\x41\x77\x6e\x56\x42\x4d\x72\x48','\x79\x4d\x66\x5a\x7a\x76\x76\x59\x42\x61','\x79\x4d\x66\x5a\x7a\x75\x4c\x54\x79\x77\x44\x4c','\x76\x65\x76\x75\x73\x75\x47','\x44\x67\x31\x41\x42\x4e\x4b','\x6c\x32\x31\x4a\x43\x61','\x43\x68\x6a\x56\x7a\x33\x6a\x4c\x43\x33\x6d','\x79\x78\x76\x30\x42\x57','\x42\x67\x4c\x5a\x44\x61','\x79\x32\x58\x50\x7a\x77\x35\x30','\x79\x32\x39\x55\x7a\x67\x65','\x7a\x4e\x6a\x56\x42\x75\x6a\x31\x41\x77\x58\x4b\x75\x4d\x76\x5a\x44\x77\x58\x30','\x76\x67\x44\x59\x43\x4c\x79','\x44\x77\x35\x4b\x7a\x77\x7a\x50\x42\x4d\x76\x4b','\x42\x77\x66\x55\x79\x77\x44\x4c\x75\x32\x66\x55\x7a\x67\x6a\x56\x45\x67\x76\x5a\x69\x68\x62\x56\x42\x67\x4c\x4a\x45\x73\x62\x54\x44\x78\x6e\x30\x69\x67\x6a\x4c\x69\x68\x6e\x31\x43\x68\x62\x53\x41\x77\x76\x4b\x69\x67\x6a\x35\x69\x68\x72\x4f\x7a\x73\x62\x30\x42\x32\x39\x53\x69\x67\x48\x56\x43\x33\x71','\x42\x67\x39\x4a\x79\x77\x58\x4c\x71\x32\x39\x54\x43\x67\x66\x59\x7a\x71','\x42\x77\x6e\x57','\x7a\x4e\x6a\x56\x42\x75\x4c\x4b','\x79\x4e\x76\x50\x42\x67\x72\x74\x79\x77\x35\x4b\x79\x4d\x39\x34\x74\x77\x6e\x57\x71\x32\x39\x55\x7a\x4d\x4c\x4e\x6f\x49\x62\x48\x44\x78\x72\x4f\x76\x67\x39\x52\x7a\x77\x34\x47\x41\x78\x6d\x47\x43\x4d\x76\x58\x44\x77\x4c\x59\x7a\x77\x71','\x41\x78\x6e\x62\x43\x4e\x6a\x48\x45\x71','\x78\x63\x72\x43\x45\x57','\x79\x77\x6a\x56\x43\x4e\x71','\x71\x33\x6a\x4c\x79\x78\x72\x4c\x6c\x63\x62\x50\x42\x4e\x6e\x57\x7a\x77\x6e\x30\x6c\x63\x62\x48\x42\x4d\x71\x47\x42\x77\x66\x55\x79\x77\x44\x4c\x69\x68\x6e\x48\x42\x4d\x72\x49\x42\x33\x47\x47\x7a\x4d\x58\x4c\x7a\x78\x72\x5a\x69\x67\x7a\x56\x43\x49\x62\x57\x79\x78\x6a\x48\x42\x67\x58\x4c\x42\x63\x62\x48\x7a\x32\x76\x55\x44\x63\x62\x33\x42\x33\x6a\x52\x42\x67\x39\x48\x7a\x68\x6d\x55','\x79\x32\x48\x48\x42\x4d\x35\x4c\x42\x68\x6d','\x42\x33\x76\x30\x43\x68\x76\x30\x76\x67\x39\x52\x7a\x77\x35\x5a','\x44\x78\x6e\x4c\x43\x47','\x70\x68\x6a\x4c\x7a\x67\x66\x4a\x44\x67\x76\x4b\x70\x47','\x43\x67\x66\x4b\x75\x33\x72\x48\x43\x4e\x71','\x79\x4c\x6e\x58\x75\x4b\x4f','\x44\x77\x6a\x31\x42\x4e\x72\x31\x6f\x4a\x69\x59\x6c\x4a\x61\x30','\x41\x77\x31\x48\x7a\x32\x75','\x43\x4d\x76\x58\x44\x77\x4c\x59\x7a\x75\x66\x30\x44\x67\x76\x5a\x44\x67\x66\x30\x41\x77\x39\x55','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x65\x4c\x4b','\x44\x67\x39\x56\x42\x65\x4c\x55\x44\x4d\x39\x4a\x79\x78\x72\x50\x42\x32\x35\x5a','\x76\x4e\x62\x6d\x72\x67\x34','\x43\x32\x6e\x59\x79\x78\x72\x4a\x41\x61','\x44\x67\x66\x55\x7a\x32\x58\x4c\x6c\x77\x6e\x56\x42\x4e\x72\x59\x42\x32\x57\x54\x43\x67\x58\x48\x42\x4d\x75','\x44\x67\x66\x55\x7a\x32\x58\x4c\x6c\x78\x6e\x48\x42\x4d\x72\x49\x42\x33\x47','\x43\x33\x72\x59\x41\x77\x35\x4e','\x7a\x78\x7a\x48\x42\x66\x39\x54\x79\x78\x72\x59\x41\x78\x47','\x44\x32\x4c\x30\x41\x65\x76\x55\x44\x47','\x79\x4e\x76\x50\x42\x67\x72\x64\x42\x32\x35\x30\x43\x4d\x39\x53\x75\x67\x58\x48\x42\x4d\x76\x6e\x79\x33\x62\x64\x42\x32\x35\x4d\x41\x77\x43\x36\x69\x67\x66\x57\x41\x75\x54\x4c\x45\x73\x62\x50\x43\x59\x62\x59\x7a\x78\x66\x31\x41\x78\x6a\x4c\x7a\x61','\x7a\x68\x76\x59\x79\x78\x72\x50\x42\x32\x35\x6e\x43\x57','\x41\x32\x76\x35\x43\x57','\x71\x4d\x76\x48\x43\x4d\x76\x59\x69\x64\x58\x59\x7a\x77\x72\x48\x79\x33\x72\x4c\x7a\x64\x34','\x43\x32\x66\x55\x7a\x67\x6a\x56\x45\x65\x6e\x53\x41\x77\x76\x55\x44\x61','\x7a\x4e\x6a\x56\x42\x75\x76\x55\x44\x68\x6a\x50\x7a\x78\x6d','\x41\x68\x72\x30\x43\x61','\x7a\x75\x4c\x6b\x72\x32\x69'];a0_0x3d79=function(){return _0x470ff1;};return a0_0x3d79();}(function(_0x94aa34,_0x95a811){const _0x1b9c11=a0_0x43aa,_0x20285c=_0x94aa34();while(!![]){try{const _0x510735=parseInt(_0x1b9c11(0x1f2))/0x1+-parseInt(_0x1b9c11(0xc1))/0x2+-parseInt(_0x1b9c11(0x130))/0x3*(parseInt(_0x1b9c11(0x1bd))/0x4)+-parseInt(_0x1b9c11(0x11a))/0x5+parseInt(_0x1b9c11(0xf0))/0x6+-parseInt(_0x1b9c11(0x186))/0x7+parseInt(_0x1b9c11(0xfa))/0x8;if(_0x510735===_0x95a811)break;else _0x20285c['push'](_0x20285c['shift']());}catch(_0x605376){_0x20285c['push'](_0x20285c['shift']());}}}(a0_0x3d79,0x750be));import{a as a0_0x4bc384,c as a0_0x4acb50,d as a0_0x57318f,h as a0_0x50f1ed,i as a0_0x47ddeb,l as a0_0x46aa32,m as a0_0x165590,n as a0_0xa8516f,o as a0_0x4ddf44,p as a0_0x27b804,r as a0_0x289c3f,t as a0_0x4a09bb,u as a0_0x4c4030}from'\x2e\x2f\x73\x61\x6e\x64\x62\x6f\x78\x2d\x6a\x6f\x4b\x74\x51\x35\x79\x33\x2e\x6a\x73';import{a as a0_0x577f0c,c as a0_0x193670,d as a0_0xd051d1,i as a0_0x3cc870,l as a0_0x3699b1,n as a0_0x392f23,o as a0_0x373d5e,r as a0_0x58deab,s as a0_0x361f23,t as a0_0x550e41,u as a0_0x5a90a4}from'\x2e\x2f\x65\x72\x72\x6f\x72\x73\x2d\x44\x5a\x73\x66\x4a\x55\x75\x63\x2e\x6a\x73';import{a as a0_0x53a25a,c as a0_0x4e27e7,i as a0_0x68730a,l as a0_0x59b9e4,n as a0_0x56ab00,o as a0_0x50fc91,r as a0_0x545f4f,s as a0_0x33e013,t as a0_0xde429d}from'\x2e\x2f\x63\x6c\x69\x65\x6e\x74\x2d\x42\x42\x5a\x37\x59\x4c\x6d\x71\x2e\x6a\x73';import{a as a0_0x81d1cc,i as a0_0x1c3ecb,n as a0_0x1558c0,r as a0_0x135b2d,t as a0_0x2b149e}from'\x2e\x2f\x63\x6f\x6c\x6c\x61\x62\x6f\x72\x61\x74\x69\x6f\x6e\x2d\x42\x78\x6c\x66\x5a\x32\x55\x68\x2e\x6a\x73';import{t as a0_0x3ca9b1}from'\x2e\x2f\x74\x61\x6e\x67\x6c\x65\x2d\x44\x4d\x30\x6f\x36\x36\x6c\x57\x2e\x6a\x73';import{defineAgentProfile,defineGitHubResource,defineInlineResource,mergeAgentProfiles}from'\x40\x74\x61\x6e\x67\x6c\x65\x2d\x6e\x65\x74\x77\x6f\x72\x6b\x2f\x61\x67\x65\x6e\x74\x2d\x69\x6e\x74\x65\x72\x66\x61\x63\x65';function generateAttestationNonce(_0xfb482c=0x20){const _0x5065da=a0_0x43aa,_0x72b1f4={'\x61\x64\x47\x6e\x53':_0x5065da(0x124),'\x69\x79\x4f\x5a\x5a':_0x5065da(0x192)},_0x6f46bf=new Uint8Array(_0xfb482c);if(typeof globalThis[_0x5065da(0x178)]!==_0x5065da(0x8c)&&typeof globalThis[_0x5065da(0x178)][_0x5065da(0x104)]===_0x72b1f4[_0x5065da(0x164)])globalThis['\x63\x72\x79\x70\x74\x6f'][_0x5065da(0x104)](_0x6f46bf);else throw new Error(_0x72b1f4[_0x5065da(0xf8)]);return Array[_0x5065da(0xb8)](_0x6f46bf)[_0x5065da(0xb1)](_0x491ea4=>_0x491ea4[_0x5065da(0x1af)](0x10)['\x70\x61\x64\x53\x74\x61\x72\x74'](0x2,'\x30'))[_0x5065da(0x1c7)]('');}async function createConfidentialSandbox(_0x5147df,_0xb2bc6a){const _0x15d283=a0_0x43aa,_0x1d9157={'\x69\x6e\x6f\x48\x44':function(_0x8d1223,_0x3ef403){return _0x8d1223(_0x3ef403);}},_0x13c4dd=_0xb2bc6a[_0x15d283(0x151)]===_0x15d283(0x86)||_0xb2bc6a[_0x15d283(0x9e)]&&!_0xb2bc6a[_0x15d283(0x151)]&&!_0xb2bc6a[_0x15d283(0x187)][_0x15d283(0x151)]?generateAttestationNonce():_0xb2bc6a[_0x15d283(0x151)]??_0xb2bc6a[_0x15d283(0x187)][_0x15d283(0x151)],_0x29f903=await _0x5147df[_0x15d283(0x150)]({..._0xb2bc6a,'\x63\x6f\x6e\x66\x69\x64\x65\x6e\x74\x69\x61\x6c':{..._0xb2bc6a['\x63\x6f\x6e\x66\x69\x64\x65\x6e\x74\x69\x61\x6c'],..._0x13c4dd?{'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x4e\x6f\x6e\x63\x65':_0x13c4dd}:{},'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x52\x65\x66\x72\x65\x73\x68':_0xb2bc6a[_0x15d283(0x187)]['\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x52\x65\x66\x72\x65\x73\x68']||Boolean(_0x13c4dd)}});let _0x305873=_0x1d9157['\x69\x6e\x6f\x48\x44'](attestationFromMetadata,_0x29f903[_0x15d283(0x1f3)]);if(!_0x305873)try{_0x305873=(await _0x29f903[_0x15d283(0x160)](_0x13c4dd?{'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x4e\x6f\x6e\x63\x65':_0x13c4dd}:void 0x0))['\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e'];}catch(_0x213c1a){if(_0xb2bc6a[_0x15d283(0x9e)])throw _0x213c1a;}if(_0xb2bc6a[_0x15d283(0x9e)]&&!_0x305873)throw new Error(_0x15d283(0x19f));return{'\x73\x61\x6e\x64\x62\x6f\x78':_0x29f903,'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e':_0x305873,'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x4e\x6f\x6e\x63\x65':_0x13c4dd};}function attestationFromMetadata(_0x2fdc42){const _0x1f3034=a0_0x43aa,_0x33d07f={'\x48\x42\x61\x52\x73':_0x1f3034(0xa5),'\x72\x58\x69\x50\x68':function(_0x334ce3,_0x4752e8){return _0x334ce3===_0x4752e8;}},_0x511565=_0x2fdc42?.[_0x1f3034(0x1eb)];if(typeof _0x511565!==_0x33d07f['\x48\x42\x61\x52\x73']||_0x33d07f[_0x1f3034(0x161)](_0x511565['\x74\x72\x69\x6d'](),''))return void 0x0;try{return JSON[_0x1f3034(0x19c)](_0x511565);}catch{return;}}function startTeeAttestationHeartbeat(_0x1a8269,_0x3ef4f0={}){const _0x463f61=a0_0x43aa,_0x27cb88={'\x45\x4e\x55\x57\x57':function(_0x5efc2d,_0x39ee71){return _0x5efc2d!==_0x39ee71;},'\x6c\x50\x6a\x51\x67':function(_0x1a5ddf){return _0x1a5ddf();}},_0x371616=_0x3ef4f0[_0x463f61(0x15d)]??0xea60;let _0x8000e1=![],_0x2ac651=0x0,_0x2d69c4=0x0,_0x67f333,_0xb5258c,_0xd2b75e;const _0x9f8734=new Promise(_0x4bcfeb=>{_0xd2b75e=_0x4bcfeb;}),_0x5a2563=()=>{if(_0x8000e1)return;_0x8000e1=!![];if(_0xb5258c)clearTimeout(_0xb5258c);_0xd2b75e?.();},_0x2ff863=async()=>{const _0x3236b=_0x463f61;if(_0x8000e1||_0x3ef4f0[_0x3236b(0x165)]?.['\x61\x62\x6f\x72\x74\x65\x64'])throw new Error(_0x3236b(0xb3));const _0x45518c=generateAttestationNonce(),_0x3ea3c3=await _0x1a8269['\x67\x65\x74\x54\x65\x65\x41\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e']({'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x4e\x6f\x6e\x63\x65':_0x45518c});if(_0x3ea3c3[_0x3236b(0x151)]&&_0x27cb88['\x45\x4e\x55\x57\x57'](_0x3ea3c3[_0x3236b(0x151)],_0x45518c))throw new Error(_0x3236b(0x180));const _0x2cb4d3={'\x73\x65\x71\x75\x65\x6e\x63\x65':++_0x2d69c4,'\x6e\x6f\x6e\x63\x65':_0x45518c,'\x72\x65\x73\x70\x6f\x6e\x73\x65':{..._0x3ea3c3,'\x61\x74\x74\x65\x73\x74\x61\x74\x69\x6f\x6e\x4e\x6f\x6e\x63\x65':_0x3ea3c3[_0x3236b(0x151)]??_0x45518c},'\x63\x68\x65\x63\x6b\x65\x64\x41\x74':new Date()};return await _0x3ef4f0[_0x3236b(0x79)]?.(_0x2cb4d3),_0x67f333=_0x2cb4d3,_0x3ef4f0[_0x3236b(0xc4)]?.(_0x2cb4d3),_0x2cb4d3;},_0x5e6192=()=>{const _0x30a62f=_0x463f61,_0x1dcda7={'\x46\x44\x58\x5a\x7a':function(_0x22c12f){return _0x22c12f();}};if(_0x8000e1||_0x3ef4f0[_0x30a62f(0x165)]?.[_0x30a62f(0x1c4)]){_0x27cb88['\x6c\x50\x6a\x51\x67'](_0x5a2563);return;}_0xb5258c=setTimeout(()=>{const _0x4ad665=_0x30a62f;_0x1dcda7[_0x4ad665(0x133)](_0x33da85);},_0x371616);},_0x33da85=async()=>{const _0x44e494=_0x463f61;try{await _0x2ff863(),_0x5e6192();}catch(_0x10fff1){_0x2ac651+=0x1,_0x3ef4f0[_0x44e494(0x16d)]?.(_0x10fff1);if(_0x3ef4f0[_0x44e494(0x10a)])_0x5e6192();else _0x5a2563();}};_0x3ef4f0[_0x463f61(0x165)]?.['\x61\x64\x64\x45\x76\x65\x6e\x74\x4c\x69\x73\x74\x65\x6e\x65\x72'](_0x463f61(0x94),_0x5a2563,{'\x6f\x6e\x63\x65':!![]});if(_0x3ef4f0[_0x463f61(0x1cc)]===![])_0x27cb88[_0x463f61(0x1e5)](_0x5e6192);else _0x27cb88[_0x463f61(0x1e5)](_0x33da85);return{'\x73\x74\x6f\x70':_0x5a2563,'\x70\x69\x6e\x67':_0x2ff863,get '\x73\x74\x6f\x70\x70\x65\x64'(){return _0x8000e1;},get '\x66\x61\x69\x6c\x75\x72\x65\x73'(){return _0x2ac651;},get '\x6c\x61\x74\x65\x73\x74'(){return _0x67f333;},'\x64\x6f\x6e\x65':_0x9f8734};}function isFetchClient(_0x582f2b){const _0x4f793c=a0_0x43aa,_0x456261={'\x41\x52\x4a\x69\x62':function(_0xa9d378,_0x4578ea){return _0xa9d378===_0x4578ea;}};return _0x456261['\x41\x52\x4a\x69\x62'](typeof _0x582f2b['\x66\x65\x74\x63\x68'],_0x4f793c(0x124));}function requestImageBuild(_0x35e2e1,_0x3d49e4){const _0x4c0ec0=a0_0x43aa,_0x30da84={'\x63\x51\x41\x48\x51':function(_0x538d64,_0x319a7b){return _0x538d64(_0x319a7b);},'\x45\x46\x63\x74\x4a':function(_0x3b4e3d,_0x599530,_0x93e210){return _0x3b4e3d(_0x599530,_0x93e210);}};if(_0x30da84[_0x4c0ec0(0x184)](isFetchClient,_0x35e2e1))return _0x35e2e1['\x66\x65\x74\x63\x68']('\x2f\x76\x31\x2f\x69\x6d\x61\x67\x65\x73',_0x3d49e4);const _0x13e25a=new Headers(_0x3d49e4[_0x4c0ec0(0x1cf)]);return _0x13e25a[_0x4c0ec0(0x1c5)](_0x4c0ec0(0x1cb),_0x4c0ec0(0xd4)+_0x35e2e1['\x61\x70\x69\x4b\x65\x79']),_0x30da84[_0x4c0ec0(0xe2)](fetch,_0x35e2e1[_0x4c0ec0(0x80)][_0x4c0ec0(0x1b4)](/\/+$/,'')+_0x4c0ec0(0x1d0),{..._0x3d49e4,'\x68\x65\x61\x64\x65\x72\x73':_0x13e25a});}var Image=class Image{constructor(_0x1aad12,_0x1301b6,_0x5b5bee,_0x56c6c2){const _0x2d8e12=a0_0x43aa;this['\x69\x64']=_0x1aad12,this[_0x2d8e12(0x1f6)]=_0x1301b6,this[_0x2d8e12(0xf2)]=_0x5b5bee,this[_0x2d8e12(0x16b)]=_0x56c6c2;}static[a0_0x5244d4(0x150)](_0x544295=a0_0x5244d4(0x9c)){return new ImageBuilder({'\x62\x61\x73\x65\x49\x6d\x61\x67\x65':_0x544295});}static[a0_0x5244d4(0x90)](_0x4b11c5){const _0x350e85=a0_0x5244d4;return new Image(_0x4b11c5,_0x4b11c5[_0x350e85(0x1bb)](_0x350e85(0x1e2))?'\x74\x61\x6e\x67\x6c\x65\x2d\x69\x6d\x61\x67\x65\x3a'+_0x4b11c5[_0x350e85(0xe6)](0x7,0x13):_0x4b11c5,_0x4b11c5);}static[a0_0x5244d4(0x1a0)](_0x353329,_0x4cae2c){const _0x4e3c4a=a0_0x5244d4;return new ImageBuilder({'\x62\x61\x73\x65\x49\x6d\x61\x67\x65':_0x4e3c4a(0xa2),'\x64\x6f\x63\x6b\x65\x72\x66\x69\x6c\x65':_0x353329,'\x64\x6f\x63\x6b\x65\x72\x43\x6f\x6e\x74\x65\x78\x74':_0x4cae2c||'\x2e'});}static[a0_0x5244d4(0x8a)](_0x5cd738){const _0x4e2476=a0_0x5244d4;return new Image(_0x5cd738['\x69\x64'],_0x5cd738[_0x4e2476(0x1f6)],_0x5cd738[_0x4e2476(0xf2)],_0x5cd738[_0x4e2476(0x16b)]);}['\x74\x6f\x4a\x53\x4f\x4e'](){const _0x3a10e4=a0_0x5244d4;return{'\x69\x64':this['\x69\x64'],'\x74\x61\x67':this[_0x3a10e4(0x1f6)],'\x64\x69\x67\x65\x73\x74':this[_0x3a10e4(0xf2)],'\x73\x70\x65\x63':this['\x73\x70\x65\x63']};}},ImageBuilder=class{[a0_0x5244d4(0x16b)];[a0_0x5244d4(0x10f)];constructor(_0x353270){const _0x723fc9=a0_0x5244d4,_0x1b98c3={'\x79\x58\x48\x45\x77':_0x723fc9(0x9c)};this['\x73\x70\x65\x63']={'\x62\x61\x73\x65\x49\x6d\x61\x67\x65':_0x353270[_0x723fc9(0x81)]||_0x1b98c3['\x79\x58\x48\x45\x77'],..._0x353270};}[a0_0x5244d4(0x114)](_0x1cddbd){const _0x2b6c83=a0_0x5244d4;return this[_0x2b6c83(0x16b)][_0x2b6c83(0x147)]=_0x1cddbd,this;}[a0_0x5244d4(0xc5)](_0x580e2d){const _0xfa1767=a0_0x5244d4;return this[_0xfa1767(0x16b)][_0xfa1767(0x72)]=[...this[_0xfa1767(0x16b)]['\x70\x61\x63\x6b\x61\x67\x65\x73']||[],..._0x580e2d],this;}[a0_0x5244d4(0x170)](_0x8de81a){const _0x4a01a0=a0_0x5244d4;return this['\x73\x70\x65\x63']['\x63\x6f\x6d\x6d\x61\x6e\x64\x73']=[...this[_0x4a01a0(0x16b)][_0x4a01a0(0x1ed)]||[],_0x4a01a0(0x1a2)+_0x8de81a],this;}[a0_0x5244d4(0x179)](_0x349069){const _0x1e51ce=a0_0x5244d4;return this[_0x1e51ce(0x16b)][_0x1e51ce(0x1ed)]=[...this[_0x1e51ce(0x16b)]['\x63\x6f\x6d\x6d\x61\x6e\x64\x73']||[],..._0x349069],this;}[a0_0x5244d4(0x193)](_0x460e48){const _0x363516=a0_0x5244d4;return this[_0x363516(0x16b)][_0x363516(0x176)]=[...this['\x73\x70\x65\x63']['\x61\x70\x74\x50\x61\x63\x6b\x61\x67\x65\x73']||[],..._0x460e48],this;}[a0_0x5244d4(0xa7)](_0x4386f5){const _0x414ca0=a0_0x5244d4;return this[_0x414ca0(0x16b)][_0x414ca0(0x174)]={...this[_0x414ca0(0x16b)][_0x414ca0(0x174)],..._0x4386f5},this;}[a0_0x5244d4(0x1d4)](_0x4fbe71){const _0x3e390b=a0_0x5244d4;return this['\x73\x70\x65\x63'][_0x3e390b(0xdc)]=[...this[_0x3e390b(0x16b)][_0x3e390b(0xdc)]||[],..._0x4fbe71],this;}[a0_0x5244d4(0x89)](_0xb307ea,_0x41defd){const _0x26e507=a0_0x5244d4,_0x200ca6={'\x61\x52\x4f\x54\x54':_0x26e507(0x1c1)};return this['\x73\x70\x65\x63'][_0x26e507(0x89)]={'\x70\x61\x63\x6b\x61\x67\x65\x73':[...this[_0x26e507(0x16b)]['\x63\x6f\x6e\x64\x61']?.[_0x26e507(0x72)]||[],..._0xb307ea],'\x63\x68\x61\x6e\x6e\x65\x6c\x73':_0x41defd||this[_0x26e507(0x16b)][_0x26e507(0x89)]?.[_0x26e507(0x96)]||[_0x200ca6[_0x26e507(0x73)]]},this;}[a0_0x5244d4(0x16c)](_0x87957f){return this['\x73\x70\x65\x63']['\x77\x6f\x72\x6b\x64\x69\x72']=_0x87957f,this;}[a0_0x5244d4(0x98)](_0x57c79f){const _0x4f1eff=a0_0x5244d4;return this[_0x4f1eff(0x16b)][_0x4f1eff(0x98)]=_0x57c79f,this;}['\x62\x75\x69\x6c\x64\x41\x72\x67\x73'](_0x24a2b1){const _0x4688c5=a0_0x5244d4;return this['\x73\x70\x65\x63'][_0x4688c5(0xf3)]={...this[_0x4688c5(0x16b)]['\x62\x75\x69\x6c\x64\x41\x72\x67\x73'],..._0x24a2b1},this;}[a0_0x5244d4(0xf9)](_0x507646){const _0x35e222=a0_0x5244d4;return this[_0x35e222(0x16b)][_0x35e222(0xf9)]={...this['\x73\x70\x65\x63'][_0x35e222(0xf9)],..._0x507646},this;}[a0_0x5244d4(0x102)](){const _0x1f93d5=a0_0x5244d4;return{...this[_0x1f93d5(0x16b)]};}async['\x63\x6f\x6d\x70\x75\x74\x65\x49\x64'](){const _0x32cf5c=a0_0x5244d4,_0x4fa38b={'\x45\x50\x74\x72\x74':_0x32cf5c(0x1a9),'\x54\x67\x72\x72\x56':function(_0x195af6,_0x26ddc6){return _0x195af6(_0x26ddc6);},'\x4f\x57\x66\x47\x46':'\x73\x68\x61\x32\x35\x36','\x5a\x4b\x4d\x49\x4e':_0x32cf5c(0x14e)},_0x39411f=JSON[_0x32cf5c(0x1b3)](this[_0x32cf5c(0x16b)],Object['\x6b\x65\x79\x73'](this[_0x32cf5c(0x16b)])['\x73\x6f\x72\x74']()),_0xe3b8da=globalThis[_0x32cf5c(0x178)]?.[_0x32cf5c(0xd7)];if(_0xe3b8da){const _0x4b67dd=await _0xe3b8da[_0x32cf5c(0xf2)](_0x4fa38b[_0x32cf5c(0x11e)],new TextEncoder()[_0x32cf5c(0x191)](_0x39411f));return Array['\x66\x72\x6f\x6d'](new Uint8Array(_0x4b67dd))['\x6d\x61\x70'](_0x673d71=>_0x673d71[_0x32cf5c(0x1af)](0x10)[_0x32cf5c(0x9a)](0x2,'\x30'))[_0x32cf5c(0x1c7)]('');}const {createHash:_0x3e3f8e}=await import('\x6e\x6f\x64\x65\x3a\x63\x72\x79\x70\x74\x6f');return _0x4fa38b[_0x32cf5c(0x8b)](_0x3e3f8e,_0x4fa38b[_0x32cf5c(0xc6)])[_0x32cf5c(0x113)](_0x39411f)[_0x32cf5c(0xf2)](_0x4fa38b['\x5a\x4b\x4d\x49\x4e']);}[a0_0x5244d4(0x198)](_0xe5b756){const _0x61ee0e=a0_0x5244d4;return this[_0x61ee0e(0x10f)]=_0xe5b756,this;}async[a0_0x5244d4(0x158)](_0x4bf66c){const _0x41f1ac=a0_0x5244d4,_0x190730={'\x57\x66\x4b\x74\x6a':function(_0x2cd51f,_0x442b47){return _0x2cd51f>_0x442b47;},'\x72\x4a\x79\x66\x64':function(_0x5ce8c6,_0x40680b,_0x4bc652){return _0x5ce8c6(_0x40680b,_0x4bc652);},'\x6a\x6f\x71\x4d\x70':_0x41f1ac(0xe0),'\x62\x53\x71\x52\x4a':function(_0x8a40e6,_0x2b67a3,_0x554ebc){return _0x8a40e6(_0x2b67a3,_0x554ebc);},'\x73\x4d\x6a\x61\x67':function(_0xb8d2e4,_0x5824af){return _0xb8d2e4===_0x5824af;},'\x61\x77\x73\x6c\x42':_0x41f1ac(0x85),'\x4b\x5a\x45\x52\x4a':'\x65\x72\x72\x6f\x72','\x54\x4a\x6d\x6a\x68':function(_0x1ec44d,_0x1e5230){return _0x1ec44d(_0x1e5230);}},_0x4bbf99=_0x4bf66c?.[_0x41f1ac(0x88)]||this[_0x41f1ac(0x10f)];if(!_0x4bbf99)throw new Error(_0x41f1ac(0x1bc));const _0xb5da50=_0x4bf66c?.[_0x41f1ac(0xf1)]??0x927c0,_0x5ce1a2=_0x190730[_0x41f1ac(0x13a)](_0xb5da50,0x0)?new AbortController():void 0x0,_0x42d31d=_0x5ce1a2?setTimeout(()=>_0x5ce1a2['\x61\x62\x6f\x72\x74'](),_0xb5da50):void 0x0;let _0x47056b;try{_0x47056b=await _0x190730[_0x41f1ac(0x7e)](requestImageBuild,_0x4bbf99,{'\x6d\x65\x74\x68\x6f\x64':_0x41f1ac(0x125),'\x68\x65\x61\x64\x65\x72\x73':{'\x43\x6f\x6e\x74\x65\x6e\x74\x2d\x54\x79\x70\x65':'\x61\x70\x70\x6c\x69\x63\x61\x74\x69\x6f\x6e\x2f\x6a\x73\x6f\x6e'},'\x73\x69\x67\x6e\x61\x6c':_0x5ce1a2?.[_0x41f1ac(0x165)],'\x62\x6f\x64\x79':JSON[_0x41f1ac(0x1b3)]({'\x73\x70\x65\x63':this[_0x41f1ac(0x16b)],'\x6f\x70\x74\x69\x6f\x6e\x73':{'\x6e\x6f\x43\x61\x63\x68\x65':_0x4bf66c?.[_0x41f1ac(0x1ec)],'\x70\x6c\x61\x74\x66\x6f\x72\x6d':_0x4bf66c?.[_0x41f1ac(0xcc)],'\x74\x61\x67':_0x4bf66c?.[_0x41f1ac(0x1f6)],'\x73\x74\x72\x65\x61\x6d':!!_0x4bf66c?.['\x6f\x6e\x50\x72\x6f\x67\x72\x65\x73\x73']}})});if(!_0x47056b['\x6f\x6b']){const _0x4565fa=await _0x47056b[_0x41f1ac(0x17b)]();throw new Error(_0x41f1ac(0xba)+_0x4565fa);}if(_0x4bf66c?.[_0x41f1ac(0x19a)]&&_0x47056b['\x68\x65\x61\x64\x65\x72\x73'][_0x41f1ac(0x127)](_0x41f1ac(0xd3))?.[_0x41f1ac(0x17c)](_0x190730[_0x41f1ac(0x11c)])){let _0x4ec3d8;for await(const _0x230224 of _0x190730[_0x41f1ac(0x9b)](a0_0x27b804,_0x47056b['\x62\x6f\x64\x79'],{'\x73\x69\x67\x6e\x61\x6c':_0x5ce1a2?.[_0x41f1ac(0x165)]})){const _0x13c659=_0x230224[_0x41f1ac(0x1c3)];if(_0x190730['\x73\x4d\x6a\x61\x67'](_0x13c659[_0x41f1ac(0x1a8)],_0x190730[_0x41f1ac(0x1b1)]))_0x4bf66c['\x6f\x6e\x50\x72\x6f\x67\x72\x65\x73\x73'](_0x13c659['\x65\x76\x65\x6e\x74']);else{if(_0x13c659[_0x41f1ac(0x1a8)]===_0x41f1ac(0x1df)){const _0x1934b1=_0x13c659[_0x41f1ac(0x166)];_0x4ec3d8={..._0x1934b1,'\x63\x72\x65\x61\x74\x65\x64\x41\x74':new Date(_0x1934b1[_0x41f1ac(0x194)])};}else{if(_0x190730[_0x41f1ac(0x173)](_0x13c659[_0x41f1ac(0x1a8)],_0x190730[_0x41f1ac(0x156)]))throw new Error(String(_0x13c659[_0x41f1ac(0x13e)]??_0x41f1ac(0x117)));}}}if(!_0x4ec3d8)throw new Error('\x42\x75\x69\x6c\x64\x20\x63\x6f\x6d\x70\x6c\x65\x74\x65\x64\x20\x62\x75\x74\x20\x6e\x6f\x20\x72\x65\x73\x75\x6c\x74\x20\x72\x65\x63\x65\x69\x76\x65\x64');return Image[_0x41f1ac(0x8a)](_0x4ec3d8);}const _0x40d80b=await _0x47056b['\x6a\x73\x6f\x6e'](),_0x5db13={..._0x40d80b,'\x63\x72\x65\x61\x74\x65\x64\x41\x74':new Date(_0x40d80b[_0x41f1ac(0x194)])};return Image['\x66\x72\x6f\x6d\x42\x75\x69\x6c\x64\x52\x65\x73\x75\x6c\x74'](_0x5db13);}catch(_0x1f0440){if(_0x5ce1a2?.[_0x41f1ac(0x165)]['\x61\x62\x6f\x72\x74\x65\x64'])throw new Error(_0x41f1ac(0x101)+_0xb5da50+'\x6d\x73');throw _0x1f0440;}finally{if(_0x42d31d)_0x190730[_0x41f1ac(0x17e)](clearTimeout,_0x42d31d);}}[a0_0x5244d4(0xf4)](){return generateDockerfile(this['\x73\x70\x65\x63']);}};function generateDockerfile(_0x4856eb){const _0x3a26d5=a0_0x5244d4,_0x3f117f={'\x6d\x68\x79\x62\x47':function(_0xa05256,_0x196329){return _0xa05256>_0x196329;},'\x44\x70\x76\x4a\x47':_0x3a26d5(0x110),'\x6c\x71\x56\x65\x66':_0x3a26d5(0x129),'\x7a\x52\x43\x73\x6b':'\x70\x79\x74\x68\x6f\x6e','\x52\x72\x64\x59\x54':_0x3a26d5(0x7f),'\x4f\x6e\x64\x73\x5a':_0x3a26d5(0xee),'\x78\x45\x57\x54\x42':_0x3a26d5(0x7d),'\x53\x69\x75\x70\x75':_0x3a26d5(0x18d),'\x71\x6e\x49\x42\x65':_0x3a26d5(0x1c1),'\x51\x59\x6b\x4e\x41':_0x3a26d5(0x78),'\x62\x76\x56\x78\x49':_0x3a26d5(0xeb)},_0x1703ab=[];_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x185)+_0x4856eb['\x62\x61\x73\x65\x49\x6d\x61\x67\x65']),_0x1703ab[_0x3a26d5(0xc8)]('');if(_0x4856eb[_0x3a26d5(0xf9)]&&Object[_0x3a26d5(0xaa)](_0x4856eb['\x6c\x61\x62\x65\x6c\x73'])['\x6c\x65\x6e\x67\x74\x68']>0x0){for(const [_0x3ee69c,_0x5afbee]of Object[_0x3a26d5(0x100)](_0x4856eb['\x6c\x61\x62\x65\x6c\x73']))_0x1703ab[_0x3a26d5(0xc8)]('\x4c\x41\x42\x45\x4c\x20'+_0x3ee69c+'\x3d\x22'+_0x5afbee+'\x22');_0x1703ab['\x70\x75\x73\x68']('');}if(_0x4856eb[_0x3a26d5(0xf3)]&&Object['\x6b\x65\x79\x73'](_0x4856eb[_0x3a26d5(0xf3)])[_0x3a26d5(0x137)]>0x0){for(const [_0x109f83,_0x22c1f1]of Object[_0x3a26d5(0x100)](_0x4856eb[_0x3a26d5(0xf3)]))_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0xc7)+_0x109f83+'\x3d'+_0x22c1f1);_0x1703ab[_0x3a26d5(0xc8)]('');}if(_0x4856eb[_0x3a26d5(0x174)]&&_0x3f117f[_0x3a26d5(0x1b2)](Object[_0x3a26d5(0xaa)](_0x4856eb[_0x3a26d5(0x174)])[_0x3a26d5(0x137)],0x0)){for(const [_0x2bac08,_0x14a428]of Object[_0x3a26d5(0x100)](_0x4856eb[_0x3a26d5(0x174)]))_0x1703ab['\x70\x75\x73\x68'](_0x3a26d5(0xdf)+_0x2bac08+'\x3d\x22'+_0x14a428+'\x22');_0x1703ab[_0x3a26d5(0xc8)]('');}_0x4856eb[_0x3a26d5(0x16c)]&&(_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x163)+_0x4856eb[_0x3a26d5(0x16c)]),_0x1703ab[_0x3a26d5(0xc8)](''));_0x4856eb[_0x3a26d5(0x176)]&&_0x3f117f[_0x3a26d5(0x1b2)](_0x4856eb[_0x3a26d5(0x176)][_0x3a26d5(0x137)],0x0)&&(_0x1703ab['\x70\x75\x73\x68'](_0x3a26d5(0x71)),_0x1703ab[_0x3a26d5(0xc8)](_0x3f117f[_0x3a26d5(0x134)]),_0x1703ab['\x70\x75\x73\x68'](_0x3a26d5(0x1be)+_0x4856eb[_0x3a26d5(0x176)][_0x3a26d5(0x1c7)]('\x20')+_0x3a26d5(0xde)),_0x1703ab[_0x3a26d5(0xc8)](_0x3f117f[_0x3a26d5(0x1d5)]),_0x1703ab[_0x3a26d5(0xc8)](''));_0x4856eb[_0x3a26d5(0x147)]&&(_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0xca)+_0x4856eb[_0x3a26d5(0x147)]),!(_0x4856eb['\x62\x61\x73\x65\x49\x6d\x61\x67\x65'][_0x3a26d5(0x17c)](_0x3f117f['\x7a\x52\x43\x73\x6b'])||_0x4856eb[_0x3a26d5(0x81)][_0x3a26d5(0x17c)](_0x3a26d5(0x153))||_0x4856eb['\x62\x61\x73\x65\x49\x6d\x61\x67\x65'][_0x3a26d5(0x17c)](_0x3f117f[_0x3a26d5(0x7b)]))&&_0x4856eb[_0x3a26d5(0x81)][_0x3a26d5(0x17c)](_0x3f117f['\x4f\x6e\x64\x73\x5a'])&&(_0x1703ab[_0x3a26d5(0xc8)](_0x3f117f[_0x3a26d5(0x134)]),_0x1703ab['\x70\x75\x73\x68'](_0x3f117f['\x78\x45\x57\x54\x42']),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0xbf)),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x199)+_0x4856eb['\x70\x79\x74\x68\x6f\x6e\x56\x65\x72\x73\x69\x6f\x6e']+'\x20\x70\x79\x74\x68\x6f\x6e'+_0x4856eb['\x70\x79\x74\x68\x6f\x6e\x56\x65\x72\x73\x69\x6f\x6e']+_0x3a26d5(0xff)+_0x4856eb[_0x3a26d5(0x147)]+_0x3a26d5(0x18e)),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x129)),_0x1703ab[_0x3a26d5(0xc8)](''),_0x1703ab[_0x3a26d5(0xc8)]('\x52\x55\x4e\x20\x75\x70\x64\x61\x74\x65\x2d\x61\x6c\x74\x65\x72\x6e\x61\x74\x69\x76\x65\x73\x20\x2d\x2d\x69\x6e\x73\x74\x61\x6c\x6c\x20\x2f\x75\x73\x72\x2f\x62\x69\x6e\x2f\x70\x79\x74\x68\x6f\x6e\x20\x70\x79\x74\x68\x6f\x6e\x20\x2f\x75\x73\x72\x2f\x62\x69\x6e\x2f\x70\x79\x74\x68\x6f\x6e'+_0x4856eb['\x70\x79\x74\x68\x6f\x6e\x56\x65\x72\x73\x69\x6f\x6e']+_0x3a26d5(0xea)),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x1cd)+_0x4856eb[_0x3a26d5(0x147)]+'\x20\x31'),_0x1703ab[_0x3a26d5(0xc8)](''),_0x1703ab[_0x3a26d5(0xc8)]('\x52\x55\x4e\x20\x63\x75\x72\x6c\x20\x2d\x73\x53\x20\x68\x74\x74\x70\x73\x3a\x2f\x2f\x62\x6f\x6f\x74\x73\x74\x72\x61\x70\x2e\x70\x79\x70\x61\x2e\x69\x6f\x2f\x67\x65\x74\x2d\x70\x69\x70\x2e\x70\x79\x20\x7c\x20\x70\x79\x74\x68\x6f\x6e')),_0x1703ab[_0x3a26d5(0xc8)](''));if(_0x4856eb[_0x3a26d5(0x89)]&&_0x4856eb[_0x3a26d5(0x89)][_0x3a26d5(0x72)][_0x3a26d5(0x137)]>0x0){_0x1703ab[_0x3a26d5(0xc8)](_0x3f117f[_0x3a26d5(0x1e0)]),_0x1703ab['\x70\x75\x73\x68']('\x52\x55\x4e\x20\x63\x75\x72\x6c\x20\x2d\x4c\x73\x20\x68\x74\x74\x70\x73\x3a\x2f\x2f\x6d\x69\x63\x72\x6f\x2e\x6d\x61\x6d\x62\x61\x2e\x70\x6d\x2f\x61\x70\x69\x2f\x6d\x69\x63\x72\x6f\x6d\x61\x6d\x62\x61\x2f\x6c\x69\x6e\x75\x78\x2d\x36\x34\x2f\x6c\x61\x74\x65\x73\x74\x20\x7c\x20\x74\x61\x72\x20\x2d\x78\x76\x6a\x20\x62\x69\x6e\x2f\x6d\x69\x63\x72\x6f\x6d\x61\x6d\x62\x61\x20\x26\x26\x20\x5c'),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x107)),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0xd6)),_0x1703ab['\x70\x75\x73\x68']('');const _0x219586=(_0x4856eb[_0x3a26d5(0x89)][_0x3a26d5(0x96)]||[_0x3f117f[_0x3a26d5(0x168)]])[_0x3a26d5(0xb1)](_0x591075=>'\x2d\x63\x20'+_0x591075)['\x6a\x6f\x69\x6e']('\x20');_0x1703ab['\x70\x75\x73\x68'](_0x3a26d5(0x1dc)+_0x219586+'\x20'+_0x4856eb[_0x3a26d5(0x89)][_0x3a26d5(0x72)]['\x6a\x6f\x69\x6e']('\x20')+'\x20\x26\x26\x20\x5c'),_0x1703ab['\x70\x75\x73\x68'](_0x3a26d5(0x1b5)),_0x1703ab['\x70\x75\x73\x68'](_0x3f117f[_0x3a26d5(0x12f)]),_0x1703ab[_0x3a26d5(0xc8)]('');}_0x4856eb[_0x3a26d5(0x72)]&&_0x4856eb['\x70\x61\x63\x6b\x61\x67\x65\x73'][_0x3a26d5(0x137)]>0x0&&(_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x1ee)),_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x16e)+_0x4856eb[_0x3a26d5(0x72)][_0x3a26d5(0x1c7)]('\x20')),_0x1703ab[_0x3a26d5(0xc8)](''));if(_0x4856eb[_0x3a26d5(0x1ed)]&&_0x4856eb[_0x3a26d5(0x1ed)][_0x3a26d5(0x137)]>0x0){_0x1703ab[_0x3a26d5(0xc8)](_0x3f117f[_0x3a26d5(0x136)]);for(const _0x3126f0 of _0x4856eb[_0x3a26d5(0x1ed)])_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x190)+_0x3126f0);_0x1703ab[_0x3a26d5(0xc8)]('');}if(_0x4856eb[_0x3a26d5(0x98)])_0x1703ab[_0x3a26d5(0xc8)](_0x3a26d5(0x14f)+_0x4856eb[_0x3a26d5(0x98)]);return _0x1703ab[_0x3a26d5(0x1c7)]('\x0a');}const MANAGE_SANDBOXES_TOOL_NAME=a0_0x5244d4(0x1d9);function createManageSandboxesTool(_0x5734ec,_0x551cd2={}){const _0x2ef0e5=a0_0x5244d4,_0x5a7bc9={'\x73\x6c\x48\x6e\x59':function(_0x1781d4,_0x5b6e44,_0x3d0366){return _0x1781d4(_0x5b6e44,_0x3d0366);},'\x52\x78\x6b\x43\x63':function(_0x216a06,_0x33147c){return _0x216a06(_0x33147c);},'\x6b\x6e\x68\x57\x4f':_0x2ef0e5(0x75),'\x6b\x6c\x58\x52\x66':_0x2ef0e5(0x87),'\x61\x41\x6c\x4f\x4e':_0x2ef0e5(0xcb),'\x57\x45\x4c\x75\x6f':_0x2ef0e5(0xe7),'\x57\x4f\x74\x69\x61':'\x61\x74\x74\x61\x63\x68\x4d\x61\x63\x68\x69\x6e\x65','\x76\x53\x45\x44\x58':'\x6d\x61\x6e\x69\x66\x65\x73\x74','\x4b\x62\x68\x61\x54':_0x2ef0e5(0x12c),'\x6a\x6a\x6d\x41\x5a':'\x69\x6e\x74\x65\x6c\x6c\x69\x67\x65\x6e\x63\x65','\x4a\x58\x69\x68\x70':_0x2ef0e5(0x1a3),'\x61\x46\x4e\x55\x46':function(_0x45311c,_0x4bedfd,_0x4c1700){return _0x45311c(_0x4bedfd,_0x4c1700);},'\x45\x4f\x74\x75\x45':_0x2ef0e5(0x15c),'\x4b\x63\x6d\x53\x59':_0x2ef0e5(0x17d),'\x59\x6a\x4b\x69\x6f':function(_0x32f75f,_0x1af73c){return _0x32f75f(_0x1af73c);}};return{'\x6e\x61\x6d\x65':MANAGE_SANDBOXES_TOOL_NAME,'\x64\x65\x73\x63\x72\x69\x70\x74\x69\x6f\x6e':_0x2ef0e5(0x95),'\x70\x61\x72\x61\x6d\x65\x74\x65\x72\x73':MANAGE_SANDBOXES_PARAMETERS,async '\x65\x78\x65\x63\x75\x74\x65'(_0x375468){const _0x4ee43b=_0x2ef0e5;switch(_0x375468['\x61\x63\x74\x69\x6f\x6e']){case _0x4ee43b(0x11b):return _0x5734ec['\x66\x6c\x65\x65\x74\x73'][_0x4ee43b(0x11b)]();case _0x4ee43b(0x150):return _0x5734ec[_0x4ee43b(0x177)]['\x63\x72\x65\x61\x74\x65'](_0x5a7bc9[_0x4ee43b(0xe4)](applyToolPolicy,_0x5a7bc9[_0x4ee43b(0x10c)](requireCreateOptions,_0x375468),_0x551cd2['\x70\x6f\x6c\x69\x63\x79']));case _0x5a7bc9[_0x4ee43b(0xdb)]:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x75)](_0x5a7bc9[_0x4ee43b(0xe4)](applyToolPolicy,requireCreateWithCoordinatorOptions(_0x375468),_0x551cd2[_0x4ee43b(0x12a)]));case _0x5a7bc9['\x6b\x6c\x58\x52\x66']:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x87)]({'\x66\x6c\x65\x65\x74\x49\x64':_0x5a7bc9[_0x4ee43b(0xe4)](requireString,_0x375468,'\x66\x6c\x65\x65\x74\x49\x64')});case _0x5a7bc9[_0x4ee43b(0x1e7)]:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0xcb)](requireString(_0x375468,_0x5a7bc9[_0x4ee43b(0xce)]));case _0x5a7bc9[_0x4ee43b(0x12d)]:return _0x5734ec[_0x4ee43b(0x177)]['\x61\x74\x74\x61\x63\x68\x4d\x61\x63\x68\x69\x6e\x65'](requireString(_0x375468,'\x66\x6c\x65\x65\x74\x49\x64'),_0x5a7bc9['\x52\x78\x6b\x43\x63'](requireMachine,_0x375468));case'\x64\x65\x74\x61\x63\x68\x4d\x61\x63\x68\x69\x6e\x65':return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x1f0)](requireString(_0x375468,_0x5a7bc9['\x57\x45\x4c\x75\x6f']),_0x5a7bc9[_0x4ee43b(0xe4)](requireString,_0x375468,_0x4ee43b(0x13b)));case _0x5a7bc9['\x76\x53\x45\x44\x58']:return _0x5734ec[_0x4ee43b(0x177)]['\x6d\x61\x6e\x69\x66\x65\x73\x74'](requireString(_0x375468,_0x5a7bc9[_0x4ee43b(0xce)]));case _0x5a7bc9['\x4b\x62\x68\x61\x54']:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x12c)](requireString(_0x375468,_0x4ee43b(0xe7)));case'\x74\x72\x61\x63\x65':return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x77)](requireString(_0x375468,_0x4ee43b(0xe7)));case _0x5a7bc9[_0x4ee43b(0x122)]:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0xed)](requireString(_0x375468,_0x4ee43b(0xe7)));case _0x5a7bc9[_0x4ee43b(0xd5)]:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x1a3)](_0x5a7bc9[_0x4ee43b(0xbc)](requireString,_0x375468,_0x5a7bc9[_0x4ee43b(0xce)]));case _0x5a7bc9[_0x4ee43b(0x1e8)]:return _0x5734ec['\x66\x6c\x65\x65\x74\x73']['\x63\x72\x65\x61\x74\x65\x57\x6f\x72\x6b\x73\x70\x61\x63\x65\x53\x6e\x61\x70\x73\x68\x6f\x74'](requireString(_0x375468,_0x4ee43b(0xe7)));case _0x5a7bc9['\x4b\x63\x6d\x53\x59']:return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0x17d)](requireString(_0x375468,_0x4ee43b(0xe7)),_0x5a7bc9[_0x4ee43b(0xbc)](requireString,_0x375468,_0x4ee43b(0xc2)));case _0x4ee43b(0xbe):return _0x5734ec[_0x4ee43b(0x177)][_0x4ee43b(0xbe)](requireString(_0x375468,'\x66\x6c\x65\x65\x74\x49\x64'));default:throw new Error(_0x4ee43b(0x19d)+_0x5a7bc9[_0x4ee43b(0x1d6)](String,_0x375468[_0x4ee43b(0x12b)]));}}};}function requireString(_0x212ec5,_0xc4a713){const _0x55c1e2=a0_0x5244d4,_0x23270b={'\x53\x4c\x4f\x71\x47':function(_0x24da63,_0x3809e0){return _0x24da63!==_0x3809e0;},'\x6d\x74\x46\x51\x61':'\x73\x74\x72\x69\x6e\x67'},_0x50cf95=_0x212ec5[_0xc4a713];if(_0x23270b[_0x55c1e2(0xbb)](typeof _0x50cf95,_0x23270b[_0x55c1e2(0xd2)])||_0x50cf95[_0x55c1e2(0x137)]===0x0)throw new Error('\x6d\x61\x6e\x61\x67\x65\x53\x61\x6e\x64\x62\x6f\x78\x65\x73\x20\x72\x65\x71\x75\x69\x72\x65\x73\x20'+_0xc4a713);return _0x50cf95;}function requireCreateOptions(_0x53953e){const _0x2dd820=a0_0x5244d4,_0xe1f0c3={'\x7a\x67\x53\x6b\x41':function(_0x2db214,_0x26655e){return _0x2db214!==_0x26655e;}},_0x8842e0=_0x53953e['\x6f\x70\x74\x69\x6f\x6e\x73'];if(!_0x8842e0||_0xe1f0c3[_0x2dd820(0x135)](typeof _0x8842e0,_0x2dd820(0x149)))throw new Error(_0x2dd820(0x15a));return rejectUserPolicy(_0x8842e0);}function requireCreateWithCoordinatorOptions(_0x30aa39){const _0x47ab7=a0_0x5244d4,_0x21bb98={'\x46\x55\x4a\x62\x53':'\x6f\x62\x6a\x65\x63\x74'},_0x456490=_0x30aa39[_0x47ab7(0x15b)];if(!_0x456490||typeof _0x456490!==_0x21bb98[_0x47ab7(0xe9)])throw new Error(_0x47ab7(0x15a));return rejectUserPolicy(_0x456490);}function rejectUserPolicy(_0x5d06a5){const _0x2ffcc5=a0_0x5244d4,_0x302fda={'\x68\x66\x42\x55\x47':function(_0x4431cd,_0x463c0f){return _0x4431cd in _0x463c0f;},'\x66\x4b\x6c\x52\x49':_0x2ffcc5(0x12a),'\x62\x74\x67\x62\x67':function(_0x2e3fb5,_0x4c5895){return _0x2e3fb5!==_0x4c5895;}};if(_0x302fda[_0x2ffcc5(0x18c)](_0x302fda[_0x2ffcc5(0x154)],_0x5d06a5)&&_0x302fda[_0x2ffcc5(0x13f)](_0x5d06a5['\x70\x6f\x6c\x69\x63\x79'],void 0x0))throw new Error(_0x2ffcc5(0x8d));return _0x5d06a5;}function applyToolPolicy(_0xbcf12d,_0xa192bc){const _0x42d566=a0_0x5244d4;if(!_0xa192bc)throw new Error(_0x42d566(0xf5));return{..._0xbcf12d,'\x70\x6f\x6c\x69\x63\x79':_0xa192bc};}function requireMachine(_0x589dcd){const _0x342524=a0_0x5244d4,_0x5b7cf0={'\x74\x6d\x5a\x6e\x79':_0x342524(0x13b),'\x62\x68\x4c\x51\x41':function(_0x3705d8,_0x4f8de8,_0xa0cd6){return _0x3705d8(_0x4f8de8,_0xa0cd6);}},_0x474bc4=_0x589dcd[_0x342524(0x1d7)];if(!_0x474bc4||typeof _0x474bc4!=='\x6f\x62\x6a\x65\x63\x74')throw new Error(_0x342524(0x145));const _0x52650b=_0x474bc4;return requireString(_0x52650b,_0x5b7cf0[_0x342524(0x83)]),_0x5b7cf0[_0x342524(0xec)](requireString,_0x52650b,_0x342524(0x9f)),_0x474bc4;}const fleetId={'\x74\x79\x70\x65':'\x73\x74\x72\x69\x6e\x67','\x70\x61\x74\x74\x65\x72\x6e':a0_0x5244d4(0x18b)},MANAGE_SANDBOXES_PARAMETERS={'\x74\x79\x70\x65':'\x6f\x62\x6a\x65\x63\x74','\x61\x64\x64\x69\x74\x69\x6f\x6e\x61\x6c\x50\x72\x6f\x70\x65\x72\x74\x69\x65\x73':![],'\x72\x65\x71\x75\x69\x72\x65\x64':['\x61\x63\x74\x69\x6f\x6e'],'\x70\x72\x6f\x70\x65\x72\x74\x69\x65\x73':{'\x61\x63\x74\x69\x6f\x6e':{'\x74\x79\x70\x65':a0_0x5244d4(0xa5),'\x65\x6e\x75\x6d':[a0_0x5244d4(0x11b),a0_0x5244d4(0x150),a0_0x5244d4(0x75),a0_0x5244d4(0x87),a0_0x5244d4(0xcb),a0_0x5244d4(0x1de),a0_0x5244d4(0x1f0),a0_0x5244d4(0xd1),a0_0x5244d4(0x12c),a0_0x5244d4(0x77),'\x69\x6e\x74\x65\x6c\x6c\x69\x67\x65\x6e\x63\x65',a0_0x5244d4(0x1a3),a0_0x5244d4(0x15c),'\x72\x65\x73\x74\x6f\x72\x65\x57\x6f\x72\x6b\x73\x70\x61\x63\x65\x53\x6e\x61\x70\x73\x68\x6f\x74',a0_0x5244d4(0xbe)]},'\x66\x6c\x65\x65\x74\x49\x64':fleetId,'\x6d\x61\x63\x68\x69\x6e\x65\x49\x64':fleetId,'\x73\x6e\x61\x70\x73\x68\x6f\x74\x49\x64':{'\x74\x79\x70\x65':a0_0x5244d4(0xa5),'\x6d\x69\x6e\x4c\x65\x6e\x67\x74\x68':0x1},'\x6f\x70\x74\x69\x6f\x6e\x73':{'\x74\x79\x70\x65':a0_0x5244d4(0x149)},'\x6d\x61\x63\x68\x69\x6e\x65':{'\x74\x79\x70\x65':'\x6f\x62\x6a\x65\x63\x74','\x72\x65\x71\x75\x69\x72\x65\x64':[a0_0x5244d4(0x13b),'\x73\x61\x6e\x64\x62\x6f\x78\x49\x64'],'\x61\x64\x64\x69\x74\x69\x6f\x6e\x61\x6c\x50\x72\x6f\x70\x65\x72\x74\x69\x65\x73':!![],'\x70\x72\x6f\x70\x65\x72\x74\x69\x65\x73':{'\x6d\x61\x63\x68\x69\x6e\x65\x49\x64':fleetId,'\x73\x61\x6e\x64\x62\x6f\x78\x49\x64':{'\x74\x79\x70\x65':a0_0x5244d4(0xa5),'\x6d\x69\x6e\x4c\x65\x6e\x67\x74\x68':0x1,'\x6d\x61\x78\x4c\x65\x6e\x67\x74\x68':0x80}}}}},SANDBOX_MCP_SERVER_NAME=a0_0x5244d4(0xa4);function a0_0x43aa(_0x19b7b6,_0x5edaf4){_0x19b7b6=_0x19b7b6-0x71;const _0x3d797b=a0_0x3d79();let _0x43aa33=_0x3d797b[_0x19b7b6];if(a0_0x43aa['\x54\x77\x6a\x4e\x50\x44']===undefined){var _0x433ed0=function(_0x11dc30){const _0x1d44f6='\x61\x62\x63\x64\x65\x66\x67\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f\x70\x71\x72\x73\x74\x75\x76\x77\x78\x79\x7a\x41\x42\x43\x44\x45\x46\x47\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f\x50\x51\x52\x53\x54\x55\x56\x57\x58\x59\x5a\x30\x31\x32\x33\x34\x35\x36\x37\x38\x39\x2b\x2f\x3d';let _0x3b8bc6='',_0x1104c7='';for(let _0x5278e1=0x0,_0x4d4409,_0x15224e,_0x517caf=0x0;_0x15224e=_0x11dc30['\x63\x68\x61\x72\x41\x74'](_0x517caf++);~_0x15224e&&(_0x4d4409=_0x5278e1%0x4?_0x4d4409*0x40+_0x15224e:_0x15224e,_0x5278e1++%0x4)?_0x3b8bc6+=String['\x66\x72\x6f\x6d\x43\x68\x61\x72\x43\x6f\x64\x65'](0xff&_0x4d4409>>(-0x2*_0x5278e1&0x6)):0x0){_0x15224e=_0x1d44f6['\x69\x6e\x64\x65\x78\x4f\x66'](_0x15224e);}for(let _0x1d0eae=0x0,_0x101652=_0x3b8bc6['\x6c\x65\x6e\x67\x74\x68'];_0x1d0eae<_0x101652;_0x1d0eae++){_0x1104c7+='\x25'+('\x30\x30'+_0x3b8bc6['\x63\x68\x61\x72\x43\x6f\x64\x65\x41\x74'](_0x1d0eae)['\x74\x6f\x53\x74\x72\x69\x6e\x67'](0x10))['\x73\x6c\x69\x63\x65'](-0x2);}return decodeURIComponent(_0x1104c7);};a0_0x43aa['\x69\x61\x77\x58\x6d\x58']=_0x433ed0,a0_0x43aa['\x6d\x6d\x49\x55\x56\x43']={},a0_0x43aa['\x54\x77\x6a\x4e\x50\x44']=!![];}const _0x32f975=_0x3d797b[0x0],_0x55b288=_0x19b7b6+_0x32f975,_0x22d15e=a0_0x43aa['\x6d\x6d\x49\x55\x56\x43'][_0x55b288];return!_0x22d15e?(_0x43aa33=a0_0x43aa['\x69\x61\x77\x58\x6d\x58'](_0x43aa33),a0_0x43aa['\x6d\x6d\x49\x55\x56\x43'][_0x55b288]=_0x43aa33):_0x43aa33=_0x22d15e,_0x43aa33;}function buildSandboxMcpConfig(_0x1725e4){const _0x3a0820=a0_0x5244d4,_0x23bf16={'\x48\x47\x6d\x6f\x7a':_0x3a0820(0x91)};if(!_0x1725e4[_0x3a0820(0x14c)])throw new Error(_0x3a0820(0x157));if(!_0x1725e4[_0x3a0820(0xfd)])throw new Error(_0x23bf16['\x48\x47\x6d\x6f\x7a']);const _0x117f80=_0x1725e4['\x73\x65\x72\x76\x65\x72\x4e\x61\x6d\x65']??'\x74\x61\x6e\x67\x6c\x65\x2d\x73\x61\x6e\x64\x62\x6f\x78',_0x774edd=_0x1725e4[_0x3a0820(0x14c)][_0x3a0820(0x1b4)](/\/+$/,'');return{'\x73\x65\x72\x76\x65\x72\x4e\x61\x6d\x65':_0x117f80,'\x63\x6f\x6e\x66\x69\x67':{'\x6d\x63\x70\x53\x65\x72\x76\x65\x72\x73':{[_0x117f80]:{'\x74\x79\x70\x65':_0x3a0820(0xae),'\x75\x72\x6c':_0x774edd+_0x3a0820(0x84),'\x68\x65\x61\x64\x65\x72\x73':{'\x41\x75\x74\x68\x6f\x72\x69\x7a\x61\x74\x69\x6f\x6e':_0x3a0820(0xd4)+_0x1725e4[_0x3a0820(0xfd)]}}}}};}const CONTROL_PLANE_MCP_SERVER_NAME=a0_0x5244d4(0xa3);function buildControlPlaneMcpConfig(_0x26f566){const _0x56c5d7=a0_0x5244d4,_0x232c46={'\x51\x41\x6c\x42\x58':_0x56c5d7(0xa8),'\x4d\x55\x77\x71\x6f':'\x74\x61\x6e\x67\x6c\x65\x2d\x63\x6f\x6e\x74\x72\x6f\x6c\x2d\x70\x6c\x61\x6e\x65','\x42\x42\x49\x57\x53':_0x56c5d7(0xae)};if(!_0x26f566[_0x56c5d7(0x171)])throw new Error('\x62\x75\x69\x6c\x64\x43\x6f\x6e\x74\x72\x6f\x6c\x50\x6c\x61\x6e\x65\x4d\x63\x70\x43\x6f\x6e\x66\x69\x67\x3a\x20\x70\x6c\x61\x74\x66\x6f\x72\x6d\x55\x72\x6c\x20\x69\x73\x20\x72\x65\x71\x75\x69\x72\x65\x64');if(!_0x26f566['\x61\x70\x69\x4b\x65\x79'])throw new Error(_0x232c46[_0x56c5d7(0xe5)]);const _0x1f7a15=_0x26f566[_0x56c5d7(0x15f)]??_0x232c46[_0x56c5d7(0x1ab)],_0x3ba929=_0x26f566[_0x56c5d7(0x171)][_0x56c5d7(0x1b4)](/\/+$/,'');return{'\x73\x65\x72\x76\x65\x72\x4e\x61\x6d\x65':_0x1f7a15,'\x63\x6f\x6e\x66\x69\x67':{'\x6d\x63\x70\x53\x65\x72\x76\x65\x72\x73':{[_0x1f7a15]:{'\x74\x79\x70\x65':_0x232c46[_0x56c5d7(0xcf)],'\x75\x72\x6c':_0x3ba929+_0x56c5d7(0x84),'\x68\x65\x61\x64\x65\x72\x73':{'\x41\x75\x74\x68\x6f\x72\x69\x7a\x61\x74\x69\x6f\x6e':_0x56c5d7(0xd4)+_0x26f566['\x61\x70\x69\x4b\x65\x79']}}}}};}const DEFAULT_ROUTER_URL=a0_0x5244d4(0xd9);async function fetchTangleRouterSearchConfig(_0x5c5356={}){const _0x3058a8=a0_0x5244d4,_0x4ee5ce={'\x7a\x4f\x6c\x75\x51':_0x3058a8(0x118),'\x7a\x4a\x76\x45\x63':_0x3058a8(0x112),'\x73\x67\x63\x79\x6c':_0x3058a8(0x1c2)},_0x4541a6=(_0x5c5356['\x72\x6f\x75\x74\x65\x72\x55\x72\x6c']??DEFAULT_ROUTER_URL)[_0x3058a8(0x1b4)](/\/+$/,''),_0x793124=new URL(_0x4541a6+_0x3058a8(0xc9));if(_0x5c5356[_0x3058a8(0x118)])_0x793124[_0x3058a8(0x183)][_0x3058a8(0x1c5)](_0x4ee5ce[_0x3058a8(0x1e9)],_0x5c5356[_0x3058a8(0x118)]);if(_0x5c5356[_0x3058a8(0x126)])_0x793124[_0x3058a8(0x183)][_0x3058a8(0x1c5)](_0x4ee5ce['\x7a\x4a\x76\x45\x63'],_0x5c5356[_0x3058a8(0x126)]);if(_0x5c5356[_0x3058a8(0x141)])_0x793124[_0x3058a8(0x183)][_0x3058a8(0x1c5)]('\x6d\x6f\x64\x65\x6c',_0x5c5356['\x6d\x6f\x64\x65\x6c']);const _0x4e3c94=await(_0x5c5356[_0x3058a8(0x1e1)]??fetch)(_0x793124);if(!_0x4e3c94['\x6f\x6b'])throw new Error(_0x3058a8(0xf7)+_0x4e3c94[_0x3058a8(0x152)]);const _0x5e5d4b=await _0x4e3c94[_0x3058a8(0x12e)]();if(_0x5e5d4b[_0x3058a8(0x149)]!==_0x4ee5ce[_0x3058a8(0x143)])throw new Error(_0x3058a8(0xd0));return _0x5e5d4b;}function buildTangleRouterSearchProfile(_0x616ddd,_0x4c0e22={}){const _0x1d76fc=a0_0x5244d4,_0x157548={'\x4b\x61\x66\x67\x55':_0x1d76fc(0xd8),'\x41\x58\x77\x7a\x68':_0x1d76fc(0xae)};return{'\x6e\x61\x6d\x65':_0x4c0e22[_0x1d76fc(0x196)]??_0x157548[_0x1d76fc(0x1ca)],'\x6d\x6f\x64\x65\x6c':{'\x64\x65\x66\x61\x75\x6c\x74':_0x4c0e22[_0x1d76fc(0x141)]??_0x616ddd[_0x1d76fc(0x19e)]['\x73\x61\x6e\x64\x62\x6f\x78\x42\x61\x63\x6b\x65\x6e\x64'][_0x1d76fc(0x141)][_0x1d76fc(0x141)]},'\x70\x65\x72\x6d\x69\x73\x73\x69\x6f\x6e\x73':{'\x6e\x65\x74\x77\x6f\x72\x6b':_0x1d76fc(0x17f),'\x6d\x63\x70':_0x1d76fc(0x17f)},'\x6d\x63\x70':{'\x74\x61\x6e\x67\x6c\x65\x5f\x77\x65\x62\x5f\x73\x65\x61\x72\x63\x68':{'\x74\x72\x61\x6e\x73\x70\x6f\x72\x74':_0x157548[_0x1d76fc(0x1e6)],'\x75\x72\x6c':_0x616ddd[_0x1d76fc(0x8f)][_0x1d76fc(0x7c)],'\x68\x65\x61\x64\x65\x72\x73':_0x616ddd[_0x1d76fc(0x8f)]['\x68\x65\x61\x64\x65\x72\x73'],'\x65\x6e\x61\x62\x6c\x65\x64':!![]}},'\x6d\x65\x74\x61\x64\x61\x74\x61':{'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72\x53\x65\x61\x72\x63\x68\x50\x72\x6f\x76\x69\x64\x65\x72':_0x616ddd['\x64\x65\x66\x61\x75\x6c\x74\x5f\x70\x72\x6f\x76\x69\x64\x65\x72'],'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72\x53\x65\x61\x72\x63\x68\x45\x6e\x64\x70\x6f\x69\x6e\x74':_0x616ddd[_0x1d76fc(0x189)][_0x1d76fc(0x1c9)]}};}function buildTangleRouterSearchBackend(_0x32d0ca,_0x2515d7={}){const _0x150770=a0_0x5244d4,_0x50e7a4={'\x4b\x48\x63\x75\x4f':'\x6f\x70\x65\x6e\x63\x6f\x64\x65','\x6d\x62\x54\x43\x72':function(_0x45da9d,_0x46380a){return _0x45da9d(_0x46380a);}},_0x5c4bda=_0x32d0ca['\x74\x63\x6c\x6f\x75\x64'][_0x150770(0x105)]['\x6d\x6f\x64\x65\x6c'];return{'\x74\x79\x70\x65':_0x2515d7[_0x150770(0x1a8)]??_0x50e7a4['\x4b\x48\x63\x75\x4f'],'\x70\x72\x6f\x66\x69\x6c\x65':_0x2515d7[_0x150770(0x1bf)]??_0x50e7a4[_0x150770(0x162)](buildTangleRouterSearchProfile,_0x32d0ca),'\x6d\x6f\x64\x65\x6c':{'\x70\x72\x6f\x76\x69\x64\x65\x72':_0x5c4bda['\x70\x72\x6f\x76\x69\x64\x65\x72'],'\x6d\x6f\x64\x65\x6c':_0x5c4bda[_0x150770(0x141)],'\x62\x61\x73\x65\x55\x72\x6c':_0x5c4bda['\x62\x61\x73\x65\x55\x72\x6c'],..._0x2515d7[_0x150770(0x1a1)]?{'\x61\x70\x69\x4b\x65\x79':_0x2515d7['\x61\x70\x69\x4b\x65\x79']}:{}}};}function buildTangleRouterEvalMatrixRequest(_0x12f9d2,_0x32ae66={}){const _0xab2b08=a0_0x5244d4;return{'\x75\x72\x6c':_0x12f9d2['\x65\x76\x61\x6c\x5f\x6d\x61\x74\x72\x69\x78'][_0xab2b08(0x1c9)],'\x62\x6f\x64\x79':{..._0x12f9d2[_0xab2b08(0xa6)][_0xab2b08(0xb5)],..._0x32ae66}};}function buildTangleRouterResponsesWebSearchRequest(_0x14d167,_0x5bb249={}){const _0x4d6b63=a0_0x5244d4,_0x28d74f={'\x6d\x63\x59\x52\x52':'\x53\x65\x61\x72\x63\x68\x20\x66\x6f\x72\x20\x74\x68\x65\x20\x6c\x61\x74\x65\x73\x74\x20\x64\x6f\x63\x75\x6d\x65\x6e\x74\x61\x74\x69\x6f\x6e\x20\x61\x6e\x64\x20\x61\x6e\x73\x77\x65\x72\x20\x77\x69\x74\x68\x20\x63\x69\x74\x61\x74\x69\x6f\x6e\x73\x2e','\x6a\x46\x74\x77\x58':_0x4d6b63(0x1b6)},_0x14f9ad=_0x14d167['\x6f\x70\x65\x6e\x72\x6f\x75\x74\x65\x72\x5f\x63\x6f\x6d\x70\x61\x74']?.['\x72\x65\x73\x70\x6f\x6e\x73\x65\x73'];if(_0x14f9ad)return{'\x75\x72\x6c':_0x14f9ad['\x75\x72\x6c'],'\x62\x6f\x64\x79':{..._0x14f9ad[_0x4d6b63(0x132)],..._0x5bb249}};const _0x3bb642=_0x14d167[_0x4d6b63(0x19e)][_0x4d6b63(0x105)][_0x4d6b63(0x141)];return{'\x75\x72\x6c':_0x3bb642[_0x4d6b63(0x80)][_0x4d6b63(0x1b4)](/\/+$/,'')+'\x2f\x72\x65\x73\x70\x6f\x6e\x73\x65\x73','\x62\x6f\x64\x79':{'\x6d\x6f\x64\x65\x6c':_0x3bb642[_0x4d6b63(0x141)],'\x69\x6e\x70\x75\x74':_0x28d74f[_0x4d6b63(0x128)],'\x74\x6f\x6f\x6c\x73':[{'\x74\x79\x70\x65':_0x28d74f[_0x4d6b63(0x10e)],'\x70\x61\x72\x61\x6d\x65\x74\x65\x72\x73':{'\x70\x72\x6f\x76\x69\x64\x65\x72':_0x14d167['\x64\x65\x66\x61\x75\x6c\x74\x5f\x70\x72\x6f\x76\x69\x64\x65\x72'],'\x6d\x61\x78\x5f\x72\x65\x73\x75\x6c\x74\x73':0x5}}],..._0x5bb249}};}async function runTangleRouterEvalMatrixInSandbox(_0x491c60){const _0x2b2e25=a0_0x5244d4,_0x5d0b54={'\x46\x4b\x4a\x66\x70':_0x2b2e25(0x1d3),'\x6e\x6a\x49\x7a\x71':function(_0x1e6b06,_0x4ead68){return _0x1e6b06(_0x4ead68);}},_0x5a8659=_0x491c60['\x66\x65\x74\x63\x68\x49\x6d\x70\x6c']??fetch,_0xde6d68=buildTangleRouterEvalMatrixRequest(_0x491c60[_0x2b2e25(0x17a)],{'\x74\x72\x61\x6e\x73\x70\x6f\x72\x74':_0x5d0b54['\x46\x4b\x4a\x66\x70'],..._0x491c60[_0x2b2e25(0x1ef)]}),_0x3ba2ae=await postJson(_0x5a8659,_0xde6d68[_0x2b2e25(0x1c9)],_0x491c60['\x61\x70\x69\x4b\x65\x79'],_0xde6d68[_0x2b2e25(0x132)]),_0x1ff94e=_0x3ba2ae['\x6d\x61\x74\x72\x69\x78'],_0x61a309=await runMatrixCases({'\x6d\x61\x74\x72\x69\x78':_0x1ff94e,'\x63\x6f\x6e\x66\x69\x67':_0x491c60[_0x2b2e25(0x17a)],'\x61\x70\x69\x4b\x65\x79':_0x491c60[_0x2b2e25(0x1a1)],'\x73\x61\x6e\x64\x62\x6f\x78\x43\x6c\x69\x65\x6e\x74':_0x491c60[_0x2b2e25(0xac)],'\x63\x6f\x6e\x63\x75\x72\x72\x65\x6e\x63\x79':_0x491c60[_0x2b2e25(0x121)]??0x3,'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64\x50\x72\x65\x66\x69\x78':_0x491c60[_0x2b2e25(0x14d)]??_0x2b2e25(0xf6)+_0x3ba2ae[_0x2b2e25(0x1a7)]['\x69\x64']}),_0x162220=await postJson(_0x5a8659,_0xde6d68[_0x2b2e25(0x1c9)][_0x2b2e25(0x1b4)](/\/api\/eval\/matrix$/,'')+'\x2f\x61\x70\x69\x2f\x65\x76\x61\x6c\x2f\x73\x75\x69\x74\x65\x73\x2f'+_0x5d0b54[_0x2b2e25(0x1ea)](encodeURIComponent,String(_0x3ba2ae[_0x2b2e25(0x1a7)]['\x69\x64']))+_0x2b2e25(0x74),_0x491c60[_0x2b2e25(0x1a1)],{'\x62\x61\x73\x65\x6c\x69\x6e\x65':_0x491c60[_0x2b2e25(0xb7)]===!![],'\x63\x61\x73\x65\x73':_0x61a309});return{'\x73\x75\x69\x74\x65':_0x3ba2ae[_0x2b2e25(0x1a7)],'\x6d\x61\x74\x72\x69\x78':_0x1ff94e,'\x63\x61\x73\x65\x73':_0x61a309,'\x62\x65\x6e\x63\x68\x6d\x61\x72\x6b':_0x162220[_0x2b2e25(0x103)]??[],'\x69\x6d\x70\x6f\x72\x74\x52\x65\x73\x75\x6c\x74':_0x162220};}async function runMatrixCases(_0x45ab60){const _0x4b0d9e=a0_0x5244d4,_0x5495a2={'\x72\x43\x4f\x46\x4c':function(_0xe768ee,_0x117249,_0xf820b2){return _0xe768ee(_0x117249,_0xf820b2);}},_0x125efc=new Map(_0x45ab60[_0x4b0d9e(0x142)][_0x4b0d9e(0x1f1)][_0x4b0d9e(0xb1)](_0x4e0b3a=>[_0x4e0b3a['\x69\x64'],_0x4e0b3a])),_0x4ef30f=new Map(_0x45ab60[_0x4b0d9e(0x142)]['\x68\x61\x72\x6e\x65\x73\x73\x65\x73'][_0x4b0d9e(0xb1)](_0x2ccf7b=>[_0x2ccf7b['\x69\x64'],_0x2ccf7b])),_0x10731c=Math['\x6d\x61\x78'](0x1,Math[_0x4b0d9e(0x1d8)](0xa,_0x45ab60['\x6d\x61\x74\x72\x69\x78'][_0x4b0d9e(0x1b0)]??0x1)),_0x29e889=[];for(let _0x547667=0x0;_0x547667<_0x10731c;_0x547667++)for(const _0x49bb19 of _0x45ab60[_0x4b0d9e(0x142)]['\x73\x63\x65\x6e\x61\x72\x69\x6f\x73'])_0x29e889[_0x4b0d9e(0xc8)](()=>runOneCase({'\x73\x63\x65\x6e\x61\x72\x69\x6f':_0x49bb19,'\x69\x74\x65\x72\x61\x74\x69\x6f\x6e':_0x547667,'\x70\x72\x6f\x66\x69\x6c\x65':_0x49bb19[_0x4b0d9e(0x1bf)]?_0x125efc['\x67\x65\x74'](_0x49bb19['\x70\x72\x6f\x66\x69\x6c\x65']):void 0x0,'\x68\x61\x72\x6e\x65\x73\x73':_0x49bb19[_0x4b0d9e(0x1b8)]?_0x4ef30f[_0x4b0d9e(0x127)](_0x49bb19['\x68\x61\x72\x6e\x65\x73\x73']):void 0x0,'\x63\x6f\x6e\x66\x69\x67':_0x45ab60[_0x4b0d9e(0x17a)],'\x61\x70\x69\x4b\x65\x79':_0x45ab60[_0x4b0d9e(0x1a1)],'\x73\x61\x6e\x64\x62\x6f\x78\x43\x6c\x69\x65\x6e\x74':_0x45ab60[_0x4b0d9e(0xac)],'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64\x50\x72\x65\x66\x69\x78':_0x45ab60['\x73\x65\x73\x73\x69\x6f\x6e\x49\x64\x50\x72\x65\x66\x69\x78']}));return _0x5495a2[_0x4b0d9e(0x119)](parallelLimit,_0x29e889,_0x45ab60['\x63\x6f\x6e\x63\x75\x72\x72\x65\x6e\x63\x79']);}async function runOneCase(_0x515bf7){const _0x342c6e=a0_0x5244d4,_0x5570ec={'\x57\x6a\x50\x4c\x63':function(_0x56516c,_0xf02316){return _0x56516c(_0xf02316);},'\x53\x4a\x49\x51\x4a':function(_0x291ea3,_0x15d66d,_0x3df7af,_0x7ac2f0,_0x531acf){return _0x291ea3(_0x15d66d,_0x3df7af,_0x7ac2f0,_0x531acf);},'\x42\x55\x48\x51\x41':function(_0x5e6e9f,_0x4f0e1b){return _0x5e6e9f(_0x4f0e1b);},'\x79\x46\x79\x69\x64':function(_0x77baa5,_0x12701e){return _0x77baa5-_0x12701e;},'\x61\x48\x6f\x44\x77':function(_0x267fd2,_0x50e424,_0xc4d66,_0x174bee){return _0x267fd2(_0x50e424,_0xc4d66,_0x174bee);},'\x6b\x6d\x79\x48\x4a':function(_0x6885c7,_0x2d9937){return _0x6885c7(_0x2d9937);}},_0x40e1da=Date[_0x342c6e(0x11f)](),_0x42c5b1=buildSandboxBackend(_0x515bf7),_0x5ed14d=await _0x515bf7['\x73\x61\x6e\x64\x62\x6f\x78\x43\x6c\x69\x65\x6e\x74']['\x63\x72\x65\x61\x74\x65']({'\x6e\x61\x6d\x65':_0x342c6e(0xdd)+safeId(_0x515bf7['\x73\x63\x65\x6e\x61\x72\x69\x6f']['\x69\x64'])[_0x342c6e(0xe6)](0x0,0x28),'\x65\x6e\x76\x69\x72\x6f\x6e\x6d\x65\x6e\x74':_0x515bf7[_0x342c6e(0x1b8)]?.['\x69\x6d\x61\x67\x65'],'\x69\x6d\x61\x67\x65':_0x515bf7[_0x342c6e(0x1b8)]?.[_0x342c6e(0x9d)],'\x62\x61\x63\x6b\x65\x6e\x64':_0x42c5b1,'\x65\x6e\x76':materializeHarnessEnv(_0x515bf7[_0x342c6e(0x17a)],_0x515bf7['\x68\x61\x72\x6e\x65\x73\x73']?.[_0x342c6e(0x155)],_0x515bf7[_0x342c6e(0x1a1)]),..._0x515bf7[_0x342c6e(0x1b8)]?.['\x67\x69\x74\x52\x65\x70\x6f']?{'\x67\x69\x74':{'\x75\x72\x6c':_0x515bf7['\x68\x61\x72\x6e\x65\x73\x73']['\x67\x69\x74\x52\x65\x70\x6f'],'\x72\x65\x66':_0x515bf7['\x68\x61\x72\x6e\x65\x73\x73'][_0x342c6e(0x13d)]}}:{}}),_0x4148a9=safeId(_0x515bf7[_0x342c6e(0x14d)])+'\x5f'+_0x5570ec[_0x342c6e(0x10b)](safeId,_0x515bf7['\x73\x63\x65\x6e\x61\x72\x69\x6f']['\x69\x64'])+'\x5f'+_0x515bf7[_0x342c6e(0x1d2)];try{const _0x3e5b28=await _0x5ed14d[_0x342c6e(0x76)](_0x515bf7[_0x342c6e(0x1dd)][_0x342c6e(0x7a)],{'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64':_0x4148a9}),_0x295e1e=await _0x5ed14d[_0x342c6e(0xfb)](_0x3e5b28[_0x342c6e(0x18a)])['\x72\x65\x73\x75\x6c\x74'](),_0x543fc5=_0x515bf7[_0x342c6e(0x1dd)]['\x73\x61\x6e\x64\x62\x6f\x78']?.[_0x342c6e(0x1c0)]??_0x515bf7[_0x342c6e(0x1b8)]?.[_0x342c6e(0x1c0)],_0x137539=_0x543fc5&&_0x5ed14d[_0x342c6e(0x1b7)]?await _0x5570ec[_0x342c6e(0x1e3)](runTestCommand,_0x5ed14d,_0x3e5b28[_0x342c6e(0x18a)],_0x543fc5,_0x515bf7[_0x342c6e(0x1b8)]?.['\x74\x69\x6d\x65\x6f\x75\x74']):void 0x0;return _0x5570ec[_0x342c6e(0xc0)](buildCaseResult,{'\x73\x63\x65\x6e\x61\x72\x69\x6f':_0x515bf7['\x73\x63\x65\x6e\x61\x72\x69\x6f'],'\x69\x74\x65\x72\x61\x74\x69\x6f\x6e':_0x515bf7['\x69\x74\x65\x72\x61\x74\x69\x6f\x6e'],'\x70\x72\x6f\x66\x69\x6c\x65':_0x515bf7['\x70\x72\x6f\x66\x69\x6c\x65'],'\x68\x61\x72\x6e\x65\x73\x73':_0x515bf7[_0x342c6e(0x1b8)],'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64':_0x3e5b28['\x73\x65\x73\x73\x69\x6f\x6e\x49\x64'],'\x73\x61\x6e\x64\x62\x6f\x78\x49\x64':_0x5ed14d['\x69\x64'],'\x72\x65\x73\x75\x6c\x74':_0x295e1e,'\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74':_0x137539,'\x64\x75\x72\x61\x74\x69\x6f\x6e\x4d\x73':_0x5570ec[_0x342c6e(0x120)](Date[_0x342c6e(0x11f)](),_0x40e1da),'\x65\x6e\x76':_0x5570ec['\x61\x48\x6f\x44\x77'](materializeHarnessEnv,_0x515bf7[_0x342c6e(0x17a)],_0x515bf7[_0x342c6e(0x1b8)]?.[_0x342c6e(0x155)],_0x515bf7[_0x342c6e(0x1a1)])});}finally{await _0x5570ec[_0x342c6e(0x111)](cleanupBox,_0x5ed14d);}}function buildSandboxBackend(_0x19ce00){const _0x2d4286=a0_0x5244d4,_0x40994b={'\x77\x55\x6e\x52\x50':_0x2d4286(0x17f),'\x52\x67\x70\x74\x6c':function(_0x129216,_0x10ff9a){return _0x129216(_0x10ff9a);}},_0x4ebb89=_0x19ce00['\x63\x6f\x6e\x66\x69\x67'][_0x2d4286(0x19e)][_0x2d4286(0x105)][_0x2d4286(0x141)],_0x325b65=inferSearchProvider(_0x19ce00[_0x2d4286(0x1bf)]),_0x9d9dd={'\x6e\x61\x6d\x65':_0x19ce00[_0x2d4286(0x1bf)]?.[_0x2d4286(0x196)]??_0x19ce00[_0x2d4286(0x1bf)]?.['\x69\x64']??_0x2d4286(0x1a5),'\x6d\x6f\x64\x65\x6c':{'\x64\x65\x66\x61\x75\x6c\x74':_0x19ce00['\x70\x72\x6f\x66\x69\x6c\x65']?.[_0x2d4286(0x141)]??_0x4ebb89[_0x2d4286(0x141)]},'\x70\x65\x72\x6d\x69\x73\x73\x69\x6f\x6e\x73':{'\x6e\x65\x74\x77\x6f\x72\x6b':_0x40994b['\x77\x55\x6e\x52\x50'],'\x6d\x63\x70':_0x2d4286(0x17f)},'\x6d\x63\x70':{'\x74\x61\x6e\x67\x6c\x65\x5f\x77\x65\x62\x5f\x73\x65\x61\x72\x63\x68':{'\x74\x72\x61\x6e\x73\x70\x6f\x72\x74':_0x2d4286(0xae),'\x75\x72\x6c':_0x19ce00['\x63\x6f\x6e\x66\x69\x67']['\x6d\x63\x70'][_0x2d4286(0x7c)],'\x68\x65\x61\x64\x65\x72\x73':_0x19ce00['\x63\x6f\x6e\x66\x69\x67'][_0x2d4286(0x8f)]['\x68\x65\x61\x64\x65\x72\x73'],'\x65\x6e\x61\x62\x6c\x65\x64':_0x325b65!=='\x6f\x66\x66'}},'\x6d\x65\x74\x61\x64\x61\x74\x61':{'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72\x53\x65\x61\x72\x63\x68\x50\x72\x6f\x76\x69\x64\x65\x72':_0x325b65,'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72\x53\x65\x61\x72\x63\x68\x45\x6e\x64\x70\x6f\x69\x6e\x74':_0x19ce00[_0x2d4286(0x17a)][_0x2d4286(0x189)][_0x2d4286(0x1c9)],'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72\x45\x76\x61\x6c\x48\x61\x72\x6e\x65\x73\x73':_0x19ce00[_0x2d4286(0x1b8)]?.['\x69\x64']},'\x65\x78\x74\x65\x6e\x73\x69\x6f\x6e\x73':{'\x74\x61\x6e\x67\x6c\x65\x52\x6f\x75\x74\x65\x72':{'\x70\x72\x6f\x76\x69\x64\x65\x72\x4f\x70\x74\x69\x6f\x6e\x73':_0x19ce00[_0x2d4286(0x1bf)]?.[_0x2d4286(0x138)]}}};return{'\x74\x79\x70\x65':_0x40994b[_0x2d4286(0x146)](backendType,_0x19ce00['\x68\x61\x72\x6e\x65\x73\x73']?.['\x69\x64']),'\x70\x72\x6f\x66\x69\x6c\x65':_0x9d9dd,'\x6d\x6f\x64\x65\x6c':{'\x70\x72\x6f\x76\x69\x64\x65\x72':_0x4ebb89[_0x2d4286(0x118)],'\x6d\x6f\x64\x65\x6c':_0x19ce00['\x70\x72\x6f\x66\x69\x6c\x65']?.[_0x2d4286(0x141)]??_0x4ebb89['\x6d\x6f\x64\x65\x6c'],'\x62\x61\x73\x65\x55\x72\x6c':_0x4ebb89['\x62\x61\x73\x65\x55\x72\x6c'],'\x61\x70\x69\x4b\x65\x79':_0x19ce00[_0x2d4286(0x1a1)]}};}function buildCaseResult(_0xff25e9){const _0x2d540e=a0_0x5244d4,_0x4db3a9={'\x6f\x55\x42\x56\x54':'\x75\x6e\x6b\x6e\x6f\x77\x6e','\x78\x54\x4e\x75\x46':function(_0x258dcc,_0x53917d){return _0x258dcc(_0x53917d);},'\x49\x48\x72\x42\x49':_0x2d540e(0x1da),'\x4e\x6c\x47\x52\x4d':_0x2d540e(0x14a),'\x54\x45\x54\x49\x48':_0x2d540e(0x181)},_0x447b70=_0xff25e9['\x72\x65\x73\x75\x6c\x74'][_0x2d540e(0x12c)],_0x2f3edf=_0xff25e9[_0x2d540e(0x166)][_0x2d540e(0x123)]??_0x2d540e(0x1c6),_0x496abe=_0xff25e9[_0x2d540e(0x166)][_0x2d540e(0x188)]?void 0x0:_0x2f3edf,_0x241ce9=_0xff25e9[_0x2d540e(0x166)]['\x73\x75\x63\x63\x65\x73\x73']&&(_0xff25e9[_0x2d540e(0xe8)]?_0xff25e9[_0x2d540e(0xe8)][_0x2d540e(0xda)]:!![]),_0x38eab4=_0xff25e9['\x73\x63\x65\x6e\x61\x72\x69\x6f'][_0x2d540e(0x103)],_0x282c62=promptToolCalls(_0xff25e9[_0x2d540e(0x166)]);return{'\x73\x63\x65\x6e\x61\x72\x69\x6f\x49\x64':_0xff25e9[_0x2d540e(0x1dd)]['\x69\x64'],'\x70\x72\x6f\x6d\x70\x74':_0xff25e9[_0x2d540e(0x1dd)][_0x2d540e(0x7a)],'\x6d\x6f\x64\x65\x6c':_0xff25e9[_0x2d540e(0x1bf)]?.[_0x2d540e(0x141)]??_0x4db3a9['\x6f\x55\x42\x56\x54'],'\x72\x65\x73\x70\x6f\x6e\x73\x65':_0xff25e9['\x72\x65\x73\x75\x6c\x74'][_0x2d540e(0x14b)]??'','\x74\x69\x6d\x69\x6e\x67':{'\x74\x6f\x74\x61\x6c\x4d\x73':_0xff25e9[_0x2d540e(0xa9)]},'\x74\x6f\x6b\x65\x6e\x73':{'\x69\x6e\x70\x75\x74':_0x447b70?.[_0x2d540e(0x106)]??0x0,'\x6f\x75\x74\x70\x75\x74':_0x447b70?.[_0x2d540e(0x97)]??0x0,'\x63\x61\x63\x68\x65\x64':0x0,'\x72\x65\x61\x73\x6f\x6e\x69\x6e\x67':0x0},'\x63\x6f\x73\x74':_0x4db3a9[_0x2d540e(0xe3)](promptCost,_0xff25e9[_0x2d540e(0x166)]),'\x6a\x75\x64\x67\x65\x43\x6f\x73\x74':0x0,'\x73\x63\x6f\x72\x65':_0x241ce9?0x8:0x1,'\x6a\x75\x64\x67\x65\x52\x65\x61\x73\x6f\x6e\x69\x6e\x67':_0x241ce9?_0x4db3a9[_0x2d540e(0x167)]:_0xff25e9['\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74']&&!_0xff25e9[_0x2d540e(0xe8)][_0x2d540e(0xda)]?'\x53\x61\x6e\x64\x62\x6f\x78\x20\x74\x65\x73\x74\x20\x63\x6f\x6d\x6d\x61\x6e\x64\x20\x66\x61\x69\x6c\x65\x64\x2e':_0x2f3edf,'\x70\x61\x73\x73\x65\x64':_0x241ce9,'\x74\x6f\x6f\x6c\x43\x61\x6c\x6c\x73':_0x282c62,'\x61\x73\x73\x65\x72\x74\x69\x6f\x6e\x73':[{'\x63\x68\x65\x63\x6b':_0x4db3a9[_0x2d540e(0xcd)],'\x70\x61\x73\x73\x65\x64':_0xff25e9[_0x2d540e(0x166)]['\x73\x75\x63\x63\x65\x73\x73']},..._0xff25e9[_0x2d540e(0xe8)]?[{'\x63\x68\x65\x63\x6b':_0x2d540e(0x1a4),'\x70\x61\x73\x73\x65\x64':_0xff25e9['\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74']['\x74\x65\x73\x74\x73\x50\x61\x73\x73\x65\x64']}]:[]],'\x62\x65\x6e\x63\x68\x6d\x61\x72\x6b':{'\x70\x72\x6f\x66\x69\x6c\x65\x49\x64':_0x38eab4?.[_0x2d540e(0x144)]??_0xff25e9[_0x2d540e(0x1bf)]?.['\x69\x64'],'\x68\x61\x72\x6e\x65\x73\x73\x49\x64':_0x38eab4?.[_0x2d540e(0x1db)]??_0xff25e9[_0x2d540e(0x1b8)]?.['\x69\x64'],'\x74\x72\x61\x6e\x73\x70\x6f\x72\x74':_0x38eab4?.[_0x2d540e(0x108)]??_0xff25e9[_0x2d540e(0x1b8)]?.['\x74\x72\x61\x6e\x73\x70\x6f\x72\x74']??_0x2d540e(0x1d3),'\x73\x65\x61\x72\x63\x68\x50\x72\x6f\x76\x69\x64\x65\x72':_0x38eab4?.[_0x2d540e(0x16f)]??inferSearchProvider(_0xff25e9['\x70\x72\x6f\x66\x69\x6c\x65']),'\x73\x65\x61\x72\x63\x68\x52\x65\x71\x75\x65\x73\x74\x73':benchmarkSearchRequests(_0xff25e9[_0x2d540e(0x166)],_0x282c62),'\x63\x69\x74\x61\x74\x69\x6f\x6e\x43\x6f\x75\x6e\x74':benchmarkCitationCount(_0xff25e9['\x72\x65\x73\x75\x6c\x74']),'\x61\x72\x74\x69\x66\x61\x63\x74\x73':{..._0x38eab4?.[_0x2d540e(0x1f5)]??{},'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64':_0xff25e9[_0x2d540e(0x18a)],'\x73\x61\x6e\x64\x62\x6f\x78\x49\x64':_0xff25e9[_0x2d540e(0x9f)],..._0x4db3a9['\x78\x54\x4e\x75\x46'](benchmarkEnvArtifacts,_0xff25e9[_0x2d540e(0x174)]),..._0xff25e9[_0x2d540e(0x166)][_0x2d540e(0x1f4)]?{'\x74\x72\x61\x63\x65\x49\x64':_0xff25e9[_0x2d540e(0x166)][_0x2d540e(0x1f4)]}:{}}},'\x69\x74\x65\x72\x61\x74\x69\x6f\x6e':_0xff25e9[_0x2d540e(0x1d2)],'\x65\x72\x72\x6f\x72':_0xff25e9[_0x2d540e(0xe8)]&&!_0xff25e9['\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74'][_0x2d540e(0xda)]?_0x4db3a9[_0x2d540e(0x82)]:_0x496abe,'\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74':_0xff25e9['\x73\x61\x6e\x64\x62\x6f\x78\x52\x65\x73\x75\x6c\x74']};}async function runTestCommand(_0x14cf0e,_0x515660,_0x563191,_0x4cfb48){const _0x4d130c=a0_0x5244d4,_0x57a94e={'\x48\x69\x65\x70\x51':function(_0x4fb007,_0x2ff5e0){return _0x4fb007??_0x2ff5e0;}};if(!_0x14cf0e['\x65\x78\x65\x63'])throw new Error(_0x4d130c(0x172));const _0x2ac195=await _0x14cf0e[_0x4d130c(0x1b7)](_0x563191,{'\x73\x65\x73\x73\x69\x6f\x6e\x49\x64':_0x515660,'\x74\x69\x6d\x65\x6f\x75\x74\x4d\x73':Math['\x6d\x61\x78'](0x1,_0x57a94e['\x48\x69\x65\x70\x51'](_0x4cfb48,0x78))*0x3e8});return{'\x65\x78\x69\x74\x43\x6f\x64\x65':_0x2ac195[_0x4d130c(0xb9)],'\x73\x74\x64\x6f\x75\x74':_0x2ac195[_0x4d130c(0xb6)]['\x73\x6c\x69\x63\x65'](0x0,0x7d0),'\x73\x74\x64\x65\x72\x72':_0x2ac195[_0x4d130c(0x169)][_0x4d130c(0xe6)](0x0,0x3e8),'\x74\x65\x73\x74\x73\x50\x61\x73\x73\x65\x64':_0x2ac195[_0x4d130c(0xb9)]===0x0};}async function postJson(_0x2b1c8c,_0x2db50f,_0x250dfa,_0x426818){const _0x420e98=a0_0x5244d4,_0x1bdc98={'\x6a\x4c\x47\x64\x70':_0x420e98(0x10d)},_0x1e361d=await _0x2b1c8c(_0x2db50f,{'\x6d\x65\x74\x68\x6f\x64':_0x420e98(0x125),'\x68\x65\x61\x64\x65\x72\x73':{'\x61\x75\x74\x68\x6f\x72\x69\x7a\x61\x74\x69\x6f\x6e':_0x420e98(0xd4)+_0x250dfa,'\x63\x6f\x6e\x74\x65\x6e\x74\x2d\x74\x79\x70\x65':_0x1bdc98[_0x420e98(0xef)],'\x61\x63\x63\x65\x70\x74':_0x1bdc98[_0x420e98(0xef)]},'\x62\x6f\x64\x79':JSON[_0x420e98(0x1b3)](stripUndefined(_0x426818))}),_0x2d42b5=await _0x1e361d[_0x420e98(0x17b)](),_0x38d18f=_0x2d42b5?JSON[_0x420e98(0x19c)](_0x2d42b5):null;if(!_0x1e361d['\x6f\x6b']){const _0x17b32f=typeof _0x38d18f?.['\x65\x72\x72\x6f\x72']===_0x420e98(0xa5)?_0x38d18f[_0x420e98(0x123)]:_0x2d42b5[_0x420e98(0xe6)](0x0,0xc8);throw new Error(_0x2db50f+_0x420e98(0x1c8)+_0x1e361d[_0x420e98(0x152)]+'\x29\x3a\x20'+_0x17b32f);}return _0x38d18f;}async function parallelLimit(_0x14a2b0,_0x498240){const _0x2fa6d9=a0_0x5244d4,_0x1aabfc={'\x68\x78\x64\x43\x6b':function(_0x2935bc){return _0x2935bc();}},_0x2741b1=[];let _0x41173b=0x0;const _0x229605=Array[_0x2fa6d9(0xb8)]({'\x6c\x65\x6e\x67\x74\x68':Math[_0x2fa6d9(0x1d8)](Math['\x6d\x61\x78'](0x1,_0x498240),_0x14a2b0['\x6c\x65\x6e\x67\x74\x68'])},async()=>{const _0x3f6154=_0x2fa6d9;while(_0x41173b<_0x14a2b0['\x6c\x65\x6e\x67\x74\x68']){const _0x460498=_0x41173b++,_0x2df55a=_0x14a2b0[_0x460498];if(_0x2df55a===void 0x0)throw new Error(_0x3f6154(0x116)+_0x460498);_0x2741b1[_0x460498]=await _0x1aabfc[_0x3f6154(0xfe)](_0x2df55a);}});return await Promise[_0x2fa6d9(0x1e4)](_0x229605),_0x2741b1;}function materializeHarnessEnv(_0x2ad808,_0x52aa60,_0x1f5cca){const _0x393003=a0_0x5244d4;return materializeEnv({..._0x2ad808[_0x393003(0x1ba)]??{},..._0x52aa60??{}},_0x2ad808,_0x1f5cca);}function materializeEnv(_0x12ef22,_0x2ee05b,_0x203ab4){const _0x1640d4=a0_0x5244d4,_0x3622cf=_0x2ee05b[_0x1640d4(0x19e)][_0x1640d4(0x105)][_0x1640d4(0x141)][_0x1640d4(0x80)]['\x72\x65\x70\x6c\x61\x63\x65'](/\/v1\/?$/,''),_0x14fdde=new Map();for(const [_0x593f53,_0x550583]of Object[_0x1640d4(0x100)](_0x12ef22))_0x14fdde[_0x1640d4(0x1c5)](_0x593f53,replaceEnvTokens(_0x550583,_0x203ab4,_0x3622cf,_0x14fdde));return Object[_0x1640d4(0xad)](_0x14fdde);}function replaceEnvTokens(_0x4d3cff,_0x3e300d,_0xcf1fee,_0x1a760e){const _0x1e8843=a0_0x5244d4;let _0x210954=_0x4d3cff[_0x1e8843(0x1b4)](/<tangle-api-key>/g,_0x3e300d)['\x72\x65\x70\x6c\x61\x63\x65'](/\$\{TANGLE_API_KEY\}/g,_0x3e300d)[_0x1e8843(0x1b4)](/\$\{TANGLE_ROUTER_URL\}/g,_0xcf1fee);for(const [_0x1d91cc,_0x530a9e]of _0x1a760e)_0x210954=_0x210954[_0x1e8843(0x1b4)](new RegExp(_0x1e8843(0x93)+escapeRegExp(_0x1d91cc)+'\x5c\x7d','\x67'),_0x530a9e);return _0x210954;}function benchmarkEnvArtifacts(_0x3e678c){const _0x4221fc=a0_0x5244d4,_0x3aa85e=Object[_0x4221fc(0x100)](_0x3e678c)['\x73\x6f\x72\x74'](([_0x1f304c],[_0x3497e7])=>_0x1f304c[_0x4221fc(0x8e)](_0x3497e7));return{'\x68\x61\x72\x6e\x65\x73\x73\x45\x6e\x76\x4b\x65\x79\x73':_0x3aa85e[_0x4221fc(0xb1)](([_0x1c26b4])=>_0x1c26b4)[_0x4221fc(0x1c7)]('\x2c'),'\x68\x61\x72\x6e\x65\x73\x73\x45\x6e\x76\x48\x61\x73\x68':stableHash(_0x3aa85e[_0x4221fc(0xb1)](([_0x50cb75,_0x43c0f4])=>_0x50cb75+'\x3d'+redactEnvValue(_0x50cb75,_0x43c0f4))[_0x4221fc(0x1c7)]('\x0a')),'\x68\x61\x72\x6e\x65\x73\x73\x45\x6e\x76':JSON[_0x4221fc(0x1b3)](Object[_0x4221fc(0xad)](_0x3aa85e[_0x4221fc(0xb1)](([_0x2d6c8e,_0x279011])=>[_0x2d6c8e,redactEnvValue(_0x2d6c8e,_0x279011)])))};}function redactEnvValue(_0x2a493a,_0x3cfdc9){const _0x1917d0=a0_0x5244d4,_0x44e3af={'\x65\x50\x65\x69\x76':_0x1917d0(0x99)};if(/token|secret|key|authorization/i[_0x1917d0(0xb4)](_0x2a493a))return _0x44e3af[_0x1917d0(0x13c)];if(/^Bearer\s+/i[_0x1917d0(0xb4)](_0x3cfdc9))return _0x1917d0(0xab);return _0x3cfdc9[_0x1917d0(0x137)]>0x1f4?_0x3cfdc9[_0x1917d0(0xe6)](0x0,0x1f4)+_0x1917d0(0x15e):_0x3cfdc9;}function stableHash(_0x3fb7c7){const _0x4d288a=a0_0x5244d4;let _0x56bc3f=0x811c9dc5;for(let _0x47b3db=0x0;_0x47b3db<_0x3fb7c7[_0x4d288a(0x137)];_0x47b3db+=0x1){_0x56bc3f^=_0x3fb7c7['\x63\x68\x61\x72\x43\x6f\x64\x65\x41\x74'](_0x47b3db),_0x56bc3f=Math['\x69\x6d\x75\x6c'](_0x56bc3f,0x1000193);}return(_0x56bc3f>>>0x0)[_0x4d288a(0x1af)](0x10)[_0x4d288a(0x9a)](0x8,'\x30');}function escapeRegExp(_0x2cb7ec){const _0x56831b=a0_0x5244d4;return _0x2cb7ec[_0x56831b(0x1b4)](/[.*+?^${}()|[\]\\]/g,'\x5c\x24\x26');}function inferSearchProvider(_0x1c2547){const _0x45744a=a0_0x5244d4,_0x4c77ab={'\x44\x65\x64\x7a\x71':function(_0x3b5eac,_0x5d88df){return _0x3b5eac===_0x5d88df;},'\x58\x52\x64\x64\x66':_0x45744a(0x149)},_0x169ecb=_0x1c2547?.[_0x45744a(0x138)]?.['\x67\x61\x74\x65\x77\x61\x79']?.[_0x45744a(0x115)];if(_0x4c77ab['\x44\x65\x64\x7a\x71'](_0x169ecb,![]))return _0x45744a(0x1ad);if(_0x169ecb&&_0x4c77ab[_0x45744a(0x1ae)](typeof _0x169ecb,_0x4c77ab[_0x45744a(0x11d)])&&typeof _0x169ecb[_0x45744a(0x118)]===_0x45744a(0xa5))return _0x169ecb[_0x45744a(0x118)];return _0x45744a(0x1b9);}function promptCost(_0x2cf761){const _0xe3f9b2=a0_0x5244d4,_0x320961={'\x49\x59\x72\x46\x70':_0xe3f9b2(0x1a6),'\x49\x74\x4c\x4a\x6c':function(_0xb667b,_0x348837){return _0xb667b===_0x348837;},'\x71\x66\x59\x6e\x64':function(_0x33d7d0,_0x4e13f0){return _0x33d7d0>_0x4e13f0;}},_0x438a00=_0x2cf761,_0x282dfa=typeof _0x438a00[_0xe3f9b2(0xe1)]===_0x320961[_0xe3f9b2(0x18f)]?_0x438a00[_0xe3f9b2(0xe1)]:_0x438a00[_0xe3f9b2(0x1a3)];return _0x320961[_0xe3f9b2(0x197)](typeof _0x282dfa,_0xe3f9b2(0x1a6))&&Number['\x69\x73\x46\x69\x6e\x69\x74\x65'](_0x282dfa)&&_0x320961[_0xe3f9b2(0x131)](_0x282dfa,0x0)?_0x282dfa:0x0;}function promptToolCalls(_0x2466e7){const _0x4622eb=a0_0x5244d4,_0x506c88=_0x2466e7;if(Array[_0x4622eb(0x92)](_0x506c88[_0x4622eb(0x109)]))return _0x506c88[_0x4622eb(0x109)];if(Array[_0x4622eb(0x92)](_0x506c88[_0x4622eb(0xa0)]))return _0x506c88[_0x4622eb(0xa0)];return[];}function benchmarkSearchRequests(_0x182f96,_0x4f807b){const _0xc5518=a0_0x5244d4,_0x258c83={'\x42\x42\x68\x56\x4c':function(_0x43384d,_0x301529){return _0x43384d(_0x301529);},'\x4d\x48\x73\x43\x76':_0xc5518(0xfc),'\x41\x44\x50\x6a\x76':function(_0x311cab,_0x187335){return _0x311cab===_0x187335;},'\x70\x6c\x61\x43\x51':function(_0x4b686a,_0x1a3b6a){return _0x4b686a!==_0x1a3b6a;}},_0x25bde3=_0x182f96,_0x1cca59=typeof _0x25bde3['\x73\x65\x61\x72\x63\x68\x52\x65\x71\x75\x65\x73\x74\x73']===_0xc5518(0x1a6)?_0x25bde3[_0xc5518(0x140)]:_0x258c83['\x41\x44\x50\x6a\x76'](typeof _0x25bde3[_0xc5518(0x1f3)]?.[_0xc5518(0x140)],_0xc5518(0x1a6))?_0x25bde3[_0xc5518(0x1f3)][_0xc5518(0x140)]:void 0x0;if(_0x258c83[_0xc5518(0xc3)](_0x1cca59,void 0x0))return Math['\x6d\x61\x78'](0x0,_0x1cca59);return _0x4f807b[_0xc5518(0x1d1)](_0x4a0c49=>{const _0x4a2a5e=_0xc5518,_0xceb3bc=_0x4a0c49;return _0x258c83['\x42\x42\x68\x56\x4c'](String,_0xceb3bc['\x6e\x61\x6d\x65']??_0xceb3bc['\x74\x6f\x6f\x6c\x4e\x61\x6d\x65']??_0xceb3bc[_0x4a2a5e(0x1a8)]??'')[_0x4a2a5e(0x1ce)]()[_0x4a2a5e(0x17c)](_0x258c83[_0x4a2a5e(0xb0)]);})[_0xc5518(0x137)];}function benchmarkCitationCount(_0x31675c){const _0x42a28e=a0_0x5244d4,_0x3cd433={'\x49\x6c\x6f\x43\x74':function(_0x10033b,_0x295f81){return _0x10033b===_0x295f81;},'\x56\x70\x4c\x44\x6e':_0x42a28e(0x1a6)},_0xa181ed=_0x31675c;if(_0x3cd433[_0x42a28e(0x195)](typeof _0xa181ed[_0x42a28e(0x159)],_0x3cd433[_0x42a28e(0xa1)]))return Math[_0x42a28e(0x1aa)](0x0,_0xa181ed[_0x42a28e(0x159)]);if(typeof _0xa181ed['\x6d\x65\x74\x61\x64\x61\x74\x61']?.[_0x42a28e(0x159)]===_0x3cd433[_0x42a28e(0xa1)])return Math[_0x42a28e(0x1aa)](0x0,_0xa181ed[_0x42a28e(0x1f3)][_0x42a28e(0x159)]);if(Array[_0x42a28e(0x92)](_0xa181ed[_0x42a28e(0xb2)]))return _0xa181ed['\x63\x69\x74\x61\x74\x69\x6f\x6e\x73'][_0x42a28e(0x137)];if(Array[_0x42a28e(0x92)](_0xa181ed[_0x42a28e(0x16a)]))return _0xa181ed['\x61\x6e\x6e\x6f\x74\x61\x74\x69\x6f\x6e\x73'][_0x42a28e(0x1d1)](_0x1ac044=>{const _0x1cd1bf=_0x42a28e,_0x3239ea=_0x1ac044;return _0x3cd433[_0x1cd1bf(0x195)](_0x3239ea[_0x1cd1bf(0x1a8)],_0x1cd1bf(0x148))||Boolean(_0x3239ea[_0x1cd1bf(0x148)]);})[_0x42a28e(0x137)];return 0x0;}function backendType(_0x450a96){const _0xf6245c=a0_0x5244d4,_0x4fb4bc={'\x62\x4d\x64\x46\x68':_0xf6245c(0xbd),'\x74\x68\x68\x55\x54':_0xf6245c(0x139)};if(_0x450a96===_0x4fb4bc['\x62\x4d\x64\x46\x68'])return _0xf6245c(0xbd);if(_0x450a96===_0xf6245c(0x1ac))return'\x63\x6f\x64\x65\x78';if(_0x450a96===_0x4fb4bc['\x74\x68\x68\x55\x54'])return'\x6f\x70\x65\x6e\x63\x6f\x64\x65';return _0xf6245c(0x139);}function safeId(_0x96f39d){const _0x542812=a0_0x5244d4,_0xdf9b98={'\x65\x77\x62\x6c\x76':'\x63\x65\x6c\x6c'};return _0x96f39d[_0x542812(0x1ce)]()[_0x542812(0x1b4)](/[^a-z0-9_-]+/g,'\x5f')[_0x542812(0x1b4)](/^_+|_+$/g,'')[_0x542812(0xe6)](0x0,0x78)||_0xdf9b98[_0x542812(0x175)];}async function cleanupBox(_0x404a6f){const _0x406032=a0_0x5244d4;if(_0x404a6f[_0x406032(0xcb)])await _0x404a6f[_0x406032(0xcb)]();else{if(_0x404a6f[_0x406032(0x182)])await _0x404a6f['\x64\x65\x73\x74\x72\x6f\x79']();}}function stripUndefined(_0x597034){const _0x498d9b=a0_0x5244d4,_0x1f0577={'\x79\x59\x79\x52\x49':function(_0x2725df,_0x5107c4){return _0x2725df!==_0x5107c4;},'\x65\x49\x4a\x47\x62':'\x6f\x62\x6a\x65\x63\x74'};if(Array[_0x498d9b(0x92)](_0x597034))return _0x597034['\x6d\x61\x70'](stripUndefined);if(!_0x597034||_0x1f0577[_0x498d9b(0x19b)](typeof _0x597034,_0x1f0577[_0x498d9b(0xaf)]))return _0x597034;return Object[_0x498d9b(0xad)](Object[_0x498d9b(0x100)](_0x597034)['\x66\x69\x6c\x74\x65\x72'](([,_0x308bfe])=>_0x308bfe!==void 0x0)[_0x498d9b(0xb1)](([_0x3bbe26,_0x340dd1])=>[_0x3bbe26,stripUndefined(_0x340dd1)]));}export{a0_0x550e41 as AuthError,CONTROL_PLANE_MCP_SERVER_NAME,a0_0x392f23 as CapabilityError,a0_0x81d1cc as CollaborationClient,a0_0x2b149e as CollaborationFileBridge,a0_0x53a25a as DEFAULT_SANDBOX_SIZE,Image,ImageBuilder,a0_0xde429d as IntelligenceClient,a0_0x289c3f as InteractiveSessionHandle,MANAGE_SANDBOXES_PARAMETERS,MANAGE_SANDBOXES_TOOL_NAME,a0_0x58deab as NetworkError,a0_0x3cc870 as NotFoundError,a0_0x577f0c as PartialFailureError,a0_0x373d5e as QuotaError,SANDBOX_MCP_SERVER_NAME,a0_0x50fc91 as SANDBOX_SIZE_PRESETS,a0_0x33e013 as SANDBOX_SIZE_PRESET_NAMES,a0_0x56ab00 as Sandbox,a0_0x56ab00 as SandboxClient,a0_0x361f23 as SandboxError,a0_0x545f4f as SandboxFleet,a0_0x68730a as SandboxFleetClient,a0_0x4a09bb as SandboxInstance,a0_0xa8516f as SandboxSession,a0_0x193670 as ServerError,a0_0x3699b1 as StateError,a0_0x3ca9b1 as TangleSandboxClient,a0_0x5a90a4 as TimeoutError,a0_0xd051d1 as ValidationError,a0_0x47ddeb as applySandboxEventText,a0_0x1558c0 as buildCollaborationDocumentId,buildControlPlaneMcpConfig,buildSandboxMcpConfig,buildTangleRouterEvalMatrixRequest,buildTangleRouterResponsesWebSearchRequest,buildTangleRouterSearchBackend,buildTangleRouterSearchProfile,a0_0x4acb50 as buildTraceExportPayload,a0_0x4bc384 as collectAgentResponseText,createConfidentialSandbox,createManageSandboxesTool,defineAgentProfile,defineGitHubResource,defineInlineResource,a0_0x46aa32 as exportTraceBundle,fetchTangleRouterSearchConfig,generateAttestationNonce,generateDockerfile,a0_0x4ddf44 as getSandboxEventText,mergeAgentProfiles,a0_0x135b2d as normalizeCollaborationPath,a0_0x165590 as normalizeRuntimeBackendConfig,a0_0x4c4030 as otelTraceIdForTangleTrace,a0_0x1c3ecb as parseCollaborationDocumentId,a0_0x27b804 as parseSSEStream,a0_0x4e27e7 as resolveSandboxResources,runTangleRouterEvalMatrixInSandbox,a0_0x59b9e4 as sandboxResourcesForSize,a0_0x50f1ed as serializeForSidecar,startTeeAttestationHeartbeat,a0_0x57318f as toOtelJson};
|
|
1
|
+
import { a as collectAgentResponseText, c as buildTraceExportPayload, d as toOtelJson, h as serializeForSidecar, i as applySandboxEventText, l as exportTraceBundle, m as normalizeRuntimeBackendConfig, n as SandboxSession, o as getSandboxEventText, p as parseSSEStream, r as InteractiveSessionHandle, t as SandboxInstance, u as otelTraceIdForTangleTrace } from "./sandbox-joKtQ5y3.js";
|
|
2
|
+
import { a as PartialFailureError, c as ServerError, d as ValidationError, i as NotFoundError, l as StateError, n as CapabilityError, o as QuotaError, r as NetworkError, s as SandboxError, t as AuthError, u as TimeoutError } from "./errors-DZsfJUuc.js";
|
|
3
|
+
import { a as DEFAULT_SANDBOX_SIZE, c as resolveSandboxResources, i as SandboxFleetClient, l as sandboxResourcesForSize, n as SandboxClient, o as SANDBOX_SIZE_PRESETS, r as SandboxFleet, s as SANDBOX_SIZE_PRESET_NAMES, t as IntelligenceClient } from "./client-BBZ7YLmq.js";
|
|
4
|
+
import { a as CollaborationClient, i as parseCollaborationDocumentId, n as buildCollaborationDocumentId, r as normalizeCollaborationPath, t as CollaborationFileBridge } from "./collaboration-BxlfZ2Uh.js";
|
|
5
|
+
import { t as TangleSandboxClient } from "./tangle-DM0o66lW.js";
|
|
6
|
+
import { defineAgentProfile, defineGitHubResource, defineInlineResource, mergeAgentProfiles } from "@tangle-network/agent-interface";
|
|
7
|
+
//#region src/confidential.ts
|
|
8
|
+
function generateAttestationNonce(bytes = 32) {
|
|
9
|
+
const buffer = new Uint8Array(bytes);
|
|
10
|
+
if (typeof globalThis.crypto !== "undefined" && typeof globalThis.crypto.getRandomValues === "function") globalThis.crypto.getRandomValues(buffer);
|
|
11
|
+
else throw new Error("Secure random nonce generation is not available");
|
|
12
|
+
return Array.from(buffer).map((byte) => byte.toString(16).padStart(2, "0")).join("");
|
|
13
|
+
}
|
|
14
|
+
async function createConfidentialSandbox(client, options) {
|
|
15
|
+
const attestationNonce = options.attestationNonce === "auto" || options.requireAttestation && !options.attestationNonce && !options.confidential.attestationNonce ? generateAttestationNonce() : options.attestationNonce ?? options.confidential.attestationNonce;
|
|
16
|
+
const sandbox = await client.create({
|
|
17
|
+
...options,
|
|
18
|
+
confidential: {
|
|
19
|
+
...options.confidential,
|
|
20
|
+
...attestationNonce ? { attestationNonce } : {},
|
|
21
|
+
attestationRefresh: options.confidential.attestationRefresh || Boolean(attestationNonce)
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
let attestation = attestationFromMetadata(sandbox.metadata);
|
|
25
|
+
if (!attestation) try {
|
|
26
|
+
attestation = (await sandbox.getTeeAttestation(attestationNonce ? { attestationNonce } : void 0)).attestation;
|
|
27
|
+
} catch (error) {
|
|
28
|
+
if (options.requireAttestation) throw error;
|
|
29
|
+
}
|
|
30
|
+
if (options.requireAttestation && !attestation) throw new Error("TEE attestation was required but no evidence was returned");
|
|
31
|
+
return {
|
|
32
|
+
sandbox,
|
|
33
|
+
attestation,
|
|
34
|
+
attestationNonce
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
function attestationFromMetadata(metadata) {
|
|
38
|
+
const raw = metadata?.teeAttestationJson;
|
|
39
|
+
if (typeof raw !== "string" || raw.trim() === "") return void 0;
|
|
40
|
+
try {
|
|
41
|
+
return JSON.parse(raw);
|
|
42
|
+
} catch {
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
//#endregion
|
|
47
|
+
//#region src/attestation-heartbeat.ts
|
|
48
|
+
/**
|
|
49
|
+
* Periodically requests nonce-bound TEE attestations for a running sandbox.
|
|
50
|
+
*
|
|
51
|
+
* This proves freshness/liveness of the attested sandbox endpoint. It does not
|
|
52
|
+
* by itself sign every computation result; callers that need result binding
|
|
53
|
+
* should include a result/session digest in the nonce preimage before asking
|
|
54
|
+
* the runtime for a quote.
|
|
55
|
+
*/
|
|
56
|
+
function startTeeAttestationHeartbeat(sandbox, options = {}) {
|
|
57
|
+
const intervalMs = options.intervalMs ?? 6e4;
|
|
58
|
+
let stopped = false;
|
|
59
|
+
let failures = 0;
|
|
60
|
+
let sequence = 0;
|
|
61
|
+
let latest;
|
|
62
|
+
let timer;
|
|
63
|
+
let resolveDone;
|
|
64
|
+
const done = new Promise((resolve) => {
|
|
65
|
+
resolveDone = resolve;
|
|
66
|
+
});
|
|
67
|
+
const stop = () => {
|
|
68
|
+
if (stopped) return;
|
|
69
|
+
stopped = true;
|
|
70
|
+
if (timer) clearTimeout(timer);
|
|
71
|
+
resolveDone?.();
|
|
72
|
+
};
|
|
73
|
+
const ping = async () => {
|
|
74
|
+
if (stopped || options.signal?.aborted) throw new Error("TEE attestation heartbeat is stopped");
|
|
75
|
+
const nonce = generateAttestationNonce();
|
|
76
|
+
const response = await sandbox.getTeeAttestation({ attestationNonce: nonce });
|
|
77
|
+
if (response.attestationNonce && response.attestationNonce !== nonce) throw new Error("TEE attestation response nonce did not match challenge");
|
|
78
|
+
const sample = {
|
|
79
|
+
sequence: ++sequence,
|
|
80
|
+
nonce,
|
|
81
|
+
response: {
|
|
82
|
+
...response,
|
|
83
|
+
attestationNonce: response.attestationNonce ?? nonce
|
|
84
|
+
},
|
|
85
|
+
checkedAt: /* @__PURE__ */ new Date()
|
|
86
|
+
};
|
|
87
|
+
await options.verify?.(sample);
|
|
88
|
+
latest = sample;
|
|
89
|
+
options.onSuccess?.(sample);
|
|
90
|
+
return sample;
|
|
91
|
+
};
|
|
92
|
+
const schedule = () => {
|
|
93
|
+
if (stopped || options.signal?.aborted) {
|
|
94
|
+
stop();
|
|
95
|
+
return;
|
|
96
|
+
}
|
|
97
|
+
timer = setTimeout(() => {
|
|
98
|
+
loop();
|
|
99
|
+
}, intervalMs);
|
|
100
|
+
};
|
|
101
|
+
const loop = async () => {
|
|
102
|
+
try {
|
|
103
|
+
await ping();
|
|
104
|
+
schedule();
|
|
105
|
+
} catch (error) {
|
|
106
|
+
failures += 1;
|
|
107
|
+
options.onFailure?.(error);
|
|
108
|
+
if (options.continueOnFailure) schedule();
|
|
109
|
+
else stop();
|
|
110
|
+
}
|
|
111
|
+
};
|
|
112
|
+
options.signal?.addEventListener("abort", stop, { once: true });
|
|
113
|
+
if (options.immediate === false) schedule();
|
|
114
|
+
else loop();
|
|
115
|
+
return {
|
|
116
|
+
stop,
|
|
117
|
+
ping,
|
|
118
|
+
get stopped() {
|
|
119
|
+
return stopped;
|
|
120
|
+
},
|
|
121
|
+
get failures() {
|
|
122
|
+
return failures;
|
|
123
|
+
},
|
|
124
|
+
get latest() {
|
|
125
|
+
return latest;
|
|
126
|
+
},
|
|
127
|
+
done
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
//#endregion
|
|
131
|
+
//#region src/image.ts
|
|
132
|
+
function isFetchClient(client) {
|
|
133
|
+
return typeof client.fetch === "function";
|
|
134
|
+
}
|
|
135
|
+
function requestImageBuild(client, init) {
|
|
136
|
+
if (isFetchClient(client)) return client.fetch("/v1/images", init);
|
|
137
|
+
const headers = new Headers(init.headers);
|
|
138
|
+
headers.set("Authorization", `Bearer ${client.apiKey}`);
|
|
139
|
+
return fetch(`${client.baseUrl.replace(/\/+$/, "")}/v1/images`, {
|
|
140
|
+
...init,
|
|
141
|
+
headers
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Represents a built or existing container image.
|
|
146
|
+
*/
|
|
147
|
+
var Image = class Image {
|
|
148
|
+
constructor(id, tag, digest, spec) {
|
|
149
|
+
this.id = id;
|
|
150
|
+
this.tag = tag;
|
|
151
|
+
this.digest = digest;
|
|
152
|
+
this.spec = spec;
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Start building a new image.
|
|
156
|
+
*
|
|
157
|
+
* @param baseImage Base Docker image (default: "ubuntu:22.04")
|
|
158
|
+
* @returns A new ImageBuilder instance
|
|
159
|
+
*
|
|
160
|
+
* @example
|
|
161
|
+
* ```typescript
|
|
162
|
+
* const builder = Image.create("python:3.11-slim");
|
|
163
|
+
* ```
|
|
164
|
+
*/
|
|
165
|
+
static create(baseImage = "ubuntu:22.04") {
|
|
166
|
+
return new ImageBuilder({ baseImage });
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Reference an existing image by ID.
|
|
170
|
+
*
|
|
171
|
+
* @param imageId The image ID
|
|
172
|
+
* @returns An Image instance
|
|
173
|
+
*
|
|
174
|
+
* @example
|
|
175
|
+
* ```typescript
|
|
176
|
+
* const image = Image.fromId("sha256:abc123...");
|
|
177
|
+
* const box = await client.create({ image: image.id });
|
|
178
|
+
* ```
|
|
179
|
+
*/
|
|
180
|
+
static fromId(imageId) {
|
|
181
|
+
return new Image(imageId, imageId.startsWith("sha256:") ? `tangle-image:${imageId.slice(7, 19)}` : imageId, imageId);
|
|
182
|
+
}
|
|
183
|
+
/**
|
|
184
|
+
* Create an image builder from a Dockerfile.
|
|
185
|
+
*
|
|
186
|
+
* @param dockerfile Dockerfile path or content
|
|
187
|
+
* @param context Build context directory
|
|
188
|
+
* @returns A new ImageBuilder instance
|
|
189
|
+
*
|
|
190
|
+
* @example
|
|
191
|
+
* ```typescript
|
|
192
|
+
* const builder = Image.fromDockerfile("./Dockerfile", "./");
|
|
193
|
+
* ```
|
|
194
|
+
*/
|
|
195
|
+
static fromDockerfile(dockerfile, context) {
|
|
196
|
+
return new ImageBuilder({
|
|
197
|
+
baseImage: "scratch",
|
|
198
|
+
dockerfile,
|
|
199
|
+
dockerContext: context || "."
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
/**
|
|
203
|
+
* Create an Image from a build result.
|
|
204
|
+
* @internal
|
|
205
|
+
*/
|
|
206
|
+
static fromBuildResult(result) {
|
|
207
|
+
return new Image(result.id, result.tag, result.digest, result.spec);
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* Convert to JSON.
|
|
211
|
+
*/
|
|
212
|
+
toJSON() {
|
|
213
|
+
return {
|
|
214
|
+
id: this.id,
|
|
215
|
+
tag: this.tag,
|
|
216
|
+
digest: this.digest,
|
|
217
|
+
spec: this.spec
|
|
218
|
+
};
|
|
219
|
+
}
|
|
220
|
+
};
|
|
221
|
+
/**
|
|
222
|
+
* Chainable builder for constructing custom container images.
|
|
223
|
+
*
|
|
224
|
+
* @example
|
|
225
|
+
* ```typescript
|
|
226
|
+
* const image = await Image.create()
|
|
227
|
+
* .python("3.11")
|
|
228
|
+
* .addPackages(["torch", "transformers"])
|
|
229
|
+
* .addCommands(["apt-get install -y ffmpeg"])
|
|
230
|
+
* .withEnv({ HF_HOME: "/models" })
|
|
231
|
+
* .withSecrets(["HF_TOKEN"])
|
|
232
|
+
* .build({ client });
|
|
233
|
+
* ```
|
|
234
|
+
*/
|
|
235
|
+
var ImageBuilder = class {
|
|
236
|
+
spec;
|
|
237
|
+
clientConfig;
|
|
238
|
+
/** @internal */
|
|
239
|
+
constructor(initialSpec) {
|
|
240
|
+
this.spec = {
|
|
241
|
+
baseImage: initialSpec.baseImage || "ubuntu:22.04",
|
|
242
|
+
...initialSpec
|
|
243
|
+
};
|
|
244
|
+
}
|
|
245
|
+
/**
|
|
246
|
+
* Configure Python version.
|
|
247
|
+
*
|
|
248
|
+
* @param version Python version (e.g., "3.11", "3.10")
|
|
249
|
+
*/
|
|
250
|
+
python(version) {
|
|
251
|
+
this.spec.pythonVersion = version;
|
|
252
|
+
return this;
|
|
253
|
+
}
|
|
254
|
+
/**
|
|
255
|
+
* Add Python packages via pip.
|
|
256
|
+
*
|
|
257
|
+
* @param packages Package names with optional versions
|
|
258
|
+
*
|
|
259
|
+
* @example
|
|
260
|
+
* ```typescript
|
|
261
|
+
* .addPackages(["numpy>=1.21", "pandas", "scikit-learn"])
|
|
262
|
+
* ```
|
|
263
|
+
*/
|
|
264
|
+
addPackages(packages) {
|
|
265
|
+
this.spec.packages = [...this.spec.packages || [], ...packages];
|
|
266
|
+
return this;
|
|
267
|
+
}
|
|
268
|
+
/**
|
|
269
|
+
* Add packages from requirements file.
|
|
270
|
+
*
|
|
271
|
+
* @param requirementsPath Path to requirements.txt
|
|
272
|
+
*/
|
|
273
|
+
addPackagesFromFile(requirementsPath) {
|
|
274
|
+
this.spec.commands = [...this.spec.commands || [], `pip install -r ${requirementsPath}`];
|
|
275
|
+
return this;
|
|
276
|
+
}
|
|
277
|
+
/**
|
|
278
|
+
* Add shell commands to run during build.
|
|
279
|
+
*
|
|
280
|
+
* @param commands Commands to execute
|
|
281
|
+
*
|
|
282
|
+
* @example
|
|
283
|
+
* ```typescript
|
|
284
|
+
* .addCommands([
|
|
285
|
+
* "apt-get update",
|
|
286
|
+
* "apt-get install -y ffmpeg libsm6"
|
|
287
|
+
* ])
|
|
288
|
+
* ```
|
|
289
|
+
*/
|
|
290
|
+
addCommands(commands) {
|
|
291
|
+
this.spec.commands = [...this.spec.commands || [], ...commands];
|
|
292
|
+
return this;
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* Add system packages via apt-get.
|
|
296
|
+
*
|
|
297
|
+
* @param packages Package names
|
|
298
|
+
*/
|
|
299
|
+
addAptPackages(packages) {
|
|
300
|
+
this.spec.aptPackages = [...this.spec.aptPackages || [], ...packages];
|
|
301
|
+
return this;
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* Set environment variables.
|
|
305
|
+
*
|
|
306
|
+
* @param env Key-value pairs
|
|
307
|
+
*
|
|
308
|
+
* @example
|
|
309
|
+
* ```typescript
|
|
310
|
+
* .withEnv({ HF_HOME: "/models", PYTHONUNBUFFERED: "1" })
|
|
311
|
+
* ```
|
|
312
|
+
*/
|
|
313
|
+
withEnv(env) {
|
|
314
|
+
this.spec.env = {
|
|
315
|
+
...this.spec.env,
|
|
316
|
+
...env
|
|
317
|
+
};
|
|
318
|
+
return this;
|
|
319
|
+
}
|
|
320
|
+
/**
|
|
321
|
+
* Inject secrets during build.
|
|
322
|
+
* Secrets are retrieved from the secret store.
|
|
323
|
+
*
|
|
324
|
+
* @param secretNames Names of secrets to inject
|
|
325
|
+
*
|
|
326
|
+
* @example
|
|
327
|
+
* ```typescript
|
|
328
|
+
* .withSecrets(["HF_TOKEN", "AWS_ACCESS_KEY"])
|
|
329
|
+
* ```
|
|
330
|
+
*/
|
|
331
|
+
withSecrets(secretNames) {
|
|
332
|
+
this.spec.secrets = [...this.spec.secrets || [], ...secretNames];
|
|
333
|
+
return this;
|
|
334
|
+
}
|
|
335
|
+
/**
|
|
336
|
+
* Configure conda environment.
|
|
337
|
+
*
|
|
338
|
+
* @param packages Conda packages
|
|
339
|
+
* @param channels Conda channels (default: ["conda-forge"])
|
|
340
|
+
*
|
|
341
|
+
* @example
|
|
342
|
+
* ```typescript
|
|
343
|
+
* .conda(["pytorch", "torchvision"], ["pytorch", "conda-forge"])
|
|
344
|
+
* ```
|
|
345
|
+
*/
|
|
346
|
+
conda(packages, channels) {
|
|
347
|
+
this.spec.conda = {
|
|
348
|
+
packages: [...this.spec.conda?.packages || [], ...packages],
|
|
349
|
+
channels: channels || this.spec.conda?.channels || ["conda-forge"]
|
|
350
|
+
};
|
|
351
|
+
return this;
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* Set working directory.
|
|
355
|
+
*
|
|
356
|
+
* @param dir Working directory path
|
|
357
|
+
*/
|
|
358
|
+
workdir(dir) {
|
|
359
|
+
this.spec.workdir = dir;
|
|
360
|
+
return this;
|
|
361
|
+
}
|
|
362
|
+
/**
|
|
363
|
+
* Set user to run as.
|
|
364
|
+
*
|
|
365
|
+
* @param user Username or UID
|
|
366
|
+
*/
|
|
367
|
+
user(user) {
|
|
368
|
+
this.spec.user = user;
|
|
369
|
+
return this;
|
|
370
|
+
}
|
|
371
|
+
/**
|
|
372
|
+
* Add build arguments.
|
|
373
|
+
*
|
|
374
|
+
* @param args Build arguments
|
|
375
|
+
*/
|
|
376
|
+
buildArgs(args) {
|
|
377
|
+
this.spec.buildArgs = {
|
|
378
|
+
...this.spec.buildArgs,
|
|
379
|
+
...args
|
|
380
|
+
};
|
|
381
|
+
return this;
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* Add image labels.
|
|
385
|
+
*
|
|
386
|
+
* @param labels Image labels
|
|
387
|
+
*/
|
|
388
|
+
labels(labels) {
|
|
389
|
+
this.spec.labels = {
|
|
390
|
+
...this.spec.labels,
|
|
391
|
+
...labels
|
|
392
|
+
};
|
|
393
|
+
return this;
|
|
394
|
+
}
|
|
395
|
+
/**
|
|
396
|
+
* Get the image specification without building.
|
|
397
|
+
*
|
|
398
|
+
* @returns The current ImageSpec
|
|
399
|
+
*/
|
|
400
|
+
toSpec() {
|
|
401
|
+
return { ...this.spec };
|
|
402
|
+
}
|
|
403
|
+
/**
|
|
404
|
+
* Compute the content-addressed ID for this spec.
|
|
405
|
+
*
|
|
406
|
+
* Uses Web Crypto when available (browsers and Node 22+), falling
|
|
407
|
+
* back to a lazy `import("node:crypto")` on older server runtimes.
|
|
408
|
+
* Works in every JavaScript environment the SDK supports.
|
|
409
|
+
*
|
|
410
|
+
* @returns SHA-256 hash of the normalized spec as a hex string.
|
|
411
|
+
*
|
|
412
|
+
* **Breaking change (v0.0.3):** `computeId()` was previously
|
|
413
|
+
* synchronous. Callers must now `await` the result. A Node-only sync
|
|
414
|
+
* variant was considered and dropped: it would have either required
|
|
415
|
+
* Node 22.3+ (breaking Node 18/20 consumers) or re-introduced the
|
|
416
|
+
* top-level `node:crypto` import that blanks every browser page
|
|
417
|
+
* transitively importing the SDK root. If you genuinely need the
|
|
418
|
+
* hash synchronously in a Node-only context, compute it yourself
|
|
419
|
+
* from `builder.toSpec()` with `JSON.stringify(spec, Object.keys(spec).sort())`.
|
|
420
|
+
*/
|
|
421
|
+
async computeId() {
|
|
422
|
+
const normalized = JSON.stringify(this.spec, Object.keys(this.spec).sort());
|
|
423
|
+
const webSubtle = globalThis.crypto?.subtle;
|
|
424
|
+
if (webSubtle) {
|
|
425
|
+
const digest = await webSubtle.digest("SHA-256", new TextEncoder().encode(normalized));
|
|
426
|
+
return Array.from(new Uint8Array(digest)).map((b) => b.toString(16).padStart(2, "0")).join("");
|
|
427
|
+
}
|
|
428
|
+
const { createHash } = await import("node:crypto");
|
|
429
|
+
return createHash("sha256").update(normalized).digest("hex");
|
|
430
|
+
}
|
|
431
|
+
/**
|
|
432
|
+
* Configure client for API access.
|
|
433
|
+
* @internal
|
|
434
|
+
*/
|
|
435
|
+
withClient(config) {
|
|
436
|
+
this.clientConfig = config;
|
|
437
|
+
return this;
|
|
438
|
+
}
|
|
439
|
+
/**
|
|
440
|
+
* Build the image.
|
|
441
|
+
*
|
|
442
|
+
* @param options Build options including client config
|
|
443
|
+
* @returns The built Image instance
|
|
444
|
+
*
|
|
445
|
+
* @example
|
|
446
|
+
* ```typescript
|
|
447
|
+
* const image = await Image.create()
|
|
448
|
+
* .python("3.11")
|
|
449
|
+
* .addPackages(["numpy"])
|
|
450
|
+
* .build({
|
|
451
|
+
* client: { baseUrl, apiKey },
|
|
452
|
+
* onProgress: (e) => console.log(e.message),
|
|
453
|
+
* });
|
|
454
|
+
*
|
|
455
|
+
* const box = await client.create({ image: image.id });
|
|
456
|
+
* ```
|
|
457
|
+
*/
|
|
458
|
+
async build(options) {
|
|
459
|
+
const client = options?.client || this.clientConfig;
|
|
460
|
+
if (!client) throw new Error("Client configuration required. Pass { client: { baseUrl, apiKey } } to build() or use ImageBuilder through the Sandbox client.");
|
|
461
|
+
const timeoutMs = options?.timeout ?? 6e5;
|
|
462
|
+
const timeoutController = timeoutMs > 0 ? new AbortController() : void 0;
|
|
463
|
+
const timeoutId = timeoutController ? setTimeout(() => timeoutController.abort(), timeoutMs) : void 0;
|
|
464
|
+
let response;
|
|
465
|
+
try {
|
|
466
|
+
response = await requestImageBuild(client, {
|
|
467
|
+
method: "POST",
|
|
468
|
+
headers: { "Content-Type": "application/json" },
|
|
469
|
+
signal: timeoutController?.signal,
|
|
470
|
+
body: JSON.stringify({
|
|
471
|
+
spec: this.spec,
|
|
472
|
+
options: {
|
|
473
|
+
noCache: options?.noCache,
|
|
474
|
+
platform: options?.platform,
|
|
475
|
+
tag: options?.tag,
|
|
476
|
+
stream: !!options?.onProgress
|
|
477
|
+
}
|
|
478
|
+
})
|
|
479
|
+
});
|
|
480
|
+
if (!response.ok) {
|
|
481
|
+
const error = await response.text();
|
|
482
|
+
throw new Error(`Failed to build image: ${error}`);
|
|
483
|
+
}
|
|
484
|
+
if (options?.onProgress && response.headers.get("content-type")?.includes("text/event-stream")) {
|
|
485
|
+
let result;
|
|
486
|
+
for await (const event of parseSSEStream(response.body, { signal: timeoutController?.signal })) {
|
|
487
|
+
const data = event.data;
|
|
488
|
+
if (data.type === "progress") options.onProgress(data.event);
|
|
489
|
+
else if (data.type === "complete") {
|
|
490
|
+
const rawResult = data.result;
|
|
491
|
+
result = {
|
|
492
|
+
...rawResult,
|
|
493
|
+
createdAt: new Date(rawResult.createdAt)
|
|
494
|
+
};
|
|
495
|
+
} else if (data.type === "error") throw new Error(String(data.message ?? "Image build failed"));
|
|
496
|
+
}
|
|
497
|
+
if (!result) throw new Error("Build completed but no result received");
|
|
498
|
+
return Image.fromBuildResult(result);
|
|
499
|
+
}
|
|
500
|
+
const data = await response.json();
|
|
501
|
+
const result = {
|
|
502
|
+
...data,
|
|
503
|
+
createdAt: new Date(data.createdAt)
|
|
504
|
+
};
|
|
505
|
+
return Image.fromBuildResult(result);
|
|
506
|
+
} catch (error) {
|
|
507
|
+
if (timeoutController?.signal.aborted) throw new Error(`Image build timed out after ${timeoutMs}ms`);
|
|
508
|
+
throw error;
|
|
509
|
+
} finally {
|
|
510
|
+
if (timeoutId) clearTimeout(timeoutId);
|
|
511
|
+
}
|
|
512
|
+
}
|
|
513
|
+
/**
|
|
514
|
+
* Generate Dockerfile from the current spec.
|
|
515
|
+
* Useful for debugging or manual builds.
|
|
516
|
+
*
|
|
517
|
+
* @returns Dockerfile content
|
|
518
|
+
*/
|
|
519
|
+
generateDockerfile() {
|
|
520
|
+
return generateDockerfile(this.spec);
|
|
521
|
+
}
|
|
522
|
+
};
|
|
523
|
+
/**
|
|
524
|
+
* Generate a Dockerfile from an ImageSpec.
|
|
525
|
+
*
|
|
526
|
+
* @param spec The image specification
|
|
527
|
+
* @returns Dockerfile content
|
|
528
|
+
*/
|
|
529
|
+
function generateDockerfile(spec) {
|
|
530
|
+
const lines = [];
|
|
531
|
+
lines.push(`FROM ${spec.baseImage}`);
|
|
532
|
+
lines.push("");
|
|
533
|
+
if (spec.labels && Object.keys(spec.labels).length > 0) {
|
|
534
|
+
for (const [key, value] of Object.entries(spec.labels)) lines.push(`LABEL ${key}="${value}"`);
|
|
535
|
+
lines.push("");
|
|
536
|
+
}
|
|
537
|
+
if (spec.buildArgs && Object.keys(spec.buildArgs).length > 0) {
|
|
538
|
+
for (const [key, value] of Object.entries(spec.buildArgs)) lines.push(`ARG ${key}=${value}`);
|
|
539
|
+
lines.push("");
|
|
540
|
+
}
|
|
541
|
+
if (spec.env && Object.keys(spec.env).length > 0) {
|
|
542
|
+
for (const [key, value] of Object.entries(spec.env)) lines.push(`ENV ${key}="${value}"`);
|
|
543
|
+
lines.push("");
|
|
544
|
+
}
|
|
545
|
+
if (spec.workdir) {
|
|
546
|
+
lines.push(`WORKDIR ${spec.workdir}`);
|
|
547
|
+
lines.push("");
|
|
548
|
+
}
|
|
549
|
+
if (spec.aptPackages && spec.aptPackages.length > 0) {
|
|
550
|
+
lines.push("# Install system packages");
|
|
551
|
+
lines.push("RUN apt-get update && \\");
|
|
552
|
+
lines.push(` apt-get install -y --no-install-recommends ${spec.aptPackages.join(" ")} && \\`);
|
|
553
|
+
lines.push(" apt-get clean && rm -rf /var/lib/apt/lists/*");
|
|
554
|
+
lines.push("");
|
|
555
|
+
}
|
|
556
|
+
if (spec.pythonVersion) {
|
|
557
|
+
lines.push(`# Install Python ${spec.pythonVersion}`);
|
|
558
|
+
if (!(spec.baseImage.includes("python") || spec.baseImage.includes("anaconda") || spec.baseImage.includes("miniconda")) && spec.baseImage.includes("ubuntu")) {
|
|
559
|
+
lines.push("RUN apt-get update && \\");
|
|
560
|
+
lines.push(" apt-get install -y software-properties-common && \\");
|
|
561
|
+
lines.push(" add-apt-repository -y ppa:deadsnakes/ppa && \\");
|
|
562
|
+
lines.push(` apt-get install -y python${spec.pythonVersion} python${spec.pythonVersion}-venv python${spec.pythonVersion}-distutils && \\`);
|
|
563
|
+
lines.push(" apt-get clean && rm -rf /var/lib/apt/lists/*");
|
|
564
|
+
lines.push("");
|
|
565
|
+
lines.push(`RUN update-alternatives --install /usr/bin/python python /usr/bin/python${spec.pythonVersion} 1 && \\`);
|
|
566
|
+
lines.push(` update-alternatives --install /usr/bin/python3 python3 /usr/bin/python${spec.pythonVersion} 1`);
|
|
567
|
+
lines.push("");
|
|
568
|
+
lines.push("RUN curl -sS https://bootstrap.pypa.io/get-pip.py | python");
|
|
569
|
+
}
|
|
570
|
+
lines.push("");
|
|
571
|
+
}
|
|
572
|
+
if (spec.conda && spec.conda.packages.length > 0) {
|
|
573
|
+
lines.push("# Install micromamba and conda packages");
|
|
574
|
+
lines.push("RUN curl -Ls https://micro.mamba.pm/api/micromamba/linux-64/latest | tar -xvj bin/micromamba && \\");
|
|
575
|
+
lines.push(" mv bin/micromamba /usr/local/bin/ && \\");
|
|
576
|
+
lines.push(" micromamba shell init -s bash -p /opt/conda");
|
|
577
|
+
lines.push("");
|
|
578
|
+
const channelArgs = (spec.conda.channels || ["conda-forge"]).map((c) => `-c ${c}`).join(" ");
|
|
579
|
+
lines.push(`RUN micromamba install -y -n base ${channelArgs} ${spec.conda.packages.join(" ")} && \\`);
|
|
580
|
+
lines.push(" micromamba clean --all --yes");
|
|
581
|
+
lines.push("ENV PATH=\"/opt/conda/bin:$PATH\"");
|
|
582
|
+
lines.push("");
|
|
583
|
+
}
|
|
584
|
+
if (spec.packages && spec.packages.length > 0) {
|
|
585
|
+
lines.push("# Install Python packages");
|
|
586
|
+
lines.push(`RUN pip install --no-cache-dir ${spec.packages.join(" ")}`);
|
|
587
|
+
lines.push("");
|
|
588
|
+
}
|
|
589
|
+
if (spec.commands && spec.commands.length > 0) {
|
|
590
|
+
lines.push("# Custom commands");
|
|
591
|
+
for (const cmd of spec.commands) lines.push(`RUN ${cmd}`);
|
|
592
|
+
lines.push("");
|
|
593
|
+
}
|
|
594
|
+
if (spec.user) lines.push(`USER ${spec.user}`);
|
|
595
|
+
return lines.join("\n");
|
|
596
|
+
}
|
|
597
|
+
//#endregion
|
|
598
|
+
//#region src/manage-sandboxes.ts
|
|
599
|
+
const MANAGE_SANDBOXES_TOOL_NAME = "manageSandboxes";
|
|
600
|
+
function createManageSandboxesTool(client, options = {}) {
|
|
601
|
+
return {
|
|
602
|
+
name: MANAGE_SANDBOXES_TOOL_NAME,
|
|
603
|
+
description: "Create, inspect, and manage sandbox fleets for parallel agent workloads.",
|
|
604
|
+
parameters: MANAGE_SANDBOXES_PARAMETERS,
|
|
605
|
+
async execute(input) {
|
|
606
|
+
switch (input.action) {
|
|
607
|
+
case "capabilities": return client.fleets.capabilities();
|
|
608
|
+
case "create": return client.fleets.create(applyToolPolicy(requireCreateOptions(input), options.policy));
|
|
609
|
+
case "createWithCoordinator": return client.fleets.createWithCoordinator(applyToolPolicy(requireCreateWithCoordinatorOptions(input), options.policy));
|
|
610
|
+
case "list": return client.fleets.list({ fleetId: requireString(input, "fleetId") });
|
|
611
|
+
case "delete": return client.fleets.delete(requireString(input, "fleetId"));
|
|
612
|
+
case "attachMachine": return client.fleets.attachMachine(requireString(input, "fleetId"), requireMachine(input));
|
|
613
|
+
case "detachMachine": return client.fleets.detachMachine(requireString(input, "fleetId"), requireString(input, "machineId"));
|
|
614
|
+
case "manifest": return client.fleets.manifest(requireString(input, "fleetId"));
|
|
615
|
+
case "usage": return client.fleets.usage(requireString(input, "fleetId"));
|
|
616
|
+
case "trace": return client.fleets.trace(requireString(input, "fleetId"));
|
|
617
|
+
case "intelligence": return client.fleets.intelligence(requireString(input, "fleetId"));
|
|
618
|
+
case "cost": return client.fleets.cost(requireString(input, "fleetId"));
|
|
619
|
+
case "createWorkspaceSnapshot": return client.fleets.createWorkspaceSnapshot(requireString(input, "fleetId"));
|
|
620
|
+
case "restoreWorkspaceSnapshot": return client.fleets.restoreWorkspaceSnapshot(requireString(input, "fleetId"), requireString(input, "snapshotId"));
|
|
621
|
+
case "reconcileWorkspace": return client.fleets.reconcileWorkspace(requireString(input, "fleetId"));
|
|
622
|
+
default: throw new Error(`Unsupported manageSandboxes action: ${String(input.action)}`);
|
|
623
|
+
}
|
|
624
|
+
}
|
|
625
|
+
};
|
|
626
|
+
}
|
|
627
|
+
function requireString(input, key) {
|
|
628
|
+
const value = input[key];
|
|
629
|
+
if (typeof value !== "string" || value.length === 0) throw new Error(`manageSandboxes requires ${key}`);
|
|
630
|
+
return value;
|
|
631
|
+
}
|
|
632
|
+
function requireCreateOptions(input) {
|
|
633
|
+
const value = input.options;
|
|
634
|
+
if (!value || typeof value !== "object") throw new Error("manageSandboxes requires options");
|
|
635
|
+
return rejectUserPolicy(value);
|
|
636
|
+
}
|
|
637
|
+
function requireCreateWithCoordinatorOptions(input) {
|
|
638
|
+
const value = input.options;
|
|
639
|
+
if (!value || typeof value !== "object") throw new Error("manageSandboxes requires options");
|
|
640
|
+
return rejectUserPolicy(value);
|
|
641
|
+
}
|
|
642
|
+
function rejectUserPolicy(options) {
|
|
643
|
+
if ("policy" in options && options.policy !== void 0) throw new Error("manageSandboxes policy must be supplied by the tool host");
|
|
644
|
+
return options;
|
|
645
|
+
}
|
|
646
|
+
function applyToolPolicy(options, policy) {
|
|
647
|
+
if (!policy) throw new Error("manageSandboxes create requires a host-owned policy");
|
|
648
|
+
return {
|
|
649
|
+
...options,
|
|
650
|
+
policy
|
|
651
|
+
};
|
|
652
|
+
}
|
|
653
|
+
function requireMachine(input) {
|
|
654
|
+
const value = input.machine;
|
|
655
|
+
if (!value || typeof value !== "object") throw new Error("manageSandboxes requires machine");
|
|
656
|
+
const machine = value;
|
|
657
|
+
requireString(machine, "machineId");
|
|
658
|
+
requireString(machine, "sandboxId");
|
|
659
|
+
return value;
|
|
660
|
+
}
|
|
661
|
+
const fleetId = {
|
|
662
|
+
type: "string",
|
|
663
|
+
pattern: "^[A-Za-z0-9][A-Za-z0-9._-]{0,63}$"
|
|
664
|
+
};
|
|
665
|
+
const MANAGE_SANDBOXES_PARAMETERS = {
|
|
666
|
+
type: "object",
|
|
667
|
+
additionalProperties: false,
|
|
668
|
+
required: ["action"],
|
|
669
|
+
properties: {
|
|
670
|
+
action: {
|
|
671
|
+
type: "string",
|
|
672
|
+
enum: [
|
|
673
|
+
"capabilities",
|
|
674
|
+
"create",
|
|
675
|
+
"createWithCoordinator",
|
|
676
|
+
"list",
|
|
677
|
+
"delete",
|
|
678
|
+
"attachMachine",
|
|
679
|
+
"detachMachine",
|
|
680
|
+
"manifest",
|
|
681
|
+
"usage",
|
|
682
|
+
"trace",
|
|
683
|
+
"intelligence",
|
|
684
|
+
"cost",
|
|
685
|
+
"createWorkspaceSnapshot",
|
|
686
|
+
"restoreWorkspaceSnapshot",
|
|
687
|
+
"reconcileWorkspace"
|
|
688
|
+
]
|
|
689
|
+
},
|
|
690
|
+
fleetId,
|
|
691
|
+
machineId: fleetId,
|
|
692
|
+
snapshotId: {
|
|
693
|
+
type: "string",
|
|
694
|
+
minLength: 1
|
|
695
|
+
},
|
|
696
|
+
options: { type: "object" },
|
|
697
|
+
machine: {
|
|
698
|
+
type: "object",
|
|
699
|
+
required: ["machineId", "sandboxId"],
|
|
700
|
+
additionalProperties: true,
|
|
701
|
+
properties: {
|
|
702
|
+
machineId: fleetId,
|
|
703
|
+
sandboxId: {
|
|
704
|
+
type: "string",
|
|
705
|
+
minLength: 1,
|
|
706
|
+
maxLength: 128
|
|
707
|
+
}
|
|
708
|
+
}
|
|
709
|
+
}
|
|
710
|
+
}
|
|
711
|
+
};
|
|
712
|
+
//#endregion
|
|
713
|
+
//#region src/mcp.ts
|
|
714
|
+
/**
|
|
715
|
+
* MCP (Model Context Protocol) helpers for sandbox capabilities.
|
|
716
|
+
*
|
|
717
|
+
* The sandbox exposes capabilities (currently `computer_use`, more
|
|
718
|
+
* later) as MCP tools over Streamable HTTP. Any MCP-capable client —
|
|
719
|
+
* Claude Desktop, Cursor, claude-code, codex, opencode, raw
|
|
720
|
+
* `@modelcontextprotocol/sdk` apps — can consume this surface by
|
|
721
|
+
* pasting the JSON returned from `Sandbox#getMcpEndpoint()` (or
|
|
722
|
+
* `buildSandboxMcpConfig` if you already have the URL + token) into
|
|
723
|
+
* the client's MCP config.
|
|
724
|
+
*
|
|
725
|
+
* Security model:
|
|
726
|
+
* - Tokens are capability-scoped JWTs (claim `cap: ["computer_use"]`).
|
|
727
|
+
* - Full sandbox runtime tokens are rejected on `/mcp`; only
|
|
728
|
+
* capability-scoped tokens work there.
|
|
729
|
+
* - A scoped token cannot pivot to admin endpoints (`/exec`, `/files`,
|
|
730
|
+
* etc.) — those routes reject scoped tokens.
|
|
731
|
+
* - Tokens are short-lived. Rotate via `Sandbox#getMcpEndpoint()`,
|
|
732
|
+
* which mints a fresh token each call.
|
|
733
|
+
*/
|
|
734
|
+
/** Default name of the MCP server entry — surfaces in the host UI. */
|
|
735
|
+
const SANDBOX_MCP_SERVER_NAME = "tangle-sandbox";
|
|
736
|
+
/**
|
|
737
|
+
* Build the canonical `mcpServers` config for a sandbox MCP endpoint.
|
|
738
|
+
* Pure function — no I/O, no crypto. Use this when you already have a
|
|
739
|
+
* `{ url, authToken }` pair from the API and just want the JSON shape
|
|
740
|
+
* to paste into a host. Most callers should use
|
|
741
|
+
* `Sandbox#getMcpEndpoint()` instead, which fetches a freshly-minted
|
|
742
|
+
* token from the API.
|
|
743
|
+
*/
|
|
744
|
+
function buildSandboxMcpConfig(options) {
|
|
745
|
+
if (!options.sandboxUrl) throw new Error("buildSandboxMcpConfig: sandboxUrl is required");
|
|
746
|
+
if (!options.authToken) throw new Error("buildSandboxMcpConfig: authToken is required");
|
|
747
|
+
const serverName = options.serverName ?? "tangle-sandbox";
|
|
748
|
+
const baseUrl = options.sandboxUrl.replace(/\/+$/, "");
|
|
749
|
+
return {
|
|
750
|
+
serverName,
|
|
751
|
+
config: { mcpServers: { [serverName]: {
|
|
752
|
+
type: "http",
|
|
753
|
+
url: `${baseUrl}/mcp`,
|
|
754
|
+
headers: { Authorization: `Bearer ${options.authToken}` }
|
|
755
|
+
} } }
|
|
756
|
+
};
|
|
757
|
+
}
|
|
758
|
+
/**
|
|
759
|
+
* Default name of the control-plane MCP server entry. Distinct from the per-
|
|
760
|
+
* sandbox runtime server (`SANDBOX_MCP_SERVER_NAME`): the sandbox surface
|
|
761
|
+
* operates INSIDE one sandbox (`run_code`/`exec`/`read`/`write`), while this one
|
|
762
|
+
* operates ACROSS the account (sandboxes, workflows, integrations, usage).
|
|
763
|
+
*/
|
|
764
|
+
const CONTROL_PLANE_MCP_SERVER_NAME = "tangle-control-plane";
|
|
765
|
+
/**
|
|
766
|
+
* Build the canonical `mcpServers` config for the public control-plane MCP
|
|
767
|
+
* endpoint — the JSON a user pastes into Claude Desktop / Cursor / claude-code
|
|
768
|
+
* to drive their Tangle account from their own agent. Pure function; mirrors
|
|
769
|
+
* `buildSandboxMcpConfig` but carries an account API key instead of a per-
|
|
770
|
+
* sandbox capability token.
|
|
771
|
+
*/
|
|
772
|
+
function buildControlPlaneMcpConfig(options) {
|
|
773
|
+
if (!options.platformUrl) throw new Error("buildControlPlaneMcpConfig: platformUrl is required");
|
|
774
|
+
if (!options.apiKey) throw new Error("buildControlPlaneMcpConfig: apiKey is required");
|
|
775
|
+
const serverName = options.serverName ?? "tangle-control-plane";
|
|
776
|
+
const baseUrl = options.platformUrl.replace(/\/+$/, "");
|
|
777
|
+
return {
|
|
778
|
+
serverName,
|
|
779
|
+
config: { mcpServers: { [serverName]: {
|
|
780
|
+
type: "http",
|
|
781
|
+
url: `${baseUrl}/mcp`,
|
|
782
|
+
headers: { Authorization: `Bearer ${options.apiKey}` }
|
|
783
|
+
} } }
|
|
784
|
+
};
|
|
785
|
+
}
|
|
786
|
+
//#endregion
|
|
787
|
+
//#region src/router-search.ts
|
|
788
|
+
const DEFAULT_ROUTER_URL = "https://router.tangle.tools";
|
|
789
|
+
async function fetchTangleRouterSearchConfig(options = {}) {
|
|
790
|
+
const routerUrl = (options.routerUrl ?? DEFAULT_ROUTER_URL).replace(/\/+$/, "");
|
|
791
|
+
const url = new URL(`${routerUrl}/v1/search/config`);
|
|
792
|
+
if (options.provider) url.searchParams.set("provider", options.provider);
|
|
793
|
+
if (options.apiKeyEnv) url.searchParams.set("api_key_env", options.apiKeyEnv);
|
|
794
|
+
if (options.model) url.searchParams.set("model", options.model);
|
|
795
|
+
const res = await (options.fetchImpl ?? fetch)(url);
|
|
796
|
+
if (!res.ok) throw new Error(`Failed to load Tangle Router search config: ${res.status}`);
|
|
797
|
+
const config = await res.json();
|
|
798
|
+
if (config.object !== "search.config") throw new Error("Invalid Tangle Router search config response");
|
|
799
|
+
return config;
|
|
800
|
+
}
|
|
801
|
+
function buildTangleRouterSearchProfile(config, options = {}) {
|
|
802
|
+
return {
|
|
803
|
+
name: options.name ?? "tangle-router-web-search",
|
|
804
|
+
model: { default: options.model ?? config.tcloud.sandboxBackend.model.model },
|
|
805
|
+
permissions: {
|
|
806
|
+
network: "allow",
|
|
807
|
+
mcp: "allow"
|
|
808
|
+
},
|
|
809
|
+
mcp: { tangle_web_search: {
|
|
810
|
+
transport: "http",
|
|
811
|
+
url: config.mcp.streamable_http_url,
|
|
812
|
+
headers: config.mcp.headers,
|
|
813
|
+
enabled: true
|
|
814
|
+
} },
|
|
815
|
+
metadata: {
|
|
816
|
+
tangleRouterSearchProvider: config.default_provider,
|
|
817
|
+
tangleRouterSearchEndpoint: config.endpoint.url
|
|
818
|
+
}
|
|
819
|
+
};
|
|
820
|
+
}
|
|
821
|
+
function buildTangleRouterSearchBackend(config, options = {}) {
|
|
822
|
+
const model = config.tcloud.sandboxBackend.model;
|
|
823
|
+
return {
|
|
824
|
+
type: options.type ?? "opencode",
|
|
825
|
+
profile: options.profile ?? buildTangleRouterSearchProfile(config),
|
|
826
|
+
model: {
|
|
827
|
+
provider: model.provider,
|
|
828
|
+
model: model.model,
|
|
829
|
+
baseUrl: model.baseUrl,
|
|
830
|
+
...options.apiKey ? { apiKey: options.apiKey } : {}
|
|
831
|
+
}
|
|
832
|
+
};
|
|
833
|
+
}
|
|
834
|
+
function buildTangleRouterEvalMatrixRequest(config, overrides = {}) {
|
|
835
|
+
return {
|
|
836
|
+
url: config.eval_matrix.url,
|
|
837
|
+
body: {
|
|
838
|
+
...config.eval_matrix.body_template,
|
|
839
|
+
...overrides
|
|
840
|
+
}
|
|
841
|
+
};
|
|
842
|
+
}
|
|
843
|
+
function buildTangleRouterResponsesWebSearchRequest(config, overrides = {}) {
|
|
844
|
+
const compat = config.openrouter_compat?.responses;
|
|
845
|
+
if (compat) return {
|
|
846
|
+
url: compat.url,
|
|
847
|
+
body: {
|
|
848
|
+
...compat.body,
|
|
849
|
+
...overrides
|
|
850
|
+
}
|
|
851
|
+
};
|
|
852
|
+
const model = config.tcloud.sandboxBackend.model;
|
|
853
|
+
return {
|
|
854
|
+
url: `${model.baseUrl.replace(/\/+$/, "")}/responses`,
|
|
855
|
+
body: {
|
|
856
|
+
model: model.model,
|
|
857
|
+
input: "Search for the latest documentation and answer with citations.",
|
|
858
|
+
tools: [{
|
|
859
|
+
type: "openrouter:web_search",
|
|
860
|
+
parameters: {
|
|
861
|
+
provider: config.default_provider,
|
|
862
|
+
max_results: 5
|
|
863
|
+
}
|
|
864
|
+
}],
|
|
865
|
+
...overrides
|
|
866
|
+
}
|
|
867
|
+
};
|
|
868
|
+
}
|
|
869
|
+
//#endregion
|
|
870
|
+
//#region src/router-eval-matrix-runner.ts
|
|
871
|
+
async function runTangleRouterEvalMatrixInSandbox(options) {
|
|
872
|
+
const fetchFn = options.fetchImpl ?? fetch;
|
|
873
|
+
const request = buildTangleRouterEvalMatrixRequest(options.config, {
|
|
874
|
+
transport: "sandbox-sdk",
|
|
875
|
+
...options.inputOverrides
|
|
876
|
+
});
|
|
877
|
+
const created = await postJson(fetchFn, request.url, options.apiKey, request.body);
|
|
878
|
+
const matrix = created.matrix;
|
|
879
|
+
const cases = await runMatrixCases({
|
|
880
|
+
matrix,
|
|
881
|
+
config: options.config,
|
|
882
|
+
apiKey: options.apiKey,
|
|
883
|
+
sandboxClient: options.sandboxClient,
|
|
884
|
+
concurrency: options.concurrency ?? 3,
|
|
885
|
+
sessionIdPrefix: options.sessionIdPrefix ?? `eval_${created.suite.id}`
|
|
886
|
+
});
|
|
887
|
+
const importResult = await postJson(fetchFn, `${request.url.replace(/\/api\/eval\/matrix$/, "")}/api/eval/suites/${encodeURIComponent(String(created.suite.id))}/runs/import`, options.apiKey, {
|
|
888
|
+
baseline: options.baseline === true,
|
|
889
|
+
cases
|
|
890
|
+
});
|
|
891
|
+
return {
|
|
892
|
+
suite: created.suite,
|
|
893
|
+
matrix,
|
|
894
|
+
cases,
|
|
895
|
+
benchmark: importResult.benchmark ?? [],
|
|
896
|
+
importResult
|
|
897
|
+
};
|
|
898
|
+
}
|
|
899
|
+
async function runMatrixCases(options) {
|
|
900
|
+
const profiles = new Map(options.matrix.agentProfiles.map((p) => [p.id, p]));
|
|
901
|
+
const harnesses = new Map(options.matrix.harnesses.map((h) => [h.id, h]));
|
|
902
|
+
const iterations = Math.max(1, Math.min(10, options.matrix.iterations ?? 1));
|
|
903
|
+
const tasks = [];
|
|
904
|
+
for (let iteration = 0; iteration < iterations; iteration++) for (const scenario of options.matrix.scenarios) tasks.push(() => runOneCase({
|
|
905
|
+
scenario,
|
|
906
|
+
iteration,
|
|
907
|
+
profile: scenario.profile ? profiles.get(scenario.profile) : void 0,
|
|
908
|
+
harness: scenario.harness ? harnesses.get(scenario.harness) : void 0,
|
|
909
|
+
config: options.config,
|
|
910
|
+
apiKey: options.apiKey,
|
|
911
|
+
sandboxClient: options.sandboxClient,
|
|
912
|
+
sessionIdPrefix: options.sessionIdPrefix
|
|
913
|
+
}));
|
|
914
|
+
return parallelLimit(tasks, options.concurrency);
|
|
915
|
+
}
|
|
916
|
+
async function runOneCase(options) {
|
|
917
|
+
const start = Date.now();
|
|
918
|
+
const backend = buildSandboxBackend(options);
|
|
919
|
+
const box = await options.sandboxClient.create({
|
|
920
|
+
name: `eval-${safeId(options.scenario.id).slice(0, 40)}`,
|
|
921
|
+
environment: options.harness?.image,
|
|
922
|
+
image: options.harness?.image,
|
|
923
|
+
backend,
|
|
924
|
+
env: materializeHarnessEnv(options.config, options.harness?.envVars, options.apiKey),
|
|
925
|
+
...options.harness?.gitRepo ? { git: {
|
|
926
|
+
url: options.harness.gitRepo,
|
|
927
|
+
ref: options.harness.gitBranch
|
|
928
|
+
} } : {}
|
|
929
|
+
});
|
|
930
|
+
const sessionId = `${safeId(options.sessionIdPrefix)}_${safeId(options.scenario.id)}_${options.iteration}`;
|
|
931
|
+
try {
|
|
932
|
+
const dispatched = await box.dispatchPrompt(options.scenario.prompt, { sessionId });
|
|
933
|
+
const result = await box.session(dispatched.sessionId).result();
|
|
934
|
+
const testCommand = options.scenario.sandbox?.testCommand ?? options.harness?.testCommand;
|
|
935
|
+
const sandboxResult = testCommand && box.exec ? await runTestCommand(box, dispatched.sessionId, testCommand, options.harness?.timeout) : void 0;
|
|
936
|
+
return buildCaseResult({
|
|
937
|
+
scenario: options.scenario,
|
|
938
|
+
iteration: options.iteration,
|
|
939
|
+
profile: options.profile,
|
|
940
|
+
harness: options.harness,
|
|
941
|
+
sessionId: dispatched.sessionId,
|
|
942
|
+
sandboxId: box.id,
|
|
943
|
+
result,
|
|
944
|
+
sandboxResult,
|
|
945
|
+
durationMs: Date.now() - start,
|
|
946
|
+
env: materializeHarnessEnv(options.config, options.harness?.envVars, options.apiKey)
|
|
947
|
+
});
|
|
948
|
+
} finally {
|
|
949
|
+
await cleanupBox(box);
|
|
950
|
+
}
|
|
951
|
+
}
|
|
952
|
+
function buildSandboxBackend(options) {
|
|
953
|
+
const model = options.config.tcloud.sandboxBackend.model;
|
|
954
|
+
const searchProvider = inferSearchProvider(options.profile);
|
|
955
|
+
const profile = {
|
|
956
|
+
name: options.profile?.name ?? options.profile?.id ?? "tangle-router-benchmark",
|
|
957
|
+
model: { default: options.profile?.model ?? model.model },
|
|
958
|
+
permissions: {
|
|
959
|
+
network: "allow",
|
|
960
|
+
mcp: "allow"
|
|
961
|
+
},
|
|
962
|
+
mcp: { tangle_web_search: {
|
|
963
|
+
transport: "http",
|
|
964
|
+
url: options.config.mcp.streamable_http_url,
|
|
965
|
+
headers: options.config.mcp.headers,
|
|
966
|
+
enabled: searchProvider !== "off"
|
|
967
|
+
} },
|
|
968
|
+
metadata: {
|
|
969
|
+
tangleRouterSearchProvider: searchProvider,
|
|
970
|
+
tangleRouterSearchEndpoint: options.config.endpoint.url,
|
|
971
|
+
tangleRouterEvalHarness: options.harness?.id
|
|
972
|
+
},
|
|
973
|
+
extensions: { tangleRouter: { providerOptions: options.profile?.providerOptions } }
|
|
974
|
+
};
|
|
975
|
+
return {
|
|
976
|
+
type: backendType(options.harness?.id),
|
|
977
|
+
profile,
|
|
978
|
+
model: {
|
|
979
|
+
provider: model.provider,
|
|
980
|
+
model: options.profile?.model ?? model.model,
|
|
981
|
+
baseUrl: model.baseUrl,
|
|
982
|
+
apiKey: options.apiKey
|
|
983
|
+
}
|
|
984
|
+
};
|
|
985
|
+
}
|
|
986
|
+
function buildCaseResult(input) {
|
|
987
|
+
const usage = input.result.usage;
|
|
988
|
+
const failureReason = input.result.error ?? "Sandbox session failed";
|
|
989
|
+
const error = input.result.success ? void 0 : failureReason;
|
|
990
|
+
const passed = input.result.success && (input.sandboxResult ? input.sandboxResult.testsPassed : true);
|
|
991
|
+
const benchmark = input.scenario.benchmark;
|
|
992
|
+
const toolCalls = promptToolCalls(input.result);
|
|
993
|
+
return {
|
|
994
|
+
scenarioId: input.scenario.id,
|
|
995
|
+
prompt: input.scenario.prompt,
|
|
996
|
+
model: input.profile?.model ?? "unknown",
|
|
997
|
+
response: input.result.response ?? "",
|
|
998
|
+
timing: { totalMs: input.durationMs },
|
|
999
|
+
tokens: {
|
|
1000
|
+
input: usage?.inputTokens ?? 0,
|
|
1001
|
+
output: usage?.outputTokens ?? 0,
|
|
1002
|
+
cached: 0,
|
|
1003
|
+
reasoning: 0
|
|
1004
|
+
},
|
|
1005
|
+
cost: promptCost(input.result),
|
|
1006
|
+
judgeCost: 0,
|
|
1007
|
+
score: passed ? 8 : 1,
|
|
1008
|
+
judgeReasoning: passed ? "Terminal sandbox result and required tests passed." : input.sandboxResult && !input.sandboxResult.testsPassed ? "Sandbox test command failed." : failureReason,
|
|
1009
|
+
passed,
|
|
1010
|
+
toolCalls,
|
|
1011
|
+
assertions: [{
|
|
1012
|
+
check: "Terminal sandbox result observed",
|
|
1013
|
+
passed: input.result.success
|
|
1014
|
+
}, ...input.sandboxResult ? [{
|
|
1015
|
+
check: "Sandbox test command passed",
|
|
1016
|
+
passed: input.sandboxResult.testsPassed
|
|
1017
|
+
}] : []],
|
|
1018
|
+
benchmark: {
|
|
1019
|
+
profileId: benchmark?.profileId ?? input.profile?.id,
|
|
1020
|
+
harnessId: benchmark?.harnessId ?? input.harness?.id,
|
|
1021
|
+
transport: benchmark?.transport ?? input.harness?.transport ?? "sandbox-sdk",
|
|
1022
|
+
searchProvider: benchmark?.searchProvider ?? inferSearchProvider(input.profile),
|
|
1023
|
+
searchRequests: benchmarkSearchRequests(input.result, toolCalls),
|
|
1024
|
+
citationCount: benchmarkCitationCount(input.result),
|
|
1025
|
+
artifacts: {
|
|
1026
|
+
...benchmark?.artifacts ?? {},
|
|
1027
|
+
sessionId: input.sessionId,
|
|
1028
|
+
sandboxId: input.sandboxId,
|
|
1029
|
+
...benchmarkEnvArtifacts(input.env),
|
|
1030
|
+
...input.result.traceId ? { traceId: input.result.traceId } : {}
|
|
1031
|
+
}
|
|
1032
|
+
},
|
|
1033
|
+
iteration: input.iteration,
|
|
1034
|
+
error: input.sandboxResult && !input.sandboxResult.testsPassed ? "Sandbox test command failed" : error,
|
|
1035
|
+
sandboxResult: input.sandboxResult
|
|
1036
|
+
};
|
|
1037
|
+
}
|
|
1038
|
+
async function runTestCommand(box, sessionId, command, timeoutSeconds) {
|
|
1039
|
+
if (!box.exec) throw new Error("Router eval sandbox does not support exec");
|
|
1040
|
+
const result = await box.exec(command, {
|
|
1041
|
+
sessionId,
|
|
1042
|
+
timeoutMs: Math.max(1, timeoutSeconds ?? 120) * 1e3
|
|
1043
|
+
});
|
|
1044
|
+
return {
|
|
1045
|
+
exitCode: result.exitCode,
|
|
1046
|
+
stdout: result.stdout.slice(0, 2e3),
|
|
1047
|
+
stderr: result.stderr.slice(0, 1e3),
|
|
1048
|
+
testsPassed: result.exitCode === 0
|
|
1049
|
+
};
|
|
1050
|
+
}
|
|
1051
|
+
async function postJson(fetchFn, url, apiKey, body) {
|
|
1052
|
+
const res = await fetchFn(url, {
|
|
1053
|
+
method: "POST",
|
|
1054
|
+
headers: {
|
|
1055
|
+
authorization: `Bearer ${apiKey}`,
|
|
1056
|
+
"content-type": "application/json",
|
|
1057
|
+
accept: "application/json"
|
|
1058
|
+
},
|
|
1059
|
+
body: JSON.stringify(stripUndefined(body))
|
|
1060
|
+
});
|
|
1061
|
+
const raw = await res.text();
|
|
1062
|
+
const data = raw ? JSON.parse(raw) : null;
|
|
1063
|
+
if (!res.ok) {
|
|
1064
|
+
const message = typeof data?.error === "string" ? data.error : raw.slice(0, 200);
|
|
1065
|
+
throw new Error(`${url} failed (${res.status}): ${message}`);
|
|
1066
|
+
}
|
|
1067
|
+
return data;
|
|
1068
|
+
}
|
|
1069
|
+
async function parallelLimit(tasks, limit) {
|
|
1070
|
+
const out = [];
|
|
1071
|
+
let idx = 0;
|
|
1072
|
+
const workers = Array.from({ length: Math.min(Math.max(1, limit), tasks.length) }, async () => {
|
|
1073
|
+
while (idx < tasks.length) {
|
|
1074
|
+
const current = idx++;
|
|
1075
|
+
const task = tasks[current];
|
|
1076
|
+
if (task === void 0) throw new Error(`Missing router eval task at index ${current}`);
|
|
1077
|
+
out[current] = await task();
|
|
1078
|
+
}
|
|
1079
|
+
});
|
|
1080
|
+
await Promise.all(workers);
|
|
1081
|
+
return out;
|
|
1082
|
+
}
|
|
1083
|
+
function materializeHarnessEnv(config, envVars, apiKey) {
|
|
1084
|
+
return materializeEnv({
|
|
1085
|
+
...config.harness_env ?? {},
|
|
1086
|
+
...envVars ?? {}
|
|
1087
|
+
}, config, apiKey);
|
|
1088
|
+
}
|
|
1089
|
+
function materializeEnv(env, config, apiKey) {
|
|
1090
|
+
const routerUrl = config.tcloud.sandboxBackend.model.baseUrl.replace(/\/v1\/?$/, "");
|
|
1091
|
+
const resolved = /* @__PURE__ */ new Map();
|
|
1092
|
+
for (const [key, raw] of Object.entries(env)) resolved.set(key, replaceEnvTokens(raw, apiKey, routerUrl, resolved));
|
|
1093
|
+
return Object.fromEntries(resolved);
|
|
1094
|
+
}
|
|
1095
|
+
function replaceEnvTokens(value, apiKey, routerUrl, resolved) {
|
|
1096
|
+
let out = value.replace(/<tangle-api-key>/g, apiKey).replace(/\$\{TANGLE_API_KEY\}/g, apiKey).replace(/\$\{TANGLE_ROUTER_URL\}/g, routerUrl);
|
|
1097
|
+
for (const [key, resolvedValue] of resolved) out = out.replace(new RegExp(`\\$\\{${escapeRegExp(key)}\\}`, "g"), resolvedValue);
|
|
1098
|
+
return out;
|
|
1099
|
+
}
|
|
1100
|
+
function benchmarkEnvArtifacts(env) {
|
|
1101
|
+
const entries = Object.entries(env).sort(([a], [b]) => a.localeCompare(b));
|
|
1102
|
+
return {
|
|
1103
|
+
harnessEnvKeys: entries.map(([key]) => key).join(","),
|
|
1104
|
+
harnessEnvHash: stableHash(entries.map(([key, value]) => `${key}=${redactEnvValue(key, value)}`).join("\n")),
|
|
1105
|
+
harnessEnv: JSON.stringify(Object.fromEntries(entries.map(([key, value]) => [key, redactEnvValue(key, value)])))
|
|
1106
|
+
};
|
|
1107
|
+
}
|
|
1108
|
+
function redactEnvValue(key, value) {
|
|
1109
|
+
if (/token|secret|key|authorization/i.test(key)) return "<redacted>";
|
|
1110
|
+
if (/^Bearer\s+/i.test(value)) return "Bearer <redacted>";
|
|
1111
|
+
return value.length > 500 ? `${value.slice(0, 500)}...` : value;
|
|
1112
|
+
}
|
|
1113
|
+
function stableHash(value) {
|
|
1114
|
+
let hash = 2166136261;
|
|
1115
|
+
for (let i = 0; i < value.length; i += 1) {
|
|
1116
|
+
hash ^= value.charCodeAt(i);
|
|
1117
|
+
hash = Math.imul(hash, 16777619);
|
|
1118
|
+
}
|
|
1119
|
+
return (hash >>> 0).toString(16).padStart(8, "0");
|
|
1120
|
+
}
|
|
1121
|
+
function escapeRegExp(value) {
|
|
1122
|
+
return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
1123
|
+
}
|
|
1124
|
+
function inferSearchProvider(profile) {
|
|
1125
|
+
const search = profile?.providerOptions?.gateway?.webSearch;
|
|
1126
|
+
if (search === false) return "off";
|
|
1127
|
+
if (search && typeof search === "object" && typeof search.provider === "string") return search.provider;
|
|
1128
|
+
return "default";
|
|
1129
|
+
}
|
|
1130
|
+
function promptCost(result) {
|
|
1131
|
+
const raw = result;
|
|
1132
|
+
const cost = typeof raw.costUsd === "number" ? raw.costUsd : raw.cost;
|
|
1133
|
+
return typeof cost === "number" && Number.isFinite(cost) && cost > 0 ? cost : 0;
|
|
1134
|
+
}
|
|
1135
|
+
function promptToolCalls(result) {
|
|
1136
|
+
const raw = result;
|
|
1137
|
+
if (Array.isArray(raw.toolCalls)) return raw.toolCalls;
|
|
1138
|
+
if (Array.isArray(raw.toolInvocations)) return raw.toolInvocations;
|
|
1139
|
+
return [];
|
|
1140
|
+
}
|
|
1141
|
+
function benchmarkSearchRequests(result, toolCalls) {
|
|
1142
|
+
const raw = result;
|
|
1143
|
+
const explicit = typeof raw.searchRequests === "number" ? raw.searchRequests : typeof raw.metadata?.searchRequests === "number" ? raw.metadata.searchRequests : void 0;
|
|
1144
|
+
if (explicit !== void 0) return Math.max(0, explicit);
|
|
1145
|
+
return toolCalls.filter((call) => {
|
|
1146
|
+
const c = call;
|
|
1147
|
+
return String(c.name ?? c.toolName ?? c.type ?? "").toLowerCase().includes("search");
|
|
1148
|
+
}).length;
|
|
1149
|
+
}
|
|
1150
|
+
function benchmarkCitationCount(result) {
|
|
1151
|
+
const raw = result;
|
|
1152
|
+
if (typeof raw.citationCount === "number") return Math.max(0, raw.citationCount);
|
|
1153
|
+
if (typeof raw.metadata?.citationCount === "number") return Math.max(0, raw.metadata.citationCount);
|
|
1154
|
+
if (Array.isArray(raw.citations)) return raw.citations.length;
|
|
1155
|
+
if (Array.isArray(raw.annotations)) return raw.annotations.filter((a) => {
|
|
1156
|
+
const annotation = a;
|
|
1157
|
+
return annotation.type === "url_citation" || Boolean(annotation.url_citation);
|
|
1158
|
+
}).length;
|
|
1159
|
+
return 0;
|
|
1160
|
+
}
|
|
1161
|
+
function backendType(harnessId) {
|
|
1162
|
+
if (harnessId === "claude-code") return "claude-code";
|
|
1163
|
+
if (harnessId === "codex") return "codex";
|
|
1164
|
+
if (harnessId === "opencode") return "opencode";
|
|
1165
|
+
return "opencode";
|
|
1166
|
+
}
|
|
1167
|
+
function safeId(value) {
|
|
1168
|
+
return value.toLowerCase().replace(/[^a-z0-9_-]+/g, "_").replace(/^_+|_+$/g, "").slice(0, 120) || "cell";
|
|
1169
|
+
}
|
|
1170
|
+
async function cleanupBox(box) {
|
|
1171
|
+
if (box.delete) await box.delete();
|
|
1172
|
+
else if (box.destroy) await box.destroy();
|
|
1173
|
+
}
|
|
1174
|
+
function stripUndefined(value) {
|
|
1175
|
+
if (Array.isArray(value)) return value.map(stripUndefined);
|
|
1176
|
+
if (!value || typeof value !== "object") return value;
|
|
1177
|
+
return Object.fromEntries(Object.entries(value).filter(([, v]) => v !== void 0).map(([k, v]) => [k, stripUndefined(v)]));
|
|
1178
|
+
}
|
|
1179
|
+
//#endregion
|
|
1180
|
+
export { AuthError, CONTROL_PLANE_MCP_SERVER_NAME, CapabilityError, CollaborationClient, CollaborationFileBridge, DEFAULT_SANDBOX_SIZE, Image, ImageBuilder, IntelligenceClient, InteractiveSessionHandle, MANAGE_SANDBOXES_PARAMETERS, MANAGE_SANDBOXES_TOOL_NAME, NetworkError, NotFoundError, PartialFailureError, QuotaError, SANDBOX_MCP_SERVER_NAME, SANDBOX_SIZE_PRESETS, SANDBOX_SIZE_PRESET_NAMES, SandboxClient as Sandbox, SandboxClient, SandboxError, SandboxFleet, SandboxFleetClient, SandboxInstance, SandboxSession, ServerError, StateError, TangleSandboxClient, TimeoutError, ValidationError, applySandboxEventText, buildCollaborationDocumentId, buildControlPlaneMcpConfig, buildSandboxMcpConfig, buildTangleRouterEvalMatrixRequest, buildTangleRouterResponsesWebSearchRequest, buildTangleRouterSearchBackend, buildTangleRouterSearchProfile, buildTraceExportPayload, collectAgentResponseText, createConfidentialSandbox, createManageSandboxesTool, defineAgentProfile, defineGitHubResource, defineInlineResource, exportTraceBundle, fetchTangleRouterSearchConfig, generateAttestationNonce, generateDockerfile, getSandboxEventText, mergeAgentProfiles, normalizeCollaborationPath, normalizeRuntimeBackendConfig, otelTraceIdForTangleTrace, parseCollaborationDocumentId, parseSSEStream, resolveSandboxResources, runTangleRouterEvalMatrixInSandbox, sandboxResourcesForSize, serializeForSidecar, startTeeAttestationHeartbeat, toOtelJson };
|