Metadata-Version: 2.5
Name: dazflow
Version: 0.1.0
Summary: A time-series modelling workflow whose every step returns tables, figures and findings ready for a model document.
Project-URL: Homepage, https://github.com/pedrobtz/py-dazflow
Project-URL: Documentation, https://pedrobtz.github.io/py-dazflow/
Project-URL: Issues, https://github.com/pedrobtz/py-dazflow/issues
Project-URL: Changelog, https://github.com/pedrobtz/py-dazflow/blob/main/CHANGELOG.md
Author-email: pedrobtz <pedrobtz@gmail.com>
License-Expression: MIT
License-File: LICENSE
Keywords: econometrics,forecasting,model documentation,stress testing,time series
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Financial and Insurance Industry
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Office/Business :: Financial
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Mathematics
Classifier: Typing :: Typed
Requires-Python: >=3.12
Requires-Dist: arch>=7.0
Requires-Dist: great-tables>=0.17
Requires-Dist: jinja2>=3.1.4
Requires-Dist: matplotlib>=3.8.4
Requires-Dist: narwhals>=2.8
Requires-Dist: numpy>=1.26.4
Requires-Dist: pandas>=2.2.2
Requires-Dist: pointblank>=0.13
Requires-Dist: pydantic>=2.8
Requires-Dist: python-docx>=1.1.2
Requires-Dist: pyyaml>=6.0.1
Requires-Dist: rich>=13.8
Requires-Dist: scipy>=1.13
Requires-Dist: statsmodels>=0.14.2
Requires-Dist: typer>=0.26.0
Provides-Extra: io
Requires-Dist: openpyxl>=3.1.3; extra == 'io'
Requires-Dist: polars>=1.0; extra == 'io'
Requires-Dist: pyarrow>=16; extra == 'io'
Description-Content-Type: text/markdown

# dazflow

[![CI](https://github.com/pedrobtz/py-dazflow/actions/workflows/ci.yml/badge.svg)](https://github.com/pedrobtz/py-dazflow/actions/workflows/ci.yml)
[![Docs](https://github.com/pedrobtz/py-dazflow/actions/workflows/docs.yml/badge.svg)](https://pedrobtz.github.io/py-dazflow/)
[![PyPI](https://img.shields.io/pypi/v/dazflow)](https://pypi.org/project/dazflow/)

`dazflow` is a Python library and command-line tool for the workflow around
a time-series model: import, clean, explore, build candidates, select,
forecast, diagnose and report. Each step returns its numbers together with
tables, figures and findings ready for a model document. Documentation:
<https://pedrobtz.github.io/py-dazflow/>.

- **Steps from configuration.** A project folder holds one YAML file per
  step, with every setting written out at its default.
- **Gates, never hidden.** Every step ends in checks against configured
  thresholds; a failed check stops the run unless an override with a reason
  accepts it.
- **Artefacts with stable identifiers.** Tables and figures (`T3.3`,
  `F3.1`) render in one house style to Markdown, HTML, SVG and Word.
- **A run record and a replay.** Every run writes a record of its
  configuration, inputs, environment and results; `dazflow replay` reruns
  it and compares.
- **Plugins.** Model forms, checks, transforms, readers and steps register
  under a key, by decorator or through the `dazflow.plugins` entry point.

The statistics come from statsmodels, arch, scipy and their peers; `dazflow`
adds the shared data object, configuration, gates, record and rendering.

## Installation

From [PyPI](https://pypi.org/project/dazflow/):

```sh
pip install dazflow
```

It needs Python 3.12 or later. The `io` extra adds the Excel and Parquet
readers and polars or pyarrow input:

```sh
pip install "dazflow[io]"
```

The development version installs from GitHub:
`pip install git+https://github.com/pedrobtz/py-dazflow`.

## A first run

```sh
dazflow init loss-rate      # a project folder with example data
cd loss-rate
dazflow validate            # configuration and inputs, without running a step
dazflow run                 # ingest through report; exit 2 if a gate fails
dazflow show T3.3           # one table of the last run
dazflow replay              # rerun from reports/record.json and compare
```

The same from Python:

```python
import dazflow as dz

project = dz.project.load("loss-rate")
run = project.run()  # in memory; writes nothing
record = project.write(run)  # reports/, data/, reports/record.json
project.replay().passed
```

[Get started](https://pedrobtz.github.io/py-dazflow/user-guide/get-started.html)
walks through the example; the
[reference](https://pedrobtz.github.io/py-dazflow/reference/) lists every
public name.

## Status

0.1.0 is the first release; the interface may still change before 1.0.
Changes are listed in
[`CHANGELOG.md`](https://github.com/pedrobtz/py-dazflow/blob/main/CHANGELOG.md).
The design is in
[`.agents/design.md`](https://github.com/pedrobtz/py-dazflow/blob/main/.agents/design.md)
and the order of work in
[`.agents/roadmap.md`](https://github.com/pedrobtz/py-dazflow/blob/main/.agents/roadmap.md).

## License

MIT
