Many changes to make compatible with upcoming PhyloBox integration.