def keyword(**args)
      reject_args!(args, :type, :index)

      if es_version_2_x?
        {type: "string", index: "not_analyzed"}.merge(args)
      else
        {type: "keyword"}.merge(args)
      end
    end
def keyword(**args)
      reject_args!(args, :type, :index)

      if es_version_2_x?
        {type: "string", index: "not_analyzed"}.merge(args)
      else
        {type: "keyword"}.merge(args)
      end
    end
COMPATIBILITY: Return a "keyword"-type mapping for a field.

 On ES 2.x, this will be a string field with not_analyzed=true. On ES 5+,
 it will be a keyword field.