Skip to content

Commit dbe54c3

Browse files
Merge pull request #24 from HenestrosaDev/dev
Release v2.2.2
2 parents bc36b03 + 87c5c6d commit dbe54c3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1033
-548
lines changed

README.md

Lines changed: 128 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@
8181

8282
- [About the Project](#about-the-project)
8383
- [Supported Languages](#supported-languages)
84+
- [Supported File Types](#supported-file-types)
8485
- [Project Structure](#project-structure)
8586
- [Built With](#built-with)
8687
- [Getting Started](#getting-started)
@@ -90,6 +91,8 @@
9091
- [Usage](#usage)
9192
- [Transcribe From](#transcribe-from)
9293
- [Save Transcription](#save-transcription)
94+
- [Autosave](#autosave)
95+
- [Overwrite Existing Files](#overwrite-existing-files)
9396
- [Transcribe Using](#transcribe-using)
9497
- [WhisperX Options](#whisperx-options)
9598
- [Transcription Translation](#transcription-translation)
@@ -238,6 +241,49 @@ You can also choose the theme you like best. It can be dark, light, or the one c
238241
- Yoruba
239242
</details>
240243

244+
### Supported File Types
245+
246+
<details>
247+
<summary>Audio file formats</summary>
248+
249+
- `.mp3`
250+
- `.mpeg`
251+
- `.wav`
252+
- `.wma`
253+
- `.aac`
254+
- `.flac`
255+
- `.ogg`
256+
- `.oga`
257+
- `.opus`
258+
</details>
259+
260+
<details>
261+
<summary>Video file formats</summary>
262+
263+
- `.mp4`
264+
- `.m4a`
265+
- `.m4v`
266+
- `.f4v`
267+
- `.f4a`
268+
- `.m4b`
269+
- `.m4r`
270+
- `.f4b`
271+
- `.mov`
272+
- `.avi`
273+
- `.webm`
274+
- `.flv`
275+
- `.mkv`
276+
- `.3gp`
277+
- `.3gp2`
278+
- `.3g2`
279+
- `.3gpp`
280+
- `.3gpp2`
281+
- `.ogv`
282+
- `.ogx`
283+
- `.wmv`
284+
- `.asf`
285+
</details>
286+
241287
<!-- PROJECT STRUCTURE -->
242288

243289
### Project Structure
@@ -399,7 +445,6 @@ You can also choose the theme you like best. It can be dark, light, or the one c
399445
source venv/Scripts/activate
400446
```
401447
5. Run `cat requirements.txt | xargs -n 1 pip install` to install the dependencies.
402-
> [!WARNING]
403448
>For some reason, `pip install -r requirements.txt` throws the error "Could not find a version that satisfies the requirement [PACKAGE_NAME]==[PACKAGE_VERSION] (from version: none)"
404449
6. Run `python src/app.py` to start the program.
405450

@@ -433,54 +478,66 @@ Once you open the **Audiotext** executable file (explained in the [getting start
433478
434479
### Transcribe From
435480

436-
You can transcribe from three audio sources:
481+
You can transcribe from four sources:
437482

438483
- **File** (see image above): Click on the file explorer icon to select the file you want to transcribe. You can also manually enter the path to the file into the input field. You can transcribe audio from both audio and video files. Note that the file explorer has the `All supported files` option selected by default. To select only audio files or video files, click the combo box in the lower right corner of the file explorer to change the file type, as marked in red in the following image:
439484

440485
![File explorer](docs/file-explorer.png)
441486

442487
![Supported files](docs/supported-files.png)
443488

444-
<details>
445-
<summary>Supported audio file formats</summary>
446-
447-
- `.mp3`
448-
- `.mpeg`
449-
- `.wav`
450-
- `.wma`
451-
- `.aac`
452-
- `.flac`
453-
- `.ogg`
454-
- `.oga`
455-
- `.opus`
456-
</details>
457-
458-
<details>
459-
<summary>Supported video file formats</summary>
460-
461-
- `.mp4`
462-
- `.m4a`
463-
- `.m4v`
464-
- `.f4v`
465-
- `.f4a`
466-
- `.m4b`
467-
- `.m4r`
468-
- `.f4b`
469-
- `.mov`
470-
- `.avi`
471-
- `.webm`
472-
- `.flv`
473-
- `.mkv`
474-
- `.3gp`
475-
- `.3gp2`
476-
- `.3g2`
477-
- `.3gpp`
478-
- `.3gpp2`
479-
- `.ogv`
480-
- `.ogx`
481-
- `.wmv`
482-
- `.asf`
483-
</details>
489+
- **Directory**: Click on the file explorer icon to select the directory with the files you want to transcribe. You can also manually enter the path to the directory into the input field. All supported video and audio files from the root of the directory and its subdirectories will be transcribed. Note that the `Autosave` option is checked and cannot be unchecked because each file's transcription will automatically be saved in the same path as the source file.
490+
491+
<picture>
492+
<source
493+
srcset="docs/light/from-directory.png"
494+
media="(prefers-color-scheme: light)"
495+
/>
496+
<source
497+
srcset="docs/dark/from-directory.png"
498+
media="(prefers-color-scheme: dark)"
499+
/>
500+
<img
501+
src="docs/light/from-directory.png"
502+
alt="Main"
503+
>
504+
</picture>
505+
506+
For example, let's use this directory as a reference:
507+
508+
```
509+
└───files-to-transcribe
510+
│ paranoid-android.mp3
511+
│ the-past-recedes.flac
512+
513+
└───movies
514+
seul-contre-tous.mp4
515+
mulholland-dr.avi
516+
```
517+
518+
After transcribing the `files-to-transcribe` directory with subtitles, the folder structure will look like this:
519+
520+
```
521+
└───files-to-transcribe
522+
│ paranoid-android.mp3
523+
│ paranoid-android.srt
524+
│ paranoid-android.txt
525+
│ paranoid-android.vtt
526+
│ the-past-recedes.flac
527+
│ the-past-recedes.srt
528+
│ the-past-recedes.txt
529+
│ the-past-recedes.vtt
530+
531+
└───movies
532+
seul-contre-tous-1998.mp4
533+
seul-contre-tous-1998.srt
534+
seul-contre-tous-1998.txt
535+
seul-contre-tous-1998.vtt
536+
mulholland-dr-2001.avi
537+
mulholland-dr-2001.srt
538+
mulholland-dr-2001.txt
539+
mulholland-dr-2001.vtt
540+
```
484541

485542
- **Microphone**: To start recording, simply click the `Start recording` button to begin the process. The text of the button will change to `Stop recording` and its color will change to red. Click it to stop recording and generate the transcription.
486543

@@ -491,8 +548,6 @@ You can transcribe from three audio sources:
491548
<!-- english.mp4 -->
492549
https://github.com/HenestrosaDev/audiotext/assets/60482743/bd0323d7-ff54-4363-8b73-a2d56e7f783b
493550

494-
>Video from v2.1.0
495-
496551
- **YouTube video**: Enter the video URL in the upper input field. When finished, click on the `Generate transcription` button.
497552

498553
<picture>
@@ -512,9 +567,32 @@ You can transcribe from three audio sources:
512567
513568
### Save Transcription
514569

515-
Once the program has generated the transcription, you'll see a green `Save transcription` button below the text box. If you click on it, you'll be prompted for a file explorer where you can give the file a name and select the path where you want to save it. The file extension is `.txt` by default, but you can change it to any other text file type.
570+
When you click on the `Save transcription` button, you'll be prompted for a file explorer where you can name the transcription file and select the path where you want to save it. The file extension is `.txt` by default, but you can change it to any other text file type.
571+
572+
If you use **WhisperX** to generate a transcription and check the `Generate subtitles` option, two files will also be saved along with the text file: a `.vtt` file and a `.srt` file. Both contain the subtitles for the transcribed file, as explained in the [Generate Subtitles](#generate-subtitles) section.
573+
574+
Please note that any text entered or modified in the textbox **WILL NOT** be included in the saved transcription.
575+
576+
#### Autosave
577+
578+
If checked, the transcription will automatically be saved in the root of the folder where the transcribed file is stored. If you check the `Generate subtitles` option, the subtitle files will also be saved automatically. If there are already existing files with the same name, they won't be overwritten. To do that, you'll need to check the `Overwrite existing files` option (see below).
516579

517-
If you used **WhisperX** to generate the transcription and checked the `Generate subtitles` option, you'll notice that two files are also saved along with the text file: a `.vtt` file and a `.srt` file. Both contain the subtitles for the transcribed file, as explained in the [Generate Subtitles](#generate-subtitles) section.
580+
#### Overwrite Existing Files
581+
582+
This option can only be checked if the `Autosave` option is checked. If `Overwrite existing files` is checked, existing transcriptions in the root directory of the file to be transcribed will be overwritten when saving.
583+
584+
For example, let's use this directory as a reference:
585+
586+
```
587+
└───audios
588+
foo.mp3
589+
foo.srt
590+
foo.txt
591+
```
592+
593+
If we transcribe the audio file `foo.mp3` with the `Generate subtitles`, `Autosave` and `Overwrite existing files` options checked, the files `foo.srt` and `foo.txt` will be overwritten and the file `foo.vtt` will be created.
594+
595+
On the other hand, if we transcribe the audio file `foo.mp3` with the options `Generate subtitles` and `Autosave` checked and the option `Overwrite existing files` unchecked, the file `foo.vtt` will still be created, but the files `foo.srt` and `foo.txt` will remain unchanged.
518596

519597
### Transcribe Using
520598

@@ -548,22 +626,16 @@ The **WhisperX** options appear when the selected transcription method is **Whis
548626

549627
To translate the audio into English, simply check the `Translate to English` checkbox before generating the transcription, as shown in the video below.
550628

551-
<!-- french-to-english.mp4 -->
629+
<!-- spanish-to-english.mp4 -->
552630
https://github.com/HenestrosaDev/audiotext/assets/60482743/0aeeaa17-432f-445c-b29a-d76839be489b
553631

554-
> [!NOTE]
555-
>Video from v2.1.0
556-
557632
However, there is another unofficial way to translate audio into any supported language by setting the `Audio language` to the target translation language. For example, if the audio is in English and you want to translate it into Spanish, you would set the `Audio language` to "Spanish".
558633

559634
Here is a practical example using the microphone:
560635

561-
<!-- english-to-spanish.mp4 -->
636+
<!-- english-to-french.mp4 -->
562637
https://github.com/HenestrosaDev/audiotext/assets/60482743/b346290f-4654-48c4-bf5a-2dcb75b136e9
563638

564-
> [!NOTE]
565-
>Video from v2.1.0
566-
567639
Make sure to double-check the generated translations.
568640

569641
#### Generate Subtitles
@@ -725,9 +797,9 @@ Remember that **WhisperX** provides fast, unlimited audio transcription that sup
725797
- [x] Add subtitle options.
726798
- [x] Add advanced options for **WhisperX**.
727799
- [x] Add the option to transcribe YouTube videos.
728-
- [ ] Add checkbox to automatically save the generated transcription [(#17)](https://github.com/HenestrosaDev/audiotext/issues/17).
800+
- [x] Add checkbox to automatically save the generated transcription [(#17)](https://github.com/HenestrosaDev/audiotext/issues/17).
801+
- [x] Allow transcription of multiple files from a directory.
729802
- [ ] Change the "Generate transcription" button to "Cancel transcription" when a transcription is in progress.
730-
- [ ] Allow transcription of multiple files at once [(#17)](https://github.com/HenestrosaDev/audiotext/issues/17).
731803
- [ ] Generate executables for macOS and Linux.
732804
- [ ] Add pre-commit config for using `Black`, `isort`, and `mypy`.
733805
- [ ] Add tests.

docs/dark/from-directory.png

72.7 KB
Loading

docs/dark/from-file.png

152 KB
Loading

docs/dark/from-microphone.png

2.87 KB
Loading

docs/dark/from-youtube.png

2.08 KB
Loading

docs/dark/main.png

2.85 KB
Loading

docs/light/from-directory.png

70.5 KB
Loading

docs/light/from-file.png

149 KB
Loading

docs/light/from-microphone.png

3.27 KB
Loading

docs/light/from-youtube.png

2.76 KB
Loading

0 commit comments

Comments
 (0)