Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

============================================================================== 🎬 CineLingo - The Ultimate Subtitle Transformation Suite 🚀

Welcome to CineLingo! If you are passionate about movies, language, or simply want to bring cinematic magic to audiences around the world, you've come to the right place. CineLingo is an innovative command-line tool designed to provide an end-to-end solution for subtitle production — from extracting audio and transcribing it using state-of-the-art AI, to translating subtitles into your chosen language and ensuring the dialogue is kid-friendly by filtering out profanities.

==============================================================================

🌟 What Is CineLingo?

CineLingo is your go-to command-line partner for creating multilingual and family-friendly subtitles. It automates the whole process:

  • Extract audio seamlessly from your video file with high-quality precision.
  • Leverage OpenAI’s Whisper model for accurate transcription complete with precise timestamps.
  • Translate your subtitles from English to the language of your choice using the Google Translate API.
  • Apply a custom-built profanity filter that automatically replaces questionable words with kid-friendly alternatives – ensuring your content is safe for all audiences.

Whether you're a content creator, educator, or just a movie buff looking for that extra edge in localization, CineLingo empowers you to reach a global audience with subtitles that speak their language.

==============================================================================

🛠️ Requirements:

To get CineLingo up and running, you'll need the following:

  • Python 3.8+: Ensure you have Python installed.
  • ffmpeg: A powerful multimedia framework. (Installation example: Ubuntu: sudo apt install ffmpeg)
  • Python Libraries:
    • whisper (from OpenAI) for transcription.
    • googletrans==4.0.0-rc1 for translation.
    • tqdm for progress visualization.

Install the required Python packages with:

 pip install git+https://github.com/openai/whisper.git
 pip install googletrans==4.0.0-rc1
 pip install tqdm

==============================================================================

🎯 How It Works:

1️⃣ Audio Extraction:
CineLingo kicks things off by extracting a crystal-clear audio track from your video using ffmpeg. This is the foundation for precise transcription.

2️⃣ Transcription with Whisper:
Next, it deploys the OpenAI Whisper model to transform the audio into text. Not only do you get the dialogues, but each line comes with exact timestamps – perfect for creating SRT files.

3️⃣ Translation:
With an intuitive selection of languages, CineLingo lets you choose your desired target language from an extensive list. Using Google Translate, every line is skillfully translated into the language you need.

4️⃣ Profanity Filtering:
Worried about maintaining a kid-friendly tone? No problem! CineLingo automatically checks for profanities using a customizable profanity mapping file (e.g., profanity_map_sq.txt for Albanian) and replaces them with gentler, family‐ friendly alternatives.

5️⃣ Final Output:
All of the above magic culminates in a polished SRT file ready to be merged back into your video or distributed on its own.

==============================================================================

📚 How to Use CineLingo:

Step 1: Open your terminal and run the script with your video file:

     python script.py path_to_your_video_file.mp4

Step 2: You'll be presented with a vibrant list of available languages. Simply enter the number corresponding to your desired target language.

     Tip: If you have a custom profanity file for your language (e.g., 
     "profanity_map_<language_code>.txt"), make sure it's in the same directory. 
     This file should contain mappings in the format: 
            english_profanity:target_language_replacement

Step 3: Sit back as the tool extracts the audio, transcribes the dialogue, translates everything into your chosen language, and applies the profanity filter.

Step 4: Voila! CineLingo outputs a stunning SRT file with transformed subtitles tailored to your international audience.

==============================================================================

🎉 What’s Included:

  • Audio Extraction: Powered by ffmpeg, ensuring top-notch audio fidelity.
  • Transcription: Using the groundbreaking Whisper model to capture every word with precision.
  • Translation: Seamlessly converting subtitles to your language of choice.
  • Profanity Filter: Customizable and dynamic, perfect for creating content that’s safe for viewers of all ages.
  • User-Friendly Interface: Simple command-line prompts and visually appealing progress bars keep you in the loop throughout the process.

==============================================================================

🚀 Ready to Transform Your Videos?

With CineLingo, you can:

  • Reach wider audiences by breaking language barriers.
  • Safeguard your content from explicit language.
  • Enhance the viewing experience with accurate, localized subtitles.

Join the revolution in film localization and subtitle creation. Let CineLingo bring your videos to life on a global stage!

==============================================================================

💬 Questions? Feedback?
We love hearing from you! Drop us a line, share your thoughts, or contribute to the project. Together, we'll make movie magic accessible to everyone.

==============================================================================

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages