Manage API keys
Get your LastMile API key
- Log in or sign up for free at https://lastmileai.dev
- Navigate to API Keys console
- Click
+ New Key
Export the API key you generated as an environment variable. Alternatively, you can also pass it directly into the Lastmile
client.
- bash
- python
export LASTMILE_API_TOKEN="your_api_key"
from lastmile import Lastmile
from lastmile.lib.auto_eval import AutoEval
# Recommended: AutoEval client SDK (higher-level APIs)
client = AutoEval(api_token="api_token_if_LASTMILE_API_TOKEN_not_set")
# Lastmile client (REST API wrappers)
client = Lastmile(
bearer_token="api_token_if_LASTMILE_API_TOKEN_not_set",
)
Configure Weights & Biases API token
AutoEval allows you to track detailed training runs in your own Weights & Biases account. To do so, navigate to the API Keys console, and save your W&B API key. Subsequent fine-tuning runs will be tracked in your account.