Hierarchical phylogeny construction