分层架构
EnerOS 采用严格的五层架构,从上到下依次为:应用层、Agent 运行时、电力原生内核、实时安全网关、基础设施。每一层只能依赖下层,禁止跨层调用与反向依赖,通过 Cargo workspace 的依赖约束在编译期强制保证。
设计原则
| 原则 | 说明 | 强制方式 |
|---|---|---|
| 单向依赖 | 上层依赖下层,下层不感知上层 | Cargo.toml 依赖声明 |
| 接口隔离 | 层间通过 trait 通信,不暴露实现 | Rust trait + impl segregation |
| 关注点分离 | 每层只负责自身职责,不越权 | 模块边界 + clippy 规则 |
| 可替换性 | 同层组件可互换(如潮流求解器) | trait 抽象 + feature flag |
| 测试独立性 | 每层可独立单元测试 | crate 隔离 + mock trait |
架构层次总览
┌─────────────────────────────────────────────────────────────────────┐
│ L5 应用层 (Application Layer) │
│ 调度 · 运维 · 交易 · 规划 · 能效 · 自愈 · 数字孪生 │
│ [DispatchAgent] [OperationAgent] [TradingAgent] │
│ [PlanningAgent] [SelfHealingAgent] [ForecastAgent] │
├─────────────────────────────────────────────────────────────────────┤
│ L4 Agent 运行时 (Agent Runtime) │
│ 7 领域 Agent · 多智能体协作 · 记忆/工具/推理/学习 │
│ [eneros-agent] [eneros-reasoning] [eneros-memory] │
│ [eneros-tool] [eneros-ai] [eneros-twin] [eneros-nl] │
├─────────────────────────────────────────────────────────────────────┤
│ L3 电力原生内核 (Power-Native Kernel) │
│ 拓扑 · 潮流 · 约束 · 设备 · 时序 · 分析 · 事件 │
│ [eneros-topology] [eneros-powerflow] [eneros-constraint] │
│ [eneros-equipment] [eneros-timeseries] [eneros-analysis] │
│ [eneros-eventbus] [eneros-cnpower] [eneros-emtp] │
├─────────────────────────────────────────────────────────────────────┤
│ L2 实时安全网关 (Real-Time Safety Gateway) │
│ mTLS · CA · IDS · 审计 · 合规 · 网关 · 信任 │
│ [eneros-gateway] [eneros-trust] [eneros-ids] │
│ [eneros-audit] [eneros-compliance] │
├─────────────────────────────────────────────────────────────────────┤
│ L1 基础设施 (Infrastructure) │
│ OS 服务 · 网络 · 存储 · 多区域 · 多租户 · 协议 · 设备 │
│ [eneros-os] [eneros-network] [eneros-multiregion] │
│ [eneros-tenant] [eneros-scada] [eneros-device] │
│ [eneros-protocol-*] [eneros-perf] [eneros-core] │
└─────────────────────────────────────────────────────────────────────┘
层间数据流
┌──────────────────┐
│ 用户 / SCADA │
└────────┬─────────┘
│ REST / GraphQL / WebSocket / SSE
▼
┌─────────────────────────────────────────────────────────────────┐
│ L5 应用层 │
│ DispatchAgent.plan() → TradingAgent.bid() → ... │
└────────┬────────────────────────────────────────────────────────┘
│ Agent SDK 调用(system_call)
▼
┌─────────────────────────────────────────────────────────────────┐
│ L4 Agent 运行时 │
│ lifecycle / orchestrator / reasoning / memory / tool │
└────────┬────────────────────────────────────────────────────────┘
│ 内核系统调用(Kernel API)
▼
┌─────────────────────────────────────────────────────────────────┐
│ L3 电力原生内核 │
│ topology.analyze() → powerflow.solve() → constraint.check() │
└────────┬────────────────────────────────────────────────────────┘
│ 命令下发(Command)
▼
┌─────────────────────────────────────────────────────────────────┐
│ L2 实时安全网关 │
│ gateway.execute_command() → trust.verify() → audit.log() │
└────────┬────────────────────────────────────────────────────────┘
│ 设备操作(Device Op)
▼
┌─────────────────────────────────────────────────────────────────┐
│ L1 基础设施 │
│ device.write() → scada.scan() → timeseries.write() │
└─────────────────────────────────────────────────────────────────┘
L5 - 应用层(Application Layer)
应用层是 EnerOS 的最上层,承载面向电力业务的具体场景。每个应用由一个或多个领域 Agent 组成,通过 Agent 运行时调用内核能力。
职责
- 业务流程编排(调度、运维、交易、规划)
- 用户交互(CLI、Web、API 客户端)
- 报表与可视化
- 第三方系统集成
应用组件
| 应用 | 关键 Agent | 执行域 | 主要场景 |
|---|---|---|---|
| 智能调度 | DispatchAgent | 通用域 | 经济调度、负荷分配、机组组合 |
| 负荷预测 | ForecastAgent | 通用域 | 短期/超短期负荷预测 |
| 智能运维 | OperationAgent | 通用域 | 设备状态监测、寿命预测 |
| 电力交易 | TradingAgent | 通用域 | 现货市场报价、虚拟电厂运营 |
| 配网规划 | PlanningAgent | 通用域 | 配电网扩展规划与方案比选 |
| 故障自愈 | SelfHealingAgent | 实时域 | 故障定位、隔离与供电恢复 |
| 数字孪生 | eneros-twin | 通用域 | 电网实时镜像与仿真推演 |
| 报表中心 | eneros-report | 通用域 | PDF/Excel/Word 报表生成 |
| 可视化 | eneros-dashboard | 通用域 | Web 可视化与 3D 场景 |
| 自然语言 | eneros-nl | 通用域 | 自然语言交互与意图识别 |
| 电力市场 | eneros-market | 通用域 | 电力市场撮合与结算 |
| 边缘智能 | eneros-edge | 通用域 | 边缘 AI 推理与自治 |
应用层代码示例
use eneros_agent::dispatch_agent::DispatchAgent;
use eneros_core::Command;
#[tokio::main]
async fn main() -> anyhow::Result<()> {
// 创建调度 Agent
let mut agent = DispatchAgent::builder()
.with_name("dispatch-001")
.with_region("east-grid")
.build()
.await?;
// 执行经济调度
let plan = agent.run_economic_dispatch().await?;
println!("调度计划: {} 台机组参与", plan.generators.len());
// 通过安全网关下发控制命令
for gen in &plan.generators {
let cmd = Command::new_generator_setpoint(
gen.id,
gen.target_mw,
"dispatch-001",
);
agent.gateway().execute_command(cmd).await?;
}
Ok(())
}
L4 - Agent 运行时(Agent Runtime)
Agent 运行时提供 Agent 的完整生命周期管理、多智能体协作、推理与学习能力。
职责
- Agent 生命周期(创建、暂停、恢复、销毁、迁移)
- 多智能体协作(Orchestrator 编排)
- 记忆系统(短期/长期/向量记忆)
- 工具引擎(工具注册、调用、权限)
- 推理引擎(LLM 集成、ReAct/CoT 策略)
- 学习与反思(RL、反思、解释)
组件详解
| 组件 | 职责 | 关键 Crate | 核心 Trait |
|---|---|---|---|
| Agent 生命周期 | 创建/暂停/恢复/销毁 | eneros-agent | Agent / AgentLifecycle |
| 编排器 | 多 Agent 任务分配与协调 | eneros-agent (orchestrator) | Orchestrator |
| 记忆系统 | 短期/长期/向量记忆 | eneros-memory | MemoryStore |
| 工具引擎 | 工具注册与调用 | eneros-tool | Tool / ToolRegistry |
| 推理引擎 | LLM 集成与推理策略 | eneros-reasoning | ReasoningEngine |
| AI/ML | 异常检测、预测、嵌入 | eneros-ai | Predictor / Embedder |
| 数字孪生 | 实时镜像与 what-if | eneros-twin | TwinModel |
| 自然语言 | 意图识别与对话 | eneros-nl | IntentRecognizer |
| 学习 | 强化学习与反馈 | eneros-agent (learning) | Learner |
| 反思 | 自我评估与改进 | eneros-agent (reflection) | Reflector |
| 解释 | LIME/SHAP 可解释性 | eneros-agent (explain) | Explainer |
| 协作 | Peer-to-peer Agent 通信 | eneros-agent (collab) | Peer |
Agent 运行时代码示例
use eneros_agent::{Agent, AgentBuilder, Orchestrator};
use eneros_memory::MemoryStore;
use eneros_tool::ToolRegistry;
use eneros_reasoning::ReasoningEngine;
#[tokio::main]
async fn main() -> anyhow::Result<()> {
// 1. 构建记忆系统
let memory = MemoryStore::builder()
.short_term_capacity(100)
.long_term_path("./data/memory")?
.build();
// 2. 构建工具引擎
let mut tools = ToolRegistry::new();
tools.register(Box::new(eneros_tool::builtin::TopologyTool::new()));
tools.register(Box::new(eneros_tool::builtin::PowerflowTool::new()));
tools.register(Box::new(eneros_tool::builtin::ConstraintTool::new()));
// 3. 构建推理引擎
let reasoning = ReasoningEngine::builder()
.strategy(eneros_reasoning::Strategy::ReAct)
.max_iterations(10)
.build();
// 4. 构建 Agent
let mut agent = AgentBuilder::new()
.name("grid-assistant")
.memory(memory)
.tools(tools)
.reasoning(reasoning)
.build()
.await?;
// 5. 执行任务
let result = agent
.run("分析当前电网拓扑,找出电压越限节点")
.await?;
println!("分析结果: {}", result.answer);
// 6. 多 Agent 协作
let orchestrator = Orchestrator::new();
orchestrator.register_agent(agent);
orchestrator.register_agent(DispatchAgent::new().await?);
orchestrator.register_agent(OperationAgent::new().await?);
let plan = orchestrator
.coordinate("处理电网电压越限问题")
.await?;
Ok(())
}
L3 - 电力原生内核(Power-Native Kernel)
电力原生内核是 EnerOS 的核心,将电力系统的领域知识、物理约束与运行逻辑内建为内核一等公民。
职责
- 电网拓扑建模与分析
- 潮流计算与状态估计
- 安全约束校验与投影
- 设备模型库
- 时序数据存储
- 高级分析(OPF、短路、DSA)
- 事件总线与发布订阅
内核组件
| 组件 | 职责 | 关键 Crate | 算法/实现 |
|---|---|---|---|
| 拓扑引擎 | 电网图建模与搜索 | eneros-topology | 邻接表 + BFS/DFS |
| 潮流求解 | Newton-Raphson 潮流 | eneros-powerflow | NR + 稀疏 LU |
| 约束引擎 | 安全约束校验与投影 | eneros-constraint | 规则引擎 + 投影 |
| 设备模型 | 设备参数库 | eneros-equipment | 参数化模型 |
| 中国配网 | 中国配网设备与标准 | eneros-cnpower | 国标设备库 |
| 时序存储 | 时序数据持久化 | eneros-timeseries | Gorilla 编码 + LSM |
| 事件总线 | 发布订阅 | eneros-eventbus | 多播 + 持久化 |
| 状态估计 | SCADA 状态估计 | eneros-analysis (analysis) | WLS + bad data |
| OPF | 最优潮流 | eneros-analysis (opf) | 内点法 |
| 短路计算 | 故障分析 | eneros-analysis | 对称/不对称 |
| DSA | 动态安全分析 | eneros-analysis (dsa) | 时域仿真 |
| 谐波分析 | 谐波潮流 | eneros-analysis (harmonic) | FFT |
| EMTP | 电磁暂态仿真 | eneros-emtp | 数值积分 |
| 模拟器 | 场景仿真 | eneros-simulator | 离散事件 |
| 线性代数 | 稀疏矩阵运算 | eneros-linalg | sprs 封装 |
内核代码示例
use eneros_topology::{TopologyEngine, Bus, Branch, Switch};
use eneros_powerflow::PowerflowSolver;
use eneros_constraint::{ConstraintEngine, Constraint, ConstraintKind};
use eneros_timeseries::{TimeseriesEngine, Point};
fn main() -> anyhow::Result<()> {
// 1. 构建电网拓扑
let mut topo = TopologyEngine::new();
topo.add_bus(Bus::new(1, "Bus-1", 138.0));
topo.add_bus(Bus::new(2, "Bus-2", 138.0));
topo.add_bus(Bus::new(3, "Bus-3", 138.0));
topo.add_branch(Branch::new(1, 1, 2, 0.01, 0.05));
topo.add_branch(Branch::new(2, 2, 3, 0.02, 0.08));
topo.add_switch(Switch::new(1, 3, 1, true));
// 2. 拓扑分析
let islands = topo.find_islands()?;
println!("电气岛数量: {}", islands.len());
let paths = topo.shortest_path(1, 3)?;
println!("Bus-1 到 Bus-3 路径: {:?}", paths);
// 3. 潮流计算
let mut solver = PowerflowSolver::new(topo.graph());
let result = solver.solve_newton_raphson()?;
println!("收敛: {} 次迭代", result.iterations);
for bus in &result.buses {
println!("Bus {}: V={:.4}pu, θ={:.2}°", bus.id, bus.voltage, bus.angle);
}
// 4. 约束校验
let mut constraints = ConstraintEngine::new();
constraints.add_constraint(Constraint::new(
ConstraintKind::VoltageLimit,
"V_min".to_string(),
0.95,
1.05,
));
constraints.add_constraint(Constraint::new(
ConstraintKind::ThermalLimit,
"Line-1".to_string(),
0.0,
100.0,
));
let violations = constraints.check(&result)?;
for v in &violations {
println!("违反约束: {} = {:.4}", v.constraint_id, v.value);
}
// 5. 时序数据写入
let mut ts = TimeseriesEngine::open("./data/ts")?;
ts.write_point(Point::new(
"bus-1-voltage",
chrono::Utc::now(),
result.buses[0].voltage,
))?;
Ok(())
}
L2 - 实时安全网关(Real-Time Safety Gateway)
实时安全网关是双执行域之间的桥梁,确保所有跨域命令经过安全校验,并提供零信任、入侵检测、审计与合规能力。
职责
- 命令拦截与安全校验
- 零信任 mTLS 通信
- 入侵检测(行为基线 + IOC)
- 审计日志(HMAC 签名 + WORM 存储)
- 合规检查(NERC CIP / IEC 62443 / GDPR / PIPL)
- 优先级排序与可行性投影
网关组件
| 组件 | 职责 | 关键 Crate | 实现要点 |
|---|---|---|---|
| 安全网关 | 命令拦截与校验 | eneros-gateway | per-device lock + lock-free |
| 零信任 | mTLS + 内部 CA | eneros-trust | rustls + 自签 CA |
| 入侵检测 | 行为基线 + IOC | eneros-ids | 异常检测 + 威胁情报 |
| 审计 | HMAC 签名 + WORM | eneros-audit | 链式哈希 + 只追加存储 |
| 合规 | 多标准合规检查 | eneros-compliance | NERC CIP / IEC 62443 |
| 看门狗 | 实时域心跳监控 | eneros-gateway (watchdog) | 超时触发 fail-safe |
| 命令分解 | 复杂命令拆解 | eneros-gateway (decomposer) | 原子操作单元 |
安全网关代码示例
use eneros_gateway::SafetyGateway;
use eneros_trust::{MtlsConfig, CertManager};
use eneros_audit::AuditLogger;
use eneros_ids::IntrusionDetector;
#[tokio::main]
async fn main() -> anyhow::Result<()> {
// 1. 初始化零信任 mTLS
let cert_manager = CertManager::builder()
.ca_cert_path("./certs/ca.pem")
.server_cert_path("./certs/server.pem")
.server_key_path("./certs/server.key")
.build()?;
let mtls = MtlsConfig::from_cert_manager(&cert_manager)?;
// 2. 初始化审计日志(HMAC + WORM)
let audit = AuditLogger::builder()
.storage_path("./audit")
.hmac_key(b"audit-secret-key-32-bytes-long!")
.worm_enabled(true)
.build()?;
// 3. 初始化入侵检测
let ids = IntrusionDetector::builder()
.baseline_window(chrono::Duration::hours(24))
.alert_threshold(0.8)
.build()?;
// 4. 构建安全网关
let gateway = SafetyGateway::new(10000)
.with_lockfree_state();
// 5. 注册安全检查
gateway.register_safety_check(Box::new(audit.clone()));
gateway.register_safety_check(Box::new(ids.clone()));
// 6. 执行命令(自动审计 + 入侵检测)
let cmd = eneros_core::Command::new_switch_toggle(42, false, "operator-1");
gateway.execute_command(cmd).await?;
// 7. 查询审计历史
let history = gateway.command_history();
println!("审计记录数: {}", history.len());
Ok(())
}
L1 - 基础设施(Infrastructure)
基础设施层提供操作系统服务、网络、存储、多区域、多租户、协议适配与设备管理能力。
职责
- OS 服务(init / rt / agentos / hal)
- 网络配置与防火墙
- 多区域复制与灾备
- 多租户隔离与配额
- SCADA 数据采集
- 设备协议适配(IEC 104 / Modbus / DNP3 / PMU / MQTT)
- 性能优化(arena / pool / ring buffer)
基础设施组件
| 组件 | 职责 | 关键 Crate | 实现要点 |
|---|---|---|---|
| OS 服务 | init/rt/agentos/hal | eneros-os | Linux 用户态 |
| 实时运行时 | SCHED_FIFO + CPU 隔离 | eneros-os (rt) | libc + sched_setaffinity |
| 共享内存 | 跨进程 IPC | eneros-os (rt/shm) | mmap + eventfd |
| 网络配置 | 网络与防火墙 | eneros-os (netcfg) | nftables / iptables |
| 高可用 | 集群与故障转移 | eneros-os (ha) | 心跳 + fencing |
| 系统日志 | syslog 与轮转 | eneros-os (syslog) | rsyslog 集成 |
| 时间同步 | NTP / PTP | eneros-os (timesync) | chrony / ptp4l |
| OTA 升级 | 签名升级 | eneros-os (update) | ed25519 + tar |
| 多区域 | WAL 复制 + DR | eneros-multiregion | CRDT + LWW |
| 多租户 | 租户隔离与配额 | eneros-tenant | RBAC + 配额 |
| SCADA | 数据采集 | eneros-scada | IEC 104 + CDT |
| 设备管理 | 设备适配与发现 | eneros-device | trait + adapter |
| 协议适配 | 电力协议实现 | eneros-protocol-* | 多协议支持 |
| 性能优化 | 内存池与零拷贝 | eneros-perf | arena + ring buffer |
| 核心类型 | 统一类型与错误 | eneros-core | 类型 + 错误 + 配置 |
| 线性代数 | 稀疏矩阵 | eneros-linalg | sprs 封装 |
| 网络 | CIM 与仿真 | eneros-network | CIM 模型 |
| 插件 | 进程隔离插件 | eneros-plugin | seccomp + 签名 |
| SDK | 多语言绑定 | eneros-sdk | C / Python / Go |
| IoT | 设备接入 | eneros-iot-hub | MQTT + CoAP + LwM2M |
| 边缘 | 边缘计算 | eneros-edge | gRPC + 模型分发 |
协议适配
| 协议 | Crate | 用途 | 标准化组织 |
|---|---|---|---|
| IEC 60870-5-104 | eneros-scada | 远动通信 | IEC |
| IEC 61850 | eneros-protocol-iccp | 变电站自动化 | IEC |
| IEC 60870-5-103 | eneros-protocol-iec103 | 继电保护 | IEC |
| CDT | eneros-protocol-cdt | 循环式传输 | 国家标准 |
| PMU / IEEE C37.118 | eneros-protocol-pmu | 同步相量 | IEEE |
| ICCP / IEC 60870-6 | eneros-protocol-iccp | 控制中心间通信 | IEC |
| Modbus | eneros-device | 工业通信 | Modbus org |
| DLT 698 | eneros-protocol-dlt698 | 中国电能表 | 国家标准 |
| MQTT | eneros-protocol-mqtt | IoT 消息 | OASIS |
| CoAP | eneros-protocol-coap | 受限设备 | IETF |
| LwM2M | eneros-protocol-lwm2m | 设备管理 | OMA |
基础设施代码示例
use eneros_os::rt::{RtConfig, RtRuntime};
use eneros_multiregion::{MultiRegionManager, RegionConfig};
use eneros_tenant::{TenantManager, TenantConfig};
use eneros_scada::{ScadaCollector, ProtocolType};
use eneros_device::{DeviceManager, ProtocolConfig};
#[tokio::main]
async fn main() -> anyhow::Result<()> {
// 1. 配置实时运行时
let rt_config = RtConfig {
cpus: vec![2, 3],
priority: 80,
lock_memory: true,
use_huge_pages: true,
};
let rt = RtRuntime::new(rt_config);
rt.configure_current_thread()?;
// 2. 多区域复制
let region = MultiRegionManager::new(RegionConfig {
local_region: "east-1".to_string(),
peer_regions: vec!["west-1".to_string(), "north-1".to_string()],
replication_mode: eneros_multiregion::ReplicationMode::AsyncWal,
});
// 3. 多租户隔离
let tenants = TenantManager::new(TenantConfig {
default_quota: eneros_tenant::Quota {
max_agents: 100,
max_storage_gb: 100,
max_requests_per_sec: 1000,
},
});
tenants.create_tenant("tenant-001", "电力公司 A").await?;
// 4. SCADA 数据采集
let mut scada = ScadaCollector::new();
scada.add_channel("rtu-1", ProtocolType::Iec104, "192.168.1.10:2404")?;
scada.add_channel("rtu-2", ProtocolType::Cdt, "192.168.1.11:2404")?;
scada.start().await?;
// 5. 设备管理
let devices = DeviceManager::new();
devices
.register_device(
"rtu-1",
Box::new(eneros_device::adapter::ModbusAdapter::new()),
eneros_device::adapter::ConnectionConfig {
host: "192.168.1.10".into(),
port: 502,
timeout_ms: 3000,
credentials: None,
protocol_config: ProtocolConfig::Modbus {
slave_id: 1,
baud_rate: None,
},
},
eneros_device::adapter::DeviceInfo {
device_id: "rtu-1".into(),
name: "RTU-1".into(),
protocol: eneros_device::protocol::ProtocolType::Modbus,
manufacturer: "Siemens".into(),
model: "S7-1500".into(),
firmware_version: "1.0.0".into(),
ip_address: "192.168.1.10".into(),
port: 502,
capabilities: vec!["read".into(), "write".into()],
},
)
.await;
Ok(())
}
层间接口规范
L5 → L4:Agent SDK
应用层通过 Agent SDK 调用运行时能力,接口形式为 Rust trait + async 方法:
// L4 暴露给 L5 的接口
pub trait AgentRuntime: Send + Sync {
async fn create_agent(&self, config: AgentConfig) -> Result<AgentHandle>;
async fn invoke_agent(&self, handle: &AgentHandle, input: AgentInput) -> Result<AgentOutput>;
async fn destroy_agent(&self, handle: AgentHandle) -> Result<()>;
}
L4 → L3:内核系统调用
Agent 运行时通过内核系统调用访问电力原生能力:
// L3 暴露给 L4 的接口
pub trait PowerNativeKernel: Send + Sync {
fn topology(&self) -> &dyn TopologyApi;
fn powerflow(&self) -> &dyn PowerflowApi;
fn constraint(&self) -> &dyn ConstraintApi;
fn timeseries(&self) -> &dyn TimeseriesApi;
fn eventbus(&self) -> &dyn EventBusApi;
}
pub trait TopologyApi: Send + Sync {
fn find_islands(&self) -> Result<Vec<Vec<BusId>>>;
fn shortest_path(&self, from: BusId, to: BusId) -> Result<Vec<BusId>>;
}
L3 → L2:命令下发
内核通过命令对象将控制指令下发到安全网关:
// L2 暴露给 L3 的接口
pub trait SafetyGatewayApi: Send + Sync {
async fn execute_command(&self, cmd: Command) -> Result<ExecutionResult>;
async fn validate_command(&self, cmd: &Command) -> Result<()>;
fn command_history(&self) -> Vec<Command>;
}
L2 → L1:设备操作
安全网关通过设备管理器访问物理设备:
// L1 暴露给 L2 的接口
pub trait DeviceManagerApi: Send + Sync {
async fn read(&self, device_id: &str, address: &str) -> Result<DataValue>;
async fn write(&self, device_id: &str, address: &str, value: DataValue) -> Result<()>;
async fn connect(&self, device_id: &str) -> Result<()>;
async fn disconnect(&self, device_id: &str) -> Result<()>;
}
各层组件完整对照表
| 层次 | 组件 | Crate | 主要 Trait | 执行域 |
|---|---|---|---|---|
| L5 | 智能调度 | eneros-agent/dispatch-agent | DispatchAgent | 通用 |
| L5 | 智能运维 | eneros-agent/operation-agent | OperationAgent | 通用 |
| L5 | 电力交易 | eneros-agent/trading-agent | TradingAgent | 通用 |
| L5 | 配网规划 | eneros-agent/planning-agent | PlanningAgent | 通用 |
| L5 | 故障自愈 | eneros-agent/self-healing-agent | SelfHealingAgent | 实时 |
| L5 | 负荷预测 | eneros-agent/forecast-agent | ForecastAgent | 通用 |
| L5 | 数字孪生 | eneros-twin | TwinModel | 通用 |
| L5 | 报表中心 | eneros-report | ReportGenerator | 通用 |
| L5 | 可视化 | eneros-dashboard / eneros-3d | Dashboard | 通用 |
| L5 | 自然语言 | eneros-nl | IntentRecognizer | 通用 |
| L5 | 电力市场 | eneros-market | MarketServer | 通用 |
| L5 | 边缘智能 | eneros-edge | EdgeRuntime | 通用 |
| L4 | Agent 生命周期 | eneros-agent | Agent / AgentLifecycle | 通用 |
| L4 | 编排器 | eneros-agent (orchestrator) | Orchestrator | 通用 |
| L4 | 记忆系统 | eneros-memory | MemoryStore | 通用 |
| L4 | 工具引擎 | eneros-tool | Tool / ToolRegistry | 通用 |
| L4 | 推理引擎 | eneros-reasoning | ReasoningEngine | 通用 |
| L4 | AI/ML | eneros-ai | Predictor / Embedder | 通用 |
| L4 | AIOps | eneros-aiops | IncidentCorrelator | 通用 |
| L3 | 拓扑引擎 | eneros-topology | TopologyEngine | 通用 |
| L3 | 潮流求解 | eneros-powerflow | PowerflowSolver | 通用 |
| L3 | 约束引擎 | eneros-constraint | ConstraintEngine | 通用 |
| L3 | 设备模型 | eneros-equipment | EquipmentLibrary | 通用 |
| L3 | 中国配网 | eneros-cnpower | CnPowerLibrary | 通用 |
| L3 | 时序存储 | eneros-timeseries | TimeseriesEngine | 通用 |
| L3 | 事件总线 | eneros-eventbus | EventBus / Publisher | 通用 |
| L3 | 高级分析 | eneros-analysis | StateEstimator / OpfSolver | 通用 |
| L3 | 电磁暂态 | eneros-emtp | EmtpSimulator | 通用 |
| L3 | 模拟器 | eneros-simulator | GridSimulator | 通用 |
| L3 | 线性代数 | eneros-linalg | SparseMatrix | 通用 |
| L3 | 网络/CIM | eneros-network | NetworkModel | 通用 |
| L2 | 安全网关 | eneros-gateway | SafetyGateway | 跨域 |
| L2 | 零信任 | eneros-trust | MtlsConfig / CertManager | 通用 |
| L2 | 入侵检测 | eneros-ids | IntrusionDetector | 通用 |
| L2 | 审计 | eneros-audit | AuditLogger | 通用 |
| L2 | 合规 | eneros-compliance | ComplianceChecker | 通用 |
| L1 | OS 服务 | eneros-os | OsService | 通用 |
| L1 | 实时运行时 | eneros-os (rt) | RtRuntime | 实时 |
| L1 | 共享内存 | eneros-os (rt/shm) | SharedMemoryChannel | 跨域 |
| L1 | 高可用 | eneros-os (ha) | HaCluster | 通用 |
| L1 | 多区域 | eneros-multiregion | MultiRegionManager | 通用 |
| L1 | 多租户 | eneros-tenant | TenantManager | 通用 |
| L1 | SCADA | eneros-scada | ScadaCollector | 实时 |
| L1 | 设备管理 | eneros-device | DeviceManager | 通用 |
| L1 | 性能优化 | eneros-perf | Arena / RingBuffer | 跨域 |
| L1 | 核心类型 | eneros-core | Command / Event | 通用 |
| L1 | 协议适配 | eneros-protocol-* | ProtocolAdapter | 实时 |
| L1 | IoT 接入 | eneros-iot-hub | IoTHub | 通用 |
| L1 | 插件系统 | eneros-plugin | PluginRegistry | 通用 |
| L1 | SDK | eneros-sdk | EnerosSdk | 通用 |
相关文档
- 双执行架构 - 双执行域详解
- Crate 依赖关系 - Crate 依赖图
- 项目结构 - 目录结构说明