Skip to content

Commit a1b3c86

Browse files
committed
cleanup threads example
1 parent 76e75da commit a1b3c86

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

examples/src/main/kotlin/assistant/Thread.kt

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ fun main() {
6868
when (content) {
6969
is TextContent -> println(content.text.value)
7070
is ImageContent -> println(content.imageFile.fileId)
71-
else -> println("Unhandled content type: $content")
7271
}
7372

7473
}
@@ -78,21 +77,18 @@ fun main() {
7877
for (toolCall in details.toolCalls) {
7978
when (toolCall) {
8079
is FunctionToolCall -> {
81-
80+
// Give the assistant the function output
8281
}
8382
is RetrievalToolCall -> {
84-
83+
// No need to do anything
8584
}
8685
is CodeInterpreterToolCall -> {
86+
// Show the code outputs to the user
8787
}
8888
}
8989
println(toolCall)
9090
}
9191
}
92-
93-
else -> {
94-
println("Unhandled step type: ${step.stepDetails.type}")
95-
}
9692
}
9793
println("Step: $step")
9894
}

0 commit comments

Comments
 (0)