Skip to content

Commit 00ee933

Browse files
committed
add suggestions from coderabbit
Signed-off-by: michaelfeil <63565275+michaelfeil@users.noreply.github.com>
1 parent a5eb313 commit 00ee933

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

modelopt/torch/utils/dataset_utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,12 +151,12 @@ def _third_party_get_dataset_samples(
151151
kwargs["tools"] = tools
152152
if not messages:
153153
raise ValueError(
154-
f"Column {i} in dataset {dataset_name} has no messages, or a empty messages."
154+
f"Row {i} in dataset {dataset_name} has no messages, or a empty messages."
155155
)
156156
text: str = tokenizer.apply_chat_template(messages, **kwargs, tokenize=False)
157157
if len(text) == 0:
158158
raise ValueError(
159-
f"Column {i} in dataset {dataset_name} has empty text after applying chat template."
159+
f"Row {i} in dataset {dataset_name} has empty text after applying chat template."
160160
)
161161
texts.append(text)
162162
elif "prompt" in dataset.column_names:
@@ -166,7 +166,7 @@ def _third_party_get_dataset_samples(
166166
else:
167167
raise NotImplementedError(
168168
f"Dataset {dataset_name} is not supported. Please use one of the following: {get_supported_datasets()}. "
169-
" For supporting thrid-party datasets, your dataset must have either a `messages` or `prompt` column, and a `train` split."
169+
" For supporting third-party datasets, your dataset must have either a `messages` or `prompt` column, and a `train` split."
170170
" For example the `baseten/quant_calibration_dataset_v1` dataset has a `messages` column and a `train` split."
171171
)
172172

0 commit comments

Comments
 (0)