RFC-0011:Phase 1 Exact Fillet Operation Module
| 项目 | 值 |
|---|---|
| 状态 | Accepted |
| 文档版本 | 0.5.0 |
| 创建/最后修改 | 2026-09-01 |
| Operation | exact.fillet@1.0.0 |
| Module | aira.op/exact.fillet@1.0.0 |
| Capability | cap:model.exact.fillet@1 |
| Catalog Snapshot | aira.catalog/exact.phase1@0.4.1 |
| 依赖 | RFC-0006、RFC-0008、RFC-0010、ADR-CORE-002 |
| Production activation | false |
1. 决策摘要
Section titled “1. 决策摘要”Aira 增加首个真正消费拓扑选择的工业 Exact feature:常半径圆角。它不是 raw OCCT API,也不接受
edge index、Three.js object index、firstEdge 或由 AI 自报的稳定 ID。AI 提交可解释的选择意图;Core
把它编译为 RFC-0010 的 canonical selector definition,并用绑定当前 Revision、ArtifactGraph 和
ExactSolid artifact 的 read receipt 解析出唯一边,之后才允许 OCCT 执行。
本 RFC 现已 Accepted:Operation Module、公共 node schema、不可变 catalog snapshot、 TypeScript/Rust 共享合同语料、真实 OCCT 单/多边 kernel proof、失败原子性、独立 Exact→Mesh/Manifold 检查、inherited/generated Face SemanticRef 的跨 Revision survival,以及九元 transaction、IndexedDB 恢复、Google Chrome/Three.js 产品 Gate 与 committed fresh detached checkout 均已成立。Accepted 只冻结合同与认证接受集;该 capability 仍不得进入 production Runtime Snapshot 或 Session Grant,production activation 必须另行裁决。
2. 为什么现在做 fillet
Section titled “2. 为什么现在做 fillet”Rectangle、extrude 和 revolve 证明了“从参数到 ExactSolid”可行;Exact Edge 证明了 AI 能以 Face SemanticRef 的拓扑交集稳定找到边。Fillet 把两者连成第一条工业 feature 链:
parameter/profile → ExactSolid → semantic edge selection → topology-changing ExactSolid
它直接检验 Aira Interface 的核心主张:AI 操作的是稳定、可发现、可诊断的建模语义,而不是内核对象、 数组位置或 GUI 状态。
3. 固定合同
Section titled “3. 固定合同”3.1 Node
Section titled “3.1 Node”exact.fillet@1.0.0 只有三个输入:
solid:同一 evaluation DAG 中的一个有效、闭合ExactSolidport;edges:Core 已编译的ExactEdgeSelectorSetliteral,至少一项、最多 32 项;radius:正的 canonicalLengthliteral 或 parameter reference。
输出固定为 solid: ExactSolid / body.main。v1 不提供 propagateTangent、variable radius、setback、
corner style 或 raw kernel option。新增这些语义必须发布新 operation/module 版本,不能偷偷扩宽 v1。
3.2 AI Intent 与 canonical node 分层
Section titled “3.2 AI Intent 与 canonical node 分层”AI-facing request 可以使用 incident-semantic-refs 或已由 producer module 发布的 authoring role。Core
负责 canonical 排序、definition hash、selector ID、authoring witness 与 read receipt。持久 canonical
node 保存编译后的 selector definition,以便重放;AI 不得自行填写 hash 后绕过编译和 receipt 验证。
3.3 v1 认证子集
Section titled “3.3 v1 认证子集”v1 只认证一个或多个互不重复的、孤立的、非相切传播的线性凸边,以及单一常半径。每项 selector 必须
在当前输入 Revision 中解析为 exactly one 且 publishable=true。OCCT 的 contour 必须与显式选边一一
对应,每个 contour 只能含一条边;任何隐式 tangent-chain 扩张均失败关闭。
圆弧边、样条边、相切边链、variable-radius、跨 body 选择与复杂多边交汇并非永久否决,但不属于 v1 认证接受集。
4. 执行与权威边界
Section titled “4. 执行与权威边界”执行器按以下顺序运行,任一步失败都不得发布部分 artifact:
- 验证 radius、Operation Module、schema 与 catalog hash;
- 验证 RFC-0010 read result/receipt,并确认它绑定输入 Revision、ArtifactGraph 与 artifact;
- 用 artifact-local stable sub-entity ID 反解真实
TopoDS_Edge,禁止 explorer index fallback; - 将显式边加入
BRepFilletAPI_MakeFillet,检查 contour 没有隐式扩张; - Build 后用
BRepCheck_Analyzer验证 ExactSolid; - 读取 OCCT
Modified/Generated/IsDeletedhistory,构建 source→fillet ArtifactGraph; - 所有输出 face 都有 lineage 后才生成 result hash;否则销毁临时 shape 并失败。
Three.js 仍只消费派生 DisplayMesh/RenderPacket,不参与选择身份、B-Rep 验证或 Revision hash。
5. Diagnostic 合同
Section titled “5. Diagnostic 合同”Module 锁定以下结构化错误:
FILLET_SELECTION_EMPTY/FILLET_SELECTION_DUPLICATE_EDGE;FILLET_SELECTION_UNRESOLVED/FILLET_SELECTION_BINDING_MISMATCH;FILLET_EDGE_GEOMETRY_UNSUPPORTED/FILLET_TANGENT_PROPAGATION_UNSUPPORTED;FILLET_RADIUS_OUT_OF_RANGE/FILLET_RADIUS_TOO_LARGE;FILLET_KERNEL_FAILED/FILLET_RESULT_INVALID/FILLET_HISTORY_INCOMPLETE。
实现内部可以提供更窄的调试错误,但公开错误不得退化为自然语言异常或静默修改选择集。
6. 已完成技术证据
Section titled “6. 已完成技术证据”- 新 OCCT runtime manifest 固定 46 个 binding,并锁定 opencascade.js source、OCCT source、Docker image
digest 与
network=false;runtime 二进制不进入 Git,只提交 sealed receipt; - WSL2/Docker 离线 custom link 得到 11,853,045-byte WASM;receipt 锁定其 SHA-256;
- 真实 10 × 8 mm rectangle、20 mm extrude,以
side.l0 ∩ side.l1选择一条竖边;2 mm fillet 产生有效 ExactSolid,face 数增加、B-Rep hash 改变、fillet face history 非空; - 同一模型 20 mm radius 由真实 OCCT 失败,零 publication;
- TypeScript/Rust 共同消费
exact-fillet-v1.corpus.json:2 个合法样例与 12 个非法样例使用相同稳定 Diagnostic code;AMIR 0.4.0 旧 catalog 继续可重放,0.4.1 才能接受 Fillet; - 两条相互隔离的 receipt-bound 竖边以 1 mm 半径原子执行,产生两个 contour、完整 history 且零 unmapped output face;
- 单边 Fillet ExactSolid 经 OCCT tessellation 后交给独立
manifold-3d 3.5.1,closed-oriented checker 返回NoError,全部 source face 都有 MeshSolid mapping; - 新增独立公开 schema
exact-fillet-semantic-ref/1.0,锁定 inherited source face binding 与fillet.surface.selectorset-valued definition;生成面身份由 feature ID 和 canonical Exact Edge selector digest 机械导出,不接受 OCCT/Three.js index、shape pointer、screen-space nearest 或firstGeneratedFace; - 真实 OCCT history 下,半径
1→2 mm、source extrude20→30 mm与双边半径0.75→1.25 mm分别实现7/7、7/7、8/8Face binding 跨 Revision resolved;六个 inherited face 与每个 selector 对应的 generated fillet surface 都保持同一语义定义; - 真实删除 selector、跨 Revision stale receipt、contract-level generated/inherited face split、maker contour
tangent 扩张、history count/lineage/hash/scope/witness 篡改全部失败关闭;失败路径 publication、Revision
与 user-head write 均为 0;Survival Gate 共
13/13; - TypeScript module/schema/dependency/catalog hash、canonical selector node 与 raw-index/number-radius/ tangent-option widening 负例均进入 Gate;
- provider 调用为 0,backend service 未启动。
- AMIR/Core
0.4.1的 source→create→radius edit→revert 形成四条真实 Revision;每次写入都走原生九元 Aira Interface 的 propose/preview/authoritative validate/task commit/read-back,Candidate 与 committed Revision 双证据和 selector/receipt/ArtifactGraph 原子持久化到 IndexedDB; - Google Chrome 首次加载以
workflowOrigin=created完成产品流程,同一 URL 的真实 reload 以workflowOrigin=restored从持久 Revision/evidence 重建事务审计;两次的最终 RevisionId、四条 history、 三笔 transaction summary、Exact/runtime/evidence hash 全部相同; - Three.js r185 只消费 RenderPacket,以稳定 EdgeId 高亮一条 receipt-bound 边并完成 read-back;真实 WebGLRenderer 记录 4 calls / 188 triangles / 157 lines,Chrome console warning/error 为 0;
- 不可能的 50 mm radius 返回
FILLET_KERNEL_FAILED且 head 不变;productionCapabilityEnabled=false、userHeadPublicationPerformed=false、provider 调用为 0。
这证明“receipt-bound semantic selection → real OCCT fillet → stable Face SemanticRef → durable native transaction → Three.js stable-ID display”产品路线已经闭合。相关实现由当前包测试和浏览器测试覆盖。
7. Candidate → Accepted Gate
Section titled “7. Candidate → Accepted Gate”RFC 只有同时满足以下条件才可改为 Accepted:
- TypeScript 与 Rust 对 module/schema/catalog/selector binding 完整 parity;已关闭;
- 覆盖单边、多边、重复边、missing/ambiguous/split/delete、跨 Revision stale receipt、非法 radius、 tangent-chain、kernel failure 与 history incomplete 的共享 corpus;已关闭:合同、内核与 survival corpus 共同覆盖,公开 Diagnostic 保持稳定;
- 成功结果通过独立 Exact→Mesh/Manifold closed-oriented 检查;已关闭;
- 未受影响 face SemanticRef 与新 fillet surface role 在 edit/read-back/reopen 后按合同解析;已关闭;
- 九元 Aira Interface 完成 propose/preview/validate/task commit/read-back/revert;已关闭;
- Revision、selector、receipt、ArtifactGraph 与 evidence 原子持久化到 IndexedDB;已关闭;
- Google Chrome 中由 Three.js 显示并可按稳定 ID 高亮,console error 为 0;已关闭:真实 reload 后 history 与全部权威 hash 不变,console warning/error 均为 0;
- fresh detached checkout 在 sealed runtime 注入下离线重放全部 Gate;已关闭:
d9afb8fdetached checkout 在--offline --frozen-lockfile下完成 Exact Edge dependency、Exact Fillet kernel/survival/browser、 完整 workspace check 与全局 evidence replay,tracked worktree 前后均为 clean; - production capability 仍由独立 activation 变更控制,不因 RFC Accepted 自动启用;已锁定:当前
所有产品收据仍为
productionCapabilityEnabled=false。
8. 当前裁决
Section titled “8. 当前裁决”接受本实现为 Exact Fillet Accepted Operation Module。合同、内核、SemanticRef、九元 transaction、
IndexedDB、Google Chrome/Three.js 与 committed fresh detached checkout Gate 均已关闭;历史 Kernel 与
Survival Candidate 收据保持原字节,并由追加式 Accepted closeout 绑定。production activation 仍是之后的
独立变更,当前继续为 false。不得绕过 selector receipt、history completeness、SemanticRef resolver 或
independent checker;对 variable radius、tangent propagation 或更广 edge geometry 的支持必须发布新版本。