Skip to content

Sparks33/YT-Shorts-Automater

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

YT-Shorts-Automater

🤖 Automatically generate YouTube shorts simply by running the script!

📝 Table of Contents

  1. About
  2. Demo
  3. How it works
  4. Getting Started
  5. Usage
  6. Built Using

🧐 About

From creation to editing and voiceover too for a YouTube short, this script automates it all. No more tedious tasks, endless hours, this script has you covered!

Absolutely free!

Watch the toturial here on how to get this script running! https://youtu.be/H9_0FPlTmes

🎥 Demo

Working

  • NOTE : This video is trimmed but it shouldn't take more than 1 minute to generate your video.

💭 How it works

#1 Content

The script starts by taking the video name and asking if the user wants to generate content using AI (which can be edited later).

#2 Text-to-Speech

After the content is generated / entered by the user, it generates Text-to-Speech and saves the file as `speech.mp3`.

#3 Editing

The editing starts by selecting a gameplay, trimming a random part of it and adding speech on top of it. Next, it resizes the video to 9:16 aspect ratio and saves the final video.

🏁 Getting Started

Follow the instructions given below to get this script up and running on your device.

Prerequisites

  1. OpenAI API Key - Get it from the Open AI Website. It provides $18 of free credits by default and they are more than enough. [OPTIONAL]
  2. OpenAI - pip install openai
  3. gTTS - pip install gtts
  4. MoviePY - pip install moviepy
  5. Dotenv - pip install python-dotenv

Installing

  1. Download this repository as zip file / using git.
  2. Open the folder.
  3. Make sure the above mentioned modules are installed. (pip install -r requirements.txt)
  4. Add your OpenAI API key to .env.example file (OPENAI_API=<key>) and rename it to just .env [OPTIONAL]
  5. Now, download both the gameplay videos from Google Drive (as they were too large to upload to Github)
  6. Put both the videos in a folder named "gameplay" in the directory with shorts.py file.
  7. Run the shorts.py python file.

🎈 Usage

To use this script,

  1. Run the shorts.py python file.
  2. Enter the name of the video.
  3. Let AI generate video content for you / enter it yourself.
  • NOTE : (Make sure you have added your OpenAI API key in .env file if using AI to generate content)
  1. And that's it! Everything else will be handled automatically!
  2. You can find your video in generated/ directory.

<sup>Beep boop, boop beep. I am a script. If there are any issues, contact my Creator - sparksjs and/or Sparks ⵢ on Discord </sup>

⛏️ Built Using

  1. OpenAI API - For generating video content.
  2. gTTS - For Text-to-Speech.
  3. MoviePY - For video editing.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages