Front-end page development method and device, equipment, storage medium and program product

The method of generating front-end pages by obtaining business requirement parameters and custom interface parameters solves the problem that back-end developers need to be familiar with front-end technology, improves algorithm development and debugging efficiency, and achieves rapid development and debugging of front-end pages.

CN118733031APending Publication Date: 2024-10-01CHONGQING CHANGAN AUTOMOBILE CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410810517.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-21
Publication Date
2024-10-01

AI Technical Summary

Technical Problem

Back-end developers need to be familiar with front-end technology to develop front-end pages, which affects algorithm development efficiency and debugging efficiency.

Method used

By obtaining the business requirement parameters corresponding to the algorithm development task, determining the initial data model, and modifying the model according to the custom interface parameters to generate the target data model, the front-end page corresponding to the business requirement parameters can be generated without the need for front-end technical knowledge.

Benefits of technology

It improves the efficiency of algorithm development, allows developers to debug algorithms on the fly, reduces dependence on front-end technology, and enhances ease of use for back-end developers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118733031A_ABST
    Figure CN118733031A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of data visualization, and discloses a front-end page development method and device, equipment, a storage medium and a program product.The method comprises the steps that service requirement parameters corresponding to an algorithm development task of a developer are obtained, and an initial data model is determined based on the service requirement parameters; obtaining a target data model according to self-defined interface parameters input by a developer based on the initial data model; and according to the target data model, generating a front-end page corresponding to the business demand parameter. According to the method and the device, the initial data model corresponding to the business demand parameter of the algorithm development task is acquired, and the target data model is obtained by modifying the initial data model according to the custom interface parameter input by a developer based on the initial data model, so that the developer does not need to know and master front-end technical knowledge; therefore, the front-end page corresponding to the business demand parameter can be obtained, a developer can conveniently debug the algorithm according to the front-end page in real time, and the algorithm development efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data visualization technology, and in particular to a front-end page development method, device, equipment, storage medium and program product. Background Art

[0002] Many machine learning and deep learning technologies are used in the development of autonomous driving algorithms. Developers need to view some training data instantly to debug the algorithm, or quickly enter the algorithm development process through the front-end page. Therefore, the front-end visualization page corresponding to the algorithm development process is particularly important. However, algorithm developers often do not understand front-end technology, and they are not interested in spending a lot of time learning front-end frameworks to build web applications. Instead, they need a tool that is easier to learn and use, as long as it can display data and collect the parameters required for modeling.

[0003] At present, low-code development technology can be used to quickly build the front-end page of an application, and the page can be customized by dragging and dropping the corresponding functional configuration components, which does not require high development capabilities from the user. However, this method overemphasizes low-code and cannot flexibly adapt to various scenarios. It often requires back-end developers to expand and optimize the code for special scenarios. In this regard, technologies such as dash and reactpy allow users to develop web applications based on only mastering the python language, but it still requires users to understand some front-end technical knowledge such as html, css, and js. There is a certain technical threshold, which greatly affects the development efficiency and debugging efficiency of the algorithm.

[0004] Therefore, there is an urgent need for a front-end page development method that is easy to use for back-end developers, so that back-end personnel can quickly develop web visualization applications without being familiar with front-end knowledge. Summary of the invention

[0005] In view of this, the present invention provides a front-end page development method, device, equipment, storage medium and program product to solve the problem in related technologies that back-end developers still need to have certain front-end technical knowledge to develop front-end pages, which seriously affects the efficiency of algorithm development.

[0006] In a first aspect, the present invention provides a front-end page development method, the method comprising:

[0007] Obtaining business requirement parameters corresponding to the algorithm development task of the developer, and determining an initial data model based on the business requirement parameters; the initial data model is obtained by encapsulating a preset web framework and a preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating a preset page general interface, a preset page layout interface, and a preset page component interface for generating a front-end page;

[0008] Obtain the target data model according to the custom interface parameters input by the developer based on the initial data model;

[0009] Generate front-end pages corresponding to business requirement parameters based on the target data model.

[0010] By obtaining the initial data model corresponding to the business requirement parameters of the algorithm development task, and modifying the initial data model according to the custom interface parameters input by the developer based on the initial data model to obtain the target data model, the front-end page corresponding to the business requirement parameters can be obtained through the target data model without being familiar with the front-end technical knowledge, which makes it convenient for developers to debug the algorithm according to the front-end page in real time, thereby improving the efficiency of algorithm development.

[0011] In an optional implementation, obtaining a target data model according to the custom interface parameters input by the developer based on the initial data model includes:

[0012] By using the preset web framework of the integrated routing interface, the custom interface parameters input by the developer based on the initial data model are mapped to the preset interface parameter model to obtain the target interface parameter model;

[0013] The preset web framework of the integrated routing interface and the target interface parameter model are encapsulated to obtain the target data model.

[0014] Thus, by encapsulating the preset web framework of the integrated routing interface and the preset interface parameter model in the initial data model, the user can directly modify the initial data model through the customized interface parameters to obtain the target data model corresponding to the front-end page without the user having to write front-end code.

[0015] In an optional implementation, the custom interface parameters include a page general interface, a page layout interface, and a page component interface;

[0016] The page general interface includes at least one of a menu bar interface, a login interface, and a logout interface;

[0017] The page layout interface includes at least one of a page URL address interface, a page configuration interface, and a text content interface;

[0018] The page component interface includes at least one of a page form interface, a form component interface, an icon interface, a pop-up window interface, a confirmation interface, and a jump interface.

[0019] By converting the content required by the front-end page into an interface in the data model, users are allowed to customize it, which helps improve the flexibility of page construction.

[0020] In an optional implementation, generating a front-end page corresponding to the business requirement parameters according to the target data model includes:

[0021] Determine the front-end and back-end data transmission protocols;

[0022] Based on the front-end and back-end data transmission protocols, the target data model obtained by encapsulation based on the preset web framework is instantiated to obtain a web front-end page corresponding to the business demand parameters.

[0023] Therefore, by agreeing on the front-end and back-end data transmission protocol, the front-end is driven to render the page through the back-end target data model, and a web front-end page corresponding to the business requirement parameters is obtained. There is no need for front-end personnel to participate, which makes it easier for back-end developers.

[0024] In an optional implementation, the preset web framework is a flask object constructed using flask, the preset interface parameter model is obtained by presetting the pydantic interface parameter model, and the preset web framework integrates the routing interface by utilizing the blueprint library in flask.

[0025] Therefore, by using the flask object and the pydantic interface parameter model, the initial data model corresponding to the front-end page is constructed, so that developers can customize the initial data model by directly entering custom interface parameters.

[0026] In an optional implementation, determining the initial data model based on the business requirement parameters includes:

[0027] Based on the business requirement parameters, determine multiple visualization targets corresponding to the algorithm development task; wherein the algorithm development task includes at least one of machine learning and deep learning;

[0028] Based on multiple visualization targets, an initial data model is obtained.

[0029] Therefore, the multiple visualization targets that need to be displayed on the front-end page can be determined through business requirement parameters, which makes it easy to determine the appropriate data model for rendering based on the visualization targets without the need for users to perform extended development.

[0030] In an optional implementation, an initial data model is obtained based on multiple visualization targets, including:

[0031] Based on multiple visualization targets, a search is performed in a pre-built data model library with data model labels to obtain an initial data model; wherein the visualization target includes at least one of a network structure image, a feature map output result, a training loss curve, and a training accuracy curve.

[0032] Therefore, a search can be performed in a pre-built data model library with data model tags to quickly determine the initial data model corresponding to the business requirement parameters and improve processing efficiency.

[0033] In an optional implementation, after generating a front-end page corresponding to the business requirement parameters according to the target data model, the method further includes:

[0034] Receive trigger requests from developers on the front-end page;

[0035] In response to the trigger request, adjust the display content of the front-end page.

[0036] Therefore, after the front-end page is displayed, the display content of the front-end page is adjusted accordingly according to the trigger operation of the developer, so that the user can view the detailed content of the page.

[0037] In a second aspect, the present invention provides a front-end page development device, the device further comprising:

[0038] An acquisition module is used to acquire business requirement parameters corresponding to the algorithm development task of the developer, and determine an initial data model based on the business requirement parameters; the initial data model is obtained by encapsulating a preset web framework and a preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating a preset page general interface, a preset page layout interface, and a preset page component interface for generating a front-end page;

[0039] A processing module, used to obtain a target data model according to the custom interface parameters input by the developer based on the initial data model;

[0040] The generation module is used to generate a front-end page corresponding to the business requirement parameters according to the target data model.

[0041] In some optional implementations, the acquisition module is further used to:

[0042] Based on the business requirement parameters, determine multiple visualization targets corresponding to the algorithm development task; wherein the algorithm development task includes at least one of machine learning and deep learning;

[0043] Based on multiple visualization targets, an initial data model is obtained.

[0044] In some optional implementations, the acquisition module is further used to:

[0045] Based on multiple visualization targets, a search is performed in a pre-built data model library with data model labels to obtain an initial data model; wherein the visualization target includes at least one of a network structure image, a feature map output result, a training loss curve, and a training accuracy curve.

[0046] In some optional implementations, the initial data model is obtained by encapsulating a preset web framework and a preset interface parameter model of the integrated routing interface; the processing module is further used to:

[0047] By using the preset web framework of the integrated routing interface, the custom interface parameters input by the developer based on the initial data model are mapped to the preset interface parameter model to obtain the target interface parameter model;

[0048] The preset web framework of the integrated routing interface and the target interface parameter model are encapsulated to obtain the target data model.

[0049] In some optional implementations, the custom interface parameters include a page general interface, a page layout interface, and a page component interface;

[0050] The page general interface includes at least one of a menu bar interface, a login interface, and a logout interface;

[0051] The page layout interface includes at least one of a page URL address interface, a page configuration interface, and a text content interface;

[0052] The page component interface includes at least one of a page form interface, a form component interface, an icon interface, a pop-up window interface, a confirmation interface, and a jump interface.

[0053] In some optional implementations, the generation module is further configured to:

[0054] Determine the front-end and back-end data transmission protocols;

[0055] Based on the front-end and back-end data transmission protocols, the target data model obtained by encapsulation based on the preset web framework is instantiated to obtain a web front-end page corresponding to the business demand parameters.

[0056] In some optional implementations, the preset web framework is a flask object constructed using flask, the preset interface parameter model is obtained by presetting the pydantic interface parameter model, and the preset web framework integrates the routing interface by utilizing the blueprint library in flask.

[0057] In some optional embodiments, the device is also used for:

[0058] Receive trigger requests from developers on the front-end page;

[0059] In response to the trigger request, adjust the display content of the front-end page.

[0060] In a third aspect, the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor are communicatively connected to each other, computer instructions are stored in the memory, and the processor executes the front-end page development method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0061] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the front-end page development method of the first aspect or any corresponding embodiment thereof.

[0062] The beneficial effects of the present invention are:

[0063] By obtaining the initial data model corresponding to the business requirement parameters of the algorithm development task, and modifying the initial data model according to the custom interface parameters input by the developer based on the initial data model to obtain the target data model, the front-end page corresponding to the business requirement parameters can be obtained through the target data model without being familiar with the front-end technical knowledge, which makes it convenient for developers to debug the algorithm according to the front-end page in real time, thereby improving the efficiency of algorithm development. BRIEF DESCRIPTION OF THE DRAWINGS

[0064] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0065] Figure 1 is a flow chart of a front-end page development method according to an embodiment of the present invention;

[0066] Figure 2 is a flow chart of another front-end page development method according to an embodiment of the present invention;

[0067] Figure 3 is a flow chart of another front-end page development method according to an embodiment of the present invention;

[0068] Figure 4is a system schematic diagram of a front-end and back-end communication method according to an embodiment of the present invention;

[0069] Figure 5 is a structural block diagram of a front-end page development framework according to an embodiment of the present invention;

[0070] Figure 6 is a schematic diagram of a rendering effect of a front-end page according to an embodiment of the present invention;

[0071] Figure 7 is a schematic diagram of a front-end and back-end data transmission protocol according to an embodiment of the present invention;

[0072] Figure 8 is a structural block diagram of a front-end page development device according to an embodiment of the present invention;

[0073] Fig. 9 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0074] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0075] As technologies such as machine learning and data science advance, it becomes important to build web applications that are shareable, fast to develop, and algorithm-friendly.

[0076] At present, low-code development technology can be used to quickly build the front-end page of an application, and the page can be customized by dragging and dropping the corresponding function configuration components, which does not require high development capabilities from the user. Patent "CN117742834A" discloses a low-code platform page component configuration method and device, which realizes page customization through selection operations on the function configuration page, improves the flexibility of function configuration, and optimizes the user's interactive experience. However, this method overemphasizes low code and cannot flexibly adapt to various scenarios. It often requires back-end developers to expand and optimize the code for special scenarios.

[0077] In this regard, technologies such as streamlit, dash and reactpy provide algorithm personnel with faster and easier-to-use applications, allowing users to develop web applications based on only mastering the back-end development language. However, these frameworks have problems to varying degrees in terms of scalability, functionality, and ease of use. Users still need to understand some front-end technical knowledge such as html, css, and js, which has a certain technical threshold and greatly affects the development efficiency and debugging efficiency of the algorithm.

[0078] Therefore, the present invention provides a front-end page development solution, which only requires the developer to input custom interface parameters in the initial data model of the back-end to obtain the target data model, and by instantiating and rendering the target data model, the front-end page required by the developer can be obtained. The developer does not need to be familiar with the front-end code knowledge, thereby improving the efficiency of back-end algorithm development.

[0079] According to an embodiment of the present invention, a front-end page development method embodiment is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0080] In this embodiment, a front-end page development method is provided, which can be used for a computer device or electronic device used by a developer, such as a tablet computer, a computer, etc. Figure 1 is a flow chart of a front-end page development method according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0081] Step S101, obtaining business requirement parameters corresponding to the algorithm development task of the developer, and determining an initial data model based on the business requirement parameters.

[0082] It should be noted that the initial data model is obtained by encapsulating the preset web framework and preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating the preset page general interface, preset page layout interface and preset page component interface used to generate the front-end page.

[0083] Exemplarily, the parameters (style, size, color, etc.) of some page components frequently used in the front-end page are preset in the preset page general interface, preset page layout interface and preset page component interface, such as login / logout interface, menu bar interface, form, etc. These interfaces are encapsulated as a preset interface parameter model based on Python objects. Further, a basic web framework is encapsulated on the basis of the preset interface parameter model to obtain the initial data model. Through preliminary research, a data model library covering most of the requirements of the front-end page required for the algorithm development task can be generated, and the data model library contains multiple initial data models.

[0084] Specifically, developers can organize business requirement parameters based on the required front-end page and the content that needs to be displayed on the front-end page. The business requirement parameters may include the task type of the current algorithm development task (machine learning, regression algorithm, clustering algorithm, etc.), the data set used, and the task objectives (training loss rate, training accuracy, image generation, etc.).

[0085] In some optional implementations, developers can directly input the organized business requirement parameters into the device, or organize the business requirement parameters into a text document for the device to read. The device will then perform fuzzy search and model matching on the business requirement parameters, allowing users to use incomplete or approximate matching keywords to find relevant information when searching to determine the initial data model.

[0086] It should be noted that the initial data model of the embodiment of the present invention is essentially a markup language used to define the page content and structure of the front-end page.

[0087] Step S102, obtaining a target data model according to the custom interface parameters input by the developer based on the initial data model.

[0088] Specifically, the initial data model is preset based on some commonly used pages in the algorithm development task, and integrates the commonly used interface parameters of the front-end page. By simply modifying the interface parameters in the initial data model according to the custom interface parameters entered by the developer, the target data model that matches the front-end page required by the developer can be obtained.

[0089] In some optional implementations, if the initial data model does not completely correspond to the business requirement parameters, that is, the initial data model cannot fully meet the developer's front-end page requirements, the developer can also be allowed to further expand and modify the initial data model so that the rendered front-end page is more in line with business requirements and meets the diverse needs of users, thereby improving the user experience.

[0090] Step S103: Generate a front-end page corresponding to the business requirement parameters according to the target data model.

[0091] Specifically, since the target data model integrates the interface parameters required for the front-end page, by instantiating and rendering the target data model, the front-end page corresponding to the business requirement parameters can be directly obtained without the use of front-end technical knowledge such as HTML and CCS. This is beneficial for back-end developers to instantly view the accuracy, structure and other parameters of the algorithm, thereby improving the efficiency of algorithm development.

[0092] The front-end page development method provided in this embodiment obtains the initial data model corresponding to the business requirement parameters of the algorithm development task, and modifies the initial data model according to the custom interface parameters input by the developer based on the initial data model to obtain the target data model. Without being familiar with the front-end technical knowledge, the front-end page corresponding to the business requirement parameters can be obtained through the target data model, which is convenient for developers to debug the algorithm according to the front-end page in real time, thereby improving the efficiency of algorithm development.

[0093] In this embodiment, a front-end page development method is provided, which can be used for a computer device or electronic device used by a developer, such as a tablet computer, a computer, etc. Figure 2 is a flow chart of a front-end page development method according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:

[0094] Step S201, obtain the business requirement parameters corresponding to the algorithm development task of the developer, and determine the initial data model based on the business requirement parameters. Figure 1 Step S101 of the illustrated embodiment will not be described in detail here.

[0095] Step S202, obtaining a target data model according to the custom interface parameters input by the developer based on the initial data model.

[0096] Specifically, the initial data model is obtained by encapsulating the preset web framework and the preset interface parameter model of the integrated routing interface; the above step S202 includes:

[0097] Step S2021, using the preset web framework of the integrated routing interface, the custom interface parameters input by the developer based on the initial data model are mapped to the preset interface parameter model to obtain the target interface parameter model.

[0098] It is important to understand that the routing interface is a key component that is responsible for mapping the custom interface parameters entered by the user to the corresponding processing functions or controllers in the preset interface parameter model.

[0099] Specifically, a series of routing rules are defined in the initial data model. These rules usually specify a URL pattern (for example, / users / :id, where ":id" is a dynamic parameter) and a corresponding processing function (which can be a function, controller method or view, etc.). When the user enters the custom interface parameters by accessing the URL, the preset Web framework will receive the request, and the routing interface will parse the requested URL, and then match the parsed URL with the pre-defined routing rules. If a matching rule is found, the routing will know which processing function should be called. If the URL contains dynamic parameters (such as ":id" in the above example), the routing will extract the values ​​of these parameters and pass them to the preset interface parameter model.

[0100] In some optional implementations, the custom interface parameters include a page general interface, a page layout interface, and a page component interface; the page general interface includes at least one of a menu bar interface, a login interface, and a logout interface; the page layout interface includes at least one of a page URL address interface, a page configuration interface, and a text content interface; the page component interface includes at least one of a page form interface, a form component interface, an icon interface, a pop-up window interface, a confirmation interface, and a jump interface. It should be noted that the content included in the above custom interface parameters is only an example, and the present invention is not limited thereto.

[0101] By converting the content required by the front-end page into an interface in the data model, users are allowed to customize it, which helps improve the flexibility of page construction.

[0102] Exemplarily, the preset web framework is a flask object constructed by using flask, the preset interface parameter model is obtained by presetting the pydantic interface parameter model, and the preset web framework integrates the routing interface by using the blueprint library in flask.

[0103] It should be noted that flask is a lightweight web framework written in Python. It adds other functions by extension on the simple core. It does not have a default database and form validation tool, and provides a certain degree of customization and scalability. Flask provides a routing system that can map different URL paths to corresponding processing functions. When a user visits a specific URL, Flask will call the corresponding processing function and return a response; Flask supports URL construction, allowing developers to create dynamic links by adding parameters to the URL.

[0104] In addition, pydantic provides a way to define data models and verify the validity of input data. The data model is defined in a declarative way, and the type and validation rules of each field are specified. Pydantic can convert input data into Python objects and perform type checking and conversion according to the data model.

[0105] Therefore, by using the flask object and the pydantic interface parameter model, the initial data model corresponding to the front-end page is constructed, so that developers can customize the initial data model by directly entering custom interface parameters.

[0106] Step S2022, encapsulate the preset web framework of the integrated routing interface and the target interface parameter model to obtain a target data model.

[0107] Exemplarily, the flask object of the integrated routing interface and the pydantic interface parameter model obtained according to the custom interface parameters can be encapsulated to obtain the target data model.

[0108] Thus, by encapsulating the preset web framework of the integrated routing interface and the preset interface parameter model in the initial data model, the user can directly modify the initial data model through the customized interface parameters to obtain the target data model corresponding to the front-end page without the user having to write front-end code.

[0109] Step S203: Generate a front-end page corresponding to the business requirement parameters according to the target data model.

[0110] Specifically, the above step S203 includes:

[0111] Step S2031, determine the front-end and back-end data transmission protocol.

[0112] In some optional implementations, the front-end and back-end data transmission protocols may be encapsulated in the initial data model to further improve the usability of the initial data model. Exemplarily, the front-end and back-end transmission protocols may be http protocols, but the present invention is not limited thereto.

[0113] Step S2032, based on the front-end and back-end data transmission protocol, the target data model obtained by encapsulation based on the preset web framework is instantiated to obtain a web front-end page corresponding to the business demand parameters.

[0114] Specifically, through the http protocol, the relevant fields are agreed upon, and the backend completely drives the frontend to render the page. For example, the target data model built based on the flask object is instantiated to obtain the web frontend page corresponding to the business requirement parameters. For details, please refer to the description of the relevant technology, which will not be repeated here.

[0115] Therefore, by agreeing on the front-end and back-end data transmission protocol, the front-end is driven to render the page through the back-end target data model, and a web front-end page corresponding to the business requirement parameters is obtained. There is no need for front-end personnel to participate, which makes it easier for back-end developers.

[0116] The front-end page development method provided in this embodiment obtains the initial data model corresponding to the business requirement parameters of the algorithm development task, and modifies the initial data model encapsulated by flask and pydantic according to the custom interface parameters input by the developer based on the initial data model to obtain the target data model. Without being familiar with the front-end technical knowledge, the web front-end page corresponding to the business requirement parameters can be obtained through the target data model, which is convenient for developers to debug the algorithm according to the front-end page in real time, thereby improving the efficiency of algorithm development.

[0117] In this embodiment, a front-end page development method is provided, which can be used for a computer device or electronic device used by a developer, such as a tablet computer, a computer, etc. Figure 3 is a flow chart of a front-end page development method according to an embodiment of the present invention. Figure 3 As shown, the process includes the following steps:

[0118] Step S301, obtaining business requirement parameters corresponding to the algorithm development task of the developer, and determining an initial data model based on the business requirement parameters.

[0119] Specifically, the above step S301 includes:

[0120] Step S3011, obtain the business requirement parameters corresponding to the algorithm development task of the developer. Figure 1 Step S101 of the illustrated embodiment will not be described in detail here.

[0121] Step S3012: Determine multiple visualization targets corresponding to the algorithm development task based on the business requirement parameters.

[0122] Specifically, the algorithm development task includes at least one of machine learning and deep learning. For different algorithm development tasks, the content that needs to be viewed is also different, which can be preset according to the actual development situation. For example, for deep learning, it is very necessary to intuitively view the training loss curve and training accuracy curve of the neural network in order to adjust the network parameters.

[0123] Step S3013, obtaining an initial data model based on multiple visualization targets.

[0124] Exemplarily, the visualization target includes at least one of a network structure image, a feature map output result, a training loss curve, and a training accuracy curve. Specifically, based on multiple visualization targets, a search is performed in a pre-built data model library with data model labels to obtain an initial data model, so that a suitable data model can be determined for rendering according to the visualization target without the need for users to perform extended development.

[0125] It should be noted that the data model library contains multiple pre-designed initial data models, each of which has a data model label corresponding to the front-end display content, such as "loss rate curve", "accuracy curve", "data set list", etc., so as to quickly determine the initial data model corresponding to the business demand parameters and improve processing efficiency.

[0126] Step S302: Obtain the target data model according to the custom interface parameters input by the developer based on the initial data model. Figure 2 Step S202 of the illustrated embodiment will not be described in detail here.

[0127] Step S303: Generate a front-end page corresponding to the business requirement parameters according to the target data model. Figure 2 Step S203 of the illustrated embodiment will not be described in detail here.

[0128] Step S304, receiving a trigger request from a developer on a front-end page.

[0129] Step S305, responding to the trigger request, adjusting the display content of the front-end page.

[0130] Specifically, after the front-end page is displayed, the display content of the front-end page is adjusted accordingly according to the trigger operation of the developer to facilitate the user to view the detailed content of the page. For details, please refer to the description of related technologies, which will not be repeated here.

[0131] The front-end page development method provided in this embodiment obtains the initial data model corresponding to the business requirement parameters of the algorithm development task, and modifies the initial data model encapsulated by flask and pydantic according to the custom interface parameters input by the developer based on the initial data model to obtain the target data model. Without being familiar with the front-end technical knowledge, the web front-end page corresponding to the business requirement parameters can be obtained through the target data model. The display content of the front-end page is adjusted according to the trigger operation of the developer, which is convenient for the developer to debug the algorithm according to the front-end page in real time, thereby improving the efficiency of algorithm development.

[0132] The front-end page development solution of the present invention is described in detail below with reference to a specific application example, which includes the following steps:

[0133] Step 1: Determine the front-end and back-end data transmission protocol.

[0134] Specifically, step 1 includes the following steps:

[0135] Step 11, define common interfaces of the page, such as menu bar interface, login interface and logout interface.

[0136] Step 12, define page layout interfaces, such as page URL address interface, page configuration interface and text content interface.

[0137] Step 13, define page component interfaces, such as page form interface, form component interface, icon interface, pop-up window interface, confirmation interface and jump interface.

[0138] Step 2: Use the framework front end to develop different data models and implement them according to the data transmission protocol.

[0139] Specifically, step 2 includes the following steps:

[0140] Step 21, implement common interfaces of the page, such as menu bar interface, login interface and logout interface.

[0141] Step 22, implement page layout interfaces, such as page URL address interface, page configuration interface and text content interface.

[0142] Step 23, implement page component interfaces, such as page form interface, form component interface, icon interface, pop-up window interface, confirmation interface and jump interface.

[0143] Step 3, the framework backend - Python layer encapsulates and extends flask to implement the interface part of the http protocol, and encapsulates the http protocol through pydantic.

[0144] Specifically, step 3 includes the following steps:

[0145] Step 31, use Flask's blueprint technology to define a unified routing interface.

[0146] Step 32: Use pydantic to encapsulate the fields in the protocol into a data model.

[0147] Step 4: The user instantiates the flask object in step 3 and implements the front-end page he needs according to the framework.

[0148] Figure 4 A system diagram of a front-end and back-end communication method provided by an embodiment of the present invention, such as Figure 4As shown, the user requests a page in the browser according to the protocol, and by directly configuring the page interface in the framework backend, the device can render the page according to the page configuration. In addition, different content interfaces can be made according to different pages or other interfaces can be extended to achieve diversity in page display. In the process of front-end and back-end communication, this application example implements site management through load balancing to share the traffic access pressure.

[0149] Figure 5 A structural block diagram of a front-end page development framework provided by an embodiment of the present invention, such as Figure 5 As shown, the framework-ui layer can be implemented using react technology, and various components are implemented through the front-end framework; the framework backend uses flask+pydantic to encapsulate the data model, shielding the front-end javascript, html, css and other technologies, and only exposing the python framework; the framework front-end and back-end are transmitted data through the http protocol. Based on this front-end page development framework, users can quickly develop encapsulated functions and quickly implement front-end page rendering.

[0150] Figure 6 A schematic diagram of the rendering effect of a front-end page provided in an embodiment of the present invention is shown in FIG. Figure 6 As shown in the figure, an instance page with a list page, a menu bar, and login / logout buttons is rendered according to the data protocol output by the backend related interface.

[0151] Figure 7 The front-end and back-end data transmission protocol specified in the embodiment of the present invention is as follows: Figure 7 As shown, through the http protocol, the relevant fields are agreed upon, and the front-end page rendering is driven entirely by the back-end data model.

[0152] The embodiment of the present invention converts the front-end development into the back-end python language, and abstracts the front-end components into easier-to-understand python objects. By encapsulating the front-end components and the front-end and back-end agreement, the front-end page is automatically rendered using data-driven. It does not completely emphasize low code, but more efficiently improves the efficiency of algorithm or back-end development, and is more adaptable to various flexible scenarios. In the traditional method, the rendering development of the front-end page requires the cooperation of the front-end and back-end, and joint debugging development and testing, which is not friendly to algorithm developers. The present invention realizes a pure algorithm, especially a pure python stack algorithm, which can efficiently develop the required front-end page.

[0153] In this embodiment, a front-end page development device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0154] This embodiment provides a front-end page development device, such as Figure 8 As shown, including:

[0155] The acquisition module 801 is used to acquire the business requirement parameters corresponding to the algorithm development task of the developer, and determine the initial data model based on the business requirement parameters; the initial data model is obtained by encapsulating the preset web framework and the preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating the preset page general interface, the preset page layout interface and the preset page component interface for generating the front-end page;

[0156] Processing module 802, used to obtain a target data model according to the custom interface parameters input by the developer based on the initial data model;

[0157] The generation module 803 is used to generate a front-end page corresponding to the business requirement parameters according to the target data model.

[0158] In some optional implementations, the acquisition module 801 is further used to:

[0159] Based on the business requirement parameters, determine multiple visualization targets corresponding to the algorithm development task; wherein the algorithm development task includes at least one of machine learning and deep learning;

[0160] Based on multiple visualization targets, an initial data model is obtained.

[0161] In some optional implementations, the acquisition module 801 is further used to:

[0162] Based on multiple visualization targets, a search is performed in a pre-built data model library with data model labels to obtain an initial data model; wherein the visualization target includes at least one of a network structure image, a feature map output result, a training loss curve, and a training accuracy curve.

[0163] In some optional implementations, the processing module 802 is further configured to:

[0164] By using the preset web framework of the integrated routing interface, the custom interface parameters input by the developer based on the initial data model are mapped to the preset interface parameter model to obtain the target interface parameter model;

[0165] The preset web framework of the integrated routing interface and the target interface parameter model are encapsulated to obtain the target data model.

[0166] In some optional implementations, the custom interface parameters include a page general interface, a page layout interface, and a page component interface;

[0167] The page general interface includes at least one of a menu bar interface, a login interface, and a logout interface;

[0168] The page layout interface includes at least one of a page URL address interface, a page configuration interface, and a text content interface;

[0169] The page component interface includes at least one of a page form interface, a form component interface, an icon interface, a pop-up window interface, a confirmation interface, and a jump interface.

[0170] In some optional implementations, the generating module 803 is further configured to:

[0171] Determine the front-end and back-end data transmission protocols;

[0172] Based on the front-end and back-end data transmission protocols, the target data model obtained by encapsulation based on the preset web framework is instantiated to obtain a web front-end page corresponding to the business demand parameters.

[0173] In some optional implementations, the preset web framework is a flask object constructed using flask, the preset interface parameter model is obtained by presetting the pydantic interface parameter model, and the preset web framework integrates the routing interface by utilizing the blueprint library in flask.

[0174] In some optional embodiments, the device is also used for:

[0175] Receive trigger requests from developers on the front-end page;

[0176] In response to the trigger request, adjust the display content of the front-end page.

[0177] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0178] The front-end page development device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.

[0179] The embodiment of the present invention also provides a computer device having the above Figure 8 The front-end page development device shown.

[0180] See also Fig. 9 , Fig. 9 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Fig. 9 As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Fig. 9 A processor 10 is taken as an example.

[0181] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.

[0182] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.

[0183] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0184] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.

[0185] The computer device also includes an input device 30 and an output device 40. The processor 10, the memory 20, the input device 30 and the output device 40 may be connected via a bus or other means. Fig. 9 The example of connecting through bus is taken in the following.

[0186] The input device 30 can receive input digital or character information, and generate key signal input related to the user settings and function control of the computer device, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator bar, one or more mouse buttons, a trackball, a joystick, etc. The output device 40 may include a display device, an auxiliary lighting device (e.g., an LED) and a tactile feedback device (e.g., a vibration motor), etc. The above-mentioned display device includes but is not limited to a liquid crystal display, a light emitting diode, a display and a plasma display. In some optional embodiments, the display device can be a touch screen.

[0187] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.

[0188] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of the computer program instruction in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.

[0189] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A front-end page development method, It is characterized in that The method comprises: Obtaining business requirement parameters corresponding to the algorithm development task of the developer, and determining an initial data model based on the business requirement parameters; the initial data model is obtained by encapsulating a preset web framework and a preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating a preset page general interface, a preset page layout interface, and a preset page component interface for generating a front-end page; Obtaining a target data model according to the custom interface parameters input by the developer based on the initial data model; A front-end page corresponding to the business requirement parameters is generated according to the target data model.

2. The method according to claim 1, It is characterized in that The step of obtaining the target data model according to the custom interface parameters input by the developer based on the initial data model includes: Using a preset web framework of an integrated routing interface, the custom interface parameters input by the developer based on the initial data model are mapped to the preset interface parameter model to obtain a target interface parameter model; The preset web framework of the integrated routing interface and the target interface parameter model are encapsulated to obtain a target data model.

3. The method according to claim 2, It is characterized in that The custom interface parameters include a page general interface, a page layout interface and a page component interface; The page universal interface includes at least one of a menu bar interface, a login interface, and a logout interface; The page layout interface includes at least one of a page URL address interface, a page configuration interface, and a text content interface; The page component interface includes at least one of a page form interface, a form component interface, an icon interface, a pop-up window interface, a confirmation interface and a jump interface.

4. The method according to claim 2 or 3, It is characterized in that The generating a front-end page corresponding to the business requirement parameters according to the target data model includes: Determine the front-end and back-end data transmission protocols; Based on the front-end and back-end data transmission protocol, a web front-end page corresponding to the business requirement parameters is obtained by instantiating a target data model obtained by encapsulating based on a preset web framework.

5. The method according to claim 4, It is characterized in that The preset web framework is a flask object constructed by using flask, the preset interface parameter model is obtained by presetting the pydantic interface parameter model, and the preset web framework integrates a routing interface by using the blueprint library in flask.

6. The method according to claim 1, It is characterized in that The determining the initial data model based on the business requirement parameters includes: Based on the business requirement parameters, determining multiple visualization targets corresponding to the algorithm development task; wherein the algorithm development task includes at least one of machine learning and deep learning; Based on the multiple visualization targets, an initial data model is obtained.

7. The method according to claim 6, It is characterized in that The initial data model is obtained based on the multiple visualization targets, including: Based on the multiple visualization targets, a search is performed in a pre-built data model library with data model labels to obtain an initial data model; wherein the visualization target includes at least one of a network structure image, a feature map output result, a training loss curve, and a training accuracy curve.

8. The method according to claim 1, It is characterized in that After generating a front-end page corresponding to the business requirement parameters according to the target data model, the method further includes: Receiving a trigger request from a developer on the front-end page; In response to the trigger request, the display content of the front-end page is adjusted.

9. A front-end page development device, It is characterized in that The device comprises: An acquisition module is used to acquire business requirement parameters corresponding to the algorithm development task of the developer, and determine an initial data model based on the business requirement parameters; the initial data model is obtained by encapsulating a preset web framework and a preset interface parameter model of the integrated routing interface, and the preset interface parameter model is obtained by encapsulating a preset page general interface, a preset page layout interface, and a preset page component interface for generating a front-end page; A processing module, used to obtain a target data model according to the custom interface parameters input by the developer based on the initial data model; A generation module is used to generate a front-end page corresponding to the business requirement parameters according to the target data model.

10. A computer device, It is characterized in that include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the front-end page development method according to any one of claims 1 to 8 by executing the computer instructions.

11. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the front-end page development method according to any one of claims 1 to 8.

12. A computer program product, It is characterized in that It includes computer instructions, and the computer instructions are used to enable a computer to execute the front-end page development method described in any one of claims 1 to 8.

Citation Information

Cited By

  • Communication control method and device

    CN121098659A

  • MTL and GCN coupled new pollutant risk prediction method and system

    CN121747753A