# Model arguments
model_name_or_path: google/gemma-2-9b-it
torch_dtype: null
attn_implementation: eager

# Data training arguments
chat_template: "{{ bos_token }}{% if messages[0]['role'] == 'system' %}{% set system_message = messages[0]['content'] | trim + '\n\n' %}{% set messages = messages[1:] %}{% else %}{% set system_message = '' %}{% endif %}{% for message in messages %}{% if loop.index0 == 0 %}{% set content = system_message + message['content'] %}{% else %}{% set content = message['content'] %}{% endif %}{% if (message['role'] == 'assistant') %}{% set role = 'model' %}{% else %}{% set role = message['role'] %}{% endif %}{{ '<start_of_turn>' + role + '\n' + content | trim + '<end_of_turn>\n' }}{% endfor %}{% if add_generation_prompt %}{{'<start_of_turn>model\n'}}{% endif %}"
dataset_mixer:
  princeton-nlp/gemma2-ultrafeedback-armorm: 1.0
dataset_splits:
- train
- test
preprocessing_num_workers: 12

# SimPOTrainer arguments
bf16: true
beta: 10
gamma_beta_ratio: 0.5
do_eval: true
evaluation_strategy: steps
eval_steps: 400
gradient_accumulation_steps: 16
gradient_checkpointing: true
gradient_checkpointing_kwargs:
  use_reentrant: False
hub_model_id: simpo-exps
learning_rate: 8.0e-7
log_level: info
logging_steps: 5
lr_scheduler_type: cosine
max_length: 2048
max_prompt_length: 1800
num_train_epochs: 1
optim: adamw_torch
output_dir: outputs/gemma-2-9b-it-simpo
run_name: gemma-2-9b-it-simpo
per_device_train_batch_size: 2
per_device_eval_batch_size: 4
push_to_hub: false
save_strategy: "steps"
save_steps: 1000000
report_to:
- wandb
save_total_limit: 20
seed: 42
warmup_ratio: 0.1
