| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135 |
- """
- Reson Agent - 模块化、可扩展的 Agent 框架
- 核心导出:
- - AgentRunner: Agent 执行引擎
- - RunConfig: 运行配置
- - Trace, Message, Goal: 执行追踪
- - Skill: 技能模型
- - tool: 工具装饰器
- - TraceStore: 存储接口
- """
- # 核心引擎
- from agent.core.runner import AgentRunner, CallResult, RunConfig
- from agent.core.presets import AgentPreset, AGENT_PRESETS, get_preset
- # 执行追踪
- from agent.trace.models import (
- Trace,
- Message,
- Step,
- StepType,
- StepStatus,
- ChatMessage,
- Messages,
- MessageContent,
- )
- from agent.trace.goal_models import Goal, GoalTree, GoalStatus
- from agent.trace.attachments import AttachmentRef
- from agent.trace.protocols import TraceAttachmentStore, TraceStore
- from agent.trace.store import FileSystemTraceStore
- # 技能系统
- from agent.skill.models import Skill
- # 工具系统
- from agent.tools import tool, ToolRegistry, get_tool_registry
- from agent.tools.models import ToolCapability, ToolResult, ToolContext
- # 显式任务执行与独立验证
- from agent.orchestration import (
- CompletionPolicy,
- AgentRole,
- TaskStatus,
- ValidationVerdict,
- ExecutionStats,
- FailureCode,
- BackgroundOperation,
- OperationKind,
- OperationStatus,
- OrchestrationAPIError,
- OrchestrationClient,
- ValidationMode,
- ValidationPlan,
- TaskCoordinator,
- AgentExecutor,
- TaskStore,
- FileSystemTaskStore,
- ArtifactStore,
- FileSystemArtifactStore,
- OrchestrationConfig,
- RoleRunConfigOverrides,
- RoleRunConfigResolver,
- RoleSystemPromptOverride,
- RoleSystemPromptResolver,
- )
- from agent.orchestration.wiring import wire_orchestration
- # SDK 公开入口:统一调用 remote / 本地 Agent
- from agent.client import invoke_agent
- __version__ = "0.4.0"
- __all__ = [
- # Core
- "AgentRunner",
- "CallResult",
- "RunConfig",
- "AgentPreset",
- "AGENT_PRESETS",
- "get_preset",
- # Trace
- "Trace",
- "Message",
- "ChatMessage",
- "Messages",
- "MessageContent",
- "Step",
- "StepType",
- "StepStatus",
- "Goal",
- "GoalTree",
- "GoalStatus",
- "TraceStore",
- "TraceAttachmentStore",
- "AttachmentRef",
- "FileSystemTraceStore",
- # Skill
- "Skill",
- # Tools
- "tool",
- "ToolRegistry",
- "get_tool_registry",
- "ToolCapability",
- "ToolResult",
- "ToolContext",
- # Orchestration
- "CompletionPolicy",
- "AgentRole",
- "TaskStatus",
- "ValidationVerdict",
- "ExecutionStats",
- "FailureCode",
- "BackgroundOperation",
- "OperationKind",
- "OperationStatus",
- "OrchestrationAPIError",
- "OrchestrationClient",
- "ValidationMode",
- "ValidationPlan",
- "TaskCoordinator",
- "AgentExecutor",
- "TaskStore",
- "FileSystemTaskStore",
- "ArtifactStore",
- "FileSystemArtifactStore",
- "OrchestrationConfig",
- "RoleRunConfigOverrides",
- "RoleRunConfigResolver",
- "RoleSystemPromptOverride",
- "RoleSystemPromptResolver",
- "wire_orchestration",
- # SDK
- "invoke_agent",
- ]
|