A tool for generating subtitles using Google Gemini models.
Project description
Subtitle tool
This utility uses Google Gemini to generate subtitles to audio and video files.
Dependencies
ffmpeg needs to be installed for audio extraction.
Process
- Extract the audio from the video
- Send the audio to Gemini for transcription
- Backup the existing subtitle
- Save the new subtitle
Dependencies
Export the API key for Gemini to the environment variable GEMINI_API_KEY
or specify it in the command line with the flag --api-key.
ffmpeg needs to be installed (brew install ffmpeg, apt-get install ffmpeg or dnf install ffmpeg)
Installation
pip install subtitle-tool
Developing
For local development it is useful to install the binary from the development
location into the user's PATH. For this, run the following commands:
uv tool install -e .
uv tool update-shell
Usage
subtitle-tool --video myvideo.avi
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 subtitle_tool-0.1.26.tar.gz.
File metadata
- Download URL: subtitle_tool-0.1.26.tar.gz
- Upload date:
- Size: 48.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e26ad4cf286ac1b0d18544d57746a19a5687cb540adaf8b0131b5f43526f7a14
|
|
| MD5 |
b860487063315063844a74cd321ca634
|
|
| BLAKE2b-256 |
4d52987af2721205c524534f975f45f9aa5093495d363d32692df66cc13e0645
|
File details
Details for the file subtitle_tool-0.1.26-py3-none-any.whl.
File metadata
- Download URL: subtitle_tool-0.1.26-py3-none-any.whl
- Upload date:
- Size: 16.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
37a639a40b498bb09c2d63b167046033593af186741e249074b585be3b403110
|
|
| MD5 |
6b092e08fcd404b60635958c0ca89612
|
|
| BLAKE2b-256 |
05a296bf63f1ab843f9bf57de92f526c5861967755d82ce207de2abaf299d854
|