(actually just noticed we can delete the "switch" map from X above to get an even smaller counterexample – a monoid with just three elements. since any two-element monoid is commutative, this is the smallest counterexample. more generally, consider the "words on an alphabet" example where we identify any two words that begin with the same letter.)