Training
Fine-tune a model on
your agent's conversations.
An open-source recipe that turns your agent's labelled conversations into a dataset and tunes the model it runs with SFT, DPO or GRPO reinforcement learning, on Fireworks, Baseten or Tinker.
Why it matters
Your agent's conversations already hold the examples a model needs.
A label is a dataset
Reviewers label replies in the annotations queue, or you import a labelled file. Either one becomes the examples to train on.
Held-out cases
Cases the training never sees score the base and the tuned model side by side, field by field.
Rewards in a sandbox
The code that scores each reply for GRPO runs in our secure sandboxes, next to the data it reads.
Your provider account
Training and serving are billed by the provider to your own account, with a budget that switches an endpoint off.
How it works
The Operator's training phase works through these steps with you, and asks before anything is trained or deployed.
1. Connect
Pick the provider and the model to tune, and check the project holds the provider's key.
2. Prepare
Find the labels that hold examples, or import a file, and check no held-out case is among them.
3. Train
Run a short trial, then the full training. Its page draws the train and test loss as each step lands.
4. Serve
See the hardware and its hourly price, set a budget, deploy, then compare base and tuned on the held-out cases.
- Base model
- glm-5p3-flash
- Duration
- 2m 33s
- Steps
- 5 / 5
- Examples (train / test)
- 598 / 66
- Tokens (trained / total)
- 21,248 / 194,719
A five-step trial on Fireworks. The page draws the train and test loss as each step lands.
1agent: agent2select:3include: [router-correct, router-wrong, router-corrected]4exclude: [router-needs-review]5holdout: evals/vitest/route-held-out.eval.jsonl6target:7script: training/router.py8train:9method: sft10provider: fireworks11base_model: accounts/fireworks/models/glm-5p3-flash12lora_rank: 813epochs: 114batch_size: 1615learning_rate: 1.0e-416max_seq_len: 204817validation_fraction: 0.118eval_every: 519evaluate:20max_tokens: 25621temperature: 0
Your data stays on the Platform
Data preparation happens on the Platform, and reward functions run in our secure sandboxes. Only the examples to train on reach the provider, on your own key.
- Create a runtime from a template, with your agent through the Operator, or from your terminal with our CLI
- Keep the recipe's repository on Introspection or in your own GitHub
- Label, import and build examples on a data plane that can sit entirely inside your own VPC on AWS, Azure or GCP
- GRPO reward functions run in our secure sandboxes, beside the data they score
- The provider's key is stored write-only in the project, and one key trains and serves
Methods and providers
Train on Fireworks, Baseten or Tinker with SFT, DPO or GRPO. Start with SFT.
SFT
Trains on labelled replies: the reply to give. A target script builds it from field labels when the reply is not written out.
DPO
Trains on pairs, a better and a worse reply to the same prompt. Suits a model that answers in the right shape but sometimes picks wrong.
GRPO
Reinforcement learning on prompts and a reward. The reward function runs in our secure sandboxes and scores each reply the model tries.
Fireworks, Baseten, Tinker
Fireworks and Baseten serve the tuned model on a dedicated deployment, per GPU-hour. On Tinker it answers as soon as training ends.