May 28th, 2024

Azure Developer CLI (azd) – Build 2024 Recap

We recently announced our May release of the Azure Developer CLI (azd) and now we have more exciting news to share! As always, you can learn about how to get started with the Azure Developer CLI by visiting our documentation.

Here’s what’s new in azd:

  • Deploy to AI / ML Studio online endpoint
  • AI Template Collection

Last week, Microsoft Build attendees saw azd in many sessions: from Scott Guthrie’s demo of GitHub Copilot for Azure to Jessica Deen and Mandy Whaley’s demo using azd pipeline config to Wendy Breiding and Brady Gaster’s demo of .NET Aspire. If you registered for Build (online or in-person), you can visit the session scheduler to find the recordings for these sessions and many others.

Sessions where you can find azd include:

Deploy to AI/ML studio online endpoint

Now we have enhanced capability for building and deploying apps that utilize AI. That means azd now supports a new host service target to allow seamless deployments of AI/ML applications to AI Studio online endpoints.

This new capability adds a new host type: ai.endpoint. With the AI host specified in your azure.yaml file, you need to include the config.deployment section to create a new online deployment to the associate online endpoint from the referenced YAML file definition. The associated environment and model are referenced when available. Then azd waits for deployment to enter a terminal provisioning state. Upon a successful deployment, all traffic is shifted to the new deployment version and all previous deployments are deleted to free up compute for future deployments.

What else can you specify?

  • Use config.flow to have azd create a new prompt flow from the specified file path
  • Use config.environment to have azd create a new environment version using the referenced YAML file definition
  • Use config.model to have azd create a new model version using the referenced YAML file definition

Here’s an example azure.yaml file using the new AI endpoint service target:

name: contoso-example
metadata:
  template: contoso-example@0.0.1-beta
services:
  chat:
    # Referenced new ai.endpoint host type
    host: ai.endpoint
    # New config flow for AI project configuration
    config:
      # The name of the AI Studio project / workspace
      workspace: ${AZUREAI_PROJECT_NAME}
      # Optional: Path to custom ML environment manifest
      environment:
        path: deployment/docker/environment.yml
      # Optional: Path to your prompt flow folder that contains the flow manifest
      flow:
        path: ./contoso-example
      # Optional: Path to custom model manifest
      model:
        path: deployment/chat-model.yaml
        overrides:
          "properties.azureml.promptflow.source_flow_id": ${AZUREAI_FLOW_NAME}
      # Required: Path to deployment manifest
      deployment:
        path: deployment/chat-deployment.yaml

Learn more about azd support AI endpoint service target.

Note AI endpoint service support is a Beta feature and subject to change. Feedback is more than welcome!

We have many templates that use this new capability coming soon! In the meantime, we have two starter templates that can help accelerate your AI solution development available to use now. These templates can be used to provision the relevant Azure resources and then you can bring in your own app code to deploy.

AI starter template

The AI Starter Template creates an Azure AI services account and provisions models within an ai.yaml configuration file. Keep in mind, this template is meant to be used as a jumping off point, so it only contains Bicep IaC files and doesn’t have application code to deploy.

Run azd init -t Azure-Samples/azd-ai-starter to get started!

AI Studio starter template

The AI Studio starter template creates an AI Studio Hub, AI Services Account, and all other dependent resources. A complete list of the resources that can be created with this starter can be found in the README.

Run azd init -t Azure-Samples/azd-aistudio-starter to get started!

AI model availability

Both of these starter templates are configured to use gpt-35-turbo and text-embedding-ada-002. Model availability varies by Azure region. Before you select your Azure location during azd provision, use Azure OpenAI Service’s model availability table to check where each model is available.

AI Template Collection

We recently added new AI templates to awesome-azd! These templates support various use cases and we can’t wait to see what you build with them.

You can use the Azure Developer CLI from:

Author

0 comments

Discussion are closed.