Replaced the static placeholder model with the chosen model

This commit is contained in:
Thorsten Sommer 2024-05-19 16:15:20 +02:00
parent bd5daea248
commit 0b66aa7c79
Signed by: tsommer
GPG Key ID: 371BBA77A02C0108

View File

@ -102,7 +102,7 @@ public partial class Chat : ComponentBase
// Use the selected provider to get the AI response.
// By awaiting this line, we wait for the entire
// content to be streamed.
await aiText.CreateFromProviderAsync(this.selectedProvider.UsedProvider.CreateProvider(), this.JsRuntime, this.SettingsManager, new Model("gpt-4o"), this.chatThread);
await aiText.CreateFromProviderAsync(this.selectedProvider.UsedProvider.CreateProvider(this.selectedProvider.InstanceName), this.JsRuntime, this.SettingsManager, this.selectedProvider.Model, this.chatThread);
// Disable the stream state:
this.isStreaming = false;