All notable changes to Myelin will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
First stable release of Myelin. Provides a unified Python interface to the official CMS (Centers for Medicare & Medicaid Services) Java-based reimbursement tools via JPype1.
- MS-DRG Grouper (
DrgClient) - assigns inpatient claims to DRGs for IPPS, IPF, and LTCH payment determination. - MCE Editor (
MceClient) - validates inpatient claims against the Medicare Code Editor. - IOCE Editor (
IoceClient) - processes outpatient claims through the Integrated Outpatient Code Editor, assigning APCs and applying edits. - HHA Grouper (
HhagClient) - groups home health claims using OASIS assessment data. - IRF Grouper (
IrfgClient) - groups inpatient rehabilitation facility claims into Case-Mix Groups (CMGs) using IRF-PAI data. - Pricer suite for IPPS, OPPS, IPF (Psych), IRF, LTCH, SNF, HHA, Hospice, ESRD, and FQHC.
- ASC Pricer - pure-Python Ambulatory Surgical Center pricer with support for code-pair offsets, MUE limits, device discounts, and wage index lookup.
Myelinorchestrator with aprocess(claim)entry point that wires the correct grouper, editor, and pricer together.AUTOmodule - automatic detection of required modules based on bill type, revenue codes, and provider data.- IPSF / OPSF provider data - automatic lookup from CMS provider-specific files with per-claim override support for what-if analysis.
- ICD-10 code conversion (
ICDConverter) - forward/backward mapping of diagnosis and procedure codes between fiscal years. - UB-04 (CMS-1450) PDF read/write - generate a filled UB-04 PDF from a
Claimand parse a filled UB-04 PDF back into aClaimobject, plus a calibration PDF helper for verifying field mappings. - Excel export -
MyelinOutput.to_excel()andto_excel_bytes()for producing human-readable summaries of pricing/editing decisions. - Pydantic input/output models throughout for type-safe claim construction and result handling.
- Plugin system via
pluggy(client_load_classes,client_methodshookspecs) for custom Java class loading and client method extension. - CMSDownloader - async, robust downloader for CMS grouper, editor, and pricer JARs with version tracking and extraction.
- SQLite and PostgreSQL database backends for provider data and ICD-10 conversion tables.
- JVM lifecycle management - thread-safe startup/shutdown, context-manager
support (
with Myelin(...) as m:), and clean integration with multi-process workloads. Java stub generation (This effort was abandoned, may revisit in the future.create_stubs.py) for IDE type checking of JPype interop.- New IOCE fields added
- IoceOutputHcpcsModifier.description — for modifier descriptions on both input and output modifier lists
- IoceOutputLineItem: action_flag_output_description, rejection_denial_flag_description, payment_method_flag_description, payment_indicator_description, revenue_code_description, discounting_formula_description
- IoceOutput: claim_rejection_edit_disposition_description, claim_denial_edit_disposition_description, claim_return_to_provider_edit_disposition_description, claim_suspension_edit_disposition_description, line_rejection_edit_disposition_description, line_denial_edit_disposition_description
- New descriptions added to ICOE output
- _enrich_disposition_and_edits now calls getEditDispositionDescription per disposition group when edits are present
- Line items now also call: getLineItemActionFlagDescription, getLineItemDenialRejectionFlagDescription, getPaymentMethodFlagDescription, getPaymentIndicatorDescription, getRevenueCodeDescription, getDiscountFormulaDescription
- Both input and output HCPCS modifier lists now call getHcpcsModifierDescription per modifier in addition to the existing edit descriptions
- Provider data patching -
IPSFDatabase.patch()andOPSFDatabase.patch()methods for incremental updates to provider-specific data. Queries the maximumlast_updateddate, downloads only new records from that point forward, and upserts them (updating existing records with the same provider_ccn + effective_date, inserting new ones). Supports both YYYYMMDD and YYYY-MM-DD date formats. - MS-DRG diagnosis output codes -
MsdrgOutputDxCodenow includes the original diagnosis code value, making principal and secondary diagnosis outputs easier to trace back to claim input. - IOCE description enrichment - IOCE output now fills additional claim disposition, edit, line-item flag, modifier, payment indicator, revenue code, discount formula, and APC descriptions, with latest-description fallbacks when version-specific lookup text is unavailable.
- IRF wage-index outputs -
IrfOutputnow exposes inherited final CBSA and final wage-index values from the CMS payment data.
- Centralized IPSF / OPSF provider lookups and exposed them on
MyelinOutputalongside pricer results. - Refactored
Myelin.process()to make provider lookup errors non-halting and standardize error returns toReturnCodevalues. - Improved type safety across the library with
Protocoltypes for Java interop surfaces. - LTCH pricer now accepts an optional review code via claim
additional_dataand defaults the blend indicator to0when not provided. - OPPS pricer tolerates a missing discount formula from IOCE.
- Hospice pricer tolerates a missing admit date and an optional IOCE output pass-through.
- IPSF / OPSF data is whitespace-stripped before being passed to Java pricers.
- Default
county_codeis now0instead of an empty string. - Excel exporter strips nested-structure prefixes from column names and can optionally include the input claim on its own sheet.
- ASC Pricer no longer requires an OPSF provider (ASCs do not appear in OPSF).
- MCE input construction validates the discharge status.
- CMSDownloader - rewritten for clearer component discovery, jar inventory validation, missing-jar detection, bounded concurrent pricer downloads, shared request timeout handling, and cleaner extraction of only the required CMS runtime jars.
- Duplicate IRFG client initialization and duplicate ASC client setup in
Myelinremoved. - Duplicate
IPSFdefinition incore.pyremoved. - LTCH-specific updates now applied prior to the Java call.
- HHA claim input construction.
- ICD converter no longer raises on a
Nonecheck. - Minor formatting issue on the Excel exporter summary tab.
IoceReturnCoderenamed fromReturnCodeto avoid duplicate naming with the shared utility.- IPPS procedure codes - inpatient procedure codes are now passed to the
IPPS Java claim object as Java strings and assigned with
setProcedureCodes. - IPSF HRR participant indicator - preserves
0values instead of treating them as missing, preventing invalid return codes and incorrect pricing. - Supplemental wage index mapping - LTCH, SNF, and IRF now opt in to sending IPSF supplemental wage-index fields to the CMS Java provider object while IPF and other shared IPSF call sites keep the previous default behavior.