Software technology stack renovation method, system and equipment based on artificial intelligence and storage medium

By using large-scale language models driven by artificial intelligence to revamp the software technology stack, the problems of low revamp efficiency and poor stability in existing technologies are solved, achieving efficient and low-cost full code revamp, which is suitable for large-scale complex software systems.

CN122086367APending Publication Date: 2026-05-26ISOFTSTONE INFORMATION TECHNOLOGY (GROUP) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ISOFTSTONE INFORMATION TECHNOLOGY (GROUP) CO LTD
Filing Date
2026-01-26
Publication Date
2026-05-26

AI Technical Summary

Technical Problem

Existing technology stack refurbishment methods are inefficient, have a poor return on investment, and have long implementation periods. They are also unable to meet the needs of large-scale and complex software system refurbishment, especially in the fields of finance, energy, healthcare, and government, where there are problems of poor system stability and high maintenance costs.

Method used

We employ large-scale AI-based language models (such as Deepseek and ChatGPT) for code analysis and translation. Through predefined code translation rules and quality inspection models, we achieve automated revamping of the entire codebase. Combined with module-level control rules and automatic repair mechanisms, we ensure the quality of the revamp.

Benefits of technology

It enables large-scale software technology stack refurbishment with low cost, high automation, and short cycle. The refurbished code has fewer runtime failures, higher quality, and is suitable for large-scale software systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122086367A_ABST
    Figure CN122086367A_ABST
Patent Text Reader

Abstract

The invention provides a software technology stack renovation method, system and device based on artificial intelligence and a storage medium. The method comprises the following steps: acquiring an original code based on an original technology stack; analyzing the original code to obtain a code association relationship and a plurality of original code subsets; inputting the code association relationship, the original code subset and a predefined code translation rule into a code conversion model to obtain a target code based on a target technology stack; wherein the code conversion model comprises a first pre-training large model. The software technology stack renovation method realizes low-cost, high-automation, short-period, high-quality and large-scale software technology stack renovation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of software technology, and in particular to a method, system, device and storage medium for revamping a software technology stack based on artificial intelligence. Background Technology

[0002] With the continuous development of informatization and digitalization, software systems have long become the fundamental support system for business operations and service delivery in all industries. At the same time, "software" is also entering our daily production and life in different forms. While becoming an important component of the infrastructure of the digital age, software has also accumulated a large amount of technological assets from different eras.

[0003] The essence of a software system is binary executable instructions, while its outward definition consists of different programming languages ​​and their associated compilation and execution mechanisms. This ecosystem related to programming languages, compilation, distribution, execution, and maintenance is collectively referred to as the "technology stack." The software source code / source programs within these different technology stack ecosystems are the most important knowledge assets representing the pre-construction aspects of binary software artifacts.

[0004] With the upgrading and replacement of computing infrastructure, especially the continuous obsolescence, discontinuation of updates and maintenance of outdated equipment, antique operating systems and environments, old software systems in various fields face urgent needs for upgrading, replacement and optimization to varying degrees. Simply refactoring the source code of some functions is no longer sufficient to meet these needs; a complete overhaul of the software system's technology stack is necessary.

[0005] However, the mainstream technology stack revamp methods in the industry still mainly rely on manual design changes and coding to complete the migration and transformation, which is driven by forward engineering based on the waterfall model. The main technical problems of this model are low revamp efficiency, poor return on investment, long implementation period, and the potential to introduce new design and code defects.

[0006] In recent years, while some methods for automated code optimization and refactoring based on artificial intelligence have emerged, these methods only consider local factors and can only achieve module-level and small-scale automated processing for small applications. When dealing with large-scale software systems, especially those in critical sectors such as finance, energy, healthcare, and government affairs, the high complexity, stringent quality control, and extremely high business continuity requirements make these methods unsuitable for large-scale or ultra-large-scale software overhaul operations.

[0007] Therefore, many large-scale software systems can only be patched up on the old technology stack, resulting in high operation and maintenance costs, poor system stability, weak governance, and high operational risks. Moreover, they cannot run on the new high-performance computing architecture, which greatly restricts business development. Summary of the Invention

[0008] To address the problems existing in the prior art, this application provides a software technology stack refurbishment method, system, device, and storage medium based on artificial intelligence, which achieves low-cost, highly automated, short-cycle, high-quality, and large-scale software technology stack refurbishment.

[0009] According to a first aspect of the present invention, a method for revamping a software technology stack based on artificial intelligence is provided, comprising: Obtain the original code based on the original technology stack; The original code was analyzed to obtain code relationships and multiple subsets of the original code; The code associations, the original code subset, and the predefined code translation rules are input into the code conversion model to obtain target code based on the target technology stack. The code conversion model includes a first pre-trained large model.

[0010] In an optional implementation, the original code is analyzed to obtain code relationships and multiple subsets of the original code, including: The relationships between the various program modules corresponding to the original code are analyzed using program analysis tools to obtain the code relationships; The original code is decomposed based on the code association relationship to obtain multiple original code subsets corresponding to each program module.

[0011] In an optional implementation, the predefined code translation rules include overall control rules and module-level control rules. The overall control rules include the original technology stack description, the target technology stack description, the target technology stack technical specifications, code conversion requirements, and / or target code examples. The module-level control rules include conversion requirements for a subset of the original code.

[0012] In an optional implementation, it further includes: The first pre-trained large model is selected from multiple pre-trained large models based on the original technology stack.

[0013] In an optional implementation, the method further includes: Using predefined quality inspection rules, the second pre-trained large model is invoked to perform quality inspection on the target code and generate a quality evaluation report; When the quality evaluation report indicates that the inspection has failed, the third pre-trained large model is invoked to repair the target code according to the quality evaluation report, and the repaired target code is generated. The quality inspection and repair are performed iteratively until the quality evaluation report indicates that the inspection has passed. Output the target code that passes the test as the final target code.

[0014] In an optional implementation, the method further includes: The revamped software documentation is generated based on the document generation rules, document template, and the final target code.

[0015] In an optional implementation, the first, second, and / or third pre-trained large models are large language models (LLMs).

[0016] According to a second aspect of the present invention, a software technology stack refurbishment system is provided, characterized in that it comprises: The acquisition module is used to acquire the original code based on the original technology stack; The code analysis module is used to analyze the original code to obtain code relationships and multiple subsets of the original code; The code translation module is used to input the code association, the original code subset and the predefined code translation rules into the code conversion model to obtain target code based on the target technology stack; The code conversion model includes a first pre-trained large model.

[0017] According to a third aspect of the present invention, an electronic device is provided, the electronic device comprising: At least one processor; and A memory that is communicatively connected to the at least one processor; The memory stores a computer program that can be executed by the at least one processor, which is then executed by the at least one processor to enable the at least one processor to perform the software technology stack refurbishment method described in the first aspect.

[0018] According to a fourth aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the software technology stack refurbishment method described in the first aspect.

[0019] Compared with the prior art, the advantages and beneficial effects of the present invention are as follows: By using pre-trained large models for software technology stack refurbishment, there is no need to train dedicated models based on labeled data, resulting in low implementation costs, no need for manual coding, high degree of automation, short refurbishment cycle, fewer code failures after refurbishment, and high refurbishment quality. Moreover, the refurbishment process is based on the analysis and decoupling of the entire original code, which can be applied to large-scale software system scenarios, thus achieving low-cost, highly automated, short-cycle, high-quality, and large-scale software technology stack refurbishment. Moreover, by introducing module-level control rules into the renovation rules, the personalized needs of specific program modules in the software are taken into account, which can effectively control the illusion of large models and improve the renovation quality. Furthermore, by using quality inspection models and automatic repair models to repair the target code being refurbished, the quality of the refurbishment can be further guaranteed. Attached Figure Description

[0020] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0021] Figure 1 A schematic flowchart illustrating the software technology stack refurbishment method provided in the embodiments of this application; Figure 2 A schematic architecture diagram of a software technology stack refurbishment system provided in the embodiments of this application; Figure 3 A schematic flowchart illustrating the process of implementing software technology stack refurbishment provided in the embodiments of this application; Figure 4 Illustrations of prompts provided for embodiments of this application; Figure 5 This is a schematic structural diagram of an electronic device provided in an embodiment of this application. Detailed Implementation

[0022] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0023] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising," "including," and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0024] Figure 1 The flowchart of the software technology stack refurbishment method provided in the embodiments of this application is illustrated schematically. For example... Figure 1 As shown in the figure, this application provides a software technology stack refurbishment method, including: S101. Obtain the original code based on the original technology stack; This can be achieved by extracting the original code from the source code repository of the software to be refurbished. This code was previously written or generated based on the original technology stack (i.e., the old technology stack).

[0025] S102. Analyze the original code to obtain code relationships and multiple subsets of the original code; Specifically, the relationships between the various program modules corresponding to the original code are analyzed using program analysis tools to obtain the code relationships; The original code is decomposed based on the code association relationship to obtain multiple original code subsets corresponding to each program module, so that they can be packaged and translated in subsequent processes for single program modules and multiple program modules.

[0026] This step decouples the original code of different program modules, breaking down the entire original code into appropriately granular subsets that can be processed in batches, serving as the execution units for subsequent code translation and ensuring both the quality and efficiency of the refurbishment.

[0027] S103. Input the code association, original code subset and predefined code translation rules into the code conversion model to obtain target code based on the target technology stack; The code conversion model includes a first pre-trained large model.

[0028] Optionally, the first pre-trained large model is a large language model (LLM), such as the open-source large models Deepseek, ChatGPT, and Tongyiqianwen. Optionally, the first pre-trained large model can be used directly as a code conversion model without fine-tuning.

[0029] Optionally, the predefined code translation rules include overall control rules and module-level control rules. The overall control rules include the original technology stack description, the target technology stack description, the target technology stack technical specifications, code conversion requirements, and / or target code examples. The module-level control rules include conversion requirements for subsets of the original code. The overall control rules define a unified high-level specification for the entire project, while the module-level control rules satisfy the personalized processing requirements of specific program modules. This ensures that the overall project's high-level standards are effectively implemented while meeting module-level personalized constraints, effectively controlling the illusion of a large model and improving the accuracy of the renovation.

[0030] Optionally, the description of the target technology stack includes the programming language of the target technology stack, etc., and the code conversion requirements include module splitting standards and engineering design standards (variable naming standards, log output standards, exception handling standards, session handling standards, database call standards, etc.). The module splitting standards are used to determine whether a subset of the original code is packaged into a single program module or multiple program modules during the refurbishment process of a large model. By defining module splitting standards, multiple subsets with similarities can be packaged into multiple program modules for processing, improving the efficiency of the refurbishment process.

[0031] Specifically, a code translation thought chain is designed based on the programming language type, program structure, and original technology stack characteristics of the original code, setting up a translation pipeline and associating it with a subset of the original code. The translation pipeline defines the scheduling method for the original code subset, such as single scheduling or batch scheduling. Then, code conversion is performed on the associated original code subset based on the translation pipeline. Specifically, the code associations, the original code subsets, and predefined code translation rules are packaged into a prompt context, and auxiliary prompts such as role-playing, error control, input / output requirements, and language options are embedded, which are then input into the code conversion model for code conversion.

[0032] Since different large models have different advantages and disadvantages, they will exhibit different performance when dealing with different types of technology stacks. Optionally, the first pre-trained large model is selected from multiple pre-trained large models based on the original technology stack.

[0033] The software technology stack refurbishment method provided in this application uses a pre-trained large model for software technology stack refurbishment. It does not require training a dedicated model based on labeled data, resulting in low implementation cost, no need for manual coding, high degree of automation, short refurbishment cycle, fewer code execution failures after refurbishment, and high refurbishment quality. Moreover, the refurbishment process is based on the analysis and decoupling of the entire original code, and can be applied to large-scale software system scenarios, thereby achieving low-cost, highly automated, short-cycle, high-quality, and large-scale software technology stack refurbishment.

[0034] In optional implementations, the software technology stack refurbishment method may further include: Using predefined quality inspection rules, the second pre-trained large model is invoked to perform quality inspection on the target code and generate a quality evaluation report; When the quality evaluation report indicates that the inspection has failed, the third pre-trained large model is invoked to repair the target code according to the quality evaluation report, and the repaired target code is generated. The quality inspection and repair are performed iteratively until the quality evaluation report indicates that the inspection has passed. Output the target code that passes the test as the final target code.

[0035] The quality inspection of the target code includes inputting the target code, a subset of the original code, and predefined quality inspection standards and a quality evaluation report format into a quality inspection model to obtain a quality evaluation report. Optionally, the quality inspection model can compare the input target code and the subset of the original code, determine whether the code passes or fails based on the quality inspection standards, identify any existing quality issues, and automatically generate a quality evaluation report according to the quality evaluation report format. Optionally, the predefined quality inspection standards include inspection content, inspection criteria, and quantitative evaluation rules. Optionally, the quality evaluation report includes the inspection results (pass or fail), and in the case of a failed inspection, it includes specific quality issues such as logical omissions, logical errors, or insufficient standardization.

[0036] The process of repairing the target code using an automatic repair model includes inputting a quality evaluation report, code optimization rules, and the target code into the automatic repair model. The automatic repair model then repairs the target code based on the quality issues included in the inspection report and the code optimization rules, and outputs the repaired target code.

[0037] Optionally, the second and / or third pre-trained large models are large language models (LLMs), such as open-source large models. Optionally, the second and / or third pre-trained large models can be used directly for quality checks and fixes without fine-tuning.

[0038] Optionally, the second and / or third pre-trained large models are also selected from multiple pre-trained large models.

[0039] Optionally, the first, second, and third pre-trained large models can be the same pre-trained large model or different pre-trained large models.

[0040] The embodiments of this application use a quality inspection model and an automatic repair model to inspect and repair the converted target code, which can further ensure the quality of the refurbishment; by utilizing the reading ability of a pre-trained large model, the target code and the original code are compared and analyzed, resulting in low implementation cost and short cycle.

[0041] In optional implementations, the software technology stack refurbishment method may further include: The revamped software documentation is generated based on the documentation generation rules, documentation templates, and the final target code.

[0042] Among them, the document generation rules and document templates are predefined based on the software documentation requirements of the target technology stack.

[0043] Optionally, the document generation rules, document templates, and final target code are input into the document generation model to output the revamped software documentation and store it in the document library.

[0044] Optionally, the document generation model is a fourth pre-trained large model, which, based on the source code characteristics of the target technology stack and organizational software engineering standards, designs prompt word rules that can be reverse-engineered by reading the source code to generate design documents. Preferably, a pre-trained large model fine-tuned on multimodal code-text pairs is used as the fourth pre-trained large model.

[0045] The embodiments of this application effectively solve the problems of knowledge gaps and high maintenance costs caused by the lag, inaccuracy or omission of manually written documents during the technology stack revamp process by introducing an automated document generation process, thus ensuring the long-term evolvability of the software after the technology stack revamp.

[0046] Figure 2 The architecture of the software technology stack refurbishment system 200 provided in an embodiment of this application is illustrated schematically. For example... Figure 2 As shown, this application embodiment provides a software technology stack refurbishment system 200, including: Module 201 is used to obtain the original code based on the original technology stack; Code analysis module 202 is used to analyze the original code to obtain code relationships and multiple subsets of the original code; The code translation module 203 is used to input the code association, the original code subset and the predefined code translation rules into the code conversion model to obtain target code based on the target technology stack; The code conversion model includes a first pre-trained large model.

[0047] In an optional implementation, the software technology stack refurbishment system may further include: The quality inspection module is used to use predefined quality inspection rules to call the second pre-trained large model to perform quality inspection on the target code and generate a quality evaluation report. The automatic repair module is used to call the third pre-trained large model to repair the target code according to the quality evaluation report when the quality evaluation report indicates that the inspection has failed, and generate the repaired target code. An iterative control unit is used to iteratively execute the quality inspection and the repair until the quality evaluation report indicates that the inspection has passed. The output module is used to output the target code that passes the verification as the final target code.

[0048] In an optional implementation, the software technology stack refurbishment system may further include: The document generation module is used to generate refurbished software documentation based on document generation rules, document templates, and the final target code.

[0049] In addition, to implement the above method, the system may also include: The translation pipeline configuration module is used to define the thought process of code translation in a graphical and visual way, linking the original technology stack description, the original code feature description, the target technology stack feature description, the target technology stack code sample, the target technology stack technical specifications, and the code conversion requirements, and embedding auxiliary prompts such as role-playing, error control, input and output requirements, and language options; The code translation scheduling module is used to establish a connection mechanism between individual programs in the original code and the translation pipeline, realize the grafting of translation rules of the original code, and perform translation scheduling of the original code using single scheduling and batch scheduling methods. The code quality inspection rule definition module is used to define the inspection model for logical inspection before and after the conversion based on the characteristics of the original technology stack and the target technology stack. This includes: inspection dimensions, inspection indicators, quality evaluation standards, quantitative scoring mechanism, and quality evaluation conclusion output format requirements. Code optimization rule definition module: Defines code optimization rules that are compatible with the quality evaluation report, and defines a set of prompt words to guide the large language model in code correction and logic optimization; Code documentation generation rule definition module: Based on the source code characteristics of the target technology stack and organizational software engineering standards, design prompt word rules that can be reverse-engineered by reading the source code to generate design documents.

[0050] System management module: manages the system's source code, target code, system roles, operators, system permissions, system functions, etc.

[0051] Large Model Connection and Routing Control Module: Dynamically selects different third-party Large Language Models (LLMs) as the models mentioned above and dynamically controls routing.

[0052] Those skilled in the art will understand that the software technology stack refurbishment system provided in the embodiments of the present invention can execute the software technology stack refurbishment method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the method execution. Please refer to the contents of the above-described method embodiments for details, which will not be repeated here.

[0053] The software technology stack refurbishment system provided in this application uses a pre-trained large model for software technology stack refurbishment. It does not require training a dedicated model based on labeled data, resulting in low implementation costs. It does not require manual coding, has a high degree of automation, a short refurbishment cycle, fewer code failures after refurbishment, and high refurbishment quality. Furthermore, the refurbishment process is based on the analysis and decoupling of the entire original code, and can be applied to large-scale software system scenarios. Thus, it achieves low-cost, highly automated, short-cycle, high-quality, and large-scale software technology stack refurbishment.

[0054] Figure 3 The schematic illustration shows the processing flow for implementing software technology stack refurbishment provided in the embodiments of this application.

[0055] Before performing the technology stack revamp, the following steps must be taken: Program analysis tool design: Design a code analysis program oriented towards identifying target code coupling and call relationships. By performing a full-process code scan of the original source code, explore the relationships between various program modules, define code coupling (grouping) relationships, and establish code associations. The entire code is decomposed into different subsets for subsequent code translation of single or multiple programs. Different analysis tools are corresponding to different types of source code languages.

[0056] Code translation rule definition: Define a unified high-level specification for the entire project, agree on the target technology stack programming language, code style, module splitting standards, and project design standards (variable naming standards, log output standards, exception handling standards, session handling standards, database call standards, etc.), and provide sample program code; For specific modules, some personalized special handling requirements are made when translating between the old and new architectures. Module-level control rules are defined so that, while ensuring that the high-level standards of the entire project are effectively implemented, personalized constraints at the module and program levels are met, so as to effectively control the illusion of a large model and improve the accuracy of program translation. "Code translation rules" is a complete set of logically defined rules that include defining the characteristics of the original code's technology stack, the characteristics of the target code's technology stack, target code examples, target code standards, target code translation constraints, and target code translation structure controls. It is a crucial step in guiding code translation for large-scale models and an important means of constraining the illusion of large-scale models. To accommodate large-scale software refurbishment work by large teams, a special design combining organizational-level rules with differentiated controls for local programs is adopted. The core is to separately define and combine engineering-level specifications with module-level control rules and / or sample code to achieve an organic unity between individual differences and organizational standards.

[0057] Quality inspection standard definition: Design a target code quality inspection model, including inspection content, inspection standards, and quantitative evaluation rules; Quality assessment report format definition: Define the format of the quality assessment report, including the test results of passing or failing, and when the test fails, include the specific quality problems, such as logical omissions, logical errors, insufficient standardization, etc.

[0058] Repair rule definition: Defines which corresponding modification rule to use for different quality issues.

[0059] Documentation generation rule definition: Define the rules for document generation based on the software documentation requirements of the target technology stack.

[0060] Document Template: A template that defines the document format based on the software documentation requirements of the target technology stack.

[0061] Based on the above design and definition, the software technology stack revamp process is implemented, including: Code extraction: Connect to code repositories such as Git repositories or local code repository folders to retrieve the original source code of the software to be refurbished, which is written based on the old technology stack; Code analysis: Using the designed program analysis tools, the original code is analyzed to obtain the code relationships that reflect the old software program structure. Based on the code relationships, the original code is decomposed to obtain multiple subsets of the original code corresponding to each program module. Code translation: Through the LLM gateway, a differentiated LLM model is selected based on the program attributes, engineering scenario, and execution mechanism of the software to be refurbished; the code translation rules, original code subsets, and code relationships are input into the selected LLM model in the form of prompt words, and the model packages the original code subsets for code translation to obtain the target code of the new technology stack; Figure 4 It is a prompt word indication, which includes the logical identification, logic and transformation specification definition for Struts Action.

[0062] Quality Inspection: Similarly, using prompts, the target code, source code, quality inspection standards, and quality evaluation report format are input into the LLM used for quality inspection. Utilizing the program reading capabilities of the large language model, the target code and source code are compared, and the inspection is carried out according to the quality inspection standards to generate a quality evaluation report. Automatic Repair: Input the quality assessment report and target code into the automatic repair model. If the quality inspection result is passed, the target code is output as the final target code. Otherwise, the target code is repaired according to the specific problems and repair rules fed back in the quality assessment report. The repaired target code is then input into the quality inspection module again, and the quality inspection and automatic repair steps are repeated until the quality inspection is passed. Finally, the final target code is output to the code repository and document generation model.

[0063] Document generation: The document generation model generates software documents such as software overview design and detailed design documents based on the final target code, document generation rules and document templates; The aforementioned process of revamping the technology stack can be specifically implemented as a visual process definition platform. By designing configurable and visual thought chain processes, it connects processes such as code extraction, code analysis, defining prompt input, large model invocation, and return results, thereby achieving visual operation scheduling and execution process monitoring, and supporting batch, local, and individual independent execution and scheduling.

[0064] Figure 4 This is a schematic diagram of an electronic device implementing a software technology stack refurbishment method according to an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.

[0065] like Figure 5As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded into the RAM 13 from storage unit 18. The RAM 13 can also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0066] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0067] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, digital signal processors (DSPs), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as software technology stack refurbishment methods.

[0068] In some embodiments, the software stack refurbishment method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the software stack refurbishment method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the software stack refurbishment method by any other suitable means (e.g., by means of firmware).

[0069] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0070] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0071] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0072] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0073] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or middleware components (e.g., application servers), or frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0074] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0075] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

[0076] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. An artificial intelligence based software technology stack refactoring method, characterized in that, The method comprises: obtaining original code based on an original technology stack; analyzing the original code to obtain code association relationships and a plurality of original code subsets; inputting the code association relationships, the original code subsets and predefined code translation rules into a code conversion model to obtain target code based on a target technology stack; wherein the code conversion model comprises a first pre-trained large model.

2. The software stack refresh method of claim 1, wherein, The analyzing of the original code to obtain code association relationships and a plurality of original code subsets comprises: analyzing the association relationships between respective program modules corresponding to the original code by using a program analysis tool to obtain the code association relationships; decomposing the original code according to the code association relationships to obtain a plurality of original code subsets corresponding to the respective program modules.

3. The software stack refresh method of claim 1, wherein, The predefined code translation rules comprise overall control rules and module-level control rules, the overall control rules comprising original technology stack descriptions, target technology stack descriptions, target technology stack technical specifications, code conversion requirements and / or target code samples; and the module-level control rules comprising conversion requirements for part of the original code subsets.

4. The software stack refresh method of claim 1, wherein, The method further comprises: selecting the first pre-trained large model from a plurality of pre-trained large models according to the original technology stack.

5. The software stack refresh method of claim 1, wherein, The method further comprises: calling a second pre-trained large model to perform quality inspection on the target code by using predefined quality inspection rules, and generating a quality evaluation report; when the quality evaluation report indicates that the inspection fails, calling a third pre-trained large model to repair the target code according to the quality evaluation report, and generating repaired target code; iteratively performing the quality inspection and the repair until the quality evaluation report indicates that the inspection passes; outputting the target code that passes the inspection as final target code.

6. The software stack refresh method of claim 5, wherein, The method further comprises: generating a refurbished software document according to a document generation rule, a document template and the final target code.

7. The software stack refresh method of any of claims 1 to 6, wherein, The first, second and / or third pre-trained large model is a large language model (LLM).

8. A software stack refresh system, characterized by, The method comprises: a obtaining module configured to obtain original code based on an original technology stack; a code analysis module configured to analyze the original code to obtain code association relationships and a plurality of original code subsets; a code translation module configured to input the code association relationships, the original code subsets and predefined code translation rules into a code conversion model to obtain target code based on a target technology stack; wherein the code conversion model comprises a first pre-trained large model.

9. An electronic device, comprising: The electronic device comprises: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the software technology stack refurbishment method of any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer instructions for causing a processor to execute the software technology stack refurbishment method of any one of claims 1-7 when executed by the processor.