2.90:Confidence Multiplier and Output Confidence (Property): Difference between revisions

From Grooper Wiki
No edit summary
Line 34: Line 34:
</tab>
</tab>
<tab name="Waterfall Extractor" style="margin:25px">
<tab name="Waterfall Extractor" style="margin:25px">
Waterfall Extractor Final Loan – The waterfall extractor is a Data Type that is a parent or references all of the unique extractors for a piece of data and then determines which one should be given as a final output to a Data Field.
The ''Waterfall Extractor'' is a '''Data Type''' that is a parent or references all of the unique extractors for a piece of data and then determines which one should be given as a final output to a '''Data Field'''.
[[File:weighted_rules_06.png|center]]
[[File:weighted_rules_06.png|center]]
</tab>
</tab>
<tab name="Default Output" style="margin:25px">
<tab name="Default Output" style="margin:25px">
Using just the Confidence value Descending as the sort criteria, two extractors match. The FinalLoan extractor matched because it found “finalloan” with no spaces and it is not a fuzzy extractor, so it matched at 100%. The Final Loan extractor did not match, because it is not using Fuzzy matching and it did not find a space between the two words so it did not consider it a match. The Final Loan Fuzzy matched because it was able to make the word “finalloan” into “final loan” by inserting a space and so it was a 90% match.
Using '''Order By''' set to ''Confidence'' and '''Direction''' set to ''Descending'' as the sort criteria, two extractors match. The ''FinalLoan'' extractor matched because it found “finalloan” with no spaces and it is not leveraging ''FuzzyRegEx'', so it matched at 100%. The ''Final Loan'' extractor did not match, because it is not using ''FuzzyRegEx'' and it did not find a space between the two words so it did not consider it a match. The ''Fuzzy: Final Loan'', leveraging ''FuzzyRegEx'', matched because it was able to make the word “finalloan” into “final loan” by inserting a space and so it was a 90% match.
[[File:weighted_rules_07.png|center]]
[[File:weighted_rules_07.png|center]]
</tab>
</tab>
</tabs>
</tabs>

Revision as of 18:29, 27 March 2020

Introduction

Weighted rules is an informal title given to the practical application of the Confidence Multiplier property of a Data Type. Its practical application allows a user to arbitrarily set the confidence of a result of a particular Data Type in order to allow that Data Type to appear more (or less) favorable to a parent Data Type that is leveraging the Order By property configured to the Confidence setting.

Use Cases

Weighted Rules can be used in cases where one is trying to find an element of data which can appear on many similar types of forms that do not have a consistent method to identify where the data is.
For Example, on different forms, the best method to pick up a piece of data may be a Key-Value Pair, a Field Class, a simple pattern match, a pattern match leveraging FuzzyRegEx, or some other method.
One of the more recent methodologies for incorporating multiple extractors to be used by a single field has been coloquially referred to as Waterfall Extraction. This is done by organizing myriad extractors (and their numerous configurations) under a parent Data Type. The Order By property of the parent Data Type can then be set to the following: Position, Frequency, Confidence, Extractor, Length, Value.
Setting Order By to Confidence may be an interesting way to organize results, but typically, properly configured extractors always return their results at 100%. The confidence of a returned result has, historically, only been affected in one of two ways:

  1. Data Type's (or a child Data Format's) regular expression pattern leverages FuzzyRegEx and it, as a result, had to insert, delete, or swap a character to match the pattern, thus generating a result less than 100% confident
  2. Field Classes, by design leverage trained/weighted features and should not return results at 100% confidence

Considering this, a properly configured extractor can, and does, return results below 100%, and thus breaks the logical approach of organizing results by confidence. To elaborate, a result returned at 90% confidence could be more desirable than one returned at 100%.
Let's explore how and why.

Configuration

Here we'll explore a use case using a mortgage document.

In this example, an OCR error produced a misread the words “final loan” by not recognizing the space between them.


Three Data Types were established to find variations of a result.

FinalLoan Final Loan Fuzzy: Final Loan
A Data Type which uses a regular expression looking for the expression “finalloan” with no spaces. A Data Type which uses a regular expression looking for the expression “final loan” with the space. A Data Type which uses a fuzzy regular expression looking for the expression “final loan” with the space.

The Waterfall Extractor is a Data Type that is a parent or references all of the unique extractors for a piece of data and then determines which one should be given as a final output to a Data Field.

Using Order By set to Confidence and Direction set to Descending as the sort criteria, two extractors match. The FinalLoan extractor matched because it found “finalloan” with no spaces and it is not leveraging FuzzyRegEx, so it matched at 100%. The Final Loan extractor did not match, because it is not using FuzzyRegEx and it did not find a space between the two words so it did not consider it a match. The Fuzzy: Final Loan, leveraging FuzzyRegEx, matched because it was able to make the word “finalloan” into “final loan” by inserting a space and so it was a 90% match.