Process of creating an openEHR system

Hello Forum , I am very new to openEHR and from my understanding to create a openEHR based website from collection patient data I have created a few steps to follow , but I am not able to understand if this is accurate and I am not able to move beyond it.
Please correct me if I am wrong and suggest steps after the ones I have listed

Step 1 : Create template from achetypes using Archetype Designer
Step 2 : Upload that template to an EHRbase server
Step 3 : Convert the template to a HTML Form and create a website
Step 4 : Upload a EHR without any body in EHRbase by the ehr_id
Step 5 : Upload a composition (I am not clear as to what I have to do here and after here)

PLease suggest sources to learn from if you can
Thank You

1 Like

Hi, this article will give you some hints CaboLabs Blog - How to work with an openEHR Clinical Data Repository - step by step

@pablo Thank You Dear sir , I have but one query , does the same logic apply with ehrbase ?

Hi,

I recommend to check the videos from @Sidharth_Ramesh:

I will later also post a postman library here that will provide you with some example payload data for posting compositions in canonical and flat formats.

Please also take a look at the Software Development Kit with many examples how to create instance data using a Java client:

1 Like

Thank You @birger.haarbrandt I did follow this guide but it covers till setup of EHRbase and posting of template as of now. I wanted to kknow the steps after that.

Do you have concrete issues setting up Medblocks or the Software Development Kit? I would advise you to use of these two to get started.

The conceptual steps should apply to any openEHR CDR. Some might differ depending on the vendor.

Hey @Yash, I’m actually releasing the next video for creating compositions this week. I’m currently doing some research on all the possible methods to create an openEHR composition. I’d like to ask community members also to add to my list if I’ve missed any:

  1. Example endpoint from Better CDR/EHR.DB (paid)
  2. Example composition using - https://toolkit.cabolabs.com/ (works with EHRServer. No canonical JSON in free version. Correct me if wrong @pablo)
  3. Using EHRbase SDK
  4. VScode extension by Nedap (awaiting confirmation from @pieterbos)
  5. Medblocks UI

Also, my team has actually taken a look at your template. We’ve created a working UI for you (except for some RM types in the template that haven’t been implemented by Medblocks UI).

3 Likes

Thank You @Sidharth_Ramesh , looking forward to learning more from your channel
Cheers !!

Is your template publicly available @Yash ?

It is , Yes
I will link it here : Open EHR – Google Drive

1 Like

Hey people! Can someone fact check this and point out any errors?

Hi @Sidharth_Ramesh the toolkit has generation for the canonical JSON, though the new version wasn’t deployed yet. Though that is included in the open source CLI tool GitHub - ppazos/openEHR-OPT: Java/Groovy Support of openEHR Operational Templates, Refernce Model,

Hi @Sidharth_Ramesh the EHRServer canonical JSON support is implemented though it is not merged yet, needs more testing, but will be there in a couple of weeks or so.

About the EHRServer JSON, it is just a canonical transformation from the canonical XML to JSON (each XML element and attribute is just converted into JSON, IIRC uses XStream - Two Minute Tutorial).

The FLAT JSON is a format from Marand AFAIK. It was ported to EHRbase but I think there are some differences that the team is working on, in fact I was creating some tests for that for EHRbase at HiGHmed. I don’t know if that implementation was ported back to EtherCIS, maybe @ian.mcnicoll or @christian can confirm.

What I do confirm is EHRServer doesn’t have plans to support formats that are not canonical or well specified. Maybe when Marand’s FLAT becomes an openEHR spec, we will consider to add support for it.

Another format that we want to support is OPT is JSON, which I think can benefit implementations, since JSON is kind of default on REST APIs, it is annoying to work all data in JSON then OPTs in XML. Something similar would apply to for systems that work with archetypes, instead of working with ADL/XML we would support archetypes in JSON.

Good chart, thanks for sharing.

Thanks for the input! Yup, I’ve already built out your openEHR-OPT groovy code, and it seems to be generating both canonical XML and JSON correctly. The UI generation is also really cool.

So, okay. Canonical JSON planned for EHRServer as well as the toolkit. Got it.

Regarding Marand’s FLAT in EtherCIS, I was going based on the documentation here. Seems to support the format. Will also wait for @christian to confirm. (Although the video is going up tomorrow :crossed_fingers:)

JSON Templates will be really cool. I’ve always used web templates wherever I can anyway, because of how tedious it is to work with XML on the front-end.

Also, the openEHR-OPT seems to fail with this massive demon of a template - it’s an Encounter that includes the Demo archetype without constraining any elements :sweat_smile:
Demo Encounter.opt (263.7 KB).

But most other real-world templates were working just fine!

Short note: in EHRbase/SDK, we directly follow the flat implementation as it was introduced by Better. It is very much aligned as we are using their integration tests and we aim to be a compatible as possible.

EtherCIS used a pre-built lib from Marand/Better for the flat format whereas EHRbase has its own open source implementation. This being said, I’m quite sure there won’t be any updates on EtherCIS as EHRbase can be considered EtherCIS 2.0. We will eventually also support the Structured Format.

1 Like

Can you paste the error for that template?

It was a super long error, so I just piped it out to this file (.txt upload is not supported in the forum @thomas.beale?)

logs.md (48.6 KB)

Alright. Video is up:

I’ll cover openEHR-OPT by @pablo and EHRbase SDK in the coming few videos.

4 Likes

Seems a missing lowerUnbounded on an interval?

Exception in thread "main" java.lang.NullPointerException: Cannot get property 'lowerUnbounded' on null object
	at org.codehaus.groovy.runtime.NullObject.getProperty(NullObject.java:60)
	at org.codehaus.groovy.runtime.InvokerHelper.getProperty(InvokerHelper.java:194)
	at org.codehaus.groovy.runtime.callsite.NullCallSite.getProperty(NullCallSite.java:46)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGetProperty(AbstractCallSite.java:329)
	at com.cabolabs.openehr.opt.instance_generator.XmlInstanceGenerator$_generate_DV_INTERVAL__DV_QUANTITY_closure71$_closure177.doCall(XmlInstanceGenerator.groovy:1756