what is a query_tool? Make this a Session.