by gpt-cmdr
Provides bounded, read‑only access to HEC‑RAS project and plan metadata through the public RAS Commander Python API, enabling LLMs such as Claude Desktop or Claude Code to query project information without needing the HEC‑RAS executable.
Ras Commander Mcp exposes a lightweight, read‑only MCP server that surfaces HEC‑RAS project length units, plan descriptions, and selected metadata via the RAS Commander Python API. It is designed for use with large language models (LLMs) to answer project‑specific questions while enforcing strict data‑access boundaries.
python -m pip install .
RAS_MCP_ALLOWED_ROOTS to a JSON array of absolute paths, e.g.:
export RAS_MCP_ALLOWED_ROOTS='["/home/user/projects/example"]'
ras-commander-mcp
On PowerShell:
$env:RAS_MCP_ALLOWED_ROOTS = '["C:\\Projects\\Example"]'
ras-commander-mcp
claude_desktop_config.json.server_information(check_updates=true) reports installed vs. latest package versions.RAS_MCP_ALLOWED_ROOTS.RasText API is stable).Q: Do I need the HEC‑RAS desktop application? A: No. The server works solely with the Python API and does not launch the HEC‑RAS executable.
Q: Can the server export geometry or raster data? A: No. It is intentionally limited to metadata, length units, and plan descriptions.
Q: What happens if I query a field that is not allowed? A: The server returns an error indicating missing data or truncation, adhering to the defined tool limits.
Q: How are updates handled?
A: Use server_information(check_updates=true) to get bounded update information, but respect any pinned versions in your environment.
Q: Is this project officially supported by USACE HEC? A: No. It is an independent open‑source complement and not endorsed by USACE HEC.
RAS Commander MCP provides bounded, read-only information from HEC-RAS project and plan text through the public RAS Commander Python API. It requires no HEC-RAS executable. The fuller modeling, analysis and GIS experience uses RAS Commander and its Python workflows outside MCP.
This independent open-source project complements HEC's work. It is not affiliated with or endorsed by USACE HEC. Official HEC references remain passive reader links.
The explicit tool set covers server/version information, project length units,
plan descriptions, and selected project/plan metadata. Project metadata and plan
configuration require the new upstream RasText API; on ras-commander 0.103.0,
units and descriptions work and metadata tools return an actionable availability
error. See release sequencing.
Project tools belong only in bounded informational subagents. Each delegation specifies the question, configured root, named file, selected fields, row and character limits, and answer format. The child returns a compact answer with source identity, installed versions, missing data and truncation. A host without subagent tool isolation should use a scoped Python workflow instead of exposing project tools to its main coordinator.
MCP does not modify projects, compute, read HDF/DSS, inspect geometry/coordinates, extract gridded data, export files, download into projects, or execute arbitrary code. Large and repeated drilldowns use Python. Tool annotations describe this boundary; descriptor checks, allowlists and bounded snapshots enforce the reads.
Use Python 3.10+ and an authorized managed environment. This 0.4 redesign is an unpublished candidate; the current PyPI package is 0.3.2 and has the previous tool set. To review this candidate, install from its checkout:
python -m pip install .
After 0.4 is published and qualified, a managed current install can use
python -m pip install --upgrade ras-commander-mcp. Preserve an existing pin or
lock when required.
Set RAS_MCP_ALLOWED_ROOTS to a JSON array of absolute, resolved project roots.
No roots are trusted by default. On Linux/macOS:
export RAS_MCP_ALLOWED_ROOTS='["/home/user/projects/example"]'
ras-commander-mcp
On PowerShell:
$env:RAS_MCP_ALLOWED_ROOTS = '["C:\\Projects\\Example"]'
ras-commander-mcp
The server uses stdio. Configure the executable and environment in a client that
routes project tools to subagents. claude_desktop_config.json illustrates transport
configuration, not proof that desktop clients provide this routing. No project
query performs package installation or an automatic upgrade.
Direct dependencies are the official MCP Python SDK (without CLI extras), ras-commander and packaging. The SDK has protocol/validation/network dependencies; ras-commander currently inherits numpy, pandas and h5py. This is a small adapter, not a stdlib-only installation. No GIS, Java/DSS or remote-engine extras are added.
server_information(check_updates=true) optionally checks fixed PyPI metadata
endpoints with bounded responses and caching. It reports installed/latest versions
and update availability; offline use remains available. Preserve deliberate user
pins and refresh managed environments outside tool calls.
The full library documentation is at RAS Commander.
Please log in to share your review and rating for this MCP.
Explore related MCPs that share similar capabilities and solve comparable challenges
by headroomlabs-ai
Compress tool outputs, logs, files, RAG chunks, and conversation history before they reach the LLM, keeping answers identical while saving up to 95% of tokens for JSON payloads.
by modelcontextprotocol
A Model Context Protocol server for Git repository interaction and automation.
by zed-industries
A high‑performance, multiplayer code editor designed for speed and collaboration.
by modelcontextprotocol
Model Context Protocol Servers
by modelcontextprotocol
A Model Context Protocol server that provides time and timezone conversion capabilities.
by cline
An autonomous coding assistant that can create and edit files, execute terminal commands, and interact with a browser directly from your IDE, operating step‑by‑step with explicit user permission.
by upstash
Provides up-to-date, version‑specific library documentation and code examples directly inside LLM prompts, eliminating outdated information and hallucinated APIs.
by daytonaio
Provides a secure, elastic infrastructure that creates isolated sandboxes for running AI‑generated code with sub‑90 ms startup, unlimited persistence, and OCI/Docker compatibility.
by continuedev
Enables faster shipping of code by integrating continuous AI agents across IDEs, terminals, and CI pipelines, offering chat, edit, autocomplete, and customizable agent workflows.