Embeddings
-
Embedding embed the meaning in the form of the vector (a mathematical point)
-
Early idea of Embedding was done by a library called as Word2Vec
-
Embedding will have the whole vocabulary
- Prompt
IN simple timeline viewer show me evolution of embeddings from word2vec quoting significant milestones
-
Embedding models
- Opensource embedding models
- Embedding models as service (Cloud)
-
Langchain Embeddings the base class
Embeddingwhich is in langchain-core.embeddings which has two simple methods- embed_query
- embed_documents
Vector Database (Vector Store)
- Once we have vectors we need to store them Refer Here to understand vector databases
- Prompt
Compare with Relational Database and Explain the organization and operations possible on vector databases
-
Vector Database Options
- Developer:
- Chroma
- FIASS
- PROD:
- Familiar:
- pgvector
- mongodb
- Cloud providers:
- AWS
- Azure
- GCP
- SaaS Providers:
- Pinecone
- Opensource Vector database:
- Weaviate
- Familiar:
- Developer:
-
Langchain vector databases integration Refer Here
-
Exercise -> Indexing Pipeline:
- Create a folder with a text files
- Each text file contains information about some city
- Ensure text is atleast 200 lines organized as paragraphs
- Use RecursiveCharacterSplitter
- Load and split => documents
- Use
text-embedding-005and chroma to store in vector database in some folder. - Ensure every chunk has the following metdata
- city: <>
- chunk-id:
- Vector database =>
./data/example1
