四层心智模型

wesgine v1.0 的核心心智模型:四层架构从容器到请求主体。


四层概览

Layer 1  Container(Hypervisor)  — 管 Cell 生命周期 + 共享资源池
Layer 2  Kernel(Loop 五件套)    — Cognitive / Context / Execution / Memory / Govern
Layer 3  Cell(三位一体)         — Runtime Instance + Tenant Unit + Portable Snapshot
Layer 4  Actor(请求主体)        — 谁在说话、谁的记忆、谁的配额

Layer 1:Container(Hypervisor)

Hypervisor 是控制面,薄,全局唯一。

只做三件事:

  1. Cell 生命周期管理
  2. 共享 Provider 池
  3. 跨 Cell 只读观测

绝不做:Chat() / Run() / Memory() / Sessions()。


Layer 2:Kernel(Loop 五件套)

Agent 引擎的基本面,是 Cell 的内核:

子系统职责
Cognitive认知解析(LLM 调用 + Provider 路由)
Context上下文组装(系统提示 + 历史 + Overlay)
Execution工具执行(Registry + Executor)
Memory持久记忆(七层模型 + 读写隔离)
Govern治理(Hardline + Sandbox + Zone)

Layer 3:Cell(三位一体)

Cell 是 Layer 2 Kernel 的具体化实例:

角色含义
Runtime Instance一组正在运行的 Kernel 子系统实例
Tenant Unit隔离域,AX-1 的物理体现
Portable Snapshot可导出/导入的完整快照

心智模型不是"一个引擎里装了很多 Cell",而是"Hypervisor 里跑了很多个独立的 wesgine 实例"。


Layer 4:Actor(请求主体)

Actor 是运行时一等标识符。

引擎基于 Actor 在 Cell 内做:

wesgine 不定义用户身份体系(AX-2),但 Actor 是运行时必填字段。


各产品映射

产品Layer 1Layer 3Layer 4
wescode管理多 workspace CellN Cell(ws-{hash})1 Actor("local")
wesclaw 桌面透明1 Cell("main")1 Actor
wesclaw SaaS存在N CellM Actor/Cell
wescraft 个人透明1 Cell("personal")1 Actor
wescraft 团队存在N CellM Actor/Cell
teleclaw存在N Cell(1/部门)M Actor/Cell

核心价值层次

Agent 引擎 Kernel(基本面)
    ↓
Cell = Kernel 的具体化实例
    ↓
Hypervisor = 编排容器(n=1 透明、n≥2 启用调度)
    ↓
多/单租户 = 部署形态(不是产品定位)