Instead of separate segment trees for each chain, use one segment tree of size . Assign each node a global position flat_pos[v]. During decomposition, maintain a global counter. Nodes in the same chain get consecutive positions. This way, chain occupying positions to maps directly to range in the single segment tree.
This simplifies implementation. You only manage one segment tree instead of many. Space usage drops from to . Most implementations use this improvement.
Space complexity is for the data structures used.