File tree Expand file tree Collapse file tree 4 files changed +4
-6
lines changed
src/main/java/com/javaaidev/chatagent/springai Expand file tree Collapse file tree 4 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 66 <parent >
77 <groupId >com.javaaidev.llmagentspec</groupId >
88 <artifactId >llm-agent-spec</artifactId >
9- <version >0.4 .0</version >
9+ <version >0.5 .0</version >
1010 </parent >
1111
1212 <artifactId >chat-agent-model</artifactId >
Original file line number Diff line number Diff line change 55 <modelVersion >4.0.0</modelVersion >
66 <groupId >com.javaaidev.llmagentspec</groupId >
77 <artifactId >llm-agent-spec</artifactId >
8- <version >0.4 .0</version >
8+ <version >0.5 .0</version >
99 <packaging >pom</packaging >
1010 <name >LLM Agent Spec</name >
1111 <description >Spec of LLM Agents</description >
Original file line number Diff line number Diff line change 66 <parent >
77 <groupId >com.javaaidev.llmagentspec</groupId >
88 <artifactId >llm-agent-spec</artifactId >
9- <version >0.4 .0</version >
9+ <version >0.5 .0</version >
1010 </parent >
1111
1212 <artifactId >spring-ai-adapter</artifactId >
Original file line number Diff line number Diff line change 2626import org .springframework .http .codec .ServerSentEvent ;
2727import org .springframework .util .CollectionUtils ;
2828import org .springframework .util .MimeType ;
29- import org .springframework .util .StringUtils ;
3029import reactor .core .publisher .Flux ;
3130
3231/**
@@ -103,7 +102,7 @@ public static ChatAgentResponse toResponse(ChatResponse chatResponse) {
103102 var content = new ArrayList <ThreadAssistantMessagePart >();
104103 for (Generation generation : chatResponse .getResults ()) {
105104 var message = generation .getOutput ();
106- if (StringUtils . hasText ( message .getText ()) ) {
105+ if (message .getText () != null ) {
107106 content .add (new TextMessagePart (message .getText ()));
108107 }
109108 extractReasoning (message ).ifPresent (
@@ -130,7 +129,6 @@ private static Optional<String> extractReasoning(AssistantMessage assistantMessa
130129 .map (metadata ::get )
131130 .filter (Objects ::nonNull )
132131 .map (Object ::toString )
133- .filter (StringUtils ::hasText )
134132 .findFirst ();
135133 }
136134
You can’t perform that action at this time.
0 commit comments