QueryAgent: A Reliable and Efficient Reasoning Framework with Environmental Feedback-based Self-Correction