Convert phases to A|B|C