Slice audio + subtitles and export to Anki via AnkiConnect
Project description
🎧 Anki‑Slicer
Anki‑Slicer is a utility that lets you take an audio file (MP3, WAV, etc.) plus two SRT subtitles (original + translation), preview and flag sentences you want to learn, and then bulk‑export them into Anki flashcards — fully synchronized with the audio.
It’s designed for language learners who want to build rich, sentence‑level listening cards with audio + text, all in just a few clicks. ✨ Features
⏯️ Continuous / Auto‑Pause playback modes for sentence‑by‑sentence listening.
🕹 Slider & Time Display to seek anywhere in the audio.
🚩 Flag individual sentences or bulk‑flag all search matches.
🔎 Search subtitles (original, translation, or both) and jump through results.
🗂 Flagged list with checkboxes (select/deselect before exporting).
📤 Export flagged items into Anki via AnkiConnect — creates cards automatically.
🃏 Output deck: AnkiSlicer (rename inside Anki if you want multiple decks).
📦 Prerequisites
Anki with the AnkiConnect add‑on installed and running.
An audio file and two SRT files:
Original transcript (same language as the audio).
Translation of the original text.
💡 Tip: I personally use McWhisper (paid app) to generate accurate SRTs and export audio from YouTube or audio files. Other workflows are possible — e.g. extracting captions from YouTube, generating with Whisper/AI, etc.
🚀 Installation
Clone the repo and install dependencies (Python 3.10+ recommended):
bash
Copy git clone https://github.com/YOUR_USERNAME/anki-slicer.git cd anki-slicer pip install -r requirements.txt
🎮 How to Use Anki‑Slicer
Ensure Anki + AnkiConnect are running.
Launch Anki‑Slicer:
bash
Copy
python main.py
Select your:
Audio file
Original SRT
Translation SRT
Use the controls:
▶ Play / ⏸ Pause / ⏮ Previous / ⏭ Next
Mode toggle = Continuous vs. Auto‑Pause playback
Use the slider to jump around
🔍 Search subtitles (Original / Translation / Both)
🚩 Flag sentences (individually or bulk‑flag from Search)
Review your flagged list, check/uncheck items.
Click Export Selection to Anki → cards are created in your AnkiSlicer deck.
🖼 UI Preview
Anki-Slicer Screenshot 🛠 Advanced Use
Enhance your translation SRT before loading:
Add explanations, grammar notes, transliterations (e.g. pinyin for Chinese).
These extras appear on the answer side of the Anki card.
Organize by subject: rename or split cards into different decks once in Anki.
🤝 Contributing
Contributions are welcome! Ideas, bug reports, feature requests → open an Issue. Pull requests are encouraged — new features (UI tweaks, extra export formats, etc.) are fair game.
⚖️ License
This project is licensed under the MIT License — see LICENSE for details.
🧪 Status
Currently tested primarily on macOS. Windows/Linux should work but are not yet validated. Feedback and testing reports are welcome!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file anki_slicer-0.2.0.tar.gz.
File metadata
- Download URL: anki_slicer-0.2.0.tar.gz
- Upload date:
- Size: 13.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c7149f6c657b135aa0c951d9b90dd29e107b4054d715ea42b2f61f620e50ad63
|
|
| MD5 |
c96a875c672eb7ca0bf7df34c6b8c9a4
|
|
| BLAKE2b-256 |
7e5cbab3634adefc31200e47b0a82e21184135d34bd46c668232d5edb7bc0e1c
|
File details
Details for the file anki_slicer-0.2.0-py3-none-any.whl.
File metadata
- Download URL: anki_slicer-0.2.0-py3-none-any.whl
- Upload date:
- Size: 13.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9bc23af70ee3e356bd299dbd063a54a8409762d50ff948162b0043b20f35f10a
|
|
| MD5 |
c2d028ce5b7fa14f437cf80e0707a3f8
|
|
| BLAKE2b-256 |
c51d0b575738bd12dd6d7289d7afc63d0cd397c76b63c5a856114b54b5a022c0
|