MODFLOW AI
Created by Daniel López at GWLab ↗sign in

Grounded answers on MODFLOW, PEST, FloPy, and PyEMU.

Every answer cites official documentation, source code, tutorials, and ModelMuse Help. Ask in the browser, or bring the same knowledge base into Claude Code, Cursor, VS Code, and other MCP compatible clients.

1862 documents · 233 modules · 158 tutorials

Request access→Connect your IDE ↓

Use it in the browser

Ask questions about MODFLOW, PEST, FloPy, and PyEMU without leaving the browser. The agent writes code, explains errors, and cites official documentation, source code, and tutorials.

open chat →

Connect it to your IDE

Model Context Protocol server. Expose MODFLOW AI inside Claude Code, Claude Desktop, Cursor, or any MCP-compatible client. Same knowledge base, inside your IDE.

Includes ModelMuse Help

Find dialogs, menu commands, objects, formulas, and MODFLOW package setup without leaving your client.

request access →
mcp.modflow.ai/mcp
mcp.modflow.ai/mcp
CLI
claude mcp add --transport http modflow-ai https://mcp.modflow.ai/mcp

Example answers

How do I set up a heat transport model in MODFLOW 6 using the GWE (energy) package?

A GWE model couples to a GWF flow simulation and adds packages specific to thermal energy. In FloPy you instantiate ModflowGwe with an EST package for thermal storage, a CND package for conduction and mechanical dispersion, and boundary conditions through CTP or the advanced packages (SFE for streams, LKE for lakes, MWE for multi-aquifer wells). A GwfGweExchange block wires the two models together so heads from GWF drive temperature in GWE.

source: mf6suptechinfo.pdf · ch. 10

source: flopy/mf6/modflow/mfgwegwe.py

How do I assign a time-varying pumping rate to a well in ModelMuse?

Draw or select the object that represents the well, open Object Properties, and activate WEL on the MODFLOW Features tab. Add rows with a starting time, ending time, and pumping rate. Use a negative rate for extraction and a positive rate for injection. ModelMuse converts those time ranges into the required stress-period entries, so you do not need to edit each stress period manually.

source: ModelMuse Help · WEL pane

source: ModelMuse Help · model features

What does PyEMU's PstFrom do, and how do I use it to build a PEST interface from a MODFLOW model?

PstFrom is a builder class in pyemu.utils that generates the full PEST(++) interface from your MODFLOW inputs. It produces a control file, template files, instruction files, and a forward run script. Parameters are set up as multipliers over existing arrays and list file values, so the original model stays the prior mean while PEST scales them during calibration.

source: pstfrom_mf6.ipynb

source: pyemu/utils/pst_from.py

Docs·Tutorials·GWLAB · 2026