# New Python openEHR Synthetic Data Generator

**URL:** <https://discourse.openehr.org/t/new-python-openehr-synthetic-data-generator/11796>\
**Category:** Tools\
**Tags:** test-data\
**Created:** [2 March 2026 12:14 UTC](https://discourse.openehr.org/t/new-python-openehr-synthetic-data-generator/11796 "2026-03-02T12:14:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Koray\_Atalag](https://discourse.openehr.org/user_avatar/discourse.openehr.org/koray_atalag/32/70_2.png) [@Koray\_Atalag](https://discourse.openehr.org/u/Koray_Atalag)\
**Post date:** [2 March 2026 12:14 UTC](https://discourse.openehr.org/t/new-python-openehr-synthetic-data-generator/11796/1 "2026-03-02T12:14:06Z")

</div>

Howdy, my weekend hack turned into something I thought might be helpful to others running after test data - heaps of them!

> **[GitHub - atalagk/openEHR-Data-Generator: Fork of Genkidata from Berlin Institute of Health...](https://github.com/atalagk/openEHR-Data-Generator)**
>
> Fork of Genkidata from Berlin Institute of Health to generate synthetic openEHR data

Project started from a fork of Berlin-Institute-of-Health / Genkidata ([https://github.com/Berlin-Institute-of-Health/Genkidata](https://github.com/Berlin-Institute-of-Health/Genkidata)).  
It has significant additions:

- instead of just duplicating existing Compositions, it uses:

- in addition a new feature to create canonical Compositions from Webtemplates (it’s a biggie! and possibly still has errors but it passed all tests from ehrbase SDK test webtemplates using Pablo’s validation tool).

When you run the app, it prompts three options:

1. API Upload (into ehrbase or other CDR)

2. Jitter Existing Compositions (\source\_models\compositions) but rather than just duplicating in the original app it creates new values)

3. Stored (Source Webtemplates)

Existing Compositions are taken from test data from [https://github.com/ehrbase/openEHR\_SDK](https://github.com/ehrbase/openEHR_SDK) so they pretty much cover all possible variations.

The amount of Compositions and EHRs is defined by user input.

Resulting canonical Compositions are saved into:

> /dist/compositions

You can put your own Compositions (to duplicate but with new values) and Webtemplates into:

> /source\_models/compositions
> 
> /source\_models/webtemplates

Enjoy! And comments / tickets / pull requests welcome.
