Stream: BRR - Pharmacy model
Topic: Ingredient
Jose Costa Teixeira (Oct 23 2020 at 22:01):
I'm struggling with Ingredient resource. It seems like sort of a "link" resource, but why is it a resource type?
I'd expect a Product to have an ingredient element (backbone) which contains
- the role
- strength
- pointer to an ingredient (another product, or a substance
But we have an Ingredient resource which contains the role, strenght and a couple of other attributes.
This means that the number of ingredient instances in a server would be between huge and just silly.
Why is this a dedicated resource, one that redefines parts of the substance?
Why not a simpler construct like Medication.ingredient?
Jose Costa Teixeira (Oct 23 2020 at 22:02):
And why does "Ingredient" resource has an "allergenicIndicator" element?
Jose Costa Teixeira (Oct 23 2020 at 22:03):
Am I missing something in the analysis?
Jean Duteau (Oct 23 2020 at 22:04):
there would probably be no instances of Ingredient in a server. I would expect that Ingredient instances would all be contained in their parent resource. NOTE: MedicationKnowledge is probably going to remove their ingredient backbone and replace it with the link to Ingredient.
Rik Smithies (Oct 23 2020 at 22:04):
Because ingredients can be shared.
Jose Costa Teixeira (Oct 23 2020 at 22:05):
Why do we have a resource type that would not be to persist in a server? What is the need behind that?
Jean Duteau (Oct 23 2020 at 22:05):
It's no different than Medication. There will probably not be any Medication instances other than compounds on servers but rather just contained.
Rik Smithies (Oct 23 2020 at 22:05):
Between different aspects of the same product, such as the manufactured form and the administrable form, and between similar products.
Jose Costa Teixeira (Oct 23 2020 at 22:06):
If ingredients can be shared - with the same role, same strenght, same substance? That would mean that the server will keep all possible combinations of these attributes
Rik Smithies (Oct 23 2020 at 22:06):
So, it will be persisted in some use cases.
Rik Smithies (Oct 23 2020 at 22:06):
All ingredient combinations that are needed, can be resources yes.
Rik Smithies (Oct 23 2020 at 22:07):
And re-used where appropriate.
Jose Costa Teixeira (Oct 23 2020 at 22:07):
that is my point - Why such an incredibly big number of resources on a server? What is the reason that it is not a backbone element?
Rik Smithies (Oct 23 2020 at 22:08):
If it was a backbone it would be a larger amount.
Rik Smithies (Oct 23 2020 at 22:08):
And a lot of redundant, repeated data.
Jose Costa Teixeira (Oct 23 2020 at 22:08):
I really don't see why a backbone element would mean more resources.
Rik Smithies (Oct 23 2020 at 22:09):
because the same ingredient is used in multiple places, in multiple products. A backbone element cannot be shared between multiple resources.
Jose Costa Teixeira (Oct 23 2020 at 22:13):
Take Paracetamol which is used in 3 products:
P1. tablet 500 mg,
P2. tablet 1000 mg,
P3. tablet 600 mg mixed with caffeine 150mg.
Total # resources if this were products with a backbone element: 5: P1, P2, P3, Paracetamol, Caffeine.
Total # resources with this as a separate resource: P1, P2, P3, Paracetamol, Caffeine, + (paracetamol 500mg) + (paracetamol 1000 mg) + (paracetamol 600 mg)
Rik Smithies (Oct 23 2020 at 22:13):
Ingredients can also be related to the manufacturing process. You can can list the ingredients used in the steps of manufacturing. The same ingredient that is also found in the finished product, and in other similar products (e.g. all the brands).
Jose Costa Teixeira (Oct 23 2020 at 22:13):
is the above missing something obvious?
Rik Smithies (Oct 23 2020 at 22:14):
Yes.
Rik Smithies (Oct 23 2020 at 22:16):
You are missing the point that there can be multiple brands/types of P1. And as many P1s as exist would have the same Ingredients. And the (various) manufacturing processes of P1 would have the same ingredients. And the manufactured and administrable forms of P1 would have the same ingredients.
Rik Smithies (Oct 23 2020 at 22:18):
And if your main goal is to have the least possible resources, then you can contain Ingredient in all those, and the counts are the same as the backbone case.
Jose Costa Teixeira (Oct 23 2020 at 22:20):
I mentioned P1, did not say it is a brand or generic.
Jose Costa Teixeira (Oct 23 2020 at 22:20):
If that makes a difference, then this is really difficult.
Jose Costa Teixeira (Oct 23 2020 at 22:20):
difficult = complex.
Jose Costa Teixeira (Oct 23 2020 at 22:22):
I think this is a consequence of the base model having one resource for each IDMP level. And because of that, we have to repeat attributes like ingredient. And because of that, we have Ingredients as a link resource.
Rik Smithies (Oct 23 2020 at 22:23):
Whoever mentions them, they do exist. Multiple variants of the same product have the same ingredients. But I am repeating myself. Those are the reasons. Ingredients are shared, and backbone elements cannot be.
Jose Costa Teixeira (Oct 23 2020 at 22:26):
I get the point, and I am giving feedback. This is complicated and I've never seen in prior discussions Ingredient being considered like that. I don't know but I think this makes search more complicated.
Jose Costa Teixeira (Oct 23 2020 at 22:26):
This is a whole new area, and I hope this can be hammered a bit better if we want these resources to be used by people around the world and outside regulatory submission.
Jose Costa Teixeira (Oct 23 2020 at 22:28):
Sorry if I cause noise, I just want to say that something feels strange the way this is working, and I do hope that we're in the phase of collecting fundamental feedback.
Rik Smithies (Oct 23 2020 at 22:31):
Thanks for the feedback Jose. We have the resources and hopefully we can agree to let implementers use them and see if they work well. Are you happy for these to be used at connectathons etc, and to find out if they are fit for purpose?
Jose Costa Teixeira (Oct 23 2020 at 22:32):
Not as they are, no, sorry.
But I do look forward to the discussion we started, because I think we can get them in shape with a few surgical changes. (if I though all is lost, I wouldn't give feedback)
Rik Smithies (Oct 23 2020 at 22:33):
So you don't want implementers to try these?
Jose Costa Teixeira (Oct 23 2020 at 22:35):
I think they could try an improved version of these.
Rik Smithies (Oct 23 2020 at 22:37):
Implementers will be the main source of the improvements. That is the FHIR way. All the pontification counts for little. Implementation experience is what counts.
Jose Costa Teixeira (Oct 23 2020 at 22:46):
Sounds like you're considering al HL7 discussions on this to be over, and you are looking now for external feedback.
Iteration is good, but the first iteration sould be viable.
Hence my opinion: without some internal ironing, I think this is a not a good starting point. I get my opinion may not matter that much, but we could be doing much better.
Rik Smithies (Oct 23 2020 at 22:50):
Jose, you can bring forward any suggestions you want. We welcome any and all specific actionable suggestions, and the benefits. We also want implementers to try these, since they have been around for a while now. They need a release, based on the resources proposed, that they can work with. Implementation work is already happening and we want to get that feedback and use it to change course if necessary.
Jose Costa Teixeira (Oct 23 2020 at 22:54):
Why bring suggestions if they are not considered?
I try to make it simple: I am trying to promote IDMP and Medicinal Product Catalogs. I think we have a few things to change before we go live. I am available for discussing, and I think we can do much better, and we need. I would not present these resources to implementers as they are.
Rik Smithies (Oct 23 2020 at 22:58):
Jose, this is a discussion. We are considering your points right now and giving our views on them. We cannot action sentiments. We can only action suggestions for change that have clear benefits and are agreed by all the workgroup participants. I don't yet know what the changes you want are. Please detail them so we understand.
Jose Costa Teixeira (Oct 23 2020 at 23:07):
My first message plus the Jira I created some time ago.
Rik Smithies (Oct 23 2020 at 23:10):
There is discussion on your Jira I believe. And I am not sure what your first message is. You opened here with a question, which we have tried to answer.
Lloyd McKenzie (Oct 23 2020 at 23:15):
I'm looking at Ingredient and I'm confused. Why is 'substance' 0..1 and strength is 0..*? I would expect you'd have multiple substances in the ingredient, each with a strength, not a single ingredient with multiple strengths?
Rik Smithies (Oct 23 2020 at 23:16):
It's one strength, but the strength can be expressed in multiple ways
Rik Smithies (Oct 23 2020 at 23:17):
Each ingredient is a single substance in an amount (expressed possibly in several ways). So there is only 1 substance per ingredient.
Rik Smithies (Oct 23 2020 at 23:17):
A product has multiple ingredients, each is just one substance.
Lloyd McKenzie (Oct 23 2020 at 23:20):
Can you give an example of how an ingredient, on its own, can have a strength?
Rik Smithies (Oct 23 2020 at 23:21):
The strength is the amount of a substance, in the whole thing, that it is an ingredient of.
Lloyd McKenzie (Oct 23 2020 at 23:21):
That can't be an independent resource
Lloyd McKenzie (Oct 23 2020 at 23:21):
Because that's not stand-alone
Rik Smithies (Oct 23 2020 at 23:21):
I knew you would say that :-)
Lloyd McKenzie (Oct 23 2020 at 23:21):
It could be a data type, but it can't be a resource
Rik Smithies (Oct 23 2020 at 23:22):
But it is a shared thing and datatypes cannot be shared
Lloyd McKenzie (Oct 23 2020 at 23:22):
How can it be shared if it's identifying the amount of a substance in a specific thing - by definition it must be tied to that one specific thing
Rik Smithies (Oct 23 2020 at 23:22):
We don't have the right machinery. Data types don't work here.
Rik Smithies (Oct 23 2020 at 23:22):
No.
Lloyd McKenzie (Oct 23 2020 at 23:23):
Not sure what the 'no' is referring to...
Rik Smithies (Oct 23 2020 at 23:23):
Because several products, that are different, can have the same ingredient/strength. Also, as mentioned earlier in the thread...
Lloyd McKenzie (Oct 23 2020 at 23:23):
Resources must be useful an meaningful completely independently
Rik Smithies (Oct 23 2020 at 23:23):
give me a chance to type :-)
Lloyd McKenzie (Oct 23 2020 at 23:24):
Well, several Medications can have the same ingredients too - but the ingredients are still listed for each Medication instance. If you change the ingredient in one medication, that wouldn't automatically change the ingredients in all of the others
Rik Smithies (Oct 23 2020 at 23:24):
different aspects of the same product express the same ingredients. And things like manufacturing, express the exact same ingredients in protocols etc
Rik Smithies (Oct 23 2020 at 23:25):
We have more sharing than medication. It is true that we could repeat it all. Over and over again. But that is not ideal for implementation.
Lloyd McKenzie (Oct 23 2020 at 23:26):
You can reference the one thing that has the ingredients. The manufacturing aspect, the regulatory aspect, etc. would all point to that one resource that indicates the ingredients
Rik Smithies (Oct 23 2020 at 23:26):
Ingredients for Medication are mainly for special case preparations, so are relatively rare, and not widely shared.
Lloyd McKenzie (Oct 23 2020 at 23:26):
If you've got multiple medications, they can't be shared
Lloyd McKenzie (Oct 23 2020 at 23:27):
If you're talking about the same medication, then define the ingredients in one place.
Rik Smithies (Oct 23 2020 at 23:27):
I meant in the real world they are not shared, so there is no need to share in FHIR
Lloyd McKenzie (Oct 23 2020 at 23:27):
I'm talking in the modeling world. You can't share ingredients across multiple medications
Rik Smithies (Oct 23 2020 at 23:28):
yes I know. For the Medication resource you cannot share. I know that. That is a limitation, but not a severe one for that simpler use case.
Rik Smithies (Oct 23 2020 at 23:29):
well you can share ingredients across medications, because there are lots of medications that have the exact same ingredients yet are different medications.
Lloyd McKenzie (Oct 23 2020 at 23:29):
No - I'm saying for the abstract concept of medication - including in the definitional space - it's inappropriate to share an Ingredient resource across multiple distinct medications just because, right now, multiple medications happen to have the same amount of a given product in them.
Rik Smithies (Oct 23 2020 at 23:30):
Why is it inappropriate? Its a reasonable way to model it. The same data definitely is needed in different places.
Lloyd McKenzie (Oct 23 2020 at 23:31):
You can share substances - which have independent identity. But Ingredient is saying "product X contains Y of Z" - it can't be independent of product X. Because if you say "product X1, X2 and X3 contain Y of Z" and then change the amount of Z in Z1, you're screwed
Rik Smithies (Oct 23 2020 at 23:31):
We don't have a "shared datatype" construct. If we did that would may have been used here.
Lloyd McKenzie (Oct 23 2020 at 23:31):
I'm saying you can't share across meds - you have to repeat
Rik Smithies (Oct 23 2020 at 23:32):
You are missing some points. You don't have to repeat and duplicate.
Lloyd McKenzie (Oct 23 2020 at 23:32):
Just as you can't have an Observation that says "John Doe and Henry Doe both had hemoglobins of X on Jan 1"
Lloyd McKenzie (Oct 23 2020 at 23:33):
How can I update ingredient safely if it's shared by multiple products?
Lloyd McKenzie (Oct 23 2020 at 23:35):
All resources must be designed such that they can function in a purely RESTful world - even if there is no short-term expectations they'll be used that way.
Rik Smithies (Oct 23 2020 at 23:35):
The same product type can have different actual medications, by different manufacturers. They have the same ingredients, by definition. They are all Acetaminophen 200mg. But they have different brands, packaging, contacts, etc. All the same basic formulation however. The excipients may vary. The data is shared.
Rik Smithies (Oct 23 2020 at 23:35):
There is nothing non-RESTful here.
Lloyd McKenzie (Oct 23 2020 at 23:36):
So if you update the ingredient, they all change?
Lloyd McKenzie (Oct 23 2020 at 23:36):
Then why do they need to share? Why aren't the ingredients defined at a single level?
Rik Smithies (Oct 23 2020 at 23:36):
Well you dont generally update the ingredient, unless you change the formulation of all acetaminphen tablets in the world. Which doesnt happen.
Rik Smithies (Oct 23 2020 at 23:37):
Because there are 100s of types of it. And you could copy and paste the ingredients 100 times, but that is redundant.
Lloyd McKenzie (Oct 23 2020 at 23:38):
If something is going to be a resource, it must be independently updateable. It seems like there's a missing level of abstractions - ingredients should be defined at one layer and the specific products should point to the abstract. Then, if you need to correct something about the abstract, you do that.
Rik Smithies (Oct 23 2020 at 23:38):
The same ingredients are referenced in the product formulation and in the steps of the manufacturing. You cannot do that with a data type.
Lloyd McKenzie (Oct 23 2020 at 23:39):
Why?
Rik Smithies (Oct 23 2020 at 23:39):
If there is a better way to model this that fulfils the need then so be it, but data types don't seem to meet the need.
Rik Smithies (Oct 23 2020 at 23:41):
Well I suppose you could express any ingredient as a substance and the amount per other entity. But that is what ingredient is aiming to do.
Rik Smithies (Oct 23 2020 at 23:41):
In a reusable way (which data type would do) and in a sharable way, which data types cannot.
Rik Smithies (Oct 23 2020 at 23:46):
There is a requirement to express the product in a manufactured form and an administrable form. They have the same ingredients. If they are stated as a data type, you would have to repeat them. The list of ingredients can be very long. It includes many inactive substances, coatings, ink, all sorts of things. You don't want to repeat it all. And there is no easy way to "un-fork" the model, so two different resources, or backbone elements, converge on one set of ingredients unless it is a resource.
Rik Smithies (Oct 23 2020 at 23:51):
Audit events are RESTful and they are not updated. So being commonly updated is not a requirement for REST as far as I know.
Rik Smithies (Oct 23 2020 at 23:53):
~ingredients should be defined at one layer and the specific products should point to the abstract.
That is how it is now. This enables that. If there is a another way to achieve it then that might also work.
Lloyd McKenzie (Oct 24 2020 at 01:19):
Why does the administrable form not point to the manufactured form? - specify the ingredients in one place.
Jean Duteau (Oct 24 2020 at 01:20):
ooh, i know the answer to this one! because the ingredients in the administrable form might be different - you might have mixed ingredients in the manufactured item to make a new ingredient
Lloyd McKenzie (Oct 24 2020 at 02:17):
Ok - so if they're not the same, why are we using the same instances to represent them?
Jean Duteau (Oct 24 2020 at 02:18):
they might be the same and they might not be. that's why you can't have one product refer to the other
Lloyd McKenzie (Oct 24 2020 at 02:29):
Right - but you're maintaining separate lists for each - so why the need to create a resource for something that is not independent and that, if it's going to be repeated, is repeated at most twice, and is managed separately besides?
Last updated: Apr 12 2022 at 19:14 UTC