Logo Lanfrica

DewofyourYouth/daily_derja_tools

Domaine:

natural language processing

Type de record:

software
Créateur:
Dew
Hôte:
# DailyDerjaTools Tooling for the Daily Derja project. Currently this provides a Mix task that generates ElevenLabs text-to-speech audio files for vocabulary and example sentences from a CSV. ## Generating TTS audio ```sh mix derja.tts examples/daif-examples.csv mix derja.tts examples/daif-examples.csv --out /absolute/path/to/static/audio ``` The task reads each row of the CSV and, unless a matching ` .mp3` already exists in the output directory, calls the ElevenLabs API and writes the audio. Existing files are skipped, so the task is safe to re-run. By default audio is written to `static/audio`. Use `--out` (alias `-o`) to override the output directory. ### Environment variables The task reads its credentials from the environment. If a `.env` file is present in the project root it is loaded automatically (via `dotenvy`). | Variable | Description | | --- | --- | | `ELEVENLABS_API_KEY` | Your ElevenLabs API key | | `ELEVENLABS_MALE_VOICE_ID` | Shami (Levantine) male voice id | | `ELEVENLABS_FEMALE_VOICE_ID` | Shami (Levantine) female voice id | | `ELEVENLABS_TUNISIAN_MALE_VOICE_ID` | Tunisian male voice id | | `ELEVENLABS_TUNISIAN_FEMALE_VOICE_ID` | Tunisian female voice id | ### CSV format ```csv slug,voice,text,en,post,dialect hadid,male,حَديد,"iron; metal",iron,both strike-iron-hot,male,"إضرب الحديد وهو حامي.","Strike the iron while it's hot.",iron,shami narqod,male,نَرْقُد,"I sleep; I go to sleep",tunisian-daily-2,tunisian ``` | Column | Description | | --- | --- | | `slug` | Output file name (without extension); audio is written to ` .mp3` | | `voice` | `male` or `female` | | `text` | The Arabic text to synthesize | | `en` | English gloss/translation (metadata only; not sent to TTS) | | `post` | The post the example belongs to (metadata only) | | `dialect` | `shami`, `tunisian`, or `both`; selects which voice is used | The combination of `voice` and `dialect` determines the ElevenLabs voice id: * `dialect` `shami` or `both` → the Shami voice (`ELEVE …