@staticmethod
def flatten_query_tree(query_tree):
    """
        Takes a query tree and returns the elements in list form.

        Args:
            query_tree (dict): A nested dictionary that organizes queries by domain then intent.

        Returns:
            list: A list of Query objects.
        """
    flattened = []
    for _, intent_queries in query_tree.items():
        for _, queries in intent_queries.items():
            flattened.extend(queries)
    return flattened
