Notebooks
N
NVIDIA
Insurance Claims

Insurance Claims

gpu-accelerationretrieval-augmented-generationllm-inferencetensorrthealthcare-datasetsnvidia-generative-ai-examplesself-hosted-tutorialslarge-language-modelsmicroservicetriton-inference-servercommunity-contributionsLLMragnemoNeMo-Data-Designer

🧾 NeMo Data Designer: Synthetic Insurance Claims Dataset Generator

📚 What you'll learn

This notebook creates a synthetic dataset of insurance claims with realistic PII (Personally Identifiable Information)
for testing data protection and anonymization techniques.

The dataset includes:

  • Policy and claim details
  • Policyholder and claimant information (PII)
  • Claim descriptions and adjuster notes with embedded PII
  • Medical information for relevant claims

👋 IMPORTANT – Environment Setup

  • If you haven't already, follow the instructions in the README to install the necessary dependencies.

  • You may need to restart your notebook's kernel after setting up the environment.

  • In this notebook, we assume you have a self-hosted instance of Data Designer up and running.

  • For deployment instructions, see the Installation Options section of the NeMo Data Designer documentation.

📦 Import the essentials

  • The data_designer module of nemo_microservices exposes Data Designer's high-level SDK.

  • The essentials module provides quick access to the most commonly used objects.

[ ]

⚙️ Initialize the NeMo Data Designer Client

  • NeMoDataDesignerClient is responsible for submitting generation requests to the microservice.
[ ]

🎛️ Define model configurations

  • Each ModelConfig defines a model that can be used during the generation process.

  • The "model alias" is used to reference the model in the Data Designer config (as we will see below).

  • The "model provider" is the external service that hosts the model (see the model config docs for more details).

  • By default, the microservice uses build.nvidia.com as the model provider.

[ ]

🏗️ Initialize the Data Designer Config Builder

  • The Data Designer config defines the dataset schema and generation process.

  • The config builder provides an intuitive interface for building this configuration.

  • The list of model configs is provided to the builder at initialization.

[ ]

🎲 Creating Person Samplers

We'll create person samplers to generate consistent personal information for different roles in the insurance claims process:

  • Policyholders (primary insurance customers)
  • Claimants (who may be different from policyholders)
  • Adjusters (insurance company employees who evaluate claims)
  • Physicians (for medical-related claims)
[ ]

Creating Policy Information

Next, we'll create the basic policy information:

  • Policy number (unique identifier)
  • Policy type (Auto, Home, Health, etc.)
  • Coverage details (based on policy type)
  • Policy start and end dates
[ ]

Policyholder Information (PII)

Now we'll add fields for the policyholder's personal information. This includes PII elements that would typically be
subject to privacy regulations:

  • First and last name
  • Birth date
  • Contact information (email)

These fields use expressions to reference the person sampler we defined earlier.

[ ]

Claim Information

Next, we'll create the core claim details:

  • Claim ID (unique identifier)
  • Dates (filing date, incident date)
  • Claim status (in process, approved, denied, etc.)
  • Financial information (amount claimed, amount approved)
[ ]

Claimant Information

In some cases, the claimant (person filing the claim) may be different from the policyholder.
We'll create fields to capture claimant information and their relationship to the policyholder:

  • Flag indicating if claimant is the policyholder
  • Claimant personal details (when different from policyholder)
  • Relationship to policyholder
[ ]

Claim Adjuster Information

Insurance claims are typically handled by claim adjusters. We'll add information about the adjuster assigned to each claim:

  • Adjuster name
  • Assignment date
  • Contact information
[ ]

Medical Information

For health insurance claims and injury-related claims in other policy types, we'll include medical information:

  • Flag indicating if there's a medical component to the claim
  • Medical claim details (when applicable)
[ ]

Free Text Fields with PII References

These fields will contain natural language text that incorporates PII elements from other fields. This is particularly useful for testing PII detection and redaction within unstructured text:

  1. Incident Description - The policyholder/claimant's account of what happened
  2. Adjuster Notes - The insurance adjuster's professional documentation
  3. Medical Notes - For claims with a medical component

The LLM will be prompted to include PII elements like names, dates, and contact information within the narrative text.

[ ]

Adding Constraints

To ensure our data is logically consistent, we'll add some constraints:

  • Incident date must be during the policy term
  • Filing date must be after incident date
[ ]

🔁 Iteration is key – preview the dataset!

  1. Use the preview method to generate a sample of records quickly.

  2. Inspect the results for quality and format issues.

  3. Adjust column configurations, prompts, or parameters as needed.

  4. Re-run the preview until satisfied.

[ ]
[ ]

📊 Analyze the generated data

  • Data Designer automatically generates a basic statistical analysis of the generated data.

  • This analysis is available via the analysis property of generation result objects.

[ ]

🆙 Scale up!

  • Happy with your preview data?

  • Use the create method to submit larger Data Designer generation jobs.

[ ]
[ ]
[ ]
[ ]