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.

ffmpeg Article's
30 articles in total
Favicon
Desvendando Subprocessos: Criando um Bot de Música com Go
Favicon
Video data IO through ffmpeg subprocess
Favicon
Wisper, ffmpeg을 활용한 비디오 자막 자동 생성
Favicon
Integrating MinIO notifications with your Node.js service, FFmpeg, and Mozilla convert API.
Favicon
Cliet-side WebM/MP4 export from React.js Canavs Animation using ffmpeg.wasm for an Upwork client
Favicon
Reduce bitrate using FFMPEG
Favicon
Add a Watermark to a Video Using VideoAlchemy
Favicon
No Bullshit Guide to Youtube shorts automation in NodeJS, OpenAI, Ollama, ElevanLabs & ffmpeg
Favicon
Building a Video Streaming Platform with Node.js, FFmpeg, and Next.js
Favicon
Record Windows Screen using ffmpeg and convert to time lapse video
Favicon
Introducing Comet: A Free, Cross-Platform Video Converter Powered by FFmpeg
Favicon
Compress, Convert and Trim Videos with Command Line
Favicon
เผื่อใครอยากทำ mp4 to gif แบบคมๆ
Favicon
How to generate thumbnails from video ?
Favicon
Convert .caf to mp3 by Directory
Favicon
FFMPEG
Favicon
Run ffmpeg within a Docker Container: A Step-by-Step Guide
Favicon
New to DEV.to - About me
Favicon
Streaming Video to AWS MediaConnect Using FFmpeg and SRT Protocol: A Complete Guide
Favicon
Displaying a video on a ESP32 powered SSD1306 OLED screen
Favicon
FFMPEG Libraries - RTSP Client Keep Alive
Favicon
From Pixels to Playbacks: Dominate Multimedia with FFmpeg in Python
Favicon
Access webcam by ffmpeg in Windows
Favicon
OSCAR 2022 sea surface velocity streamplot animation
Favicon
Mastering Video Previews: A Guide to Compressed Videos and Thumbnails
Favicon
Dall.E Image Gen, And Size Comparison Of Image Formats
Favicon
AIS vessel density maps with pyspark and h3 and animations with ffmpeg
Favicon
Using Electron to create videos (Canvas + FFmpeg)
Favicon
BMF 📹 + Hugging Face🤗, The New Video Processing BFFs
Favicon
Leveraging GPU Acceleration in BMF for High-Performance Video Processing

Featured ones: