GH-2342: Remove unused json-path dependency in spring-ai-openai
Signed-off-by: Barsha Ghosh <barshaghosh.721@gmail.com> Use the proper StringUtils in OpenAiAudioSpeechModel Signed-off-by: Soby Chacko <soby.chacko@broadcom.com>
This commit is contained in:
committed by
Soby Chacko
parent
62cc6f12c0
commit
9de13d1b2f
@@ -55,11 +55,6 @@
|
||||
<version>${project.parent.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.rest-assured</groupId>
|
||||
<artifactId>json-path</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.victools</groupId>
|
||||
<artifactId>jsonschema-generator</artifactId>
|
||||
|
||||
@@ -16,7 +16,6 @@
|
||||
|
||||
package org.springframework.ai.openai;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import reactor.core.publisher.Flux;
|
||||
@@ -35,6 +34,7 @@ import org.springframework.ai.retry.RetryUtils;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.retry.support.RetryTemplate;
|
||||
import org.springframework.util.Assert;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
/**
|
||||
* OpenAI audio speech client implementation for backed by {@link OpenAiAudioApi}.
|
||||
@@ -174,7 +174,7 @@ public class OpenAiAudioSpeechModel implements SpeechModel, StreamingSpeechModel
|
||||
}
|
||||
}
|
||||
|
||||
String input = StringUtils.isNotBlank(options.getInput()) ? options.getInput()
|
||||
String input = StringUtils.hasText(options.getInput()) ? options.getInput()
|
||||
: request.getInstructions().getText();
|
||||
|
||||
OpenAiAudioApi.SpeechRequest.Builder requestBuilder = OpenAiAudioApi.SpeechRequest.builder()
|
||||
|
||||
Reference in New Issue
Block a user