Add proper string substitution for transitions/reductions