Deterministic N-gram Extraction for Text Classification Interpretation
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current text classification models lack effective methods for determining the input text instances that most contribute to predictions, especially in inaccessible models, due to high computational complexity and non-deterministic approaches, which are impractical for large inputs and closed-source services.
Innovation Solution
A decoupled system that projects input and predictions into a shared embedding space for deterministic explanation generation, using n-gram vectors and similarity comparisons to identify prominent n-grams without model probing, allowing for efficient and cost-effective explanations.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Loss of information
If permutation-based methods (LIME, Shapley values) are used to extract explanations from text classification models, then interpretability is improved, but computational complexity and cost increase significantly
Solution Approach 1:
The patent extracts only the essential information needed for explanation by directly identifying prominent n-grams from the input text that contribute to the classification prediction, rather than performing comprehensive permutation-based analysis. This extraction approach obtains the necessary interpretability information while avoiding the computational overhead of evaluating all possible feature permutations.
Solution Approach 2:
The patent segments the explanation task into identifying individual prominent n-grams independently, rather than analyzing complex interactions between all features. By breaking down the explanation into discrete n-gram contributions, the computational complexity is reduced while maintaining interpretability through clear, localized feature importance identification.
2Adaptability or versatility
If permutation-based methods are used to generate explanations, then model-agnostic interpretability is achieved, but processing time and computational resources increase
Solution Approach 1:
The patent enables the explanation system to serve itself by directly analyzing the input text and prediction to identify prominent n-grams without requiring access to the internal model structure or parameters. This self-service approach achieves model-agnostic interpretability while avoiding the computationally expensive permutation-based probing of model internals.
Solution Approach 2:
The patent performs preliminary identification of prominent n-grams directly from the input text before any model probing is required. By pre-identifying candidate explanation features from the text itself, the system eliminates the need for time-consuming permutation-based analysis while maintaining model-agnostic versatility.
3Loss of information
If systematic deletion of words or phrases is performed to extract explanations, then feature importance is identified, but the approach is inapplicable to closed-source services with inaccessible models
Solution Approach 1:
The patent introduces an intermediary approach that works through the input text and prediction output without requiring access to the model's internal structure. By mediating the explanation process through text analysis rather than model probing, the system achieves feature importance identification that is compatible with closed-source services.
Solution Approach 2:
Instead of probing the model internally through systematic deletion (forward approach), the patent inverts the approach by analyzing the relationship between input text and prediction output directly. This inversion enables feature importance identification without requiring model accessibility, making it applicable to closed-source services.
Data Source
AI summary
Provided are a computer program product, system, and method for interpreting text classification predictions through deterministic extraction of prominent n-grams. A determination is made of n-gram vectors comprising word embeddings of n-grams in a document and of a document vector comprising word embeddings of the document. A label is received from the text classifier program, comprising a text classification of the document. A determination is made of a label vector comprising word embeddings of the label. The n-gram vectors, the document vector, and the label vector are used to determine n-grams that explain the text classification of the text classifier program.


