encoder: guess map value type