Best practice guidance is to use keyless authentication with Azure resources, and we'll soon publish this guidance in our AI docs as well. We should update the demo to use a recommended pattern for this. For example, here's the default approach, using the Azure.Identity library, that is included in the upcoming doc:
Kernel kernel = Kernel
.CreateBuilder()
.AddAzureOpenAITextGeneration(
"your-model",
"your-endpoint",
new DefaultAzureCredential())
.Build();
This does increase some complexity in configuring the application, which for other samples we include in the infra code that's published with AZD. Perhaps there's a good practice for this with Aspire already, I just haven't dived in there yet - Filing the issue for now so I don't forget.
Best practice guidance is to use keyless authentication with Azure resources, and we'll soon publish this guidance in our AI docs as well. We should update the demo to use a recommended pattern for this. For example, here's the default approach, using the Azure.Identity library, that is included in the upcoming doc:
This does increase some complexity in configuring the application, which for other samples we include in the infra code that's published with AZD. Perhaps there's a good practice for this with Aspire already, I just haven't dived in there yet - Filing the issue for now so I don't forget.