When you challenged to build an app that able to read aloud text or document, your first option is Google Text to Speech API. It is indeed powerful, and pricey. Google's solution may not suit for developer on budget.
Here is an alternative for Google Text to Speech API that you may utilize. The idea is to use a Web API, embedded in modern web browser, even mobile.
The basic code is simply:
var speech = new SpeechSynthesisUtterance(); specch.text = "This is the way"; window.speechSynthesis.speak(speech);
You can try it now in your browser's console. The downside, it may not compatible with some browser such as IE, Web View Android & Opera.
The good part? IT IS FREE! For more practical demonstration, you may check Mohan Raj's Text to Speech quick demo