Dyna – Logic Programming for Machine Learning
8 days ago
- #machine-learning
- #programming-language
- #declarative-programming
- Dyna is a programming language designed for machine learning researchers, building on logic programming languages like Datalog and Prolog.
- Dyna allows flexible execution orders and weighted rules, enabling complex programs to be written concisely.
- Example Dyna programs include matrix multiplication, the Fibonacci sequence, CKY parsing, and neural networks.
- The Dyna project started in 2004 to bridge the gap between mathematical notation and executable code for ML researchers.
- Dyna 1.0 extended Datalog by allowing any semiring, making it useful for dynamic programming.
- Dyna 2.0 introduced functions, free variables, lazy expressions, and prototype-based inheritance (dynabases).
- Ongoing research includes using relational algebra and term rewriting for implementation and reinforcement learning for optimization.
- Several research papers and theses have been published on Dyna, covering its development and applications.
- Multiple implementations of Dyna exist, including Dyna3 (Clojure), Dyna-R (Python), Dyna-Pi (Python), Dyna-Phi (Truffle/Graal), and earlier versions in Haskell and Python.