Account data processing method and device, computer device, and storage medium

CN122926094APending Publication Date: 2026-10-16TENCENT TECHNOLOGY (SHENZHEN) CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510429013.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-07
Publication Date
2026-10-16

AI Technical Summary

Technical Problem

[0003]相关技术中,基于用户账号的数据以及人工智能的风险预测模型完成上述预测,然而,风险预测模型的预测准确度不高

Benefits of technology

[0070] The aforementioned account data processing method, apparatus, computer equipment, storage medium, and computer program product train a first initial behavior prediction model using first resource interaction forward samples and a second initial behavior prediction model using first resource interaction backward samples. The resource interaction forward samples are resource interaction data generated by a sample account without resource borrowing service permissions, while the resource interaction backward samples are resource interaction data generated by the matched sample account with resource borrowing service permissions. Therefore, the resource interaction backward samples belong to the resource interaction data generated by the sample account with resource borrowing service permissions. This resource interaction data includes resource interaction data generated for the resource borrowing service, has a stronger correlation with the resource borrowing service, and can reflect the true situation of the target behavior of the sample account after using the resource borrowing service. Next, based on the second initial behavior prediction model, this embodiment integrates the additional information contained in the second resource interaction data samples into the first initial behavior prediction model to obtain a target behavior prediction model, which can improve the prediction accuracy of the target behavior prediction model. Furthermore, in constructing the loss, this embodiment of the disclosure not only utilizes the hard loss between the first target behavior prediction result and the actual result, but also utilizes the soft loss between the first target behavior prediction result and the second target behavior prediction result. The latter reflects the correlation information between the prediction results. The combination of the two losses can further improve the prediction accuracy of the target behavior prediction model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122926094A_ABST
    Figure CN122926094A_ABST
Patent Text Reader

Abstract

The application relates to an account data processing method and device, computer equipment, a storage medium and a computer program product. The method comprises the following steps: obtaining a first initial behavior prediction model and a second initial behavior prediction model; inputting a second resource interaction forward sample into the first initial behavior prediction model to output a first target behavior prediction result; inputting a second resource interaction backward sample into the second initial behavior prediction model to output a second target behavior prediction result; based on a first difference between the first target behavior prediction result and the second target behavior prediction result, a second difference between the first target behavior prediction result and an actual result corresponding to the second resource interaction forward sample, iteratively training the first initial behavior prediction model to obtain a target behavior prediction model. The application can improve the accuracy of the target behavior prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and in particular to an account data processing method, apparatus, computer equipment, storage medium, and computer program product. Background Technology

[0002] During resource exchange, if a user lacks sufficient resources, they can borrow resources from a third-party platform and return them within a specified period. If the user fails to return the borrowed resources within the specified period, the user is deemed to have engaged in targeted behavior. To mitigate this risk, third-party platforms often predict whether a user will engage in targeted behavior before borrowing resources.

[0003] In related technologies, risk prediction models based on user account data and artificial intelligence are used to make the above predictions. However, the accuracy of these risk prediction models is not high. Summary of the Invention

[0004] Therefore, it is necessary to provide an account data method, apparatus, computer device, computer-readable storage medium, and computer program product that can improve the accuracy of target behavior prediction models in response to the above-mentioned technical problems.

[0005] Firstly, this application provides a method for processing account data. The method includes:

[0006] Obtain a first initial behavior prediction model trained based on forward samples of the first resource interaction, and a second initial behavior prediction model trained based on backward samples of the first resource interaction.

[0007] The second resource interaction forward sample is input into the first initial behavior prediction model, and the first target behavior prediction result is output.

[0008] The second resource interaction backward sample is input into the second initial behavior prediction model, and the second target behavior prediction result is output; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the matched sample account with the resource borrowing service permission.

[0009] Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

[0010] Secondly, this application provides a method for processing account data. The method includes:

[0011] In response to a request for resource borrowing service permissions from an account to be processed, obtain the resource interaction forward data corresponding to the account to be processed;

[0012] The forward data of resource interaction is input into a target behavior prediction model to predict the target behavior of the account to be processed. The target behavior prediction model is obtained by iteratively training a first initial behavior prediction model based on a first difference between a first target behavior prediction result and a second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the second forward resource interaction sample. The first target behavior prediction result is obtained by inputting the second forward resource interaction sample into the first initial behavior prediction model and outputting it. The second target behavior prediction result is obtained by inputting the second backward resource interaction sample into the second initial behavior prediction model and outputting it. The first initial behavior prediction model is trained based on the first forward resource interaction sample, and the second initial behavior prediction model is trained based on the first backward resource interaction sample. The forward resource interaction sample is the resource interaction data generated by the sample account without resource borrowing service permissions, and the backward resource interaction sample is the resource interaction data generated by the sample account with resource borrowing service permissions.

[0013] Based on the target behavior of the account to be processed, determine the result of the resource borrowing service permission request corresponding to the request information.

[0014] Thirdly, this application also provides an account data processing apparatus, the apparatus comprising:

[0015] The first acquisition module is used to acquire a first initial behavior prediction model trained based on forward samples of the first resource interaction, and a second initial behavior prediction model trained based on backward samples of the first resource interaction.

[0016] The first prediction module is used to input the second resource interaction forward sample into the first initial behavior prediction model and output the first target behavior prediction result.

[0017] The second prediction module is used to input the second resource interaction backward sample into the second initial behavior prediction model and output the second target behavior prediction result; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the matched sample account with the resource borrowing service permission.

[0018] The first processing module is used to iteratively train the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

[0019] In one embodiment, the apparatus further includes a second processing module, the second processing module being used for:

[0020] The first offset weight is used to perform a ratio calculation on the actual result corresponding to the second resource interaction forward sample and the first target behavior prediction result, and the result of the ratio calculation is mapped to obtain the first offset weight corresponding to each prediction category; wherein, the first offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the actual result.

[0021] Based on the first offset weights corresponding to each prediction category, the actual results corresponding to each prediction category are fused to obtain the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample.

[0022] In one embodiment, the apparatus further includes a third processing module, the third processing module being used for:

[0023] Based on the first smoothing coefficient, the prediction result of the first target behavior is smoothed to obtain the processed prediction result of the first target behavior.

[0024] Based on the second smoothing coefficient, the prediction result of the second target behavior is smoothed to obtain the processed prediction result of the second target behavior.

[0025] The second target behavior prediction result of the processing is proportionally calculated with the corresponding first target behavior prediction result of the processing. The result of the proportional calculation is then mapped to obtain the second offset weight corresponding to each prediction category. The second offset weight is used to characterize the degree of offset between the first target behavior prediction result and the second target behavior prediction result.

[0026] Based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain the first difference between the first target behavior prediction result and the second target behavior prediction result.

[0027] In one embodiment, the first processing module is configured to:

[0028] Weighted factor combinations are obtained from a preset search range; wherein, the weighted factor combination includes a first weighted factor and a second weighted factor;

[0029] Based on each weighted factor combination, the first difference and the second difference are fused to obtain a first joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; and the second difference is the difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample.

[0030] Based on each of the first joint losses, the first initial behavior prediction models are iteratively trained; the first initial behavior prediction model with the highest standard evaluation coefficient is determined as the target behavior prediction model.

[0031] In one embodiment, the first initial behavior prediction model includes a first encoder network and a first classifier network; the second initial behavior prediction model includes a second encoder network and a second classifier network; the first prediction module is further configured to:

[0032] Based on the first encoder network, feature extraction is performed on the forward samples of the second resource interaction to obtain a first feature vector. Based on the first classifier network, the first feature vector is classified to obtain a first target behavior prediction result.

[0033] The second prediction module is also used for:

[0034] Based on the second encoder network, feature extraction is performed on the second resource interaction backward sample to obtain a second feature vector. Based on the second classifier network, the second feature vector is classified to obtain the second target behavior prediction result.

[0035] The first processing module is also used for:

[0036] Based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0037] In one embodiment, the first processing module is further configured to:

[0038] The weight coefficient combinations are obtained from the preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient.

[0039] Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; and the third difference is the difference between the first feature vector and the second feature vector.

[0040] Based on each of the second joint losses, the first initial behavior prediction model is iteratively trained to determine the first initial behavior prediction model with the highest standard evaluation coefficient, which is then used as the target behavior prediction model.

[0041] In one embodiment, the first processing module is further configured to:

[0042] The first feature value, the first feature key value, and the first feature query vector are extracted from the first feature vector based on the first attention network.

[0043] Based on the correlation between the first feature key value and the first feature query vector, the first feature value is weighted and fused to obtain the processed first feature vector;

[0044] The second feature value, the second feature key value, and the second feature query vector are extracted from the second feature vector based on the second attention network.

[0045] Based on the correlation between the second feature key value and the second feature query vector, the second feature value is weighted and fused to obtain the processed second feature vector;

[0046] Based on the third difference between the first feature vector and the second feature vector processed, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0047] In one embodiment, the apparatus further includes a first training module, the first training module being used for:

[0048] Obtain a sample set; the sample set includes the first resource interaction backward sample and the labeled target behavior tags;

[0049] The first resource interaction post-sample is input into the first original behavior prediction model, and the third target behavior prediction result is output.

[0050] Based on the difference between the third target behavior prediction result and the target behavior label, the first original behavior prediction model is iteratively adjusted until the difference meets the preset requirements to obtain the second initial behavior prediction model.

[0051] In one embodiment, the apparatus further includes a second training module, the second training module being used for:

[0052] Obtain a sample set; the sample set includes the first resource interaction backward sample;

[0053] Obtain the first positive sample, the second positive sample, and the negative sample from the sample set;

[0054] Based on the second original behavior prediction model, feature extraction is performed on the first positive sample to obtain the third feature vector;

[0055] Based on the second original behavior prediction model, feature extraction is performed on the second positive sample to obtain the fourth feature vector;

[0056] Based on the second original behavior prediction model, feature extraction is performed on the negative sample to obtain the fifth feature vector;

[0057] Based on the distance between the third feature vector and the fourth feature vector, and the distance between the third feature vector and the fifth feature vector, a contrastive loss is constructed;

[0058] Based on the contrast loss, the second original behavior prediction model is iteratively adjusted until the difference meets the preset requirements, thus obtaining the second initial behavior prediction model.

[0059] In one embodiment, the first processing module is further configured to:

[0060] Obtain a third initial behavior prediction model trained based on the backward samples of the first resource interaction; wherein the type of the third initial behavior prediction model includes at least one.

[0061] The first resource interaction feedback sample is input into each of the third initial behavior prediction models, and the prediction results of each third target behavior are output.

[0062] Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, the first initial behavior prediction model is iteratively trained based on the third differences between the first target behavior prediction result and each of the third target behavior prediction results.

[0063] Fourthly, this application also provides an account data processing apparatus, the apparatus comprising:

[0064] The second acquisition module is used to acquire the resource interaction forward data corresponding to the account to be processed in response to the request information of the resource borrowing service permission of the account to be processed.

[0065] The third prediction module is used to input the forward data of resource interaction into the target behavior prediction model to predict the target behavior of the account to be processed; wherein, the target behavior prediction model is obtained by iteratively training a first initial behavior prediction model based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the second forward sample of resource interaction; wherein, the first target behavior prediction result is obtained by inputting the second forward sample of resource interaction into the first initial behavior prediction model and outputting it; the second target behavior prediction result is obtained by inputting the second backward sample of resource interaction into the second initial behavior prediction model and outputting it; the first initial behavior prediction model is trained based on the first forward sample of resource interaction, and the second initial behavior prediction model is trained based on the first backward sample of resource interaction; wherein, the forward sample of resource interaction is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the backward sample of resource interaction is the resource interaction data generated by the sample account with the resource borrowing service permission.

[0066] The determination module is used to determine the resource borrowing service permission request result corresponding to the request information based on the target behavior of the account to be processed.

[0067] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the method described in any embodiment of this disclosure.

[0068] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, implements the steps of the methods described in any embodiment of this disclosure.

[0069] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the steps of the methods described in any embodiment of this disclosure.

[0070] The aforementioned account data processing method, apparatus, computer equipment, storage medium, and computer program product train a first initial behavior prediction model using first resource interaction forward samples and a second initial behavior prediction model using first resource interaction backward samples. The resource interaction forward samples are resource interaction data generated by a sample account without resource borrowing service permissions, while the resource interaction backward samples are resource interaction data generated by the matched sample account with resource borrowing service permissions. Therefore, the resource interaction backward samples belong to the resource interaction data generated by the sample account with resource borrowing service permissions. This resource interaction data includes resource interaction data generated for the resource borrowing service, has a stronger correlation with the resource borrowing service, and can reflect the true situation of the target behavior of the sample account after using the resource borrowing service. Next, based on the second initial behavior prediction model, this embodiment integrates the additional information contained in the second resource interaction data samples into the first initial behavior prediction model to obtain a target behavior prediction model, which can improve the prediction accuracy of the target behavior prediction model. Furthermore, in constructing the loss, this embodiment of the disclosure not only utilizes the hard loss between the first target behavior prediction result and the actual result, but also utilizes the soft loss between the first target behavior prediction result and the second target behavior prediction result. The latter reflects the correlation information between the prediction results. The combination of the two losses can further improve the prediction accuracy of the target behavior prediction model. Attached Figure Description

[0071] Figure 1 This is an application environment diagram for account data processing in one embodiment;

[0072] Figure 2 This is a flowchart illustrating an account data processing method in one embodiment;

[0073] Figure 3 This is a flowchart illustrating an account data processing method in another embodiment;

[0074] Figure 4 This is a flowchart illustrating an account data processing method in another embodiment;

[0075] Figure 5 This is an architecture diagram of a target behavior prediction model in one embodiment;

[0076] Figure 6 This is a flowchart illustrating an account data processing method in another embodiment;

[0077] Figure 7 This is a flowchart illustrating an account data processing method in another embodiment;

[0078] Figure 8 This is an architecture diagram of the target behavior prediction model in another embodiment;

[0079] Figure 9 This is a flowchart illustrating an account data processing method in another embodiment;

[0080] Figure 10 This is a structural block diagram of an account data processing device in one embodiment;

[0081] Figure 11 This is a structural block diagram of an account data processing device in one embodiment;

[0082] Figure 12 This is an internal structural diagram of a computer device in one embodiment;

[0083] Figure 13 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0084] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0085] The account data processing method provided in this application embodiment can be applied to, for example... Figure 1In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104 or placed on the cloud or other servers. Terminal 102 sends a resource borrowing service permission request to server 104 for the account to be processed. Server 104 obtains the resource interaction forward data of the account to be processed and inputs the resource interaction forward data into a target behavior prediction model to predict the target behavior of the account to be processed. The target resource prediction model can be obtained by: obtaining a first initial behavior prediction model trained based on the first resource interaction forward samples, and a second initial behavior prediction model trained based on the first resource interaction backward samples. The second resource interaction forward samples are input into the first initial behavior prediction model to output a first target behavior prediction result; the second resource interaction backward samples are input into the second initial behavior prediction model to output a second target behavior prediction result. Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained to obtain the target behavior prediction model. Optionally, the target behavior prediction model can also be deployed on the terminal 102 to predict the target behavior of the account to be processed based on the resource interaction forward data of the account to be processed. The terminal 102 can be, but is not limited to, various desktop computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices can be smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, etc. Portable wearable devices can be smartwatches, smart bracelets, head-mounted devices, etc. The server 104 can be implemented using a standalone server or a server cluster composed of multiple servers.

[0086] In one embodiment, such as Figure 2 As shown, an account data processing method is provided, which can be applied to... Figure 1 Taking server 104 or terminal 102 as an example, the following steps are included:

[0087] Step S201: Obtain the first initial behavior prediction model trained based on the forward samples of the first resource interaction, and the second initial behavior prediction model trained based on the backward samples of the first resource interaction.

[0088] In practice, an account can apply for resource borrowing services from a resource borrower before or during resource interaction. Upon successful application, the account borrows the target amount of resources to complete the resource interaction and returns the borrowed resources to the resource borrower within a specified period. The account can continue to use the resource borrowing service for subsequent resource interactions. Conversely, upon receiving a resource borrowing service application, the resource borrower reviews the account. If approved, the resource borrower grants the account resource borrowing service permissions, indicating that the account can use the service. During the review process, if the account engages in the target activity, resource borrowing service permissions may not be granted.

[0089] The target behavior can be the failure of an account to return a specified amount of resources within a specified period after borrowing resources from a resource borrower. In its implementation, the first initial behavior prediction model can be trained using machine learning on the feedforward samples of the first resource interaction. Specifically, the first initial behavior prediction model can include an encoder network and a classifier network. The encoder network can include convolutional neural networks, autoencoders, Transformer encoders, recurrent neural networks, etc. Examples of convolutional neural networks include VGG, ResNet, and Inception. Examples of autoencoders include denoising autoencoders, variational autoencoders, and convolutional autoencoders. Examples of recurrent neural networks include RNNs, LSTMs, and GRUs. The classifier network can include fully connected classifiers (MLPs), support vector machines (SVMs), lightweight classifiers (SENet), etc.

[0090] In an exemplary embodiment, a first resource interaction feedforward sample of a sample account is input into a first original behavior prediction model. The first original behavior prediction model outputs a prediction result. The prediction result may include whether the sample account will perform the target behavior or not. The first resource interaction feedforward sample corresponds to a labeled result, which may include whether the sample account actually performed the target behavior or not. Based on the difference between the prediction result and the corresponding actual result, the network parameters in the encoder network and classifier network are iteratively adjusted until the difference meets a preset requirement, thus obtaining a first initial behavior prediction model.

[0091] Similarly, the training method for the second initial behavior prediction model can also employ the supervised machine learning approach described above. Therefore, the second initial behavior prediction model can consist of an encoder network and a classifier network. Furthermore, the second initial behavior prediction model can also be trained unsupervised based on the backward samples of the first resource interaction. Specifically, in an exemplary embodiment, the second initial behavior prediction model may include an encoder network and a decoder network. The backward samples of the first resource interaction are input into the second initial behavior prediction model, and a reconstructed backward sample of the first resource interaction is output. Based on the difference between the backward sample of the first resource interaction and the reconstructed backward sample of the first resource interaction, the network parameters in the encoder network and decoder network are iteratively adjusted until the difference meets a preset requirement, thus obtaining the second initial behavior prediction model.

[0092] Step S203: Input the second resource interaction forward sample into the first initial behavior prediction model and output the first target behavior prediction result.

[0093] Specifically, the first resource interaction data samples of each sample account are input into the first initial behavior prediction model, and the first target behavior prediction result for each sample account is output. For example, the first target behavior prediction result is represented as follows: : 0.1, 0.9.

[0094] It should be noted that the forward samples and backward samples of the first resource interaction can originate from the same sample account, and the forward samples and backward samples of the second resource interaction can also originate from the same sample account, so as to align the first initial behavior prediction model and the second initial behavior prediction model in terms of features and prediction results. Optionally, the forward samples of the first resource interaction and the forward samples of the second resource interaction can originate from different sample accounts.

[0095] Step S205: Input the second resource interaction feedback sample into the second initial behavior prediction model and output the second target behavior prediction result.

[0096] Specifically, the second resource interaction samples of each of the above sample accounts are input into the second initial behavior prediction model, and the second target behavior prediction result for each sample account is output. For example, the second target behavior prediction result is expressed as follows: : 0.2, 0.8.

[0097] In this embodiment, the resource interaction data generated by the sample account corresponding to the resource interaction forward sample is generated without obtaining resource borrowing service permissions. Resource interaction data generated by the sample account without obtaining resource borrowing service permissions can be understood as resource interaction data generated by the sample account without using the resource borrowing service. Specifically, the resource interaction data may include resource transfer data between collective accounts and resource interaction data between individual accounts. Resource transfer data between collective accounts includes, for example, the quantity, time, and number of resource transfers between the sample account and a commercial account. Resource interaction data between the sample account and individual accounts includes, for example, the quantity, time, and number of resource transfers between the sample account and its friends' accounts. In specific implementations, this can be payment behavior data, red envelope behavior data, or transfer behavior data. Optionally, the resource interaction data may include credit evaluation data for the account to be processed based on the above resource transfer data and resource interaction data. The credit evaluation data can be determined according to the evaluation system corresponding to different application scenarios, such as high credit score, medium credit score, and low credit score.

[0098] In this embodiment, the resource interaction data generated by the sample account corresponding to the resource interaction backward sample is obtained when the sample account obtains the resource borrowing service permission. The sample account in the resource interaction backward sample can be the same as the sample account in the resource forward interaction, so as to align the features of the first initial behavior prediction model and the second initial behavior prediction model. The resource interaction data generated by the sample account when it obtains the resource borrowing service permission can be understood as the resource interaction data performed by the sample account using the resource borrowing service. The resource interaction data can include resource transfer data between the sample account and a collective account, resource interaction data between the sample account and an individual account, and resource interaction data with the resource borrower during the above resource interaction process. Resource transfer data with a collective account includes, for example, the quantity, time, and number of resource transfers between a commercial account and a commercial account. Resource interaction data with an individual account includes, for example, the quantity, time, and number of resource transfers between a friend's account and a friend's account. Resource interaction data with the resource borrower includes, for example, the time of returning borrowed resources, the number of times the resource borrowing service is used, the amount of resources in the resource borrowing service, and the number of installments. In specific implementations, this can be payment behavior data, red envelope behavior data, or transfer behavior data.

[0099] Step S207: Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

[0100] In the specific implementation process, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, can be described by a loss function. This loss function includes, but is not limited to, cross-entropy loss function, Hinge Loss loss function, and KL divergence.

[0101] In an exemplary embodiment, the first difference It can be represented as follows;

[0102] (1)

[0103] In an exemplary real-time scenario, the actual result corresponding to the second resource interaction forward sample is represented as: Y: 0, 1, 1… Where 0 indicates that the target behavior does not occur, and 1 indicates that the target behavior occurs. Second Difference It can be represented as follows:

[0104] (2)

[0105] In this embodiment of the disclosure, based on the first difference and the second difference mentioned above, the network parameters of the first initial behavior prediction model are iteratively trained until the first difference and the second difference meet preset requirements, such as the number of iterations meeting a preset number of times, the prediction accuracy of the model meeting a preset accuracy, etc., to obtain the target behavior prediction model.

[0106] In the above embodiments, a first initial behavior prediction model is obtained by training with first resource interaction forward samples, and a second initial behavior prediction model is obtained by training with first resource interaction backward samples. The resource interaction forward samples are resource interaction data generated by the sample account without resource borrowing service permissions, while the resource interaction backward samples are resource interaction data generated by the matched sample account with resource borrowing service permissions. Therefore, the resource interaction backward samples belong to the resource interaction data generated by the sample account with resource borrowing service permissions. This resource interaction data includes resource interaction data generated for the resource borrowing service, has a stronger correlation with the resource borrowing service, and can reflect the true situation of the target behavior of the sample account after using the resource borrowing service. Next, based on the second initial behavior prediction model, this embodiment integrates the additional information contained in the second resource interaction data samples into the first initial behavior prediction model to obtain a target behavior prediction model, which can improve the prediction accuracy of the target behavior prediction model. Furthermore, in constructing the loss, this embodiment of the disclosure not only utilizes the hard loss between the first target behavior prediction result and the actual result, but also utilizes the soft loss between the first target behavior prediction result and the second target behavior prediction result. The latter reflects the correlation information between the prediction results. The combination of the two losses can further improve the prediction accuracy of the target behavior prediction model.

[0107] In one embodiment, before iteratively training the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the method further includes:

[0108] The actual result corresponding to the second resource interaction forward sample is proportionally calculated with the first target behavior prediction result. The result of the proportional calculation is then mapped to obtain the first offset weight corresponding to each sample account. The first offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the actual result.

[0109] Based on the first offset weight corresponding to each account, the actual results corresponding to each account are fused to obtain the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample.

[0110] In this embodiment of the disclosure, the actual result corresponding to the second resource interaction forward sample is represented as follows: First target behavior prediction results The ratio of the two can be expressed as: Then, this ratio is mapped to obtain the first offset weight, which is expressed as: Based on the first offset weights corresponding to each predicted category, the actual results corresponding to each predicted category are fused to obtain the second difference, as shown below:

[0111] (3)

[0112] In a specific embodiment, for example, the actual result corresponding to the second resource interaction forward sample of the sample account is represented as: Y: [0, 1]. Here, the probability that the sample account belongs to category a is 0, and the probability that the sample account belongs to category b is 1. The first target behavior prediction result of the above sample account is represented as: [0.1, 0.9]. Where the probability of predicting category a is 0.1, and the probability of predicting category b is 0.9. The second difference is calculated as follows: .

[0113] In the above method, a ratio calculation is performed between the actual results corresponding to the second resource interaction forward samples and the first target behavior prediction results. The results of the ratio calculation are then mapped to obtain the first offset weights corresponding to each prediction category. Based on the first offset weights corresponding to each prediction category, the actual results corresponding to each sample account are fused to obtain a second difference between the first target behavior prediction results and the actual results corresponding to the second resource interaction forward samples. This second difference can directly measure the data distribution between the first target behavior prediction results and the actual results, retaining the ability to distinguish the true labels. It provides strong supervision signals through the actual results, ensuring the accuracy of the first initial behavior prediction model.

[0114] In one embodiment, reference Figure 3 As shown, before iteratively training the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the method further includes:

[0115] Step S301: Based on the first smoothing coefficient, smooth the first target behavior prediction result to obtain the processed first target behavior prediction result.

[0116] In this embodiment of the disclosure, the prediction result of the first target behavior can be expressed as: The first smoothing coefficient can be expressed as 1. In an exemplary embodiment, the classification layer output of the first initial behavior prediction model is represented as: The first target behavior prediction result is processed. ,in, This represents the first smoothing coefficient. In an exemplary embodiment, smoothing the prediction result of the first target behavior based on the first smoothing coefficient can also be expressed as: .

[0117] Step S303: Based on the second smoothing coefficient, smooth the prediction result of the second target behavior to obtain the processed prediction result of the second target behavior.

[0118] In this embodiment of the disclosure, the prediction result of the second target behavior can be expressed as: The second smoothing coefficient can be expressed as 2. In an exemplary embodiment, the output of the classification layer of the second initial behavior prediction model is represented as: The second target behavior prediction result is processed. in, This represents the second smoothing coefficient. In an exemplary embodiment, the first target behavior prediction result is smoothed based on the first smoothing coefficient, which can also be expressed as: Optionally, the first smoothing coefficient 1 and second smoothing coefficient 2 can be the same or different. This disclosure does not impose any restrictions on this.

[0119] Step S305: Perform a ratio calculation on the second target behavior prediction result and the corresponding first target behavior prediction result, and perform mapping processing on the ratio calculation result to obtain the second offset weight corresponding to each prediction category; wherein, the second offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the second target behavior prediction result.

[0120] In this embodiment of the disclosure, the processed second target behavior prediction result is expressed as follows: The result of the first target behavior prediction is expressed as: The ratio between the two can be expressed as: Then, this ratio is mapped to obtain the first offset weight, which is expressed as: .

[0121] Step S307: Based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain the first difference between the first target behavior prediction result and the second target behavior prediction result.

[0122] In this embodiment of the disclosure, based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain a first difference between the first target behavior prediction result and the second target behavior prediction result, as shown below:

[0123] (4)

[0124] In a specific embodiment, for example, the actual results corresponding to the second resource interaction forward samples of each prediction category are represented as follows: [0.2, 0.8]. Specifically, the forward sample of the second resource interaction for prediction category a is labeled with an actual result of 0.2, and the forward sample of the second resource interaction for prediction category b is labeled with an actual result of 0.8. The prediction results of the first target behavior for each of the above prediction categories are expressed as follows: [0.1, 0.9]. Wherein, the prediction result for the first target behavior of category a is 0.1, and the prediction result for the first target behavior of category b is 0.9. The second difference is calculated as follows: .

[0125] In the above embodiments, the first target behavior prediction result is smoothed based on a first smoothing coefficient to obtain a processed first target behavior prediction result. The second target behavior prediction result is smoothed based on a second smoothing coefficient to obtain a processed second target behavior prediction result. The first and second smoothing coefficients are used to adjust the smoothness of the probability distribution. Based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain a first difference between the first target behavior prediction result and the second target behavior prediction result. Thus, the first initial behavior model can learn the probability distribution of the second initial behavior model, learn the similarity between categories, and ultimately perform more robustly on the test set.

[0126] In one embodiment, the step of iteratively training the first initial behavior prediction model based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, to obtain a target behavior prediction model, includes:

[0127] Weighted factor combinations are obtained from a preset search range; wherein the weighted factor combination includes a first weighted factor and a second weighted factor.

[0128] Based on each weighted factor combination, the first difference and the second difference are fused to obtain a first joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; and the second difference is the difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample.

[0129] Based on each of the first joint losses, the first initial behavior prediction models are iteratively trained; the first initial behavior prediction model with the highest standard evaluation coefficient is determined as the target behavior prediction model.

[0130] Specifically, the preset search range can be a range of values. In the exemplary embodiment, it can be a range between 0 and 1, such as (0.0, 0.1, 0.2, ..., 0.9, 1.0). It is understood that the preset search range can be further refined, such as (0.0, 0.05, 0.1, 0.15, 0.2, 0.25, 0.3, ..., 0.95, 1.0); or, the search step size can be increased, such as (0.0, 0.4, ..., 0.8, 1.0). This disclosure does not limit this.

[0131] In an exemplary embodiment, a combination of weighting factors, such as a first weighting factor, is obtained from a preset search range. Second weighting factor Optionally, the first weighting factor and the second weighting factor are correlated, for example... Based on the first weighting factor Second weighting factor The first difference and the second difference are fused to obtain the first joint loss, which is exemplarily represented as follows:

[0132] (5)

[0133] in, Indicates the first difference, This indicates the second difference.

[0134] In this embodiment of the disclosure, it is understood that different first joint losses can train different first initial behavior prediction models. For example, based on the first joint loss... The first initial behavior prediction model 1 is obtained; based on the first joint loss The first initial behavior prediction model 2 is obtained; based on the first joint loss This yields the first initial behavior prediction model 3, etc. Finally, the first initial behavior prediction model with the highest standard evaluation coefficient is selected from all the first initial behavior prediction models as the target behavior prediction model. The standard evaluation coefficient is used to evaluate the performance of the artificial intelligence model, such as AUC, accuracy, precision, recall, error rate, and mean squared error (MSE).

[0135] In the above embodiments, weighted factor combinations are obtained from a preset search range. Based on each weighted factor combination, the first difference and the second difference are fused to obtain a first joint loss. Based on each of the first joint losses, the first initial behavior prediction model is iteratively trained. The first initial behavior prediction model with the highest standard evaluation coefficient is determined as the target behavior prediction model. The first and second weighted factors can adjust the learning ratio between the first difference (soft label) and the second difference (hard label) of the first initial behavior prediction model to determine the first initial behavior prediction model with optimal performance.

[0136] In one embodiment, reference Figure 4 As shown, the step of inputting the forward sample of the second resource interaction into the first initial behavior prediction model and outputting the first target behavior prediction result; and inputting the backward sample of the second resource interaction into the second initial behavior prediction model and outputting the second target behavior prediction result includes:

[0137] Step S401: Based on the first encoder network, feature extraction is performed on the forward samples of the second resource interaction to obtain a first feature vector. Based on the first classifier network, the first feature vector is classified to obtain a first target behavior prediction result.

[0138] In the specific implementation process, refer to Figure 5 As shown, the first initial behavior prediction model 509 includes a first encoder network 501 and a first classifier network 505. The second initial behavior prediction model 511 includes a second encoder network 503 and a second classifier network 507. The first encoder network and the second encoder network include, but are not limited to, convolutional neural networks, autoencoders, Transformer encoders, recurrent neural networks, etc. The first classifier network and the second classifier network include, but are not limited to, fully connected classifiers (MLP), support vector machines (SVM), lightweight classifiers (SENet), etc.

[0139] In an exemplary embodiment, the second resource interaction forward sample is represented as follows: The first encoder network is represented as The first eigenvector is represented as The first classifier network is represented as... The prediction result of the first target behavior can be expressed as .

[0140] Step S403: Based on the second encoder network, feature extraction is performed on the second resource interaction backward sample to obtain a second feature vector. Based on the second classifier network, the second feature vector is classified to obtain the second target behavior prediction result.

[0141] In one exemplary embodiment, the second resource interaction backward sample is represented as The second encoder network is represented as The second eigenvector is represented as The first classifier network is represented as... The prediction result of the second target behavior can be expressed as .

[0142] The iterative training of the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, includes:

[0143] Step S405: Based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0144] The third difference between the first feature vector and the second feature vector can be measured by a mean squared error (MSE) or cosine distance, among other metrics. In an exemplary embodiment, the third difference... It can be represented as follows:

[0145] (5)

[0146] In this embodiment of the disclosure, the third difference Combined with the first difference as described in formula (1) The second difference described in formula (2) The first initial behavior prediction model is iteratively trained. The third difference, representing the difference between the first and second feature vectors, belongs to the intermediate layer of the model. The second initial behavior prediction model is used to supervise the feature distribution of the first initial behavior prediction model, achieving alignment between the two models at the representation level. Combining the first and second differences enables multi-level knowledge transfer, enhancing the generalization ability of the target behavior prediction model. When processing forward data from resource interactions at different stages, the model can flexibly adapt to changes in data distribution, improving its stability and adaptability in practical applications.

[0147] In one embodiment, reference Figure 6 As shown, the step of iteratively training the first initial behavior prediction model based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, to obtain the target behavior prediction model, includes:

[0148] Step S601: Obtain weight coefficient combinations from the preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient.

[0149] Similar to the above embodiments, in this disclosure, the preset search range can be a range of values, which in the exemplary embodiment can be a range between 0 and 1.

[0150] Step S603: Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss. Wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; and the third difference is the difference between the first feature vector and the second feature vector.

[0151] In an exemplary embodiment, a combination of weight coefficients is obtained from a preset search range, for example, a first weight coefficient. Second weighting coefficient and the third weighting coefficient Based on the weighted coefficient combination, the first difference, second difference, and third difference are fused to obtain the second joint loss. For example, the second joint loss is expressed as follows:

[0152] (6)

[0153] in, Indicates the first difference, Indicates the second difference. This indicates the third difference.

[0154] Step S605: Based on each of the second joint losses, iteratively train the first initial behavior prediction model respectively, and determine the first initial behavior prediction model with the highest standard evaluation coefficient after training as the target behavior prediction model.

[0155] In this embodiment of the disclosure, it is understood that different second joint losses can train different first initial behavior prediction models. For example, based on the second joint loss... The first initial behavior prediction model 1 is obtained; based on the second joint loss... The first initial behavior prediction model 2 is obtained; based on the second joint loss... This yields the first initial behavior prediction model 3, etc. Finally, the first initial behavior prediction model with the highest standard evaluation coefficient is selected from all the first initial behavior prediction models as the target behavior prediction model. The standard evaluation coefficient is used to evaluate the performance of the artificial intelligence model, such as AUC, accuracy, precision, recall, error rate, and mean squared error (MSE).

[0156] In the above embodiments, weight coefficient combinations are obtained from a preset search range. Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss. Based on each second joint loss, the first initial behavior prediction model is iteratively trained to determine the first initial behavior prediction model with the highest standard evaluation coefficient, which is then used as the target behavior prediction model. The first, second, and third weight coefficients can adjust the learning ratios of the first initial behavior prediction model corresponding to the first, second, and third differences, balancing the contributions between feature vector alignment and prediction result alignment, determining the optimal first initial behavior prediction model, and improving the accuracy of the target behavior prediction model.

[0157] In one embodiment, reference Figure 7 As shown, the iterative training of the first initial behavior prediction model based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, includes:

[0158] Step S701: Extract the first feature value, the first feature key value, and the first feature query vector from the first feature vector based on the first attention network.

[0159] In this embodiment, the attention network is a deep learning technique that mimics the human visual and cognitive system's focus on key information. It determines the importance of different input parts by dynamically assigning weights. The attention network comprises three core components: Query: the target representation to be generated; Key: the feature representation of the input element; and Value: the actual content corresponding to the Key.

[0160] Specifically, refer to Figure 8 As shown, the first feature vector is represented as The first eigenvalue of the extracted first feature vector is represented as The first feature key value of the extracted first feature vector represents The first feature query vector extracted from the first feature vector is represented as: .

[0161] Step S703: Based on the correlation between the first feature key value and the first feature query vector, the first feature value is weighted and fused to obtain the processed first feature vector.

[0162] The correlation between the first feature key value and the first feature query vector can be obtained using existing similarity algorithms, such as Euclidean distance, cosine similarity, correlation coefficient, Jaccard similarity coefficient, Manhattan distance, and Hamming distance.

[0163] In the specific implementation process, the first feature vector 801 processed can be represented as:

[0164] (7)

[0165] in for The scaling factor is used to prevent the gradient from vanishing due to excessively large dot products.

[0166] Step S705: Extract the second feature value, the second feature key value, and the second feature query vector from the second feature vector based on the second attention network.

[0167] Similarly, the second eigenvector is represented as The second eigenvalue of the extracted second eigenvector is represented as The extracted second feature vector represents the second feature key value. The extracted second feature vector is represented as the second feature query vector. .

[0168] Step S707: Based on the correlation between the second feature key value and the second feature query vector, the second feature value is weighted and fused to obtain the processed second feature vector.

[0169] In the specific implementation process, the processed second feature vector 801 can be represented as:

[0170] (8)

[0171] in for The scaling factor is used to prevent the gradient from vanishing due to excessively large dot products.

[0172] Step S709: Based on the third difference between the processed first feature vector and the processed second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0173] Specifically, similar to the above embodiments, weight coefficient combinations are obtained from a preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient. Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss; wherein the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; and the third difference is the difference between the first feature vector and the second feature vector. Based on each of the second joint losses, the first initial behavior prediction model is iteratively trained to determine the first initial behavior prediction model with the highest standard evaluation coefficient, which is then used as the target behavior prediction model.

[0174] In the above embodiments, a first attention network extracts the first feature value, the first feature key value, and the first feature query vector from the first feature vector, and a second attention network extracts the second feature value, the second feature key value, and the second feature query vector from the second feature vector. Based on the third difference between the processed first feature vector and the processed second feature vector, as well as the first difference and the second difference, the first initial behavior prediction model is iteratively trained. The processed first feature vector and the processed second feature vector enable the first initial behavior prediction model to focus on the same parts of important features as the second initial behavior prediction model, thereby enhancing the first initial behavior prediction model's ability to capture key features and improving the overall performance of the model.

[0175] In one embodiment, before obtaining the first initial behavior prediction model trained based on the first resource interaction forward samples and the second initial behavior prediction model trained based on the first resource interaction backward samples, the method further includes:

[0176] Obtain a sample set; the sample set includes the first resource interaction back sample and the labeled target behavior tags.

[0177] The first resource interaction feedback sample is input into the first original behavior prediction model, and the third target behavior prediction result is output.

[0178] Based on the difference between the third target behavior prediction result and the target behavior label, the first original behavior prediction model is iteratively adjusted until the difference meets the preset requirements to obtain the second initial behavior prediction model.

[0179] Specifically, the sample set includes the first resource interaction feedback samples of the sample accounts, that is, resource interaction data generated when the resource borrowing service is granted. Examples include the quantity, time, and number of resource transfers between commercial accounts; resource interaction data between individual accounts, such as the quantity, time, and number of resource transfers between friend accounts; and resource interaction data with the resource borrower, such as the time of returning borrowed resources, the number of times the resource borrowing service is used, the amount of resources borrowed, and the number of installments.

[0180] In an exemplary embodiment, the sample account is labeled with a target behavior tag after the first resource interaction, for example, Y: [1, 0], where 1 indicates that the target behavior has occurred and 0 indicates that the target behavior has not occurred. In this embodiment, the first original behavior prediction model may include an encoder network and a classifier network, wherein the specific types of the encoder network and classifier network may be the same as those in the above embodiments, and this disclosure does not limit them. In an exemplary embodiment, the sample after the first resource interaction is input into the first original behavior prediction model, and a third target behavior prediction result Y' is output, for example, Y': [0.7, 0.3].

[0181] Optionally, the difference between the third target behavior prediction result and the target behavior label can be described using a loss function. This loss function includes, but is not limited to, cross-entropy loss, Hinge Loss, and KL divergence. Based on the above difference, the first original behavior prediction model is iteratively adjusted according to the difference between the third target behavior prediction result and the target behavior label until the difference meets preset requirements, such as accuracy meeting preset standards, to obtain a second initial behavior prediction model.

[0182] In the above embodiments, the second original behavior prediction model is iteratively adjusted in a supervised manner to obtain the second initial behavior prediction model. The second original behavior prediction model is based on backward samples from the first resource interaction and includes resource interaction data with the resource borrower. This supervises the first initial behavior prediction model, enabling it to achieve higher prediction accuracy.

[0183] In one embodiment, before obtaining the first initial behavior prediction model trained based on the first resource interaction forward samples and the second initial behavior prediction model trained based on the first resource interaction backward samples, the method further includes:

[0184] Obtain a sample set; the sample set includes the first resource interaction backward sample. Obtain a first positive sample, a second positive sample, and a negative sample from the sample set.

[0185] Based on the second original behavior prediction model, feature extraction is performed on the first positive sample to obtain a third feature vector. Based on the second original behavior prediction model, feature extraction is performed on the second positive sample to obtain a fourth feature vector. Based on the second original behavior prediction model, feature extraction is performed on the negative sample to obtain a fifth feature vector.

[0186] A contrast loss is constructed based on the distances between the third and fourth feature vectors, and between the third and fifth feature vectors. Based on this contrast loss, the second original behavior prediction model is iteratively adjusted until the differences meet preset requirements, thus obtaining the second initial behavior prediction model.

[0187] Specifically, similar to the embodiments described above, the sample set includes the first resource interaction backward samples of the sample accounts, that is, resource interaction data generated when resource borrowing service permissions are obtained. Examples include the quantity, time, and number of resource transfers between commercial accounts and individual accounts, such as the quantity, time, and number of resource transfers between friends' accounts. It also includes resource interaction data with the resource borrower, such as the time of returning borrowed resources, the number of times the resource borrowing service is used, the amount of resources borrowed, and the number of installments.

[0188] The first positive sample and the second positive sample can be different enhanced versions of the backward sample that interact with the same first resource. For example, data modification can be performed on the first positive sample to obtain the second positive sample. Negative samples come from samples in the sample set other than the first positive sample and the second positive sample.

[0189] In one exemplary embodiment, features are extracted from the first positive sample based on the second original behavior prediction model to obtain a third feature vector, for example, denoted as X1. Features are extracted from the second positive sample based on the second original behavior prediction model to obtain a fourth feature vector, for example, denoted as X2. Features are extracted from the negative sample based on the second original behavior prediction model to obtain a fifth feature vector, for example, denoted as X3. The distances D1 between the third and fourth feature vectors and D2 between the third and fifth feature vectors can be described using Euclidean, cosine similarity, or other methods. In an exemplary embodiment, the contrastive loss is represented as follows:

[0190] (9)

[0191] in, , The sample pair can be represented by the third feature vector X1, the fourth feature vector X2, and the fifth feature vector X3. m is a hyperparameter (margin) that defines the minimum interval between positive and negative samples to prevent negative samples from being too close together.

[0192] In the above embodiments, the second initial behavior prediction model can be trained in an unsupervised manner based on contrastive learning. By pre-training on unlabeled data, the feature representation of the second initial behavior prediction model is generated and used as a supervision signal for the first initial behavior prediction model. In this way, the first initial behavior prediction model can learn on more unlabeled data, improving its generalization ability and performance.

[0193] In one embodiment, the iterative training of the first initial behavior prediction model based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, includes:

[0194] Obtain a third initial behavior prediction model trained based on the backward samples of the first resource interaction; wherein the type of the third initial behavior prediction model includes at least one.

[0195] The first resource interaction feedback samples are respectively input into each of the third initial behavior prediction models, and the prediction results of each third target behavior are output.

[0196] Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, the first initial behavior prediction model is iteratively trained based on the third differences between the first target behavior prediction result and each of the third target behavior prediction results.

[0197] Specifically, different types of third initial behavior prediction models can correspond to different first resource interaction backward samples. For example, the first resource interaction backward samples used to train third initial behavior prediction model a come from sample set a; the first resource interaction backward samples used to train third initial behavior prediction model b come from sample set b; the first resource interaction backward samples used to train third initial behavior prediction model c come from sample set c, and so on. Optionally, different types of third initial behavior prediction models can correspond to different training tasks to monitor abnormal resource interaction behaviors, such as illegal transfers or addiction to games that allow winning large amounts of resources.

[0198] Next, the backward sample of the first resource is input into the third initial behavior prediction model a, and the third target behavior prediction result is output. The first resource backward sample is input into the third initial behavior prediction model b, and the third target behavior prediction result is output. The first resource feedback sample is input into the third initial behavior prediction model c, and the third target behavior prediction result is output. Then, based on the third differences between the prediction results of the first target behavior and each of the prediction results of the third target behavior, it can be expressed as follows: , , Combining the first difference in equation (1) above and the second difference in equation (2) above. The first initial behavior prediction model is iteratively trained.

[0199] In the above embodiments, by introducing the third differences between the first target behavior prediction results and each of the third target behavior prediction results, each third initial behavior prediction model can be trained on different subtasks or different datasets. By integrating the knowledge of multiple third initial behavior prediction models into the first initial behavior prediction model, the advantages of different third initial behavior prediction models can be fully utilized, thereby improving the generalization ability of the first initial behavior prediction model.

[0200] In one embodiment, reference Figure 9 As shown, an account data processing method is provided, which can be applied to... Figure 1 Taking server 104 or terminal 102 as an example, the following steps are included:

[0201] Step S901: In response to the request information for the resource borrowing service permission of the account to be processed, obtain the resource interaction forward data corresponding to the account to be processed.

[0202] Specifically, an account awaiting processing can apply for resource borrowing service permissions from the resource borrower before or during resource interaction. The forward data for resource interaction corresponds to resource interaction data generated by the account awaiting processing without resource borrowing service permissions. This resource interaction data generated by the account awaiting processing without resource borrowing service permissions can be understood as resource interaction data generated by the account awaiting processing without using the resource borrowing service. Specifically, resource interaction data can include resource transfer data between collective accounts and resource interaction data between individual accounts. Resource transfer data between collective accounts includes, for example, the quantity, time, and number of resource transfers between the account awaiting processing and a commercial account. Resource interaction data between the account awaiting processing and individual accounts includes, for example, the quantity, time, and number of resource transfers between the account awaiting processing and its friends' accounts. In specific implementations, this can be payment behavior data, red envelope behavior data, or transfer behavior data. Optionally, resource interaction data can include credit evaluation data for the account awaiting processing based on the aforementioned resource transfer data and resource interaction data. The credit rating data can be determined based on the evaluation system corresponding to different application scenarios, such as high credit rating, medium credit rating, and low credit rating.

[0203] Step S903: Input the forward resource interaction data into the target behavior prediction model to predict the target behavior of the account to be processed; wherein, the target behavior prediction model is obtained by iteratively training the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; wherein, the first target behavior prediction result is obtained by inputting the second resource interaction forward sample into the first initial behavior prediction model and outputting it; the second target behavior prediction result is obtained by inputting the second resource interaction backward sample into the second initial behavior prediction model and outputting it; the first initial behavior prediction model is trained based on the first resource interaction forward sample, and the second initial behavior prediction model is trained based on the first resource interaction backward sample; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the sample account with obtaining resource borrowing service permission.

[0204] Specifically, the first initial behavior prediction model may be trained using machine learning on the first resource interaction feedforward samples. Specifically, the first initial behavior prediction model may include an encoder network and a classifier network. In an exemplary embodiment, the first resource interaction feedforward samples of a sample account are input into the first initial behavior prediction model, and the model outputs a prediction result. The prediction result may indicate whether the sample account will perform the target behavior or not. The first resource interaction feedforward samples have corresponding annotation results, which may indicate whether the sample account actually performed the target behavior or not. Based on the difference between the prediction result and the corresponding actual result, the network parameters in the encoder network and classifier network are iteratively adjusted until the difference meets a preset requirement, thus obtaining the first initial behavior prediction model.

[0205] Similarly, the training method for the second initial behavior prediction model can also employ the supervised machine learning approach described above. Therefore, the second initial behavior prediction model can consist of an encoder network and a classifier network. Furthermore, the second initial behavior prediction model can also be trained unsupervised based on the backward samples of the first resource interaction. Specifically, in an exemplary embodiment, the second initial behavior prediction model may include an encoder network and a decoder network. The backward samples of the first resource interaction are input into the second initial behavior prediction model, and a reconstructed backward sample of the first resource interaction is output. Based on the difference between the backward sample of the first resource interaction and the reconstructed backward sample of the first resource interaction, the network parameters in the encoder network and decoder network are iteratively adjusted until the difference meets a preset requirement, thus obtaining the second initial behavior prediction model.

[0206] In this embodiment of the disclosure, the first resource interaction data samples of each sample account are input into a first initial behavior prediction model, and the first target behavior prediction result of each sample account is output. The second resource interaction samples of the above-mentioned sample accounts are input into a second initial behavior prediction model, and the second target behavior prediction result of each sample account is output.

[0207] In one possible implementation, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, can be described by a loss function. Based on the above first and second differences, the network parameters of the first initial behavior prediction model are iteratively trained until the above first and second differences meet preset requirements, such as the number of iterations meeting a preset number of times, the prediction accuracy of the model meeting a preset accuracy, etc., to obtain the target behavior prediction model.

[0208] Step S905: Based on the target behavior of the account to be processed, determine the resource borrowing service permission request result corresponding to the request information.

[0209] The target behavior can be the failure of an account to return a specified amount of resources within a specified period after borrowing resources from a resource borrower. In one exemplary embodiment, if the target behavior is predicted to occur in the account to be processed, the permission to borrow resources for that account is denied. In another exemplary embodiment, if the target behavior is predicted not to occur in the account to be processed, the permission to borrow resources for that account can be determined comprehensively by combining other information.

[0210] In the above embodiments, a first initial behavior prediction model is obtained by training with first resource interaction forward samples, and a second initial behavior prediction model is obtained by training with first resource interaction backward samples. The resource interaction forward samples are resource interaction data generated by the sample account without resource borrowing service permissions, while the resource interaction backward samples are resource interaction data generated by the matched sample account with resource borrowing service permissions. Therefore, the resource interaction backward samples belong to the resource interaction data generated by the sample account with resource borrowing service permissions. This resource interaction data includes resource interaction data generated for the resource borrowing service, has a stronger correlation with the resource borrowing service, and can reflect the true situation of the target behavior of the sample account after using the resource borrowing service. Next, based on the second initial behavior prediction model, this embodiment integrates the additional information contained in the second resource interaction data samples into the first initial behavior prediction model to obtain a target behavior prediction model, which can improve the prediction accuracy of the target behavior prediction model. Furthermore, in constructing the loss, this embodiment of the disclosure not only utilizes the hard loss between the first target behavior prediction result and the actual result, but also utilizes the soft loss between the first target behavior prediction result and the second target behavior prediction result. The latter reflects the correlation information between the prediction results. The combination of the two losses can further improve the accuracy of the target behavior prediction of the account to be processed.

[0211] In a specific embodiment, the method of this application can be applied to the detection of user financial default behavior. In the prior art, to mitigate the risk of user default behavior, a risk prediction model is used to predict user resource interaction data before resource borrowing; however, the prediction accuracy of the aforementioned model is not high. This application provides an account data processing method that can improve the prediction accuracy of the target behavior prediction model.

[0212] Specifically, the method of this application includes a training phase of a first initial behavior prediction model, a training phase of a second initial behavior prediction model, and a training phase of a target behavior prediction model.

[0213] During the training phase of the first initial behavior prediction model, the first resource interaction feedforward sample of the sample account is input into the first initial behavior prediction model. The first initial behavior prediction model outputs a prediction result. This prediction result may include whether the sample account will perform the target behavior or not. The first resource interaction feedforward sample has corresponding annotation results, which may include whether the sample account actually performed the target behavior or not. Based on the difference between the prediction result and the corresponding actual result, the network parameters in the encoder network and classifier network are iteratively adjusted until the difference meets a preset requirement, thus obtaining the first initial behavior prediction model.

[0214] During the training phase of the second initial behavior prediction model, the first resource interaction feedback sample of the sample account is input into the first initial behavior prediction model. The first initial behavior prediction model outputs a prediction result. This prediction result may include whether the sample account will perform the target behavior or not. The first resource interaction feedback sample has corresponding annotation results, which may include whether the sample account actually performed the target behavior or not. Based on the difference between the prediction result and the corresponding actual result, the network parameters in the encoder network and classifier network are iteratively adjusted until the difference meets preset requirements, thus obtaining the second initial behavior prediction model.

[0215] Optionally, the second initial behavior prediction model can also be obtained in the following manner: Obtain a sample set; the sample set includes backward samples from the first resource interaction. Obtain a first positive sample, a second positive sample, and a negative sample from the sample set. Extract features from the first positive sample based on the second initial behavior prediction model to obtain a third feature vector. Extract features from the second positive sample based on the second initial behavior prediction model to obtain a fourth feature vector. Extract features from the negative sample based on the second initial behavior prediction model to obtain a fifth feature vector. Construct a contrastive loss based on the distance between the third and fourth feature vectors, and the distance between the third and fifth feature vectors. Iteratively adjust the second initial behavior prediction model based on the contrastive loss until the difference meets a preset requirement, thus obtaining the second initial behavior prediction model.

[0216] In the training phase of the target behavior prediction model, the method includes: Step S203, inputting the forward samples of the second resource interaction into the first initial behavior prediction model and outputting the first target behavior prediction result. Step S205, inputting the backward samples of the second resource interaction into the second initial behavior prediction model and outputting the second target behavior prediction result. Step S601, obtaining weight coefficient combinations from a preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient. Step S603, based on each weight coefficient combination, performing a fusion process on the first difference, the second difference, and the third difference to obtain a second joint loss. The first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; the third difference is the difference between the first feature vector and the second feature vector. Step S605, based on each of the second joint losses, iteratively training the first initial behavior prediction model, determining the first initial behavior prediction model with the highest standard evaluation coefficient as the target behavior prediction model.

[0217] The second difference is obtained by: performing a ratio calculation on the actual result corresponding to the second resource interaction forward sample and the first target behavior prediction result; mapping the result of the ratio calculation to obtain a first offset weight corresponding to each sample account; wherein the first offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the actual result. Based on the first offset weight corresponding to each account, the actual results corresponding to each account are fused to obtain a second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample.

[0218] The method for obtaining the first difference includes: Step S301, smoothing the first target behavior prediction result based on a first smoothing coefficient to obtain a processed first target behavior prediction result. Step S303, smoothing the second target behavior prediction result based on a second smoothing coefficient to obtain a processed second target behavior prediction result. Step S305, performing a proportional operation on the processed second target behavior prediction result and the corresponding processed first target behavior prediction result, and mapping the result of the proportional operation to obtain a second offset weight corresponding to each prediction category; wherein, the second offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the second target behavior prediction result.

[0219] The method for obtaining the third difference includes: Step S401, extracting features from the forward samples of the second resource interaction based on the first encoder network to obtain a first feature vector, and classifying the first feature vector based on the first classifier network to obtain a first target behavior prediction result. Step S403, extracting features from the backward samples of the second resource interaction based on the second encoder network to obtain a second feature vector, and classifying the second feature vector based on the second classifier network to obtain a second target behavior prediction result. The difference between the first feature vector and the second feature vector is taken as the third difference.

[0220] In a specific application scenario, the target behavior could be an account's loan default behavior. A first initial behavior prediction model is trained based on forward samples of resource interactions when the sample account has not yet obtained loan permissions, such as transfer data, resource donation data, and consumption data. A second initial behavior prediction model is trained based on backward samples of resource interactions after the sample account has obtained loan permissions, which could include resource interactions occurring without using borrowed resources, or transfer data, resource donation data, and consumption data generated using borrowed resources. Subsequently, the knowledge from the second initial behavior prediction model is extracted into the first initial behavior prediction model through knowledge distillation, thereby improving the prediction accuracy of the first initial behavior prediction model.

[0221] In another specific application scenario, the target behavior could be a project contract breach by an account. Based on forward samples of resource interactions when the sample account did not have permission to contract the target project (e.g., project delivery data, delivery time, delivery quality), a first initial behavior prediction model is trained. Based on backward samples of resource interactions when the sample account gained permission to contract the target project (e.g., including resource interactions not related to the target project, as well as project delivery data, delivery time, delivery quality generated by resources related to the target project), a second initial behavior prediction model is trained. Subsequently, the knowledge from the second initial behavior prediction model is extracted into the first initial behavior prediction model through knowledge distillation, thereby improving the prediction accuracy of the first initial behavior prediction model.

[0222] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0223] Based on the same inventive concept, this application also provides an account data processing apparatus for implementing the account data processing method described above. The solution provided by this apparatus is similar to the implementation described in the above method; therefore, the specific limitations in one or more account data processing apparatus embodiments provided below can be found in the limitations of the account data processing method described above, and will not be repeated here.

[0224] In one embodiment, such as Figure 10 As shown, an account data processing device 1000 is provided, comprising:

[0225] The first acquisition module 1001 is used to acquire a first initial behavior prediction model trained based on the first resource interaction forward sample and a second initial behavior prediction model trained based on the first resource interaction backward sample.

[0226] The first prediction module 1003 is used to input the second resource interaction forward sample into the first initial behavior prediction model and output the first target behavior prediction result.

[0227] The second prediction module 1005 is used to input the second resource interaction backward sample into the second initial behavior prediction model and output the second target behavior prediction result; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the matched sample account with the resource borrowing service permission.

[0228] The first processing module 1007 is used to iteratively train the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

[0229] In one embodiment, the apparatus further includes a second processing module, the second processing module being used for:

[0230] The first offset weight is used to perform a ratio calculation on the actual result corresponding to the second resource interaction forward sample and the first target behavior prediction result, and the result of the ratio calculation is mapped to obtain the first offset weight corresponding to each prediction category; wherein, the first offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the actual result.

[0231] Based on the first offset weights corresponding to each prediction category, the actual results corresponding to each prediction category are fused to obtain the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample.

[0232] In one embodiment, the apparatus further includes a third processing module, the third processing module being used for:

[0233] Based on the first smoothing coefficient, the prediction result of the first target behavior is smoothed to obtain the processed prediction result of the first target behavior.

[0234] Based on the second smoothing coefficient, the prediction result of the second target behavior is smoothed to obtain the processed prediction result of the second target behavior.

[0235] The second target behavior prediction result of the processing is proportionally calculated with the corresponding first target behavior prediction result of the processing. The result of the proportional calculation is then mapped to obtain the second offset weight corresponding to each prediction category. The second offset weight is used to characterize the degree of offset between the first target behavior prediction result and the second target behavior prediction result.

[0236] Based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain the first difference between the first target behavior prediction result and the second target behavior prediction result.

[0237] In one embodiment, the first processing module is configured to:

[0238] Weighted factor combinations are obtained from a preset search range; wherein, the weighted factor combination includes a first weighted factor and a second weighted factor;

[0239] Based on each weighted factor combination, the first difference and the second difference are fused to obtain a first joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; and the second difference is the difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample.

[0240] Based on each of the first joint losses, the first initial behavior prediction models are iteratively trained; the first initial behavior prediction model with the highest standard evaluation coefficient is determined as the target behavior prediction model.

[0241] In one embodiment, the first initial behavior prediction model includes a first encoder network and a first classifier network; the second initial behavior prediction model includes a second encoder network and a second classifier network; the first prediction module is further configured to:

[0242] Based on the first encoder network, feature extraction is performed on the forward samples of the second resource interaction to obtain a first feature vector. Based on the first classifier network, the first feature vector is classified to obtain a first target behavior prediction result.

[0243] The second prediction module is also used for:

[0244] Based on the second encoder network, feature extraction is performed on the second resource interaction backward sample to obtain a second feature vector. Based on the second classifier network, the second feature vector is classified to obtain the second target behavior prediction result.

[0245] The first processing module is also used for:

[0246] Based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0247] In one embodiment, the first processing module is further configured to:

[0248] The weight coefficient combinations are obtained from the preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient.

[0249] Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; and the third difference is the difference between the first feature vector and the second feature vector.

[0250] Based on each of the second joint losses, the first initial behavior prediction model is iteratively trained to determine the first initial behavior prediction model with the highest standard evaluation coefficient, which is then used as the target behavior prediction model.

[0251] In one embodiment, the first processing module is further configured to:

[0252] The first feature value, the first feature key value, and the first feature query vector are extracted from the first feature vector based on the first attention network.

[0253] Based on the correlation between the first feature key value and the first feature query vector, the first feature value is weighted and fused to obtain the processed first feature vector;

[0254] The second feature value, the second feature key value, and the second feature query vector are extracted from the second feature vector based on the second attention network.

[0255] Based on the correlation between the second feature key value and the second feature query vector, the second feature value is weighted and fused to obtain the processed second feature vector;

[0256] Based on the third difference between the first feature vector and the second feature vector processed, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

[0257] In one embodiment, the apparatus further includes a first training module, the first training module being used for:

[0258] Obtain a sample set; the sample set includes the first resource interaction backward sample and the labeled target behavior tags;

[0259] The first resource interaction post-sample is input into the first original behavior prediction model, and the third target behavior prediction result is output.

[0260] Based on the difference between the third target behavior prediction result and the target behavior label, the first original behavior prediction model is iteratively adjusted until the difference meets the preset requirements to obtain the second initial behavior prediction model.

[0261] In one embodiment, the apparatus further includes a second training module, the second training module being used for:

[0262] Obtain a sample set; the sample set includes the first resource interaction backward sample;

[0263] Obtain the first positive sample, the second positive sample, and the negative sample from the sample set;

[0264] Based on the second original behavior prediction model, feature extraction is performed on the first positive sample to obtain the third feature vector;

[0265] Based on the second original behavior prediction model, feature extraction is performed on the second positive sample to obtain the fourth feature vector;

[0266] Based on the second original behavior prediction model, feature extraction is performed on the negative sample to obtain the fifth feature vector;

[0267] Based on the distance between the third feature vector and the fourth feature vector, and the distance between the third feature vector and the fifth feature vector, a contrastive loss is constructed;

[0268] Based on the contrast loss, the second original behavior prediction model is iteratively adjusted until the difference meets the preset requirements, thus obtaining the second initial behavior prediction model.

[0269] In one embodiment, the first processing module is further configured to:

[0270] Obtain a third initial behavior prediction model trained based on the backward samples of the first resource interaction; wherein the type of the third initial behavior prediction model includes at least one.

[0271] The first resource interaction feedback sample is input into each of the third initial behavior prediction models, and the prediction results of each third target behavior are output.

[0272] Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, the first initial behavior prediction model is iteratively trained based on the third differences between the first target behavior prediction result and each of the third target behavior prediction results.

[0273] In one embodiment, such as Figure 11 As shown, an account data processing device 1100 is provided, including:

[0274] The second acquisition module 1101 is used to acquire the resource interaction forward data corresponding to the account to be processed in response to the request information of the resource borrowing service permission of the account to be processed.

[0275] The third prediction module 1103 is used to input the forward data of resource interaction into the target behavior prediction model to predict the target behavior of the account to be processed; wherein, the target behavior prediction model is obtained by iteratively training a first initial behavior prediction model based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the second forward sample of resource interaction; wherein, the first target behavior prediction result is obtained by inputting the second forward sample of resource interaction into the first initial behavior prediction model and outputting it; the second target behavior prediction result is obtained by inputting the second backward sample of resource interaction into the second initial behavior prediction model and outputting it; the first initial behavior prediction model is trained based on the first forward sample of resource interaction, and the second initial behavior prediction model is trained based on the first backward sample of resource interaction; wherein, the forward sample of resource interaction is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the backward sample of resource interaction is the resource interaction data generated by the sample account with the resource borrowing service permission.

[0276] The determination module 1105 is used to determine the resource borrowing service permission request result corresponding to the request information based on the target behavior of the account to be processed.

[0277] Each module in the aforementioned account data processing device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0278] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 12 As shown, this computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores account data processing data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When the computer program is executed by the processor, it implements an account data processing method.

[0279] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 13 As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, NFC (Near Field Communication), or other technologies. When executed by the processor, the computer program implements an account data processing method. The display unit of the computer device is used to form a visually visible image. It can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.

[0280] Those skilled in the art will understand that Figure 13The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0281] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0282] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, etc., and are not limited to these.

[0283] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0284] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A method for processing account data, characterized in that, The method includes: Obtain a first initial behavior prediction model trained based on forward samples of the first resource interaction, and a second initial behavior prediction model trained based on backward samples of the first resource interaction. The second resource interaction forward sample is input into the first initial behavior prediction model, and the first target behavior prediction result is output. The second resource interaction backward sample is input into the second initial behavior prediction model, and the second target behavior prediction result is output; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the matched sample account with the resource borrowing service permission. Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

2. The method according to claim 1, characterized in that, Before iteratively training the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the method further includes: The actual result corresponding to the second resource interaction forward sample is proportionally calculated with the first target behavior prediction result. The result of the proportional calculation is then mapped to obtain the first offset weight corresponding to each prediction category. The first offset weight is used to characterize the degree of offset of the first target behavior prediction result relative to the actual result. Based on the first offset weights corresponding to each prediction category, the actual results corresponding to each prediction category are fused to obtain the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample.

3. The method according to claim 1, characterized in that, Before iteratively training the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the method further includes: Based on the first smoothing coefficient, the prediction result of the first target behavior is smoothed to obtain the processed prediction result of the first target behavior. Based on the second smoothing coefficient, the prediction result of the second target behavior is smoothed to obtain the processed prediction result of the second target behavior. The second target behavior prediction result of the processing is proportionally calculated with the corresponding first target behavior prediction result of the processing. The result of the proportional calculation is then mapped to obtain the second offset weight corresponding to each prediction category. The second offset weight is used to characterize the degree of offset between the first target behavior prediction result and the second target behavior prediction result. Based on the second offset weights corresponding to each prediction category, the second target behavior prediction results corresponding to each prediction category are fused to obtain the first difference between the first target behavior prediction result and the second target behavior prediction result.

4. The method according to any one of claims 1 to 3, characterized in that, The first initial behavior prediction model is iteratively trained based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, to obtain a target behavior prediction model, including: Weighted factor combinations are obtained from a preset search range; wherein, the weighted factor combination includes a first weighted factor and a second weighted factor; Based on each weighted factor combination, the first difference and the second difference are fused to obtain a first joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; and the second difference is the difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample. Based on each of the first joint losses, the first initial behavior prediction models are iteratively trained; the first initial behavior prediction model with the highest standard evaluation coefficient is determined as the target behavior prediction model.

5. The method according to claim 1, characterized in that, The first initial behavior prediction model includes a first encoder network and a first classifier network; the second initial behavior prediction model includes a second encoder network and a second classifier network; the second resource interaction forward sample is input into the first initial behavior prediction model, and the first target behavior prediction result is output. The second resource interaction post-sample is input into the second initial behavior prediction model, and the second target behavior prediction result is output, including: Based on the first encoder network, feature extraction is performed on the forward samples of the second resource interaction to obtain a first feature vector. Based on the first classifier network, the first feature vector is classified to obtain a first target behavior prediction result. Based on the second encoder network, feature extraction is performed on the second resource interaction backward sample to obtain a second feature vector. Based on the second classifier network, the second feature vector is classified to obtain the second target behavior prediction result. The iterative training of the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, includes: Based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

6. The method according to claim 5, characterized in that, The step of iteratively training the first initial behavior prediction model based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, to obtain the target behavior prediction model, includes: The weight coefficient combinations are obtained from the preset search range; wherein the weight coefficients include a first weight coefficient, a second weight coefficient, and a third weight coefficient. Based on each weight coefficient combination, the first difference, the second difference, and the third difference are fused to obtain a second joint loss; wherein, the first difference is the difference between the first target behavior prediction result and the second target behavior prediction result; the second difference is the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample; and the third difference is the difference between the first feature vector and the second feature vector. Based on each of the second joint losses, the first initial behavior prediction model is iteratively trained to determine the first initial behavior prediction model with the highest standard evaluation coefficient, which is then used as the target behavior prediction model.

7. The method according to claim 5, characterized in that, The iterative training of the first initial behavior prediction model based on the third difference between the first feature vector and the second feature vector, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample includes: The first feature value, the first feature key value, and the first feature query vector are extracted from the first feature vector based on the first attention network. Based on the correlation between the first feature key value and the first feature query vector, the first feature value is weighted and fused to obtain the processed first feature vector; The second feature value, the second feature key value, and the second feature query vector are extracted from the second feature vector based on the second attention network. Based on the correlation between the second feature key value and the second feature query vector, the second feature value is weighted and fused to obtain the processed second feature vector; Based on the third difference between the first feature vector and the second feature vector processed, the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, the first initial behavior prediction model is iteratively trained.

8. The method according to claim 1, characterized in that, Before obtaining the first initial behavior prediction model trained based on the first resource interaction forward samples and the second initial behavior prediction model trained based on the first resource interaction backward samples, the method further includes: Obtain a sample set; the sample set includes the first resource interaction backward sample and the labeled target behavior tags; The first resource interaction post-sample is input into the first original behavior prediction model, and the third target behavior prediction result is output. Based on the difference between the third target behavior prediction result and the target behavior label, the first original behavior prediction model is iteratively adjusted until the difference meets the preset requirements to obtain the second initial behavior prediction model.

9. The method according to claim 1, characterized in that, Before obtaining the first initial behavior prediction model trained based on the first resource interaction forward samples and the second initial behavior prediction model trained based on the first resource interaction backward samples, the method further includes: Obtain a sample set; the sample set includes the first resource interaction backward sample; Obtain the first positive sample, the second positive sample, and the negative sample from the sample set; Based on the second original behavior prediction model, feature extraction is performed on the first positive sample to obtain the third feature vector; Based on the second original behavior prediction model, feature extraction is performed on the second positive sample to obtain the fourth feature vector; Based on the second original behavior prediction model, feature extraction is performed on the negative sample to obtain the fifth feature vector; Based on the distance between the third feature vector and the fourth feature vector, and the distance between the third feature vector and the fifth feature vector, a contrastive loss is constructed; Based on the contrast loss, the second original behavior prediction model is iteratively adjusted until the difference meets the preset requirements, thus obtaining the second initial behavior prediction model.

10. The method according to claim 1, characterized in that, The iterative training of the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, includes: Obtain a third initial behavior prediction model trained based on the backward samples of the first resource interaction; wherein the type of the third initial behavior prediction model includes at least one. The first resource interaction feedback sample is input into each of the third initial behavior prediction models, and the prediction results of each third target behavior are output. Based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the first resource interaction data sample, the first initial behavior prediction model is iteratively trained based on the third differences between the first target behavior prediction result and each of the third target behavior prediction results.

11. A method for processing account data, characterized in that, The method includes: In response to a request for resource borrowing service permissions from an account to be processed, obtain the resource interaction forward data corresponding to the account to be processed; The forward data of resource interaction is input into a target behavior prediction model to predict the target behavior of the account to be processed. The target behavior prediction model is obtained by iteratively training a first initial behavior prediction model based on a first difference between a first target behavior prediction result and a second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the second forward resource interaction sample. The first target behavior prediction result is obtained by inputting the second forward resource interaction sample into the first initial behavior prediction model and outputting it. The second target behavior prediction result is obtained by inputting the second backward resource interaction sample into the second initial behavior prediction model and outputting it. The first initial behavior prediction model is trained based on the first forward resource interaction sample, and the second initial behavior prediction model is trained based on the first backward resource interaction sample. The forward resource interaction sample is the resource interaction data generated by the sample account without resource borrowing service permissions, and the backward resource interaction sample is the resource interaction data generated by the sample account with resource borrowing service permissions. Based on the target behavior of the account to be processed, determine the result of the resource borrowing service permission request corresponding to the request information.

12. An account data processing device, characterized in that, The device includes: The first acquisition module is used to acquire a first initial behavior prediction model trained based on forward samples of the first resource interaction, and a second initial behavior prediction model trained based on backward samples of the first resource interaction. The first prediction module is used to input the second resource interaction forward sample into the first initial behavior prediction model and output the first target behavior prediction result. The second prediction module is used to input the second resource interaction backward sample into the second initial behavior prediction model and output the second target behavior prediction result; wherein, the resource interaction forward sample is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the resource interaction backward sample is the resource interaction data generated by the matched sample account with the resource borrowing service permission. The first processing module is used to iteratively train the first initial behavior prediction model based on the first difference between the first target behavior prediction result and the second target behavior prediction result, and the second difference between the first target behavior prediction result and the actual result corresponding to the second resource interaction forward sample, to obtain a target behavior prediction model. The target behavior prediction model is used to predict the target behavior of the account to be processed for the resource borrowing service based on the resource interaction forward data of the account to be processed.

13. An account data processing device, characterized in that, The device includes: The second acquisition module is used to acquire the resource interaction forward data corresponding to the account to be processed in response to the request information of the resource borrowing service permission of the account to be processed. The third prediction module is used to input the forward data of resource interaction into the target behavior prediction model to predict the target behavior of the account to be processed; wherein, the target behavior prediction model is obtained by iteratively training a first initial behavior prediction model based on a first difference between the first target behavior prediction result and the second target behavior prediction result, and a second difference between the first target behavior prediction result and the actual result corresponding to the second forward sample of resource interaction; wherein, the first target behavior prediction result is obtained by inputting the second forward sample of resource interaction into the first initial behavior prediction model and outputting it; the second target behavior prediction result is obtained by inputting the second backward sample of resource interaction into the second initial behavior prediction model and outputting it; the first initial behavior prediction model is trained based on the first forward sample of resource interaction, and the second initial behavior prediction model is trained based on the first backward sample of resource interaction; wherein, the forward sample of resource interaction is the resource interaction data generated by the sample account without obtaining the resource borrowing service permission, and the backward sample of resource interaction is the resource interaction data generated by the sample account with the resource borrowing service permission. The determination module is used to determine the resource borrowing service permission request result corresponding to the request information based on the target behavior of the account to be processed.

14. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 10 or the steps of the method according to claim 11.

15. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 10 or the steps of the method according to claim 11.

16. A computer program product, comprising a computer program, characterized in that, When executed by a processor, the computer program implements the steps of the method according to any one of claims 1 to 10 or the steps of the method according to claim 11.