Agentic HEC-RAS
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| HECRAS_EXE | No | Path to the HEC-RAS executable (Ras.exe). If not set, auto-detected in the default install folder. |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| ras_manifest_writeA | Write a provenance manifest (JSON) for one modelling step: the project .prj + input + result (.p##.hdf) + figure files each with a sha256, the ras_run QA status, the edits made (ras_plan_set / ras_flow_set_hydrograph returns), the tool calls, and free notes. Call it at the end of a run so the run can be audited or re-compared later. Reports any referenced file that is missing. No HEC-RAS needed. |
| ras_results_compareA | Compare two runs (baseline HDF vs scenario HDF) at one location: delta peak (value and %), peak timing shift, RMSE, NSE, and for flows the delta volume; time bases are aligned ('exact' or 'interpolated'). kind/location/variable/mesh as in ras_results_timeseries. For kind 'xsec' with NO location, ranks every shared cross section by change of peak (n increased / decreased / unchanged, top-N) and details the largest change. |
| ras_flow_set_hydrographA | Edit ONE boundary condition table in an unsteady flow file (.u##): replace the hydrograph 'values' (any length; count line rewritten), or scale the existing values by 'multiplier', or set the HEC-RAS flow multiplier 'qmult' (Flow Hydrograph QMult, applied at run time), and/or change the 'interval' ('1HOUR','15MIN'). Select the boundary by boundary_index (from ras_project_info plan detail) or river/reach/rs, or area/bc_line for 2D BC lines. Works for Flow, Stage, Lateral Inflow, Uniform Lateral Inflow, Precipitation hydrographs and Gate Openings. Edit a COPY of the project. Returns the boundary before/after summary (n, peak). |
| ras_plan_setA | Change settings of one plan (.p##) in place: simulation window, computation / output / mapping interval, number of cores, short id, title, description, and which geometry (g##) or unsteady flow file (u##) the plan uses. Returns before/after values. Edit a COPY of the project (ras_project_copy) — this rewrites the plan file. Intervals use HEC-RAS strings ('10SEC','1MIN','15MIN','1HOUR'); dates accept '02JAN1900 0000' or ISO '1900-01-02T00:00'. |
| ras_plotA | Make a PNG figure from results HDF(s). plot='hydrograph': one time series (kind/location/variable/mesh as in ras_results_timeseries) for 1-4 runs overlaid (hdfs + labels), peaks annotated. plot='profile': maximum water surface (or flow / velocity) along the river stations of a reach ('reach'='River/Reach', default all) for 1-4 runs. plot='mesh_max': map of the 2D cells coloured by maximum water surface (single hdf, optional 'mesh'). Returns the PNG path. |
| ras_project_infoA | Inspect a HEC-RAS project: plans (title, geometry, flow file, simulation window, intervals, cores, whether a results .p##.hdf exists), geometries, unsteady/steady flow files with their boundary conditions, current plan, and which Ras.exe would be used. Pass 'plan' to also get that plan's boundary conditions in detail (river/reach/RS or 2D area/BC line, kind, interval, n values, peak; include_values=true for the full hydrograph). No HEC-RAS install needed. |
| ras_project_copyA | Copy a whole HEC-RAS project folder to a new folder (all .prj/.g##/.p##/.u##/.f##/terrain/DSS files, relative references stay valid). Use it BEFORE editing or running so the original model is never modified. Results HDFs and logs are excluded unless include_results=true. |
| ras_results_summaryA | One-screen summary of a HEC-RAS results HDF (.p##.hdf): plan info, run QA status, unsteady summary (max WSEL error, solution text), volume accounting (error %), runtime, cross sections (count, reaches, upstream/downstream, top-N by max flow with max WSE / velocity and time), 2D mesh areas (cells, max WSE stats + where/when), reference lines / points and boundary conditions with their peaks. Units follow the project (US customary or SI). No HEC-RAS needed. |
| ras_results_timeseriesA | One time series from a results HDF with peak / time of peak / min / mean, downsampled to at most max_points. kind: 'xsec' (location 'River/Reach/Station' or just the station; variable flow | water_surface | velocity | velocity_channel | flow_lateral), 'ref_line' / 'ref_point' / 'boundary' (location = name; variable e.g. 'Flow' or 'Water Surface'), 'mesh_cell' (mesh = 2D area name, location = cell id, variable 'Water Surface'). Omit location to get the first one. |
| ras_runA | Run one HEC-RAS plan headless (Ras.exe -c project.prj plan.p##; geometry preprocessing, unsteady/steady computation and post-processing) and QA the result. If run_dir is given the whole project is first copied there and run inside it (safe); otherwise the plan runs in place (use on a copy!). Blocks until the run finishes. Returns status ('completed', 'completed_with_warnings', 'unstable', 'failed', 'no_results'), usable (bool), reasons, metrics (max WSEL error, volume error %, ERROR/WARNING line counts), the results HDF path, runtime and the log tail. Gate on 'status'/'usable', not on 'ok'. A watchdog accepts HEC-RAS's 'Terms and Conditions for Use' dialog if it appears (accept_tcu, default true) and kills the run after timeout_s (default 4 h). Needs HEC-RAS installed (Windows). |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 10 tools
Each tool has a clearly distinct purpose: inspecting, copying, editing plan settings, editing boundary conditions, running, summarizing results, extracting timeseries, comparing results, plotting, and writing manifests. No two tools could be confused for one another.
All tools share the 'ras_' prefix, and most follow a noun_verb pattern (e.g., project_info, results_compare). Minor deviations like 'ras_plot' and 'ras_run' being verb-only are acceptable, and the naming is generally predictable.
With 10 tools, the server is well-scoped for a HEC-RAS modeling workflow. Each tool addresses a necessary step in the pipeline without redundancy or bloat.
The tool set covers the full lifecycle: project inspection, copying, editing plans and flow hydrographs, running simulations, extracting and summarizing results, comparing scenarios, plotting, and recording provenance. No critical gaps are apparent for the stated domain.