There are many ways to approach this, but here is what I will use:
1) Get a dictionary like /usr/share/dict/words
2) Write a program that looks at each letter and calculates the odds of any letter following it. For example, it might seem that E has a 1% chance that A will follow, or that X has a 5% chance that it will be followed by the end of a word.
This should allow you to generate words like words, but not the words themselves.
source share