Substance recommendation method based on node screening
By screening the correlation distance between abnormal human characteristic nodes and material nodes in the user map, combining enrichment scores and preset thresholds, high accuracy analysis and material recommendation of user abnormal situations are achieved, and the problem of low recommendation accuracy in the prior art is solved.
Patent Information
- Application Number
- CN202411475850.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-22
- Publication Date
- 2025-03-21
- Estimated Expiration
- 2044-10-22
AI Technical Summary
The prior art is difficult to accurately analyze the node feature correlation interaction relationships in multiple dimensions under user abnormal situations, resulting in low accuracy of material recommendations.
The material recommendation method based on node screening is adopted. By obtaining the characteristic data of multiple nodes in the target user map, the correlation distance between abnormal human characteristic nodes and material nodes is selected, and the candidate node path and target material nodes are selected based on the enrichment score and preset threshold.
It improves the targetedness and accuracy of material recommendations, enhances the accuracy of analyzing abnormal situations of target users, and meets the user's personalized recommendation needs.
Smart Images

Figure CN119669553A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing, and in particular to a substance recommendation method based on node screening. Background Art
[0002] The factors that cause abnormal changes in abnormal situations for different users are different, which leads to complex and diverse abnormal data of users, making it difficult for users to filter and find effective solutions from a large number of abnormal solutions.
[0003] Traditional recommendation methods generally obtain user graphs based on the node feature data of multiple dimensions of the user and the node feature data of the substance to be recommended under various abnormal circumstances, and recommend substances to users by analyzing the node feature data in the user graph. However, the abnormal data of users is complex and diverse, and it is difficult to analyze the correlation and interaction relationship between node features of multiple dimensions, which makes the analysis of the correlation and interaction relationship less accurate, resulting in low accuracy in recommending substances to users, making it difficult to meet user requirements.
[0004] Therefore, how to improve the accuracy of material recommendations to target users becomes an urgent problem to be solved. Summary of the invention
[0005] In view of the above technical problems, the technical solution adopted by the present invention is a substance recommendation method based on node screening, and the substance recommendation method based on node screening comprises the following steps:
[0006] S100, obtain several first human feature nodes in the target user graph, the second human feature nodes corresponding to each first human feature node, the third human feature nodes corresponding to each first human feature node, several material nodes, several node paths corresponding to all first human feature nodes, and the first human feature detection data corresponding to all first human feature nodes, the first connection relationship data corresponding to each first human feature node, the second human feature data corresponding to each second human feature node, and the third human feature data corresponding to each third human feature node.
[0007] S200, screening out a first abnormal human feature node from all first human feature nodes according to the first human feature detection data, and determining a node path corresponding to the first abnormal human feature node as a first candidate node path.
[0008] S300: According to the first connection relationship data, second abnormal human body feature nodes are screened out from the first abnormal human body feature nodes corresponding to each first candidate node path.
[0009] S400, obtaining a first node distance between each second abnormal human feature node and each material node according to positions of the second abnormal human feature node and the material node in the target user graph.
[0010] S500 , obtaining the enrichment score of each node pathway, and screening out second candidate node pathways from all node pathways according to a preset first score threshold and a preset second score threshold.
[0011] S600, acquiring target feature data corresponding to each first human feature node according to the second human feature data corresponding to each second human feature node and the third human feature data corresponding to each third human feature node.
[0012] S700 , selecting a target human body feature node from the first human body feature nodes corresponding to each second candidate node path according to the target feature data, a preset first feature threshold and a preset second feature threshold.
[0013] S800, obtaining a second node distance between each target human feature node and each material node according to positions of the target human feature node and the material node in the target user graph.
[0014] S900 , screening out a target material node from all material nodes according to the first node distance, the second node distance and a preset distance threshold.
[0015] Compared with the prior art, the present invention has obvious beneficial effects. By means of the above technical scheme, the substance recommendation method based on node screening provided by the present invention can achieve considerable technical advancement and practicality, and has wide industrial utilization value, and has at least the following beneficial effects: classifying and screening the first human feature nodes according to the first human feature detection data, screening out the first abnormal human feature nodes from all the first human feature nodes, and determining the node path corresponding to the first abnormal human feature node as the first candidate node path, thereby improving the pertinence and accuracy of substance recommendation; according to the first connection relationship data, regarding the first abnormal human feature node at the most downstream in the first candidate node path as the second abnormal human feature node, to analyze the abnormal situation caused by the abnormal feature node of the target user, and to analyze the effect of the substance node in repairing the abnormal situation, thereby improving the accuracy of the analysis result; according to the positions of the second abnormal human feature node and the substance node in the target user graph, obtaining the first node distance between each second abnormal human feature node and each substance node, to characterize the effect of each substance node on each second abnormal human feature node; obtaining each node The enrichment score of the pathway is used to characterize the degree of enrichment of the first human characteristic node corresponding to the node pathway at both ends of the sorting sequence of the preset reference node pathway set, and then to characterize the influence of the coordinated change of the first human characteristic node in the corresponding node pathway on the preset phenotypic state. According to the preset first score threshold and the preset second score threshold, the second candidate node pathway is screened out from all the node pathways. According to the second human characteristic data and the third human characteristic data, the target characteristic data corresponding to each first human characteristic node is obtained. Combined with the preset first characteristic threshold and the preset second characteristic threshold, the target human characteristic node is screened out from the first human characteristic node corresponding to each second candidate node pathway, and the influence of the first human characteristic node with medium expression on the abnormal situation analysis is eliminated, thereby improving the pertinence and accuracy of the substance recommendation. According to the position of the target human characteristic node and the substance node in the target user map, the second node distance between each target human characteristic node and each substance node is obtained. According to the first node distance, the second node distance and the preset distance threshold, the target substance node is screened out from all the substance nodes, thereby improving the accuracy of the substance recommendation result. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0017] Figure 1A flowchart of a substance recommendation method based on node screening provided by an embodiment of the present invention;
[0018] Figure 2 A flowchart of a substance recommendation method based on a user graph provided in Embodiment 2 of the present invention;
[0019] Figure 3 This is a flowchart of an execution computer program of a substance recommendation system provided in Embodiment 1 of the present invention. DETAILED DESCRIPTION
[0020] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0021] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations are intended to cover non-exclusive inclusions, for example, a process, method, method, substance or server that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, substances or devices.
[0022] Embodiment 1
[0023] This embodiment 1 provides a substance recommendation method based on node screening, such as Figure 1 As shown, the substance recommendation method based on node screening includes the following steps:
[0024] S100, obtain several first human feature nodes in the target user graph, the second human feature nodes corresponding to each first human feature node, the third human feature nodes corresponding to each first human feature node, several material nodes, several node paths corresponding to all first human feature nodes, and the first human feature detection data corresponding to all first human feature nodes, the first connection relationship data corresponding to each first human feature node, the second human feature data corresponding to each second human feature node, and the third human feature data corresponding to each third human feature node.
[0025] The target user may refer to a user who needs to be recommended related substances, and the first human feature node, the second human feature node, and the third human feature node may refer to nodes that will change differently when an abnormal situation occurs to the target user, and may present different node abnormal situations.
[0026] The substance corresponding to the substance node refers to a recommendation target for the target user. The substance corresponding to the substance node acts on the first human feature node of the target user based on the second human feature node, and then acts on the target user.
[0027] The first connection relationship data corresponding to the first human feature node is used to characterize the connection relationship and interaction relationship between the first human feature nodes, for example, the activation effect or inhibition effect that the first human feature node can have on other first human feature nodes. The node pathway is a pathway composed of the first human feature nodes based on the first connection relationship data corresponding to the first human feature node.
[0028] The first human feature detection data corresponding to all first human feature nodes may refer to whole exome sequencing data of the target user, which is used to characterize whether the first human feature corresponding to the first human feature node has changed.
[0029] The second human body feature data corresponding to each second human body feature node may refer to the information expression amount corresponding to the second human body feature node.
[0030] The third human body feature data corresponding to each third human body feature node may refer to the information expression amount corresponding to the third human body feature node.
[0031] The target user graph represents the first human feature node, the second human feature node, the third human feature node, the abnormal feature node and the material node corresponding to the target user, as well as the association and interaction relationships between the nodes. It represents the abnormal situation of the target user from multiple dimensions and provides a data basis for recommending materials to the target user.
[0032] In a specific implementation, the target user graph is obtained through the following steps:
[0033] S1, obtain the first human feature node set A, the first human feature data set α, the second human feature data set β, the third human feature data set γ, the abnormal feature node set E, the material node set F corresponding to the target user, and the second human feature node set B, the third human feature node set C and the first connection relationship data set G corresponding to the first human feature node set A, and the second connection relationship data set H corresponding to the second human feature node set B, the fourth connection relationship data set Y corresponding to the abnormal feature node set E and the fifth connection relationship data set Z corresponding to the material node set F, where A = {A1, A2, ..., Ai , ..., A I}, A i It refers to the first human feature node of the ith character, B={B1,B2,……,B i , ..., B I}, B i A i The corresponding second human feature node, C = {C1, C2, ..., C i , ..., C I}, C i A i The corresponding third human feature node, G is used to characterize the connection relationship between the first human feature nodes, H is used to characterize the connection relationship between the second human feature nodes, Y is used to characterize the connection relationship between the abnormal feature node and the first human feature node, the second human feature node and the third human feature node, Z is used to characterize the connection relationship between the abnormal feature node and the second human feature node, i=1, 2,..., I, u(i)=1, 2,..., i-1, i+1,..., I, I refers to the total number of first human feature nodes, j=1, 2,..., n, n refers to the total number of change categories.
[0034] S2, according to the first human feature node set A, the second human feature node set B and the third human feature node set C, obtain the first user graph set P = {P1, P2, ..., P i , ..., P I}, where the i-th first user graph P i Through A i , B i and C i Connect two by two.
[0035] Among them, the first human feature node A i There is a corresponding second human feature node B i and a corresponding third human feature node C i , first of all, i , B i and C i By connecting two by two, we can obtain the corresponding first user graph P i , then for the I first human feature nodes, the first user graph set P = {P1, P2, ..., P i , ..., P I}, as the basis for analyzing the node relationships of target users.
[0036] In the above, the first human feature node, the corresponding second human feature node and the corresponding third human feature node of the target user are connected in pairs to obtain the corresponding first user graph, which characterizes the association relationship between the first human feature node, the corresponding second human feature node and the corresponding third human feature node, and provides a data basis for material recommendation for the target user.
[0037] S3: Connect all first user graphs in the first user graph set P according to the first connection relationship data set G and the second connection relationship data set H to obtain a second user graph.
[0038] Among them, the associated first human feature nodes are connected according to the first connection relationship data between the first human feature nodes, and the associated second human feature nodes are connected according to the second connection relationship data between the second human feature nodes. Combined with the first user graph, the connections between all the first human feature nodes, the second human feature nodes and the third human feature nodes can be completed, and the second user graph can be obtained, which improves the degree of association between the first human feature nodes, the second human feature nodes and the third human feature, thereby improving the accuracy of the representation of the association relationship and interaction relationship between the nodes.
[0039] In a specific implementation manner, the first connection relationship data set G = {G1, G2, . . . , G i , ..., G I}, G i = {G i1 , G i2 , ..., G iu(i) , ..., G iI}, G iu(i) A i and A u(i) The first connection relationship data is used to indicate whether there is a first connection line segment, the direction of the arrow of the first connection line segment, and the first preset category of the first connection line segment, S3 also includes the following steps:
[0040] S311, get A i and A u(i) The first connection relationship data G iu(i) = {GX iu(i) 1 , GX iu(i) 2}, where GX iu(i) 1 =GX iu(i) 2 =0 means A i and A u(i) There is no first connecting line segment between GX iu(i)1 =1 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A i Point to A u(i) , GX iu(i) 1 =2 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A u(i) Point to A i , GX iu(i) 2 =ρ represents A i and A u(i) There are first connecting line segments and the category of the first connecting line segments is the ρth first preset category, ρ=1, 2, ..., μ, μ refers to the total number of the first preset categories of the first connecting line segments.
[0041] S312, if GX iu(i) 1 =GX iu(i) 2 = 0, then do not connect A i and A u(i) .
[0042] S313, if GX iu(i) 1 =1 and GX iu(i) 2 =ρ, then according to the direction of the arrow, i Point to A u(i) And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) .
[0043] S314, if GX iu(i) 1 =2 and GX iu(i) 2 =ρ, then according to the direction of the arrow, u(i) Point to A i And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) .
[0044] The first preset category may be set by the implementer according to actual conditions. For example, the first preset category may refer to an interaction relationship category such as binding, activation, inhibition, etc.
[0045] In the above, based on the first connection relationship data between the first human feature nodes, it is determined whether there is a first connecting line segment between the first human feature nodes and the arrow direction and category of the first connecting line segment, so as to complete the connection between the first human feature nodes, thereby improving the correlation degree between the first human feature nodes in the second user graph, thereby improving the accuracy of characterizing the correlation relationship and interaction relationship between the nodes.
[0046] In a specific implementation manner, the second connection relationship data set H = {H1, H2, . . . , H i , ..., H I}, H i ={H i1 , H i2 , ..., H iu(i) , ..., H iI}, H iu(i) Refers to B i and B u(i) The second connection relationship data between the two is used to indicate whether the second connection line segment exists and the confidence of the second connection line segment. S3 further includes the following steps:
[0047] S321, get B i and B u(i) The second connection relationship data H between iu(i) , where H iu(i) =0 means B i and B u(i) There is no second connecting line segment between them, H iu(i) >0 means B i and B u(i) There is a second connecting line segment between them and the confidence corresponding to the second connecting line segment is equal to H iu(i) .
[0048] S322, if H iu(i) = 0, do not connect B i and B u(i) .
[0049] S323, if H iu(i) >0, then the corresponding confidence level is equal to H iu(i) The second connecting line segment connects B i and B u(i) .
[0050] The confidence level is used to characterize the credibility of the existence of the second connecting line segment between the two corresponding second human feature nodes, and can be obtained by the implementer from a preset database.
[0051] In the above, based on the second connection relationship data between the second human feature nodes, it is determined whether there is a second connecting line segment between the second human feature nodes and the confidence level corresponding to the second connecting line segment, and the connection between the second human feature nodes is completed, thereby improving the correlation degree between the second human feature nodes in the second user graph, thereby improving the accuracy of characterizing the correlation relationship and interaction relationship between the nodes.
[0052] S4, based on the first human feature data set α, the second human feature data set β and the third human feature data set γ, update the node feature data of all the first human feature nodes, the second human feature nodes and the third human feature nodes in the second user graph, and obtain the third user graph corresponding to the target user.
[0053] Among them, the specific change category can be set by the implementer according to the actual situation. For example, the traversal category in this embodiment can refer to frameshift deletion mutation, frameshift insertion mutation, in-frame deletion, in-frame insertion, missense mutation, nonsense mutation, stop codon mutation, splice site mutation, start codon mutation, base insertion and other change categories.
[0054] The node feature data corresponding to the second human feature node may refer to the information expression amount corresponding to the second human feature node. The node feature data corresponding to the third human feature node may refer to the information expression amount corresponding to the third human feature node.
[0055] Among them, the initial node feature data of all the first human feature nodes, the second human feature nodes and the third human feature nodes in the second user graph are 0.
[0056] As described above, after obtaining the first human feature data set α, the second human feature data set β and the third human feature data set γ corresponding to the target user, the node feature data of all the first human feature nodes, the second human feature nodes and the third human feature nodes in the second user graph are updated accordingly, and the third user graph corresponding to the target user is obtained, which improves the degree of representation of the target user's human feature data by the third user graph, and improves the accuracy of the material recommendation results when used as the data basis for material recommendation to the target user.
[0057] S5. According to the fourth connection relationship data set Y and the fifth connection relationship data set Z, all abnormal feature nodes in the abnormal feature node set E and all material nodes in the material node set F are added to the third user graph to obtain the target user graph.
[0058] In a specific implementation, S5 further includes the following steps:
[0059] S531, obtaining the material node set F and the fifth connection relationship data set Z corresponding to F, where F = {F1, F2, ..., F t , ..., F T}, F t It refers to the tth material node, Z = {Z1, Z2, ..., Z t , ..., Z T}, F t The corresponding fifth connection relationship data list Z t = {Z t 1 , Z t 2}, Z t 1 ε F t The εth second human feature node connected, It means E t The nth abnormal characteristic node connected, t = 1, 2, ..., T, T refers to the total number of material nodes, ε = 1, 2, ..., ζ(t), ζ(t) refers to F t The total number of connected second human feature nodes, η = 1, 2, ..., λ(t), λ(t) refers to F t The total number of connected anomaly feature nodes.
[0060] S532, adding all material nodes in F to the second user sub-graph according to Z, and obtaining the target user graph.
[0061] Among them, the substance corresponding to the substance node refers to the recommended target for the target user, and the substance corresponding to the substance node acts on the abnormal feature node of the target user based on the second human feature node, and then acts on the target user.
[0062] Therefore, this embodiment can connect the material node, the corresponding second human feature node and the abnormal feature node according to the fifth connection relationship corresponding to the material node to characterize the association relationship and interaction relationship between the material node and the second human feature node and the abnormal feature node, thereby improving the accuracy of the target user graph in characterizing the association relationship and interaction relationship between each node in the target user.
[0063] In a specific implementation, the node path is obtained by the following steps:
[0064] S101, for the i-th first human feature node A i , if G i1 1 =G i2 1 =……=Giu(i) 1 =……=G iI 1 ≠1, then A i Update to the first level target node.
[0065] S102, according to G i , will point to A i The first human feature node is updated to A i The corresponding second-level target node.
[0066] S103, according to G, will point to A i The first human feature node of the corresponding ω-th level target node is updated to A i The corresponding ω+1th level target node, until A i The total number of corresponding ω+1th level target nodes is equal to 0, where ω is an integer greater than 1.
[0067] S104, according to A i , A i The corresponding second-level target node, A i The corresponding third-level target node to A i The corresponding order of the ω-th level target nodes is obtained i The corresponding node path.
[0068] S105, traverse the first human feature node set A to obtain all node paths.
[0069] Among them, when there is a first connecting line segment between two first human feature nodes in the target user graph, it can represent that there is an interactive relationship between the corresponding two first human feature nodes, and the direction of the arrow of the first connecting line segment can represent that the first human feature node has binding, activation, inhibition, etc. interactive effects on the pointed first human feature node.
[0070] At the same time, the arrow pointing of the first connecting line segment can represent the direction from the upstream node to the downstream node in the corresponding node pathway, so as to trace the upstream node according to the first-level target node at the most downstream to obtain the corresponding second-level target node, third-level target node and other upstream nodes at various levels, and then obtain the candidate node pathway to further serve as the data basis for substance recommendation.
[0071] Specifically, the first human feature node pointing to the second-level target node is determined as the third-level target node, the first human feature node pointing to the third-level target node is determined as the fourth-level target node, and so on, the first human feature node pointing to the ω-th level target node is determined as the ω+1-th level target node, until the total number of ω+1-th level target nodes is equal to 0, indicating that the upstream nodes corresponding to all the first-level target nodes have been determined, then the acquisition of the target nodes is stopped.
[0072] Therefore, the corresponding candidate node paths can be obtained in reverse order according to the first-level target node, the second-level target node, the third-level target node, etc. Then, by traversing all the first target nodes, all the node paths can be obtained from the target user graph as the basis for recommending substances to the target user, and the influence of redundant node information in the target user graph on the substance recommendation results can be eliminated, thereby improving the accuracy of the substance recommendation results.
[0073] S200, screening out a first abnormal human feature node from all first human feature nodes according to the first human feature detection data, and determining a node path corresponding to the first abnormal human feature node as a first candidate node path.
[0074] In a specific implementation, S200 further includes the following steps:
[0075] S201, judging the state detection category corresponding to each first human feature node according to the first human feature detection data, wherein the state detection category is abnormal or not abnormal.
[0076] S202: When the state detection category corresponding to the first human feature node is abnormal, the corresponding first human feature node is determined as a first abnormal human feature node.
[0077] Among them, the first human feature detection data can characterize whether the first human feature corresponding to the first human feature node has changed. Therefore, based on the first human feature detection data, it can be judged whether the state detection category corresponding to each first human feature node is abnormal or not, and when the state detection category corresponding to the first human feature node is abnormal, the corresponding first human feature node is determined as the first abnormal human feature node.
[0078] As described above, the first human feature nodes are classified and screened according to the first human feature detection data, and abnormal first human feature nodes are selected as analysis objects, and the influence of non-abnormal node pathways of non-abnormal first human feature nodes on abnormal situation analysis is eliminated, so that the abnormal situation analysis of the target user can be performed more efficiently and accurately, thereby improving the pertinence and accuracy of material recommendation.
[0079] S300: According to the first connection relationship data, second abnormal human body feature nodes are screened out from the first abnormal human body feature nodes corresponding to each first candidate node path.
[0080] In a specific implementation, S300 further includes the following steps:
[0081] S301, for any first candidate node path, obtaining the level sequence number corresponding to each first abnormal human body feature node in the first candidate node path.
[0082] S302: Determine the first abnormal human feature node corresponding to the smallest level sequence number in the first candidate node path as the second abnormal human feature node corresponding to the first candidate node path.
[0083] Among them, in each candidate node path, the upstream first human feature node will bind, activate, inhibit and other interactive behaviors to the downstream first human feature node. Therefore, when the abnormal feature node causes the abnormal situation of the downstream first human feature node, and the material node repairs the abnormal situation of the downstream first human feature node, the upstream first human feature node will also affect the abnormal situation of the first human feature node. Therefore, when analyzing the abnormal situation caused by the abnormal feature node of the target user and analyzing the effect of the material node repairing the abnormal situation, the most downstream first abnormal human feature node in the first candidate node path is regarded as the most concerned node.
[0084] The level sequence number corresponding to each first abnormal human feature node can represent the upstream and downstream situation of the first abnormal human feature node in the corresponding first candidate node path, and the smaller the level sequence number, the more downstream the first abnormal human feature node is in the corresponding first candidate node path. The first abnormal human feature node corresponding to the smallest level sequence number in the first candidate node path is determined as the second abnormal human feature node corresponding to the first candidate node path.
[0085] In the above, based on the interactive behavior of the upstream first human feature node with the downstream first human feature node, the most downstream first abnormal human feature node in the first candidate node path is regarded as the most concerned second abnormal human feature node, to analyze the abnormal situation caused by the abnormal feature node of the target user, and to analyze the effect of the material node in repairing the abnormal situation, thereby improving the accuracy of the analysis results.
[0086] S400, obtaining a first node distance between each second abnormal human feature node and each material node according to positions of the second abnormal human feature node and the material node in the target user graph.
[0087] In a specific implementation, S400 further includes the following steps:
[0088] S401, obtain the tth material node F t The second human feature node Z connected to t 1 ε and Z t 1 ε The first human feature node connected, Z t 1 ε The first human feature node connected is determined as F t The corresponding first reference human feature node.
[0089] S402: For any second abnormal characteristic node, if the second abnormal characteristic node and F t The corresponding first reference human feature node is on the same node path, then the first level sequence number of the second abnormal feature node on the node path is obtained, and F t The second level sequence number of the corresponding first reference human feature node on the node path.
[0090] S403, according to the first level sequence number and the second level sequence number, obtain the second abnormal feature node and F t The first node distance between them.
[0091] S404, if the second abnormal feature node and F t If the corresponding first reference human feature node is not on the same node path, the preset node distance is determined as the distance between the second abnormal feature node and F t The first node distance between them.
[0092] Among them, the substance corresponding to the substance node refers to the recommendation target recommended to the target user, and the substance corresponding to the substance node acts on the first human feature node of the target user based on the second human feature node, and then acts on the target user.
[0093] Therefore, the node distance between the second abnormal human feature node and the material node can be converted into a node distance between the first human feature node connected to the second human feature node connected to the material node.
[0094] When the second abnormal feature node and the corresponding first reference human feature node are on the same node path, the corresponding first node distance can be characterized according to the difference in the upstream and downstream positions of the nodes in the node path.
[0095] When the second abnormal feature node and the corresponding first reference human feature node are not on the same node path, it means that the corresponding material node has a smaller effect on the second abnormal feature node, that is, the first node distance between the second abnormal feature node and the corresponding material node is far. At this time, the preset node distance is determined as the corresponding first node distance.
[0096] The preset node distance may be set according to actual conditions. For example, the preset node distance may be the maximum level number.
[0097] As described above, according to the positions of the second abnormal human feature nodes and the material nodes in the target user graph, the first node distance between each second abnormal human feature node and each material node is obtained to characterize the effect of each material node on each second abnormal human feature node, and serve as the basis for material recommendation, thereby improving the accuracy of the material recommendation results.
[0098] S500 , obtaining the enrichment score of each node pathway, and screening out second candidate node pathways from all node pathways according to a preset first score threshold and a preset second score threshold.
[0099] Among them, phenotype refers to the characteristics and features (morphology, structure, physiology, biochemistry, behavior, etc.) exhibited by an individual under certain environmental conditions. The preset phenotypic state can be set by the implementer according to actual needs.
[0100] This embodiment can obtain the reference node pathway corresponding to each type of phenotypic state, and then filter out the reference node pathway corresponding to the preset phenotypic state, and form a preset reference node pathway set. Then, based on the node pathway and the reference node pathway set, the enrichment score of each node pathway is obtained to characterize the degree of enrichment of the first human characteristic node corresponding to the node pathway at both ends of the sorting sequence of the preset reference node pathway set, and then to characterize the influence of the coordinated change of the first human characteristic node in the corresponding node pathway on the preset phenotypic state, so that the candidate node pathway with a larger or smaller enrichment score can be screened out according to the enrichment score, and the second candidate node pathway with a higher degree of attention can be used to recommend substances, so that the recommended substances have a higher degree of matching with the preset phenotypic state and the actual needs of the implementer, thereby improving the accuracy of the recommendation results.
[0101] Specifically, the expression level of each first human characteristic node in the preset reference node pathway set under the preset phenotypic state is obtained, and the first human characteristic nodes in the reference node pathway set are sorted in descending order of expression level, so as to obtain the sorting sequence of the preset reference node pathway set.
[0102] The calculation method of the enrichment score is a well-known technical means in the art and will not be described in detail here.
[0103] In the above, the enrichment score is obtained to characterize the degree of enrichment of the first human characteristic node corresponding to the node pathway at both ends of the sorting sequence of the preset reference node pathway set, and then to characterize the impact of the coordinated change of the first human characteristic node in the corresponding node pathway on the preset phenotypic state, and the second candidate node pathway with higher attention and higher matching degree with the actual needs of the implementer is screened out from the node pathway, thereby improving the accuracy of the material recommendation results.
[0104] In a specific implementation, the preset second score threshold is less than the preset first score threshold, and S500 further includes the following steps:
[0105] For any node pathway, if the enrichment score corresponding to the node pathway is greater than a preset first score threshold, or the enrichment score corresponding to the node pathway is less than a preset second score threshold, the node pathway is determined as a second candidate node pathway.
[0106] S600, acquiring target feature data corresponding to each first human feature node according to the second human feature data corresponding to each second human feature node and the third human feature data corresponding to each third human feature node.
[0107] Among them, each first human body feature node has a corresponding second human body feature node and a corresponding second human body feature node, which can form a corresponding human body feature triplet.
[0108] The second human body feature data may refer to the information expression amount corresponding to the second human body feature node, and the third human body feature data may refer to the information expression amount corresponding to the third human body feature node. For each human body feature triplet, based on the second human body feature data corresponding to the second human body feature node and the third human body feature data corresponding to the third human body feature node, the target feature data corresponding to the first human body feature node can be obtained to characterize the expression amount of the first human body feature node.
[0109] For example, the target feature data may be the product of the first preset priority and the second human feature data, plus the product of the second preset priority and the third human feature data, wherein the first preset priority and the second preset priority are respectively used to characterize the importance of the second human feature node and the third human feature node in expressing the node data of the corresponding first human feature node.
[0110] S700 , selecting a target human body feature node from the first human body feature nodes corresponding to each second candidate node path according to the target feature data, a preset first feature threshold and a preset second feature threshold.
[0111] In a specific implementation manner, the preset second characteristic threshold is less than the preset first characteristic threshold, and S700 further includes the following steps:
[0112] For any target feature data, if the target feature data is greater than a preset first feature threshold, or the target feature data is less than a preset second feature threshold, the first human feature node corresponding to the target feature data is determined as the target human feature node.
[0113] Among them, when analyzing the abnormal situation of the target user, the first human feature nodes with larger or smaller expression amounts are screened out as the target human feature nodes with higher attention, and the influence of the first human feature nodes with medium expression amounts on the abnormal situation analysis is eliminated. This can more efficiently and accurately analyze the abnormal situation of the target user, thereby improving the pertinence and accuracy of material recommendations.
[0114] S800, obtaining a second node distance between each target human feature node and each material node according to positions of the target human feature node and the material node in the target user graph.
[0115] In a specific implementation, S800 further includes the following steps:
[0116] S801, for any target human feature node, if the target human feature node and F t If the corresponding first reference human feature node is on the same node path, the third level sequence number of the target human feature node on the node path is obtained.
[0117] S802, according to the third level sequence number and the second level sequence number, obtain the target human feature node and F t The second node distance between them.
[0118] S803, if the target human feature node and F t If the corresponding first reference human feature node is not on the same node path, the preset node distance is determined as the distance between the target human feature node and F t The second node distance between them.
[0119] Among them, the node distance between the target human feature node and the material node can be converted into the node distance between the first human feature node connected to the target human feature node and the second human feature node connected to the material node.
[0120] When the target human feature node and the corresponding first reference human feature node are on the same node path, the corresponding second node distance can be characterized according to the difference in the upstream and downstream positions of the nodes in the node path.
[0121] When the target human feature node and the corresponding first reference human feature node are not on the same node path, it means that the corresponding material node has a smaller effect on the target human feature node, that is, the second node distance between the target human feature node and the corresponding material node is far. At this time, the preset node distance is determined as the corresponding second node distance.
[0122] As described above, based on the positions of the target human feature nodes and the material nodes in the target user graph, the second node distance between each target human feature node and each material node is obtained to characterize the effect of each material node on each target human feature node, and serves as the basis for material recommendation, thereby improving the accuracy of the material recommendation results.
[0123] S900 , screening out a target material node from all material nodes according to the first node distance, the second node distance and a preset distance threshold.
[0124] In a specific implementation, S900 further includes the following steps:
[0125] S901 , screening out first recommended material nodes from all material nodes according to a first node distance and a preset first distance threshold, and acquiring a first recommended material node set.
[0126] S902: Filter out second recommended material nodes from all material nodes according to the second node distance and a preset first distance threshold, and obtain a second recommended material node set.
[0127] S903: Determine the intersection of the first recommended substance node set and the second recommended substance node set as the set corresponding to the target substance node.
[0128] When the first node distance is less than a preset first distance threshold, the material node corresponding to the first node distance is determined as the first recommended material node.
[0129] When the second node distance is less than a preset first distance threshold, the material node corresponding to the second node distance is determined as a second recommended material node.
[0130] When a substance node is both a first recommended substance node and a second recommended substance node, the substance node is determined as a target substance node, so that the substance corresponding to the target substance node is recommended to the target user.
[0131] The specific value of the first distance threshold may be set by the implementer according to actual conditions.
[0132] In the above, the first human feature nodes are classified and screened according to the first human feature detection data, the first abnormal human feature nodes are screened out from all the first human feature nodes, and the node pathway corresponding to the first abnormal human feature node is determined as the first candidate node pathway, thereby improving the pertinence and accuracy of the material recommendation; according to the first connection relationship data, the first abnormal human feature node at the most downstream in the first candidate node pathway is regarded as the second abnormal human feature node to analyze the abnormal situation caused by the abnormal feature node of the target user, and to analyze the effect of the material node in repairing the abnormal situation, thereby improving the accuracy of the analysis result; according to the positions of the second abnormal human feature nodes and the material nodes in the target user graph, the first node distance between each second abnormal human feature node and each material node is obtained to characterize the effect of each material node on each second abnormal human feature node; the enrichment score of each node pathway is obtained to characterize the first human feature node corresponding to the node pathway in the sorting sequence of the preset reference node pathway set. The degree of enrichment at both ends is used to characterize the influence of the coordinated changes of the first human characteristic nodes in the corresponding node pathway on the preset phenotypic state. According to the preset first score threshold and the preset second score threshold, the second candidate node pathway is screened out from all the node pathways. According to the second human characteristic data and the third human characteristic data, the target characteristic data corresponding to each first human characteristic node is obtained. Combined with the preset first characteristic threshold and the preset second characteristic threshold, the target human characteristic node is screened out from the first human characteristic node corresponding to each second candidate node pathway, and the influence of the first human characteristic node with medium expression on the abnormal situation analysis is eliminated, thereby improving the pertinence and accuracy of the substance recommendation; according to the position of the target human characteristic node and the substance node in the target user map, the second node distance between each target human characteristic node and each substance node is obtained, and according to the first node distance, the second node distance and the preset distance threshold, the target substance node is screened out from all the substance nodes, thereby improving the accuracy of the substance recommendation results.
[0133] Embodiment 2
[0134] Based on the above-mentioned embodiment 1, this embodiment 2 provides a substance recommendation method based on user graph, such as Figure 2 As shown, the substance recommendation method based on user graph includes:
[0135] S1, obtain the first human feature node set A, the first human feature data set α, the second human feature data set β, the third human feature data set γ, the abnormal feature node set E, the material node set F corresponding to the target user, and the second human feature node set B, the third human feature node set C and the first connection relationship data set G corresponding to the first human feature node set A, and the second connection relationship data set H corresponding to the second human feature node set B, the fourth connection relationship data set Y corresponding to the abnormal feature node set E and the fifth connection relationship data set Z corresponding to the material node set F, where A = {A1, A2, ..., A i , ..., A I}, A i It refers to the first human feature node of the ith character, B={B1,B2,……,B i , ..., B I}, B i A i The corresponding second human feature node, C = {C1, C2, ..., C i , ..., C I}, C i A i The corresponding third human feature node, G is used to characterize the connection relationship between the first human feature nodes, H is used to characterize the connection relationship between the second human feature nodes, Y is used to characterize the connection relationship between the abnormal feature node and the first human feature node, the second human feature node and the third human feature node, Z is used to characterize the connection relationship between the abnormal feature node and the second human feature node, i=1, 2,..., I, u(i)=1, 2,..., i-1, i+1,..., I, I refers to the total number of first human feature nodes, j=1, 2,..., n, n refers to the total number of change categories.
[0136] S2, according to the first human feature node set A, the second human feature node set B and the third human feature node set C, obtain the first user graph set P = {P1, P2, ..., P i , ..., P I}, where the i-th first user graph P i Through A i , B i and C i Connect two by two.
[0137] S3: Connect all first user graphs in the first user graph set P according to the first connection relationship data set G and the second connection relationship data set H to obtain a second user graph.
[0138] In a specific implementation manner, the first connection relationship data set G = {G1, G2, . . . , G i , ..., GI}, G i = {G i1 , G i2 , ..., G iu(i) , ..., G iI}, G iu(i) A i and A u(i) The first connection relationship data is used to indicate whether there is a first connection line segment, the direction of the arrow of the first connection line segment, and the first preset category of the first connection line segment, S3 further includes the following steps:
[0139] S311, get A i and A u(i) The first connection relationship data G iu(i) = {GX iu(i) 1 , GX iu(i) 2}, where GX iu(i) 1 =GX iu(i) 2 =0 means A i and A u(i) There is no first connecting line segment between GX iu(i) 1 =1 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A i Point to A u(i) , GX iu(i) 1 =2 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A u(i) Point to A i , GX iu(i) 2 =ρ represents A i and A u(i) There are first connecting line segments and the category of the first connecting line segments is the ρth first preset category, ρ=1, 2, ..., μ, μ refers to the total number of the first preset categories of the first connecting line segments.
[0140] S312, if GX iu(i) 1 =GX iu(i) 2 = 0, then do not connect A i and A u(i) .
[0141] S313, if GX iu(i) 1 =1 and GXiu(i) 2 =ρ, then according to the direction of the arrow, from A i Point to A u(i) And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) .
[0142] S314, if GX iu(i) 1 =2 and GX iu(i) 2 =ρ, then according to the direction of the arrow, from A u(i) Point to A i And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) .
[0143] In a specific implementation manner, the second connection relationship data set H = {H1, H2, . . . , H i , ..., H I}, H i ={H i1 , H i2 , ..., H iu(i) , ..., H iI}, H iu(i) Refers to B i and B u(i) The second connection relationship data between the two is used to indicate whether the second connection line segment exists and the confidence of the second connection line segment. S3 further includes the following steps:
[0144] S321, get B i and B u(i) The second connection relationship data H between iu(i) , where H iu(i) =0 means B i and B u(i) There is no second connecting line segment between them, H iu(i) >0 means B i and B u(i) There is a second connecting line segment between them and the confidence corresponding to the second connecting line segment is equal to H iu(i) .
[0145] S322, if H iu(i) = 0, do not connect B i and B u(i) .
[0146] S323, if H iu(i) >0, then the corresponding confidence level is equal to H iu(i) The second connecting line segment connects B i and Bu(i) .
[0147] The confidence level is used to characterize the credibility of the existence of the second connecting line segment between the two corresponding second human feature nodes, and can be obtained by the implementer from a preset database.
[0148] In the above, based on the second connection relationship data between the second human feature nodes, it is determined whether there is a second connecting line segment between the second human feature nodes and the confidence level corresponding to the second connecting line segment, and the connection between the second human feature nodes is completed, thereby improving the correlation degree between the second human feature nodes in the second user graph, thereby improving the accuracy of characterizing the correlation relationship and interaction relationship between the nodes.
[0149] S4, based on the first human feature data set α, the second human feature data set β and the third human feature data set γ, update the node feature data of all the first human feature nodes, the second human feature nodes and the third human feature nodes in the second user graph, and obtain the third user graph corresponding to the target user.
[0150] In a specific embodiment, α={α1, α2, . . . , α i , ..., α m}, α i ={α i1 , α i2 , ..., α ij , ..., α in}, α ij It refers to the number of changes in the jth change category corresponding to the i-th first human feature node, β = {β1, β2, ..., β i , ..., β m}, β i It refers to the node feature data corresponding to the second human feature node of the ith human body, γ={γ1,γ2,……,γ i , ..., γ m}, γ i refers to the node feature data corresponding to the ith third human feature node, and S4 further includes the following steps:
[0151] S411, update the node feature data corresponding to the i-th first human feature node in the second user graph to α i .
[0152] S412, update the node feature data corresponding to the i-th second human feature node in the second user graph to β i .
[0153] S413, updating the node feature data corresponding to the i-th third human feature node in the second user graph to γ i .
[0154] S5. According to the fourth connection relationship data set Y and the fifth connection relationship data set Z, all abnormal feature nodes in the abnormal feature node set E and all material nodes in the material node set F are added to the third user graph to obtain the target user graph.
[0155] In a specific implementation, S5 further includes the following steps:
[0156] S521, obtain the abnormal feature node set E and the fourth connection relationship data set Y corresponding to E, where E = {E1, E2, ..., E k ,……,E K}, E k It refers to the kth abnormal feature node, Y = {Y1, Y2, ..., Y k , ..., Y K}, E k Corresponding fourth connection relationship data list Y k = {Y k 1 , Y k 2 , Y k 3}, It means E k The qth first human feature node connected, It means E k The rth second human feature node connected, It means E k The sth third human feature node connected, k = 1, 2, ..., K, K refers to the total number of abnormal feature nodes, q = 1, 2, ..., Q(k), Q(k) refers to E k The total number of connected first human feature nodes, r = 1, 2, ..., R (k), R (k) refers to E k The total number of connected second human feature nodes, s = 1, 2, ..., S(k), S(k) refers to E k The total number of connected third-person feature nodes.
[0157] S522, according to Y, all abnormal feature nodes in E are added to the first user sub-graph to obtain the second user sub-graph.
[0158] Among them, the abnormal feature node may refer to a feature node corresponding to an abnormal situation, and the abnormal situation corresponding to the abnormal feature node may affect the first human body feature node, the second human body feature node and the third human body feature node.
[0159] Therefore, this embodiment can connect the abnormal feature node, all corresponding first human feature nodes, second human feature nodes and third human feature nodes according to the fourth connection relationship corresponding to the abnormal feature node to characterize the association relationship and interaction relationship between the abnormal feature node and the first human feature node, the second human feature node and the third human feature node, thereby improving the accuracy of the target user graph in characterizing the association relationship and interaction relationship between each node in the target user.
[0160] In a specific implementation, S5 further includes the following steps:
[0161] S531, obtaining the material node set F and the fifth connection relationship data set Z corresponding to F, where F = {F1, F2, ..., F t , ..., F T}, F t It refers to the tth material node, Z = {Z1, Z2, ..., Z t , ..., Z T}, F t The corresponding fifth connection relationship data list Z t = {Z t 1 , Z t 2}, F t The εth second human feature node connected, It means E t The nth abnormal characteristic node connected, t = 1, 2, ..., T, T refers to the total number of material nodes, ε = 1, 2, ..., ζ(t), ζ(t) refers to F t The total number of connected second human feature nodes, η = 1, 2, ..., λ(t), λ(t) refers to F t The total number of connected anomaly feature nodes.
[0162] S532, adding all material nodes in F to the second user sub-graph according to Z, and obtaining the target user graph.
[0163] S6, inputting the target user map into a preset recommendation model to obtain the target substance recommendation result corresponding to the target user.
[0164] Among them, the preset recommendation model is used to analyze the nodes in the target user graph, the connection relationship between the nodes and the node feature data of the nodes, and output the predicted connection value between the abnormal feature nodes and the material nodes to characterize the degree of association and interaction between the abnormal feature nodes and the material nodes, and then screen out the material nodes whose predicted connection value is greater than the preset connection value threshold, and determine the substance corresponding to the screened material node as the target substance corresponding to the target user, so as to obtain the target substance recommendation result, thereby improving the accuracy of the target substance recommendation result.
[0165] The preset recommendation model may be acquired and trained by the implementer according to actual conditions. For example, the preset recommendation model may include a preset first encoding model, a preset second encoding model, and a preset prediction model.
[0166] In the above, according to the first human feature node set A corresponding to the target user, the second human feature node set B corresponding to A and the third human feature node set C corresponding to A, the first user graph set P is obtained, and according to the first connection relationship data set G corresponding to A and the second connection relationship data set H corresponding to B, all the first user graphs in P are connected to obtain the second user graph, thereby improving the degree of association between the first human feature node, the second human feature node and the third human feature in the second user graph; according to the first human feature data set α, the second human feature data set β and the third human feature data set γ corresponding to the target user, the node feature data of all the first human feature nodes, the second human feature nodes and the third human feature nodes in the second user graph are updated to obtain the third user graph corresponding to the target user. , which improves the representation degree of the third user graph on the human feature data of the target user; according to the fourth connection relationship data set Y corresponding to the abnormal feature node set E and the fifth connection relationship data set Z corresponding to the material node set F, all abnormal feature nodes in E and all material nodes in F are added to the third user graph to obtain the target user graph, and the first human feature node, the second human feature node, the third human feature node, the abnormal feature node and the material node, as well as the association relationship and interaction relationship between the nodes are displayed in the target user graph, which improves the accuracy of the target user graph in representing the association relationship and interaction relationship between each node in the target user; the target user graph is input into the preset recommendation model to obtain the target substance recommendation result corresponding to the target user, which improves the accuracy of the target substance recommendation result.
[0167] Embodiment 3
[0168] On the basis of the above-mentioned Embodiment 1 and Embodiment 2, this Embodiment 3 provides a substance recommendation system, which includes a processor and a memory storing a computer program, wherein the memory further stores a preset third user graph corresponding to a target user, a preset target user graph, a preset first coding model, a preset second coding model, and a preset prediction model. When the computer program is executed by the processor, the following steps are implemented: Figure 3 As shown:
[0169] S10, according to the preset third user graph, obtain the first node connection matrix ψ0, the first human feature data matrix ψ1, the second human feature data matrix ψ2 and the third human feature data matrix ψ3 corresponding to the target user, wherein ψ0 includes the first connection relationship data between all first human feature nodes corresponding to the target user, ψ1 includes the node feature data of all first human feature nodes corresponding to the target user, ψ2 includes the node feature data of all second human feature nodes corresponding to the target user, and ψ3 includes the node feature data of all third human feature nodes corresponding to the target user.
[0170] Among them, the first node connection matrix ψ0 is used to characterize the connection relationship between any two first human feature nodes, the first human feature data matrix ψ1 is used to characterize the changes corresponding to each first human feature node, including the change category and the change degree, the second human feature data matrix ψ2 is used to characterize the expression quantity corresponding to each second human feature node, and the third human feature data matrix ψ3 is used to characterize the expression quantity corresponding to each third human feature node. The abnormal situation of the target user can be characterized in multiple dimensions according to the third user graph and the corresponding ψ0, ψ1, ψ2 and ψ3, thereby providing a data basis for material recommendation to the target user.
[0171] In a specific implementation, the first node connection matrix ψ0 is obtained by the following steps:
[0172] S011, get A i and A u(i) The first connection relationship data G iu(i) = {GX iu(i) 1 , GX iu(i) 2}, where GX iu(i) 1 =GX iu(i) 2 =0 means A i and A u(i) There is no first connecting line segment between GX iu(i) 1 =1 means A i and A u(i)There is a first connecting line segment between them and the arrow points from A i Point to A u(i) , GX iu(i) 1 =2 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A u(i) Point to A i , GX iu(i) 2 =ρ represents A i and A u(i) There are first connecting line segments and the category of the first connecting line segments is the ρth first preset category, ρ=1, 2, ..., μ, μ refers to the total number of the first preset categories of the first connecting line segments.
[0173] S012, if GX iu(i) 1 =GX iu(i) 2 =0, then the data value of the i-th row and u(i)-th column in ψ0 is determined to be 0.
[0174] S013, if GX iu(i) 1 =1 and GX iu(i) 2 =ρ, then the data value of the i-th row and u(i)-th column in ψ0 is determined to be ρ.
[0175] S014, if GX iu(i) 1 =2 and GX iu(i) 2 =ρ, then the data value of the i-th row and u(i)-th column in ψ0 is determined to be -ρ.
[0176] S015, determine that the data value of the i-th row and i-th column is 0.
[0177] S016, traverse all first human feature nodes to obtain the first node connection matrix ψ0.
[0178] Among them, the data of the i-th row and u(i)-th column of the first node connection matrix ψ0 is the i-th first human feature node A iThe data value corresponding to the connection relationship between the u(i)th first human feature nodes, and the data value of 0 can represent that there is no direct association relationship between the corresponding one or two first human feature nodes, the positive or negative of the data value can represent the direction of the arrow of the corresponding first connecting line segment, and the absolute value of the data value can represent the first preset category of the corresponding first connecting line segment. Therefore, the association relationship between the first human feature nodes can be represented according to the first node connection matrix ψ0, and then it can be used as the node feature of the target user, providing a feature basis for the material recommendation task for the target user.
[0179] In a specific embodiment, α={α1, α2, . . . , α i , ..., α m}, α i ={α i1 , α i2 , ..., α ij , ..., α in}, α ij It refers to the number of changes in the jth change category corresponding to the i-th first human feature node. The data value of the i-th row and j-th column in the first human feature data matrix ψ1 is α ij .
[0180] Among them, the data value of the i-th row and j-th column in the first human feature data matrix ψ1 is the change quantity α of the j-th change category corresponding to the i-th first human feature node ij .
[0181] In one embodiment, β = {β1, β2, ..., β i , ..., β m}, β i It refers to the node feature data corresponding to the i-th second human feature node. The i-th row data value in the second human feature data matrix ψ2 is β i .
[0182] Among them, the data value of the i-th row in the second human feature data matrix ψ2 is the node feature data β corresponding to the i-th second human feature node i .
[0183] In a specific embodiment, γ={γ1, γ2, . . . , γ i , ..., γ m}, γ i It refers to the node feature data corresponding to the i-th third human feature node. The i-th row data value in the third human feature data matrix ψ3 is γ i .
[0184] Among them, the data value of the i-th row in the third human feature data matrix ψ3 is the node feature data γ corresponding to the i-th third human feature nodei .
[0185] As described above, the abnormal situations of the target user in multiple dimensions are characterized according to the third user graph and the corresponding ψ0, ψ1, ψ2 and ψ3, which provides a multi-dimensional data basis for the material recommendation task of the target user, thereby improving the accuracy of the material recommendation results.
[0186] S20, input the preset third user graph, ψ0, ψ1, ψ2 and ψ3 into the preset first coding model to obtain the target user embedding feature corresponding to the target user.
[0187] Among them, the first encoding model is used to extract and encode the input third user graph, ψ0, ψ1, ψ2 and ψ3, and output the target user embedded features corresponding to the target user to characterize the feature information of the first human feature node, the second human feature node and the third human feature node of the target user, providing multi-dimensional feature information for the material recommendation task of the target user, thereby improving the accuracy of the material recommendation results.
[0188] In a specific implementation, the preset first coding model is obtained by the following steps:
[0189] S021, obtain several sample users, a third user graph sample corresponding to each sample user, a first node connection matrix sample corresponding to each sample user, a first human feature data matrix sample, a second human feature data matrix sample and a third human feature data matrix sample.
[0190] S022, input each third user graph sample, the first human feature node connection matrix sample corresponding to each third user graph sample, the first human feature data matrix sample, the second human feature data matrix sample and the third human feature data matrix sample into the first encoding model to be trained, and obtain the sample user embedding features corresponding to the sample user corresponding to each third user graph sample.
[0191] S023, inputting the embedded features of each sample user into a preset first decoding model, and outputting a first node prediction connection matrix corresponding to each sample user.
[0192] S024: Calculate the first model loss according to all first node connection matrix samples and all first node prediction connection matrices.
[0193] S025, training parameters of the first coding model to be trained according to the first model loss until the first model loss converges, and obtaining a preset first coding model.
[0194] Among them, the third user graph sample is obtained according to the node connection information and node feature data of the sample user, and the acquisition method of the third user graph sample, the first node connection matrix sample, the first human feature data matrix sample, the second human feature data matrix sample and the third human feature data matrix sample is consistent with the acquisition method of the third user graph, the first node connection matrix, the first human feature data matrix, the second human feature data matrix and the third human feature data matrix.
[0195] The higher the similarity between the first node connection matrix sample and the corresponding first node prediction connection matrix, the higher the accuracy of the first coding model. Therefore, the degree of difference between each first node connection matrix sample and the corresponding first node prediction connection matrix is calculated, and the average value of the degree of difference between all first node connection matrix samples and all first node prediction connection matrices is determined as the first model loss, thereby improving the training accuracy of the first coding model.
[0196] As described above, the first encoding model trained according to the third user graph samples, the first node connection matrix samples, the first human feature data matrix samples, the second human feature data matrix samples and the third human feature data matrix samples is more adaptable to the target user, and the first encoding model is more accurate, thereby improving the accuracy of the embedded features of the target user.
[0197] S30, inputting a preset target user graph into a preset second coding model to obtain a material embedding feature corresponding to the target user.
[0198] Among them, the target user graph represents the first human feature node, the second human feature node, the third human feature node, the abnormal feature node and the material node, as well as the association and interaction relationships between the nodes. Compared with the third user graph, the target user graph represents the abnormal situation of the target user from more dimensions, thereby providing a data basis for recommending materials to the target user.
[0199] The second encoding model is used to extract and encode the input target user graph, and output the material embedding features corresponding to the target user to characterize the association relationship between the material node and the first human feature node, the second human feature node, the third human feature node and the abnormal feature node.
[0200] As described above, the preset target user graph is input into the preset second encoding model to obtain the material embedding features corresponding to the target user. The material recommendation task of the target user provides feature information of more dimensions, thereby improving the accuracy of the material recommendation results.
[0201] S40, inputting the target user embedded features and the material embedded features into a preset prediction model to obtain the predicted connection value between the material node and the abnormal feature node.
[0202] Among them, the prediction model is used to perform feature encoding and feature classification on the input target user embedded features and material embedded features, and output the predicted connection value between the material node and the abnormal feature node to characterize the effectiveness of the material corresponding to the material node in solving the abnormal situation corresponding to the abnormal feature node, which serves as the basis for recommending materials to the target users.
[0203] As described above, the target user embedding features and the material embedding features are input into the preset prediction model, and the predicted connection value between the material node and the abnormal feature node is obtained to characterize the effectiveness of the material corresponding to the material node in solving the abnormal situation corresponding to the abnormal feature node, which is used to recommend materials to the target user, thereby improving the accuracy of the material recommendation results.
[0204] S50, determining a material node whose corresponding predicted connection value is greater than a preset connection value threshold as a target material node, and recommending the material corresponding to the target material node to a target user.
[0205] The specific value of the preset connection value threshold can be set by the implementer according to actual conditions.
[0206] In the above, the first node connection matrix ψ0, the first human feature data matrix ψ1, the second human feature data matrix ψ2 and the third human feature data matrix ψ3 corresponding to the target user are obtained according to the preset third user graph, the preset third user graph, ψ0, ψ1, ψ2 and ψ3 are input into the preset first coding model, the target user embedding feature corresponding to the target user is obtained to characterize the feature information of the first human feature node, the second human feature node and the third human feature node of the target user, the preset target user graph is input into the preset second coding model, the material embedding feature corresponding to the target user is obtained, the association relationship between the material node and the first human feature node, the second human feature node, the third human feature node and the abnormal feature node is characterized, and multi-dimensional feature information is provided for the material recommendation task of the target user; the target user embedding feature and the material embedding feature are input into the preset prediction model, the predicted connection value between the material node and the abnormal feature node is obtained, the material node whose corresponding predicted connection value is greater than the preset connection value threshold is determined as the target material node, and the material corresponding to the target material node is recommended to the target user, thereby improving the accuracy of the material recommendation result.
[0207] Although some specific embodiments of the present invention have been described in detail by way of example, it should be understood by those skilled in the art that the above examples are for illustration only and are not intended to limit the scope of the present invention. It should also be understood by those skilled in the art that various modifications may be made to the embodiments without departing from the scope and spirit of the present invention. The scope of the present invention is defined by the appended claims.
Claims
1. A substance recommendation method based on node screening, characterized in that: The substance recommendation method based on node screening comprises the following steps: S100, obtaining a plurality of first human feature nodes in the target user graph, a second human feature node corresponding to each first human feature node, a third human feature node corresponding to each first human feature node, a plurality of material nodes, a plurality of node pathways corresponding to all first human feature nodes, and first human feature detection data corresponding to all first human feature nodes, first connection relationship data corresponding to each first human feature node, second human feature data corresponding to each second human feature node, and third human feature data corresponding to each third human feature node; S200, screening out a first abnormal human feature node from all first human feature nodes according to the first human feature detection data, and determining a node path corresponding to the first abnormal human feature node as a first candidate node path; S300, screening out second abnormal human body feature nodes from the first abnormal human body feature nodes corresponding to each first candidate node path according to the first connection relationship data; S400, acquiring a first node distance between each second abnormal human feature node and each material node according to the positions of the second abnormal human feature node and the material node in the target user graph; S500, obtaining an enrichment score of each node pathway, and screening out a second candidate node pathway from all node pathways according to a preset first score threshold and a preset second score threshold; S600, acquiring target feature data corresponding to each first human feature node according to the second human feature data corresponding to each second human feature node and the third human feature data corresponding to each third human feature node; S700, screening out a target human body feature node from the first human body feature nodes corresponding to each second candidate node path according to the target feature data, a preset first feature threshold and a preset second feature threshold; S800, acquiring a second node distance between each target human feature node and each material node according to the positions of the target human feature node and the material node in the target user graph; S900: Filter out a target material node from all material nodes according to the first node distance, the second node distance and a preset distance threshold.
2. The substance recommendation method based on node screening according to claim 1, characterized in that: S200 also includes the following steps: S201, judging a state detection category corresponding to each first human feature node according to the first human feature detection data, wherein the state detection category is abnormal or not abnormal; S202: When the state detection category corresponding to the first human feature node is abnormal, the corresponding first human feature node is determined as a first abnormal human feature node.
3. The substance recommendation method based on node screening according to claim 1, characterized in that: The target user graph is obtained through the following steps: S1, obtain the first human feature node set A, the first human feature data set α, the second human feature data set β, the third human feature data set γ, the abnormal feature node set E, the material node set F corresponding to the target user, and the second human feature node set B, the third human feature node set C and the first connection relationship data set G corresponding to the first human feature node set A, and the second connection relationship data set H corresponding to the second human feature node set B, the fourth connection relationship data set Y corresponding to the abnormal feature node set E and the fifth connection relationship data set Z corresponding to the material node set F, wherein A={A1,A2,……,A i , ..., A I }, A i It refers to the first human feature node of the ith character, B={B1,B2,……,B i , ..., B I }, B i A i The corresponding second human feature node, C = {C1, C2, ..., C i , ..., C I }, C i A i The corresponding third human feature node, G is used to characterize the connection relationship between the first human feature nodes, H is used to characterize the connection relationship between the second human feature nodes, Y is used to characterize the connection relationship between the abnormal feature node and the first human feature node, the second human feature node and the third human feature node, and Z is used to characterize the connection relationship between the abnormal feature node and the second human feature node, i=1, 2, ..., I, u(i)=1, 2, ..., i-1, i+1, ..., I, I refers to the total number of first human feature nodes, j=1, 2, ..., n, n refers to the total number of change categories; S2, according to the first human feature node set A, the second human feature node set B and the third human feature node set C, obtain a first user graph set P = {P1, P2, ..., P i , ..., P I }, where the i-th first user graph P i Through A i , B i and C i Connect two by two to get; S3, connecting all first user graphs in the first user graph set P according to the first connection relationship data set G and the second connection relationship data set H to obtain a second user graph; S4, updating the node feature data of all the first human feature nodes, the second human feature nodes, and the third human feature nodes in the second user graph according to the first human feature data set α, the second human feature data set β, and the third human feature data set γ, and acquiring the third user graph corresponding to the target user; S5. According to the fourth connection relationship data set Y and the fifth connection relationship data set Z, all abnormal feature nodes in the abnormal feature node set E and all material nodes in the material node set F are added to the third user graph to obtain a target user graph.
4. The substance recommendation method based on node screening according to claim 3 is characterized in that: The first connection relationship data set G={G1, G2, . . . , G i , ..., G I }, G i = {G i1 , G i2 , ..., G iu(i) , ..., G iI }, G iu(i) A i and A u(i) The first connection relationship data is used to indicate whether there is a first connection line segment, the direction of the arrow of the first connection line segment, and the first preset category of the first connection line segment, S3 further includes the following steps: S311, get A i and A u(i) The first connection relationship data G between iu(i) = {GX iu(i) 1 , GX iu(i) 2 }, where GX iu(i) 1 =GX iu(i) 2 =0 means A i and A u(i) There is no first connecting line segment between GX iu(i) 1 =1 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A i Point to A u(i) , GX iu(i) 1 =2 means A i and A u(i) There is a first connecting line segment between them and the arrow points from A u(i) Point to A i , GX iu(i) 2 =ρ represents A i and A u(i) There exists a first connecting line segment and the category of the first connecting line segment is the ρth first preset category, ρ=1, 2, ..., μ, μ refers to the total number of the first preset category of the first connecting line segments; S312, if GX iu(i) 1 =GX iu(i) 2 = 0, then do not connect A i and A u(i) ; S313, if GX iu(i) 1 =1 and GX iu(i) 2 =ρ, then according to the direction of the arrow, i Point to A u(i) And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) ; S314, if GX iu(i) 1 =2 and GX iu(i) 2 =ρ, then according to the direction of the arrow, u(i) Point to A i And the first connecting line segment belonging to the pth first preset category connects A i and A u(i) .
5. The substance recommendation method based on node screening according to claim 4, characterized in that: The node path is obtained by the following steps: S101, for the i-th first human feature node A i , if G i1 1 =G i2 1 =……=G iu(i) 1 =……=G iI 1 ≠1, then A i Update to the first-level target node; S102, according to G i , will point to A i The first human feature node is updated to A i The corresponding second-level target node; S103, according to G, will point to A i The first human feature node of the corresponding ω-th level target node is updated to A i The corresponding ω+1th level target node, until A i The total number of corresponding ω+1th level target nodes is equal to 0, where ω is an integer greater than 1; S104, according to A i , A i The corresponding second-level target node, A i The corresponding third-level target node to A i The corresponding order of the ω-th level target nodes is obtained i The corresponding node pathway; S105, traverse the first human feature node set A to obtain all node paths.
6. The substance recommendation method based on node screening according to claim 5, characterized in that: S300 also includes the following steps: S301, for any first candidate node path, obtaining a level sequence number corresponding to each first abnormal human body feature node in the first candidate node path; S302: Determine the first abnormal human feature node corresponding to the smallest level sequence number in the first candidate node path as the second abnormal human feature node corresponding to the first candidate node path.
7. The substance recommendation method based on node screening according to claim 3, characterized in that: S400 also includes the following steps: S401, obtain the tth material node F t The second human feature node Z connected to t 1 ε and Z t 1 ε The first human feature node connected, Z t 1 ε The first human feature node connected is determined as F t The corresponding first reference human feature node; S402: For any second abnormal characteristic node, if the second abnormal characteristic node and F t The corresponding first reference human feature node is on the same node path, then the first level sequence number of the second abnormal feature node on the node path is obtained, and F t The second level sequence number of the corresponding first reference human feature node on the node path; S403, according to the first level sequence number and the second level sequence number, obtain the second abnormal feature node and F t The first node distance between them; S404, if the second abnormal feature node and F t If the corresponding first reference human feature node is not on the same node path, the preset node distance is determined as the distance between the second abnormal feature node and F t The first node distance between them.
8. The substance recommendation method based on node screening according to claim 1, characterized in that: The preset second score threshold is less than the preset first score threshold, S500 further includes the following steps: For any node pathway, if the enrichment score corresponding to the node pathway is greater than the preset first score threshold, or the enrichment score corresponding to the node pathway is less than the preset second score threshold, the node pathway is determined as the second candidate node pathway.
9. The substance recommendation method based on node screening according to claim 1, characterized in that: The preset second characteristic threshold is less than the preset first characteristic threshold, S700 further includes the following steps: For any target feature data, if the target feature data is greater than the preset first feature threshold, or the target feature data is less than the preset second feature threshold, the first human feature node corresponding to the target feature data is determined as the target human feature node.
10. The substance recommendation method based on node screening according to claim 1, characterized in that: S900 also includes the following steps: S901, screening out first recommended material nodes from all material nodes according to the first node distance and a preset first distance threshold, and acquiring a first recommended material node set; S902, screening out second recommended material nodes from all material nodes according to the second node distance and a preset first distance threshold, and acquiring a second recommended material node set; S903: Determine the intersection of the first recommended material node set and the second recommended material node set as the set corresponding to the target material node.
Citation Information
Patent Citations
Multimedia recommendation method and device
CN111414493A
Computer implemented method for the automated analysis or use of data
US20230136902A1