Try harder to find a type name when serializing to JSON-LD
Mostly matters when (ab)using this for verifying unit test data.