# US 12,118,352 B2 · Code interdependency analysis system

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

- Number: US 12,118,352 B2
- Document ID: US12118352B2
- Status: Granted
- Kind: B2
- Application number: 18/389,262
- Filed: 2023-11-14
- Published: 2024-03-07
- Granted: 2024-10-15
- Earliest claimed: 2021-10-20
- Assignees: Evernorth Strategic Development, Inc.
- Applicants: Evernorth Strategic Development, Inc.
- Inventors: Brittany P. DePoi; Jonathan E. Magen
- Web page: https://patentgrep.com/patent/US12118352B2

## CPC

- G06F 8/77: Software metrics
- G06F 8/36: Software reuse
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A system and method of generating a reuse metric starts with a processor receiving from a client device, a program comprising modules. Processor extracts the modules from the program and generates frequency tables associated with the modules. Frequency tables includes numbers of imports associated with the modules, and import ratios associated with the modules. Processor generates, based on the frequency tables, a histogram of the modules and the import ratios. Processor generates key statistical measures based on the import ratios and the histogram. Generating the key statistical measures comprises determining histogram weights, determining a Pareto fit of the histogram, and generating a reuse metric based on the Pareto fit and a Kurtosis of the histogram weights. Processor causes the client device to display the reuse metric and the histogram. Other embodiments are disclosed herein.

## Claims

### Claim 1

A method comprising:
receiving, by a processor, from a client device, a program, wherein the program is a software project or software code base that comprises a plurality of modules;
extracting the plurality of modules from the program;
generating a plurality of frequency tables associated with the plurality of modules, wherein the frequency tables include a plurality of numbers of imports associated with the modules, and a plurality of import ratios associated with the modules;
generating, based on the frequency tables, a histogram of the modules and the import ratios;
generating a plurality of key statistical measures based on the import ratios and the histogram, wherein generating the key statistical measures comprises:
determining histogram weights,
determining a Pareto fit of the histogram, and
generating a reuse metric based on the Pareto fit and a Kurtosis of the histogram weights; and
causing testing of a least used module in the modules or a most used module in the modules, wherein the least used module and the most used module are identified based on the reused metric.

### Claim 2 (depends on 1)

The method of claim 1, wherein the plurality of modules comprise a plurality of interdependent modules, wherein the interdependent modules comprise modules that are imported, modules that import modules, or a combination thereof.

### Claim 3 (depends on 1)

The method of claim 1, wherein generating the frequency tables further comprises:
determining the import ratios associated with the plurality of modules, the import ratios being based on the numbers of imports associated with the modules and a total number of modules in the program.

### Claim 4 (depends on 1)

The method of claim 1, wherein generating the key statistical measures further comprises:
filtering non-negative histogram weights from the histogram.

### Claim 5 (depends on 4)

The method of claim 4, wherein determining the Pareto fit of the histogram further comprises:
determining the Pareto fit of the non-negative histogram weights.

### Claim 6 (depends on 5)

The method of claim 5, wherein the reuse metric comprises a result of subtracting the Kurtosis of the histogram weights from the Pareto fit.

### Claim 7 (depends on 6)

The method of claim 6, wherein generating the key statistical measures further comprises:
generating a weak distance metric by computing an absolute value of the reuse metric.

### Claim 8 (depends on 7)

The method of claim 7, wherein the key statistical measures comprise the Pareto fit, the Kurtosis of the histogram weights, the reuse metric, the weak distance metric, or any combination thereof.

### Claim 9 (depends on 8)

The method of claim 8, wherein the key statistical measures further comprise a plurality of properties including:
an entropy, a maximum import ratio, a minimum import ratio, a mean import ratio, a plurality of percentiles associated with the import ratios, skewness of the histogram weights, standard deviation of the import ratios, variance of the import ratios, interquartile range of the import ratios, variation of the import ratios, the kurtosis of the histogram weights, modular inconsistency based on the entropy and the variation.

### Claim 10 (depends on 8)

The method of claim 8, further comprising:
causing the key statistical measures to be displayed by the client device.

### Claim 11 (depends on 8)

The method of claim 8, further comprising:
generating a plurality of graphs based on the plurality of modules;
generating graph data based on the graphs, wherein, for each of the graphs, the graph data comprises statistical measures.

### Claim 12 (depends on 1)

The method of claim 1, wherein the program is a system code base.

### Claim 13

A non-transitory computer-readable storage medium, the computer-readable storage medium storing instructions that when executed by a processor, cause the processor to perform operations comprising:
receiving from a client device, a program, wherein the program is a software project or software code base that comprises a plurality of modules;
extracting the plurality of modules from the program;
generating a plurality of frequency tables associated with the plurality of modules, wherein the frequency tables include a plurality of numbers of imports associated with the modules, and a plurality of import ratios associated with the modules;
generating, based on the frequency tables, a histogram of the modules and the import ratios;
generating a plurality of key statistical measures based on the import ratios and the histogram, wherein generating the key statistical measures comprises:
determining histogram weights,
determining a Pareto fit of the histogram, and
generating a reuse metric based on the Pareto fit and a Kurtosis of the histogram weights; and
causing testing of a least used module in the modules or a most used module in the modules, wherein the least used module and the most used module are identified based on the reused metric.

### Claim 14 (depends on 13)

The non-transitory computer-readable storage medium of claim 13, wherein the plurality of modules comprise a plurality of interdependent modules, wherein the interdependent modules comprise modules that are imported, modules that import modules, or a combination thereof.

### Claim 15 (depends on 13)

The non-transitory computer-readable storage medium of claim 13, wherein generating the frequency tables further comprises:
determining the import ratios associated with the plurality of modules, the import ratios being based on the numbers of imports associated with the modules and a total number of modules in the program.

### Claim 16 (depends on 13)

The non-transitory computer-readable storage medium of claim 13, wherein generating the key statistical measures further comprises:
filtering non-negative histogram weights from the histogram, and
wherein determining the Pareto fit of the histogram further comprises determining the Pareto fit of the non-negative histogram weights.

### Claim 17 (depends on 16)

The non-transitory computer-readable storage medium of claim 16, wherein the reuse metric comprises a result of subtracting the Kurtosis of the histogram weights from the Pareto fit.

### Claim 18 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein generating the key statistical measures further comprises:
generating a weak distance metric by computing an absolute value of the reuse metric.

### Claim 19 (depends on 18)

The non-transitory computer-readable storage medium of claim 18, wherein the key statistical measures comprise the Pareto fit, the Kurtosis of the histogram weights, the reuse metric, the weak distance metric, or any combination thereof.

### Claim 20

A system comprising:
a processor; and
a memory storing instructions that, when executed by the processor, causes the system to perform operations comprising:
receiving from a client device, a program, wherein the program is a software project or software code base that comprises a plurality of modules;
extracting the plurality of modules from the program;
generating a plurality of frequency tables associated with the plurality of modules, wherein the frequency tables include a plurality of numbers of imports associated with the modules, and a plurality of import ratios associated with the modules;
generating, based on the frequency tables, a histogram of the modules and the import ratios;
generating a plurality of key statistical measures based on the import ratios and the histogram, wherein generating the key statistical measures comprises:
determining histogram weights,
determining a Pareto fit of the histogram, and
generating a reuse metric based on the Pareto fit and a Kurtosis of the histogram weights; and
causing testing of a least used module in the modules or a most used module in the modules, wherein the least used module and the most used module are identified based on the reused metric.
