Update README.md

#1
by pulkitT007 - opened
Files changed (1) hide show
  1. README.md +124 -3
README.md CHANGED
@@ -1,12 +1,133 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  title: TravAI
3
  emoji: πŸ“Š
4
  colorFrom: green
5
  colorTo: pink
6
  sdk: gradio
7
- sdk_version: 5.33.0
8
  app_file: app.py
9
  pinned: false
10
  ---
11
-
12
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
1
+ # πŸ—ΊοΈ Tour Planner MCP Tool
2
+ **Track**: `mcp-server-track`
3
+ **Hackathon**: Agents & MCP Hackathon 2025
4
+ **Team**: Sarthak Bhardwaj, Maria Dirnberger, Pulkit Thukral
5
+
6
+ ---
7
+
8
+ ## 🌟 Overview
9
+ **Tour Planner MCP Tool** is an agent-accessible Gradio app that functions as a **Model Context Protocol (MCP) Server**. It helps usersβ€”and by extension, AI agentsβ€”plan smart travel routes and check localized weather forecasts for their trips.
10
+
11
+ This app includes:
12
+ - 🧭 **Google Maps Directions**: Get step-by-step, optimized routes between locations, optionally with waypoints, travel mode, and a static map snapshot.
13
+ - 🌀️ **Weather Forecast**: Get detailed weather insights (including hourly breakdowns and UV index) for a given location and date range, using the Open-Meteo API.
14
+
15
+ Perfect for itinerary-building agents or AI assistants that need contextual, real-world travel and weather data.
16
+
17
+ ---
18
+
19
+ ## πŸš€ Live Demo
20
+ πŸ‘‰ [Launch the MCP Tool on Hugging Face Spaces](#)
21
+ πŸŽ₯ [Watch a quick demo of the tool in action](#)
22
+
23
+ ---
24
+
25
+ ## πŸ”§ Features
26
+
27
+ ### πŸ“ Google Maps Directions Tool
28
+ **Inputs:**
29
+ - Source Location (text)
30
+ - Destination Location (text)
31
+ - Travel Mode (driving / walking / bicycling / transit)
32
+ - Departure Time (in `YYYY-MM-DD HH:MM` format)
33
+ - One Waypoint
34
+
35
+ **Output:**
36
+ - Markdown summary of route with:
37
+ - Total distance and duration
38
+ - Step-by-step directions
39
+ - Static map snapshot
40
+
41
+ ---
42
+
43
+ ### 🌦️ Weather Forecast Tool
44
+ **Inputs:**
45
+ - Location Name
46
+ - Start Date
47
+ - End Date
48
+
49
+ **Output:**
50
+ - Daily weather breakdown (sunrise, sunset, UV index, temperature)
51
+ - Hourly details (up to 7 days ahead): temperature, weather condition, UV index, visibility
52
+ - Markdown-formatted output
53
+
54
+ ---
55
+
56
+ ## πŸ“œ How to Use (MCP-Compatible)
57
+
58
+ To use this tool via MCP, simply connect any MCP-compatible client such as:
59
+ - [Claude Desktop](https://huggingface.co/spaces/Anthropic/claude-desktop)
60
+ - [Cursor](https://www.cursor.so/)
61
+ - [Tiny Agents](https://huggingface.co/spaces/mcp/tiny-agents)
62
+
63
+ This app exposes two API endpoints:
64
+ - `/predict/get direction`
65
+ - `/predict/get weather forecast`
66
+
67
+ Agents can interact with it using structured input fields defined in the Gradio UI and receive Markdown or structured output to reason over.
68
+
69
+ ---
70
+
71
+ ## πŸ’‘ Motivation
72
+ We wanted to build a travel-assistant-style MCP tool that an LLM agent could query in natural language to:
73
+ - Check if walking from Brandenburg Gate to Museum Island makes sense.
74
+ - See if it might rain in Paris during the second week of June.
75
+ - Create routes with coffee stops between meetings.
76
+
77
+ Combining **live navigation logic** with **real weather forecasting** creates powerful context for itinerary-focused AI agents.
78
+
79
+ ---
80
+
81
+ ## πŸ› οΈ Tech Stack
82
+ - `Gradio 4.x` (with `mcp_server=True`)
83
+ - `Google Maps Directions API`
84
+ - `Open-Meteo API`
85
+ - `geopy`, `pandas`, `dotenv`, `requests`, `re`, `datetime`, `json`
86
+
87
+ ---
88
+
89
+ ## πŸ” API Keys
90
+ - Requires a valid `GOOGLE_API_KEY` in a `.env` file for route planning.
91
+ - Weather data is free and does not require a key (via Open-Meteo).
92
+
93
+ ---
94
+
95
+ ## πŸ“₯ Setup Instructions
96
+
97
+ 1. Clone this repo
98
+ 2. Create a `.env` file with your Google API key:
99
+ ```dotenv
100
+ GOOGLE_API_KEY=your_api_key_here
101
+ 3. Install dependencies
102
+ ```
103
+ pip install -r requirements.txt
104
+ 4. Run locally
105
+ ```
106
+ python app.py
107
+
108
+ ---
109
+
110
+ ## 🎯 Future Enhancements
111
+ - Auto-detect location from IP
112
+ - Add alerts for UV index or rain warnings
113
+ - Suggest alternate routes based on weather
114
+ - Integrate with calendar events for smart trip planning
115
+
116
+ ---
117
+
118
+ ## πŸ“¬ Contact
119
+
120
+ Built by **Sarthak Bhardwaj**, **Maria Dirnberger**, and **Pulkit Thukral**
121
+
122
+
123
  ---
124
  title: TravAI
125
  emoji: πŸ“Š
126
  colorFrom: green
127
  colorTo: pink
128
  sdk: gradio
129
+ sdk_version: 5.33.1
130
  app_file: app.py
131
  pinned: false
132
  ---
133
+ Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference