(self, text: String)
| 202 | } |
| 203 | |
| 204 | pub(super) fn finish(self, text: String) -> AgentResult { |
| 205 | AgentResult { |
| 206 | text, |
| 207 | messages: self.messages, |
| 208 | usage: self.total_usage, |
| 209 | tool_calls_count: self.tool_calls_count, |
| 210 | verification_reports: self.verification_reports, |
| 211 | } |
| 212 | } |
| 213 | |
| 214 | /// Build a result from a turn that was cancelled mid-generation. Keeps the |
| 215 | /// conversation accumulated so far (the user's message above all) so the next |
no outgoing calls