Skip to content

Commit 6f847cf

Browse files
sjmonsonAlonKellner-RedHat
authored andcommitted
Convert single data to list
Signed-off-by: Samuel Monson <[email protected]> Signed-off-by: Alon Kellner <[email protected]>
1 parent a5422b0 commit 6f847cf

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/guidellm/benchmark/schemas.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424

2525
import yaml
2626
from pydantic import (
27-
AliasChoices,
28-
AliasGenerator,
2927
ConfigDict,
3028
Field,
3129
ValidationError,
@@ -1957,13 +1955,13 @@ def get_default(cls: type[BenchmarkGenerativeTextArgs], field: str) -> Any:
19571955
description="Whether to stop the benchmark if the model is over-saturated",
19581956
)
19591957

1960-
@field_validator("data", "data_args", "rate", mode="wrap")
1958+
@field_validator("data", mode="wrap")
19611959
@classmethod
19621960
def single_to_list(
19631961
cls, value: Any, handler: ValidatorFunctionWrapHandler
19641962
) -> list[Any]:
19651963
"""
1966-
Ensures field is always a list.
1964+
Ensures 'data' field is always a list.
19671965
19681966
:param value: Input value for the 'data' field
19691967
:return: List of data sources

0 commit comments

Comments
 (0)