The core language, using Scheme as the host language, is described in this short, interactive tutorial.
A detailed discussion of the differences between miniKanren and Prolog can be found here.Daniel P. Friedman, William E. Byrd, Oleg Kiselyov, and Jason Hemann
The Reasoned Schemer, Second Edition The MIT Press, Cambridge, MA, 2018Will Byrd organizes a weekly miniKanren uncourse, which meets Sundays at noon Pacific/3pm Eastern time. We show off miniKanren projects, talk about miniKanren implementation, and do live coding/live research. A link to each week's hangout is posted to the miniKanren uncourse mailing list.miniKanren-with-symbolic-constraints miniKanren with extensions for symbolic constraint solving. Includes compatibility files for Racket and various Scheme implementations.
A minimal miniKanren implementation, as described in the 2013 Scheme Workshop paper.
A modified/improved microKanren implementation, as described in the 2016 DLS paper.
miniKanren extended with nominal logic programming, as described in the 2007 Scheme Workshop paper.
miniKanren implementation for R7RS sagittarius scheme 0.6.0 based on (microKanren) with the
miniKanren with guided search, as described in the 2013 Scheme Workshop paper.
miniKanren with constraint extensions that runs under Bigloo Scheme.
Stochastic Logic Programs (SLP) style probabilistic logic programming in miniKanren. (Deprecated--please see probKanren instead.)
Oleg Kiselyov's minimal implementation of logic programming. miniKanren-with-symbolic-constraints miniKanren with extensions for symbolic constraint solving. Includes compatibility files for Racket and various Scheme implementations.
miniKanren extended with Constraint Logic Programming (CLP); an improved version of the system described in the 2011 Scheme Workshop paper.
cKanren with fair conjunction core.logic
(core.logic cheatsheet, courtesy of Benjamin Peter)
A literate Clojure implementation of microKanren.Implementations of microKanren in assorted languages csharp_ukanrenFriebyrd cl-kanren-trs
Kanren-Fset (Fset collection library support for cl-kanren-trs)miniKanren-Dylan ExKanren elm-microKanren Reazon erlKanrenmini-over-micro-extempore logic A logic programming library for F#
An attempted implementation of MiniKanren in F#. gologic groovy-logic ukanrenHywaiimk.java microKanren in Java.
miniKanren in Java. veneer Browser based miniKanren editor and REPL, with constraints.mkr lua-ukanrenmímirKanren micro-in-miniml-mukanrenkanren.mox minikanren-nu OCanren Statically typed embedding of miniKanren into Objective Caml.reasoned-phpmicrokanren-prolog
A Prolog implementation of microKanren. pykanrenpure mini_kanrenrust-kanren scalognomicroKanren-shenmicrokanren-pharo
Smalltalk Hub link to microkanren-pharo Barliman Barliman is a prototype "smart editor" that performs real-time program synthesis to try to make the programmer's life a little easier.
minikanren mips assembler/disassembler. SMUG The Sheet Music Generator.
A small experiment in parsing packets in a style similar to Erlang's
The core.logic wiki also has links to projects using core.logic.William E. Byrd (joint work with Michael Ballantyne, Gregory Rosenblatt, and Matthew Might)
A Unified Approach to Solving Seven Programming Problems (Functional Pearl)
International Conference on Functional Programming (ICFP), Oxford, England, 4 September 2017.
paper | interactive paper | downloadable artifact | Barliman Tom Stuart
Hello, declarative world LRUG August 2015 Meetup, August 8, 2015. Dan Friedman and Jason Hemann
Write the Other Half of Your Program: From Functional to Logic Programming Strange Loop, St. Louis, September 18, 2014.
Relational Programming in miniKanren, Part 1 and Part 2
Lambda Lounge Utah, Sandy, UT, May 13, 2014.
A Relational Exploration of the Chomsky Hierarchy Strange Loop, St. Louis, September, 2013.
Fun with Relational Interpreters in miniKanren flatmap 2013, Oslo, Norway, May 14, 2013 (keynote).
miniKanren Philosophy Clojure/conj 2012, Raleigh, NC, November 16, 2012. (Beware the pink tint!)
Relational Programming in miniKanren Strange Loop 2012, St. Louis, MO, September 24, 2012
Clojure/conj 2011, Raleigh, NC, November 10, 2011. Nada Amin and William E. Byrd
From Greek to Clojure Clojure/conj, Alexandria, VA, November 14, 2013
Core.logic and SQL Killed my ORM Clojure/West 2013, Portland, OR, March 19th, 2013.
The Refined Clojurist Clojure Exchange 2012, London, December 6, 2012
Web Testing with Logic Programming Clojure/conj 2012, Raleigh, NC, November 17, 2012.
Challenges for Logic Programming Clojure/conj 2012, Raleigh, NC, November 17, 2012.
An Introduction to Logic Programming on the JVM with core.logic (Clojure) FP Days 2012, Cambridge, October 25, 2012
core.logic: A tutorial reconstruction ("unsession") Strange Loop 2012, St. Louis, MO, September 24, 2012
core.logic.intro EuroClojure 2012, London, May 24, 2012
Practical core.logic Clojure/West 2012, San Jose, March 17, 2012
Introduction to Logic Programming with Clojure
Clojure/conj 2011, Raleigh, NC, November 10, 2011. Adam Solove
Constraint programming in the browser (Talk focuses on the Cassowary constraint solver for GUI layout, but also discusses core.logic.)
JSConf US, Amelia Island, FL, May 31, 2013Gabriel Pickard
Logic programming in the wild (video not posted yet)
Intro to CLP with core.logic
Molog: Typed Functional Logic Programming in Haskell
The Architecture of core.logic
core.logic.nominal (video not posted yet)
The Unreasonable Schemers (video not posted yet)
source code William E. Byrd
William Byrd on Logic and Relational Programming, miniKanren
Recorded by InfoQ at Code Mesh 2013, London, England, December, 2013 Introduction to Logic Programming with Clojure
Relational Programming in miniKanren: Techniques, Applications, and Implementations. Indiana University, Bloomington, IN, September 30, 2009.
Easier to read, single-spaced, re-typeset version of Will's dissertation, released under Creative Commons Attribution 4.0 International (CC BY 4.0) license.Wheeler, Kaylen FJ
Representing Game Dialogue as Expressions in First-Order Logic
University of Western Ontario, London, Ontario, Canada, 2013. Ramana Kumar
Mechanising Aspects of miniKanren in HOL Australian National University, Canberra, Australian Capital Territory, Australia, May 2010. (Undergraduate Honors Thesis) Emily Fox
A Unified Approach to Solving Seven Programming Problems (Functional Pearl)
In Proceedings of the ACM on Programming Languages (PACMPL), 1, ICFP, Article 8 (August 2017), 26 pages. DOI.
Interactive version of the paper, created by Nada Amin. Jason Hemann, Daniel P. Friedman, William E. Byrd, and Matthew Might
microKanren: A Minimal Functional Core for Relational Programming. In Proceedings of the 2013 Workshop on Scheme and Functional Programming (Scheme '13), Alexandria, VA, 2013.
rKanren: Guided Search in miniKanren. In Proceedings of the 2013 Workshop on Scheme and Functional Programming (Scheme '13), Alexandria, VA, 2013.
cKanren: miniKanren with Constraints. In Proceedings of the 2011 Workshop on Scheme and Functional Programming (Scheme '11), Portland, OR, 2011.
alphaKanren: A Fresh Name in Nominal Logic Programming. In Proceedings of the 2007 Workshop on Scheme and Functional Programming, Universite Laval Technical Report DIUL-RT-0701, pp. 79-90.
Revised source code (R5RS Scheme) William E. Byrd and Daniel P. FriedmanComposing music using core.logic and Overtone - The Composing Schemer
source code January 2013. Clojure Core.Logic With Custom Data Sources October 25, 2013.
related blog post Dec 13, 2012. Getting started querying an Eclipse workspace using Ekeko
August 14, 2012. Hangout #13, Sunday, June 30.
Topic: Claire shows off a new macro for defining constraints using attributed variables, a new version of the matche pattern matching macro, and the implementation of templateo (declarative
copy_term) (URL). Norman demos his code for solving nonogrids problems. Will talks about CPSing miniKanren programs.
Hangout #12, Sunday, June 23, 2013.
Topic: Gary shows off his CLP(FD) program to layout 2D figures; Will describes the new, apparently fixed
templateo constraint, and explains how it is used in a relational term reducer for the untyped lambda-calculus.
Topic: Unexpected memory usage in
conde, and how to fix it in CLP(FD); meta-interpreters in miniKanren (code); what do you need to know to use miniKanren effectively?; Will's new book on miniKanren (in progress).
Topic: We discuss CLP(Set) and declarative
templateo) (code). Lindsey shows off LVish (code). David poses a core.logic puzzle. Dan and Jason discuss miniC, a minimal miniKanren without macros. Will shows off a relational lambda calculus reducer (code).
Topic: Will shows off a meta-circular interpreter for miniKanren (code), and describes the outline for a new book he is writing on relational programming (book).
Topic: Dan and Jason show off a cool way to implement mutual recursion in an interpreter. Will and the gang then live-code a relational interpreter for general Deterministic Finite Automata (code).
Topic: Stump the Chump! Will partially translates miniKanren's unify function from Scheme into miniKanren (code). Also, discussion of extra-logical operators, and new miniKanren features in progress: CLP(Set), constraint handling rules, lazy constraints for recursion.
Topic: Debugging miniKanren programs; Constraint Logic Programming over sets (based on the paper Sets and Constraint Logic Programming by Dovier, et al., 2000).
Implementation of simplified miniKanren (source code).
A little miniKanren history, what it means to be relational, a relational variant of copy-term, debugging miniKanren programs. Mostly lazy... a Clojure podcast
Episode 9 with Kevin Lynagh and Paul deGrandis: web dev ennui, CRDTs, and core.logic
Recorded December 14th, 2012. STLC Redux: Part II
Logic Programming is Underrated
The Simply Typed Lambda Calculus in 20 Lines Redux
A Logic Programming Reading List
core.logic & VPRI STEPS
Another Taste of cKanren
A Taste of cKanren
Simple Type Inference For The Simply Typed Lambda Calculus in ~20 Lines
Logos -> core.logic
Tabling in Logos
Finally ... a clue
Logic Programming and Performance
A Short Break
Life Without Tail Call Optimization
A miniKanren introduction via Clojure
Generating Sentences of Modal Logic
Generating Propositional Logic Proofs
Another Logic Programming Reading List
lx in core.logic #3: Finite State Transducers
lx in core.logic #2: Jumps, Flexible Transitions and Parsing
Finite State Machines in core.logic Generating Sight-Reading Exercises using Constraint Logic Programming in Clojure, Part 1 Bytecode Assembler in Core.Logic
Byte Packing with core.logic Parsing packets Erlang style using core.logic
The Composing Schemer
Finding cliques in graphs using core.logic
Maximum cliques algorithm in Clojure mini-Sudoku in mini-Kanren (in Clojure-"ish")
Logic Programming Part 3 (List Logic)
Logic Programming Part 2 (Building Blocks)
Logic Programming Part 1 Lojic Part Two
Lojic Part One Building Trees
Build An Arrow
Messin With Core.logic Fair conjunction: status report
The Reasoned Scheduler The Magical Island of Kanren - core.logic Intro Part 1
Appendo the Great Some core.logic graph code
Replicating Datomic/Datalog queries with core.logic, take 2
Replicating Datomic/Datalog queries with core.logic, take 1
N-Queens with core.logic, take 2
N-Queens with core.logic, take 1 miniKanren in Haskell
The First Time Programming Scared Me Solving Logic Puzzles With Clojure's Core Logic, Part Two
Solving Logic Puzzles With Clojure's Core Logic, Part One PPfAI Chapter 2 (in Clojure Core.Logic)
PPfAI Chapter 1 in Clojure Core.Logic Unification: It's Not Just for Prolog Generating tautologies with miniKanren A Nice Feature in core.logic and Thoughts About A Data Structure Day 31: Binary trees with core.logic! MiniKanren A field trip into logic programming Using Clojure's core.logic with custom data structures rKanren: Guided Search in miniKanren, Part 1 Using Clojure and core.logic from Groovy Temporal logic programming in Clojure core.logic Transitive relations in core.logic Getting my feet wet with Clojure's core.logic Search trees and core.logic Find Elements in a Collection Using core.logic Explorations in Clojure's core.logic Fun with Lambda calculus Interpreters in miniKanren This site is maintained by Will Byrd: firstname.lastname@example.org.