If a dog is stressed or afraid, their demeanor and typical behaviors will change. If you see this in your dog (or really any dog you know) you should step back and check on your dog. Are they hurt? Did a new dog come around they don’t know? Has the weather changed? Is it hot outside? When was the last time they had a chance to go outside to pee or poop?
For pups that ambush you and bite your rear end while playing outside, hide a toy or two in the backyard and ask them to find the toy. Bad weather can give puppies cabin fever when they don’t have adequate time outside to run off the energy. Mental stimulation can wear them out, too. Show your puppy a favorite toy and then roll it up inside an old towel and knot it to make a puzzle. Encourage the pup to unravel and get the toy. You can even tie the first toy-in-the-towel inside a second one for more of a challenge to relieve boredom.
Other commands can be substituted for ‘sit’ if you prefer, such as ‘stay’ or ‘down.’ However, if your dog simply gets too excited to execute these commands properly (as is often the case, especially with puppies) try diverting their attention elsewhere. Ask them to go find their ball, or a favorite toy, as a way to distract them and expend some energy. And, as always, reward the good behavior with praise.