This knowledge sharing article demonstrates how to use Pega GenAI Connect rule to analyze and summarize a list of healthcare claims submitted in a PDF document. This is another example of showing an intelligent document processing by Pega GenAI capability.
Pega Infinity version used: 25.1.2
Runtime behavior
- User uploads a PDF document that contains a list of healthcare claims in a tabular format.
Here is the PDF document file uploaded by the user. Examine the tabular data in the document to validate the AI results later.
Sample Claim Data from Providers.pdf (193.2 KB)
- Click Submit.
At this point, GenAI Connector rule is analyzing and producing a claim summary..
(When GenAI completes the processing)
- AI-generated claim summary is displayed
- Grouped by providers
- Total number of claims
- Number of paid claims
- Total paid amount ($)
- Number of denied claims
- Total denied amount ($)
Verified: the accuracy of the AI-generated results.
Takeaway: GenAI Connect rule was able to quickly analyze and summarize a raw tabular data from the PDF document. Without the Pega GenAI capability, it would have taken a much longer time to develop and produce the same outcome.
How to configure
Step 1 - Login to App Studio.
Step 2 - Create a Provider data object and related fields.
- Field 1: Provider name
- Field 2: NPI
- Field 3: Number of claims
- Field 4: Paid (number of paid claims)
- Field 5: Total paid ($)
- Field 6: Denied (number of denied claims)
- Field 7: Total denied ($)
Step 3 - Create a ProviderList field under the Bulk process claims case type.
- Type: Embedded Data
- Data object: Provider
- Options: List of records
Step 4 - Create a ClaimFile field (which will be used to upload a PDF document)
- Type: Attachment
Step 5 - Create a GenAI Connect rule (‘ProviderAnalysis’) in the AI Designer landing page.
Select the Include attachment field for analysis checkbox and .ClaimFile attachment field.
Select Structured - List as Expected response mode and .ProviderList as List context in the Response section and add the relevant properties. GenAI Connect rule will map the response to this data model, which we’ll be later displayed in a table in Constellation UI.
For this example, we used Claude-Sonnet-45 GenAI model.
Here are the prompts sent to the GenAI model for processing.
-
User prompt
Analyze the attached file and provide a summary of total claims submitted, total paid claim count, total denied claim count, total amount denied and total amount paid for each provider. Sort the results in descending order by the number of claims. -
System prompt (auto generated based on the user prompt)
You are a data analysis expert specializing in healthcare claims processing. Your role is to extract, aggregate, and analyze claims data from provided files. Instructions: 1. Parse the attached file to identify all claims records and associated provider information. 2. Extract the following data points for each claim: provider identifier/name, claim count, paid count, denied count, total amount denied, and total amount paid. 3. Aggregate claims data by provider, calculating the total number of claims submitted, calculating total number of paid claims, calculating total number of denied claims, the total amount denied and the total amount paid for each provider. 4. Sort the aggregated results in descending order by the number of claims submitted (highest claim count first). 5. Present the analysis in a clear, structured format showing provider name/identifier, total claims count, total denied count, total paid count, total denied amount and total paid amount. 6. Ensure accuracy in calculations and data extraction from the source file. 7. If any data is missing or unclear, note it in your analysis.
Step 6 - Configure the Upload claim file view.
Add the Claim field attachment field.
Step 7 - Add the GenAI Connect step in the case lifecycle and select the ProviderAnalysis GenAI Connect rule.
Step 8 - Configure the Review claim summary view to display the GenAI response in a table.
Add the ProviderList embedded data field.
Select Table display and relevant columns.
Additional information
- Though I recevied accurate results from Claude-Sonnet-45 model, there were some other AI models that returned incorrect results. We’ll need to validate the final response from AI.
= = =
Please feel free to leave any comment or question.

















