Following our decision to provide a more basic specification of the Simplified Data Template (SDT), I thought I would start at the ‘easy’ end, i.e. data types and various low level RM types. Here is a wiki page that I am starting to populate on this.
One question I thought I would pose is this. For primitive, types, the representation is generally obvious and non-controversial (i.e. it’s the JSON built-in types plus date/times as Strings, and a few extras like URI strings etc).
However for DV types and things like PARTICIPATION etc, we potentially want a parsable structure, in order to avoid the more voluminous standard JSON.
So for example, in the EtherCIS approach that you see here, we have:
- DvCodedText:
"terminology::code|value|"
- DvQuantity:
"78.500,kg"
The Marand Web Template (MWT) uses a different approach of path additions to add to normal paths:
DvCodedText
{
"|code": "238",
"|value": "other care",
"|terminology": "openehr"
}
and
DvQuantity is (I assume) the same kind of thing, i.e.
{
"|magnitude": "78.5",
"|precision": 3,
"|units": "kg"
}
Now, if the aim is to compress some of these types more like the EtherCIS approach, I would propose the following:
- DvCodedText:
"{[terminology::code|value|]}"
- DvQuantity:
"{78.500,kg}"
In both cases, you have a String field - unavoidable, from a JSON point of view. What comes next is {}
, which is intended to say: this is an object, not a primitive value. So, this is how a DvCodedText
would be distinguished from a Terminology_code
(i.e. CodePhrase
), which we consider a primitive - it would just be "[terminology::code|value|]"
(Note: I added the []
that ADL and ODIN uses, because this is an openEHR standard).
This could potentially be used to write short forms of Participation
and so on.
I don’t know if this is a good idea, or even if people want this compressed style of data type serialisation, so just putting it out there.