This is a chatbot application powered by Vector Search + Text2SQL. It is built using the Vercel AI SDK and Retrieval-Augmented Generation (RAG). The chatbot is built using the following stack:
- Next.js 14 (App Router)
- Vercel AI SDK
- OpenAI
- Drizzle ORM
- Postgres with pgvector
- shadcn-ui and TailwindCSS for styling
- Clone the repository:
git clone https://github.com/zarifaziz/fitness-center-rag-demo.git- Install dependencies:
cd ai-answer-engine
pnpm install
- Start the development server:
pnpm run dev
- Open
http://localhost:3000with your browser to see the chatbot in action
- Retrieval-Augmented Generation (RAG): The chatbot uses the Vercel AI SDK's RAG guide to generate responses based on the information it has in its knowledge base.
- Vector Search: The chatbot uses pgvector to perform vector search on the knowledge base, allowing it to quickly find relevant information.
- Text2SQL: The chatbot uses the Text2SQL tool from the Vercel AI SDK to generate SQL queries based on user input, allowing it to retrieve information from the knowledge base.