refactored assemble function into TSPLBase