use state tree in builder