A list of all the spoken audio the Content Safety Detection model flagged.
For each label that was predicted in the results
set, the severity_score_summary
key provides the overall severity of each label in relation to the entire audio file.
Will be either "success"
, or "unavailable"
in the rare case that the Content Safety Detection model failed.
For each label that was predicted in the results
set, the summary
key provides the confidence of each label in relation to the entire audio file. For example, there could be a single result of disasters
with 0.99
confidence, but if this was a single result in a 3 hour audio file, the summary
would show a low confidence for disasters
- indicating that disasters
is not spoken of widely throughout the entire audio file.
Generated using TypeDoc
With Content Safety Detection, AssemblyAI can detect if any of the following sensitive content is spoken in your audio/video files, and pinpoint exactly when and what was spoken:
Simply include the
content_safety
parameter in yourPOST
request when submitting audio files for transcription, and set this parameter totrue
.Interpreting Content Safety Detection Results
Once the transcription is complete, and you get the result, there will be an additional key
content_safety_labels
in the JSON response. Below, we'll drill into the data that is returned in thecontent_safety_labels
key.Understanding Severity Scores and Confidence Scores
Each label will be returned with a
confidence
score and aseverity
score. It is important to note that these two keys measure two very different things. Theseverity
key will produce a score that shows how severe the flagged content is on a scale of0–1
. For example, a natural disaster with mass casualties would be a1
, whereas a wind storm that broke a lamppost would be a0.1
.In comparison,
confidence
displays how confident the model was in predicting the label it predicted, also on a scale of0-1
.We can break this down further by reviewing the following label:
In the above example, the Content Safety model is indicating it is
82.25%
confident that the spoken content is about Health Issues; however, it is measured at a low severity of0.1509
. This means the model is very confident the content is about health issues, but the content was not severe in nature (ie, was likely about a minor health issue).Understanding the Severity Score Summary
The
severity_score_summary
key lists each label that was detected along withlow
,medium
, andhigh
keys.The value of the
low
,medium
, andhigh
keys reflect the API's confidence that the label is "low," "medium," or "high" in severity throughout the entire audio file. This score is based on the intersection of the length of the audio file, the frequency oflow
/medium
/high
severity tags through the file, and theconfidence
score for each of those occurrences.Controlling the Threshold of Surfaced Results
By default, the content safety model will return any label with a confidence of 50% or greater. If you wish to set a higher or lower threshold, simply add the
content_safety_confidence: {number}
parameter to yourPOST
request. This parameter will accept an integer value between25
and100
, inclusive.