Model running method, device, equipment, storage medium and program product
By establishing a correspondence between query statements and models in the banking system, query statements with no anomalies and the shortest processing time are selected and automatically assigned to batch processing tasks. This solves the problems of batch processing task allocation and computation time in the banking system, and improves the efficiency and resource utilization of batch processing machines.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA CONSTRUCTION BANK
- Filing Date
- 2022-09-27
- Publication Date
- 2026-07-07
AI Technical Summary
The allocation of batch processing tasks and model calculations in the banking system consume a lot of time and resources, resulting in low efficiency of batch processing machines.
By establishing a correspondence between query statement sets and models, query statements with no anomalies and the shortest processing time are selected, and batch processing tasks are automatically assigned to the corresponding models, avoiding manual intervention.
It improved the operating efficiency and resource utilization of batch processing machines, and shortened the allocation and execution time of batch processing tasks.
Smart Images

Figure CN115391620B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of artificial intelligence technology, and in particular relates to a model operation method, apparatus, device, storage medium and program product. Background Technology
[0002] Batch processing, also known as "batch execution," is a common business process in various IT systems today. Statistics show that 70% of operations in business systems are completed using batch processing. Simply put, batch processing involves accumulating a certain volume of similar business processes (identical business processes, batched together) and then automatically processing them at a specified time point to simplify operations and improve efficiency. Analyzing the batch processing process, we can easily summarize its characteristics: large processing volume (batch processing), specific triggering times (specified time points), and automatic processing capability.
[0003] However, currently, batch processing tasks for different business operations in the banking system still require manual configuration of batch processing parameters, and different batch processing tasks are assigned to different models. Given the large number of customers banks have, the allocation of batch processing tasks and model calculations consume a significant amount of time, while banks typically have limited equipment resources. This manual allocation of batch processing tasks results in low efficiency for the batch processing machines. Summary of the Invention
[0004] This application provides a model running method, apparatus, device, storage medium, and program product that can solve the problem of low running efficiency of existing batch processing machines.
[0005] In a first aspect, embodiments of this application provide a model running method, the method comprising:
[0006] Obtain the first set of query statements corresponding to the first type of model;
[0007] The execution templates of each first query statement in the first query statement set are compared with the preset abnormal templates, and N first query statements without abnormalities are selected based on the comparison results.
[0008] Select the second query statement with the shortest query time from the N first query statements that have no anomalies;
[0009] Execute the second query statement to obtain the first processing object corresponding to the first type of model;
[0010] The first processing object is input into the first type of model to obtain the running result of the first type of model.
[0011] In some embodiments, the first type of model includes at least one model;
[0012] The step of inputting the first processing object into the first type of model and obtaining the running result of the first type of model includes:
[0013] The first processing object is split to obtain at least one group, and each group includes at least one processing object from the first processing object;
[0014] Determine the model corresponding to each group in the first type of model in the at least one group;
[0015] Each group is input into its corresponding model to obtain the predicted probability value of each group.
[0016] In some embodiments, the step of inputting each group into its corresponding model to obtain the predicted probability value of each group includes:
[0017] The at least one processing object in each group is sequentially input into the corresponding model to obtain a predicted probability value that corresponds one-to-one with each of the at least one processing object.
[0018] In some embodiments, the step of sequentially inputting the at least one processing object in each group into the corresponding model to obtain a predicted probability value corresponding one-to-one with each of the at least one processing object includes:
[0019] Determine the standardized score corresponding to each of the processing objects based on the predicted probability value;
[0020] Based on the predicted probability value and the standardized score, determine the contribution score of each feature of each of the processed objects in the standardized score;
[0021] The processed object is analyzed based on the standardized score and the contribution score.
[0022] In some embodiments, the step of determining the standardized score corresponding to each of the processed objects based on the predicted probability value includes:
[0023] The good-bad ratio of the processed object is determined based on the predicted probability value;
[0024] The standardized score is determined based on the good-bad ratio.
[0025] In some embodiments, splitting the first processing object to obtain at least one group includes:
[0026] Obtain the number of processing objects included in the first processing object;
[0027] Obtain the preset number of processing objects included in each group of the first type of model;
[0028] Based on the number of processing objects included in the first processing object and the number of processing objects included in each preset group, the first processing object is split to obtain at least one group.
[0029] Secondly, embodiments of this application provide a model running apparatus, the apparatus comprising:
[0030] The acquisition module is used to acquire the first set of query statements corresponding to the first type of model;
[0031] The first filtering module is used to compare the execution template of each first query statement in the first query statement set with each preset abnormal template, and filter out N first query statements without abnormalities based on the comparison results.
[0032] The second filtering module is used to execute the second query statement and obtain the first processing object corresponding to the first type of model;
[0033] The execution module is used to execute the second query statement and obtain the first processing object corresponding to the first type of model;
[0034] The running module is used to input the first processing object into the first type of model and obtain the running result of the first type of model.
[0035] Thirdly, embodiments of this application provide a model running device, the device including: a processor and a memory storing computer program instructions;
[0036] The processor implements the above model operation method when executing computer program instructions.
[0037] Fourthly, embodiments of this application provide a computer storage medium storing computer program instructions, which, when executed by a processor, implement the above-described model operation method.
[0038] Fifthly, embodiments of this application provide a computer program product, which includes computer program instructions that, when executed by a processor, implement the above-described model operation method.
[0039] In this application, a correspondence is established between different sets of query statements and different types of models. By comparing the execution templates of the query statements in the query statement set with preset abnormal templates, query statements without abnormalities are obtained based on the comparison results. Furthermore, the normal query statements with the shortest execution time are selected, thereby selecting the most suitable query statements for different types of models. Based on the most suitable query statements, batch processing tasks are automatically obtained from the database. This avoids manually assigning batch processing tasks to the batch processing machine, shortens the allocation and running time of batch processing tasks, and improves the running efficiency of the batch processing machine. Attached Figure Description
[0040] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0041] Figure 1 This is a schematic flowchart of a model running method provided in an embodiment of this application;
[0042] Figure 2 This is a schematic diagram of the hardware structure of a model running device provided in one embodiment of this application;
[0043] Figure 3 This is a schematic diagram of the structure of a model running device provided in an embodiment of this application. Detailed Implementation
[0044] The features and exemplary embodiments of various aspects of this application will be described in detail below. To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain this application and not to limit it. For those skilled in the art, this application can be implemented without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples of this application.
[0045] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, 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 a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0046] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. The embodiments will now be described in detail with reference to the accompanying drawings.
[0047] Batch processing, also known as "batch execution," is a common business process in various IT systems today. Statistics show that 70% of operations in business systems are completed using batch processing. Simply put, batch processing involves accumulating a certain volume of similar business processes (identical business processes, batched together) and then automatically processing them at a specified time point to simplify operations and improve efficiency. Analyzing the batch processing process, we can easily summarize its characteristics: large processing volume (batch processing), specific triggering times (specified time points), and automatic processing capability.
[0048] Generally, for non-real-time batch processing models, the allocation of batch processing tasks and model computation do not consume too many resources. However, currently in banking systems, different batch processing tasks for different business lines still require manual configuration of different batch processing parameters, and different batch processing tasks are assigned to different models. Given the large number of customers banks have, the allocation of batch processing tasks and model computation consume significant resources, while banks typically have limited equipment resources. This manual allocation of batch processing tasks results in low resource utilization of the batch processing machines.
[0049] To address the aforementioned issues, this application establishes a correspondence between different query statements and different types of models, and uses different query statements to allocate batch processing tasks to different types of models, thereby eliminating the need for manual allocation of batch processing tasks to the batch processing machine and improving the running efficiency of the batch processing machine.
[0050] Specifically, in order to solve the problems of the prior art, embodiments of this application provide a model running method, apparatus, device, storage medium, and program product. The model running method provided in the embodiments of this application will be described first below.
[0051] Figure 1 A flowchart illustrating a model running method according to an embodiment of this application is shown. The method includes the following steps:
[0052] S110, obtain the first set of query statements corresponding to the first type of model.
[0053] In this embodiment, the batch processing machine contains at least one type of model, where the first type of model is any one of these types. Each type of model can include at least one model. These models can include XGBOOST models, lightGBM models, etc. Different types of models correspond to different sets of first query statements in the database, which stores the assigned batch processing tasks. The first type of model can obtain its corresponding set of first query statements.
[0054] The first query statement set includes at least one first query statement. The first type of model can retrieve the required first processing object by applying any of these first query statements. However, the first type of model only needs to apply one first query statement at a time, so it can select one first query statement from the first query statement set for querying.
[0055] S120, compare the execution template of each first query statement in the first query statement set with each preset abnormal template, and select N first query statements without abnormalities based on the comparison results.
[0056] In this embodiment, the execution template refers to the statement obtained by abstracting and normalizing the specific parameter values of the query statement, i.e., variables. The execution templates of the first query statements that have various anomalies can be stored as anomaly templates. Before each filtering of the first query statements, the execution templates of each first query statement in the set of first query statements are compared with the set of anomaly templates. If an anomaly is found in the execution template, the first query statements corresponding to the execution templates with anomalies are filtered out. In this way, N anomaly-free first query statements can be determined.
[0057] S130, select the second query statement with the shortest query time from the N first query statements without abnormalities;
[0058] In this embodiment, in order to improve the efficiency of batch processing tasks and save batch processing time, it is necessary to select the second query statement with the shortest query time from N first query statements without anomalies, and use it for querying the first type of model.
[0059] In one embodiment, the average time of the first three queries of each of the N first query statements without anomalies can be obtained, and the first query statement without anomalies with the shortest average time can be determined as the second query statement.
[0060] S140, Execute the second query statement to obtain the first processing object corresponding to the first type of model.
[0061] In this embodiment, after the first type of model obtains the corresponding second query statement, the first processing object can be obtained from the database through the second query statement. The first processing object is the batch processing task assigned to the first type of model.
[0062] In one embodiment, the server responsible for allocating batch processing tasks distributes the batch processing tasks in the server to the databases of different batch processing machines according to a preset allocation rule. Each batch processing machine has at least one first type of model, and each first type of model has a corresponding first query statement in the database. The first type of model obtains the corresponding first processing object from the database through the corresponding first query statement.
[0063] In one embodiment, different batch processing tasks in the database have a unique identifier. The first query statement can retrieve the identifier corresponding to the batch processing task and retrieve the required first processing object from the database based on the identifier.
[0064] Assuming each batch processing machine can execute a maximum of q batch processing tasks simultaneously, the aforementioned preset allocation rule could be: iterate through all batch processing machines, monitor each machine sequentially, and if the number of batch processing tasks currently being executed on a machine is less than q, then send a batch processing task to that machine; if the number of batch processing tasks currently being executed on a machine is greater than or equal to q, then do not allocate any batch processing tasks to that machine. If all batch processing machines are executing greater than or equal to q tasks, the server enters a sleep state, and after a first preset time interval, iterates through all batch processing machines again and allocates tasks according to the aforementioned preset allocation rule.
[0065] The above-mentioned preset allocation rule can also be to distribute the batch processing tasks evenly across all batches.
[0066] S150, input the first processing object into the first type of model, and obtain the running result of the first type of model.
[0067] In this embodiment, after obtaining the first processing object, the first processing object is input into the first type model corresponding to it. The first type model can then output the predicted probability value of the first processing object. It can be understood that the running result of the first type model is the predicted probability value of the first processing object.
[0068] This application establishes a correspondence between different sets of query statements and different types of models. By comparing the execution templates of the query statements in the query statement set with preset abnormal templates, it obtains query statements without abnormalities based on the comparison results, and further filters out the normal query statements with the shortest execution time. This allows for the selection of the most suitable query statements for different types of models. Based on the most suitable query statement, it automatically retrieves batch processing tasks from the database. This avoids manually assigning batch processing tasks to the batch processing machine, shortens the allocation and execution time of batch processing tasks, and improves the resource utilization of the batch processing machine.
[0069] As an optional embodiment, the first type of model includes at least one model. In order to match the processing object and the model, the above-mentioned S130 may include:
[0070] S210, the first processing object is split to obtain at least one group, and each group includes at least one processing object from the first processing object;
[0071] S220, determine the model corresponding to each group in the first type of model in the at least one group;
[0072] S230, input each group into the corresponding model to obtain the predicted probability value of each group.
[0073] In this embodiment, during the batch processing of batch tasks, the same batch processing machine includes different types of models, and the same type of model includes multiple models with different model parameters. Although these multiple models belong to the same type of model, the different model parameters of the models result in different algorithms of the models, and therefore their corresponding processing objects are also different.
[0074] Since the first processing object comprises multiple processing objects, and these processing objects need to be input into different models respectively, this embodiment splits the first processing object into at least one group. Each group includes at least one processing object from the first processing object, and the processing objects in different groups are input into their corresponding models to obtain the predicted probability values for each group.
[0075] In one embodiment, the number of processing objects in each group is the maximum number of processing objects that the same model can process simultaneously. This ensures that different processing objects are input into the corresponding models, and that the model's efficiency is maximized.
[0076] As an optional embodiment, the above-described S230 may further include:
[0077] S310, the at least one processing object in each group is sequentially input into the corresponding model to obtain the predicted probability value corresponding to each processing object in the at least one processing object.
[0078] In this embodiment, each group contains at least one processing object. By inputting each processing object into the corresponding model, an independent prediction probability value corresponding to each processing object can be obtained.
[0079] The specific representation of the predicted probability value is determined by the model algorithm and the features contained in the processed object. It can represent the probability of a user repaying a loan on time, or it can be used to represent the probability of a user taking out a loan.
[0080] As an optional embodiment, after S310 above, it may further include:
[0081] S410, determine the standardized score corresponding to each of the processing objects based on the predicted probability value;
[0082] S420, based on the predicted probability value and the standardized score, determine the contribution score of each feature of each of the processed objects in the standardized score;
[0083] S430, Analyze the processed object based on the standardized score and the contribution score.
[0084] In this embodiment, standardized score refers to the process of mapping the model's running results, i.e., the predicted probability value, to a specific good-bad ratio in order to facilitate the management of model results in business. This mapping is usually achieved by establishing a specific functional relationship between the predicted probability value and the standardized score, thereby converting the predicted probability value into a standardized score.
[0085] Standardized scores are used to characterize the contribution of all features in the processing object to the predicted probability value. After obtaining the standardized scores, the contribution score of each feature in the processing object to the predicted probability value can be calculated based on the standardized scores. Based on the proportion of the feature contribution score in the standardized scores, the importance of each feature in the processing object can be analyzed.
[0086] As an optional embodiment, the above-described S410 may include:
[0087] S510, determine the good-bad ratio of the processed object based on the predicted probability value;
[0088] S520, determine the standardized score based on the natural logarithm of the good-bad ratio.
[0089] In this embodiment, the conversion formula between the predicted probability value and the standardized score is as follows:
[0090]
[0091] in, Here, p represents the standardized score, p is the predicted probability value, and A and B are user-defined constants, with A being the first preset constant and B being the second preset constant. The ratio of bad to good.
[0092] In one embodiment, it can be As interpretable values corresponding to the processed objects, the predicted probability values are converted into standardized scores using these interpretable values:
[0093]
[0094] Where shap is the interpretable value corresponding to the object being processed, and p is the predicted probability value of the object being processed.
[0095] Furthermore, each feature in the processing object has a corresponding interpretable value, and the sum of the interpretable values of all features in the processing object is the total interpretable value of the processing object. The contribution score of each feature can be determined based on its interpretable value, as shown in the following formula:
[0096]
[0097] Where shap is the interpretable value corresponding to the processed object, the processed object includes k features, shapk is the interpretable value corresponding to the kth feature, and base is the base score.
[0098] After calculating the interpretable values of these k features, the contribution score of each feature can be calculated based on these interpretable values. The calculation process is as follows:
[0099] hapk
[0100] in, Let be the contribution score of the k-th feature, and shapk be the interpretable value corresponding to the k-th feature.
[0101] Therefore, in this embodiment, the standardized score of the processed object is the sum of the first preset constant and the contribution scores corresponding to each feature.
[0102] As an optional embodiment, in order to group the processing objects, the above-described S210 includes:
[0103] S610, obtain the number of processing objects included in the first processing object;
[0104] S620, obtain the preset number of processing objects included in each group of the first type of model;
[0105] S630, based on the number of processing objects included in the first processing object and the number of processing objects included in each preset group, the first processing object is split to obtain at least one group.
[0106] In this embodiment, based on the number of processing objects included in the first processing object and the preset number of processing objects included in each group, the number of groups can be calculated using the following formula:
[0107] GN = ceiling(N / BN)
[0108] Where N is the number of processing objects included in the first processing object, BN is the preset number of processing objects included in each group, GN is the number of groups, and ceiling() is the rounding up function.
[0109] By using the grouping method described above, the processing objects corresponding to different algorithms can be divided into different groups, which can also ensure that the number of processing objects processed by the model at the same time does not exceed BN.
[0110] Based on the model running method provided in the above embodiments, this application also provides specific implementations of the model running apparatus. Please refer to the following embodiments.
[0111] First see Figure 2 The model running device 200 provided in this application embodiment includes the following modules:
[0112] Module 201 is used to obtain the first set of query statements corresponding to the first type of model;
[0113] The first filtering module 202 is used to compare the execution template of each first query statement in the first query statement set with each preset abnormal template, and filter out N first query statements without abnormalities based on the comparison results.
[0114] The second filtering template 203 is used to filter out the second query statement with the shortest query time from the N first query statements without anomalies.
[0115] Execution module 204 is used to execute the first query statement and obtain the first processing object corresponding to the first type of model;
[0116] The running module 205 is used to input the first processing object into the first type of model and obtain the running result of the first type of model.
[0117] The device can establish a correspondence between different sets of query statements and different types of models. By comparing the execution templates of the query statements in the query statement set with preset abnormal templates, it can obtain query statements without abnormalities based on the comparison results, and further filter out the normal query statements with the shortest execution time. This allows it to select the most suitable query statement for different types of models, and automatically retrieve batch processing tasks from the database based on the most suitable query statement. This avoids manually assigning batch processing tasks to the batch processing machine, shortens the allocation and running time of batch processing tasks, and improves the resource utilization of the batch processing machine.
[0118] As one implementation of this application, in order to match the processing object and the model, the above-mentioned running module 205 may further include:
[0119] A grouping unit is used to split the first processing object to obtain at least one group, and each group includes at least one processing object from the first processing object;
[0120] A matching unit is used to determine the model corresponding to each group in the at least one group in the first type of model;
[0121] The prediction unit is used to input each group into the corresponding model to obtain the predicted probability value of each group.
[0122] As one implementation of this application, the prediction unit may further include:
[0123] The prediction subunit is used to sequentially input the at least one processing object in each group into the corresponding model to obtain a prediction probability value that corresponds one-to-one with each of the at least one processing object.
[0124] As one implementation of this application, in order to record information about isolated devices, the aforementioned model running device 200 may further include:
[0125] The standardized score determination unit is used to determine the standardized score corresponding to each of the processing objects based on the predicted probability value.
[0126] A contribution score determination unit is used to determine the contribution score of each feature of each of the processed objects in the standardized score based on the predicted probability value and the standardized score;
[0127] An analysis unit is used to analyze the processed object based on the standardized score and the contribution score.
[0128] As one implementation of this application, the standardized score determination unit may further include:
[0129] A good-bad ratio determination unit is used to determine the good-bad ratio of the processed object based on the predicted probability value;
[0130] A standardized score determination subunit is used to determine the standardized score based on the natural logarithm of the good-bad ratio.
[0131] As one implementation of this application, the above-mentioned running module 205 may further include:
[0132] The first acquisition unit is used to acquire the number of processing objects included in the first processing object;
[0133] The second acquisition unit is used to acquire the number of processing objects included in each group of the first type of model.
[0134] The splitting subunit is used to split the first processing object according to the number of processing objects included in the first processing object and the number of processing objects included in each preset group, to obtain at least one group.
[0135] Figure 3 A schematic diagram of the hardware structure of the model running device provided in an embodiment of this application is shown.
[0136] The model running device may include a processor 301 and a memory 302 storing computer program instructions.
[0137] Specifically, the processor 301 may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.
[0138] Memory 302 may include mass storage for data or instructions. For example, and not limitingly, memory 302 may include a hard disk drive (HDD), floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 302 may include removable or non-removable (or fixed) media. Where appropriate, memory 302 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 302 is non-volatile solid-state memory.
[0139] Memory may include read-only memory (ROM), random access memory (RAM), disk storage media devices, optical storage media devices, flash memory devices, and electrical, optical, or other physical / tangible memory storage devices. Therefore, typically, memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the methods according to one aspect of this disclosure.
[0140] The processor 301 reads and executes computer program instructions stored in the memory 302 to implement any of the model operation methods in the above embodiments.
[0141] In one example, the model running device may also include a communication interface 303 and a bus 310. For example, Figure 3 As shown, the processor 301, memory 302, and communication interface 303 are connected through bus 310 and complete communication with each other.
[0142] The communication interface 303 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of this application.
[0143] Bus 310 includes hardware, software, or both, that couples components of a model running device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGp) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LpC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (pCI) bus, a pCI-Express (pCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 310 may include one or more buses. Although specific buses are described and illustrated in embodiments of this application, this application contemplates any suitable bus or interconnect.
[0144] The model running device can be based on the above embodiments to realize the model running method and apparatus described above.
[0145] Furthermore, in conjunction with the model running methods in the above embodiments, this application embodiment can provide a computer storage medium for implementation. This computer storage medium stores computer program instructions; when these computer program instructions are executed by a processor, they implement any of the model running methods in the above embodiments and achieve the same technical effect. To avoid repetition, further details are omitted here. The aforementioned computer-readable storage medium may include non-transitory computer-readable storage media, such as read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks, etc., and is not limited thereto.
[0146] In addition, this application also provides a computer program product, including computer program instructions, which, when executed by a processor, can implement the steps and corresponding content of the aforementioned method embodiments.
[0147] It should be clarified that this application is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of this application is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of this application.
[0148] The functional blocks shown in the above block diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.
[0149] It should also be noted that the exemplary embodiments mentioned in this application describe methods or systems based on a series of steps or apparatus. However, this application is not limited to the order of the above steps; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.
[0150] The aspects of this disclosure have been described above with reference to flowchart illustrations and / or block diagrams of methods, apparatus, and computer program products according to embodiments of this disclosure. It should be understood that each block in 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, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that these instructions, executable via the processor of the computer or other programmable data processing apparatus, enable the implementation of the functions / actions specified in one or more blocks of the flowchart illustrations and / or block diagrams. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It is also understood that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can also be implemented by special-purpose hardware performing the specified functions or actions, or can be implemented by a combination of special-purpose hardware and computer instructions.
[0151] The above are merely specific embodiments of this application. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the protection scope of this application.
Claims
1. A model running method, characterized in that, include: Obtain the first set of query statements corresponding to the first type of model, wherein the first type of model is any one of the at least one type of model in the batch processing machine; The execution templates of each first query statement in the first query statement set are compared with the preset abnormal templates, and N first query statements without abnormalities are selected based on the comparison results. Select the second query statement with the shortest query time from the N first query statements that have no anomalies; Execute the second query statement to obtain the first processing object corresponding to the first type of model. The first processing object is obtained from the database through the second query statement. The first processing object is a batch processing task assigned to the first type of model. The first processing object is input into the first type of model to obtain the running result of the first type of model. The running result of the first type of model is the predicted probability value of the first processing object. The first type of model includes at least one model; The step of inputting the first processing object into the first type of model and obtaining the running result of the first type of model includes: The first processing object is split to obtain at least one group, and each group includes at least one processing object from the first processing object; Determine the model corresponding to each group in the first type of model in the at least one group; Each group is input into its corresponding model to obtain the predicted probability value of each group.
2. The model running method according to claim 1, characterized in that, The step of inputting each group into its corresponding model to obtain the predicted probability value of each group includes: The at least one processing object in each group is sequentially input into the corresponding model to obtain a predicted probability value that corresponds one-to-one with each of the at least one processing object.
3. The model running method according to claim 2, characterized in that, After sequentially inputting at least one processing object from each group into the corresponding model to obtain a predicted probability value corresponding one-to-one with each of the at least one processing object, the method further includes: Determine the standardized score corresponding to each of the processing objects based on the predicted probability value; Based on the predicted probability value and the standardized score, determine the contribution score of each feature of each of the processed objects in the standardized score; The processed object is analyzed based on the standardized score and the contribution score.
4. The model running method according to claim 3, characterized in that, The step of determining the standardized score corresponding to each of the processing objects one-to-one based on the predicted probability value includes: The good-bad ratio of the processed object is determined based on the predicted probability value; The standardized score is determined based on the good-bad ratio.
5. The model running method according to claim 1, characterized in that, The step of splitting the first processing object to obtain at least one group includes: Obtain the number of processing objects included in the first processing object; Obtain the preset number of processing objects included in each group of the first type of model; Based on the number of processing objects included in the first processing object and the number of processing objects included in each preset group, the first processing object is split to obtain at least one group.
6. A model running device, characterized in that, The device includes: The acquisition module is used to acquire the first set of query statements corresponding to the first type of model, wherein the first type of model is any one of the at least one type of model in the batch processing machine; The first filtering module is used to compare the execution template of each first query statement in the first query statement set with each preset abnormal template, and filter out N first query statements without abnormalities based on the comparison results. The second filtering module is used to filter out the second query statement with the shortest query time from the N first query statements without anomalies. The execution module is used to execute the second query statement and obtain the first processing object corresponding to the first type of model; The running module is used to input the first processing object into the first type of model and obtain the running result of the first type of model. The running result of the first type of model is the predicted probability value of the first processing object, and the predicted probability value represents the probability of the user repaying the loan on time or the probability of the user taking out a loan. The first type of model includes at least one model. The operating module includes: A grouping unit is used to split the first processing object to obtain at least one group, and each group includes at least one processing object from the first processing object; A matching unit is used to determine the model corresponding to each group in the at least one group in the first type of model; The prediction unit is used to input each group into the corresponding model to obtain the predicted probability value of each group.
7. A model running device, characterized in that, The model running device includes: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, it implements the model running method as described in any one of claims 1-5.
8. A computer storage medium, characterized in that, The computer storage medium stores computer program instructions, which, when executed by a processor, implement the model running method as described in any one of claims 1-5.
9. A computer program product, characterized in that, The computer program product includes computer program instructions, which, when executed by a processor, implement the model running method according to any one of claims 1-5.