A rose-tree library with polymorphic nodes, edges, and leaves