Skip to main content

ICD-10 unified coder — deterministic ICD-10-CM (diagnosis) + ICD-10-PCS (procedure) code mapping with bundled CMS 2025 data

Project description

ICD-10 Unified Coder

진단(ICD-10-CM)과 시술(ICD-10-PCS)을 하나의 CLI/스킬로 매핑하는 통합 코딩 도구. 한국어·영문 의료 용어를 표준 ICD-10 코드로 변환한다. LLM 단독 대비 hallucination 없는 결정론적 조회.

icd10-cm + icd10-pcs 두 프로젝트를 통합한 배포 패키지. (SNOMED CT는 라이선스/규모 문제로 별도 유지 — 아래 참고.)

구성

icd10-coder/
├── .claude/skills/icd10-coder/SKILL.md   # Claude Code 스킬 (라우팅 포함)
├── scripts/coder.py                       # 통합 CLI
├── data/
│   ├── icd10cm.db        (22MB)  ICD-10-CM ~97K 진단코드 + FTS
│   ├── icd10pcs.db       (50MB)  ICD-10-PCS ~68K + 알파벳 인덱스 + GEMs + 트리
│   └── body_part_hierarchy.json  PCS body part sibling 확장맵
└── README.md

사용법

python scripts/coder.py dx   "type 2 diabetes with neuropathy"   # 진단 → CM
python scripts/coder.py dx -k "심방세동"                          # 한국어
python scripts/coder.py proc "laparoscopic cholecystectomy"      # 시술 → PCS
python scripts/coder.py code 0FT44ZZ                             # 코드 상세 (자동 판별)
python scripts/coder.py code E11.40
python scripts/coder.py hierarchy I48                            # 계층 탐색

dx/code/hierarchy는 결정론적 조회. proc는 PCS 알파벳 인덱스 + GEMs + body-part 열거 브리지로 후보 컨텍스트를 출력하고, LLM(스킬)이 7자리 코드를 조립한다.

PCS 검색 파이프라인 (proc)

icd10-pcs 프로젝트의 v2 검색 개선이 내장돼 있다:

  1. 인덱스 표제어 직접 조회 (Cholecystectomy → 0FT4)
  2. 노이즈 단어 필터 + 수술 어간 우선 + round-robin FTS
  3. 3자리 접두사 → body part 열거 브리지 (0GT → 0GTK 복원)
  4. 출처순 정렬된 후보 접두사 + 트리 실재 코드 제시

벤치마크(gpt-oss-120b, 195건, SNUH/MOVER)에서 이 개선으로 TOP-5 정확도 29% → 47%.

데이터 라이선스

ICD-10-CM / ICD-10-PCS 모두 CMS 퍼블릭 도메인 → 자유 배포 가능.

통합 범위 메모

  • 포함: ICD-10-CM(진단) + ICD-10-PCS(시술). 동일 패턴·공개 도메인·합계 72MB.
  • 미포함: SNOMED CT. 이유 — (1) 규모(snomed.db 412MB + FAISS 2.8GB), (2) SNOMED/UMLS 라이선스 제약(자유 배포 불가), (3) 작업 종류가 다름(엔티티 스팬 추출+링킹). 향후 UMLS CUI 크로스워크(이 ICD 코드 ↔ SNOMED 개념)를 라이선스 보유 환경에서 별도 계층으로 추가 가능.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

icd10_coder-0.1.0.tar.gz (10.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

icd10_coder-0.1.0-py3-none-any.whl (11.1 MB view details)

Uploaded Python 3

File details

Details for the file icd10_coder-0.1.0.tar.gz.

File metadata

  • Download URL: icd10_coder-0.1.0.tar.gz
  • Upload date:
  • Size: 10.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for icd10_coder-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0a213c43079831d60986f3af345f3a814610e226cbd83a2755ce2009cb97d61a
MD5 5e0ee126ab8007651aea4c26a787a827
BLAKE2b-256 45c3fcfe4acf6aebf825a82800f887b9391faf0f89105ec6e3536f09bde2f949

See more details on using hashes here.

File details

Details for the file icd10_coder-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: icd10_coder-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 11.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for icd10_coder-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 68b3e09c0e17f562c919676b2020c6e94ec56610bcc767404e5b30abf3aaba2f
MD5 da6bae06f0545ff419cddf26c5f713cb
BLAKE2b-256 552827822179e3de78dd5e54ab0043ba18c7843768279df5950dee656b36613c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page