FHIR Chat · Progress · CCDA / FHIR mapping stream

Stream: CCDA / FHIR mapping stream

Topic: Progress


view this post on Zulip Grahame Grieve (May 20 2018 at 21:58):

@Jean Duteau I'm home and recovering from the WGM, and actually working now.... where are we with this?

view this post on Zulip Jean Duteau (May 20 2018 at 22:13):

The most important things are:
1) CDA.Narrative to/from FHIR.xhtml
2) ConceptMap translations - could be my syntax
3) getting my source where condition clauses working right

For #3, see above where I give you my mapping that isn't working
For #2, you think I'm using them the "wrong way around", so I'd need to know what I'm doing wrong
And #1 needs to be done but I'm now not sure that it should be done in code.

view this post on Zulip Grahame Grieve (May 20 2018 at 22:17):

#1 - ok why not in code?

view this post on Zulip Grahame Grieve (May 20 2018 at 22:17):

#2 - the translations are unidirectional - from FHIR to CDA. but you're invoking them as if they are from CDA to FHIR

view this post on Zulip Grahame Grieve (May 20 2018 at 22:18):

#3 - the conditions work for me but they have to start with a variable name

view this post on Zulip Jean Duteau (May 20 2018 at 22:23):

okay, for #2 - I guess we (and when I say we, I probably mean my team) need to create the CDA->FHIR mappings?

view this post on Zulip Jean Duteau (May 20 2018 at 22:23):

#3 - I do have variable names. see above to see what I've done

view this post on Zulip Grahame Grieve (May 20 2018 at 22:24):

#2 yes, for now. guess we should normalise this into the spec?

view this post on Zulip Jean Duteau (May 20 2018 at 22:26):

#1 - the mapping language and the maps are, right now, tool agnostic. anyone can potentially write a mapping engine and then execute any maps. that seems to me to argue that all maps should be done via map files and not be built-in to any tool. basically, if you write the narrative text transform into the validator code, then anyone else who wants to build a mapping engine is going to have to replicate that code in their engine.

view this post on Zulip Jean Duteau (May 20 2018 at 22:27):

thus whatever you write in code needs to be totally documented so that others can replicate it. wouldn't the best way to document that be via a mapping file?

view this post on Zulip Grahame Grieve (May 21 2018 at 21:12):

well, it would sure be the most comprehensive mapping. but is is the most effective? That I'm not sure about. Here's what we have for mapping at the moment:

view this post on Zulip Grahame Grieve (May 21 2018 at 21:13):

http://wiki.hl7.org/index.php?title=CDA_Narrative_to_html_mapping

view this post on Zulip Jean Duteau (May 21 2018 at 22:55):

i would hope that others would chime in on this.

view this post on Zulip Grahame Grieve (May 21 2018 at 22:56):

@Rick Geimer volunteered to look at it.

view this post on Zulip Jean Duteau (May 21 2018 at 22:59):

i looked at it and updated it a bit. it's not the mapping itself but rather whether this should be done in code or external that I'd love more than you and I to decide.

view this post on Zulip Grahame Grieve (May 22 2018 at 12:14):

thinking more about it... the problem with doing it in the mapping is that then I have to work up models for both xhtml and Struc.TExt

view this post on Zulip Grahame Grieve (May 22 2018 at 12:39):

that sounds like a heavy lift and is outside what I expected to do in the short term

view this post on Zulip Grahame Grieve (May 22 2018 at 16:46):

https://build.fhir.org/ig/HL7/fhir-cda/

view this post on Zulip Jean Duteau (May 22 2018 at 16:56):

that's nice.

view this post on Zulip Grahame Grieve (May 22 2018 at 17:38):

could be made very nice if someone wanted to. e.g. could replace the existing CDA guide - start with the RMIM and all. Just a matter of how much someone wants to invest

view this post on Zulip Jean Duteau (May 30 2018 at 04:38):

And any progress on Narrative <-> XHTML?

view this post on Zulip Grahame Grieve (Jun 04 2018 at 08:13):

so looking at the wiki page...

view this post on Zulip Grahame Grieve (Jun 04 2018 at 08:13):

what

view this post on Zulip Grahame Grieve (Jun 04 2018 at 08:13):

what's the right thing to happen with referencedObject?

view this post on Zulip Grahame Grieve (Jun 05 2018 at 00:47):

hey Jean - one of your test documents has this in it:

view this post on Zulip Grahame Grieve (Jun 05 2018 at 00:47):

                        <substanceAdministration classCode="SBADM" moodCode="INT">
                            <templateId root="2.16.840.1.113883.10.20.22.4.16"/>
                            <id root="a0e312da-2007-4f4b-b8ed-3973e93b948d"/>
                            <text>
                                <reference value="#medication920000875889"/>
                            </text>
                            <comments>
                                <reference value="#medcommentsmedication920000875889"/>
                            </comments>

view this post on Zulip Grahame Grieve (Jun 05 2018 at 00:47):

I don't recognise the comments element?

view this post on Zulip Grahame Grieve (Jun 05 2018 at 00:50):

.. I'm doing round trip testing on the CDA documents...

view this post on Zulip Grahame Grieve (Jun 05 2018 at 03:51):

ok. committed. Round-tripping CDA -> logical model -> CDA looks good to me (attributes get re-ordered, of course, but everything is preserved that is valid CDA). That means that CDA narrative will not map correctly.

view this post on Zulip Grahame Grieve (Jun 05 2018 at 03:52):

the way the FHIR framework works, doing the mapping by the mapping language is actually very difficult; it's not about the mapping language, but about the way StructureDefinition has been set up to handle CDA narrative - we effectively already decided that it would be converted by magic.

view this post on Zulip Grahame Grieve (Jun 05 2018 at 03:53):

but the code is actually pretty simple, since there's no context to carry around (yet!):

view this post on Zulip Grahame Grieve (Jun 05 2018 at 03:58):

https://gforge.hl7.org/svn/fhir/trunk/build/implementations/java/org.hl7.fhir.utilities/src/org/hl7/fhir/utilities/xhtml/CDANarrativeFormat.java

view this post on Zulip Grahame Grieve (Jun 05 2018 at 04:48):

by product of testing out the CDA round-tripping: CDA in Json....

view this post on Zulip Grahame Grieve (Jun 05 2018 at 04:49):

testdocuments.zip

view this post on Zulip Grahame Grieve (Jun 05 2018 at 04:55):

what is this?

              <doseQuantity/>
              <doseQuantity unit="Tablet(s)" value="1"/>
              <doseQuantity unit="MG" value="300-30"/>

view this post on Zulip Grahame Grieve (Jun 05 2018 at 04:56):

in what world is that valid?

view this post on Zulip Grahame Grieve (Jun 05 2018 at 05:03):

we can have RDF CDA documents too ;-)

view this post on Zulip Grahame Grieve (Jun 05 2018 at 05:03):

testdocuments.zip

view this post on Zulip Grahame Grieve (Jun 05 2018 at 05:04):

though the only thing that shows is that RDf is pretty much the worst way to say anything useful

view this post on Zulip Grahame Grieve (Jun 06 2018 at 05:01):

btw, the CDA Implementation guide - as opposed to the CCDA on FHIR implementation guide... needs some love. We kind of need to figure out how far we want to take it... if we really wanted to, it could replace the CDA spec (R2.1, I guess....) . We probably don't want to... but we need to base artifact, so we need to decided how much to do with it


Last updated: Apr 12 2022 at 19:14 UTC