Databases · Senior · Question 60 of 75
What is a vector database (or the pgvector extension) used for?
- 1Storing 2D game coordinates only
- 2Replacing B-tree indexes for numbers
- ✓Correct answer: Storing embeddings and finding nearest neighbors by similarity, for semantic search and retrieval for LLM applications
Explanation
Approximate indexes like HNSW trade a little accuracy for speed. pgvector keeps vectors next to the rest of your data and transactions.