Thank you for your interest in contributing! This guide will help you get started.
cd scripts/
npm install # installs elkjs, bpmn-moddle, jest
npm test # run all tests (136 tests, Jest + ES Modules)node pipeline.js tests/fixtures/simple-approval.json /tmp/test
# outputs: /tmp/test.bpmn + /tmp/test.svgscripts/ Pipeline modules (ES Modules, no CommonJS)
references/ Schema docs, prompt templates, OMG compliance mapping
rules/ Rule engine profiles (default, strict)
tests/fixtures/ Test inputs (JSON Logic-Core) + golden files
docs/ Generated pipeline self-diagram
See README.md for the full module architecture and dependency graph.
- ES Modules —
import/export, norequire() - Pure functions — no global state except
CFG(loaded from config.json) - Minimal dependencies — only
elkjsandbpmn-moddleat runtime - Config over code — visual constants live in
scripts/config.json - XML escaping — always use
esc()fromutils.js - IDs — must match
^[a-zA-Z_][a-zA-Z0-9_-]*$
- Fork the repository and create a feature branch
- Read the relevant module before modifying it
- Run tests after every change:
npm test - Golden files — if your change affects layout or XML output, regenerate:
node pipeline.js ../tests/fixtures/simple-approval.json ../tests/fixtures/simple-approval.expected node pipeline.js ../tests/fixtures/multi-pool-collaboration.json ../tests/fixtures/multi-pool-collaboration.expected node pipeline.js ../tests/fixtures/expanded-subprocess.json ../tests/fixtures/expanded-subprocess.expected
- Submit a PR with a clear description of what changed and why
- Add a rule object to
scripts/rules.js→RULESarray - Fields:
id,layer,defaultSeverity,description,ref,check(proc) checkreturns{ pass: true }or{ pass: false, message: '...' }- Document in
references/fachliches-regelwerk.md - Add test in
pipeline.test.js
types.js— extendbpmnXmlTagmap, add type predicate if neededlayout.js—buildElkNodefor layout dimensionsbpmn-xml.js— XML serializationsvg.js— SVG renderingicons.js— if icon/marker neededimport.js— BPMN XML → Logic-Core parsingreferences/omg-compliance.md— update OMG mappingreferences/input-schema.json— extend schema
- All tests use Jest with ES Modules (
--experimental-vm-modules) - Golden file tests compare generated SVG/BPMN against
.expected.*files - Round-trip tests verify XML → parse → re-serialize produces valid output
- Test fixtures live in
tests/fixtures/
- Use GitHub Issues for bug reports and feature requests
- Include the Logic-Core JSON input that triggers the bug
- Include the generated SVG/BPMN if it's a visual issue
By contributing, you agree that your contributions will be licensed under the MIT License.