Skip to main content

MCP server for EPWForge — generate, morph, and download EPW weather files for EnergyPlus, OpenStudio, IES VE, and eQUEST. TMYx, AMY, CMIP6 future-climate scenarios, and wildfire smoke overlays for AI agents.

Project description

epwforge-mcp

MCP server for EPWForge — give Claude, Cursor, and other AI agents the ability to generate, morph, and download weather files for building energy simulation.

Status: 0.1.0 (Python). One tool call → one EPW. Production backend, Pro-tier features wired in.

What is EPWForge?

EPWForge generates and morphs weather files (.epw, .ddy) for building energy simulation tools — EnergyPlus, OpenStudio, IES VE, eQUEST, and any workflow that consumes EPW. The platform supports:

  • TMYx generation anywhere — typical meteorological years synthesized from ERA5 reanalysis for any global lat/lon
  • AMY (Actual Meteorological Year) — historical hourly weather for hindcasting and calibration
  • CMIP6 climate morphing — apply future-scenario deltas (SSP1-2.6, SSP2-4.5, SSP3-7.0, SSP5-8.5) at 7 warming percentiles
  • Urban Heat Island adjustment — Stewart & Oke LCZ presets (suburban / urban / dense_urban)
  • Extreme event injection — heat waves, cold snaps, humidity events, wind events, with auto-compound blending and per-event intensity (1-10 slider, AR6-auto-fill under SSP)
  • Wildfire smoke overlays — CAMS-derived AOD with Beer-Lambert solar attenuation, RH bump, temp shift
  • Per-model CMIP6 ensembles — up to 21 morphed EPWs (one per model) for inter-model uncertainty analysis

Tools

Four MCP tools, each mapping 1:1 to an EPWForge API endpoint:

Tool Purpose
generate_weather_file The workhorse. One call returns an EPW with any combination of TMY/AMY/SSP basis, UHI, extreme events, and smoke.
generate_design_day DDY file for EnergyPlus design-day sizing, computed from the same enriched hourly data.
generate_ensemble Per-model CMIP6 ensemble — one morphed EPW per climate model (Pro plan).
find_station Search weather stations near a coordinate (returns name, WMO ID, distance).

Most users will only ever need generate_weather_file. Compose options into one call instead of chaining tools.

Quick example

# What an AI agent might call to get a worst-case design weather file:
generate_weather_file(
    lat=40.71,
    lon=-74.01,
    ssp="ssp585",      # SSP5-8.5 emissions
    year=2090,         # End-of-century
    percentile=90,     # 90th percentile warming
    uhi="urban",       # Stewart-Oke urban LCZ
    events="heatwave,hothumid",  # Auto-compound heat + humidity
    event_duration=14,
    smoke=True,
    smoke_intensity=5,
    save_to="/tmp/nyc_2090_worst_case.epw",
)

Returns {filename, saved_to, bytes_written, scenario, lat, lon, ...} — no inline base64 bloat when save_to is set.

Install

pip install epwforge-mcp

Requires Python ≥ 3.10.

Connecting to Claude / Cursor

Add to your MCP client config (Claude Desktop's claude_desktop_config.json, Cursor's MCP settings, etc.):

{
  "mcpServers": {
    "epwforge": {
      "command": "epwforge-mcp",
      "env": {
        "EPWFORGE_API_KEY": "sk_live_..."
      }
    }
  }
}

Generate an API key at epwforge.com/account.

Plan requirements

Feature Plan
TMYx / AMY basis (generate_weather_file, generate_design_day without SSP) Starter
UHI / events / smoke adjustments Starter
SSP future-climate morphing Pro
generate_ensemble (per-model CMIP6) Pro
find_station Free

Tier enforcement happens at the API; the MCP surfaces 403s as "Plan upgrade required — upgrade at https://epwforge.com/pricing".

Environment variables

Variable Purpose Default
EPWFORGE_API_KEY Bearer token for the EPWForge API required
EPWFORGE_BASE_URL Override the API host (mainly for testing) https://epwforge.com

Behavior notes

  • File output: every file-generating tool accepts save_to (or save_to_dir for ensembles). When provided, the EPW is written to disk and the tool returns the path. When omitted, the EPW is returned base64-encoded in the response (≈ 250 KB for a typical year). save_to is recommended to keep agent context lean.
  • Compound events: events="heatwave,hothumid" automatically blends hothumid's humidity onto the heatwave at 50%. events="coldsnap,coldwindy" does the same for wind onto a cold snap. The secondary is folded into the primary stitch — not stitched separately.
  • Event placement: events are anchored at the cell's hottest day (heat-family) or coldest day (cold-family) and centered for the requested duration. The peak day's diurnal cycle is sustained across the event, producing 30 days of peak heat for a 30-day request — not a stretched 14-day shape.
  • Smoke + heat compound: when both are active, smoke aligns to the same anchor day and pads with peak AOD on the heat event's shoulders so solar is fully attenuated across the entire event window.
  • AR6 SSP auto-fill: with an SSP scenario active, unspecified event intensities are auto-filled from IPCC AR6 ensemble factors for the cell's region. Cold events stay at intensity 5 (no future amplification) because recent observations (Texas 2021, polar-vortex disruption) don't yet support the AR6 ensemble's cold-side dampening. Pass intensity_auto=false to disable.

Development

git clone https://github.com/guzz-labs/epwforge-mcp
cd epwforge-mcp/python
uv sync
uv run epwforge-mcp  # runs the stdio server

To test against a local API:

EPWFORGE_BASE_URL=http://localhost:3000 \
EPWFORGE_API_KEY=sk_live_... \
uv run epwforge-mcp

Links

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

epwforge_mcp-0.1.0.tar.gz (53.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

epwforge_mcp-0.1.0-py3-none-any.whl (11.6 kB view details)

Uploaded Python 3

File details

Details for the file epwforge_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: epwforge_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 53.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for epwforge_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e3287d834d6a734c9262baf3746bd7244df340f6e9afd9514479873355df2a03
MD5 fda2e635bb9f5799792bb4c5a4d40526
BLAKE2b-256 f23f678794b225609bc8b94f244ed865dba112c7b5c4a87219268ce7aac65a04

See more details on using hashes here.

File details

Details for the file epwforge_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: epwforge_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 11.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for epwforge_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b7ab20f7b34a3166f9de37cb93d8782426e55e7dd9cff561c6ce13655c70e6fb
MD5 e5c226de80d9a788d3c584bda3736be5
BLAKE2b-256 c8953fbbfa2d460e86caec6aa44f81a9a3e2af84eed241c47b5338aa1e0981e8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page