A full-stack search system inspired by Flipkart, featuring autosuggest, typo-tolerance, and semantic search over a real product dataset. Built with FastAPI (backend) and Next.js (frontend).
Frontend: https://grid-front-deploy.vercel.app/
Backend: https://grid-backend-20320365612.asia-south1.run.app/health
Our advanced autosuggestion system handles spelling errors, phonetic matching, and fuzzy search to provide accurate suggestions even when users make typos.
The system remembers your search patterns and prioritizes relevant categories based on your previous searches. When you search for "shirt", the system saves the category path (Apparel→Men→Shirts→Casual Shirts) in local storage.
Later, when you type "pan", pants-related products appear at the top of suggestions based on your browsing context.
Our system adapts suggestions based on the time of day:
- Early morning: Typing "d" shows diya, dal, etc. (daily essentials)
- Night time: Typing "d" suggests daaru, wine, etc. (evening items)
A unique feature missing in many e-commerce sites - sort products by number of delivery days to find the fastest shipping options.
- Semantic product search using sentence transformers
- Trending keywords and multi-language support (Hindi-English ready)
- Real Flipkart product data (from Kaggle)
- Modern, responsive frontend with product grid, filters, and cart functionality
flipkartSearchSystem/
├── backend/ # FastAPI backend
│ ├── data/
│ │ └── products.json # Product database (JSON)
│ ├── main.py # Main API server
│ └── requirements.txt # Backend dependencies
├── frontend/ # Next.js frontend
│ ├── components/
│ ├── pages/
│ └── ...
└── dataset.csv # (Optional) Raw product dataset
For more detailed technical requirements and implementation details, please refer to our Technical Documentation.
Don't want to set up locally? Use our deployed links:
- Frontend: https://grid-front-deploy.vercel.app/
- Backend: https://grid-backend-20320365612.asia-south1.run.app/health
git clone https://github.com/prasaaaad98/Grid7.0.git
cd Grid7.0a. Create Virtual Environment (Recommended)
cd backend
python -m venv venv
# Windows
venv\Scripts\activate
# Mac/Linux
source venv/bin/activateb. Install Dependencies
pip install -r requirements.txt
python -m spacy download en_core_web_smc. Run Backend Server
uvicorn main:app --reloadThe API will be available at http://localhost:8000
cd ../frontend
npm install
npm run devThe frontend will be available at http://localhost:3000
Note: If the frontend
.envfile containsNEXT_PUBLIC_BACKEND_URL, that URL will be used; otherwise, it defaults tohttp://localhost:8000
- Open
http://localhost:3000in your browser - Use the search bar to test:
- Autosuggest functionality
- Typo-tolerance features
- Semantic product search
- Explore features:
- Add products to cart
- Apply filters
- Sort by delivery days
- Experience context-based suggestions
We welcome contributions! Here's how to get started:
- Fork this repository and clone your fork
- Create a new branch for your feature or bugfix
- Make your changes (backend or frontend)
- Test thoroughly (run both backend and frontend locally)
- Submit a pull request with a clear description
- Improve autosuggest ranking algorithms
- Add more filters (brand, category, price range)
- Enhance product detail pages
- Implement user authentication and order history
- Optimize backend for larger datasets
- Add Hindi-English translation for queries
- Implement real-time inventory updates
- Add recommendation system based on user behavior
| Issue | Solution |
|---|---|
| Backend slow to start | Reduce dataset size in convert_csv_to_json.py |
| Unicode errors | Ensure all files use encoding='utf-8' |
| Dependency errors | Check Python and Node.js versions |
| Frontend not connecting to backend | Verify NEXT_PUBLIC_BACKEND_URL in .env |
The backend uses backend/data/products.json as its database. To use a new dataset:
- Place your CSV as
dataset.csvin the project root - Run the conversion script:
python convert_csv_to_json.py
- This generates
backend/data/products.jsonin the correct format
MIT License - feel free to use this project for learning and development.
- Data Scraping: EcommerceAPI.io
- Product Dataset: Kaggle Flipkart Product Dataset
- Built with: FastAPI, Next.js, and open-source libraries
- Created by: Grid 7.0 Team
Star this Repository
If you found this project helpful, please consider giving it a star!
*Happy Searching!