<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def register(self, key, value):
 """ Registers a callable with the specified key. `key` String key to identify a callable. `value` Callable object. """


        self._actions[key] = value

        # invalidate cache of results for existing key
        if key in self._cache:
            del self._cache[key]