Port to TreeBuilder 4