Skip to content

Commit

Permalink
Merge pull request #234 from Yanick-Salzmann/bug/missing-api-version
Browse files Browse the repository at this point in the history
Added apiVersion parameter to AzureOpenAiEmbeddingModel and AzureOpen…
  • Loading branch information
geoand authored Jan 22, 2024
2 parents b53feaa + 8ef8229 commit 5de41ca
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ public Supplier<?> streamingChatModel(Langchain4jAzureOpenAiConfig runtimeConfig
var builder = AzureOpenAiStreamingChatModel.builder()
.baseUrl(getBaseUrl(runtimeConfig))
.apiKey(runtimeConfig.apiKey())
.apiVersion(runtimeConfig.apiVersion())
.timeout(runtimeConfig.timeout())
.logRequests(firstOrDefault(false, chatModelConfig.logRequests(), runtimeConfig.logRequests()))
.logResponses(firstOrDefault(false, chatModelConfig.logResponses(), runtimeConfig.logResponses()))
Expand All @@ -76,6 +77,7 @@ public Supplier<?> embeddingModel(Langchain4jAzureOpenAiConfig runtimeConfig) {
var builder = AzureOpenAiEmbeddingModel.builder()
.baseUrl(getBaseUrl(runtimeConfig))
.apiKey(runtimeConfig.apiKey())
.apiVersion(runtimeConfig.apiVersion())
.timeout(runtimeConfig.timeout())
.maxRetries(runtimeConfig.maxRetries())
.logRequests(firstOrDefault(false, embeddingModelConfig.logRequests(), runtimeConfig.logRequests()))
Expand Down

0 comments on commit 5de41ca

Please sign in to comment.