Convert to new tuple/map formatting