As mentioned by the previous educator, there are three stages of Winston's reintegration: learning, understanding and acceptance.
Each of these three stages comes with a very specific form of torture, designed to break Winston down and make him realise that resistance against Big Brother is futile.
In the first stage, for example, Winston learns that the party is all-powerful and will use any method to bring about his domination. We see this through the violent beatings that he suffers and the "Party intellectuals" who inject Winston with an unknown chemical. O'Brien also encourages Winston's learning by saying that Julia has betrayed him; a fact designed to cause distress and demonstrate that the party can break anyone down, even the most rebellious.
In the second stage, O'Brien increases the intensity of Winston's torture with the introduction of a machine called the dials. This machine enables O'Brien to inflict pain on Winston (controlled by a lever) as he questions him on the party. If Winston gets a question wrong (does not answer according to party ideology) then O'Brien cranks the lever, causing more pain:
O'Brien had pushed the lever of the dial up to thirty-five.
"That was stupid, Winston, stupid!" he said. "You should know better than to say a thing like that."
Finally, the third stage of Winston's reintegration is represented by Room 101. There is much mystery surrounding the contents of this room. When asked, O'Brien tells Winston that it contains "the worst thing in the world." When Winston is sent there, in Part Three, Chapter Five, he is confronted by rats, his ultimate fear. He is so overcome with terror that he almost immediately relents:
Do it to Julia! Do it to Julia! Not me!
O'Brien has thus demonstrated the effectiveness of the three stages of reintegration. Having betrayed Julia, the woman he loved, Winston is no longer considered to pose a threat to the party's supremacy. He is released from the Ministry of Love, completely reformed.