makoralle provides pydantic models for the German
MaKo (Marktkommunikation) processes together with serializers that turn those
models into the output formats used downstream:
- YAML – process and EBD (Entscheidungsbaum-Diagramm) representations
- WSD – the websequencediagrams DSL for sequence diagrams
- BPMN – business process model XML
- Markdown – human-readable process documentation
It is the shared, dependency-light foundation (only pydantic and PyYAML) consumed by
the private makorele parser and by the process-documentation webapp.
Part of the Hochfrequenz MaKo tooling — four repositories, one responsibility each:
- makoralle (public, PyPI) — the data model + serializers. ← this repo
- makorele (private) — the parser (BDEW PDFs → validated models).
- machine-readable_mako-prozesse (private) — the generated dataset, consumed at a pinned tag.
- mako_prozesse — the web app that presents the dataset.
Dependencies flow one way: makorele → makoralle; the dataset is produced by the tooling and consumed by the web app at a pinned tag. makoralle imports neither the parser nor the app.
pip install makoralleThe public serialization API is exposed at the package root and resolved lazily
(importing makoralle, or a light submodule like makoralle.grouping, does not
eagerly pull in the serialization stack):
from makoralle import emit_yaml, emit_wsd, emit_markdown, emit_bpmn
from makoralle.models.process import Process
# build or load a Process model, then serialize it
yaml_text = emit_yaml(process)
wsd_text = emit_wsd(process.sequence_diagrams[0])The models live under makoralle.models (process, ebd, pid, activity, chunk)
and the serializers under makoralle.serialization.
This project uses the Hochfrequenz src-layout Python template
with tox. To set up a development environment:
tox -e devRun the unit tests, linting, type checks and coverage:
tox -e tests
tox -e linting
tox -e type_check
tox -e coverage