Logo

dev-resources.site

for different kinds of informations.

No Bullshit Guide to Youtube shorts automation in NodeJS, OpenAI, Ollama, ElevanLabs & ffmpeg

Published at
9/8/2024
Categories
automation
node
ollama
ffmpeg
Author
nobullshit-coder
Categories
4 categories in total
automation
open
node
open
ollama
open
ffmpeg
open
Author
16 person written this
nobullshit-coder
open
No Bullshit Guide to Youtube shorts automation in NodeJS, OpenAI, Ollama, ElevanLabs & ffmpeg

We all have seen tutorials on YouTube that promise YouTube faceless shorts automation using some tools that use drag-drop or “No/low code” and all seems too easy, but as a developer you know “No/Low code” is not really “no/low code” it’s just hiding complexity for babies.

So just like any other developer, I thought I could “code” this as well, and instead of “Good UI/UX” I could create a “Great UI/UX”, a CLI (Command Line Interface).

So without any bullshit here is what you are for.

We will be creating a YouTube shorts automation that will accept 3 parameters

  1. topic: Topic for video (default: “science facts”)
  2. num: Number of shorts to generate (default: “3”)
  3. output: Output directory (default: “output”)

node index.js --help

Image description

Workflow

  • Fetch topics from generative AI for video content
  • Generate high-quality audio using Text to Speech services
  • Create captions automatically with the transcribe service
  • Download a stock video from the free video API
  • Produce the final video

With this powerful automation script, you can generate high-quality YouTube Shorts quickly and efficiently, saving you hours of work!

What You’ll Learn:

  • Setting up the automation script in JavaScript
  • Using the OpenAI API and Local Ollama API for content generation
  • Integrating Eleven Labs API or OpenAI Audio API for Audio Creation
  • Capturing captions with AWS Transcribe using AWS SDK v3
  • Pexels API and download video
  • Rendering with FFmpeg

Github


Full step-by-step Youtube Tutorial

https://www.youtube.com/watch?v=YvGKsPkWzRs

I am working on creating more content on YouTube, and you see I still don’t have enough subscribers and views to monetize my channel. I would appreciate it if you subscribe and watch the video. Please show some love.

No monetizing also means
You will see the whole video "Ad Free" 🤣.

Free or Open Source alternative to paid service

  1. I have also provided code to use Local Lamma instead of chatGPT
  2. Pexels video API is free
  3. FFMPEG is free and open source

Out of 5 services used in the code, 3 of them are either free or you can find an open-source alternative.

If you find any good open-source or free alternative to text-to-speech and audio transcription, please let me know in the comments.

Links

Next Steps:

  1. Add a background music
  2. Randomize the TTS voices
  3. How to break long videos into clips and then create shorts out of that
    • Break the clips into smaller chunks
    • we will resize them to fit the vertical format
    • transcribe and caption
  4. We will use AI to center the speaker in case of podcast or interview videos
  5. We will also use YouTube data API to upload the video directly to YouTube
  6. We will use a YouTube heatmap to figure out what was trending moment in the given video and auto-create clips out of it — this will be the true long-to-short automation. you just pass the video URL and it will generate 10–20 shorts of trending topics.

What do you think?

Let me know what else we can do and your thoughts on the process improvements and peer review.

If you like this tutorial
Subscribe to me on YouTube: https://www.youtube.com/watch?v=YvGKsPkWzRs
and follow me on Twitter (X) (Yeah I still call it Twitter): https://x.com/nobullshitcoder

Thank you & take care.

ollama Article's
30 articles in total
Favicon
What is ollama? Is it also a LLM?
Favicon
Semantic Kernel: Crea un API para GeneraciĂłn de Texto con Ollama y Aspire
Favicon
Local AI apps with C#, Semantic Kernel and Ollama
Favicon
Running Out of Space? Move Your Ollama Models to a Different Drive 🚀
Favicon
Working with LLMs in .NET using Microsoft.Extensions.AI
Favicon
Building an Ollama-Powered GitHub Copilot Extension
Favicon
Step-by-Step Guide: Write Your First AI Storyteller with Ollama (llama3.2) and Semantic Kernel in C#
Favicon
Run LLMs Locally with Ollama & Semantic Kernel in .NET: A Quick Start
Favicon
How to Set Up a Local Ubuntu Server to Host Ollama Models with a WebUI
Favicon
Ollama 0.5 Is Here: Generate Structured Outputs
Favicon
Building AI-Powered Apps with SvelteKit: Managing HTTP Streams from Ollama Server
Favicon
Run Llama 3 Locally
Favicon
Building 5 AI Agents with phidata and Ollama
Favicon
Run Ollama on Intel Arc GPU (IPEX)
Favicon
Quick tip: Running OpenAI's Swarm locally using Ollama
Favicon
Langchain4J musings
Favicon
How to deploy SmolLM2 1.7B on a Virtual Machine in the Cloud with Ollama?
Favicon
Ollama - Custom Model - llama3.2
Favicon
Coding Assistants and Artificial Intelligence for the Rest of Us
Favicon
Using a Locally-Installed LLM to Fill in Client Requirement Gaps
Favicon
Create Your Own Local AI Chatbot with Ollama and LangChain
Favicon
Consuming HTTP Streams in PHP with Symfony HTTP Client and Ollama API
Favicon
Llama 3.2 Running Locally in VSCode: How to Set It Up with CodeGPT and Ollama
Favicon
Ollama Unveiled: Run LLMs Locally
Favicon
No Bullshit Guide to Youtube shorts automation in NodeJS, OpenAI, Ollama, ElevanLabs & ffmpeg
Favicon
Unloading a model from Ollama
Favicon
OLLAMA + LLAMA3 + RAG + Vector Database (Local, Open Source, Free)
Favicon
The 6 Best LLM Tools To Run Models Locally
Favicon
Demystifying AI of Your Own
Favicon
Langchain Chat Assistant using Chainlit App

Featured ones: