Skip to content

Latest commit

Β 

History

26 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ClaimIQ

Healthcare Claims Data Quality & Operations Platform

ClaimIQ is a synthetic-data healthcare Revenue Cycle Management (RCM) data quality and operations platform designed to identify claims-data discrepancies, validate operational workflows, support issue investigation, and provide actionable analytics and reporting.

The project is being developed as a phased software engineering project, with a strong focus on SQL, MySQL 8.x, data quality, quality assurance, data integrity, operational analytics, documentation, and AI-assisted investigation.

Important: ClaimIQ uses synthetic healthcare data exclusively. It does not process real patient information, Protected Health Information (PHI), real insurance records, real claims, or production healthcare systems.


🎯 Project Mission

Healthcare Revenue Cycle Management depends on large volumes of interconnected operational and financial data. Even relatively small data inconsistencies can result in incorrect reporting, payment discrepancies, unresolved claims, and downstream operational issues.

ClaimIQ aims to simulate a data operations environment where analysts can:

  • Validate healthcare claims data
  • Detect data-quality issues
  • Identify financial discrepancies
  • Detect invalid relationships and business-rule violations
  • Investigate operational issues
  • Track issue resolution
  • Monitor data-quality metrics
  • Generate operational reports
  • Maintain QA rules and process documentation
  • Use AI to assist with investigation and explanation of verified issues

The goal is not to recreate a production healthcare billing system, but to demonstrate how a data operations platform can maintain accuracy, consistency, traceability, and operational quality across a claims dataset.


πŸ₯ RCM Domain

ClaimIQ models a simplified healthcare Revenue Cycle Management lifecycle:

Patient
   ↓
Encounter
   ↓
Claim Creation
   ↓
Claim Submission
   ↓
Payer Processing
   ↓
Adjudication
   β”œβ”€β”€ Accepted
   β”œβ”€β”€ Rejected
   └── Denied
   ↓
Payment / Adjustment
   ↓
Remittance
   ↓
Reconciliation
   ↓
Resolution

The platform uses synthetic representations of common RCM concepts including:

  • Patients
  • Providers
  • Healthcare organizations
  • Payers and insurance plans
  • Encounters
  • Procedures
  • Claims
  • Claim lines
  • Payments
  • Adjustments
  • Denials
  • Remittances
  • Claim statuses
  • Reconciliation records

Healthcare coding and transaction concepts may be modeled using synthetic equivalents inspired by industry terminology. No real patient, payer, or billing data is used.


πŸ”Ž Problems ClaimIQ Addresses

ClaimIQ focuses on five major categories of operational data problems.

1. Data Quality

  • Missing mandatory fields
  • Duplicate records
  • Invalid identifiers
  • Malformed values
  • Inconsistent data

2. Financial Discrepancies

  • Payment greater than claim amount
  • Negative financial values
  • Duplicate payments
  • Incorrect adjustments
  • Unreconciled balances

3. Temporal Anomalies

  • Submission before service
  • Payment before submission
  • Denial before submission
  • Future-dated events
  • Invalid event sequences

4. Referential Integrity

  • Orphaned claims
  • Invalid patient references
  • Invalid provider references
  • Invalid payer references
  • Payments referencing nonexistent claims

5. Business Logic Violations

Examples include:

  • Paid claim with zero payment
  • Denied claim with positive payment
  • Pending claim with payment
  • Claims without service lines
  • Invalid claim-status combinations

🧩 Core Capabilities

The completed ClaimIQ platform is planned to provide:

Data Quality

  • Automated QA validation
  • Data-quality scoring
  • Duplicate detection
  • Missing-data detection
  • Referential integrity validation
  • Financial validation
  • Business-rule validation

Claims Operations

  • Claims search
  • Claims exploration
  • Claim lifecycle tracking
  • Issue investigation
  • Issue assignment
  • Resolution tracking
  • Escalation workflows

Analytics

  • Data-quality trends
  • Issue distribution
  • Provider-level analysis
  • Payer-level analysis
  • Financial discrepancy analysis
  • Claims status analysis
  • QA rule performance

Reporting

  • Daily Data Quality Reports
  • Weekly Operations Reports
  • Critical Financial Discrepancy Reports
  • Provider Quality Scorecards
  • Payer Reports
  • Claims Pipeline Reports
  • QA Performance Reports

AI-Assisted Operations

The final phase will introduce an AI assistant capable of working with verified ClaimIQ data to assist with:

  • Issue explanations
  • Investigation summaries
  • Operational report generation
  • Pattern analysis
  • SOP guidance

The AI layer is designed to explain and assist with verified data rather than act as the source of truth.


πŸ—οΈ Project Architecture

ClaimIQ is being developed incrementally.

                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚     ClaimIQ UI      β”‚
                    β”‚     Dashboard       β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                               β”‚
                               β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚     Backend API     β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                               β”‚
              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
              β”‚                β”‚                β”‚
              β–Ό                β–Ό                β–Ό
        Claims Services    QA Engine        Reporting
              β”‚                β”‚                β”‚
              β”‚                β–Ό                β”‚
              β”‚          SQL Validation         β”‚
              β”‚                β”‚                β”‚
              β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                               β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚      Database       β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                               β”‚
                               β–Ό
                    Synthetic Data Engine
                               β”‚
                               β–Ό
                       Error Injection
                               β”‚
                               β–Ό
                      Controlled QA Tests

The architecture will evolve throughout the project's phases.


πŸ› οΈ Planned Technology Stack

The technology stack will be finalized during the relevant implementation phases.

Current planned technologies include:

Area Technology
Database MySQL 8.x (Storage Engine: InnoDB, Charset: utf8mb4)
Financial Precision DECIMAL(12,2)
Temporal Standard DATETIME(6), UTC
Querying SQL
Data Generation Python
Data Analysis Python / Pandas
Backend Python-based API
Frontend HTML / CSS / JavaScript
Visualization Charting library
Testing Python testing framework
Containerization Docker
CI/CD GitHub Actions
AI LLM/API-based assistant

Technology decisions will be documented as the project progresses.


πŸ“‹ Project Roadmap

ClaimIQ is divided into 12 major phases.

Phase Description Status
Phase 1 Domain Research, Scope & Requirements βœ… Complete
Phase 2 Database Architecture & Data Modeling βœ… Complete
Phase 3 Synthetic Data Generation βœ… Complete
Phase 4 Controlled Data Error Injection βœ… Complete
Phase 5 SQL Data Quality Engine πŸ”œ Next
Phase 6 Python Analytics Engine ⏳ Planned
Phase 7 Backend & API ⏳ Planned
Phase 8 Operations Dashboard ⏳ Planned
Phase 9 Investigation, Audit & Reporting ⏳ Planned
Phase 10 SOP & Documentation System ⏳ Planned
Phase 11 Testing, Security & Performance ⏳ Planned
Phase 12 AI Intelligence & Final Release ⏳ Planned

πŸ“š Phase 1 β€” Requirements Foundation

Phase 1 established the conceptual and operational foundation of ClaimIQ.

Documentation includes:

docs/
β”œβ”€β”€ project-overview.md
β”œβ”€β”€ rcm-domain-overview.md
β”œβ”€β”€ problem-definition.md
β”œβ”€β”€ users-and-roles.md
β”œβ”€β”€ use-cases.md
β”œβ”€β”€ functional-requirements.md
β”œβ”€β”€ non-functional-requirements.md
β”œβ”€β”€ data-quality-framework.md
β”œβ”€β”€ severity-model.md
β”œβ”€β”€ claim-lifecycle.md
β”œβ”€β”€ issue-lifecycle.md
β”œβ”€β”€ operational-workflow.md
β”œβ”€β”€ reporting-requirements.md
β”œβ”€β”€ success-metrics.md
β”œβ”€β”€ project-scope.md
└── requirements-traceability-matrix.md

reports/
└── PHASE_1_COMPLETION_REPORT.md

Phase 1 established:

  • 16 formal use cases
  • 60+ functional requirements
  • Non-functional requirements
  • Seven data-quality dimensions
  • Claim lifecycle model
  • Issue lifecycle model
  • Severity framework
  • Operational workflow
  • Reporting requirements
  • Success metrics
  • Requirements traceability
  • Project scope and phase dependencies

Phase 1 Status

Complete and verified.

No database, backend, frontend, AI implementation, or production infrastructure was introduced during Phase 1.


πŸ›οΈ Phase 2 β€” Database Architecture & Data Modeling

Phase 2 established the complete MySQL 8.x relational foundation for ClaimIQ.

Documentation and schema artifacts include:

docs/
β”œβ”€β”€ database-architecture.md
β”œβ”€β”€ entity-relationship-diagram.md
β”œβ”€β”€ data-dictionary.md
β”œβ”€β”€ normalization-strategy.md
β”œβ”€β”€ index-strategy.md
β”œβ”€β”€ database-conventions.md
β”œβ”€β”€ claim-data-model.md
└── phase-2-schema-validation.md

database/
β”œβ”€β”€ schema/
β”‚   β”œβ”€β”€ 01_reference_tables.sql
β”‚   β”œβ”€β”€ 02_patient_provider_tables.sql
β”‚   β”œβ”€β”€ 03_clinical_encounter_tables.sql
β”‚   β”œβ”€β”€ 04_claims_tables.sql
β”‚   β”œβ”€β”€ 05_financial_tables.sql
β”‚   β”œβ”€β”€ 06_operations_qa_tables.sql
β”‚   β”œβ”€β”€ 07_audit_tables.sql
β”‚   β”œβ”€β”€ 08_indexes.sql
β”‚   └── 09_seed_reference_data.sql
β”‚
β”œβ”€β”€ migrations/
β”‚   └── 001_initial_schema.sql
β”‚
└── validate_schema.py

reports/
└── PHASE_2_COMPLETION_REPORT.md

Phase 2 established:

  • MySQL 8.x database architecture with InnoDB storage engine and utf8mb4 character set
  • Standardized temporal precision (DATETIME(6) in UTC) and exact financial precision (DECIMAL(12,2))
  • 22 normalized tables and 124 documented columns
  • Primary keys (BIGINT UNSIGNED AUTO_INCREMENT) and foreign keys with declarative referential integrity
  • Unique, NOT NULL, and CHECK constraints
  • Secondary B-Tree index strategy for foreign keys and operational queues
  • Claim lifecycle and state transition history model
  • Financial reconciliation and variance balancing model
  • Operational issue management and root-cause tracking model
  • QA engine metadata and execution telemetry supporting structures
  • Immutable audit event logging structure
  • Deterministic, reproducible migration script (001_initial_schema.sql)
  • MySQL 8.x Python schema validation harness (validate_schema.py)

Phase 2 Status

Complete and verified.

The schema contains the structural foundation and reference data, but no large synthetic datasets, error injection, or QA engine implementation.


βš™οΈ Phase 3 β€” Synthetic Data Generation Engine

Phase 3 implemented the deterministic synthetic healthcare data generation engine and produced a 100% clean, mathematically balanced baseline dataset in MySQL 8.x.

Documentation and generation modules include:

docs/
β”œβ”€β”€ phase-3-data-generation.md
β”œβ”€β”€ synthetic-data-model.md
β”œβ”€β”€ generation-configuration.md
β”œβ”€β”€ clinical-code-library.md
β”œβ”€β”€ generation-validation.md
└── generation-performance.md

generator/
β”œβ”€β”€ config.py
β”œβ”€β”€ database.py
β”œβ”€β”€ random_state.py
β”œβ”€β”€ identifiers.py
β”œβ”€β”€ dates.py
β”œβ”€β”€ financials.py
β”œβ”€β”€ distributions.py
β”œβ”€β”€ reference_data.py
β”œβ”€β”€ validators.py
β”œβ”€β”€ cli.py
β”œβ”€β”€ templates/
└── generators/

tests/
β”œβ”€β”€ test_identifiers.py
β”œβ”€β”€ test_dates.py
β”œβ”€β”€ test_financials.py
β”œβ”€β”€ test_distributions.py
└── test_generation.py

reports/
└── PHASE_3_COMPLETION_REPORT.md

Phase 3 established:

  • Deterministic multi-scale synthetic generation (small: 1k claims, medium: 10k claims, large: 100k claims)
  • Seeded reproducibility (random.Random(seed) + Faker.seed(seed))
  • Standardized 10-digit NPI generation with CMS Luhn checksum validation
  • 35 CPT procedural codes and 45 ICD-10 diagnostic codes in a controlled clinical code library
  • Exact Decimal(12, 2) fixed-point arithmetic ensuring $\text{Variance} = $0.00$ on all baseline reconciliations
  • Strict chronological date sequencing adhering to payer timely filing limits
  • Realistic claim lifecycle state transition tracking (Submitted $\rightarrow$ Accepted $\rightarrow$ Paid / Partially Paid / Denied)
  • Chunked batch database insertion (2,500 rows per chunk) with active foreign keys
  • Automated 7-dimension SQL data quality validation suite (python -m generator --validate)
  • Safe database reset mechanism (python -m generator --reset) preserving schema and reference data

Phase 3 Status

Complete and verified.

The generated dataset represents a clean operational baseline ready for Phase 4 controlled error injection.


πŸ’‰ Phase 4 β€” Controlled Error Injection & Anomaly Datasets

Phase 4 implemented the deterministic error injection framework capable of creating controlled, realistic, traceable defects in copies of the clean Phase 3 baseline dataset.

Documentation and injection modules include:

docs/
β”œβ”€β”€ phase-4-error-injection.md
β”œβ”€β”€ anomaly-taxonomy.md
β”œβ”€β”€ injection-profiles.md
β”œβ”€β”€ anomaly-ground-truth.md
β”œβ”€β”€ anomaly-validation.md
└── phase-4-test-results.md

database/schema/
└── 10_ground_truth_tables.sql

generator/
β”œβ”€β”€ inject.py
└── injector/
    β”œβ”€β”€ models.py
    β”œβ”€β”€ taxonomy.py
    β”œβ”€β”€ profiles.py
    β”œβ”€β”€ engine.py
    β”œβ”€β”€ ground_truth.py
    β”œβ”€β”€ validators.py
    β”œβ”€β”€ cli.py
    └── mutators/
        β”œβ”€β”€ completeness.py
        β”œβ”€β”€ duplication.py
        β”œβ”€β”€ referential.py
        β”œβ”€β”€ financial.py
        β”œβ”€β”€ temporal.py
        β”œβ”€β”€ lifecycle.py
        β”œβ”€β”€ business_logic.py
        └── formatting.py

tests/
β”œβ”€β”€ test_anomaly_selection.py
β”œβ”€β”€ test_anomaly_determinism.py
β”œβ”€β”€ test_financial_anomalies.py
β”œβ”€β”€ test_temporal_anomalies.py
β”œβ”€β”€ test_duplicate_anomalies.py
β”œβ”€β”€ test_lifecycle_anomalies.py
β”œβ”€β”€ test_ground_truth.py
β”œβ”€β”€ test_reset.py
└── test_injection_profiles.py

reports/
└── PHASE_4_COMPLETION_REPORT.md

Phase 4 established:

  • Authoritative 67-anomaly taxonomy (E001–E067) spanning all 8 core defect categories
  • Deterministic multi-scale injection profiles (clean, light: ~1%, moderate: ~5%, heavy: ~10%, targeted)
  • Explicit Ground Truth Registry (anomaly_ground_truth table in MySQL 8.x + JSON export)
  • Dry-run simulation mode (python -m generator.inject --profile moderate --seed 42 --dry-run)
  • Targeted anomaly injection CLI (python -m generator.inject --profile targeted --anomaly E023,E030,E034)
  • Automated anomaly validation suite auditing live database state against ground truth
  • Precise two-way mutation reversion (python -m generator.inject --reset-anomalies)
  • Comprehensive test suite (41 unit & regression tests passing in 0.57s)

Phase 4 Status

Complete and verified.

The anomalous datasets and ground truth registry are ready for Phase 5 automated QA rule evaluation.


πŸ” Data & Privacy

ClaimIQ is intentionally designed around synthetic data.

The project will not contain:

  • Real patient information
  • Protected Health Information (PHI)
  • Real medical records
  • Real insurance member information
  • Real claims
  • Real payment transactions
  • Production payer connections
  • Production EHR integrations

All patient identifiers, provider identifiers, payer information, financial values, claims, procedures, and transactions will be generated synthetically.


🎯 Project Goals

The primary technical goals of ClaimIQ are to demonstrate:

  • SQL proficiency
  • Relational data modeling
  • Data-quality engineering
  • Data validation
  • Data analysis
  • QA methodology
  • Root-cause investigation
  • Operational workflow design
  • Reporting
  • Documentation
  • API development
  • Software testing
  • Security fundamentals
  • Performance analysis
  • AI-assisted data operations

The project is specifically designed to demonstrate practical skills relevant to Data Operations, RCM Operations, QA, Data Analysis, and AI-enabled operational systems.


⚠️ Project Scope

ClaimIQ is an educational and portfolio project.

It is not:

  • An EHR
  • A medical diagnosis platform
  • A clinical decision-support system
  • A production claims processor
  • A real insurance platform
  • A real payer gateway
  • A medical billing service
  • A replacement for healthcare infrastructure

No clinical decisions should be made using ClaimIQ.


πŸ§ͺ Development Philosophy

ClaimIQ follows a phased development and verification approach.

Each phase must:

  1. Define a clear objective
  2. Establish explicit deliverables
  3. Remain within its defined scope
  4. Validate its outputs
  5. Produce a completion report
  6. Establish readiness for the next phase

Features belonging to later phases should not be prematurely implemented.

This ensures that the project evolves from:

Requirements
     ↓
Architecture
     ↓
    Data
     ↓
Validation
     ↓
Analytics
     ↓
Application
     ↓
Operations
     ↓
    AI

rather than attempting to build the entire platform simultaneously.


πŸ“ˆ Long-Term Vision

The final ClaimIQ platform will provide a simulated end-to-end environment for healthcare claims data operations:

Synthetic Claims Data
        ↓
    Database
        ↓
  Automated QA
        ↓
Data Quality Analysis
        ↓
 Issue Detection
        ↓
 Investigation
        ↓
Resolution / Escalation
        ↓
Operational Reporting
        ↓
Trend Monitoring
        ↓
AI-Assisted Analysis

The ultimate objective is to demonstrate how data quality, operational processes, analytics, and AI can work together to improve the reliability of complex claims workflows.


πŸ“„ License

This project is intended for educational and portfolio purposes.

License information will be added as the project progresses.


Project Status

  • Phase 1 β€” Domain Research, Scope & Requirements Definition: βœ… Complete
  • Phase 2 β€” Database Architecture & Data Modeling: βœ… Complete
  • Phase 3 β€” Synthetic Healthcare Claims Data Generation: βœ… Complete
  • Phase 4 β€” Controlled Error Injection & Anomaly Dataset Engineering: βœ… Complete
  • Next Phase: Phase 5 β€” SQL Data Quality & QA Engine (πŸ”œ Next)

ClaimIQ
Healthcare Claims Data Quality & Operations Platform

About

Healthcare claims data quality and operations platform for detecting data discrepancies, validating RCM workflows, and supporting QA, analytics, and AI-assisted investigation using synthetic data.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages