list_realtime_contact_analysis_segments
(**kwargs)¶Provides a list of analysis segments for a real-time analysis session.
See also: AWS API Documentation
Request Syntax
response = client.list_realtime_contact_analysis_segments(
InstanceId='string',
ContactId='string',
MaxResults=123,
NextToken='string'
)
[REQUIRED]
The identifier of the Amazon Connect instance.
[REQUIRED]
The identifier of the contact.
dict
Response Syntax
{
'Segments': [
{
'Transcript': {
'Id': 'string',
'ParticipantId': 'string',
'ParticipantRole': 'string',
'Content': 'string',
'BeginOffsetMillis': 123,
'EndOffsetMillis': 123,
'Sentiment': 'POSITIVE'|'NEUTRAL'|'NEGATIVE',
'IssuesDetected': [
{
'CharacterOffsets': {
'BeginOffsetChar': 123,
'EndOffsetChar': 123
}
},
]
},
'Categories': {
'MatchedCategories': [
'string',
],
'MatchedDetails': {
'string': {
'PointsOfInterest': [
{
'BeginOffsetMillis': 123,
'EndOffsetMillis': 123
},
]
}
}
}
},
],
'NextToken': 'string'
}
Response Structure
(dict) --
Segments (list) --
An analyzed transcript or category.
(dict) --
An analyzed segment for a real-time analysis session.
Transcript (dict) --
The analyzed transcript.
Id (string) --
The identifier of the transcript.
ParticipantId (string) --
The identifier of the participant.
ParticipantRole (string) --
The role of participant. For example, is it a customer, agent, or system.
Content (string) --
The content of the transcript.
BeginOffsetMillis (integer) --
The beginning offset in the contact for this transcript.
EndOffsetMillis (integer) --
The end offset in the contact for this transcript.
Sentiment (string) --
The sentiment of the detected for this piece of transcript.
IssuesDetected (list) --
List of positions where issues were detected on the transcript.
(dict) --
Potential issues that are detected based on an artificial intelligence analysis of each turn in the conversation.
CharacterOffsets (dict) --
The offset for when the issue was detected in the segment.
BeginOffsetChar (integer) --
The beginning of the issue.
EndOffsetChar (integer) --
The end of the issue.
Categories (dict) --
The matched category rules.
MatchedCategories (list) --
The category rules that have been matched in the analyzed segment.
MatchedDetails (dict) --
The category rule that was matched and when it occurred in the transcript.
(string) --
(dict) --
Provides information about the category rule that was matched.
PointsOfInterest (list) --
The section of audio where the category rule was detected.
(dict) --
The section of the contact audio where that category rule was detected.
BeginOffsetMillis (integer) --
The beginning offset in milliseconds where the category rule was detected.
EndOffsetMillis (integer) --
The ending offset in milliseconds where the category rule was detected.
NextToken (string) --
If there are additional results, this is the token for the next set of results. If response includes nextToken
there are two possible scenarios:
If response does not include nextToken
, the analysis is completed (successfully or failed) and there are no more segments to retrieve.
Exceptions
ConnectContactLens.Client.exceptions.InvalidRequestException
ConnectContactLens.Client.exceptions.AccessDeniedException
ConnectContactLens.Client.exceptions.ResourceNotFoundException
ConnectContactLens.Client.exceptions.InternalServiceException
ConnectContactLens.Client.exceptions.ThrottlingException