Resource recommendation method and apparatus, resource recommendation model training method and apparatus, and device

By introducing source domain interaction data into resource recommendation, filtering out the parts associated with the target domain, and predicting the interaction between objects and target resources, the problem of inaccurate recommendations caused by the sparsity of target domain data is solved, and the accuracy of resource recommendations is improved.

WO2026031903A1PCT designated stage Publication Date: 2026-02-12TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/106212
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-08-09
Filing Date
2025-06-30
Publication Date
2026-02-12

AI Technical Summary

Technical Problem

In existing technologies, the accuracy of resource recommendations is low due to the limited feedback data from users in a particular field.

Method used

By acquiring interaction data of objects in the source and target domains, filtering out source domain interaction data associated with the target domain, and combining object data and resource data, the interaction between objects and target resources can be predicted.

Benefits of technology

It improves the accuracy of resource recommendations, compensates for the lack of interactive data in the target domain, reduces interference from irrelevant data, and enhances the precision of recommendations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025106212_12022026_PF_FP_ABST
    Figure CN2025106212_12022026_PF_FP_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of computers, and discloses a resource recommendation method and apparatus, a resource recommendation model training method and apparatus, and a device. The method comprises: acquiring object data of an object and resource data of a target resource, the target resource belonging to a target domain; acquiring first source domain interaction data of the object and target domain interaction data of the object, wherein the first source domain interaction data comprises a plurality of source domain interaction items, the target domain interaction data comprises a plurality of target domain interaction items, and a source domain and the target domain belong to different fields; determining, from the first source domain interaction data, at least one source domain interaction item associated with the target domain to constitute second source domain interaction data; and determining a recommendation prediction result of the target resource on the basis of the object data, the resource data, the second source domain interaction data and the target domain interaction data. By introducing the source domain interaction data, the defect of insufficient target domain interaction data can be compensated for, thereby improving the accuracy of resource recommendation.
Need to check novelty before this filing date? Find Prior Art

Description

Resource recommendation method, training method and device of resource recommendation model, and equipment TECHNICAL FIELD

[0001] The present application claims priority to the Chinese patent application No. 2024110976362, filed on August 9, 2024, and entitled "Resource recommendation method, training method and device of resource recommendation model, and equipment", the whole content of which is incorporated herein by reference.

[0002] TECHNICAL FIELD

[0003] Embodiments of the present application relate to the technical field of computer, in particular to a resource recommendation method, a training method and device of a resource recommendation model, and equipment. BACKGROUND

[0004] With the rapid development of computer technology, artificial intelligence technology is increasingly widely used in the field of recommendation. For example, resources such as items, videos, music, etc. can be recommended to users, and users will provide feedback on the received resources. The feedback data can be used as a basis for the recommendation system to recommend to users.

[0005] In related technologies, for a recommendation task in a certain field, feedback data generated by a user in the field is usually used to infer which resources in the field to recommend to the user. However, if the feedback data generated by the user in the field is small, the amount of data used for resource recommendation is insufficient, which leads to low accuracy of resource recommendation. SUMMARY

[0006] Embodiments of the present application provide a resource recommendation method, a training method and device of a resource recommendation model, which can improve the accuracy of resource recommendation. The technical solution is as follows:

[0007] In one aspect, the present application provides a resource recommendation method, comprising:

[0008] Obtaining object data of an object and resource data of a target resource, the target resource belonging to a target domain, the target domain being any domain;

[0009] Obtaining first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data including a plurality of source domain interaction items, the source domain interaction item being an interaction item between the object and a resource in a source domain, the target domain interaction data including a plurality of target domain interaction items, the target domain interaction item being an interaction item between the object and a resource in the target domain, the source domain and the target domain belonging to different domains;

[0010] In the first source domain interaction data, at least one source domain interaction event associated with the target domain is determined to constitute second source domain interaction data;

[0011] Based on the object data, the resource data, the second source domain interaction data and the target domain interaction data, a recommendation prediction result of the target resource is determined, which is used to represent the interaction between the object and the target resource if the target resource is recommended to the object.

[0012] Optionally, if the similarity between the entity to which the resource in the source domain interaction event belongs and any target entity is greater than a similarity threshold, it is determined that the source domain interaction event is associated with the target domain, comprising:

[0013] Obtaining a target entity feature of each target entity;

[0014] Extracting features of the entity to which the resource in the source domain interaction event belongs to obtain a source domain entity feature;

[0015] If the similarity between the source domain entity feature and any target entity feature is greater than the similarity threshold, it is determined that the source domain interaction event is associated with the target domain.

[0016] Optionally, the feature extraction sub-model further comprises a second attention network, and the second attention network comprises a second mapping matrix; and the determination of the source domain interaction feature based on the second fusion interaction feature comprises:

[0017] Splitting an intermediate source domain interaction feature from the second fusion interaction feature;

[0018] Multiplying the resource feature and the second mapping matrix through the second attention network to obtain a second query feature, and multiplying the intermediate source domain interaction feature and the second mapping matrix to obtain a second key feature and a second value feature;

[0019] Fusing the second query feature, the second key feature and the second value feature through the second attention network to obtain the source domain interaction feature.

[0020] Optionally, the feature extraction sub-model further comprises a third attention network, and the third attention network comprises a third mapping matrix; and the determination of the target domain interaction feature based on the second fusion interaction feature comprises:

[0021] Splitting an intermediate target domain interaction feature from the second fusion interaction feature;

[0022] The third query feature, the third key feature and the third value feature are fused through the third attention network to obtain the target domain interactive feature.

[0023] The third query feature, the third key feature and the third value feature are fused through the third attention network to obtain the target domain interactive feature.

[0024] Optionally, after the recommendation prediction result of the target resource is determined based on the object data, the resource data, the second source domain interactive data and the target domain interactive data, the method further comprises:

[0025] If the recommendation prediction result meets a recommendation condition, the target resource is recommended to the object.

[0026] In another aspect, the application provides a training method of a resource recommendation model, the method comprising:

[0027] Sample object data of a sample object, sample resource data of a sample resource and a sample label are obtained, the sample resource belongs to a target domain, the sample label is used to represent a real interactive condition between the sample object and the sample resource after the sample resource is recommended to the sample object, and the target domain is any domain;

[0028] First sample source domain interactive data of the sample object and sample target domain interactive data of the sample object are obtained, the first sample source domain interactive data comprises a plurality of sample source domain interactive items, the sample source domain interactive item refers to an interactive item between the sample object and a resource in a source domain, the sample target domain interactive data comprises a plurality of sample target domain interactive items, the sample target domain interactive item refers to an interactive item between the sample object and a resource in the target domain, and the source domain and the target domain belong to different domains;

[0029] At least one sample source domain interactive item associated with the target domain is determined in the first sample source domain interactive data to constitute second sample source domain interactive data;

[0030] A recommendation prediction result of the sample resource is determined based on the sample object data, the sample resource data, the second sample source domain interactive data and the target domain sample interactive data through a resource recommendation model, the recommendation prediction result is used to represent a predicted interactive condition between the sample object and the sample resource if the sample resource is recommended to the sample object;

[0031] The resource recommendation model is trained based on the recommendation prediction result and the sample label.

[0032] Optionally, the feature extraction sub-model comprises a feature extraction network, a feature fusion network and a first attention network, the first attention network comprising a first mapping matrix; the feature extraction of the second sample source domain interaction data and the sample target domain interaction data by the feature extraction sub-model comprises:

[0033] the feature extraction of the second sample source domain interaction data by the feature extraction network to obtain initial sample source domain interaction features, and the feature extraction of the sample target domain interaction data to obtain initial sample target domain interaction features;

[0034] the fusion of the initial sample source domain interaction features and the initial sample target domain interaction features by the feature fusion network to obtain first sample fusion interaction features;

[0035] the multiplication of the first sample fusion interaction features and the first mapping matrix by the first attention network to obtain first sample query features, first sample key features and first sample value features, and the fusion of the first sample query features, the first sample key features and the first sample value features to obtain second sample fusion interaction features;

[0036] determination of the sample source domain interaction features and the sample target domain interaction features based on the second sample fusion interaction features.

[0037] Optionally, the feature extraction sub-model further comprises a second attention network, the second attention network comprising a second mapping matrix; the determination of the sample source domain interaction features and the sample target domain interaction features based on the second sample fusion interaction features comprises:

[0038] splitting of intermediate sample source domain interaction features from the second sample fusion interaction features;

[0039] the multiplication of the sample resource features and the second mapping matrix by the second attention network to obtain second sample query features, the multiplication of the intermediate sample source domain interaction features and the second mapping matrix to obtain second sample key features and second sample value features;

[0040] the fusion of the second sample query features, the second sample key features and the second sample value features by the second attention network to obtain the sample source domain interaction features.

[0041] Optionally, the feature extraction sub-model further comprises a third attention network, the third attention network comprising a third mapping matrix; and the determining the sample source domain interaction feature and the sample target domain interaction feature based on the second sample fusion interaction feature comprises:

[0042] splitting an intermediate sample target domain interaction feature from the second sample fusion interaction feature;

[0043] multiplying the sample resource feature and the third mapping matrix through the third attention network to obtain a third sample query feature, and multiplying the intermediate sample target domain interaction feature and the third mapping matrix to obtain a third sample key feature and a third sample value feature;

[0044] fusing the third sample query feature, the third sample key feature and the third sample value feature through the third attention network to obtain the sample target domain interaction feature.

[0045] Optionally, the determining at least one sample source domain interaction matter associated with the target domain in the first sample source domain interaction data comprises:

[0046] determining a plurality of target entities, the target entity referring to an entity to which a resource of the target domain belongs, the entity referring to an object providing the resource;

[0047] for any sample source domain interaction matter in the first sample source domain interaction data, if an entity to which a resource in the sample source domain interaction matter belongs is any of the target entities, it is determined that the sample source domain interaction matter is associated with the target domain.

[0048] Optionally, the determining at least one sample source domain interaction matter associated with the target domain in the first sample source domain interaction data comprises:

[0049] determining a plurality of target entities, the target entity referring to an entity to which a resource of the target domain belongs, the entity referring to an object providing the resource;

[0050] for any sample source domain interaction matter in the first sample source domain interaction data, if a similarity between an entity to which a resource in the sample source domain interaction matter belongs and any of the target entities is greater than a similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0051] Optionally, the determining that the sample source domain interaction matter is associated with the target domain if the similarity between the entity to which the resource in the sample source domain interaction matter belongs and any of the target entities is greater than the similarity threshold comprises:

[0052] obtaining a target entity feature of each of the target entities;

[0053] perform feature extraction on an entity to which a resource in the sample source domain interaction matter belongs, to obtain a sample source domain entity feature;

[0054] If a similarity between the sample source domain entity feature and any of the target entity features is greater than the similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0055] In another aspect, the present application provides a resource recommendation device, the device comprising:

[0056] a first acquisition module configured to acquire object data of an object and resource data of a target resource, the target resource belonging to a target domain, the target domain being any domain;

[0057] a second acquisition module configured to acquire first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data comprising a plurality of source domain interaction matters, the source domain interaction matter being an interaction matter between the object and a resource in a source domain, the target domain interaction data comprising a plurality of target domain interaction matters, the target domain interaction matter being an interaction matter between the object and a resource in the target domain, the source domain and the target domain belonging to different domains;

[0058] a screening module configured to determine at least one source domain interaction matter associated with the target domain in the first source domain interaction data, to constitute second source domain interaction data;

[0059] a prediction module configured to determine a recommendation prediction result of the target resource based on the object data, the resource data, the second source domain interaction data and the target domain interaction data, the recommendation prediction result being used to represent an interaction condition between the object and the target resource if the target resource is recommended to the object.

[0060] Optionally, the screening module is configured to:

[0061] determine a plurality of target entities, the target entity being an entity to which a resource in the target domain belongs, the entity being an object providing the resource;

[0062] For any source domain interaction matter in the first source domain interaction data, if an entity to which a resource in the source domain interaction matter belongs is any of the target entities, it is determined that the source domain interaction matter is associated with the target domain.

[0063] Optionally, the screening module is configured to:

[0064] determine a plurality of target entities, the target entity being an entity to which a resource in the target domain belongs, the entity being an object providing the resource;

[0065] For any source domain interaction matter in the first source domain interaction data, if the similarity between the entity to which the resource in the source domain interaction matter belongs and any target entity is greater than a similarity threshold, it is determined that the source domain interaction matter is associated with the target domain.

[0066] Optionally, the screening module is configured to:

[0067] obtain a target entity feature of each target entity;

[0068] extract a source domain entity feature from an entity to which a resource in the source domain interaction matter belongs;

[0069] if the similarity between the source domain entity feature and any target entity feature is greater than the similarity threshold, it is determined that the source domain interaction matter is associated with the target domain.

[0070] Optionally, the prediction module is configured to:

[0071] extract an object feature from the object data;

[0072] extract a resource feature from the resource data;

[0073] extract a source domain interaction feature and a target domain interaction feature from the second source domain interaction data and the target domain interaction data;

[0074] determine a recommendation prediction result of the target resource based on the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature.

[0075] Optionally, the prediction module is configured to:

[0076] extract an initial source domain interaction feature from the second source domain interaction data and an initial target domain interaction feature from the target domain interaction data;

[0077] fuse the initial source domain interaction feature and the initial target domain interaction feature to obtain a first fused interaction feature;

[0078] multiply the first fused interaction feature by a first mapping matrix to obtain a first query feature, a first key feature, and a first value feature;

[0079] fuse the first query feature, the first key feature, and the first value feature to obtain a second fused interaction feature;

[0080] determine the source domain interaction feature and the target domain interaction feature based on the second fused interaction feature.

[0081] Optionally, the prediction module is configured to:

[0082] split an intermediate source domain interaction feature from the second fused interaction feature;

[0083] multiply the resource feature by a second mapping matrix to obtain a second query feature;

[0084] multiply the intermediate source domain interaction feature by the second mapping matrix to obtain a second key feature and a second value feature;

[0085] fuse the second query feature, the second key feature and the second value feature to obtain the source domain interaction feature.

[0086] Optionally, the prediction module is configured to:

[0087] split an intermediate target domain interaction feature from the second fused interaction feature;

[0088] multiply the resource feature by a third mapping matrix to obtain a third query feature;

[0089] multiply the intermediate target domain interaction feature by the third mapping matrix to obtain a third key feature and a third value feature;

[0090] fuse the third query feature, the third key feature and the third value feature to obtain the target domain interaction feature.

[0091] Optionally, the resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model, and the prediction module is configured to:

[0092] extract features of the object data by the feature extraction sub-model to obtain object features;

[0093] extract features of the resource data by the feature extraction sub-model to obtain resource features;

[0094] extract features of the second source domain interaction data and the target domain interaction data by the feature extraction sub-model to obtain source domain interaction features and target domain interaction features;

[0095] determine the recommendation prediction result of the target resource based on the object features, the resource features, the source domain interaction features and the target domain interaction features by the recommendation prediction sub-model.

[0096] Optionally, the feature extraction sub-model comprises a feature extraction network, a feature fusion network and a first attention network, the first attention network comprises a first mapping matrix, and the prediction module is configured to:

[0097] extracting features of the second source domain interaction data through the feature extraction network to obtain initial source domain interaction features, and extracting features of the target domain interaction data to obtain initial target domain interaction features;

[0098] fusing the initial source domain interaction features and the initial target domain interaction features through the feature fusion network to obtain first fused interaction features;

[0099] multiplying the first fused interaction features and the first mapping matrix through the first attention network to obtain first query features, first key features and first value features, and fusing the first query features, the first key features and the first value features to obtain second fused interaction features;

[0100] determining the source domain interaction features and the target domain interaction features based on the second fused interaction features.

[0101] Optionally, the feature extraction sub-model further comprises a second attention network, and the second attention network comprises a second mapping matrix; the prediction module is configured to:

[0102] splitting intermediate source domain interaction features from the second fused interaction features;

[0103] multiplying the resource features and the second mapping matrix through the second attention network to obtain second query features, and multiplying the intermediate source domain interaction features and the second mapping matrix to obtain second key features and second value features;

[0104] fusing the second query features, the second key features and the second value features through the second attention network to obtain the source domain interaction features.

[0105] Optionally, the feature extraction sub-model further comprises a third attention network, and the third attention network comprises a third mapping matrix; the prediction module is configured to:

[0106] splitting intermediate target domain interaction features from the second fused interaction features;

[0107] multiplying the resource features and the third mapping matrix through the third attention network to obtain third query features, and multiplying the intermediate target domain interaction features and the third mapping matrix to obtain third key features and third value features;

[0108] fusing the third query features, the third key features and the third value features through the third attention network to obtain the target domain interaction features.

[0109] Optionally, the apparatus further comprises:

[0110] a recommendation module configured to recommend the target resource to the object if the recommendation prediction result meets a recommendation condition.

[0111] In another aspect, the present application provides a resource recommendation apparatus, the apparatus comprising:

[0112] a first obtaining module configured to obtain sample object data of a sample object, sample resource data of a sample resource, and a sample label, the sample resource belonging to a target domain, the sample label being used to indicate a real interaction between the sample object and the sample resource after the sample resource is recommended to the sample object, the target domain being any domain;

[0113] a second obtaining module configured to obtain first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object, the first sample source domain interaction data comprising a plurality of sample source domain interaction items, the sample source domain interaction item being an item of interaction between the sample object and a resource in a source domain, the sample target domain interaction data comprising a plurality of sample target domain interaction items, the sample target domain interaction item being an item of interaction between the sample object and a resource in the target domain, the source domain and the target domain belonging to different domains;

[0114] a screening module configured to determine at least one sample source domain interaction item associated with the target domain in the first sample source domain interaction data to form second sample source domain interaction data;

[0115] a prediction module configured to determine a recommendation prediction result of the sample resource based on the sample object data, the sample resource data, the second sample source domain interaction data, and the target domain sample interaction data by using a resource recommendation model, the recommendation prediction result being used to represent a predicted interaction between the sample object and the sample resource if the sample resource is recommended to the sample object;

[0116] a training module configured to train the resource recommendation model based on the recommendation prediction result and the sample label.

[0117] Optionally, the resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model; the prediction module is configured to:

[0118] extract features of the sample object data by using the feature extraction sub-model to obtain sample object features;

[0119] extract features of the sample resource data by using the feature extraction sub-model to obtain sample resource features;

[0120] The feature extraction sub-model is used for feature extraction on the second sample source domain interaction data and the sample target domain interaction data, to obtain sample source domain interaction features and sample target domain interaction features;

[0121] The recommendation prediction sub-model is used for determining the recommendation prediction result based on the sample object features, the sample resource features, the sample source domain interaction features and the sample target domain interaction features.

[0122] Optionally, the sample source domain interaction events include source domain resources and interaction time points of the source domain resources, the sample target domain interaction events include target domain resources and interaction time points of the target domain resources, the sample source domain interaction features include source domain resource features of the source domain resources in each sample source domain interaction event, and the sample target domain interaction features include target domain resource features of the target domain resources in each sample target domain interaction event; the apparatus further includes:

[0123] The first determining module is configured to, for any source domain resource in the second sample source domain interaction data, determine a first target domain resource in the sample target domain interaction data, determine source domain resource features of the source domain resource and target domain resource features of the first target domain resource as a first positive sample pair, and determine a similarity between the source domain resource features and the target domain resource features in the first positive sample pair, wherein the interaction time point of the first target domain resource is closest to the interaction time point of the source domain resource.

[0124] The training module is configured to:

[0125] The resource recommendation model is trained based on the recommendation prediction result, the sample label, and the similarity between the source domain resource features and the target domain resource features in the first positive sample pair.

[0126] Optionally, the apparatus further includes:

[0127] The second determining module is configured to, for any source domain resource in the second sample source domain interaction data, determine a second target domain resource in sample target domain interaction data of any object other than the sample object, determine source domain resource features of the source domain resource and target domain resource features of the second target domain resource as a first negative sample pair, and determine a similarity between the source domain resource features and the target domain resource features in the first negative sample pair, wherein the second target domain resource is any target domain resource in the sample target domain interaction data of the any object.

[0128] The training module is configured to:

[0129] The resource recommendation model is trained based on the recommendation prediction result, the sample label, similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, and similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair.

[0130] Optionally, the sample source domain interactive matter includes a source domain resource and an entity to which the source domain resource belongs, the sample target domain interactive matter includes a target domain resource and an entity to which the target domain resource belongs, the sample source domain interactive feature includes a source domain resource feature of the source domain resource in each sample source domain interactive matter, and the sample target domain interactive feature includes a target domain resource feature of the target domain resource in each sample target domain interactive matter. The apparatus further includes:

[0131] The third determination module is configured to, for any source domain resource in the second sample source domain interactive data, determine a third target domain resource in the sample target domain interactive data, determine a source domain resource feature of the source domain resource and a target domain resource feature of the third target domain resource as a second positive sample pair, and determine similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, where the entity to which the third target domain resource belongs is the same as the entity to which the source domain resource belongs.

[0132] The training module is configured to:

[0133] The resource recommendation model is trained based on the recommendation prediction result, the sample label, similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, and similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair.

[0134] Optionally, the apparatus further includes:

[0135] The fourth determination module is configured to, for any source domain resource in the second sample source domain interactive data, determine a fourth target domain resource, determine a source domain resource feature of the source domain resource and a target domain resource feature of the fourth target domain resource as a second negative sample pair, and determine similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair, where the fourth target domain resource is any target domain resource different from the entity to which the source domain resource belongs.

[0136] The training module is configured to:

[0137] The resource recommendation model is trained based on the recommendation prediction result, the sample label, similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, and similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair.

[0138] Optionally, the feature extraction sub-model comprises a feature extraction network, a feature fusion network, and a first attention network, the first attention network comprising a first mapping matrix; the prediction module is configured to:

[0139] extracting, by the feature extraction network, the second sample source domain interaction data to obtain initial sample source domain interaction features, and extracting the sample target domain interaction data to obtain initial sample target domain interaction features;

[0140] fusing, by the feature fusion network, the initial sample source domain interaction features and the initial sample target domain interaction features to obtain first sample fusion interaction features;

[0141] multiplying, by the first attention network, the first sample fusion interaction features and the first mapping matrix to obtain first sample query features, first sample key features, and first sample value features, and fusing the first sample query features, the first sample key features, and the first sample value features to obtain second sample fusion interaction features;

[0142] determining the sample source domain interaction features and the sample target domain interaction features based on the second sample fusion interaction features.

[0143] Optionally, the feature extraction sub-model further comprises a second attention network, the second attention network comprising a second mapping matrix; the prediction module is configured to:

[0144] splitting out intermediate sample source domain interaction features from the second sample fusion interaction features;

[0145] multiplying, by the second attention network, the sample resource features and the second mapping matrix to obtain second sample query features, and multiplying the intermediate sample source domain interaction features and the second mapping matrix to obtain second sample key features and second sample value features;

[0146] fusing, by the second attention network, the second sample query features, the second sample key features, and the second sample value features to obtain the sample source domain interaction features.

[0147] Optionally, the feature extraction sub-model further comprises a third attention network, the third attention network comprising a third mapping matrix; the prediction module is configured to:

[0148] splitting out intermediate sample target domain interaction features from the second sample fusion interaction features;

[0149] The third sample query feature is obtained by multiplying the sample resource feature and the third mapping matrix through the third attention network, and the third sample key feature and the third sample value feature are obtained by multiplying the intermediate sample target domain interaction feature and the third mapping matrix;

[0150] The sample target domain interaction feature is obtained by fusing the third sample query feature, the third sample key feature and the third sample value feature through the third attention network.

[0151] Optionally, the screening module is configured to:

[0152] a plurality of target entities are determined, the target entity being an entity to which a resource of the target domain belongs, the entity being an object providing the resource;

[0153] For any sample source domain interaction matter in the first sample source domain interaction data, if an entity to which a resource in the sample source domain interaction matter belongs is any target entity, it is determined that the sample source domain interaction matter is associated with the target domain.

[0154] Optionally, the screening module is configured to:

[0155] a plurality of target entities are determined, the target entity being an entity to which a resource of the target domain belongs, the entity being an object providing the resource;

[0156] For any sample source domain interaction matter in the first sample source domain interaction data, if a similarity between an entity to which a resource in the sample source domain interaction matter belongs and any target entity is greater than a similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0157] Optionally, the screening module is configured to:

[0158] a target entity feature of each target entity is obtained;

[0159] a sample source domain entity feature is obtained by performing feature extraction on an entity to which a resource in the sample source domain interaction matter belongs;

[0160] If a similarity between the sample source domain entity feature and any target entity feature is greater than the similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0161] In another aspect, the present application provides a computer device, comprising a processor and a memory, wherein the memory stores at least one computer program, and the at least one computer program is loaded and executed by the processor to implement the operations performed by the resource recommendation method according to the above aspect, or implement the operations performed by the training method of the resource recommendation model according to the above aspect.

[0162] In another aspect, the present application provides a computer readable storage medium, wherein the computer readable storage medium stores at least one computer program, and the at least one computer program is loaded and executed by a processor to implement the operations performed by the resource recommendation method according to the above aspect, or implement the operations performed by the training method of the resource recommendation model according to the above aspect.

[0163] In another aspect, the present application provides a computer program product, comprising a computer program, wherein the computer program is loaded and executed by a processor to implement the operations performed by the resource recommendation method according to the above aspect, or implement the operations performed by the training method of the resource recommendation model according to the above aspect.

[0164] The scheme provided by the embodiments of the present application needs to refer to the historical interaction of the object and other resources to infer the interaction tendency of the object to the target resource when determining whether to recommend the target resource of the target domain to the object. Therefore, the target domain interaction data of the object in the target domain is obtained, and considering that the target domain interaction data may be insufficient in data quantity, the source domain interaction data of the object in the source domain is additionally obtained, and the part associated with the target domain is filtered out from the source domain interaction data, and then the target domain interaction data and the filtered source domain interaction data are used as references to predict the interaction between the object and the target resource if the target resource is recommended to the object. On the one hand, since the source domain interaction data is introduced, the defect of insufficient target domain interaction data can be made up, and the influence caused by the sparsity of the target domain interaction data is alleviated. On the other hand, since only the source domain interaction data associated with the target domain is considered, the source domain interaction data irrelevant to the target domain is discarded, so the interference of the source domain interaction data irrelevant to the target domain on the prediction result can be reduced, thereby improving the accuracy of resource recommendation as a whole. BRIEF DESCRIPTION OF DRAWINGS

[0165] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creating laborious work.

[0166] FIG. 1 is a schematic diagram of an implementation environment provided by an embodiment of the present application;

[0167] FIG. 2 is a flowchart of a resource recommendation method according to an embodiment of the present application;

[0168] FIG. 3 is a flowchart of another resource recommendation method according to an embodiment of the present application;

[0169] FIG. 4 is a data volume comparison diagram according to an embodiment of the present application;

[0170] FIG. 5 is a schematic diagram of a resource recommendation method according to an embodiment of the present application;

[0171] FIG. 6 is a flowchart of another resource recommendation method according to an embodiment of the present application;

[0172] FIG. 7 is a flowchart of a training method of a resource recommendation model according to an embodiment of the present application;

[0173] FIG. 8 is a flowchart of another training method of a resource recommendation model according to an embodiment of the present application;

[0174] FIG. 9 is a schematic diagram of a training method of a resource recommendation model according to an embodiment of the present application;

[0175] FIG. 10 is a whole architecture diagram of a resource recommendation method according to an embodiment of the present application;

[0176] FIG. 11 is a flowchart of another resource recommendation method according to an embodiment of the present application;

[0177] FIG. 12 is a schematic diagram of a service interface according to an embodiment of the present application;

[0178] FIG. 13 is a schematic diagram of a recharge interface according to an embodiment of the present application;

[0179] FIG. 14 is a schematic diagram of another service interface according to an embodiment of the present application;

[0180] FIG. 15 is a structural schematic diagram of a resource recommendation apparatus according to an embodiment of the present application;

[0181] FIG. 16 is a structural schematic diagram of another resource recommendation apparatus according to an embodiment of the present application;

[0182] FIG. 17 is a structural schematic diagram of a training apparatus of a resource recommendation model according to an embodiment of the present application;

[0183] FIG. 18 is a structural schematic diagram of another training apparatus of a resource recommendation model according to an embodiment of the present application;

[0184] FIG. 19 is a structural schematic diagram of a terminal according to an embodiment of the present application;

[0185] FIG. 20 is a structural schematic diagram of a server according to an embodiment of the present application. DETAILED DESCRIPTION

[0186] In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the following further describes the embodiments of the present application with reference to the drawings.

[0187] It can be understood that the terms "first", "second", and the like as used in the present application can be used in the description of various concepts herein, but unless specifically stated, these concepts are not limited by these terms. These terms are only used to distinguish one concept from another concept. For example, without departing from the scope of the present application, a first source domain interaction data can be referred to as a second source domain interaction data, and similarly, a second source domain interaction data can be referred to as a first source domain interaction data.

[0188] Among them, at least one refers to one or more than one, for example, at least one source domain interaction matter can be one source domain interaction matter, two source domain interaction matters, three source domain interaction matters, or any integer greater than or equal to one source domain interaction matter. Multiple refers to two or more than two, for example, multiple source domain interaction matters can be two source domain interaction matters, three source domain interaction matters, or any integer greater than or equal to two source domain interaction matters. Each refers to each of at least one, for example, each source domain interaction matter refers to each source domain interaction matter in multiple source domain interaction matters, if the multiple source domain interaction matters are three source domain interaction matters, each source domain interaction matter refers to each source domain interaction matter in the three source domain interaction matters.

[0189] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data for analysis, stored data, displayed data, etc.) and signals (including but not limited to signals transmitted between user terminals and other devices, etc.) involved in the present application are all fully authorized by users or relevant parties, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.

[0190] For example, the object data, resource data, source domain interaction data and target domain interaction data involved in the present application are all fully authorized by users or relevant parties, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.

[0191] The resource recommendation method provided by the embodiments of the present application can be used in a computer device. Optionally, the computer device is a terminal or a server. Optionally, the server is a physical server, or a server cluster or a distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud service, cloud database, cloud computing, cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, CDN (Content Delivery Network), and big data and artificial intelligence platform. Optionally, the terminal is a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, a smart voice interaction device, a smart home appliance, a vehicle-mounted terminal, an aircraft, and the like, but is not limited thereto. The embodiments of the present application can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, intelligent transportation, and assisted driving.

[0192] In a possible implementation manner, the computer program related to the embodiments of the present application can be deployed to execute on one computer device, or to execute on multiple computer devices located in one place, or to execute on multiple computer devices distributed in multiple places and interconnected through a communication network, and the multiple computer devices distributed in multiple places and interconnected through a communication network can constitute a blockchain system.

[0193] In a possible implementation manner, the computer device in the embodiments of the present application is a node in the blockchain system, which can store object data, resource data, source domain interaction data, target domain interaction data and the like in the blockchain, and then the node or other nodes corresponding to the node in the blockchain can query the data stored in the blockchain by accessing the blockchain.

[0194] FIG. 1 is a schematic diagram of an implementation environment provided by the embodiments of the present application, referring to FIG. 1, the implementation environment includes a terminal 101 and a server 102. The terminal 101 and the server 102 are connected through a wireless or wired network.

[0195] The terminal 101 is installed and runs a client 111, which can be a social application client, an online payment client, a network shopping client, a game client, a medical service client, a video client, and the like. When the terminal 101 runs the client 111, a user interface of the client 111 is displayed on a screen of the terminal 101. The terminal 101 is a terminal used by a user 121.

[0196] Optionally, the terminal 101 can refer to one of a plurality of terminals, and the terminal 101 includes, but is not limited to, a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart voice interaction device, a smart household appliance, a vehicle terminal, a flying device, a virtual reality (VR) device, an augmented reality (AR) device, and the like.

[0197] It can be appreciated by those skilled in the art that the number of the terminals can be more or less. For example, the terminals can be only one, or the terminals can be six or eight or more. Embodiments of the present application do not limit the number of the terminals and the types of the devices.

[0198] Only one terminal is shown in FIG. 1, but there are a plurality of other terminals 103 that can access the server 102 in different embodiments. Optionally, there is also one or more terminals 103 that are corresponding to developers, and a development and editing platform of the client is installed on the terminal 103. The developers can edit and update the client on the terminal 103, and transmit the updated client installation package to the server 102 through a wired or wireless network. The terminal 101 can download the client installation package from the server 102 to implement the update of the client.

[0199] The terminal 101 and the other terminals 103 are connected to the server 102 through a wired network or a wireless network.

[0200] The server 102 includes at least one of a server, a plurality of servers, a cloud computing platform, and a virtualization center. The server 102 is configured to provide a background service for the client. Optionally, the server 102 undertakes a main computing work, and the terminal 101 undertakes a secondary computing work; or the server 102 undertakes a secondary computing work, and the terminal 101 undertakes a main computing work; or the server 102 and the terminal 101 adopt a distributed computing architecture to perform collaborative computing.

[0201] In embodiments of the present application, the terminal 101 sends a recommendation task for an object to the server 102. After receiving the recommendation task, the server 102 acquires object data of the object and resource data of a target resource to be recommended, and acquires source domain interaction data and target domain interaction data of the object. The target resource belongs to a resource of a target domain. The server 102 determines a recommendation prediction result according to the object data of the object, the resource data of the target resource, the source domain interaction data, and the target domain interaction data. If the recommendation prediction result indicates that the object is more likely to interact with the target resource if the target resource is recommended to the object, the server 102 returns the target resource to the terminal 101. The terminal 101 receives the target resource and recommends the target resource to the object.

[0202] It should be noted that the above implementation environment is only an example, and the method provided by the embodiment of the present application can also be executed by the terminal 101 or the server 102 alone, or by other computer devices, and the embodiment of the present application does not limit this.

[0203] FIG. 2 is a flowchart of a resource recommendation method provided by an embodiment of the present application, which is executed by a computer device, such as the terminal 101 or the server 102 shown in FIG. 1. Referring to FIG. 2, the method includes the following steps.

[0204] 201. The computer device acquires object data of an object and resource data of a target resource, the target resource belonging to a target domain.

[0205] The computer device acquires object data of an object, which is an object to which a resource is to be recommended, for example, the object can be an account, etc. The object data includes an object nickname, an object age, an object label, and preference information of the object, etc.

[0206] The computer device acquires a target resource, which is a resource to be recommended to the object. In the embodiment of the present application, the resource can include a virtual resource, an item resource, an image resource, a video resource, a graphic-text resource, etc. For example, the virtual resource can be a coupon for exchanging an item, etc.

[0207] In the embodiment of the present application, the target resource belongs to a target domain, which can be any domain. For example, the target domain can be an advertising delivery domain, a video recommendation domain, an item recommendation domain, etc., and the embodiment of the present application does not limit this.

[0208] 202. The computer device acquires first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data including a plurality of source domain interaction items, a source domain interaction item being an item of interaction of the object with a resource in a source domain, the target domain interaction data including a plurality of target domain interaction items, a target domain interaction item being an item of interaction of the object with a resource in a target domain, the source domain and the target domain belonging to different domains.

[0209] In the embodiment of the present application, the source domain can be any domain different from the target domain, for example, the source domain can be a shopping domain, a video playing domain, etc.

[0210] The computer device acquires first source domain interaction data of the object, which is acquired according to a historical interaction of the object with at least one resource in a source domain. The first source domain interaction data includes a plurality of source domain interaction items, one source domain interaction item being an item of interaction of the object with a resource in a source domain, that is, the source domain interaction item records a resource in the source domain that the object has interacted with.

[0211] The computer device obtains target domain interaction data of the object, the target domain interaction data being obtained according to historical interaction of the object with at least one resource in a target domain. The target domain interaction data includes a plurality of target domain interaction events, and one target domain interaction event refers to an interaction event of the object with a resource in the target domain, that is, the target domain interaction event records a resource in the target domain that has been interacted with by the object.

[0212] Optionally, the object interacts with the resource in multiple ways. For example, the resource is an article, and the object interacts with the resource by purchasing the article; for another example, the resource is a virtual resource (such as a coupon), and the object interacts with the resource by obtaining the virtual resource; for another example, the resource is a video, and the object interacts with the resource by playing the video; for another example, the resource is an electronic book, and the object interacts with the resource by reading the electronic book, and the like.

[0213] 203. The computer device determines at least one source domain interaction event associated with the target domain in the first source domain interaction data to form second source domain interaction data.

[0214] The first source domain interaction data includes a plurality of source domain interaction events, some of which are associated with the target domain, and some of which are not associated with the target domain. In the embodiment of the present application, the source domain interaction event is used as a reference to predict whether the target resource in the target domain is recommended to the object. If the reference source domain interaction event is not associated with the target domain, it will interfere with the prediction result, and also increase the processing burden.

[0215] Therefore, after determining the first source domain interaction data, at least one source domain interaction event associated with the target domain is selected therefrom to form second source domain interaction data, and the second source domain interaction data associated with the target domain is used to predict whether the target resource in the target domain is recommended to the object.

[0216] 204. The computer device determines a recommendation prediction result of the target resource based on the object data, the resource data, the second source domain interaction data, and the target domain interaction data, and the recommendation prediction result is used to represent an interaction of the object with the target resource if the target resource is recommended to the object.

[0217] Since the object data can reflect the characteristics of the object, the resource data can reflect the characteristics of the target resource, the second source domain interaction data can reflect the interest tendency of the object to the resource in the source domain, and the target domain interaction data can reflect the interest tendency of the object to the resource in the target domain, therefore, by using the object data, the resource data, the second source domain interaction data and the target domain interaction data, the interest tendency of the object to the target resource can be inferred, and then the recommendation prediction result of the target resource is determined, the recommendation prediction result is used to represent the interaction tendency of the object to the target resource, that is, if the object is recommended the target resource, how large the possibility is that the object interacts with the target resource. If the possibility that the object interacts with the target resource is relatively large, the target resource can be recommended to the object in the subsequent, and if the possibility that the object interacts with the target resource is relatively small, the target resource can not be recommended to the object in the subsequent.

[0218] The method provided by the embodiment of the present application needs to refer to the historical interaction of the object with other resources to infer the interaction tendency of the object to the target resource when determining whether to recommend the target resource of the target domain to the object. Therefore, the target domain interaction data of the object in the target domain is obtained, and the source domain interaction data of the object in the source domain is additionally obtained considering that the target domain interaction data may have insufficient data amount, and the part associated with the target domain is filtered out from the source domain interaction data, and then the target domain interaction data and the filtered source domain interaction data are used as references to predict the interaction of the object with the target resource if the target resource is recommended to the object. On the one hand, since the source domain interaction data is introduced, the defect of insufficient target domain interaction data can be made up, and the influence caused by the sparsity of the target domain interaction data is alleviated, and on the other hand, since only the source domain interaction data associated with the target domain is considered and the source domain interaction data irrelevant to the target domain is discarded, the interference of the source domain interaction data irrelevant to the target domain on the prediction result can be reduced, thereby the accuracy of the resource recommendation is improved as a whole.

[0219] On the basis of the above embodiment, FIG. 3 is a flow chart of another resource recommendation method provided by the embodiment of the present application, and the embodiment of the present application is executed by a computer device, which is a terminal 101 or a server 102 as shown in FIG. 1, etc. Referring to FIG. 3, the method comprises:

[0220] 301. The computer device obtains object data of an object and resource data of a target resource, and the target resource belongs to a target domain.

[0221] In a possible implementation manner, the computer device obtains registration data of the object, resource data of resources that the object has ever interacted with, etc. as the object data of the object. The registration data refers to the data provided when the object is registered, and can include a nickname of the object, an age of the object, etc.

[0222] In a possible implementation, the computer device obtains resource name, resource type, and entity to which the target resource belongs, as resource data of the target resource.

[0223] 302. The computer device obtains first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data comprising a plurality of source domain interaction items, a source domain interaction item being an interaction item of the object with a resource in a source domain, the target domain interaction data comprising a plurality of target domain interaction items, a target domain interaction item being an interaction item of the object with a resource in a target domain, the source domain and the target domain belonging to different domains.

[0224] In a possible implementation, the computer device obtains a plurality of source domain interaction items that have occurred to the object within a preset time length before the current time point, and takes the plurality of source domain interaction items within the preset time length as the first source domain interaction data.

[0225] Optionally, the preset time length is pre-set, for example, 6 months, 3 months, or the like.

[0226] Optionally, each source domain interaction item comprises a source domain resource interacted by the object, an entity to which the source domain resource belongs, and an interaction time point. The entity to which the source domain resource belongs refers to an object that provides the source domain resource, for example, the entity can be a company or a manufacturer, or the like.

[0227] For example, in a case where the source domain is a shopping scenario, the source domain resource is a purchased item, the source domain interaction item is a shopping item, the computer device is associated with a target client, the target client is provided with a payment function, and the computer device stores a payment bill generated by a payment operation of the object in the target client. The computer device obtains a plurality of payment bills of the object generated within a preset time length between the current time point, and for each payment bill, the computer device generates a source domain interaction item based on the payment bill, the source domain interaction item comprising a purchased item in the payment bill, an entity to which the item belongs, and a payment time point. The purchased item is the source domain resource, and the payment time point is the interaction time point.

[0228] In a possible implementation, the computer device obtains a plurality of target domain interaction items that have occurred to the object within a preset time length before the current time point, and takes the plurality of target domain interaction items within the preset time length as the first target domain interaction data.

[0229] Optionally, each target domain interaction item comprises a target domain resource interacted by the object, an entity to which the target domain resource belongs, and an interaction time point. The entity to which the target domain resource belongs refers to an object that provides the target domain resource, for example, the entity can be a company or a manufacturer, or the like.

[0230] Exemplarily, in a case where the target domain is an advertisement delivery scenario, the target domain resource is a virtual resource contained in a delivered advertisement, and the virtual resource is used to exchange the item in the source domain. The target domain interaction matter is a virtual resource collection matter, and the computer device is associated with a target client. The target client is provided with an advertisement delivery function, and the advertisement containing the virtual resource can be delivered in the target client. The computer device stores a collection record generated by a virtual resource collection operation of the object performed in the target client. The computer device obtains a plurality of collection records of the object generated within a preset time length between a current time point. For each collection record, the computer device generates a target domain interaction matter based on the collection record. The target domain interaction matter includes the virtual resource collected in the collection record, the entity to which the virtual resource belongs, and the collection time point. The purchased virtual resource is the target domain resource, and the collection time point is the interaction time point.

[0231] 303、The computer device determines at least one source domain interaction matter associated with the target domain in the first source domain interaction data to constitute second source domain interaction data.

[0232] The computer device stores interaction data of a plurality of objects. Each object corresponds to a respective source domain interaction matter and a target domain interaction matter. The data amount of the source domain interaction matter of each object is huge. As shown in FIG. 4, the total number of the source domain interaction matters and the target domain interaction matters of the plurality of objects is counted. The maximum number of the total number of the source domain interaction matters reaches about 5000, the median number of the total number of the source domain interaction matters reaches about 1000, and the maximum number of the total number of the target domain interaction matters is much less than 1000.

[0233] Therefore, the number of the plurality of source domain interaction matters in the first source domain interaction data obtained by the computer device is also large. However, among the plurality of source domain interaction matters, some source domain interaction matters are associated with the target domain, and some source domain interaction matters are irrelevant to the target domain. In the embodiment of the present application, it is necessary to refer to the source domain interaction matter to predict whether to recommend the target resource in the target domain to the object. If the source domain interaction matter referred to is irrelevant to the target domain, it will interfere with the prediction result, and because the data amount is large, it will also increase the processing burden.

[0234] Based on this, after determining the first source domain interaction data, at least one source domain interaction matter associated with the target domain is selected therefrom to constitute second source domain interaction data, so as to ensure that all source domain interaction matters in the second source domain interaction data are related to the target domain, and the second source domain interaction data is used subsequently to predict whether to recommend the target resource in the target domain to the object. On the one hand, it can ensure that the source domain interaction data referred to is strongly related to the target domain, and on the other hand, it can effectively reduce the amount of data required to be processed and reduce the processing burden.

[0235] In a possible implementation, the computer device determines a plurality of target entities, where a target entity refers to an entity to which a resource of the target domain belongs, and an entity refers to an object providing a resource; for any source domain interaction event in the first source domain interaction data, if an entity to which a resource in the source domain interaction event belongs is any target entity, it is determined that the source domain interaction event is associated with the target domain.

[0236] The resources of the target domain have respective entities to which the resources belong, and the entities to which the resources of the target domain belong are determined as target entities. The resources of the source domain have respective entities to which the resources belong, and for any source domain interaction event, if an entity to which a resource in the source domain interaction event belongs is the same as any target entity, it can be considered that the source domain interaction event is associated with the target domain.

[0237] In the embodiments of the present application, it is considered that a user can have similar interaction tendencies for different resources provided by the same entity, and if an entity to which a resource in the source domain interaction event belongs is the same as an entity to which a resource of the target domain belongs, it can be considered that the source domain interaction event is associated with the target domain, and the interaction tendency of the user for a resource provided by the same entity in the target domain can be predicted by taking the source domain interaction event as a reference, which is beneficial to ensure the accuracy of cross-domain mining of user interests and further improve the accuracy of resource recommendation.

[0238] Moreover, the source domain interaction event associated with the target domain is found by taking the same entity as a condition, which can ensure that the found source domain interaction event has strong correlation with the target domain, and is beneficial to improve the accuracy of finding the source domain interaction event associated with the target domain.

[0239] In another possible implementation, the computer device determines a plurality of target entities, where a target entity refers to an entity to which a resource of the target domain belongs, and an entity refers to an object providing a resource; for any source domain interaction event in the first source domain interaction data, if a similarity between an entity to which a resource in the source domain interaction event belongs and any target entity is greater than a similarity threshold, it is determined that the source domain interaction event is associated with the target domain.

[0240] For any source domain interaction event, if a similarity between an entity to which a resource in the source domain interaction event belongs and any target entity is greater than a similarity threshold, it can be considered that the source domain interaction event is associated with the target domain.

[0241] Optionally, the computer device can use a large language model to determine the similarity between the entity to which the resource in the source domain interaction event belongs and any target entity.

[0242] Optionally, the computer device obtains target entity features of each target entity; performs feature extraction on an entity to which a resource in the source domain interactive matter belongs, to obtain source domain entity features; and if a similarity between the source domain entity features and any target entity feature is greater than a similarity threshold, it is determined that the source domain interactive matter is associated with the target domain.

[0243] For example, the computer device obtains an entity name of a target entity, inputs the entity name of the target entity into a text semantic extraction model, and obtains target entity features output by the text semantic extraction model. The computer device obtains an entity name to which a source domain resource belongs, inputs the entity name to which the source domain resource belongs into the text semantic extraction model, and obtains source domain entity features output by the text semantic extraction model.

[0244] The text semantic extraction model is used to extract semantic features, and can be a deep learning model, a machine learning model, or a large language model, etc. For example, the text semantic extraction model can be a BGE (BAAI General Embedding, text semantic vector model).

[0245] For example, the computer device determines similarities between the source domain entity features and each target entity feature, and obtains a maximum similarity from the determined multiple similarities. If the maximum similarity is greater than a similarity threshold, the source domain interactive matter is determined to be associated with the target domain.

[0246] The similarity can be a cosine similarity, etc. The similarity threshold can be a pre-set threshold, for example, the similarity threshold can be equal to 0.8 or 0.85, etc.

[0247] In the embodiments of the present application, considering that a user can have a similar interactive tendency to different resources provided by similar entities, if an entity to which a resource in a source domain interactive matter belongs is similar to an entity to which a resource in a target domain belongs, it can be considered that the source domain interactive matter is associated with the target domain, and the interactive tendency of the user to the resources provided by similar entities in the target domain can be predicted by taking the source domain interactive matter as a reference, which is beneficial to ensure the accuracy of cross-domain mining of user interests, and further improve the accuracy of resource recommendation.

[0248] Moreover, finding a source domain interactive matter associated with the target domain based on entity similarity can cover more source domain interactive matters related to the target domain, which is beneficial to ensure the data volume of the found source domain interactive matter, and avoid the problems of data sparseness and insufficient mining.

[0249] Moreover, the similarity between entities is determined according to the similarity between the features of the entities, which is beneficial to ensure the accuracy of the determined similarity, and further ensure the accuracy of the found source domain interactive matter associated with the target domain.

[0250] In a possible implementation, if the length of the second source domain interaction data is less than the preset length, the second source domain interaction data is padded so that the length of the padded second source domain interaction data is equal to the preset length. Optionally, the padding value can be 0. If the length of the second source domain interaction data is greater than the preset length, the second source domain interaction data is truncated so that the length of the truncated second source domain interaction data is equal to the preset length. Optionally, the truncation of the second source domain interaction data means that, in the order of interaction time points from early to late, the source domain interaction items with relatively earlier interaction time points are deleted.

[0251] The length of the second source domain interaction data is the number of source domain interaction items in the second source domain interaction data.

[0252] In a possible implementation, if the length of the target domain interaction data is less than the preset length, the target domain interaction data is padded so that the length of the padded target domain interaction data is equal to the preset length. Optionally, the padding value can be 0. If the length of the target domain interaction data is greater than the preset length, the target domain interaction data is truncated so that the length of the truncated target domain interaction data is equal to the preset length. Optionally, the truncation of the target domain interaction data means that, in the order of interaction time points from early to late, the target domain interaction items with relatively earlier interaction time points are deleted.

[0253] The length of the target domain interaction data is the number of target domain interaction items in the target domain interaction data.

[0254] 304, the computer device extracts features from the object data to obtain object features.

[0255] After obtaining the object data, the computer device extracts features from the object data to obtain object features.

[0256] Optionally, the computer device can use a feature extraction sub-model to perform the feature extraction step. The computer device inputs the object data into the feature extraction sub-model, and the feature extraction sub-model extracts features from the object data to output the object features.

[0257] Optionally, the object features can be a feature vector or a feature matrix.

[0258] 305, the computer device extracts features from the resource data to obtain resource features.

[0259] After obtaining the resource data, the computer device extracts features from the resource data to obtain resource features.

[0260] Optionally, the computer device can perform the feature extraction step by using a feature extraction sub-model, inputting the resource data into the feature extraction sub-model, and outputting resource features by the feature extraction sub-model.

[0261] Optionally, the resource features can be feature vectors or feature matrices, etc.

[0262] 306. The computer device extracts features from the second source domain interaction data and the target domain interaction data to obtain source domain interaction features and target domain interaction features.

[0263] After obtaining the second source domain interaction data and the target domain interaction data, the computer device extracts features from the second source domain interaction data and the target domain interaction data to obtain source domain interaction features of the second source domain interaction data and target domain interaction features of the target domain interaction data.

[0264] In one possible implementation, the second source domain interaction data includes a plurality of source domain interaction events, each source domain interaction event including a source domain resource, an entity to which the source domain resource belongs, and an interaction time point. The source domain interaction features include features of the plurality of source domain interaction events, and each source domain interaction event feature includes a source domain resource feature, a source domain entity feature, and a source domain interaction time feature.

[0265] In one possible implementation, the target domain interaction data includes a plurality of target domain interaction events, each target domain interaction event including a target domain resource, an entity to which the target domain resource belongs, and an interaction time point. The target domain interaction features include features of the plurality of target domain interaction events, and each target domain interaction event feature includes a target domain resource feature, a target domain entity feature, and a target domain interaction time feature.

[0266] In one possible implementation, the computer device uses an attention mechanism to process the second source domain interaction data and the target domain interaction data to obtain the source domain interaction features and the target domain interaction features. The step 306 includes the following steps 3061-3065.

[0267] 3061. Extract features from the second source domain interaction data to obtain initial source domain interaction features, and extract features from the target domain interaction data to obtain initial target domain interaction features.

[0268] The computer device extracts features from the second source domain interaction data and the target domain interaction data respectively to obtain initial source domain interaction features and initial target domain interaction features. The initial source domain interaction features represent the features of the second source domain interaction data itself without being affected by the target domain interaction data, and the initial target domain interaction features represent the features of the target domain interaction data itself without being affected by the second source domain interaction data.

[0269] However, although each source domain interaction in the second source domain interaction data is associated with the target domain, the degree of association of each source domain interaction with the target domain is different. In order to improve accuracy, the influence of the source domain interaction feature with a relatively higher degree of association with the target domain on the recommendation prediction result should be enhanced, and the influence of the source domain interaction feature with a relatively lower degree of association with the target domain on the recommendation prediction result should be reduced. In addition, there may be noise in the target domain interaction data. For example, when a certain target domain interaction is completely irrelevant to the source domain, the target domain interaction may be generated due to user error touch, and therefore the influence of the target domain interaction feature of such target domain interaction on the recommendation prediction result should be reduced. Based on this, in steps 3062-3064, the initial source domain interaction feature and the initial target domain interaction feature are processed by using an attention mechanism to mine the importance of each part of the initial source domain interaction feature and the initial target domain interaction feature, so as to enhance the more important part of the initial source domain interaction feature and the initial target domain interaction feature.

[0270] 3062. The initial source domain interaction feature and the initial target domain interaction feature are fused to obtain a first fused interaction feature.

[0271] Optionally, the computer device splices the initial source domain interaction feature and the initial target domain interaction feature to obtain the first fused interaction feature.

[0272] For example, the computer device determines the first fused interaction feature by using the following formula: HC=[HS gs ||HT]

[0273] HC represents the first fused interaction feature, HS gs represents the initial source domain interaction feature, HT represents the initial target domain interaction feature, and || represents the splicing operation.

[0274] Optionally, the computer device performs weighted summation on the initial source domain interaction feature and the initial target domain interaction feature to obtain the first fused interaction feature.

[0275] 3063. The first fused interaction feature is multiplied by a first mapping matrix to obtain a first query feature, a first key feature, and a first value feature.

[0276] The key feature, the value feature, and the query feature in the embodiment of the application belong to different feature spaces respectively. The value feature represents the feature of the first fused interaction feature itself, and the query feature and the key feature are used to determine the importance of the feature corresponding to each interaction in the first fused interaction feature.

[0277] The first mapping matrix is a pre-set parameter matrix, and the first mapping matrix is used for spatial transformation of the first fused interaction feature.

[0278] Optionally, the first mapping matrix is a 3-dimensional mapping matrix, including a mapping matrix of the query dimension, a mapping matrix of the key dimension, and a mapping matrix of the value dimension. The computer device respectively multiplies the 3-dimensional mapping matrix and the first fused interaction feature to obtain a first query feature, a first key feature, and a first value feature.

[0279] Optionally, the computer device determines the first query feature, the first key feature, and the first value feature by using the following formula.

[0280] wherein Q1 represents the first query feature, K1 represents the first key feature, and V1 represents the first value feature. HC represents the first fused interaction feature, represents the mapping matrix of the query dimension, represents the mapping matrix of the key dimension, represents the mapping matrix of the value dimension.

[0281] 3064、The first query feature, the first key feature, and the first value feature are fused to obtain a second fused interaction feature.

[0282] Optionally, the computer device normalizes the product of the transpose of the first query feature and the first key feature and a scaling factor to obtain a first normalized feature, and determines the product of the first normalized feature and the first value feature as the second fused interaction feature.

[0283] For example, the computer device fuses the first query feature, the first key feature, and the first value feature by using the following formula.

[0284] wherein Attention(Q1, K1, V1) represents the second fused interaction feature, Q1 represents the first query feature, K1 represents the first key feature, and V1 represents the first value feature. T represents the transpose operation of the matrix, represents the scaling factor, and Softmax(·) represents the normalization operation.

[0285] 3065、Based on the second fused interaction feature, a source domain interaction feature and a target domain interaction feature are determined.

[0286] After determining the second fused interaction feature, the computer device splits the second fused interaction feature into the source domain interaction feature and the target domain interaction feature. Optionally, the first fused interaction feature is obtained by splicing the initial source domain interaction feature and the initial target domain interaction feature, and then the second fused interaction feature is split according to the splicing manner, and the two split interaction features are used as the final source domain interaction feature and the target domain interaction feature.

[0287] For example, the first fusion interaction feature is obtained by splicing the initial source domain interaction feature and the initial target domain interaction feature, the length of the initial source domain interaction feature is m, the length of the initial target domain interaction feature is n, and the first fusion interaction feature and the second fusion interaction feature are both m+n. Then the computer device takes the first to mth items in the second fusion interaction feature as the source domain interaction feature, and takes the m+1th to m+nth items as the target domain interaction feature.

[0288] Optionally, the process of determining the source domain interaction feature in step 3065 includes: splitting the intermediate source domain interaction feature from the second fusion interaction feature; multiplying the resource feature by the second mapping matrix to obtain a second query feature; multiplying the intermediate source domain interaction feature by the second mapping matrix to obtain a second key feature and a second value feature; and fusing the second query feature, the second key feature, and the second value feature to obtain the source domain interaction feature.

[0289] In the embodiment of the application, the computer device takes the interaction feature belonging to the source domain split from the second fusion interaction feature as the intermediate source domain interaction feature, and processes the intermediate source domain interaction feature and the resource feature using the attention mechanism to obtain the source domain interaction feature finally used.

[0290] The second mapping matrix is a pre-set parameter matrix, and the second mapping matrix is used for spatial transformation of the resource feature and the intermediate source domain interaction feature.

[0291] For example, the second mapping matrix is a mapping matrix of 3 dimensions, including a query dimension mapping matrix, a key dimension mapping matrix, and a value dimension mapping matrix. The computer device multiplies the query dimension mapping matrix by the resource feature to obtain a second query feature, and multiplies the key dimension mapping matrix and the value dimension mapping matrix by the intermediate source domain interaction feature to obtain a second key feature and a second value feature, respectively.

[0292] For example, the computer device determines the second query feature, the second key feature, and the second value feature using the following formula.

[0293] wherein Q2 represents the second query feature, K2 represents the second key feature, and V2 represents the second value feature. t represents the resource feature, HS sa represents the intermediate source domain interaction feature. represents the query dimension mapping matrix, represents the key dimension mapping matrix, represents the value dimension mapping matrix.

[0294] Exemplarily, the computer device normalizes the product of the transpose of the second query feature, the second key feature and the scaling factor to obtain a second normalized feature, and determines the product of the second normalized feature and the second value feature as the source domain interaction feature.

[0295] For example, the computer device fuses the second query feature, the second key feature and the second value feature by using the following formula.

[0296] wherein, Attention(Q2, K2, V2) represents the source domain interaction feature, Q2 represents the second query feature, K2 represents the second key feature, and V2 represents the second value feature. T represents the transpose operation of a matrix, denotes a scaling factor, and Softmax(·) represents a normalization operation.

[0297] Optionally, the process of determining the target domain interaction feature in the step 3065 comprises: splitting an intermediate target domain interaction feature from the second fused interaction feature; multiplying the resource feature by a third mapping matrix to obtain a third query feature; multiplying the intermediate target domain interaction feature by the third mapping matrix to obtain a third key feature and a third value feature; and fusing the third query feature, the third key feature and the third value feature to obtain the target domain interaction feature.

[0298] In the embodiment of the application, the computer device takes the interaction feature belonging to the target domain split from the third fused interaction feature as an intermediate target domain interaction feature, and processes the intermediate target domain interaction feature and the resource feature by using the attention mechanism to obtain the target domain interaction feature used finally.

[0299] wherein, the third mapping matrix is a pre-set parameter matrix, and the third mapping matrix is used for spatial transformation of the resource feature and the intermediate target domain interaction feature.

[0300] Exemplarily, the third mapping matrix is a mapping matrix of 3 dimensions, including a mapping matrix of a query dimension, a mapping matrix of a key dimension and a mapping matrix of a value dimension. The computer device multiplies the mapping matrix of the query dimension by the resource feature to obtain the third query feature, and respectively multiplies the mapping matrix of the key dimension and the mapping matrix of the value dimension by the intermediate target domain interaction feature to obtain the third key feature and the third value feature.

[0301] For example, the computer device determines the third query feature, the third key feature and the third value feature by using the following formula.

[0302] wherein, Q3 represents the third query feature, K3 represents the third key feature, and V3 represents the third value feature. t denotes the resource feature, and HT sa denotes the intermediate target domain interaction feature. a mapping matrix representing the query dimension, a mapping matrix representing the key dimension, a mapping matrix representing the value dimension.

[0303] For example, the computer device normalizes the product of the third query feature, the transpose of the third key feature and the scaling factor to obtain a third normalized feature, and determines the product of the third normalized feature and the third value feature as the target domain interaction feature.

[0304] For example, the computer device fuses the third query feature, the third key feature and the third value feature by using the following formula.

[0305] wherein, Attention(Q3, K3, V3) represents the target domain interaction feature, Q3 represents the third query feature, K3 represents the third key feature, and V3 represents the third value feature. T represents the transpose operation of a matrix, represents a scaling factor, and Softmax(·) represents a normalization operation.

[0306] In the embodiments of the present application, the source domain interaction feature and the target domain interaction feature are processed by using the attention mechanism. On the one hand, the source domain interaction feature can be weighted by using the correlation between the source domain interaction feature and the target domain interaction feature, which is conducive to enhancing the source domain interaction feature with higher correlation with the target domain and weakening the source domain interaction feature with lower correlation with the target domain. On the other hand, the target domain interaction feature can be weighted by using the correlation between the target domain interaction feature and the source domain interaction feature, so as to adjust the target domain interaction feature by using the source domain interaction feature, which is conducive to weakening the feature of the sparse interaction behavior in the target domain and reducing the interference of the mis-touch interaction behavior in the target domain to a certain extent.

[0307] In addition, the source domain interaction feature and the resource feature of the target resource are processed by using the attention mechanism, which can weight the source domain interaction feature by using the correlation between the source domain interaction feature and the resource feature, which is conducive to enhancing the source domain interaction feature with higher correlation with the target resource, so as to mine the source domain interaction feature with strong correlation with the target resource, so that the source domain interaction feature referred to in the target resource recommendation is concentrated on the source domain interaction feature related to the target resource to be recommended, the interference of irrelevant source domain interaction features is reduced, and the accuracy of the recommendation prediction result of the target resource is improved.

[0308] Further, the target domain interaction features and the resource features of the target resource are processed by using the attention mechanism, the target domain interaction features can be weighted by using the correlation between the target domain interaction features and the resource features, the target domain interaction features with higher correlation with the target resource are enhanced, the target domain interaction features with strong correlation with the target resource are mined, the target domain interaction features referred to in the target resource recommendation are concentrated on the target domain interaction features related to the target resource to be recommended, the interference of irrelevant target domain interaction features is reduced, and the accuracy of the recommendation prediction result of the target resource is improved.

[0309] 307. The computer device determines a recommendation prediction result of the target resource based on the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature, and the recommendation prediction result is used to represent an interaction between the object and the target resource if the target resource is recommended to the object.

[0310] After the computer device determines the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature, the interest tendency of the object to the target resource can be inferred by using the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature, and the recommendation prediction result of the target resource is determined, and the recommendation prediction result is used to represent the interaction tendency of the object to the target resource.

[0311] In a possible implementation manner, the recommendation prediction result is used to represent an interaction probability between the object and the target resource if the target resource is recommended to the object. For example, the recommendation prediction result can be a click-through rate (CTR).

[0312] In the embodiments of the present application, the interaction between the object and the target resource is predicted according to the features of the object data, the features of the resource data, the features of the source domain interaction data, and the features of the target domain interaction data, the interest tendency of the object and the matching degree between the interest tendency of the object and the target resource can be fully mined by using the potential features of the data, the interaction tendency of the object to the target resource is inferred, and the accuracy of the recommendation prediction result is improved.

[0313] 308. If the recommendation prediction result meets the recommendation condition, the computer device recommends the target resource to the object.

[0314] After the computer device determines the recommendation prediction result, it is determined whether the recommendation prediction result meets the recommendation condition. If the recommendation prediction result meets the recommendation condition, the target resource is recommended to the object. If the recommendation prediction result does not meet the recommendation condition, the target resource does not need to be recommended to the object.

[0315] In a possible implementation, the recommendation prediction result is used to represent a probability that the target resource is interacted with by the object if the target resource is recommended to the object. The recommendation condition is that the interaction probability of the target resource is greater than a probability threshold, or the recommendation condition is that the target resource ranks in a front preset number in an order of size among the interaction probabilities of the plurality of candidate recommended resources.

[0316] FIG. 5 is a schematic diagram of a resource recommendation method provided in an embodiment of the present application. As shown in FIG. 5, a user views a product interface and requests a resource recommendation service in the product interface. A server obtains object data, resource data, source domain interaction data and target domain interaction data from an online storage. A resource recommendation model is used to determine a recommendation prediction result of a target resource according to the obtained data, and the target resource is recommended to the user if the recommendation condition is met. After the user interacts with the target resource, a log is generated, and the server stores the log in a log system. The target domain interaction events of the object can be extracted from the log for a next recommendation task.

[0317] The method provided in the embodiment of the present application needs to refer to the historical interaction of the object with other resources to infer the interaction tendency of the object to the target resource when determining whether to recommend the target resource of the target domain to the object. Therefore, the target domain interaction data of the object in the target domain is obtained. Considering that the target domain interaction data may be insufficient in data quantity, the source domain interaction data of the object in the source domain is additionally obtained, and the source domain interaction data associated with the target domain is filtered out. Then, the target domain interaction data and the filtered source domain interaction data are used as references to predict the interaction of the object with the target resource if the target resource is recommended to the object. On the one hand, the introduction of the source domain interaction data can make up for the defect of insufficient target domain interaction data and alleviate the influence caused by the sparsity of the target domain interaction data. On the other hand, since only the source domain interaction data associated with the target domain is considered and the source domain interaction data irrelevant to the target domain is discarded, the interference of the source domain interaction data irrelevant to the target domain on the prediction result can be reduced, thereby improving the accuracy of resource recommendation as a whole.

[0318] Moreover, when the recommendation prediction result meets the recommendation condition, it means that the object is more likely to interact with the target resource, and therefore the target resource is recommended to the object, so as to realize personalized resource recommendation to the object, which is beneficial to improving the conversion rate of resource recommendation and improving the recommendation effect.

[0319] On the basis of the above embodiment, the steps 304-307 can be implemented by using a resource recommendation model, and the resource recommendation model includes a feature extraction sub-model and a recommendation prediction sub-model. The detailed process can be referred to the embodiment of FIG. 6.

[0320] FIG. 6 is a flowchart of another resource recommendation method provided by the embodiments of the present application. The embodiments of the present application are executed by a computer device, such as the terminal 101 or the server 102 shown in FIG. 1. Referring to FIG. 6, the method includes the following steps.

[0321] 601. The computer device acquires object data of an object and resource data of a target resource, the target resource belonging to a target domain.

[0322] 602. The computer device acquires first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data including a plurality of source domain interaction items, a source domain interaction item being an item of interaction between the object and a resource in a source domain, the target domain interaction data including a plurality of target domain interaction items, a target domain interaction item being an item of interaction between the object and a resource in the target domain, the source domain and the target domain belonging to different domains.

[0323] 603. The computer device determines at least one source domain interaction item associated with the target domain in the first source domain interaction data to constitute second source domain interaction data.

[0324] The steps 601-603 are the same as the steps 301-303, and thus are not described herein again.

[0325] 604. The computer device extracts features from the object data by a feature extraction sub-model in a resource recommendation model to obtain object features.

[0326] The feature extraction sub-model in the resource recommendation model is configured to extract features. The computer device inputs the object data into the feature extraction sub-model, and the feature extraction sub-model extracts features from the object data to output the object features.

[0327] The process of extracting features from the object data by the feature extraction sub-model is the same as the step 304, and thus is not described herein again.

[0328] 605. The computer device extracts features from the resource data by the feature extraction sub-model to obtain resource features.

[0329] The computer device inputs the resource data into the feature extraction sub-model, and the feature extraction sub-model extracts features from the resource data to output the resource features.

[0330] The process of extracting features from the resource data by the feature extraction sub-model is the same as the step 305, and thus is not described herein again.

[0331] 606. The computer device extracts features from the second source domain interaction data and the target domain interaction data by the feature extraction sub-model to obtain source domain interaction features and target domain interaction features.

[0332] The computer device inputs the second source domain interaction data and the target domain interaction data into the feature extraction sub-model, and the feature extraction sub-model extracts features from the second source domain interaction data and the target domain interaction data to output the source domain interaction features and the target domain interaction features.

[0333] In a possible implementation, the feature extraction sub-model includes a feature extraction network, a feature fusion network, and a first attention network, and the first attention network includes a first mapping matrix. The step 606 includes the following steps 6061-6065.

[0334] 6061. The feature extraction network is used to extract features from the second source domain interaction data to obtain initial source domain interaction features.

[0335] 6062. The feature extraction network is used to extract features from the target domain interaction data to obtain initial target domain interaction features.

[0336] 6063. The feature fusion network is used to fuse the initial source domain interaction features and the initial target domain interaction features to obtain first fused interaction features.

[0337] 6064. The first attention network is used to multiply the first fused interaction features by a first mapping matrix to obtain a first query feature, a first key feature, and a first value feature, and fuse the first query feature, the first key feature, and the first value feature to obtain second fused interaction features.

[0338] 6065. The source domain interaction features and the target domain interaction features are determined based on the second fused interaction features.

[0339] Optionally, the feature extraction sub-model further includes a second attention network, and the second attention network includes a second mapping matrix.

[0340] The process of determining the source domain interaction features in the step 6065 includes: splitting intermediate source domain interaction features from the second fused interaction features; multiplying, by the second attention network, the resource features by a second mapping matrix to obtain a second query feature, multiplying the intermediate source domain interaction features by the second mapping matrix to obtain a second key feature and a second value feature; and fusing, by the second attention network, the second query feature, the second key feature, and the second value feature to obtain the source domain interaction features.

[0341] Optionally, the feature extraction sub-model further includes a third attention network, and the third attention network includes a third mapping matrix.

[0342] The process of determining the target domain interaction feature in step 6065 includes: splitting the intermediate target domain interaction feature from the second fusion interaction feature; multiplying the resource feature and the third mapping matrix through the third attention network to obtain the third query feature, multiplying the intermediate target domain interaction feature and the third mapping matrix to obtain the third key feature and the third value feature; and fusing the third query feature, the third key feature and the third value feature through the third attention network to obtain the target domain interaction feature.

[0343] In the embodiments of the present application, the source domain interaction feature and the target domain interaction feature are processed by using the attention network. On the one hand, the source domain interaction feature can be weighted by using the correlation between the source domain interaction feature and the target domain interaction feature, which is beneficial to enhancing the source domain interaction feature with higher correlation with the target domain and weakening the source domain interaction feature with lower correlation with the target domain. On the other hand, the target domain interaction feature can be weighted by using the correlation between the target domain interaction feature and the source domain interaction feature, so as to adjust the target domain interaction feature by using the source domain interaction feature, which is beneficial to weakening the feature of the sparse interaction behavior in the target domain and reducing the interference of the mis-touch interaction behavior in the target domain to a certain extent.

[0344] In addition, the source domain interaction feature and the resource feature of the target resource are processed by using the attention network, which can weight the source domain interaction feature by using the correlation between the source domain interaction feature and the resource feature, which is beneficial to enhancing the source domain interaction feature with higher correlation with the target resource, so as to mine the source domain interaction feature with strong correlation with the target resource, make the source domain interaction feature referred to in the target resource recommendation concentrate on the source domain interaction feature related to the target resource to be recommended, reduce the interference of irrelevant source domain interaction feature, and further improve the accuracy of the recommendation prediction result of the target resource.

[0345] In addition, the target domain interaction feature and the resource feature of the target resource are processed by using the attention network, which can weight the target domain interaction feature by using the correlation between the target domain interaction feature and the resource feature, which is beneficial to enhancing the target domain interaction feature with higher correlation with the target resource, so as to mine the target domain interaction feature with strong correlation with the target resource, make the target domain interaction feature referred to in the target resource recommendation concentrate on the target domain interaction feature related to the target resource to be recommended, reduce the interference of irrelevant target domain interaction feature, and further improve the accuracy of the recommendation prediction result of the target resource.

[0346] It should be noted that in the case where the feature extraction sub-model includes the feature extraction network, the feature fusion network and the first attention network, in steps 604 and 605, only the object feature and the resource feature need to be extracted by the feature extraction network.

[0347] 607、The computer device determines a recommendation prediction result of the target resource based on the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature through a recommendation prediction sub-model in the resource recommendation model. The recommendation prediction result is used to represent an interaction between the object and the target resource if the target resource is recommended to the object.

[0348] The recommendation prediction sub-model in the resource recommendation model is used to determine the recommendation prediction result. The computer device inputs the object feature, the resource feature, the source domain interaction feature, and the target domain interaction feature into the recommendation prediction sub-model, and outputs the recommendation prediction result from the recommendation prediction sub-model. For example, the recommendation prediction sub-model can be a multilayer perceptron (MLP).

[0349] In a possible implementation, the computer device pools the source domain interaction feature and the target domain interaction feature to obtain a pooled source domain interaction feature and a pooled target domain interaction feature. The computer device concatenates the object feature, the resource feature, the pooled source domain interaction feature, and the pooled target domain interaction feature to obtain a concatenated feature, and inputs the concatenated feature into the recommendation prediction sub-model to output the recommendation prediction result from the recommendation prediction sub-model.

[0350] Optionally, the source domain interaction feature includes source domain interaction item features of a plurality of source domain interaction items, and the target domain interaction feature includes target domain interaction item features of a plurality of target domain interaction items. The computer device performs average pooling on the plurality of source domain interaction item features to obtain the pooled source domain interaction feature. The computer device performs average pooling on the plurality of target domain interaction item features to obtain the pooled target domain interaction feature.

[0351] For example, the computer device pools the source domain interaction feature and the target domain interaction feature by using the following formula.

[0352] wherein rs represents the pooled source domain interaction feature, hs represents a source domain interaction item feature in the source domain interaction feature, and m represents a length of the source domain interaction feature, that is, a number of source domain interaction item features. rt represents the pooled target domain interaction feature, ht represents a target domain interaction item feature in the target domain interaction feature, and n represents a length of the target domain interaction feature, that is, a number of target domain interaction item features.

[0353] For example, the computer device determines the recommendation prediction result by using the following formula.

[0354] wherein, represents the recommendation prediction result, x represents the object feature, q represents the resource feature, rs represents the pooled source domain interaction feature, rt represents the pooled target domain interaction feature, and f represents a function of the recommendation prediction sub-model. twherein, rs represents the pooled source domain interactive feature, rt represents the pooled target domain interactive feature, || represents the splicing operation, and Model(·) represents a recommendation prediction sub-model.

[0355] 608、If the recommendation prediction result meets the recommendation condition, the computer device recommends the target resource to the object.

[0356] The method provided in the embodiments of the present application needs to refer to the historical interactive situation of the object and other resources to infer the interactive tendency of the object to the target resource when determining whether to recommend the target resource of the target domain to the object. Therefore, the target domain interactive data of the object in the target domain is obtained, and the source domain interactive data of the object in the source domain is additionally obtained considering that the target domain interactive data may be insufficient in data amount, and the source domain interactive data associated with the target domain is filtered out from the source domain interactive data, and then the target domain interactive data and the filtered source domain interactive data are used as references to predict the interactive situation of the object and the target resource if the target resource is recommended to the object. On the one hand, the source domain interactive data is introduced, so that the defect of insufficient target domain interactive data is made up and the influence caused by the sparsity of the target domain interactive data is alleviated, and on the other hand, only the source domain interactive data associated with the target domain is considered and the source domain interactive data irrelevant to the target domain is discarded, so that the interference of the source domain interactive data irrelevant to the target domain on the prediction result is reduced, thereby improving the accuracy of resource recommendation as a whole.

[0357] Moreover, the process of determining the recommendation prediction result based on the object data, the resource data, the source domain interactive data and the target domain interactive data using the resource recommendation model is beneficial to improving the processing efficiency.

[0358] The embodiments of the present application also provide a training method of a resource recommendation model. FIG. 7 is a flowchart of a training method of a resource recommendation model provided in the embodiments of the present application, and the embodiments of the present application are executed by a computer device, which is a terminal 101 or a server 102 or the like as shown in FIG. 1. Referring to FIG. 7, the method comprises:

[0359] 701. The computer device obtains sample object data of a sample object, sample resource data of a sample resource and a sample label, the sample resource belongs to a target domain, and the sample label is used to represent the real interactive situation of the sample object and the sample resource after the sample resource is recommended to the sample object.

[0360] The sample resource is a resource that has been recommended to the sample object, the sample object data is the same as the object data, and the sample resource data is the same as the resource data, which will not be described herein again.

[0361] The sample label can be a real interaction probability of the sample object and the sample resource after the sample object is recommended the sample resource. For example, if the sample object interacts with the sample resource, the sample label can be set to 1, and if the sample object does not interact with the sample resource, the sample label can be set to 0.

[0362] 702、The computer device obtains first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object. The first sample source domain interaction data includes a plurality of sample source domain interaction events, and the sample source domain interaction event refers to an event in which the sample object interacts with a resource in a source domain. The sample target domain interaction data includes a plurality of sample target domain interaction events, and the sample target domain interaction event refers to an event in which the sample object interacts with a resource in a target domain. The source domain and the target domain belong to different domains.

[0363] 703、The computer device determines at least one sample source domain interaction event associated with the target domain in the first sample source domain interaction data to constitute second sample source domain interaction data.

[0364] 704、The computer device determines a recommendation prediction result of the sample resource based on the sample object data, the sample resource data, the second sample source domain interaction data, and the target domain sample interaction data through the resource recommendation model. The recommendation prediction result is used to represent a predicted interaction condition of the sample object and the sample resource if the sample resource is recommended to the sample object.

[0365] The processes of steps 702-704 are the same as those of steps 602-607 described above, and will not be repeated here.

[0366] 705、The computer device trains the resource recommendation model based on the recommendation prediction result and the sample label.

[0367] The sample label can reflect the real interaction condition of the sample object and the sample resource, and the recommendation prediction result is a prediction result obtained based on the resource recommendation model and can reflect the predicted interaction condition of the sample object and the sample resource. The smaller the difference between the recommendation prediction result and the sample label, the more accurate the recommendation prediction result, that is, the more accurate the resource recommendation model. Therefore, the computer device trains the resource recommendation model based on the recommendation prediction result and the sample label, and the training target is to reduce the difference between the recommendation prediction result and the sample label, thereby improving the accuracy of the resource recommendation model.

[0368] The method provided in the embodiments of the present application, when training the resource recommendation model, obtains sample target domain interaction data of a sample object in a target domain for a recommendation task of the target domain. Considering that the sample target domain interaction data may be insufficient in data quantity, the method additionally obtains sample source domain interaction data of the sample object in a source domain, and filters out a part of the sample source domain interaction data associated with the target domain. Then, the method uses the sample target domain interaction data and the filtered sample source domain interaction data as references, uses the resource recommendation model to predict a recommendation prediction result of recommending a sample resource to the sample object, and further trains the resource recommendation model by using the recommendation prediction result and a sample label. On the one hand, because the sample source domain interaction data is introduced, the defect of insufficient sample target domain interaction data can be made up, the influence of sparse sample target domain interaction data is alleviated, and the accuracy of the resource recommendation model is improved. On the other hand, because only the sample source domain interaction data associated with the target domain is considered and the sample source domain interaction data irrelevant to the target domain is discarded, the interference of the sample source domain interaction data irrelevant to the target domain on the prediction result is reduced, and the accuracy of the resource recommendation model is further improved. Moreover, the sample source domain interaction data irrelevant to the target domain is filtered out, the amount of data required to be stored and processed is effectively controlled, and the storage resource and the processing resource are saved.

[0369] On the basis of the above embodiments, the resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model. FIG. 8 is a flowchart of another method for training a resource recommendation model provided in the embodiments of the present application. The embodiments of the present application are executed by a computer device, which is a terminal 101 or a server 102 shown in FIG. 1 or the like. Referring to FIG. 8, the method comprises the following steps.

[0370] 801. The computer device obtains sample object data of a sample object, sample resource data of a sample resource, and a sample label. The sample resource belongs to a target domain, and the sample label is used to represent a real interaction between the sample object and the sample resource after the sample resource is recommended to the sample object.

[0371] 802. The computer device obtains first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object. The first sample source domain interaction data comprises a plurality of sample source domain interaction items. A sample source domain interaction item refers to an interaction between the sample object and a resource in a source domain. The sample target domain interaction data comprises a plurality of sample target domain interaction items. A sample target domain interaction item refers to an interaction between the sample object and a resource in a target domain. The source domain and the target domain belong to different domains.

[0372] 803. The computer device determines at least one sample source domain interaction item associated with the target domain in the first sample source domain interaction data to constitute second sample source domain interaction data.

[0373] In a possible implementation, a plurality of target entities are determined, the target entity refers to an entity to which a resource of the target domain belongs, and the entity refers to an object providing the resource; for any sample source domain interaction matter in the first sample source domain interaction data, if an entity to which a resource in the sample source domain interaction matter belongs is any target entity, it is determined that the sample source domain interaction matter is associated with the target domain.

[0374] In another possible implementation, a plurality of target entities are determined, the target entity refers to an entity to which a resource of the target domain belongs, and the entity refers to an object providing the resource; for any sample source domain interaction matter in the first sample source domain interaction data, if a similarity between an entity to which a resource in the sample source domain interaction matter belongs and any target entity is greater than a similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0375] Optionally, a target entity feature of each target entity is obtained; an entity feature of a resource in the sample source domain interaction matter is extracted, to obtain a sample source domain entity feature; and if a similarity between the sample source domain entity feature and any target entity feature is greater than a similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0376] 804, the computer device extracts features of the sample object data by using the feature extraction sub-model in the resource recommendation model, to obtain sample object features.

[0377] 805, the computer device extracts features of the sample resource data by using the feature extraction sub-model, to obtain sample resource features.

[0378] 806, the computer device extracts features of the second sample source domain interaction data and the sample target domain interaction data by using the feature extraction sub-model, to obtain sample source domain interaction features and sample target domain interaction features.

[0379] In a possible implementation, the feature extraction sub-model includes a feature extraction network, a feature fusion network, and a first attention network, and the first attention network includes a first mapping matrix. The step 806 includes the following steps 8061-8065.

[0380] 8061, the feature extraction network is used to extract features of the second sample source domain interaction data, to obtain initial sample source domain interaction features.

[0381] 8062, the feature extraction network is used to extract features of the sample target domain interaction data, to obtain initial sample target domain interaction features.

[0382] 8063, the feature fusion network is used to fuse the initial sample source domain interaction features and the initial sample target domain interaction features, to obtain first sample fusion interaction features.

[0383] 8064. Through the first attention network, the first sample fusion interaction feature is multiplied by the first mapping matrix to obtain the first sample query feature, the first sample key feature and the first sample value feature. The first sample query feature, the first sample key feature and the first sample value feature are fused to obtain the second sample fusion interaction feature.

[0384] 8065. Based on the second sample fusion interaction features, determine the sample source domain interaction features and sample target domain interaction features.

[0385] Optionally, the feature extraction sub-model also includes a second attention network, which includes a second mapping matrix.

[0386] The process of determining the source domain interaction features of the samples in step 8065 includes: splitting the intermediate sample source domain interaction features from the second sample fusion interaction features; multiplying the sample resource features with the second mapping matrix through the second attention network to obtain the second sample query features; multiplying the intermediate sample source domain interaction features with the second mapping matrix to obtain the second sample key features and the second sample value features; and fusing the second sample query features, the second sample key features, and the second sample value features through the second attention network to obtain the sample source domain interaction features.

[0387] Optionally, the feature extraction sub-model also includes a third attention network, which includes a third mapping matrix.

[0388] The process of determining the target domain interaction features of the samples in step 8065 includes: splitting the intermediate sample target domain interaction features from the second sample fusion interaction features; multiplying the sample resource features with the third mapping matrix through the third attention network to obtain the third sample query features; multiplying the intermediate sample target domain interaction features with the third mapping matrix to obtain the third sample key features and the third sample value features; and fusing the third sample query features, the third sample key features, and the third sample value features through the third attention network to obtain the target domain interaction features of the samples.

[0389] 807. The computer equipment determines the recommendation prediction result based on the sample object characteristics, sample resource characteristics, sample source domain interaction characteristics, and sample target domain interaction characteristics through the recommendation prediction sub-model in the resource recommendation model.

[0390] In the embodiments of the present application, the interaction between the sample object and the sample resource is predicted according to the characteristics of the sample object data, the characteristics of the sample resource data, the characteristics of the sample source domain interaction data, and the characteristics of the sample target domain interaction data. The potential characteristics of these sample data can be fully utilized to mine the interest tendency of the sample object and the matching degree between the interest tendency of the sample object and the sample resource, so as to infer the interaction tendency of the sample object to the sample resource, which is beneficial to ensuring the accuracy of the recommendation prediction result and accelerating the training process of the resource recommendation model.

[0391] 808、The computer device trains the resource recommendation model based on the recommendation prediction result and the sample label.

[0392] In a possible implementation, the computer device determines a first loss parameter based on the recommendation prediction result and the sample label, and trains the resource recommendation model based on the first loss parameter, so that the first loss parameter obtained based on the trained resource recommendation model is reduced.

[0393] Optionally, the computer device determines the first loss parameter by using the following formula.

[0394] wherein, the first loss parameter is represented by L, the recommendation prediction result is represented by y, and the sample label is represented by y.

[0395] In a possible implementation, due to the cross-domain problem and the fact that the resource recommendation model is trained by taking the recommendation task of the target domain as a sample, the representation learning of the resources in the source domain is insufficient, and the gap between the resource features in the source domain and the resource features in the target domain is large. To overcome the above challenges, an additional supervised learning process can be added to the source domain resource features and the target domain resource features extracted by the resource recommendation model, so as to align the resource features in the source domain and the resource features in the target domain as the training target, and then the resource recommendation model is trained. The following provides two training methods.

[0396] Firstly, the sample source domain interaction item includes a source domain resource and an interaction time point of the source domain resource, the sample target domain interaction item includes a target domain resource and an interaction time point of the target domain resource, the sample source domain interaction feature includes a source domain resource feature of the source domain resource in each sample source domain interaction item, and the sample target domain interaction feature includes a target domain resource feature of the target domain resource in each sample target domain interaction item.

[0397] The computer device determines a first target domain resource in the sample target domain interaction data for any source domain resource in the second sample source domain interaction data, and determines the source domain resource feature of the source domain resource and the target domain resource feature of the first target domain resource as a first positive sample pair, wherein the interaction time point of the first target domain resource is closest to the interaction time point of the source domain resource.

[0398] The step 808 comprises: training the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair.

[0399] The resources in the interaction events of the same object in the same domain should exhibit similar features. Further, the interests of the object remain stable in different domains in a short period of time, and therefore, it can be considered that the resources in the interaction events of the same object in different domains in a similar time period should also exhibit similar features. Therefore, the source domain resource feature and the target domain resource feature in the source domain and the target domain with close interaction time points can be taken as a positive sample pair, and the training target is to narrow the distance between the two resource features in the positive sample pair.

[0400] In the step 808, the training target is to reduce the difference between the recommendation prediction result and the sample label, and to improve the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair.

[0401] Optionally, for any source domain resource in the second sample source domain interaction data, the computer device determines a second target domain resource in the sample target domain interaction data of any object other than the sample object, determines the source domain resource feature of the source domain resource and the target domain resource feature of the second target domain resource as a first negative sample pair, and the second target domain resource is any target domain resource in the sample target domain interaction data of any object. Meanwhile, the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair is determined.

[0402] The step 808 comprises: training the resource recommendation model based on the recommendation prediction result, the sample label, the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, and the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair.

[0403] Correspondingly, the resources in the interaction events of different objects in different domains should exhibit dissimilar features. Therefore, the source domain resource feature of the object in the source domain and the target domain resource feature of the other object in the target domain can be taken as a negative sample pair, and the training target is to increase the distance between the two resource features in the negative sample pair.

[0404] For example, the computer device determines the second loss parameter by using the following formula.

[0405] For example, the computer device determines the second loss parameter by using the following formula.

[0406] wherein, es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. uc es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. uc es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. uc es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. uo es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features. u es represents the second loss parameter, es represents the similarity between the source domain resource feature and the target domain resource feature in the first positive sample pair, et represents the similarity between the source domain resource feature and the target domain resource feature in the first negative sample pair, and m represents the length of the source domain interaction feature, which can also be understood as the number of source domain resource features.

[0407] In the embodiments of the present application, the resource recommendation model extracts the source domain resource feature of the source domain resource and the target domain resource feature of the target domain resource. Considering that the resources interacted by the same object in different domains at similar times are also close, the features of the two resources in the source domain and the target domain that are close in the interaction time are taken as a positive sample pair, so as to take the distance between the source domain resource feature and the target domain resource feature in the positive sample pair as the target to train the resource recommendation model, which can effectively align the resource features of different domains extracted by the resource recommendation model, improve the feature extraction capability of the resource recommendation model, and is conducive to ensuring the accuracy of the cross-domain processing process.

[0408] In addition, considering that the resources interacted by the same object in different domains at different times are quite different, the features of the two resources in the source domain and the target domain that are not close in the interaction time are taken as a negative sample pair, so as to take the distance between the source domain resource feature and the target domain resource feature in the negative sample pair as the target to train the resource recommendation model, which can further align the resource features of different domains extracted by the resource recommendation model.

[0409] The second kind: the sample source domain interactive matter includes a source domain resource and an entity to which the source domain resource belongs, the sample target domain interactive matter includes a target domain resource and an entity to which the target domain resource belongs, the sample source domain interactive feature includes a source domain resource feature of the source domain resource in each sample source domain interactive matter, and the sample target domain interactive feature includes a target domain resource feature of the target domain resource in each sample target domain interactive matter.

[0410] The computer device determines, for any source domain resource in the second sample source domain interactive data, a third target domain resource in the sample target domain interactive data, determines the source domain resource feature of the source domain resource and the target domain resource feature of the third target domain resource as a second positive sample pair, and the entity to which the third target domain resource belongs is the same as the entity to which the source domain resource belongs. At the same time, the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair is determined.

[0411] The step 808 includes: training the resource recommendation model based on the recommendation prediction result, the sample label, the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair.

[0412] Different resources with the same entity in the same domain should exhibit similar features, which can be considered to also apply to different resources across domains, that is, different resources with the same entity in different domains should also exhibit similar features. Therefore, the source domain resource feature and the target domain resource feature belonging to the same entity in the source domain and the target domain can be regarded as a positive sample pair, and the distance between the two resource features in the positive sample pair is narrowed as the training target.

[0413] Then, in the step 808, the training target is to reduce the difference between the recommendation prediction result and the sample label, and to improve the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair.

[0414] Alternatively, the computer device determines, for any source domain resource in the second sample source domain interactive data, a fourth target domain resource, determines the source domain resource feature of the source domain resource and the target domain resource feature of the fourth target domain resource as a second negative sample pair, and the fourth target domain resource is any target domain resource different from the entity to which the source domain resource belongs. At the same time, the similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair is determined.

[0415] The step 808 includes: training the resource recommendation model based on the recommendation prediction result, the sample label, the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, and the similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair.

[0416] Correspondingly, different resources with different entities in different domains should exhibit different characteristics. Therefore, the source domain resource characteristics and the target domain resource characteristics of the object with different entities can be taken as a negative sample pair to increase the distance between the two resource characteristics in the negative sample pair as a training target.

[0417] For example, the computer device determines a first loss parameter based on the recommendation prediction result and the sample label, determines a third loss parameter based on the similarity between the source domain resource characteristics and the target domain resource characteristics in the second positive sample pair and the similarity between the source domain resource characteristics and the target domain resource characteristics in the second negative sample pair, and trains the resource recommendation model based on the first loss parameter and the third loss parameter, so that the first loss parameter and the third loss parameter obtained based on the trained resource recommendation model are reduced.

[0418] For example, the computer device determines the third loss parameter by using the following formula.

[0419] wherein, The third loss parameter is represented by es, the source domain resource characteristics in the second positive sample pair are represented by es lc The target domain resource characteristics in the second positive sample pair are represented by et lc The target domain resource characteristics in the second positive sample pair are represented by et lc The source domain resource characteristics in the second negative sample pair are represented by es lo The target domain resource characteristics in the second negative sample pair are represented by et, m represents the length of the source domain interaction characteristics, which can also be understood as the number of source domain resource characteristics. τ is a hyperparameter, The source domain interaction characteristics are represented by es, and sim(·) represents the cosine similarity.

[0420] In the embodiments of the present application, the resource recommendation model extracts the source domain resource characteristics of the source domain resource and the target domain resource characteristics of the target domain resource. Considering that resources belonging to the same entity in different domains are relatively close, the characteristics of two resources belonging to the same entity in the source domain and the target domain are taken as a positive sample pair, the distance between the source domain resource characteristics and the target domain resource characteristics in the positive sample pair is narrowed as a target, and the resource recommendation model is trained, which can effectively align the resource characteristics of different domains extracted by the resource recommendation model, improve the feature extraction capability of the resource recommendation model, and is beneficial to ensuring the accuracy of the cross-domain processing process.

[0421] Moreover, considering that resources belonging to different entities in different domains are relatively different, the characteristics of two resources belonging to different entities in the source domain and the target domain are taken as a negative sample pair, the distance between the source domain resource characteristics and the target domain resource characteristics in the negative sample pair is increased as a target, and the resource recommendation model is trained, which can further align the resource characteristics of different domains extracted by the resource recommendation model.

[0422] In a possible implementation, the computer device determines a target loss parameter based on the first loss parameter, the second loss parameter, and the third loss parameter, and trains the resource recommendation model based on the target loss parameter, so that the target loss parameter obtained based on the trained resource recommendation model is reduced.

[0423] Optionally, the computer device determines the target loss parameter by using the following formula.

[0424] wherein, the first loss parameter is denoted as L1, the second loss parameter is denoted as L2, the third loss parameter is denoted as L3, the target loss parameter is denoted as L, uc , λ lc , and λ ca are hyperparameters.

[0425] In a possible implementation, the above description is only taken as an example of taking the resource features of the aligned source domain and target domain as the training target, and in addition thereto, the resource features of the same domain can also be taken as the training target to train the resource recommendation model. The following provides the following multiple training modes.

[0426] Optionally, the computer device determines the first source domain resource and the second source domain resource in the second sample source domain interaction data of the sample object, and determines the source domain resource features of the first source domain resource and the source domain resource features of the second source domain resource as a third positive sample pair, the first source domain resource being any source domain resource, and the interaction time point of the second source domain resource being closest to the interaction time point of the first source domain resource. The computer device trains the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the two source domain resource features in the third positive sample pair. The training target is to reduce the difference between the recommendation prediction result and the sample label, and to improve the similarity between the two source domain resource features in the third positive sample pair.

[0427] Optionally, for the first source domain resource in the second sample source domain interaction data, the computer device determines the third source domain resource in the sample source domain interaction data of any object other than the sample object, and determines the source domain resource features of the first source domain resource and the source domain resource features of the third source domain resource as a third negative sample pair, the third source domain resource being any source domain resource in the sample source domain interaction data of any object. The computer device trains the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the two source domain resource features in the third negative sample pair. The training target is to reduce the difference between the recommendation prediction result and the sample label, and to reduce the similarity between the two source domain resource features in the third negative sample pair.

[0428] Optionally, the computer device determines a first source domain resource and a fourth source domain resource in the second sample source domain interaction data of the sample object, and determines source domain resource features of the first source domain resource and the fourth source domain resource as a fourth positive sample pair, the first source domain resource being any source domain resource, and the entity to which the fourth source domain resource belongs being the same as the entity to which the first source domain resource belongs. The computer device trains the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the two source domain resource features in the fourth positive sample pair. The training target is to reduce the difference between the recommendation prediction result and the sample label, and to improve the similarity between the two source domain resource features in the fourth positive sample pair.

[0429] Optionally, for the first source domain resource in the second sample source domain interaction data, the computer device determines a fifth source domain resource, and determines source domain resource features of the first source domain resource and the fifth source domain resource as a fourth negative sample pair, the fifth source domain resource being any source domain resource different from the entity to which the first source domain resource belongs. The computer device trains the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the two source domain resource features in the fourth negative sample pair. The training target is to reduce the difference between the recommendation prediction result and the sample label, and to reduce the similarity between the two source domain resource features in the fourth negative sample pair.

[0430] The above only takes the alignment of the resource features of the source domain as an example for description. The process of aligning the resource features of the target domain is the same as that of aligning the resource features of the source domain, and will not be described herein again.

[0431] The method provided by the embodiments of the present application can make up for the defects of insufficient sample target domain interaction data, alleviate the influence caused by the sparsity of the sample target domain interaction data, and is beneficial to improving the accuracy of the resource recommendation model. On the other hand, since only the sample source domain interaction data associated with the target domain is considered, and the sample source domain interaction data irrelevant to the target domain is discarded, the interference of the sample source domain interaction data irrelevant to the target domain on the prediction result can be reduced, and the accuracy of the resource recommendation model can be further improved. Moreover, filtering out the sample source domain interaction data irrelevant to the target domain can also effectively control the amount of data required to be stored and processed, which is beneficial to saving storage resources and processing resources.

[0432] FIG. 9 is a schematic diagram of a training method of a resource recommendation model according to an embodiment of the present application. As shown in FIG. 9, initial samples are processed from user logs, and the initial samples are processed to obtain training samples. Source domain interaction data is obtained from a source domain, and target domain interaction data is obtained from a target domain. The source domain interaction data is cross-domain filtered to obtain source domain interaction data associated with the target domain. The filtered source domain interaction data and the target domain interaction data are feature extracted and stored in a feature library. The resource recommendation model is trained using the training samples and the data in the feature library. The data stored in the feature library can also be used for online resource recommendation.

[0433] FIG. 10 is a schematic diagram of a resource recommendation method according to an embodiment of the present application. As shown in FIG. 10, the overall architecture includes a cross-domain retrieval module, a cross-domain feature alignment module, a feature enhancement module, and a recommendation prediction module.

[0434] The cross-domain retrieval module is configured to filter source domain interaction data associated with the target domain. For example, the target entities include entity A, entity B, and entity F. Through cross-domain retrieval, it can be determined that the source domain interaction events corresponding to entity A, entity B, and entity D in the source domain are associated with the target domain.

[0435] The cross-domain feature alignment module is configured to align the resource features of the source domain and the target domain. For the same object, the source domain resource features and the target domain resource features of the same object at the close interaction time points in the source domain and the target domain need to be pulled closer. For the same entity, the source domain resource features and the target domain resource features belonging to the same entity in the source domain and the target domain need to be pulled closer.

[0436] The feature enhancement module is configured to enhance the source domain interaction features associated with the target domain, and to enhance the source domain interaction features associated with the target resource. The attention mechanism is used to process the source domain interaction features and the target domain interaction features, the attention mechanism is used to process the source domain interaction features and the resource features, and the attention mechanism is used to process the target domain interaction features and the resource features.

[0437] The recommendation prediction module is configured to determine a recommendation prediction result according to the object features, the resource features, the source domain interaction features, and the target domain interaction features. For example, the recommendation prediction module includes a recommendation prediction sub-model, and the recommendation prediction sub-model includes a concatenation network and a prediction network. The object features, the resource features, the source domain interaction features, and the target domain interaction features are input into the concatenation network for concatenation to obtain concatenated features, and the concatenated features are input into the prediction network to obtain the recommendation prediction result.

[0438] In order to verify the effectiveness of the resource recommendation method provided by the embodiments of the present application, the experimental data is used to test the resource recommendation method provided by the embodiments of the present application and the resource recommendation method provided by the related art, and the test results are shown in Table 1 below.

[0439] Table 1

[0440] Wherein, the offline evaluation index adopts AUG (Area Under Curve, a model performance measurement index), and the online evaluation index adopts CTR. As can be seen from Table 1, the scheme of the embodiments of the present application achieves a relatively better effect than the related art in both offline and online.

[0441] The embodiments of the present application provide a cross-domain super-long interactive data modeling method based on retrieval and alignment, which is used to solve the application of rich interactive data in the source domain to the resource recommendation task in the target domain, so as to improve the accuracy and diversity of resource recommendation. The method of the embodiments of the present application can be applied to any scene requiring resource recommendation.

[0442] For example, the source domain is a shopping field, the target domain is an advertisement field, the resource in the source domain is an item in the shopping field, and the resource in the target domain is a virtual resource in the advertisement field, which is used to exchange the item in the source domain. For example, the virtual resource is a coupon or a redemption ticket, etc.

[0443] Optionally, the virtual resource in the target domain and the item in the source domain can be provided by the same entity, or can be provided by different entities. Optionally, the virtual resource provided by each entity in the target domain is used to exchange the item provided by the entity in the source domain. For example, the virtual resource provided by entity A in the target domain is used to exchange the item provided by entity A in the source domain, but the virtual resource provided by entity A in the target domain cannot be used to exchange the item provided by other entities in the source domain except entity A, and the item provided by entity A in the source domain cannot be exchanged by using the virtual resource provided by other entities in the target domain except entity A.

[0444] The following takes the source domain as a shopping field and the target domain as an advertisement field as an example to describe the process of the resource recommendation method provided by the embodiments of the present application. FIG. 11 is a flowchart of another resource recommendation method provided by the embodiments of the present application, referring to FIG. 11, the method comprises:

[0445] 1101. When the object meets the advertisement placement condition, the terminal sends a resource recommendation task for the object to the server.

[0446] 1102. The server acquires object data of the object and virtual resource data of a target virtual resource used to exchange an item in response to the resource recommendation task for the object.

[0447] 1103. The server acquires first item interactive data of the object and virtual resource interactive data of the object.

[0448] The first item interaction data includes a plurality of item interaction events, and the item interaction event refers to interaction of the object with an item in a shopping field. For example, the interaction of the object with the item refers to a behavior of purchasing the item.

[0449] The virtual resource interaction data includes a plurality of virtual resource interaction events, and the virtual resource interaction event refers to interaction of the object with a virtual resource in an advertising field. For example, the virtual resource is a coupon in the advertising field, and the interaction of the object with the virtual resource refers to a behavior of obtaining the coupon.

[0450] 1104. The server determines, in the first item interaction data, at least one item interaction event associated with the advertising field, and the at least one item interaction event associated with the advertising field constitutes second item interaction data.

[0451] 1105. The server determines, based on the object data, the virtual resource data, the second item interaction data, and the virtual resource interaction data, a recommendation prediction result of the target virtual resource, and the recommendation prediction result is used to represent an interaction of the object with the target virtual resource if the target virtual resource is recommended to the object.

[0452] 1106. If the recommendation prediction result meets a recommendation condition, the server returns the target virtual resource to the terminal.

[0453] 1107. The terminal recommends the target virtual resource to the object.

[0454] In a possible implementation manner, the terminal runs a target client, and the target client provides a plurality of services, for example, including a payment service and an advertising service. For example, after the user completes a payment operation in the target client, the target client recommends an advertising resource to the user, and the advertising resource includes a virtual resource used for exchanging an item.

[0455] FIG. 12 is a schematic diagram of a service interface provided by an embodiment of the present application. As shown in FIG. 12, the service interface is provided with a recharge entry 1201. After the user clicks the recharge entry 1201, the user is switched to a recharge interface. The recharge interface is used for charging a fee, and in addition to this, the recharge interface further includes a welfare obtaining entry 1202.

[0456] Optionally, after the fee is charged, the user is switched from the recharge interface shown in FIG. 12 to a recharge interface shown in FIG. 13. As shown in FIG. 13, the recharge interface displays a message notification of successful charging. In addition to this, the recharge interface further includes an advertising resource 1301 recommended for the user. The advertising resource 1301 carries a virtual resource used for exchanging an item, for example, a coupon.

[0457] Optionally, if the user clicks the benefit obtaining entry 1202 in the recharge interface shown in FIG. 12, the user is directed to the service interface shown in FIG. 14. The service interface shown in FIG. 14 displays a plurality of advertisement resources recommended for the user, each of which carries a virtual resource for exchange of goods, such as a coupon, a red packet, a cash voucher, a discount coupon, etc.

[0458] The above is only described by taking the shopping field and the advertisement field as examples. In addition, the method of the embodiments of the present application can also be applied to other resource recommendation scenarios. For example, taking an e-book as a source domain and a movie as a target domain, or taking a self-selected stock as a source domain and stock information as a target domain, etc.

[0459] FIG. 15 is a structural schematic diagram of a resource recommendation device provided by an embodiment of the present application. Referring to FIG. 15, the device comprises:

[0460] A first acquisition module 1501 is configured to acquire object data of an object and resource data of a target resource, the target resource belonging to a target domain, and the target domain being any domain;

[0461] A second acquisition module 1502 is configured to acquire first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data comprising a plurality of source domain interaction items, a source domain interaction item being an item of interaction between the object and a resource in a source domain, the target domain interaction data comprising a plurality of target domain interaction items, a target domain interaction item being an item of interaction between the object and a resource in a target domain, and the source domain and the target domain belonging to different domains;

[0462] A screening module 1503 is configured to determine at least one source domain interaction item associated with the target domain in the first source domain interaction data to form second source domain interaction data;

[0463] A prediction module 1504 is configured to determine a recommendation prediction result of the target resource based on the object data, the resource data, the second source domain interaction data and the target domain interaction data, the recommendation prediction result being used to represent an interaction condition between the object and the target resource if the target resource is recommended to the object.

[0464] The resource recommendation apparatus provided in the embodiments of the present application needs to refer to the historical interaction conditions of the object and other resources to infer the interaction tendency of the object to the target resource when determining whether to recommend the target resource of the target domain to the object. Therefore, the target domain interaction data of the object in the target domain is obtained, and the source domain interaction data of the object in the source domain is additionally obtained considering that the target domain interaction data may be insufficient in data quantity, and then the part associated with the target domain is filtered out from the source domain interaction data, and the target domain interaction data and the filtered source domain interaction data are taken as references to predict the interaction condition of the object and the target resource if the target resource is recommended to the object. On the one hand, the source domain interaction data is introduced, so that the defect of insufficient target domain interaction data is made up, and the influence caused by the sparsity of the target domain interaction data is alleviated. On the other hand, only the source domain interaction data associated with the target domain is considered, and the source domain interaction data irrelevant to the target domain is discarded, so that the interference of the source domain interaction data irrelevant to the target domain on the prediction result is reduced, thereby improving the accuracy of resource recommendation as a whole.

[0465] Optionally, referring to FIG. 16, the filtering module 1503 is configured to:

[0466] determine a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs, the entity being an object providing the resource;

[0467] for any source domain interaction matter in the first source domain interaction data, if an entity to which a resource in the source domain interaction matter belongs is any target entity, it is determined that the source domain interaction matter is associated with the target domain.

[0468] Optionally, referring to FIG. 16, the filtering module 1503 is configured to:

[0469] determine a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs, the entity being an object providing the resource;

[0470] for any source domain interaction matter in the first source domain interaction data, if a similarity between an entity to which a resource in the source domain interaction matter belongs and any target entity is greater than a similarity threshold, it is determined that the source domain interaction matter is associated with the target domain.

[0471] Optionally, referring to FIG. 16, the filtering module 1503 is configured to:

[0472] obtain a target entity feature of each target entity;

[0473] extract a feature of the entity to which the resource in the source domain interaction matter belongs to obtain a source domain entity feature;

[0474] if a similarity between the source domain entity feature and any target entity feature is greater than a similarity threshold, it is determined that the source domain interaction matter is associated with the target domain.

[0475] Optionally, referring to FIG. 16, the prediction module 1504 is configured to:

[0476] perform feature extraction on the object data to obtain object features;

[0477] perform feature extraction on the resource data to obtain resource features;

[0478] perform feature extraction on the second source domain interaction data and the target domain interaction data to obtain source domain interaction features and target domain interaction features;

[0479] determine the recommendation prediction result of the target resource based on the object features, the resource features, the source domain interaction features, and the target domain interaction features.

[0480] Optionally, referring to FIG. 16, the prediction module 1504 is configured to:

[0481] perform feature extraction on the second source domain interaction data to obtain initial source domain interaction features, and perform feature extraction on the target domain interaction data to obtain initial target domain interaction features;

[0482] fuse the initial source domain interaction features and the initial target domain interaction features to obtain first fused interaction features;

[0483] multiply the first fused interaction features by a first mapping matrix to obtain first query features, first key features, and first value features;

[0484] fuse the first query features, the first key features, and the first value features to obtain second fused interaction features;

[0485] determine the source domain interaction features and the target domain interaction features based on the second fused interaction features.

[0486] Optionally, referring to FIG. 16, the prediction module 1504 is configured to:

[0487] split intermediate source domain interaction features from the second fused interaction features;

[0488] multiply the resource features by a second mapping matrix to obtain second query features;

[0489] multiply the intermediate source domain interaction features by the second mapping matrix to obtain second key features and second value features;

[0490] fuse the second query features, the second key features, and the second value features to obtain the source domain interaction features.

[0491] Optionally, referring to FIG. 16, the prediction module 1504 is configured to:

[0492] split intermediate target domain interaction features from the second fused interaction features;

[0493] multiplying the resource feature with the third mapping matrix to obtain a third query feature;

[0494] multiplying the intermediate target domain interactive feature with the third mapping matrix to obtain a third key feature and a third value feature;

[0495] fusing the third query feature, the third key feature and the third value feature to obtain the target domain interactive feature.

[0496] Optionally, referring to FIG. 16, the resource recommendation model includes a feature extraction sub-model and a recommendation prediction sub-model, and the prediction module 1504 is configured to:

[0497] extracting features of the object data through the feature extraction sub-model to obtain object features;

[0498] extracting features of the resource data through the feature extraction sub-model to obtain resource features;

[0499] extracting features of the second source domain interactive data and the target domain interactive data through the feature extraction sub-model to obtain source domain interactive features and target domain interactive features;

[0500] determining a recommendation prediction result of the target resource based on the object features, the resource features, the source domain interactive features and the target domain interactive features through the recommendation prediction sub-model.

[0501] Optionally, referring to FIG. 16, the feature extraction sub-model includes a feature extraction network, a feature fusion network and a first attention network, and the first attention network includes a first mapping matrix; and the prediction module 1504 is configured to:

[0502] extracting features of the second source domain interactive data through the feature extraction network to obtain initial source domain interactive features, and extracting features of the target domain interactive data to obtain initial target domain interactive features;

[0503] fusing the initial source domain interactive features and the initial target domain interactive features through the feature fusion network to obtain first fused interactive features;

[0504] multiplying the first fused interactive features with the first mapping matrix through the first attention network to obtain first query features, first key features and first value features, and fusing the first query features, the first key features and the first value features to obtain second fused interactive features;

[0505] determining the source domain interactive features and the target domain interactive features based on the second fused interactive features.

[0506] Optionally, referring to FIG. 16, the feature extraction sub-model further includes a second attention network, and the second attention network includes a second mapping matrix; and the prediction module 1504 is configured to:

[0507] Splitting out the intermediate source domain interaction feature in the second fusion interaction feature;

[0508] Multiplying the resource feature and the second mapping matrix through the second attention network to obtain a second query feature, and multiplying the intermediate source domain interaction feature and the second mapping matrix to obtain a second key feature and a second value feature;

[0509] Fusing the second query feature, the second key feature and the second value feature through the second attention network to obtain the source domain interaction feature.

[0510] Optionally, referring to FIG. 16, the feature extraction sub-model further includes a third attention network, and the third attention network includes a third mapping matrix; the prediction module 1504 is configured to:

[0511] Splitting out an intermediate target domain interaction feature in the second fusion interaction feature;

[0512] Multiplying the resource feature and the third mapping matrix through the third attention network to obtain a third query feature, and multiplying the intermediate target domain interaction feature and the third mapping matrix to obtain a third key feature and a third value feature;

[0513] Fusing the third query feature, the third key feature and the third value feature through the third attention network to obtain the target domain interaction feature.

[0514] Optionally, referring to FIG. 16, the apparatus further includes:

[0515] The recommendation module 1505 is configured to recommend the target resource to the object if the recommendation prediction result meets the recommendation condition.

[0516] It should be noted that: the resource recommendation apparatus provided in the above embodiments is only exemplified by the division of the above functional modules, and in actual application, the above functions can be completed by different functional modules according to needs, that is, the internal structure of the computer device is divided into different functional modules to complete all or part of the above described functions. In addition, the resource recommendation apparatus and the resource recommendation method provided in the above embodiments belong to the same concept, and the specific implementation process is detailed in the method embodiments, which will not be repeated here.

[0517] FIG. 17 is a structural schematic diagram of a resource recommendation model training apparatus provided by an embodiment of the present application. Referring to FIG. 17, the apparatus includes:

[0518] The first obtaining module 1701 is configured to obtain sample object data of a sample object, sample resource data of a sample resource, and a sample label, the sample resource belonging to a target domain, and the sample label being used to represent a real interaction between the sample object and the sample resource after the sample object is recommended the sample resource, the target domain being any domain;

[0519] The second obtaining module 1702 is configured to obtain first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object, the first sample source domain interaction data including a plurality of sample source domain interaction items, the sample source domain interaction item being an item of interaction between the sample object and a resource in a source domain, and the sample target domain interaction data including a plurality of sample target domain interaction items, the sample target domain interaction item being an item of interaction between the sample object and a resource in a target domain, the source domain and the target domain belonging to different domains;

[0520] The screening module 1703 is configured to determine at least one sample source domain interaction item associated with the target domain in the first sample source domain interaction data to constitute second sample source domain interaction data.

[0521] The prediction module 1704 is configured to determine a recommendation prediction result of the sample resource based on the sample object data, the sample resource data, the second sample source domain interaction data, and the target domain sample interaction data by using a resource recommendation model, the recommendation prediction result being used to represent a predicted interaction between the sample object and the sample resource if the sample resource is recommended to the sample object.

[0522] The training module 1705 is configured to train the resource recommendation model based on the recommendation prediction result and the sample label.

[0523] The training device of the resource recommendation model provided in the embodiments of the present application, when training the resource recommendation model, obtains sample target domain interaction data of a sample object in a target domain for a recommendation task of the target domain. Considering that the sample target domain interaction data may be insufficient in data quantity, the device additionally obtains sample source domain interaction data of the sample object in a source domain, and then filters out the part of the sample source domain interaction data that is associated with the target domain. Then, the device uses the sample target domain interaction data and the filtered sample source domain interaction data as references, uses the resource recommendation model to predict a recommendation prediction result of recommending a sample resource to the sample object, and then uses the recommendation prediction result and a sample label to train the resource recommendation model. On the one hand, because the sample source domain interaction data is introduced, the deficiency of insufficient sample target domain interaction data can be made up, the influence of sparse sample target domain interaction data is alleviated, and the accuracy of the resource recommendation model is improved. On the other hand, because only the sample source domain interaction data associated with the target domain is considered and the sample source domain interaction data irrelevant to the target domain is discarded, the interference of the sample source domain interaction data irrelevant to the target domain on the prediction result is reduced, and the accuracy of the resource recommendation model is further improved. Moreover, the sample source domain interaction data irrelevant to the target domain is filtered out, and the amount of data required to be stored and processed can be effectively controlled, which is beneficial to saving storage resources and processing resources.

[0524] Optionally, referring to FIG. 18, the resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model; the prediction module 1704 is configured to:

[0525] The feature extraction sub-model is configured to perform feature extraction on the sample object data to obtain sample object features;

[0526] The feature extraction sub-model is configured to perform feature extraction on the sample resource data to obtain sample resource features;

[0527] The feature extraction sub-model is configured to perform feature extraction on the second sample source domain interaction data and the sample target domain interaction data to obtain sample source domain interaction features and sample target domain interaction features;

[0528] The recommendation prediction sub-model is configured to determine a recommendation prediction result based on the sample object features, the sample resource features, the sample source domain interaction features, and the sample target domain interaction features.

[0529] Optionally, referring to FIG. 18, the sample source domain interaction items comprise source domain resources and interaction time points of the source domain resources, the sample target domain interaction items comprise target domain resources and interaction time points of the target domain resources, the sample source domain interaction features comprise source domain resource features of the source domain resources in each sample source domain interaction item, and the sample target domain interaction features comprise target domain resource features of the target domain resources in each sample target domain interaction item; the device further comprises:

[0530] The first determining module 1706 is configured to, for any source domain resource in the second sample source domain interaction data, determine a first target domain resource in the sample target domain interaction data, and determine source domain resource features of the source domain resource and target domain resource features of the first target domain resource as a first positive sample pair, the interaction time point of the first target domain resource being closest to the interaction time point of the source domain resource.

[0531] The training module 1705 is configured to:

[0532] The training module 1705 is configured to:

[0533] Optionally, referring to FIG. 18, the apparatus further includes:

[0534] The second determining module 1707 is configured to, for any source domain resource in the second sample source domain interaction data, determine a second target domain resource in sample target domain interaction data of any object except the sample object, and determine source domain resource features of the source domain resource and target domain resource features of the second target domain resource as a first negative sample pair, the second target domain resource being any target domain resource in the sample target domain interaction data of the any object; and determine a similarity between the source domain resource features and the target domain resource features in the first negative sample pair.

[0535] The training module 1705 is configured to:

[0536] The training module 1705 is configured to:

[0537] Optionally, referring to FIG. 18, the sample source domain interaction matter includes a source domain resource and an entity to which the source domain resource belongs, the sample target domain interaction matter includes a target domain resource and an entity to which the target domain resource belongs, the sample source domain interaction feature includes source domain resource features of the source domain resource in each sample source domain interaction matter, and the sample target domain interaction feature includes target domain resource features of the target domain resource in each sample target domain interaction matter. The apparatus further includes:

[0538] The third determining module 1708 is configured to, for any source domain resource in the second sample source domain interaction data, determine a third target domain resource in the sample target domain interaction data, and determine source domain resource features of the source domain resource and target domain resource features of the third target domain resource as a second positive sample pair, the entity to which the third target domain resource belongs being the same as the entity to which the source domain resource belongs; and determine a similarity between the source domain resource features and the target domain resource features in the second positive sample pair.

[0539] The training module 1705 is configured to:

[0540] The resource recommendation model is trained based on the recommendation prediction result, the sample label, and the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair.

[0541] Optionally, referring to FIG. 18, the apparatus further includes:

[0542] The fourth determination module 1709 is configured to determine, for any source domain resource in the second sample source domain interaction data, a fourth target domain resource, determine the source domain resource feature of the source domain resource and the target domain resource feature of the fourth target domain resource as a second negative sample pair, and determine the similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair, the fourth target domain resource being any target domain resource different from an entity to which the source domain resource belongs.

[0543] The training module 1705 is configured to:

[0544] The resource recommendation model is trained based on the recommendation prediction result, the sample label, the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, and the similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair.

[0545] Optionally, referring to FIG. 18, the feature extraction sub-model includes a feature extraction network, a feature fusion network, and a first attention network, the first attention network including a first mapping matrix; and the prediction module 1704 is configured to:

[0546] The feature extraction network is used to perform feature extraction on the second sample source domain interaction data to obtain initial sample source domain interaction features, and perform feature extraction on the sample target domain interaction data to obtain initial sample target domain interaction features.

[0547] The feature fusion network is used to fuse the initial sample source domain interaction features and the initial sample target domain interaction features to obtain first sample fusion interaction features.

[0548] The first attention network is used to multiply the first sample fusion interaction features and the first mapping matrix to obtain first sample query features, first sample key features, and first sample value features, and fuse the first sample query features, the first sample key features, and the first sample value features to obtain second sample fusion interaction features.

[0549] The sample source domain interaction feature and the sample target domain interaction feature are determined based on the second sample fusion interaction features.

[0550] Optionally, referring to FIG. 18, the feature extraction sub-model further includes a second attention network, the second attention network including a second mapping matrix; and the prediction module 1704 is configured to:

[0551] Splitting out the intermediate sample source domain interaction feature in the second sample fusion interaction feature;

[0552] Multiplying the sample resource feature and the second mapping matrix through the second attention network to obtain a second sample query feature, multiplying the intermediate sample source domain interaction feature and the second mapping matrix to obtain a second sample key feature and a second sample value feature;

[0553] Fusing the second sample query feature, the second sample key feature and the second sample value feature through the second attention network to obtain the sample source domain interaction feature.

[0554] Optionally, referring to FIG. 18, the feature extraction sub-model further includes a third attention network, and the third attention network includes a third mapping matrix; the prediction module 1704 is configured to:

[0555] Splitting out the intermediate sample target domain interaction feature in the second sample fusion interaction feature;

[0556] Multiplying the sample resource feature and the third mapping matrix through the third attention network to obtain a third sample query feature, multiplying the intermediate sample target domain interaction feature and the third mapping matrix to obtain a third sample key feature and a third sample value feature;

[0557] Fusing the third sample query feature, the third sample key feature and the third sample value feature through the third attention network to obtain the sample target domain interaction feature.

[0558] Optionally, referring to FIG. 18, the screening module 1703 is configured to:

[0559] Determining a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs, and the entity being an object providing the resource;

[0560] For any sample source domain interaction matter in the first sample source domain interaction data, if an entity to which a resource in the sample source domain interaction matter belongs is any target entity, it is determined that the sample source domain interaction matter is associated with the target domain.

[0561] Optionally, referring to FIG. 18, the screening module 1703 is configured to:

[0562] Determining a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs, and the entity being an object providing the resource;

[0563] For any sample source domain interaction matter in the first sample source domain interaction data, if a similarity between an entity to which a resource in the sample source domain interaction matter belongs and any target entity is greater than a similarity threshold, it is determined that the sample source domain interaction matter is associated with the target domain.

[0564] Optionally, referring to FIG. 18, a screening module 1703 is configured to:

[0565] obtain target entity features of each target entity;

[0566] extract features of entities to which resources in the sample source domain interactive matter belong, to obtain sample source domain entity features;

[0567] if the similarity between the sample source domain entity features and any target entity feature is greater than the similarity threshold, it is determined that the sample source domain interactive matter is associated with the target domain.

[0568] It should be noted that the resource recommendation device provided in the above embodiments is only exemplified by the division of the above functional modules. In actual applications, the above functions can be completed by different functional modules according to needs, that is, the internal structure of the computer device is divided into different functional modules to complete all or part of the functions described above. In addition, the training device and method of the resource recommendation model provided in the above embodiments belong to the same concept, and the specific implementation process is described in the method embodiments, which will not be repeated here.

[0569] The embodiments of the present application further provide a computer device, which comprises a processor and a memory. The memory stores at least one computer program, which is loaded and executed by the processor to implement the operations performed in the resource recommendation method of the above embodiments.

[0570] Optionally, the computer device is provided as a terminal. FIG. 19 shows a structural schematic diagram of a terminal 1900 provided by an example embodiment of the present application.

[0571] The terminal 1900 comprises a processor 1901 and a memory 1902.

[0572] The processor 1901 can include one or more processing cores, such as a 4-core processor, an 8-core processor, and the like. The processor 1901 can be implemented in at least one of a hardware form of a DSP (Digital Signal Processing), an FPGA (Field Programmable Gate Array), a PLA (Programmable Logic Array). The processor 1901 can also include a main processor and a coprocessor, the main processor being a processor for processing data in an awake state, also known as a CPU (Central Processing Unit), and the coprocessor being a low-power processor for processing data in a standby state. In some embodiments, the processor 1901 can be integrated with a GPU (Graphics Processing Unit) for rendering and drawing content required to be displayed by the display screen. In some embodiments, the processor 1901 can further include an AI (Artificial Intelligence) processor for processing machine learning-related computing operations.

[0573] The memory 1902 can include one or more computer-readable storage media that can be non-transitory. The memory 1902 can also include a high-speed random access memory, and a nonvolatile memory such as one or more disk storage devices, flash storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 1902 is used to store at least one computer program for being executed by the processor 1901 to implement a resource recommendation method or a training method of a resource recommendation model provided by the method embodiments in the present application.

[0574] In some embodiments, the terminal 1900 can also optionally include a peripheral device interface 1903 and at least one peripheral device. The processor 1901, the memory 1902, and the peripheral device interface 1903 can be connected through a bus or a signal line. Each peripheral device can be connected to the peripheral device interface 1903 through a bus, a signal line, or a circuit board. Optionally, the peripheral device includes at least one of a radio frequency circuit 1904, a display screen 1905, a camera component 1906, an audio circuit 1907, and a power supply 1908.

[0575] The peripheral interface 1903 can be used to connect at least one I / O (Input / Output) related peripheral device to the processor 1901 and the memory 1902. In some embodiments, the processor 1901, the memory 1902 and the peripheral interface 1903 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 1901, the memory 1902 and the peripheral interface 1903 can be implemented on a separate chip or circuit board, and the present embodiments are not limited in this regard.

[0576] The radio frequency circuit 1904 is used to receive and send RF (Radio Frequency) signals, also known as electromagnetic signals. The radio frequency circuit 1904 communicates with the communication network and other communication devices through electromagnetic signals. The radio frequency circuit 1904 converts electrical signals into electromagnetic signals for transmission, or converts received electromagnetic signals into electrical signals. Optionally, the radio frequency circuit 1904 includes an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a subscriber identity module card, and the like. The radio frequency circuit 1904 can communicate with other devices through at least one wireless communication protocol.

[0577] The display screen 1905 is used to display a UI (User Interface). The UI can include graphics, text, icons, video, and any combination thereof. When the display screen 1905 is a touch display screen, the display screen 1905 also has the ability to collect touch signals on or above the surface of the display screen 1905. The touch signals can be input as control signals to the processor 1901 for processing. At this time, the display screen 1905 can also be used to provide virtual buttons and / or virtual keyboards, also known as soft buttons and / or soft keyboards. In some embodiments, the display screen 1905 can be one, arranged on the front panel of the terminal 1900; in some other embodiments, the display screen 1905 can be at least two, arranged on different surfaces of the terminal 1900 or in a folding design; in some other embodiments, the display screen 1905 can be a flexible display screen, arranged on a curved surface or a folding surface of the terminal 1900.

[0578] The camera component 1906 is configured to capture images or videos. Optionally, the camera component 1906 includes a front-facing camera and a rear-facing camera. The front-facing camera is disposed on the front panel of the terminal 1900, and the rear-facing camera is disposed on the back of the terminal 1900. In some embodiments, the rear-facing camera is at least two, which is any one of a main camera, a depth-of-field camera, a wide-angle camera, and a telephoto camera, to realize the background blur function of the main camera and the depth-of-field camera, the panorama shooting and VR (Virtual Reality) shooting function of the main camera and the wide-angle camera, or other fusion shooting functions. In some embodiments, the camera component 1906 can also include a flash. The flash can be a single-color-temperature flash or a dual-color-temperature flash. The dual-color-temperature flash refers to the combination of a warm light flash and a cold light flash, which can be used for light compensation at different color temperatures.

[0579] The audio circuit 1907 can include a microphone and a speaker. The microphone is configured to capture sound waves of a user and an environment, and convert the sound waves into an electrical signal input to the processor 1901 for processing or to the radio frequency circuit 1904 to realize voice communication. For the purpose of stereo sound collection or noise reduction, the microphone can be multiple, disposed at different parts of the terminal 1900. The microphone can also be an array microphone or an omnidirectional collection microphone. The speaker is configured to convert an electrical signal from the processor 1901 or the radio frequency circuit 1904 into sound waves. The speaker can be a traditional diaphragm speaker or a piezoelectric ceramic speaker. When the speaker is a piezoelectric ceramic speaker, it can not only convert an electrical signal into a sound wave audible to humans, but also convert an electrical signal into an inaudible sound wave to humans for ranging purposes. In some embodiments, the audio circuit 1907 can also include a headphone jack.

[0580] The power supply 1908 is configured to supply power to each component in the terminal 1900. The power supply 1908 can be alternating current, direct current, a disposable battery, or a rechargeable battery. When the power supply 1908 includes a rechargeable battery, the rechargeable battery can support wired charging or wireless charging. The rechargeable battery can also be used to support fast charging technology.

[0581] Those skilled in the art can understand that the structure shown in FIG. 19 does not constitute a limitation on the terminal 1900, and can include more or fewer components than shown, or combine certain components, or use different component arrangements.

[0582] Optionally, the computer device is provided as a server. FIG. 20 is a structural schematic diagram of a server provided by an embodiment of the present application. The server 2000 can be quite different in configuration or performance, and can include one or more processors (Central Processing Units, CPUs) 2001 and one or more memories 2002. The memory 2002 stores at least one computer program, which is loaded and executed by the processor 2001 to implement the method provided by each of the above method embodiments. Of course, the server can also have a wired or wireless network interface, a keyboard, an input and output interface, and other components for implementing device functions, and will not be described here in detail.

[0583] The embodiment of the present application further provides a computer readable storage medium, which stores at least one computer program, and the at least one computer program is loaded and executed by a processor to implement the operations performed by the resource recommendation method of the above embodiment, or implement the operations performed by the training method of the resource recommendation model of the above embodiment.

[0584] The embodiment of the present application further provides a computer program product, which includes a computer program, and the computer program is loaded and executed by a processor to implement the operations performed by the resource recommendation method of the above embodiment, or implement the operations performed by the training method of the resource recommendation model of the above embodiment.

[0585] Those skilled in the art can understand that all or part of the steps of the above-mentioned embodiments can be completed by hardware, or by a program instructing relevant hardware to complete, and the program can be stored in a computer readable storage medium, and the storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk.

[0586] The above description is only optional embodiments of the present application, and does not limit the present application. Any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A resource recommendation method, characterized by, The method comprises: acquiring object data of an object and resource data of a target resource, the target resource belonging to a target domain, the target domain being any domain; acquiring first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data comprising a plurality of source domain interaction items, the source domain interaction item being an item of interaction of the object with a resource in a source domain, the target domain interaction data comprising a plurality of target domain interaction items, the target domain interaction item being an item of interaction of the object with a resource in the target domain, the source domain and the target domain belonging to different domains; in the first source domain interaction data, determining at least one source domain interaction item associated with the target domain to constitute second source domain interaction data; based on the object data, the resource data, the second source domain interaction data and the target domain interaction data, determining a recommendation prediction result of the target resource, the recommendation prediction result being used to represent an interaction condition of the object and the target resource if the target resource is recommended to the object.

2. The method of claim 1, wherein, The method comprises: determining a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs; for any source domain interaction item in the first source domain interaction data, if an entity to which a resource in the source domain interaction item belongs is any target entity, it is determined that the source domain interaction item is associated with the target domain.

3. The method of claim 1, wherein, The method comprises: determining a plurality of target entities, the target entity being an entity to which a resource of the target domain belongs; for any source domain interaction item in the first source domain interaction data, if a similarity between an entity to which a resource in the source domain interaction item belongs and any target entity is greater than a similarity threshold, it is determined that the source domain interaction item is associated with the target domain.

4. The method according to any one of claims 1 to 3, characterized in that, The method comprises: performing feature extraction on the object data to obtain object features; performing feature extraction on the resource data to obtain resource features; performing feature extraction on the second source domain interaction data and the target domain interaction data to obtain source domain interaction features and target domain interaction features; based on the object features, the resource features, the source domain interaction features and the target domain interaction features, determining a recommendation prediction result of the target resource.

5. The method of claim 4, wherein, The method comprises: performing feature extraction on the second source domain interaction data to obtain initial source domain interaction features, and performing feature extraction on the target domain interaction data to obtain initial target domain interaction features; fusing the initial source domain interaction features and the initial target domain interaction features to obtain first fused interaction features; Multiplying the first fusion interaction feature with a first mapping matrix to obtain a first query feature, a first key feature and a first value feature; Fusing the first query feature, the first key feature and the first value feature to obtain a second fusion interaction feature; Determining the source domain interaction feature and the target domain interaction feature based on the second fusion interaction feature.

6. The method of claim 5, wherein, The determining the source domain interaction feature based on the second fusion interaction feature comprises: Splitting an intermediate source domain interaction feature from the second fusion interaction feature; Multiplying the resource feature with a second mapping matrix to obtain a second query feature; Multiplying the intermediate source domain interaction feature with the second mapping matrix to obtain a second key feature and a second value feature; Fusing the second query feature, the second key feature and the second value feature to obtain the source domain interaction feature.

7. The method according to claim 5 or 6, characterized in that, The determining the target domain interaction feature based on the second fusion interaction feature comprises: Splitting an intermediate target domain interaction feature from the second fusion interaction feature; Multiplying the resource feature with a third mapping matrix to obtain a third query feature; Multiplying the intermediate target domain interaction feature with the third mapping matrix to obtain a third key feature and a third value feature; Fusing the third query feature, the third key feature and the third value feature to obtain the target domain interaction feature.

8. The method according to any one of claims 1 to 7, characterized in that, The resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model, and the determining the recommendation prediction result of the target resource based on the object data, the resource data, the second source domain interaction data and the target domain interaction data comprises: Extracting features of the object data by the feature extraction sub-model to obtain object features; Extracting features of the resource data by the feature extraction sub-model to obtain resource features; Extracting features of the second source domain interaction data and the target domain interaction data by the feature extraction sub-model to obtain source domain interaction features and target domain interaction features; Determining the recommendation prediction result of the target resource based on the object features, the resource features, the source domain interaction features and the target domain interaction features by the recommendation prediction sub-model.

9. The method of claim 8, wherein, The feature extraction sub-model comprises a feature extraction network, a feature fusion network and a first attention network, the first attention network comprises a first mapping matrix, and the extracting features of the second source domain interaction data and the target domain interaction data by the feature extraction sub-model to obtain source domain interaction features and target domain interaction features comprises: Extracting features of the second source domain interaction data by the feature extraction network to obtain initial source domain interaction features, and extracting features of the target domain interaction data by the feature extraction network to obtain initial target domain interaction features; Fusing the initial source domain interaction features and the initial target domain interaction features by the feature fusion network to obtain a first fusion interaction feature; The first query feature, the first key feature and the first value feature are fused to obtain a second fusion interaction feature. The source domain interaction feature and the target domain interaction feature are determined based on the second fusion interaction feature. 10.A method for training a resource recommendation model, the method comprising: The method comprises: obtaining sample object data of a sample object, sample resource data of a sample resource, and a sample label, the sample resource belonging to a target domain, the sample label being used to represent a real interaction condition between the sample object and the sample resource after the sample resource is recommended to the sample object, and the target domain being any domain; obtaining first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object, the first sample source domain interaction data comprising a plurality of sample source domain interaction items, the sample source domain interaction item being an item of interaction between the sample object and a resource in a source domain, the sample target domain interaction data comprising a plurality of sample target domain interaction items, the sample target domain interaction item being an item of interaction between the sample object and a resource in the target domain, and the source domain and the target domain belonging to different domains; at least one sample source domain interaction item associated with the target domain is determined in the first sample source domain interaction data to constitute second sample source domain interaction data; a recommendation prediction result of the sample resource is determined based on the sample object data, the sample resource data, the second sample source domain interaction data and the target domain sample interaction data by using a resource recommendation model, the recommendation prediction result being used to represent a predicted interaction condition between the sample object and the sample resource if the sample resource is recommended to the sample object; the resource recommendation model is trained based on the recommendation prediction result and the sample label.

11. The method of claim 10, wherein, The resource recommendation model comprises a feature extraction sub-model and a recommendation prediction sub-model; and the determination of the recommendation prediction result of the sample resource based on the sample object data, the sample resource data, the second sample source domain interaction data and the target domain sample interaction data by using the resource recommendation model comprises: sample object features are extracted from the sample object data by using the feature extraction sub-model; sample resource features are extracted from the sample resource data by using the feature extraction sub-model; sample source domain interaction features and sample target domain interaction features are extracted from the second sample source domain interaction data and the sample target domain interaction data by using the feature extraction sub-model; the recommendation prediction result is determined based on the sample object features, the sample resource features, the sample source domain interaction features and the sample target domain interaction features by using the recommendation prediction sub-model.

12. The method according to claim 10 or 11, characterized in that, The sample source domain interaction includes a source domain resource and an interaction time point of the source domain resource, the sample target domain interaction includes a target domain resource and an interaction time point of the target domain resource, the sample source domain interaction feature includes a source domain resource feature of the source domain resource in each sample source domain interaction, and the sample target domain interaction feature includes a target domain resource feature of the target domain resource in each sample target domain interaction. The method further includes: For any source domain resource in the second sample source domain interaction data, a first target domain resource is determined in the sample target domain interaction data, and a source domain resource feature of the source domain resource and a target domain resource feature of the first target domain resource are determined as a first positive sample pair, and an interaction time point of the first target domain resource is closest to an interaction time point of the source domain resource. Similarities between the source domain resource feature and the target domain resource feature in the first positive sample pair are determined. The training of the resource recommendation model based on the recommendation prediction result and the sample label includes: The resource recommendation model is trained based on the recommendation prediction result, the sample label, and the similarities between the source domain resource feature and the target domain resource feature in the first positive sample pair.

13. The method of claim 12, wherein, The method further includes: For any source domain resource in the second sample source domain interaction data, a second target domain resource is determined in sample target domain interaction data of any object other than the sample object, and a source domain resource feature of the source domain resource and a target domain resource feature of the second target domain resource are determined as a first negative sample pair, and the second target domain resource is any target domain resource in the sample target domain interaction data of the any object. Similarities between the source domain resource feature and the target domain resource feature in the first positive sample pair are determined. The training of the resource recommendation model based on the recommendation prediction result, the sample label, and the similarities between the source domain resource feature and the target domain resource feature in the first positive sample pair includes: The resource recommendation model is trained based on the recommendation prediction result, the sample label, the similarities between the source domain resource feature and the target domain resource feature in the first positive sample pair, and similarities between the source domain resource feature and the target domain resource feature in the first negative sample pair.

14. The method of claim 10 or 11, wherein, The sample source domain interaction includes a source domain resource and an entity to which the source domain resource belongs, the sample target domain interaction includes a target domain resource and an entity to which the target domain resource belongs, the sample source domain interaction feature includes a source domain resource feature of the source domain resource in each sample source domain interaction, and the sample target domain interaction feature includes a target domain resource feature of the target domain resource in each sample target domain interaction. The method further includes: For any source domain resource in the second sample source domain interaction data, a third target domain resource is determined in the sample target domain interaction data, and a source domain resource feature of the source domain resource and a target domain resource feature of the third target domain resource are determined as a second positive sample pair, an entity to which the third target domain resource belongs is same as an entity to which the source domain resource belongs; Similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair is determined; The training of the resource recommendation model based on the recommendation prediction result and the sample label comprises: The resource recommendation model is trained based on the recommendation prediction result, the sample label, and the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair.

15. The method of claim 14, wherein, The method further comprises: For any source domain resource in the second sample source domain interaction data, a fourth target domain resource is determined, and a source domain resource feature of the source domain resource and a target domain resource feature of the fourth target domain resource are determined as a second negative sample pair, the fourth target domain resource is any target domain resource different from the entity to which the source domain resource belongs; Similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair is determined; The training of the resource recommendation model based on the recommendation prediction result, the sample label, and the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair comprises: The resource recommendation model is trained based on the recommendation prediction result, the sample label, the similarity between the source domain resource feature and the target domain resource feature in the second positive sample pair, and the similarity between the source domain resource feature and the target domain resource feature in the second negative sample pair.

16. A resource recommendation apparatus, characterized by comprising: The device comprises: A first obtaining module is configured to obtain object data of an object and resource data of a target resource, the target resource belonging to a target domain, the target domain being any domain; A second obtaining module is configured to obtain first source domain interaction data of the object and target domain interaction data of the object, the first source domain interaction data comprising a plurality of source domain interaction items, the source domain interaction item being an item of interaction between the object and a resource in a source domain, the target domain interaction data comprising a plurality of target domain interaction items, the target domain interaction item being an item of interaction between the object and a resource in the target domain, the source domain and the target domain belonging to different domains; A screening module is configured to determine at least one source domain interaction item associated with the target domain in the first source domain interaction data to form second source domain interaction data; A prediction module is configured to determine a recommendation prediction result of the target resource based on the object data, the resource data, the second source domain interaction data, and the target domain interaction data, the recommendation prediction result being used to represent an interaction condition between the object and the target resource if the object is recommended the target resource.

17. A training device for a resource recommendation model, characterized in that, The device comprises: The first obtaining module is configured to obtain sample object data of a sample object, sample resource data of a sample resource, and a sample label, the sample resource belonging to a target domain, the sample label being used to represent a real interaction between the sample object and the sample resource after the sample resource is recommended to the sample object, and the target domain being any domain. The second obtaining module is configured to obtain first sample source domain interaction data of the sample object and sample target domain interaction data of the sample object, the first sample source domain interaction data including a plurality of sample source domain interaction items, the sample source domain interaction item being an interaction between the sample object and a resource in a source domain, and the sample target domain interaction data including a plurality of sample target domain interaction items, the sample target domain interaction item being an interaction between the sample object and a resource in the target domain, the source domain and the target domain belonging to different domains. The screening module is configured to determine at least one sample source domain interaction item associated with the target domain in the first sample source domain interaction data to form second sample source domain interaction data. The prediction module is configured to determine a recommendation prediction result of the sample resource based on the sample object data, the sample resource data, the second sample source domain interaction data, and the target domain sample interaction data by using a resource recommendation model, the recommendation prediction result being used to represent a predicted interaction between the sample object and the sample resource if the sample resource is recommended to the sample object. The training module is configured to train the resource recommendation model based on the recommendation prediction result and the sample label.

18. A computer device, comprising: The computer device includes a processor and a memory, and the memory stores at least one computer program, the at least one computer program is loaded and executed by the processor to implement the operations performed by the resource recommendation method according to any one of claims 1 to 9, or implement the operations performed by the training method of the resource recommendation model according to any one of claims 10 to 15.

19. A computer-readable storage medium, characterized in that, The computer readable storage medium stores at least one computer program, and the at least one computer program is loaded and executed by the processor to implement the operations performed by the resource recommendation method according to any one of claims 1 to 9, or implement the operations performed by the training method of the resource recommendation model according to any one of claims 10 to 15.

20. A computer program product comprising a computer program, characterized in that, The computer program is loaded and executed by the processor to implement the operations performed by the resource recommendation method according to any one of claims 1 to 9, or implement the operations performed by the training method of the resource recommendation model according to any one of claims 10 to 15.

Citation Information

Patent Citations

  • Sorting model training method for intelligent recommendation and intelligent recommendation method and device

    CN114139052A

  • Sequence recommendation method and system fusing cooperation information and self-attention mechanism

    CN115269974A

  • Recommendation method and device, equipment and storage medium

    CN116028704A

  • Resource recommendation method, resource recommendation model training method, device and equipment

    CN119003873A

  • Scalable cross domain recommendation system

    EP2860672A2