Duck
Tutorials8 min read

Build a Custom Slides AI Generator That Doesn't Suck

Samet Turan— Editor··8 min read

Stop wasting hours on presentations. Learn to build a custom slides AI generator that uses your content to create pitch decks and reports in minutes.

The Core Stack: What You Actually Need

You have a 20-page report that needs to become a 15-slide deck by 9 AM. The off-the-shelf slides AI generator tools you’ve tried spit out generic, clipart-filled garbage that looks nothing like your brand. You need a system that ingests your raw content and produces a presentation that’s actually usable. You can build it yourself.

This isn’t about finding the perfect all-in-one app. It’s about assembling a simple, powerful system from three components:

  • An LLM API: This is your brain. You’ll be making calls to an API like OpenAI’s GPT-4o or Anthropic’s Claude 3. We’re not using the chat interface; we’re using the API, which gives us structured control.
  • A Slide Creation API: This is your hands. You need a way to programmatically create a presentation file. The best way is using the Google Slides API. It’s free and works directly with your Google account. You could also use a service like Slidev if you prefer Markdown-based generation, but the Google Slides API is more direct for most business users.
  • An Orchestration Tool: This is the nervous system connecting the brain and hands. A no-code AI tool like the Make platform or, my preference, a low-code platform like Pipedream will run your workflow, call the LLM, process the response, and then call the slide API.

Honestly, for this kind of multi-step logic, Pipedream is the better choice. You can drop into Node.js or Python for a single step if you need to transform data in a specific way, which is often necessary when dealing with API responses. Make.com is great, but its error handling and data manipulation can get clunky for complex chains. Pipedream’s $19/mo developer plan is a bargain for what you get, and the free tier is more than enough to build and test this entire flow.

What Most Guides Get Wrong

Almost every tutorial on this topic makes the same fundamental mistake. They treat slide generation as a single-step process. They tell you to write one massive prompt that says, “Take this document and turn it into a 10-slide presentation.”

🤖
Recommended Reading

AI Side Hustles

12 Ways to Earn with AI

Practical setups for building real income streams with AI tools. No coding needed. 12 tested models with real numbers.


Get the Guide → $14

★★★★★ (89)

This never works.

You get a deck with a nonsensical structure, repeated points, and generic filler. The LLM tries to do too many things at once—summarize, structure, write, and design—and fails at all of them. It’s a classic sign of someone who has only used the ChatGPT web UI and hasn’t built a production system.

The correct approach is to build a multi-agent chain. Think of it as an assembly line, not a magic box. Each step has a single, clearly defined job. This is the core of a functional ai agent framework. Your workflow won’t be one prompt; it will be a sequence of at least three specialized prompts that hand off work to each other.

Step-by-Step: The Prompting Chain for Coherent Slides

Let’s walk through the assembly line. Imagine we’re feeding it a long-form document about quarterly sales performance.

Step 1: The Distiller Agent
The first agent doesn’t write any slides. Its only job is to read the entire source document and pull out the most important facts, figures, and arguments. It creates a dense, structured summary. This is your source of truth for the rest of the process.

A simple prompt for this might be:

Analyze the following document. Extract the key performance indicators (KPIs), main conclusions, strategic initiatives mentioned, and any direct quotes or data points that are essential. Output this as a structured JSON object with keys: 'kpis', 'conclusions', 'initiatives', and 'data_points'.

Step 2: The Architect Agent
This agent takes the distilled summary from Step 1 and designs the presentation’s structure. It doesn’t write the content for the slides yet. It only decides what the slides should be about and in what order. It creates the narrative flow.

The prompt would look something like this:

Based on the following summary, create a logical slide deck outline. The deck should have a Title Slide, an Agenda, a slide for each key conclusion, a summary of next steps, and a Q&A slide. For each slide, provide a short, action-oriented title and a brief description of its purpose. Output as a JSON array of objects, where each object has 'slide_title' and 'slide_purpose' keys.

This step is critical. By forcing the AI to create an outline first, you prevent it from rambling or creating a deck with no clear point.

Step 3: The Writer.com Agent Loop
This is where the slides actually get written. Your orchestration tool (Pipedream) will loop through the JSON array created by the Architect. For each slide in the outline, it runs a new, highly-focused prompt.

The Writer prompt gets the distilled summary from Step 1 and the specific slide title/purpose from Step 2. Its job is to write the content for *only that one slide*.

You are a business presentation writer. Using the provided context, write the content for a single slide titled "{slide_title}". The slide's purpose is "{slide_purpose}". Your output must be a JSON object containing a 'title' (string, max 10 words) and 'bullet_points' (array of strings, max 4 items, each max 15 words). Ground your response *only* in the provided context. Do not invent information. Context: {distilled_summary}

By running this in a loop, you ensure each slide is crafted individually, based on a clear instruction, which dramatically increases quality.

So, How Do You Handle Images and Branding?

This is where every automated tool falls apart. My biggest gripe with commercial AI slide generators is their complete disregard for branding. They insert cheesy stock photos and use fonts and colors that clash with your company’s style guide. It’s an instant signal of a low-effort presentation.

Don’t let the LLM handle design. It can’t. The solution is a template.

My favorite workflow uses the Google Slides API. I have a master template presentation saved in Google Drive. It has all our company branding: the logo in the corner, the correct font (Inter, not Arial), the right color palette for titles and body text, and pre-formatted layouts for different slide types (e.g., title slide, bullet point slide, image-with-caption slide). The API doesn’t create slides from scratch; it makes a *copy* of my template and then just inserts the text generated by the Writer agent into the predefined text boxes. This is a one-time setup that guarantees every single presentation is perfectly on-brand.

For images, the approach is similar. Don’t ask the LLM to find an image. It will give you a useless URL to a watermarked stock photo. Instead, modify your Writer agent’s prompt to also suggest a *concept* for an image. Add a key to the JSON output called `image_concept` (e.g., “a simple line graph showing revenue growth,” or “an icon representing teamwork”). You can then use that string to search an image API like Unsplash or an icon API like Noun Project to find and insert relevant, high-quality visuals.

How to Debug When This Breaks

This system will fail. The most common point of failure is the LLM breaking the JSON format in its response. A stray comma or a missing bracket can crash your entire workflow. The fix is twofold. First, be explicit in your prompt: add a sentence like “Your response MUST be a valid, minified JSON object and nothing else. Do not include any explanatory text before or after the JSON.” Second, your orchestration tool needs to validate the response. Both Make.com and Pipedream have built-in JSON parsing modules that will throw an error if the format is invalid, so you can catch it and even retry the LLM call.

The second common failure is content drift, where the AI starts hallucinating facts not present in the source document. This happens when your prompts aren’t properly grounded. The fix is in the Writer agent loop. Make sure you are passing the relevant chunk of the *original document* or the *distilled summary* into the prompt for each slide. Don’t let the agent rely on conversation history. This is a core discipline in any good operator playbook: keep your context tight and your prompts stateless.

Finally, log everything. Store the input and output of every single API call. When a slide comes out with bizarre text, you can trace it back to the exact prompt and LLM response that generated it. Without logs, you’re just guessing.

Scaling: From One-Off Decks to an Automated Engine

Once you’ve built this workflow, you have more than just a slides AI generator. You have an asset. You can trigger it from anywhere. Set up a webhook to run it from a Slack command. Or, my favorite, point it at a Google Drive folder. Using a trigger in Pipedream or Make.com, the system can watch for any new file dropped into a folder called “Reports to Process.” When a new document appears, it automatically runs the entire chain and saves the finished slide deck to an “Outputs” folder.

This is a true ai automation blueprint. It’s a system that works for you in the background. And the cost is trivial. With current GPT-4o pricing, processing a 30-page document into a finished deck might cost you ten cents. The bottleneck isn’t the AI; it’s the execution limits of your orchestration tool’s plan.

Building this takes some effort upfront (especially the Google Slides API authentication, which, yes, is annoying to set up the first time). But the result is a custom, branded, high-quality generator that you own and control.

For more on this exact angle, deeper coverage of AI agent platforms.

If you’d rather skip the build and deploy a working version in an afternoon, we’ve packaged this entire slides AI generator workflow as a blueprint at deepusecase.com/vault.

— The Colophon

One AI tool. Tested. Reviewed.
In your inbox every Sunday.

~3 minute read. Real outcomes from operators, not marketers.

Free. One email per Sunday. Unsubscribe in one click.