huggingface / huggingface/course

Keyword argument 'evaluation_strategy' in TrainingArguments has been replaced with 'eval_strategy'

Open
#987 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
MDX
Stars
4.2k
Forks
1.4k
Avg merge
13m
Merged PRs (30d)
1

Description

Hi team,

In Chapter 7: Fine-Tuning a Masked Language Model, the example code uses:
```
TrainingArguments(
...,
evaluation_strategy="epoch",
...
)
```
However, the evaluation_strategy keyword argument in TrainingArguments has now been replaced with eval_strategy. Using the old argument causes an error:
```
TypeError: TrainingArguments.__init__() got an unexpected keyword argument 'evaluation_strategy'
```
See this related discussion for reference:
https://github.com/huggingface/transformers/issues/7974#issuecomment-2803578764

Proposed fix:
Update the code example to use `eval_strategy` instead of `evaluation_strategy` to match the latest transformers library version.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.