SYSTEM AND METHOD FOR PROVIDING GLOBAL COUNTERFACTUAL EXPLANATIONS IN ARTIFICIAL INTELLIGENCE

A method for providing a global counterfactual explanation and a system for implementing the method are disclosed. The method includes generating an initial ground set based on a first candidate set of outer-If conditions, and a second candidate set used for selecting Inner-If or Then conditions. The method then evaluates a fixed number of triples and forms a new ground set that provides a recourse accuracy level above a reference threshold, in which the fixed number of triples included in the new ground set is less than a number of triples included in the initial ground set. The method further includes sorting the new ground set by recourse accuracy, selecting a predetermined number of triples based on corresponding recourse accuracies indicated in the sorting, and performing calculation based on the selected number of triples.

TECHNICAL FIELD

This disclosure generally relates to a system and method for providing global counter factual explanations.

BACKGROUND

The developments described in this section are known to the inventors. However, unless otherwise indicated, it should not be assumed that any of the developments described in this section qualify as prior art merely by virtue of their inclusion in this section, or that those developments are known to a person of ordinary skill in the art.

Counterfactual explanations (CEs) are a common tool for determining what small changes can be made to the input of a model such that the output changes to the desired prediction. The CEs may be used in settings whereby an end user may, for example, be informed of a slight change in information for rendering a different outcome or result. For example, the CEs may indicate a slight change in the user's loan application (e.g., debt level) may change a rejection decision to an approval.

Although CEs have been applied locally or at an individual level, attempts have been made to apply the CEs globally. In such a setting, global CEs (GCEs) may indicate small changes that can be made to groups of inputs, or subgroups, such that model predictions are flipped for a sufficient proportion with the subgroups. The GCEs may be used to compare recourses between subgroups to assess model fairness. For example, if the global recourses for foreign workers are much more costly than for non-foreign workers, this may suggest some level of model bias.

However, currently available frameworks for providing GCEs perform poorly on datasets with a large proportion of continuous features and is also computationally inefficient, leading to excessive utilization of processor resources. Such deficiencies may pose a problem to (a) practitioners who wish to quickly vet the fairness of their models, and (b) models which incorporate fairness assessment into their training procedures.

SUMMARY

According to an aspect of the present disclosure, a method for outputting a global counterfactual explanation is provided. The method includes performing, using a processor and a memory: generating an initial ground set based on a first candidate set of outer-If conditions (SD), and a second candidate set used for selecting Inner-If or Then conditions (RL); evaluating a fixed number of triples and forming a new ground set that provides a recourse accuracy level above a reference threshold, in which the fixed number of triples included in the new ground set is less than a number of triples included in the initial ground set; sorting the new ground set by recourse accuracy; selecting a predetermined number of triples based on corresponding recourse accuracies indicated in the sorting; and performing calculation based on the selected number of triples.

According to another aspect of the present disclosure, the generating of the ground set is performed by iterating over the second candidate set in O(n) time and computing feature combinations, before removing any items that contain a feature combination that only occurs once, for yielding a new RL with size an, in which a is greater than or equal to 0 and less than or equal 1.

According to another aspect of the present disclosure, the generating of the ground set is performed by filtering a dataset based on the outer-If or the inner-If conditions, and separately deploying a method for generating Then conditions.

According to yet another aspect of the present disclosure, each triple includes an outer-If condition, an inner-If condition, and a Then condition.

According to another aspect of the present disclosure, the selecting of the predetermined number of triples includes selecting highest-performing triples within the new ground set.

According to a further aspect of the present disclosure, each triple forming the new ground set increases the recourse accuracy level.

According to yet another aspect of the present disclosure, one or more constraints are applied during the generating of the initial ground set.

According to a further aspect of the present disclosure, the initial ground set removes a feature combination that only occurs once.

According to another aspect of the present disclosure, an upper bound defined as acc(R)≤acc(V) is reached before an algorithm for providing the global counterfactual explanation has completed execution, acc(R) is a percentage of instances in Xaffthat are provided with a successful recourse, Xaffis a set of individuals with an unfavorable prediction from a model, and acc(v) is a recourse accuracy.

According to a further aspect of the present disclosure, the algorithm is terminated prior to its completion when the upper bound for saturation is reached.

According to another aspect of the present disclosure, a system for outputting a global counterfactual explanation is disclosed. The system includes at least one processor; at least one memory; and at least one communication circuit. The at least one processor performs: generating an initial ground set based on a first candidate set of outer-If conditions (SD), and a second candidate set used for selecting Inner-If or Then conditions (RL); evaluating a fixed number of triples and forming a new ground set that provides a recourse accuracy level above a reference threshold, in which the fixed number of triples included in the new ground set is less than a number of triples included in the initial ground set; sorting the new ground set by recourse accuracy; selecting a predetermined number of triples based on corresponding recourse accuracies indicated in the sorting; and performing calculation based on the selected number of triples.

According to a further aspect of the present disclosure, the generating of the ground set is performed by iterating over the second candidate set in O(n) time and computing feature combinations, before removing any items that contain a feature combination that only occurs once, for yielding a new RL with size an, in which a is greater than or equal to 0 and less than or equal 1.

According to a further aspect of the present disclosure, the generating of the ground set is performed by filtering a dataset based on the outer-If or the inner-If conditions, and separately deploying a method for generating Then conditions.

According to a further aspect of the present disclosure, each triple includes an outer-If condition, an inner-If condition, and a Then condition.

According to a further aspect of the present disclosure, the selecting of the predetermined number of triples includes selecting highest-performing triples within the new ground set.

According to a further aspect of the present disclosure, each triple forming the new ground set increases the recourse accuracy level.

According to a further aspect of the present disclosure, one or more constraints are applied during the generating of the initial ground set.

According to a further aspect of the present disclosure, the initial ground set removes a feature combination that only occurs once.

According to a further aspect of the present disclosure, an upper bound defined as acc(R)≤acc(V) is reached before an algorithm for providing the global counterfactual explanation has completed execution, acc(R) is a percentage of instances in Xaffthat are provided with a successful recourse, Xaffis a set of individuals with an unfavorable prediction from a model, and acc(v) is a recourse accuracy.

According to a further aspect of the present disclosure, the algorithm is terminated prior to its completion when the upper bound for saturation is reached.

DETAILED DESCRIPTION

FIG.1illustrates a computer system for implementing a global counter explanation (GCE) system in accordance with an exemplary embodiment.

The system100is generally shown and may include a computer system102, which is generally indicated. The computer system102may include a set of instructions that can be executed to cause the computer system102to perform any one or more of the methods or computer-based functions disclosed herein, either alone or in combination with the other described devices. The computer system102may operate as a standalone device or may be connected to other systems or peripheral devices. For example, the computer system102may include, or be included within, any one or more computers, servers, systems, communication networks or cloud environment. Even further, the instructions may be operative in such cloud-based computing environment.

Furthermore, the computer system102may include any additional devices, components, parts, peripherals, hardware, software or any combination thereof which are commonly known and understood as being included with or within a computer system, such as, but not limited to, a network interface114and an output device116. The network interface114may include, without limitation, a communication circuit, a transmitter or a receiver. The output device116may be, but is not limited to, a speaker, an audio out, a video out, a remote-control output, a printer, or any combination thereof.

In accordance with various embodiments of the present disclosure, the methods described herein may be implemented using a hardware computer system that executes software programs. Further, in an exemplary, non-limited embodiment, implementations can include distributed processing, component/object distributed processing, and an operation mode having parallel processing capabilities. Virtual computer system processing can be constructed to implement one or more of the methods or functionality as described herein, and a processor described herein may be used to support a virtual processing environment.

FIG.2illustrates an exemplary diagram of a network environment with a GCE system in accordance with an exemplary embodiment.

A GCE system (GCES)202may be implemented with one or more computer systems similar to the computer system102as described with respect toFIG.1.

The GCE system202may store one or more applications that can include executable instructions that, when executed by the GCE system202, cause the GCE system202to perform actions, such as to execute, transmit, receive, or otherwise process network messages, for example, and to perform other actions described and illustrated below with reference to the figures. The application(s) may be implemented as modules or components of other applications. Further, the application(s) can be implemented as operating system extensions, modules, plugins, or the like.

Even further, the application(s) may be operative in a cloud-based computing environment or other networking environments. The application(s) may be executed within or as virtual machine(s) or virtual server(s) that may be managed in a cloud-based computing environment. Also, the application(s), and even the GCE system202itself, may be located in virtual server(s) running in a cloud-based computing environment rather than being tied to one or more specific physical network computing devices. Also, the application(s) may be running in one or more virtual machines (VMs) executing on the GCE system202. Additionally, in one or more embodiments of this technology, virtual machine(s) running on the GCE system202may be managed or supervised by a hypervisor.

In the network environment200ofFIG.2, the GCE system202is coupled to a plurality of server devices204(1)-204(n) that hosts a plurality of databases206(1)-206(n), and also to a plurality of client devices208(1)-208(n) via communication network(s)210. According to exemplary aspects, databases206(1)-206(n) may be configured to store data that relates to distributed ledgers, blockchains, user account identifiers, biller account identifiers, and payment provider identifiers. A communication interface of the GCE system202, such as the network interface114of the computer system102ofFIG.1, operatively couples and communicates between the GCE system202, the server devices204(1)-204(n), and/or the client devices208(1)-208(n), which are all coupled together by the communication network(s)210, although other types and/or numbers of communication networks or systems with other types and/or numbers of connections and/or configurations to other devices and/or elements may also be used.

The communication network(s)210may be the same or similar to the network122as described with respect toFIG.1, although the GCE system202, the server devices204(1)-204(n), and/or the client devices208(1)-208(n) may be coupled together via other topologies. Additionally, the network environment200may include other network devices such as one or more routers and/or switches, for example, which are well known in the art and thus will not be described herein.

The GCE system202may be a standalone device or integrated with one or more other devices or apparatuses, such as one or more of the server devices204(1)-204(n), for example. In one particular example, the GCE system202may be hosted by one of the server devices204(1)-204(n), and other arrangements are also possible. Moreover, one or more of the devices of the GCE system202may be in the same or a different communication network including one or more public, private, or cloud networks, for example.

The server devices204(1)-204(n) may be hardware or software or may represent a system with multiple servers in a pool, which may include internal or external networks. The server devices204(1)-204(n) hosts the databases206(1)-206(n) that are configured to store metadata sets, data quality rules, and newly generated data.

The plurality of client devices208(1)-208(n) may also be the same or similar to the computer system102or the computer device120as described with respect toFIG.1, including any features or combination of features described with respect thereto. Client device in this context refers to any computing device that interfaces to communications network(s)210to obtain resources from one or more server devices204(1)-204(n) or other client devices208(1)-208(n).

According to exemplary embodiments, the client devices208(1)-208(n) in this example may include any type of computing device that can facilitate the implementation of the GCE system202that may efficiently provide a platform for implementing a cloud native GCE system module, but the disclosure is not limited thereto.

One or more of the devices depicted in the network environment200, such as the GCE system202, the server devices204(1)-204(n), or the client devices208(1)-208(n), for example, may be configured to operate as virtual instances on the same physical machine. For example, one or more of the GCE system202, the server devices204(1)-204(n), or the client devices208(1)-208(n) may operate on the same physical device rather than as separate devices communicating through communication network(s)210. Additionally, there may be more or fewer GCE system202, server devices204(1)-204(n), or client devices208(1)-208(n) than illustrated inFIG.2. According to exemplary embodiments, the GCE system202may be configured to send code at run-time to remote server devices204(1)-204(n), but the disclosure is not limited thereto.

FIG.3illustrates a system diagram for implementing a GCE system in accordance with an exemplary embodiment.

As illustrated inFIG.3, the system300may include a GCE system302within which a group of API modules306is embedded, a server304, a database(s)312, a plurality of client devices308(1) . . .308(n), and a communication network310.

According to exemplary embodiments, the GCE system302including the API modules306may be connected to the server304, and the database(s)312via the communication network310. Although there is only one database that has been illustrated, the disclosure is not limited thereto. Any number of databases may be utilized. The GCE system302may also be connected to the plurality of client devices308(1) . . .308(n) via the communication network310, but the disclosure is not limited thereto.

According to exemplary embodiment, the GCE system302is described and shown inFIG.3as including the API modules306, although it may include other rules, policies, modules, databases, or applications, for example. According to exemplary embodiments, the database(s)312may be embedded within the GCE system302. According to exemplary embodiments, the database(s)312may be configured to store configuration details data corresponding to a desired data to be fetched from one or more data sources, user information data etc., but the disclosure is not limited thereto.

According to exemplary embodiments, the API modules306may be configured to receive real-time feed of data or data at predetermined intervals from the plurality of client devices308(1) . . .308(n) via the communication network310.

The API modules306may be configured to implement a user interface (UI) platform that is configured to enable GCE system as a service for a desired data processing scheme. The UI platform may include an input interface layer and an output interface layer. The input interface layer may request preset input fields to be provided by a user in accordance with a selection of an automation template. The UI platform may receive user input, via the input interface layer, of configuration details data corresponding to a desired data to be fetched from one or more data sources. The user may specify, for example, data sources, parameters, destinations, rules, and the like. The UI platform may further fetch the desired data from said one or more data sources based on the configuration details data to be utilized for the desired data processing scheme, automatically implement a transformation algorithm on the desired data corresponding to the configuration details data and the desired data processing scheme to output a transformed data in a predefined format, and transmit, via the output interface layer, the transformed data to downstream applications or systems.

The plurality of client devices308(1) . . .308(n) are illustrated as being in communication with the GCE system302. In this regard, the plurality of client devices308(1) . . .308(n) may be “clients” of the GCE system302and are described herein as such. Nevertheless, it is to be known and understood that the plurality of client devices308(1) . . .308(n) need not necessarily be “clients” of the GCE system302, or any entity described in association therewith herein. Any additional or alternative relationship may exist between either or both of the plurality of client devices308(1) . . .308(n) and the GCE system302, or no relationship may exist.

The first client device308(1) may be, for example, a smart phone. Of course, the first client device308(1) may be any additional device described herein. The second client device308(n) may be, for example, a personal computer (PC). Of course, the second client device308(n) may also be any additional device described herein. According to exemplary embodiments, the server304may be the same or equivalent to the server device204as illustrated inFIG.2.

The process may be executed via the communication network310, which may comprise plural networks as described above. For example, in an exemplary embodiment, one or more of the plurality of client devices308(1) . . .308(n) may communicate with the GCE system302via broadband or cellular communication. Of course, these embodiments are merely exemplary and are not limiting or exhaustive.

The computing device301may be the same or similar to any one of the client devices208(1)-208(n) as described with respect toFIG.2, including any features or combination of features described with respect thereto. The GCE system302may be the same or similar to the GCE system202as described with respect toFIG.2, including any features or combination of features described with respect thereto.

FIG.4Aillustrates a workflow for a GCE system in accordance with an exemplary embodiment.FIG.4Billustrates a summary of enhancements provided by a GCE system in accordance with an exemplary embodiment.FIG.5illustrates a redundancy in a ground set in accordance with an exemplary embodiment.

Local counterfactual explanations have been studied in explainability, with a range of application dependent methods emerging in fairness, recourse and model understanding. However, shortcomings associated with these methods includes their inability to provide explanations beyond the local or instance level. While a notion of a global explanation has been touched upon, typically suggesting aggregating masses of local explanations in the hope of ascertaining global properties, workable frameworks that are reliable and/or computationally tractable were unavailable.

Local counterfactual explanations were defined as points that are close to a query input, with respect to some distance metric, that result in a desired machine learning model prediction. Another approach included proposal of desirable properties of counterfactual explanations and generation of counterfactual explanations that achieved the desirable properties. Other approaches included generation of plausible CEs by consideration of proximity to a data manifold, or taking into account causal relations among input features. Actionability of recourse is another desired data as some features may be non-actionable and hence should not be part of the CEs. In another direction, some approaches focused on generating CEs for specific model categories (e.g., tree-based models, differentiable models).

Counterfactual explanations may identify input perturbations that result in desired predictions from machine learning (ML) models. A key benefit of these explanations is their ability to offer recourse to affected individuals in certain scenarios (e.g., automated credit decisioning). Recent years have witnessed a surge of research therein, with a focus on identifying desirable properties of CEs, developing the methods to model those properties and understanding the weaknesses and vulnerabilities of the proposed methods.

However, the research efforts so far have largely centered around local analysis, generating explanations for individual inputs. Such analysis may help to vet model behavior at an instance-level, though it is seldom obvious if the insights gained therein would generalize globally. For example, a local CE may suggest that a particular decisioning model is not biased against a protected attribute (e.g., gender, race) despite net biases existing across all inputs. A potential way to gain global insights is to aggregate local explanations, but given that the generation of CEs is generally computationally expensive, it is not evident that such an approach would scale well or retain certainly.

Despite a growing desire for global explanation methods that provide summaries of model behavior, struggles associated with summarizing complex high-dimensional models globally has yet to be comprehensively solved. Some manner of aggregations of local explanations have been suggested, although no compelling results have been shown that (a) are computationally tractable, and (b) return reliable GCEs. Although there has been a desire for more interactivity with explanation tools, alongside global summaries, such considerations cannot be accommodated until efficiency issues associated with the existing global methods were addressed.

Although Actionable Recourse Summaries (AReS) was recently proposed as a potential framework for constructing global counterfactual explanations (GCEs), AReS had several shortcomings that limited its application for real-world usage. Specifically, AReS was (a) computationally expensive (i.e., required heavy processing power), and (b) sensitive to continuous features. Accordingly, a modified framework was desired for providing GCEs for real-world implementation possibilities.

According to exemplary aspects, a GCE system with a modified algorithm (different than that is provided in the original AReS framework) is provided for overcoming the above noted limitations in the original AReS framework for significant performance improvements in processor utilization and reliability of data application, inclusive of continuous features.

The GCE system or framework may adopt a model agnostic, interpretable structure, termed two-level recourse set. According to exemplary aspects, the two-level recourse set may contain triples of the form Outer-If/Inner-If/Then conditions, as illustrated inFIG.4A. As further illustrated inFIG.4A, a frequent itemset mining algorithm, such as Apriori, is deployed to generate candidate sets of conditions (e.g., Sex=Male, 20≤Age≤30). These are combined to generate triples, with all valid triples forming the ground set V. In an example, a valid triple requires that the features in the Outer-If/Inner-If conditions do not match, and the features in the Inner-If/Then conditions match exactly with at least one change in feature value. Although Apriori is referenced herein for the frequent itemset mining algorithm, aspects of the present disclosure are not limited thereto, such that other frequent itemset mining algorithm may be utilized without limitation.

The candidate set of Outer-If conditions is referred to as subgroup descriptors (SD), while RL refers to a candidate set used to select Inner-If or Then conditions. For Apriori mining or other frequent itemset mining, the probability of an itemset in the data, or support threshold p, may determine the size of SD and RL, and consequently, the size of the ground set V. The subgroup descriptors SD may be set by the user to subgroups of interest, which is shown useful in assessing fairness via the disparate impact of recourses between subgroups. Otherwise, SD and RL may be assigned to the same set generated by Apriori. According to exemplary aspects, the GCE system or framework may deploy a non-monotone submodular maximization algorithm that selects, from the ground set V, a final, smaller set of rules R. Interpretability constraints for the total number of triples ϵ1, the maximum width of any Outer-If/Inner-If combination ϵ2and the number of unique subgroup descriptors ϵ3in a reduced or modified set R are applied throughout. In an example, values of 20, 7, 10 were selected for ϵ1, ϵ2, ϵ3, respectively.

As noted above, while the original (OG) AReS provided a novel framework, the original AReS framework falls short on two fronts, namely, (i) computational efficiency, and (ii) continuous features, which are discussed in more detail provided below along with how the GCE system or framework overcomes such shortcomings.

(i) Computational efficiency: The AReS framework requires an extremely low p value to achieve high-performance, resulting in an impractically large ground set to optimize, and resulting computational inefficiency or impracticality. Exemplary aspects of the present disclosure provides a GCE system or framework that allows for efficient generation of denser, higher-performing ground sets, unlocking utility that is lacking in the original AReS framework.

(ii) Continuous features: the original AReS framework proposes binning continuous features prior to generating frequent item sets with Apriori. However, for models trained on continuous features, this approach struggles to trade speed with performance. Too few bins result in unrealistic recourses, but too many bins result in excessive computation time for Apriori. Exemplary aspects of the present disclosure provides a GCE system or framework includes a modified ground set generation algorithm that is different from that is utilized in the original AReS framework, and demonstrates significant improvements on continuous data.

As illustrated inFIG.4A, the GCE framework includes three general stages of processing, namely, Stage 1 (ground set generation), Stage 2 (ground set evaluation), and Stage 3 (ground set optimization).

According to exemplary aspects, SD and RL are assigned to the same set generated by Apriori. In Stage 1, SD×RL2is iterated over to compute all valid triples (Outer-If/InnerIf/Then conditions) for the ground set V. In Stage 2, each item in the ground set V is evaluated, and the optimization procedure is applied in Stage 3, returning the smaller two-level recourse set R. The three stages of processing included in the GCE framework are discussed in further detail below.

According to exemplary aspects, the GCE framework or system improves upon the original AReS framework also including 3 stages of processing, but with optimizations. In the modified AReS framework or the GCE framework, the ground set V may be defined as the set of triples from which the submodular maximization algorithm selects a two-level recourse set R⊂SD×RL2. Although a prior work by Rawal & Lakkaraju (2020) indicated that the solution to be a subset R⊂SD×RL, this is mathematically impossible given that three conditions are required to form a valid triple (unless RL contains If/Then sets, which cannot be true if SD=RL, as generated by Apriori). Authors of the above noted prior work confirmed this understanding. In an example, a dataset is denoted as X, and the set of affected individuals with an unfavorable prediction from the model as Xaff. The objective function ƒ(R) to be maximized is positive, comprising of incorrectness, coverage and cost. The metrics used in evaluating performance are recourse accuracy (the percentage of instances in Xaffthat are provided with a successful recourse), denoted acc(R), and average recourse cost (the average cost of those individuals in Xafffor whom prescribed recourses result in desired outcomes), denoted cost(R).

The overall global counterfactual search in the GCE framework for a two-level recourse set can be partitioned into three stages, as detailed inFIG.4andFIG.5. Ground set Vis generated, evaluated, and optimized (e.g., by selecting a smaller, more interpretable set, R). Each of these stages are described in more detail below, alongside exemplary optimizations. According to exemplary aspects, a recourse set R may be evaluated in terms of recourse accuracy and average recourse cost, and it should be noted that, since recourse accuracy is monotonic (a new triple cannot invalidate a previous triple), |R|≤|V|=⇒acc(R)≤acc(V), provides an upper-bound.

Ground Set Generation (Stage 1)

The optimization algorithm requires a ground set V, which may be generated by iterating through SD×RL2and selecting valid triples. To generate a larger SD or RL, and thus a larger ground set V, a smaller Apriori threshold p may be utilized. With no user input, SD and RL may be automatically assigned to the same set generated by the Apriori, giving a strict subset of V⊂RL. According to exemplary aspects, one or more invalid triples may be found in the RL3. For example, if the first element of RL is “Sex=Female”, the first iteration generates the triple “If Sex=Female, If Sex=Female, Then Sex=Female”, an invalid triple. According to exemplary aspects, |RL|=n=⇒|V|<n3. Interpretability constraints that are independent of the optimization, such as ϵ2, are applied in this stage in O(n2) and not O(n3) time.

More specifically, according to exemplary aspects, one or more constraints may be applied during the generation of the initial ground set. The GCE framework may include interpretability constraints for the total number of triples ϵ1, the maximum width of any Outer-If/Inner-If combination ϵ2 and the number of unique subgroup descriptors ϵ3 in the recourse set R. In an example, values of 20, 7, 10 are provided for ϵ1, ϵ2, ϵ3, respectively. In an example, the ϵ2 constraint for width to the ground set generation process may be expedited by constraining Apriori to only return frequent itemsets that have length ϵ2−1 or less, since those already with width ϵ2 cannot then be further combined with another itemset to form Outer-If/Inner-If conditions. If the width constraint is not violated for the If conditions, the resulting triple will automatically satisfy the constraint.

Accordingly, the constraint may be applied in the Stage 1 while the ground set is being generated (e.g., in the first two levels of the iteration through RL3). This avoids applying the width constraint mid-optimization in Stage 3, reducing the time complexity of the operation from O(n3) to O(n2). It also reduces the number of constraints used in speeding up Stage 3.

Then-Generation: A lower bound for the threshold q may be used in the Then-Generation. In fact, there always exists a lower bound when mining frequent itemsets, such as in Apriori, since no observed itemset can be observed fewer than once. Thus, setting q<1/|X| may be redundant. This allows for analysis for the full effect of 1/|X≤q≤1 inFIG.7.

According to exemplary aspects, the GCE framework provides two methods are provided for generating the ground set V. The first method may compute a similar ground set V as provided by the AReS framework, but more efficiently. The second method may compute a different ground set V.

More specifically, the first method may perform an RL reduction process. More specifically, iterating natively over SD×RL2may be wasteful, as many members of RL will never form valid “If-Then” conditions. Accordingly, the first method instead iterate over RL in O(n) time and compute feature combinations, before removing any items that contain a feature combination that only occurs once, yielding a new RL with size an, where 0≤α≤1 (note that SD=RL is left untouched). For instance, when the item “Foreign-Worker=True, Sex=Male” has a feature combination of “Foreign-Worker, Sex” that only occurs once, it can be safely removed. For a given RL, the ground set V itself may be similar to one provided by the original AReS framework, yet (1−α2)n3iterations may be saved, allowing for more efficient processing.

According to exemplary aspects, the second method may perform a Then-generation. More specifically, the second method, instead searching SD×RL2for triples, may search SD×RL for If conditions, and deploy a separate method to generate the Then conditions. Specifically for each valid element of SD×RL, with index i, its feature combination may be computed, and dataset may be filtered by these features (also removing inputs that satisfy the initial If conditions), before applying Apriori again, with threshold q, to generate a set of Then conditions, denoted Ti. Bound threshold q may be lowered as 1/|X| (i.e., no observed itemset can have frequency <1), and varying of the threshold q may have little impact on speed but reduces performance. (See e.g.,FIG.7). If m=max i|Ti| is the maximum size of any such Ti, the number of iterations may have an upper bound of n2m. The ground set generated may differ from the original method and significant improvements on continuous features may be observed.

Ground Set Evaluation (Stage 2)

The submodular maximization first evaluates the objective function ƒ over all triples v∈V, before initializing the solution R as the singleton set {v} with the maximum ƒ({v}). For a large |V|, this evaluation becomes computationally costly (e.g., requiring more CPU resources), more-so does the subsequent ground set optimization, and many triples may also be redundant. However, a large |V| may be required in order to find high-performing triples and achieve an acceptable upper bound on the final set, R⊆V. For example, if acc(V)=25%, acc(R)>25% may not be able to be achieved. Conversely, a ground set with acc(V)=80% may require major evaluation and will also include many low-performing, redundant triples.

Exemplary aspects of the present disclosure may take advantage of two empirical observations: (1) the generation of a large ground set V is relatively cheap computationally; and (2) the recourse accuracy acc(V) of the full ground set is approached far before the whole set has been evaluated. The noted advantages allows efficient shrinkage of the initial large ground sets to smaller ones with comparable recourse accuracy. For example, in 40 seconds, the Apriori threshold p=0.22 on the German Credit dataset produces a ground set with |V|=119708. While acc(V)=84% then takes 300 seconds to evaluate, 84% is converged to after only 5 seconds. See e.g.,FIG.5. The maximum value of a single triple is also seen to converge quickly. A large ground set may be generated, before only evaluating a small portion of this set to yield an equally high-performing yet denser ground set. Note that simply raising p to 0.323 and producing a smaller ground set of equal size does not yield 84% accuracy (instead, it yields 27%). See e.g., (A) All Selected Triples vs. (B) Maximum Single Selected Triple inFIG.5.

According to exemplary aspects, the GCE framework may be configured to evaluate a fixed number of triples and form a new ground set in one of two ways: (i) by adding each new triple (r), or (ii) by only adding triples that increase the recourse accuracy of the new ground set (r′) (i.e., vertical steps ofFIG.5). In an example, r=None, and r′=10000 results in 10000 evaluations and less than 10000 triples added.

According to exemplary aspects, either (i) added each new triple (r), or (ii) added triples that increase the recourse accuracy of the new ground set (r′) may be utilized to reevaluate the objective function ƒ(R) over a fixed number of triples in the ground set V. In contrast, the original AReS framework evaluates the entirety of the ground set V. According to exemplary aspects, evaluation of the entire ground set is wasteful, given that performance of the first r elements of the ground set V saturates quickly, and more so if one considers that Stage 3 ground set optimization performs submodular maximization over a space potentially hundreds of times as large, as opposed to the original AReS framework that only guarantees polynomial time. The objective function ƒ(R) is discussed in further detail below with reference to the Stage 3 ground set optimization.

According to further aspects, there is a distinction between evaluating the objective function ƒ and evaluating the recourse accuracy acc and cost terms used in evaluation. In an example, no significant extra computation is required to evaluate the acc and cost terms, since the objective function ƒ returns model predictions and costs. Although the two processes differ, they may be carried out efficiently in tandem. Such observation allow termination of evaluation once saturation has been reached, and also provides an upper bound acc(R)≤acc(V). This upper bound may be reached in Stage 3 processing far before the algorithm has completed being executed, thus allowing for early termination of the algorithm and usage of processing or CPU resources. Such early termination may allow the GCE workflow to be completed/processed more efficiently or quickly with less expenditure of computing hardware resources.

Ground Set Optimization (Stage 3)

The bottleneck in the GCE framework is, however, a submodular maximization that takes the ground set V and returns a reduced set R that satisfies the interpretability constraints. The time taken is a function of the size |V| of the ground set. Accordingly, speedups may be achieved by effectively further shrinking the ground set pre-optimization. The submodular maximization may provide optimality guarantees, such that the algorithm itself is not modified. However, with knowledge of the upper bound acc(R)≤acc(V), optimization may be terminated if this bound is approached. Such a bound can also be used to determine if Stage 3 is even initiated. According to exemplary aspects, the ground set modifications of the GCE framework may provide the algorithm with a superior starting point and the upper bound instead of modifying the algorithm itself.

According to exemplary aspects, the GCE framework may be configured to sort the (new) ground set by recourse accuracy, which is already calculated, and select the s highest-performing triples. If s=r or s=r′, then no sorting occurs.

According to further aspects, there are two exemplary modifications to the Stage 3 processing of the original AReS framework that may provide improvement of performance. More specifically, the first modification is directed to the objective function, and the second modification is directed to the submodular maximization, which are discussed in further detail below.

First Modification: Objective Function

The objective function ƒ(R) is designed to be non-normal, non-negative, non-monotone and submodular, and to have constraints that are matroids. These conditions are required for the submodular maximization in the original AReS framework to have a formal guarantee of convergence. This results in four terms in ƒ(R): incorrectrecourse, cover, featurecost, and featurechange. Bar the cover term, all of these are subtracted from (i.e., maximizing correct recourse by maximizing the negative of incorrectrecourse). Such an objective function with three adjustable hyperparameters may be very difficult to tune. For that reason, an objective that consists very simply of acc(R)−λ×cost(R), which was maximized, may be utilized in the GCE framework. According to exemplary aspects, the formal guarantees of convergence (polynomial time) are largely a misdirection of efforts in the original method. Polynomial time is not particularly helpful when the size of ground sets required for certain datasets/models is huge, and thus reducing the size of the ground set while retaining quality was focused upon before the submodular maximization is applied.

Algorithm executed via the GCE system states that for k constraints, up to k elements may be exchanged from the solution set R alongside the addition of one element from the ground set V. Further, the algorithm states that the optimization processing should be repeated k+1 times, before the best solution for R is then chosen. However, in reality, both of these induce high computational costs. Trivially, for the latter, ignoring the maximum width constraint and taking k+1=3, time taken by the original AReS framework may be mostly increased three-fold. According to exemplary aspects, both of these steps do not improve the performance of the AReS framework significantly and are thus omitted in the GCE system implementation.

FIG.6illustrates a redundancy in a ground set in accordance with an exemplary embodiment.

According to exemplary aspects, the GCE framework methodology has been evaluated on two benchmarked financial datasets: (1) the German credit data set that classifies credit risk on people described by a set of attributes, consisting mostly of categorical features, and (2) the Home Equity Line of Credit (HELOC) dataset that includes anonymized credit applications made by real homeowners, and consist solely of continuous features. Deep Neural Networks (DNNs) were trained with width 50 and depth 10 and 5 respectively on these datasets, with an 80% training split. Continuous features are binned into 10 equal intervals post-training, and recourses are constructed on the training set. Layers include dropout, bias and Rectified Linear Unit (ReLU) activation functions. The final layer to the output was mapped using softmax, and Adam was utilized to optimize a cross-entropy loss function in the standard manner. The below noted table details various model parameters/behaviors.

The above noted table provides a summary of the DNNs used in the experiments. The proportion of negative labels in the dataset were 30% and 53% for the German credit dataset and HELOC dataset, respectively. Exemplary models may roughly follow suit, with 20% and 49%, respectively.

Of note is the scalability of original AReS framework, which struggled with HELOC, a dataset that contained significantly more points to explain (|Xaff|) than the German credit dataset. Additionally, the proportion of points with positive predictions (e.g., 80% for the German credit dataset and 51% for the HELOC dataset) influences the ease with which the original AReS framework finds recourses. For stringent models (those which scarcely predict positively), it would make sense that the vast majority of frequent itemsets generated by Apriori are representative of feature value combinations that exist in the inputs with negative predictions. Accordingly, an enormous number of triples may require generation before a successful recourse may be identified.

Input dimensions of the German credit dataset were augmented by performing a one-hot encoding over necessary variables (e.g., Sex, Foreign-Worker, and the like). A cost matrix, where false positive predictions induce a higher cost than false negative predictions was ignored in the model training.

Missing values in the HELOC dataset are represented with negative integers. Inputs where all feature values are missing are dropped and replaced with the remaining missing values in the dataset with the median value of each feature. In addition, any duplicate input in the dataset may be dropped. Notably, the majority of features are monotonically increasing/decreasing.

As illustrated inFIG.6, the top row illustrates the three stages of the GCE workflow applied for the German credit dataset, and the bottom row illustrates the three stages of the GCE workflow applied to the HELOC dataset. The left column shows a graph for Stage 1 processing with respect to size of ground set V vs. time. The center column shows a graph for Stage 2 processing with respect to the ground set acc(V) vs. time. The right column shows a graph for Stage 3 processing with respect to the final set acc(R) vs. time.

In view ofFIG.6, performance of the original AReS framework and the GCE framework are analyzed cumulatively, at each of the three stages of the workflow. For various input parameter combinations (p, r, r′ and s), the final two-level recourse sets returned in Stage 3 achieve significantly higher recourse accuracy within a time frame of 300 seconds (5 minutes), achieving accuracies for which the original AReS framework required 45 minutes on the German credit dataset, and over 18 hours on the HELOC dataset.

As illustrated inFIG.6, in Stage 1, RL Reduction (b) is capable of generating an equivalent ground set V orders of magnitude faster than the original method (i.e., original (OG) AReS (a)). Further, in Stage 2, the GCE framework's Then Generation technique also constructs (different) ground sets rapidly. Stage 2 shrinking (r=5000) performs significantly better than full evaluation, and Then Generation erases many of the limitations surrounding continuous features. In Stage 3, vast speedups may be observed, owing to the generation of very small yet high-performing ground sets: r, r′ and s restrict the size of V yet retain a near-optimal acc(V).

As exemplified inFIG.6, choice of SD=RL affects performance (selecting a fixed SD may reduce the size of |Xaff| and V). The effect of performance allows for scalability of the GCE framework that was unavailable using the original AReS framework.

Training data from each dataset may be utilized to learn recourses. Since the original AReS framework struggles to achieve sufficient recourse accuracy within reasonable timeframes for various datasets and models, hyperparameters were set for featurecost and featurechange to 0. For this setting, it was found that the average cost of recourse were low and did not vary a large amount, justifying the decision to target correctness. The remaining hyperparameters used inFIG.6experiments are detailed in the below table.

FIG.7illustrates an effect of a frequent itemset mining algorithm threshold in a Then Generation method applied by a GCE system in accordance with an exemplary embodiment.

According to exemplary aspects, a range of the Apriori threshold q used in the Then Generation is bounded to a range of 1/|X|≤q≤1.FIG.7illustrates that for q≥1/|X|, the time taken by the algorithm has been reduced, but at the expense of a much larger drop in performance. Observe that the (II) line and (IV) lines (where p is held constant and q is varied) converge to the (I) line and (III) line (where q=1/|X| and p is varied), respectively. The (IV) line plots and (III) line plots also indicate that combining the two improvements, namely, (i) the RL Reduction and (ii) the Then Generation, perform suboptimally. Accordingly, these improvements were evaluated separately with a fixed q=1/|X| threshold used in the Then Generation method.

According to exemplary aspects, a modified AReS framework that speed up the generation of GCEs by orders of magnitude, also witnessing significant accuracy improvements on continuous data is provided.