async def METHOD_NAME(self, message_id: str, reason: str) -> models.DbMessage:
    """Update an assistant message in the database to mark it as having been aborted by the allocated worker."""
    logger.warning(f"Aborting work on message {message_id}")
    message = await self.get_assistant_message_by_id(message_id)
    message.state = inference.MessageState.aborted_by_worker
    message.work_end_at = datetime.datetime.utcnow()
    message.error = reason
    await self.session.commit()
    logger.debug(f"Aborted work on message {message_id}")
    await self.session.refresh(message)
    return message