(address: string, args: unknown)
| 89 | ); |
| 90 | |
| 91 | const invokeByAddressCode = (address: string, args: unknown) => ` |
| 92 | const segments = ${JSON.stringify(address)}.split(".").slice(1); |
| 93 | let node = tools; |
| 94 | for (const segment of segments) node = node[segment]; |
| 95 | const result = await node(${JSON.stringify(args)}); |
| 96 | return JSON.stringify(result); |
| 97 | `; |
| 98 | |
| 99 | /** The ToolResult envelope every sandbox tool call resolves to. */ |
| 100 | type ToolEnvelope = { |
no outgoing calls
no test coverage detected