Integrations¶
Weights & Biases¶
LLM Engine integrates with Weights & Biases to track metrics during fine tuning. To enable:
from llmengine import FineTune
response = FineTune.create(
model="llama-2-7b",
training_file="s3://my-bucket/path/to/training-file.csv",
validation_file="s3://my-bucket/path/to/validation-file.csv",
hyperparameters={"report_to": "wandb"},
wandb_config={"api_key":"key", "project":"fine-tune project"}
)
Configs to specify:
- (Required) Set
hyperparameters.report_totowandbto enables automatic metrics tracking. - (Required) Set
wandb_config.api_keyto the API key. - (Optional) Set
wandb_config.base_urlto use a custom Weights & Biases server. wandb_configalso accepts keys from wandb.init().