Method and device for determining association degree with target object, equipment and product
By assigning sampling weights to associated objects in a knowledge graph and utilizing the Shapley value algorithm and Monte Carlo method, the problem of determining the degree of association in knowledge graph prediction tasks is solved, thereby improving the interpretability of prediction results and user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-05
- Publication Date
- 2026-03-10
AI Technical Summary
When using knowledge graphs for prediction tasks, existing technologies struggle to quickly determine the degree of association between related objects and target objects, leading to unclear prediction results and impacting user experience.
By assigning multiple sampling weights to multiple related objects in the knowledge graph, and utilizing pre-defined knowledge and machine learning methods, the degree of association between multiple related objects and the target object is determined, and the Shapley value algorithm and Monte Carlo method are combined for interpretation.
It enables the rapid determination of the degree of association between related objects and target objects, improves the interpretability of prediction tasks, and enhances the user experience.
Smart Images

Figure CN121638239A_ABST
Abstract
Description
Technical Field
[0001] The embodiments disclosed herein generally relate to the field of knowledge graph processing, and more specifically to methods, apparatus, devices, and products for determining the degree of association with a target object. Background Technology
[0002] Knowledge graphs are a powerful way to represent and organize knowledge. They clearly display entities, concepts, and the relationships between them using a graph structure. Like a vast knowledge network, they encompass information from various fields. In a knowledge graph, entities can be people, places, events, etc., concepts are summaries and classifications of these entities, and relationships indicate the connections between them.
[0003] Knowledge graphs have a wide range of applications and significant value. In search engines, they can provide more accurate and comprehensive search results and understand user intent. Enterprises can leverage knowledge graphs to process various internal information, providing content management information for production and product supply, and offering services to users by quickly and accurately answering customer questions. Therefore, the application of knowledge graphs in various information processing applications is increasing. Summary of the Invention
[0004] Embodiments of this disclosure provide methods, apparatus, devices, and products for determining the degree of association with a target object.
[0005] According to a first aspect of this disclosure, a method for determining the degree of association between an object and a target object is provided. The method includes assigning multiple sampling weights to multiple associated objects in a knowledge graph based on predetermined knowledge related to a prediction task concerning the target object in the knowledge graph, wherein the multiple sampling weights include at least two different sampling weights. The method further includes determining multiple degrees of association between the multiple associated objects and the target object for the prediction task, based on the multiple sampling weights and the knowledge graph.
[0006] According to a second aspect of this disclosure, a knowledge graph-based prediction method is provided. This method includes determining a prediction result for a prediction task targeting a target object in a knowledge graph, and multiple degrees of association between multiple related objects in the knowledge graph and the target object for the prediction task. These multiple degrees of association are determined based on the knowledge graph and multiple sampling weights assigned to the multiple related objects, wherein the multiple sampling weights include at least two different sampling weights. The method also includes generating a prediction interpretation of the prediction result for the prediction task targeting the target object based on the multiple degrees of association.
[0007] According to a third aspect of this disclosure, an apparatus for determining the degree of association with a target object is provided. The apparatus includes a sampling weight allocation module configured to allocate multiple sampling weights to multiple associated objects in a knowledge graph based on predetermined knowledge related to a prediction task of the target object in the knowledge graph, wherein the multiple sampling weights include at least two different sampling weights; and an association degree determination module configured to determine multiple degrees of association between the multiple associated objects and the target object for the prediction task based on the multiple sampling weights and the knowledge graph.
[0008] According to a fourth aspect of this disclosure, a knowledge graph-based prediction apparatus is provided. The apparatus includes a determining module configured to determine a prediction result for a prediction task targeting a target object in a knowledge graph, and multiple degrees of association between multiple related objects in the knowledge graph and the target object for the prediction task, the multiple degrees of association being determined based on the knowledge graph and multiple sampling weights assigned to the multiple related objects, wherein the multiple sampling weights include at least two different sampling weights; and a prediction interpretation generation module configured to generate a prediction interpretation of the prediction result for the prediction task targeting the target object based on the multiple degrees of association.
[0009] According to a fifth aspect of this disclosure, an electronic device is provided. The electronic device includes at least one processor; and a memory coupled to the at least one processor and having instructions stored thereon, which, when executed by the at least one processor, cause the electronic device to perform the steps of the methods in the first or second aspect of this disclosure.
[0010] According to a sixth aspect of this disclosure, a machine program product is provided. The machine program product includes machine-executable instructions, wherein the machine-executable instructions are executed by a processor to implement the steps of the method in the first or second aspect of this disclosure.
[0011] According to a seventh aspect of this disclosure, a machine-readable storage medium is provided. The machine-readable storage medium stores machine-executable instructions, which are executed by a processor to implement the steps of the methods in the first or second aspect of this disclosure. Attached Figure Description
[0012] Figure 1 The illustration shows a schematic diagram of an example environment in which a computing device and / or method according to embodiments of the present disclosure may be implemented;
[0013] Figure 2 The illustration shows a flowchart of a method for determining the degree of association with a target object according to an embodiment of the present disclosure;
[0014] Figure 3The illustration shows a schematic diagram of an example for determining the degree of association with a target object according to an embodiment of the present disclosure;
[0015] Figure 4 The illustration shows a schematic diagram of an example of a knowledge graph including target components according to an embodiment of the present disclosure;
[0016] Figure 5 The illustration shows a schematic diagram of an example of the degree of relevance to a target component according to an embodiment of the present disclosure;
[0017] Figure 6 The illustration shows a schematic diagram of another example of a knowledge graph including target components according to an embodiment of the present disclosure;
[0018] Figure 7 The illustration shows another example of the degree of relevance to the target component according to an embodiment of the present disclosure;
[0019] Figure 8 A flowchart illustrating a knowledge graph-based prediction method according to an embodiment of the present disclosure is shown.
[0020] Figure 9 The illustration shows a schematic diagram of an apparatus for determining the degree of association with a target object according to an embodiment of the present disclosure;
[0021] Figure 10 The illustration shows a schematic diagram of a knowledge graph-based prediction device according to an embodiment of the present disclosure;
[0022] Figure 11 A schematic block diagram of an example computing device suitable for implementing embodiments of the present disclosure is illustrated.
[0023] In the various figures, the same or corresponding reference numerals indicate the same or corresponding parts. Detailed Implementation
[0024] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.
[0025] In the description of embodiments of this disclosure, the term "comprising" and similar terms should be understood as open-ended inclusion, i.e., "including but not limited to". The term "based on" should be understood as "at least partially based on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The terms "first", "second", etc., may refer to different or the same objects. Other explicit and implicit definitions may also be included below.
[0026] Knowledge graphs are increasingly being used across various fields. For example, in the manufacturing processes of some production enterprises, personnel from different departments or with different roles often need to undertake cross-departmental and cross-domain communication and data integration responsibilities. Such processes typically require a significant amount of time to fully communicate relevant domain knowledge and acquire all necessary data. To address the challenges of diverse domain knowledge, knowledge graphs can be used to facilitate data integration within enterprises. By constructing a common model, integrating business knowledge, and utilizing knowledge graph technology to integrate heterogeneous data into a graph database, relevant personnel can execute real-time queries to retrieve all the data.
[0027] However, despite the aforementioned knowledge graph-based data integration, various roles and users still rely on data for repetitive decision-making. Furthermore, business execution is often difficult to achieve quickly and efficiently through cross-departmental and cross-domain communication and collaboration. Therefore, data integration only achieves resource savings during the digitization process. To improve the efficiency of task execution (e.g., task decision-making), the constructed knowledge graph is used to make predictions. However, the prediction process itself does not clearly provide information on how relevant factors influence the prediction results, thus hindering the accurate interpretation of these predictions.
[0028] To this end, embodiments of this disclosure provide a method for determining the degree of association between multiple objects and a target object. In this method, a computing device can first use predetermined knowledge related to a prediction task involving the target object in a knowledge graph to assign multiple sampling weights to multiple associated objects in the knowledge graph. Each associated object can be assigned a corresponding sampling weight, wherein the assigned multiple sampling weights include at least two different sampling weights. Then, the device further utilizes the assigned multiple sampling weights and the knowledge graph to determine multiple degrees of association between the multiple associated objects and the target object for the prediction task. Through this method, by using sampling weights assigned with predetermined knowledge, multiple degrees of association between multiple associated objects and the target object can be quickly determined for the prediction task, thereby reasonably interpreting the results of the prediction task and improving the user experience.
[0029] The embodiments of this disclosure will now be described in further detail with reference to the accompanying drawings, wherein... Figure 1 The examples shown illustrate computing devices and / or methods of embodiments of this disclosure that may be implemented in an example environment.
[0030] Figure 1 A schematic diagram of an example environment 100 in which various embodiments of this disclosure may be implemented is shown. For example... Figure 1 As shown, computing device 104 can process the acquired knowledge graph 106. Computing device 104 includes, but is not limited to, personal computers, server computers, handheld or laptop devices, mobile devices (such as mobile phones, personal digital assistants (PDAs), media players, etc.), multiprocessor systems, consumer electronics, minicomputers, mainframe computers, and distributed computing environments that include any of the above systems or devices.
[0031] Knowledge graph 106 includes multiple nodes and the relationships between these nodes. In one example, knowledge graph 106 may be a product knowledge graph, including information on the product's production process, design, and materials. In another example, knowledge graph 106 may be a knowledge graph comprising all information of an enterprise or department, such as information on the production, design, supply, materials, and factories of various types of products. In some embodiments, knowledge graph 106 may be a part of a product knowledge graph or an enterprise or department's knowledge graph. For example, knowledge graph 106 may be a knowledge graph composed of partial information selected by technicians from a large knowledge graph that is relevant to the prediction task of the target object to be processed. Therefore, during the extraction phase of knowledge graph 106, actual business scenarios may involve different query logics, thereby defining different nodes and relationships. The above examples are only for describing this disclosure and are not specific limitations of this disclosure.
[0032] The computing device 104 can also acquire predefined knowledge 102 related to the prediction task of the target object in the knowledge graph. The prediction task for the target object can be any suitable type of task. In one example, the knowledge graph includes product inventory levels, production status, and customer historical orders; the prediction task is to determine whether the production plan for that product needs to be increased or decreased for a specific customer within a future time interval. In another example, the knowledge graph includes different customers and orders, as well as relationships between customers, between customers and materials, and between materials; the prediction task is to provide the supply team with material recommendations for customers. In yet another example, the prediction task is to predict whether a component will fail; in this case, the design information, production information, current usage status, and material information of the component are acquired to predict whether the component will fail. Additionally, the target object in the processed knowledge graph can be an unprocessed node or a positive sample node used for the prediction task.
[0033] The pre-defined knowledge 102 can be expert knowledge specific to different domains. For the target object of the knowledge graph and the prediction task for that target object, there exists some relevant expert knowledge. This knowledge can be used to assign sampling weights to other nodes in the knowledge graph that are related to the target node. For example, component fault detection personnel typically know which aspects of information mainly affect component quality; and product maintenance personnel typically know some customer requirements. Therefore, based on this expert knowledge, different sampling weights can be assigned to different types of reference objects in the knowledge graph.
[0034] The computing device 104 can use pre-defined knowledge 102 to assign corresponding sampling weights 108 to multiple other nodes or multiple related objects based on the prediction task of the node or object to be processed and the importance of other nodes and related objects. The pre-defined knowledge 102 can be expert knowledge in a specific domain related to the prediction task. For example, if predicting whether a component will fail, if experts in the relevant domain believe, based on their expertise, that the main cause of the component's failure is the component's manufacturing process and design process, then higher sampling weights can be assigned to nodes in the knowledge graph related to the component's manufacturing process and design process, while lower sampling weights can be assigned to other nodes. Further analysis can be performed based on expert knowledge. If it is believed that the likelihood of a failure caused by the manufacturing process is higher than that caused by the design process, then the weights assigned to nodes related to the component's manufacturing process are higher than the weights assigned to nodes related to the component's design process.
[0035] Then, the computing device 104 determines the association relationship between the multiple associated objects and the target object based on the knowledge graph 106 and the multiple sampling weights 108 assigned to the multiple associated objects. In some embodiments, the computing device 104 selects a target associated object in the knowledge graph 106 using a biased random sampling method based on the sampling weights assigned to nodes other than the target node in the knowledge graph 106. Then, a pre-trained prediction model is used to process the knowledge graph 106 with the target associated object and the knowledge graph 106 without the target associated object, giving two prediction results for the target object. Then, random sampling can be performed multiple times in the knowledge graph 106 in the manner described above. After multiple random samplings and determining the corresponding prediction results, the degree of influence of the associated objects in each node on the target object on the target node can be determined based on these prediction results. Additionally, these degrees of influence can be transformed to map to a predetermined space, thereby determining multiple degrees of association 110 between the multiple associated objects and the target object.
[0036] For example, when the prediction task is to determine whether a component has failed, if the prediction result is that the component has failed, multiple correlation levels 110 can indicate which node information is related to the component failure and the degree of correlation, thereby providing an interpretation associated with the prediction result. Additionally, this interpretation can be further determined based on relevant expert knowledge.
[0037] By using the sampling weights assigned by predefined knowledge, the degree of association between multiple related objects and the target object can be quickly determined for a prediction task. This allows for a reasonable interpretation of the prediction task's results and improves the user experience.
[0038] The above combination Figure 1 This describes the process of determining multiple degrees of association. During this process, machine learning is applied, primarily involving knowledge graph extraction and model design and selection. For example, the aforementioned functionality is achieved using a machine learning component. This component consists of two parts: one involving knowledge graph extraction, and the other focusing on model design and selection. These two parts can be customized according to different project scenarios. In the knowledge graph data extraction phase, actual business scenarios may involve different query logics, thus defining different nodes and relationships. For example, the example above of determining whether to increase or decrease a specific customer's production plan is a typical node classification task. The goal is to classify whether a specific customer needs to increase or decrease their production plan based on various factors. The example above of providing material recommendations to the supply team involves linking customers, materials, and their interactions to recommend available material information. This is a potential link prediction task, aiming to predict the relationships between customers, materials, and their interactions to recommend available material information. Furthermore, the extracted graph data plays a crucial role in the subsequent stages of model design and training. Therefore, expert knowledge related to the target task can be used to extract the required graph data, especially information about objects or nodes that experts believe have a significant impact on the prediction task, so as to effectively extract graph data and use it for model training and use.
[0039] The following is combined Figure 2 A flowchart describing a method for determining the degree of association with a target object according to embodiments of the present disclosure. This method can be... Figure 1 The method can be executed in the environment shown or any suitable environment, and can be executed by computing device 104 or any suitable computing device.
[0040] In Example 200, at box 202, computing device 104 assigns multiple sampling weights to multiple associated objects in the knowledge graph based on predetermined knowledge related to the prediction task of the target object in the knowledge graph, wherein the multiple sampling weights include at least two different sampling weights.
[0041] In some embodiments, computing device 104 may collect multiple data from multiple different data sources. Then, computing device 104 uses this collected data to generate a knowledge graph. For example, computing device 104 may collect data from a database, such as machine tool production data. Additionally, computing device 104 may obtain log data, such as production system log data, through an application programming interface. Furthermore, computing device 104 may also receive manually entered data, such as order information, outbound information, etc. These multiple heterogeneous data sources provide data for the generation of the knowledge graph. Computing device 104 preprocesses the data obtained from different data sources to convert it into triple data. For example, adjusting the data format, merging field data, splitting field data, or removing some inappropriate field information. Additionally, computing device 104 may also format and quantize the triple data of the knowledge graph to generate data that is recognizable and usable by machine learning models that perform task prediction. In some embodiments, computing device 104 may receive the knowledge graph from other computing devices or networks.
[0042] Since the impact of associated objects corresponding to different nodes within a knowledge graph on the prediction task of the target object varies, different sampling weights can be assigned to different associated objects based on expert knowledge. Therefore, when assigning multiple sampling weights to multiple associated objects in a knowledge graph, the computing device 104 can first determine multiple types of the multiple associated objects in the knowledge graph. Then, the computing device 104 uses the multiple types and predetermined knowledge related to the prediction task of the target object to assign multiple sampling weights to the multiple associated objects in the knowledge graph. As mentioned above, for component failures, according to expert knowledge, the production and design processes may have a greater impact on node failures. Therefore, the sampling weight of nodes corresponding to the production and design processes should be greater than that of nodes of other types. Furthermore, different weights can be assigned to nodes in the production and design processes. The above examples are only for describing this disclosure and are not intended to specifically limit this disclosure.
[0043] At box 204, computing device 104 determines multiple degrees of association between multiple related objects and the target object for the prediction task, based on multiple sampling weights and a knowledge graph. After obtaining the sampling weights and the knowledge graph, computing device 104 can randomly select target related objects from the knowledge graph for processing to ultimately determine the multiple degrees of association between the multiple related objects and the target object.
[0044] In some embodiments, when determining multiple degrees of association between multiple associated objects and a target object for a prediction task, the computing device first selects a target associated object from the multiple associated objects using multiple sampling weights assigned to multiple associated nodes. In one example, the computing device 104 uses a Monte Carlo method to perform biased random sampling based on multiple sampling weights during random sampling to select the target associated object from the multiple associated objects in the knowledge graph. In another example, the computing device 104 can use other random sampling methods based on multiple sampling weights to select the target associated object from the multiple associated objects in the knowledge graph. The above examples are merely for describing this disclosure and are not intended to limit this disclosure. Next, the computing device 104 can remove the target associated object from the knowledge graph to generate an adjusted knowledge graph. Then, the computing device 104 uses the knowledge graph and the adjusted knowledge graph to determine multiple degrees of association between the multiple associated objects and the target object for the prediction task.
[0045] For example, the computing device uses a knowledge graph-based and adjusted knowledge graph to determine a first prediction result and a second prediction result for a prediction task targeting a target object. In this process, the computing device 104 applies the knowledge graph to the task prediction model to determine the first prediction result related to the prediction task for the target object. Furthermore, the computing device 104 also applies the adjusted knowledge graph to the task prediction model to determine the second prediction result related to the prediction task for the target object. Then, the computing device determines multiple degrees of association between multiple related objects and the target object based on the first and second prediction results.
[0046] In some embodiments, when determining the degree of association between multiple associated objects and a target object using a first prediction result and a second prediction result, the computing device first calculates the difference between the first prediction result and the second prediction result. Then, the computing device uses the calculated difference to determine multiple degrees of association between the multiple associated objects and the target object. In one example, the difference is processed according to a predetermined formula to obtain multiple degrees of association. In another example, a pre-trained machine learning model is used to process the difference to determine multiple degrees of association. Additionally, based on the difference, the computing device first determines multiple association values between the multiple associated objects and the target object. Then, the computing device adjusts the multiple association values to transform them into values within a predetermined range, for example, all mapped to the range of 0-1, to represent the degree of association between the multiple associated objects and the target object.
[0047] Alternatively, when determining the degree of association between multiple related objects and the target object based on the first and second prediction results, the degree of association can also be determined by applying the first and second prediction results to the Shapley value algorithm. For example, the Shapley value formula above can be used to calculate the degree of association.
[0048] Alternatively, the computing device can employ any suitable method to determine multiple degrees of association between multiple related objects and the target object for a prediction task, based on multiple sampling weights and a knowledge graph. For example, multiple degrees of association can be determined using a pre-trained neural network model.
[0049] Furthermore, the computing device 104 can interpret the prediction results of the target object's prediction task based on multiple degrees of correlation. This interpretation can indicate which correlated nodes have a greater impact on the target node's prediction task.
[0050] In one example, when predicting the failure of a target product, it is possible to identify which nodes in the knowledge graph correspond to the target objects that cause the failure. For instance, if nodes in the production process are highly correlated with the target node, while other processes are less correlated, the report can indicate that the production process has a higher probability of causing the product failure, requiring attention to improvement or adjustment of the production process. In another example, when predicting whether to increase or decrease the production plan for a specific customer, if the materials used in the product have a significant impact on increasing or decreasing the production plan for that specific customer, while other types of nodes have a smaller impact, the report can indicate that the choice of materials affects the production plan for the target customer; if the material quality is good, the production plan can be increased, etc. The above examples are only used to describe this disclosure and are not intended to specifically limit this disclosure. Additionally, the generated explanatory report may include any suitable information and can be set according to actual needs.
[0051] By using the sampling weights assigned by predefined knowledge, the degree of association between multiple related objects and the target object can be quickly determined for a prediction task. This allows for a reasonable interpretation of the prediction task's results and improves the user experience.
[0052] The following is combined Figure 3 A schematic diagram illustrating Example 300 for determining the degree of association with a target object according to embodiments of the present disclosure. This example can be derived from... Figure 1 The computing device 104 in the middle executes.
[0053] At box 302, computing device 104 performs data preprocessing. The computing device integrates data from heterogeneous data sources into the knowledge graph database. Additionally, computing device 104 first selects the required data fields and performs some data cleaning and formatting.
[0054] At box 304, the computing device performs data integration. For example, a predefined knowledge graph platform can be used to store the integrated data. At box 306, computing device 104 performs feature engineering and converts the triples into data in a predefined data format. Here, feature engineering is a graph query. By using appropriate business logic queries, many application tools can be used to convert the query triples into the predefined data format. The converted dataset can then be fed into a model and trained.
[0055] At box 308, the computing device selects a machine learning model. As mentioned above, there is considerable flexibility in model selection. The only requirement for the model is compatibility between the model and the data format. Therefore, if the prediction task to be performed has been determined, any suitable model corresponding to that prediction task can be selected, such as any pre-trained neural network model that can be used to perform that prediction task. In one example, when performing a fault prediction task, any pre-trained machine learning model that can predict component faults or a fault prediction model trained using sample nodes in a knowledge graph can be used. Therefore, there are no restrictions on model selection. Users are free to define the criteria for selecting a model. More accurate models tend to have greater acceptance in interpreting subsequent results.
[0056] In box 310, computing device 104 performs predictive interpretation. This process determines the degree of association between multiple related objects in the knowledge graph and the target object. The Shapley value algorithm can be used in this process. The equivalent expression for the Shapley value related to node i in the knowledge graph can be represented by the following formula (1):
[0057]
[0058] Where N is the set of all nodes, n is the number of all nodes, S is the subset of N excluding node i, v(S) represents the predicted value for set S, and v(S∪{i}) represents the predicted value including node i and set S. Let represent the binomial coefficient. The above formula can be expressed as the following formula (2):
[0059]
[0060] Monte Carlo Tree Search (MCTS) can be used to approximate Shapley values. MCTS can be divided into four phases, with the initial node selection phase being relatively simple. For most tasks, only positive samples need to be interpreted. For example, an engineer might be interested in understanding the causes of component failures rather than focusing on every component that did not fail. In the node expansion phase, Monte Carlo sampling methods can be used. Here, the experience of domain experts is incorporated into the sampling process. This method uses expert-defined sampling weights. For example, if a sampling node is important, the sampling weight can be defined as 0.99. Therefore, the actual sampling weights can be defined by experts based on the node type. In the example above of determining production plans for customers, more sampling can be done on inventory and production status because, according to expert experience, they may have a greater impact on future order changes. In the simulation phase, an "with and without" strategy is used, consistent with the form of Shapley values mentioned earlier. By calculating the values of currently sampled nodes participating and not participating, the contribution of the current sampled node to the prediction result of the target node is estimated.
[0061] For example, the predictive interpretation process may include multiple sub-operations in boxes 312, 314, 316, 318, and 320. At box 312, the computing device performs interpretation set selection. At this point, positive sample nodes can be simply selected from the graph. Then, each node in the node set is traversed. At box 314, the computing device performs sampling strategy design. As described above, a biased sampler is developed based on expert experience using domain knowledge. This strategy may change due to shifts in business focus or developments in expert cognition. Additionally, statistical fitting can be performed on the data distribution in certain problems to make the generated interpretation robust.
[0062] At box 316, perform the computation with / without a target reference object or target reference node. After sampling the defined distribution, sampled neighbors or edges can be easily added and removed. Compute the predictions for both from the machine learning model. Store the results for the current node in the selected node set.
[0063] At box 318, Shapley value estimation is performed. This is a Monte Carlo method, which involves repeating the operations in boxes 314 and 316 above through multiple simulations. The computing device can then obtain a list of many samples and calculation results. The Shapley value of the current node is estimated using the formula mentioned above. Then, proceed to box 312 and move to the next node.
[0064] At box 320, after performing the aforementioned calculations on each node, computing device 104 can obtain the Shapley values for all nodes. Therefore, the Shapley values can be used for interpretation. At this point, the generated report not only includes metrics related to the Shapley values and instance-level explanations, but also model-level explanations, data quality checks, and data interpretation.
[0065] Furthermore, the machine learning model can be evaluated. In the construction of the machine learning model described above, it was emphasized that the evaluation method for model selection can be customized. Here, evaluation refers to the evaluation of the final interpretation. Therefore, visualization methods can be used at this stage, leaving the judgment of the model results to domain experts.
[0066] In addition, the evaluation of graph models typically involves assessing fidelity, sparsity, stability, and accuracy. Furthermore, comprehensive metrics specifically designed for these metrics can also be used. Therefore, a holistic explanation can be provided in the report, including model-level metric data, instance-level node contributions, and some traditional model and data evaluation data and metrics. Fidelity and sparsity are represented by the following formulas (3) and (4), respectively:
[0067]
[0068] Where N is the number of nodes (when classifying nodes), G i =G is a single graph instance, E i ∈V(G i ) is the interpretation set; G i \E i It is a masked graph, where E i The node's characteristics are set to 0; Is the model in class y i The confidence level and output of the prediction.
[0069] By using the sampling weights assigned by predefined knowledge, the degree of association between multiple related objects and the target object can be quickly determined for a prediction task. This allows for a reasonable interpretation of the prediction task's results and improves the user experience.
[0070] The following is combined Figure 4 and Figure 5 Describe examples used to determine multiple degrees of association for a target node in a knowledge graph. Among them, Figure 4 An example of a knowledge graph including a target component according to an embodiment of the present disclosure is illustrated, and correspondingly Figure 5 The illustration shows an example of the degree of relevance to the target component according to an embodiment of the present disclosure.
[0071] For example, Figure 4Example 400 represents a knowledge graph associated with the target product. Additionally, it may be a portion of a larger knowledge graph extracted or retrieved from a factory or enterprise based on relevant expert experience.
[0072] Node 416 represents the target product. The goal is to predict whether the target product has failed and to determine the cause of the failure. Alternatively, or additionally, the target product has already failed; this could be a positive sample for the machine learning model performing the prediction. Further investigation is needed to determine the cause of the failure.
[0073] Nodes 410, 404, 406, 412, and 414 are nodes related to the production process, such as the first machine used in the production process, the second machine produced, and the production line. Nodes 402 and 408 represent different raw materials used in the production process. Nodes 418, 422, 420, and 424 can represent different nodes in the product design process, such as different design steps. Therefore, when determining the impact of other nodes associated with node 416 on the node's failure, computing device 104 can assign different sampling weights to these nodes based on expert knowledge related to failure detection. Next, a target reference node in the knowledge graph is determined using these different sampling weights. Then, the knowledge graph and the knowledge graph without the selected target reference node are input into a machine learning model to perform failure prediction. This operation is then repeated a predetermined number of times. This allows for the determination of many pairs of such predicted values. These pairs of predicted values are then processed using a predetermined method, such as the Shapley value algorithm, to determine the degree of correlation between the impact of other nodes in the knowledge graph on the failure of node 416. Figure 4 As shown, an example 500 illustrates the degree of correlation between nodes and the target component. As shown in Example 500, the numerical values between nodes indicate the degree of influence of connected nodes on the failure of node 416. It can be seen that nodes adjacent to node 416 have a greater impact on node 416, while the impact of peripheral nodes is relatively smaller. Therefore, the correlation values of these nodes can be used to further describe which factors caused the failure of component 416. Additionally, the correlation of the nodes in the graph can be visualized as part of interpretability, allowing experts to evaluate and select the factors that have the greatest impact on node 416.
[0074] The following is combined Figure 6 and Figure 7 This describes another example used to determine the degree of association for a target node in a knowledge graph. Among them, Figure 6 The illustration shows another example 600 of a knowledge graph including target components according to an embodiment of the present disclosure, corresponding to... Figure 7 Another example 700 illustrating the degree of relevance to the target component according to an embodiment of the present disclosure is shown.
[0075] Node 608 is a node corresponding to a product, and the prediction task could be to predict whether to increase its production plan for a specific customer. Node 602 is a node related to a specific customer, and nodes 604 and 606 contain information related to other components ordered by that specific customer. Nodes 612, 614, 616, and 618 contain information about other customer nodes, and node 610 is a node related to materials. Therefore, when determining the degree of association between other nodes and node 608, computing device 104 can assign different sampling weights to these nodes based on expert knowledge related to the production field. Next, the different sampling weights are used to determine a target reference node in the knowledge graph.
[0076] Then, the knowledge graph and the knowledge graph with the selected target reference node removed are input into the machine learning model to perform predictions of increasing the production plan. This operation is then repeated a predetermined number of times. This allows for the identification of many pairs of such predictions. These pairs of predictions are then processed using a predetermined method to determine the degree of relevance of other nodes in the knowledge graph to the impact of node 608 on increasing the production plan for a specific customer. Figure 7 As shown, an example 700 illustrates the degree of relevance to the target component. As shown in Example 700, the numerical values between nodes indicate the degree of influence of connected nodes on node 608's production schedule for a specific customer. It can be seen that nodes adjacent to node 608 have a greater impact on node 608, while the impact of peripheral nodes is relatively smaller. Therefore, these correlation values can be used to further describe which factors caused node 608 to increase its production schedule for a specific customer. Additionally, the correlation of nodes in the graph can be visualized as part of interpretability, allowing experts to evaluate and select the factors that have the greatest impact on node 608.
[0077] After determining the degree of association between multiple related objects in the knowledge graph and the target object for a prediction task, the determined degree of association can be used to perform various related operations. For example, the determined degree of association can be used to interpret the prediction results of the prediction task. The following section will combine... Figure 8 A flowchart describing a knowledge graph-based prediction method according to embodiments of the present disclosure is provided. This method can be... Figure 1 The computing device 104 or any suitable computing device in the system shall execute the test.
[0078] At box 802, computing device 104 determines the prediction result of a prediction task for a target object in a knowledge graph, as well as multiple degrees of association between multiple related objects in the knowledge graph and the target object for the prediction task. These multiple degrees of association are determined based on the knowledge graph and multiple sampling weights assigned to the multiple related objects, wherein the multiple sampling weights include at least two different sampling weights. Computing device 104 can utilize the data in the knowledge graph to perform a prediction task on the target object in the knowledge graph using a prediction algorithm. For example, when a component is included in the knowledge graph, the prediction task could be to predict whether the component is faulty. In this case, a machine learning model used to perform the prediction task can be used for prediction. Therefore, using the knowledge graph in conjunction with the prediction algorithm can provide a prediction result for the prediction task of the target object. Furthermore, for this prediction task, multiple degrees of association between multiple related objects and the target object can also be determined using the knowledge graph. The process for determining these degrees of association can refer to the method for determining the degree of association with the target object described in the preceding embodiments.
[0079] At box 804, computing device 104 generates a prediction interpretation of the prediction results for the prediction task of the target object based on multiple degrees of association. After obtaining multiple degrees of association, the prediction results can be interpreted. For example, based on multiple degrees of association, it can be determined which associated objects have a greater impact on the prediction results and which associated objects have a smaller impact on the prediction results. Additionally, these interpretations can be used to further generate corresponding interpretation reports.
[0080] Figure 9 A schematic diagram of an apparatus 900 for determining the degree of association with a target object according to an embodiment of the present disclosure is further shown. The apparatus 900 can be applied to a computing device 104 and may include multiple modules for performing tasks such as... Figure 2 The corresponding steps in method 200 discussed herein. For example... Figure 9 As shown, the apparatus 900 includes a sampling weight allocation module 902, configured to allocate multiple sampling weights to multiple associated objects in the knowledge graph based on predetermined knowledge related to the prediction task of the target object in the knowledge graph, wherein the multiple sampling weights include at least two different sampling weights; and an association degree determination module 904, configured to determine multiple association degrees between the multiple associated objects and the target object for the prediction task based on the multiple sampling weights and the knowledge graph.
[0081] In some embodiments, the association degree determination module 904 includes: a target associated object selection module, configured to select a target associated object from multiple associated objects based on multiple sampling weights; and an adjusted knowledge graph generation module, configured to generate an adjusted knowledge graph by removing the target associated object from the knowledge graph; and an object association degree determination module, configured to determine multiple association degrees between the multiple associated objects and the target object for the prediction task based on the knowledge graph and the adjusted knowledge graph.
[0082] In some embodiments, the target associated object selection module includes a weight-based selection module configured to select target associated objects from the knowledge graph using a Monte Carlo method based on multiple sampling weights.
[0083] In some embodiments, the object association degree determination module includes: a prediction result generation module configured to determine a first prediction result and a second prediction result for a prediction task targeting the target object based on a knowledge graph and an adjusted knowledge graph, respectively; and a prediction result determination module configured to determine multiple association degrees between multiple associated objects and the target object based on the first prediction result and the second prediction result.
[0084] In some embodiments, the prediction result generation module includes: a first prediction result determination module configured to determine a first prediction result related to the prediction task for a target object by applying a knowledge graph to a task prediction model; and a second prediction result determination module configured to determine a second prediction result related to the prediction task for a target object by applying an adjusted knowledge graph to a task prediction model.
[0085] In some embodiments, the determination module based on the prediction result includes: a difference determination module configured to determine the difference between the first prediction result and the second prediction result; and a difference-based determination module configured to determine multiple degrees of association between multiple associated objects and the target object based on the difference.
[0086] In some embodiments, the difference-based determination module includes: an association value determination module configured to determine multiple association values between multiple associated objects and a target object based on the difference; and an association value determination module configured to determine the degree of association between multiple associated objects and a target object by adjusting the multiple association values.
[0087] In some embodiments, the determination module based on the prediction results includes an application module configured to determine multiple degrees of association between multiple associated objects and a target object by applying a first prediction result and a second prediction result to a Shapley value algorithm.
[0088] In some embodiments, the sampling weight allocation module 902 includes: a plurality of type determination module configured to determine a plurality of types of a plurality of associated objects in a knowledge graph; and a sampling weight allocation module configured to allocate a plurality of sampling weights to a plurality of associated objects in a knowledge graph based on the plurality of types and predetermined knowledge related to the prediction task of the target object.
[0089] In some embodiments, the apparatus 900 further includes: a data collection module configured to collect multiple data from multiple different data sources; and a knowledge graph generation module configured to generate a knowledge graph based on the multiple data.
[0090] In some embodiments, the prediction task includes one of the following: failure prediction for the target object, production plan prediction for the target object, and recommendation prediction for the target object.
[0091] Figure 10 A schematic diagram of a knowledge graph-based prediction apparatus according to an embodiment of the present disclosure is further shown. The apparatus 1000 can be applied to a computing device 104, which may include multiple modules for performing tasks such as... Figure 8 The corresponding steps in method 800 discussed herein. For example... Figure 8 As shown, the apparatus 1000 includes a determining module 1002 configured to determine the prediction result of a prediction task for a target object in a knowledge graph and multiple degrees of association between multiple related objects in the knowledge graph and the target object for the prediction task, wherein the multiple degrees of association are determined based on the knowledge graph and multiple sampling weights assigned to the multiple related objects, wherein the multiple sampling weights include at least two different sampling weights; and a prediction interpretation generation module 1004 configured to generate a prediction interpretation of the prediction result of the prediction task for the target object based on the multiple degrees of association.
[0092] Figure 11 A schematic block diagram of an example computing device 1100 that can be used to implement embodiments of the present disclosure is shown. Figure 1 The computing device 104 can be implemented using the computing device 1100. As shown, the computing device 1100 includes a central processing unit (CPU) 1101, which can perform various appropriate actions and processes according to computer program instructions stored in read-only memory (ROM) 1102 or loaded from storage unit 1108 into random access memory (RAM) 1103. The RAM 1103 can also store various programs and data required for the operation of the computing device 1100. The CPU 1101, ROM 1102, and RAM 1103 are interconnected via a bus 1104. An input / output (I / O) interface 1105 is also connected to the bus 1104.
[0093] Multiple components in computing device 1100 are connected to I / O interface 1105, and may include, for example: input unit 1106, such as keyboard, mouse, etc.; output unit 1107, such as various types of displays, speakers, etc.; memory 1108, such as disk, optical disk, etc.; and communication unit 1109, such as network card, modem, wireless transceiver, etc. Communication unit 1109 allows computing device 1100 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0094] The various processes and procedures described above, such as methods 200 and 800, can be executed by processing unit 1101. For example, in some embodiments, methods 200 and 800 can be implemented as computer software programs tangibly contained in a machine-readable medium, such as storage unit 1108. In some embodiments, part or all of the computer program can be loaded and / or installed on computing device 1100 via ROM 1102 and / or communication unit 1109. When the computer program is loaded into RAM 1103 and executed by CPU 1101, one or more actions of methods 200 and 800 described above can be performed.
[0095] This disclosure can be a method, apparatus, system, and / or computer program product. A computer program product may include a computer-readable storage medium having computer-readable program instructions loaded thereon for performing various aspects of this disclosure.
[0096] A computer-readable storage medium can be a tangible device capable of holding and storing instructions for use by an instruction execution device. A computer-readable storage medium can be, for example—but not limited to—an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. More specific examples (a non-exhaustive list) of computer-readable storage media include: random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), and any suitable combination thereof. The computer-readable storage medium as used herein is not to be construed as a transient signal itself, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through waveguides or other transmission media (e.g., light pulses through fiber optic cables), or electrical signals transmitted through wires.
[0097] The computer-readable program instructions described herein can be downloaded from computer-readable storage media to various computing / processing devices, or downloaded via a network, such as the Internet, local area network, wide area network, and / or wireless network, to an external computer or external storage device. The network may include copper transmission cables, fiber optic transmission, wireless transmission, routers, firewalls, switches, gateway computers, and / or edge servers. A network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards them to the computer-readable storage media in the respective computing / processing device.
[0098] Computer program instructions used to perform the operations of this disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, status setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages such as Smalltalk, C++, etc., and conventional procedural programming languages such as the "C" language or similar programming languages. The computer-readable program instructions may execute entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or may be connected to an external computer (e.g., via the Internet using an Internet service provider). In some embodiments, electronic circuitry, such as programmable logic circuitry, field-programmable gate arrays (FPGAs), or programmable logic arrays (PLAs), is personalized by utilizing the status information of the computer-readable program instructions to implement various aspects of this disclosure.
[0099] Various aspects of this disclosure are described herein with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this disclosure. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer-readable program instructions.
[0100] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that, when executed by the processing unit of the computer or other programmable data processing apparatus, they create means for implementing the functions / actions specified in one or more blocks of the flowchart and / or block diagram. These computer-readable program instructions can also be stored in a computer-readable storage medium that causes a computer, programmable data processing apparatus, and / or other device to operate in a particular manner. Thus, the computer-readable medium storing the instructions comprises an article of manufacture that includes instructions for implementing aspects of the functions / actions specified in one or more blocks of the flowchart and / or block diagram.
[0101] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series of operational steps to be performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to perform the functions / actions specified in one or more boxes of a flowchart and / or block diagram.
[0102] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of an instruction containing one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions marked in the blocks may occur in a different order than those shown in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0103] The various embodiments of this disclosure have been described above. These descriptions are exemplary and not exhaustive, and are not limited to the disclosed embodiments. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments. The terminology used herein is chosen to best explain the principles, practical applications, or technical improvements to the technology in the market, or to enable others skilled in the art to understand the embodiments disclosed herein.
Claims
1. A method (200) for determining degrees of association with a target object, comprising: assigning (202), based on predetermined knowledge related to a prediction task of a target object in a knowledge graph, a plurality of sampling weights to a plurality of associated objects in the knowledge graph, wherein the plurality of sampling weights comprises at least two different sampling weights; and determining (204), based on the plurality of sampling weights and the knowledge graph, a plurality of degrees of association of the plurality of associated objects with the target object for the prediction task.
2. The method (200) of claim 1, wherein determining (204), based on the plurality of sampling weights and the knowledge graph, a plurality of degrees of association of the plurality of associated objects with the target object for the prediction task comprises: selecting, based on the plurality of sampling weights, a target associated object from the plurality of associated objects; and generating an adjusted knowledge graph by removing the target associated object from the knowledge graph; determining, based on the knowledge graph and the adjusted knowledge graph, the plurality of degrees of association of the plurality of associated objects with the target object for the prediction task.
3. The method (200) of claim 2, wherein selecting, based on the plurality of sampling weights, a target associated object from the plurality of associated objects comprises: selecting, based on the plurality of sampling weights, the target associated object from the knowledge graph by a Monte Carlo method.
4. The method (200) of claim 2, wherein determining, based on the knowledge graph and the adjusted knowledge graph, the plurality of degrees of association of the plurality of associated objects with the target object for the prediction task comprises: determining, based on the knowledge graph and the adjusted knowledge graph, a first prediction result and a second prediction result for the prediction task of the target object, respectively; and determining the plurality of degrees of association of the plurality of associated objects with the target object based on the first prediction result and the second prediction result.
5. The method (200) of claim 4, wherein determining, based on the knowledge graph and the adjusted knowledge graph, a first prediction result and a second prediction result for the prediction task of the target object, respectively, comprises: determining, by applying the knowledge graph to a task prediction model, a first prediction result related to the prediction task for the target object; and determining, by applying the adjusted knowledge graph to the task prediction model, a second prediction result related to the prediction task for the target object.
6. The method (200) of claim 4, wherein determining the degrees of association of the plurality of associated objects with the target object based on the first prediction result and the second prediction result comprises: determining a difference value of the first prediction result and the second prediction result; and determining the plurality of degrees of association of the plurality of associated objects with the target object based on the difference value.
7. The method (200) of claim 6, wherein determining the plurality of correlation degrees of the plurality of correlated objects to the target object based on the difference values comprises: determining a plurality of correlation values between the plurality of correlated objects and the target object based on the difference values; and determining the correlation degrees of the plurality of correlated objects to the target object by adjusting the plurality of correlation values.
8. The method (200) of claim 4, wherein determining the plurality of correlation degrees of the plurality of correlated objects to the target object based on the first prediction result and the second prediction result comprises: determining the plurality of correlation degrees of the plurality of correlated objects to the target object by applying the first prediction result and the second prediction result to a Shapley value algorithm.
9. The method (200) of claim 1, wherein assigning (202) a plurality of sampling weights to a plurality of correlated objects in a knowledge graph based on predetermined knowledge related to a prediction task of a target object in the knowledge graph comprises: determining a plurality of types of the plurality of correlated objects in the knowledge graph; and assigning the plurality of sampling weights to the plurality of correlated objects in the knowledge graph based on the plurality of types and the predetermined knowledge related to the prediction task of the target object.
10. The method (200) of claim 1, further comprising: collecting a plurality of data from a plurality of different data sources; and generating the knowledge graph based on the plurality of data.
11. The method (200) of claim 1, wherein the prediction task comprises one of: a failure prediction for the target object, a production plan prediction for the target object, a recommendation prediction for the target object.
12. A knowledge graph based prediction method (800), comprising: determining (802) a prediction result of a prediction task for a target object in a knowledge graph and a plurality of correlation degrees of a plurality of correlated objects in the knowledge graph to the target object for the prediction task, the plurality of correlation degrees being determined based on the knowledge graph and a plurality of sampling weights assigned to the plurality of correlated objects, wherein the plurality of sampling weights comprise at least two different sampling weights; and generating (804) a prediction explanation of the prediction result of the prediction task for the target object based on the plurality of correlation degrees.
13. An apparatus (900) for determining correlation degrees of a target object, comprising: a sampling weight assigning module (902) configured to assign a plurality of sampling weights to a plurality of correlated objects in a knowledge graph based on predetermined knowledge related to a prediction task of a target object in the knowledge graph, wherein the plurality of sampling weights comprise at least two different sampling weights; and a correlation degree determining module (904) configured to determine a plurality of correlation degrees of the plurality of correlated objects to the target object for the prediction task based on the plurality of sampling weights and the knowledge graph.
14. A knowledge graph based prediction apparatus (1000), comprising: determining, by a determining module (1002), a prediction result for a prediction task of a target object in the knowledge graph and a plurality of correlation degrees of a plurality of correlated objects in the knowledge graph to the target object for the prediction task, the plurality of correlation degrees being determined based on the knowledge graph and a plurality of sampling weights assigned to the plurality of correlated objects, wherein the plurality of sampling weights comprises at least two different sampling weights; and generating, by a prediction explanation generating module (1004), a prediction explanation for the prediction result of the prediction task of the target object based on the plurality of correlation degrees.
15. An electronic device (1100), comprising: at least one processor; and a memory coupled to the at least one processor and having stored thereon instructions which, when executed by the at least one processor, cause the electronic device to perform the method according to any one of claims 1-12.
16. A computer program product comprising computer-executable instructions, wherein the computer-executable instructions are executed by a processor to implement the method according to any one of claims 1 to 12.