Metadata-Version: 2.4
Name: hydroreopllm
Version: 0.1.1
Summary: HydroReOpLLM: configurable reservoir operations coupled with HydroCNHS
License-Expression: BSD-3-Clause
Project-URL: Repository, https://github.com/WenyuChiou/HydroReOpLLM
Project-URL: Documentation, https://wenyuchiou.github.io/HydroReOpLLM/
Requires-Python: >=3.12
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: licenses/HydroCNHS-BSD-3-Clause.txt
Requires-Dist: joblib
Requires-Dist: matplotlib
Requires-Dist: numpy
Requires-Dist: pandas
Requires-Dist: ruamel.yaml
Requires-Dist: scipy
Requires-Dist: scikit-learn
Requires-Dist: tqdm
Requires-Dist: PyYAML>=6
Requires-Dist: deap
Provides-Extra: hydrocnhs
Provides-Extra: test
Requires-Dist: pytest>=8; extra == "test"
Requires-Dist: pytest-subtests; extra == "test"
Requires-Dist: setuptools>=77.0.3; extra == "test"
Provides-Extra: docs
Requires-Dist: mkdocs[i18n]==1.6.1; extra == "docs"
Provides-Extra: gis
Requires-Dist: shapely<3,>=2; extra == "gis"
Requires-Dist: pyproj<4,>=3; extra == "gis"
Dynamic: license-file

# HydroReOpLLM

[![User manual](https://wenyuchiou.github.io/HydroReOpLLM/assets/branding/docs-badge-en.svg)](https://wenyuchiou.github.io/HydroReOpLLM/)

![Reservoirs and rivers with LLM reservoir operators](https://wenyuchiou.github.io/HydroReOpLLM/assets/branding/cover.png)

HydroReOpLLM builds on HydroCNHS to simulate reservoir operations using prepared inflows or weather data, with rule-based, prescribed, or LLM-based release decisions.

## Quick start

Run a four-day synthetic single-reservoir case with a prescribed release. The simulation requires no API key. Start in an empty working directory with an active Python 3.12 or newer virtual environment. [Create a virtual environment](https://wenyuchiou.github.io/HydroReOpLLM/GETTING_STARTED.html#install-from-pypi).

```sh
python -m pip install hydroreopllm
python -c "from pathlib import Path
from shutil import copytree
from sysconfig import get_path
source = Path(get_path('data')) / 'share/llm-reservoir-agent/examples'
copytree(source, 'examples')"
reservoir-experiment check examples/daily_offline/single.yaml
reservoir-experiment run examples/daily_offline/single.yaml
reservoir-experiment verify runs/daily-single --require-offline
```

Look for `PASS`, 4 days, and `observed_network_calls: 0` in the verification output. Open `runs/daily-single/summary.json` to confirm the run is `COMPLETED` and the final storage of `Lake_1` is **1,345,600 m³**. To repeat the case, [set a new run ID and output path](https://wenyuchiou.github.io/HydroReOpLLM/GETTING_STARTED.html#repeat-a-run).

## Clone and run the notebook

The PyPI package includes ready-to-run examples. Clone the repository for the notebook and the full collection of examples and templates. [Clone and install HydroReOpLLM](https://wenyuchiou.github.io/HydroReOpLLM/GETTING_STARTED.html#install-from-a-clone) · [Open the notebook tutorial](https://wenyuchiou.github.io/HydroReOpLLM/tutorials/index.html)

## Choose an example

| What you want to do | Where to start |
| --- | --- |
| Trace releases through one reservoir or a connected cascade | [Single-reservoir and cascade examples](https://wenyuchiou.github.io/HydroReOpLLM/examples/daily_offline/index.html) |
| Run two independent reservoirs driven by weather data, each draining to its own outlet | [Two reservoirs with separate outlets](https://wenyuchiou.github.io/HydroReOpLLM/examples/multiple_reservoirs/index.html) |
| Run daily, hourly, or fixed-interval simulations | [Time-step examples](https://wenyuchiou.github.io/HydroReOpLLM/examples/time_scales/index.html) |
| Set up your own case and inspect decisions, storage, and water balance | [Configuration](https://wenyuchiou.github.io/HydroReOpLLM/CONFIGURATION.html) · [Results guide](https://wenyuchiou.github.io/HydroReOpLLM/RESULTS_GUIDE.html) |

## Tests and license

From a clone, install the test extra with `python -m pip install -c environment/requirements-bundled.txt ".[test]"` and run `python -m pytest -q`.

[BSD 3-Clause License](https://github.com/WenyuChiou/HydroReOpLLM/blob/main/LICENSE) · [Third-party notices](https://github.com/WenyuChiou/HydroReOpLLM/blob/main/THIRD_PARTY_NOTICES.md)
