# US 2026/0065034 A1 · Multi-domain bias and hallucination evaluation systems and methods for large language models

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2026/0065034 A1
- Document ID: US20260065034A1
- Status: Published application
- Kind: A1
- Application number: 18/825,838
- Filed: 2024-09-05
- Published: 2026-03-05
- Earliest claimed: 2024-09-05
- Assignees: Wells Fargo Bank, N.A.
- Applicants: Wells Fargo Bank, N.A.
- Inventors: Naveen Gururaja Yeri; Shuvam Sengupta; Ramesh Babu Sarvesetty
- Web page: https://patentgrep.com/patent/US20260065034A1

## CPC

- G06N 3/0475: Generative networks
- G06F 40/186: Templates
- G06F 40/30: Semantic analysis
- G06F 40/35: Discourse or dialogue representation
- G06F 40/40: Processing or translation of natural language (natural language analysis G06F40/20; semantic analysis G06F40/30)
- G06F 40/56: Natural language generation
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A method may include generating a test set of prompts; executing a generative artificial intelligence (GenAI) machine learning model using the test set of prompts; in response to the executing, receiving a plurality of generated answers; classifying the plurality of generated answers into a first group and a second group; calculating a percentage of generated answers in the first group compared to a total number of answers of the first group and second group; determining the percentage exceeds a value; based on the determining, updating a bias metric the GenAI machine learning model; and presenting the bias metric on a user interface.

## Claims

### Claim 1

A method comprising:
generating a test set of prompts;
executing a generative artificial intelligence (GenAI) machine learning model using the test set of prompts;
in response to the executing, receiving a plurality of generated answers;
classifying the plurality of generated answers into a first group and a second group;
calculating a percentage of generated answers in the first group compared to a total number of answers of the first group and second group;
determining the percentage exceeds a value;
based on the determining, updating a bias metric the GenAI machine learning model; and
presenting the bias metric on a user interface.

### Claim 2 (depends on 1)

The method of claim 1, wherein generating the test set of prompts includes:
accessing a base prompt template, the base prompt template including a demographic characteristic field; and
modifying the demographic characteristic field in the base prompt template to include a type of the demographic characteristic.

### Claim 3 (depends on 1)

The method of claim 1, wherein classifying the plurality of generated answers into the first group and the second group includes, for an answer in the plurality of generated answers:
classifying, using a natural language processor, the answer as having a positive sentiment.

### Claim 4 (depends on 3)

The method of claim 3, wherein determining the percentage exceeds a value includes:
querying a database for a historical percentage of answers having a positive sentiment; and
using the historical percentage as a basis for the value.

### Claim 5 (depends on 1)

The method of claim 1, further comprising:
generating a first text embedding of an answer in the plurality of generated answers;
generating a second text embedding of a training data set used for training the GenAI machine learning model;
calculating a cosine similarity metric between the first text embedding and the second text embedding; and
updating a hallucination metric for the GenAI machine learning model based on the cosine similarity metric.

### Claim 6 (depends on 5)

The method of claim 5, wherein the training data set is a first training data set and has a stored categorization of a first domain.

### Claim 7 (depends on 6)

The method of claim 6, further comprising:
generating a third text embedding of a second training data set used for training the GenAI machine learning model, the second training data set having a stored categorization of a second domain;
calculating a cosine similarity metric between the first text embedding and the third text embedding; and
updating the hallucination metric for the GenAI machine learning model based on the cosine similarity metric between the first text embedding and the third text embedding.

### Claim 8 (depends on 1)

The method of claim 1, wherein the GenAI machine learning model includes a transformer layer.

### Claim 9

A system comprising:
a processing unit; and
a storage device comprising instructions, which when executed by the processing unit, configure the processing unit to perform operations comprising:
generating a test set of prompts;
executing a generative artificial intelligence (GenAI) machine learning model using the test set of prompts;
in response to the executing, receiving a plurality of generated answers;
classifying the plurality of generated answers into a first group and a second group;
calculating a percentage of generated answers in the first group compared to a total number of answers of the first group and second group;
determining the percentage exceeds a value;
based on the determining, updating a bias metric the GenAI machine learning model; and
presenting the bias metric on a user interface.

### Claim 10 (depends on 9)

The system of claim 9, wherein generating the test set of prompts includes:
accessing a base prompt template, the base prompt template including a demographic characteristic field; and
modifying the demographic characteristic field in the base prompt template to include a type of the demographic characteristic.

### Claim 11 (depends on 9)

The system of claim 9, wherein classifying the plurality of generated answers into the first group and the second group includes, for an answer in the plurality of generated answers:
classifying, using a natural language processor, the answer as having a positive sentiment.

### Claim 12 (depends on 11)

The system of claim 11, wherein determining the percentage exceeds a value includes:
querying a database for a historical percentage of answers having a positive sentiment; and
using the historical percentage as a basis for the value.

### Claim 13 (depends on 9)

The system of claim 9, wherein the instructions, which when executed by the processing unit, further configure the processing unit to perform operations comprising:
generating a first text embedding of an answer in the plurality of generated answers;
generating a second text embedding of a training data set used for training the GenAI machine learning model;
calculating a cosine similarity metric between the first text embedding and the second text embedding; and
updating a hallucination metric for the GenAI machine learning model based on the cosine similarity metric.

### Claim 14 (depends on 13)

The system of claim 13, wherein the training data set is a first training data set and has a stored categorization of a first domain.

### Claim 15 (depends on 14)

The system of claim 14, wherein the instructions, which when executed by the processing unit, further configure the processing unit to perform operations comprising:
generating a third text embedding of a second training data set used for training the GenAI machine learning model, the second training data set having a stored categorization of a second domain;
calculating a cosine similarity metric between the first text embedding and the third text embedding; and
updating the hallucination metric for the GenAI machine learning model based on the cosine similarity metric between the first text embedding and the third text embedding.

### Claim 16 (depends on 9)

The system of claim 9, wherein the GenAI machine learning model includes a transformer layer.

### Claim 17

A non-transitory computer-readable medium comprising instructions, which when executed by a processing unit, configure the processing unit to perform operations comprising:
generating a test set of prompts;
executing a generative artificial intelligence (GenAI) machine learning model using the test set of prompts;
in response to the executing, receiving a plurality of generated answers;
classifying the plurality of generated answers into a first group and a second group;
calculating a percentage of generated answers in the first group compared to a total number of answers of the first group and second group;
determining the percentage exceeds a value;
based on the determining, updating a bias metric the GenAI machine learning model; and
presenting the bias metric on a user interface.

### Claim 18 (depends on 17)

The non-transitory computer-readable medium of claim 17, wherein generating the test set of prompts includes:
accessing a base prompt template, the base prompt template including a demographic characteristic field; and
modifying the demographic characteristic field in the base prompt template to include a type of the demographic characteristic.

### Claim 19 (depends on 17)

The non-transitory computer-readable medium of claim 17, wherein classifying the plurality of generated answers into the first group and the second group includes, for an answer in the plurality of generated answers:
classifying, using a natural language processor, the answer as having a positive sentiment.

### Claim 20 (depends on 19)

The non-transitory computer-readable medium of claim 19, wherein determining the percentage exceeds a value includes:
querying a database for a historical percentage of answers having a positive sentiment; and
using the historical percentage as a basis for the value.
