# US 2026/0099552 A1 · Computer-Implemented Methods and Systems for Generative Document Merge

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2026/0099552 A1
- Document ID: US20260099552A1
- Status: Published application
- Kind: A1
- Application number: 19/338,447
- Filed: 2025-09-24
- Published: 2026-04-09
- Earliest claimed: 2024-10-16
- Assignees: Quabbin Patent Holdings, Inc.
- Applicants: Quabbin Patent Holdings, Inc.
- Inventors: Robert Plotkin
- Web page: https://patentgrep.com/patent/US20260099552A1

## CPC

- G06F 16/93: Document management systems
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A computer-implemented method and system for recursive generative content generation processes merge templates containing multiple elements within document creation workflows. The method includes receiving a merge template comprising a plurality of elements, and for each element determining whether it is an action definition. If so, the method applies the action definition to generate output by providing a prompt to a language model, and inserts the generated output into a merged document. If not an action definition, the method determines whether the element is a merge field, obtains its value and inserts it into the merged document. Otherwise, the method copies the element into the merged document. The system enables sophisticated document personalization by combining traditional mail merge functionality with AI-driven content generation capabilities.

## Claims

### Claim 1

A method performed by at least one computer processor executing computer program instructions stored on at least one non-transitory computer-readable medium, the method comprising:
(A) receiving a merge template comprising a plurality of elements;
(B) for each element in the plurality of elements:
(B)(1) determining whether the element is an action definition;
(B)(2) if the element is determined to be an action definition:
(B)(2)(a) applying the action definition to generate output, comprising providing a prompt specified by the action definition to a language model;
(B)(2)(b) inserting the generated output into a merged document;
(B)(3) if the element is not determined to be an action definition, then determining whether the element is a merge field;
(B)(4) if the element is determined to be a merge field:
(B)(4)(a) obtaining a value for the merge field;
(B)(4)(b) inserting the obtained value into the merged document;
(B)(5) if the element is not determined to be a merge field:
(B)(5)(a) copying the element into the merged document.

### Claim 2 (depends on 1)

The method of claim 1, wherein applying the action definition to generate output comprises providing merge data to the language model along with the prompt specified by the action definition.

### Claim 3 (depends on 1)

The method of claim 1, further comprising repeating the method multiple times using different merge data to generate a plurality of merged documents.

### Claim 4 (depends on 1)

The method of claim 1, wherein the generated output from applying the action definition comprises hybrid content that includes both static text and at least one additional action definition, and further comprising applying the at least one additional action definition to generate additional output.

### Claim 5 (depends on 4)

The method of claim 4, further comprising providing structured output specifications to the language model alongside content generation requests to ensure the generated content includes both static text and dynamic elements in appropriate locations.

### Claim 6 (depends on 1)

The method of claim 1, wherein the merge template comprises a plurality of action definitions, and wherein the the method comprises:
applying a first action definition in the plurality of action definitions to generate first output; and
applying a second action definition in the plurality of action definitions to the first output to generate second output.

### Claim 7 (depends on 6)

The method of claim 6, wherein the first action definition appears at a first location in the merge template that is earlier than a second location of the second action definition, and wherein the method comprises executing the second action definition before executing the first action definition.

### Claim 8 (depends on 7)

The method of claim 7, further comprising analyzing references between the plurality of action definitions to identify dependencies, building a dependency graph of action definitions, and determining an execution sequence that satisfies all dependencies.

### Claim 9 (depends on 1)

The method of claim 1, wherein the action definition includes a tokenized prompt comprising at least one token that is replaced with a corresponding value during application of the action definition.

### Claim 10 (depends on 1)

The method of claim 1, wherein the action definition includes an alternative take prompt comprising a plurality of component prompts, and wherein applying the action definition comprises:
applying each component prompt in the plurality of component prompts to generate a corresponding plurality of output instances; and
selecting one of the plurality of output instances; and
wherein (B)(2)(b) comprises inserting the selected one of the plurality of output instance into the merged document.

### Claim 11

A system comprising at least one non-transitory computer-readable medium storing computer program instructions, wherein the computer program instructions are executable by at least one computer processor to perform a method, the method comprising:
(A) receiving a merge template comprising a plurality of elements;
(B) for each element in the plurality of elements:
(B)(1) determining whether the element is an action definition;
(B)(2) if the element is determined to be an action definition:
(B)(2)(a) applying the action definition to generate output, comprising providing a prompt specified by the action definition to a language model;
(B)(2)(b) inserting the generated output into a merged document;
(B)(3) if the element is not determined to be an action definition, then determining whether the element is a merge field;
(B)(4) if the element is determined to be a merge field:
(B)(4)(a) obtaining a value for the merge field;
(B)(4)(b) inserting the obtained value into the merged document;
(B)(5) if the element is not determined to be a merge field:
(B)(5)(a) copying the element into the merged document.

### Claim 12 (depends on 11)

The system of claim 11, wherein applying the action definition to generate output comprises providing merge data to the language model along with the prompt specified by the action definition.

### Claim 13 (depends on 11)

The system of claim 11, wherein the method further comprises repeating the method multiple times using different merge data to generate a plurality of merged documents.

### Claim 14 (depends on 11)

The system of claim 11, wherein the generated output from applying the action definition comprises hybrid content that includes both static text and at least one additional action definition, and wherein the method further comprises applying the at least one additional action definition to generate additional output.

### Claim 15 (depends on 14)

The system of claim 14, wherein the method further comprises providing structured output specifications to the language model alongside content generation requests to ensure the generated content includes both static text and dynamic elements in appropriate locations.

### Claim 16 (depends on 11)

The system of claim 11, wherein the merge template comprises a plurality of action definitions, and wherein the method comprises:
applying a first action definition in the plurality of action definitions to generate first output; and
applying a second action definition in the plurality of action definitions to the first output to generate second output.

### Claim 17 (depends on 16)

The system of claim 16, wherein the first action definition appears at a first location in the merge template that is earlier than a second location of the second action definition, and wherein the method comprises executing the second action definition before executing the first action definition.

### Claim 18 (depends on 17)

The system of claim 17, wherein the method further comprises analyzing references between the plurality of action definitions to identify dependencies, building a dependency graph of action definitions, and determining an execution sequence that satisfies all dependencies.

### Claim 19 (depends on 11)

The system of claim 11, wherein the action definition includes a tokenized prompt comprising at least one token that is replaced with a corresponding value during application of the action definition.

### Claim 20 (depends on 11)

The system of claim 11, wherein the action definition includes an alternative take prompt comprising a plurality of component prompts, and wherein applying the action definition comprises:
applying each component prompt in the plurality of component prompts to generate a corresponding plurality of output instances; and
selecting one of the plurality of output instances; and
wherein (B)(2)(b) comprises inserting the selected one of the plurality of output instances into the merged document.
