Automatic validation of computer-generated code method and apparatus
Abstract
Techniques for automatically generating a natural language (NL) translation of computer code are disclosed. In one embodiment, a computer-implemented method is disclosed comprising receiving, from a user, a code translation request in connection with code generated by a code generation system based on natural language (NL) input, analyzing the computer-generated code and generating a natural language (NL) translation of the computer-generated code based on the analysis, generating a graphical user interface (GUI) comprising the NL input, the NL translation of the computer-generated code and GUI control elements for receiving input from the user in connection with at least one of the NL input and the NL translation; causing the GUI to be displayed at a client device of the user, and receiving input from the user via at least one GUI control element and causing performance of at least one operation in response to the input.
Claims
exact text as granted — not AI-modified1 . A method comprising:
receiving, at a computing device, from a user, a code translation request in connection with code generated by a code generation system based on natural language (NL) input; analyzing, via the computing device, the computer-generated code and generating a natural language (NL) translation of the computer-generated code based on the analysis; generating, via the computing device, a graphical user interface (GUI) comprising the NL input, the NL translation of the computer-generated code and GUI control elements for receiving input from the user in connection with at least one of the NL input and the NL translation; causing, via the computing device, the GUI to be displayed at a client device of the user; and receiving, at the computing device, input from the user via at least one GUI control element and causing performance of at least one operation in response to the input.
2 . The method of claim 1 , wherein the NL input is received via the GUI and the at least one operation comprises requesting the code generation system to generate the computer-generated code.
3 . The method of claim 1 , wherein received user input comprises changes to the NL translation and the at least one operation comprises requesting the code generation system to generate updated computer-generated code.
4 . The method of claim 1 , wherein the GUI further comprises the computer-generated code.
5 . The method of claim 4 , wherein received user input comprises a request for the computer-generated code to be processed by a code processing system and the at least one operation comprises requesting the code processing system to process the computer-generated code.
6 . The method of claim 5 , wherein the processing request comprises a request to evaluate the computer-generated code prior to execution of the computer-generated code.
7 . The method of claim 5 , further comprising:
receiving, via the computing device, from the code processing system, results of processing the computer-generated code; and causing, via the computing device, the GUI displayed at the client device to be updated to include the processing results received from the code processing system.
8 . The method of claim 5 , further comprising:
receiving, via the computing device, from the code processing system, a warning regarding the computer-generated code; and causing, via the computing device, the GUI displayed at the client device to be updated to include the warning received from the code processing system.
9 . The method of claim 5 , further comprising:
receiving, via the computing device, input from the user via at least one GUI control element, the user input comprising a request for suggested edits to either the NL input or the NL translation; and causing, via the computing device, the GUI displayed at the client device to be updated to include at least one suggested edit in response to the request for suggested edits.
10 . The method of claim 1 , further comprising:
analyzing, via the computing device, the input received from the user; and; updating, via the computing device, a NL generation module used in analyzing subsequent computer-generated and generating a NL translation based on the analysis.
11 . The method of claim 1 , further comprising:
forwarding, via the computing device, feedback based on the input received from the user to the code generation system.
12 . The method of claim 1 , analyzing the computer-generated code further comprising:
parsing, via the computing device, the computer-generated code to identify constructs in accordance with a syntax of a programming language used in generating the computer-generated code; replacing, via the computing device, the identified constructs with NL versions of the constructs using a set of mappings.
13 . A non-transitory computer-readable storage medium tangibly encoded with computer-executable instructions that when executed by a processor associated with a computing device perform a method comprising:
receiving, from a user, a code translation request in connection with code generated by a code generation system based on natural language (NL) input; analyzing the computer-generated code and generating a natural language (NL) translation of the computer-generated code based on the analysis; generating a graphical user interface (GUI) comprising the NL input, the NL translation of the computer-generated code and GUI control elements for receiving input from the user in connection with at least one of the NL input and the NL translation; causing the GUI to be displayed at a client device of the user; and receiving input from the user via at least one GUI control element and causing performance of at least one operation in response to the input.
14 . The non-transitory computer-readable storage medium of claim 13 , wherein the NL input is received via the GUI and the at least one operation comprises requesting the code generation system to generate the computer-generated code.
15 . The non-transitory computer-readable storage medium of claim 13 , wherein received user input comprises changes to the NL translation and the at least one operation comprises requesting the code generation system to generate updated computer-generated code.
16 . The non-transitory computer-readable storage medium of claim 13 , wherein the GUI further comprises the computer-generated code and the received user input comprises a request for the computer-generated code to be processed by a code processing system and the at least one operation comprises requesting the code processing system to process the computer-generated code.
17 . The non-transitory computer-readable storage medium of claim 16 , wherein the processing request comprises a request to evaluate the computer-generated code prior to execution of the computer-generated code.
18 . The non-transitory computer-readable storage medium of claim 16 , the method further comprising:
receiving, from the code processing system, results of processing the computer-generated code; and causing the GUI displayed at the client device to be updated to include the processing results received from the code processing system.
19 . The non-transitory computer-readable storage medium of claim 13 , the method further comprising:
receiving input from the user via at least one GUI control element, the user input comprising a request for suggested edits to either the NL input or the NL translation; and causing the GUI displayed at the client device to be updated to include at least one suggested edit in response to the request for suggested edits.
20 . A computing device comprising:
a processor; and a non-transitory storage medium for tangibly storing thereon program logic for execution by the processor, the program logic comprising:
receiving logic executed by the processor for receiving, from a user, a code translation request in connection with code generated by a code generation system based on natural language (NL) input;
analyzing logic executed by the processor for analyzing the computer-generated code and generating a natural language (NL) translation of the computer-generated code based on the analysis;
generating logic executed by the processor for generating a graphical user interface (GUI) comprising the NL input, the NL translation of the computer-generated code and GUI control elements for receiving input from the user in connection with at least one of the NL input and the NL translation;
causing logic executed by the processor for causing the GUI to be displayed at a client device of the user; and
receiving logic executed by the processor for receiving input from the user via at least one GUI control element and causing performance of at least one operation in response to the input.Join the waitlist — get patent alerts
Track US2025103308A1 — get alerts on status changes and closely related new filings.
We store only your email — no account needed. See our privacy policy.