From what I understand, it works like this:
Your Lead Pokémon carries Yawn instead of Trick, as it normally would. It uses it on the first turn, and then on the second turn it generally diverts the attack away by using Protect or U-Turn if that's available. Then, while the opponent sleeps, you either have your Lead set up on it in the usual manner or attempt to get a Sweeper in instead and set up.
The main issues that I see with it are getting two suitable Sweepers, I guess. As you will have two free turns to set up before the opponent can chose its attacks again, you need to make it work fast and it would help if you had weakened the opponent down a little bit first. A slow Lead is also required because you will need to be moving after the opponent to be able to get them back to Sleep again after the two turns when they wake up. Essentially,
>Opponent wakes up and attacks
> You use Yawn
> You use Protect
> Repeat
Rather than
> Opponent wakes up and attacks
> You use Yawn
> Opponent attacks again
> You Protect
> Repeat
Essentially, cutting out a turn of damage. You will also need to refer to the BT List to identify the opponent's moveset to know when to bring in your Sweeper. I believe Togekiss works pretty well with this, as do Snorlax and Uxie, but I'm not quite sure of movesets. My knowledge of this is pretty basic and I don't know that much about it yet, but this is what I can gather. Might be wrong, but it could be fun anyway.