File tree Expand file tree Collapse file tree 1 file changed +10
-10
lines changed
colorist/step_06/lib/services Expand file tree Collapse file tree 1 file changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -78,17 +78,17 @@ class GeminiChatService {
7878
7979 if (block.functionCalls.isNotEmpty) {
8080 final geminiTools = ref.read (geminiToolsProvider);
81- final results = < (String , Map <String , Object ?>)> [];
82- for (final functionCall in block.functionCalls) {
83- results.add ((
84- functionCall.name,
85- geminiTools.handleFunctionCall (functionCall.name, functionCall.args),
86- ));
87- }
8881 final responseStream = chatSession.sendMessageStream (
89- Content .functionResponses (
90- results.map ((result) => FunctionResponse (result.$1, result.$2)),
91- ),
82+ Content .functionResponses ([
83+ for (final functionCall in block.functionCalls)
84+ FunctionResponse (
85+ functionCall.name,
86+ geminiTools.handleFunctionCall (
87+ functionCall.name,
88+ functionCall.args,
89+ ),
90+ ),
91+ ]),
9292 );
9393 await for (final response in responseStream) {
9494 final responseText = response.text;
You can’t perform that action at this time.
0 commit comments