It depends alot with the ref, being one of those moves that depends greatly on interpretation. Personally, I let the pokemon recover a set amount of HP each action, and Half that amount of Energy, but only allow it to last for 5 actions (as with the game). I usually make it about 10% HP (and so 5% Energy), since I feel letting it go straight back to 100% instantly is far to cheap and unfair. After 5 actions, 10% has totalled 50%, so that's half healed. Obviously it totally heals confusion, poison, and other status effects. Unlike other sleep conditions, they are less likely to be woken up by being attacked, unless it is severe (like, a resting Magmar dropped into a lake, for instance).