Model management method and apparatus, storage medium, and electronic device

CN115794773BActive Publication Date: 2026-09-18INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211510698.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-29
Publication Date
2026-09-18
Estimated Expiration
2042-11-29

AI Technical Summary

Technical Problem

[0006]本申请提供一种模型管理方法、装置、存储介质以及电子设备,以解决相关技术中多个用户在处理模型的时候,容易造成模型的管理混乱,并且在多人同时处理模型的时候出现冲突的问题

Benefits of technology

[0017]This application employs the following steps: obtaining request information sent by the user client and retrieving the model ID from the request information; searching for the model ID in the database, where the request information is used by the user client to request a model; if the model ID exists in the database, obtaining the initial model corresponding to the model ID, sending the initial model to the user client, and receiving the preset model and update strategy returned by the user client; updating the initial model in the database according to the update strategy and the preset model to obtain the target model; if the model ID does not exist in the database, sending first feedback information to the user client and obtaining the initial model and initial storage information sent by the user client based on the first feedback information; storing the initial model in the database according to the initial storage information, where the first feedback information indicates that the model ID does not exist in the database. This solves the problem in related technologies where multiple users processing models can easily lead to chaotic model management and conflicts when multiple people process models simultaneously. By determining the user's modifications to the model based on the initial model and update strategy after the user obtains the model, the update strategy ensures that the model content will not be modified in conflict when multiple people make changes to the same model, thereby improving model processing efficiency and strengthening model management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115794773B_ABST
    Figure CN115794773B_ABST
Patent Text Reader

Abstract

The application discloses a model management method and device, a storage medium and an electronic device. It relates to the field of artificial intelligence. The method comprises the following steps: obtaining request information sent by a user end, and obtaining a model ID from the request information and searching for the model ID in a database; if the model ID exists in the database, obtaining an initial model corresponding to the model ID, sending the initial model to the user end, receiving a preset model and an update strategy returned, updating the initial model in the database according to the update strategy and the preset model, and obtaining a target model; if the model ID does not exist in the database, sending first feedback information to the user end, and obtaining an initial model and initial storage information sent by the user end, and storing the initial model in the database. Through the application, the problem that multiple users easily cause model management confusion and conflict when processing models in related technologies is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence, and more specifically, to a model management method, apparatus, storage medium, and electronic device. Background Technology

[0002] An IoT platform is an integrated platform that combines capabilities such as device management, data processing, data visualization, and message subscription. To enable these capabilities, it is typically necessary to establish entity models within the platform, including devices, rule engines, and visualization dashboards.

[0003] However, these modeling tasks usually require the assistance of multiple engineers or business experts. To avoid modeling conflicts, when an engineer or expert is making adjustments or changes to the model, the model cannot be used by other users at the same time. They can only use or change it after the previous user has completed the changes, which affects the efficiency of modeling processing.

[0004] Furthermore, due to modifications made to the model by multiple people, the model becomes increasingly difficult to manage efficiently as the number of models grows, resulting in the inability to accurately retrieve the model when needed.

[0005] There is currently no effective solution to the problems that arise when multiple users process a model in related technologies, which can easily lead to chaotic model management and conflicts when multiple people process a model simultaneously. Summary of the Invention

[0006] This application provides a model management method, apparatus, storage medium, and electronic device to solve the problems in the related art where multiple users processing models can easily lead to chaotic model management and conflicts when multiple people process models simultaneously.

[0007] According to one aspect of this application, a model management method is provided. The method includes: obtaining request information sent by a user terminal, retrieving a model ID from the request information, and searching for the model ID in a database, wherein the request information is used by the user terminal to request a model; if the model ID exists in the database, obtaining the initial model corresponding to the model ID, sending the initial model to the user terminal, receiving a preset model and update strategy returned by the user terminal, updating the initial model in the database according to the update strategy and the preset model to obtain a target model; if the model ID does not exist in the database, sending first feedback information to the user terminal, obtaining the initial model and initial storage information sent by the user terminal based on the first feedback information, and storing the initial model in the database according to the initial storage information, wherein the first feedback information is used to indicate that the model ID does not exist in the database.

[0008] Optionally, the update strategy includes an overwrite strategy and a merge strategy. The initial model in the database is updated according to the update strategy and the preset model to obtain the target model. This includes: when the update strategy is an overwrite strategy, the initial model is moved to the historical data pool in the database to obtain a first historical model, and the preset model is determined as the target model; when the update strategy is a merge strategy, the initial model is backed up in the historical data pool to obtain a second historical model, and the preset model is combined with the initial model to obtain the target model.

[0009] Optionally, before updating the initial model in the database according to the update strategy and the preset model to obtain the target model, the method further includes: determining the number of user terminals to obtain a first number; if the first number is greater than a first preset number, determining the number of preset models to obtain a second number; if the second number is greater than the first preset number, issuing a first alarm message to multiple user terminals, wherein the first alarm message indicates that the initial model update has failed; and if the second number is less than or equal to the first preset number, performing the step of updating the initial model in the database according to the update strategy and the preset model to obtain the target model.

[0010] Optionally, after sending the initial model to the user terminal, the method further includes: determining whether the initial model in the database has changed; if the initial model in the database has changed, sending the changed initial model and second feedback information to the user terminal, wherein the second feedback information is used to indicate that the initial model has changed.

[0011] Optionally, before obtaining the request information sent by the user terminal, the method further includes: obtaining user information from the user terminal and determining whether the user information contains preset permission information, wherein the preset permission information indicates that the user terminal has the permission to access and modify the database; if the user information does not contain preset permission information, returning a second alarm message, wherein the second alarm message is used to indicate that the user terminal does not have preset permissions; if the user information contains preset permission information, performing the step of obtaining the request information sent by the user terminal.

[0012] Optionally, after obtaining the request information sent by the user, the method further includes: determining whether there is a historical version number of the model in the request information; if there is a historical version number in the request information, retrieving the historical model corresponding to the historical version number from the historical data pool in the database and sending it to the user, wherein the historical model in the historical data pool is associated with the historical version number of the model.

[0013] Optionally, after obtaining the request information sent by the user, the method further includes: determining whether there is a comparison request in the request information, wherein the comparison request represents the user requesting to obtain difference information between multiple models; if there is a comparison request in the request information, determining whether there are multiple historical version numbers in the comparison request; if there are multiple historical version numbers in the comparison request, obtaining the historical model corresponding to each historical version number from the historical data pool in the database to obtain multiple historical models, generating difference information between the multiple historical models to obtain first difference information, and sending the first difference information to the user, wherein the historical models in the historical data pool are associated with the historical version numbers of the models; if there is a single historical version number in the comparison request, obtaining the historical model corresponding to the historical version number, generating difference information between the historical model and the initial model to obtain second difference information, and sending the second difference information to the user.

[0014] According to another aspect of this application, a model management apparatus is provided. The apparatus includes: a first acquisition unit, configured to acquire request information sent by a user terminal, and obtain a model ID from the request information, and search for the model ID in a database, wherein the request information is used by the user terminal to request the acquisition of a model; an update unit, configured to, if the model ID exists in the database, acquire an initial model corresponding to the model ID, send the initial model to the user terminal, and receive a preset model and update strategy returned by the user terminal, and update the initial model in the database according to the update strategy and the preset model to obtain a target model; and a storage unit, configured to, if the model ID does not exist in the database, send first feedback information to the user terminal, acquire the initial model and initial storage information sent by the user terminal based on the first feedback information, and store the initial model in the database according to the initial storage information, wherein the first feedback information is used to indicate that the model ID does not exist in the database.

[0015] According to another aspect of the present invention, a computer storage medium is also provided for storing a program, wherein the program, when running, controls the device where the computer storage medium is located to execute a model management method.

[0016] According to another aspect of the present invention, an electronic device is also provided, comprising one or more processors and a memory; the memory stores computer-readable instructions, and the processor is used to execute the computer-readable instructions, wherein the computer-readable instructions execute a model management method when they are run.

[0017] This application employs the following steps: obtaining request information sent by the user client and retrieving the model ID from the request information; searching for the model ID in the database, where the request information is used by the user client to request a model; if the model ID exists in the database, obtaining the initial model corresponding to the model ID, sending the initial model to the user client, and receiving the preset model and update strategy returned by the user client; updating the initial model in the database according to the update strategy and the preset model to obtain the target model; if the model ID does not exist in the database, sending first feedback information to the user client and obtaining the initial model and initial storage information sent by the user client based on the first feedback information; storing the initial model in the database according to the initial storage information, where the first feedback information indicates that the model ID does not exist in the database. This solves the problem in related technologies where multiple users processing models can easily lead to chaotic model management and conflicts when multiple people process models simultaneously. By determining the user's modifications to the model based on the initial model and update strategy after the user obtains the model, the update strategy ensures that the model content will not be modified in conflict when multiple people make changes to the same model, thereby improving model processing efficiency and strengthening model management. Attached Figure Description

[0018] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:

[0019] Figure 1 This is a schematic diagram of a model management system provided according to an embodiment of this application;

[0020] Figure 2 This is a flowchart of a model management method provided according to an embodiment of this application;

[0021] Figure 3 This is a flowchart of an optional model management method provided according to an embodiment of this application;

[0022] Figure 4 This is a schematic diagram of a model management device provided according to an embodiment of this application;

[0023] Figure 5 This is a schematic diagram of an electronic device provided according to an embodiment of this application. Detailed Implementation

[0024] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.

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

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

[0027] It should be noted that all information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for display, data used for analysis, etc.) involved in this disclosure are information and data authorized by the user or fully authorized by all parties. For example, this system has an interface with relevant users or organizations. Before obtaining relevant information, it is necessary to send an acquisition request to the aforementioned user or organization through the interface, and obtain the relevant information after receiving consent information from the aforementioned user or organization.

[0028] It should be noted that the model management method, apparatus, storage medium and electronic device defined in this disclosure can be used in the field of artificial intelligence, or in any field other than artificial intelligence. The application fields of the model management method, apparatus, storage medium and electronic device defined in this disclosure are not limited.

[0029] In this embodiment, as Figure 1 As shown, the aforementioned model management method is executed using an optional model management system as the execution subject. The model management method includes at least a modeling user terminal 101, an IoT platform 102, and a Git repository 103.

[0030] According to embodiments of this application, a model management method is provided. Figure 2 This is a flowchart of a model management method according to an embodiment of this application. For example... Figure 2 As shown, the method includes the following steps:

[0031] Step S201: Obtain the request information sent by the user terminal, and retrieve the model ID from the request information. Search for the model ID in the database. The request information is used by the user terminal to request the model.

[0032] Specifically, when a user wants to obtain a model or modify a model, they can send a request message to the IoT platform through the user's terminal to obtain the model. At this time, the IoT platform will parse the request information, obtain the model ID of the model that the user wants to obtain from the request information, and search for the model ID in the database to determine whether the model corresponding to the model ID exists in the database.

[0033] It should be noted that the database can be a Git repository, which can store a large number of models, so that models can be retrieved from the Git repository when users request models from the IoT platform.

[0034] Step S202: If a model ID exists in the database, obtain the initial model corresponding to the model ID, send the initial model to the user terminal, and receive the preset model and update strategy returned by the user terminal. Update the initial model in the database according to the update strategy and the preset model to obtain the target model.

[0035] Specifically, if the model ID exists in the Git repository, the initial model corresponding to the model ID can be sent to the client. It should be noted that the initial model is the latest version of the model corresponding to the model ID in the Git database. For example, if a model ID corresponds to 3 models in the Git repository, namely versions 1.0, 1.1, and 2.0, then version 2.0 will be determined as the initial model, and versions 1.0 and 1.1 will be determined as the historical models under the model ID.

[0036] Furthermore, after sending the initial model to the user, a preset model and update strategy will be received from the user. The initial model can then be modified according to the preset model and update strategy to complete the update of the initial model in the Git repository.

[0037] For example, if the update strategy is replacement, the original initial model in the Git repository is used as the historical model, and the preset model is determined as the new initial model, thus completing the model update.

[0038] Step S203: If the model ID does not exist in the database, send first feedback information to the user terminal, and obtain the initial model and initial storage information sent by the user terminal based on the first feedback information. Store the initial model in the database according to the initial storage information. The first feedback information is used to indicate that the model ID does not exist in the database.

[0039] Specifically, if the model ID does not exist in the Git repository, the first feedback message needs to be sent to the user to inform them that the model does not exist in the Git repository. At this time, the user needs to build the model themselves and store it in the Git repository to obtain the first initial model corresponding to the model ID.

[0040] It should be noted that, along with the model sent by the user, the system also receives the initial storage information sent by the user. This initial storage information includes the repository name, branch name, and external entity ID in the Git repository. The system then stores the initial model under that model ID in the storage space corresponding to the repository name-branch name-external entity ID in the Git repository, thereby ensuring the standardization of model storage.

[0041] The model management method provided in this application embodiment obtains request information sent by the user terminal, retrieves the model ID from the request information, and searches for the model ID in the database. The request information is used by the user terminal to request a model. If the model ID exists in the database, the method obtains the initial model corresponding to the model ID, sends the initial model to the user terminal, and receives a preset model and update strategy returned by the user terminal. The method then updates the initial model in the database according to the update strategy and the preset model to obtain the target model. If the model ID does not exist in the database, the method sends first feedback information to the user terminal and obtains the initial model and initial storage information sent by the user terminal based on the first feedback information. The initial model is then stored in the database according to the initial storage information. The first feedback information indicates that the model ID does not exist in the database. This method solves the problem in related technologies where multiple users processing models can easily lead to chaotic model management and conflicts when multiple people process models simultaneously. By determining the user's modifications to the model based on the initial model and update strategy after the user obtains the model, the method ensures that the model content will not conflict when multiple people modify the same model, thereby improving model processing efficiency and strengthening model management.

[0042] Optionally, in the model management method provided in this application embodiment, the update strategy includes an overwrite strategy and a merge strategy. Updating the initial model in the database according to the update strategy and the preset model to obtain the target model includes: when the update strategy is an overwrite strategy, moving the initial model to the historical data pool in the database to obtain a first historical model, and determining the preset model as the target model; when the update strategy is a merge strategy, backing up the initial model in the historical data pool to obtain a second historical model, and combining the preset model with the initial model to obtain the target model.

[0043] Specifically, when the obtained update strategy is an overwrite strategy, the original initial model is identified as the historical model, and the received preset model is identified as the new initial model, thus achieving the effect of overwrite, i.e., replacement. When the obtained update strategy is a merge strategy, the preset model and the initial model need to be merged. That is, the preset model returned by the user can be a supplement to the initial model. After merging, the problems in the initial model can be corrected, thereby achieving the update of the initial model.

[0044] Optionally, in the model management method provided in this application embodiment, before updating the initial model in the database according to the update strategy and the preset model to obtain the target model, the method further includes: determining the number of user terminals to obtain a first number; if the first number is greater than a first preset number, determining the number of preset models to obtain a second number; if the second number is greater than the first preset number, issuing a first alarm message to multiple user terminals, wherein the first alarm message indicates that the initial model update has failed; and if the second number is less than or equal to the first preset number, performing the step of updating the initial model in the database according to the update strategy and the preset model to obtain the target model.

[0045] Specifically, the first preset quantity can be 1. That is, if the first quantity is greater than the first preset quantity, it means that the number of user terminals is greater than 1. Since the IoT platform can be accessed by multiple user terminals at the same time, there is a possibility that the IoT platform may receive preset models sent by two user terminals at the same time. When the above situation occurs, since two preset models and two update strategies are obtained at the same time, the initial model update operation cannot be performed. At this time, it is necessary to send the first alarm information to the two user terminals to inform the users using the two user terminals that the initial model cannot be updated at the moment and need to retry, thereby preventing the initial model from becoming abnormal due to multiple user terminals sending change information at the same time.

[0046] Optionally, in the model management method provided in this application embodiment, after sending the initial model to the user terminal, the method further includes: determining whether the initial model in the database has changed; if the initial model in the database has changed, sending the changed initial model and second feedback information to the user terminal, wherein the second feedback information is used to indicate that the initial model has changed.

[0047] Specifically, after the initial model is sent to user terminal 1, if the IoT platform receives preset models and update strategies from other user terminals, the initial model will change. In order to prevent the preset model sent by user terminal 1 from overwriting or merging with the updated initial model, it is necessary to promptly send a second feedback message to user terminal 1 to inform it that the initial model has changed, and send the changed initial model to that user terminal. This allows the user terminal to adjust the preset models created in the user terminal in a timely manner, thereby ensuring that each model is free of anomalies.

[0048] Optionally, in the model management method provided in this application embodiment, before obtaining the request information sent by the user terminal, the method further includes: obtaining user information from the user terminal and determining whether the user information contains preset permission information, wherein the preset permission information indicates that the user terminal has the permission to access and modify the database; if the user information does not contain preset permission information, returning second alarm information, wherein the second alarm information is used to indicate that the user terminal does not have preset permissions; if the user information contains preset permission information, performing the step of obtaining the request information sent by the user terminal.

[0049] Specifically, when a user updates or acquires a model, they need to log in on their client and send their information to the IoT platform. This determines whether the user has the necessary permissions on the IoT platform. If the user lacks permissions, an alert is sent to them, prompting them to request and acquire those permissions. Only after obtaining the required permissions can the user send requests through their client.

[0050] Optionally, in the model management method provided in this application embodiment, after obtaining the request information sent by the user terminal, the method further includes: determining whether there is a historical version number of the model in the request information; if there is a historical version number in the request information, obtaining the historical model corresponding to the historical version number from the historical data pool in the database and sending it to the user terminal, wherein the historical model in the historical data pool is associated with the historical version number of the model.

[0051] Specifically, if a historical version number exists in the request information, the historical model corresponding to the historical version number can be retrieved from the historical data pool corresponding to the model ID in the Git repository, and the historical model can be returned to the user, so that the user can obtain the historical model.

[0052] For example, the system retrieves the version number to be restored from the request information, calls the Git API based on the repository information, Git branch, and version number to obtain the entity storage information, i.e., the historical model, and sends the historical model to the user end, thereby completing the retrieval of the historical model on the user end.

[0053] Optionally, in the model management method provided in this application embodiment, after obtaining the request information sent by the user terminal, the method further includes: determining whether there is a comparison request in the request information, wherein the comparison request represents the user terminal requesting to obtain difference information between multiple models; if there is a comparison request in the request information, determining whether there are multiple historical version numbers in the comparison request; if there are multiple historical version numbers in the comparison request, obtaining the historical model corresponding to each historical version number from the historical data pool in the database to obtain multiple historical models, and generating difference information between the multiple historical models to obtain first difference information, and sending the first difference information to the user terminal, wherein the historical models in the historical data pool are associated with the historical version numbers of the models; if there is a single historical version number in the comparison request, obtaining the historical model corresponding to the historical version number, and generating difference information between the historical model and the initial model to obtain second difference information, and sending the second difference information to the user terminal.

[0054] Specifically, if the request information contains comparison information, it is necessary to determine whether the comparison information is comparing two historical versions of historical models or comparing the current initial model and historical models. If the comparison information is comparing two historical versions of historical models, it is necessary to obtain the historical version number of the model to be compared, and after determining the model to be compared based on the historical version number, generate the difference information between the models and return the difference information to the user.

[0055] Similarly, when the comparison information needs to be compared between the current initial model and the historical model, the comparison information only contains the historical version number of the historical model. In this case, the historical version number of the model to be compared is obtained according to the above method. After determining the model to be compared based on the historical version number, the difference information between the model and the current initial model is generated and returned to the user. Thus, the change information of each model change can be determined through the difference information.

[0056] Figure 3 This is a flowchart of an optional model management method provided according to an embodiment of this application, such as... Figure 3As shown, after receiving a request from a user, the IoT platform needs to send the request to a Git repository. The Git repository then determines whether the desired model exists in the repository based on the request. If it exists, it returns the initial model to the user; otherwise, it sends a first feedback message to the user informing them that the corresponding initial model does not exist. After receiving the content returned by the Git repository, the IoT platform displays it. The user then generates a preset model and update strategy, or generates an initial model and initial storage information, based on the returned information. This generated content is then sent to the Git repository. The Git repository updates the initial model according to the update strategy or stores the initial model according to the initial storage information, and executes a merge or overwrite strategy based on the update strategy, thereby changing or storing the initial model.

[0057] If a historical version number exists in the request information, the historical model corresponding to the historical version number can be retrieved from the historical data pool corresponding to the model ID in the Git repository, and the historical model can be returned to the user, so that the user can obtain the historical model.

[0058] When the request includes comparison information, it's necessary to determine whether the comparison involves two historical models from different versions or the current initial model and a historical model. If the comparison involves two historical models from different versions, the historical version number of the model to be compared needs to be obtained. After determining the model to be compared based on the historical version number, the difference information between the models is generated and returned to the user. This improves model processing efficiency while enhancing model management.

[0059] It should be noted that the steps shown in the flowchart in 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 may be executed in a different order than that shown here.

[0060] This application also provides a model management device. It should be noted that the model management device of this application can be used to execute the model management method provided in this application. The model management device provided in this application is described below.

[0061] Figure 4 This is a schematic diagram of a model management device provided according to an embodiment of this application. For example... Figure 4 As shown, the device includes: a first acquisition unit 41, an update unit 42, and a storage unit 43.

[0062] The first acquisition unit 41 is used to acquire request information sent by the user terminal, obtain the model ID from the request information, and search for the model ID in the database, wherein the request information is used by the user terminal to request to acquire the model.

[0063] The update unit 42 is configured to, when the model ID exists in the database, obtain the initial model corresponding to the model ID, send the initial model to the user terminal, receive the preset model and update strategy returned by the user terminal, and update the initial model in the database according to the update strategy and the preset model to obtain the target model.

[0064] Storage unit 43 is configured to send first feedback information to the user terminal when the model ID does not exist in the database, and to obtain the initial model and initial storage information sent by the user terminal based on the first feedback information, and to store the initial model in the database according to the initial storage information, wherein the first feedback information is used to indicate that the model ID does not exist in the database.

[0065] The model management device provided in this application embodiment includes a first acquisition unit 41, used to acquire request information sent by a user terminal, obtain a model ID from the request information, and search for the model ID in a database. The request information is used by the user terminal to request a model. An update unit 42, if the model ID exists in the database, acquires the initial model corresponding to the model ID, sends the initial model to the user terminal, receives a preset model and update strategy returned by the user terminal, and updates the initial model in the database according to the update strategy and the preset model to obtain the target model. A storage unit 43, if the model ID does not exist in the database, sends first feedback information to the user terminal, acquires the initial model and initial storage information sent by the user terminal based on the first feedback information, and stores the initial model in the database according to the initial storage information. The first feedback information indicates that the model ID does not exist in the database. This solves the problems in related technologies where multiple users processing models can easily lead to chaotic model management and conflicts when multiple people process models simultaneously. After a user acquires a model, the system determines the changes the user makes to the model based on the initial model feedback and the update strategy. This ensures that when multiple people modify the same model, the update strategy will prevent conflicting modifications to the model content, thereby improving model processing efficiency and strengthening model management.

[0066] Optionally, in the model management device provided in this application embodiment, the update strategy includes an overwrite strategy and a merge strategy. The update unit 42 includes: a determination module, used to move the initial model to the historical data pool in the database to obtain a first historical model when the update strategy is an overwrite strategy, and determine the preset model as the target model; and a combination module, used to back up the initial model in the historical data pool to obtain a second historical model when the update strategy is a merge strategy, and combine the preset model with the initial model to obtain the target model.

[0067] Optionally, in the model management device provided in the embodiments of this application, the device further includes: a first determining unit, configured to determine the number of user terminals to obtain a first number; a second determining unit, configured to determine the number of preset models to obtain a second number when the first number is greater than a first preset number; a first alarm unit, configured to send a first alarm message to multiple user terminals when the second number is greater than the first preset number, wherein the first alarm message indicates that the initial model update has failed; and a first execution unit, configured to execute the step of updating the initial model in the database according to the update strategy and the preset model to obtain the target model when the second number is less than or equal to the first preset number.

[0068] Optionally, in the model management device provided in the embodiments of this application, the device further includes: a first judgment unit, used to judge whether the initial model in the database has changed; and a first sending unit, used to send the changed initial model and second feedback information to the user terminal when the initial model in the database has changed, wherein the second feedback information is used to indicate that the initial model has changed.

[0069] Optionally, in the model management device provided in this application embodiment, the device further includes: a second acquisition unit, configured to acquire user information from a user terminal and determine whether the user information contains preset permission information, wherein the preset permission information indicates that the user terminal has the permission to access and modify the database; a second alarm unit, configured to return second alarm information if the user information does not contain preset permission information, wherein the second alarm information is used to indicate that the user terminal does not have preset permissions; and a second execution unit, configured to execute the step of acquiring request information sent by the user terminal if the user information contains preset permission information.

[0070] Optionally, in the model management device provided in the embodiments of this application, the device further includes: a second judgment unit, used to judge whether there is a historical version number of the model in the request information; and a second sending unit, used to obtain the historical model corresponding to the historical version number from the historical data pool in the database and send it to the user terminal when there is a historical version number in the request information, wherein the historical model in the historical data pool is associated with the historical version number of the model.

[0071] Optionally, in the model management device provided in this application embodiment, the device further includes: a third judgment unit, used to judge whether there is a comparison request in the request information, wherein the comparison request represents a user request to obtain difference information between multiple models; a fourth judgment unit, used to judge whether there are multiple historical version numbers in the comparison request if there is a comparison request in the request information; a third acquisition unit, used to acquire the historical model corresponding to each historical version number from the historical data pool in the database when there are multiple historical version numbers in the comparison request, to obtain multiple historical models, and to generate difference information between the multiple historical models, to obtain first difference information, and to send the first difference information to the user, wherein the historical models in the historical data pool are associated with the historical version numbers of the models; and a fourth acquisition unit, used to acquire the historical model corresponding to the historical version number when there is a single historical version number in the comparison request, and to generate difference information between the historical model and the initial model, to obtain second difference information, and to send the second difference information to the user.

[0072] The aforementioned model management device includes a processor and a memory. The first acquisition unit 41, update unit 42, storage unit 43, etc., are all stored in the memory as program units, and the processor executes the aforementioned program units stored in the memory to realize the corresponding functions.

[0073] The processor contains a kernel, which retrieves the corresponding program units from memory. One or more kernels can be configured. By adjusting kernel parameters, the problems of model management chaos and conflicts that can easily occur when multiple users are processing models simultaneously in related technologies can be resolved.

[0074] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0075] This invention provides a computer-readable storage medium storing a program thereon, which, when executed by a processor, implements the model management method.

[0076] This invention provides a processor for running a program, wherein the program executes the model management method during runtime.

[0077] like Figure 5As shown, this embodiment of the invention provides an electronic device 50, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, it performs the following steps: obtaining request information sent by a user terminal, retrieving a model ID from the request information, and searching for the model ID in a database. The request information is used by the user terminal to request a model. If the model ID exists in the database, obtaining the initial model corresponding to the model ID, sending the initial model to the user terminal, and receiving a preset model and update strategy returned by the user terminal. Updating the initial model in the database according to the update strategy and the preset model to obtain the target model. If the model ID does not exist in the database, sending first feedback information to the user terminal, and obtaining the initial model and initial storage information sent by the user terminal based on the first feedback information. Storing the initial model in the database according to the initial storage information. The first feedback information indicates that the model ID does not exist in the database. The device in this document can be a server, PC, PAD, mobile phone, etc.

[0078] This application also provides a computer program product, which, when executed on a data processing device, is suitable for executing an initialization program with the following method steps: obtaining request information sent by a user terminal, obtaining a model ID from the request information, and searching for the model ID in a database, wherein the request information is used by the user terminal to request a model; if the model ID exists in the database, obtaining the initial model corresponding to the model ID, sending the initial model to the user terminal, and receiving a preset model and update strategy returned by the user terminal, updating the initial model in the database according to the update strategy and the preset model to obtain the target model; if the model ID does not exist in the database, sending first feedback information to the user terminal, obtaining the initial model and initial storage information sent by the user terminal based on the first feedback information, and storing the initial model in the database according to the initial storage information, wherein the first feedback information is used to indicate that the model ID does not exist in the database.

[0079] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0080] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0081] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0082] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0083] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0084] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0085] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0086] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0087] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.

Claims

1. A model management method, characterized in that, include: Obtain request information sent by the user client, retrieve the model ID from the request information, and search for the model ID in the database. The request information is used by the user client to request the model. If the model ID exists in the database, obtain the initial model corresponding to the model ID, send the initial model to the user terminal, and receive the preset model and update strategy returned by the user terminal. Update the initial model in the database according to the update strategy and the preset model to obtain the target model. The initial model is the latest version of the model corresponding to the model ID in the database. If the model ID does not exist in the database, a first feedback message is sent to the user terminal, and the initial model and initial storage information sent by the user terminal based on the first feedback message are obtained. The initial model is then stored in the database according to the initial storage information, wherein the first feedback message is used to indicate that the model ID does not exist in the database. The system determines whether a comparison request exists in the request information, wherein the comparison request represents the user's request to obtain difference information between multiple models; if the comparison request exists in the request information, it determines whether multiple historical version numbers exist in the comparison request; if multiple historical version numbers exist in the comparison request, it retrieves the historical model corresponding to each historical version number from the historical data pool in the database to obtain multiple historical models, and generates difference information between the multiple historical models to obtain first difference information, and sends the first difference information to the user, wherein the historical models in the historical data pool are associated with the historical version numbers of the models; if a single historical version number exists in the comparison request, it retrieves the historical model corresponding to the historical version number, and generates difference information between the historical model and the initial model to obtain second difference information, and sends the second difference information to the user.

2. The method according to claim 1, characterized in that, The update strategy includes an overwrite strategy and a merge strategy. Based on the update strategy and the preset model, the initial model in the database is updated to obtain the target model, including: When the update strategy is the coverage strategy, the initial model is moved to the historical data pool in the database to obtain the first historical model, and the preset model is determined as the target model; When the update strategy is the merging strategy, the initial model is backed up in the historical data pool to obtain a second historical model, and the preset model is combined with the initial model to obtain the target model.

3. The method according to claim 1, characterized in that, Before updating the initial model in the database according to the update strategy and the preset model to obtain the target model, the method further includes: The number of user terminals is determined to obtain a first number; If the first quantity is greater than the first preset quantity, the number of preset models is determined to obtain the second quantity; If the second quantity is greater than the first preset quantity, a first alarm message is sent to multiple user terminals, wherein the first alarm message indicates that the initial model update has failed; If the second quantity is less than or equal to the first preset quantity, the step of updating the initial model in the database according to the update strategy and the preset model to obtain the target model is executed.

4. The method according to claim 1, characterized in that, After sending the initial model to the user terminal, the method further includes: Determine whether the initial model in the database has been changed; If the initial model in the database changes, the changed initial model and second feedback information are sent to the user terminal, wherein the second feedback information is used to indicate that the initial model has changed.

5. The method according to claim 1, characterized in that, Before obtaining the request information sent by the user, the method further includes: Obtain user information from the user terminal and determine whether the user information contains preset permission information, wherein the preset permission information indicates that the user terminal has the permission to access and modify the database; If the preset permission information is not present in the user information, a second alarm message is returned, wherein the second alarm message is used to indicate that the user does not have the preset permission; If the preset permission information is present in the user information, the step of obtaining the request information sent by the user terminal is executed.

6. The method according to claim 1, characterized in that, After obtaining the request information sent by the user, the method further includes: Determine whether the request information contains a historical version number of the model; If the historical version number exists in the request information, the historical model corresponding to the historical version number is obtained from the historical data pool in the database and sent to the user terminal, wherein the historical model in the historical data pool is associated with the historical version number of the model.

7. A model management device, characterized in that, include: The first acquisition unit is used to acquire request information sent by the user terminal, obtain the model ID from the request information, and search for the model ID in the database, wherein the request information is used by the user terminal to request to acquire the model; An update unit is configured to, when the model ID exists in the database, obtain the initial model corresponding to the model ID, send the initial model to the user terminal, receive the preset model and update strategy returned by the user terminal, update the initial model in the database according to the update strategy and the preset model, and obtain the target model, wherein the initial model is the latest version of the model corresponding to the model ID in the database; A storage unit is configured to send first feedback information to the user terminal when the model ID does not exist in the database, and to obtain the initial model and initial storage information sent by the user terminal based on the first feedback information, and to store the initial model in the database according to the initial storage information, wherein the first feedback information is used to indicate that the model ID does not exist in the database; The third judgment unit is used to determine whether there is a comparison request in the request information, wherein the comparison request represents the user terminal requesting to obtain difference information between multiple models; the fourth judgment unit is used to determine whether there are multiple historical version numbers in the comparison request if the comparison request exists in the request information; the third acquisition unit is used to acquire the historical model corresponding to each historical version number from the historical data pool in the database if the comparison request contains the multiple historical version numbers, thereby obtaining multiple historical models, generating difference information between the multiple historical models, obtaining first difference information, and sending the first difference information to the user terminal, wherein the historical models in the historical data pool are associated with the historical version numbers of the models; the fourth acquisition unit is used to acquire the historical model corresponding to the historical version number if the comparison request contains a single historical version number, generating difference information between the historical model and the initial model, obtaining second difference information, and sending the second difference information to the user terminal.

8. A computer storage medium, characterized in that, The computer storage medium is used to store a program, wherein the program, when running, controls the device where the computer storage medium is located to execute the model management method according to any one of claims 1 to 6.

9. An electronic device, characterized in that, It includes one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors cause the one or more processors to implement the model management method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Model deployment method and device based on Tensorflow Serving and medium

    CN112286535A

  • Micro-application development system and method based on knowledge and data driving

    CN114661289A