Creates an instance of AgentException.
AgentException
Description of the problem encountered by the AI Agent.
Optional cause of the exception, which can provide additional context about the error.