hgraph


Namehgraph JSON
Version 0.4.69 PyPI version JSON
download
home_pageNone
SummaryA functional reactive platform used to process time-series streams. Provides support for backtest (simulation) and realtime time-series processing. Using a forward propagation graph with a microtask scheduler for the runtime engine.
upload_time2025-07-15 05:46:38
maintainerNone
docs_urlNone
authorNone
requires_python>=3.11
licenseMIT
keywords forward propogating graph fpg frp functional functional reactive programming graph reactive time series time-series
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage
            # hgraph
A functional reactive programming engine with a Python front-end.

This provides a DSL and runtime to support the computation of results over time, featuring
a graph based directed acyclic dependency graph and the concept of time-series properties.
The language is function-based, and promotes composition to extend behaviour.

Here is a simple example:

```python
from hgraph import graph, run_graph, const
from hgraph.nodes import debug_print

@graph
def main():
    a = const(1)
    c = a + 2
    debug_print("a + 2", c)

run_graph(main)
```
Results in:
```
[1970-01-01 00:00:00.000385][1970-01-01 00:00:00.000001] a + 2: 3
```

See [this](https://hgraph.readthedocs.io/en/latest/) for more information.

## Development

The project is currently configured to make use of [uv](https://github.com/astral-sh/uv) for dependency management. 
Take a look at the website to see how best to install the tool.

Here are some useful commands:

First, create a virtual environment in the project directory:

```bash
uv venv
```

Then use the following command to install the project and its dependencies:

```bash
# Install the project with all dependencies
uv pip install -e .

# Install with optional dependencies
uv pip install -e ".[docs,web,notebook]"

# Install with all optional dependencies
uv pip install -e ".[docs,web,notebook,test]"
```

PyCharm can make use of the virtual environment created by uv to ``setup`` the project.

### Run Tests

```bash
# No Coverage
python -m pytest
```

```bash
# Generate Coverage Report
python -m pytest --cov=hgraph --cov-report=xml
```

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "hgraph",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.11",
    "maintainer_email": null,
    "keywords": "forward propogating graph, fpg, frp, functional, functional reactive programming, graph, reactive, time series, time-series",
    "author": null,
    "author_email": "Howard Henson <howard@henson.me.uk>, Alexander Balabin <balabin@me.com>, Simon Young <whepstead@gmail.com>, Tope Olukemi <tolukemi@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/03/c4/1750414e364c669c684cce2243a6c7656d94914451ddbe770c740b93b8fe/hgraph-0.4.69.tar.gz",
    "platform": null,
    "description": "# hgraph\nA functional reactive programming engine with a Python front-end.\n\nThis provides a DSL and runtime to support the computation of results over time, featuring\na graph based directed acyclic dependency graph and the concept of time-series properties.\nThe language is function-based, and promotes composition to extend behaviour.\n\nHere is a simple example:\n\n```python\nfrom hgraph import graph, run_graph, const\nfrom hgraph.nodes import debug_print\n\n@graph\ndef main():\n    a = const(1)\n    c = a + 2\n    debug_print(\"a + 2\", c)\n\nrun_graph(main)\n```\nResults in:\n```\n[1970-01-01 00:00:00.000385][1970-01-01 00:00:00.000001] a + 2: 3\n```\n\nSee [this](https://hgraph.readthedocs.io/en/latest/) for more information.\n\n## Development\n\nThe project is currently configured to make use of [uv](https://github.com/astral-sh/uv) for dependency management. \nTake a look at the website to see how best to install the tool.\n\nHere are some useful commands:\n\nFirst, create a virtual environment in the project directory:\n\n```bash\nuv venv\n```\n\nThen use the following command to install the project and its dependencies:\n\n```bash\n# Install the project with all dependencies\nuv pip install -e .\n\n# Install with optional dependencies\nuv pip install -e \".[docs,web,notebook]\"\n\n# Install with all optional dependencies\nuv pip install -e \".[docs,web,notebook,test]\"\n```\n\nPyCharm can make use of the virtual environment created by uv to ``setup`` the project.\n\n### Run Tests\n\n```bash\n# No Coverage\npython -m pytest\n```\n\n```bash\n# Generate Coverage Report\npython -m pytest --cov=hgraph --cov-report=xml\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A functional reactive platform used to process time-series streams. Provides support for backtest (simulation) and realtime time-series processing. Using a forward propagation graph with a microtask scheduler for the runtime engine.",
    "version": "0.4.69",
    "project_urls": {
        "Changelog": "https://github.com/hhenson/hgraph/blob/main/CHANGELOG.md",
        "Documentation": "https://github.com/hhenson/hgraph/blob/main/docs/index.md",
        "Homepage": "https://github.com/hhenson/hgraph",
        "Issues": "https://github.com/hhenson/hgraph/blob/main/ISSUES.md",
        "Repository": "https://github.com/hhenson/hgraph.git"
    },
    "split_keywords": [
        "forward propogating graph",
        " fpg",
        " frp",
        " functional",
        " functional reactive programming",
        " graph",
        " reactive",
        " time series",
        " time-series"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "9298fd54a4d0e157e186199cd77d667b1e6c272ad50e553237ec13278c303e7c",
                "md5": "9fde91f25b46fb37bdabfbeb2dc5266a",
                "sha256": "1d1c7d34ae371d476d3a9d3aff77ab7d59bc780c79473cc44e0083ca086d179a"
            },
            "downloads": -1,
            "filename": "hgraph-0.4.69-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "9fde91f25b46fb37bdabfbeb2dc5266a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.11",
            "size": 530760,
            "upload_time": "2025-07-15T05:46:35",
            "upload_time_iso_8601": "2025-07-15T05:46:35.924253Z",
            "url": "https://files.pythonhosted.org/packages/92/98/fd54a4d0e157e186199cd77d667b1e6c272ad50e553237ec13278c303e7c/hgraph-0.4.69-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "03c41750414e364c669c684cce2243a6c7656d94914451ddbe770c740b93b8fe",
                "md5": "23ca9081aa247018b50cc74c5d9ae179",
                "sha256": "2ed3c692caff734831492553fcdec0852b732fc9c9a7bcb1f10183d2be9959bb"
            },
            "downloads": -1,
            "filename": "hgraph-0.4.69.tar.gz",
            "has_sig": false,
            "md5_digest": "23ca9081aa247018b50cc74c5d9ae179",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.11",
            "size": 810816,
            "upload_time": "2025-07-15T05:46:38",
            "upload_time_iso_8601": "2025-07-15T05:46:38.251692Z",
            "url": "https://files.pythonhosted.org/packages/03/c4/1750414e364c669c684cce2243a6c7656d94914451ddbe770c740b93b8fe/hgraph-0.4.69.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-15 05:46:38",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "hhenson",
    "github_project": "hgraph",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": true,
    "lcname": "hgraph"
}
        
Elapsed time: 1.05055s