Actually, the keyboards are not different. The keytop engravings differ, but that's it.
There are really only a few actual physical differences amongst Model M/Windows and workalike keyboards. (i.e. I am not talking about things like Maltron keyboards.) Those are the differences between 101/104, 102/105, 103/106, 104/107, and 106/109 key keyboards.
Ironically, that's really all that looking at the keys next to the shift keys gives one. The 102/105-key and 104/107-key keyboards add a key at B00, in between the left shift and B01. The 104/107-key and 106/109-key keyboards add a key at B11, in between the right shift and B10. So it's possible to detect the number of keys somewhat by seeing what USB HID codes come down the wire for "next to the shift key".
But this does not tell the computer anything about what is engraved on the keytops, and is not sufficient information for determining, say, Dvorak from AZERTY. (It's not even sufficient for detecting the 103/106-key keyboard, whose extra keys are on row A.)
There are really only a few actual physical differences amongst Model M/Windows and workalike keyboards. (i.e. I am not talking about things like Maltron keyboards.) Those are the differences between 101/104, 102/105, 103/106, 104/107, and 106/109 key keyboards.
Ironically, that's really all that looking at the keys next to the shift keys gives one. The 102/105-key and 104/107-key keyboards add a key at B00, in between the left shift and B01. The 104/107-key and 106/109-key keyboards add a key at B11, in between the right shift and B10. So it's possible to detect the number of keys somewhat by seeing what USB HID codes come down the wire for "next to the shift key".
But this does not tell the computer anything about what is engraved on the keytops, and is not sufficient information for determining, say, Dvorak from AZERTY. (It's not even sufficient for detecting the 103/106-key keyboard, whose extra keys are on row A.)