Dear all,
I meet several difficulties in creating profile with slicing, and validate resource with slicing profile.
I m creating profile for image annotation, which required to fill the component svg-annotation.
But I keep encountered “the slicing cannot be evaluated” error.
Here is my image annotation SD:
{
"resourceType": "StructureDefinition",
"id": "d10dda59-237b-4683-8cf6-4ee22bf6309d",
"meta": {
"versionId": "8",
"lastUpdated": "2023-03-16T22:56:57.413+08:00",
"source": "#oGBGtqAcVQFVoYBS"
},
"url": "base/StructureDefinition/ImageAnnotationObservation",
"name": "ImageAnnotation",
"title": "ImageAnnotation",
"status": "draft",
"description": "The standard specification for storing image annotation",
"purpose": "The standard specification for storing image annotation",
"fhirVersion": "5.0.0-snapshot1",
"kind": "resource",
"abstract": false,
"type": "Observation",
"baseDefinition": "http://hl7.org/fhir/StructureDefinition/Observation",
"derivation": "constraint",
"differential": {
"element": [ {
"id": "Observation.status",
"path": "Observation.status",
"binding": {
"strength": "required",
"description": "Codes providing the status of an observation annotation.",
"valueSet": "http://hl7.org/fhir/ValueSet/observation-status|5.0.0-cibuild"
}
}, {
"id": "Observation.category",
"path": "Observation.category",
"slicing": {
"discriminator": [ {
"type": "pattern",
"path": "$this"
} ],
"rules": "open"
},
"min": 1,
"max": "1"
}, {
"id": "Observation.category:imaging-category",
"path": "Observation.category",
"sliceName": "imaging-category",
"min": 1,
"max": "1",
"patternCodeableConcept": {
"coding": [ {
"system": "http://terminology.hl7.org/CodeSystem/observation-category",
"code": "imaging",
"display": "Imaging"
} ]
}
}, {
"id": "Observation.code.coding",
"path": "Observation.code.coding",
"min": 1,
"max": "1",
"fixedCoding": {
"system": "cs",
"code": "image.annotation",
"display": "Image annotation"
}
}, {
"id": "Observation.subject",
"path": "Observation.subject",
"min": 1,
"type": [ {
"code": "Reference",
"targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Patient" ]
} ]
}, {
"id": "Observation.effective[x]",
"path": "Observation.effective[x]",
"min": 1,
"type": [ {
"code": "dateTime"
} ]
}, {
"id": "Observation.performer",
"path": "Observation.performer",
"short": "Who is responsible for the observation annotation",
"min": 1,
"max": "1",
"type": [ {
"code": "Reference",
"targetProfile": [ "http://hl7.org/fhir/StructureDefinition/Practitioner", "http://hl7.org/fhir/StructureDefinition/PractitionerRole" ]
} ]
}, {
"id": "Observation.derivedFrom",
"path": "Observation.derivedFrom",
"min": 1,
"max": "1",
"type": [ {
"code": "Reference",
"targetProfile": [ "http://hl7.org/fhir/StructureDefinition/DocumentReference", "http://hl7.org/fhir/StructureDefinition/ImagingStudy" ]
} ]
}, {
"id": "Observation.component",
"path": "Observation.component",
"slicing": {
"discriminator": [ {
"type": "pattern",
"path": "$this"
} ],
"rules": "open"
}
}, {
"id": "Observation.component:svg-annotation",
"path": "Observation.component",
"sliceName": "svg-annotation",
"code": [ {
"system": "https://docs.google.com/spreadsheets/d/1BBBZZbEO82wkvLbHtbpa4ihdFTMoIG0KQGH5bgUoo70/edit#gid=0",
"code": "svg.annotation",
"display": "SVG Annotation"
} ],
"min": 1,
"max": "1"
}, {
"id": "Observation.component:svg-annotation.code",
"path": "Observation.component.code",
"patternCodeableConcept": {
"coding": [ {
"system": "cs",
"code": "svg.annotation",
"display": "SVG Annotation"
} ]
}
}, {
"id": "Observation.component:svg-annotation.value[x]",
"path": "Observation.component.value[x]",
"type": [ {
"code": "Attachment"
} ]
}, {
"id": "Observation.component:svg-annotation.value[x].contentType",
"path": "Observation.component.value[x].contentType",
"min": 1,
"fixedCode": "image/svg+xml"
}, {
"id": "Observation.component:svg-annotation.value[x].data",
"path": "Observation.component.value[x].data",
"min": 1
} ]
}
}
thanks
Best regard,
Jeshika