Data conversion method, device, computer equipment and medium based on artificial intelligence
Through the artificial intelligence-based data conversion method, JSP pages are automatically converted into Vue pages, which solves the problems of low efficiency and high cost of manual conversion and realizes efficient and high-quality code conversion.
Patent Information
- Application Number
- CN202411487360.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-23
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2044-10-23
AI Technical Summary
The existing manual conversion method of converting JSP pages to Vue pages is inefficient, costly, and difficult to guarantee conversion quality.
Adopting an artificial intelligence-based data conversion method, it judges user requests, extracts JSP page code, uses a pre-trained conversion model to perform format conversion and optimization, and generates and sends optimized Vue page code.
It realizes the automatic conversion of JSP pages to Vue pages, improves processing efficiency, saves labor costs, and improves the quality of generated code.
Smart Images

Figure CN119514496B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the fields of artificial intelligence development technology and financial technology, and in particular to artificial intelligence-based data conversion methods, devices, computer equipment, and storage media. Background Art
[0002] In the financial industry's informatization process, the stable operation and continuous optimization of business systems are key factors driving the industry's development. In recent years, with the rapid development of information technology and the increasing demand for independent control, the localization of full-stack trusted innovation has become a key trend in the financial industry's informatization efforts. This trend requires financial institutions to not only achieve technological independence and control over their core business systems, but also continuously improve their performance, flexibility, and scalability.
[0003] Many financial institutions are currently facing an urgent need to migrate their legacy core systems to a new architecture. These systems are often built on traditional technology stacks, such as Oracle databases and JSP pages. However, with the continuous advancement of technology, these legacy systems are no longer able to meet the needs of current business development. Therefore, financial institutions need to migrate these legacy systems to a more advanced and flexible new architecture to support rapid business growth and changes.
[0004] During the migration of legacy systems to the new architecture, converting JSP page technology became a pressing issue. As a back-end rendering technology, JSP page technology was widely used in early web development. However, with the continuous advancement of front-end technology, modern front-end frameworks such as Vue have gradually become the mainstream choice for front-end development due to their advantages such as componentization, responsive data binding, and ease of use.
[0005] However, converting a large number of JSP pages to Vue pages is not an easy task. Currently, manual conversion is still the most common method. While manual conversion can ensure flexibility, it is inefficient, costly, and difficult to guarantee conversion quality. Summary of the Invention
[0006] The purpose of the embodiments of the present application is to propose an artificial intelligence-based data conversion method, device, computer equipment and storage medium to solve the technical problems of low processing efficiency, high cost and difficulty in ensuring conversion quality in the existing manual conversion method used to convert JSP pages into Vue pages.
[0007] In order to solve the above technical problems, the present application provides an artificial intelligence-based data conversion method, which adopts the following technical solutions:
[0008] Determine whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted;
[0009] If so, extracting the JSP page code from the data conversion request;
[0010] Performing format conversion processing on the JSP page code to obtain corresponding target code data;
[0011] The target code data is converted based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data;
[0012] Optimize the Vue page code to obtain the corresponding target Vue page code;
[0013] The target Vue page code is sent to the user.
[0014] Furthermore, the step of optimizing the Vue page code to obtain the corresponding target Vue page code specifically includes:
[0015] Performing code structure optimization processing on the Vue page code to obtain corresponding first code data;
[0016] performing component sequence adjustment processing on the first code data to obtain corresponding second code data;
[0017] Performing tuning processing on the second code data based on a preset tuning strategy to obtain corresponding third code data;
[0018] The third code data is used as the target Vue page code.
[0019] Furthermore, the step of sending the target Vue page code to the user specifically includes:
[0020] Review the target Vue page code based on a preset review strategy;
[0021] If the target Vue page code passes the review, the target Vue page code is tested based on a preset test strategy;
[0022] If the target Vue page code passes the test, the preset target sending method is obtained;
[0023] Based on the target sending method, the target Vue page code is sent to the user.
[0024] Furthermore, the step of reviewing the target Vue page code based on a preset review strategy specifically includes:
[0025] Get preset code review rules and readability review rules;
[0026] Perform code review on the target Vue page code based on the code review rules;
[0027] If the target Vue page code passes the code review, then the target Vue page code is subjected to a readability review based on the readability review rules;
[0028] If the target Vue page code passes the readability review, it is determined that the target Vue page code passes the review; otherwise, it is determined that the target Vue page code fails the review.
[0029] Furthermore, the step of testing the target Vue page code based on a preset test strategy specifically includes:
[0030] Obtain preset functional testing rules, compatibility testing rules, and performance testing rules;
[0031] Perform functional testing on the target Vue page code based on the functional testing rules;
[0032] If the target Vue page code passes the functional test, a compatibility test is performed on the target Vue page code based on the compatibility test rules;
[0033] If the target Vue page code passes the compatibility test, then the target Vue page code is subjected to a performance test based on the performance test rules;
[0034] If the target Vue page code passes the performance test, it is determined that the target Vue page code passes the test; otherwise, it is determined that the target Vue page code fails the test.
[0035] Furthermore, before the step of converting the target code data based on the pre-trained conversion model to generate the Vue page code corresponding to the target code data, the method further includes:
[0036] Acquire pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data;
[0037] Parsing the initial JSP page code data and the initial Vue page code data to obtain corresponding JSP page information and Vue page information;
[0038] Perform feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data;
[0039] Call the preset initial model and obtain the preset optimization strategy;
[0040] Based on the optimization strategy, the initial model is trained using the sample data to obtain a specified model that meets the preset model construction requirements;
[0041] The specified model is used as the conversion model.
[0042] Furthermore, the step of performing feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data specifically includes:
[0043] Preprocess the JSP page information and the Vue page information respectively to obtain corresponding specified JSP page information and specified Vue page information;
[0044] Get the preset feature type information;
[0045] Perform feature selection processing on the specified JSP page information and the specified Vue page information based on the feature type information to obtain corresponding specified features;
[0046] Constructing a corresponding feature vector based on the specified feature;
[0047] The sample data is generated based on the feature vector.
[0048] In order to solve the above technical problems, the embodiment of the present application further provides a data conversion device based on artificial intelligence, which adopts the following technical solution:
[0049] A judgment module, configured to judge whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted;
[0050] An extraction module, configured to extract the JSP page code from the data conversion request if yes;
[0051] The first processing module is used to perform format conversion processing on the JSP page code to obtain corresponding target code data;
[0052] A conversion module is used to convert the target code data based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data;
[0053] An optimization module is used to optimize the Vue page code to obtain the corresponding target Vue page code;
[0054] A sending module is used to send the target Vue page code to the user.
[0055] In order to solve the above technical problems, the embodiment of the present application further provides a computer device, which adopts the following technical solution:
[0056] Determine whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted;
[0057] If so, extracting the JSP page code from the data conversion request;
[0058] Performing format conversion processing on the JSP page code to obtain corresponding target code data;
[0059] The target code data is converted based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data;
[0060] Optimize the Vue page code to obtain the corresponding target Vue page code;
[0061] The target Vue page code is sent to the user.
[0062] In order to solve the above technical problems, the embodiment of the present application further provides a computer-readable storage medium, which adopts the following technical solution:
[0063] Determine whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted;
[0064] If so, extracting the JSP page code from the data conversion request;
[0065] Performing format conversion processing on the JSP page code to obtain corresponding target code data;
[0066] The target code data is converted based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data;
[0067] Optimize the Vue page code to obtain the corresponding target Vue page code;
[0068] The target Vue page code is sent to the user.
[0069] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0070] The present application determines whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted; if so, the JSP page code is extracted from the data conversion request; then the JSP page code is formatted and processed to obtain corresponding target code data; then the target code data is converted and processed based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data; subsequently, the Vue page code is optimized and processed to obtain the corresponding target Vue page code; finally, the target Vue page code is sent to the user. The present application extracts the JSP page code from the data conversion request triggered by the user in the preset interface, and formats the JSP page code to obtain the target code data, and then converts the target code data based on the use of the conversion model, which can quickly and intelligently realize the automatic conversion of JSP page to Vue page, effectively improving the processing efficiency of the page conversion of the JSP page code and saving a lot of manpower costs. In addition, the Vue page code will be further optimized, so as to effectively improve the quality of the generated target Vue page code. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] In order to more clearly illustrate the solutions in this application, a brief introduction will be given below to the drawings required for use in the description of the embodiments of this application. Obviously, the drawings described below are some embodiments of this application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0072] Figure 1 is an exemplary system architecture diagram to which the present application may be applied;
[0073] Figure 2 A flowchart of an embodiment of the artificial intelligence-based data conversion method according to the present application;
[0074] Figure 3 1 is a schematic structural diagram of an embodiment of an artificial intelligence-based data conversion device according to the present application;
[0075] Figure 4 It is a structural diagram of an embodiment of a computer device according to the present application. DETAILED DESCRIPTION
[0076] Unless otherwise defined, all technical and scientific terms used herein have the same meanings as commonly understood by those skilled in the art to which this application belongs. The terms used in the specification of the application are for the purpose of describing specific embodiments only and are not intended to limit this application. The terms "including" and "having" and any variations thereof in the specification and claims of this application and the above-mentioned drawings are intended to cover non-exclusive inclusions. The terms "first", "second", etc. in the specification and claims of this application or the above-mentioned drawings are used to distinguish different objects, not to describe a specific order.
[0077] References herein to "embodiments" mean that a particular feature, structure, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present application. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute an independent or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0078] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings.
[0079] like Figure 1 As shown, system architecture 100 may include a terminal device 101, a network 102, and a server 103. Terminal device 101 may be a laptop computer 1011, a tablet computer 1012, or a mobile phone 1013. Network 102 is a medium for providing a communication link between terminal device 101 and server 103. Network 102 may include various connection types, such as wired or wireless communication links or fiber optic cables.
[0080] The user can use the terminal device 101 to interact with the server 103 via the network 102 to receive or send messages, etc. Various communication client applications can be installed on the terminal device 101, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0081] The terminal device 101 can be various electronic devices with a display screen and supporting web browsing. In addition to the laptop computer 1011, tablet computer 1012 or mobile phone 1013, the terminal device 101 can also be an e-book reader, an MP3 player (Moving Picture Experts Group Audio Layer III), an MP4 (Moving Picture Experts Group Audio Layer IV) player, a laptop computer and a desktop computer, etc.
[0082] The server 103 may be a server that provides various services, such as a background server that provides support for web pages displayed on the terminal device 101 .
[0083] It should be noted that the artificial intelligence-based data conversion method provided in the embodiment of the present application is generally executed by a server / terminal device, and accordingly, the artificial intelligence-based data conversion device is generally set in the server / terminal device.
[0084] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is merely illustrative. Any number of terminal devices, networks and servers may be provided as required.
[0085] Continue to refer Figure 2 , shows a flowchart of an embodiment of the data conversion method based on artificial intelligence according to the present application. According to different needs, the order of the steps in the flowchart can be changed, and some steps can be omitted. The data conversion method based on artificial intelligence provided by the embodiment of the present application can be applied to any scenario that requires data conversion, and the data conversion method based on artificial intelligence can be applied to products in these scenarios, for example, page conversion in the financial insurance field. The data conversion method based on artificial intelligence includes the following steps:
[0086] Step S201 , determining whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted.
[0087] In this embodiment, the data conversion method based on artificial intelligence is run on the electronic device (eg Figure 1The server / terminal device shown in the figure) can obtain the data conversion request through a wired connection or a wireless connection. It should be noted that the above-mentioned wireless connection method may include but is not limited to 3G / 4G / 5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wideband) connection, and other wireless connection methods currently known or to be developed in the future. The execution subject of this application may be a business system with a page conversion function, or simply referred to as a system. The above-mentioned preset interface may be a system interface, such as a web form, a desktop application, etc. The above-mentioned user data conversion request may be a request triggered by the user in the preset interface to convert the input JSP page code to be converted into a processing request for the corresponding Vue page code. In the business scenario of finance and insurance, the above-mentioned business system may be an insurance system, a banking system, a payment system, and the like.
[0088] Step S202: If yes, extract the JSP page code from the data conversion request.
[0089] In this embodiment, the data conversion request may be parsed to extract the JSP page code from the data conversion request.
[0090] Step S203: performing format conversion processing on the JSP page code to obtain corresponding target code data.
[0091] In this embodiment, the format conversion process may refer to encoding of the conversion model, i.e., encoding the JSP page code using the conversion model to convert it into an internal representation, thereby obtaining corresponding target code data. The internal representation may be vector-based, such as word embedding.
[0092] Step S204: converting the target code data based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data.
[0093] In this embodiment, the target code data in the internal representation can be decoded using a pre-trained conversion model to generate the corresponding Vue page code. The decoding process involves a series of complex operations, such as syntax generation, semantic understanding, contextual reasoning, etc. During the decoding process, the conversion model uses the knowledge learned in the training phase to convert the structure, data binding, event processing and other features of the JSP page into the corresponding features of the Vue page. The specific construction process of the above-mentioned conversion model will be further described in detail in the subsequent specific embodiments of this application, and will not be elaborated on here.
[0094] Step S205: Optimize the Vue page code to obtain the corresponding target Vue page code.
[0095] In this embodiment, the above-mentioned optimization processing of the Vue page code to obtain the specific implementation process of the corresponding target Vue page code will be further described in detail in subsequent specific embodiments of this application, and will not be elaborated on here.
[0096] Step S206: Send the target Vue page code to the user.
[0097] In this embodiment, the specific implementation process of sending the target Vue page code to the user will be further described in detail in subsequent specific embodiments of the present application, and will not be elaborated on here.
[0098] The present application determines whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted; if so, the JSP page code is extracted from the data conversion request; then the JSP page code is formatted and processed to obtain corresponding target code data; then the target code data is converted and processed based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data; subsequently, the Vue page code is optimized and processed to obtain the corresponding target Vue page code; finally, the target Vue page code is sent to the user. The present application extracts the JSP page code from the data conversion request triggered by the user in the preset interface, and formats the JSP page code to obtain the target code data, and then converts the target code data based on the use of the conversion model, which can quickly and intelligently realize the automatic conversion of JSP page to Vue page, effectively improving the processing efficiency of the page conversion of the JSP page code and saving a lot of manpower costs. In addition, the Vue page code will be further optimized, so as to effectively improve the quality of the generated target Vue page code.
[0099] In some optional implementations, step S205 includes the following steps:
[0100] The Vue page code is subjected to code structure optimization processing to obtain corresponding first code data.
[0101] In this embodiment, the above code structure optimization process may include: structural optimization of the generated Vue page code, such as merging repeated styles, removing unnecessary JavaScript code, adjusting the nesting relationship of HTML tags, etc.
[0102] Component sequence adjustment processing is performed on the first code data to obtain corresponding second code data.
[0103] In this embodiment, the component sequence adjustment process may include: sorting and grouping the generated components according to the component development principle of Vue to ensure the clarity and maintainability of the code.
[0104] The second code data is tuned based on a preset tuning strategy to obtain corresponding third code data.
[0105] In this embodiment, the policy content of the above-mentioned tuning policy may include performing code tuning processing by adding comments, formatting code, using consistent naming conventions, and other methods.
[0106] The third code data is used as the target Vue page code.
[0107] This application performs code structure optimization processing on the Vue page code to obtain corresponding first code data; then performs component order adjustment processing on the first code data to obtain corresponding second code data; then performs tuning processing on the second code data based on a preset tuning strategy to obtain corresponding third code data; and subsequently uses the third code data as the target Vue page code. This application performs code structure optimization processing, component order adjustment processing, and tuning processing on the Vue page code, thereby achieving rapid and accurate optimization processing of the Vue page code, effectively improving the code quality and readability of the generated target Vue page code.
[0108] In some optional implementations of this embodiment, step S205 includes the following steps:
[0109] The target Vue page code is reviewed based on a preset review strategy.
[0110] In this embodiment, the specific implementation process of reviewing the target Vue page code based on the preset review strategy will be further described in detail in subsequent specific embodiments of this application, and will not be elaborated on here.
[0111] If the target Vue page code passes the review, the target Vue page code is tested based on a preset test strategy.
[0112] In this embodiment, the specific implementation process of testing the target Vue page code based on the preset test strategy will be further described in detail in subsequent specific embodiments of the present application, and will not be elaborated on here.
[0113] If the target Vue page code passes the test, the preset target sending method is obtained.
[0114] In this embodiment, there is no specific limitation on the selection of the above-mentioned target sending method, which can be determined according to actual business needs. For example, the sending methods such as interface display, SMS sending, and email sending can be used.
[0115] Based on the target sending method, the target Vue page code is sent to the user.
[0116] In this embodiment, the above-mentioned target sending method can be used to send the target Vue page code to the user.
[0117] This application reviews and processes the target Vue page code based on a preset review strategy; if the target Vue page code passes the review, the target Vue page code is tested based on a preset test strategy; if the target Vue page code passes the test, a preset target sending method is obtained; and subsequently, based on the target sending method, the target Vue page code is sent to the user. Before sending the target Vue page code to the user, this application will automatically and intelligently review and process the target Vue page code based on the use of the review strategy, and test and process the target Vue page code based on the use of the test strategy, effectively ensuring that the generated target Vue page code meets the expected quality and readability requirements. And subsequently, after detecting that the target Vue page code has passed both the review and the test, the target Vue page code will be sent to the user, which improves the accuracy of sending the target Vue page code, thereby helping to improve user satisfaction and thus improve the success rate of the project.
[0118] In some optional implementations, the review process of the target Vue page code based on a preset review strategy includes the following steps:
[0119] Get preset code review rules and readability review rules.
[0120] In this embodiment, the procedural content of the above-mentioned code review rules may include: conducting structural review, style review, logic review and security review. Among them, the structural review may include: checking whether the division of Vue components is reasonable and whether the dependencies between components are clear. The style review may include: ensuring that the CSS style complies with the project's coding specifications and there are no redundant or conflicting styles. The logic review may include: verifying whether the JavaScript logic correctly implements the functions of the JSP page, including data binding, event handling, and routing navigation. The security review may include: checking whether the code has common security vulnerabilities, such as XSS, CSRF, etc.
[0121] The readability review rules mentioned above may include: conducting naming convention reviews, comment reviews, and format reviews. The naming convention review may include ensuring that variables, functions, components, and other names are clear and easy to understand. The comment review may include checking whether the code contains sufficient comments to explain complex logic or algorithms. The format review may include ensuring that the code format is consistent and complies with the project's coding standards.
[0122] Perform code review on the target Vue page code based on the code review rules.
[0123] In this embodiment, the target Vue page code can be code reviewed according to the rule content of the above-mentioned code review rules, thereby obtaining a corresponding code review result. Among them, the code review result may include that the target Vue page code passes the code review, or that the target Vue page code fails the code review.
[0124] If the target Vue page code passes the code review, a readability review is performed on the target Vue page code based on the readability review rules.
[0125] In this embodiment, the readability review of the target Vue page code can be performed according to the content of the readability review rules, thereby obtaining a corresponding readability review result. The readability review result may include: the target Vue page code passes the readability review, or the target Vue page code fails the readability review.
[0126] If the target Vue page code passes the readability review, it is determined that the target Vue page code passes the review; otherwise, it is determined that the target Vue page code fails the review.
[0127] This application obtains preset code review rules and readability review rules; then performs code review on the target Vue page code based on the code review rules; if the target Vue page code passes the code review, then performs readability review on the target Vue page code based on the readability review rules; if the target Vue page code passes the readability review, then the target Vue page code is determined to have passed the review, otherwise it is determined that the target Vue page code has not passed the review. This application performs code review on the target Vue page code based on the use of code review rules, and performs readability review on the target Vue page code based on the use of readability review rules, thereby quickly and accurately completing the review process for the target Vue page code, thereby improving the processing efficiency and accuracy of the review process. And only when it is detected that the target Vue page code has passed both the code review and the readability review, will the target Vue page code be determined to have passed the review, effectively ensuring the accuracy of the review result of the generated target Vue page code.
[0128] In some optional implementations, the testing process on the target Vue page code based on a preset testing strategy includes the following steps:
[0129] Get preset functional testing rules, compatibility testing rules, and performance testing rules.
[0130] In this embodiment, the rule content of the above-mentioned functional testing rules may include: using automated testing tools to write test cases and perform automated testing on Vue pages. The rule content of the above-mentioned compatibility testing rules may include: testing browser compatibility and testing device compatibility. Among them, testing browser compatibility includes: testing Vue pages on different browsers to ensure that they can work properly in different environments. Testing device compatibility includes: testing Vue pages on different devices (such as mobile phones, tablets, desktop computers, etc.) to ensure that they can be displayed well under different screen sizes and resolutions. The above-mentioned performance testing rules may include: testing loading speed and testing resource consumption. Among them, testing loading speed may include: testing the loading speed of Vue pages to ensure that they are loaded within a reasonable time. Testing resource consumption may include: monitoring the consumption of CPU, memory and other resources by Vue pages during runtime to ensure that they do not consume excessive resources and cause the device to freeze or crash.
[0131] Perform functional testing on the target Vue page code based on the functional testing rules.
[0132] In this embodiment, the target Vue page code can be functionally tested according to the rule content of the above-mentioned functional test rule to obtain a corresponding functional test result. Among them, the content of the functional test result may include that the target Vue page code passes the functional test, or that the target Vue page code fails the functional test.
[0133] If the target Vue page code passes the functional test, a compatibility test is performed on the target Vue page code based on the compatibility test rules.
[0134] In this embodiment, the target Vue page code may be subjected to a compatibility test according to the content of the compatibility test rules, thereby obtaining a corresponding compatibility test result. The content of the functional test result may include whether the target Vue page code passes the compatibility test or whether the target Vue page code fails the compatibility test.
[0135] If the target Vue page code passes the compatibility test, a performance test is performed on the target Vue page code based on the performance test rules.
[0136] In this embodiment, the target Vue page code can be performance tested according to the rule content of the above-mentioned performance test rules to obtain corresponding performance test results. Among them, the content of the functional test result may include that the target Vue page code passes the performance test, or that the target Vue page code fails the performance test.
[0137] If the target Vue page code passes the performance test, it is determined that the target Vue page code passes the test; otherwise, it is determined that the target Vue page code fails the test.
[0138] The present application obtains preset functional test rules, compatibility test rules and performance test rules; then performs functional testing on the target Vue page code based on the functional test rules; if the target Vue page code passes the functional test, the target Vue page code is subjected to compatibility testing based on the compatibility test rules; if the target Vue page code passes the compatibility test, the target Vue page code is subjected to performance testing based on the performance test rules; if the target Vue page code passes the performance test, the target Vue page code is determined to have passed the test, otherwise the target Vue page code is determined to have failed the test. The present application performs functional testing on the target Vue page code based on the use of functional test rules, performs compatibility testing on the target Vue page code based on the use of compatibility test rules, and performs performance testing on the target Vue page code based on the use of performance test rules, thereby achieving rapid and accurate completion of the test processing for the target Vue page code, thereby improving the processing efficiency and accuracy of the test processing. And only when it is detected that the target Vue page code has passed the functional test, compatibility test and performance test, will the target Vue page code be determined to have passed the test, effectively ensuring the accuracy of the test results of the generated target Vue page code.
[0139] In some optional implementations of this embodiment, before step S204, the electronic device may further perform the following steps:
[0140] Acquire pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data.
[0141] In this embodiment, a reliable data source of JSP page code and Vue page code can be determined, which can be an internal enterprise project library, an open source project, a code hosting platform, etc. Then, representative JSP and Vue page code pairs (i.e., initial JSP page code data, and initial Vue page code data corresponding to the initial JSP page code data) are screened from the reliable data source to ensure that they can cover common page structures and functions.
[0142] The initial JSP page code data and the initial Vue page code data are parsed to obtain corresponding JSP page information and Vue page information.
[0143] In this embodiment, JSP page code can be parsed using a suitable parsing tool to extract information such as page structure, data binding, and event handling, and then JSP element identification can be performed to obtain elements including HTML / CSS / JavaScript, JSP instructions, JSP script elements, JSP action elements, EL expressions, custom tags, etc., and then integrated to obtain corresponding JSP page information. Furthermore, Vue page code can be parsed using a suitable parsing tool to extract information such as component definition, data binding, and routing configuration, and then integrated to obtain corresponding Vue page information.
[0144] Perform feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data.
[0145] In this embodiment, the above-mentioned feature vectorization processing of the JSP page information and the Vue page information to obtain the corresponding sample data is described in further detail in subsequent specific embodiments of this application and will not be elaborated on here.
[0146] Call the preset initial model and obtain the preset optimization strategy.
[0147] In this embodiment, the initial model can be constructed using a machine learning or deep learning algorithm, preferably a random forest algorithm. Random forest is an ensemble learning algorithm based on decision trees that combines multiple decision trees to improve the accuracy and stability of the model. It can be used to build a model for automatically converting JSP to Vue, improving prediction accuracy by analyzing multiple factors. The following is the formula for the random forest algorithm:
[0148] 1. Build a decision tree. F = {f1, f2, ..., fN}, where f1, f2, ..., fN are each decision tree in the decision tree. Each decision tree is built and features extracted based on other decision trees.
[0149] 2. Calculate the mean and standard error. E = (1 / N) * sum(F^2), where E represents the mean and standard error of the decision tree, 1 / N represents the number of calculations for each decision tree, and sum represents the summation operation.
[0150] 3. Random split. X_k = X*f_k / N, where X_k represents the input vector of the kth feature, f_k is the output vector of the kth decision tree, and N is the number of features.
[0151] 4. Calculate the model evaluation metric. mse = sqrt(E / N), where mse represents the mean absolute error of the model. E / N represents the number of calculations per feature divided by the number of features.
[0152] 5. Model training. M = (X_1, X_2, ..., X_N) * (X_1^T * X_2^T, X_1*X_2^T, ..., X_N*X_1^T), where M represents the model's input vector. The random forest algorithm trains the model using random splits and uses the model to make predictions on the training set.
[0153] 6. Model evaluation: Y_pred = prediction(M), where prediction means using the model to make predictions on the test set.
[0154] In addition, the aforementioned optimization strategies may include adjusting model parameters through backpropagation, employing regularization and dropout techniques to prevent overfitting, and using the Adam optimization algorithm to optimize the training process and improve convergence speed and accuracy.
[0155] Based on the optimization strategy, the initial model is trained using the sample data to obtain a specified model that meets the preset model construction requirements.
[0156] In this embodiment, the initial model can be trained using sample data, and the model parameters can be adjusted using the backpropagation algorithm to enable the model to accurately convert JSP page code into Vue page code. Regularization, Dropout, and other techniques are used to prevent overfitting. The Adam optimization algorithm is used to optimize the training process, and grid search or random search methods provided by scikit-learn are used to automatically adjust the model parameters to find the optimal model configuration. Performance indicators such as accuracy and loss function value during the training process, as well as performance changes on the validation set, are then monitored to ensure that the model is not overfitting or underfitting, thereby obtaining a specified model that meets the model building requirements.
[0157] The specified model is used as the conversion model.
[0158] In this embodiment, a test dataset can also be used to test the converted Vue page to verify the correctness and completeness of its functionality. The test results are then statistically analyzed to evaluate the conversion effect of the conversion model. The conversion model can then be further optimized and improved based on the test results. The test dataset can be composed of a specified proportion of data randomly selected from the sample data. There is no limit on the specified proportion; for example, 0.3 can be used.
[0159] The present application obtains pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data; then parses the initial JSP page code data and the initial Vue page code data to obtain corresponding JSP page information and Vue page information; then performs feature vectorization on the JSP page information and the Vue page information to obtain corresponding sample data; subsequently calls a preset initial model and obtains a preset optimization strategy; finally, based on the optimization strategy, uses the sample data to train the initial model to obtain a specified model that meets the preset model construction requirements, and uses the specified model as the conversion model, thereby automatically and quickly completing the construction process of the conversion model, effectively improving the construction efficiency of the conversion model, and effectively ensuring the model effect of the generated conversion model.
[0160] In some optional implementations of this embodiment, performing feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data includes the following steps:
[0161] The JSP page information and the Vue page information are preprocessed respectively to obtain corresponding specified JSP page information and specified Vue page information.
[0162] In this embodiment, the preprocessing may include data cleaning, data labeling, and data formatting. Data cleaning may include removing irrelevant information, such as comments and whitespace, to ensure data integrity. Data labeling may include labeling the extracted information, such as labeling EL expressions in JSP pages as data binding or labeling v-bind in Vue pages as data binding. Data formatting may include converting the extracted information into a unified format, such as JSON or XML, to facilitate subsequent processing.
[0163] Get the preset feature type information.
[0164] In this embodiment, the above-mentioned feature type information may at least include the JSP page feature type and the Vue page feature type. Among them, the JSP page feature type specifically includes the following features. 1) Page structure features: HTML tag type, tag nesting relationship, attribute type and quantity, etc. 2) Data binding features: EL expression position, binding variable name, binding type (such as text, attribute, event, etc.). 3) Event processing features: event type (such as click, input, etc.), event processing function name. 4) JSP element features: JSP instruction type, script element type, action element type, custom tag name, etc.
[0165] In addition, Vue page feature types specifically include the following features: 1) Component features: component name, component type (global / local), component properties, slot usage, etc. 2) Data binding features: Vue data binding syntax (such as v-bind, v-model), binding variable name, binding expression. 3) Routing features: routing path, routing component mapping relationship. 4) Style and script features: CSS selectors, JavaScript function names, variable names, etc.
[0166] Based on the feature type information, feature selection processing is performed on the specified JSP page information and the specified Vue page information to obtain corresponding specified features.
[0167] In this embodiment, feature selection processing can be performed on the specified JSP page information and the specified Vue page information according to the above feature type information, that is, features matching the feature type information are filtered out from the specified JSP page information and the specified Vue page information, thereby obtaining the above specified features.
[0168] A corresponding feature vector is constructed based on the specified feature.
[0169] In this embodiment, a corresponding feature vector may be constructed based on the obtained specified features and used as input for the model.
[0170] The sample data is generated based on the feature vector.
[0171] In this embodiment, the feature vector can be directly used as the sample data. The sample data is data containing a pair of JSP and Vue page codes.
[0172] The present application obtains the corresponding designated JSP page information and designated Vue page information by pre-processing the JSP page information and the Vue page information respectively; then obtains preset feature type information; then performs feature selection processing on the designated JSP page information and the designated Vue page information based on the feature type information to obtain corresponding designated features; subsequently constructs corresponding feature vectors based on the designated features; and finally generates the sample data based on the feature vectors. The present application obtains the corresponding designated JSP page information and the Vue page information by pre-processing the JSP page information and the Vue page information respectively; then performs feature selection processing on the designated JSP page information and the designated Vue page information based on the obtained feature type information to obtain designated features. Based on the designated features, high-quality sample data can be quickly and intelligently constructed, effectively improving the efficiency of sample data construction and providing reliable data support for subsequent model construction.
[0173] In some optional implementations, the user information obtained is obtained with the user's consent and complies with relevant laws and policies.
[0174] In addition, any software tools or components not provided by our company that appear in the embodiments of this application are merely examples and do not represent actual use.
[0175] This application provides a method for automatically converting JSP pages to Vue pages, which can greatly improve the efficiency and quality of front-end development. This method can be integrated into front-end development tools or platforms to provide developers with a one-click JSP page to Vue page function.
[0176] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0177] It should be emphasized that in order to further ensure the privacy and security of the above-mentioned target Vue page code, the above-mentioned target Vue page code can also be stored in a blockchain node.
[0178] The blockchain referred to in this application is a new application model for computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Blockchain is essentially a decentralized database, a series of data blocks generated using cryptographic methods. Each data block contains information about a batch of network transactions, which is used to verify the validity of this information (to prevent counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, the platform product service layer, and the application service layer.
[0179] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Artificial Intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to achieve optimal results.
[0180] Fundamental AI technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0181] Those skilled in the art will appreciate that all or part of the processes in the above-described method embodiments can be implemented by instructing related hardware via computer-readable instructions. The computer-readable instructions can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes in the above-described method embodiments. The aforementioned storage medium can be a non-volatile storage medium such as a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
[0182] It should be understood that although the steps in the flowcharts of the accompanying drawings are shown in sequence as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some of the steps in the flowcharts of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
[0183] Further references Figure 3 , as a response to the above Figure 2 The present application provides an embodiment of a data conversion device based on artificial intelligence. Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0184] like Figure 3 As shown, the artificial intelligence-based data conversion device 300 of this embodiment includes: a judgment module 301, an extraction module 302, a first processing module 303, a conversion module 304, an optimization module 305 and a sending module 306. Among them:
[0185] The judgment module 301 is used to judge whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted;
[0186] Extraction module 302, configured to extract the JSP page code from the data conversion request;
[0187] The first processing module 303 is used to perform format conversion processing on the JSP page code to obtain corresponding target code data;
[0188] The conversion module 304 is used to convert the target code data based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data;
[0189] The optimization module 305 is used to optimize the Vue page code to obtain the corresponding target Vue page code;
[0190] The sending module 306 is used to send the target Vue page code to the user.
[0191] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based data conversion method in the aforementioned embodiment, and are not repeated here.
[0192] In some optional implementations of this embodiment, the optimization module 305 includes:
[0193] A first processing submodule is used to perform code structure optimization processing on the Vue page code to obtain corresponding first code data;
[0194] a second processing submodule, configured to perform component sequence adjustment processing on the first code data to obtain corresponding second code data;
[0195] a third processing submodule, configured to perform tuning processing on the second code data based on a preset tuning strategy to obtain corresponding third code data;
[0196] Determine a submodule for using the third code data as the target Vue page code.
[0197] In some optional implementations of this embodiment, the sending module 306 includes:
[0198] The review submodule is used to review the target Vue page code based on a preset review strategy;
[0199] A test submodule is used to test the target Vue page code based on a preset test strategy if the target Vue page code passes the review;
[0200] The first acquisition submodule is used to obtain a preset target sending method if the target Vue page code passes the test;
[0201] The sending submodule is used to send the target Vue page code to the user based on the target sending method.
[0202] In some optional implementations of this embodiment, the review submodule includes:
[0203] A first acquisition unit is used to acquire preset code review rules and readability review rules;
[0204] A first review unit is configured to perform a code review on the target Vue page code based on the code review rules;
[0205] A second review unit is configured to perform a readability review on the target Vue page code based on the readability review rule if the target Vue page code passes the code review;
[0206] The first determination unit is configured to determine that the target Vue page code has passed the review if the target Vue page code has passed the readability review, and otherwise determine that the target Vue page code has failed the review.
[0207] In some optional implementations of this embodiment, the testing submodule includes:
[0208] A second acquiring unit, configured to acquire preset functional testing rules, compatibility testing rules, and performance testing rules;
[0209] A first testing unit is used to perform a functional test on the target Vue page code based on the functional testing rules;
[0210] A second testing unit is configured to perform a compatibility test on the target Vue page code based on the compatibility test rules if the target Vue page code passes the functional test;
[0211] A third testing unit is configured to perform a performance test on the target Vue page code based on the performance test rules if the target Vue page code passes the compatibility test;
[0212] The second determination unit is configured to determine that the target Vue page code has passed the test if the target Vue page code has passed the performance test, and otherwise determine that the target Vue page code has failed the test.
[0213] In some optional implementations of this embodiment, the artificial intelligence-based data conversion device further includes:
[0214] An acquisition module is used to acquire pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data;
[0215] A parsing module is used to parse the initial JSP page code data and the initial Vue page code data to obtain corresponding JSP page information and Vue page information;
[0216] The second processing module is used to perform feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data;
[0217] The calling module is used to call the preset initial model and obtain the preset optimization strategy;
[0218] A training module, configured to train the initial model using the sample data based on the optimization strategy to obtain a specified model that meets the preset model building requirements;
[0219] A determination module is configured to use the specified model as the conversion model.
[0220] In some optional implementations of this embodiment, the second processing module includes:
[0221] A preprocessing submodule is used to preprocess the JSP page information and the Vue page information respectively to obtain corresponding specified JSP page information and specified Vue page information;
[0222] The second acquisition submodule is used to obtain preset feature type information;
[0223] A selection submodule is used to perform feature selection processing on the specified JSP page information and the specified Vue page information based on the feature type information to obtain corresponding specified features;
[0224] A construction submodule, configured to construct a corresponding feature vector based on the specified feature;
[0225] A generating submodule is used to generate the sample data based on the feature vector.
[0226] To solve the above technical problems, the present application also provides a computer device. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.
[0227] The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that are interconnected through a system bus. It should be noted that the figure only shows a computer device 4 with components 41-43, but it should be understood that it is not required to implement all the components shown, and more or fewer components can be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application-specific integrated circuits (ASICs), programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.
[0228] The computer device may be a desktop computer, notebook computer, PDA, cloud server, etc. The computer device may interact with the user via a keyboard, mouse, remote control, touchpad, or voice control device.
[0229] The memory 41 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic storage, magnetic disk, optical disk, etc. In some embodiments, the memory 41 can be an internal storage unit of the computer device 4, such as the hard disk or memory of the computer device 4. In other embodiments, the memory 41 can also be an external storage device of the computer device 4, such as a plug-in hard disk equipped on the computer device 4, a smart memory card (SMC), a secure digital (SD) card, a flash memory card, etc. Of course, the memory 41 can also include both the internal storage unit of the computer device 4 and its external storage device. In this embodiment, the memory 41 is generally used to store the operating system and various application software installed on the computer device 4, such as computer-readable instructions for artificial intelligence-based data conversion methods. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or are to be output.
[0230] In some embodiments, the processor 42 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 42 is generally used to control the overall operation of the computer device 4. In this embodiment, the processor 42 is used to execute computer-readable instructions stored in the memory 41 or process data, such as executing computer-readable instructions for the artificial intelligence-based data conversion method.
[0231] The network interface 43 may include a wireless network interface or a wired network interface. The network interface 43 is generally used to establish a communication connection between the computer device 4 and other electronic devices.
[0232] The present application also provides another embodiment, namely, providing a computer-readable storage medium, which stores computer-readable instructions, and the computer-readable instructions can be executed by at least one processor to enable the at least one processor to perform the steps of the above-mentioned artificial intelligence-based data conversion method.
[0233] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present application.
[0234] Obviously, the embodiments described above are only some of the embodiments of the present application, rather than all of the embodiments. The preferred embodiments of the present application are given in the accompanying drawings, but they do not limit the patent scope of the present application. The present application can be implemented in many different forms. On the contrary, the purpose of providing these embodiments is to make the understanding of the disclosure of the present application more thorough and comprehensive. Although the present application has been described in detail with reference to the aforementioned embodiments, for those skilled in the art, it is still possible to modify the technical solutions described in the aforementioned specific embodiments, or to make equivalent replacements for some of the technical features therein. Any equivalent structure made using the contents of the present application specification and the accompanying drawings, directly or indirectly used in other related technical fields, is also within the scope of patent protection of the present application.
Claims
1. A data conversion method based on artificial intelligence, characterized in that: The steps include: Determine whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted; If so, extracting the JSP page code from the data conversion request; Performing format conversion processing on the JSP page code to obtain corresponding target code data; The target code data is converted based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data; Optimize the Vue page code to obtain the corresponding target Vue page code; Send the target Vue page code to the user; Wherein, before the step of converting the target code data based on the pre-trained conversion model to generate the Vue page code corresponding to the target code data, the step further includes: Acquire pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data; Parsing the initial JSP page code data and the initial Vue page code data to obtain corresponding JSP page information and Vue page information; Perform feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data; Call the preset initial model and obtain the preset optimization strategy; Based on the optimization strategy, the initial model is trained using the sample data to obtain a specified model that meets the preset model construction requirements; Using the specified model as the conversion model; The step of performing feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data specifically includes: Preprocess the JSP page information and the Vue page information respectively to obtain corresponding specified JSP page information and specified Vue page information; Get the preset feature type information; Perform feature selection processing on the specified JSP page information and the specified Vue page information based on the feature type information to obtain corresponding specified features; Constructing a corresponding feature vector based on the specified feature; The sample data is generated based on the feature vector.
2. The data conversion method based on artificial intelligence according to claim 1, characterized in that: The step of optimizing the Vue page code to obtain the corresponding target Vue page code specifically includes: Performing code structure optimization processing on the Vue page code to obtain corresponding first code data; performing component sequence adjustment processing on the first code data to obtain corresponding second code data; Performing tuning processing on the second code data based on a preset tuning strategy to obtain corresponding third code data; The third code data is used as the target Vue page code.
3. The data conversion method based on artificial intelligence according to claim 1, characterized in that: The step of sending the target Vue page code to the user specifically includes: Review the target Vue page code based on a preset review strategy; If the target Vue page code passes the review, the target Vue page code is tested based on a preset test strategy; If the target Vue page code passes the test, the preset target sending method is obtained; Based on the target sending method, the target Vue page code is sent to the user.
4. The artificial intelligence-based data conversion method according to claim 3, characterized in that: The step of reviewing the target Vue page code based on the preset review strategy specifically includes: Get preset code review rules and readability review rules; Perform code review on the target Vue page code based on the code review rules; If the target Vue page code passes the code review, then the target Vue page code is subjected to a readability review based on the readability review rules; If the target Vue page code passes the readability review, it is determined that the target Vue page code passes the review; otherwise, it is determined that the target Vue page code fails the review.
5. The data conversion method based on artificial intelligence according to claim 3, characterized in that: The step of testing the target Vue page code based on a preset test strategy specifically includes: Obtain preset functional testing rules, compatibility testing rules, and performance testing rules; Perform functional testing on the target Vue page code based on the functional testing rules; If the target Vue page code passes the functional test, a compatibility test is performed on the target Vue page code based on the compatibility test rules; If the target Vue page code passes the compatibility test, then the target Vue page code is subjected to a performance test based on the performance test rules; If the target Vue page code passes the performance test, it is determined that the target Vue page code passes the test; otherwise, it is determined that the target Vue page code fails the test.
6. A data conversion device based on artificial intelligence, characterized in that: The artificial intelligence-based data conversion device is a device for executing the artificial intelligence-based data conversion method according to any one of claims 1 to 5, and the artificial intelligence-based data conversion device comprises: A judgment module, configured to judge whether a data conversion request triggered by a user in a preset interface is received; wherein the data conversion request carries the JSP page code to be converted; An extraction module, configured to extract the JSP page code from the data conversion request if yes; The first processing module is used to perform format conversion processing on the JSP page code to obtain corresponding target code data; A conversion module is used to convert the target code data based on a pre-trained conversion model to generate a Vue page code corresponding to the target code data; An optimization module is used to optimize the Vue page code to obtain the corresponding target Vue page code; A sending module, used to send the target Vue page code to the user; Among them, the data conversion device based on artificial intelligence also includes: An acquisition module is used to acquire pre-collected initial JSP page code data and initial Vue page code data corresponding to the initial JSP page code data; A parsing module is used to parse the initial JSP page code data and the initial Vue page code data to obtain corresponding JSP page information and Vue page information; The second processing module is used to perform feature vectorization processing on the JSP page information and the Vue page information to obtain corresponding sample data; The calling module is used to call the preset initial model and obtain the preset optimization strategy; A training module, configured to train the initial model using the sample data based on the optimization strategy to obtain a specified model that meets the preset model building requirements; a determination module, configured to use the specified model as the conversion model; The second processing module includes: A preprocessing submodule is used to preprocess the JSP page information and the Vue page information respectively to obtain corresponding specified JSP page information and specified Vue page information; The second acquisition submodule is used to obtain preset feature type information; A selection submodule is used to perform feature selection processing on the specified JSP page information and the specified Vue page information based on the feature type information to obtain corresponding specified features; A construction submodule, configured to construct a corresponding feature vector based on the specified feature; A generating submodule is used to generate the sample data based on the feature vector.
7. A computer device, characterized in that: The method comprises a memory and a processor, wherein the memory stores computer-readable instructions, and when the processor executes the computer-readable instructions, the steps of the artificial intelligence-based data conversion method as described in any one of claims 1 to 5 are implemented.
8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the artificial intelligence-based data conversion method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Method and device for converting H5 project into Vue framework and computer equipment
CN110968319A
JSP version code reconstruction transcoding method and device, equipment and medium
CN117032794A