Implement determinize function for StateMachine