

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 即時通話分析輸出
<a name="tca-output-streaming"></a>

即時通話分析文字記錄會依區段逐段顯示。其中包括類別事件、問題偵測、情緒，以及 PII 識別和修訂。類別事件可讓您設定即時警示；請參閱 [建立類別配對的即時警示](tca-start-stream.md#tca-create-alert-stream)，了解詳細資訊。

若要提高準確性並進一步根據您的使用案例自訂文字記錄，例如包括產業專用術語，請在您的通話分析要求中新增[自訂詞彙](custom-vocabulary.md)或[自訂語言模型](custom-language-models.md)。若要遮蔽、移除或標記轉錄結果中不想要的字詞 (例如褻瀆性文字)，請新增[字彙篩選](vocabulary-filtering.md)功能。

以下章節顯示即時通話分析轉錄的 JSON 輸出範例。

## 類別事件
<a name="tca-output-category-event-stream"></a>

以下是轉錄輸出中類別配對的外觀。此範例顯示 19010 毫秒時間戳記到 22690 毫秒時間戳記的音訊與「network-complaint」類別相符。在這種情況下，自訂「network-complaint」類別要求客戶說出「*網路問題*」(完全相符的詞)。

```
"CategoryEvent": { 
    "MatchedCategories": [ 
        "network-complaint" 
    ],
    "MatchedDetails": { 
        "network issues" : { 
            "TimestampRanges": [    
                { 
                    "BeginOffsetMillis": 9299375,
                    "EndOffsetMillis": 7899375
                }
            ]
        }
    }
},
```

## 問題偵測
<a name="tca-output-issue-detection-stream"></a>

以下是轉錄輸出中問題偵測配對的外觀。該範例顯示從字元 26 到字元 62 的文字已描述問題。

```
"UtteranceEvent": {
    ...
    "Transcript": "Wang Xiulan I'm tired of the network issues my phone is having.",
    ...
    "IssuesDetected": [
        {
            "CharacterOffsets": {
                "BeginOffsetChar": 26,
                "EndOffsetChar": 62
            }
        }
    ]
},
```

## 情緒
<a name="tca-output-sentiment-stream"></a>

以下是轉錄輸出中情緒分析的外觀。

```
"UtteranceEvent": {    
    ...
    "Sentiment": "NEGATIVE",
    "Items": [{
        ...
```

## PII 識別
<a name="tca-output-pii-id-stream"></a>

以下是轉錄輸出中 PII 識別的外觀。

```
"Entities": [
    {
        "Content": "Wang Xiulan",
        "Category": "PII",
        "Type": "NAME",
        "BeginOffsetMillis": 7999375,
        "EndOffsetMillis": 199375,
        "Confidence": 0.9989
    }
],
```

## PII 修訂
<a name="tca-output-pii-redact-stream"></a>

以下是轉錄輸出中 PII 修訂的外觀。

```
"Content": "[NAME]. Hi, [NAME]. I'm [NAME] Happy to be helping you today.",
"Redaction": {
    "RedactedTimestamps": [
        {
            "BeginOffsetMillis": 32670,
            "EndOffsetMillis": 33343
        }, 
        {
            "BeginOffsetMillis": 33518,
            "EndOffsetMillis": 33858
        }, 
        {
            "BeginOffsetMillis": 34068,
            "EndOffsetMillis": 34488
        }
    ]
},
```

## 語言識別
<a name="tca-output-language-id-stream"></a>

以下是轉錄輸出中語言識別的外觀。

```
{
  "LanguageCode": "en-US",
  "LanguageIdentification": [
    {
      "Code": "en-US",
      "Score": 0.823
    },
    {
      "Code": "de-DE",
      "Score": 0.177
    }
  ]
}
```

## 編譯的即時通話分析輸出
<a name="tca-output-streaming-compiled"></a>

為了簡潔起見，以下轉錄輸出的某些內容將以省略符號取代。

```
{
    "CallAnalyticsTranscriptResultStream": {
        "BadRequestException": {},
        "ConflictException": {},
        "InternalFailureException": {},
        "LimitExceededException": {},
        "ServiceUnavailableException": {},
        "UtteranceEvent": {
            "UtteranceId": "58c27f92-7277-11ec-90d6-0242ac120003",
            "ParticipantRole": "CUSTOMER",
            "IsPartial": false,
            "Transcript": "Wang Xiulan I'm tired of the network issues my phone is having.",
            "BeginOffsetMillis": 19010,
            "EndOffsetMillis": 22690,
            "Sentiment": "NEGATIVE",
            "Items": [{
                    "Content": "Wang",
                    "BeginOffsetMillis": 379937,
                    "EndOffsetMillis": 299375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                {
                    "Content": "Xiulan",
                    "EndOffsetMillis": 5899375,
                    "BeginOffsetMillis": 3899375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                ...
                {
                    "Content": "network",
                    "EndOffsetMillis": 199375,
                    "BeginOffsetMillis": 9299375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                {
                    "Content": "issues",
                    "EndOffsetMillis": 7899375,
                    "BeginOffsetMillis": 5999375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                {
                    "Content": "my",
                    "EndOffsetMillis": 9199375,
                    "BeginOffsetMillis": 7999375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                {
                    "Content": "phone",
                    "EndOffsetMillis": 199375,
                    "BeginOffsetMillis": 9299375,
                    "Type": "pronunciation",
                    "Confidence": 0.9961,
                    "VocabularyFilterMatch": false
                },
                ...
            ],
            "Entities": [{
                "Content": "Wang Xiulan",
                "Category": "PII",
                "Type": "NAME",
                "BeginOffsetMillis": 7999375,
                "EndOffsetMillis": 199375,
                "Confidence": 0.9989
            }],
            "IssuesDetected": [{
                "CharacterOffsets": {
                    "BeginOffsetChar": 26,
                    "EndOffsetChar": 62
                }
            }],
            "LanguageCode": "en-US",
            "LanguageIdentification": [
                {
                    "Code": "en-US",
                    "Score": 0.823
                },
                {
                    "Code": "de-DE",
                    "Score": 0.177
                }
            ]
        },
        "CategoryEvent": { 
            "MatchedCategories": [ 
                "network-complaint" 
            ],
            "MatchedDetails": { 
                "network issues" : { 
                    "TimestampRanges": [    
                        { 
                            "BeginOffsetMillis": 9299375,
                            "EndOffsetMillis": 7899375
                        }
                    ]
                }
            }
        }
    }
}
```