1. A method for executing voice applications to perform a voice-based function, the method comprising: retrieving a document; parsing the document to create a parse tree; create script code from the parse tree, thereby consuming part of the parse tree to create a reduced parse tree; and storing the reduced parse tree in a cache for subsequent use to perform the voice-based function.