CLI tool for subtitle translation using ChatGPT
Top 78.7% on sourcepulse
This project provides a tool to translate subtitle files using the ChatGPT API, targeting users who need to localize video content. It offers multi-language support and context-aware translation by considering surrounding sentences.
How It Works
The tool leverages the gpt-3.5-turbo
model for translation. It processes subtitle files (SRT, VTT) by sending segments to the ChatGPT API, incorporating context from preceding and succeeding lines to improve translation accuracy.
Quick Start & Requirements
npm install
node index.js
config.example.json
to config.json
and add API key and target language.src
folder; translated files appear in res
.Highlighted Details
.srt
and .vtt
subtitle formats.gpt-3.5-turbo
for translation.Maintenance & Community
Pull requests are welcome; major changes require opening an issue first.
Licensing & Compatibility
The license is not specified in the README.
Limitations & Caveats
The project relies on an external OpenAI API key, incurring costs. The README does not specify the license, which may impact commercial use.
1 year ago
1 day