(input: unknown, taskBindingAvailable: boolean)
| 296 | } |
| 297 | |
| 298 | function cleanSubagentSpawnInput(input: unknown, taskBindingAvailable: boolean): unknown { |
| 299 | if (!input || typeof input !== 'object' || Array.isArray(input)) return input; |
| 300 | const cleaned = { ...(input as Record<string, unknown>) }; |
| 301 | if (cleaned.subagent_id !== undefined) delete cleaned.profile; |
| 302 | if (!taskBindingAvailable) delete cleaned.task_id; |
| 303 | return cleaned; |
| 304 | } |
| 305 | |
| 306 | async function resolvePresetDefinition( |
| 307 | subagentId: string, |
no outgoing calls
no test coverage detected