原文:https://www.postgresql.org/about/news/pg_mentat-130-released-datomic-compatible-datalog-inside-postgresql-3306/ 发布日期:2026-05-22 作者:Greg Burd
pg_mentat 是一个 PostgreSQL 扩展,在 PostgreSQL 内部实现了 Datomic 的数据模型:不可变事实(datoms)、以 schema 为先的属性体系、完整的 Datalog 查询编译器、pull API、时间旅行(time travel)以及 ACID 事务。
该项目使用 Rust + pgrx 0.17 构建,支持 PostgreSQL 13 到 18。
当前版本为 1.3.0(作者称为“Postgres Extension Family”版本),新增了一批能够与其他扩展联动的 Datalog where-fns:可桥接 rum、pg_trgm、fuzzystrmatch、pgvector、pg_infer、PostGIS 等作为“软依赖”。pg_mentat 本身不强制依赖这些扩展,但当它们存在时,相关 where-fns 会自动启用。
项目地址:https://github.com/gburd/pg_mentat
此文章已从旧版 PostgreSQL 网站迁移。对于迁移导致的任何格式问题,我们深表歉意。