The Core Stack: What You Actually Need
Forget the all-in-one, click-a-button web apps. They produce generic, soulless content that gets zero engagement. If you want to build a real ai shorts generator for your business, you need to assemble it from specialist components. This is the only way to get the control you need for quality output. It’s an AI automation blueprint, not a toy.
Here’s the stack I use:
- The Brain (LLM): This is your scriptwriter. I use OpenAI‘s GPT-4o via their API for this. It’s fast, relatively cheap, and its instruction-following for structured output (like JSON) is reliable enough for production. You could use Claude 3 Opus, but I find it gets a bit too verbose for short-form video scripts.
- The Voice (TTS): You need a text-to-speech API that doesn’t sound like a robot from 2008. ElevenLabs voice is the clear winner here. The quality is exceptional, and their API is straightforward. The Starter plan at $5/mo is a no-brainer for high-quality voiceovers. Honestly, the free tier is a joke for any real work due to the limitations and lack of commercial licensing.
- The Assembler (Video API): This is the magic piece that stitches everything together. You send it a timeline with video clips, audio files, text overlays, and transitions, and it renders a final MP4 for you. I use Shotstack for this. It’s a true API-first video editor, which is exactly what an operator needs. It’s not a drag-and-drop tool with an API tacked on as an afterthought.
That’s it. Three core components. You orchestrate these with a simple workflow tool. You can use the Make platform or Pipedream for this. I prefer Pipedream for its code-level control, but Make is a solid no-code AI option if you’re less technical.
What Most Guides Get Wrong About AI Shorts
Most tutorials on this topic are fundamentally flawed. They show you how to create a glorified PowerPoint presentation with a robot voiceover. They miss the entire point of what makes a Short or Reel engaging.
AI Side Hustles
Practical setups for building real income streams with AI tools. No coding needed. 12 tested models with real numbers.
Get the Guide → $14
Here’s what they get wrong:
- They treat it as a single prompt problem. They’ll show you a massive, complicated prompt that tries to generate a script, scene descriptions, and keywords all at once. This never works reliably. The LLM gets confused, and the output quality plummets. Real automation uses a chain of smaller, focused prompts.
- They rely on static images. A video made of DALL-E images panning slowly is not a video. It’s boring, and platforms are starting to de-prioritize this kind of low-effort content. You need actual video clips to hold attention.
- They ignore pacing. Shorts need to be fast. The visuals must change every 1-3 seconds. The script needs to be punchy. Most AI-generated scripts are rambling and academic. You have to explicitly prompt for a fast-paced, direct style suitable for the medium.
The goal isn’t just to automate video creation. It’s to automate the creation of *good* video. Big difference.
Step-by-Step: From Topic to Rendered Short
Let’s build a workflow for a short video explaining the concept of ‘API’.
Step 1: Generate the Script with a Master Prompt
First, we hit the GPT-4o API. The key is to ask for the script *and* a list of visual concepts for each sentence. We also demand the output in a clean JSON format.
{ "role": "system", "content": "You are a scriptwriter for viral tech-explainer TikToks. Your style is extremely direct, fast-paced, and uses simple analogies. You will write a script that is under 60 seconds when read aloud. For each sentence, provide a corresponding visual concept. The final output must be a JSON object with a single key 'scenes', which is an array of objects, each with 'text' and 'visual' keys." }
{ "role": "user", "content": "Write a script explaining what an API is." }
The LLM will return a structured JSON that your automation workflow can easily parse. This is far more reliable than trying to regex a block of text.
Step 2: Generate the Voiceover
Take the ‘text’ value from each scene and concatenate them into a single string. Send this to the ElevenLabs API. It will return an MP3 file. Store this file somewhere accessible, like an S3 bucket, and save its URL. The duration of this audio file is now your master timing for the entire video.
Step 3: Source Visual Assets
Now, iterate through the ‘visual’ value for each scene from Step 1. These are your search queries for a stock video provider. Use the Pexels API or Storyblocks API. For a visual like “waiter taking order from a customer,” you’ll search for that. My biggest gripe with the Pexels API is its search relevance; you ask for ‘server rack blinking lights’ and get a stock photo of a dinner server. It’s infuriating and requires either very clever keyword mapping in your prompt or a manual review step.
For each scene, grab the URL of the best video clip you find.
Step 4: Assemble and Render the Video
This is where Shotstack comes in. You’ll construct a JSON payload that defines the video edit. You’ll have one audio track (the ElevenLabs MP3) and multiple video clips on the timeline. You calculate the duration for each clip to match the pacing of the voiceover. You can also add text overlays, captions, and transitions here.
A simplified Shotstack request might look something like this:
{ "timeline": { "tracks": [ { "clips": [ { "asset": { "type": "video", "src": "PEXELS_VIDEO_URL_1" }, "start": 0, "length": 3.5 }, { "asset": { "type": "video", "src": "PEXELS_VIDEO_URL_2" }, "start": 3.5, "length": 4.1 } ] }, { "clips": [ { "asset": { "type": "audio", "src": "ELEVENLABS_MP3_URL" }, "start": 0 } ] } ] }, "output": { "format": "mp4", "resolution": "1080p", "aspectRatio": "9:16" } }
You send this to their API. It queues the render job. A few minutes later, you get a webhook ping with the URL to your final, rendered MP4 file. Done.
