Skip to content

Commit 8617f2a

Browse files
updata-env
1 parent ac0579c commit 8617f2a

156 files changed

Lines changed: 154 additions & 27108 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README-CN.md

Lines changed: 153 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,153 @@
1+
# OntoLoop 主权操作系统(工程运行时)
2+
OntoLoop 是面向**治理 + 执行 + 学习 + 回放**的 AI 主权运行时。
3+
当前版本已进入工程可用量产阶段,具备治理、执行、可信校验与持续学习全闭环能力。
4+
5+
## 核心能力模块
6+
- 治理流水线:策略 / 租户 / 审批 / 风险 / 预算 / 灰度发布
7+
- 执行流水线:能力准入 → 可信准入内核 → 运行时防护 → 分层工具栈 → 执行架构
8+
- 可信流水线:证据标记器 → 流转状态引擎 → 可信证据账本(哈希链结构)
9+
- 学习流水线:学习提案 → 晋升准入闸 → 私有记忆 / 组织知识库
10+
- 可观测性流水线:遥测采集器 → 策略信号聚合器 → 查询/回放/解释平面
11+
- 可信内核(本体核心)集成:身份认证、可信背书、供应链校验、强隔离、可回放审计
12+
13+
## 架构流水线(精简版)
14+
```text
15+
[用户/触发源]
16+
-> 结构化传输 + 会话桥接层
17+
-> 会话轮次状态机 + 上下文编译/压缩器
18+
-> 需求澄清模块
19+
-> 策略与治理上下文
20+
-> 知识上下文 + 超级记忆模块
21+
-> 查询引擎 + 编排调度器 + 能力路由器
22+
-> 能力准入校验
23+
-> 可信准入内核
24+
-> 运行时防护 + 权限模式管控
25+
-> 分层工具执行 + 执行架构 + 运行时钩子
26+
-> 证据标记采集
27+
-> 流转状态引擎
28+
-> 可信证据账本落盘
29+
-> 校验器与审计模块
30+
-> 模型学习与能力晋升
31+
-> 私有记忆 / 组织知识库更新
32+
-> 统一查询 / 流程回放 / 行为解释
33+
-> 可观测性监控 + 报表输出
34+
-> 进入下一轮迭代闭环
35+
```
36+
37+
## 快速开始
38+
### 1)环境依赖
39+
- Rust 工具链
40+
- 可选:状态存储命令行工具
41+
- 可选:Docker / Docker Compose
42+
43+
### 2)本地运行
44+
```powershell
45+
cargo run --manifest-path .\Cargo.toml -- --message "构建可治理的自主运行闭环" --swarm
46+
```
47+
48+
### 3)本地校验
49+
```powershell
50+
cargo check --workspace --manifest-path .\Cargo.toml
51+
cargo test --workspace --manifest-path .\Cargo.toml
52+
```
53+
54+
## 常用 CLI 命令
55+
```powershell
56+
# 系统健康自检
57+
cargo run --manifest-path .\Cargo.toml -- system health
58+
59+
# 指定会话生成流程回放报告
60+
cargo run --manifest-path .\Cargo.toml -- --session demo system replay-report
61+
62+
# 查看所有触发器列表
63+
cargo run --manifest-path .\Cargo.toml -- trigger list
64+
65+
# 指定会话查看管控看板
66+
cargo run --manifest-path .\Cargo.toml -- --session demo focus board
67+
68+
# 查看组织级上下文配置
69+
cargo run --manifest-path .\Cargo.toml -- --session demo org context
70+
71+
# 查看桥接服务状态
72+
cargo run --manifest-path .\Cargo.toml -- bridge status
73+
74+
# 批量导出知识图谱
75+
cargo run --manifest-path .\Cargo.toml -- knowledge batch-export --anchor-list .\deploy\anchors.txt --type graph
76+
77+
# 触发 Webhook 事件并立即执行
78+
cargo run --manifest-path .\Cargo.toml -- trigger webhook --anchor-id cli:focus --topic order.created --payload "{\"order_id\": \"A-1001\"}" --run-now
79+
80+
# 导出指定会话系统配置
81+
cargo run --manifest-path .\Cargo.toml -- --session cli:focus system export
82+
83+
# 查看前端服务状态
84+
cargo run --manifest-path .\Cargo.toml -- --session cli:focus frontend status
85+
86+
# 查看前端事件日志(格式化输出、限制条数)
87+
cargo run --manifest-path .\Cargo.toml -- --session cli:focus frontend events --format pretty --limit 20
88+
```
89+
90+
CLI 前端采用增量式扩展设计,现有 `dashboard-ui/` 等前端目录完整保留,可用于后续应用界面拓展开发。
91+
92+
## 验收测试脚本
93+
Windows 环境:
94+
```powershell
95+
powershell -ExecutionPolicy Bypass -File .\deploy\scripts\p95_acceptance.ps1
96+
powershell -ExecutionPolicy Bypass -File .\deploy\scripts\pq9_acceptance.ps1
97+
powershell -ExecutionPolicy Bypass -File .\deploy\scripts\week6_acceptance.ps1
98+
powershell -ExecutionPolicy Bypass -File .\deploy\scripts\trigger_supermemory_acceptance.ps1
99+
```
100+
101+
Linux 环境:
102+
```bash
103+
bash ./deploy/scripts/week6_acceptance.sh
104+
```
105+
106+
输出产物:
107+
- `deploy/runtime/p95-acceptance.log`
108+
- `deploy/runtime/p95-acceptance.json`
109+
110+
## 项目目录结构
111+
- `src/`:核心运行时与治理逻辑
112+
- `src/query_engine/`:会话轮次 / 任务续接 / 上下文压缩 / 闭环调度器
113+
- `src/runtime/`:运行时防护 / 准入控制 / 任务执行 / 证据采集 / 流转引擎
114+
- `src/security/`:策略管控 / 权限模式 / 能力准入体系
115+
- `src/session/`:检查点 / 任务恢复 / 运行时会话管理
116+
- `src/memory/`:私有记忆 + 超级记忆流水线
117+
- `src/observability/`:遥测采集器 / 查询平面 / 流程回放与链路解释
118+
- `src/transport/`:结构化传输 / 跨环境会话桥接
119+
- `src/plugins/`:插件生命周期管理
120+
- `src/skills/`:技能注册中心 / 能力构建流水线
121+
- `src/services/`:服务中介与编排核心骨架
122+
- `tests/`:端到端测试 & 回归测试套件
123+
- `deploy/scripts/`:自动化验收与运维脚本
124+
- `docs/`:协议规范文档 / 架构设计文档 / 验收标准文档
125+
126+
## 当前版本状态
127+
当前发布版已达到高成熟工程阶段:**核心流水线可完整运行、数据全链路可追溯、审计日志可解释**
128+
建议优先通过 `deploy/scripts/` 完成全量回归校验,再逐步落地生产级业务负载。
129+
130+
命令行规范文档路径:
131+
- docs/CLI_SPECIFICATION.md
132+
133+
## 白盒信号调试命令(D9/D10/D11 层级)
134+
内部信号流水线对外开放白盒 CLI 调试命令,用于问题排查与链路观测:
135+
```powershell
136+
# 查看系统信号链路状态
137+
cargo run --manifest-path .\Cargo.toml -- system signal status
138+
139+
# 根据追踪 ID 解析信号链路详情
140+
cargo run --manifest-path .\Cargo.toml -- system signal explain --trace-id <trace-id>
141+
142+
# 清空信号缓存队列
143+
cargo run --manifest-path .\Cargo.toml -- system signal drain
144+
```
145+
146+
### 开发治理规范
147+
- 所有业务侧信号写入,必须统一经过 `SignalFacade` 门面层。
148+
- 绕过门面层的直写操作,将被静态扫描测试拦截禁止。
149+
- 信号流水线验收已集成至 `week6_acceptance` 全量回归脚本。
150+
151+
## 规则引用策略
152+
`rule/` 目录下的第三方参考资料,仅用于架构对标与理论抽象提炼。
153+
该目录文件不参与项目编译依赖,也不会在运行时被加载执行。

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# OntoLoop Sovereign OS (Engineering Runtime)
1+
# OntoLoop Sovereign OS (Engineering Runtime)
22
OntoLoop is an AI sovereign runtime oriented to **Governance + Execution + Learning + Replay**.
33
The current version has entered a production-ready engineering phase, featuring closed-loop capabilities for governance, execution, trust verification and continuous learning.
44

cli-frontend/COPY_MANIFEST.json

Lines changed: 0 additions & 12 deletions
This file was deleted.

cli-frontend/opencode-subset/README.md

Lines changed: 0 additions & 15 deletions
This file was deleted.

cli-frontend/opencode-subset/bin/ontoloop.cmd

Lines changed: 0 additions & 2 deletions
This file was deleted.

cli-frontend/opencode-subset/package.json

Lines changed: 0 additions & 184 deletions
This file was deleted.

cli-frontend/opencode-subset/src/cli/cmd/cmd.ts

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)