(
scope: TurnScope,
eventSink: DurableSessionEventSink,
)
| 1342 | } |
| 1343 | |
| 1344 | private createCodeModeExecTool( |
| 1345 | scope: TurnScope, |
| 1346 | eventSink: DurableSessionEventSink, |
| 1347 | ): MakaTool<{ code: string }> { |
| 1348 | return { |
| 1349 | name: 'exec', |
| 1350 | description: [ |
| 1351 | 'Execute a bounded orchestration cell over the active tools.', |
| 1352 | 'Use tools.<name>(args), await dependent calls, and Promise.all for independent calls.', |
| 1353 | 'The sandbox has no process, filesystem, network, timer, eval, import, or cross-cell state.', |
| 1354 | 'Terminate by returning a JSON-serializable value. Failures return a structured diagnostic.', |
| 1355 | ].join(' '), |
| 1356 | parameters: z.object({ code: z.string() }), |
| 1357 | executionSemantics: 'exclusive_step', |
| 1358 | nesting: 'direct_only', |
| 1359 | recoveryMode: 'never_auto_retry', |
| 1360 | impl: (args, context) => this.executeCodeModeCell(scope, eventSink, args.code, context), |
| 1361 | }; |
| 1362 | } |
| 1363 | |
| 1364 | // -------------------------------------------------------------------------- |
| 1365 | // manual history compaction |
no test coverage detected