The guidelines from Apple for general internal speaker issue troubleshooting don't seem to offer much in terms of the problem you describe, but they're surely worth pursuing. And it seems like you've done a good job isolating the trigger, i.e., when the system falls asleep or goes into standby, it doesn't fully wake. There are a couple of things to try. One would be to reset the NVRAM, as suggested by the Apple Community Specialist chuck_3rd in this thread on a similar topic. Another thing to try is to reset the SMC, which the NVRAM Apple Support article mentions.
Lastly, you might also also consider seeing if the problem recurs with speakers other than the internal ones, such when Bluetooth speakers are connected or headphones are connected via the 3.5 mm jack. If you do end up having to contact Apple Support, the foregoing steps could provide useful diagnostic information to whomever assists you.
Good luck!
JDee