Skip to content

Create speech-to-speech voice agents that deliver personalized self-service experiences and natural-sounding voices, seamlessly integrated with telephony systems.

License

Notifications You must be signed in to change notification settings

ArcherAZ/call-center-voice-agent-accelerator

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Voice Live Agent Template with Web and ACS Clients

Lightweight template to test real-time voice calls using Azure Communication Services (ACS) Call Automation + Azure Voice Live API โ€” no PSTN number needed. Start locally with uv run, deploy later to Azure Web App.

This sample demonstrates how to build a real-time voice assistant using the Azure Speech Voice Live API, now in public preview.

The solution includes:

  • A backend service that connects to the Voice Live API for real-time ASR, LLM and TTS
  • Two client options: Web browser (microphone/speaker) and Azure Communication Services (ACS) phone calls
  • Flexible configuration to customize prompts, ASR, TTS, and behavior
  • Easy extension to other client types such as Audiohook

You can also try the Voice Live API via Azure AI Foundry for quick experimentation before deploying this template to your own Azure subscription.

Architecture

Architecture Diagram

Get Started

Prerequisites

Deployment and setup

  1. Sign up for a free Azure account and create an Azure Subscription.

  2. Login to Azure:

    azd auth login
  3. Provision and deploy all the resources:

    azd up

    It will prompt you to provide an azd environment name (like "flask-app"), select a subscription from your Azure account, and select a location (like "eastus"). Then it will provision the resources in your account and deploy the latest code. If you get an error with deployment, changing the location can help, as there may be availability constraints for some of the resources.

  4. When azd has finished deploying, you'll see an endpoint URI in the command output. Visit that URI, and you should see the API output! ๐ŸŽ‰

  5. When you've made any changes to the app code, you can just run:

    azd deploy

Note

AZD will also setup the local Python environment for you, using venv and installing the required packages.

Note

  • Region: swedencentral is strongly recommended due to AI Foundry availability.
  • Post-Deployment: You can also setup ACS Event Grid subscription and PSTN to use the ACS client.

Test the Agent

After deployment, you can verify that your Voice Agent is running correctly using either the Web Client (for quick testing) or the ACS Phone Client (for simulating a real-world call center scenario).

๐ŸŒ Web Client (Test Mode)

Use this browser-based client to confirm your Container App is up and responding.

  1. Go to the Azure Portal and navigate to the Resource Group created by your deployment.
  2. Find and open the Container App resource.
  3. On the Overview page, copy the Application URL.
  4. Open the URL in your browser โ€” a demo webpage should load.
  5. Click Start Talking to Agent to begin a voice session using your browserโ€™s microphone and speaker.
  6. Click Stop Conversation to end the session.

โš ๏ธ This web client is intended for testing purposes only. Use the ACS client below for production-like call flow testing.

๐Ÿ“ž ACS Client (Call Center Scenario)

This simulates a real inbound phone call to your voice agent using Azure Communication Services (ACS).

1. Set Up Incoming Call Webhook

  1. In the same resource group, find and open the Communication Services resource.

  2. In the left-hand menu, click Events.

  3. Click + Event Subscription and fill in the following:

    • Event Type: IncomingCall
    • Endpoint Type: Web Hook
    • Endpoint Address:
      https://<your-container-app-url>/acs/incomingcall
      
      Replace <your-container-app-url> with the Application URL from your Container App.

๐Ÿ“ธ Refer to the screenshot below for guidance:

Event Subscription screenshot

2. Get a Phone Number

If you haven't already, obtain a phone number for your ACS resource:

๐Ÿ‘‰ How to get a phone number (Microsoft Docs)

3. Call the Agent

Once your event subscription is configured and the phone number is active:

  • Dial the ACS number.
  • Your call will connect to the real-time voice agent powered by Azure Voice Live.

Clean up resources

When you no longer need the resources created in this article, run the following command to power down the app:

azd down

If you want to redeploy to a different region, delete the .azure directory before running azd up again. In a more advanced scenario, you could selectively edit files within the .azure directory to change the region.

Local execution

Once the environment has been deployed with azd up you can also run the application locally.

Please follow the instructions in the instructions in service

Contributing

This project welcomes contributions and suggestions. Please see CONTRIBUTING.md for details.

License

This project is licensed under the MIT License. See LICENSE.md for details.

About

Create speech-to-speech voice agents that deliver personalized self-service experiences and natural-sounding voices, seamlessly integrated with telephony systems.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 43.1%
  • Bicep 38.4%
  • HTML 14.0%
  • Dockerfile 2.6%
  • JavaScript 1.9%