Skip to main content

Module runtime

Module runtime 

Source
Expand description

Agent lifecycle and execution management

This module provides runtime infrastructure for managing agent execution.

§Main Components

  • AgentBuilder: Builder pattern for constructing agents
  • SimpleRuntime: Multi-agent coordination (non-dora)
  • AgentRuntime: Dora-rs integration (with dora feature)

§Example

use mofa_sdk::runtime::{AgentBuilder, SimpleRuntime};

let runtime = SimpleRuntime::new();
runtime.register_agent(metadata, config, "worker").await?;

Structs§

AgentBuilder
智能体构建器 - 提供流式 API
AgentRegistry
Agent 注册中心
AgentRunner
统一 Agent 运行器
AgentRunnerBuilder
AgentRunner 构建器
FrameworkConfig
框架核心配置
RegistryStats
注册中心统计
RunnerStats
运行器统计信息
SimpleRuntime
简单运行时 - 管理多个智能体的协同运行(非 dora 版本)

Enums§

RunnerState
运行器状态

Traits§

AgentFactory
Agent 工厂 Trait

Functions§

run_agents
创建并运行 Agent(多次执行)