Lepton
Lepton AI provides efficient inference for open-source language models with optimized deployment and scaling. Braintrust integrates seamlessly with Lepton through direct API access, wrapper functions for automatic tracing, and proxy support.
Setup
To use Lepton models, configure your Lepton API key in Braintrust.
- Get a Lepton API key from Lepton AI Dashboard
- Add the Lepton API key to your organization's AI providers
- Set the Lepton API key and your Braintrust API key as environment variables
API keys are encrypted using 256-bit AES-GCM encryption and are not stored or logged by Braintrust.
Use Lepton with Braintrust AI proxy
The Braintrust AI Proxy allows you to access Lepton models through a unified OpenAI-compatible interface.
Install the braintrust
and openai
packages.
pnpm add braintrust openai
Then, initialize the client and make a request to a Lepton model via the Braintrust AI Proxy.
Trace logs with Lepton
Trace your Lepton LLM calls for observability and monitoring.
When using the Braintrust AI Proxy, API calls are automatically logged to the specified project.
The Braintrust AI Proxy is not required to trace Lepton API calls. For more control, learn how to customize traces.
Evaluate with Lepton
Evaluations distill the non-deterministic outputs of Lepton models into an effective feedback loop that enables you to ship more reliable, higher quality products. Braintrust Eval
is a simple function composed of a dataset of user inputs, a task, and a set of scorers. To learn more about evaluations, see the Experiments guide.
To learn more about tool use, multimodal support, attachments, and masking sensitive data with Lepton, visit the customize traces guide.
Models and capabilities
Model | Multimodal | Reasoning | Max input | Max output | Input $/1M | Output $/1M |
---|---|---|---|---|---|---|
llama3-3-70b | ﹣ | ﹣ | $0.80 | $0.80 | ||
llama3-2-3b | ﹣ | ﹣ | $0.03 | $0.03 | ||
llama3-2-1b | ﹣ | ﹣ | $0.01 | $0.01 | ||
llama3-1-70b | ﹣ | ﹣ | $0.80 | $0.80 | ||
llama3-1-8b | ﹣ | ﹣ | $0.07 | $0.07 | ||
llama3-70b | ﹣ | ﹣ | $0.80 | $0.80 | ||
llama3-8b | ﹣ | ﹣ | $0.07 | $0.07 | ||
mistral-7b | ﹣ | ﹣ | $0.07 | $0.07 | ||
mixtral-8x7b | ﹣ | ﹣ | $0.50 | $0.50 | ||
wizardlm-2-7b | ﹣ | ﹣ | $0.07 | $0.07 | ||
wizardlm-2-8x22b | ﹣ | ﹣ | $1.00 | $1.00 | ||
nous-hermes-llama2-13b | ﹣ | ﹣ | $0.18 | $0.18 | ||
dolphin-mixtral-8x7b | ﹣ | ﹣ | $0.50 | $0.50 |