These 'caller' if statements would make more sense as components of the individual query object.  It makes the code more readable, and the options need to be specified in the docstring anyway.