Release Website Documentation Discord


Vector AI is a framework designed to make the process of building production grade vector based applications as quickly and easily as possible. Create, store, manipulate, search and analyse vectors alongside json documents to power applications such as neural search, semantic search, personalised recommendations recommendations etc.


Features

  • Multimedia Data Vectorisation: Image2Vec, Audio2Vec, etc (Any data can be turned into vectors through machine learning)
  • Document Orientated Store: Store your vectors alongside documents without having to do a db lookup for metadata about the vectors.
  • Vector Similarity Search: Enable searching of vectors and rich multimedia with vector similarity search. The backbone of many popular A.I use cases like reverse image search, recommendations, personalisation, etc.
  • Hybrid Search: There are scenarios where vector search is not as effective as traditional search, e.g. searching for skus. Vector AI lets you combine vector search with all the features of traditional search such as filtering, fuzzy search, keyword matching to create an even more powerful search.
  • Multi-Model Weighted Search: Our Vector search is highly customisable and you can peform searches with multiple vectors from multiple models and give them different weightings.
  • Vector Operations: Flexible search with out of the box operations on vectors. e.g. mean, median, sum, etc.
  • Aggregation: All the traditional aggregation you’d expect. e.g. group by mean, pivot tables, etc
  • Clustering: Interpret your vectors and data by allocating them to buckets and get statistics about these different buckets based on data you provide.
  • Vector Analytics: Get better understanding of your vectors by using out-of-the-box practical vector analytics, giving you better understanding of the quality of your vectors.

Quick Terminologies

  • Models/Encoders (aka. Embedders) ~ Turns data into vectors e.g. Word2Vec turns words into vector
  • Vector Similarity Search (aka. Nearest Neighbor Search, Distance Search)
  • Collection (aka. Index, Table) ~ a collection is made up of multiple documents
  • Documents (aka. Json, Item, Dictionary, Row) ~ a document can contain vectors, text and links to videos/images/audio.

QuickStart

Install via pip! Compatible with any OS.

pip install vectorai

If you require the nightly version due to on-going improvements, you can install the nightly version using:

pip install vectorai-nightly

Note: while the nightly version will still pass automated tests, it may not be stable.

Check out our quickstart notebook on how to make a text/image/audio search engine in 5 minutes: quickstart.ipynb

<div class="snippet-clipboard-content position-relative overflow-auto" data-snippet-clipboard-copy-content="from vectorai import ViClient, request_api_key

api_key = request_api_key(username=, email=, description=, referral_code="github_referred")

vi_client = ViClient(username=username, api_key=api_key)

from vectorai.models.deployed import ViText2Vec
text_encoder = ViText2Vec(username, api_key)

documents = [
{
‘_id’: 0,
‘color’: ‘red’
},
{
‘_id’: 1,
‘color’: ‘blue’
}
]

# Insert the data
vi_client.insert_documents(‘test-collection’, documents, models={‘color’: text_encoder.encode})

# Search the data
vi_client.search(‘test-collection’, text_encoder.encode(‘maroon’), ‘color_vector_’, page_size=2)

# Get Recommendations
vi_client.search_by_id(‘test-collection’, ‘1’, ‘color_vector_’, page_size=2)
“>

from vectorai import ViClient, request_api_key

api_key = request_api_key(username=<username>, email=<email>, description=<description>, referral_code="github_referred")

vi_client = ViClient(username=username, api_key=api_key)

from vectorai.models.deployed import ViText2Vec
text_encoder = ViText2Vec(username, api_key)

documents = [
    {
        '_id': 0,
        'color': 'red'
    },
    {
        '_id': 1,
        'color': 'blue'
    }
]

# Insert the data
vi_client.insert_documents('test-collection', documents, models={'color': text_encoder.encode})

# Search the data
vi_client.search('test-collection', text_encoder.encode('maroon'), 'color_vector_', page_size=2)

# Get Recommendations
vi_client.search_by_id('test-collection', '1', 'color_vector_', page_size=2)