(role: string)
| 118 | served.push({ messages, toolNames }); |
| 119 | |
| 120 | const lastOf = (role: string) => |
| 121 | [...messages].reverse().find((message) => message.role === role)?.content; |
| 122 | |
| 123 | let scripted: BrainResponse; |
| 124 | // oxlint-disable-next-line executor/no-try-catch-or-throw -- boundary: a throwing script must surface as a recorded error + a stop response, not a hung agent |