Featured
- Get link
- X
- Other Apps
How I Make YouTube Tutorials and Shorts with Code, Not a Video Editor
When I started my YouTube channel, I hit the same wall many creators hit: editing. A ten-minute tutorial can take hours to edit, and Shorts need fast cuts, captions and motion every few seconds. I wanted to publish dozens of videos in a consistent style, and doing that by hand was not realistic for one person.
So I stopped treating videos as something to edit and started treating them as something to generate. Today almost every video on my channel is built from a written script by a pipeline of free and open tools. This post explains how that pipeline works and what I learned building it.
The core idea: a video is data
A tutorial video is mostly a sequence of scenes. Each scene has some spoken text, a visual (a title, a diagram, a list, a comparison, a chart), and a duration. If you describe those scenes in a structured file, a program can turn them into audio and video.
So every video starts as a spec: a list of "beats". A beat says what the narrator says and which visual layout to show while they say it. For example: a hook beat with a large question on screen, a list beat with three points, a comparison beat with two columns, a summary beat, and a call to action.
Writing the spec is the creative part. Everything after that is automated.
Step 1: Narration with open-source text-to-speech
For the voice, I used Kokoro, a small open-weight text-to-speech model that runs on an ordinary CPU. That matters: it means narration can be generated on free cloud runners without a GPU and without paying per character.
The pipeline generates audio for each beat separately. That has two advantages:
- The exact length of every beat is known, so visuals can be timed precisely to the voice.
- If one sentence sounds wrong, only that beat needs to be regenerated, and results are cached so unchanged beats are not regenerated at all.
A few practical tips for synthetic narration:
- Write for the ear: short sentences, simple words, one idea per sentence.
- Spell out tricky items, such as numbers, abbreviations and product names, the way they should be pronounced.
- Normalise loudness so every video plays at a consistent volume. I target around −14 LUFS, a common level for online platforms.
I also state clearly in each video that the voice is synthetic. Viewers deserve to know.
Step 2: Visuals with Remotion
Remotion is a framework for creating videos with React, the same library used to build websites. Each frame of the video is a web page rendered at a specific moment in time, and Remotion captures those frames and encodes them into a video file.
For a developer this is powerful:
- Reusable components. I built components for each type of beat: hook, list, comparison, flow diagram, table, chart, verdict and call to action. Once a component looks good, every future video gets it for free.
- Consistent style. Fonts, colours, spacing and animation timing live in one place, so the whole channel looks coherent.
- Multiple formats. The same components render a 1920×1080 long video, a 1080×1920 Short, and a 1280×720 thumbnail.
Remotion has its own licence terms: it is free for individuals and small teams, while larger companies need a paid licence. Check the current terms before using it commercially.
Step 3: Timing everything to the voice
After the audio for each beat is generated, the pipeline measures its duration and builds a timeline: beat one starts at zero and lasts as long as its narration, beat two starts where beat one ends, and so on. That timeline is passed to Remotion as input properties, so each visual appears exactly when the narrator starts talking about it.
For Shorts, I also show the spoken words on screen as captions. To get word-level timing, I run the generated audio through Whisper (via the faster-whisper implementation), which returns the time of every word. Those timings drive the on-screen captions.
Step 4: Automatic quality checks
Generating videos automatically means you can also generate mistakes automatically. So every render goes through checks before it is allowed to upload:
- Audio: loudness and peak levels are within the target range, and no single beat runs too long.
- Speech accuracy: the narration is transcribed again and compared with the script. If the transcript does not match closely enough, the voice probably mispronounced something.
- Render: the file exists, has the right resolution and the expected duration.
- Visual: a contact sheet of frames is generated so I can glance at a whole video in a single image.
- Metadata: titles stay within a length limit and contain the main keyword.
Only videos that pass every check move to the upload queue.
Step 5: Rendering in the cloud for free
Rendering many videos on a laptop is slow and keeps the machine busy. I moved rendering to GitHub Actions, where each video is rendered as a separate job. A push to a list of "to render" items starts the jobs; when they finish, the finished videos and their metadata are stored and picked up by the uploader. My earlier post explains how the upload side works.
What works well, and what does not
Works well:
- Consistency. Every video follows the same visual language.
- Speed. Once the components exist, a new video is mostly writing a script.
- Fixes at scale. Improving a component improves every future video.
Limits:
- It does not replace good ideas. A dull script produces a dull video, just faster.
- Synthetic voices are good but still less expressive than a skilled human narrator.
- Very custom scenes, like a one-off animation for a single video, are still easier in a traditional editor.
- Building the first set of components takes real time and some web development skill.
Lessons for other creators
- Find the repeating structure in your videos. If your videos share a shape, that shape can be automated.
- Start with one format. I began with Shorts, then reused the components for long videos.
- Automate the checks, not just the creation. Quality gates saved me from publishing broken videos more than once.
- Keep humans for judgment. I still review contact sheets and decide what is worth publishing.
Conclusion
Making videos with code changed how I think about content. Instead of spending hours on timelines, I spend that time on scripts and on improving the system. Tools like Remotion, Kokoro and Whisper make this possible at very low cost. If you are a developer who wants to publish consistently, treating video as data is worth trying.
Written by Omkar Vijay Ghate, Mumbai.
More guides on this blog
Voice AI agents
- How to Reduce Latency in AI Voice Agents
- How to Write a System Prompt for an AI Voice Agent
- How to Test an AI Voice Agent Before Launch
- How to Read AI Voice Agent Call Logs
- Connecting AI Voice Agents to VICIdial and Asterisk
- Multilingual Voice AI for India
- Voice Cloning for Business in India
AI agents and automation
- What Is Agentic AI?
- How to Build an AI Agent Without Code
- How to Build a WhatsApp RAG Chatbot
- AI Workflow Automation with n8n
- Prompt Engineering Guide 2026
- AI Customer Service in India
- AI vs Human Customer Service
- The Future of Work with AI Agents
- AI and Human Creativity
YouTube automation
- Get link
- X
- Other Apps
Popular Posts
How to Reduce Latency in AI Voice Agents: A Practical Checklist
- Get link
- X
- Other Apps
How to Read AI Voice Agent Call Logs: Status vs Real Outcome
- Get link
- X
- Other Apps
Comments
Post a Comment