Skip to main content

Processforge

processforge-logo

A lightweight Python framework for process simulation, coupling hydraulic, thermal, and reactor workflows.

Install

Install the pf command-line tool with uv:

uv tool install processforge

For CoolProp-backed units:

uv tool install "processforge[coolprop]"

Optional solver backends:

uv tool install "processforge[eo]"
uv tool install "processforge[eo-casadi]"
uv tool install "processforge[modelica]"

Quick start

  1. Install the tool

    uv tool install processforge
    
  2. Download an example flowsheet

    curl -O https://raw.githubusercontent.com/urjanova/processforge/master/flowsheets/hydraulic-chain.json
    
  3. Initialize, plan, and apply

    pf init flowsheets/hydraulic-chain.json
    pf plan flowsheets/hydraulic-chain.json
    pf apply flowsheets/hydraulic-chain.json
    

    plan validates the flowsheet (schema, DOF, units) without running the solver; apply solves it and stores a snapshot.

  4. Look at the output

    pf apply (and pf run) write a single unified archive under outputs/:

    • outputs/<base>.pfarchive/ — the unified store for a flowsheet's solved state and outputs:
      • snapshots/ — Zarr store of converged state vectors (one group per successful pf apply), each with x/x_delta arrays and config/var-name/metadata attributes, plus a latest pointer (powers warm-start, drift detection, and homotopy).
      • runs/<run_id>.json — the run manifest: every stream and unit engine output (values, units, dtypes, shapes) and run provenance (backend, version, flowsheet hash).
      • outputs/streams/<name>.json — per-stream timeseries from the solve.
      • artifacts.json — content-addressed registry of all output artifacts (local + remote URIs).
      • index.json — field_name → occurrences index for fast cross-run lookups.
      • latest_run — plain-text pointer to the most recent run.
    • outputs/<base>_divergence.json — written only when both direct and homotopy solves fail on pf apply, capturing drifted params, solver stats, and top residual violators.

    For dynamic flowsheets with Tank units, use pf run (not pf apply, which is steady-state EO only) to solve with the dynamic engine.

Python API

Low-level API

from processforge import EOFlowsheet, validate_flowsheet

config = validate_flowsheet("flowsheets/hydraulic-chain.json")
fs = EOFlowsheet(config, backend="scipy")
results = fs.run()

High-level runner (web-app friendly)

from processforge import run_flowsheet

result = run_flowsheet("flowsheets/hydraulic-chain.json")
print(result.run_id, result.status, result.remote_uris)

run_flowsheet and apply_flowsheet perform the full CLI lifecycle (validate, health-check, solve, persist, and upload the pfarchive to S3) and return structured results instead of calling SystemExit. See docs/usage.md for a FastAPI + S3/Railway example.

Usage

See the usage guide for CLI commands and workflows.

Individual providers (e.g. FESTIM, OpenMC) can be run via Docker images using the provider image contract.

Flowsheets

The core of Processforge is the flowsheet JSON format, which defines materials, units, and recycle rules. See below for more information on the formats and example flowsheets.

License

BSD 3-Clause License

Metadata

Release files for processforge 0.6.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for processforge 0.6.6
File Size Uploaded
processforge-0.6.6.tar.gz 257.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for processforge 0.6.6
File Interpreter ABI Platform
processforge-0.6.6-py3-none-any.whl Python 3 none any Details

Total release size: 515.6 kB

Release files / processforge-0.6.6.tar.gz

Download URL processforge-0.6.6.tar.gz
Size 257.7 kB
Tags Source
SHA-256 checksum
How to use checksums
f7cd7889a77300d989dee7a65380f63725def1c5d24a967b546fcddd04a03108
BLAKE2b-256 checksum
How to use checksums
9fa77977f1079b852351312eb1900874437de68ada8ab0f7d8beab73d78f7dc3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.0

Release files / processforge-0.6.6-py3-none-any.whl

Download URL processforge-0.6.6-py3-none-any.whl
Size 257.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
acfe812f86ccce421349670350febded991c172cd71321691a23a7312eab0ad3
BLAKE2b-256 checksum
How to use checksums
61817fd4f971de4f2fe58f640f5f8ae5f6aee55af747b0d0a325fe691064b5ad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.0

Release history Release notifications | RSS feed

This release

0.6.6 This release

2 release files

0.6.5

2 release files

0.6.4

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.0

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.3

2 release files

0.4.1

2 release files

0.3.26

2 release files

0.3.25

2 release files

0.3.23

2 release files

0.3.21

2 release files

0.3.20

2 release files

0.3.19

2 release files

0.3.17

2 release files

0.3.16

2 release files

0.3.15

2 release files

0.3.14

2 release files

0.3.13

2 release files

0.3.12

2 release files

0.3.11

2 release files

0.3.10

2 release files

0.3.9

2 release files

0.3.8

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.2.40

2 release files

0.2.38

2 release files

0.2.34

2 release files

0.2.30

2 release files

0.2.24

2 release files

0.2.22

2 release files

0.2.15

2 release files

0.2.14

2 release files

0.2.13

2 release files

0.2.12

2 release files

0.2.11

2 release files

0.2.10

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page