                      
                            ;; lazy-sequence of phrasal complements to pass one-by-one to the above (map)'s function.
                            (do
-                             (log/debug (str "generating lexical complements with spec: " (strip-refs spec)))
+                             (log/debug (str "generating phrasal complements with spec: " (strip-refs spec)))
                              (let [phrasal-complements (generate-all spec grammar lexicon cache morph)]
+                               (log/debug (str "number of phrasal components given spec: " spec ":"
+                                               (count phrasal-complements)))
+                               (if (> (count phrasal-complements) 0)
+                                 (log/debug (str "phrasal complements given spec: " spec ":"
+                                                 (string/join "," (map morph phrasal-complements))))
+                                 (log/debug (str "phrasal complements of spec: " spec ":"
+                                                 "were empty.")))
+                                               
                                (if (lexemes-before-phrases)
                                  (lazy-cat shuffled-candidate-lexical-complements phrasal-complements)
                                  (do

            (if (empty? return-val)

              ;; else, no complements could be added to this bolt: Throw an exception
              (let [log-limit 100
                    log-fn (if (= (get-in bolt (concat path [:phrasal]))
                                  false)
                             (fn [message] (log/debug message));; since complement must be phrasal, less logging

                             ;; else: should have found a lexical complement: log all problems: provide logging for diagnostics.
                             (fn [message] (log/error message)))
                    throw-exception-if-no-complements-found true
                    message
                    (cond (= (get-in bolt (concat path [:phrasal]))
                             true)
                          (str "skipping logging about lexical complements since bolt wants a phrasal complement.")
                          true
                          (str " add-complement to " (get-in bolt [:rule]) " at path: " path " took " run-time " msec, but found no lexical complements for "
                               "'" (morph from-bolt) "'"
                               ". Bolt wants phrasal-wise: " (get-in bolt (concat path [:phrasal]))
                               ". Desired complement [:synsem] was: " (strip-refs (get-in bolt (concat path [:synsem])))
                               ". " (count complement-candidate-lexemes) " complement(s) tried were:"
                               (str " "
                                    (string/join "," (sort (map morph (take log-limit complement-candidate-lexemes))))

                                    (if (< 0 (- (count complement-candidate-lexemes) log-limit))
                                      (str ",.. and "
                                           (- (count complement-candidate-lexemes) log-limit) " more."))
                                    
                                    ";     with preds:   "
                                    (string/join "," (map #(get-in % [:synsem :sem :pred]) (take log-limit complement-candidate-lexemes)))

                                    ";     fail-paths:   "
                                    (string/join ","
                                                 (map #(if
                                                           (or true (not (fail? (unifyc (get-in % [:synsem :sem :pred])
                                                                                        (get-in bolt (concat path
                                                                                                             [:synsem :sem :pred]))))))
                                                             (str "'" (morph %) "':"
                                                                  (fail-path-between (strip-refs %)
                                                                                     (strip-refs (get-in bolt path)))))
                                                          (take log-limit complement-candidate-lexemes)))
                                    
                                    (if (< 0 (- (count complement-candidate-lexemes) log-limit))
                                      (str ",.. and "
                                           (- (count complement-candidate-lexemes) log-limit) " more.")))))]
                (log-fn message)

                ;; set to true to work on optimizing generation, since this situation of failing to add any

              
              return-val
              (filter (fn [result]
                        (do
                          (log/debug (str "LOOKING AT RESULT:  " result))
                          (not (fail? result))))
                      (map (fn [complement]
                             (let [debug (log/debug (str "adding complement to: ["
                                                         (get-in bolt [:rule]) " "
