Skip to content
All case studies

Frameflow, Marketing technology

From one product photo to a finished talking video ad

A five-stage video generation application designed around asynchronous provider work and callback-driven progression.

Built for: A marketing software team producing UGC-style video ads for brands.

generation stages
5
generation stages
configured output
10s
configured output
provider cost per video
~$1.35
provider cost per video

First agent live in one week. A short call. Your first agent, a fixed quote, and the timeline. No obligation.

Frameflow case study overview: what we built, key numbers, and AI used

Sound familiar?

  • “Every video means copying files between four different AI tools by hand.”
  • “Jobs stall halfway and nobody knows which stage failed.”
  • “We can't tell what one finished video actually costs us to produce.”

How the system works.

  1. Step 1

    Five-stage creative pipeline

    Scene analysis, imagery, script, image-to-video, and voice with lip-sync run as one sequence from a single reference image and product brief.

  2. Step 2

    Orchestration that waits properly

    AWS Step Functions coordinates each stage and pauses on task tokens until long-running provider jobs report back, instead of holding a web request open.

  3. Step 3

    Callback routing to the right project

    Every external job ID is stored in DynamoDB, so when a provider calls back through API Gateway the pipeline resumes the correct project at the correct stage.

  4. Step 4

    Failure handling built in

    A dedicated error path records a failed generation as a clear project state, so no video appears to run forever.

  5. Step 5

    Per-video cost model

    Provider costs were broken out per stage so the team could see the unit economics of each output.

What changed.

  • 5 creative stages run end to end from one reference image.
  • 10-second finished videos with 12-15 word scripts, per the production configuration.
  • About $1.35 in provider cost per video: roughly $0.001 Gemini, $0.50 Kling, and $0.83 Sync.so.
  • No one moves intermediate files between providers; the pipeline carries each job to finalized media.

The AI inside.

Google Gemini

Analyzes the reference scene and prepares imagery and the script.

Kling

Turns the prepared image into video.

Speech generation

Produces the voiceover from the script.

Sync.so

Lip-syncs the voice to the generated video.

The full stack.

Frontend

  • React
  • Vite
  • AWS Amplify

Backend

  • AWS Lambda
  • API Gateway callbacks

Data

  • DynamoDB
  • Amazon S3

AI and automation

  • AWS Step Functions
  • Gemini
  • Kling
  • Sync.so
  • Speech generation

Infrastructure

  • AWS CDK (TypeScript)

This fits you if...

  • Your team chains several AI tools together by hand to produce one output.
  • You run long AI jobs that finish minutes later and need to resume reliably.
  • You need to know the real cost of each generated asset before you scale it.

Start with a free Agent Audit. First agent live in one week

The AI Operations Assistant brings this to your team.

An AI team member that handles the admin work across your email, documents, CRM, and spreadsheets, and asks before anything important goes out.

Full project write-upRead it

Project overview

A five-stage pipeline for UGC-style video ads

Services: AI Workflow Automation ; AI Agents
Delivery: Video-generation application and AWS orchestration infrastructure. Portfolio alias.

Project Snapshot

FigureWhat it represents
5 creative stagesScene, image, script, video, and voice/lip-sync
10-second videoTarget output in the documented pipeline
12-15 wordsScript target in the documented configuration
About $1.35Historical provider-cost estimate per video, not a current measured all-in cost

The Problem

Producing one video involved several AI services. An image had to reach the video provider, the script had to reach speech generation, and the finished video and audio had to reach lip-sync.

The providers did not all finish within one request. A video job could remain active after the user left the page. The application needed to retain the job, recognize the callback, and continue from the correct stage.

What We Delivered

The pipeline starts with a reference image and product information. Gemini analyzes the scene and prepares the imagery and script. Kling handles image-to-video generation. Speech generation and Sync.so provide the voice and lip-sync stages.

AWS Step Functions coordinates the sequence. Lambda tasks perform individual actions, DynamoDB stores project and external-job information, and S3 holds media. API Gateway exposes callback routes.

The state machine includes waits for Kling and Sync.so completion, a finalization task, and an error-handling path.

Engineering Decisions

Wait for completion events. The pipeline uses task-token waits for long-running jobs rather than holding an ordinary web request open.

Retain the external job ID. A provider callback needs to resolve to the correct project and stage.

Track failure as part of the workflow. A failed generation must leave a useful project state rather than appearing to run forever.

Keep the cost breakdown visible. Earlier documentation estimates roughly $0.001 for Gemini, $0.50 for Kling, and $0.83 for Sync.so, rounded to about $1.35. Retries, duration, infrastructure, and changing provider rates can alter the actual cost.

Results

The delivered product coordinates the generation stages from input to finalized media. Users do not need to manually move each intermediate output between the providers in that pipeline.

The historical estimate is useful for explaining the original unit-cost design. It is not presented as a current price guarantee or evidence that the videos increased ad conversions.

Technology stack

React, Vite, Amplify; AWS CDK in TypeScript; Step Functions, Lambda, DynamoDB, S3, API Gateway; Gemini, Kling, speech generation, and Sync.so.

Want this for your team?

Book a short audit call and show us the workflow. You leave with the first agent we would build, a fixed quote, and the timeline.

Get my free Agent Audit