Model hot update processing method and its device, equipment, medium and product

By configured the model version of the search service in the vector search service, the service pause and user experience problem when updating the neural network model to update the neural network model achieved the effect of reasoning historical data and rapidly being used during the update process.

CN114327546BActive Publication Date: 2025-01-28GUANGZHOU HUADUO NETWORK TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111602307.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-24
Publication Date
2025-01-28
Estimated Expiration
2041-12-24

AI Technical Summary

Technical Problem

When the prior art updates the neural network model in business services, the service needs to be suspended, resulting in users being unable to use it, and the new model cannot provide complete services, affecting the user experience.

Method used

Through the construction of vector search service, the search field search field is pre -configured in advance, and in the process of updating the neural network model, input historical business data into the new model for reasoning, and store the new vector value to the vector search service to ensure that the service is in After the update, it can be quickly put into use.

Benefits of technology

During the model update process, the new model reasoning historical data is driven, enabling business services to be quickly put into use after completing the model update, and solving the problem of lack of data required by the model reasoning that affects the user's use.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114327546B_ABST
    Figure CN114327546B_ABST
Patent Text Reader

Abstract

The present application discloses a model hot update processing method and its device, equipment, medium, and product, the method comprising: responding to a new model deployment event acting on the current model service, obtaining the model version number of the new neural network model; determining the model version search field corresponding to the model version number according to a preset search field conversion rule; maintaining the operation of the old neural network model in the current model service, continuously inputting historical business data into the new neural network model, and storing each new vector value output by the new neural network model in the model version search field of the vector search service; after storing the new vector values ​​corresponding to all historical business data output by the new neural network model in the vector search service, the old neural network model is offline, and the new neural network model is online to provide reasoning function for the current model service. The present application realizes the vector data refresh of the new model during the hot update process of the model, so that the relevant online services can be put into use quickly.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of neural network model updating, and in particular to a model hot update processing method, and also to corresponding devices, equipment, non-volatile storage media and computer program products of the method. Background Art

[0002] There are various types of business services built based on neural network models in existing Internet platforms. For example, business services used to provide users with intelligent customer service generally include model services corresponding to neural network models used for semantic reasoning, and business services used to provide users with product classification generally include model services corresponding to neural network models used for product classification. In addition, with the development of neural network technology, each platform will also update the neural network models that provide reasoning functions in its business services to improve the business processing efficiency of business services built based on neural network models and optimize the user experience.

[0003] However, when existing platforms update neural network models in business services, they often need to suspend the operation of the old version of the neural network model in the business service, wait for the new version of the neural network model to be deployed, and then launch the new version of the neural network model to provide reasoning services for the business service. During this process, since the business service needs to be offline to wait for the deployment of the new model, the users of the platform will not be able to use the business service.

[0004] Secondly, although the existing platform also uses hot update to update the neural network model in the business service, after hot updating the new version of the neural network model for the business service, the new version of the neural network model does not have the corresponding new feature vector, so after the business service updates the model, it cannot provide complete services to the platform users, affecting the user experience.

[0005] In view of the problems existing in updating neural network models in existing business services, the applicant has made corresponding explorations in order to solve this problem. Summary of the invention

[0006] The purpose of this application is to provide a model hot update processing method to meet user needs, and also relates to corresponding devices, equipment, non-volatile storage media and computer program products of the method.

[0007] In order to achieve the purpose of this application, the following technical solutions are adopted:

[0008] A model hot update processing method proposed for the purpose of this application includes the following steps:

[0009] In response to the new model deployment event acting on the current model service, obtain the model version number corresponding to the newly deployed new neural network model;

[0010] According to a preset search field conversion rule, a model version search field corresponding to the model version number is determined, and the model version search field is used to search for a vector value corresponding to the corresponding model version number from a vector search service;

[0011] Maintaining the operation of the old neural network model in the current model service to generate a vector value of the corresponding model version number for the input business data and storing it in the vector search service, continuously inputting the historical business data into the new neural network model, and storing each new vector value output by the new neural network model in the model version search field of the vector search service;

[0012] After storing the new vector values ​​corresponding to all the historical business data output by the new neural network model in the vector search service, the old neural network model is taken offline, and the new neural network model is put online to provide reasoning function for the current model service.

[0013] In a further embodiment, the method comprises the following preparatory steps:

[0014] In response to a version setting event acting on the vector search service, determining a model version number set by the version setting event;

[0015] Generate model version search fields whose number is the same as the number represented by the model version number, each of which represents the model version number corresponding to it;

[0016] The model version search fields are stored in the vector search service.

[0017] In a further embodiment, the method comprises the following post-processing steps:

[0018] In response to a model version rollback instruction acting on the current model service, determine the old model version number contained in the instruction;

[0019] According to the old model version number, obtaining the old neural network model retained in the model storage space;

[0020] The new neural network model currently online in the current model service is rolled back to the old neural network model to drive the current model service to search for the old vector value retained in the vector search service according to the model version search field corresponding to the old model version number for service.

[0021] In a further embodiment, the step of determining the model version search field corresponding to the model version number according to a preset search field conversion rule includes:

[0022] Determining the number of model versions existing in the vector search service according to the type of the model version search field stored in the vector search service;

[0023] Calculate the remainder of the model version number of the new neural network model divided by the number of model versions;

[0024] A model version search field whose model version representation is the remainder in the vector search service is queried, and the model version search field is matched with the model version number.

[0025] In a further embodiment, the step of continuously inputting the historical business data into the new neural network model respectively, and storing the new vector values ​​output by the new neural network model respectively into the model version search field of the vector search service accordingly, includes:

[0026] Acquire the historical business data from a business database, where the business database stores business data related to its business, including intelligent customer service business data or e-commerce product business data;

[0027] Inputting the historical business data into the new neural network model to drive the new neural network model to infer new vector values ​​corresponding to the historical business data;

[0028] The new vector value output by the new neural network model is obtained, and the new vector value is stored in the storage space corresponding to the model version search field in the vector search service.

[0029] In a further embodiment, the step of taking the old neural network model offline and bringing the new neural network model online to provide reasoning function for the current model service includes:

[0030] Monitoring the calculation events of all historical business data respectively calculated by the new neural network model, and after monitoring that the new vector values ​​corresponding to all the historical business data output by the new neural network model are stored in the vector search service, triggering the online instruction acting on the new neural network model;

[0031] In response to the online instruction, the operation of the old neural network model in the current model service is stopped, and the new neural network model is switched to an online state to provide reasoning function for the current model service.

[0032] A model thermal update processing device proposed for the purpose of this application includes:

[0033] A model version number acquisition module is used to respond to a new model deployment event acting on the current model service and obtain the model version number corresponding to the newly deployed new neural network model;

[0034] A search field determination module, used to determine the model version search field corresponding to the model version number according to a preset search field conversion rule, wherein the model version search field is used to search for a vector value corresponding to the corresponding model version number from a vector search service;

[0035] A new vector value storage module is used to maintain the operation of the old neural network model in the current model service so as to generate a vector value of a corresponding model version number for the input business data and store it in the vector search service, continuously input the historical business data into the new neural network model, and store each new vector value output by the new neural network model in the model version search field of the vector search service;

[0036] The new model online module is used to store the new vector values ​​corresponding to all the historical business data output by the new neural network model to the vector search service, then take the old neural network model offline and put the new neural network model online to provide reasoning function for the current model service.

[0037] In a further embodiment, the search field determination module includes:

[0038] A model version number determination submodule, used to determine the number of model versions existing in the vector search service according to the type of the model version search field stored in the vector search service;

[0039] A remainder calculation submodule, used to calculate the remainder of the model version number of the new neural network model divided by the number of model versions;

[0040] The model version search field determination submodule is used to query the model version search field whose model version representation is the remainder in the vector search service, and correspond the model version search field to the model version number.

[0041] In a further embodiment, the new vector value storage module includes:

[0042] A historical business data acquisition submodule is used to acquire the historical business data from a business database, where the business database stores business data associated with its business, including intelligent customer service business data or e-commerce product business data;

[0043] A historical business data inference submodule, used for inputting the historical business data into the new neural network model, and driving the new neural network model to infer new vector values ​​corresponding to the historical business data;

[0044] The new vector value storage submodule is used to obtain the new vector value output by the new neural network model, and store the new vector value in the storage space corresponding to the model version search field in the vector search service.

[0045] In a further embodiment, the new model online module includes:

[0046] A calculation event monitoring submodule is used to monitor the calculation events acting on the new neural network model to respectively calculate all historical business data, and when the new vector values ​​corresponding to all the historical business data output by the new neural network model are monitored to be stored in the vector search service, an online instruction acting on the new neural network model is triggered;

[0047] The online instruction response submodule is used to respond to the online instruction, stop the operation of the old neural network model in the current model service, and switch the new neural network model to the online state to provide reasoning function for the current model service.

[0048] In order to solve the above technical problems, an embodiment of the present application also provides a computer device, including a memory and a processor, wherein the memory stores computer-readable instructions, and when the computer-readable instructions are executed by the processor, the processor executes the steps of the above-mentioned model hot update processing method.

[0049] In order to solve the above technical problems, an embodiment of the present application also provides a storage medium storing computer-readable instructions. When the computer-readable instructions are executed by one or more processors, the one or more processors execute the steps of the above-mentioned model hot update processing method.

[0050] In order to solve the above technical problems, an embodiment of the present application also provides a computer program product, including a computer program and computer instructions. When the computer program and computer instructions are executed by a processor, the processor executes the steps of the above-mentioned model hot update processing method.

[0051] Compared with the prior art, the advantages of this application are as follows:

[0052] The present application constructs a vector search service and pre-configures the model version search field required in the model service in the vector search service, so that in the process of updating the model for the business service, historical business data can be simultaneously input into the new model for inference, and the new vectors output by the new model are stored in the storage space corresponding to the model version search field corresponding to the new model in the vector search service. After the business service completes the model update, it can obtain the new vectors it needs from the vector search service to provide services to platform users. Compared with the existing model update, it is possible to simultaneously drive the new model to infer historical data during the model update process, so that the business service can be quickly put into use after the model update is completed, thereby solving the problem of users' use of business services being affected by the lack of data required for model inference.

[0053] Secondly, when this application deploys a new model for the model service in the business model, there is no need to take offline the old model that is providing reasoning function in the model service. Wait for the new model to store the new vector it outputs to the vector search service, and then replace the old and new models to achieve hot update of the neural network model in the business model. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0055] Figure 1 A schematic diagram of a typical network deployment architecture related to implementing the technical solution of this application;

[0056] Figure 2 A flowchart of a typical embodiment of the model hot update processing method of the present application;

[0057] Figure 3 A flowchart diagram of an implementation method of pre-setting the model version search field of each version in the vector search service in this application, which is a pre-step of this method;

[0058] Figure 4 A flowchart diagram of the implementation method of rolling back the old version of the neural network model of the current model service in this application, which is a post-step of this method;

[0059] Figure 5 A flowchart diagram of a specific implementation method of the present application for determining a model version search field of a new neural network model;

[0060] Figure 6 A flowchart diagram of a specific implementation method of hot updating of old and new versions of neural network models of the current model service in this application;

[0061] Figure 7A flowchart of a specific implementation method of launching a new neural network model for the current model service in this application;

[0062] Figure 8 It is a principle block diagram of a typical embodiment of the model hot update processing device of the present application;

[0063] Fig. 9 This is a basic structural block diagram of a computer device according to an embodiment of the present application. DETAILED DESCRIPTION

[0064] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be interpreted as limiting the present application.

[0065] It will be understood by those skilled in the art that, unless expressly stated, the singular forms "one", "said", and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. It should be understood that when we refer to an element as being "connected" or "coupled" to another element, it may be directly connected or coupled to the other element, or there may be an intermediate element. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The term "and / or" used herein includes all or any unit and all combinations of one or more associated listed items.

[0066] It will be understood by those skilled in the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as generally understood by those skilled in the art to which this application belongs. It should also be understood that terms such as those defined in common dictionaries should be understood to have meanings consistent with the meanings in the context of the prior art, and will not be interpreted with idealized or overly formal meanings unless specifically defined as here.

[0067] It will be understood by those skilled in the art that the "client", "terminal" and "terminal device" used herein include both devices with wireless signal receivers, which are devices with only wireless signal receivers without transmission capabilities, and devices with receiving and transmitting hardware, which are devices with receiving and transmitting hardware capable of two-way communication on a two-way communication link. Such devices may include: cellular or other communication devices such as personal computers, tablet computers, which have single-line displays or multi-line displays or cellular or other communication devices without multi-line displays; PCS (Personal Communications Service, personal communication system), which can combine voice, data processing, fax and / or data communication capabilities; PDA (Personal Digital Assistant, personal digital assistant), which may include a radio frequency receiver, pager, Internet / intranet access, web browser, notepad, calendar and / or GPS (Global Positioning System, global positioning system) receiver; traditional laptop and / or palmtop computers or other devices, which have and / or include radio frequency receivers. The "client", "terminal" and "terminal device" used herein may be portable, transportable, installed in a vehicle (air, sea and / or land), or suitable and / or configured to run locally, and / or in a distributed form, at any other location on the earth and / or in space. The "client", "terminal" and "terminal device" used herein may also be a communication terminal, an Internet terminal, a music / video playback terminal, such as a PDA, a MID (Mobile Internet Device) and / or a mobile phone with a music / video playback function, or a smart TV, a set-top box and other devices.

[0068] The hardware referred to by the names such as "server", "client", and "working node" in this application is essentially an electronic device with capabilities equivalent to those of a personal computer. It is a hardware device that has the necessary components revealed by the von Neumann principle, such as a central processing unit (including an arithmetic unit and a controller), a memory, an input device, and an output device. Computer programs are stored in its memory, and the central processing unit calls the program stored in the external memory into the internal memory for execution, executes the instructions in the program, and interacts with the input and output devices to complete specific functions.

[0069] It should be pointed out that the concept of "server" referred to in this application can also be extended to the case of server clusters. According to the network deployment principle understood by those skilled in the art, the servers should be logically divided. In physical space, these servers can be independent of each other but can be called through interfaces, or integrated into a physical computer or a set of computer clusters. Those skilled in the art should understand this flexibility, and should not use it to restrict the implementation of the network deployment method of this application.

[0070] See also Figure 1 , the hardware foundation required for the implementation of the relevant technical solutions of this application can be deployed according to the architecture shown in the figure. The server 80 referred to in this application is deployed in the cloud. As a business server, it can be responsible for further connecting relevant data servers and other servers that provide relevant support, etc., so as to form a logically related service cluster to provide services for relevant terminal devices such as the smartphone 81 and personal computer 82 shown in the figure or a third-party server (not shown). The smartphone and personal computer can access the Internet through a well-known network access method and establish a data communication link with the server 80 in the cloud to run terminal applications related to the services provided by the server.

[0071] For the server, the application is usually constructed as a service process, opening the corresponding program interface for remote calls by applications running on various terminal devices. The relevant technical solutions suitable for running on the server in this application can be implemented in the server in this way.

[0072] The application described herein refers to an application running on a server or terminal device. This application implements the relevant technical solutions of the present application in a programming manner. Its program code can be stored in a non-volatile storage medium recognizable by a computer in the form of computer executable instructions, and can be loaded into the memory by the central processing unit for execution. The relevant device of the present application is constructed by the operation of the application on the computer.

[0073] For the server, the application is usually constructed as a service process, opening the corresponding program interface for remote calls by applications running on various terminal devices. The relevant technical solutions suitable for running on the server in this application can be implemented in the server in this way.

[0074] Those skilled in the art should be aware that, although the various methods of the present application are described based on the same concept and thus present commonality to each other, unless otherwise specified, these methods can be independently executed. Similarly, for each embodiment disclosed in the present application, they are all proposed based on the same inventive concept, therefore, concepts with the same expression, and concepts that are appropriately changed for convenience despite different expressions, should be understood as equivalent.

[0075] See also Figure 2 A model hot update processing method of the present application, in its typical embodiment, comprises the following steps:

[0076] Step S11, responding to the new model deployment event acting on the current model service, obtaining the model version number corresponding to the newly deployed new neural network model:

[0077] The server responds to the new model deployment event acting on the current model service and obtains the model version number corresponding to the new neural network model deployed on the current model service.

[0078] The current model service is generally associated with relevant business services in the current platform, so that the current model service provides neural network model reasoning services for the corresponding business services. For example, when the business service is an intelligent customer service service, the current model service can generally provide semantic reasoning services for the business service, so that the intelligent customer service service can provide the current model service to identify the semantic features of the chat text submitted by the platform users, and then query the response text with similar semantic features for feedback; or when the business service is a product classification service, the current model service can provide product classification services for the business service, so that the product classification service can classify the product objects existing in the platform through the current model service.

[0079] There is a neural network model in the current model service that provides it with reasoning functions. The server inputs business data into the neural network model to obtain the vector value output by the neural network model by extracting the business data for storage. The vector value is generally stored in the vector search service so that the current model service can subsequently provide corresponding reasoning services for the business service. The specific model structure of the neural network model is generally corresponding to the business service associated with the current model service. For the associated embodiments of the vector search service, please refer to the subsequent steps, and this step will not be repeated here.

[0080] The new model deployment event is generally triggered by the user deploying a new neural network model to the current model service. The server responds to the new model deployment event and obtains the model version number set by the user for the new neural network model from the relevant setting information of the new neural network model, so that the vector value output by the new neural network model when extracting business data can be stored in the vector search service.

[0081] Step S12: According to a preset search field conversion rule, a model version search field corresponding to the model version number is determined, and the model version search field is used to search for a vector value corresponding to the corresponding model version number from a vector search service:

[0082] After the server obtains the model version number corresponding to the new neural network model, it determines the model version search field of the vector search service that the model version number acts on according to the preset search field conversion rule.

[0083] The model version search field is used to search from the vector search service for the vector value inferred and output by the neural network model corresponding to the model version number corresponding to the model version search field. The expression of the field regarding the model version generally corresponds to the model version number of the neural network model to which it corresponds. For example, when the model version number of the neural network model is 1, the model version search field determined by the model version number according to the search field conversion rule is result_1.

[0084] The search field conversion rule generally converts the model version number into the model version search field according to the number of model versions stored in the vector search service. Specifically, after the server obtains the model version number of the new neural network model, it determines the type of model version currently existing in the vector search service, determines the number of model versions existing in the vector search service, and then calculates the remainder obtained by dividing the search model version number by the number of model versions, and then queries the model version search field in the vector search service whose model version is represented by the remainder. The model version search field corresponds to the model version number, so that the new vector value output by the new neural network model can be subsequently stored in the vector search service in correspondence with the model version search field.

[0085] The vector search service is generally based on the search service built on Elasticsearch. The vector search service is generally deployed in the current server or in other servers. The vector search service stores the vector values ​​output by each version of the neural network model inference business data, and the vector values ​​output by the neural network model of each model version are stored corresponding to the model version search field, so that the vector search service can distinguish the vector values ​​corresponding to each model version, and the vector value corresponding to the model version can be queried from the vector service through the model version search field corresponding to the neural network model of the corresponding model version.

[0086] Step S13, maintaining the operation of the old neural network model in the current model service to generate a vector value of the corresponding model version number for the input business data and storing it in the vector search service, continuously inputting the historical business data into the new neural network model, and storing each new vector value output by the new neural network model in the model version search field of the vector search service:

[0087] After the server determines the model version search field corresponding to the new neural network model, it continues to input the historical business data into the neural network model for reasoning, and stores the new vector values ​​corresponding to the historical business data output by the new neural network model in the model version search field of the vector search service. At the same time, the operation of the old neural network model in the current model service is maintained to ensure that when the new neural network model performs historical data reasoning, the old neural network model can perform reasoning for the business data input into the current model service, and store the vector values ​​output by the reasoning in the search vector service in accordance with the corresponding model version search field.

[0088] The business data generally refers to the data corresponding to the business performed by the business service associated with the current model service. For example, when the business service is an intelligent customer service service, the business data is generally the response text preset by the developer and the chat text pushed by the platform users; when the business service is a product classification service, the business data is generally the product feature data such as the product image and product title text of the product object.

[0089] The historical business data generally refers to the business data that is not the latest pushed to the current model service by the business service, that is, the historical business data is generally the business data received by the current model service before a preset time. The preset time is generally set by the developer, and its range is generally within 2-24 hours of the current time.

[0090] While maintaining the operation of the old neural network model, the server inputs historical business data into the new neural network model for inference, ensuring that the current model service can provide inference services for its associated business services, while driving the new neural network model to execute the data refresh process to achieve hot updates for the neural network model in the current model service.

[0091] The server obtains the historical business data from a business database, which stores business data related to its business, including intelligent customer service business data or e-commerce product business data, and then inputs the historical business data into the new neural network model, drives the new neural network model to infer new vector values ​​corresponding to the historical business data, so as to obtain the new vector value output by the new neural network model, and stores the new vector value in the storage space corresponding to the model version search field in the vector search service.

[0092] Step S14, after storing the new vector values ​​corresponding to all the historical business data output by the new neural network model in the vector search service, the old neural network model is offline, and the new neural network model is online to provide reasoning function for the current model service:

[0093] When the new neural network model outputs the new vector values ​​corresponding to all the historical business data, and the new vector values ​​are stored in the vector search service in correspondence with the model version search fields corresponding to the neural network model, the server will take offline the old neural network model running in the current model service, and switch the new neural network model to an online state, so that the new neural network model can provide reasoning functions for the current model service.

[0094] The server listens to the calculation events of the new neural network model to calculate all the historical business data respectively. When the server listens to the fact that the neural network model has completed the new vector values ​​corresponding to each of the historical business data, and the new vector values ​​are all stored in the vector search service corresponding to the model version search field, the server will stop running the old neural network model that provides reasoning function in the current model version, and the new neural network model online provides a new version of reasoning function for the current model service.

[0095] Through the typical implementation of the method, it can be known that the method constructs a vector search service and pre-configures the model version search field required in the model service in the vector search service, so that in the process of updating the neural network model for the business service, historical business data can be simultaneously input into the new neural network model for inference, and the new vector output by the new neural network model is stored in the storage space corresponding to the model version search field corresponding to the new model in the vector search service, so that after the business service completes the model update, it can obtain the new vector required by it from the vector search service to provide services for platform users. Compared with the existing model update, the new model is driven to infer historical data during the model update process, so that the business service can be quickly put into use after completing the model update, solving the problem of user use being affected by the lack of data required for model inference; secondly, when deploying a new model for the model service in the business model, there is no need to offline the old model that is providing the inference function in the model service, and wait for the new model to store the new vector output by it to the vector search service, and then replace the old and new models to realize the hot update of the neural network model in the business model.

[0096] The above typical embodiments and their variations fully disclose the implementation scheme of the model hot update processing method of the present application. However, various variations of the method can still be derived by changing and amplifying some technical means. Other embodiments are briefly described as follows:

[0097] In one embodiment, please refer to Figure 3 , the method comprises the following pre-steps:

[0098] Step S08, responding to a version setting event acting on the vector search service, determining the number of model versions set by the version setting event:

[0099] The server responds to the version setting event acting on the service of the vector and determines the model version number set by the development user in the version setting event.

[0100] The version setting event is triggered by the development user setting the number of neural network model versions expected to exist in the current model service in the vector search service, so that the server responds to the event and determines the number of model versions that the development user needs to set for the current model service.

[0101] Step S09, generating model version search fields whose number is the same as the number represented by the model version number, each of which represents the corresponding model version number:

[0102] After the server determines the model version number set by the version setting event, it generates the model version search fields with the number represented by the model version number. These model version search fields each represent the corresponding model version number. For example, when the number represented by the model version number is 2, the server will generate 2 types of model version search fields, including a model version search field representing a model version number of 0 and a model version search field representing a model version of 1.

[0103] Step S10: storing the model version search fields in the vector search service:

[0104] The server stores the generated multiple model version search fields in the search vector search service, and constructs storage spaces corresponding to each of the model version search fields in the vector search service for storing vector values ​​corresponding to the model version search fields.

[0105] In this embodiment, a model version search field corresponding to each version of the neural network model that the model service is expected to deploy is set in the vector search service, so that the vector values ​​output by each version of the neural network model can be stored in the vector search service accordingly.

[0106] In one embodiment, please refer to Figure 4 , the method comprises the following post-processing steps:

[0107] Step S15, responding to the model version rollback instruction acting on the current model service, determining the old model version number contained in the instruction:

[0108] The server responds to the search model version rollback instruction acting on the current model service and determines the old model version number of the neural network model whose version contained in the instruction is older than the neural network model running in the current model service.

[0109] Step S16, according to the old model version number, obtain the old neural network model retained in the model storage space:

[0110] The server obtains the old neural network model corresponding to the old model version number from the model storage space, and the model storage space stores the neural network models existing in the current model service, including the old version of the neural network model and the new version of the neural network model currently running.

[0111] Step S17, rolling back the new neural network model currently online in the current model service to the old neural network model, so as to drive the current model service to search for the old vector value retained in the vector search service according to the model version search field corresponding to the old model version number for service:

[0112] After the server obtains the old neural network model, it takes the new neural network model currently online in the current model service offline and puts the old neural network model online to roll back the neural network model version in the current model service, so that the current model service can obtain the old vector value corresponding to the old neural network model from the vector search service according to the model version search field corresponding to the old neural network model for service.

[0113] In this embodiment, the current model service can roll back the old version of the neural network model for inference service, and the vector service retains the old vectors of the old version of the neural network model in the current model service, so that the current model service can go online quickly when rolling back the old version of the neural network model.

[0114] In one embodiment, please refer to Figure 5 The step of determining the model version search field corresponding to the model version number according to the preset search field conversion rule includes:

[0115] Step S121: Determine the number of model versions existing in the vector search service according to the type of the model version search field stored in the vector search service:

[0116] After the server determines the model version number of the newly deployed new neural network model, it will determine the type of the model version search field stored in the vector search service, that is, the type of model version preset in the search vector search service, to determine the number of model versions existing in the vector search service.

[0117] Step S122, calculate the remainder of the model version number of the new neural network model divided by the number of model versions:

[0118] The server calculates the model version number of the new neural network model and divides it by the number of model versions existing in the service of the vector to obtain a remainder represented in the calculation result.

[0119] Step S123, querying the model version search field whose model version representation is the remainder in the vector search service, and matching the model version search field with the model version number:

[0120] After obtaining the remainder, the server will query the model version search field in the vector search service whose model version representation is the remainder, and use the model version search field as the model version search field stored in the vector search service corresponding to the new vector value output by the new neural network model.

[0121] In this embodiment, the remainder calculation is performed between the model version number of the new neural network model and the model version number of the model version search field existing in the vector search service to determine the model version search field corresponding to the new neural network model. The storage location of the new vector output by the new neural network model in the vector search service can be quickly determined through simple calculation, thereby improving the speed of launching the new neural network model.

[0122] In one embodiment, please refer to Figure 6 The step of continuously inputting the historical business data into the new neural network model respectively, and storing the new vector values ​​output by the new neural network model respectively into the model version search field of the vector search service accordingly, includes:

[0123] Step S131, obtaining the historical business data from a business database, wherein the business database stores business data associated with the business, including smart customer service business data or e-commerce product business data:

[0124] After the server determines the model version search field corresponding to the new neural network model, it obtains the historical business data from the business database, which stores the business data of business services associated with the current model service. For example, when the business service is an intelligent customer service service, the business data is generally the response text preset by the developer and the chat text pushed by the platform users; when the business service is a product classification service, the business data is generally product feature data such as product images and product title texts of product objects.

[0125] The historical business data generally refers to the business data that is not the latest pushed to the current model service by the business service, that is, the historical business data is generally the business data received by the current model service before a preset time. The preset time is generally set by the developer, and its range is generally within 2-24 hours of the current time.

[0126] Step S132: input the historical business data into the new neural network model, and drive the new neural network model to infer the new vector value corresponding to the historical business data:

[0127] The server inputs the multiple historical business data obtained from the business database into the new neural network model respectively, and drives the new neural network model to infer the new vector values ​​respectively output by the historical business data.

[0128] Step S133, obtaining the new vector value output by the new neural network model, and storing the new vector value in the storage space corresponding to the model version search field in the vector search service:

[0129] The server obtains the new vector values ​​respectively output by the new neural network model, and stores these new vector values ​​in the storage space corresponding to the model version search field corresponding to the new neural network model in the vector search service.

[0130] The storage space generally refers to a database or list for storing vector values ​​corresponding to the neural network model version, or refers to a storage location in the vector database of the vector search service for storing vector values ​​corresponding to the neural network model version, and the storage space has a corresponding model version search field so that the server can identify the model version to which the stored vector value belongs.

[0131] In this embodiment, the server stores the vector value output by the neural network model in the storage space corresponding to the model version search field corresponding to the neural network model in the vector search service, so that the current model service searches for the vector value of the corresponding model version from the vector search service through the model version search field for inference.

[0132] In one embodiment, please refer to Figure 7 , the step of taking the old neural network model offline and bringing the new neural network model online to provide reasoning function for the current model service includes:

[0133] Step S141, monitoring the calculation events of all historical business data respectively calculated by the new neural network model, and after monitoring that the new vector values ​​corresponding to all historical business data output by the new neural network model are stored in the vector search service, triggering the online instruction acting on the new neural network model:

[0134] The server listens to the calculation events of the new neural network model to calculate all the historical business data respectively. When the server listens that the neural network model has completed the new vector values ​​corresponding to each of the historical business data, and these new vector values ​​are all stored in the vector search service corresponding to the model version search field, it will trigger the online instruction acting on the new neural network model to bring the new neural network model online.

[0135] Step S142, in response to the online instruction, stops the operation of the old neural network model in the current model service, and switches the new neural network model to an online state to provide reasoning function for the current model service:

[0136] The server responds to the online instruction, stops running the old neural network model that currently provides reasoning function in the current model service, takes the old neural network model offline, and then switches the new neural network model to an online state, so that the current model service can provide reasoning services for the business services associated with it through the reasoning function provided by the new neural network model.

[0137] In this embodiment, after the new neural network model completes the vector calculation of all historical business data and stores it in the vector search service, the new neural network model is put online to update the model in the current model service.

[0138] Furthermore, by functionalizing each step in the method disclosed in the above embodiments, a model thermal update processing device of the present application can be constructed. According to this idea, please refer to Figure 8 In a typical embodiment, the device includes: a model version number acquisition module 11, which is used to respond to a new model deployment event acting on the current model service and obtain the model version number corresponding to the newly deployed new neural network model; a search field determination module 12, which is used to determine the model version search field corresponding to the model version number according to a preset search field conversion rule, and the model version search field is used to search for the vector value corresponding to the corresponding model version number from the vector search service; a new vector value storage module 13, which is used to maintain the operation of the old neural network model in the current model service so as to generate the vector value of the corresponding model version number for the input business data and store it in the vector search service, continuously input the historical business data into the new neural network model respectively, and store the new vector values ​​output by the new neural network model respectively in the model version search field of the vector search service; a new model online module 14, which is used to store the new vector values ​​corresponding to all the historical business data output by the new neural network model in the vector search service, then offline the old neural network model, and online the new neural network model to provide reasoning function for the current model service.

[0139] In one embodiment, the search field determination module 12 includes: a model version quantity determination submodule, used to determine the number of model versions existing in the vector search service according to the type of the model version search field stored in the vector search service; a remainder calculation submodule, used to calculate the remainder of the model version number of the new neural network model divided by the number of model versions; a model version search field determination submodule, used to query the model version search field in the vector search service whose model version is represented by the remainder, and correspond the model version search field to the model version number.

[0140] In one embodiment, the new vector value storage module 13 includes: a historical business data acquisition submodule, used to acquire the historical business data from a business database, wherein the business database stores business data associated with its business, including intelligent customer service business data or e-commerce product business data; a historical business data inference submodule, used to input the historical business data into the new neural network model, and drive the new neural network model to infer the new vector value corresponding to the historical business data; a new vector value storage submodule, used to acquire the new vector value output by the new neural network model, and store the new vector value in the storage space corresponding to the model version search field in the vector search service.

[0141] In one embodiment, the new model online module 14 includes: a calculation event monitoring submodule, which is used to monitor the calculation events that act on the new neural network model to calculate all historical business data respectively, and when it is monitored that the new vector values ​​corresponding to all historical business data output by the new neural network model are stored in the vector search service, it triggers the online instruction acting on the new neural network model; an online instruction response submodule, which is used to respond to the online instruction, stop the operation of the old neural network model in the current model service, and switch the new neural network model to the online state to provide reasoning function for the current model service.

[0142] In order to solve the above technical problems, the embodiment of the present application also provides a computer device for running a computer program implemented according to the model hot update processing method. Fig. 9 , Fig. 9 This is a basic structural block diagram of the computer device in this embodiment.

[0143] like Fig. 9 As shown, a schematic diagram of the internal structure of a computer device. The computer device includes a processor, a non-volatile storage medium, a memory, and a network interface connected via a system bus. Among them, the non-volatile storage medium of the computer device stores an operating system, a database, and computer-readable instructions. The database may store a control information sequence. When the computer-readable instructions are executed by the processor, the processor can implement a model hot update processing method. The processor of the computer device is used to provide computing and control capabilities to support the operation of the entire computer device. The memory of the computer device may store computer-readable instructions. When the computer-readable instructions are executed by the processor, the processor can execute a model hot update processing method. The network interface of the computer device is used to connect and communicate with a terminal. Those skilled in the art can understand that Fig. 9The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0144] In this embodiment, the processor is used to execute the specific functions of each module / submodule in the model hot update processing device of this application, and the memory stores the program code and various data required to execute the above modules. The network interface is used to transmit data between user terminals or servers. The memory in this embodiment stores the program code and data required to execute all modules / submodules in the model hot update processing device, and the server can call the server's program code and data to execute the functions of all submodules.

[0145] The present application also provides a non-volatile storage medium, in which the model hot update processing method is written into a computer program and stored in the storage medium in the form of computer-readable instructions. When the computer-readable instructions are executed by one or more processors, it means that the program is running in the computer, thereby enabling one or more processors to execute the steps of the model hot update processing method of any of the above-mentioned embodiments.

[0146] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a non-volatile storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

[0147] To summarize, in the process of updating the model for business services, the present application can simultaneously input historical business data into the new model for inference, so that after the business service completes the model update, it can obtain the new vectors it needs from the vector search service to provide services to platform users.

[0148] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.

[0149] Those skilled in the art will appreciate that the various operations, methods, steps, measures, and schemes in the processes discussed in this application may be alternated, altered, combined, or deleted. Further, other steps, measures, and schemes in the various operations, methods, and processes discussed in this application may also be alternated, altered, rearranged, decomposed, combined, or deleted. Further, the steps, measures, and schemes in the prior art that are similar to those disclosed in this application may also be alternated, altered, rearranged, decomposed, combined, or deleted.

[0150] The above description is only a partial implementation method of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A model hot update processing method, characterized in that: The steps include: In response to the new model deployment event acting on the current model service, obtain the model version number corresponding to the newly deployed new neural network model; According to a preset search field conversion rule, a model version search field corresponding to the model version number is determined, and the model version search field is used to search for a vector value corresponding to the corresponding model version number from a vector search service; Maintaining the operation of the old neural network model in the current model service to generate a vector value of the corresponding model version number for the input business data and storing it in the vector search service, continuously inputting the historical business data into the new neural network model, and storing each new vector value output by the new neural network model in the model version search field of the vector search service; After storing the new vector values ​​corresponding to all the historical business data output by the new neural network model in the vector search service, the old neural network model is taken offline, and the new neural network model is put online to provide reasoning function for the current model service.

2. The method according to claim 1, characterized in that: This method includes the following preparatory steps: In response to a version setting event acting on the vector search service, determining a model version number set by the version setting event; Generate model version search fields whose number is the same as the number represented by the model version number, each of which represents the model version number corresponding to it; The model version search fields are stored in the vector search service.

3. The method according to claim 1, characterized in that This method includes the following post-processing steps: In response to a model version rollback instruction acting on the current model service, determine the old model version number contained in the instruction; According to the old model version number, obtaining the old neural network model retained in the model storage space; The new neural network model currently online in the current model service is rolled back to the old neural network model to drive the current model service to search for the old vector value retained in the vector search service according to the model version search field corresponding to the old model version number for service.

4. The method according to claim 1, characterized in that: The step of determining the model version search field corresponding to the model version number according to the preset search field conversion rule includes: Determining the number of model versions existing in the vector search service according to the type of the model version search field stored in the vector search service; Calculate the remainder of the model version number of the new neural network model divided by the number of model versions; A model version search field whose model version representation is the remainder in the vector search service is queried, and the model version search field is matched with the model version number.

5. The method according to claim 1, characterized in that The step of continuously inputting the historical business data into the new neural network model respectively, and storing the new vector values ​​outputted by the new neural network model respectively into the model version search field of the vector search service accordingly, comprises: Acquire the historical business data from a business database, where the business database stores business data related to its business, including intelligent customer service business data or e-commerce product business data; Inputting the historical business data into the new neural network model to drive the new neural network model to infer new vector values ​​corresponding to the historical business data; The new vector value output by the new neural network model is obtained, and the new vector value is stored in the storage space corresponding to the model version search field in the vector search service.

6. The method according to claim 1, characterized in that The step of taking the old neural network model offline and bringing the new neural network model online to provide the reasoning function for the current model service includes: Monitoring the calculation events of all historical business data respectively calculated by the new neural network model, and after monitoring that the new vector values ​​corresponding to all the historical business data output by the new neural network model are stored in the vector search service, triggering the online instruction acting on the new neural network model; In response to the online instruction, the operation of the old neural network model in the current model service is stopped, and the new neural network model is switched to an online state to provide reasoning function for the current model service.

7. A model thermal update processing device, characterized in that: include: A model version number acquisition module is used to respond to a new model deployment event acting on the current model service and obtain the model version number corresponding to the newly deployed new neural network model; A search field determination module, used to determine the model version search field corresponding to the model version number according to a preset search field conversion rule, wherein the model version search field is used to search for a vector value corresponding to the corresponding model version number from a vector search service; A new vector value storage module is used to maintain the operation of the old neural network model in the current model service so as to generate a vector value of a corresponding model version number for the input business data and store it in the vector search service, continuously input the historical business data into the new neural network model, and store each new vector value output by the new neural network model in the model version search field of the vector search service; The new model online module is used to store the new vector values ​​corresponding to all the historical business data output by the new neural network model to the vector search service, then take the old neural network model offline and put the new neural network model online to provide reasoning function for the current model service.

8. An electronic device, comprising a central processing unit and a memory, characterized in that: The central processing unit is used to call and run a computer program stored in the memory to execute the steps of the method according to any one of claims 1 to 6.

9. A non-volatile storage medium, characterized in that: It stores a computer program implemented according to the method described in any one of claims 1 to 6 in the form of computer-readable instructions, and when the computer program is called and executed by a computer, the steps included in the method are executed.

10. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Application program hot update method and device, storage medium and electronic equipment

    CN110837391A

  • Neural network model parameter updating method

    CN111459661A