Skip to content
AI & Data

A Practical Framework for Fine-Tuning a Model vs. Using a Hosted API

Most teams default to fine-tuning too early or too late — a decision framework based on data volume, latency needs, and total cost of ownership, not hype.

4 min readMay 6, 2025
Share
A Practical Framework for Fine-Tuning a Model vs. Using a Hosted API

The fine-tune-versus-hosted-API question comes up in almost every AI engagement, usually framed as a technology decision. It's really a total-cost-of-ownership decision, and the teams that get it wrong tend to make the call based on which option feels more sophisticated rather than which one fits their actual constraints — data volume, latency budget, update frequency, and who's going to maintain it in a year.

Start with the question a hosted API almost always answers well

For the majority of enterprise use cases we see — document summarization, classification, drafting assistance, customer support triage — a well-prompted call to a hosted frontier model API handles the task adequately without any fine-tuning. The reasons to default here first:

  • No training infrastructure to maintain. Fine-tuning isn't a one-time cost — model updates, retraining as data drifts, and evaluation all become ongoing engineering work someone owns.
  • Frontier models improve continuously. A fine-tuned smaller model locks in the reasoning capability of its base model at training time; a hosted API upgrade often improves your feature for free with a version bump.
  • Faster time to a working feature. Prompt engineering and few-shot examples can be iterated in hours. A fine-tuning run, plus the data pipeline to support it, is measured in weeks at minimum.

The mistake is stopping the analysis here just because it's the easier path. There are specific, identifiable conditions where fine-tuning is genuinely the better call, and ignoring them costs real money at scale.

When fine-tuning earns its complexity

Three conditions, and we look for at least two of them before recommending a client invest in fine-tuning:

  1. High, consistent request volume with a narrow, well-defined task. If you're making a million classification calls a month against a task that hasn't changed in six months, a fine-tuned smaller model can cut per-call cost by an order of magnitude compared to a frontier model API call, and often improves latency too. This math doesn't work at low volume — the fine-tuning investment doesn't amortize.
  2. A task where prompting genuinely plateaus. For some structured extraction tasks — pulling specific fields out of non-standardized documents, for instance — we've hit a ceiling on hosted-model accuracy no amount of prompt iteration moved past, and fine-tuning on a few thousand labeled examples closed the gap meaningfully. This is task-specific; test it before assuming it applies.
  3. Latency requirements a hosted API can't hit reliably. Sub-200ms response requirements, common in real-time fraud scoring, are hard to guarantee against a third-party API with variable load. A fine-tuned, self-hosted smaller model gives control over the full latency budget.

What fine-tuning does not solve

Fine-tuning is frequently proposed as a fix for hallucination or for the model "not knowing" company-specific information. It's rarely the right tool for either. Hallucination is better addressed with retrieval-augmented generation and stricter prompting; company-specific knowledge is a retrieval problem, not a training problem, in the vast majority of cases we've evaluated. Fine-tuning teaches a model a task pattern or a style, not facts — feeding it your product documentation as training examples doesn't reliably make it "know" your product the way retrieval does.

Data volume and quality requirements are usually underestimated

Teams frequently assume fine-tuning needs less data than it does, or don't account for the labeling effort. A usable fine-tuning dataset for a narrow classification or extraction task typically needs:

  • At least 500-1,000 high-quality labeled examples as a starting point, more for tasks with high output variability.
  • A labeling process with inter-annotator agreement checked, not a single person's judgment — inconsistent labels teach the model inconsistency.
  • A held-out evaluation set that's genuinely separate from training data, refreshed periodically as the task or data distribution shifts.

Underestimating this step is the most common reason fine-tuning projects run over budget — the model training itself is usually the cheap and fast part; building a reliable, well-labeled dataset is the expensive part, and it's ongoing, not one-time, if the task evolves.

A workable decision path

When a client asks us to make this call, we walk through it roughly in this order: estimate monthly request volume and per-call cost difference at that volume; check whether the task is narrow and stable enough that a smaller fine-tuned model would plausibly match frontier-model accuracy; confirm a labeled dataset of sufficient size and quality either exists or can be built within budget; and only then weigh the ongoing maintenance cost of owning a fine-tuned model against the simplicity of a hosted API.

Most engagements land on a hosted API, sometimes with a smaller open-weight model added later once volume justifies it — and that's the right outcome for most teams, not a failure to be sophisticated. The cases where fine-tuning is clearly right tend to be obvious once the volume and latency numbers are actually run, rather than assumed.

Khoa Pham

Head of AI Engineering