Get the latest tech news
Compositional Datalog on SQL: Relational Algebra of the Environment
I spent some time before making Datalogs that translated into SQL. https://www.philipzucker.com/tiny-sqlite-datalog/
It is a basic trick that I vaguely associated with finally tagless that you can remove the middle man of the AST when you have an expression datatype and instead just use combinators which are basically partially applied versions of the interpreter to the expressions interp myexp : database -> env -> set[env]. souffle /tmp/test.dl Takes ~0.2s in interpreted mode, ~0.1s in compiled mode.-j parallelization doesn’t seem to help much (too small?) Then i can directly interpet the relation algebra, do optimizations finally tagless style or interpret into SQL.
Or read this on Hacker News