Metadata-Version: 2.4
Name: open-fdd
Version: 3.1.1
Summary: Arrow-native HVAC fault detection runtime — lint, test, and run apply_faults_arrow rules on columnar telemetry (PyPI). Use GHCR Docker images for the full edge operator stack.
Author-email: Ben Bartling <ben.bartling@gmail.com>
License: MIT
Project-URL: Homepage, https://github.com/bbartling/open-fdd
Project-URL: Documentation, https://bbartling.github.io/open-fdd/
Project-URL: Repository, https://github.com/bbartling/open-fdd
Keywords: hvac,fdd,fault-detection,building-automation,pyarrow,arrow
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pyarrow>=17.0.0
Requires-Dist: pyyaml
Requires-Dist: pydantic<3,>=2.4
Provides-Extra: ml
Requires-Dist: numpy>=1.26.0; extra == "ml"
Requires-Dist: scikit-learn>=1.4.0; extra == "ml"
Provides-Extra: analytics
Requires-Dist: numpy>=1.26.0; extra == "analytics"
Provides-Extra: pandas
Requires-Dist: pandas>=2.0.0; extra == "pandas"
Provides-Extra: release
Requires-Dist: build>=1.2.0; extra == "release"
Requires-Dist: twine>=6.0.0; extra == "release"
Provides-Extra: test
Requires-Dist: pytest>=7.0; extra == "test"
Requires-Dist: pytest-timeout>=2.3.0; extra == "test"
Provides-Extra: dev
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: pytest-timeout>=2.3.0; extra == "dev"
Requires-Dist: pyyaml; extra == "dev"
Requires-Dist: pydantic<3,>=2.4; extra == "dev"
Requires-Dist: black[jupyter]>=25.11.0; extra == "dev"
Requires-Dist: pre-commit; extra == "dev"
Requires-Dist: build>=1.2.0; extra == "dev"
Requires-Dist: twine>=6.0.0; extra == "dev"
Provides-Extra: docs
Requires-Dist: pyyaml; extra == "docs"
Requires-Dist: weasyprint>=62.0; extra == "docs"
Provides-Extra: portfolio
Requires-Dist: dash>=2.17; extra == "portfolio"
Requires-Dist: plotly>=5.22; extra == "portfolio"
Requires-Dist: pandas>=2.2; extra == "portfolio"
Provides-Extra: datafusion
Requires-Dist: datafusion>=40.0.0; extra == "datafusion"
Dynamic: license-file

# Open-FDD

<p align="center">
  <a href="https://discord.gg/Ta48yQF8fC"><img src="https://img.shields.io/badge/Discord-Join%20Server-5865F2.svg?logo=discord&logoColor=white" alt="Discord"></a>
  <a href="https://github.com/bbartling/open-fdd/actions/workflows/ci.yml"><img src="https://github.com/bbartling/open-fdd/actions/workflows/ci.yml/badge.svg?branch=master" alt="CI"></a>
  <img src="https://img.shields.io/badge/license-MIT-green.svg" alt="MIT">
  <img src="https://img.shields.io/badge/status-Beta-blue" alt="Beta">
  <img src="https://img.shields.io/badge/Python-%3E%3D3.10-blue?logo=python&logoColor=white" alt="Python 3.10+">
</p>

<p align="center">
  <img src="https://raw.githubusercontent.com/bbartling/open-fdd/master/image.png" alt="Open-FDD logo" width="440">
</p>

<p align="center">
  Open-source <strong>supervisory fault detection</strong> for buildings — Arrow-native rules,
  optional DataFusion SQL rules for Rust-ready migration,
  optional <strong>PyPI</strong> embeddable runtime, and a full <strong>Docker/GHCR</strong> edge operator stack
  (BACnet, bridge API, dashboard, MCP).
</p>

<p align="center">
  <a href="https://bbartling.github.io/open-fdd/"><img src="https://img.shields.io/badge/Documentation-read_online-2563EB?style=for-the-badge" alt="Documentation"></a>
  <a href="https://github.com/bbartling/open-fdd/blob/master/pdf/open-fdd-docs.pdf"><img src="https://img.shields.io/badge/Docs-PDF_download-DC2626?style=for-the-badge" alt="PDF documentation"></a>
</p>

---

## Install / run

### Full Open-FDD edge stack (Docker / GHCR)

Use GHCR for BACnet polling, Operator Bridge API, React dashboard, historian, and MCP sidecar in a `docker pull` workflow.

| Image | Role |
|-------|------|
| [`ghcr.io/bbartling/openfdd-bridge`](https://github.com/bbartling/open-fdd/pkgs/container/openfdd-bridge) | API, dashboard, historian |
| [`ghcr.io/bbartling/openfdd-commission`](https://github.com/bbartling/open-fdd/pkgs/container/openfdd-commission) | BACnet discover, read, poll |
| [`ghcr.io/bbartling/openfdd-mcp-rag`](https://github.com/bbartling/open-fdd/pkgs/container/openfdd-mcp-rag) | MCP + doc-search |

**Prefer pinned release tags in production** (not floating `latest`):

```bash
# Bootstrap a new edge host (no git clone) — creates ~/open-fdd, auth.env.local, BACnet bind
curl -fsSL -o /tmp/openfdd_edge_bootstrap.sh \
  https://github.com/bbartling/open-fdd/raw/refs/heads/master/scripts/openfdd_edge_bootstrap.sh
OPENFDD_IMAGE_TAG=3.0.34 bash /tmp/openfdd_edge_bootstrap.sh --start --image-tag 3.0.34

# Update an existing site — backup workspace, pull pinned GHCR tags, recreate containers
cd ~/open-fdd
./scripts/openfdd_site_backup.sh
NEW_TAG=3.0.34 ./scripts/openfdd_site_update.sh
```

From a repo checkout: `./scripts/openfdd_edge_bootstrap.sh --start --image-tag 3.0.34`

Edge bootstrap: [Run with Docker images](https://bbartling.github.io/open-fdd/quick-start/docker/) · Site updates: [Updating the stack](https://bbartling.github.io/open-fdd/quick-start/updating/)

### Python package (PyPI)

Use PyPI when you only need the **embeddable Arrow-native FDD runtime** — lint, test, and run rules in your own pipelines (cloud, IoT, notebooks) **without** Docker.

```bash
pip install open-fdd
```

```python
import pyarrow as pa
import pyarrow.compute as pc

from open_fdd.arrow_runtime import run_arrow_rule


def high_sat(table, cfg, context=None):
    return pc.greater(table["SAT"], float(cfg["high"]))


table = pa.table({"SAT": [70.0, 90.0]})

result = run_arrow_rule(high_sat, table, {"high": 85})

print(result.true_count)  # 1
```


---

## Develop

```bash
git clone https://github.com/bbartling/open-fdd.git && cd open-fdd
python -m venv .venv && source .venv/bin/activate
pip install -e ".[test,dev,analytics]"
pytest open_fdd/tests -q
```

Contributor layout: `AGENTS.md` and [developer docs](https://bbartling.github.io/open-fdd/developer/).

---

## License

MIT — see [LICENSE](LICENSE).
