add comment
trying to memoize lexemes-for-head
comment about using (commute) where possible (Rathore, Clojure in Action, p. 133), since unification is commutative.
implement using Clojure's agent a cache which is a map of specifications (key value pairs, with nesting allowed) to lazy sequences of lexemes that match that specification
remove lexemes-for-head (per-function call cache)