DiscovAI
August 8, 2024 ยท View on GitHub
An AI-powered search engine for AI tools, or your own data.
https://github.com/user-attachments/assets/2cdc92d0-d0c9-4098-8166-260e973783f0
Please feel free to contact me on Twitter or create an issue if you have any questions.
๐ป Live Demo
DiscovAI.io (use it for free without signin or credit card)
๐๏ธ Overview
- ๐ Features
- ๐งฑ Tech-Stack
- ๐ Quickstart
- ๐ Deploy
๐ Features
-
Vector-based Search: Converts user queries into vectors for precise similarity matching in our AI product database.
-
Redis-powered Caching: Utilizes Redis to cache search results and outputs, significantly improving response times for repeated queries.
-
Comprehensive AI Database: Maintains an up-to-date collection of AI products across various categories and industries.
-
LLM-powered Responses: Leverages large language models to provide detailed, context-aware answers based on search results.
-
User-friendly Interface: Offers an intuitive design for effortless navigation and efficient AI product discovery.
๐งฑ Stack
- App framework: Next.js
- Text streaming: Vercel AI SDK
- LLM Model: gpt-4o-mini
- Database: Supabase
- Vector: Pgvector
- Embedding Model: Jina AI
- Redis Cache: Upstash
- Component library: shadcn/ui
- Headless component primitives: Radix UI
- Styling: Tailwind CSS
๐ Quickstart
1. Clone repo
run the following command to clone the repo:
git clone https://github.com/DiscovAI/DiscovAI-search
2. Install dependencies
cd discovai-search
pnpm i
3. Setting up Supabase
create a supabase project, then run the src/db/init.sql in SQL Editor to setup database
4. Setting up Upstash
Follow the guide below to set up Upstash Redis. Create a database and obtain UPSTASH_REDIS_REST_URL and UPSTASH_REDIS_REST_TOKEN. Refer to the Upstash guide for instructions on how to proceed.
4. Fill out secrets
cp .env.local.example .env.local
Your .env.local file should look like this:
# Required
# for match documents
NEXT_PUBLIC_SUPABASE_URL=
NEXT_PUBLIC_SUPABASE_ANON_KEY=
# for embedding query, retrieved here: https://jina.ai/embeddings/
JINA_API_KEY=
# for llm output, retrieved here: https://platform.openai.com/api-keys
OPENAI_API_KEY=
OPENAI_API_URL=
# for llm cache and serach cache
UPSTASH_REDIS_REST_URL=
UPSTASH_REDIS_REST_TOKEN=
5. Run app locally
pnpm dev
You can now visit http://localhost:3000.
๐ Deploy
You can deploy on any saas platform like vercel, zeabur, cloudflare pages.