                             (map #(get science-keywords %))
                             (remove nil?)
                             (s/join ":"))
-        keyword-value (get science-keywords terminal-key)]
+        keyword-value (get science-keywords terminal-key)
+        id (-> (s/lower-case keyword-string)
+               (str "_science_keywords")
+               hash)]
      {:type "science_keywords"
-      :_id (str (s/lower-case keyword-string) "_science_keywords")
+      :_id id
        :value keyword-value
-       :field keyword-string
+       :fields keyword-string
        :_index "1_autocomplete"
        :_type "suggestion"}))
 

(ns cmr.indexer.services.index-service
  "Provide functions to index concept"
  (:require
   [camel-snake-kebab.core :as csk]
   [cheshire.core :as cheshire]
   [clj-time.core :as t]
   [clj-time.core :as t]

     (science-keywords->elastic-docs value-map)
     (map (fn [value]
            (let [v (val value)
                  type (camel-snake-kebab/->snake_case_keyword key-name)
                  id (-> (s/lower-case v)
                         (str "_" type)
                         hash)]
             {:type type
              :_id id
              :value v
              :fields (camel-snake-kebab/->snake_case_keyword (name (key value)))
              :_index "1_autocomplete"
              :_type "suggestion"}))
         values))))
