Skip to content

Commit 02aac49

Browse files
Merge pull request #206946 from eric-urban/eur/call-center-qs
post-call transcription analysis scenario QS
2 parents 734213a + 3d8f792 commit 02aac49

File tree

19 files changed

+449
-9
lines changed

19 files changed

+449
-9
lines changed

articles/cognitive-services/Speech-Service/call-center-overview.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.author: jagoerge
88
ms.service: cognitive-services
99
ms.subservice: speech-service
1010
ms.topic: conceptual
11-
ms.date: 08/10/2022
11+
ms.date: 09/18/2022
1212
---
1313

1414
# Call Center Overview
@@ -21,6 +21,8 @@ Some example scenarios for the implementation of Azure Cognitive Services in cal
2121
- Post-call analytics: Post-call analysis to create insights into customer conversations to improve understanding and support continuous improvement of call handling, optimization of quality assurance and compliance control as well as other insight driven optimizations.
2222

2323
> [!TIP]
24+
> Try the [Post-call transcription and analytics quickstart](/azure/cognitive-services/speech-service/call-center-quickstart).
25+
>
2426
> To deploy a call center transcription solution to Azure with a no-code approach, try the [Ingestion Client](/azure/cognitive-services/speech-service/ingestion-client).
2527
2628
## Cognitive Services features for call centers
@@ -67,7 +69,6 @@ You can find an overview of all Language service features and customization opti
6769

6870
## Next steps
6971

72+
* [Post-call transcription and analytics quickstart](/azure/cognitive-services/speech-service/call-center-quickstart)
7073
* [Try out the Language Studio](https://language.cognitive.azure.com)
71-
* [Explore the Language service features](/azure/cognitive-services/language-service/overview#available-features)
7274
* [Try out the Speech Studio](https://speech.microsoft.com)
73-
* [Explore the Speech service features](/azure/cognitive-services/speech-service/overview)
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
title: "Post-call transcription and analytics quickstart - Speech service"
3+
titleSuffix: Azure Cognitive Services
4+
description: In this quickstart, you perform sentiment analysis and conversation summarization of call center transcriptions.
5+
services: cognitive-services
6+
author: eric-urban
7+
manager: nitinme
8+
ms.service: cognitive-services
9+
ms.subservice: speech-service
10+
ms.topic: quickstart
11+
ms.date: 09/20/2022
12+
ms.author: eur
13+
ms.devlang: csharp
14+
---
15+
16+
# Quickstart: Post-call transcription and analytics
17+
18+
[!INCLUDE [C# include](includes/quickstarts/call-center/csharp.md)]
19+
20+
## Next steps
21+
22+
> [!div class="nextstepaction"]
23+
> [Try the Ingestion Client](ingestion-client.md)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.subservice: speech-service
5+
ms.date: 06/30/2022
6+
ms.topic: include
7+
ms.author: eur
8+
---
9+
10+
> [!div class="checklist"]
11+
> * Azure subscription - [Create one for free](https://azure.microsoft.com/free/cognitive-services)
12+
> * <a href="https://portal.azure.com/#create/Microsoft.CognitiveServicesAllInOne" title="Create a Cognitive Services resource" target="_blank">Create a Cognitive Services multi-service resource</a> in the Azure portal. This quickstart only requires one Cognitive Services [multi-service resource](/azure/cognitive-services/cognitive-services-apis-create-account.md?tabs=multiservice#create-a-new-azure-cognitive-services-resource). The sample code allows you to specify separate <a href="https://portal.azure.com/#create/Microsoft.CognitiveServicesTextAnalytics" title="Create a Language resource" target="_blank">Language</a> and <a href="https://portal.azure.com/#create/Microsoft.CognitiveServicesSpeechServices" title="Create a Speech resource" target="_blank">Speech</a> resource keys.
13+
> * Get the resource key and region. After your Cognitive Services resource is deployed, select **Go to resource** to view and manage keys. For more information about Cognitive Services resources, see [Get the keys for your resource](~/articles/cognitive-services/cognitive-services-apis-create-account.md#get-the-keys-for-your-resource).
14+
15+
> [!IMPORTANT]
16+
> This quickstart requires access to [conversation summarization](/azure/cognitive-services/language-service/summarization/how-to/conversation-summarization). To get access, you must submit an [online request](https://aka.ms/applyforconversationsummarization/) and have it approved.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.topic: include
5+
ms.date: 09/18/2022
6+
ms.author: eur
7+
---
8+
9+
[!INCLUDE [Header](header.md)]
10+
11+
We haven't yet included a call center quickstart for the Speech CLI. Please select another programming language or one of the studios links above to get started.
12+
13+
> [!TIP]
14+
> To deploy a call center transcription solution to Azure with a no-code approach, try the [Ingestion Client](/azure/cognitive-services/speech-service/ingestion-client).
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.topic: include
5+
ms.date: 09/18/2022
6+
ms.author: eur
7+
---
8+
9+
[!INCLUDE [Header](header.md)]
10+
11+
[!INCLUDE [Introduction](intro.md)]
12+
13+
## Prerequisites
14+
15+
[!INCLUDE [Prerequisites](azure-prerequisites.md)]
16+
17+
## Set up the environment
18+
19+
This quickstart requires *nlohmann::json*, *libcurl*, and a PEM certificate.
20+
21+
1. Download the latest version of the [nlohmann::json](https://github.com/nlohmann/json/releases) library.
22+
1. Install libcurl. On Windows, you install it from [https://curl.se/download.html].
23+
1. Get a `cacert.pem` file from [https://curl.se/ca/cacert.pem](https://curl.se/ca/cacert.pem).
24+
1. Copy YourPathTo\curl\bin\libcurl-x64.def and YourPathTo\curl\bin\libcurl-x64.dll to your project folder.
25+
1. Run the `lib /def:libcurl-x64.def` command to generate the `.lib` file.
26+
27+
## Run post-call transcription analysis
28+
29+
Follow these steps to run post-call transcription analysis:
30+
31+
1. Download or copy the <a href="https://github.com/Azure-Samples/cognitive-services-speech-sdk/tree/master/scenarios/cpp/windows/call-center" title="Copy the samples" target="_blank">scenarios/cpp/windows/call-center/</a> sample files from GitHub into a local directory.
32+
1. Open the `call-center.sln` solution file in Visual Studio.
33+
1. Open **Project** > **Properties** > **General**. Set **Configuration** to `All configurations`. Set **C++ Language Standard** to `ISO C++17 Standard (/std:c++17)`.
34+
1. Open **Build** > **Configuration Manager**.
35+
- On a 64-bit Windows installation, set **Active solution platform** to `x64`.
36+
- On a 32-bit Windows installation, set **Active solution platform** to `x86`.
37+
1. Open **Project** > **Properties** > **Debugging**. Enter your preferred command line arguments at **Command Arguments**. See [usage and arguments](#usage-and-arguments) for the available options. Here's an example:
38+
```
39+
--certificate "YourPathTo\\cacert.pem" --input "https://github.com/Azure-Samples/cognitive-services-speech-sdk/raw/main/scenarios/call-center/sampledata/Call1_separated_16k_health_insurance.wav" --speechKey YourResourceKey --speechRegion YourResourceRegion --languageKey YourResourceKey --languageEndpoint YourResourceEndpoint --stereo --output call.output.txt > call.json.txt
40+
```
41+
Replace `YourResourceKey` with your Cognitive Services resource key, replace `YourResourceRegion` with your Cognitive Services resource [region](~/articles/cognitive-services/speech-service/regions.md) (such as `eastus`), and replace `YourResourceEndpoint` with your Cognitive Services endpoint. Make sure that the paths specified by `--input` and `--output` are valid. Otherwise you must change the paths.
42+
43+
> [!IMPORTANT]
44+
> Remember to remove the key from your code when you're done, and never post it publicly. For production, use a secure way of storing and accessing your credentials like [Azure Key Vault](../../../../../key-vault/general/overview.md). See the Cognitive Services [security](../../../../cognitive-services-security.md) article for more information.
45+
46+
1. [Build and run](/cpp/build/vscpp-step-2-build) the console application. The default console output is a combination of the JSON responses from the [batch transcription](/azure/cognitive-services/speech-service/batch-transcription) (Speech), [sentiment](/azure/cognitive-services/language-service/sentiment-opinion-mining/overview) (Language), and [conversation summarization](/azure/cognitive-services/language-service/summarization/overview?tabs=conversation-summarization) (Language) APIs. If you specify `--output FILE`, a better formatted version of the results is written to the file.
47+
48+
## Usage and arguments
49+
50+
Usage: `call-center -- [...]`
51+
52+
[!INCLUDE [Usage arguments](usage-arguments.md)]
53+
54+
## Clean up resources
55+
56+
[!INCLUDE [Delete resource](delete-resource.md)]
57+
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.topic: include
5+
ms.date: 09/18/2022
6+
ms.author: eur
7+
ms.devlang: csharp
8+
---
9+
10+
[!INCLUDE [Header](header.md)]
11+
12+
[!INCLUDE [Introduction](intro.md)]
13+
14+
## Prerequisites
15+
16+
[!INCLUDE [Prerequisites](azure-prerequisites.md)]
17+
18+
## Run post-call transcription analysis with C#
19+
20+
Follow these steps to run post-call transcription analysis from an audio file.
21+
22+
1. Copy the <a href="https://github.com/Azure-Samples/cognitive-services-speech-sdk/tree/master/scenarios/csharp/dotnetcore/call-center/" title="Copy the samples" target="_blank">scenarios/csharp/dotnetcore/call-center/</a> sample files from GitHub. If you have [Git installed](https://git-scm.com/downloads), open a command prompt and run the `git clone` command to download the Speech SDK samples repository.
23+
```dotnetcli
24+
git clone https://github.com/Azure-Samples/cognitive-services-speech-sdk.git
25+
```
26+
1. Open a command prompt and change to the project directory.
27+
```dotnetcli
28+
cd <your-local-path>/scenarios/csharp/dotnetcore/call-center/call-center/
29+
```
30+
1. Build the project with the .NET CLI.
31+
```dotnetcli
32+
dotnet build
33+
```
34+
1. Run the application with your preferred command line arguments. See [usage and arguments](#usage-and-arguments) for the available options. Here is an example:
35+
```dotnetcli
36+
dotnet run --languageKey YourResourceKey --languageEndpoint YourResourceEndpoint --speechKey YourResourceKey --speechRegion YourResourceRegion --input "https://github.com/Azure-Samples/cognitive-services-speech-sdk/raw/master/scenarios/call-center/sampledata/Call1_separated_16k_health_insurance.wav" --stereo --output summary.txt
37+
```
38+
Replace `YourResourceKey` with your Cognitive Services resource key, replace `YourResourceRegion` with your Cognitive Services resource [region](~/articles/cognitive-services/speech-service/regions.md) (such as `eastus`), and replace `YourResourceEndpoint` with your Cognitive Services endpoint. Make sure that the paths specified by `--input` and `--output` are valid. Otherwise you must change the paths.
39+
40+
> [!IMPORTANT]
41+
> Remember to remove the key from your code when you're done, and never post it publicly. For production, use a secure way of storing and accessing your credentials like [Azure Key Vault](../../../../../key-vault/general/overview.md). See the Cognitive Services [security](../../../../cognitive-services-security.md) article for more information.
42+
43+
## Check results
44+
45+
The console output shows the full conversation and summary. Here's an example of the overall summary:
46+
47+
```output
48+
Conversation summary:
49+
Issue: Customer wants to sign up for insurance.
50+
Resolution: Helped customer to sign up for insurance.
51+
```
52+
53+
If you specify `--output FILE`, a JSON version of the results are written to the file. The file output is a combination of the JSON responses from the [batch transcription](/azure/cognitive-services/speech-service/batch-transcription) (Speech), [sentiment](/azure/cognitive-services/language-service/sentiment-opinion-mining/overview) (Language), and [conversation summarization](/azure/cognitive-services/language-service/summarization/overview?tabs=conversation-summarization) (Language) APIs.
54+
55+
The `transcription` property contains a JSON object with the results of sentiment analysis merged with batch transcription. Here's an example, with redactions for brevity:
56+
```json
57+
{
58+
"source": "https://github.com/Azure-Samples/cognitive-services-speech-sdk/raw/master/scenarios/call-center/sampledata/Call1_separated_16k_health_insurance.wav",
59+
// Example results redacted for brevity
60+
"nBest": [
61+
{
62+
"confidence": 0.77464247,
63+
"lexical": "hello thank you for calling contoso who am i speaking with today",
64+
"itn": "hello thank you for calling contoso who am i speaking with today",
65+
"maskedITN": "hello thank you for calling contoso who am i speaking with today",
66+
"display": "Hello, thank you for calling Contoso. Who am I speaking with today?",
67+
"sentiment": {
68+
"positive": 0.78,
69+
"neutral": 0.21,
70+
"negative": 0.01
71+
}
72+
},
73+
]
74+
// Example results redacted for brevity
75+
}
76+
```
77+
78+
The `conversationAnalyticsResults` property contains a JSON object with the results of the conversation summarization analysis. Here's an example, with redactions for brevity:
79+
```json
80+
{
81+
"conversationSummaryResults": {
82+
}
83+
// Example results redacted for brevity
84+
}
85+
```
86+
87+
## Usage and arguments
88+
89+
Usage: `call-center -- [...]`
90+
91+
[!INCLUDE [Usage arguments](usage-arguments.md)]
92+
93+
94+
## Clean up resources
95+
96+
[!INCLUDE [Delete resource](delete-resource.md)]
97+
98+
99+
100+
101+
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.subservice: speech-service
5+
ms.topic: include
6+
ms.date: 01/25/2022
7+
ms.author: eur
8+
---
9+
10+
You can use the [Azure portal](~/articles/cognitive-services/cognitive-services-apis-create-account.md#clean-up-resources) or [Azure Command Line Interface (CLI)](~/articles/cognitive-services/cognitive-services-apis-create-account-cli.md#clean-up-resources) to remove the Cognitive Services resource you created.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.topic: include
5+
ms.date: 09/18/2022
6+
ms.author: eur
7+
---
8+
9+
[!INCLUDE [Header](header.md)]
10+
11+
We haven't yet included a call center quickstart in Go. Please select another programming language or one of the studios links above to get started.
12+
13+
> [!TIP]
14+
> To deploy a call center transcription solution to Azure with a no-code approach, try the [Ingestion Client](/azure/cognitive-services/speech-service/ingestion-client).
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.subservice: speech-service
5+
ms.date: 02/04/2022
6+
ms.topic: include
7+
ms.author: eur
8+
---
9+
10+
[Language service documentation](/azure/cognitive-services/language-service/) | [Language Studio](https://aka.ms/LanguageStudio) | [Speech service documentation](/azure/cognitive-services/speech-service/) | [Speech Studio](https://aka.ms/SpeechStudio)
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
author: eric-urban
3+
ms.service: cognitive-services
4+
ms.topic: include
5+
ms.date: 09/18/2022
6+
ms.author: eur
7+
---
8+
9+
In this C# quickstart, you perform sentiment analysis and conversation summarization of [call center](/azure/cognitive-services/speech-service/call-center-overview) transcriptions. The sample will automatically identify, categorize, and redact sensitive information. The quickstart implements a cross-service scenario that uses features of the [Azure Cognitive Speech](/azure/cognitive-services/speech-service/) and [Azure Cognitive Language](/azure/cognitive-services/language-service/) services.
10+
11+
> [!TIP]
12+
> To deploy a call center transcription solution to Azure with a no-code approach, try the [Ingestion Client](/azure/cognitive-services/speech-service/ingestion-client).
13+
14+
The following Azure Cognitive Services for Speech features are used:
15+
- [Batch transcription](/azure/cognitive-services/speech-service/batch-transcription): Submit a batch of audio files for transcription.
16+
- [Speaker separation](/azure/cognitive-services/speech-service/batch-transcription): Separate multiple speakers through diarization of mono 16khz 16 bit PCM wav files.
17+
18+
The Language service offers the following features that are used in the quickstart:
19+
20+
- [Personally Identifiable Information (PII) extraction and redaction](/azure/cognitive-services/language-service/personally-identifiable-information/how-to-call-for-conversations): Identify, categorize, and redact sensitive information in conversation transcription.
21+
- [Conversation summarization](/azure/cognitive-services/language-service/summarization/overview?tabs=conversation-summarization): Summarize in abstract text what each conversation participant said about the issues and resolutions. For example, a call center can group product issues that have a high volume.
22+
- [Sentiment analysis and opinion mining](/azure/cognitive-services/language-service/sentiment-opinion-mining/overview): Analyze transcriptions and associate positive, neutral, or negative sentiment at the utterance and conversation-level.

0 commit comments

Comments
 (0)