I have been working to build a complex data structure which would return a dictionary. Currently that class return string object of the form
{
cset : x,
Is that the actual data format? Do you have any flexibility?
It's very nearly JSON, which is a standard data format for which Python has native libraries for reading and writing (serialising and deserialising). However, to make it valid JSON both the keys and values would need to be surrounded by quotes:
"cset" : "x",
"b1" : "y"
and so on.