类class
agentscope.exceptionAgentOrientedException
class AgentOrientedException(Exception)
源码Source
agentscope/exception/_base.py:5–18智能体 Oriented 异常,表示执行过程中的错误。位于 agentscope.exception 包,继承自 Exception。
The base class for all agent-oriented exceptions. Declared in agentscope.exception. Extends Exception.
构造器摘要Constructor Summary
| 构造器Constructor | 说明Description |
|---|---|
def __init__(message: str) | 初始化 `AgentOrientedException` 实例。 Initialize the exception with a message. |
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
def __str__() -> str | 返回字符串表示。 Return the string representation of the exception. |
构造器详情Constructor Detail
AgentOrientedException
def __init__(message: str)
初始化 AgentOrientedException 实例。
Initialize the exception with a message.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
message | str | 消息(类型 `str`)。The message. |
源码Source
agentscope/exception/_base.py:11–14方法详情Method Detail
__str__
def __str__() -> str
返回字符串表示。
Return the string representation of the exception.
str
返回字符串结果。Returns a string.
源码Source
agentscope/exception/_base.py:16–18