Benchmarking ASR models (Whisper, Wav2Vec2, SeamlessM4T) on Moroccan Darija medical consultations.
# Darija Medical ASR Benchmark
This repository contains benchmarking code for three speech recognition models on Moroccan Darija medical consultations.
## Methodology
Three speech recognition models were tested on three 15-30 second audio recordings simulating medical consultations:
* **Audio 1**: Pure Moroccan Darija symptoms.
* **Audio 2**: Mixed Darija and French symptoms.
* **Audio 3**: Pure French symptoms.
### Models compared:
* **OpenAI Whisper (large-v3)**: `openai/whisper-large-v3`
* **Facebook wav2vec2-large-xlsr-53**: Fine-tuned `boumehdi/wav2vec2-large-xlsr-moroccan-darija`
* **Meta SeamlessM4T (v2-large)**: `facebook/seamless-m4t-v2-large`
## Transcripts (Reference)
### Transcript 1: Pure Moroccan Darija symptoms
> سلام دكتور، هادي يومين وانا مريض. راسي كيضرني بزاف وكرشي حتا هيا. ما قدرتش نعس فاليل وكيجيني رضان. السخانة طالعة ويديا كيفشلو عليا، مابقا عندي جهد لوالو.
### Transcript 2: Moroccan Darija and French mixed symptoms
> دكتور، فيا la fièvre et راسي كيضرني بزاف. عندي des problèmes respiratoires والصدر ديالي كيحرقني. Je me sens très fatigué وما بقيتش قادر نتنفس مزيان.
### Transcript 3: Pure French symptoms
> Bonjour docteur. J'ai une forte migraine depuis trois jours. J'ai aussi mal à la gorge, une toux sèche persistante et je me sens extrêmement épuisé. La fièvre n'a pas baissé depuis hier matin.
## Setup & Installation
1. Install dependencies:
```bash
pip install -r requirements.txt
```
2. Place your audio files and transcripts in the following structure:
- `audio_files/`: Contains `audio1.wav`, `audio2.wav`, `audio3.wav`
- `original_transcripts/`: Contains `originalTranscript1.txt`, `originalTranscript2.txt`, `originalTranscript3.txt`
- `transcription_output_example/`: (Optional) Contains sample output transcripts for reference.
## Usage
1. **Run Transcription**:
Generate transcripts using the three models.
```bash
python transcribe.py
```
This will produce output files in the `transcription_output/` folder.
2. **Evaluate Perform …