Serious refactoring

Mostly method renaming for increased clarity. Started work on the
ability to cache requests.