mirror of https://github.com/razor-ai/soup.git
53 lines
1.4 KiB
YAML
53 lines
1.4 KiB
YAML
# TEMPLATE — NOT runnable as-is. Bring your own images and JSONL.
|
|
#
|
|
# Every other config in this directory trains on a bundled fixture. This one
|
|
# cannot: there is no vision fixture in the repo, because we do not commit
|
|
# image files. So `data.train` and `data.image_dir` below are placeholders you
|
|
# must replace before this config will run.
|
|
#
|
|
# Vision fine-tuning of LLaMA-3.2-Vision on image + conversation pairs,
|
|
# LLaVA format:
|
|
#
|
|
# {"image": "cat.jpg", "conversations": [
|
|
# {"from": "human", "value": "<image>\nWhat is in this photo?"},
|
|
# {"from": "gpt", "value": "A cat sitting on a windowsill."}]}
|
|
#
|
|
# `image_dir` is the root the per-row `image` paths resolve against.
|
|
#
|
|
# Usage (after pointing data.train / data.image_dir at your own files):
|
|
# soup train --config examples/configs/vision_llama.yaml
|
|
|
|
base: meta-llama/Llama-3.2-11B-Vision-Instruct
|
|
task: sft
|
|
modality: vision
|
|
backend: transformers
|
|
|
|
data:
|
|
train: ./your_vision_data.jsonl # <- replace
|
|
format: llava
|
|
image_dir: ./your_images/ # <- replace
|
|
max_length: 4096
|
|
|
|
training:
|
|
epochs: 2
|
|
lr: 1e-4
|
|
batch_size: 4
|
|
gradient_accumulation_steps: 4
|
|
quantization: 8bit
|
|
scheduler: cosine
|
|
warmup_ratio: 0.1
|
|
weight_decay: 0.01
|
|
logging_steps: 10
|
|
save_steps: 50
|
|
lora:
|
|
r: 128
|
|
alpha: 256
|
|
dropout: 0.1
|
|
target_modules:
|
|
- q_proj
|
|
- v_proj
|
|
- k_proj
|
|
- o_proj
|
|
|
|
output: ./output_vision/
|