// 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.graph.explore({
  index: "clicklogs",
  query: {
    match: {
      "query.raw": "midi",
    },
  },
  controls: {
    use_significance: false,
    sample_size: 2000,
    timeout: 2000,
    sample_diversity: {
      field: "category.raw",
      max_docs_per_value: 500,
    },
  },
  vertices: [
    {
      field: "product",
      size: 5,
      min_doc_count: 10,
      shard_min_doc_count: 3,
    },
  ],
  connections: {
    query: {
      bool: {
        filter: [
          {
            range: {
              query_time: {
                gte: "2015-10-01 00:00:00",
              },
            },
          },
        ],
      },
    },
    vertices: [
      {
        field: "query.raw",
        size: 5,
        min_doc_count: 10,
        shard_min_doc_count: 3,
      },
    ],
  },
});
console.log(response);
----
