huggingface / huggingface/setfit

examples out of date ?

Open
#572 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jupyter Notebook
Stars
2.8k
Forks
267
Avg merge
36m
Merged PRs (30d)
5

Description

Hi,

It seems the example code is out of date

I follow notebooks/text-classification.ipynb, as well as the blog on huggingface.
these use SetFitTrainer, which is deprecated, when I try to use Trainer, the parameters are no longer valid.
Unfortunelely I'm unable to infer how an up to date incantation should look like (should add training arguments data structure ?)

specifically loss_class=CosineSimilarityLoss, is not recognized.

(edit : it seems the example https://huggingface.co/docs/setfit/how_to/zero_shot contains clues as to how to call the trainer with trainerarguments data structure)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with notebooks/text-classification.ipynb and compare its trainer usage with the Hugging Face zero-shot documentation linked in the issue. Update the example to use the current trainer API and valid parameters, including the reported loss configuration, so the notebook runs without deprecated or unrecognized arguments.

Written by the indexing model from the issue text.

Assessment

Tech stack
huggingface, jupyter-notebook
Domain
documentation, machine-learning
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.