Ch 2
╭─── Claude Code v2.0.35 ────────────────────────────────────────────────────────────────────────────────────────────────╮ │ │ Tips for getting started │ │ Welcome back Dan! │ Run /init to create a CLAUDE.md file with instructions for Claude │ │ │ ───────────────────────────────────────────────────────────────── │ │ ▗ ▗ ▖ ▖ │ Recent activity │ │ │ No recent activity │ │ ▘▘ ▝▝ │ │ │ │ │ │ Sonnet 4.5 · Claude Pro │ │ │ /Users/dan/Documents/ws/modeling-healthcare-data │ │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
use the hc-graph-generator skill to create a new MicroSim using the following requirements
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | |
⎿ ⧉ Selected 30 lines from docs/chapters/01-graph-theory-database-foundations/index.md in Visual Studio Code
⏺ I'll use the hc-graph-generator skill to create this healthcare graph visualization MicroSim for you.
The "hc-graph-generator" skill is running
The "hc-graph-generator" skill is running
⏺ I'll generate the healthcare graph visualization MicroSim following the skill's workflow. Let me start by gathering the requirements and checking for available icons.
⏺ Search(pattern: "hc-icons/*.svg") ⎿ Found 0 files
⏺ Now I'll create the MicroSim with the specified requirements. Let me start by creating the directory structure and generating all necessary files.
⏺ Bash(mkdir -p /Users/dan/Documents/ws/modeling-healthcare-data/docs/sims/healthcare-graph-fundamentals) ⎿ (No content)
⏺ Read(.claude/skills/hc-graph-generator/assets/template-main.html) ⎿ Read 83 lines
⏺ Read(.claude/skills/hc-graph-generator/assets/template-script.js) ⎿ Read 293 lines
⏺ Read(.claude/skills/hc-graph-generator/assets/template-style.css) ⎿ Read 369 lines
⏺ Read(.claude/skills/hc-graph-generator/assets/template-index.md) ⎿ Read 71 lines
⏺ Now I'll generate all the files for the healthcare graph fundamentals MicroSim. Let me start with the data file:
⏺ Write(docs/sims/healthcare-graph-fundamentals/healthcare-graph-fundamentals-data.json) ⎿ Wrote 122 lines to docs/sims/healthcare-graph-fundamentals/healthcare-graph-fundamentals-data.json { "nodes": [ { "id": 1, "label": "Sarah Chen", "type": "Patient", "properties": { "name": "Sarah Chen", "age": 58, "mrn": "MRN-2024-789012", … +112 lines (ctrl+o to expand)
⏺ Now I'll create the main.html file:
⏺ Write(docs/sims/healthcare-graph-fundamentals/main.html)
⎿ Wrote 88 lines to docs/sims/healthcare-graph-fundamentals/main.html
<!DOCTYPE html>
⏺ Now I'll create the script.js file:
⏺ Write(docs/sims/healthcare-graph-fundamentals/script.js) ⎿ Wrote 293 lines to docs/sims/healthcare-graph-fundamentals/script.js // Global variables let nodes, edges, network; let allNodes = []; let allEdges = []; let nodeTypes = new Set(); // Initialize on page load window.addEventListener('load', init); async function init() { … +283 lines (ctrl+o to expand)
⏺ Now I'll copy the style.css file and create the documentation:
⏺ Bash(cp /Users/dan/Documents/ws/modeling-healthcare-data/.claude/skills/hc-graph-generator/assets/template-style.css /Users/dan/Documents/ws/modeling-healthcare-data…) ⎿ (No content)
⏺ Now I'll create the index.md documentation:
⏺ Write(docs/sims/healthcare-graph-fundamentals/index.md)
⎿ Wrote 94 lines to docs/sims/healthcare-graph-fundamentals/index.md
# Healthcare Graph Fundamentals
View Healthcare Graph Fundamentals Fullscreen
This visualization demonstrates the fundamental components of a graph—nodes and edges—using a simple healthcare scenario. It features a patient (Sarah
Chen) interacting with various healthcare entities including a provider (Dr. Martinez), a diagnosis (Type 2 Diabetes), medication (Metformin), and a
facility (City Hospital).
## Overview
This interactive visualization illustrates what nodes (entities) and edges (relationships) are in graph theory by modeling a basic healthcare scenario.
Each node represents a distinct entity in the healthcare system with its own unique properties, while edges show the relationships between these
entities. This foundational example demonstrates how graph databases naturally model real-world healthcare interactions.
… +84 lines (ctrl+o to expand)
⏺ Now I need to add this MicroSim to the site navigation. Let me check the mkdocs.yml file:
⏺ Read(mkdocs.yml) ⎿ Read 98 lines
⏺ Now I'll add the MicroSim to the navigation in mkdocs.yml:
⏺ Update(mkdocs.yml)
⎿ Updated mkdocs.yml with 1 addition
39 - View Healcare Icons: sims/view-hc-icons/index.md
40 - Graph Viewer: sims/graph-viewer/index.md
41 - Codes: sims/codes/index.md
42 + - Healthcare Graph Fundamentals: sims/healthcare-graph-fundamentals/index.md
43 - Prompts:
44 - Introduction: prompts/index.md
45 - Icon: prompts/icon.md
⏺ Perfect! Let me verify the files were created successfully:
⏺ Bash(ls -la /Users/dan/Documents/ws/modeling-healthcare-data/docs/sims/healthcare-graph-fundamentals/)
⎿ total 80
drwxr-xr-x 7 dan staff 224 Nov 6 15:14 .
drwxr-xr-x@ 7 dan staff 224 Nov 6 15:12 ..
… +5 lines (ctrl+o to expand)
⏺ Excellent! I've successfully generated the Healthcare Graph Fundamentals MicroSim. Here's a comprehensive summary:
Successfully Generated HC Graph MicroSim: Healthcare Graph Fundamentals
Files Created:
/docs/sims/healthcare-graph-fundamentals/index.md /docs/sims/healthcare-graph-fundamentals/main.html /docs/sims/healthcare-graph-fundamentals/script.js /docs/sims/healthcare-graph-fundamentals/style.css /docs/sims/healthcare-graph-fundamentals/healthcare-graph-fundamentals-data.json
Data Summary:
- 5 nodes across 5 node types
- Patient (blue): Sarah Chen
- Provider (green): Dr. Martinez
- Diagnosis (orange): Type 2 Diabetes
- Medication (purple): Metformin
- Facility (yellow): City Hospital
- 5 directed edges (relationships)
- VISITED_PROVIDER: Patient → Provider
- DIAGNOSED_WITH: Provider → Diagnosis
- HAS_CONDITION: Patient → Diagnosis
- PRESCRIBED: Provider → Medication
- ADMITTED_TO: Patient → Facility
Educational Focus:
This visualization illustrates the fundamental components of a graph—nodes and edges—using a simple healthcare scenario. It demonstrates how nodes represent entities and edges represent relationships, forming the foundational building blocks of graph databases.
Key Features:
- All nodes are circles as requested, color-coded by type
- Dark gray arrows with labels showing directed relationships
- Interactive legend showing node types
- Hover tooltips and click-to-view details
- Search and filter capabilities
- Educational callouts and insights
- Heterogeneous properties (each node type has unique property sets)
Next Steps:
- View the visualization: docs/sims/healthcare-graph-fundamentals/main.html
- Read documentation: docs/sims/healthcare-graph-fundamentals/index.md
- Test locally: Run mkdocs serve and navigate to the MicroSims section
- Embed in chapter: Use this iframe code in your chapter content:
The MicroSim has been added to your mkdocs.yml navigation under "MicroSims > Healthcare Graph Fundamentals" and is ready to use!
use the hc-graph-generator skill to create a new MicroSim using the following requirements
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | |
⎿ ⧉ Selected 42 lines from docs/chapters/01-graph-theory-database-foundations/index.md in Visual Studio Code
⏺ I'll use the hc-graph-generator skill to create a DAG (Directed Acyclic Graph) visualization for the clinical care pathway.
The "hc-graph-generator" skill is running
The "hc-graph-generator" skill is running
⏺ I'll create a DAG visualization for the clinical care pathway. Let me design the data structure and generate all the necessary files.
⏺ Bash(mkdir -p /Users/dan/Documents/ws/modeling-healthcare-data/docs/sims/clinical-care-pathway-dag) ⎿ (No content)
⏺ Now I'll create the data file with the 8 care stage nodes and their connections:
⏺ Write(docs/sims/clinical-care-pathway-dag/clinical-care-pathway-dag-data.json) ⎿ Wrote 200 lines to docs/sims/clinical-care-pathway-dag/clinical-care-pathway-dag-data.json { "nodes": [ { "id": 1, "label": "Patient Admission", "type": "CareStage", "properties": { "stage": "Patient Admission", "stage_number": 1, "duration_estimate": "30 minutes", … +190 lines (ctrl+o to expand)
⏺ Now I'll create the main.html file with custom callouts about DAG properties:
⏺ Write(docs/sims/clinical-care-pathway-dag/main.html)
⎿ Wrote 88 lines to docs/sims/clinical-care-pathway-dag/main.html
<!DOCTYPE html>
⏺ Now I'll create the script.js file:
⏺ Write(docs/sims/clinical-care-pathway-dag/script.js) ⎿ Wrote 306 lines to docs/sims/clinical-care-pathway-dag/script.js // Global variables let nodes, edges, network; let allNodes = []; let allEdges = []; let nodeTypes = new Set(); // Initialize on page load window.addEventListener('load', init); async function init() { … +296 lines (ctrl+o to expand)
⏺ Now I'll copy the CSS file and create the documentation:
⏺ Bash(cp /Users/dan/Documents/ws/modeling-healthcare-data/.claude/skills/hc-graph-generator/assets/template-style.css /Users/dan/Documents/ws/modeling-healthcare-data…) ⎿ (No content)
⏺ Now I'll create the comprehensive documentation:
⏺ Write(docs/sims/clinical-care-pathway-dag/index.md)
⎿ Wrote 142 lines to docs/sims/clinical-care-pathway-dag/index.md
# Clinical Care Pathway DAG
View Clinical Care Pathway DAG Fullscreen
A Directed Acyclic Graph (DAG) visualization demonstrating how a patient's clinical care journey progresses through distinct stages without cycles.
This pathway shows the temporal progression from admission through discharge, emphasizing the acyclic nature of a single care encounter where patients
move forward through stages without returning to the beginning.
## Overview
This interactive visualization teaches what a Directed Acyclic Graph (DAG) is and why it's important in healthcare workflows. A DAG is a graph with
directed edges (arrows) that has no cycles—meaning you cannot start at one node and follow the arrows to return to that same node. In clinical care
pathways, this property ensures that each stage progresses forward in time without reverting to previous states during a single encounter.
… +132 lines (ctrl+o to expand)
⏺ Now I'll add this MicroSim to the site navigation:
⏺ Read(mkdocs.yml) ⎿ Read 10 lines
⏺ Update(mkdocs.yml)
⎿ Updated mkdocs.yml with 1 addition
40 - Graph Viewer: sims/graph-viewer/index.md
41 - Codes: sims/codes/index.md
42 - Healthcare Graph Fundamentals: sims/healthcare-graph-fundamentals/index.md
43 + - Clinical Care Pathway DAG: sims/clinical-care-pathway-dag/index.md
44 - Prompts:
45 - Introduction: prompts/index.md
46 - Icon: prompts/icon.md
⏺ Perfect! Let me verify the files were created successfully:
⏺ Bash(ls -la /Users/dan/Documents/ws/modeling-healthcare-data/docs/sims/clinical-care-pathway-dag/)
⎿ total 88
drwxr-xr-x 7 dan staff 224 Nov 6 15:30 .
drwxr-xr-x@ 8 dan staff 256 Nov 6 15:28 ..
… +5 lines (ctrl+o to expand)
⏺ Excellent! I've successfully generated the Clinical Care Pathway DAG MicroSim. Here's a comprehensive summary:
✅ Successfully Generated HC Graph MicroSim: Clinical Care Pathway DAG
📁 Files Created:
/docs/sims/clinical-care-pathway-dag/index.md /docs/sims/clinical-care-pathway-dag/main.html /docs/sims/clinical-care-pathway-dag/script.js /docs/sims/clinical-care-pathway-dag/style.css /docs/sims/clinical-care-pathway-dag/clinical-care-pathway-dag-data.json
📊 Data Summary:
- 8 nodes (1 node type: CareStage)
- Patient Admission → Initial Assessment → Diagnostic Testing → Test Results Review → Treatment Planning → Treatment Administration → Monitoring & Evaluation → Discharge Planning
- 8 directed edges
- 7 solid edges (dark blue) for main pathway
- 1 dashed edge (gray) for optional retest path (Test Results Review → Diagnostic Testing)
- Node types: CareStage (light blue rectangular boxes)
🎓 Educational Focus:
This visualization demonstrates a Directed Acyclic Graph (DAG) representing a clinical care pathway where stages progress without cycles. A DAG is a graph with directed edges that contains no cycles—you cannot start at a node and follow arrows to return to that same node. This property is essential for healthcare workflows where care episodes progress forward through time without returning to the beginning during a single encounter.
Key DAG Properties Demonstrated:
- No Cycles: Patients never return to admission during the same encounter
- Temporal Progression: Each stage moves forward in time chronologically
- Topological Ordering: Clear linear sequence from admission to discharge
- Conditional Paths: Optional retest edge shows flexibility without creating true cycles
🎨 Visual Features:
- Hierarchical Layout: Left-to-right flow emphasizing temporal progression
- Color Coding: Light blue nodes (#7dd3fc), dark blue edges (#1e40af)
- Edge Styles: Solid for main pathway, dashed for optional paths
- Educational Callouts: Explains DAG properties and acyclic nature
- Interactive Controls: Search, filter, hover tooltips, click for details
🔗 Next Steps:
- View the visualization: docs/sims/clinical-care-pathway-dag/main.html
- Read documentation: docs/sims/clinical-care-pathway-dag/index.md
- Test locally: Run mkdocs serve and navigate to MicroSims → Clinical Care Pathway DAG
- Embed in chapter: Use this iframe code in your chapter content:
The MicroSim has been added to your mkdocs.yml navigation under "MicroSims → Clinical Care Pathway DAG" and is ready to use! The visualization clearly demonstrates the DAG property with a flowchart-style layout showing temporal progression through the clinical care pathway.
/clear ⎿ (no content)
run the chapter-content-generator on chapter 2 at /docs/chapters/02-*/index.md
⏺ I'll help you run the chapter-content-generator on chapter 2. Let me first find the exact path to chapter 2.
⏺ Search(pattern: "docs/chapters/02-*/index.md") ⎿ Found 1 file (ctrl+o to expand)
⏺ Now I'll run the chapter-content-generator skill on chapter 2:
The "chapter-content-generator" skill is running
The "chapter-content-generator" skill is running
⏺ I'll now run the chapter-content-generator skill for chapter 2. Let me start by verifying the chapter structure and reading level.
⏺ Read(docs/chapters/02-intro-to-healthcare-systems/index.md) ⎿ Read 41 lines
⏺ Read(docs/course-description.md) ⎿ Read 206 lines
⏺ Read(~/.claude/skills/chapter-content-generator/references/reading-levels.md) ⎿ Read 245 lines
⏺ Read(~/.claude/skills/chapter-content-generator/references/content-element-types.md) ⎿ Read 595 lines
⏺ Perfect! I have all the information needed. Let me generate comprehensive chapter content for Chapter 2: Introduction to Healthcare Systems.
Verification Summary: - ✅ Chapter file exists at: /Users/dan/Documents/ws/modeling-healthcare-data/docs/chapters/02-intro-to-healthcare-systems/index.md - ✅ Title: "Introduction to Healthcare Systems" - ✅ Summary present - ✅ 20 concepts listed - ✅ Reading level: College Undergraduate (from course description)
Now I'll generate the detailed chapter content with appropriate reading level, pedagogical ordering, and rich non-text elements.
⏺ Read(docs/chapters/02-intro-to-healthcare-systems/index.md) ⎿ Read 41 lines
⏺ Now I'll generate the comprehensive chapter content:
⏺ Update(docs/chapters/02-intro-to-healthcare-systems/index.md)
⎿ Updated docs/chapters/02-intro-to-healthcare-systems/index.md with 1238 additions and 1 removal
37
38 ---
39
40 - TODO: Generate Chapter Content
40 + ## Introduction to the Healthcare Ecosystem
41 +
42 + The healthcare system represents one of the most complex information ecosystems in modern society, characterized by intricate
+ relationships among patients, providers, payers, regulatory bodies, pharmaceutical companies, and medical device manufacturers. Unlike
+ other industries where data flows are relatively straightforward, healthcare involves multi-directional information exchange across
+ organizational boundaries while maintaining strict privacy and security requirements. Understanding this ecosystem is essential for
+ designing graph data models that accurately capture the interconnected nature of clinical, financial, and administrative data.
43 +
44 + The United States healthcare system faces a distinctive challenge: it delivers world-class medical innovation while simultaneously
+ experiencing the highest per-person healthcare costs globally. This paradox stems from systemic inefficiencies in how healthcare services
+ are organized, delivered, and reimbursed. Graph database technologies offer promising solutions to these challenges by enabling more
+ sophisticated analytics on interconnected healthcare data, facilitating the transition from volume-based to value-based care models, and
+ supporting real-time clinical decision-making.
45 +
46 + Before diving into data modeling approaches, we must first understand the healthcare domain itself—the stakeholders, workflows,
+ terminology, and data standards that shape how healthcare information is captured, exchanged, and analyzed.
47 +
48 + Healthcare Ecosystem Stakeholder Diagram
50 + Type: diagram
51 +
52 + Purpose: Illustrate the three primary stakeholder perspectives in healthcare and their key relationships
53 +
54 + Components to show:
55 + - Central triangle with three points labeled: "Patient", "Provider", and "Payer"
56 + - Each stakeholder as a different colored circle (Patient: blue, Provider: green, Payer: orange)
57 + - Bidirectional arrows connecting all three stakeholders
58 + - Secondary entities around the perimeter: Pharmacy, Lab, Hospital, Clinic, Insurance Company, Employer, Government
59 +
60 + Relationships (arrows with labels):
61 + - Patient ↔ Provider: "Care Delivery", "Medical Records"
62 + - Provider ↔ Payer: "Claims", "Reimbursement"
63 + - Payer ↔ Patient: "Coverage", "Premiums"
64 + - Provider → Pharmacy: "Prescriptions"
65 + - Provider → Lab: "Test Orders", "Results"
66 + - Payer → Pharmacy: "Formulary Rules", "Reimbursement"
67 + - Employer → Payer: "Group Coverage"
68 + - Government → Payer: "Regulations", "Medicare/Medicaid"
69 +
70 + Style: Network diagram with central triangle and satellite nodes
71 +
72 + Visual hierarchy:
73 + - Primary stakeholders (larger circles, bold labels)
74 + - Secondary entities (smaller circles, regular labels)
75 + - Primary relationships (thick arrows)
76 + - Secondary relationships (thin arrows)
77 +
78 + Color scheme:
79 + - Patient entities: Blue tones
80 + - Provider entities: Green tones
81 + - Payer entities: Orange tones
82 + - Government/regulatory: Gray
83 +
84 + Annotations:
85 + - Label showing "Data flows in all directions"
86 + - Note: "Each relationship generates complex data exchanges"
87 +
88 + Implementation: SVG-based diagram or Mermaid diagram embedded in markdown
89 +
91 + ## Understanding Healthcare Economics
92 +
93 + ### The Healthcare Cost Crisis
94 +
95 + Healthcare cost refers to the total financial resources consumed by healthcare services, encompassing direct medical expenses
+ (physician fees, hospital charges, medications, procedures) as well as indirect costs (administrative overhead, insurance processing,
+ regulatory compliance). In the United States, total healthcare expenditures exceeded $4.3 trillion in 2021, representing approximately
+ 18.3% of the nation's GDP—far exceeding other developed nations where healthcare typically represents 9-12% of GDP.
96 +
97 + The per-person healthcare cost metric provides a normalized view of healthcare spending by dividing total expenditures by population.
+ In 2021, the United States averaged approximately $12,900 per person annually, compared to $6,000-7,000 in other high-income countries like
+ Germany, Canada, and France. This dramatic cost differential exists despite comparable or sometimes superior health outcomes in
+ lower-spending nations, indicating systemic inefficiencies in the U.S. healthcare delivery and payment models.
98 +
99 + Several factors contribute to elevated U.S. healthcare costs:
100 +
101 + - Administrative complexity: Fragmented payer systems require extensive billing, coding, and authorization processes
102 + - Fee-for-service incentives: Payment models that reward volume over value
103 + - Pharmaceutical pricing: Higher drug prices compared to international markets with price controls
104 + - Defensive medicine: Excessive testing and procedures driven by liability concerns
105 + - Chronic disease burden: Growing prevalence of expensive chronic conditions requiring long-term management
106 + - Technology adoption costs: Expensive medical equipment and electronic health record systems
107 + - Market consolidation: Hospital and provider mergers reducing competition
108 +
109 + Per-Person Healthcare Cost Comparison Chart
111 + Type: chart
112 +
113 + Chart type: Bar chart with dual y-axis
114 +
115 + Purpose: Compare per-person healthcare spending across countries and show U.S. cost premium
116 +
117 + X-axis: Countries (United States, Switzerland, Germany, Sweden, Netherlands, France, Canada, United Kingdom, Japan)
118 +
119 + Y-axis (left): Per-person annual healthcare spending (USD)
120 + Y-axis (right): Healthcare spending as % of GDP
121 +
122 + Data series 1 (bars - primary y-axis):
123 + - United States: $12,914
124 + - Switzerland: $7,138
125 + - Germany: $6,731
126 + - Sweden: $6,262
127 + - Netherlands: $6,190
128 + - France: $5,564
129 + - Canada: $5,418
130 + - United Kingdom: $5,087
131 + - Japan: $4,691
132 +
133 + Data series 2 (line with markers - secondary y-axis):
134 + - United States: 18.3%
135 + - Switzerland: 11.3%
136 + - Germany: 11.7%
137 + - Sweden: 10.9%
138 + - Netherlands: 10.1%
139 + - France: 11.0%
140 + - Canada: 10.8%
141 + - United Kingdom: 10.2%
142 + - Japan: 10.9%
143 +
144 + Color scheme:
145 + - U.S. bar: Red (to highlight)
146 + - Other countries: Blue
147 + - Line graph: Orange with circular markers
148 +
149 + Title: "Per-Person Healthcare Spending: United States vs. Comparable Nations (2021)"
150 +
151 + Annotations:
152 + - Arrow pointing to U.S. bar: "2x higher than comparable nations"
153 + - Shaded region showing "Typical range for developed nations"
154 + - Data source note: "OECD Health Statistics 2022"
155 +
156 + Legend: Position top-right showing bar and line meanings
157 +
158 + Implementation: Chart.js library with responsive design
159 +
161 + ### Payment Models: Fee-For-Service vs. Value-Based Care
162 +
163 + The fee-for-service model (FFS) represents the traditional healthcare payment approach where providers receive reimbursement for each
+ individual service, procedure, test, or visit performed. Under FFS, a physician conducting a 15-minute office visit, ordering two lab
+ tests, and performing a minor procedure would bill separately for each component. This model creates problematic incentives: providers
+ generate more revenue by delivering more services, regardless of whether those services improve patient outcomes or represent the most
+ efficient care pathway.
164 +
165 + Fee-for-service contributes to healthcare cost escalation through several mechanisms:
166 +
167 + - Volume incentives: Providers are rewarded for quantity rather than quality of care
168 + - Fragmented care: Each specialist focuses on their narrow domain without coordinating across the patient's complete care needs
169 + - Overutilization: Financial incentives favor performing additional tests and procedures
170 + - Reactive rather than preventive: Payment occurs when patients are sick, not for keeping them healthy
171 + - Administrative burden: Each service requires separate coding, billing, and claims processing
172 +
173 + Here's a comparison of the fundamental differences between payment models:
174 +
175 + | Dimension | Fee-For-Service | Value-Based Care |
176 + |-----------|----------------|------------------|
177 + | Payment basis | Per service/procedure | Per patient or outcome |
178 + | Risk bearer | Payer assumes risk | Provider assumes partial/full risk |
179 + | Primary incentive | Maximize service volume | Improve outcomes, reduce costs |
180 + | Care coordination | Minimal | Essential |
181 + | Data requirements | Service codes, charges | Outcomes, quality metrics, costs |
182 + | Preventive care focus | Low | High |
183 + | Technology needs | Billing systems | Analytics, predictive models |
184 + | Provider mindset | "How many patients can I see?" | "How can I keep patients healthy?" |
185 +
186 + Value-based care (VBC) represents a fundamental restructuring of healthcare economics, where providers receive compensation based on
+ patient health outcomes rather than service volume. Under value-based models, providers might receive a fixed payment per patient
+ (capitation), bonus payments for achieving quality benchmarks, or shared savings when they deliver care more efficiently than baseline
+ costs. This alignment of financial incentives with patient outcomes theoretically encourages providers to emphasize prevention, care
+ coordination, and evidence-based medicine.
187 +
188 + Value-based care models include several variants:
189 +
190 + - Pay-for-Performance (P4P): Bonus payments for meeting quality metrics
191 + - Bundled Payments: Single payment covering all services for an episode of care
192 + - Accountable Care Organizations (ACOs): Provider groups sharing responsibility for patient populations
193 + - Capitation: Fixed per-patient-per-month payment regardless of services consumed
194 + - Shared Savings/Risk: Providers share financial gains from cost reductions while maintaining quality
195 +
196 + Healthcare Payment Model Comparison MicroSim
198 + Type: microsim
199 +
200 + Learning objective: Enable students to explore how different payment models affect provider behavior, healthcare costs, and patient
+ outcomes through an interactive simulation
201 +
202 + Canvas layout (1000x700px):
203 + - Top section (1000x150): Title and model selector
204 + - Left side (650x550): Visualization area showing patient flow and costs
205 + - Right side (350x550): Control panel and metrics dashboard
206 +
207 + Visual elements in simulation area:
208 + - 10 patient icons moving through a healthcare journey
209 + - Provider building (hospital icon)
210 + - Service stations: Office Visit, Lab Tests, Imaging, Procedures, Follow-up
211 + - Money indicators ($) showing costs generated
212 + - Health meter for each patient (green=healthy, yellow=moderate, red=poor)
213 + - Timeline showing days elapsed
214 +
215 + Interactive controls (right panel):
216 +
217 + 1. Payment Model Selector (radio buttons):
218 + - Fee-For-Service
219 + - Value-Based Care (Bundled Payment)
220 + - Value-Based Care (Capitation)
221 + - Value-Based Care (ACO Shared Savings)
222 +
223 + 2. Patient Population Characteristics (sliders):
224 + - Chronic disease prevalence: 0-50% (default: 30%)
225 + - Health literacy level: Low/Medium/High (default: Medium)
226 + - Complexity of conditions: Simple/Mixed/Complex (default: Mixed)
227 +
228 + 3. Provider Behavior Parameters (sliders):
229 + - Care coordination investment: 0-100% (default: 50%)
230 + - Preventive care emphasis: 0-100% (default: 50%)
231 + - Technology adoption: 0-100% (default: 50%)
232 +
233 + 4. Simulation Controls:
234 + - "Start Simulation" button
235 + - "Reset" button
236 + - Speed slider: 1x to 10x (default: 3x)
237 + - "Pause/Resume" button
238 +
239 + Metrics Dashboard (updates in real-time):
240 + - Total Cost per Patient: $X,XXX
241 + - Number of Services per Patient: X.X
242 + - Average Health Outcome Score: XX/100
243 + - Provider Revenue: $XX,XXX
244 + - Provider Margin: XX%
245 + - Preventive Services Ratio: XX%
246 + - Emergency Visit Rate: XX%
247 + - Patient Satisfaction: XX/100
248 +
249 + Default parameters for each payment model:
250 +
251 + Fee-For-Service:
252 + - Base office visit: $150
253 + - Lab test: $100
254 + - Imaging: $400
255 + - Procedure: $800
256 + - Follow-up: $120
257 + - Provider incentive: Maximize service volume
258 + - Typical services per patient: 8-12
259 + - Total cost per patient: $3,500-5,000
260 +
261 + Bundled Payment (episode of care):
262 + - Bundle payment: $3,000 per episode
263 + - Provider keeps savings if costs < $3,000
264 + - Provider loses money if costs > $3,000
265 + - Provider incentive: Efficient care delivery
266 + - Typical services per patient: 5-7
267 + - Total cost per patient: $2,500-3,200
268 +
269 + Capitation:
270 + - Per-member-per-month: $250
271 + - Covers all services for time period
272 + - Provider incentive: Prevention and care coordination
273 + - Typical services per patient: 3-5
274 + - Total cost per patient: $1,800-2,800
275 +
276 + Behavior modeling:
277 +
278 + Under Fee-For-Service:
279 + - Patients undergo more diagnostic tests
280 + - More procedures performed
281 + - More follow-up visits scheduled
282 + - Less investment in prevention
283 + - Higher short-term costs
284 + - Outcomes: moderate improvement
285 +
286 + Under Value-Based Care:
287 + - More preventive services
288 + - Better care coordination
289 + - Fewer unnecessary tests
290 + - More patient education
291 + - Lower long-term costs
292 + - Outcomes: greater improvement
293 +
294 + Animation behavior:
295 + - Patient icons move through service stations
296 + - $ icons pop up when services delivered
297 + - Health meters change color based on care received
298 + - Cost counter increments
299 + - Comparison metrics update continuously
300 + - At end, show side-by-side comparison of models
301 +
302 + Visual feedback:
303 + - Highlight differences in care pathways between models
304 + - Show cost accumulation differently (rapid under FFS, controlled under VBC)
305 + - Display outcome improvements with color changes
306 + - Graph total cost trajectory over time
307 +
308 + Educational annotations:
309 + - Hover over service stations to see costs and frequency
310 + - Click patient icons to see individual care journey
311 + - Hover over metrics to see explanations
312 + - Display key insights when simulation completes
313 +
314 + Implementation notes:
315 + - Use p5.js for rendering and animation
316 + - Store model parameters in JavaScript objects
317 + - Implement simple probability models for care decisions
318 + - Use random variation within realistic ranges
319 + - Ensure reproducible results with seed option
320 + - Include "Explanation" mode that pauses and highlights key decision points
321 +
322 + Implementation: p5.js with HTML/CSS controls, deployed in /docs/sims/healthcare-payment-models/
323 +
325 + The transition from fee-for-service to value-based care represents one of the most significant ongoing transformations in U.S. healthcare.
+ This shift creates substantial data challenges: VBC requires comprehensive patient data across time and care settings, sophisticated risk
+ stratification models, real-time quality measurement, and predictive analytics to identify high-risk patients before expensive
+ complications occur. Graph databases excel at these requirements by naturally representing the complex, interconnected relationships among
+ patients, providers, conditions, treatments, and outcomes.
326 +
327 + ## Key Healthcare Stakeholders
328 +
329 + ### The Healthcare Patient
330 +
331 + The healthcare patient represents an individual receiving or seeking medical services, but in data modeling terms, patients are far
+ more than simple demographic records. A patient embodies a complex information entity with temporal clinical history, multiple concurrent
+ conditions, medication regimens, procedure histories, care team relationships, insurance coverage, care preferences, family medical
+ history, social determinants of health, and longitudinal outcomes. Modern healthcare informatics increasingly recognizes patients as active
+ participants in their care rather than passive recipients, which implies bidirectional information flows and patient-generated health
+ data.
332 +
333 + Patient demographics encompass the core identifying and descriptive attributes of individuals within healthcare systems, including
+ age, gender, race, ethnicity, language preferences, contact information, emergency contacts, and social determinants of health such as
+ education level, housing stability, food security, and transportation access. While traditional healthcare systems limited demographics to
+ administrative identifiers, contemporary population health approaches recognize that demographic and social factors significantly influence
+ health outcomes and care utilization patterns. Graph models naturally accommodate this complexity by representing demographic attributes
+ as node properties while allowing flexible connections to social determinant nodes that may be shared across patient populations.
334 +
335 + From a graph modeling perspective, patient nodes serve as central hubs connecting to:
336 +
337 + - Provider relationships (primary care physician, specialists, care team members)
338 + - Encounter history (office visits, emergency department visits, hospitalizations, telehealth sessions)
339 + - Condition and diagnosis nodes (chronic diseases, acute conditions, resolved issues)
340 + - Medication regimens (current prescriptions, historical medications, allergies)
341 + - Procedure history (surgeries, diagnostic tests, imaging studies, treatments)
342 + - Insurance coverage (current and historical payer relationships)
343 + - Clinical documents (lab results, radiology reports, clinical notes)
344 + - Care plans and treatment protocols
345 + - Family relationships and medical history
346 + - Social determinants and community resources
347 +
348 + ### The Healthcare Provider
349 +
350 + The healthcare provider encompasses individuals and organizations delivering medical services, including physicians (primary care and
+ specialists), nurses, physician assistants, nurse practitioners, therapists, hospitals, clinics, urgent care centers, skilled nursing
+ facilities, home health agencies, and ancillary service providers such as laboratories and imaging centers. In healthcare data ecosystems,
+ providers function as both data generators (creating clinical documentation, ordering tests, prescribing medications) and data consumers
+ (reviewing patient histories, analyzing test results, coordinating care across teams).
351 +
352 + Provider entities in graph models require rich property sets and relationship structures:
353 +
354 + Individual provider properties:
355 +
356 + - National Provider Identifier (NPI)
357 + - Specialties and subspecialties
358 + - Board certifications
359 + - License jurisdictions
360 + - Practice locations
361 + - Hospital affiliations
362 + - Accepting new patients status
363 + - Languages spoken
364 +
365 + Organizational provider properties:
366 +
367 + - Facility type (hospital, clinic, urgent care, etc.)
368 + - Bed capacity (for hospitals)
369 + - Service lines offered
370 + - Accreditation status
371 + - Quality ratings
372 + - Medicare/Medicaid participation
373 + - Insurance networks participated
374 +
375 + Provider relationships in graph models:
376 +
377 + - Affiliation: Individual provider → Organization provider
378 + - Referral networks: Provider → Provider (referral patterns)
379 + - Care team: Multiple providers → Patient (coordinated care)
380 + - Coverage arrangements: Provider → Provider (call coverage, backup)
381 + - Supervision: Attending physician → Resident/Fellow
382 + - Consultation: Requesting provider → Consulting provider
383 +
384 + ### The Healthcare Payer
385 +
386 + The healthcare payer represents entities that finance healthcare services, primarily insurance companies (commercial insurers, Blue
+ Cross Blue Shield plans), government programs (Medicare, Medicaid, TRICARE, Veterans Affairs), and self-insured employers. Payers play a
+ critical role in healthcare data ecosystems by adjudicating claims, negotiating provider payment rates, establishing coverage policies,
+ managing formularies, detecting fraud and abuse, and increasingly, driving quality improvement initiatives through value-based payment
+ models.
387 +
388 + Payer organizations maintain extensive data on:
389 +
390 + - Member enrollment and eligibility
391 + - Benefit plan designs and coverage rules
392 + - Provider networks and contracted rates
393 + - Claims history (submitted, adjudicated, paid, denied)
394 + - Prior authorization requirements and approvals
395 + - Utilization management (case management, disease management)
396 + - Quality metrics and performance scorecards
397 + - Fraud, waste, and abuse detection patterns
398 + - Pharmacy benefits and formulary rules
399 + - Care management programs
400 +
401 + The payer-provider-patient triangle creates complex data exchange requirements:
402 +
403 + | Data Flow | Information Exchanged | Purpose |
404 + |-----------|----------------------|---------|
405 + | Patient → Payer | Enrollment applications, eligibility verification requests | Establish/confirm coverage |
406 + | Payer → Patient | Insurance cards, benefit explanations, claim denials, EOBs | Communicate coverage details |
407 + | Provider → Payer | Claims, prior authorization requests, medical records | Seek reimbursement, approval |
408 + | Payer → Provider | Claim adjudication results, authorization decisions, payment | Reimburse services, manage utilization |
409 + | Payer → Patient → Provider | Insurance information, coverage details | Enable billing and care decisions |
410 +
411 + ## Clinical Operations and Healthcare Data
412 +
413 + ### Medical Encounters
414 +
415 + A medical encounter represents any interaction between a patient and healthcare provider for the purpose of assessment, diagnosis,
+ treatment, counseling, or preventive care. Encounters vary widely in type, setting, duration, and complexity, ranging from brief telehealth
+ check-ins to multi-day intensive care hospitalizations. From a data modeling perspective, encounters serve as temporal containers that
+ link patients, providers, locations, diagnoses, procedures, medications, and charges within a specific timeframe.
416 +
417 + Encounter types include:
418 +
419 + - Ambulatory/Outpatient: Office visits, clinic appointments, urgent care visits
420 + - Emergency: Emergency department visits for acute conditions
421 + - Inpatient: Hospital admissions requiring overnight stays
422 + - Observation: Short-term hospital monitoring without formal admission
423 + - Surgical: Operating room procedures (may be inpatient or outpatient)
424 + - Telehealth: Virtual visits via video, phone, or asynchronous messaging
425 + - Home Health: Provider visits to patient's residence
426 + - Skilled Nursing: Care in long-term care facilities
427 + - Hospice: End-of-life care services
428 +
429 + Each encounter generates substantial structured and unstructured data:
430 +
431 + Structured encounter data:
432 +
433 + - Encounter ID (unique identifier)
434 + - Encounter type and class
435 + - Admission/start date-time
436 + - Discharge/end date-time
437 + - Primary and secondary diagnoses (ICD codes)
438 + - Procedures performed (CPT/HCPCS codes)
439 + - Chief complaint and reason for visit
440 + - Attending provider and care team
441 + - Facility and department location
442 + - Disposition (discharged home, admitted, transferred, etc.)
443 + - Length of stay
444 + - Total charges and expected reimbursement
445 +
446 + Unstructured encounter data:
447 +
448 + - Provider clinical notes (history and physical, progress notes, discharge summaries)
449 + - Nursing documentation
450 + - Radiology and lab reports
451 + - Pathology findings
452 + - Operative reports
453 + - Consultation notes
454 +
455 + Clinical Encounter Workflow Diagram
457 + Type: workflow
458 +
459 + Purpose: Illustrate the typical flow of a patient encounter from arrival through billing, showing data capture points and system
+ interactions
460 +
461 + Visual style: Swimlane flowchart with four lanes representing different roles/systems
462 +
463 + Swimlanes:
464 + 1. Patient
465 + 2. Clinical Staff (Registration, Nursing, Physician)
466 + 3. Clinical Systems (EHR, CPOE, Lab/Imaging)
467 + 4. Administrative Systems (Billing, Claims)
468 +
469 + Workflow steps:
470 +
471 + Patient Lane:
472 + 1. Patient Arrives
473 + Hover: "Patient presents to clinic or hospital"
474 +
475 + 2. Provides Information
476 + Hover: "Demographics, insurance, chief complaint"
477 +
478 + 3. Undergoes Care
479 + Hover: "Examination, tests, procedures, treatments"
480 +
481 + 4. Receives Instructions
482 + Hover: "Discharge instructions, prescriptions, follow-up appointments"
483 +
484 + 5. Receives Bill/EOB
485 + Hover: "Explanation of Benefits showing charges and coverage"
486 +
487 + Clinical Staff Lane:
488 + 1. Registration
489 + Hover: "Verify identity, check insurance eligibility, collect copay"
490 + Data captured: Demographics, insurance, reason for visit
491 +
492 + 2. Triage/Vitals
493 + Hover: "Record vital signs, chief complaint, medications, allergies"
494 + Data captured: Blood pressure, temperature, pulse, height, weight
495 +
496 + 3. Provider Assessment
497 + Hover: "History, physical exam, differential diagnosis"
498 + Data captured: History of present illness, review of systems, exam findings
499 +
500 + 4. Order Entry
501 + Hover: "Labs, imaging, medications, procedures"
502 + Data captured: Orders sent to CPOE
503 +
504 + 5. Results Review
505 + Hover: "Interpret test results, revise diagnosis"
506 + Data captured: Results integrated into EHR
507 +
508 + 6. Documentation
509 + Hover: "Clinical notes, diagnosis codes, procedure codes"
510 + Data captured: Encounter note, ICD codes, CPT codes
511 +
512 + 7. Discharge/Follow-up
513 + Hover: "Prescriptions, referrals, next appointment"
514 + Data captured: Care plan, prescriptions, referral orders
515 +
516 + Clinical Systems Lane:
517 + 1. EHR: Create Encounter
518 + Hover: "New encounter record created with patient context"
519 +
520 + 2. CPOE: Receive Orders
521 + Hover: "Computerized Provider Order Entry processes orders"
522 +
523 + 3. Lab/Imaging: Perform Tests
524 + Hover: "Diagnostic services execute ordered tests"
525 +
526 + 4. Results Interface
527 + Hover: "Test results flow back to EHR via HL7/FHIR"
528 +
529 + 5. EHR: Document Finalization
530 + Hover: "Provider signs note, triggers billing process"
531 +
532 + Administrative Systems Lane:
533 + 1. Eligibility Check
534 + Hover: "Real-time verification of insurance coverage"
535 + System: Claims clearinghouse or payer portal
536 +
537 + 2. Charge Capture
538 + Hover: "Extract billable services from clinical documentation"
539 + System: Charge Description Master (CDM)
540 +
541 + 3. Medical Coding
542 + Hover: "Assign ICD, CPT, HCPCS codes to encounter"
543 + System: Coding module (may use AI/NLP assistance)
544 +
545 + 4. Claim Generation
546 + Hover: "Create CMS-1500 or UB-04 claim with all required data elements"
547 + System: Billing system
548 +
549 + 5. Claim Submission
550 + Hover: "Electronic submission to payer via EDI 837 transaction"
551 + System: Claims clearinghouse
552 +
553 + 6. Adjudication Wait
554 + Hover: "Payer reviews claim, determines payment"
555 + System: Payer adjudication engine
556 +
557 + 7. Payment Posting
558 + Hover: "Record payment, contractual adjustments, patient responsibility"
559 + System: Billing system accounts receivable
560 +
561 + Decision points:
562 + - After Registration: Is eligibility active? (Yes → Continue, No → Patient pay or reschedule)
563 + - After Provider Assessment: Admit to hospital? (Yes → Inpatient workflow, No → Continue outpatient)
564 + - After Documentation: Coding complete? (Yes → Submit claim, No → Return to coder)
565 + - After Claim Submission: Claim accepted? (Yes → Wait for payment, No → Fix errors and resubmit)
566 +
567 + Color coding:
568 + - Patient activities: Blue
569 + - Clinical activities: Green
570 + - System processes: Purple
571 + - Financial processes: Orange
572 + - Decision points: Yellow diamonds
573 +
574 + Annotations:
575 + - Typical timeframes for key stages
576 + - Data standards used (HL7, FHIR, X12)
577 + - Common pain points and delays
578 +
579 + Implementation: Mermaid diagram or interactive SVG with hover states, embedded in markdown or as separate HTML file
580 +
582 + ### Clinical Workflows
583 +
584 + Clinical workflow describes the sequence of tasks, decisions, handoffs, and information exchanges that occur during healthcare
+ delivery. Clinical workflows span multiple timeframes—from seconds (responding to a cardiac arrest) to years (managing chronic disease
+ progression)—and involve coordination across diverse roles, systems, and organizations. Effective graph modeling of healthcare data
+ requires understanding these workflows because they determine how data elements relate temporally and causally.
585 +
586 + Common clinical workflows include:
587 +
588 + Ambulatory Care Workflow:
589 + 1. Appointment scheduling and pre-visit planning
590 + 2. Check-in and registration
591 + 3. Triage and vital signs collection
592 + 4. Provider encounter (history, examination, assessment, plan)
593 + 5. Order entry (labs, imaging, medications, referrals)
594 + 6. Patient education and discharge instructions
595 + 7. Follow-up appointment scheduling
596 + 8. Results notification and management
597 +
598 + Inpatient Care Workflow:
599 + 1. Admission (emergency department, direct admit, transfer)
600 + 2. Initial assessment and order set activation
601 + 3. Daily rounding and progress notes
602 + 4. Order management and care plan updates
603 + 5. Multidisciplinary care coordination (nursing, pharmacy, case management, therapy)
604 + 6. Transition planning (discharge planning, post-acute care arrangements)
605 + 7. Discharge and follow-up
606 +
607 + Medication Management Workflow:
608 + 1. Provider prescribing (with clinical decision support checks)
609 + 2. Pharmacist verification and screening
610 + 3. Dispensing and labeling
611 + 4. Nursing administration (inpatient) or patient pickup (outpatient)
612 + 5. Medication reconciliation at transitions of care
613 + 6. Adherence monitoring and refill management
614 + 7. Adverse event monitoring and reporting
615 +
616 + ### Electronic Health Records
617 +
618 + The electronic health record (EHR) serves as the digital repository for patient clinical data, replacing paper charts with structured
+ and unstructured electronic information. EHR systems capture, store, and present patient data to support clinical decision-making, care
+ coordination, quality measurement, and regulatory reporting. Unlike simple digitized records, modern EHRs include clinical decision
+ support, computerized provider order entry (CPOE), interoperability interfaces, patient portals, population health analytics, and revenue
+ cycle integration.
619 +
620 + Major EHR vendors include Epic, Cerner (Oracle Health), Meditech, Allscripts, athenahealth, and eClinicalWorks, each with proprietary data
+ models and varying interoperability capabilities. This fragmentation creates challenges for healthcare data integration, as different EHRs
+ structure information differently despite adherence to common standards like HL7 and FHIR.
621 +
622 + Core EHR functionality:
623 +
624 + - Clinical documentation: Notes, templates, voice recognition, natural language processing
625 + - Medication management: ePrescribing, medication reconciliation, drug interaction checking
626 + - Order entry: Labs, imaging, procedures, consultations with clinical decision support
627 + - Results management: Lab, pathology, and radiology result review and acknowledgment
628 + - Problem lists: Active and historical diagnoses and conditions
629 + - Care planning: Treatment protocols, goals, interventions, care team coordination
630 + - Patient portal: Secure messaging, test result access, appointment scheduling, bill payment
631 +
632 + EHR data challenges for graph modeling:
633 +
634 + - Data model variability: Each EHR structures data differently (relational tables, objects, documents)
635 + - Unstructured content: Clinical notes contain rich information not captured in structured fields
636 + - Temporal complexity: Data elements have effective dates, update histories, and validity periods
637 + - Relationship inference: Many relationships are implicit and must be inferred from context
638 + - Data quality issues: Missing data, inconsistent terminology, duplicate records, data entry errors
639 +
640 + ## Medical Terminology and Coding Systems
641 +
642 + ### Medical Terminology
643 +
644 + Medical terminology represents the specialized language of healthcare, built from Greek and Latin roots combined systematically to
+ describe anatomical structures, physiological processes, pathological conditions, diagnostic procedures, and therapeutic interventions.
+ Medical terms follow consistent construction rules: roots (word cores), prefixes (modifiers preceding roots), and suffixes (modifiers
+ following roots). For example, "gastroenterology" combines "gastro-" (stomach), "entero-" (intestine), and "-logy" (study of) to indicate
+ the study of digestive system disorders.
645 +
646 + Understanding medical terminology is essential for healthcare data modeling because:
647 +
648 + - Precision: Medical terms convey specific clinical meanings that general language cannot capture
649 + - Standardization: Consistent terminology enables clear communication across providers and systems
650 + - Semantic relationships: Term structure reveals hierarchical and relational connections (e.g., all "-itis" terms indicate
+ inflammation)
651 + - Code mapping: Medical terminology forms the foundation for medical coding systems
652 +
653 + Common medical terminology patterns:
654 +
655 + | Component | Type | Example | Meaning |
656 + |-----------|------|---------|---------|
657 + | cardi- | Root | cardiology | Heart |
658 + | -itis | Suffix | arthritis | Inflammation |
659 + | hyper- | Prefix | hypertension | Above/excessive |
660 + | -ectomy | Suffix | appendectomy | Surgical removal |
661 + | nephro- | Root | nephrology | Kidney |
662 + | -pathy | Suffix | neuropathy | Disease/disorder |
663 + | brady- | Prefix | bradycardia | Slow |
664 + | -plasty | Suffix | rhinoplasty | Surgical repair |
665 +
666 + ### Medical Coding Systems Overview
667 +
668 + A medical coding system translates clinical documentation (diagnoses, procedures, services, supplies, medications) into standardized
+ alphanumeric codes used for claims submission, statistical analysis, quality measurement, and population health management. Medical coding
+ serves as the bridge between clinical care and healthcare finance, enabling payers to determine reimbursement based on documented services.
+ Multiple coding systems coexist in healthcare, each serving distinct purposes and governed by different organizations.
669 +
670 + The primary medical coding systems in U.S. healthcare are:
671 +
672 + - ICD (International Classification of Diseases): Diagnosis and procedure codes
673 + - CPT (Current Procedural Terminology): Physician services and procedures
674 + - HCPCS (Healthcare Common Procedure Coding System): Services, supplies, and equipment not in CPT
675 + - NDC (National Drug Codes): Pharmaceutical products and medications
676 + - LOINC (Logical Observation Identifiers Names and Codes): Lab and clinical observations
677 + - SNOMED CT (Systematized Nomenclature of Medicine Clinical Terms): Comprehensive clinical terminology
678 + - RxNorm: Normalized medication names and relationships
679 +
680 + Medical Coding Systems Interactive Infographic
682 + Type: infographic
683 +
684 + Purpose: Provide a visual overview of the major medical coding systems, their purposes, governing bodies, and relationships
685 +
686 + Layout: Central hub-and-spoke design with "Medical Coding Systems" at center
687 +
688 + Main coding systems (spokes radiating from center):
689 +
690 + 1. ICD (International Classification of Diseases)
691 + Position: Top center
692 + Color: Red
693 + Icon: Medical diagnosis symbol
694 + Click to expand details:
695 + - Full name: International Classification of Diseases, 10th/11th Revision
696 + - Governing body: World Health Organization (WHO)
697 + - U.S. version: ICD-10-CM (Clinical Modification) for diagnoses
698 + - U.S. procedure codes: ICD-10-PCS (Procedure Coding System)
699 + - Purpose: Classify diseases, injuries, causes of death
700 + - Structure: Hierarchical categories with 3-7 character codes
701 + - Example: E11.9 = Type 2 diabetes mellitus without complications
702 + - Use cases: Claims, epidemiology, quality measures, mortality statistics
703 + - Update frequency: Annual (October 1)
704 +
705 + 2. CPT (Current Procedural Terminology)
706 + Position: Upper right
707 + Color: Blue
708 + Icon: Stethoscope/procedure symbol
709 + Click to expand details:
710 + - Full name: Current Procedural Terminology
711 + - Governing body: American Medical Association (AMA)
712 + - Purpose: Describe physician services, procedures, diagnostic tests
713 + - Structure: 5-digit codes with optional 2-digit modifiers
714 + - Categories: Category I (common procedures), Category II (quality measures), Category III (emerging procedures)
715 + - Example: 99213 = Office visit, established patient, level 3
716 + - Use cases: Professional fee billing, utilization tracking, performance measurement
717 + - Update frequency: Annual (January 1)
718 +
719 + 3. HCPCS (Healthcare Common Procedure Coding System)
720 + Position: Right
721 + Color: Green
722 + Icon: Medical supply/durable medical equipment
723 + Click to expand details:
724 + - Full name: Healthcare Common Procedure Coding System
725 + - Governing body: Centers for Medicare & Medicaid Services (CMS)
726 + - Structure: Level I = CPT codes, Level II = National codes (A-V)
727 + - Purpose: Services, supplies, equipment, ambulance, drugs not in CPT
728 + - Example: E0163 = Commode chair, mobile or stationary
729 + - Use cases: Medicare/Medicaid billing, durable medical equipment, supplies
730 + - Update frequency: Quarterly
731 +
732 + 4. NDC/Drug Codes
733 + Position: Lower right
734 + Color: Purple
735 + Icon: Pill/medication bottle
736 + Click to expand details:
737 + - Full name: National Drug Code
738 + - Governing body: U.S. Food and Drug Administration (FDA)
739 + - Structure: 10-11 digit code (labeler-product-package)
740 + - Purpose: Uniquely identify drug products
741 + - Example: 0071-0155-23 = Lipitor 20mg, 90 tablets
742 + - Related systems: RxNorm (normalized names), GPI (therapeutic classification)
743 + - Use cases: Pharmacy billing, formulary management, drug utilization review
744 + - Update frequency: Continuous as products registered
745 +
746 + 5. LOINC (Lab/Clinical Observations)
747 + Position: Lower left
748 + Color: Orange
749 + Icon: Laboratory test tube
750 + Click to expand details:
751 + - Full name: Logical Observation Identifiers Names and Codes
752 + - Governing body: Regenstrief Institute
753 + - Purpose: Identify laboratory and clinical observations
754 + - Structure: Numeric codes with six-part names
755 + - Example: 2339-0 = Glucose [Mass/volume] in Blood
756 + - Use cases: Lab results exchange, clinical observations, vital signs
757 + - Update frequency: Biannually
758 +
759 + 6. SNOMED CT (Clinical Terminology)
760 + Position: Left
761 + Color: Teal
762 + Icon: Medical hierarchy tree
763 + Click to expand details:
764 + - Full name: Systematized Nomenclature of Medicine Clinical Terms
765 + - Governing body: International Health Terminology Standards Development Organisation (IHTSDO)
766 + - Purpose: Comprehensive clinical terminology and ontology
767 + - Structure: Concept codes with hierarchical relationships
768 + - Example: 44054006 = Diabetes mellitus type 2
769 + - Use cases: EHR documentation, clinical decision support, semantic interoperability
770 + - Update frequency: Biannual releases
771 +
772 + Relationship connectors (lines between spokes):
773 + - ICD ↔ CPT: "Often billed together" (dotted line)
774 + - CPT ↔ HCPCS: "HCPCS Level I = CPT" (solid line)
775 + - ICD ↔ SNOMED CT: "SNOMED more granular than ICD" (dotted line)
776 + - NDC ↔ HCPCS: "Some HCPCS codes map to drug categories" (dotted line)
777 + - All systems → Center: "All contribute to healthcare data ecosystem"
778 +
779 + Interactive features:
780 + - Hover over coding system: Show brief description and icon highlight
781 + - Click coding system: Expand detailed panel with full information
782 + - Click relationship line: Show mapping examples between systems
783 + - Toggle button: "Show update timelines" (displays timeline view of update frequencies)
784 + - Search box: Enter a condition/procedure to see which coding systems apply
785 +
786 + Visual enhancements:
787 + - Each coding system uses distinct color
788 + - Icons represent primary use case
789 + - Pulsing animation on hover
790 + - Smooth expand/collapse animations
791 + - Clean, modern flat design
792 +
793 + Annotations:
794 + - "All U.S. healthcare claims must include ICD diagnosis codes"
795 + - "CPT and HCPCS together describe all billable services"
796 + - "Multiple coding systems often describe the same clinical concept"
797 +
798 + Footer information:
799 + - "Understanding these coding systems is essential for healthcare data modeling"
800 + - "Graph databases can represent relationships among codes from different systems"
801 +
802 + Implementation: HTML/CSS/JavaScript with SVG or Canvas, responsive design, deployed as standalone HTML file
803 +
805 + ### ICD Codes: Diagnosis and Inpatient Procedures
806 +
807 + ICD codes (International Classification of Diseases) represent the global standard for classifying diseases, injuries, causes of
+ death, and inpatient hospital procedures. The World Health Organization (WHO) maintains the international version (currently ICD-11), while
+ the United States uses ICD-10-CM (Clinical Modification) for diagnoses and ICD-10-PCS (Procedure Coding System) for inpatient procedures.
+ ICD-10-CM was adopted in the U.S. in October 2015, replacing the decades-old ICD-9-CM system and expanding from approximately 14,000
+ diagnosis codes to over 70,000, enabling far greater clinical specificity.
808 +
809 + ICD-10-CM code structure:
810 +
811 + - Character 1: Category (letter, except U)
812 + - Character 2: Etiology, anatomic site, or manifestation
813 + - Character 3: Additional detail (completes the category)
814 + - Character 4-7: Even greater specificity (laterality, severity, episode of care, etc.)
815 +
816 + Examples demonstrating increasing specificity:
817 +
818 + - E11: Type 2 diabetes mellitus (category)
819 + - E11.6: Type 2 diabetes mellitus with other specified complications
820 + - E11.65: Type 2 diabetes mellitus with hyperglycemia
821 + - E11.641: Type 2 diabetes mellitus with hypoglycemia with coma
822 +
823 + ICD codes serve multiple purposes beyond billing:
824 +
825 + - Claims adjudication: Payers use ICD codes to determine medical necessity and appropriate reimbursement
826 + - Epidemiology: Public health tracking of disease prevalence and incidence
827 + - Quality measurement: Many quality metrics require specific diagnosis codes
828 + - Research: Disease registries and clinical research studies
829 + - Population health: Risk stratification and care management program enrollment
830 +
831 + ICD-10-PCS codes describe inpatient hospital procedures with seven-character alphanumeric codes, each character representing a specific
+ attribute:
832 +
833 + 1. Section: Type of procedure (Medical/Surgical, Obstetrics, Imaging, etc.)
834 + 2. Body System: Anatomical region operated on
835 + 3. Root Operation: Objective of the procedure (excision, repair, replacement, etc.)
836 + 4. Body Part: Specific anatomical site
837 + 5. Approach: How the body part was reached (open, percutaneous, via natural opening, etc.)
838 + 6. Device: Device left in place, if any
839 + 7. Qualifier: Additional detail
840 +
841 + Example: 0DT60ZZ = Resection of stomach, open approach
842 +
843 + ### CPT Codes: Physician Services and Outpatient Procedures
844 +
845 + CPT codes (Current Procedural Terminology), maintained by the American Medical Association (AMA), describe physician services,
+ outpatient procedures, diagnostic tests, and therapeutic services. CPT codes form the foundation of professional fee billing—when a
+ physician sees a patient, performs a procedure, or orders a test, CPT codes translate those services into billable line items. CPT contains
+ over 10,000 codes updated annually, with a rigorous process for adding, modifying, or deleting codes based on evolving medical practice.
846 +
847 + CPT code categories:
848 +
849 + Category I (5-digit numeric codes): Established procedures and services
850 +
851 + - Evaluation and Management (E&M) (99202-99499): Office visits, consultations, hospital rounds, emergency department visits
852 + - Anesthesia (00100-01999): Anesthesia services by anatomical site
853 + - Surgery (10021-69990): Organized by body system
854 + - Radiology (70010-79999): Diagnostic and interventional imaging
855 + - Pathology and Laboratory (80047-89398): Lab tests and analyses
856 + - Medicine (90281-99607): Immunizations, dialysis, physical therapy, etc.
857 +
858 + Category II (4 digits + letter F): Optional quality measurement codes
859 +
860 + - Used for performance measurement programs
861 + - Not used for reimbursement
862 + - Example: 3074F = Most recent systolic blood pressure <130 mmHg
863 +
864 + Category III (4 digits + letter T): Temporary codes for emerging procedures
865 +
866 + - Used for new technologies under evaluation
867 + - May eventually become Category I codes or be retired
868 + - Example: 0075T = Transcatheter placement of extracranial vertebral artery stent(s)
869 +
870 + CPT modifiers (2-digit codes) provide additional information:
871 +
872 + - -25: Significant, separately identifiable E&M service on same day as procedure
873 + - -50: Bilateral procedure
874 + - -51: Multiple procedures
875 + - -59: Distinct procedural service (unbundling modifier)
876 + - -76: Repeat procedure by same physician
877 + - -LT/-RT: Left/right side indicators
878 +
879 + Common CPT code examples:
880 +
881 + | Code | Description | Typical Reimbursement |
882 + |------|-------------|----------------------|
883 + | 99213 | Office visit, established patient, level 3 | $100-150 |
884 + | 99214 | Office visit, established patient, level 4 | $150-200 |
885 + | 99285 | Emergency department visit, high severity | $300-500 |
886 + | 29881 | Arthroscopy, knee, surgical | $1,500-2,500 |
887 + | 80053 | Comprehensive metabolic panel (lab test) | $15-30 |
888 + | 71046 | Chest X-ray, 2 views | $50-100 |
889 +
890 + ### HCPCS Codes: Medical Supplies and Services
891 +
892 + HCPCS codes (Healthcare Common Procedure Coding System, pronounced "hick-picks") is a two-level coding system maintained by the
+ Centers for Medicare & Medicaid Services (CMS). Level I HCPCS codes are identical to CPT codes. Level II HCPCS codes (commonly referred to
+ simply as "HCPCS codes") cover services, supplies, and equipment not included in CPT, particularly items relevant to Medicare and Medicaid
+ billing.
893 +
894 + Level II HCPCS code structure:
895 +
896 + - First character: Letter (A-V) indicating code category
897 + - Next four characters: Numbers providing specificity
898 + - Optional modifiers: 2-character alphanumeric codes
899 +
900 + HCPCS Level II categories:
901 +
902 + | Code Range | Category | Examples |
903 + |-----------|----------|----------|
904 + | A codes | Transportation, supplies, administrative | A0428 (Ambulance service, basic life support), A4253 (Blood glucose test
+ strips, box of 50) |
905 + | B codes | Enteral and parenteral therapy | B4034 (Enteral feeding supply kit) |
906 + | C codes | Temporary hospital outpatient PPS | C1713 (Anchor/screw for opposing bone-to-bone) |
907 + | D codes | Dental procedures | D0120 (Periodic oral evaluation) |
908 + | E codes | Durable medical equipment (DME) | E0143 (Walker, folding, wheeled), E0163 (Commode chair) |
909 + | G codes | Temporary procedures/services | G0439 (Annual wellness visit, first occurrence) |
910 + | J codes | Drugs administered other than oral | J0129 (Injection, abatacept, 10 mg) |
911 + | K codes | Temporary codes for DME | K0001 (Standard wheelchair) |
912 + | L codes | Orthotics and prosthetics | L3260 (Surgical boot/shoe) |
913 + | P codes | Pathology and laboratory | P9010 (Blood, split unit) |
914 + | Q codes | Temporary codes | Q4081 (Injection, epoetin alfa, 100 units) |
915 + | S codes | Temporary national codes (non-Medicare) | S0630 (Removal of sutures by someone other than physician) |
916 + | V codes | Vision and hearing services | V2020 (Frames, purchases) |
917 +
918 + HCPCS codes are particularly important for:
919 +
920 + - Durable medical equipment (DME): Wheelchairs, hospital beds, oxygen equipment, walkers, crutches
921 + - Orthotics and prosthetics: Braces, artificial limbs, orthopedic shoes
922 + - Injectable drugs: Chemotherapy, biologics, vaccines given in office or hospital settings
923 + - Ambulance services: Different levels and types of emergency medical transport
924 + - Medical supplies: Diabetic supplies, ostomy supplies, incontinence products
925 +
926 + ### Drug Codes: Pharmaceutical Products
927 +
928 + Drug codes identify pharmaceutical products for prescribing, dispensing, billing, and clinical decision support. The primary drug
+ coding systems in U.S. healthcare are:
929 +
930 + National Drug Code (NDC): FDA-assigned 10-11 digit identifier for drug products
931 +
932 + - Segment 1 (Labeler): Manufacturer or distributor (4-5 digits)
933 + - Segment 2 (Product): Drug formulation and strength (3-4 digits)
934 + - Segment 3 (Package): Package size and type (1-2 digits)
935 +
936 + Example: 0071-0156-23
937 + - 0071 = Pfizer (labeler)
938 + - 0156 = Lipitor 10mg tablet (product)
939 + - 23 = Bottle of 90 tablets (package)
940 +
941 + RxNorm: National Library of Medicine system providing normalized names for clinical drugs
942 +
943 + RxNorm links various drug vocabularies (NDC, SNOMED CT, MeSH, FDA) and provides standard naming conventions at multiple levels of
+ granularity:
944 +
945 + - Ingredient: Active pharmaceutical ingredient (e.g., atorvastatin)
946 + - Clinical Drug: Ingredient + strength (e.g., atorvastatin 10 mg)
947 + - Branded Drug: Brand name + ingredient + strength (e.g., Lipitor 10 mg)
948 + - Clinical Drug Form: Ingredient + strength + dose form (e.g., atorvastatin 10 mg oral tablet)
949 + - Branded Drug Form: Complete product specification (e.g., Lipitor 10 mg oral tablet)
950 +
951 + Other drug classification systems:
952 +
953 + - Generic Product Identifier (GPI): Hierarchical classification by therapeutic class
954 + - American Hospital Formulary Service (AHFS): Pharmacologic-therapeutic classification
955 + - Anatomical Therapeutic Chemical (ATC): WHO classification system
956 +
957 + Drug codes support critical healthcare functions:
958 +
959 + - ePrescribing: Electronic transmission of prescriptions to pharmacies
960 + - Drug interaction checking: Clinical decision support for contraindications and interactions
961 + - Formulary management: Determining which drugs are covered by insurance plans and at what tier
962 + - Medication reconciliation: Comparing medication lists across care transitions
963 + - Adverse event reporting: Pharmacovigilance and safety monitoring
964 + - Pharmacy billing: Submission of pharmacy claims with NDC codes
965 +
966 + ## Healthcare Interoperability and Data Exchange
967 +
968 + ### The Interoperability Challenge
969 +
970 + Healthcare interoperability refers to the ability of healthcare information systems to exchange, interpret, and use data across
+ organizational boundaries, enabling seamless information flow among providers, payers, patients, and public health agencies. True
+ interoperability requires not just technical data exchange (syntactic interoperability) but also shared understanding of meaning (semantic
+ interoperability) and coordinated workflows (process interoperability). Despite decades of effort and billions of dollars invested in
+ health IT, interoperability remains one of healthcare's most persistent challenges.
971 +
972 + Barriers to healthcare interoperability include:
973 +
974 + Technical barriers:
975 + - Proprietary EHR data models and interfaces
976 + - Heterogeneous data formats (HL7 v2, CDA, FHIR, X12, NCPDP, DICOM)
977 + - Inconsistent identifier systems across organizations
978 + - Legacy systems with limited integration capabilities
979 + - Network security restrictions and firewall configurations
980 +
981 + Semantic barriers:
982 + - Multiple coding systems describing the same clinical concepts
983 + - Local terminology variations and custom codes
984 + - Incomplete or missing standardized terminology use
985 + - Different granularity in documentation practices
986 + - Ambiguous or context-dependent clinical terms
987 +
988 + Organizational barriers:
989 + - Competitive concerns about sharing patient data
990 + - Lack of business incentives for interoperability investments
991 + - Information blocking practices to maintain patient populations
992 + - Complex data sharing agreements and legal concerns
993 + - Varying privacy and consent frameworks across states
994 +
995 + Regulatory barriers:
996 + - HIPAA privacy and security requirements
997 + - 42 CFR Part 2 restrictions on substance use disorder records
998 + - State-specific privacy laws (e.g., mental health, genetic data, HIV status)
999 + - Data ownership ambiguities
1000 + - Consent requirements for health information exchange
1001 +
1002 + The 21st Century Cures Act (2016) and subsequent regulations require healthcare providers and EHR vendors to implement standardized APIs,
+ prohibit information blocking, and enable patients to access their complete electronic health information. These policies are accelerating
+ the adoption of FHIR (Fast Healthcare Interoperability Resources) as the emerging standard for healthcare data exchange.
1003 +
1004 + ### Healthcare Data Exchange Standards and Approaches
1005 +
1006 + Healthcare data exchange encompasses the technical mechanisms, standards, and organizational frameworks for sharing health
+ information. Multiple exchange paradigms coexist in modern healthcare, each optimized for different use cases, technical capabilities, and
+ organizational relationships.
1007 +
1008 + Data exchange standards:
1009 +
1010 + HL7 Version 2.x (Health Level Seven):
1011 + - Message-based standard from the 1980s-90s
1012 + - Pipe-delimited text format (e.g., PID|1||12345^^^MRN^MR||DOE^JOHN^||19600101|M)
1013 + - Common message types: ADT (admissions), ORU (results), ORM (orders), SIU (scheduling)
1014 + - Still widely used for intra-organizational interfaces
1015 + - Flexible structure leads to implementation variations
1016 +
1017 + HL7 CDA (Clinical Document Architecture):
1018 + - XML-based standard for clinical documents
1019 + - Structures documents (discharge summaries, progress notes, imaging reports)
1020 + - Continuity of Care Document (CCD) and Consolidated CDA (C-CDA) are common implementations
1021 + - Human-readable and machine-processable
1022 + - Required for Meaningful Use and ONC certification
1023 +
1024 + HL7 FHIR (Fast Healthcare Interoperability Resources):
1025 + - Modern RESTful API standard (2014-present)
1026 + - JSON and XML formats
1027 + - Resource-based model (Patient, Encounter, Observation, Medication, etc.)
1028 + - Easier to implement than previous HL7 standards
1029 + - Supports web-based and mobile applications
1030 + - Growing adoption for patient access, payer-provider exchange, public health reporting
1031 +
1032 + X12 EDI (Electronic Data Interchange):
1033 + - ANSI standard for administrative transactions
1034 + - Common transaction sets:
1035 + - 270/271: Eligibility inquiry and response
1036 + - 276/277: Claim status inquiry and response
1037 + - 278: Prior authorization
1038 + - 837: Claims submission
1039 + - 835: Payment/remittance advice
1040 + - Fixed-length and delimited formats
1041 + - Required for HIPAA-covered transactions
1042 +
1043 + DICOM (Digital Imaging and Communications in Medicine):
1044 + - Standard for medical imaging (X-rays, CT, MRI, ultrasound)
1045 + - Defines image formats and transmission protocols
1046 + - Includes patient and study metadata
1047 + - Basis for PACS (Picture Archiving and Communication Systems)
1048 +
1049 + Data exchange approaches:
1050 +
1051 + | Approach | Description | Use Cases | Advantages | Disadvantages |
1052 + |----------|-------------|-----------|------------|---------------|
1053 + | Direct messaging | Secure email-like exchange using Direct Protocol | Provider-to-provider referrals, transitions of care | Simple,
+ encrypted, "push" model | Requires known recipient address, no query capability |
1054 + | Health Information Exchanges (HIEs) | Regional or statewide networks aggregating data | Emergency department access to patient
+ history | Broad coverage, query for missing information | Governance complexity, funding challenges, variable data quality |
1055 + | EHR vendor networks | Data sharing within same EHR vendor ecosystem | Care coordination among Epic or Cerner sites | Easier semantic
+ interoperability | Limited to single vendor, proprietary |
1056 + | FHIR APIs | Standardized RESTful APIs for data access | Patient apps, payer integrations, research | Standards-based, modern
+ architecture | Implementation variations, security complexity |
1057 + | Point-to-point interfaces | Custom connections between specific systems | Lab results, radiology images, ADT notifications |
+ Optimized for specific workflow | Maintenance burden, brittle, non-scalable |
1058 +
1059 + Graph databases offer unique advantages for healthcare interoperability challenges:
1060 +
1061 + - Schema flexibility: Easily accommodate data from multiple sources with varying structures
1062 + - Relationship representation: Naturally model connections among patients, encounters, providers, diagnoses, medications
1063 + - Identity resolution: Graph algorithms can link records representing same patient across systems
1064 + - Data lineage: Track provenance of data elements across exchanges
1065 + - Semantic mapping: Represent relationships among coding systems (ICD, SNOMED CT, LOINC, etc.)
1066 + - Master data management: Create unified views of patients, providers, and facilities across sources
1067 +
1068 + Healthcare Data Integration Graph Model
1070 + Type: graph-model
1071 +
1072 + Purpose: Demonstrate how graph databases can integrate healthcare data from multiple sources (EHR, claims, lab, pharmacy) around a
+ unified patient view
1073 +
1074 + Node types:
1075 +
1076 + 1. Patient (blue circles, large)
1077 + Properties: patient_id, MRN, name, DOB, gender, address
1078 + Labels: "Master Patient Record"
1079 +
1080 + 2. Source System (gray hexagons, medium)
1081 + Properties: system_name, vendor, organization
1082 + Examples: "Epic EHR - Hospital A", "Claims Database - Payer X", "LabCorp Interface", "CVS Pharmacy"
1083 +
1084 + 3. Encounter (green squares, medium)
1085 + Properties: encounter_id, date, type, facility, chief_complaint
1086 + Examples: "Office Visit 2024-01-15", "ED Visit 2024-02-03", "Hospitalization 2024-03-10"
1087 +
1088 + 4. Diagnosis (red diamonds, small)
1089 + Properties: ICD_code, description, onset_date, status
1090 + Examples: "E11.9 Type 2 Diabetes", "I10 Essential Hypertension", "J45.909 Asthma"
1091 +
1092 + 5. Medication (purple pill shapes, small)
1093 + Properties: drug_name, NDC, RxNorm, dose, frequency, start_date
1094 + Examples: "Metformin 500mg BID", "Lisinopril 10mg daily", "Albuterol inhaler PRN"
1095 +
1096 + 6. Lab Result (orange test tubes, small)
1097 + Properties: LOINC_code, test_name, value, units, date, reference_range
1098 + Examples: "HbA1c 7.2%", "Glucose 145 mg/dL", "Creatinine 0.9 mg/dL"
1099 +
1100 + 7. Provider (teal stethoscope icons, medium)
1101 + Properties: NPI, name, specialty, organization
1102 + Examples: "Dr. Smith - PCP", "Dr. Jones - Endocrinology", "Dr. Lee - Emergency Medicine"
1103 +
1104 + 8. Coding System (yellow books, small)
1105 + Properties: system_name, version, code
1106 + Examples: "ICD-10-CM", "RxNorm", "LOINC", "SNOMED CT"
1107 +
1108 + Edge types:
1109 +
1110 + 1. SOURCED_FROM (Patient → Source System)
1111 + Properties: identifier_type, identifier_value, confidence_score
1112 + Style: Dashed gray arrows
1113 + Purpose: Show which systems contributed patient data
1114 +
1115 + 2. HAD_ENCOUNTER (Patient → Encounter)
1116 + Properties: admission_date, discharge_date
1117 + Style: Solid green arrows
1118 + Purpose: Link patient to care episodes
1119 +
1120 + 3. DOCUMENTED_BY (Encounter → Provider)
1121 + Properties: role (attending, consulting, PCP)
1122 + Style: Solid teal arrows
1123 + Purpose: Connect encounters to providers
1124 +
1125 + 4. DIAGNOSED_WITH (Encounter → Diagnosis)
1126 + Properties: diagnosis_type (primary, secondary), documentation_date
1127 + Style: Solid red arrows
1128 + Purpose: Link diagnoses to encounters
1129 +
1130 + 5. PRESCRIBED (Encounter → Medication)
1131 + Properties: prescription_date, prescribing_provider, status (active, discontinued)
1132 + Style: Solid purple arrows
1133 + Purpose: Connect medications to encounters where prescribed
1134 +
1135 + 6. ORDERED (Encounter → Lab Result)
1136 + Properties: order_date, ordering_provider
1137 + Style: Solid orange arrows
1138 + Purpose: Link lab results to encounters
1139 +
1140 + 7. TAKES (Patient → Medication)
1141 + Properties: start_date, end_date, adherence_score
1142 + Style: Dashed purple arrows
1143 + Purpose: Show current medication regimen
1144 +
1145 + 8. HAS_DIAGNOSIS (Patient → Diagnosis)
1146 + Properties: onset_date, status (active, resolved, historical)
1147 + Style: Dashed red arrows
1148 + Purpose: Link patient to problem list
1149 +
1150 + 9. CODED_AS (Diagnosis → Coding System)
1151 + Properties: code_value, version
1152 + Style: Dotted yellow arrows
1153 + Purpose: Show code mappings across terminologies
1154 +
1155 + 10. MAPS_TO (Coding System → Coding System)
1156 + Properties: mapping_confidence, mapping_type (equivalent, narrower, broader)
1157 + Style: Bidirectional dotted yellow arrows
1158 + Purpose: Represent semantic relationships among coding systems
1159 +
1160 + Sample data structure:
1161 +
1162 + Central patient node: "John Doe, DOB: 1960-01-01"
1163 + ├─ SOURCED_FROM → "Epic EHR - Hospital A" (MRN: 123456)
1164 + ├─ SOURCED_FROM → "Claims Database - Payer X" (Member ID: 987654)
1165 + ├─ SOURCED_FROM → "LabCorp Interface" (Account: LC-456)
1166 + ├─ HAD_ENCOUNTER → "Office Visit 2024-01-15"
1167 + │ ├─ DOCUMENTED_BY → "Dr. Smith - PCP"
1168 + │ ├─ DIAGNOSED_WITH → "E11.9 Type 2 Diabetes"
1169 + │ ├─ PRESCRIBED → "Metformin 500mg BID"
1170 + │ └─ ORDERED → "HbA1c 7.2%"
1171 + ├─ HAD_ENCOUNTER → "Office Visit 2024-04-10"
1172 + │ ├─ DOCUMENTED_BY → "Dr. Smith - PCP"
1173 + │ └─ ORDERED → "HbA1c 6.8%"
1174 + ├─ HAS_DIAGNOSIS → "E11.9 Type 2 Diabetes"
1175 + │ └─ CODED_AS → "ICD-10-CM: E11.9"
1176 + │ └─ MAPS_TO → "SNOMED CT: 44054006 (Diabetes mellitus type 2)"
1177 + ├─ HAS_DIAGNOSIS → "I10 Essential Hypertension"
1178 + └─ TAKES → "Metformin 500mg BID"
1179 +
1180 + Layout: Hierarchical radial layout with patient at center
1181 +
1182 + Interactive features:
1183 + - Zoom: Mouse wheel to zoom in/out
1184 + - Pan: Click and drag background
1185 + - Node hover: Show full properties in tooltip
1186 + - Node click: Highlight all connected nodes and edges (1-hop neighborhood)
1187 + - Edge hover: Show relationship properties
1188 + - Double-click node: Expand to show additional connections (if collapsed)
1189 + - Right-click node: Context menu with options:
1190 + - "Find similar patients" (show patients with similar diagnoses)
1191 + - "View timeline" (temporal view of connected encounters)
1192 + - "Show data lineage" (highlight source systems)
1193 + - Filter panel: Toggle node types on/off to simplify view
1194 + - Search box: Find specific patients, diagnoses, medications by name or code
1195 +
1196 + Visual styling:
1197 + - Node size: Based on number of connections (degree centrality)
1198 + - Edge thickness: Thicker for more recent/active relationships
1199 + - Color coding: Consistent colors for node types
1200 + - Transparency: Lower opacity for historical/inactive elements
1201 + - Animation: Gentle pulsing for nodes with recent activity
1202 + - Clustering: Visually group related nodes (encounters + associated diagnoses/meds)
1203 +
1204 + Legend (top-right panel):
1205 + - Node shape and color key
1206 + - Edge style meanings
1207 + - Interaction instructions
1208 + - "Show sample queries" button
1209 +
1210 + Sample queries panel (expandable):
1211 + 1. "Find all encounters where diabetes was diagnosed"
1212 + 2. "Show medication history across all sources"
1213 + 3. "Identify gaps in lab monitoring"
1214 + 4. "Trace data lineage for HbA1c result"
1215 + 5. "Find coding system mappings for diabetes"
1216 +
1217 + Educational annotations:
1218 + - Callout: "Patient data integrated from 4 source systems"
1219 + - Callout: "Graph model handles multiple identifiers per patient"
1220 + - Callout: "Coding system relationships enable semantic queries"
1221 + - Callout: "Temporal relationships show care progression"
1222 +
1223 + Canvas size: 1000x800px
1224 +
1225 + Implementation:
1226 + - vis-network JavaScript library for graph visualization
1227 + - D3.js for enhanced layout and animations
1228 + - Responsive design for various screen sizes
1229 + - Export options: PNG image, JSON data, Cypher queries
1230 + - Deployed in /docs/sims/healthcare-data-integration-graph/
1231 +
1232 + Data generation:
1233 + - Use realistic synthetic patient data
1234 + - Include 1 patient (center), 4 source systems, 5-7 encounters, 3-5 diagnoses, 4-6 medications, 6-10 lab results, 3-4 providers
1235 + - Ensure temporal consistency (later encounters reference earlier diagnoses)
1236 + - Include code mappings among ICD, SNOMED, RxNorm, LOINC
1237 +
1239 + ## Summary and Key Takeaways
1240 +
1241 + This chapter provided a comprehensive overview of the healthcare system domain knowledge essential for effective graph data modeling.
+ Understanding healthcare economics, stakeholder perspectives, clinical workflows, and data standards forms the foundation for designing
+ graph models that accurately represent the complexity and interconnectedness of healthcare information.
1242 +
1243 + Key concepts covered:
1244 +
1245 + Healthcare Economics:
1246 + - U.S. healthcare costs are twice those of comparable nations ($12,900 per person annually)
1247 + - Fee-for-service models incentivize volume over value, contributing to cost escalation
1248 + - Value-based care aligns payment with outcomes, requiring sophisticated data analytics
1249 + - Graph databases support the transition to value-based care through advanced relationship analytics
1250 +
1251 + Healthcare Stakeholders:
1252 + - Patients: Central information hub connecting clinical, administrative, and social determinant data
1253 + - Providers: Individual clinicians and organizations generating and consuming clinical documentation
1254 + - Payers: Insurance companies and government programs financing care and driving quality initiatives
1255 + - All three stakeholders generate complex, interconnected data requiring graph representation
1256 +
1257 + Clinical Operations:
1258 + - Medical encounters: Temporal containers linking patients, providers, diagnoses, procedures, and charges
1259 + - Clinical workflows: Multi-step processes spanning seconds to years, involving coordination across roles and systems
1260 + - Electronic health records: Digital repositories with structured and unstructured patient data, varying by vendor
1261 + - Patient demographics: Core identifying attributes plus social determinants influencing health outcomes
1262 +
1263 + Medical Coding and Terminology:
1264 + - Medical terminology: Specialized language built from Greek/Latin roots enabling precise clinical communication
1265 + - ICD codes: Classify diagnoses and inpatient procedures (70,000+ codes)
1266 + - CPT codes: Describe physician services and outpatient procedures (10,000+ codes)
1267 + - HCPCS codes: Cover supplies, equipment, and services not in CPT
1268 + - Drug codes: Identify pharmaceutical products (NDC, RxNorm, GPI)
1269 + - Multiple coding systems require semantic mapping and relationship management
1270 +
1271 + Interoperability and Data Exchange:
1272 + - Healthcare interoperability: Ability to exchange and meaningfully use health information across organizations
1273 + - Data exchange standards: HL7 v2, CDA, FHIR, X12, DICOM serve different exchange needs
1274 + - Exchange approaches: Direct messaging, HIEs, vendor networks, FHIR APIs, point-to-point interfaces
1275 + - Graph advantages: Schema flexibility, relationship representation, identity resolution, semantic mapping
1276 +
1277 + With this healthcare domain foundation, you are now prepared to design graph data models that accurately capture the intricate
+ relationships among patients, providers, payers, clinical concepts, and healthcare transactions. The next chapters will build on this
+ knowledge to develop specific graph modeling patterns for patient-centric, provider-centric, and payer-centric perspectives.
⏺ Perfect! Chapter content has been successfully generated. Let me provide you with a comprehensive summary:
✅ Chapter Content Generation Complete
Chapter: 02-intro-to-healthcare-systemsReading Level: College UndergraduateContent Length: ~10,500 words
Non-Text Elements Summary
Directly embedded (no skills needed): - Markdown lists: 36 (including bullet points and numbered lists) - Markdown tables: 5 (comparison tables with proper formatting)
Interactive elements requiring implementation: - Diagrams: 1 (Healthcare Ecosystem Stakeholder Diagram) - Charts: 1 (Per-Person Healthcare Cost Comparison Chart) - Infographics: 1 (Medical Coding Systems Interactive Infographic) - MicroSims: 1 (Healthcare Payment Model Comparison MicroSim) - Workflows: 1 (Clinical Encounter Workflow Diagram) - Graph models: 1 (Healthcare Data Integration Graph Model)
Interactive Elements Breakdown
Total interactive elements: 6 detailed specifications in
Skills that can be used to implement: 1. hc-graph-generator - For Healthcare Data Integration Graph Model 2. microsim-p5 - For Healthcare Payment Model Comparison MicroSim 3. Custom HTML/CSS/JavaScript - For infographic, chart, diagram, and workflow
Concept Coverage Verification ✓
All 20 concepts from the "Concepts Covered" list have been addressed:
- ✓ Healthcare System
- ✓ Healthcare Cost
- ✓ Per-Person Healthcare Cost
- ✓ Fee-For-Service Model
- ✓ Value-Based Care
- ✓ Healthcare Payer
- ✓ Healthcare Provider
- ✓ Healthcare Patient
- ✓ Electronic Health Record
- ✓ Medical Coding System
- ✓ ICD Code
- ✓ CPT Code
- ✓ HCPCS Code
- ✓ Drug Code
- ✓ Medical Terminology
- ✓ Clinical Workflow
- ✓ Patient Demographics
- ✓ Medical Encounter
- ✓ Healthcare Interoperability
- ✓ Healthcare Data Exchange
Content Organization
The chapter follows a pedagogical progression from foundational to complex:
- Introduction - Healthcare ecosystem overview
- Healthcare Economics - Costs, payment models (FFS vs VBC)
- Key Stakeholders - Patient, Provider, Payer perspectives
- Clinical Operations - Encounters, workflows, EHRs
- Medical Coding - Terminology, ICD, CPT, HCPCS, Drug codes
- Interoperability - Data exchange challenges and standards
- Summary - Key takeaways and next steps
Writing Quality
- College-level academic style with 18-25 word sentences
- Technical terminology with contextual definitions
- Balanced concrete examples and abstract concepts
- Frequent use of lists and tables for clarity
- Rich interactive element specifications for implementation
The chapter is now ready for students. If you'd like to implement any of the interactive elements, I can help run the appropriate skills (hc-graph-generator, microsim-p5) or create custom visualizations.
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── ⏵⏵ accept edits on (shift+tab to cycle)