Skip to main content

Fine-Tuning

Fine-tuning continues the training of a supported base model on examples for a specific task. It can reinforce response patterns, terminology, style, or output structure. It does not automatically add reliable, current knowledge and it does not guarantee better results. Model and provider support varies. Confirm the available base models, data format, limits, and costs in your B-Bot Hub configuration before preparing a dataset.

Choose the Right Method

System Prompt

Use for instructions, priorities, tone, boundaries, and behavior that may change.

Knowledge Retrieval

Use for source material that must stay current, traceable, or easy to replace.

Fine-Tuning

Use for repeated examples of the behavior or output pattern you want the model to learn.
Try prompt and knowledge improvements first. Consider fine-tuning when you have a stable task, a measurable gap, representative examples, and a supported model.

Fine-Tuning Workflow

1

Define the Target

Write a narrow improvement goal, such as following a response schema or applying a consistent support style.
2

Create an Evaluation Set

Prepare representative test cases before training. Keep them separate from training examples.
3

Prepare Examples

Use clear inputs and reviewed ideal outputs. Include normal cases, difficult cases, and appropriate refusals.
4

Review the Dataset

Remove duplicates, contradictions, sensitive data, outdated facts, and examples that reward unsupported claims.
5

Train a Version

Select a supported base model and use the training controls available in B-Bot Hub.
6

Compare and Decide

Evaluate the base and trained versions on the same held-out cases. Adopt the trained version only when it improves the defined target without unacceptable regressions.

Dataset Principles

  • Representative: Match real inputs, including their length and ambiguity.
  • Consistent: Resolve conflicts in tone, policy, and expected behavior.
  • Complete: Include enough context for the desired answer.
  • Current: Remove stale policies, product details, and links.
  • Safe: Exclude secrets and personal data unless collection and use are approved.
  • Balanced: Include cases where the correct behavior is to ask, refuse, or escalate.
There is no universal number of examples that guarantees a useful model. Start with a reviewed dataset, measure the result, and add examples that address observed gaps.

Evaluation

Evaluate dimensions separately:
  • Task success and factual accuracy
  • Instruction and format compliance
  • Appropriate uncertainty and refusal
  • Robustness to paraphrases and edge cases
  • Regressions outside the target behavior
  • Latency and cost in the intended environment
Record the dataset version, base model, configuration, and evaluation results so the decision can be reproduced.

Common Mistakes

Frequently changing facts are usually easier to maintain in a knowledge source or request context.
This measures memorization, not performance on new requests. Keep a separate evaluation set.
Generated examples can contain errors and repeated patterns. Review them before training.
A completed training job is not evidence of better behavior. Compare against the base model.

Training Guide

Use the B-Bot Hub training interface.

Model Distillation

Learn how teacher-generated examples can support a fine-tuning dataset.