Skip to content

unexpected keyword argument tokenizer [FIXED]  #1285

@avemio-digital

Description

@avemio-digital

I used orpo colab example for mistral model and I am getting this error. I am using below configs

from trl import ORPOConfig, ORPOTrainer
from unsloth import is_bfloat16_supported

orpo_trainer = ORPOTrainer(
model = model,
train_dataset = dataset,
tokenizer = tokenizer,
args = ORPOConfig(
max_length = max_seq_length,
max_prompt_length = max_seq_length//2,
max_completion_length = max_seq_length//2,
per_device_train_batch_size = 2,
gradient_accumulation_steps = 4,
beta = 0.1,
logging_steps = 1,
optim = "adamw_8bit",
lr_scheduler_type = "linear",
max_steps = 1500, # Change to num_train_epochs = 1 for full training runs
fp16 = not is_bfloat16_supported(),
bf16 = is_bfloat16_supported(),
output_dir = "outputs",
report_to = "none", # Use this for WandB etc
),
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions