def build_vectorstore(docs):
"""
Create vectorstore from documents using configured embedding model.
"""
# Choose embedding model
if cfg.EMBED_MODEL.lower() == "openai":
embeddings = OpenAIEmbeddings(model="text-embedding-3-small")
elif cfg.EMBED_MODEL.lower() == "huggingface":
from langchain_community.embeddings import HuggingFaceEmbeddings
embeddings = HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
elif cfg.EMBED_MODEL.lower() == "nomic-embed-text":
from langchain_ollama import OllamaEmbeddings
embeddings = OllamaEmbeddings(model=cfg.EMBED_MODEL)
This right here is the key difference! Yes anyone can vibe code a replacement for many apps - but will it still run 2 years later (assuming they get it 'running' in an prod environment at all