神经模块架构让AI学会三值逻辑,且推理过程更可靠。
THEIA: Learning Complete Kleene Three-Valued Logic in a Pure-Neural Modular Architecture
- 用纯神经模块架构学习三值逻辑,无需符号规则或人工门电路。
- 在5组实验中,99%以上规则准确率,且能保持不确定性传播特性。
- 适合研究神经逻辑推理、可解释性模型的学者和工程师。
我们提出THEIA,一种参数量为275万的模块化神经架构,可在不依赖外部符号推理或人工编码三值逻辑门的前提下,从任务数据中学习完整的克里尼三值逻辑(K3)真值表。在5个随机种子下,所有39条K3规则的单条准确率均超过99%。尽管基线Transformer和扁平MLP在相同样本上也能通过全部规则,且在第一阶段精度差距仅0.04个百分点,但本研究的核心贡献在于所学系统的两个特性:(1) 不确定性-断言的不对称传播:在上游边界始终保留“未知”状态(算术/顺序/集合/逻辑任务中分别为80.0%/91.1%/90.8%/99.7%,显著高于约52%的多数基准),而最终断言解码能力维持在73.4%以内;激活修补实验证明非吸收型T→U转换会翻转全部4,898对OR与4,719对AND,排除残差捷径可能。(2) 在离散化端到端训练下具备可靠性谱。在可沿引擎边界分解的任务中,模3序列组合任务可从5步泛化至500步,准确率达99.96±0.04%(5种子)。相同训练条件下,扁平MLP在50步时坍缩至随机水平;2×2 ResMLP网格仅在3/20(配置×种子)中达到≥99%;预归一化Transformer达99.24±0.34%。直通离散化避免了0.999^500的累积衰减;架构分隔器确保第三阶段训练中仍维持第一阶段性能,而扁平MLP则失败。辅助结果:在默认开发设置下(非优化器控制),THEIA比参数相当的8层Transformer快6.5倍完成全部12项克里尼覆盖;采用标准调优后缩小至约3.6倍,同配方下对比为4.93倍。比率受配置影响,非渐近量。
原文摘要 · Abstract (English)
We present THEIA, a 2.75M-parameter modular neural architecture that learns the complete Kleene three-valued logic (K3) truth table from task data without external symbolic inference or hand-encoded K3 gate primitives. Across 5 seeds it passes all 39 K3 rules at >99% per-rule accuracy. K3 learnability is not the central finding: Transformer baselines also pass all 39 rules, and flat MLPs match THEIA on Phase-1 accuracy within 0.04pp. The contributions are two properties of the learned system. (1) Uncertainty-verdict asymmetric propagation. THEIA preserves Has-Unknown at every upstream boundary (80.0/91.1/90.8/99.7% across Arith/Order/Set/Logic vs. ~52% majority) while final-verdict decodability stays at or below a 73.4% U-vs-non-U oracle reference under linear and nonlinear probes. Activation patching on non-absorbent T->U cases flips 4,898/4,898 OR and 4,719/4,719 AND pairs across 5 seeds, ruling out residual shortcuts. (2) Reliability spectrum under discretized end-to-end training, on tasks decomposable along the engine boundaries. A mod-3 sequential composition task generalizes from 5- to 500-step evaluation at 99.96+-0.04% (5 seeds). Under identical Gumbel-softmax training, flat MLPs collapse to chance by 50 steps; a 2x2 ResMLP grid reaches >=99% on only 3/20 (config, seed) trials; a pre-LN Transformer reaches 99.24+-0.34%. Straight-through discretization prevents 0.999^500 compounding; the architectural separator is sustaining Phase-1 accuracy under Phase-3 training, where flat MLPs fail. Auxiliary: under per-architecture development defaults (not optimizer-controlled), THEIA reaches 12/12 Kleene coverage 6.5x faster than a parameter-comparable 8L Transformer; this narrows to ~3.6x with Transformer-standard tuning and 4.93x with the same recipe on both. Ratios are config-specific, not asymptotic.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。