Now, this approach works very well until you have
very large bodies of text with many many words.
So for example, you could try the complete works of
Shakespeare and you'll likely hit memory errors,
as assigning the one-hot encodings of the labels to
matrices that have over 31,477 elements,
which is the number of unique words in the collection,
and there are over 15 million sequences
generated using the algorithm that we showed here.
So the labels alone would require
the storage of many terabytes of RAM.
So for your next task,
you'll go through a workbook by yourself
that uses character-based prediction.
The full number of unique characters in a corpus is far
less than the full number of
unique words, at least in English.
So the same principles that you use to
predict words can be used to apply here.
The workbook is at this URL, so try it out,
and once you've done, that you'll be ready for
this week's final exercise.