extracting-sdoh
Fungsinya
Skill ini menemukan faktor sosial yang memengaruhi kesehatan, seperti masalah perumahan, kerawanan pangan, dan hambatan transportasi, dalam catatan klinis, lalu menyarankan kode Z ICD-10 yang cocok. Skill ini untuk tim perawatan dan analis kesetaraan kesehatan yang membutuhkan faktor ini sebagai data.
Kapan dipakai
- βSaat catatan menjelaskan risiko sosial seperti tidak punya tempat tinggal, makanan, atau tumpangan ke janji temu.
- βSaat analisis kesetaraan kesehatan membutuhkan faktor sosial yang tercatat sebagai data terstruktur.
- βSaat kebutuhan sosial yang terdokumentasi mungkin tidak ada di daftar masalah yang dikodekan.
Link skill
https://github.com/maziyarpanahi/openmed/blob/master/skills/extracting-sdoh/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βDari catatan yang sudah dihapus identitasnya ini, temukan masalah perumahan atau makanan dan sarankan kode Z yang cocok untuk ditinjau pengodean.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Agent menjalankan ekstraksi entitas pada catatan yang sudah dihapus identitasnya, mencocokkan span risiko sosial dengan keluarga kode Z55 sampai Z65, lalu menyajikan saran untuk ditetapkan oleh orang.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Extracting SDOH and Mapping to ICD-10-CM Z-Codes
Social determinants of health (SDOH) β the conditions in which people live, work, and age β drive an estimated 80% of health outcomes, yet they live almost entirely in free-text narrative. Multiple chart-review studies find SDOH documented in notes but coded with a Z-code under ~2% of the time. The information is there; the structured signal is not. This skill recovers it: run OpenMed NER over de-identified notes, then map the resulting spans to the ICD-10-CM Z55βZ65 family.
When to use
- A note clearly describes a social risk ("lives in her car", "skips meals to afford insulin", "no ride to dialysis") and you want a coded, queryable signal.
- You are building health-equity dashboards, risk stratification, or closed-loop referral feeds and need SDOH as discrete data.
- You want to reconcile what the chart says against what was coded, and flag Z-code gaps for a coder or care team to confirm.
This is a decision-support step. It proposes Z-codes; a human assigns them. SDOH coding is sensitive β never expose individual SDOH inferences outside the care/coding workflow, and never feed them to coverage or pricing decisions.
Quick start
De-identify first, run NER, then map spans to Z-codes:
import openmed
from sdoh_zcode_map import SDOH_ZCODES # see references/sdoh_zcode_map.md
note = (
"62F with CHF. Reports she lost her apartment last month and is "
"staying in a shelter. Often runs out of food before month-end. "
"No car; misses appointments because the bus does not run to clinic."
)
# 1) Strip PHI before any downstream processing or storage.
deid = openmed.deidentify(note, method="replace", policy="hipaa_safe_harbor")
# 2) Run clinical NER. Use an SDOH/clinical model from the registry; discover
# available keys with openmed.get_models_by_category(...).
result = openmed.analyze_text(deid.text, output_format="dict")
# 3) Map each entity span to a candidate Z-code.
for ent in result["entities"]:
code = SDOH_ZCODES.get(ent["label"].lower())
if code:
print(f"{ent['text']!r:40} {ent['label']:18} -> {code}")
analyze_text returns entities shaped as
{"text", "label", "confidence", "start", "end", "metadata"}. The start/end
offsets index into the text you passed in, so you can anchor every suggested
Z-code back to its exact source span for human review.
Workflow
- De-identify the note with
openmed.deidentify(HIPAA Safe Harbor or a stricter policy). SDOH text is dense with PHI (addresses, employer names). - Extract entities with
openmed.analyze_text. Pick a model whose label set covers social concepts; if your model only emits clinical findings, run a second pass with a zero-shot model (openmed zero) using SDOH labels such ashousing_instability,food_insecurity,unemployment,transportation_barrier,social_isolation,financial_strain. - Map spans to Z-codes using a curated lookup keyed by label
(
references/sdoh_zcode_map.md). Keep the span offsets and the modelconfidenceon every suggestion. - Stage for confirmation. Emit
(span, label, suggested_code, confidence)tuples for a coder or the Gravity Project pipeline to accept or reject. Do not auto-bill a Z-code from an inference alone. - Normalize to value sets. Align labels to the Gravity Project SDOH
domains so codes are interoperable with FHIR (
Condition,Observation,Goal) and USCDI v3 SDOH elements.
Z-code families you will hit most (ICD-10-CM Z55βZ65)
| Domain | Range | Example |
|---|---|---|
| Education / literacy | Z55 | Z55.0 illiteracy |
| Employment | Z56 | Z56.0 unemployment |
| Occupational exposure | Z57 | β |
| Housing / economic | Z59 | Z59.0 homelessness, Z59.41 food insecurity, Z59.82 transportation insecurity |
| Social environment | Z60 | Z60.2 living alone, Z60.4 social exclusion |
| Upbringing | Z62 | β |
| Family / support circumstances | Z63 | Z63.4 disappearance/death of family member |
| Psychosocial circumstances | Z64βZ65 | Z65.1 imprisonment |
The full curated labelβcode table lives in references/sdoh_zcode_map.md.
Hand-off to / from OpenMed
- From OpenMed: this skill consumes
openmed.analyze_text(...)output (PredictionResultdict). Eachentity["start"]/["end"]anchors a Z-code suggestion to source text. - To OpenMed: always run `openmed.de
Pertanyaan umum
Apakah skill ini menetapkan kode Z sendiri?
Tidak. Skill mengusulkan kode, dan orang yang menetapkannya.
Apakah hasilnya boleh dibagikan secara luas?
Tidak. Skill menyarankan temuan risiko sosial individu tetap berada dalam alur perawatan dan pengodean.
Apakah ini membantu keputusan cakupan asuransi?
Tidak. Skill menyarankan agar kesimpulan ini tidak pernah dipakai untuk keputusan cakupan atau harga.
Detail
Deskripsi asli dari pembuat
Extracts social determinants of health (SDOH) β housing instability, food insecurity, unemployment, transportation barriers, social isolation, financial strain β from clinical narrative and maps the spans to ICD-10-CM Z-codes (Z55βZ65). Use after running OpenMed NER when the user wants SDOH surfacing, Z-code suggestion, health-equity analytics, or to recover SDOH that is documented in free text but not coded. Pairs with OpenMed analyze_text output. Standards: ICD-10-CM Z55βZ65, Gravity Project value sets, n2c2 2022 SDOH track. Trigger keywords: SDOH, social determinants, Z-codes, housing, food
repo: maziyarpanahi/openmed
Popularitas
- Bintang GitHub
- 5.8k
- Peringkat
- #14703
- Lisensi
- Apache-2.0
- Diperbarui
- 2/11/2026
Komentar
- β¦
Skill lain dari repositori ini
annotating-variants
5.8kMembantu agent Anda memperkirakan apa yang dilakukan varian genetik, mengubah nama HGVS menjadi posisi genom, dan menambahkan frekuensi populasi, dengan memakai anotator publik yang gratis.
ask-openmed
5.8kMembantu agent Anda memilih alur kerja OpenMed yang tepat untuk permintaan teks klinis, dimulai dengan pemeriksaan privasi setiap kali data pasien mungkin ada.
assembling-fhir-bundles
5.8kMengemas beberapa rekam kesehatan FHIR menjadi satu Bundle transaksi yang siap dikirim ke EHR, dengan referensi internal yang terhubung dengan benar.
auditing-deid-leakage
5.8kMemindai teks klinis yang sudah dihapus identitasnya untuk mencari pengenal yang tertinggal, seperti nomor SSN, nomor kartu, email, dan tanggal, dan memblokir rilis jika masih ada.
Skill serupa
gitcrawl
394kMemungkinkan agent Anda mencari arsip issue dan pull request GitHub yang tersimpan, mengelompokkan yang duplikat, dan memeriksa status terkininya di GitHub.
slacrawl
394kMemungkinkan agent Anda mencari dan menghitung pesan di arsip Slack lokal, memeriksa seberapa baru arsip itu, dan menyegarkannya bila diperlukan.
goplaces
394kMembantu agent Anda mencari tempat, mendapatkan detail dan ulasannya, serta menentukan nama tempat memakai Google Places, dengan keluaran JSON untuk skrip.