hi @jonkl2024
The below comment thread mentions all the error or correction you require to do in your codes
Also your codes have the same issue as the post creator
Convert the original string into a tensor, you are support convert the texts and not text to tensor as it mention original string
Same goes for next line of code where you vectorise, you need to use texts
Refer to the linked comment which explains this part about the same.
next your code is incorrect for the iteration step as you have left it _ blank, it requires you recall the iteration.
next the code has been recalled incorrectly if next token is EOS, refer the linked comment, it has an image on how to recall.
Regards
DP