**FHIR에서 Single-cell RNA-seq 및 NGS 데이터 다루는 표준 방법**
FHIR은 **임상/진료 연계 데이터** 교환을 위한 표준으로, 대용량 omics 데이터(raw FASTQ, BAM, count matrix, AnnData/H5AD 등)를 직접 저장하기에는 적합하지 않습니다. 대신 **메타데이터, 주요 결과(derived findings), 해석(interpretation)**을 구조화하여 교환하는 데 중점을 둡니다.
### 1. 핵심 표준: HL7 FHIR Genomics Reporting Implementation Guide (GRIG)
가장 공식적이고 널리 사용되는 가이드는 **HL7 Clinical Genomics Work Group**이 만드는 **Genomics Reporting Implementation Guide**입니다.
- **현재 버전**: v3.0.0 (STU3, 2024년 12월, FHIR R4 기반)
- **CI Build (최신)**: v4.0.0-cibuild
- 공식 사이트: [http://hl7.org/fhir/uv/genomics-reporting/](http://hl7.org/fhir/uv/genomics-reporting/)
이 IG는 주로 **변이 보고(variant reporting)**, 약물유전체(pharmacogenomics), 체세포 변이(somatic), HLA typing 등을 다루지만, RNA-seq / 유전자 발현 결과도 **Observation** 프로파일로 표현할 수 있습니다.
### 2. 주요 FHIR 리소스 및 사용 방법
| 리소스 | 용도 | Single-cell / NGS에서의 역할 | 비고 |
|---------------------|-------------------------------------------|-------------------------------------------------------|------|
| **Observation** | 변이, 유전자 발현, 세포 타입, 해석 등 | 가장 많이 사용. 변이 + 발현 결과 + cell type annotation | Genomics IG에서 강력히 프로파일링 |
| **DiagnosticReport**| Genomic report 전체 구성 | 여러 Observation을 그룹핑하여 하나의 보고서로 만듦 | 필수 |
| **MolecularSequence** | 분자 서열 (DNA/RNA) 표현 | 특정 서열 segment, reference sequence, alignment metadata | R5부터 본격화. Full BAM은 비추천 |
| **GenomicStudy** | Genomic 분석 워크플로우 (R5+) | Sequencing run, library prep, pipeline (Cell Ranger 등) 메타데이터 | 연구/실험실 환경에 유용 |
| **MolecularDefinition** | 분자 엔티티 정의 (R6 ballot) | Allele, haplotype, sequence 정의 (MolecularSequence 대체 예정) | 향후 중요해질 예정 |
| **Specimen** | 샘플 정보 | Single-cell suspension, tissue dissociation 방법 등 | 확장 가능 |
| **DocumentReference** | 대용량 파일 링크 | FASTQ/BAM/count matrix/H5AD 파일 URL 연결 | 가장 현실적인 방법 |
### 3. Single-cell RNA-seq / NGS 데이터 처리 실제 패턴
#### 패턴 A: Raw / Large 데이터 (권장)
- FHIR에 raw 데이터를 넣지 않음
- **DocumentReference** 또는 `Observation.derivedFrom`으로 외부 저장소 링크
- 저장소 예시: S3/GCS + presigned URL, **GA4GH DRS**, GEO/SRA, Human Cell Atlas Portal, 10x Genomics dataset
#### 패턴 B: Derived / Clinically Actionable 결과 (FHIR에 넣을 내용)
- **Variant calling 결과** (SNV, CNV, structural variant) → Genomics IG의 **Variant** 관련 Observation 프로파일 사용
- **유전자 발현 / 세포 수준 결과**:
- Cell type annotation (`Observation` + code for "T cell", "Exhausted CD8+ T cell" 등)
- Marker gene expression (e.g., `CD3E`, `PDCD1` 발현 수준)
- Cluster / UMAP 결과 요약
- Differential expression 결과
- **워크플로우 메타데이터** → **GenomicStudy** (10x Chromium, Smart-seq2, library prep protocol, sequencing platform, analysis pipeline 등)
#### 예시 구조 (개념적)
```json
// GenomicStudy 예시 (scRNA-seq 워크플로우)
{
"resourceType": "GenomicStudy",
"type": [{"coding": [{"code": "gene-expression-profiling"}]}],
"analysis": [{
"methodType": {"coding": [{"code": "10x-genomics-chromium", "display": "10x Genomics Chromium"}]},
"device": {"reference": "Device/sequencer-novaseq"},
"performer": [...],
"input": [{"reference": "Specimen/single-cell-suspension-123"}]
}]
}
// Observation 예시 (세포 타입 + 주요 마커 발현)
{
"resourceType": "Observation",
"code": {"coding": [{"system": "http://loinc.org", "code": "...", "display": "Cell type"}]},
"subject": {"reference": "Patient/xxx"},
"derivedFrom": [{"reference": "GenomicStudy/yyy"}],
"component": [
{"code": {"text": "Cell type"}, "valueCodeableConcept": {"text": "Exhausted CD8+ T cell"}},
{"code": {"text": "PDCD1 expression"}, "valueQuantity": {"value": 12.5, "unit": "log2(CPM)"}}
]
}
```
### 4. R5 / R6에서의 변화 (중요)
- **R4**: 주로 **Observation** + **MolecularSequence** (초기)
- **R5**: **GenomicStudy** + **MolecularSequence** 정식 지원
- **R6 ballot**: **MolecularDefinition** 도입 (MolecularSequence를 점차 대체할 예정). 더 구조화된 분자 정의 가능
### 5. 현실적인 구현 조언
| 상황 | 추천 접근 방식 | 비고 |
|-------------------------|---------------------------------------------|------|
| 임상 보고서 (변이 중심) | Genomics Reporting IG + Observation/DiagnosticReport | 가장 성숙 |
| 연구 / translational | GenomicStudy + Observation + DocumentReference | 워크플로우 기록에 강점 |
| 대용량 scRNA-seq 데이터 | DocumentReference + external repository | 필수 |
| Single-cell 특화 | Specimen 확장 + GenomicStudy + Observation | 아직 전용 IG는 없음 |
| 장기적 (R6+) | MolecularDefinition + GenomicStudy | 주의해서 모니터링 |
### 참고 자료
- **Genomics Reporting IG**: [http://hl7.org/fhir/uv/genomics-reporting/](http://hl7.org/fhir/uv/genomics-reporting/)
- FHIR R5 **GenomicStudy**: [https://hl7.org/fhir/genomicstudy.html](https://hl7.org/fhir/genomicstudy.html)
- mCODE (암 유전체): Genomics Reporting IG를 기반으로 함
- GA4GH 연계: DRS, Phenopackets (FHIR과 함께 사용)
**결론**
FHIR은 **raw NGS/scRNA-seq 파일 자체**를 저장하는 도구가 아니라, **그 결과를 임상/연구에서 의미 있게 교환**하기 위한 표준입니다. 대용량 데이터는 외부 저장 + 링크, 핵심 결과는 **Observation + GenomicStudy** 조합으로 표현하는 것이 현재 가장 표준적인 방법입니다.