FHIR Chat · Translation extension vs designation · implementers

Stream: implementers

Topic: Translation extension vs designation


view this post on Zulip Jing Tang (Jun 14 2021 at 12:11):

Code system and value sets have the designation field, which can be used to provide alternative representations in other languages. Does it not overlap with translation extension? See 7.15.3 and 7.15.4 in https://www.hl7.org/fhir/languages.html. For a code system or value set, should we then respect both the translation extension and the designation? What happens if there's a conflict? Thanks!

view this post on Zulip Grahame Grieve (Jun 14 2021 at 12:16):

designation is preferred, but they won't conflict- extensions are just additive designations with implied use = display

view this post on Zulip Patrick (Jun 15 2021 at 16:03):

Grahame Grieve said:

designation is preferred, but they won't conflict- extensions are just additive designations with implied use = display

I am not sure if I am allowed to reply here. But actually I am trying to figure out how to implement translation for ActivityDefinition and reading about the options. Where would designation be described and is there any example on how to work with the translation extension?

view this post on Zulip Grahame Grieve (Jun 15 2021 at 21:25):

You are indeed allowed to reply here. Ddesignation is a feature of the CodeSystem resource, not an ActivityDefinition. There's an example of the translation extension here: http://hl7.org/fhir/languages.html##ext

view this post on Zulip Patrick Palacin (Jun 16 2021 at 11:52):

Hi @Grahame Grieve thanks. I checked the example, but how does it know what I want to translate? I don't get how the server makes the link at the end

view this post on Zulip Grahame Grieve (Jun 16 2021 at 11:55):

the link with what?

view this post on Zulip Patrick Palacin (Jun 16 2021 at 12:32):

With the activity resource. I tried it like that: https://paste.ubuntu.com/p/TSwrszDRYp/ , but maybe I understood the docs wrong how it works? When I call it with GET and header Accept-Language: de-DE it still returns the english title :/
Shouldnt it be similar to the citizenship extension in patient?

view this post on Zulip Patrick Palacin (Jun 16 2021 at 13:13):

@Grahame Grieve Do I maybe need to do it like that? "_title":
{
"url": "http://hl7.org/fhir/StructureDefinition/translation",
"extension": [
{
"url": "lang",
"valueCode": "de"
},
{
"url": "title",
"valueString": "Warum Fisch das Grünzeug schlägt"
}
],
"value": "Why Fish is better than Veggie"
}
,

view this post on Zulip Grahame Grieve (Jun 16 2021 at 13:17):

probably the server doesn't perform translation based on the accept-language. That's a todo for me on test.fhir.org

view this post on Zulip Patrick Palacin (Jun 16 2021 at 13:19):

But do I do it right? I want make sure before reporting to James. I am using HAPI under the hood and according to what I found in the code it should pay respect to the header :/

view this post on Zulip Grahame Grieve (Jun 16 2021 at 13:22):

oh. you need to put the extension on the title itself not just in the resource

view this post on Zulip Patrick Palacin (Jun 16 2021 at 13:24):

ok wait, so my second request? Wait I can add it to pastebin for u

view this post on Zulip Patrick Palacin (Jun 16 2021 at 13:29):

Here we go: https://paste.ubuntu.com/p/ZGxR64FnHh/

view this post on Zulip Patrick Palacin (Jun 16 2021 at 13:29):

but it still doesnt work with it, and now I even miss the english title

view this post on Zulip Patrick Palacin (Jun 16 2021 at 14:40):

@Grahame Grieve any idea? I just checked the old way but it doesnt accept it. However I like it: http://hl7.org/implement/standards/fhir/2015Jan/extensiondefinition-example-translation.html :)

view this post on Zulip Patrick Palacin (Jun 16 2021 at 14:56):

Tried it with XML as well... same result :( https://paste.ubuntu.com/p/y6Cj3FyTnX/

view this post on Zulip Grahame Grieve (Jun 16 2021 at 19:57):

the last one is correct - the extension is in the right place

view this post on Zulip Patrick Palacin (Jun 16 2021 at 21:18):

Yeah but unfortunately it doesn't work in combination with the HTTP-header. Maybe @James Agnew has an idea what is going on. Code seems fine to me :/

view this post on Zulip Lloyd McKenzie (Jun 25 2021 at 21:55):

@Patrick Palacin - you may be interested in a discussion we're having on the Questionnaire stream about an alternative approach to managing translations that we plan to trial with Questionnaire but hopefully pull into R5 for use with other canonical resources such as ActivityDefinition. (Could theoretically be pre-adopted in R4 too.)
https://chat.fhir.org/#narrow/stream/179255-questionnaire/topic/multi-language.20questionnaires


Last updated: Apr 12 2022 at 19:14 UTC