tinyvector

Crates.iotinyvector
lib.rstinyvector
version0.0.1
sourcesrc
created_at2023-07-03 17:33:54.584405
updated_at2023-07-04 05:00:23.417803
descriptionA tiny nearest-neighbor embedding database built with SQLite.
homepage
repositoryhttps://github.com/m1guelpf/tinyvector-rs
max_upload_size
id907220
size71,346
Miguel Piedrafita (m1guelpf)

documentation

README

tinyvector - the tiny, least-dumb, speedy vector embedding database.
🦀 rewrite of 0hq's tinyvector

Features

  • Tiny: It's in the name. It's literally just an axum server. Extremely easy to customize, around 600 lines of code.
  • Fast: Tinyvector will have comparable speed to advanced vector databases when it comes to speed on small to medium datasets.
  • Vertically Scales: Tinyvector stores all indexes in memory for fast querying. Very easy to scale up to 100 million+ vector dimensions without issue.
  • Open Source: MIT Licensed, free forever.

Soon

  • Integrated Models: Soon you won't have to bring your own vectors, just generate them on the server automaticaly. Will support SBert, Hugging Face models, OpenAI, Cohere, etc.
  • Python/JS Client: We'll add a comprehensive Python and Javascript package for easy integration with tinyvector in the next two weeks.

We're better than ...

In most cases, most vector databases are overkill for something simple like:

  1. Using embeddings to chat with your documents. Most document search is nowhere close to what you'd need to justify accelerating search speed with HNSW or FAISS.
  2. Doing search for your website or store. Unless you're selling 1,000,000 items, you don't need Pinecone.
  3. Performing complex search queries on a very large database. Even if you have 2 million embeddings, this might still be the better option due to vector databases struggling with complex filtering. Tinyvector doesn't support metadata/filtering just yet, but it's very easy for you to add that yourself.

Embeddings?

What are embeddings?

As simple as possible: Embeddings are a way to compare similar things, in the same way humans compare similar things, by converting text into a small list of numbers. Similar pieces of text will have similar numbers, different ones have very different numbers.

Read OpenAI's explanation.

License

MIT

Commit count: 21

cargo fmt