Business processing method and device, computer equipment, storage medium and program product

By using timestamp-based association storage of social relationship graphs and graph neural network prediction, the problem of inaccurate object evaluation in social networks in existing technologies is solved, thereby improving the accuracy of business processing.

CN120996960APending Publication Date: 2025-11-21GUANGZHOU TENCENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410635515.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-21
Publication Date
2025-11-21

AI Technical Summary

Technical Problem

In existing technologies, the technical problem with objects in social networks is that business evaluation is based solely on the object's own social characteristics, leading to inaccurate evaluations and affecting the accuracy of business processing.

Method used

By storing graph data in a social relationship graph in association with timestamps, querying subgraph data of social relationship subgraphs associated with objects, and using graph neural networks to predict business evaluation information.

Benefits of technology

This improved the accuracy of predicting business evaluation information for objects, thereby enhancing the accuracy of business processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120996960A_ABST
    Figure CN120996960A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a business processing method and device, computer equipment, a storage medium and a program product. The business processing method comprises the steps that when a business request for a first object in a social network is detected, request information is acquired, and the request information comprises a first timestamp for triggering the business request and an object identifier of the first object; the social network is represented by a social relation graph, and graph data of the social relation graph and timestamps are stored in an associated manner; querying sub-graph data of a social relation sub-graph associated with the first object from graph data of the social relation graph based on the request information; the timestamp associated with the sub-graph data is smaller than the first timestamp; predicting business evaluation information of the first object based on the sub-graph data; and performing business processing on the first object according to the business evaluation information. By adopting the embodiment of the invention, the prediction accuracy of the business evaluation information of the object can be improved, so that the business processing accuracy of the object can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, in particular to a business processing method, a business processing apparatus, a computer device, a computer readable storage medium, and a computer program product. BACKGROUND

[0002] In a social network, there is a demand for business evaluation of an object in the social network, and the business evaluation information of the object can guide the business processing of the object. For example, when the business evaluation information of the object indicates that the object is an illegal object, the social function of the object can be closed, so that the object cannot carry out social activities; for another example, when the business evaluation information of the object indicates that the object is a high-activity object, a high-activity label can be added to the object; and so on. At present, when the object in the social network is evaluated, some social features of the object are usually focused on, and only based on these social features, the object in the social network is evaluated, which will lead to inaccurate prediction of the business evaluation information of the object, thereby affecting the accuracy of the business processing of the object. SUMMARY

[0003] The embodiments of the present application provide a business processing method, apparatus, computer device, storage medium and program product, which can improve the prediction accuracy of the business evaluation information of the object, thereby improving the accuracy of the business processing of the object.

[0004] In one aspect, the embodiments of the present application provide a business processing method, which comprises:

[0005] When a business request for a first object in a social network is detected, request information is acquired, the request information comprising a first timestamp triggering the business request and an object identifier of the first object; the social network adopts a social relationship graph, the social relationship graph comprising nodes and edges, the nodes being used to represent objects in the social network, and the edges being used to connect two objects in the social network having a social relationship; graph data of the social relationship graph is stored in association with a timestamp;

[0006] Based on the request information, subgraph data of a social relationship subgraph associated with the first object is queried from the graph data of the social relationship graph; the timestamp associated with the subgraph data is less than the first timestamp;

[0007] Based on the subgraph data, business evaluation information of the first object is predicted;

[0008] According to the business evaluation information, the first object is processed.

[0009] Correspondingly, the embodiments of the present application provide a business processing apparatus, which comprises:

[0010] The acquisition unit is used to acquire request information when a business request for a first object in the social network is detected. The request information includes the first timestamp that triggered the business request and the object identifier of the first object. The social network is represented by a social relationship graph, which includes nodes and edges. Nodes represent objects in the social network, and edges connect two objects in the social network that have social relationships. The graph data of the social relationship graph is stored in association with the timestamp.

[0011] The processing unit is used to query the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph based on the request information; the timestamp associated with the subgraph data is less than the first timestamp;

[0012] The processing unit is also used to predict the business evaluation information of the first object based on the subgraph data;

[0013] The processing unit is also used to perform business processing on the first object based on the business evaluation information.

[0014] In one implementation, graph data is stored using edge data structures and vertex data structures;

[0015] The edge data structure is used to store the edge data corresponding to the edges in the social relationship graph. ij Used to connect the i-th object and the j-th object in a social network that have a first social relationship, with the i-th object being the starting point for establishing the first social relationship; edge ij The corresponding edge data includes the node identifier of the starting node, the node identifier of the ending node, the edge data timestamp, and the edge attribute information; where the i-th object corresponds to the starting node, the j-th object corresponds to the ending node, the edge data timestamp refers to the establishment time of the first social relationship, and the edge attribute information refers to the relationship characteristics of the first social relationship.

[0016] The point data structure is used to store the point data corresponding to the nodes in the social relationship graph. The i-th node in the social relationship graph is used to represent the i-th object in the social relationship network. The point data corresponding to the i-th node includes the node identifier of the i-th node, the point data timestamp, and the point attribute information. Among them, the point data timestamp refers to the time when the point attribute information is generated, and the point attribute information refers to the object characteristics of the i-th object at the point data timestamp.

[0017] In one implementation, the social relationship subgraph corresponds to the social subnetwork associated with the first object in the social network. The social subnetwork includes the first object and a second object that has a first-level or multi-level social relationship with the first object before the first timestamp. The social relationship subgraph includes nodes corresponding to each object in the social subnetwork and edges used to connect two objects with social relationships in the social subnetwork.

[0018] The processing unit is configured to, based on the request information, query, from the graph data of the social relationship graph, subgraph data of a social relationship subgraph associated with the first object, specifically configured to perform the following steps:

[0019] query, based on the object identifier of the first object, from the graph data, edge data corresponding to each edge in the social relationship subgraph before the first timestamp, to obtain a set of edge data;

[0020] query, from the graph data, point data corresponding to each node in the social relationship subgraph before the first timestamp, to obtain a set of point data;

[0021] determine the edge data in the set of edge data and the point data in the set of point data as the subgraph data.

[0022] In an implementation manner, the processing unit is configured to, when querying, based on the object identifier of the first object, from the graph data, edge data corresponding to each edge in the social relationship subgraph before the first timestamp to obtain a set of edge data, specifically configured to perform the following steps:

[0023] query, from the graph data, first-level edge data; the edge data in the first-level edge data has a timestamp smaller than the first timestamp, and a starting node in the first-level edge data has a node identifier corresponding to the object identifier of the first object;

[0024] query, from the graph data, second-level edge data; the edge data in the second-level edge data has a timestamp smaller than the first timestamp, and a starting node in the second-level edge data has a node identifier corresponding to a terminal node in the first-level edge data;

[0025] continue to query, from the graph data, third-level edge data until the query result is empty;

[0026] determine the edge data of each level as the edge data in the set of edge data.

[0027] In an implementation manner, during the process of querying, from the graph data, the first-level edge data, if there are multiple target edge data, the node identifiers of the starting nodes in the multiple target edge data are the same, the node identifiers of the terminal nodes in the multiple target edge data are the same, but the edge data timestamps of the multiple target edge data are different, the processing unit is further configured to perform the following steps:

[0028] add, to the first-level edge data, the edge data with the largest edge data timestamp in the multiple target edge data.

[0029] In an implementation manner, the processing unit is configured to, when querying, from the graph data, point data corresponding to each node in the social relationship subgraph before the first timestamp to obtain a set of point data, specifically configured to perform the following steps:

[0030] According to the node identifier in the edge data in the edge data set, the node identifier of each node in the social relationship subgraph is determined;

[0031] In the graph data, the point data whose point data timestamp is less than the first timestamp and whose node identifier is the node identifier of each node in the social relationship subgraph is obtained, to obtain the point data corresponding to each node in the social relationship subgraph;

[0032] The point data corresponding to each node in the social relationship subgraph is determined as the point data in the point data set.

[0033] In an implementation manner, the processing unit is configured to, based on the subgraph data, predict the business evaluation information of the first object, and specifically configured to perform the following steps:

[0034] The edge data in the edge data set and the point data in the point data set are converted into input information of the business processing model;

[0035] The business processing model is called to perform business prediction on the first object based on the input information, to obtain the business evaluation information of the first object.

[0036] In an implementation manner, each edge data in the edge data set corresponds to a respective level; and the processing unit is configured to, when converting the edge data in the edge data set and the point data in the point data set into input information of the business processing model, specifically configured to perform the following steps:

[0037] According to the edge data in the edge data set and the point data in the point data set, the node features of each node in the social relationship subgraph are determined;

[0038] According to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set, each edge data in the edge data set is sorted;

[0039] After sorting, the node features of each node in the social relationship subgraph are spliced according to the arrangement order of each edge data in the edge data set, to obtain the input information of the business processing model.

[0040] In an implementation manner, any node in the social relationship subgraph is represented as a target node; and the processing unit is configured to, when determining the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set, specifically configured to perform the following steps:

[0041] The point attribute information in the point data corresponding to the target node is determined as the first node feature of the target node;

[0042] Obtaining edge data corresponding to the target node, performing aggregation processing on the edge data corresponding to the target node, and obtaining a second node feature of the target node;

[0043] According to the first node feature and the second node feature, determining a node feature of the target node.

[0044] In an implementation manner, when the processing unit is used for sorting each edge data in the edge data set according to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set, the processing unit is specifically used for performing the following steps:

[0045] According to the level corresponding to each edge data in the edge data set, performing first sorting on each edge data in the edge data set;

[0046] For the edge data in the same level in the edge data set, performing second sorting on the edge data in the same level according to the node identifier of the starting node;

[0047] For the edge data with the same starting node in the edge data set, performing third sorting on the edge data with the same starting node according to the node identifier of the terminal node.

[0048] In an implementation manner, when the processing unit is used for splicing the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set to obtain the input information of the business processing model, the processing unit is specifically used for performing the following steps:

[0049] Determining the node feature of the first node representing the first object as the first input information;

[0050] According to the arrangement order of the edge data in each level, splicing the node features of the terminal nodes of the edge data in each level to obtain the level input information corresponding to each level;

[0051] Determining the first input information and the level input information corresponding to each level as the input information of the business processing model.

[0052] In an implementation manner, the business evaluation information of the first object is predicted by the business processing model; the processing unit is further used for performing the following steps:

[0053] Training the first business processing model under the first framework to obtain a second business processing model; the model format of the second business processing model is the first model format, and the first model format is a model format defined by the first framework;

[0054] Converting the model format of the second business processing model into a second model format to obtain a third business processing model, and the second model format is a model format defined by a second framework.

[0055] deploying the third business processing model under the second framework;

[0056] The processing unit is configured to invoke the third business processing model under the second framework to predict the business evaluation information of the first object based on the subgraph data.

[0057] In an implementation manner, the graph data includes offline graph data before a period start point of a current data statistical period and real-time graph data in the current data statistical period; the graph data is stored in a graph database; and an updating process of the graph data includes:

[0058] updating the offline graph data to the graph database when the period start point of the current data statistical period is reached;

[0059] updating the real-time graph data generated in the current data statistical period to the graph database.

[0060] Correspondingly, an embodiment of the present application provides a computer device, which comprises:

[0061] a processor adapted to implement a computer program;

[0062] a computer readable storage medium, the computer readable storage medium storing the computer program, the computer program being adapted to be loaded and executed by the processor to perform the business processing method.

[0063] Correspondingly, an embodiment of the present application provides a computer readable storage medium, the computer readable storage medium storing a computer program, the computer program being read and executed by a processor of a computer device to cause the computer device to perform the business processing method.

[0064] Correspondingly, an embodiment of the present application provides a computer program product, the computer program product comprising a computer program stored in a computer readable storage medium. The processor of the computer device reads the computer program from the computer readable storage medium, and the processor executes the computer program to cause the computer device to perform the business processing method.

[0065] In the embodiments of the present application, when a service request for a first object in a social network is detected, it can be indicated that there is a demand for service evaluation of the first object in the social network. The first object associated social relationship subgraph subgraph data can be queried from the graph data of the social relationship graph based on the request information of the service request, and the service evaluation information of the first object can be predicted based on the subgraph data. It can be seen that when predicting the service evaluation information of the object, not only the social characteristics of the object itself are considered, but also the subgraph data of the social relationship subgraph associated with the object. The subgraph data is more comprehensive than the social characteristics of the object itself, which can improve the prediction accuracy of the service evaluation information of the object, thereby improving the service processing accuracy of the object. Moreover, by associating and storing the graph data with the timestamp, the subgraph data with a timestamp less than the first timestamp triggering the service evaluation can be queried. The subgraph data with a timestamp less than the first timestamp can accurately reflect the characteristics of the object before triggering the service evaluation. The subgraph data with a timestamp greater than or equal to the first timestamp is irrelevant to the service evaluation. In this way, the subgraph data with a timestamp greater than or equal to the first timestamp can be avoided to affect the prediction accuracy of the service evaluation information, thereby further improving the prediction accuracy of the service evaluation information of the object and further improving the service processing accuracy of the object. BRIEF DESCRIPTION OF DRAWINGS

[0066] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed to be used in the embodiments or the prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0067] Figure 1 is an architecture schematic diagram of a service processing system provided by an embodiment of the present application;

[0068] Figure 2 is a training flow schematic diagram of model training provided by an embodiment of the present application;

[0069] Figure 3 is a reasoning flow schematic diagram of model reasoning provided by an embodiment of the present application;

[0070] Figure 4 is a flow schematic diagram of a service processing method provided by an embodiment of the present application;

[0071] Figure 5 is a schematic diagram of a social relationship subgraph provided by an embodiment of the present application;

[0072] Figure 6 is a flow schematic diagram of another service processing method provided by an embodiment of the present application;

[0073] Figure 7 is a hierarchical diagram of edge data provided by an embodiment of the present application;

[0074] Figure 8 is a division diagram of offline graph data and real-time graph data provided by an embodiment of the present application;

[0075] Figure 9 is a data reading logic diagram of a graph database provided by an embodiment of the present application;

[0076] Figure 10 is a structural diagram of a service processing device provided by an embodiment of the present application;

[0077] Figure 11 is a structural diagram of a computer device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0078] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of protection of the present application.

[0079] In order to make the technical solutions provided by the present application more clearly understood, the technical terms involved in the present application are introduced as follows:

[0080] I. Social network:

[0081] A social network refers to a network formed by objects and social relationships between two objects. The objects in the social network can be social groups or social accounts. A social account refers to a personal account in a social network, and a social group refers to a group account in which two or more social accounts participate.

[0082] The network form of a social network is diverse. For example, a social network can include a network form of "social group-social account-other social group". In detail, a first social account in a first social group adds a second social account to the first social group, and the first social account can be understood as a facilitator of the first social group, and the first social group and the first social account can have a social relationship; thereafter, the first social account adds a third social account to a second social group, and the first social account can be understood as a facilitator of the second social group, and the first social account and the second social group can have a social relationship. That is, a social network with a network form of "first social group-first social account-second social group" is formed.

[0083] For example, the social network can include a network form of "social account-social group-other social account". In detail, the first social account is added to the first social group, and the first social account and the first social group can have a social relationship, and the first social group also includes the second social account, and the first social group and the second social account can have a social relationship. That is, a social network with a network form of "first social account-first social group-second social account" is formed.

[0084] For another example, the social network can include a network form of "social account-other social account". In detail, the first social account adds the second social account as a friend, and the first social account and the second social account can have a social relationship (here, the social relationship refers to a friend relationship), and the second social account adds the third social account as a friend, and the second social account and the third social account can have a social relationship. That is, a social network with a network form of "first social account-second social account-third social account" is formed.

[0085] II. Social relationship graph

[0086] The social network can be represented in the form of a graph in the computer device, and the graph used to represent the social network can be referred to as a social relationship graph. The social relationship graph can include nodes and edges, and the nodes in the social relationship graph can be used to represent objects in the social network, and the edges in the social relationship graph can be used to connect two objects in the social network that have a social relationship. The graph data of the social relationship graph refers to data used to describe the nodes and edges in the social relationship graph, and the graph data of the social relationship graph can include point data corresponding to the nodes in the social relationship graph and edge data corresponding to the edges in the social relationship graph.

[0087] Based on the above introduction to the technical terms, the present application proposes a business processing method, which innovates the storage, query (or can be referred to as screening) and use of the graph data of the social relationship graph.

[0088] Specifically, the innovation of the graph data of the social relationship graph in storage can be specifically manifested as follows: the graph data of the social relationship graph (which can include offline graph data and real-time graph data) is stored in a graph database in a unified storage format, and the graph data is stored in association with a timestamp.

[0089] The innovation of the graph data of the social relationship graph on the query can be specifically manifested as follows: a graph database combined with an efficient query language can be adopted to support on-demand dynamic extraction of graph data, significantly reduce memory occupation and data preparation time, and improve data processing efficiency; and by introducing a timestamp filtering mechanism, it can be ensured that only the graph data before the triggering time point of the sample (the sample here refers to the object in the social network) is used for model training and reasoning to predict the business evaluation information of the sample, which can effectively avoid feature crossing (here, feature crossing refers to using the graph data after the triggering time point and the triggering time point for model training and reasoning, which is irrelevant to the prediction of business evaluation information, and will affect the prediction accuracy of business evaluation information in model training and reasoning), thereby improving the accuracy of model prediction.

[0090] The innovation of the graph data of the social relationship graph in the use mode can be specifically manifested as follows: a business processing model can be called to predict the business evaluation information of the object in the social network based on the sub-graph data of the object in the social network queried, so as to perform data processing on the object in the social network based on the business evaluation information.

[0091] The efficient query language may, for example, include the Cypher query language, which is a graph database query language introduced by the Neo4j graph database. It allows complex database operations to be performed through declarative syntax, and is particularly suitable for querying graph structure data. The graph database refers to a database for storing the graph data of the social relationship graph, and the graph database may, for example, include DGL (Deep Graph Library), which is an open-source Python library designed to provide a convenient interface and high-performance implementation for the research and application of graph neural networks.

[0092] In addition, the business processing model specifically refers to a GNN (Graph Neural Network) in the field of artificial intelligence (AI). The GNN is a deep learning model specifically designed to process graph data structures, which learns by utilizing information on the nodes and edges of the graph, and is suitable for fields such as social networks and molecular structures.

[0093] Artificial intelligence is the use of digital computers or digital computer-controlled machines to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology of computer science, which aims to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence is the design principle and implementation method of various intelligent machines, so that machines have the functions of perception, reasoning and decision-making.

[0094] Artificial intelligence technology is a comprehensive discipline involving a wide range of fields, both hardware and software technologies. Artificial intelligence basic technologies generally include, such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, pre-training model technology, operation / interaction system, mechatronics, etc. Among them, the pre-training model is also called large model, basic model, which can be widely applied to downstream tasks in various directions of artificial intelligence after fine-tuning. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning, etc.

[0095] It can be understood that the collection and processing of relevant data (for example, graph data in the present application) in the present application should strictly comply with the requirements of relevant national laws and regulations, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing behavior within the scope of authorization of laws and regulations and the personal information subject.

[0096] The business processing system is introduced below in conjunction with the drawings. The business processing system is suitable for implementing the business processing method.

[0097] As shown in Figure 1 The business processing system can include a business request front end 101 and a business service back end 102. The present application does not limit the communication connection mode between the business request front end 101 and the business service back end 102. The business request front end 101 and the business service back end 102 can establish a direct communication connection through wired communication, or the business request front end 101 and the business service back end 102 can establish an indirect communication connection through wireless communication. Figure 1 The business processing system shown in the figure takes the number of business request front ends 101 connected to the business service back end 102 as an example for illustration. In the implemented and running business processing system, the number of business request front ends 101 connected to the business service back end 102 can be one or more. The present application does not limit the number of business request front ends connected to the business service back end 102.

[0098] I. Business request front end 101:

[0099] The business request front end 101 can be a terminal running business client. The business client can include but is not limited to any of the following: business application program, business software, business applet, or business web application program. The terminal can be a smart phone, tablet computer, notebook computer, desktop computer, smart voice interaction device, smart watch, vehicle-mounted terminal, smart home appliance, aircraft, etc., but is not limited thereto.

[0100] II. Business service background 102

[0101] The business service background 102 can be a single physical server, a server cluster composed of multiple physical servers or a distributed system, and can also be a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and basic cloud computing services such as big data and artificial intelligence platforms.

[0102] The business service background 102 can include a graph database, a graph query module, a subgraph extraction module, an offline training module, and an online inference module. Among them: ① The graph database can be used to store graph data of a social relationship graph, and the graph data can include offline graph data and real-time graph data; the graph database can manage graph data according to a data statistical period (for example, the data statistical period can be one day); the graph database can also query graph data based on a given node identifier and a given timestamp, and return a graph query result. ② The graph query module can be used to send a graph query request to the graph database based on a given node identifier and a given timestamp, to request the graph database to query subgraph data associated with the given node identifier before the given timestamp, and to receive the graph query result returned by the graph database. ③ The subgraph extraction module can be used to call the graph query module. ④ The offline training module can be used to train a business processing model. ⑤ The online inference module can be used to call the trained business processing model for inference.

[0103] In the business processing system composed of the business request front end 101 and the business service background 102, the training process of the business processing model is as follows: Figure 2As shown, the inference process of the business processing model can include: (1) the subgraph extraction module obtains sample data, which can include the node identifier (sample ID) of the sample node corresponding to the sample object, the sample timestamp, and the sample label of the sample object. (2) The subgraph extraction module calls the graph query module, and the graph query module sends a graph query request to the graph database according to the node identifier and the sample timestamp of the sample node. (3) The graph database queries data based on the node identifier and the sample timestamp of the sample node, and returns the graph query result to the graph query module. The graph query result can include the first subgraph data associated with the sample node before the sample timestamp. (4) The graph query module can return the graph query result to the subgraph extraction module. (5) The subgraph extraction module can send the first subgraph data to the offline training module. (6) The offline training module can predict the label of the sample object based on the first subgraph data, and train the business processing model based on the difference between the predicted label of the business sample object and the sample label of the sample object. (7) After the training of the business processing model is completed, the offline training module can send the model file of the business processing model to the online inference module, and the online inference module can deploy the trained business processing model.

[0104] In a business processing system composed of a business request front end 101 and a business service back end 102, the inference process of the business processing model can include: Figure 3 (1) The business request front end 101 generates a business request in response to a triggering event of a first object in a social network (for example, the first object as a social group or a social account is reported, a social account is added or reduced in the first object as a social group, the first object as a social account is queried, etc.), and sends the business request to the business service back end 102. The request information of the business request can include the object identifier of the first object and the first timestamp of the triggering event. (2) The subgraph extraction module can obtain the request information and determine the node identifier of the first node corresponding to the first object in the social relationship subgraph. (3) The subgraph extraction module can call the graph query module, and the graph query module can send a graph query request to the graph database according to the node identifier and the first timestamp of the first node. (4) The graph database can query data based on the node identifier and the first timestamp of the first node, and return the graph query result to the subgraph extraction module. The graph query result can include the second subgraph data associated with the first node before the first timestamp. (5) The graph query module can return the graph query result to the subgraph extraction module. (6) The subgraph extraction module can send the second subgraph data to the online inference module. (7) The online inference module can predict the business evaluation information of the first object based on the second subgraph data, and perform business processing on the first object based on the business evaluation information of the first object.

[0105] Based on the above model training and model inference processes, it can be seen that the graph data stored in the graph database is common to the model training process and the inference process, and the storage format of the graph data is unified, so that the graph data stored in the graph database can be reused in model training and model inference. Moreover, the graph database uses a flexible and efficient query syntax for data query, realizing efficient storage and query of graph data and optimizing utilization of hardware resources.

[0106] It can be understood that the business processing system described in the embodiments of the present application is for more clearly illustrating the technical solutions of the embodiments of the present application, and does not constitute a limitation on the technical solutions provided by the embodiments of the present application. It can be known by those skilled in the art that, with the evolution of system architecture and the appearance of new business scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0107] The embodiments of the present application provide a business processing method. The content introduced by the business processing method includes a storage structure of graph data (edge data structure and point data structure) and a query method of graph data. The business processing method can be executed by a computer device, for example, can be a business service background 102 in the business processing system as shown. Figure 1 As shown in the business processing method can include but is not limited to the following steps S401-S404: Figure 4

[0108] S401, when detecting a business request for a first object in a social network, obtaining request information, the request information including a first timestamp triggering the business request and an object identifier of the first object; the social network adopts a social relationship graph representation; the graph data corresponding to the social relationship graph is stored in association with the timestamp.

[0109] The business request can be generated according to a triggering event for a first object in a social network. The first object can be a social group or a social account. When the first object is a social group, the triggering event for the first object can include any one of the following: an event that the first object is reported, an event that the first object is marked, an event that the group members in the first object change (for example, a social account is added or reduced), an event that a resource transfer portal (for example, a collection QR code) appears in the first object, and an event that resource transfer occurs in the first object, etc. When the first object is a social account, the triggering event for the first object can include any one of the following: an event that the first object is reported, an event that the first object is marked, an event that the first object joins a social group, an event that the first object exits from a social group, an event that the first object performs resource transfer, and an event that the first object is queried for object information (for example, active degree or object intimacy of the queried object), etc.

[0110] ​The request information for a business request may include the object identifier of the first object and the first timestamp that triggered the business request. Specifically, the first timestamp that triggered the business request may refer to the timestamp when a triggering event occurred for the first object. For example, the timestamp when the first object was reported, the timestamp when the group members of the first object changed, the timestamp when the first object joined a social group, or the timestamp when the first object left a social group, etc.

[0111] Social networks can be represented in computer devices using social relationship graphs. A social relationship graph includes nodes and edges. Nodes represent objects within the social network, and edges connect two objects with social relationships. Graph data refers to the data describing the nodes and edges in the social relationship graph. Nodes correspond to objects in the social network, and edges correspond to social relationships. Therefore, graph data can be understood as data describing the object characteristics of objects and the social relationships within the social network. Furthermore, graph data can be stored in association with timestamps. Timestamps can represent the time when object characteristics are generated or when social relationships are established within the social network. Graph data can be stored using edge data structures and vertex data structures, which are described below:

[0112] (1) Edge data structure:

[0113] Edge data structures can be used to store edge data corresponding to edges in a social relationship graph. (The text then repeats the example of edges in a social relationship graph.) ij For example, side ij It can be used to connect the i-th object and the j-th object in a social network that have a first social relationship, with the i-th object being the starting point for establishing the first social relationship; edge ij The corresponding edge data may include the node identifier of the starting node, the node identifier of the ending node, the edge data timestamp, and the edge attribute information; where the i-th object corresponds to the starting node, the j-th object corresponds to the ending node, the edge data timestamp refers to the establishment time of the first social relationship, and the edge attribute information refers to the relationship characteristics of the first social relationship.

[0114] Relationship characteristics refer to the quantitative values ​​of social relationships. For example, in a resource transfer relationship, the relationship characteristic could be the amount of resources transferred; similarly, in a social group and social account joining a social group, the relationship characteristic could be the time of joining the group; and so on.

[0115] side ijThe corresponding edge data can also include social relationship type information (RANK), which can be used to indicate the social relationship type of the first social relationship. In detail:

[0116] ① The format of the edge data adopts (start ID | end ID | timestamp | RANK | other edge attributes...). Among them, the start ID refers to the node identifier of the starting node, the end ID refers to the node identifier of the terminating node, the timestamp refers to the edge data timestamp, the RANK refers to the social relationship type information, and the other edge attributes refer to the edge attribute information. In the edge data, the start ID, end ID, timestamp and RANK are basic attributes, and the other edge attributes can exist or can not exist. Based on the format of the edge data, it is possible to support filtering social relationships at a specific time point or within a time range based on the timestamp, thereby enhancing the flexibility of data query.

[0117] ② The RANK value as a custom field can provide the ability to insert multiple edges between the same starting node and terminating node according to different social relationship types. For example, it can provide the ability to insert multiple edges according to different resource transfer types (different resource transfer types may include direct resource transfer, resource transfer through electronic resource packages, resource transfer through QR codes, etc.).

[0118] ③ The edge data storage can adopt a key-value (KV) storage mode. The key-value storage mode of the edge data refers to using the combination of (start ID | end ID | timestamp | RANK) as a unique key (key) and using (other edge attributes...) as the value (value) corresponding to the key to quickly obtain related edge data. Through the key-value storage mode, it is ensured that even between the same two nodes, multiple edge information can be distinguished and stored according to the RANK value, thereby increasing the flexibility and diversity of data storage.

[0119] (2) Point data structure:

[0120] The point data structure can be used to store the point data corresponding to the nodes in the social relationship graph. Taking the i-th node in the social relationship graph as an example, the i-th node in the social relationship graph can be used to represent the i-th object in the social relationship network; the point data corresponding to the i-th node can include the node identifier of the i-th node, the point data timestamp, and the point attribute information; wherein the point data timestamp refers to the time when the point attribute information is generated, and the point attribute information refers to the object characteristics of the i-th object at the point data timestamp. In detail:

[0121] The format of the point data adopts (point ID | timestamp | other point attributes...). Among them, the point ID refers to the node identifier, the timestamp refers to the point data timestamp, and the other point attributes refer to the point attribute information. Based on the format of the point data, it is allowed to query the point attribute information by time, thereby ensuring the real-time and historical consistency of the data.

[0122] Similar to edge data, point data can also adopt a key-value (KV) storage mode. The key-value storage mode of point data refers to taking a combination of (point ID | timestamp) as a unique key and taking (other point attributes...) as a value corresponding to the key, so as to facilitate quick retrieval of node information at a specific time point.

[0123] Based on the above content about the storage format of the graph data of the social relationship graph, the following introduces a data indexing mechanism, an identifier generation mechanism, and a timestamp processing mechanism of the graph data:

[0124] Data indexing mechanism: As described above, both point data and edge data adopt a key-value storage mode, and the point data and the edge data are stored in a key-value storage. The edge data can take a point ID (i.e., a node identifier of a starting node) as a primary index, and the point data can take a point ID (i.e., a node identifier) as a primary index, so as to achieve fast data retrieval and meet the query requirements on the graph data.

[0125] Identifier generation mechanism: As described above, the nodes in the social relationship graph correspond to objects in the social network, and the node identifier of a node can be determined according to the object identifier of the object corresponding to the node. The object identifier of an object can be, for example, a group identifier (e.g., a group id) of a social group or an account identifier (e.g., an account uin (account unique identifier)) of a social account. In one implementation manner, the object identifier of the object can be directly determined as the node identifier of the node. In another implementation manner, the type identifier of the object and the object identifier of the object can be spliced to obtain the node identifier of the node. The type identifier of the object can be used to identify that the type of the object is a social group or a social account. Specifically, after the type identifier of the object and the object identifier of the object are spliced, an integer value in an Int64 (64-bit integer data type) range is generated by using a hash algorithm, and is used as the node identifier. In this way, an efficient way is provided to identify each node in the social relationship graph, and the generation manners of the identifiers of the nodes in the social relationship graph are consistent.

[0126] Timestamp processing mechanism: As described above, the graph data of the social relationship graph can include offline graph data and real-time graph data, and the offline graph data and the real-time graph data can each include edge data and point data. For the offline graph data, each piece of data can be allowed to specify a timestamp value to represent the actual time (e.g., the establishment time of a social relationship, the generation time of point attribute information, etc.) at which the data occurs. For the real-time graph data, a timestamp at the time of writing can be automatically assigned, so as to ensure the timeliness and consistency of the data.

[0127] S402, based on the request information, query the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph; the timestamp associated with the subgraph data is less than the first timestamp.

[0128] After obtaining the request information of the business request, the subgraph data of the social relationship subgraph associated with the first object can be queried from the graph data of the social relationship graph based on the request information. The timestamp associated with the subgraph data is less than the first timestamp. Here, the social relationship subgraph can refer to the subgraph in the social relationship graph that corresponds to the social subnetwork of the first object in the social network. That is, the social relationship subgraph corresponds to the social subnetwork of the first object in the social network. The social subnetwork can include the first object and second objects that have one or more levels of social relationship with the first object before the first timestamp. The social relationship subgraph can include the nodes corresponding to each object in the social subnetwork and the edges used to connect the two objects with social relationship in the social subnetwork.

[0129] by Figure 5 For example, in the social relationship graph corresponding to the social network, the first object corresponds to the first node (node ​​A) in the social relationship graph. Subgraph 501 is the social relationship subgraph associated with the first object, which includes nodes A, B1, B2, C11, C12, C21, C22, and C23. Among them, the objects corresponding to nodes B1 and B2 are the second objects in the social network that have a first-level social relationship with the first object before the first time stamp; the objects corresponding to nodes C11, C12, C21, C22, and C23 are the second objects in the social network that have a second-level social relationship with the first object before the first time stamp.

[0130] S403, based on subgraph data, predict the business evaluation information of the first object.

[0131] After retrieving the subgraph data, the process of predicting the business evaluation information of the first object based on the subgraph data can include: converting the subgraph data into input information for a business processing model; and calling the business processing model to perform business prediction on the first object based on the input information to obtain the business evaluation information of the first object. The business processing model can be, for example, a GNN (Graph Neural Network).

[0132] The business evaluation information for the first object can refer to its business score. For example, regarding the business score of whether the first object is an illegal object, a higher business score indicates a higher probability that the first object is an illegal object. Similarly, regarding the activity score of the first object, a higher business score indicates a higher level of activity of the first object.

[0133] S404, Based on the business evaluation information, perform business processing on the first object.

[0134] After predicting the business evaluation information of the first object, business processing can be performed on the first object based on the business evaluation information. The business processing methods can include at least one of the following: adding tags, managing objects.

[0135] Regarding the method of adding tags, the process of performing business processing on the first object based on business evaluation information may include: determining target business tags that match the business evaluation information of the first object, and adding target business tags to the first object. For example, when the business evaluation information is about the activity rating of the first object, target activity tags that match the activity rating of the first object can be determined, and target activity tags can be added to the first object.

[0136] Regarding the management of objects, the process of handling the first object based on business evaluation information can include: managing the first object based on its business evaluation information. For example, if the business evaluation information of the first object is a business score regarding whether the first object is an illegal object, and the business score is greater than the score threshold, the first object can be determined to be an illegal object, and its social functions can be disabled to prevent it from engaging in social activities.

[0137] In this embodiment, the graph data storage structure (including edge data structure and vertex data structure) design, along with the graph data indexing mechanism, identifier generation mechanism, and timestamp processing mechanism, not only optimizes the graph data storage structure and improves the query efficiency and flexibility of graph data, but also ensures the real-time performance and consistency of data through a refined timestamp and node identifier generation mechanism, meeting the needs of efficient graph data processing. Furthermore, by storing graph data in association with timestamps, it is possible to query sub-graph data whose timestamps are less than the first timestamp that triggered the event. This avoids inaccurate predictions of the first object's business evaluation information due to the sub-graph data used for business evaluation containing future information (feature traversal); in other words, the timestamp-based query mechanism can improve the prediction accuracy of the first object's business evaluation information.

[0138] This application provides a business processing method, which includes: methods for querying edge data, methods for querying vertex data, and methods for converting subgraph data into input information. This business processing method can be executed by a computer device, such as... Figure 1 The business service backend 102 in the business processing system is shown. For example... Figure 6As shown, the business processing method can include, but is not limited to, the following steps S601-S605:

[0139] S601, when detecting a business request for a first object in a social network, obtaining request information, the request information including a first timestamp triggering the business request and an object identifier of the first object; the social network adopts a social relationship graph representation; graph data corresponding to the social relationship graph is stored in association with a timestamp.

[0140] In the embodiment of the application, the execution process of step S601 is the same as that of step S401 in the above Figure 4 The specific execution process of step S601 can refer to the related description of step S401 in the above Figure 4 embodiment, which will not be described here in detail.

[0141] S602, based on the request information, querying subgraph data of a social relationship subgraph associated with the first object from the graph data of the social relationship graph; the timestamp associated with the subgraph data is less than the first timestamp.

[0142] The subgraph data of the social relationship subgraph associated with the first object can include the following substeps s11-s13:

[0143] s11, based on the object identifier of the first object, querying the edge data corresponding to each edge in the social relationship subgraph before the first timestamp from the graph data to obtain an edge data set.

[0144] In substep s11, the query process of the edge data set can include: querying the first level edge data in the graph data; the edge data time stamp in the first level edge data is less than the first timestamp, and the node identifier of the starting node in the first level edge data is the node identifier corresponding to the object identifier of the first object; querying the second level edge data in the graph data; the edge data time stamp in the second level edge data is less than the first timestamp, and the node identifier of the starting node in the second level edge data is the node identifier of the terminal node in the first level edge data; continue to query the third level edge data in the graph data until the query result is empty; determine the edge data of each level queried as the edge data in the edge data set.

[0145] For example, the first level edge data includes edge data 1 and edge data 2, the second level edge data includes edge data 3 and edge data 4, and the third level edge data includes edge data 5. Figure 5For example, the edge data in the edge data set can include: edge data with a starting node of node A, a terminal node of node B1, and an edge data timestamp less than the first timestamp, which belongs to the first level of edge data; edge data with a starting node of node A, a terminal node of node B2, and an edge data timestamp less than the first timestamp, which belongs to the first level of edge data; edge data with a starting node of node B1, a terminal node of node C11, and an edge data timestamp less than the first timestamp, which belongs to the second level of edge data; edge data with a starting node of node B1, a terminal node of node C12, and an edge data timestamp less than the first timestamp, which belongs to the second level of edge data; edge data with a starting node of node B2, a terminal node of node C21, and an edge data timestamp less than the first timestamp, which belongs to the second level of edge data; edge data with a starting node of node B2, a terminal node of node C22, and an edge data timestamp less than the first timestamp, which belongs to the second level of edge data; and edge data with a starting node of node B2, a terminal node of node C23, and an edge data timestamp less than the first timestamp, which belongs to the second level of edge data.

[0146] In addition, in the reading logic of the graph data, the keys of multiple data are the same except the timestamp, but the timestamps are different; for example, the keys of the edge data are the same (start ID | end ID | RANK), but the edge data timestamps are different; for another example, the keys of the point data are the same (start ID), but the point data timestamps are different. If a specific timestamp is not specified, the data entry with the largest timestamp (i.e., the latest) can be read by default. If a specific timestamp t0 is specified, the data with the largest timestamp (i.e., closest to t0) among the data entries with timestamps less than t0 can be returned.

[0147] That is, taking the process of querying the first level of edge data as an example, in the process of querying the first level of edge data in the graph data, if there are multiple target edge data, the node identifiers of the starting nodes in the multiple target edge data are the same, the node identifiers of the terminal nodes in the multiple target edge data are the same (if there is social relationship type information (RANK), the values of RANK are also the same), but the edge data timestamps of the multiple target edge data are different. Then in this case, the edge data with the largest edge data timestamp in the multiple target edge data can be added to the first level of edge data. Through the reading logic of the edge data, the latest edge data can be read, which can reflect the latest social relationship between the social objects in the first object associated social sub-network before the first timestamp, and can improve the prediction accuracy of the business evaluation information of the first object.

[0148] s12, query the point data corresponding to each node in the social relationship subgraph before the first timestamp in the graph data, and obtain the point data set.

[0149] The process of querying point data may include: determining the node identifier of each node in the social relationship subgraph based on the node identifier in the edge data in the edge data set; querying point data in the graph data whose point data timestamp is less than the first timestamp and whose node identifier is the node identifier of each node in the social relationship subgraph, thereby obtaining the point data corresponding to each node in the social relationship subgraph; and determining the point data corresponding to each node in the social relationship subgraph as the point data in the point data set.

[0150] by Figure 5 For example, the point data in the point data set can include the point data corresponding to node A, the point data corresponding to node B1, the point data corresponding to node B2, the point data corresponding to node C12, the point data corresponding to node C21, the point data corresponding to node C22, and the point data corresponding to node C23.

[0151] Similarly, the point data query process follows the same logic as the graph data reading process described above. During the point data query, if multiple point data points exist for the same node with timestamps smaller than the first timestamp and with different timestamps, the point data point with the largest timestamp can be included in the point data set. This point data reading logic ensures that the latest point data is retrieved. The latest point data reflects the latest social characteristics of each object in the social sub-network (i.e., the first object or a second object with a social relationship with the first object) before the first timestamp, thus improving the accuracy of predicting the business evaluation information of the first object.

[0152] s13, determine the edge data in the edge data set and the point data in the point data set as subgraph data.

[0153] After retrieving the edge data from the edge data set and the vertex data from the vertex data set, the edge data from the edge data set and the vertex data from the vertex data set can be identified as subgraph data.

[0154] S603 converts subgraph data into input information for the business processing model.

[0155] Subgraph data can include edge data from the edge dataset and vertex data from the vertex dataset. The edge data from the edge dataset and the vertex data from the vertex dataset can be converted into input information for the business processing model.

[0156] Before introducing the conversion process of the subgraph data, the hierarchical concept of the edge data is introduced first. The hierarchical corresponding to the edge data can be used to indicate the order of establishment of the social relationship corresponding to the edge data. The social relationship corresponding to the edge data with a lower hierarchical is established earlier, and the social relationship corresponding to the edge data with a higher hierarchical is established later. For example, in the process of finding the first puller in the first social group through the first social group, and then finding the second social group through the first puller, there are two social relationships, the social relationship between the first social group and the first puller, and the social relationship between the first puller and the second social group. The social relationship between the first social group and the first puller is established earlier, and the social relationship between the first puller and the second social group is established later. The hierarchical of the edge data corresponding to the social relationship between the first puller and the second social group is lower than the hierarchical of the edge data corresponding to the social relationship between the first social group and the first puller. For another example, in the process of finding the second social group through the second puller in the second social group through the first puller in the first social group, there are two social relationships, the social relationship between the first social group and the first puller, and the social relationship between the first puller and the second social group. The social relationship between the first puller and the second social group is established earlier, and the social relationship between the first social group and the first puller is established later. The hierarchical of the edge data corresponding to the social relationship between the first social group and the first puller is lower than the hierarchical of the edge data corresponding to the social relationship between the first puller and the second social group. Figure 7 In the above example, the edge data corresponding to edge AB1 and the edge data corresponding to edge AB2 are both first hierarchical, and the edge data corresponding to edge B1C11, the edge data corresponding to edge B1C12, the edge data corresponding to edge B2C21, the edge data corresponding to edge B2C22, and the edge data corresponding to edge B2C23 are all second hierarchical.

[0157] Based on the hierarchical concept of the edge data, each edge data in the edge data set can correspond to a respective hierarchical, and the conversion process of the subgraph data can include the following sub-steps s21-s23:

[0158] s21, according to the edge data in the edge data set and the point data in the point data set, determining the node features of each node in the social relationship subgraph.

[0159] Here, taking any node in the social relationship subgraph as an example, the determination process of the node features is introduced. Any node in the social relationship subgraph can be represented as a target node, and the determination process of the node features of the target node can include: determining the point attribute information in the point data corresponding to the target node as the first node feature of the target node; obtaining the edge data corresponding to the target node, and performing aggregation processing on the edge data corresponding to the target node to obtain the second node feature of the target node; and determining the node features of the target node according to the first node feature and the second node feature.

[0160] Among them, performing aggregation processing on the edge data corresponding to the target node to obtain the second node feature of the target node can include any one of the following:

[0161] The first kind is the aggregation processing of the number of edges. According to the edge data corresponding to the target node, the edges connected with the target node can be determined, and the number of edges connected with the target node can be aggregated to obtain the second node feature of the target node. The aggregation of the number of edges connected with the target node specifically refers to the accumulation of the number of edges connected with the target node. For example, the object corresponding to the target node is a hand, and each edge connected with the target node connects each group pulled by the hand. By aggregating the number of edges connected with the target node, the total number of groups pulled by the hand can be determined, and the total number of groups can be determined as the second node feature of the target node.

[0162] The second kind is the aggregation processing of edge features. According to the edge data corresponding to the target node, the relationship features of the social relationships corresponding to the edges connected with the target node can be determined, and the relationship features of the social relationships corresponding to the edges connected with the target node can be aggregated to obtain the second node feature of the target node. The aggregation of the relationship features of the social relationships corresponding to the edges connected with the target node specifically refers to the accumulation of the relationship features of the social relationships corresponding to the edges connected with the target node. For example, each edge connected with the target node represents a resource transfer-in relationship of the target node, and the relationship feature of the resource transfer-in relationship is the resource transfer-in amount. By aggregating the relationship features of the social relationships corresponding to the edges connected with the target node, the total resource amount to the target node can be determined, and the total resource amount can be determined as the second feature of the target node.

[0163] That is, the node feature of the target node can include the point attribute information in the point data of the target node as a feature, and the aggregation feature obtained by aggregating the edge data associated with the target node.

[0164] s22, according to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set, sorting each edge data in the edge data set.

[0165] The sorting process of each edge data in the edge data set can include: first sorting each edge data in the edge data set according to the level corresponding to each edge data in the edge data set; for the edge data in the edge data set at the same level, second sorting the edge data at the same level according to the node identifier of the starting node; for the edge data in the edge data set with the same starting node, third sorting the edge data with the same starting node according to the node identifier of the terminal node. Wherein, the first sorting, the second sorting and the third sorting can be ascending (ASC) or descending (DESC).

[0166] S23, after sorting, splicing the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set, to obtain the input information of the business processing model.

[0167] The splicing process of the node features of each node in the social relationship subgraph can include: determining the node features of the first node representing the first object as the first input information; splicing the node features of the terminal nodes of the edge data in each level according to the arrangement order of the edge data in each level to obtain the level input information corresponding to each level; and determining the first input information and the level input information corresponding to each level as the input information of the business processing model.

[0168] Based on the above splicing process, it can be seen that, in addition to directly determining the node features of the first node as the first input information, the edge data of each level determines a level input information, and then the first input information and the level input information corresponding to each level can be determined as the input information of the business processing model. The form of the input information can be a matrix. The purpose of sorting the node features of the nodes before splicing is to make the nodes adjacent to each other on the edges corresponding to the same starting node adjacent to each other in the matrix.

[0169] S604, calling the business processing model to perform business prediction on the first object based on the input information, to obtain business evaluation information of the first object.

[0170] After converting the edge data in the edge data set and the point data in the point data set into the input information of the business processing model, the business processing model can be called to perform business prediction on the first object based on the input information, to obtain the model score (i.e. business score) of the first object. The model score of the first object can be determined as the business evaluation information of the first object.

[0171] S605, performing business processing on the first object according to the business evaluation information.

[0172] In the embodiments of the present application, the execution process of step S605 is the same as the execution process of step S404 in the above-mentioned Figure 4 embodiment. The specific execution process of step S605 can be referred to the related description of step S404 in the above-mentioned Figure 4 embodiment, which will not be repeated here.

[0173] In the embodiments of the present application, a timestamp screening mechanism is introduced, and the post-data (post-data refers to data generated after the sample labeling time) is filtered in combination with the sample labeling time (i.e., the generation time of the trigger event), which effectively avoids the feature crossing problem and improves the prediction accuracy and generalization ability of the business processing model in the actual business scenario. In addition, based on the way of converting the queried edge data and point data into the input matrix of the business processing model, different scales and types of graph data processing requirements can be standardized into general matrix and vector data formats, which can adapt to various graph neural network models and tasks.

[0174] The above Figure 4 and Figure 6 The embodiments shown introduce the real-time prediction logic of the business processing model in the inference process. Based on the real-time prediction logic, the following introduces a real-time prediction instance of the business processing model. The real-time prediction instance can include the flow of graph data query, the flow of model input information generation, and the flow of model prediction business evaluation information. Among them:

[0175] (1) The flow of graph data query:

[0176] First, the object identifier and the first timestamp (ts) of the first object corresponding to the trigger event can be obtained, and the node identifier (input_id) of the first node corresponding to the first object can be determined according to the object identifier of the first object.

[0177] Second, the Cypher MATCH syntax can be used in combination with the node identifier (input_id) of the first node and the first timestamp (ts) to dynamically extract the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph. For example, the statement "MATCH(x)-[e:edge where e.timestamp<ts]->(y)-[...]->(z) where id(x)=input_id with..." can be used to obtain the edge data E of the social relationship subgraph. The edge data E can be represented as: [(src_id_0,dst_id_0,layer_idx),...], where src_id_0 represents the node identifier of the starting node, dst_id_0 represents the node identifier of the terminal node, and layer_idx represents the level corresponding to the edge data. In addition, the queried edge data can be sorted according to the order of layer_idx ASC, src_id_0 ASC, and dst_id_0 ASC, and ASC represents ascending order.

[0178] Then, the point data and the graph features at the first timestamp (ts) can be obtained by using the WITH statement and the MATCH statement of Cypher in combination with the first timestamp (ts), to obtain node data F in the social relationship subgraph. The node data F can include node features of each node in the social relationship subgraph, and the node data F can be represented as: [(id_0, feat_1, feat_2,...),...], where id_0 represents a node identifier, and feat represents a node feature.

[0179] Then, a string S containing a subgraph structure of the social relationship subgraph and node features of each node in the social relationship subgraph can be obtained by splicing the edge data E and the feature data F, and the string S is convenient for transmission between modules.

[0180] (2) The flow of generating model input information:

[0181] Considering the performance requirements (for example, high QPS (Queries Per Second, one of the indicators for measuring the request processing capability of a system, commonly used to evaluate the performance of a database, server or network service), low latency), C++ (another programming language) can be selected as the development language. In C++, the same feature processing logic is usually more complex and more difficult to debug than languages such as Python, but under our design scheme, only simple processing of the string S is required to generate the data required for reasoning. In this process, we use the Numpy library (an open source scientific computing library) of C++ to read the string S, according to the layer_idx in the edge data E, for each node in the layer, according to the edge data order, using the node features in the feature data F to organize a matrix, to ensure that the features of adjacent nodes on the multiple edges corresponding to the same src_id are row adjacent in the matrix. The composed matrix can be used as the input information of the business processing model.

[0182] (3) The flow of model predicting business evaluation information:

[0183] The online inference model parses the string S, which can organize the data in the string S into a matrix object available to C++ (i.e., the input information of the business processing model), and pass it to the C++ runtime of ONNX (an inference framework). Then, the business processing model can calculate the input information to obtain the model score (i.e., the business evaluation information of the first object), and also obtain other auxiliary information (for example, the embedding vector of the first object). Then, the first object can be processed according to the business evaluation information of the first object. Wherein, the C++ runtime of ONNX (i.e., the C++ runtime) is an open source engine for optimizing the execution of machine learning models, which supports multiple hardware platforms and deep learning frameworks, and can improve the efficiency of model inference.

[0184] In combination with the real-time prediction instance of the above business processing model, it can be seen that accessing real-time data and using Cypher queries can achieve efficient on-demand access to real-time graph data. This mechanism not only supports high query per second (QPS) and low latency requirements, but also enables rapid iteration and adjustment of graph association and feature calculation logic in a high-adversarial environment.

[0185] It should be noted that in the embodiments of the present application, the training phase of the business processing model and the inference phase of the business processing model use different frameworks. Specifically, the first business processing model can be trained in the first framework to obtain the second business processing model; the model format of the second business processing model is the first model format, and the first model format is the model format defined by the first framework; the first framework is a model training framework. Then, the model format of the second business processing model can be converted to the second model format to obtain the third business processing model, and the second model format is the model format defined by the second framework. Then, the third business processing model can be deployed in the second framework, and the second framework is a model inference framework. On this basis, when predicting the business evaluation information of the first object based on the subgraph data, the third business processing model can be called in the second framework to predict the business evaluation information of the first object based on the subgraph data.

[0186] In detail, in the offline model training process, the sample data we use can include the node identifier (sample ID) of the sample node corresponding to the sample object, the sample timestamp and the sample label. Based on the node identifier and the sample timestamp of the sample node, a string S' can be obtained, which can include the subgraph structure of the social relationship subgraph associated with the sample node, and the node features of each node in the social relationship subgraph associated with the sample node. Each sample data corresponds to a string S', and these data can be saved to a hard disk file, with each row corresponding to a sample data.

[0187] During offline training, the string S' of each row of the hard disk file can be parsed into a matrix object available to PyTorch (i.e., the first framework) in a Python environment for model training. After training, we use the Python library of ONNX (i.e., the second framework) to generate an ONNX format model for use in the C++ version of the ONNX framework, realizing the cross-platform transfer of the model. This method ensures the lowest cost of data conversion during training and deployment, while maintaining excellent cross-platform consistency.

[0188] In the embodiments of the present application, the offline training and online inference data formats are unified, which means that the data format used remains consistent whether in the model training phase (usually offline environment) or in the model inference phase in actual application (usually online environment). Generally, offline training and online inference may use different technical frameworks, which have different requirements for data formats and processing methods. Taking a graph neural network as an example, offline training may use a library such as PyTorch Geometric (PyG), which provides specific data structure support. However, this data structure may not be compatible with the ONNX framework used for online inference. If the trained model is directly used for online inference, it may be necessary to convert the model from PyTorch to ONNX format, which may encounter problems such as data structure mismatch and model logic inconsistency during the conversion process. In addition, online inference also needs to convert the data structure used during offline training into a format suitable for online inference, which not only increases the deployment cost, but also may introduce consistency problems. By unifying the data formats of offline training and online inference, the need for data and model conversion can be eliminated, thereby reducing the complexity and operation and maintenance cost of the system, improving the efficiency and stability of model deployment. This unified processing also helps to speed up the iteration of business and the online process of models. That is, the innovative batch subgraph feature data structure and its processing logic in the embodiments of the present application realize the unification of offline training and online inference data formats, significantly improving the data level alignment efficiency of large-scale graph data training process and inference link, and simplifying the deployment and online process of new GNN models. Moreover, by using a cross-platform machine learning inference accelerator, it can be widely applied to online business, broadening the application prospects.

[0189] It should be noted that the graph data can be synchronized and updated to the graph database according to the data statistical period, and the offline graph data and real-time graph data in the graph data can be divided according to the starting point of the data statistical period. The embodiments of the present application take one day as the data statistical period, and 0 o'clock every day as the starting point of the data statistical period as an example to illustrate the synchronization and update of the graph data, and the division of the offline graph data and the real-time graph data.

[0190] AsFigure 8 As shown, the graph data in the offline graph data and the real-time graph data can be divided according to the cycle start point of the data statistical cycle. The graph data before the cycle start point (the timestamp ts corresponding to the cycle start point) of the current data statistical cycle is the invalidated real-time graph data (that is, the offline graph data), and the graph data generated after the cycle start point of the current data statistical cycle is the validated real-time graph data (that is, the real-time graph data). When the cycle start point of the current data statistical cycle is reached, the offline graph data of the current data statistical cycle can be determined, and the offline graph data can be updated into the graph database when the cycle start point of the current data statistical cycle is reached. The real-time graph data generated in the current data statistical cycle is updated into the graph database.

[0191] The graph database stores graph data in a distributed manner. The process of updating the offline graph data into the graph database when the cycle start point of the current data statistical cycle is reached can include:

[0192] T can represent the current data statistical cycle, and T+1 data (also referred to as offline graph data) refers to all graph data before 0 o'clock of the current data statistical cycle (for example, T day). Such data is often used in business scenarios, for example, 90-day object data (for example, greeting information when adding friends) and full-amount relationship data (for example, friend relationships between objects). In business scenarios, the data volume of such data is huge, reaching hundreds of billions to several hundred billions.

[0193] The offline data part is usually stored on a storage facility with lower cost, for example, stored in a mechanical hard disk cluster in Hive table (Hive table is a data warehouse tool) format. Through Spark (that is, a mechanical hard disk cluster), a configured SQL statement can be run to perform entry filtering and field selection (for example, it can be configured which point attribute information is stored as point attribute information in the point data into the graph database, and which social relationship type of social relationship corresponds to the edge stored in the graph database), to obtain the T+1 data required by the graph data table. Next, the Spark cluster sorts and serializes the data, saves it as a format required by KV storage, and uploads it to HDFS (Hadoop Distributed File System).

[0194] The KV storage of the graph database (using high-performance servers and high-speed SSD (Solid State Disk or Solid State Drive)) loads the prepared T+1 data file from the HDFS, and replaces the data in the graph database before 0 o'clock of the day (T day). The synchronization and update of the offline graph data are realized.

[0195] After introducing the update process of offline graph data, the update process of real-time graph data is introduced below. The process of updating the real-time graph data generated in the current data statistics period to the graph database can include:

[0196] The real-time graph data reported by the front section of the business request first appears on a distributed message stream platform such as Pulsar, Kafka, etc. By using the Flink (Flink is an open source stream processing framework for real-time data processing, which can process continuous data streams and support the concepts of event time and processing time, suitable for real-time data analysis and processing) framework, the real-time message stream is filtered and processed, and then arranged into the format required by the point data table or the edge data table. The processed data is reported to the Pulsar topic dedicated to the real-time data of the graph database.

[0197] Using the message queue (MQ) module on the line, the system continuously reads the data in the Pulsar topic, assembles multiple data into batches, and then sends them to the graph database in batches, and uses the insert statement supported by the graph database to write data into the graph database. The written data is first saved in the memory-KV storage matched with the graph database, and every half hour, the data will sink from the memory-KV to the SSD-KV storage. Whether the data is in the memory-KV or the SSD-KV, it can be accessed by the graph query. This "temporary storage-sinking" operation aims to balance the memory usage of the memory-KV and the write IO performance of the SSD-KV, and optimize performance and resource utilization.

[0198] Moreover, whether it is real-time graph data or offline graph data in the graph database, the default reading logic of the graph data in the graph database is the same: as shown in Figure 9 The key information of multiple data is the same except for the timestamp, but the timestamps are different; for example, the key of the edge data (start ID | end ID | RANK) is the same, but the edge data timestamp is different; for example, the key of the point data (start ID) is the same, but the point data timestamp is different. If a specific timestamp t0 is not specified, the data entry with the largest (i.e. the latest) timestamp can be read by default. If a specific timestamp t0 is specified, the data with the largest (i.e. closest to t0) timestamp among the data entries with timestamps less than t0 can be returned.

[0199] The specific application scenarios of the business processing method are introduced below. The business processing method can be applied in any of the following business scenarios: illegal social group reporting scenario, malicious account marking scenario, and active account query scenario, etc. Among them:

[0200] (1) Illegal social group reporting scenario:

[0201] In the illegal social group reporting scenario, the network form of the social network is "social group-pull hand-other social group", the pull hand is a group member who pulls a new group member into the social group, and the social group and the social account are both objects in the social network. If the social group 1 in the social network is reported, the group relationship data before the time point t1 can be extracted by using the time point t1 when the social group 1 is reported and the group identifier of the social group 1, and the relationship chain of "social group 1-pull hand-other social group" is formed. By obtaining the social relationship subgraph before the time point t1 and the node features of each node in the social relationship subgraph, and converting the social relationship subgraph before the time point t1 and the node features of each node in the social relationship subgraph into input information of the GNN model, the GNN model can be used to process the input information to predict the business score of whether the social group 1 is an illegal social group. If the business score is greater than the score threshold, it can be determined that the social group 1 is an illegal group, and if the business score is less than or equal to the score threshold, it can be determined that the social group 1 is not an illegal group.

[0202] (2) Malicious account marking scenario:

[0203] In the malicious account marking scenario, the network form of the social network is "social account-social group-other social account", and the malicious account enters each social group to publish malicious information. The social group and the social account are both objects in the social network. If the social account 1 in the social network is marked as a malicious account, the group relationship data before the time point t2 can be extracted by using the time point t2 when the social account 1 is marked and the account identifier of the social account 1, and the relationship chain of "social account 1-social group-other social account" is formed. By obtaining the social relationship subgraph before the time point t2 and the node features of each node in the social relationship subgraph, and converting the social relationship subgraph before the time point t2 and the node features of each node in the social relationship subgraph into input information of the GNN model, the GNN model can be used to process the input information to predict the business score of whether the social account 1 is a malicious account. If the business score is greater than the score threshold, it can be determined that the social group 1 is a malicious account, and if the business score is less than or equal to the score threshold, it can be determined that the social account 1 is not a malicious account, and the malicious label of the social account 1 can be removed.

[0204] (3) Active account query scenario:

[0205] In the active account query scenario, the network form of the social network is "social account-other social account", and the social accounts can establish a social relationship through adding friends, chatting, sending gifts, resource transfer and the like. In this scenario, the objects in the social network can all be social accounts. If the social account 2 in the social network is queried for the activity level, the time point t3 at which the social account 2 is queried and the account identifier of the social account 2 can be used to extract the in-group relationship data before the time point t3, to form a relationship chain of "social account 2-other social account". By obtaining the social relationship subgraph before the time point t3 and the node features of each node in the social relationship subgraph, and converting the social relationship subgraph before the time point t3 and the node features of each node in the social relationship subgraph into input information of the GNN model, the GNN model can be used to process the input information to predict the business score of the social account 2 on the activity level. The activity level of the social account 2 can be determined according to the business score of the social account 2 on the activity level, and the activity level of the social account 2 can be returned as a query result.

[0206] The above describes the method of the embodiments of the present application in detail. In order to better implement the above-mentioned scheme of the embodiments of the present application, the device of the embodiments of the present application is provided as follows.

[0207] Please refer to Figure 10 , Figure 10 is a structural schematic diagram of a business processing device provided by the embodiments of the present application. The business processing device can be arranged in the computer device provided by the embodiments of the present application. The computer device can be the business service background 102 in the business processing system shown in Figure 1 . The business processing device shown in Figure 10 may be a computer program running in the computer device. The device can be used to execute part or all of the steps in the method embodiments shown in Figure 4 or Figure 6 . Please refer to Figure 10 . The business processing device can include the following units:

[0208] The obtaining unit 1001 is configured to, when detecting a business request for a first object in a social network, obtain request information, the request information including a first timestamp triggering the business request and an object identifier of the first object; the social network adopts a social relationship graph, the social relationship graph including nodes and edges, the nodes being used to represent objects in the social network, and the edges being used to connect two objects in the social network having a social relationship; graph data of the social relationship graph is stored in association with a timestamp;

[0209] The processing unit 1002 is configured to, based on the request information, query subgraph data of a social relationship subgraph associated with the first object from the graph data of the social relationship graph; the timestamp associated with the subgraph data is less than the first timestamp;

[0210] The processing unit 1002 is further configured to predict the service evaluation information of the first object based on the subgraph data.

[0211] The processing unit 1002 is further configured to perform service processing on the first object according to the service evaluation information.

[0212] In an implementation manner, the graph data is stored in an edge data structure and a point data structure.

[0213] The edge data structure is used to store edge data corresponding to an edge in a social relationship graph, and the edge in the social relationship graph is used to connect an i-th object and a j-th object having a first social relationship in a social network, and the establishment of the first social relationship is started from the i-th object. ij The edge data structure is used to store edge data corresponding to an edge in a social relationship graph, and the edge in the social relationship graph is used to connect an i-th object and a j-th object having a first social relationship in a social network, and the establishment of the first social relationship is started from the i-th object. ij The corresponding edge data includes a node identifier of a starting node, a node identifier of a terminal node, an edge data timestamp, and edge attribute information; wherein the i-th object corresponds to the starting node, the j-th object corresponds to the terminal node, the edge data timestamp refers to the establishment time of the first social relationship, and the edge attribute information refers to the relationship characteristics of the first social relationship.

[0214] The point data structure is used to store point data corresponding to a node in a social relationship graph, and the i-th node in the social relationship graph is used to represent the i-th object in the social relationship network; the point data corresponding to the i-th node includes a node identifier of the i-th node, a point data timestamp, and point attribute information; wherein the point data timestamp refers to the time when the point attribute information is generated, and the point attribute information refers to the object characteristics of the i-th object at the point data timestamp.

[0215] In an implementation manner, the social relationship subgraph corresponds to a social subnetwork associated with the first object in the social network, and the social subnetwork includes the first object and a second object having a one-level or multi-level social relationship with the first object before a first timestamp; the social relationship subgraph includes nodes corresponding to each object in the social subnetwork and edges used to connect two objects having a social relationship in the social subnetwork.

[0216] The processing unit 1002 is configured to, when querying the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph based on the request information, specifically perform the following steps:

[0217] Based on the object identifier of the first object, the edge data corresponding to each edge in the social relationship subgraph before the first timestamp is queried in the graph data to obtain an edge data set;

[0218] The point data corresponding to each node in the social relationship subgraph before the first timestamp is queried in the graph data to obtain a point data set;

[0219] The edge data in the edge data set and the point data in the point data set are determined as subgraph data.

[0220] In an implementation manner, the processing unit 1002 is configured to, when querying the edge data corresponding to each edge in the social relationship subgraph before the first timestamp in the graph data to obtain the edge data set based on the object identifier of the first object, specifically perform the following steps:

[0221] querying the edge data of the first level in the graph data; the edge data in the edge data of the first level has an edge data timestamp smaller than the first timestamp, and a starting node in the edge data of the first level has a node identifier corresponding to the object identifier of the first object;

[0222] querying the edge data of the second level in the graph data; the edge data in the edge data of the second level has an edge data timestamp smaller than the first timestamp, and a starting node in the edge data of the second level has a node identifier corresponding to the node identifier of the terminal node in the edge data of the first level;

[0223] continuing to query the edge data of the third level in the graph data until the query result is empty;

[0224] determining the edge data of each level as the edge data in the edge data set.

[0225] In an implementation manner, during the process of querying the edge data of the first level in the graph data, if there are multiple target edge data, the node identifiers of the starting nodes in the multiple target edge data are the same, the node identifiers of the terminal nodes in the multiple target edge data are the same, but the edge data timestamps of the multiple target edge data are different, the processing unit 1002 is further configured to perform the following steps:

[0226] adding the edge data with the largest edge data timestamp in the multiple target edge data to the edge data of the first level.

[0227] In an implementation manner, the processing unit 1002 is configured to, when querying the point data corresponding to each node in the social relationship subgraph before the first timestamp in the graph data to obtain the point data set, specifically perform the following steps:

[0228] determining the node identifier of each node in the social relationship subgraph according to the node identifier in the edge data in the edge data set;

[0229] querying the point data with a point data timestamp smaller than the first timestamp and a node identifier corresponding to each node in the social relationship subgraph in the graph data to obtain the point data corresponding to each node in the social relationship subgraph;

[0230] determining the point data corresponding to each node in the social relationship subgraph as the point data in the point data set.

[0231] In an implementation manner, the processing unit 1002 is configured to predict the service evaluation information of the first object based on the subgraph data, and specifically configured to perform the following steps:

[0232] convert the edge data in the edge data set and the point data in the point data set into input information of the service processing model;

[0233] invoke the service processing model to perform service prediction on the first object based on the input information, and obtain the service evaluation information of the first object.

[0234] In an implementation manner, each edge data in the edge data set corresponds to a respective level; and the processing unit 1002 is configured to convert the edge data in the edge data set and the point data in the point data set into input information of the service processing model, and specifically configured to perform the following steps:

[0235] determine the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set;

[0236] sort the edge data in the edge data set according to the levels corresponding to the edge data in the edge data set and the node identifiers of the edge data in the edge data set;

[0237] after sorting, splice the node features of each node in the social relationship subgraph according to the arrangement order of the edge data in the edge data set, and obtain the input information of the service processing model.

[0238] In an implementation manner, any node in the social relationship subgraph is represented as a target node; and the processing unit 1002 is configured to determine the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set, and specifically configured to perform the following steps:

[0239] determine the point attribute information in the point data corresponding to the target node as the first node feature of the target node;

[0240] obtain the edge data corresponding to the target node, aggregate the edge data corresponding to the target node, and obtain the second node feature of the target node;

[0241] determine the node feature of the target node according to the first node feature and the second node feature.

[0242] In an implementation manner, the processing unit 1002 is configured to sort the edge data in the edge data set according to the levels corresponding to the edge data in the edge data set and the node identifiers of the edge data in the edge data set, and specifically configured to perform the following steps:

[0243] According to the level corresponding to each edge data in the edge data set, the first sorting is performed on each edge data in the edge data set;

[0244] For the edge data in the same level in the edge data set, the second sorting is performed on the edge data in the same level according to the node identifier of the starting node;

[0245] For the edge data with the same starting node in the edge data set, the third sorting is performed on the edge data with the same starting node according to the node identifier of the terminal node.

[0246] In an implementation manner, the processing unit 1002 is configured to splice the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set, to obtain the input information of the business processing model, and specifically configured to perform the following steps:

[0247] The node features of the first node representing the first object are determined as the first input information;

[0248] The node features of the terminal node of the edge data in each level are spliced according to the arrangement order of the edge data in each level, to obtain the level input information corresponding to each level;

[0249] The first input information and the level input information corresponding to each level are determined as the input information of the business processing model.

[0250] In an implementation manner, the business evaluation information of the first object is predicted by the business processing model; the processing unit 1002 is further configured to perform the following steps:

[0251] The first business processing model is trained under the first framework to obtain a second business processing model; the model format of the second business processing model is the first model format, and the first model format is a model format defined by the first framework;

[0252] The model format of the second business processing model is converted into a second model format to obtain a third business processing model, and the second model format is a model format defined by a second framework;

[0253] The third business processing model is deployed under the second framework;

[0254] The processing unit 1002 is configured to predict the business evaluation information of the first object based on the subgraph data, and specifically configured to perform the following steps: the third business processing model is called under the second framework to predict the business evaluation information of the first object based on the subgraph data.

[0255] In an implementation, the graph data includes offline graph data before a cycle start point of a current data statistical cycle and real-time graph data within the current data statistical cycle; the graph data is stored in a graph database; and the updating process of the graph data includes:

[0256] When the cycle start point of the current data statistical cycle is reached, the offline graph data is updated into the graph database;

[0257] The real-time graph data generated within the current data statistical cycle is updated into the graph database.

[0258] According to an embodiment of the present application, Figure 10 The units in the business processing apparatus shown can be combined into one or several other units respectively or all, or some of the units can be further split into a plurality of units with smaller functions to constitute, which can achieve the same operation without affecting the implementation of the technical effects of the embodiments of the present application. The above units are divided based on logical functions, and in actual applications, the functions of one unit can also be implemented by multiple units, or the functions of multiple units can be implemented by one unit. In other embodiments of the present application, the apparatus can also include other units, and in actual applications, these functions can also be assisted by other units, and can be implemented by multiple units.

[0259] According to another embodiment of the present application, the business processing apparatus as shown in Figure 4 or Figure 6 The steps involved in part or all of the methods shown can be constructed by running a computer program capable of executing the steps on a general computing device such as a computer including processing elements and storage elements such as a central processing unit (CPU), random access memory (RAM), read-only memory (ROM), etc. Figure 11 The business processing apparatus as shown in

[0260] In the embodiment of the present application, when a service request for a first object in a social network is detected, it indicates that there is a demand for service evaluation of the first object in the social network. The request information of the service request can be used to query the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph, and the service evaluation information of the first object can be predicted based on the subgraph data. It can be seen that when predicting the service evaluation information of the object, not only the social characteristics of the object itself are considered, but also the subgraph data of the social relationship subgraph associated with the object. The subgraph data is more comprehensive than the social characteristics of the object itself, which can improve the prediction accuracy of the service evaluation information of the object, thereby improving the service processing accuracy of the object. Moreover, by associating and storing the graph data with the timestamp, the subgraph data with a timestamp less than the first timestamp triggering the service evaluation can be queried. The subgraph data with a timestamp less than the first timestamp can accurately reflect the characteristics of the object before triggering the service evaluation. The subgraph data with a timestamp greater than or equal to the first timestamp is irrelevant to the service evaluation. Therefore, the subgraph data with a timestamp greater than or equal to the first timestamp can be avoided to affect the prediction accuracy of the service evaluation information, thereby further improving the prediction accuracy of the service evaluation information of the object and further improving the service processing accuracy of the object.

[0261] Based on the above method and device embodiments, the present embodiment provides a computer device. Please refer to Figure 11 , Figure 11 is a structural schematic diagram of a computer device provided by the present embodiment. Figure 11 The computer device shown in the figure at least includes a processor 1101, an input interface 1102, an output interface 1103, and a computer readable storage medium 1104. Wherein, the processor 1101, the input interface 1102, the output interface 1103 and the computer readable storage medium 1104 can be connected through bus or other ways.

[0262] The computer readable storage medium 1104 can be stored in the memory of the computer device, and the computer readable storage medium 1104 is used to store computer programs, and the computer programs include computer instructions. The processor 1101 is used to execute the computer programs stored in the computer readable storage medium 1104. The processor 1101 (or CPU (Central Processing Unit, Central Processing Unit)) is the computing core and control core of the computer device, which is suitable for implementing computer programs, and specifically suitable for loading and executing computer programs to realize corresponding method processes or corresponding functions.

[0263] The embodiment of the present application further provides a computer readable storage medium (Memory), which is a memory device in a computer device and is used for storing programs and data. It can be understood that the computer readable storage medium herein can include an internal storage medium in the computer device, and of course can include an extended storage medium supported by the computer device. The computer readable storage medium provides a storage space, which stores an operating system of the computer device. Moreover, the storage space also stores a computer program suitable for being loaded and executed by a processor. It should be noted that the computer readable storage medium herein can be a high-speed RAM memory, or a non-volatile memory (Non-Volatile Memory), for example, at least one disk memory; and optionally can be at least one computer readable storage medium located away from the aforementioned processor.

[0264] The computer device can be Figure 1 The service processing system shown in the figure 102. In a specific implementation, the computer program stored in the computer readable storage medium 1104 can be loaded and executed by the processor 1101 to implement the corresponding steps in the method shown above. Figure 4 Or Figure 6 The computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to implement the following steps:

[0265] When detecting a service request for a first object in a social network, obtaining request information, the request information including a first timestamp triggering the service request and an object identifier of the first object; the social network adopts a social relationship graph, the social relationship graph including nodes and edges, the nodes being used for representing objects in the social network, and the edges being used for connecting two objects in the social network having a social relationship; graph data of the social relationship graph is stored in association with a timestamp;

[0266] Based on the request information, querying subgraph data of a social relationship subgraph associated with the first object from the graph data of the social relationship graph; the timestamp associated with the subgraph data is less than the first timestamp;

[0267] Based on the subgraph data, predicting service evaluation information of the first object;

[0268] According to the service evaluation information, performing service processing on the first object.

[0269] In an implementation manner, the graph data is stored in an edge data structure and a point data structure;

[0270] The edge data structure is used for storing edge data corresponding to edges in the social relationship graph, and the edges in the social relationship graph ijAn edge connecting the ith object and the jth object in the social network, the first social relationship being established from the ith object as a starting point ij Corresponding edge data includes node identification of a starting node, node identification of a terminal node, edge data timestamp, and edge attribute information; wherein the ith object corresponds to the starting node, the jth object corresponds to the terminal node, the edge data timestamp refers to the establishment time of the first social relationship, and the edge attribute information refers to the relationship characteristics of the first social relationship;

[0271] Point data structure is used to store point data corresponding to nodes in a social relationship graph, and the ith node in the social relationship graph is used to represent the ith object in the social relationship network; the point data corresponding to the ith node includes node identification of the ith node, point data timestamp, and point attribute information; wherein the point data timestamp refers to the time when the point attribute information is generated, and the point attribute information refers to the object characteristics of the ith object at the point data timestamp.

[0272] In an implementation mode, the social relationship subgraph corresponds to a social subnetwork associated with the first object in the social network, and the social subnetwork includes the first object and a second object having one or more levels of social relationship with the first object before the first timestamp; the social relationship subgraph includes nodes corresponding to each object in the social subnetwork, and edges connecting two objects having social relationship in the social subnetwork;

[0273] The computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101, and when querying the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph based on the request information, it is specifically used to execute the following steps:

[0274] Based on the object identification of the first object, querying the edge data corresponding to each edge in the social relationship subgraph before the first timestamp in the graph data to obtain an edge data set;

[0275] Querying the point data corresponding to each node in the social relationship subgraph before the first timestamp in the graph data to obtain a point data set;

[0276] The edge data in the edge data set and the point data in the point data set are determined as the subgraph data.

[0277] In an implementation mode, the computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101, and when querying the edge data corresponding to each edge in the social relationship subgraph before the first timestamp in the graph data based on the object identification of the first object to obtain an edge data set, it is specifically used to execute the following steps:

[0278] querying the first level of edge data in the graph data; the edge data in the first level of edge data has an edge data timestamp less than the first timestamp, and a starting node in the first level of edge data has a node identifier corresponding to an object identifier of the first object;

[0279] querying the second level of edge data in the graph data; the edge data in the second level of edge data has an edge data timestamp less than the first timestamp, and a starting node in the second level of edge data has a node identifier corresponding to a node identifier of a terminal node in the first level of edge data;

[0280] continuing to query the third level of edge data in the graph data until the query result is empty;

[0281] determining the queried edge data in each level as edge data in the edge data set.

[0282] In an implementation, in the process of querying the first level of edge data in the graph data, if there are multiple target edge data, the starting nodes in the multiple target edge data have the same node identifier, the terminal nodes in the multiple target edge data have the same node identifier, but the edge data timestamps of the multiple target edge data are different, the computer program in the computer readable storage medium 1104 is loaded by the processor 1101 and further used to execute the following steps:

[0283] adding the edge data with the largest edge data timestamp in the multiple target edge data to the first level of edge data.

[0284] In an implementation, the processing unit is used to query the point data corresponding to each node in the social relationship subgraph in the graph data before the first timestamp to obtain the point data set, and is specifically used to execute the following steps:

[0285] determining the node identifier of each node in the social relationship subgraph according to the node identifier in the edge data in the edge data set;

[0286] querying the point data with a point data timestamp less than the first timestamp and a node identifier corresponding to each node in the social relationship subgraph in the graph data to obtain the point data corresponding to each node in the social relationship subgraph;

[0287] determining the point data corresponding to each node in the social relationship subgraph as the point data in the point data set.

[0288] In an implementation, the computer program in the computer readable storage medium 1104 is loaded by the processor 1101 and executed to predict the business evaluation information of the first object based on the subgraph data, and is specifically used to execute the following steps:

[0289] convert the edge data in the edge data set and the point data in the point data set into input information of the business processing model;

[0290] invoke the business processing model to perform business prediction on the first object based on the input information, and obtain business evaluation information of the first object.

[0291] In an implementation manner, each edge data in the edge data set corresponds to a respective level; when the computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to convert the edge data in the edge data set and the point data in the point data set into input information of the business processing model, the computer program is specifically used to perform the following steps:

[0292] determine the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set;

[0293] sort each edge data in the edge data set according to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set;

[0294] After sorting, splice the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set, to obtain the input information of the business processing model.

[0295] In an implementation manner, any node in the social relationship subgraph is represented as a target node; when the computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to determine the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set, the computer program is specifically used to perform the following steps:

[0296] determine the point attribute information in the point data corresponding to the target node as the first node feature of the target node;

[0297] obtain the edge data corresponding to the target node, aggregate the edge data corresponding to the target node, and obtain the second node feature of the target node;

[0298] determine the node feature of the target node according to the first node feature and the second node feature.

[0299] In an implementation manner, when the computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to sort each edge data in the edge data set according to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set, the computer program is specifically used to perform the following steps:

[0300] The edge data in the edge data set is first sorted according to the level corresponding to each edge data in the edge data set;

[0301] For edge data in the edge data set at the same level, the edge data at the same level is second sorted according to the node identifier of the starting node;

[0302] For edge data in the edge data set with the same starting node, the edge data with the same starting node is third sorted according to the node identifier of the terminal node.

[0303] In an implementation manner, the computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to splice the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set, and obtain the input information of the business processing model, and specifically used to execute the following steps:

[0304] The node features of the first node representing the first object are determined as the first input information;

[0305] According to the arrangement order of the edge data in each level, the node features of the terminal node of the edge data in each level are spliced to obtain the level input information corresponding to each level;

[0306] The first input information and the level input information corresponding to each level are determined as the input information of the business processing model.

[0307] In an implementation manner, the business evaluation information of the first object is predicted by the business processing model; the computer program in the computer readable storage medium 1104 is loaded by the processor 1101 and further used to execute the following steps:

[0308] The first business processing model is trained under the first framework to obtain a second business processing model; the model format of the second business processing model is the first model format, and the first model format is a model format defined by the first framework;

[0309] The model format of the second business processing model is converted into a second model format to obtain a third business processing model, and the second model format is a model format defined by a second framework;

[0310] The third business processing model is deployed under the second framework;

[0311] The computer program in the computer readable storage medium 1104 is loaded and executed by the processor 1101 to predict the business evaluation information of the first object based on the subgraph data, and specifically used to execute the following steps: the third business processing model is called under the second framework to predict the business evaluation information of the first object based on the subgraph data.

[0312] In an implementation manner, the graph data comprises offline graph data before a period start of a current data statistical period and real-time graph data within the current data statistical period; the graph data is stored in a graph database; and an updating process of the graph data comprises:

[0313] updating the offline graph data to the graph database when reaching the period start of the current data statistical period;

[0314] updating the real-time graph data generated within the current data statistical period to the graph database.

[0315] In the embodiments of the present application, when a service request for a first object in a social network is detected, it indicates that there is a demand for service evaluation of the first object in the social network. The request information of the service request can be used to query the subgraph data of the social relationship subgraph associated with the first object from the graph data of the social relationship graph, and the service evaluation information of the first object can be predicted based on the subgraph data. It can be seen that when predicting the service evaluation information of the object, not only the social characteristics of the object itself are considered, but also the subgraph data of the social relationship subgraph associated with the object. The subgraph data is more comprehensive than the social characteristics of the object itself, which can improve the prediction accuracy of the service evaluation information of the object, thereby improving the service processing accuracy of the object. Moreover, by associating and storing the graph data with the timestamp, the subgraph data with a timestamp less than the first timestamp triggering the service evaluation can be queried. The subgraph data with a timestamp less than the first timestamp can accurately reflect the characteristics of the object before triggering the service evaluation. The subgraph data with a timestamp greater than or equal to the first timestamp is irrelevant to the service evaluation. Therefore, the subgraph data with a timestamp greater than or equal to the first timestamp can be avoided to affect the prediction accuracy of the service evaluation information, thereby further improving the prediction accuracy of the service evaluation information of the object and further improving the service processing accuracy of the object.

[0316] The embodiments of the present application also provide a computer program product, which comprises a computer program stored in a computer readable storage medium. A processor of a computer device reads the computer program from the computer readable storage medium, and the processor executes the computer program to enable the computer device to perform the service processing method described above.

[0317] Those skilled in the art can realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed in the present application can be realized by electronic hardware or a combination of computer software and electronic hardware. Whether the functions are realized in hardware or software manner depends on the specific application and design constraints of the technical solutions. Those skilled in the art can use different methods to realize the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0318] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined target, and can be implemented in whole or in part by using software, hardware (such as a processing circuit or a memory), or a combination thereof. Similarly, one processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be a part of an integral module or unit that includes the functions of the module or unit.

[0319] In the above embodiments, all or part can be implemented by software, hardware, firmware, or any combination thereof. When implemented by software, all or part can be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions according to the embodiments of the present application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. Computer instructions can be stored in a computer-readable storage medium or transmitted by a computer-readable storage medium. Computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through wired (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (for example, infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that the computer can access or a data storage device such as a server, data center, etc. that includes one or more available media sets. The available media can be magnetic media (for example, floppy disk, hard disk, magnetic tape), optical media (for example, DVD), or semiconductor media (for example, solid state disk (SSD)) and the like.

[0320] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical scope disclosed in the present application, which should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A service processing method characterized by, The method comprises the following steps: When a service request for a first object in a social network is detected, request information is acquired, the request information comprising a first timestamp triggering the service request and an object identifier of the first object; the social network adopts a social relationship graph, the social relationship graph comprising nodes and edges, the nodes being used for representing objects in the social network, and the edges being used for connecting two objects in the social network having a social relationship; graph data of the social relationship graph is stored in association with a timestamp; Based on the request information, subgraph data of a social relationship subgraph associated with the first object is queried from the graph data of the social relationship graph; The timestamp associated with the subgraph data is less than the first timestamp; Based on the subgraph data, service evaluation information of the first object is predicted; According to the service evaluation information, the first object is processed.

2. The method of claim 1, wherein, The graph data is stored in an edge data structure and a point data structure; The edge data structure is used for storing edge data corresponding to an edge in the social relationship graph, and the edge in the social relationship graph ij For connecting an i-th object and a j-th object with a first social relationship in the social network, the establishment of the first social relationship is started from the i-th object; the edge ij The corresponding edge data includes a node identifier of a starting node, a node identifier of a terminal node, an edge data timestamp, and edge attribute information; wherein the i-th object corresponds to the starting node, the j-th object corresponds to the terminal node, the edge data timestamp refers to the establishment time of the first social relationship, and the edge attribute information refers to the relationship characteristics of the first social relationship. The point data structure is used for storing point data corresponding to nodes in the social relationship graph, an i-th node in the social relationship graph being used for representing an i-th object in the social relationship network; the point data corresponding to the i-th node comprises a node identifier of the i-th node, a point data timestamp and point attribute information; wherein the point data timestamp refers to a time when the point attribute information is generated, and the point attribute information refers to an object feature of the i-th object at the point data timestamp.

3. The method of claim 2, wherein, The social relationship subgraph corresponds to a social subnetwork associated with the first object in the social network, the social subnetwork comprising the first object and a second object having one or more levels of social relationship with the first object before the first timestamp; the social relationship subgraph comprises nodes corresponding to each object in the social subnetwork and edges connecting two objects in the social subnetwork having a social relationship; The method comprises the following steps: Based on the object identifier of the first object, edge data corresponding to each edge in the social relationship subgraph before the first timestamp is queried from the graph data, to obtain an edge data set; Point data corresponding to each node in the social relationship subgraph before the first timestamp is queried from the graph data, to obtain a point data set; Edge data in the edge data set and point data in the point data set are determined as the subgraph data.

4. The method of claim 3, wherein, The method comprises the following steps: First-level edge data is queried from the graph data; the edge data in the first-level edge data has a timestamp less than the first timestamp, and a starting node in the first-level edge data has a node identifier corresponding to the object identifier of the first object; querying edge data of a second level in the graph data; edge data in the edge data of the second level has a smaller edge data timestamp than the first timestamp, and a node identifier of a starting node in the edge data of the second level is the same as a node identifier of a terminal node in the edge data of the first level; continuing to query edge data of a third level in the graph data until a query result is empty; determining the queried edge data of each level as edge data in the edge data set.

5. The method of claim 4, wherein, In the process of querying the edge data of the first level in the graph data, if there are multiple target edge data, the node identifiers of the starting nodes in the multiple target edge data are the same, the node identifiers of the terminal nodes in the multiple target edge data are the same, and the edge data timestamps of the multiple target edge data are different, the method further comprises: adding edge data with the largest edge data timestamp in the multiple target edge data to the edge data of the first level.

6. The method of claim 3, wherein, The querying of the point data corresponding to each node in the social relationship subgraph in the graph data before the first timestamp to obtain the point data set comprises: determining the node identifiers of each node in the social relationship subgraph according to the node identifiers in the edge data in the edge data set; querying point data with a smaller point data timestamp than the first timestamp and the node identifier of each node in the social relationship subgraph in the graph data to obtain the point data corresponding to each node in the social relationship subgraph; determining the point data corresponding to each node in the social relationship subgraph as the point data in the point data set.

7. The method of claim 3, wherein, The prediction of the business evaluation information of the first object based on the subgraph data comprises: converting the edge data in the edge data set and the point data in the point data set into input information of a business processing model; calling the business processing model to perform business prediction on the first object based on the input information to obtain the business evaluation information of the first object.

8. The method of claim 7, wherein, Each edge data in the edge data set corresponds to a respective level; the conversion of the edge data in the edge data set and the point data in the point data set into input information of a business processing model comprises: determining node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set; sorting each edge data in the edge data set according to the level corresponding to each edge data in the edge data set and the node identifier of each edge data in the edge data set; after sorting, splicing the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set to obtain the input information of the business processing model.

9. The method of claim 8, wherein, Any node in the social relationship subgraph is denoted as a target node; the determination of the node features of each node in the social relationship subgraph according to the edge data in the edge data set and the point data in the point data set comprises: Determine point attribute information in point data corresponding to the target node as a first node feature of the target node; Obtain edge data corresponding to the target node, aggregate the edge data corresponding to the target node, and obtain a second node feature of the target node; Determine the node feature of the target node according to the first node feature and the second node feature.

10. The method of claim 8, wherein, The sorting of each edge data in the edge data set includes: Firstly, sorting each edge data in the edge data set according to the level corresponding to each edge data in the edge data set; Secondly, for edge data in the same level in the edge data set, sorting the edge data in the same level according to the node identifier of the starting node; Thirdly, for edge data with the same starting node in the edge data set, sorting the edge data with the same starting node according to the node identifier of the terminal node.

11. The method of claim 8, wherein, The splicing of the node features of each node in the social relationship subgraph according to the arrangement order of each edge data in the edge data set includes: Determine the node feature of the first node representing the first object as first input information; According to the arrangement order of the edge data in each level, splice the node features of the terminal nodes of the edge data in each level to obtain the level input information corresponding to each level; Determine the first input information and the level input information corresponding to each level as the input information of the business processing model.

12. The method of any one of claims 1-11, wherein, The business evaluation information of the first object is predicted by a business processing model; the method further includes: Training the first business processing model under a first framework to obtain a second business processing model; the model format of the second business processing model is a first model format, and the first model format is a model format defined by the first framework; Converting the model format of the second business processing model into a second model format to obtain a third business processing model, and the second model format is a model format defined by a second framework; Deploying the third business processing model under the second framework; The prediction of the business evaluation information of the first object based on the subgraph data includes: calling the third business processing model under the second framework to predict the business evaluation information of the first object based on the subgraph data.

13. The method of any one of claims 1-11, wherein, The graph data includes offline graph data before the starting point of the current data statistical period and real-time graph data in the current data statistical period; The graph data is stored in a graph database; The updating process of the graph data includes: When the starting point of the current data statistical period is reached, update the offline graph data to the graph database; Update the real-time graph data generated in the current data statistical period to the graph database.

14. A service processing apparatus characterized by comprising: ​ An acquisition unit is configured to acquire request information when a service request for a first object in a social network is detected, the request information including a first timestamp triggering the service request and an object identifier of the first object; the social network is represented by a social relationship graph, the social relationship graph including nodes and edges, the nodes being configured to represent objects in the social network, and the edges being configured to connect two objects having a social relationship in the social network; graph data of the social relationship graph is stored in association with timestamps; A processing unit is configured to query subgraph data of a social relationship subgraph associated with the first object from the graph data of the social relationship graph based on the request information; a timestamp associated with the subgraph data is less than the first timestamp; The processing unit is further configured to predict service evaluation information of the first object based on the subgraph data; The processing unit is further configured to perform service processing on the first object according to the service evaluation information.

15. A computer device, comprising: The computer device comprises: a processor adapted to implement a computer program; a computer readable storage medium storing a computer program, the computer program being adapted to be loaded and executed by the processor to implement the service processing method according to any one of claims 1-13.

16. A computer readable storage medium characterized by: The computer readable storage medium stores a computer program, the computer program being adapted to be loaded and executed by the processor to implement the service processing method according to any one of claims 1-13.

17. A computer program product, characterised in that, The computer program product comprises a computer program, the computer program being executed by the processor to implement the service processing method according to any one of claims 1-13.