From 1fe1ec4ac647112dd1e061c2139cd8d86091a925 Mon Sep 17 00:00:00 2001 From: Nikolas Nyby Date: Mon, 8 Jun 2026 08:56:12 -0400 Subject: [PATCH] Adjust azure assessment config * Use grading system 1-100 * Skip prosody assessment * Use word granularity * enable miscue --- absi/main/azure_speech.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/absi/main/azure_speech.py b/absi/main/azure_speech.py index 1040c59..fb44206 100644 --- a/absi/main/azure_speech.py +++ b/absi/main/azure_speech.py @@ -62,9 +62,16 @@ def submit_audio_to_azure(path: str, transcribe_text: str) -> dict | None: ) pronunciation_config = speechsdk.PronunciationAssessmentConfig( - reference_text=transcribe_text) + reference_text=transcribe_text, + grading_system=( + speechsdk.PronunciationAssessmentGradingSystem.HundredMark, + ), + granularity=speechsdk.PronunciationAssessmentGranularity.Word, + enable_miscue=True, + ) - pronunciation_config.enable_prosody_assessment() + # Skip this for now - low support in arabic. + # pronunciation_config.enable_prosody_assessment() pronunciation_config.apply_to(recognizer)