             (cons (lookup (first tokens))
                   (toks2 (rest tokens) lexicon lookup))))
         ;; only one token left: look it up.
-        (= (.size tokens) 1)
+        (= (count tokens) 1)
         (list (lookup (first tokens)))
         true
         nil))
 
 (defn create-unigram-map [args index]
-  (if (< index (.size args))
+  (if (< index (count args))
     (merge
      {[index (+ 1 index)]
       (subvec args index (+ 1 index))}
      (create-unigram-map args (+ 1 index)))))
 
 (defn create-bigram-map [args index grammar]
-  (if (< (+ 1 index) (.size args))
+  (if (< (+ 1 index) (count args))
     (let [left-side (subvec args index (+ 1 index))
           right-side (subvec args (+ 1 index) (+ 2 index))]
       (merge

(declare over)

(defn create-trigram-map [args index grammar bigrams]
  (if (< (+ 2 index) (.size args))
    (do
      (merge
       {[index (+ 3 index)]

  (over/over grammar left right))

(defn create-ngram-map [args left ngrams grammar split-at x]
  (log/debug (str "create-ngram-map: left:" left ";split-at:" split-at "; size:" (count args) "; x:" x))
  (if (< (+ left (- split-at 2))
         (/ (count args) 2))
    (lazy-cat
     (let [left-parses (get ngrams [left (+ left (- split-at 0))] '())
           right-parses (get ngrams [(+ left split-at 0) (- (count args) 0)] '())]
       (if (and (not (empty? left-parses))
                (not (empty? right-parses)))
         (over grammar left-parses right-parses)))
