Hybrid model training method and device based on multi-modal features
By constructing a multimodal feature set and using a target decision tree to filter important features, and combining it with training prediction models of various different structures, the problem of insufficient model adaptability in existing technologies is solved, and the accuracy and generalization ability of classification prediction are improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-10
- Publication Date
- 2026-04-07
AI Technical Summary
Existing classification prediction models trained in the technology have a simple structure and are difficult to adapt to different types of model input features, resulting in reduced accuracy of classification prediction results.
By constructing a multimodal feature set, using a target decision tree model to filter important features, and combining various prediction models with different structures for training, a hybrid model training framework is formed.
This improves the generalization ability and accuracy of classification prediction results of the hybrid training model framework, giving full play to the complementary advantages of different types of features.
Smart Images

Figure CN121808373A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of machine learning technology, and more specifically, to a method and apparatus for training a hybrid model based on multimodal features. Background Technology
[0002] In many business scenarios, a classification prediction model is often trained to solve the target prediction problem based on the actual business needs. For example, in credit assessment, to solve the user classification problem, a classification prediction model needs to be trained based on the user's credit performance data to predict whether the user is a trustworthy user; while in fraud detection, to identify whether a user has fraud risk, a classification prediction model needs to be trained based on the user's historical behavior data to predict whether the user has fraud risk, and so on.
[0003] Currently, existing technologies for training classification prediction models typically use training data to directly train a single-structured classification prediction model. For example, training data can be used to train a LightGBM model or an LSTM (Long Short-Term Memory) network model. However, this commonly used single-model training method, due to the uniformity of the trained model structure, makes it difficult for the trained model to fully adapt to different types of input features. It fails to leverage the advantages of different model types in processing various feature types, resulting in reduced accuracy in the final classification prediction results. Summary of the Invention
[0004] In view of this, this application provides a hybrid model training method and apparatus based on multimodal features. On the one hand, by constructing data features with multiple feature dimensions as model input features, it is beneficial to give full play to the complementary advantages of different types of features. On the other hand, by training multiple classification prediction models with different structures on different feature sets at the same time, a hybrid training model framework with a heterogeneous integrated structure of multiple models can be obtained, thereby effectively improving the overall model generalization ability and the accuracy of classification prediction results of the hybrid training model framework.
[0005] To make the above-mentioned objectives, features and advantages of this application more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings.
[0006] In a first aspect, embodiments of this application provide a hybrid model training method based on multimodal features, applied to a hybrid model training framework, wherein the hybrid model training framework includes multiple prediction models; wherein the multiple prediction models are multiple prediction models with different structures used to solve the same target prediction problem, and the hybrid model training method includes: Based on multiple feature dimensions, data features corresponding to each feature dimension are extracted from the original training data to obtain a multimodal feature set composed of multiple data features; wherein, the original training data is determined according to the target prediction problem; The multimodal feature set is input into the target decision tree model. The target decision tree model outputs the importance score corresponding to each data feature in the multimodal feature set. Based on the importance score corresponding to each data feature, target data features that meet the preset importance screening conditions are extracted from the multimodal feature set to obtain the optimal feature set composed of the target data features. Based on the multimodal feature set, the multiple prediction models are trained respectively to obtain multiple trained first prediction models; Based on the optimal feature set, the multiple prediction models are trained respectively to obtain multiple trained second prediction models; The model framework consisting of multiple trained first prediction models and multiple trained second prediction models is used as the training framework for the trained hybrid model.
[0007] Secondly, embodiments of this application provide a hybrid model training device based on multimodal features, applied to a hybrid model training framework, wherein the hybrid model training framework includes multiple prediction models; wherein the multiple prediction models are multiple prediction models with different structures used to solve the same target prediction problem, and the hybrid model training device includes: The feature construction module is used to extract data features corresponding to each feature dimension from the original training data according to multiple feature dimensions, so as to obtain a multimodal feature set composed of multiple data features; wherein, the original training data is determined according to the target prediction problem; The feature filtering module is used to input the multimodal feature set into the target decision tree model, output the importance score corresponding to each data feature in the multimodal feature set through the target decision tree model, and extract target data features that meet the preset importance filtering conditions from the multimodal feature set according to the importance score corresponding to each data feature, so as to obtain the optimal feature set composed of the target data features. The model training module is used to train the multiple prediction models according to the multimodal feature set to obtain multiple trained first prediction models. Based on the optimal feature set, the multiple prediction models are trained respectively to obtain multiple trained second prediction models; The model framework consisting of multiple trained first prediction models and multiple trained second prediction models is used as the training framework for the trained hybrid model.
[0008] Thirdly, embodiments of this application provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the above-described hybrid model training method based on multimodal features.
[0009] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the above-described hybrid model training method based on multimodal features.
[0010] The technical solutions provided by the embodiments of this application may include the following beneficial effects: This application provides a hybrid model training method and apparatus based on multimodal features. On the one hand, by constructing multiple data features with different feature dimensions as model input features, it is beneficial to give full play to the complementary advantages of different types of features. On the other hand, by training multiple classification prediction models with different structures on different feature sets at the same time, a hybrid training model framework with a heterogeneous integrated structure of multiple models can be obtained, thereby effectively improving the overall model generalization ability and the accuracy of classification prediction results of the hybrid training model framework. Attached Figure Description
[0011] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0012] Figure 1 The diagram illustrates a flowchart of a hybrid model training method based on multimodal features provided in an embodiment of this application. Figure 2 A schematic diagram of the structure of a hybrid model training device based on multimodal features provided in an embodiment of this application is shown. Figure 3 This is a schematic diagram of the structure of an electronic device 300 provided in an embodiment of this application. Detailed Implementation
[0013] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the accompanying drawings in this application are for illustrative and descriptive purposes only and are not intended to limit the scope of protection of this application. Furthermore, it should be understood that the schematic drawings are not drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of this application. It should be understood that the operations in the flowcharts may not be implemented in sequence, and steps without logical contextual relationships may be reversed or implemented simultaneously. In addition, those skilled in the art, guided by the content of this application, may add one or more other operations to the flowcharts, or remove one or more operations from the flowcharts.
[0014] Furthermore, the described embodiments are merely some, not all, of the embodiments of this application. The components of the embodiments of this application described and illustrated herein can typically be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0015] It should be noted that the term "comprising" will be used in the embodiments of this application to indicate the presence of the features declared thereafter, but does not exclude the addition of other features.
[0016] To facilitate understanding of the embodiments of this application, a detailed description of a hybrid model training method and apparatus based on multimodal features provided in the embodiments of this application is given below.
[0017] Reference Figure 1 As shown, Figure 1 The diagram illustrates a flowchart of a hybrid model training method based on multimodal features provided in this application. The hybrid model training method is applied to a hybrid model training framework, which includes multiple prediction models. These multiple prediction models are prediction models with different structures used to solve the same target prediction problem. The hybrid model training method includes steps S101-S105; specifically: S101. Based on multiple feature dimensions, extract the corresponding data features from the original training data for each feature dimension to obtain a multimodal feature set composed of multiple data features.
[0018] In this embodiment, the hybrid model training framework consists of multiple prediction models with different model structures but the same model function (i.e., all used to solve the target prediction problem). In the hybrid model training framework, the same training data is used to train each prediction model simultaneously, resulting in a trained hybrid model training framework composed of multiple trained prediction models, which serves as the final model actually used to solve the target prediction problem.
[0019] Here, considering that different types of model input features have different data advantages when the prediction model performs target prediction (i.e., solves the target prediction problem), this application embodiment is based on multiple preset feature dimensions. By constructing multiple data features of different feature dimensions from the original training data as model input features, it is beneficial to realize the effective use of multi-dimensional information (that is, it is beneficial to give full play to the complementary advantages of different types of features).
[0020] It should be noted that the original training data mentioned above is determined based on the target prediction problem. For example, when the target prediction problem is to solve the user classification problem in a credit assessment scenario, the original training data can be the user's credit performance data. In this case, the multiple prediction models mentioned above can be multiple prediction models with different structures used to classify and predict whether a user is a trustworthy user. When the target prediction problem is to solve the classification problem of identifying whether a user has fraud risk in a fraud detection scenario, the original training data mentioned above can be the user's historical behavior data (e.g., historical transaction behavior data, claims behavior data, etc.). In this case, the multiple prediction models mentioned above can be multiple prediction models with different structures used to classify and predict whether a user has fraud risk.
[0021] Specifically, the aforementioned multiple feature dimensions may include: statistical feature dimensions, embedded feature dimensions, and similarity-derived feature dimensions. In this case, as an optional embodiment, step S101 can be performed according to the method shown in steps a1-a4 below: Step a1: Based on multiple preset statistical indicators under the statistical feature dimension, calculate the indicator values corresponding to the multiple preset statistical indicators from the original training data to obtain the statistical features composed of the indicator values corresponding to the multiple preset statistical indicators.
[0022] Here, the multiple preset statistical indicators included under the statistical feature dimension may include, but are not limited to: mean indicator, standard deviation indicator, trend feature indicator, and periodic feature indicator.
[0023] Specifically, when calculating the index value corresponding to the mean index from the original training data, the average value of the numerical data in the original training data can be calculated as the index value corresponding to the mean index.
[0024] Specifically, when calculating the index value corresponding to the standard deviation index from the original training data, the standard deviation of the numerical data in the original training data can be calculated as the index value corresponding to the standard deviation index.
[0025] Specifically, when calculating the index value corresponding to the trend feature index from the original training data, the data features that can represent the long-term trend of the time series data can be extracted from the time series data in the original training data as the index value corresponding to the trend feature index.
[0026] Specifically, when calculating the index value corresponding to the periodic feature index from the original training data, the local time series that matches the period length corresponding to the periodic index can be extracted from the time series data in the original training data, and the periodic change features that can represent the local time series can be extracted as the index value corresponding to the periodic feature index.
[0027] Step a2: Perform binning and WoE encoding on the original training data to obtain the bin ID feature and WoE encoded feature corresponding to the original training data. Then, fuse the bin ID feature and the WoE encoded feature through an embedding layer to obtain the fusion result as the embedding feature corresponding to the original training data.
[0028] Here, by binning the original training data, we can obtain the bin ID feature corresponding to the original training data. The bin ID feature is a discrete feature corresponding to the original training data.
[0029] Here, by performing WoE encoding on the original training data, we can obtain the WoE encoded features corresponding to the original training data. The WoE encoded features are a type of continuous feature corresponding to the original training data.
[0030] Specifically, binning and WoE encoding correspond to the two input paths of the embedding layer. After obtaining the bin ID features and WoE encoded features corresponding to the original training data in the embedding layer, the bin ID features and WoE encoded features can be fused through multi-path fusion to obtain the fused result as the embedding feature corresponding to the original training data.
[0031] Step a3: Extract features from the original training data to obtain the original features corresponding to the original training data, and calculate the similarity derived features corresponding to the original training data based on the original features and the embedded features.
[0032] Here, a general feature extraction method can be used to extract features from the above-mentioned original training data to obtain the original features corresponding to the original training data. In this embodiment, it is only necessary to ensure that the original features and the embedded features obtained in step a2 above have the same feature dimension (that is, to ensure that the original features can be used to perform feature calculations with the embedded features, for example, both the original features and the embedded features are 156-dimensional features). This embodiment does not limit the specific feature extraction method corresponding to the above-mentioned original features.
[0033] Specifically, when calculating the aforementioned similarity-derived features, the arithmetic mean of the original features and the embedded features can be calculated as the aforementioned similarity-derived features; alternatively, the sum of squares and the square root of the original features and the embedded features can be calculated as the aforementioned similarity-derived features.
[0034] Step a4: Standardize the statistical features, the embedded features, and the similarity-derived features to obtain feature dimension-aligned statistical features, embedded features, and similarity-derived features, and use the feature set composed of feature dimension-aligned statistical features, embedded features, and similarity-derived features as the multimodal feature set.
[0035] Here, the standardization processing methods include, but are not limited to, Min-Max standardization processing, Z-Score standardization processing, etc.; the purpose of standardization processing is to ensure that the feature dimensions of the above-mentioned various types of features (i.e., statistical features, embedded features, and similarity-derived features) can be aligned. This application embodiment does not impose any mandatory limitations on the specific standardization processing methods actually used.
[0036] S102, the multimodal feature set is input into the target decision tree model. The target decision tree model outputs the importance score corresponding to each data feature in the multimodal feature set. Based on the importance score corresponding to each data feature, target data features that meet the preset importance screening conditions are extracted from the multimodal feature set to obtain the optimal feature set composed of the target data features.
[0037] Here, the target decision tree model can be a pre-trained decision tree model based on the model input feature set constructed from the initial model training data; the specific data format of the initial model training data can refer to the aforementioned description of the original training data, and the method of constructing the model input feature set based on the initial model training data is the same as the method of constructing the multimodal feature set based on the original training data in step S101 above, and the repetition will not be repeated here.
[0038] Specifically, during model training, the decision tree model calculates the information gain of all types of data features in the input feature set at each node, and then selects the data feature with the largest information gain as the splitting feature. Therefore, the trained decision tree model (i.e., the target decision tree model) is itself a powerful feature selector. It can accumulate the sum of the information gains of each type of data feature in all splitting nodes as the importance score corresponding to each type of data feature. Since the model input feature set used by the target decision tree model during model training contains the same types of data features as the aforementioned multimodal feature set (for example, both contain statistical features, embedding features, and similarity-derived features), after inputting the aforementioned multimodal feature set into the target decision tree model, the target decision tree model can directly output the sum of the information gains of each data feature in all splitting nodes as the importance score corresponding to each type of data feature.
[0039] Specifically, after obtaining the importance score corresponding to each data feature, as an optional embodiment, redundant data features whose performance does not meet the preset importance screening conditions can be deleted from the multimodal feature set by means of index screening, as shown in steps b1-b2 below: Step b1: Calculate the index value of the multiple preset feature screening indicators for each data feature according to the multiple preset feature screening indicators.
[0040] Here, multiple preset feature selection indicators include, but are not limited to: IV (Information Value) value, information gain, and other indicators.
[0041] Step b2: Based on the index values of the multiple preset feature filtering indicators corresponding to each data feature, delete redundant data features with index values lower than the preset index threshold from the multimodal feature set to obtain the optimal feature set composed of the remaining data features.
[0042] Here, the preset threshold values corresponding to different preset feature filtering indicators are different. In one optional embodiment, data features whose index value of any preset feature filtering indicator is lower than the preset threshold value can be identified as redundant data features that need to be deleted. In another optional embodiment, data features whose index values of all preset feature filtering indicators are lower than the preset threshold value can also be identified as redundant data features that need to be deleted.
[0043] Specifically, the IV value can be used to measure the contribution of data features to solving the target prediction problem. When the IV value of a data feature is lower than a preset IV threshold (such as 0.02), it can be determined that the contribution of that data feature to solving the target prediction problem is low, and it can be eliminated as a redundant data feature.
[0044] Specifically, the information gain of a data feature can be the sum of the information gains of that data feature in all split nodes, directly output by the target decision tree model. In other words, the information gain of a data feature can also be the importance score of that data feature. When the importance score of a data feature is lower than the preset information gain threshold, it can be determined that the data feature has a low contribution to solving the target prediction problem and can be eliminated as a redundant data feature.
[0045] Specifically, after obtaining the importance score corresponding to each data feature, as another optional embodiment, the data features with the lowest importance score after each iteration of training can be removed from the multimodal feature set during the iterative training of the target decision tree model through recursive elimination, as shown in steps c1-c4 below. These data features are considered redundant and do not meet the preset importance screening conditions. Step c1: Based on the multimodal feature set, iteratively train the target decision tree model, and at the end of the iterative training, calculate the model performance index value corresponding to the target decision tree model.
[0046] Here, at the end of each iteration of training, the model performance of the target decision tree model needs to be evaluated by calculating the model performance index value. When the model performance evaluation result of the target decision tree model reaches the expected result (that is, the model performance index value is greater than or equal to the preset model performance index threshold), the iterative training process of the target decision tree model is terminated.
[0047] It should be noted that the specific model performance metrics corresponding to the above-mentioned model performance metrics are not unique. For example, the above-mentioned model performance metrics can be the AUC metric. Taking the target prediction problem of identifying whether a user's transaction data (i.e., the above multimodal feature set) belongs to fraudulent transactions or normal transactions as an example, if positive sample M represents transaction data belonging to fraudulent transactions and negative sample N represents transaction data belonging to normal transactions, then the AUC metric value indicates that the target decision tree model randomly selects one data feature belonging to a positive sample and one data feature belonging to a negative sample from the multimodal feature set, and the target decision tree model scores the data feature belonging to the positive sample higher than the data feature belonging to the negative sample. In this case, the AUC metric value can be used to intuitively reflect the target decision tree model's ability to distinguish between positive and negative samples.
[0048] Step c2: In response to the model performance index value being less than the preset model performance index threshold, based on the importance score corresponding to each data feature, delete the data feature with the lowest importance score from the multimodal feature set to obtain a new version of the multimodal feature set composed of the remaining data features.
[0049] Here, when the model performance index value is less than the preset model performance index threshold, it means that the target decision tree model has not yet reached its optimal state and still needs to be iterated and trained. At this time, based on the importance score corresponding to each data feature, the data features with the lowest importance score (i.e., the data features that contribute the least to the target decision tree model in solving the target prediction problem) can be deleted from the multimodal feature set, resulting in a new version of the multimodal feature set composed of the remaining data features. The new version of the multimodal feature set is then used as the model input feature set required for the next iteration of training of the target decision tree model.
[0050] Step c3: Based on the new version of the multimodal feature set, repeat the iterative training process of the target decision tree model until the model performance index value is greater than or equal to the preset model performance index threshold.
[0051] Here, repeat the method shown in steps c1-c3 above to iteratively train the target decision tree model until the model performance index value is greater than or equal to the preset model performance index threshold. At this point, it can be determined that the target decision tree model has reached the optimal state, and the iterative training process can be ended.
[0052] Step c4: In response to the model performance index value being greater than or equal to the preset model performance index threshold, the remaining subset of data features in the new version of the multimodal feature set is taken as the optimal feature set.
[0053] Here, after the target decision tree model finishes its iterative training, the remaining subset of data features in the new multimodal feature set (equivalent to the feature set composed of the remaining data features after multiple iterative training) can be used as the final optimal feature set.
[0054] In this embodiment of the application, as described above regarding the target decision tree model, the target decision tree model can output the sum of information gains generated by each data feature in all split nodes as the importance score corresponding to each type of data feature. To improve the accuracy of the importance score output by the target decision tree model for each data feature, as an optional embodiment, the importance scores corresponding to various data features output by the target decision tree model can be updated periodically according to the method shown in steps d1-d2 below. Specifically: Step d1: Input the new version of the multimodal feature set into the target decision tree model, and output the new version importance score corresponding to each data feature in the new version of the multimodal feature set through the target decision tree model.
[0055] Here, the specific execution method of step d1 is the same as the method of outputting the importance score corresponding to each data feature through the target decision tree model in step S102 above, and the repetition will not be repeated here.
[0056] Step d2: For each data feature included in the new version of the multimodal feature set, based on the importance score corresponding to that data feature and the new version of the importance score, the importance score corresponding to that data feature in the next iteration training of the target decision tree model is calculated using the exponential smoothing formula.
[0057] Specifically, the importance score for each data feature can be calculated using the exponential smoothing formula shown below during the next iteration of training the target decision tree model: ; in, It is a smoothing coefficient (usually 0.5-0.8), used to control the importance score obtained at historical time points (that is, the importance score corresponding to this type of data feature in step S102). This represents the importance score of this data feature at the historical time t-1 (which in step d2 is equivalent to the importance score of this data feature in step S102). This indicates the actual importance score corresponding to this type of data feature at the current time t (at this time in step d2, it is equivalent to the above-mentioned new version importance score corresponding to this type of data feature). This indicates the importance score of the data feature during the next iteration of training of the target decision tree model.
[0058] S103, based on the multimodal feature set, train the multiple prediction models respectively to obtain multiple trained first prediction models.
[0059] Here, the multimodal feature set is equivalent to the global feature set that has not been optimized by the target decision tree model.
[0060] It should be noted that the aforementioned multiple prediction models may include, but are not limited to: LightGBM model, LSTM model, and Transformer model; wherein, the aforementioned multiple first prediction models are equivalent to LightGBM model, LSTM model, and Transformer model trained using the aforementioned multimodal feature set.
[0061] It should be noted that different types of prediction models are suitable for different training methods. This application embodiment does not involve any modification to the training method of each prediction model. It only emphasizes the use of a multimodal feature set as the model input feature of each prediction model in step S103, and performs model training for each prediction model separately. This application embodiment does not limit the specific training method actually used for each prediction model.
[0062] Specifically, when training the LightGBM model, the gradient boosting framework can be used to train the LightGBM model (which is a type of decision tree model). The LightGBM model is suitable for processing large-scale structured data, and its advantages are fast training speed and low memory usage.
[0063] Specifically, when training an LSTM model, given its strength in handling features with temporal dependencies, the following gating mechanism can be used to train the LSTM model to capture long-term dependencies exhibited in time-series features from the input multimodal feature set:
[0064] The relevant explanations of the variables involved in the above gating mechanism formula are shown in Table 1 below:
[0065] Table 1 Specifically, when training a Transformer model, since the Transformer model excels at capturing global dependencies between different features using a self-attention mechanism, multi-head self-attention can be calculated using the following formula:
[0066] Where Q (Query): Query matrix, representing the content that needs to be focused on; K (Key): Key matrix, representing the content being retrieved; V (Value): Value matrix, representing the actual output content; : The dimension of the key vector, used to scale the dot product and prevent gradient vanishing; The dot product of the query and the key represents the relevance score. softmax: Converts scores into a probability distribution; h: Number of attention heads; : The output of the i-th attention head; : The linear transformation matrix of the Query corresponding to the i-th attention head; : The linear transformation matrix of the Key corresponding to the i-th attention head; : The linear transformation matrix of the Value corresponding to the i-th attention head; Concat: Concatenates the outputs of multiple attention heads along the feature dimension; : Linear transformation matrix for multi-head output.
[0067] S104, Based on the optimal feature set, train the multiple prediction models respectively to obtain multiple trained second prediction models.
[0068] It should be noted that the multiple prediction models mentioned above are the same multiple prediction models as those in step S103. The only difference is that the model input features of each prediction model have been changed from the previous global feature set (i.e., the multimodal feature set) to the optimal feature set (equivalent to the optimal feature subset selected from the above multimodal feature set). For the specific model training method of each prediction model, please refer to the content in step S103 above. The repetitions will not be repeated here.
[0069] S105, the model framework composed of multiple trained first prediction models and multiple second prediction models is used as the training framework of the trained hybrid model.
[0070] Here, after obtaining the trained hybrid model training framework, the model weight coefficients for each prediction model (i.e., each first prediction model and each second prediction model) in the hybrid model training framework can be dynamically allocated according to the methods shown in steps e1-e2 below. Specifically: Step e1: Input the model test data into the plurality of first prediction models and the plurality of second prediction models respectively, and obtain the classification prediction results output by the plurality of first prediction models and the plurality of second prediction models for the model test data respectively.
[0071] Here, the model test data can also be determined based on the target prediction problem; the specific construction method of the model test data can refer to the aforementioned method of constructing a multimodal feature set based on the original training data, and the repetition will not be repeated here.
[0072] Step e2: Based on the model test data and the classification prediction results, calculate the model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models respectively.
[0073] Here, for each prediction model (i.e., each first prediction model and each second prediction model), the index value of the model performance evaluation index corresponding to each prediction model can be calculated based on the classification prediction result output by the prediction model for the model test data (e.g., the probability value of predicting whether the model test data belongs to a positive sample or a negative sample) and the sample label carried in the model test data (e.g., used to label whether the model test data belongs to a positive sample or a negative sample). Then, based on the index weight of each model performance evaluation index, the model performance score corresponding to each prediction model is calculated by weighted summation.
[0074] Specifically, taking model performance evaluation metrics including AUC, KS, and PSI as examples, for each prediction model (i.e., each first prediction model and each second prediction model), the AUC, KS, and PSI values for each prediction model can be calculated as shown in Table 2 below:
[0075] Table 2 Specifically, taking the model performance evaluation metrics including AUC, KS, and PSI as examples, for each prediction model (i.e., each first prediction model and each second prediction model), the model performance score can be calculated based on the corresponding AUC, KS, and PSI values, as shown in the following formula: ; in, This represents the model performance score corresponding to the prediction model; This represents the AUC value corresponding to the prediction model; This represents the KS index value corresponding to the prediction model; PSI represents the PSI index value corresponding to the prediction model; This represents the weighting coefficient corresponding to the AUC indicator; This represents the weighting coefficient corresponding to the KS indicator; This represents the weighting coefficient corresponding to the PSI index.
[0076] Step e3: Normalize the model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models respectively to obtain the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models respectively.
[0077] Here, after obtaining the model performance score for each prediction model (i.e., each first prediction model and each second prediction model), the model weight coefficient for each prediction model can be obtained through normalization as shown in the following formula: ; in, This represents the model weight coefficient corresponding to the i-th prediction model; This represents the model performance score corresponding to the i-th prediction model; This represents the sum of the model performance scores for all prediction models (i.e., all first prediction models and all second prediction models), where n represents the number of prediction models.
[0078] It should be noted that when determining the model weight coefficients for each prediction model, the weight constraints can be adjusted according to the actual needs of solving the target prediction problem during the normalization process described above (for example, the weight constraints can be set as follows: the lower limit of the model weight coefficient is 0.1 and the upper limit is 0.6).
[0079] Based on this, in the actual model application stage, the trained hybrid model training framework can be used to solve the target prediction problem according to the following steps f1-f2: Step f1: Input the model application data into the trained hybrid model training framework, and use the multiple first prediction models and the multiple second prediction models to predict the classification results of the model application data, so as to obtain the target classification prediction results output by the multiple first prediction models and the multiple second prediction models respectively.
[0080] Here, the model application data can also be determined based on the target prediction problem; the specific construction method of the model application data can refer to the aforementioned method of constructing a multimodal feature set based on the original training data, and the repetition will not be repeated here.
[0081] Step f2: Based on the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models, and the target classification prediction results output by the plurality of first prediction models and the plurality of second prediction models, the final classification prediction result output by the trained hybrid model training framework for the model application data is calculated by weighted summation.
[0082] Here, after obtaining the target classification prediction results output by each prediction model (i.e., each first prediction model and each second prediction model), the final classification prediction results of the trained hybrid model training framework applied to the model using the data can be obtained through the following formula: ; in, It is the target classification prediction result output by the i-th prediction model; This represents the model weight coefficient corresponding to the i-th prediction model; n represents the total number of prediction models (i.e., all first prediction models and all second prediction models); This represents the final classification prediction result output by the trained hybrid model training framework.
[0083] In this embodiment of the application, for the above-mentioned trained hybrid model training framework, the cross-time stability of each prediction model in the above-mentioned trained hybrid model training framework can also be monitored and evaluated through the following steps: 1. Time window division: Set a sliding time window (e.g., the last 3 months) to periodically collect new model input data.
[0084] 2. Stability index calculation: For each prediction model, calculate the index values of stability indices such as PSI and AUC.
[0085] 3. Model adaptive adjustment: When the stability index is lower than the threshold (e.g., PSI>0.2), a model update strategy is triggered, such as retraining the prediction model or online learning.
[0086] Based on the above-mentioned hybrid model training method based on multimodal features provided in the embodiments of this application, on the one hand, by constructing multiple data features of different feature dimensions as model input features, it is beneficial to give full play to the complementary advantages of different types of features; on the other hand, by simultaneously training multiple classification prediction models with different structures on different feature sets, a hybrid training model framework with a heterogeneous integrated structure of multiple models can be obtained, thereby effectively improving the overall model generalization ability and the accuracy of classification prediction results of the hybrid training model framework.
[0087] Based on the same inventive concept, this application also provides a multimodal feature-based hybrid model training device corresponding to the above-mentioned multimodal feature-based hybrid model training method. Since the principle of solving the problem by the multimodal feature-based hybrid model training device in the embodiments of this application is similar to that of the above-mentioned multimodal feature-based hybrid model training method in the embodiments of this application, the implementation of the multimodal feature-based hybrid model training device can refer to the implementation of the above-mentioned multimodal feature-based hybrid model training method, and the repeated parts will not be described again.
[0088] Reference Figure 2 As shown, Figure 2 This illustration shows a schematic diagram of a hybrid model training device based on multimodal features provided in an embodiment of this application. The hybrid model training device is applied to a hybrid model training framework, which includes multiple prediction models. These multiple prediction models are prediction models with different structures used to solve the same target prediction problem. The hybrid model training device includes: The feature construction module 201 is used to extract data features corresponding to each feature dimension from the original training data according to multiple feature dimensions, so as to obtain a multimodal feature set composed of multiple data features; wherein, the original training data is determined according to the target prediction problem; The feature filtering module 202 is used to input the multimodal feature set into the target decision tree model, output the importance score corresponding to each data feature in the multimodal feature set through the target decision tree model, and extract the target data features that meet the preset importance filtering conditions from the multimodal feature set according to the importance score corresponding to each data feature, so as to obtain the optimal feature set composed of the target data features. The model training module 203 is used to train the multiple prediction models according to the multimodal feature set to obtain multiple trained first prediction models. Based on the optimal feature set, the multiple prediction models are trained respectively to obtain multiple trained second prediction models; The model framework consisting of multiple trained first prediction models and multiple trained second prediction models is used as the training framework for the trained hybrid model.
[0089] In an optional implementation, when extracting data features corresponding to each feature dimension from the original training data according to multiple feature dimensions to obtain a multimodal feature set composed of multiple data features, the feature construction module 201 is used to: Based on multiple preset statistical indicators under the statistical feature dimension, the indicator values corresponding to the multiple preset statistical indicators are calculated from the original training data to obtain the statistical features composed of the indicator values corresponding to the multiple preset statistical indicators. The original training data is binned and WoE encoded to obtain bin ID features and WoE encoded features corresponding to the original training data. The bin ID features and WoE encoded features are then fused through an embedding layer to obtain the fused result as the embedding feature corresponding to the original training data. Feature extraction is performed on the original training data to obtain the original features corresponding to the original training data, and similarity-derived features corresponding to the original training data are calculated based on the original features and the embedded features. The statistical features, the embedded features, and the similarity-derived features are standardized to obtain feature dimension-aligned statistical features, embedded features, and similarity-derived features. The feature set composed of feature dimension-aligned statistical features, embedded features, and similarity-derived features is used as the multimodal feature set.
[0090] In an optional implementation, when extracting target data features that satisfy preset importance screening conditions from the multimodal feature set based on the importance score corresponding to each data feature, and obtaining an optimal feature set composed of the target data features, the feature screening module 202 is used to: Based on multiple preset feature screening indicators, calculate the index value of each preset feature screening indicator corresponding to each data feature; Based on the index values of the multiple preset feature filtering indicators corresponding to each data feature, redundant data features with index values lower than the preset index threshold are deleted from the multimodal feature set to obtain the optimal feature set composed of the remaining data features.
[0091] In an optional implementation, when extracting target data features that satisfy preset importance screening conditions from the multimodal feature set based on the importance score corresponding to each data feature, and obtaining an optimal feature set composed of the target data features, the feature screening module 202 is further configured to: Based on the multimodal feature set, the target decision tree model is iteratively trained, and at the end of the iterative training, the model performance index value corresponding to the target decision tree model is calculated; In response to the model performance index value being less than a preset model performance index threshold, based on the importance score corresponding to each data feature, the data feature with the lowest importance score is deleted from the multimodal feature set, resulting in a new version of the multimodal feature set composed of the remaining data features; Based on the new multimodal feature set, the target decision tree model is iteratively trained repeatedly until the model performance index value is greater than or equal to the preset model performance index threshold. In response to the model performance index value being greater than or equal to a preset model performance index threshold, the remaining subset of data features in the new version of the multimodal feature set is taken as the optimal feature set.
[0092] In an optional implementation, during the iterative training of the target decision tree model based on the new multimodal feature set, the feature selection module 202 is further configured to: The new version of the multimodal feature set is input into the target decision tree model, and the target decision tree model outputs the new importance score corresponding to each data feature in the new version of the multimodal feature set; For each data feature included in the new version of the multimodal feature set, the importance score of that data feature during the next iteration of training of the target decision tree model is calculated using an exponential smoothing formula, based on the importance score corresponding to that data feature and the new version of the importance score.
[0093] In an optional implementation, the hybrid model training apparatus further includes a dynamic weight allocation module, wherein the dynamic weight allocation module is used to: The model test data is input into the plurality of first prediction models and the plurality of second prediction models respectively to obtain the classification prediction results output by the plurality of first prediction models and the plurality of second prediction models for the model test data respectively; wherein, the model test data is determined according to the target prediction problem; Based on the model test data and the classification prediction results, calculate the model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models respectively; The model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models are normalized to obtain the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models.
[0094] In an optional implementation, the hybrid model training apparatus further includes a model application module, wherein the model application module is used for: The model application data is input into the trained hybrid model training framework, and the multiple first prediction models and multiple second prediction models respectively predict the classification result to which the model application data belongs, to obtain the target classification prediction result output by the multiple first prediction models and multiple second prediction models respectively; wherein, the model application data is determined according to the target prediction problem; Based on the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models, and the target classification prediction results output by the plurality of first prediction models and the plurality of second prediction models, the final classification prediction result output by the trained hybrid model training framework for the model application data is calculated by weighted summation.
[0095] like Figure 3 As shown, this application provides an electronic device 300 for executing the hybrid model training method based on multimodal features in this application. The device includes a memory 301, a processor 302, and a computer program stored in the memory 301 and executable on the processor 302. The memory 301 and the processor 302 are connected via a bus. When the processor 302 executes the computer program, it implements the steps of the hybrid model training method based on multimodal features.
[0096] Specifically, the memory 301 and processor 302 mentioned above can be general-purpose memory and processor, without any specific limitations. When the processor 302 runs the computer program stored in the memory 301, it can execute the above-mentioned hybrid model training method based on multimodal features.
[0097] Corresponding to the hybrid model training method based on multimodal features in this application, this application embodiment also provides a computer-readable storage medium storing a computer program, which is executed by a processor to perform the steps of the above-described hybrid model training method based on multimodal features.
[0098] Specifically, the storage medium can be a general-purpose storage medium, such as a removable disk or hard disk. When the computer program on the storage medium is run, it can execute the above-mentioned hybrid model training method based on multimodal features.
[0099] In the embodiments provided in this application, it should be understood that the disclosed systems and methods can be implemented in other ways. The system embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and there may be other division methods in actual implementation. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Additionally, the coupling or direct coupling or communication connection shown or discussed may be through some communication interface; the indirect coupling or communication connection between systems or units may be electrical, mechanical, or other forms.
[0100] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0101] In addition, the functional units in the embodiments provided in this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0102] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0103] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. In addition, the terms "first", "second", "third", etc. are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0104] Finally, it should be noted that the above-described embodiments are merely specific implementations of this application, used to illustrate the technical solutions of this application, and not to limit them. The protection scope of this application is not limited thereto. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this application; and these modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application. All should be covered within the protection scope of this application. Therefore, the protection scope of this application should be determined by the protection scope of the claims.
Claims
1. A hybrid model training method based on multimodal features, characterized in that, An application is made to a hybrid model training framework, which includes multiple prediction models; wherein the multiple prediction models are multiple prediction models with different structures used to solve the same target prediction problem, and the hybrid model training method includes: Based on multiple feature dimensions, data features corresponding to each feature dimension are extracted from the original training data to obtain a multimodal feature set composed of multiple data features; wherein, the original training data is determined according to the target prediction problem; The multimodal feature set is input into the target decision tree model. The target decision tree model outputs the importance score corresponding to each data feature in the multimodal feature set. Based on the importance score corresponding to each data feature, target data features that meet the preset importance screening conditions are extracted from the multimodal feature set to obtain the optimal feature set composed of the target data features. Based on the multimodal feature set, the multiple prediction models are trained respectively to obtain multiple trained first prediction models; Based on the optimal feature set, the multiple prediction models are trained respectively to obtain multiple trained second prediction models; The model framework consisting of multiple trained first prediction models and multiple trained second prediction models is used as the training framework for the trained hybrid model.
2. The hybrid model training method according to claim 1, characterized in that, The process involves extracting data features corresponding to each feature dimension from the original training data based on multiple feature dimensions, resulting in a multimodal feature set composed of various data features, including: Based on multiple preset statistical indicators under the statistical feature dimension, the indicator values corresponding to the multiple preset statistical indicators are calculated from the original training data to obtain the statistical features composed of the indicator values corresponding to the multiple preset statistical indicators. The original training data is binned and WoE encoded to obtain bin ID features and WoE encoded features corresponding to the original training data. The bin ID features and WoE encoded features are then fused through an embedding layer to obtain the fused result as the embedding feature corresponding to the original training data. Feature extraction is performed on the original training data to obtain the original features corresponding to the original training data, and similarity-derived features corresponding to the original training data are calculated based on the original features and the embedded features. The statistical features, the embedded features, and the similarity-derived features are standardized to obtain feature dimension-aligned statistical features, embedded features, and similarity-derived features. The feature set composed of feature dimension-aligned statistical features, embedded features, and similarity-derived features is used as the multimodal feature set.
3. The hybrid model training method according to claim 1, characterized in that, The step of extracting target data features that meet preset importance screening conditions from the multimodal feature set based on the importance score corresponding to each data feature, and obtaining an optimal feature set composed of the target data features, includes: Based on multiple preset feature screening indicators, calculate the index value of each preset feature screening indicator corresponding to each data feature; Based on the index values of the multiple preset feature filtering indicators corresponding to each data feature, redundant data features with index values lower than the preset index threshold are deleted from the multimodal feature set to obtain the optimal feature set composed of the remaining data features.
4. The hybrid model training method according to claim 1, characterized in that, The step of extracting target data features that meet preset importance screening conditions from the multimodal feature set based on the importance score corresponding to each data feature, and obtaining an optimal feature set composed of the target data features, includes: Based on the multimodal feature set, the target decision tree model is iteratively trained, and at the end of the iterative training, the model performance index value corresponding to the target decision tree model is calculated; In response to the model performance index value being less than a preset model performance index threshold, based on the importance score corresponding to each data feature, the data feature with the lowest importance score is deleted from the multimodal feature set, resulting in a new version of the multimodal feature set composed of the remaining data features; Based on the new multimodal feature set, the target decision tree model is iteratively trained repeatedly until the model performance index value is greater than or equal to the preset model performance index threshold. In response to the model performance index value being greater than or equal to a preset model performance index threshold, the remaining subset of data features in the new version of the multimodal feature set is taken as the optimal feature set.
5. The hybrid model training method according to claim 4, characterized in that, In the process of iteratively training the target decision tree model based on the new multimodal feature set, the hybrid model training method further includes: The new version of the multimodal feature set is input into the target decision tree model, and the target decision tree model outputs the new importance score corresponding to each data feature in the new version of the multimodal feature set; For each data feature included in the new version of the multimodal feature set, the importance score of that data feature during the next iteration of training of the target decision tree model is calculated using an exponential smoothing formula, based on the importance score corresponding to that data feature and the new version of the importance score.
6. The hybrid model training method according to claim 1, characterized in that, After obtaining the trained hybrid model training framework, the model training method further includes: The model test data is input into the plurality of first prediction models and the plurality of second prediction models respectively to obtain the classification prediction results output by the plurality of first prediction models and the plurality of second prediction models for the model test data respectively; wherein, the model test data is determined according to the target prediction problem; Based on the model test data and the classification prediction results, calculate the model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models respectively; The model performance scores corresponding to the plurality of first prediction models and the plurality of second prediction models are normalized to obtain the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models.
7. The hybrid model training method according to claim 6, characterized in that, The model training method also includes: The model application data is input into the trained hybrid model training framework, and the multiple first prediction models and multiple second prediction models respectively predict the classification result to which the model application data belongs, to obtain the target classification prediction result output by the multiple first prediction models and multiple second prediction models respectively; wherein, the model application data is determined according to the target prediction problem; Based on the model weight coefficients corresponding to the plurality of first prediction models and the plurality of second prediction models, and the target classification prediction results output by the plurality of first prediction models and the plurality of second prediction models, the final classification prediction result output by the trained hybrid model training framework for the model application data is calculated by weighted summation.
8. A hybrid model training device based on multimodal features, characterized in that, An application is made to a hybrid model training framework, which includes multiple prediction models; wherein the multiple prediction models are multiple prediction models with different structures used to solve the same target prediction problem, and the hybrid model training device includes: The feature construction module is used to extract data features corresponding to each feature dimension from the original training data according to multiple feature dimensions, so as to obtain a multimodal feature set composed of multiple data features; wherein, the original training data is determined according to the target prediction problem; The feature filtering module is used to input the multimodal feature set into the target decision tree model, output the importance score corresponding to each data feature in the multimodal feature set through the target decision tree model, and extract target data features that meet the preset importance filtering conditions from the multimodal feature set according to the importance score corresponding to each data feature, so as to obtain the optimal feature set composed of the target data features. The model training module is used to train the multiple prediction models according to the multimodal feature set to obtain multiple trained first prediction models. Based on the optimal feature set, the multiple prediction models are trained respectively to obtain multiple trained second prediction models; The model framework consisting of multiple trained first prediction models and multiple trained second prediction models is used as the training framework for the trained hybrid model.
9. An electronic device, characterized in that, include: The device includes a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the memory via the bus. When the machine-readable instructions are executed by the processor, they perform the steps of the hybrid model training method based on multimodal features as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the hybrid model training method based on multimodal features as described in any one of claims 1 to 7.