If you like perplexity, I've long advocated for using equivalent ideas when evaluating code and engineering quality. https://benoitessiambre.com/entropy.html
It's fundamental to anything trying to be smart.
The fact that LLMs explicitly target this measure is one reason they are getting good at engineering and architecture, sometimes better than humans who think they know better but lean on engineering fads instead of more mathematically supported (but more nuanced and probabilistic) principles like entropy/perplexity.