How bhavygandhi125273-sketch/ai-product-finder works
Product Finder is a web app for uploading a product photo, identifying the primary item with AI, and finding similar products through visual search. The main workflow runs through the client page, which prepares the image and calls separate analysis and product-search endpoints, then displays the identification and product results. The product-search endpoint compresses and uploads the image before querying Google Lens via SerpApi. The README is only the Next.js starter template; the supplied page excerpt omits some request and state-handling code, so the graph shows only wiring supported by the excerpts.
Main entry points: page.tsx Upload and results UI · products/route.ts Image product-search API · analyze/route.ts Product identification API
Components 6
User Interface
- Upload and results UI
app/page.tsx
AI Identification
- Product identification API
app/api/analyze/route.ts
Visual Product Search
- Image product-search API
app/api/products/route.ts
Other components
- Photo uploader
- OpenAI
- SerpApi / Google Lens
Connections 9
- Photo uploader → Upload and results UI: uploads photo
- Upload and results UI → Product identification API: submits image
- Upload and results UI → Image product-search API: submits image
- Product identification API → OpenAI: requests identification
- OpenAI → Product identification API: returns analysis
- Product identification API → Upload and results UI: returns result
- Image product-search API → SerpApi / Google Lens: uploads image
- Image product-search API → SerpApi / Google Lens: searches products
- Image product-search API → Upload and results UI: returns matches