I forgot to post an answer to this question when I found it. Here's how:
Assuming I wanted to take the "Rarity" value from an ATTRIBUTE_MAP, this is how I would get it.
string rarity_value = get<string>(immutable_template_data["rarity"]);
For further context:
Hopefully this was clear enough to ...
Converting to/from JSON could take a long time. Blockchain transactions need to be very fast (<30ms). Recommend not doing this.
If you want to do it, you need to provide your own JSON encoder/decoder in your contract.