Text classification example issue

I am a beginner and did an example on text classification.

I did it on R studio with importing python modules but in the training process, an issue occurs with the above message.

Please help with this issue… I don’t know the reason why this issue related cardinality happens.