Generate random UUID
Pyth, 20 bytes

j\-msm.HO16*4hdj83 3


Demonstration.

Encodes [1, 0, 0, 0, 2] as 83 in base 3, then adds one and multiplies by four to get the length of each segment. Then makes hex digits and joins on hyphens.