mirror of
https://github.com/microsoft/autogen.git
synced 2026-04-20 03:02:16 -04:00
[.Net] update oai tests by using new OpenAI resources (#2939)
* update oai tests * Update MetaInfo.props
This commit is contained in:
@@ -22,11 +22,11 @@ internal static class LLMConfiguration
|
||||
return new OpenAIConfig(openAIKey, modelId);
|
||||
}
|
||||
|
||||
public static AzureOpenAIConfig GetAzureOpenAIGPT3_5_Turbo(string deployName = "gpt-35-turbo-16k")
|
||||
public static AzureOpenAIConfig GetAzureOpenAIGPT3_5_Turbo(string? deployName = null)
|
||||
{
|
||||
var azureOpenAIKey = Environment.GetEnvironmentVariable("AZURE_OPENAI_API_KEY") ?? throw new Exception("Please set AZURE_OPENAI_API_KEY environment variable.");
|
||||
var endpoint = Environment.GetEnvironmentVariable("AZURE_OPENAI_ENDPOINT") ?? throw new Exception("Please set AZURE_OPENAI_ENDPOINT environment variable.");
|
||||
|
||||
deployName = deployName ?? Environment.GetEnvironmentVariable("AZURE_OPENAI_DEPLOY_NAME") ?? throw new Exception("Please set AZURE_OPENAI_DEPLOY_NAME environment variable.");
|
||||
return new AzureOpenAIConfig(endpoint, deployName, azureOpenAIKey);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user