What this is
Use this as the default lifecycle: bootstrap a trainer, run iterative updates, export checkpoints, then sample through deployment endpoints for realistic evaluation.How to use these APIs
tinker.ServiceClient: Connect your local loop to the trainer service.TrainingClient.forward_backward / forward_backward_custom: Compute gradients with built-in or custom objectives.TrainingClient.optim_step: Apply optimization updates.TrainingClient.save_weights_for_sampler: Export serving-compatible checkpoints.Fireworks.deployments.*: Hotload and evaluate checkpoints under serving conditions.
Workflow
- Create or reuse a service-mode trainer job.
- Instantiate a training client from the trainer endpoint.
- Run repeated train steps with objective + optimizer updates.
- Save sampler checkpoints on cadence.
- Hotload the serving deployment and sample evaluation prompts.
- Record metrics and decide whether to continue or branch experiments.
End-to-end examples
Bootstrap training client
Run train-step with custom objective
Checkpoint, hotload, and evaluate
Operational guidance
- Service-mode trainer jobs currently support full-parameter tuning only. When
serviceMode=true, settraining_config.lora_rankand Tinker clientrankto0. - Keep checkpoint intervals predictable so evaluation comparisons are stable.
- Store the exact prompt set used for each evaluation sweep.
Common pitfalls
- Sampling from trainer internals instead of deployment endpoints can skew results.
- Missing checkpoint-to-deployment traceability makes rollback risky.