// This file is autogenerated, DO NOT EDIT
// Use `node scripts/generate-docs-examples.js` to generate the docs examples

[source, js]
----
const response = await client.search({
  index: "retrievers_example",
  retriever: {
    rrf: {
      retrievers: [
        {
          knn: {
            field: "vector",
            query_vector: [0.23, 0.67, 0.89],
            k: 3,
            num_candidates: 5,
          },
        },
        {
          text_similarity_reranker: {
            retriever: {
              standard: {
                query: {
                  term: {
                    topic: "ai",
                  },
                },
              },
            },
            field: "text",
            inference_id: "my-rerank-model",
            inference_text:
              "Can I use generative AI to identify user intent and improve search relevance?",
          },
        },
      ],
      rank_window_size: 10,
      rank_constant: 1,
    },
  },
  _source: false,
});
console.log(response);
----
