Command Palette

Search for a command to run...

UnylyUnyly
Весь каталог

UK Weather & Travel Outfit Recommender Server

БесплатноНе проверен

Combines UK Met Office weather forecasts with travel routing to provide outfit recommendations for walking, cycling, or driving journeys.

GitHubEmbed

Описание

Combines UK Met Office weather forecasts with travel routing to provide outfit recommendations for walking, cycling, or driving journeys.

README

A Model Context Protocol (MCP) server that combines Met Office weather data with travel routing to recommend what to wear for your journey.

Features

  • Outfit Recommendations: Get personalised clothing suggestions based on weather conditions and your travel plans
  • Weather Forecasts: Detailed hourly weather forecasts for UK locations
  • Travel Information: Calculate travel time and distance between locations
  • Supports multiple travel modes: walking, cycling, and driving
  • Real-time UK weather data from the Met Office DataHub API
  • Intelligent clothing recommendations based on temperature, precipitation, wind, and UV index

Prerequisites

Installation

  1. Clone the repository:
git clone <repository-url>
cd commute_mcp
  1. Create a virtual environment and install dependencies:
uv venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
uv pip install -e .
  1. Set up your Met Office API key:
export MET_OFFICE_API_KEY="your-api-key-here"

Usage

Running as an MCP Server

Start the server using stdio transport:

python -m src.server

The server provides three tools:

1. Get Outfit Recommendation

Analyses your journey and provides clothing recommendations:

{
  "name": "get_outfit_recommendation",
  "arguments": {
    "origin": "Bristol",
    "destination": "Bath",
    "travel_mode": "walking",
    "hours_until_departure": 0
  }
}

Parameters:

  • origin (required): Starting location (e.g., "Bristol", "London Bridge")
  • destination (required): Destination location
  • travel_mode (optional): "walking", "cycling", or "driving" (default: "walking")
  • hours_until_departure (optional): Hours until you leave, 0 for now (default: 0)

2. Get Weather Forecast

Get detailed hourly weather forecast for a UK location:

{
  "name": "get_weather_forecast",
  "arguments": {
    "location": "Manchester",
    "hours": 12
  }
}

Parameters:

  • location (required): Location name (e.g., "Bristol", "Edinburgh")
  • hours (optional): Number of hours to forecast (default: 12)

3. Get Travel Information

Calculate travel time and distance:

{
  "name": "get_travel_info",
  "arguments": {
    "origin": "London",
    "destination": "Cambridge",
    "mode": "driving"
  }
}

Parameters:

  • origin (required): Starting location
  • destination (required): Destination location
  • mode (optional): "walking", "cycling", or "driving" (default: "walking")

Using with Claude Desktop

To use this MCP server with Claude Desktop, add it to your Claude configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "commute-mcp": {
      "command": "uv",
      "args": ["--directory", "/path/to/commute_mcp", "run", "python", "-m", "src.server"],
      "env": {
        "MET_OFFICE_API_KEY": "your-api-key-here"
      }
    }
  }
}

Then restart Claude Desktop. You can now ask Claude questions like:

  • "What should I wear for a walk from Bristol to Bath?"
  • "What's the weather forecast for Edinburgh for the next 6 hours?"
  • "How long would it take to cycle from Manchester to Salford?"

How It Works

  1. Geocoding: Converts location names to coordinates using OpenStreetMap's Nominatim API
  2. Routing: Calculates travel time and distance using OSRM (Open Source Routing Machine)
  3. Weather Data: Fetches hourly forecasts from the Met Office DataHub API
  4. Analysis: Analyses weather conditions for your journey window
  5. Recommendations: Generates clothing suggestions based on:
    • Temperature and "feels like" temperature
    • Precipitation probability
    • Wind speed and gusts
    • UV index
    • Travel mode and duration

Development

Running Tests

pytest tests/

Project Structure

commute_mcp/
├── src/
│   ├── __init__.py
│   ├── server.py       # MCP server and tool handlers
│   ├── location.py     # Geocoding and routing
│   ├── weather.py      # Weather data and outfit recommendations
│   └── preferences.py  # User preferences management
├── tests/
│   ├── test_api.py
│   └── test_geocode.py
├── pyproject.toml
└── README.md

APIs Used

  • Met Office DataHub: Weather forecasts for UK locations
  • OSRM: Open-source routing engine for travel calculations
  • Nominatim: OpenStreetMap geocoding service

from github.com/tomw66/commute_mcp

Установка UK Weather & Travel Outfit Recommender Server

У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.

▸ github.com/tomw66/commute_mcp

FAQ

UK Weather & Travel Outfit Recommender Server MCP бесплатный?

Да, UK Weather & Travel Outfit Recommender Server MCP бесплатный — установка в пару кликов через Unyly без оплаты.

Нужен ли API-ключ для UK Weather & Travel Outfit Recommender Server?

Нет, UK Weather & Travel Outfit Recommender Server работает без API-ключей и переменных окружения.

UK Weather & Travel Outfit Recommender Server — hosted или self-hosted?

Доступен hosted-вариант: Unyly запускает сервер в облаке, локальная установка не обязательна.

Как установить UK Weather & Travel Outfit Recommender Server в Claude Desktop, Claude Code или Cursor?

Открой UK Weather & Travel Outfit Recommender Server на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.

Похожие MCP

Compare UK Weather & Travel Outfit Recommender Server with

Не уверен что выбрать?

Найди свой стек за 60 секунд

Автор?

Embed-бейдж для README

Похожее

Все в категории development