def modify(self, fields=None, **fields_kwargs):
modified_fields = set()<EOL>fields = self.make_dict(fields, fields_kwargs)<EOL>fields = self._modify(fields)<EOL>for field_name, field_val in fields.items():<EOL><INDENT>in_schema = field_name in self.schema.fields<EOL>if in_schema:<EOL><INDENT>setattr(self, field_name, field_val)<EOL>modified_fields.add(field_name)<EOL><DEDENT><DEDENT>return modified_fields<EOL>
update the fields of this instance with the values in dict fields

        this should rarely be messed with, if you would like to manipulate the
        fields you should override _modify()

        :param fields: dict, the fields in a dict
        :param **fields_kwargs: dict, if you would like to pass the fields as key=val
            this picks those up and combines them with fields
        :returns: set, all the names of the fields that were modified