TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Show HN: Elastiknn – Elasticsearch Plugin for Nearest Neighbor Search

1 点作者 kleebeesh超过 4 年前

1 comment

kleebeesh超过 4 年前
Hi HN! Elastiknn is an Elasticsearch plugin that lets users store numerical vectors within documents and run exact and approximate nearest neighbor queries on them. It supports dense and sparse vectors with five similarity functions (L1, L2, Angular, Jaccard, Hamming).<p>It&#x27;s a hobby project of mine, based on an application where I needed to to continuously update an index of vectors for approximate searches. Very few of the existing approximate search libraries satisfy this use-case; most require re-building the index from scratch.<p>Elastiknn lets you add&#x2F;update&#x2F;delete vectors without rebuilding the index and combine vector queries with existing Elasticsearch queries, all through the standard JSON&#x2F;HTTP API, all in your existing cluster. You just specify a field type of `elastiknn_sparse_bool_vector` or `elastiknn_dense_float_vector`, specify some optional settings for approximate indexing, index vectors as JSON lists, and then use the `elastiknn_nearest_neighbors` query in your search requests.<p>Nothing is without tradeoffs. In terms of raw throughput, Elastiknn is slower than many existing solutions. If you need a high performance solution for offline batch jobs, it&#x27;s likely not for you. There are some benchmark results at <a href="https:&#x2F;&#x2F;elastiknn.com&#x2F;performance&#x2F;" rel="nofollow">https:&#x2F;&#x2F;elastiknn.com&#x2F;performance&#x2F;</a>.<p>My current goals for the project are: integrating with the ann-benchmarks project, releasing builds for multiple Elasticsearch versions, and creating some example applications.<p>All feedback is appreciated. At this point there are several teams evaluating the plugin. There&#x27;s a pretty thorough test suite, but nothing beats real-world usage and feedback. Cheers!