# US 12,002,022 B2 · Interchange code prediction system for processing credit card transactions

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

- Number: US 12,002,022 B2
- Document ID: US12002022B2
- Status: Granted
- Kind: B2
- Application number: 17/218,856
- Filed: 2021-03-31
- Published: 2022-10-13
- Granted: 2024-06-04
- Earliest claimed: 2021-03-31
- Assignees: Toast, Inc.
- Applicants: Toast, Inc.
- Inventors: Alan Z. Zhao; Benjamin C. W. Tang
- Web page: https://patentgrep.com/patent/US12002022B2

## CPC

- G06Q 20/102: {Bill distribution or payments}
- G06Q 20/34: using cards, e.g. integrated circuit [IC] cards or magnetic cards
- G06N 5/01: Dynamic search techniques; Heuristics; Dynamic trees; Branch-and-bound
- G06N 20/00: Machine learning
- G06N 20/20: Ensemble learning
- G06Q 20/24: Credit schemes, i.e. "pay after"
- G06Q 20/26: Debit schemes, e.g. "pay now"
- G06Q 20/401: {Transaction verification}
- G06Q 20/405: {Establishing or using transaction specific rules}
- G06Q 20/4093: {Monitoring of device authentication}
- G06Q: INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

A computer-implemented method for predicting interchange charges includes: retrieving a historical transactions set, where each completed transaction in the set includes transaction features, a bank identification number (BIN), and a corresponding true interchange code; transforming all BINs in the set into a corresponding plurality of BIN features that comprise probabilities; creating a first training set including all transaction features, all pluralities of BIN features, and all true interchange codes associated with the historical transactions set; training a random forest model using the first training set and generating a second training set including rounded BIN features, rounded transaction features, discrete ones of the transaction features, and the true interchange codes; training the random forest model using the second training set to generate a trained random forest model for prediction of the interchange codes; and executing the trained random forest model for new transactions to generate corresponding predicted interchange codes.

## Claims

### Claim 1

A computer-implemented method for predicting interchange codes corresponding to credit card transactions, the method comprising:
retrieving a historical completed transactions set from a database that corresponds to a plurality of merchants, where each completed transaction in the set comprises transaction features, a bank identification number (BIN), and a corresponding true interchange code;
transforming all BINs in the set into a corresponding plurality of BIN features that comprise probabilities of a given BIN falling into each of the corresponding plurality of BIN features;
creating a first training set comprising all transaction features, all pluralities of BIN features, and all true interchange codes associated with the historical completed transactions set;
training a random forest model using the first training set, wherein said training comprises rounding of all BIN features and non-discrete ones of the transaction features, and generating a second training set comprising rounded BIN features, rounded transaction features, discrete ones of the transaction features, and the true interchange codes;
training the random forest model using the second training set to generate a trained random forest model for prediction of the true interchange codes; and
executing the trained random forest model for new transactions to generate corresponding predicted interchange codes.

### Claim 2 (depends on 1)

The computer-implemented method as recited in claim 1, wherein the transaction features comprise a total transaction amount along and a tip percentage.

### Claim 3 (depends on 2)

The computer-implemented method as recited in claim 2, wherein the transaction features further comprise a time in hours between transaction authorization and transaction capture.

### Claim 4 (depends on 3)

The computer-implemented method as recited in claim 3, wherein the transaction features further comprise a type of transaction and an address verification system response.

### Claim 5 (depends on 4)

The computer-implemented method as recited in claim 4, wherein the transaction features further comprise a card network, a card type, and a merchant category code.

### Claim 6 (depends on 1)

The computer-implemented method as recited in claim 1, wherein the plurality of BIN features comprises regulated debit, debit, rewards, and high rewards.

### Claim 7 (depends on 1)

The computer-implemented method as recited in claim 1, wherein the corresponding predicted interchange codes comprise a weighted sum of interchange rates and fees for a plurality of predicted interchange codes, where each of the plurality of predicted interchange codes comprises a weight, the weight indicating the probability that a corresponding transaction will be assigned to a corresponding one of the plurality of predicted interchange codes.

### Claim 8

A non-transitory computer-readable storage medium storing instructions that, when executed by a computer, cause the computer to perform a method for using a computer system to predict interchange codes corresponding to credit card transactions, the method comprising:
retrieving a historical completed transactions set from a database that corresponds to a plurality of merchants, where each completed transaction in the set comprises transaction features, a bank identification number (BIN), and a corresponding true interchange code;
transforming all BINs in the set into a corresponding plurality of BIN features that comprise probabilities of a given BIN falling into each of the corresponding plurality of BIN features;
creating a first training set comprising all transaction features, all pluralities of BIN features, and all true interchange codes associated with the historical completed transactions set;
training a random forest model using the first training set, wherein said training comprises rounding of all BIN features and non-discrete ones of the transaction features, and generating a second training set comprising rounded BIN features, rounded transaction features, discrete ones of the transaction features, and the true interchange codes;
training the random forest model using the second training set to generate a trained random forest model for prediction of the true interchange codes; and
executing the trained random forest model for new transactions to generate corresponding predicted interchange codes.

### Claim 9 (depends on 8)

The non-transitory computer-readable storage medium as recited in claim 8, wherein the transaction features comprise a total transaction amount along and a tip percentage.

### Claim 10 (depends on 9)

The non-transitory computer-readable storage medium as recited in claim 9, wherein the transaction features further comprise a time in hours between transaction authorization and transaction capture.

### Claim 11 (depends on 10)

The non-transitory computer-readable storage medium as recited in claim 10, wherein the transaction features further comprise a type of transaction and an address verification system response.

### Claim 12 (depends on 11)

The non-transitory computer-readable storage medium as recited in claim 11, wherein the transaction features further comprise a card network, a card type, and a merchant category code.

### Claim 13 (depends on 8)

The non-transitory computer-readable storage medium as recited in claim 8, wherein the plurality of BIN features comprises regulated debit, debit, rewards, and high rewards.

### Claim 14 (depends on 8)

The non-transitory computer-readable storage medium as recited in claim 8, wherein the corresponding predicted interchange codes comprise a weighted sum of interchange rates and fees for a plurality of predicted interchange codes, where each of the plurality of predicted interchange codes comprises a weight, the weight indicating the probability that a corresponding transaction will be assigned to a corresponding one of the plurality of predicted interchange codes.

### Claim 15

A computer program product for predicting interchange codes corresponding to credit card transactions, the computer program product comprising:
a computer readable non-transitory medium having computer readable program code stored thereon, the computer readable program code comprising:
program instructions that, when executed by a processor, cause the processor to retrieve a historical completed transactions set from a database that corresponds to a plurality of merchants, where each completed transaction in the set comprises transaction features, a bank identification number (BIN), and a corresponding true interchange code;
program instructions that, when executed by a processor, cause the processor to transform all BINs in the set into a corresponding plurality of BIN features that comprise probabilities of a given BIN falling into each of the corresponding plurality of BIN features;
program instructions that, when executed by a processor, cause the processor to create a first training set comprising all transaction features, all pluralities of BIN features, and all true interchange codes associated with the historical completed transactions set;
program instructions that, when executed by a processor, cause the processor to train a random forest model using the first training set, wherein said training comprises rounding of all BIN features and non-discrete ones of the transaction features, and generating a second training set comprising rounded BIN features, rounded transaction features, discrete ones of the transaction features, and the true interchange codes;
program instructions that, when executed by a processor, cause the processor to train the random forest model using the second training set to generate a trained random forest model for prediction of the true interchange codes; and
program instructions that, when executed by a processor, cause the processor to execute the trained random forest model for new transactions to generate corresponding predicted interchange codes.

### Claim 16 (depends on 15)

The computer program product as recited in claim 15, wherein the transaction features comprise a total transaction amount along and a tip percentage.

### Claim 17 (depends on 16)

The computer program product as recited in claim 16, wherein the transaction features further comprise a time in hours between transaction authorization and transaction capture.

### Claim 18 (depends on 17)

The computer program product as recited in claim 17, wherein the transaction features further comprise a type of transaction and an address verification system response.

### Claim 19 (depends on 15)

The computer program product as recited in claim 15, wherein the plurality of BIN features comprises regulated debit, debit, rewards, and high rewards.

### Claim 20 (depends on 15)

The computer program product as recited in claim 15, wherein the corresponding predicted interchange codes comprise a weighted sum of interchange rates and fees for a plurality of predicted interchange codes, where each of the plurality of predicted interchange codes comprises a weight, the weight indicating the probability that a corresponding transaction will be assigned to a corresponding one of the plurality of predicted interchange codes.
