refactor: remove retry_count from ProviderConfig and enhance error handling in tool execution

- Removed the `retry_count` field from `ProviderConfig` as it is no longer needed.
- Introduced `argument_error` field in `ToolCall` to capture errors related to tool arguments.
- Updated various components to handle argument errors more gracefully, including in the `ToolDispatcher` and `ConversationOutput`.
- Enhanced tests to validate the new error handling and ensure proper functionality of tool calls.
This commit is contained in:
leokun
2026-09-01 10:14:53 +08:00
parent 29fde7d7c7
commit d83e14af9a
38 changed files with 1105 additions and 444 deletions
+1
View File
@@ -1580,6 +1580,7 @@ fn text_response(text: &str) -> Vec<ModelEvent> {
ModelEvent::TextEnd,
ModelEvent::Usage(Usage {
input_tokens: Some(1),
context_input_tokens: Some(1),
output_tokens: Some(1),
total_tokens: Some(2),
..Default::default()