huggingface / huggingface/lighteval
[FT] Fail faster when passing unsupported metrics to InferenceEndpointModel
- Dominant language
- Python
- Stars
- 2.5k
- Forks
- 555
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 1
Description
## Issue encountered
When passing an unsupported metric (e.g. single-token metric) to `InferenceEndpointModel`, an error is raised from `Pipeline.evaluate`:
```
ValueError: Endpoint models can't use single token metrics. Change the metric to the standard version
```
This happens once the endpoint has been created and the model has been created and loaded.
I wonder if the error could be raised earlier for optimization reasons: the process fails faster and resources are not wasted.
## Solution/Feature
Raise the error before the endpoint has been created.
## Possible alternatives
Leave it as it is.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.