Comparisons

Build vs buy an AI avatar engine: the real costs

Build vs buy an AI avatar engine: what self-hosting a model really involves, a worked cost example, and when an avatar API is the cheaper path for B2B teams.

PitchTwin team, , 6 min read

You have a product that needs avatar video, a capable engineering team, and a stack of open research papers that make it look doable. The question every technical founder hits next: should you run your own avatar model, or pay an API per second of output? The answer depends less on the model itself and more on everything that has to surround it in production.

This post breaks down what "building" actually means, walks through a cost comparison with clearly hypothetical numbers, and lists the cases where each path wins.

What running your own avatar model involves

The model is the part people think about. In practice it is maybe a third of the work. A production avatar pipeline for a B2B product needs all of the following.

The model and its inputs

  • Model selection and licensing. Many research checkpoints ship with non-commercial licenses. Check before you build a roadmap on one.
  • Input normalization. Customers upload phone videos. You will see rotated clips, HEVC files that your decoder chokes on, 4K footage, and variable frame rates. Every one of these needs handling before inference.
  • Voice. If you voice scripts for customers, you need voice cloning and text-to-speech in addition to the video model, plus word-level timings if you want captions.
  • Quality control. You need a way to catch broken outputs before a customer's prospect does.

The infrastructure around it

  • GPU capacity. Avatar rendering is GPU work. You either keep GPUs warm (paying for idle time) or accept cold starts and queueing.
  • A job queue and async delivery. Videos take time to render, so you need queued jobs, status tracking, retries, and webhooks or polling for your own app.
  • Storage and signed URLs. Source clips, cloned voices, and output MP4s all need storage, expiry rules, and deletion paths.
  • Versioning. When you upgrade the model, existing avatars change. If a customer's sales rep suddenly looks slightly different, that is a support ticket. You need to pin avatars to model versions and run old versions side by side.

Then add the ongoing work: model upgrades, driver updates, on-call, and consent records for every person whose likeness you process. None of this is impossible. It is a product in its own right, built next to the one you actually sell.

A worked cost comparison

The numbers below are hypothetical and exist to show the arithmetic. Replace them with your own quotes and salaries.

Self-hosted assumptions

ItemHypothetical value
GPU instance$2.00 per hour
Render time3 minutes of GPU time per 1 minute of video
Always-on GPUs to avoid cold starts2
Engineering time1 engineer at $15,000 per month, fully loaded

Fixed GPU cost for two always-on instances:

2 GPUs × $2.00/hour × 730 hours/month = $2,920 per month

Two GPUs at a 3:1 render ratio can produce at most:

2 × 730 hours × 60 min ÷ 3 = 29,200 video minutes per month

So the self-hosted floor, before any traffic, is:

$2,920 (GPUs) + $15,000 (engineer) = $17,920 per month

API assumptions

Using PitchTwin's public pack prices: the Scale pack is $149 for 12,000 tokens. One token is one second of video when you bring your own audio, and 1.5 tokens per second when PitchTwin voices the script.

$149 ÷ 12,000 tokens = $0.0124 per token
Own audio:   60 tokens/min × $0.0124 ≈ $0.74 per minute
Our voice:   90 tokens/min × $0.0124 ≈ $1.12 per minute

Break-even

How many minutes per month does it take for the API bill to equal the self-hosted floor?

Own audio:  $17,920 ÷ $0.74 ≈ 24,200 minutes per month
Our voice:  $17,920 ÷ $1.12 ≈ 16,000 minutes per month

Below those volumes, the API is cheaper in this example. Above them, self-hosting starts to win on paper, but notice two things:

  1. 24,200 minutes is already close to the 29,200-minute ceiling of two GPUs. More volume means more GPUs, so the fixed cost climbs with you.
  2. The example assumes one engineer is enough, and that the self-hosted model also handles voice cloning and text-to-speech. If it does not, add that cost too.

For a deeper look at margin per customer, see unit economics of AI avatar products.

When building makes sense

Building is a reasonable choice when:

  • The avatar engine is your product. If your differentiation is the model itself, you should own it.
  • You need something no API offers. Real-time interactive avatars, on-premise deployment for a regulated buyer, or a custom output format are valid reasons.
  • You have sustained, predictable volume well past break-even and a team that already runs GPU inference in production.
  • You have research talent who will keep improving the model rather than just keeping it alive.

When buying makes sense

An API is usually the better fit when:

  • Video is a feature inside a larger product, such as an AI SDR tool, a training platform, or a recruiting product.
  • Your volume is uncertain or seasonal. Prepaid, per-second pricing scales down to zero; GPUs you reserved do not.
  • You want to ship this quarter rather than next year.
  • You would rather spend engineering time on the workflow your customers pay for.

When comparing APIs, look at output quality first, then price. Providers differ in how they make avatars. PitchTwin builds each avatar from real video of the person and keeps that original footage, so results look 1:1 like the person. Other providers have their own strengths, such as larger stock avatar libraries or studio editors; a side-by-side is in AI avatar API pricing compared.

The hybrid path: start with an API, keep the door open

You do not need to decide forever. Put a thin interface between your app and the video provider so you can swap it later.

// video-provider.ts
export interface VideoProvider {
  generate(input: { avatarId: string; text: string; webhookUrl: string }): Promise<{ id: string }>;
}

export class PitchTwinProvider implements VideoProvider {
  constructor(private apiKey: string) {}

  async generate(input: { avatarId: string; text: string; webhookUrl: string }) {
    const res = await fetch("https://pitchtwin.ai/api/v1/generations", {
      method: "POST",
      headers: {
        Authorization: `Bearer ${this.apiKey}`,
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        avatar_id: input.avatarId,
        text: input.text,
        voice: { language: "en" },
        webhook_url: input.webhookUrl,
      }),
    });
    if (res.status !== 202) throw new Error(`Generation failed: ${res.status}`);
    const { id } = await res.json();
    return { id };
  }
}

Store the generation ID and tokens_charged from each finished generation next to your own job record. That real cost data is what you need if you revisit the build decision. Also on the API side:

  • Failed generations are refunded automatically, so a failed render costs you nothing but a retry.
  • Each avatar is pinned to its engine version, so faces do not drift when the provider improves its models. This is the versioning problem from the build list, handled for you.
  • Tokens never expire and there are no seats or subscriptions, so an uneven month does not waste budget.

Decision checklist

QuestionLeans buildLeans buy
Is the avatar model your core differentiation?YesNo
Monthly video minutes, sustainedWell past your break-evenBelow or uncertain
Need for real-time or on-premiseYesNo
Team already runs GPU inference in productionYesNo
Time to shipNext year is fineThis quarter

If most of your answers land in the right column, buy now and revisit with real usage data in a year.

Try it

You can test the buy side in an afternoon. Sign up for 60 free seconds of video with no card, upload a clip in the dashboard, and generate a test video in the Playground. When you are ready to integrate, the quickstart covers the full request flow.

Keep reading