@utilities.arguments_not_none<EOL><INDENT>def unassign_agent_from_resource(self, agent_id, resource_id):<DEDENT>
collection = JSONClientValidated('<STR_LIT>',<EOL>collection='<STR_LIT>',<EOL>runtime=self._runtime)<EOL>resource = collection.find_one({'<STR_LIT>': ObjectId(resource_id.get_identifier())})<EOL>try:<EOL><INDENT>resource['<STR_LIT>'].remove(str(agent_id))<EOL><DEDENT>except (KeyError, ValueError):<EOL><INDENT>raise errors.NotFound('<STR_LIT>')<EOL><DEDENT>collection.save(resource)<EOL>
Removes an ``Agent`` from a ``Resource``.

        arg:    agent_id (osid.id.Id): the ``Id`` of the ``Agent``
        arg:    resource_id (osid.id.Id): the ``Id`` of the ``Resource``
        raise:  NotFound - ``agent_id`` or ``resource_id`` not found or
                ``agent_id`` not assigned to ``resource_id``
        raise:  NullArgument - ``agent_id`` or ``resource_id`` is
                ``null``
        raise:  OperationFailed - unable to complete request
        raise:  PermissionDenied - authorization failure
        *compliance: mandatory -- This method must be implemented.*