You probably first want to analyze the response metadata to understand where the latency is a) filtering, b) projection/aggregation, c) lookup, d) any custom UDFs.
Once we know which part is slow, there are different options to make each part faster.