title: How to exclude array with ids from ElasticSearch results set?
body: <p>I'm using Rails with ElasticSearch. As mapper I'm using <a href="https://github.com/karmi/retire" rel="nofollow">https://github.com/karmi/retire</a> .</p>
  
  <p>I have model <code>Exercise</code></p>
  
  <pre><code>class Exercise &lt; ActiveRecord::Base
    mapping do
      # ....
    end
  
    def self.search(params)
      archived_exercise_ids = [1,2,3,4]
      tire.search(load: true, page: params[:page], per_page: 15) do
        # ES documents have attribute _id
  
      end
    end
  end
  </code></pre>
  
  <p>I have set of ids for exercises which are already archived, let's say:</p>
  
  <pre><code>archived_exercise_ids = [1,2,3,4]
  </code></pre>
  
  <p>How I can write search method which won't take into consideration in the results exercises with <code>id</code> included in <code>archived_exercise_ids</code>?</p>