Skip to main content
QUICK REVIEW

[论文解读] TensorLog: A Differentiable Deductive Database

William W. Cohen|arXiv (Cornell University)|May 20, 2016
Bayesian Modeling and Causal Inference参考文献 9被引用 75
一句话总结

TensorLog 引入了一种可微分的概率演绎数据库,将逻辑理论编译为因子图,并将信念传播 unroll 为可微分函数,从而实现高效、基于梯度的参数学习。它实现了线性时间的编译与推理,在递归任务上具有良好的可扩展性,并在学习准确率和推理速度方面达到或超过 ProbLog2 和 ProPPR 等成熟系统的表现。

ABSTRACT

Large knowledge bases (KBs) are useful in many tasks, but it is unclear how to integrate this sort of knowledge into "deep" gradient-based learning systems. To address this problem, we describe a probabilistic deductive database, called TensorLog, in which reasoning uses a differentiable process. In TensorLog, each clause in a logical theory is first converted into certain type of factor graph. Then, for each type of query to the factor graph, the message-passing steps required to perform belief propagation (BP) are "unrolled" into a function, which is differentiable. We show that these functions can be composed recursively to perform inference in non-trivial logical theories containing multiple interrelated clauses and predicates. Both compilation and inference in TensorLog are efficient: compilation is linear in theory size and proof depth, and inference is linear in database size and the number of message-passing steps used in BP. We also present experimental results with TensorLog and discuss its relationship to other first-order probabilistic logics.

研究动机与目标

  • 为解决将大型知识库集成到深度学习系统中的挑战,通过支持可微分推理实现。
  • 设计一种概率演绎数据库(PrDDB),使推理过程可微分,支持端到端的基于梯度的参数学习。
  • 实现与理论规模、数据库规模和消息传递步数成线性关系的高效编译与推理。
  • 证明可微分的逻辑推理能够有效逼近复杂的概率逻辑模型,如 ProbLog2 和 ProPPR。
  • 通过可微分、可组合的推理函数,实现与深度学习框架的紧密集成。

提出的方法

  • 将理论中的每个逻辑子句编译为因子图,其中逻辑变量映射为随机变量,文字映射为因子。
  • 将信念传播(BP)的消息传递步骤 unroll 为每类查询的可微分函数,以支持梯度计算。
  • 递归组合可微分推理函数,以处理具有多个谓词的复杂、相互关联的逻辑理论。
  • 通过梯度下降优化参数(如事实置信度),使用未正则化的交叉熵损失和类似 ReLU 的截断方法,以确保非负性。
  • 系统使用 softmax 将输出得分转换为概率分布,以支持概率推理。
  • 推理与编译的时间复杂度相对于理论规模、证明深度、数据库规模和 BP 步数均为线性。

实验结果

研究问题

  • RQ1能否使概率演绎数据库中的逻辑推理完全可微分,以支持基于梯度的学习?
  • RQ2可微分推理在递归和深度嵌套的逻辑查询上能否实现高效扩展?
  • RQ3像 TensorLog 这样的可微分逻辑系统能否在学习准确率和推理速度方面与 ProbLog2 和 ProPPR 等成熟系统相媲美或超越?
  • RQ4可微分逻辑推理在多大程度上能逼近完整一阶概率逻辑的语义?
  • RQ5可微分逻辑推理能否被有效集成到深度学习流水线中,以支持联合训练?

主要发现

  • TensorLog 实现了线性时间的编译与推理,其性能随理论规模、数据库规模和消息传递步数线性扩展。
  • 在 16×16 网格路径查找任务中,TensorLog 训练 20 个周期后,每个周期约 3 秒内达到 96.5% 的测试准确率。
  • 即使查询的实体数量是 ProbLog2 的六倍,TensorLog 的推理速度仍快数倍。
  • 在 64×64 网格上,TensorLog 展现出更优的可扩展性与更短的运行时间,尤其在深度递归查询中优势显著。
  • 在引文匹配与关系预测任务中,尽管采用更简单的学习方案和单线程实现,TensorLog 的准确率仍与 ProPPR 相当。
  • 在 6×6 网格的可视化中,学习到的权重呈现出有意义的模式,边的方向性和大小差异反映了对路径置信度的学习结果。

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。