Enforcing Randomness in Malicious Setting
The way that this is used is that each party proves in zero-knowledge during the protocol that it sent the correct message based on its committed input, the randomness defined by the committed $s_i$ value and the clear $s'_i$ value, and the series of incoming messages. This proof forces the party to not use any other randomness.

However, in order for this to work formally, you can't use plain commitments. Rather, the commitment must be something that we call ``extractable'' by a simulator. 

In any case, you should read more about this as the GMW compiler. You can read about it in the 2nd volume of Goldreich's textbook.