Implemented a more efficient parsing, searches cache for partial matches as well