{"name": "lab-hepatitis-b-surface-antigen-coded", "comment": "A laboratory Observation whose value is coded: the LOINC answer as a code IRI and its text as the value's text; the local code is a finding.", "input": {"file": "fixtures/in/lab-hepatitis-b-surface-antigen-coded.json", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/in/lab-hepatitis-b-surface-antigen-coded.json", "text": "{\n  \"resourceType\": \"Observation\",\n  \"id\": \"obs-hbsag-1\",\n  \"status\": \"final\",\n  \"category\": [\n    {\n      \"coding\": [\n        {\n          \"system\": \"http://terminology.hl7.org/CodeSystem/observation-category\",\n          \"code\": \"laboratory\"\n        }\n      ]\n    }\n  ],\n  \"code\": {\n    \"coding\": [\n      {\n        \"system\": \"http://loinc.org\",\n        \"code\": \"5196-1\",\n        \"display\": \"Hepatitis B virus surface Ag [Presence] in Serum or Plasma by Immunoassay\"\n      }\n    ],\n    \"text\": \"Hepatitis B surface antigen\"\n  },\n  \"subject\": {\n    \"reference\": \"Patient/pat-conformance-1\"\n  },\n  \"effectiveDateTime\": \"2026-08-03T09:25:00Z\",\n  \"valueCodeableConcept\": {\n    \"coding\": [\n      {\n        \"system\": \"http://loinc.org\",\n        \"code\": \"LA6577-6\",\n        \"display\": \"Negative\"\n      },\n      {\n        \"system\": \"http://lab.meridian.example/answers\",\n        \"code\": \"NEG\"\n      }\n    ],\n    \"text\": \"Negative\"\n  }\n}\n"}, "expectedGraph": {"file": "fixtures/expected/lab-hepatitis-b-surface-antigen-coded.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/expected/lab-hepatitis-b-surface-antigen-coded.ttl", "text": "@prefix bridge: <https://ns.cascadeprotocol.org/bridge/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix cascade: <https://ns.cascadeprotocol.org/cascade#> .\n@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .\n@prefix prov: <http://www.w3.org/ns/prov#> .\n@prefix dct: <http://purl.org/dc/terms/> .\n@prefix dcterms: <http://purl.org/dc/terms/> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n@prefix pav: <http://purl.org/pav/> .\n<ni:///sha-256;KZHCBzJZZAVet8sZHKqe1p4uqsyJPzOzLf29wdRXLJo> cascade:testCode <http://loinc.org/rdf/5196-1> ;\n\tcascade:testName \"Hepatitis B surface antigen\" ;\n\tcascade:resultValueKind cascade:CodedResultValue ;\n\tcascade:resultValueText \"Negative\" ;\n\tcascade:resultValueCode <http://loinc.org/rdf/LA6577-6> ;\n\tcascade:resultClinicallyRelevantTime \"2026-08-03T09:25:00Z\"^^xsd:dateTime ;\n\tcascade:workflowStatus \"final\" .\n<urn:uuid:08ac15f0-c3b0-8837-a45c-b4df0a59eea9> a cascade:LaboratoryTestResult ;\n\tcascade:sourceUrl <https://fhir.meridian.example/api/FHIR/R4/Observation/obs-hbsag-1> ;\n\tcascade:sourceRecordId \"obs-hbsag-1\" .\n<ni:///sha-256;KZHCBzJZZAVet8sZHKqe1p4uqsyJPzOzLf29wdRXLJo> prov:specializationOf <urn:uuid:08ac15f0-c3b0-8837-a45c-b4df0a59eea9> ;\n\tcascade:patient <urn:uuid:7883c5a4-6c61-837c-9bf7-dbe1b37d89ff> .\n_:7d1437cb46f880f55e861d2ae82e2597 bridge:arrivedAs <ni:///sha-256;KZHCBzJZZAVet8sZHKqe1p4uqsyJPzOzLf29wdRXLJo> ;\n\toa:hasSelector _:9d69f387badd5be03e303abfcd3628e6 ;\n\toa:hasSource <ni:///sha-256;KotTT_MLS-yFk2ZpMmJnurV5cJBwk0sHUYJIrWIdRhY> ;\n\tprov:wasDerivedFrom <ni:///sha-256;KotTT_MLS-yFk2ZpMmJnurV5cJBwk0sHUYJIrWIdRhY> ;\n\tprov:wasGeneratedBy _:866104d6ba15a31ee5659c777ee89e1f .\n_:9d69f387badd5be03e303abfcd3628e6 a oa:FragmentSelector ;\n\tdct:conformsTo <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"\" .\n<ni:///sha-256;KotTT_MLS-yFk2ZpMmJnurV5cJBwk0sHUYJIrWIdRhY> cascade:serverBaseUrl \"https://fhir.meridian.example/api/FHIR/R4\" ;\n\tpav:retrievedOn \"2026-09-01T10:00:00Z\"^^xsd:dateTime ;\n\tprov:wasGeneratedBy _:bd91136ee02d481a369f5cc74b96eb58 ;\n\tprov:wasAttributedTo _:8d417f0f0f2aaa6a3399f6909f1c4f36 ;\n\tcascade:authenticatedPatient \"Patient/eM5vN8qTz2Hc4Rk7Jw0Pb3\" ;\n\tcascade:authenticatedAsProxy false ;\n\tcascade:sourceFormatVersion \"4.0.1\" .\n_:d45ef4d635c8aeac96a3cbb1303dbd29 prov:agent _:8d417f0f0f2aaa6a3399f6909f1c4f36 ;\n\tprov:hadRole cascade:AuthorRole .\n_:bd91136ee02d481a369f5cc74b96eb58 prov:qualifiedAssociation _:d45ef4d635c8aeac96a3cbb1303dbd29 .\n_:9605bf4164256d627a76b6dcb77895da prov:agent _:3acb5f351cf622da29c2ed826722a763 ;\n\tprov:hadRole cascade:TransmitterRole .\n_:bd91136ee02d481a369f5cc74b96eb58 prov:qualifiedAssociation _:9605bf4164256d627a76b6dcb77895da .\n_:8d417f0f0f2aaa6a3399f6909f1c4f36 <http://www.w3.org/2000/01/rdf-schema#label> \"Meridian Health System\" .\n_:3acb5f351cf622da29c2ed826722a763 <http://www.w3.org/2000/01/rdf-schema#label> \"Apple Health\" .\n_:866104d6ba15a31ee5659c777ee89e1f <http://www.w3.org/2000/01/rdf-schema#label> \"Apple Health export\" ;\n\tprov:startedAtTime \"2026-09-01T10:00:04Z\"^^xsd:dateTime .\n<ni:///sha-256;KotTT_MLS-yFk2ZpMmJnurV5cJBwk0sHUYJIrWIdRhY> a prov:Entity .\n_:866104d6ba15a31ee5659c777ee89e1f a prov:Activity ;\n\tprov:used <ni:///sha-256;KotTT_MLS-yFk2ZpMmJnurV5cJBwk0sHUYJIrWIdRhY> ;\n\tprov:qualifiedAssociation _:69b39b6c52ec40aeaac6c34cade66b49 .\n_:69b39b6c52ec40aeaac6c34cade66b49 prov:hadPlan _:67082108a6deb1af4469d3632eb5c29e .\n_:67082108a6deb1af4469d3632eb5c29e a prov:Plan ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"fhir-r4\" ;\n\tpav:version \"0.1.0\" .\n_:69b39b6c52ec40aeaac6c34cade66b49 prov:agent _:b1f97e08af9f9052f7d289130d2c8cb1 .\n_:b1f97e08af9f9052f7d289130d2c8cb1 a prov:SoftwareAgent ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"Cascade Bridge for Rust\" ;\n\tpav:version \"0.1.0\" .\n"}, "expectedFindings": {"file": "fixtures/findings/lab-hepatitis-b-surface-antigen-coded.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/findings/lab-hepatitis-b-surface-antigen-coded.ttl", "text": "@prefix fhirr4: <https://ns.cascadeprotocol.org/adapter/fhir-r4/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix sh: <http://www.w3.org/ns/shacl#> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n_:a7d65cd8b004e9a5a0252208d52c116c a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"\" .\n_:a930ee5f32f36be585440eb7402e8549 oa:hasSource <../in/lab-hepatitis-b-surface-antigen-coded.json> .\n_:a7d65cd8b004e9a5a0252208d52c116c oa:refinedBy _:ce6c60f5dd0ff460b7f8adfe767d1da2 .\n_:ce6c60f5dd0ff460b7f8adfe767d1da2 a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/valueCodeableConcept/coding/1/code\" .\n_:a930ee5f32f36be585440eb7402e8549 oa:hasSelector _:a7d65cd8b004e9a5a0252208d52c116c .\n_:b669f6a8028f919a9791ee98c59d1079 oa:hasTarget _:a930ee5f32f36be585440eb7402e8549 ;\n\tsh:resultSeverity sh:Info ;\n\ta oa:Annotation ;\n\toa:hasBody fhirr4:labResultValueCode ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"NEG\" .\n", "empty": false}}