 
     ;; rewrite clauses
     (doseq [[rule-id clauses] @rule-id->clauses]
-      (doseq [[_ clause-type clause-id name] clauses]
+      (doseq [[_ clause-type clause-id name] clauses
+              :when (not #{"constant=" "variable=" "function="} name)]
         (let [fields (get @clause-id->fields clause-id)
               var->key (atom {})]
           (doseq [[_ field-type key val] fields]


(.get-or-create-index kn "know" "connected" #js ["x" "y"])


                                                       ix-a (get var->ix variable-a)
                                                       ix-b (get var->ix variable-b)]
                                                   [(btree/equal) #js [ix-a ix-b]])
                                     "=function" (let [variable (first (for [[_ field-type key val] fields
                                                                             :when (= key "variable")]
                                                                         val))
                                                       js (first (for [[_ field-type key val] fields
                                                                       :when (= key "js")]
                                                                   val))
                                                       ix (get var->ix variable)
                                                       args (for [var @vars
                                                                  :when (>= (.indexOf js var) 0)]
                                                              var)
                                                       arg-ixes (map var->ix args)
                                                       fun (apply js/Function (conj (vec args) (str "return (" js ");")))]
                                                   [(btree/function fun) (into-array (conj (vec arg-ixes) ix))])
                                     (let [clause-vars&keys (sort-by (fn [[val key]] (var->ix val))
                                                                     (for [[_ field-type key val] fields]
                                                                       [val key]))
