These changes enable support for both Exact k-NN and Approximate k-NN searches in OpenSearch. The code was updated and refactored to include this new functionality, as it previously only supported Exact k-NN.

  • Enhanced OpenSearchVectorStore to support both exact and approximate k-NN search methods.
  • Updated integration tests to cover common similarity metrics (cosinesimil, l2, innerproduct) for both exact and approximate k-NN.
  • Made necessary updates to the auto-configuration to accommodate the new support for approximate k-NN.

Comment From: tzolov

Thank you @JM-Lab , Could you please update the documentation as well. Add and document the new (and/or updated) properties there and perhaps explain how to switch between the 2 search options.

Comment From: JM-Lab

@tzolov Thanks for the feedback! I’ve updated the documentation with the new properties, search options, and corrected some errors.

Comment From: JM-Lab

Hi @tzolov, @sobychacko,

This branch is too outdated, and while rebasing with the main branch, it got tangled. I have created a new pull request to start fresh from the squashed branch: #1121. Therefore, I am closing this pull request.

Review the new pull request. Thank you.