Skip to main content
Loops is in early access. Fill out the signup form to request access for your workspace.
Loops is a training SDK for fine-tuning and post-training large language models at long sequence lengths. You write a Python training loop that calls a dedicated trainer and sampler for a supported base model. Each forward pass, optimizer step, and sampling call goes through the API.

How Loops works

A Loops session pairs a trainer with a sampler. The trainer runs forward, backward, and optimizer steps. The sampler generates output from the latest weights published by the trainer. Because they scale independently, reinforcement learning (RL) rollouts do not compete with training for compute. You can wait for weight transfers synchronously or asynchronously to run on-policy or bounded off-policy algorithms. Download checkpoints through presigned URLs, or deploy them to the Baseten Inference Stack through the UI, CLI, or API.

Where to go next

The Loops quickstart runs the full session lifecycle: train a step, sample from the tuned weights, list the checkpoint, and shut the trainer and sampler down. The Loops concepts page explains sessions, trainers, samplers, checkpoints, and weight synchronization. Use Training Jobs when you need to bring your own container and training code. Training on Baseten compares Loops and Training Jobs. To migrate an existing Tinker project, see Migrate from Tinker.