I am an AI engineer and I would like to share how to quickly build your own chatbot.
- Start with your custom data, which you believe to be true, and an embedding model for the encoder.
- Chunk and generate embeddings of your data using the encoder. Save the data and metadata in a vector database.
- The user asks a question. Generate embeddings of the question using the same encoder from step 1.
- Retrieve answers to your question by performing a semantic search using the vector database.
- Stuff the answer chunks of text from your custom documents into a “Context.” Stuff the question and context into a prompt. Send the prompt to a generating LLM.
- Get back a reliable answer from the generating LLM.
The specific code can be found at the ziliiz blog :building-open-source-chatbot-using-milvus-and-langchain-in-5-minutes