I see! It makes total sense. I copied and pasted without any modifications the train.py script in this blog post from Huggingface The Partnership: Amazon SageMaker and Hugging Face. Maybe that tutorial is outdated or requires some changes*
Another question that I have is that I don’t defined anywhere the way the data is passed to the model for inference. I haven’t got to that point yet, but I am assuming the data should be passed as a json with a key as inputs and value as array of the text? Something like this: data = {'inputs': ['text_1', 'text_2', ...]}. And that is regardless of the dataset and its format that I have used?
Thank you again!