IP Library Granted Patent US 12,417,079
Granted Patent B2
US 12,417,079 · App. 18/047,683 · Granted Sep 16, 2025

Interactive editing of a machine-generated document

Inventors: Steven I. Ross (S. Hamilton, MA); Stephanie Houde (Belmont, MA); Fernando Carlos Martinez (Buenos Aires, AR)
Assignee: International Business Machines Corporation
G06F8/33
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 12,417,079
App. No.
18/047,683
Granted
Sep 16, 2025
Kind
B2
Abstract

Embodiments relate to interactive editing of a machine-generated document. A computer-implemented method includes receiving, by a processor, a machine-generated document and performing a comparison of a current state of the machine-generated document to a previous state. A user edit is identified as one or more user-replaced tokens of a previous token sequence based at least in part on the comparison. A new version of the machine-generated document is generated that includes the one or more user-replaced tokens and identifies one or more related tokens to replace with a suggested replacement token sequence associated with the one or more user-replaced tokens. A suggestion list is generated for display to the user in a graphical user interface to indicate the suggested replacement token sequence to replace the one or more related tokens.

Claims (46)

1. A computer-implemented method comprising:

receiving, by an interactive editing tool executed by a processor, a machine-generated document that is generated by a generative model, the machine-generated document including a translation of a corpus in a programming language from a first representation to a second representation;

performing, by the interactive editing tool executed by the processor, a comparison of a current state of the machine-generated document to a previous state of the machine-generated document, wherein the comparison of the current state of the machine-generated document to the previous state is during an editing session of the machine-generated document through the interactive editing tool;

identifying, by the interactive editing tool executed by the processor, a user edit made to the machine-generated document as one or more user-replaced tokens of a previous token sequence in the machine-generated document based at least in part on the comparison;

identifying, by the interactive editing tool executed by the processor, one or more related tokens appearing after the one or more user-replaced tokens in the previous token sequence, wherein the one or more related tokens are identified based on the translation including the user edit incorporated using the generative model configured with language structure rules for the translation;

generating, by the interactive editing tool executed by the processor, or triggering generation, by an application, of a new version of the machine-generated document that includes the one or more user-replaced tokens and identifies the one or more related tokens to replace with a suggested replacement token sequence associated with the one or more user-replaced tokens;

generating, by the interactive editing tool executed by the processor, a suggestion list for display to the user in a graphical user interface to indicate the suggested replacement token sequence to replace the one or more related tokens;

outputting, by the interactive editing tool executed by the processor, the suggestion list in the graphical user interface during the editing session through the interactive editing tool;

confirming, by the interactive editing tool executed by the processor, user acceptance of the suggested replacement token sequence at one or more replacement locations in the new version of the machine-generated document during the editing session;

selecting, by the interactive editing tool executed by the processor, an alternate version of the machine-generated document as the current state based at least in part on the user rejecting one or more changes from the suggestion list during the editing session, to make the alternate version of the machine-generated document a basis for subsequent comparisons; and

continuing to monitor, by the interactive editing tool executed by the processor, for further edits to the machine-generated document through the graphical user interface after confirming the user acceptance and generating further suggested updates of the machine-generated document until the editing session is complete, wherein the further suggested updates comprise an alternate suggested replacement sequence based on a user rejection of one or more of the further suggested updates during the editing session.

2. The computer-implemented method of claim 1 , wherein the new version of the machine-generated document is generated using autoregression to produce a next token based at least in part on one or more previous tokens generated up to a current location within the machine-generated document.

3. The computer-implemented method of claim 1 , further comprising performing a multiple way difference comparison to track multiple changes to the machine-generated documents to identify edits.

4. The computer-implemented method of claim 1 , wherein the new version of the machine-generated document is generated using non-causal generation to search forward and backward from the one or more user-replaced tokens to replace the one or more related tokens with the suggested replacement token sequence associated with the one or more user-replaced tokens.

5. A computer system comprising:

a memory having computer readable instructions; and

one or more processors for executing the computer readable instructions of an interactive editing tool, the computer readable instructions configured to perform operations by the interactive editing tool comprising:

receiving a machine-generated document that is generated by a generative model, the machine-generated document including a translation of a corpus in a programming language from a first representation to a second representation;

performing a comparison of a current state of the machine-generated document to a previous state of the machine-generated document, wherein the comparison of the current state of the machine-generated document to the previous state is during an editing session of the machine-generated document through the interactive editing tool;

identifying a user edit made to the machine-generated document as one or more user-replaced tokens of a previous token sequence in the machine-generated document based at least in part on the comparison;

identifying one or more related tokens appearing after the one or more user-replaced tokens in the previous token sequence, wherein the one or more related tokens are identified based on the translation including the user edit incorporated using the generative model configured with language structure rules for the translation;

generating or triggering generation, by an application, of a new version of the machine-generated document that includes the one or more user-replaced tokens and identifies the one or more related tokens to replace with a suggested replacement token sequence associated with the one or more user-replaced tokens;

generating a suggestion list for display to the user in a graphical user interface to indicate the suggested replacement token sequence to replace the one or more related tokens;

outputting the suggestion list in the graphical user interface during the editing session through the interactive editing tool;

confirming user acceptance of the suggested replacement token sequence at one or more replacement locations in the new version of the machine-generated document during the editing session;

selecting an alternate version of the machine-generated document as the current state based at least in part on the user rejecting one or more changes from the suggestion list during the editing session, to make the alternate version of the machine-generated document a basis for subsequent comparisons; and

continuing to monitor for further edits to the machine-generated document through the graphical user interface after confirming the user acceptance and generating further suggested updates of the machine-generated document until the editing session is complete, wherein the further suggested updates comprise an alternate suggested replacement sequence based on a user rejection of one or more of the further suggested updates during the editing session.

6. The system of claim 5 , wherein the new version of the machine-generated document is generated using autoregression to produce a next token based at least in part on one or more previous tokens generated up to a current location within the machine-generated document.

7. The system of claim 5 , wherein the operations further comprise:

performing a multiple way difference comparison to track multiple changes to the machine-generated document to identify edits.

8. The system of claim 5 , wherein the new version of the machine-generated document is generated using non-causal generation to search forward and backward from the one or more user-replaced tokens to replace the one or more related tokens with the suggested replacement token sequence associated with the one or more user-replaced tokens.

9. A computer program product comprising a computer readable storage medium having program instructions embodied therewith of an interactive editing tool, the program instructions executable by one or more processors and configured to perform operations by the interactive editing tool comprising:

receiving a machine-generated document that is generated by a generative model, the machine-generated document including a translation of a corpus in a programming language from a first representation to a second representation;

performing a comparison of a current state of the machine-generated document to a previous state of the machine-generated document, wherein the comparison of the current state of the machine-generated document to the previous state is during an editing session of the machine-generated document through the interactive editing tool;

identifying a user edit made to the machine-generated document as one or more user-replaced tokens of a previous token sequence in the machine-generated document based at least in part on the comparison;

identifying one or more related tokens appearing after the one or more user-replaced tokens in the previous token sequence, wherein the one or more related tokens are identified based on the translation including the user edit incorporated using the generative model configured with language structure rules for the translation;

generating or triggering generation, by an application, of a new version of the machine-generated document that includes the one or more user-replaced tokens and identifies the one or more related tokens to replace with a suggested replacement token sequence associated with the one or more user-replaced tokens;

generating a suggestion list for display to the user in a graphical user interface to indicate the suggested replacement token sequence to replace the one or more related tokens;

outputting the suggestion list in the graphical user interface during the editing session through the interactive editing tool;

confirming user acceptance of the suggested replacement token sequence at one or more replacement locations in the new version of the machine-generated document during the editing session;

selecting an alternate version of the machine-generated document as the current state based at least in part on the user rejecting one or more changes from the suggestion list during the editing session, to make the alternate version of the machine-generated document a basis for subsequent comparisons; and

continuing to monitor for further edits to the machine-generated document through the graphical user interface after confirming the user acceptance and generating further suggested updates of the machine-generated document until the editing session is complete, wherein the further suggested updates comprise an alternate suggested replacement sequence based on a user rejection of one or more of the further suggested updates during the editing session.

10. The computer program product of claim 9 , wherein the operations further comprise:

performing a multiple way difference comparison to track multiple versions of the machine-generated document with divergent region alternatives.

11. The computer program product of claim 9 , wherein the new version of the machine-generated document is generated using autoregression to produce a next token based at least in part on one or more previous tokens generated up to a current location within the machine-generated document.

12. The computer program product of claim 9 , wherein the new version of the machine-generated document is generated using non-causal generation to search forward and backward from the one or more user-replaced tokens to replace the one or more related tokens with the suggested replacement token sequence associated with the one or more user-replaced tokens.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 6, 2023
From: ROSS, STEVEN I.; HOUDE, STEPHANIE; MARTINEZ, FERNANDO CARLOS
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 062885/0326 →
Continuity (2)
Related Publication 20240134611A1 · Apr 25, 2024
Related Publication 20240231763A9 · Jul 11, 2024
References Cited (53)
US 5067166A · Ito · 1991 [cited by applicant]
US 6847979B2 · Allemang et al. · 2005 [cited by applicant]
US 7698124B2 · Menezes et al. · 2010 [cited by applicant]
US 8374979B2 · Zhou et al. · 2013 [cited by applicant]
US 9015680B1 · Shropshire · 2015 [cited by applicant]
US 9063949B2 · Zhai et al. · 2015 [cited by applicant]
US 9760542B1 · Lai et al. · 2017 [cited by applicant]
US 10713432B2 · Goyal et al. · 2020 [cited by applicant]
US 11262984B2 · Svyatkovskiy · 2022 [cited by examiner]
US 11748555B2 · Tran · 2023 [cited by examiner]
US 12014155B2 · Athiwaratkun · 2024 [cited by examiner]
US 20070130563A1 · Elgazzar et al. · 2007 [cited by applicant]
US 20130268511A1 · Bailey et al. · 2013 [cited by applicant]
US 20140136497A1 · Georgiev et al. · 2014 [cited by applicant]
US 20150051896A1 · Simard et al. · 2015 [cited by applicant]
US 20150136497A1 · Morin · 2015 [cited by applicant]
US 20150242932A1 · Beguin et al. · 2015 [cited by applicant]
US 20170161264A1 · Zhao et al. · 2017 [cited by applicant]
US 20170169346A1 · Rinkus · 2017 [cited by applicant]
US 20170192950A1 · Gaither · 2017 [cited by examiner]
US 20170220535A1 · Olsen et al. · 2017 [cited by applicant]
US 20180308583A1 · Yegnanarayanan · 2018 [cited by applicant]
US 20200086760A1 · Rini · 2020 [cited by applicant]
US 20200097261A1 · Smith · 2020 [cited by examiner]
US 20200272443A1 · Fu · 2020 [cited by examiner]
US 20210042475A1 · Zhang et al. · 2021 [cited by applicant]
US 20220157315A1 · Raux · 2022 [cited by examiner]
US 20220188646A1 · Ramesh · 2022 [cited by examiner]
US 20220222047A1 · Todirel · 2022 [cited by examiner]
US 20230068394A1 · Choudhury · 2023 [cited by examiner]
US 20230088175A1 · Ross et al. · 2023 [cited by applicant]
US 20230305690A1 · Brdiczka · 2023 [cited by examiner]
US 20230325164A1 · Singh · 2023 [cited by examiner]
US 20240004623A1 · Groenewegen · 2024 [cited by examiner]
CN 111985220A · 2020 [cited by applicant]
CN 113947072A · 2022 [cited by applicant]
Lee eat al., IntelliCAT: Intelligent Machine Translation Post-Editing with Quality Estimation and Translation Suggestion (Year: 2021). [cited by examiner]
Chakraborty, CODIT: Code Editing with Tree-Based Neural Models (Year: 2022). [cited by examiner]
Chen et al., “By the Community & for the Community: A Deep Learning Approach to Assist Collaborative Editing in Q&A Sites,” Proceedings of the ACM on Human-Computer Interaction 1.CSCW (2017): 1-21. [cited by applicant]
Chen, “Nonlinear Revision Control for Images”, ACM Transactions on Graphics, vol. 30, Issue 4, Jul. 2011, 10 pages. [cited by applicant]
Diffuse, [online]; [retrieved on Sep. 3, 2021]; retrieved from the Internethttp://diffuse.sourceforge.net/. [cited by applicant]
Falleri, “Fine-grained and Accurate Source Code Differencing”; ASE'14, Sep. 15-19, 2014; 12 pages. [cited by applicant]
Weisz, “Perfection Not Required? Human-AI Partnerships in Code Translation”, Proceedings of 26th International Conference on Intelligent User Interfaces (IUI '21). ACM, New York, NY; Apr. 8, 2021, 18 pages. [cited by applicant]
Hata et al., “Learning to generate corrective patches using neural machine translation,” Journal of Latex Class Files, vol. 14, No. 8, Aug. 2015, 20 pages. [cited by applicant]
Lachaux et al., “Unsupervised Translation of Programming Languages”, Sep. 22, 2020, 21 pages. [cited by applicant]
Li et al., “MISS: An Assistant for Multi-Style Simultaneous Translation,” Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, 2021, pp. 1-10. [cited by applicant]
Mesbah et al., “DeepDelta: Learning to Repair Compilation Errors,” Proceedings of the 2019 27th ACM Joint Meeting on European Software Engineering Conference and Symposium on the Foundations of Software Engineering (ESE… [cited by applicant]
Myers, “An O(ND) Difference Algorithm and Its Variations”; National Science Foundation; 1986; 15 pages. [cited by applicant]
Vaswani et al., “Attention Is All You Need”, 31st Conference on Neural Information Processing Systems (NIPS 2017), 15 pages. [cited by applicant]
Whitaker, “Understanding Changes in n-way Merge: Use-cases and User Interface Demonstrations”, DChanges 'Sep. 14, 16 2014, 4 pages. [cited by applicant]
Yoon, “Supporting Selective Undo in a Code Editor”, 2015 IEEE/ACM 37th IEEE International Conference on Software Engineering, May 16-24, 2015, 11 pages. [cited by applicant]
Ross, et al., “Interactive Graphical Display of Multiple Overlapping Hypotheses or Document Versions”, U.S. Appl. No. 17/482,536, filed Sep. 23, 2021. [cited by applicant]
IBM: List of IBM Patents or Patent Applications Treated as Related (Appendix P); Date Filed: Oct. 19, 2022; 2 pages. [cited by applicant]
Cited By (1)
US 12,602,952