Change serializer to remove 'state' field from serialized objects, instead merging type info and state together.