   (assoc state :object
          (ask (str "Please enter new object: ")
               #(read-string (str (read-line)))
-              #(not (contains? (objects ctx) %))
+              #(not (contains? objects %))
               "This object is already present, please enter a new one: ")))
 
 (define-repl-fn attributes
   "Enter all attributes the object has."
   (let [new-attributes (ask (str "Please enter the attributes the new object should have: ")
                             #(read-string (str "#{" (read-line) "}"))
-                            #(subset? % (attributes ctx))
+                            #(subset? % attributes)
                             (str "The attributes have to be present in the given context.\n"
                                  "Please enter new attributes: "))]
     (-> state
         (assoc :positives new-attributes)
-        (assoc :negatives (difference (attributes ctx) new-attributes)))))
+        (assoc :negatives (difference attributes new-attributes)))))
 
 (define-repl-fn positives
   "Give some attributes the object definitively has."
   (let [positives (ask (str "Please enter attributes the new object definitively has: ")
                        #(read-string (str "#{" (read-line) "}"))
-                       #(and (subset? % (attributes ctx))
+                       #(and (subset? % attributes)
                              (not (exists [m (:negatives state)]
                                     (contains? % m))))
                        (str "The attributes are invalid or already marked as negative.\n"


(define-repl-fn context
  "Prints the current context."
  (println ctx)
  state)

(define-repl-fn knowledge

           (println t)
           state))))))

;;

(defn counterexample-via-repl
  "Starts a repl for counterexamples, which must be specified completely."
  [ctx knowledge impl]
  (loop [state {:context ctx,
                :knowledge knowledge,
                :implication impl
                :complete-counterexamples? true}]
    (let [query  (ask "counterexample> "
                      #(read-string (str (read-line)))
                      (constantly true)
