Skip to content
Β 
Β 

Latest commit

Β 

History

18 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🏭 Multi-Agent Industrial Geolocation Engine

Built for the GoogleX Hackathon in collaboration with DeepStation

Live Demo deployed on Cloud Run

An AI-powered multi-agent platform that helps investors and entrepreneurs identify the best industrial parks across India by combining real-time web scraping, Google Maps intelligence, government scheme matching, and Gemini AI deep research β€” all in a single unified pipeline.


πŸ—οΈ Architecture

flowchart LR
    A["πŸ‘€ User Input<br/>Sector Β· State Β·<br/>Land Β· Budget"] --> B["Step 2<br/>Query Engine<br/>Filter 4200+ parks"]
    B --> C["πŸ€– Scraper Agent<br/>Geocode Β· Logistics<br/>Β· Gemini Research"]
    C --> D["πŸ’Ύ MongoDB<br/>Store Enriched Data"]
    D --> E["πŸ€– Ranking Agent<br/>Score (100pts) Β·<br/>Deep AI Research"]
    E --> F["πŸ€– Scheme Agent<br/>Gemini + Google Search<br/>Central + State Schemes"]
    F --> G["πŸ“Š Top 10 Results<br/>Score Β· Breakdown Β·<br/>AI Recommendation"]
    G --> H["πŸ“„ PDF / Excel Export<br/>+ ROI Calculator"]

    style C fill:#3b82f6,color:#fff
    style E fill:#3b82f6,color:#fff
    style F fill:#3b82f6,color:#fff
    style H fill:#ec4899,color:#fff
Loading

Agent Detail View

flowchart TD
    subgraph SA["πŸ€– Scraper Agent"]
        SA1["Google Maps Geocoding<br/>Find Place β†’ Place Details"]
        SA2["Google Maps Places<br/>Highway Β· Railway Β· Airport Β· Port"]
        SA3["Gemini AI Research<br/>Water Β· Raw Materials Β· Incentives"]
        SA1 --> SA2 --> SA3
    end

    subgraph RA["πŸ€– Ranking Agent"]
        RA1["Multi-Criteria Scoring<br/>7 categories = 100 pts"]
        RA2["Deep Research via Gemini<br/>Why suitable Β· Why attractive"]
        RA1 --> RA2
    end

    subgraph SchA["πŸ€– Scheme Agent"]
        SchA1["Gemini + Google Search Grounding"]
        SchA2["Central & State Schemes"]
        SchA3["Subsidy Stack Calculation"]
        SchA1 --> SchA2 --> SchA3
    end

    subgraph POST["πŸ“Š Post-Pipeline"]
        P1["Live AI Recommendations"]
        P2["ROI Calculator"]
        P3["PDF & Excel Export"]
    end

    SA --> RA --> SchA --> POST

    style SA fill:#3b82f620,stroke:#3b82f6
    style RA fill:#3b82f620,stroke:#3b82f6
    style SchA fill:#3b82f620,stroke:#3b82f6
    style POST fill:#ec489920,stroke:#ec4899
Loading

✨ Key Features

Feature Description
Multi-Agent Pipeline 3 specialized AI agents (Scraper, Ranking, Scheme) orchestrated via SSE streaming
4,200+ Industrial Parks Comprehensive dataset covering all Indian states and union territories
Precise Geocoding Google Maps Find Place β†’ Place Details β†’ Geocoding API pipeline
Multi-Criteria Scoring 7-category weighted scoring engine (Sector, Land, Logistics, Water, Incentives, Plug&Play, Raw Materials)
Deep AI Research Per-park Gemini analysis with unique insights and recommendations
Government Schemes Gemini + Google Search grounding for real, active central & state schemes
ROI Calculator AI-powered investment return projections (break-even, NPV, payback)
PDF/Excel Export Professional report generation with Gemini-crafted executive summaries
Live AI Recommendations Async per-card Gemini recommendations loaded after results render
Interactive Maps Color-coded pins (green/yellow/red by score) with Google Maps integration

πŸ› οΈ Tech Stack

Layer Technology
Backend Python 3.11+ Β· Flask Β· SSE Streaming
AI Engine Google Gemini API (v1beta REST) Β· google-genai SDK
Maps & Location Google Maps Platform (Places, Geocoding, Distance Matrix, JS API)
Database MongoDB (with in-memory fallback)
Report Generation ReportLab (PDF) Β· openpyxl (Excel)
Frontend Vanilla HTML/CSS/JS Β· Google Maps JavaScript API

πŸš€ Quick Start

Prerequisites

⚠️ Google Maps API requires these APIs enabled in Cloud Console:

  • Places API (New), Geocoding API, Distance Matrix API, Maps JavaScript API

Option A: Run Locally (Python)

# Clone the repository
git clone https://github.com/mandeepsinh-parmar/GoogleX_Hackathon.git
cd GoogleX_Hackathon

# Set up environment
python -m venv .venv
source .venv/bin/activate  # Windows: .venv\Scripts\activate
pip install -r requirements.txt

# Configure keys
cp .env.example .env
# Edit .env with your Google API keys

# Run the app
python app.py

Open http://localhost:5000

Option B: Run Locally (Docker)

docker build -t industrial-finder .
docker run -p 8080:8080 --env-file .env industrial-finder

Open http://localhost:8080


☁️ Deployment (Google Cloud Run)

The application is containerized and ready for serverless deployment on Google Cloud Run.

# 1. Install Google Cloud CLI and authenticate
gcloud auth login
gcloud config set project YOUR_PROJECT_ID

# 2. Deploy directly from source
gcloud run deploy startupadvisor \
  --source . \
  --region asia-south1 \
  --allow-unauthenticated \
  --memory 512Mi \
  --set-env-vars "GOOGLE_API_KEY=YOUR_GEMINI_KEY,GOOGLE_MAPS_API_KEY=YOUR_MAPS_KEY"

For detailed deployment instructions, see DEPLOY.md.


πŸ“ Project Structure

GoogleX_Hackathon/
β”œβ”€β”€ app.py                      # Flask backend β€” SSE pipeline orchestrator
β”œβ”€β”€ requirements.txt            # Python dependencies
β”œβ”€β”€ .env.example                # Environment variable template
β”‚
β”œβ”€β”€ agents/
β”‚   β”œβ”€β”€ scraper_agent.py        # πŸ€– Agent 1: Geocoding + Logistics + Gemini Research
β”‚   β”œβ”€β”€ ranking_agent.py        # πŸ€– Agent 2: Multi-criteria scoring + Deep Research
β”‚   └── scheme_agent.py         # πŸ€– Agent 3: Government scheme matching via Gemini
β”‚
β”œβ”€β”€ tools/
β”‚   β”œβ”€β”€ location_tools.py       # Park query engine (4200+ parks) + geocoding
β”‚   β”œβ”€β”€ scheme_tools.py         # Scheme matching + subsidy estimation
β”‚   β”œβ”€β”€ scoring_tools.py        # Weighted location scoring + state ranking
β”‚   └── export_tools.py         # PDF (ReportLab) + Excel (openpyxl) generation
β”‚
β”œβ”€β”€ db/
β”‚   └── mongo_client.py         # MongoDB client with session management
β”‚
β”œβ”€β”€ data/
β”‚   └── iilb_parks.json         # Dataset: 4,200+ industrial parks across India
β”‚
β”œβ”€β”€ templates/
β”‚   └── index.html              # Frontend: Wizard UI + Google Maps + Results
β”‚
└── docs/
    └── ARCHITECTURE.md         # Detailed architecture documentation

πŸ”Œ API Endpoints

Method Endpoint Description
GET / Main application UI
POST /api/find-parks Step 2: Filter parks by sector, state, land
POST /api/run-pipeline Steps 3–7: Full SSE pipeline (scrape β†’ rank β†’ schemes)
GET /api/results/<id> Fetch stored results by session ID
POST /api/ai-recommendation Generate unique AI recommendation for a park
POST /api/roi-calculator AI-powered ROI calculation for a park
POST /api/export/pdf Download professional PDF report
POST /api/export/excel Download Excel data export
POST /api/chat Direct Gemini Q&A
GET /api/health Health check

πŸ”„ Pipeline Flow

User Input β†’ Query 4,200+ Parks β†’ Scraper Agent (Geocode + Logistics + Research)
    β†’ MongoDB Storage β†’ Ranking Agent (Score + Deep Research)
    β†’ Scheme Agent (Central + State Schemes) β†’ Top 10 Results
    β†’ [Async] AI Recommendations β†’ [On-Demand] ROI Calculator β†’ [On-Demand] PDF/Excel Export

Scoring Breakdown (100 points)

Category Max Points How It's Scored
Sector Match 20 Exact match vs. mixed-use
Available Land 20 Meets or exceeds requirement
Logistics 20 Highway + Railway + Airport + Port distances
Water Supply 10 Availability assessment
Incentives 15 Number and relevance of park incentives
Plug & Play 5 Ready-to-move infrastructure
Raw Materials 10 Regional availability

🀝 Team

Built with ❀️ for the GoogleX Hackathon in collaboration with DeepStation.


πŸ“„ License

MIT License β€” see LICENSE for details.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages