title: How does System Profiler retrieve the full Mac hardware identifier?
body: <p>There are several terminal commands to retrieve the numerical / abbreviated Model Identifier for Mac hardware.</p>
  
  <ul>
  <li><code>sysctl hw.model</code></li>
  <li><code>system_profiler SPHardwareDataType</code></li>
  </ul>
  
  <p>These dump a string with the hardware name and x,y versioning. Currently we have to maintain a table to convert these identifiers into the full english machine description.</p>
  
  <p>Is there an API, or better a command line tool that can produce the more human friendly names that match Apple's documentation <strong>MacBook Pro 15-inch, Mid 2009</strong> or <strong>MacBook Pro (13-inch, 2016, Four Thunderbolt 3 Ports)</strong> instead of the more abbreviated <strong>MacBookPro5,3</strong> or <strong>MacBookPro13,2</strong> Model Identifier?</p>
  
  <p><img src="https://i.stack.imgur.com/Ka0Up.png" alt="MacBookPro5,3">
  <img src="https://i.stack.imgur.com/Pz5SF.png" alt="MacBookPro13,2"></p>
  
  <p>To summarize, how does System Profiler get the full localized names of Macintosh hardware in a way I can generate to consume that information systematically via script or program?</p>