We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9739359 commit a77be48Copy full SHA for a77be48
1 file changed
kotlin/java/com/google/ai/edge/litertlm/Conversation.kt
@@ -320,7 +320,12 @@ class Conversation(
320
addProperty("name", functionName)
321
add("response", result)
322
}
323
- toolResponsesJSONArray.add(toolResponseJSONObject)
+ val toolResponseWithTypeJSONObject =
324
+ JsonObject().apply {
325
+ addProperty("type", "tool_response")
326
+ add("tool_response", toolResponseJSONObject)
327
+ }
328
+ toolResponsesJSONArray.add(toolResponseWithTypeJSONObject)
329
330
return JsonObject().apply {
331
addProperty("role", "tool")
0 commit comments