Skip to content

ElderServe provider-directory pipeline + mapper (Plan-Net CSV)#15

Open
eremec wants to merge 2 commits into
mainfrom
feat/s3-csv-ingest
Open

ElderServe provider-directory pipeline + mapper (Plan-Net CSV)#15
eremec wants to merge 2 commits into
mainfrom
feat/s3-csv-ingest

Conversation

@eremec

@eremec eremec commented Jul 15, 2026

Copy link
Copy Markdown

Per-client workspace side of the S3 CSV → FHIR feature (engine PR: HealthSamurai/interbox#60).

What's here

  • elderserve-providers — the original single-file provider mapper → Practitioner (id = NPI).
  • elderserve-provider-directory (new) — the Plan-Net CSV spec: three cross-referenced files per drop (providers / facilities / networks), delivered as a dated subfolder with a manifest.json. The pipeline enables the engine load barrier, so the whole drop maps together (references resolved only against complete data).
    • Mapper routes by file_type: providers → Practitioner, facilities → Organization, networks → Organization (network flavor). One row per (NPI + location + plan + specialty); id = NPI collapses a provider's many rows into one Practitioner.

Tested

End-to-end against MinIO with a spec-conformant drop (sharded providers + facilities + networks + manifest): staged until sealed, then 5 Practitioner + 4 Organization, 0 error.

Deferred

Cross-file references (PractitionerRole → network/org, OrganizationAffiliation) need a mapper-context sibling lookup within the sealed batch; full Plan-Net graph (Location, InsurancePlan, richer PractitionerRole).

🤖 Generated with Claude Code

eremec and others added 2 commits July 13, 2026 20:14
New S3 CSV pipeline (s3CsvSource -> elderserve-providers mapper ->
aidboxSender) mapping the ElderServe per-payer provider-directory rows to
FHIR Practitioner:
- identity: Practitioner.id derived from NPI, so rows for the same provider
  (multiple sites / payer files) collapse into one Practitioner; no-NPI rows
  error.
- fields: name (+ degree suffix), gender, telecom, address, languages,
  qualification. Header keys normalized (trim + lowercase) to tolerate the
  casing/whitespace drift across payer files.

Requires the S3 CSV support in @health-samurai/interbox (unreleased). For
local dev, `bun run link:workspace` from the engine checkout links the local
SDK build.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…pec)

New batching CSV pipeline for the ElderServe Plan-Net provider directory — three
cross-referenced files per drop (providers / facilities / networks), gated by the
engine load barrier so a whole drop maps together.

- Mapper routes by file_type: providers → Practitioner (id = NPI), facilities →
  Organization (id = NPI), networks → Organization (network; id = network-<slug>).
  Unrecognized rows map to nothing.
- Pipeline turns the barrier on (batch: subprefix boundary + manifest completion),
  path provider-directory/.

Cross-file references (PractitionerRole → network/org, OrganizationAffiliation)
are deferred — they need a mapper-context sibling lookup within the sealed batch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant