Data Marts & Analytics

Disclaimer: For informational purposes only. This content is designed for data professionals learning healthcare domain knowledge, not for medical or insurance advice.
TL;DR

Tuva includes 13+ pre-built data marts: CMS-HCCs (risk adjustment), HEDIS/Quality Measures, Readmissions, Financial PMPM, Chronic Conditions, ED Classification, Pharmacy, Provider Attribution, AHRQ measures, CCSR, and more. Each mart produces analytics-ready tables that plug directly into BI tools.

Explain Like I'm 12

Imagine you want to build a Lego castle, but instead of starting with a pile of random bricks, someone gives you pre-built walls, towers, and gates. That's what data marts are. Instead of writing complex SQL from scratch every time you need an analytics report, Tuva gives you ready-made analytics tables that are already assembled from the raw data.

Each data mart is like a different section of the castle — one handles costs, another tracks quality scores, another flags patients who might get readmitted to the hospital. You just pick the ones you need and connect them to your dashboard tool.

Tuva Data Marts Architecture

Tuva's 13+ data marts built on top of the Core Data Model

What Are Data Marts?

Data marts are pre-built analytics layers that run on top of Tuva's Core Data Model. Think of the Core Model as a clean, standardized foundation — data marts are the specialized analytics modules that sit on top and produce tables ready for BI tools like Power BI, Tableau, or Looker.

Each mart is a collection of dbt models that transform the Core Data Model into analytics-ready output tables. You enable them via dbt variables — turn on the ones you need, run dbt build, and the tables appear in your warehouse.

Why this matters: Without Tuva, building a CMS-HCC risk adjustment pipeline from scratch takes months. With Tuva, you enable a variable and run dbt. The logic is open-source, peer-reviewed, and version-controlled.

All 13+ Data Marts

Here's the complete landscape of Tuva's data marts. Each one solves a specific healthcare analytics problem:

Data Mart What It Does Key Output Tables Use Case
CMS-HCCs Maps diagnoses to HCC categories, calculates RAF scores patient_risk_factors, patient_risk_scores Medicare Advantage risk adjustment
Quality Measures Calculates HEDIS-style quality measures summary_counts, summary_long STAR ratings, care gap identification
Readmissions Identifies 30-day all-cause readmissions readmission_summary, encounter_augmented CMS penalties, quality improvement
Financial PMPM Per-Member-Per-Month cost analysis pmpm_prep, pmpm_payer_plan Healthcare financial analytics
Chronic Conditions Groups patients by chronic conditions (CCW definitions) tuva_chronic_conditions_long, tuva_chronic_conditions_wide Population health segmentation
ED Classification Classifies ED visits: emergent, non-emergent, avoidable ed_classification_summary Utilization management
CCSR Maps ICD-10 codes to clinical categories ccsr_dx, ccsr_pr Clinical classification and grouping
HCC Suspecting Identifies undercoded conditions hcc_suspecting_list Revenue recovery, coding accuracy
HCC Recapture Tracks documentation gaps for known conditions hcc_recapture_list Annual coding completeness
Pharmacy Brand/generic classification, drug analysis pharmacy_claim_expanded Pharmacy cost and utilization
Provider Attribution Assigns members to primary care providers provider_attribution Value-based care, provider scorecards
AHRQ Measures Agency for Healthcare Research and Quality metrics ahrq_measures Patient safety, prevention quality
FHIR Preprocessing Transforms FHIR resources for Tuva ingestion fhir_staging tables FHIR-based data sources

CMS-HCCs (Risk Adjustment)

The CMS-HCC mart maps diagnosis codes to Hierarchical Condition Categories and calculates Risk Adjustment Factor (RAF) scores. This is the engine behind Medicare Advantage risk adjustment — the process that determines how much CMS pays a plan for each member.

How It Works

  1. Diagnosis mapping: ICD-10 codes from claims are mapped to HCC categories using CMS's official crosswalk
  2. Hierarchy application: Higher-severity HCCs supersede lower ones (e.g., Diabetes with complications trumps Diabetes without complications)
  3. Coefficient lookup: Each HCC has a coefficient (weight) from the CMS-HCC model
  4. RAF calculation: Sum of demographic factors + HCC coefficients + interaction terms = RAF score

Key Output Tables

  • patient_risk_factors: Every HCC mapped to each patient, with coefficients and model version
  • patient_risk_scores: Final RAF score per patient, broken down by demographic and disease components
  • hcc_suspecting: Conditions suggested by pharmacy or lab data but missing from claims (undercoding detection)
  • hcc_recapture: Chronic conditions documented last year but not yet documented this year (documentation gap tracking)
Why this is the most valuable mart: CMS-HCC is the most commercially valuable data mart in Tuva. Medicare Advantage plans gain or lose millions of dollars based on the accuracy of their risk scores. A single HCC that's missed across a large population can mean tens of millions in lost revenue.

Quality Measures (HEDIS)

The Quality Measures mart calculates HEDIS-style quality measures — the same metrics that drive CMS STAR ratings. It identifies which members are eligible for each measure (denominator), which members have met the measure (numerator), and which members have gaps in care.

What It Measures

  • Breast cancer screening (BCS): Women 50–74 who received a mammogram
  • Diabetes A1c control (HBD): Diabetic patients with controlled hemoglobin A1c
  • Controlling blood pressure (CBP): Hypertensive patients with controlled BP
  • Follow-up after hospitalization: Patients who received follow-up care within 7/30 days

Connection to STAR Ratings

Many CMS STAR rating measures come directly from HEDIS. If your HEDIS scores improve, your STAR ratings typically improve too. For Medicare Advantage plans, this means quality bonus payments worth 5% of the base benchmark — potentially hundreds of millions for large plans.

Care gap workflow: The Quality Measures mart produces a list of members with open care gaps. This feeds directly into outreach campaigns — call the patient, schedule the mammogram, close the gap, improve the STAR rating.

Readmissions

The Readmissions mart identifies 30-day all-cause readmissions — patients who are discharged from a hospital and readmitted within 30 days. CMS penalizes hospitals with higher-than-expected readmission rates through the Hospital Readmissions Reduction Program (HRRP).

What It Flags

  • Index admissions: The original hospital stay
  • Readmissions: Any subsequent admission within 30 days of discharge
  • Potentially preventable readmissions: Readmissions that could have been avoided with better discharge planning or follow-up care
  • Exclusions: Planned readmissions (scheduled surgeries) are excluded from penalty calculations
Financial impact: CMS reduces Medicare payments to hospitals with excess readmissions by up to 3%. For a large hospital system, this can mean millions in lost revenue annually. The readmissions mart helps identify patterns and target interventions.

Financial PMPM

The Financial PMPM mart calculates Per-Member-Per-Month cost analysis — the foundational metric of healthcare financial analytics. It breaks down total spend by member, service category, provider, and time period.

The PMPM Formula

PMPM = Total Cost / Member Months

If a plan spent $10 million on 5,000 members over 12 months (60,000 member months), the PMPM is $166.67. This single number tells you the average cost to insure one member for one month.

What the Mart Produces

  • Total PMPM: Combined medical + pharmacy spend per member per month
  • Medical PMPM: Broken down by inpatient, outpatient, professional, ED
  • Pharmacy PMPM: Brand vs. generic, specialty drug spend
  • Service category breakdown: Which types of services drive the most cost
  • Provider-level analysis: PMPM by provider group or facility
The most common metric in healthcare finance: PMPM = Total Cost / Member Months. Every actuarial report, every financial dashboard, every rate negotiation starts with PMPM. If you work in healthcare analytics, you will calculate PMPM constantly.

Chronic Conditions

The Chronic Conditions mart groups patients by chronic conditions using CMS Chronic Condition Warehouse (CCW) definitions. These are the official CMS algorithms for identifying conditions like diabetes, CHF, COPD, depression, and dozens more from claims data.

What It Enables

  • Population health segmentation: Group your member population by condition for targeted interventions
  • Comorbidity analysis: Identify members with multiple chronic conditions (the highest-cost, highest-risk group)
  • Prevalence tracking: Monitor condition rates over time across your population
  • Care management targeting: Prioritize members for disease management programs

ED Classification

The ED Classification mart classifies emergency department visits into categories: emergent, non-emergent, and avoidable. Non-emergent ED visits represent a massive cost opportunity — these patients could have been treated in a primary care setting at a fraction of the cost.

This mart is essential for utilization management teams who track ED usage patterns and design programs to redirect non-emergent visits to urgent care or telehealth.

CCSR (Clinical Classifications)

The CCSR mart maps ICD-10 codes to clinically meaningful categories using AHRQ's Clinical Classifications Software Refined system. Instead of working with 70,000+ individual ICD-10 codes, you can analyze data at the level of ~530 diagnosis categories and ~320 procedure categories.

CCSR replaces the older CCS (Clinical Classifications Software) system and is now the standard for clinical grouping in healthcare analytics.

Other Marts

Tuva includes several additional marts for specialized use cases:

  • AHRQ Measures: Patient safety indicators (PSIs) and prevention quality indicators (PQIs) from the Agency for Healthcare Research and Quality
  • Pharmacy: Expands pharmacy claims with brand/generic classification, therapeutic class, and drug-level analytics
  • Provider Attribution: Assigns each member to their primary care provider using claims-based attribution logic
  • FHIR Preprocessing: Transforms raw FHIR resources (Patient, Condition, MedicationRequest, etc.) into Tuva's Input Layer format for ingestion
  • HCC Recapture: Tracks chronic conditions documented in prior years but not yet documented in the current year — these are documentation gaps that need provider attention
  • HCC Suspecting: Identifies conditions suggested by pharmacy data (e.g., insulin prescriptions without a diabetes diagnosis) or lab results that haven't been coded on claims

Enabling Data Marts

Data marts are controlled via dbt variables in your dbt_project.yml. You can enable all marts at once or pick individual ones:

Enable All Marts

# dbt_project.yml
vars:
  tuva_marts_enabled: true

Enable Individual Marts

# dbt_project.yml
vars:
  cms_hcc_enabled: true
  quality_measures_enabled: true
  readmissions_enabled: true
  financial_pmpm_enabled: true
  chronic_conditions_enabled: true
  ed_classification_enabled: true

Then run dbt build and the enabled marts will materialize their output tables in your data warehouse.

Start small: Don't enable all 13+ marts on day one. Start with Financial PMPM and Chronic Conditions — they're the quickest wins. Add CMS-HCC and Quality Measures once you've validated the core data.

Connecting to BI Tools

Once the data marts run, their output tables live in your data warehouse (Snowflake, BigQuery, Redshift, Databricks, or DuckDB). Connecting to BI tools is straightforward — just point your tool at the mart tables.

Common Report Patterns

  • Executive PMPM dashboard: Connect to the Financial PMPM mart. Show total/medical/pharmacy PMPM trends by month, service category breakdown, and top cost drivers.
  • Risk adjustment scorecard: Connect to the CMS-HCC mart. Show RAF score distributions, HCC capture rates, suspecting opportunities, and recapture gaps.
  • Quality measures tracker: Connect to the Quality Measures mart. Show numerator/denominator rates per measure, gap counts, and distance to STAR thresholds.
  • Population health view: Connect to the Chronic Conditions mart. Show condition prevalence, comorbidity patterns, and high-risk member lists.
  • Readmission monitor: Connect to the Readmissions mart. Show 30-day readmission rates, trends, and contributing factors.

Test Yourself

Q: What are Tuva data marts, and how do they relate to the Core Data Model?

Data marts are pre-built analytics layers that run on top of Tuva's Core Data Model. The Core Model is the clean, standardized foundation (normalized claims, eligibility, conditions). Data marts are specialized dbt models that transform this foundation into analytics-ready output tables for specific use cases like risk adjustment, quality measures, and financial analysis. You enable them via dbt variables and run dbt build.

Q: How does the CMS-HCC data mart calculate RAF scores?

The CMS-HCC mart follows four steps: (1) Maps ICD-10 diagnosis codes from claims to HCC categories using the official CMS crosswalk, (2) Applies the HCC hierarchy so higher-severity conditions supersede lower ones, (3) Looks up the coefficient (weight) for each HCC from the CMS-HCC model, (4) Calculates the RAF score by summing demographic factors + HCC coefficients + interaction terms. The output includes patient_risk_factors (individual HCCs per patient) and patient_risk_scores (final RAF per patient).

Q: What is PMPM and why is it the most important metric in healthcare finance?

PMPM (Per-Member-Per-Month) = Total Cost / Member Months. It normalizes healthcare spending to a per-person-per-month basis, making it possible to compare costs across populations of different sizes and enrollment durations. Every actuarial report, financial dashboard, and rate negotiation in healthcare starts with PMPM. Tuva's Financial PMPM mart breaks this down by medical/pharmacy, service category, and provider.

Q: What is the difference between HCC suspecting and HCC recapture?

HCC suspecting identifies conditions suggested by indirect evidence (pharmacy data or lab results) that are NOT yet documented on claims. Example: a patient taking insulin but with no diabetes diagnosis code. HCC recapture tracks chronic conditions that WERE documented in prior years but haven't been re-documented in the current year. Since chronic conditions must be re-documented annually for risk adjustment, recapture ensures documentation completeness. Both represent revenue recovery opportunities.

Q: How do you enable specific data marts in Tuva?

Data marts are controlled via dbt variables in dbt_project.yml. You can enable all marts at once with tuva_marts_enabled: true, or enable individual marts with specific variables like cms_hcc_enabled: true, quality_measures_enabled: true, readmissions_enabled: true, etc. Then run dbt build and the enabled marts materialize their output tables in your data warehouse.

Interview Questions

Q: What is the CMS-HCC data mart used for?

The CMS-HCC data mart implements Medicare Advantage risk adjustment within Tuva. It maps ICD-10 diagnosis codes to Hierarchical Condition Categories (HCCs), applies the CMS hierarchy rules, and calculates Risk Adjustment Factor (RAF) scores for each patient. The output tables include patient_risk_factors (all mapped HCCs with coefficients), patient_risk_scores (final RAF per patient), hcc_suspecting (undercoded conditions identified from pharmacy/lab data), and hcc_recapture (chronic conditions from prior years not yet re-documented). This is the most commercially valuable mart because MA plans gain or lose millions based on RAF accuracy. A missed HCC across a large population can cost tens of millions in annual revenue.

Q: How does Tuva calculate PMPM?

Tuva's Financial PMPM mart calculates Per-Member-Per-Month costs using the formula: PMPM = Total Cost / Member Months. It pulls paid amounts from the Core Data Model's claims tables and member months from eligibility data. The mart breaks PMPM down by multiple dimensions: total, medical (inpatient, outpatient, professional, ED), pharmacy (brand vs. generic, specialty), service category, provider group, and time period. The output tables (pmpm_prep and pmpm_payer_plan) can be connected directly to BI tools for financial dashboards. PMPM is the foundational metric in healthcare finance — every actuarial report, rate negotiation, and cost trend analysis starts here.

Q: What is the difference between HCC suspecting and HCC recapture?

These are two complementary revenue recovery strategies in Tuva's risk adjustment pipeline. HCC suspecting identifies conditions that are likely present but never documented on claims. It looks for indirect evidence: a patient on insulin without a diabetes diagnosis, or abnormal lab values without a corresponding condition code. These are net-new coding opportunities. HCC recapture tracks conditions that were documented in prior years but haven't been re-documented in the current year. Since CMS requires annual re-documentation of chronic conditions for risk adjustment, any condition that "drops off" represents lost RAF score. Suspecting finds new revenue; recapture prevents revenue loss.

Q: How would you use Tuva's readmissions mart for quality improvement?

The Readmissions mart identifies 30-day all-cause readmissions and flags potentially preventable ones. For quality improvement: (1) Analyze readmission rates by diagnosis, provider, and facility to identify hotspots, (2) Examine the gap between index discharge and readmission — were follow-up appointments scheduled? Was medication reconciliation done? (3) Segment readmissions into planned (scheduled surgeries) and unplanned to focus on truly preventable cases, (4) Use the data to design interventions: enhanced discharge planning, transition-of-care programs, post-discharge phone calls, and medication management. (5) Track intervention effectiveness over time — are readmission rates actually declining? This directly impacts CMS penalties through the Hospital Readmissions Reduction Program, where hospitals with excess readmissions face up to 3% payment reductions.