Change _query to instance method
Update test cases
Add fq-tree.py