nmslib / hnswlib

Header-only C++/python library for fast approximate nearest neighbors
https://github.com/nmslib/hnswlib
Apache License 2.0
4.3k stars 633 forks source link

Can I make use of hnswlib for finding shortest paths between nodes? #528

Open yazhinia opened 9 months ago

yazhinia commented 9 months ago

Dear developers, I would like to know if there is any possibility of using hnsw results for finding the shortest path between nodes. Your response is much appreciated.

Thank you.

Best, Yazhini

yurymalkov commented 9 months ago

Hi @yazhinia,

You can use HNSW to find the short paths between nodes, but only in HNSW-built graph and they are not guaranteed to be the shortest