Patents
Literature
Patsnap Eureka AI that helps you search prior art, draft patents, and assess FTO risks, powered by patent and scientific literature data.

786results about "Source to source" patented technology

Code-change based prompt for code repair

A source code repair system generates a prompt including a few-shot examples of code changes made previously to correct a particular source code vulnerability. The prompt is given to a large language model to generate repair code for a source code snippet having the same vulnerability. Code changes made for a particular source code vulnerability, in the form of code diffs, are clustered into groups of closely related code change embeddings. A select few of the code diffs in each group having a closest mean of the cluster are used as the few-shot examples for the corresponding source code vulnerability.
Owner:MICROSOFT TECHNOLOGY LICENSING LLC

Large language models for creating a multi-lingual, low-resource code translation dataset

One or more unit-test cases are generated from a monolingual code corpus and the generated unit-test cases are filtered to generate a corpus of unit-test cases which have acceptability scores exceeding one or more predefined thresholds. One or more of the code samples of the monolingual code corpus are translated from a source language to a target language using a pretrained Large Language Model and the generated unit-test cases are translated from the source language to the target language. The LLM-translated code samples are validated using the translated unit-test cases and a parallel-data training corpus comprising the LLM-translated code samples that pass the validation is created. The pretrained large language model (LLM) is fine-tuned using the parallel-data training corpus, a given code segment is translated using the fine-tuned large language model (LLM), the translated given code segment is tested and the tested given code segment is deployed.
Owner:INTERNATIONAL BUSINESS MACHINE CORPORATION +1

Generating new software code from legacy software code using large language models

Computer-implemented systems and methods use a Large Language Model (LLM) for converting a legacy computer program in a first language to a human-language description of the legacy computer program, which description can be validated as being an accurate description of the legacy computer program. Once validated, the human-language description can be converted, again using an LLM, to a computer program in a target programming language. An LLM can also be used to generate test scripts for the new target-language program to test the performance of the target-language program in a production environment. An LLM can also be used to reconcile outputs from the legacy program to the new target program, such as on a function-by-function basis. If the differences between the outputs (if any) are sufficiently negligible, the legacy computer program can be decommissioned, and the new, target language program can be used in production.
Owner:MORGAN STANLEY SERVICES GROUP INC

System and method for transpilation of source code using machine learning

The disclosed system and method automate the transpilation of query source code to a distributed data processing system. The process involves instantiating transpiler libraries and source code, executing the source code, and transpiling the source code into a transpiled code using the transpiler libraries. A machine learning algorithm is utilized to control the operation of the transpilation process wherever different transpilation options are available as an automated mechanism for adapting transpilation based on tracked downstream operational characteristics. The system is configured for automatic source code generation in the target language as an output, which can then be deployed to a distributed data processing or query system. Variants are described using a combination of test and production environments for initial testing and tuning of the machine learning model architecture until a performance threshold is met. A same code segment may be transpiled periodically for continual automatic optimization.
Owner:HSBC GRP MANAGEMENT SERVICES LTD

Methods and apparatus to utilize large language artificial intelligence models to convert computer code

Systems, apparatus, articles of manufacture, and methods are disclosed to utilize large language artificial intelligence models to convert computer code. An example apparatus includes instructions and processor circuitry to execute the instructions to at least: train a large language model based on a computer instructions repository that includes code of a first type; utilize the large language model to convert an input set of instructions of the first type into output code of a second type; cause execution of the output code; determine if the execution is successful; and when the execution is not successful, utilize the output code for fine-tuning training of the large language model with incorrect data.
Owner:INTEL CORP

Method and system for legacy code transformation

This disclosure relates to method and system for facilitating legacy code transformation. The method includes receiving legacy code data and natural language document from one or more data sources. Each of the one or more data sources is one of an external data source or an internal data source. Further, the method includes generating a first natural language output based on the legacy code data through a first LLM, and a second natural language output based on the natural language document through a second LLM. Further, the method includes fine-tuning one of the first LLM or the second LLM based on the first natural language output and the second natural language output, through a third LLM. Further, the method includes generating a natural language specification document corresponding to the legacy code data based on the first natural language output and the second natural language output through the third LLM.
Owner:INFOSYS LTD

Neural network-based context-aware code translation and optimization

Systems and methods for efficiently translating program code from a source language to a target language. Input source code is parsed, using a processor device, into an Intermediate Representation (IR). A structural and semantic model of the source code are established by applying static analysis to the IR, and a program skeleton of the target code is constructed from the IR, including generating context-aware placeholders. The IR is transformed into a Single Static Assignment (SSA) form, and a System Dependency Graph (SDG) is built from the SSA form. The SDG is traversed to order translation tasks, and ordered tasks are translated into the target language using a Large Language Model (LLM). A translated program is generated by integrating translated code segments into a coherent program structure in the target language.
Owner:INTERNATIONAL BUSINESS MACHINE CORPORATION

Systems and methods for iterative feedback-driven code synthesis using syntax trees and large language models

PendingUS20250306882A1Code compilationSource to sourceCode synthesisObject code
A system for translating source code in a first programming language to a target language is provided. The system is configured to receive source code for converting to target code; determine an abstract syntax tree from the source code; determine program specifications from the source code; determine a dependency graph from the source code; determine a plurality of chunks based at least in part on the abstract syntax tree, the program specifications, and the dependency graph; determine a plurality of converted chunks based at least in part on the plurality of chunks and a deep learning model, the deep learning model converting the plurality of chunks from the language of the source code to the language of the target code; post-process the plurality of converted chunks to obtain intermediate code; and provide the intermediate code as the target code.
Owner:UST GLOBAL INC

Code conversion method and device, computer equipment and storage medium

The invention belongs to the field of artificial intelligence, and relates to a code conversion method and device, computer equipment and a storage medium, and the method comprises the steps: obtaining a source code and a target language; analyzing the source code to generate an abstract syntax tree; analyzing the abstract syntax tree, and extracting semantic information; according to the semantic information and a grammar rule of a target language, converting the code into the target language to obtain a preliminary conversion code; and further optimizing the preliminarily converted code to generate a final translated code. The automation degree is high, and the workload of manual conversion is greatly reduced; the conversion process is standard and unified, and the consistency and accuracy of code conversion are improved; by analyzing the AST, the source code can be understood more deeply, so that the translation code with higher quality is generated; extension and maintenance are easy, and support for new languages or characteristics can be added according to needs; the optimization step ensures that the converted code is not only correct, but also efficient and high in readability; and cross-language programming and code reuse are promoted.
Owner:SHENZHEN LANYOU TECHNOLOGY CO LTD

Code generation method and related equipment

The invention discloses a code generation method, which comprises the following steps that: a code development platform receives input information of a user in a first code file in a project, acquires a context in the file and a first cross-file context according to a static structure of the project, and acquires a second cross-file context according to behavior characteristics of the user in a development project, obtaining a third cross-file context according to the evolution coupling degree of at least one second code file in a code warehouse of the project and the first code file, and generating prompt information according to the input information, the context in the file, the first cross-file context, the second cross-file context and the third cross-file context, and inputting the prompt information into the code generation model for reasoning to obtain at least one group of generation codes, and displaying the at least one group of generation codes to the user. According to the method, the multi-dimensional item-level context and the user input serve as the input of the code generation model, the capability of the code generation model for utilizing the cross-file context in the code generation process is improved, and the code generation effect is improved.
Owner:HUAWEI CLOUD COMPUTING TECHNOLOGIES CO LTD

System and method for translating a first coding language into a second coding language

Systems and methods for translating a first coding language into a second coding language train a machine learning (ML) model on a first coding language specific data set relating to the first coding language, in which the ML model is trained to translate one or more code sets of the first coding language to respective one or more code sets of the second coding language; using the ML model, generate various unit test cases, in which the unit test cases run the one or more code sets of the second coding language in parallel with the one or more code sets of the first coding language; iteratively test and refine the ML model until a maturity threshold is reached; and upon reaching the maturity threshold, containerize the one or more code sets of the second coding language into one or more applications.
Owner:THE BANK OF NEW YORK MELLON

Large language model code translation error detection

Large language model code translation error detection include receiving a code portion of a first programming language, and converting the code portion to a second programming language. A first accuracy of the converting of the code portion to the second programming language is calculated. A difference between the first accuracy and an historical accuracy of a conversion from the first programming language to the second programming language is determined. A potential error in the code portion of the first programming language is indicated based on the difference between the first accuracy and the historical accuracy being greater than a predetermined value is indicated.
Owner:INTERNATIONAL BUSINESS MACHINE CORPORATION

System for assisting to transplant Android language to ArkTS (Arkaus) language of swan Mongolia

The invention relates to the technical field of computer software engineering and cross-platform development, in particular to a system for assisting in transplanting Android language to ArkTS (ArkTS) of the swan Mongolia, which comprises a code input module for acquiring Java and Kotlin double-language source codes, an analysis module for analyzing codes by using an improved grammar analysis algorithm, and a storage module for storing the codes. The translation module constructs an abstract syntax tree based on an analysis result and generates an attribute description array, and the generation module generates an ArkTS interface code according to the attribute description array; the distributed computing architecture realizes efficient task scheduling and processing, and the post-processing optimization module guarantees the code quality. Through multi-module cooperation, the probability-rule fusion algorithm, the type dynamic mapping and other technologies, code transplantation can be rapidly and accurately completed, the large project transplantation period is shortened from several weeks to several days, the manual correction cost is reduced, the code conversion accuracy and the system stability are improved, and the development of the wide-gap application ecology is powerfully promoted.
Owner:XIAMEN BEST DIGITAL TECH CO LTD

Using complexity metrics to assess code generated using artificial intelligence

Using complexity metrics to assess code generated using artificial intelligence includes generating, by an artificial intelligence (AI) language model, output source code based on input source code; identifying respective complexity scores for the input source code and the output source code using one or more complexity metrics; and generating, based on an evaluation of the respective complexity scores, a validation score for the output source code.
Owner:INTERNATIONAL BUSINESS MACHINE CORPORATION

C-to-Rust code translation large model construction method based on intermediate representation

PendingCN119166162AMachine learningCode compilationCode TranslationFunctional semantics
The invention belongs to the field of software engineering, and particularly relates to a C-to-Rust code translation large model construction method based on intermediate representation, which can be used for constructing an efficient code translation large model so as to improve the efficiency of translating a C code into a Rust code. The method is mainly divided into two stages. Firstly, a large number of Rust codes are collected through software project hosting platforms such as Githaub and the like, and the Rust codes are converted into corresponding intermediate representations used for training a large model to achieve translation from the intermediate representations to the Rust codes. Then, C codes and Rust codes with the same functional semantics are collected, and the C codes are converted into corresponding intermediate representations, so that the large model is finely adjusted, and intermediate representation differences in the translation process from the C codes to the Rust codes are aligned; the method can be used for automatically translating codes written in a C language in a software project into Rust codes with the same functional semantics.
Owner:DALIAN UNIV OF TECH

Java-to-ArkTS code conversion method and system based on large model

The invention provides a Java-to-ArkTS code conversion method and system based on a large model, and belongs to the field of computers.The Java-to-ArkTS code conversion method comprises the steps that S1, a Java project to be converted is comprehensively analyzed, the dependency relationship and semantic information between files are extracted, and a code knowledge graph is constructed; s2, determining a code conversion sequence based on the code knowledge graph, extracting context information and multi-modal semantic information of a to-be-converted code, and completing conversion from Java to TS codes in combination with a multi-agent cooperation mechanism; and S3, comparing and analyzing the TS code with an official ArkTS coding specification, identifying a violation code, and correcting and verifying the violation code through a plurality of intelligent agents to generate an ArkTS code which accords with the ArkTS grammar specification and is consistent in semantics. According to the method, the automatic migration from the Java project to the ArkTS project can be effectively supported, the project migration efficiency and the code quality are improved, and the manual intervention cost is reduced.
Owner:BEIHANG UNIV

Vehicular development and debugging system and methods of text codes and graphic codes for vehicle development

A vehicular development and debugging system includes: a computer device, a bus adapter or a burner, where the computer device includes a processor, a readable storage medium, a communication bus and a communication interface; the readable storage medium is configured to store programs of performing the conversion method of text codes and graphic codes, and the programs cause the processor to perform the operations corresponding to the conversion method of text codes and graphic codes to generate the text codes; the processor, the readable storage medium and the communication interface communicate with the bus adapter via the communication bus; the processor is configured to compile at least one fragment of execution codes in the text codes; and the bus adapter or the burner is configured to write the compiled execution codes into a debugging device.
Owner:SHANGHAI TOSUN TECH LTD

Conversion method and conversion apparatus of text codes and graphic codes for vehicle development

A conversion method and conversion system of text codes and graphic codes for vehicle development. The conversion method of text codes and graphic codes for vehicle development includes: converting the graphic codes into the text codes, and while generating target text codes, inserting configuration information of each execution unit in current graphic codes into an annotation region of the target text codes; and, when converting the target text codes back to graphic codes, extracting the configuration information of the annotation region of the target text codes and loading the configuration information to restore the graphic codes.
Owner:SHANGHAI TOSUN TECH LTD

Systems and methods for streamlining model risk documentation platform outputs using natively sourced kernels

Systems and methods for streamlining risk modeling in software development using natively sourced kernels are described. The system may receive a native kernel for the first model, wherein the native kernel comprises a native code sample and a native description of the native code sample. The system may input the native code sample into an artificial intelligence model to generate a first output. The system may filter the first output based on the native description to generate a first validation assessment for the first model. The system may generate for display, in the user interface, the first validation assessment.
Owner:CITIBANK N A

Cross-platform program translation method and device

The invention provides a cross-platform program translation method and device, and the method comprises the steps: obtaining a source program used for running on a source platform, converting a parallel built-in variable in the source program into a serial program based on a loop instruction through a large language model, and carrying out the deep learning of the hardware performance of an accelerator according to a target platform, cyclically segmenting the serial program and binding the serial program to a target platform through a built-in parallel variable of the target platform to obtain an input code; checking the storage use condition of the input code, and decorating the storage of the input code according to a preset storage level to obtain an input program; tensor operation existing in the input program is restored into scalar calculation, a tensor operation instruction of the target platform is used for expressing the scalar calculation again, a target program used for running on the target platform is obtained, the deep learning accelerator of the target platform runs the target program, and a running result is obtained.
Owner:INST OF COMPUTING TECH CHINESE ACAD OF SCI

Structural Code Refactoring Based On The User's Code Changes Using Large Language Models

A computer-implemented method includes receiving an original code snapshot corresponding to original code from a first file of a plurality of files. The method also includes receiving a modified code snapshot corresponding to modified code that includes a code modification modifying the original code. The method also includes generating, using a large language model (LLM), refactoring code based on the original code snapshot and the modified code snapshot. The refactoring code is configured to apply the code modification to code from other files of the plurality of files associated with the original code. The method also includes identifying target code from a second file of the plurality of files where the target code is associated with the original code. The method also includes applying the code modification to the identified target code using the refactoring code.
Owner:GOOGLE LLC

Code generation method and related device

PCT designated stage expiredWO2025097689A1Version controlCode refactoringCode generationUser input
Disclosed in the present application is a code generation method. The method comprises: a code development platform receiving input information from a user for a first code file in a project; acquiring in-file context and first cross-file context on the basis of a static structure of the project; acquiring second cross-file context on the basis of behavior characteristics of the user when developing the project; acquiring third cross-file context on the basis of the degree of evolution coupling between at least one second code file in a code warehouse of the project and the first code file; generating prompt information on the basis of the input information, the in-file context, the first cross-file context, the second cross-file context and the third cross-file context; inputting the prompt information into a code generation model for reasoning, so as to obtain at least one group of generated codes; and presenting to the user the at least one group of generated codes in parallel. The method takes multi-dimensional project-level context and a user input as inputs of a code generation model, thereby improving the capability of the code generation model using cross-file context during code generation, and improving the code generation performance.
Owner:HUAWEI CLOUD COMPUTING TECHNOLOGIES CO LTD

Database migration method, device and system based on MyBatis and storage medium

The invention discloses a database migration method, device and system based on MyBatis and a storage medium, and relates to the technical field of data migration. The method comprises the steps that an XML configuration file of MyBatis is obtained and analyzed, and a first SQL statement is obtained; obtaining a source database grammar rule and a target database grammar rule, and converting the first SQL statement according to the source database grammar rule to generate a second SQL statement conforming to the target database grammar rule; and performing optimization processing on the second SQL statement based on the characteristics of the target database to obtain an optimized SQL statement, and rewriting the optimized SQL statement into the XML configuration file of the MyBatis. According to the method disclosed by the embodiment of the invention, the migration workload is reduced, the migration efficiency and accuracy are improved, the error risk in the migration process is reduced, and the portability of the application program and the compatibility of the database are enhanced; and the execution efficiency of the SQL statement is improved.
Owner:ACCURAD HEALTHCARE TECH CO LTD

Code conversion method and device, storage medium and program product

The embodiment of the invention provides a code conversion method and device, a storage medium and a program product. In the code conversion method, a code acquisition operation can be responded, an initial code of a target function object written in a first programming language is acquired, and knowledge information required for converting the initial code into a target code written in a second programming language is acquired in a target knowledge base. And calling a code conversion model, and converting the initial code according to the knowledge information to obtain a target code. Wherein the knowledge information at least comprises functional attribute information and / or programming knowledge information of the target functional object, so that the code conversion model can learn or supplement specific domain knowledge required for converting an initial code written in a first programming language into a target code written in a second programming language, and the target code written in the second programming language can be converted by utilizing the specific domain knowledge. The initial code is converted into the target code meeting the requirement, so that the dependence of the code conversion operation on manpower is greatly reduced, and the cost of the code conversion operation is reduced.
Owner:TAOBAO CHINA SOFTWARE

Code conversion system and method, electronic equipment and storage medium

The invention discloses a code conversion system and method, electronic equipment and a storage medium, and belongs to the technical field of artificial intelligence, and the code conversion system comprises a project input module which is used for obtaining a code engineering project containing a project file, and the code engineering project is written by a first programming language; the data preprocessing module is used for creating a knowledge base corresponding to a code engineering project and splitting a project file into a plurality of split texts; the function analysis module is used for determining a function list of the code engineering project according to the knowledge base, the split text and the first programming language, and the function list comprises a plurality of functions achieved by the code engineering project and calling relations among the functions; and the code conversion output module is used for generating a target conversion code corresponding to the code engineering project according to the function list and the second programming language, so that reliable conversion of any project-level code of any programming language can be realized, and the code conversion effect is relatively good.
Owner:KYLAND TECH CO LTD

System and method for performing multi-platform software code merging and migration using hybrid neural networks

Embodiments of the present invention provide a system for performing multi-platform software code merging and migration using hybrid neural networks. The system is configured for identifying source files in a software code development environment, wherein each of the source files comprise software code associated with entity applications that is developed by one or more users in one or more software programming languages, translating the software code in each of the source files that is developed in the one or more software programming languages into a translated code that is in a first software programming language, merging the translated code associated with the software code in each of the source files into a unified code, wherein the unified code is in the first software programming language, automatically performing build and packaging of the unified code for deployment, and automatically deploying the packaged unified code into a software code production environment.
Owner:BANK OF AMERICA CORP

Hardware enforcement of boundaries on the control, space, time, modularity, reference, initialization, and mutability aspects of software

Modifications to existing computer hardware, compiler changes or source-to-source transforms performed during the software build process, and a collection of libraries and modifications to existing standard system software and libraries. The invention allows a program author to enforce various kinds of locality of causality in software to provide enforcement of boundaries for the following aspects of a computer program: control, space, time, modularity, reference, initialization, and mutability. Where these properties do not suffice to guarantee a property at static time, dynamic checks may be added and the constraints on control flow prevent such dynamic checks from being avoided by the program.
Owner:WHOLE SKY TECH CO

Context aware transcoding and optimization based on neural network

Systems and methods for efficiently converting program code from a source language to a target language. Input source code is parsed into an intermediate representation (IR) using a processor device. Structural and semantic models of the source code are established by applying static analysis to the IR, and a program architecture of the target code is constructed from the IR, including generating context-aware placeholders. The IR is transformed into a single static assignment (SSA) form, and a system dependency graph (SDG) is constructed from the SSA form. The SDG is traversed to sort the translation tasks, and the sorted tasks are translated into a target language using a large language model (LLM). A translated program is generated by integrating the translated code segment into a coherent program structure in the target language.
Owner:INTERNATIONAL BUSINESS MACHINE CORPORATION

Manufacturing system colored Petri net model building method and system based on PDDL language

ActiveCN119718336AProgramme controlComputer controlModelSimColored petri
The invention relates to the technical field of scheduling, and discloses a manufacturing system colored Petri net model establishment method and system based on a PDDL language, and the method comprises the following steps: updating the PDDL language, describing resources and tasks of a manufacturing system by using the updated PDDL language, and generating a manufacturing system PDDL model; and designing a conversion rule of the PDDL language and the colored Petri net, converting an object, an initial, a target, a predicate, an action and a type in the PDDL model into a place, a transition and a directed arc of the colored Petri net, and generating a colored Petri net model of the manufacturing system. According to the method, the PDDL grammar is expanded, the conversion rule for automatically converting the PDDL into the colored Petri net is designed, the PDDL model is automatically converted into the colored Petri net, and compared with manual establishment of the colored Petri net, the method has the advantages that the modeling process is simplified, and the modeling efficiency is improved.
Owner:HUAQIAO UNIVERSITY