Skip to content

Commit

Permalink
Fix pyright warnings/errors
Browse files Browse the repository at this point in the history
This patch fixes a pyright string concatenation warning and also adds
typing information where necessary.
  • Loading branch information
boomanaiden154 committed Sep 20, 2023
1 parent 83d36a5 commit 1831916
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion llmfoundry/data/finetuning/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ def __getitem__(self, idx: int) -> Dict[str, Any]:
return _read_binary_tokenized_sample(sample)
else:
raise RuntimeError(
'FineTurningDataset needs samples to have prompt/response columns '
'FineTurningDataset needs samples to have prompt/response columns ' +\
'or tokens/labels columns')


Expand Down
2 changes: 1 addition & 1 deletion tests/test_dataloader.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def build_mock_ft_streaming_dataset(data_path: str, split: str):
output_writer.write(sample)


def build_mock_tokenized_ft_streaming_dataset(data_path, split):
def build_mock_tokenized_ft_streaming_dataset(data_path: str, split: str):
columns = {'tokens': 'bytes', 'labels': 'bytes'}

dataset = [{
Expand Down

0 comments on commit 1831916

Please sign in to comment.