<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def note_addition(self, key, value):
 """ Updates the change state to reflect the addition of a field. Detects previous changes and deletions of the field and acts accordingly. """

        # If we're adding a field we previously deleted, remove the deleted note.
        if key in self._deleted:
            # If the key we're adding back has a different value, then it's a change
            if value != self._deleted[key]:
                self._previous[key] = self._deleted[key]
            del self._deleted[key]
        else:
            self._added.append(key)