Method and system for extracting mathematical structures in tables
AssigneeXerox Corporation
InventorHervé Déjean
Life of this patent
Estimating the term…
Abstract
Disclosed is a method and system for extracting a mathematical structure associated with a financial table. According to an exemplary embodiment, the method uses a LR-(Left-to-Right) parser reducing stack and a LR-parser nonreducing stack to generate a final reducing stack representative of the mathematical structure.
Claims22
A computer-implemented method of extracting a mathematical structure representation of a digital version of a financial table associated with a financial document using a document processing system including a memory and a processor communicatively coupled to the memory for performing the method, the method comprising:
- a) detecting a financial table included in the financial document, the financial table including a plurality of line items organized in columns and rows, each line item associated with a row and one or more columns, each row including a value label associated with a first column and a respective value associated with a second column;
- b) extracting a first value associated with the second column;
- c) shifting the extracted first value to a top location of a LR-(Left-to-Right) parser reducing stack and shifting the extracted first value to a top location of a nonreducing stack;
- d) extracting a second value associated with the second column;
- e) shifting the extracted second value to the top location of the LR-parser reducing stack directly above the first value, and shifting the extracted second value to the top location of the nonreducing stack directly above the first value;
- f) determining if the second value shifted to the top location of the LR-parser reducing stack is a sum of any sequential preceding values below in the LR-parser reducing stack or nonreducing stack and if the second value shifted to the top location of the LR-parser reducing stack is a sum of any sequential values below in the LR-parser reducing stack or nonreducing stack, eliminating the sequential preceding values below in the LR-parser reducing stack which provide the sum and retaining the second value shifted to the top location of the LR-parser reducing stack which is the sum, while retaining all sequential preceding values below in the nonreducing stack;
- g) repeating steps d)-f) for all sequential values included in the second column of the financial table to generate a final LR-parser reduced stack;
- and
- h) processing the final reducing stack to generate a mathematical structure associated with the second column.
A document processing system for generating a mathematical structure representation of a digital version of a financial table associated with a financial document, the document processing system comprising:
- a financial table detection module configured to detect a financial table included in the financial document, the financial table including a plurality of line items organized in columns and rows, each line item associated with a raw and one or more columns, each row including a value label associated with a first column and a respective value associated with a second column;
- an extraction module configured to sequentially extract a plurality of values associated with the second column;
- a nonreducing stack module configured to sequentially process a plurality of extracted values associated with the second columns to generate a nonreduced stack of the extracted values;
- a LR-(Left-to-Right) parser reducing stack module configured to sequentially process the plurality of extracted values associated with the second column to generate a reduced stack of the extracted values;
- and
- a mathematical structure generation module configured to generate a mathematical structure associated with the second column,
- wherein one or more of the financial table detection module, the extraction module, the nonreducing stack module, the LR-parser reducing sack module and the mathematical structure generation module are configured to perform:
- a) detecting a financial table included in the financial document, the financial table including a plurality of line items organized in columns and rows, each line item associated with a row and one or more columns, each row including a value label associated with a first column and a respective value associated with a second column;
- b) extracting a first value associated with the second column;
- c) shifting the extracted first value to a top location of a LR-(Left-to-Right) parser reducing stack and shifting the extracted first value to a top location of a nonreducing stack;
- d) extracting a second value associated with the second column;
- e) shifting the extracted second value to the top location of the LR-parser reducing stack directly above the first value, and shifting the extracted second value to the top location of the nonreducing stack directly above the first value;
- f) determining if the second value shifted to the top location of the LR-parser reducing stack is a sum of any sequential preceding values below in the LR-parser reducing stack or nonreducing stack and if the second value shifted to the top location of the LR-parser reducing stack is a sum of any sequential values below in the LR-parser reducing stack or nonreducing stack, eliminating the sequential preceding values below in the LR-parser reducing stack which provide the sum and retaining the second value shifted to the top location of the LR-parser reducing stack which is the sum, while retaining all sequential preceding values below in the nonreducing stack;
- g) repeating steps d)-f) for all sequential values included in the second column of the financial table to generate a final LR-parser reduced stack;
- and
- h) processing the final reducing stack to generate a mathematical structure associated with the second column.
A computer-implemented method of extracting a mathematical structure representation of a digital version of a financial table associated with a financial document using a document processing system including a memory and a processor communicatively coupled to the memory for performing the method, the method comprising:
- a) detecting a financial table included in the financial document, the financial table including a plurality of line items organized in columns and rows, each line item associated with a row and one or more columns, each row including a value label associated with a first column and a respective value associated with a second column;
- b) associating the first value with a first location of a LR-(Left-to-Right) parser reducing stack, and associating the first value with a first location of a nonreducing flat stack;
- c) associating the second value with a second location of the LR-parser reducing stack, and associating the second value with a second location of the nonreducing flat stack;
- d) determining if the second value associated with the LR-parser reducing stack is a sum of any sequential preceding values in the LR-parser reducing stack or nonreducing stack, and if the second value associated with the LR-parser reducing stack is a sum of any sequential preceding values in the LR-parser reducing stack or nonreducing stack, eliminating the sequential preceding values associated with the LR-parser reducing stack which provide the sum and retaining the second value associated with the first location of the LR-parser reducing stack which is the sum, while retaining all sequential preceding values associated with the nonreducing stack;
- e) repeating steps c) and d) for all sequential values included in the second column of the financial table to generate a final sequential series of final values associated with a final LR-parser reduced stack;
- and
- f) processing the final values associated with the final LR-parser reduced stack to generate a mathematical structure associated with the second column.
Dependencies are inferred from the claim text.