Set audio output device hierarchy? Is it possible to set a hierarchy for audio output devices? 

I have a home and work office and move my MacBook Pro (13", Touchbar) between them. When I'm at work, I connect to an Apple Thunderbolt display with built-in audio. At home, I connect to an HDMI monitor with horrible built-in audio, so I prefer to use the MacBook's speakers. 

Despite manually changing the output device in each environment, the MacBook can't seem to make the right (or even consistent) choice on its own.

For example, at work, instead of choosing the Thunderbold display's speakers as an output device, my MacBook will choose it's internal speakers. At home, it will choose the HDMI monitor's speakers. 

It would be great if I were to be able to put the output devices in a hierarchy, so, if a device at the top of the list exists, it would be selected before any others… similar to how you can drag Wifi networks into a specific order:
Try using your Audio MIDI Setup application under the Utilities folder. I don't have multiple outputs to test, but it looks like you may be able to adjust the order of preference.

Also as an alternative workaround you could use a VGA or DVI cable instead of HDMI, which will only transfer video and no audio.