Documentation ¶
Overview ¶
Package azure provides helpful types and functions for use with Azure OpenAI.
Index ¶
Constants ¶
View Source
const ( AzureTenantIDKey string = "AZURE_TENANT_ID" AzureOpenAIAPIKey string = "AZURE_OPENAI_API_KEY" AzureOpenAIEndpointKey string = "AZURE_OPENAI_ENDPOINT" AzureOpenAIAPIVersionKey string = "OPENAI_API_VERSION" )
View Source
const (
AzureOpenAIAPIVersionDefault string = "2024-07-01-preview" //"2024-06-01"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { TenantID string OpenAIEndpoint string OpenAIAPIKey string OpenAIAPIVersion string }
Config represents the configuration needed for Azure OpenAI.
func LoadConfig ¶
func LoadConfig() *Config
LoadConfig reads the environment variables and returns a new AzureConfig. This function assumes that the environment variables (for example, from and .env file) are already loaded.
Click to show internal directories.
Click to hide internal directories.