You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Accumulate the token usage when toolcalling is invoked
- Fix both call() and stream() methods
- Add `usage` field to the Chat completion choice as the usage is returned via Choice
- Add Mootshot chatmodel ITs for functioncalling tests
Move the tests into MoonshotChatModelFunctionCallingIT
Copy file name to clipboardExpand all lines: models/spring-ai-moonshot/src/main/java/org/springframework/ai/moonshot/api/MoonshotStreamFunctionCallingHelper.java
Copy file name to clipboardExpand all lines: models/spring-ai-moonshot/src/test/java/org/springframework/ai/moonshot/chat/MoonshotChatModelFunctionCallingIT.java
+73-1Lines changed: 73 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
/*
2
-
* Copyright 2023-2024 the original author or authors.
2
+
* Copyright 2023-2025 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
@@ -17,6 +17,7 @@
17
17
packageorg.springframework.ai.moonshot.chat;
18
18
19
19
importjava.util.ArrayList;
20
+
importjava.util.Arrays;
20
21
importjava.util.List;
21
22
importjava.util.Objects;
22
23
importjava.util.stream.Collectors;
@@ -53,6 +54,33 @@ class MoonshotChatModelFunctionCallingIT {
0 commit comments