IP Library Granted Patent US 11,861,321
Granted Patent B1
US 11,861,321 · App. 18/344,344 · Granted Jan 2, 2024

Systems and methods for structure discovery and structure-based analysis in natural language processing models

Inventors: Brian O'Kelly (Denver, CO); Javed Qadrud-Din (Union City, CO); Ryan Walker (Lancaster, PA); Walter DeFoor (Rockville, MD); Pablo Arredondo (Palo Alto, CA)
Assignee: Casetext, Inc.
G06F40/40G06F16/33G06F16/338G06F16/3344G06F40/174G06F40/186G06F40/205G06F40/279G06F40/289
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,861,321
App. No.
18/344,344
Granted
Jan 2, 2024
Kind
B1
Abstract

A regular expression prompt may be determined by combining a regular expression prompt template with input text from an input document. The regular expression prompt template may include a natural language instruction to identify one or more regular expressions from the input text and one or more fillable portions designated for filling with the input text. The regular expression prompt may be sent to a large language model for evaluation, and one or more regular expressions may be identified based on a response received from the large language model. The regular expressions may be used to disaggregate the input text, and the disaggregated text portions may be used to determine a structured document based on the input document. The structured document may be used to determine a response to a query of the input document.

Claims (49)

1. A method comprising:

determining a regular expression prompt via a hardware processor by combining a regular expression prompt template with input text from an input document, the regular expression prompt template including a natural language instruction to identify one or more regular expressions from the input text, the regular expression prompt template also including one or more fillable portions designated for filling with the input text;

transmitting the regular expression prompt to a large language model for evaluation via a model interface;

identifying the one or more regular expressions based on a response received from the large language model;

determining a plurality of disaggregated text portions by applying the one or more regular expressions to subdivide the input text into the disaggregated text portions;

determining a structured document that includes the disaggregated text portions and structural information for the disaggregated text portions, the structural information characterizing a hierarchical relationship among the disaggregated text portions;

receiving a query identifying one or more characteristics for querying the structured document; and

transmitting via a communication interface a query response that includes a subset of the input text selected based on evaluating the query based at least in part on the structural information included in the structured document.

2. The method recited in claim 1 , wherein determining the structured document comprises:

determining a document structure prompt based on a document structure prompt template and the plurality of disaggregated text portions, the document structure prompt template including a document structure natural language instruction to identify the structural information, the document structure prompt template also include one or more fillable elements designated for filling with the plurality of disaggregated text portions.

3. The method recited in claim 2 , wherein determining the structured document further comprises:

transmitting the document structure prompt to a large language model for evaluation via the model interface;

receiving a document structure response from the large language model, the document structure response including a completed portion that includes the structural information; and

parsing the response to identify the structural information.

4. The method recited in claim 1 , wherein the structural information identifies a designated level in a hierarchy corresponding to a designated disaggregated text portion of the plurality of disaggregated text portions.

5. The method recited in claim 1 , wherein the structural information identifies a parent-child relationship between a first designated disaggregated text portion of the plurality of disaggregated text portions and a second designated disaggregated text portion of the plurality of disaggregated text portions.

6. The method recited in claim 1 , wherein the structural information identifies a first designated disaggregated text portion of the plurality of disaggregated text portions referenced by a second designated disaggregated text portion of the plurality of disaggregated text portions.

7. The method recited in claim 1 , wherein the structural information identifies a term defined by a definitional disaggregated text portion of the plurality of disaggregated text portions.

8. The method recited in claim 1 , wherein the query response includes a first text element from a first disaggregated text portion of the plurality of disaggregated text portions selected based on the one or more characteristics.

9. The method recited in claim 8 , wherein the query response includes a second text element from a second disaggregated text portion of the plurality of disaggregated text portions selected based on a structural relationship between the first disaggregated text portion and the second disaggregated text portion, the structural relationship being reflected in the structural information.

10. The method recited in claim 9 , wherein the structural relationship is a parent-child relationship.

11. The method recited in claim 9 , wherein the structural relationship is a sibling relationship.

12. The method recited in claim 8 , wherein the query response identifies a hierarchy level for the first text element determined based on the structural information.

13. A computing system having a hardware processor and a communication interface, the computing system being configured to perform a method comprising:

determining a regular expression prompt via the hardware processor by combining a regular expression prompt template with input text from an input document, the regular expression prompt template including a natural language instruction to identify one or more regular expressions from the input text, the regular expression prompt template also including one or more fillable portions designated for filling with the input text;

transmitting the regular expression prompt to a large language model for evaluation via a model interface interacting with the communication interface;

identifying the one or more regular expressions based on a response received from the large language model;

determining a plurality of disaggregated text portions by applying the one or more regular expressions to subdivide the input text into the disaggregated text portions;

determining a structured document that includes the disaggregated text portions and structural information for the disaggregated text portions, the structural information characterizing a hierarchical relationship among the disaggregated text portions;

receiving a query identifying one or more characteristics for querying the structured document; and

transmitting via a communication interface a query response that includes a subset of the input text selected based on evaluating the query based at least in part on the structural information included in the structured document.

14. The computing system recited in claim 13 , wherein determining the structured document comprises:

determining a document structure prompt based on a document structure prompt template and the plurality of disaggregated text portions, the document structure prompt template including a document structure natural language instruction to identify the structural information, the document structure prompt template also include one or more fillable elements designated for filling with the plurality of disaggregated text portions.

15. The computing system recited in claim 14 , wherein determining the structured document further comprises:

transmitting the document structure prompt to a large language model for evaluation via the model interface;

receiving a document structure response from the large language model, the document structure response including a completed portion that includes the structural information; and

parsing the response to identify the structural information.

16. The computing system recited in claim 13 , wherein the structural information identifies a designated level in a hierarchy corresponding to a designated disaggregated text portion of the plurality of disaggregated text portions.

17. The computing system recited in claim 13 , wherein the structural information identifies a parent-child relationship between a first designated disaggregated text portion of the plurality of disaggregated text portions and a second designated disaggregated text portion of the plurality of disaggregated text portions.

18. The computing system recited in claim 13 , wherein the structural information identifies a first designated disaggregated text portion of the plurality of disaggregated text portions referenced by a second designated disaggregated text portion of the plurality of disaggregated text portions.

19. The computing system recited in claim 13 , wherein the structural information identifies a term defined by a definitional disaggregated text portion of the plurality of disaggregated text portions.

20. One or more non-transitory computer readable media having instructions stored thereon for performing a method, the method comprising:

determining a regular expression prompt via the hardware processor by combining a regular expression prompt template with input text from an input document, the regular expression prompt template including a natural language instruction to identify one or more regular expressions from the input text, the regular expression prompt template also including one or more fillable portions designated for filling with the input text;

transmitting the regular expression prompt to a large language model for evaluation via a model interface interacting with the communication interface;

identifying the one or more regular expressions based on a response received from the large language model;

determining a plurality of disaggregated text portions by applying the one or more regular expressions to subdivide the input text into the disaggregated text portions;

determining a structured document that includes the disaggregated text portions and structural information for the disaggregated text portions, the structural information characterizing a hierarchical relationship among the disaggregated text portions;

receiving a query identifying one or more characteristics for querying the structured document; and

transmitting via a communication interface a query response that includes a subset of the input text selected based on evaluating the query based at least in part on the structural information included in the structured document.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jun 29, 2023
From: O'KELLY, BRIAN; QADRUD-DIN, JAVED; WALKER, RYAN; DEFOOR, WALTER; ARREDONDO, PABLO
To: CASETEXT, INC.
Reel/Frame 064118/0200 →
Cited By (21)
US 12,210,550 US 12,229,522 US 12,248,898 US 12,299,017 US 12,299,406 US 12,307,799 US 12,314,332 US 12,361,741 US 12,386,871 US 12,493,615 US 12,505,145 US 12,517,941 US 12,596,709 US 12,608,370 US 12,632,541 US 12,639,348 US 12,645,674 US 12,664,365 US 12,670,151 US 12,675,512 US 12,681,939