Speech Type model helps you understand the type of conversation at any given time. Every phone call, online or offline conversation can be broadly classified into four categories - Statement, Command, Action Item, or a Question.
Type | Description |
Statement | a definite or clear expression of something in chat |
Command | an authoritative or peremptory order |
Action Item | a chat worded or expressed regarding an event, task, activity, or action that needs to take place |
Question | a chat worded or expressed so as to elicit information |
Input Type Supported: Audio, Video
Model Dependency for Audio Input: Speech to Text, Speaker Separation
speech_type.enable
key is set to true
under the settings
objectTransaction ID
is returned in the JSON body once the processing job is launched successfully.
This Transaction ID
can be used to check the status of the job or fetch the results of the job once the metadata is computed{"status":true,"transaction_id":32dcef1a-5724-4df8-a4a5-fb43c047716b,"message": " Compute job for file-id: 32dcef1a-5724-4df8-a4a5-fb43c047716b launched successfully"}
Speech to Text
has to be enabled for Action Items
to be enabled){"status":false,"error":{"code":"MCST07","message":"DependencyError: emotion_analysis depends on speech_to_text"}}
curl --request POST 'https://api.marsview.ai/v1/conversation/compute' \--header 'appSecret: 32dcef1a-5724-4df8-a4a5-fb43c047716b' \--header 'appId: 1ZrKT0tTv7rVWX-qNAKLc' \--header 'Content-Type: application/json' \--data-raw '{"settings":{"speech_to_text":{"enable":true,"pii_detection":false,"custom_vocabulary":["Marsview" , "Pikachu"]},"speaker_separation":{"enable":true,"num_speakers":4},"speech_type_analysis":{"enable":true}}}'
Given below is a sample response JSON when the Status code is 200.
{"status":true,"transaction_id":32dcef1a-5724-4df8-a4a5-fb43c047716b,"message": " Compute job for file-id: 32dcef1a-5724-4df8-a4a5-fb43c047716b launched successfully"}
data
object returns the requested metadata if it is computed. The status
object shows the current state of the requested metadata. Status for each metadata field can take values "Queued"/"Processing"/"Completed
".
Shown below is a case where "sentiment analysis" Job is in "Queued"
state and "Completed"
state. {"status":{"speech_type_analysis":"Queued",}"data":{"speech_type_analysis":{}}}
{"status":{"speech_type_analysis":"Completed"}"data":{"speech_type_analysis":{"chunks":[...{"start_time" : "174100.0""end_time" : "175100.0","sentence" : "How do I access the Documentation ?","speech_type": "Question","confidence" : "0.33"},{"start_time" : "174100.0""end_time" : "175100.0","sentence": "Make the requested changes on the website by Friday","speech_type": "Action","confidence" :"0.95"},...]}}}
Fields | Description |
| Starting time of the chunk in milliseconds |
| Ending time of the chunk in milliseconds |
| The transcribed sentence from Marsview STT |
| Speech Type label for the Sentence/Chunk |
| Confidence of the speech type label (ranges from 0 to 1). Higher the better |