Knowledge graph construction method, electronic device, and storage medium
By updating and partially editing object nodes in the knowledge graph and combining it with a generative language model, the problems of long update cycles and insufficient information coverage in existing technologies are solved, enabling dynamic updating and efficient construction of the knowledge graph.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HANGZHOU ALIBABA INT INTERNET IND CO LTD
- Filing Date
- 2026-03-31
- Publication Date
- 2026-07-10
AI Technical Summary
Existing knowledge graph construction methods rely on controlled, predefined knowledge systems, which cannot comprehensively cover product information. In particular, they cannot accurately obtain query results for new products, and the update cycle is long, making dynamic iteration impossible.
By responding to the object information of the object to be processed, the knowledge graph is updated based on the object information. Combined with the generative language model, the knowledge system is automatically expanded to achieve local updates and dynamic editing, including editing operations of object nodes, object type nodes, attribute name nodes, and attribute value nodes.
It enables dynamic updating and efficient construction of knowledge graphs, automatically expands knowledge content, improves the efficiency of knowledge graph construction and updating, and adapts to the addition of new products and information changes.
Smart Images

Figure CN122366631A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data processing technology, and in particular to a knowledge graph construction method, an electronic device, a storage medium, and a computer program product. Background Technology
[0002] In e-commerce platforms, product attribute data serves as a crucial infrastructure, playing a vital role by supporting multidimensional search navigation, improving search relevance, enhancing the accuracy of recommendation systems, and enabling large-scale semantic product understanding. Product knowledge graphs, with their ability to uniformly represent and constrain heterogeneous and noisy product information, thereby achieving standardized expression and information association of product attributes, are widely used to provide a data foundation for downstream tasks such as structured product data governance, eliminating model illusions during attribute extraction, personalized recommendations, product insights, and early warning monitoring. However, existing product knowledge graph technologies rely on controlled, predefined knowledge systems, resulting in incomplete coverage of product information. Especially for knowledge not present in the original attribute system, such as when a new product appears, it is impossible to accurately obtain relevant query results based on the knowledge graph.
[0003] On the other hand, the construction process of knowledge graphs in existing technologies requires a lot of manual review, and the knowledge graph update cycle is long, making it impossible to dynamically iterate and upgrade the knowledge graph as new products are added to the product library.
[0004] It is evident that existing knowledge graph construction methods still need improvement. Summary of the Invention
[0005] This application provides a knowledge graph construction method that can effectively improve the efficiency of knowledge graph construction and updating.
[0006] Accordingly, embodiments of this application also provide an electronic device, a storage medium, and a computer program product to ensure the implementation and application of the above-mentioned knowledge graph construction method.
[0007] To solve the above-mentioned technical problems, this application is implemented as follows: In a first aspect, embodiments of this application provide a knowledge graph construction method, the method comprising: In response to obtaining the object information of the object to be processed, the object node update process is performed on the knowledge graph to be updated based on the object information, and the object nodes associated with the object to be processed are determined. Based on the object information and the retrieval results of object types in the knowledge graph, an object type-related graph editing operation is performed on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type that matches the object to be processed; Following a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, graph editing operations related to different node types are sequentially performed on the locally updated knowledge graph to obtain the knowledge graph updated based on the object information.
[0008] In a second aspect, embodiments of this application provide an electronic device, which includes a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the method described in the first aspect.
[0009] Thirdly, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first aspect.
[0010] Fourthly, embodiments of this application provide a computer program product, including a computer program / computer executable instructions, which, when executed by a processor in an electronic device, implement the method described in the first aspect.
[0011] Compared with the prior art, the embodiments of this application have the following advantages: In response to the acquisition of object information of the object to be processed, object node update processing is performed on the knowledge graph to be updated based on the object information to determine the object nodes associated with the object to be processed. Then, based on the object information and the retrieval results of object types in the knowledge graph, graph editing operations related to object types are performed on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type that matches the object to be processed. Finally, according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, graph editing operations related to different node types are performed sequentially on the partially updated knowledge graph to obtain the knowledge graph updated based on the object information, thus realizing dynamic updating of the knowledge graph. In the process of constructing a knowledge graph using this method, it is not necessary to predefine a knowledge classification system. By combining the retrieval results of existing knowledge in the knowledge graph and the knowledge generation capabilities of generative language models, the knowledge system is automatically expanded and the knowledge content is enriched, effectively improving the construction and updating efficiency of the knowledge graph. Attached Figure Description
[0012] Figure 1 This is a flowchart illustrating the steps of the knowledge graph construction method disclosed in an embodiment of this application; Figure 2 This is a schematic diagram of the implementation process of the knowledge graph construction method disclosed in the embodiments of this application under one application scenario; Figure 3 This is another step of the knowledge graph construction method disclosed in the embodiments of this application; Figure 4 This is a schematic diagram of the technical framework of the knowledge graph construction method disclosed in the embodiments of this application; Figure 5 This is a schematic diagram of the structure of an exemplary device provided in one embodiment of this application. Detailed Implementation
[0013] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0014] The knowledge graph construction method disclosed in this application utilizes multi-agent collaboration for knowledge extraction and standardization, as well as knowledge graph writing, to achieve the inference, standardization, and storage of different types of knowledge in a specified application scenario. For example, in the scenario of constructing a product knowledge graph for an e-commerce platform, various reasoning agents with different functions infer knowledge such as product type, attribute names, and attribute values of each attribute name. A decision agent, based on the various knowledge inferred from the current product information, updates the product knowledge graph in real time. When a target object is discovered, this method can automatically infer a preset level of knowledge about the target object based on the object information and write the inferred knowledge into a pre-created object knowledge graph. This can be achieved by creating new nodes in the object knowledge graph and storing the inferred knowledge in the new nodes; or by updating the knowledge stored in existing nodes in the object knowledge graph using the inferred knowledge, thereby achieving the goal of real-time updating of the object knowledge graph.
[0015] like Figure 1 As shown, the knowledge graph construction method disclosed in this application includes steps 102 to 106.
[0016] The knowledge graph constructed by the method disclosed in this application includes multiple types of nodes, and there are hierarchical relationships between the knowledge recorded by different types of nodes. Therefore, when updating the knowledge graph based on each object information, it is necessary to edit the different nodes of the knowledge graph in a certain order. Taking the node types in the knowledge graph as including: object nodes, object type nodes, attribute name nodes, and attribute value nodes, the node editing order from first to last is: object node, object type node, attribute name node, and attribute value node. Each type of node is used to store structured knowledge of different knowledge entities, which is referred to as "metadata" in this application embodiment.
[0017] The definitions of various nodes are introduced below.
[0018] (a) Object Node Each object node is associated with an object and stores the object's metadata. The metadata content stored in the object node is determined based on the application scenario. Taking the construction scenario of a product knowledge graph on an e-commerce platform as an example, the metadata stored in the object node includes, but is not limited to, one or more of the following information: product name, product title, category, detailed description, and product image. In the product knowledge graph, one object node is created for each product.
[0019] (ii) Object type node The object type nodes are associated one-to-one with object types and are used to store the metadata of the object types. The metadata of the object types includes, but is not limited to, one or more of the following: object type values (such as object type name), the definition of the object type value, the reasoning basis, and reasoning cases. Taking the construction scenario of a product knowledge graph on an e-commerce platform as an example, the metadata stored in the object type nodes includes, but is not limited to, one or more of the following: product category name, the definition of the current product category, the reasoning basis, and reasoning cases. In the product knowledge graph, each product category is associated with one object type node. For example, in an electronic product knowledge graph, each electronic product category can be associated with a separate node. Specifically, styluses, mice, and tablets are associated with different object type nodes. The metadata stored in the object type nodes is obtained through reasoning by an inference agent that matches the object types.
[0020] (iii) Attribute Name Node In the process of constructing a knowledge graph using the knowledge graph construction method disclosed in the embodiments of this application, each object type includes one or more attributes. These attributes are identified by attribute names; that is, each object type is matched with one or more attribute names, and each attribute name is associated with an attribute name node. In other words, each attribute name node is associated one-to-one with the attribute names of the object. Taking the product knowledge graph construction scenario of an e-commerce platform as an example, for an object type with the value "stylus," its matched attribute names include, but are not limited to, one or more of the following: touch method, information transmission method, and material.
[0021] Given the known object type, the first reasoning agent, through attribute name matching, can infer the attribute names associated with each known object type matched by the current object based on the object information. When the object type (i.e., product type) matched by product A is "stylus" based on the product information, the first reasoning agent can further infer which attribute name(s) of "stylus" matched by product A based on the product information.
[0022] (iv) Attribute value node Optionally, the attribute value nodes are associated one-to-one with attribute values. In the process of constructing a knowledge graph using the knowledge graph construction method disclosed in this application, different attribute value nodes are created for each attribute value to store metadata of the attribute value corresponding to the attribute name. Each attribute name allows one or more attribute values, which describe the specific value of the attribute value for the corresponding attribute name. Taking the product knowledge graph construction scenario of an e-commerce platform as an example, for an object type with the value "stylus," its compatible attribute names include, but are not limited to, one or more of the following: touch mode, information transmission mode, and material. Furthermore, for the attribute name "information transmission mode," its allowed attribute values include, but are not limited to, one or more of the following: Bluetooth transmission, near-field communication transmission, and wireless communication transmission.
[0023] Optionally, given the known object type and attribute name, a second reasoning agent can infer different attribute values for the "information transmission method" attribute name for each known object type matched by the current object based on the object information. For example, it can infer that the "information transmission method" of product A, which is a "stylus," is Bluetooth transmission and / or near-field communication transmission and / or wireless communication transmission material.
[0024] In specific implementation, the constructed knowledge graph may also include other nodes, which will not be listed one by one in this embodiment. The node types and knowledge architecture relationships in the knowledge graph are determined according to the specific application scenario, and at least include: object nodes, object type nodes associated with the object type knowledge matched by the object node, attribute name nodes associated with the attribute name knowledge adapted to the object type, and attribute value nodes associated with the attribute name knowledge allowed by the attribute name node.
[0025] The following is combined with Figure 1 and Figure 2 Examples illustrate the specific implementation of each step in the knowledge graph construction method disclosed in the embodiments of this application.
[0026] Step 102: In response to obtaining the object information of the object to be processed, the object node update process is performed on the knowledge graph to be updated based on the object information, and the object node associated with the object to be processed is determined.
[0027] The knowledge graph construction method disclosed in this application can automatically expand the knowledge graph from an empty graph to include several nodes and edges as objects are added and / or the knowledge associated with those objects is supplemented. That is, the knowledge graph to be updated can be an initially empty knowledge graph, or a graph that has been updated multiple times and has been inscribed with knowledge associated with several objects.
[0028] The object information refers to information describing knowledge related to the object. Taking the construction of a product knowledge graph for an e-commerce platform as an example, the object to be processed is the product, and the object information is product information.
[0029] In the embodiments of this application, after obtaining the object information of the object to be processed, the object to be processed is first compared with existing objects in the knowledge graph to be updated to determine whether the object to be processed is a new object. If the object to be processed is determined to be a new object, an object node is created in the knowledge graph to be updated, and the object node is associated with the object to be processed. Optionally, whether the object to be processed is a new object can be determined by checking whether the object identifier of the object to be processed exists among the object identifiers associated with existing object nodes in the knowledge graph to be updated. Alternatively, the object node can be associated with the object to be processed by storing the object identifier of the object to be processed in the created object node.
[0030] Taking the construction of a product knowledge graph for an e-commerce platform as an example, in the process of storing product information of existing products in the e-commerce platform into the product knowledge graph, each product processed sequentially is an object to be processed. When a new product is released on the e-commerce platform, an object node needs to be created for that new product. When the product information of an existing product in the product knowledge graph is updated, such as when a mobile phone adds a charging method, the product is considered an existing product, and there is no need to create a new object node for that product.
[0031] When the object identifier is known, the specific implementation of creating the object node associated with the object to be processed in the knowledge graph to be updated is described in the prior art, and will not be repeated in the embodiments of this application.
[0032] Next, for the current object to be processed, based on the object information of the object to be processed and the existing object type-related knowledge in the knowledge graph, a knowledge graph editing operation is performed.
[0033] Step 104: Based on the object information and the retrieval results of object types in the knowledge graph, perform graph editing operations related to object types on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type that matches the object to be processed.
[0034] The knowledge graph editing operations performed in this step include: editing the object type nodes associated with object types in the knowledge graph and the edges connecting the object type nodes.
[0035] Optionally, the step of performing object type-related graph editing operations on the knowledge graph based on the object information and the retrieval results of object types in the knowledge graph to obtain a partially updated knowledge graph includes: sub-steps A1 to A4.
[0036] Sub-step A1: Using an object type matching reasoning agent, candidate proposals and reasoning descriptions of the object type matching the object to be processed are generated based on the object information.
[0037] The reasoning agent for object type matching can be a reasoning unit obtained by fine-tuning a generative language model. The reasoning description includes, but is not limited to, the following information: the reasoning basis of the candidate proposal, reasoning examples, and object type definitions.
[0038] Optionally, the object type matching inference agent generates prompt information based on the object information, and describes in the prompt information the rules for inferring candidate proposals for object types based on the object information, as well as the requirement instruction for generating an inference description. Then, based on the prompt information, the generative language model is triggered to perform object type inference operations to obtain candidate proposals for object types output by the generative language model. Simultaneously, the inference process of the candidate proposals is output as an inference description. For example, prompt information is generated based on the product name, product title, category, detailed description, and product image, and the prompt information guides the generative language model to infer the product type matching the current product based on the product name, product title, category, detailed description, and product image. The inferred product type will serve as a candidate proposal for the object type.
[0039] Optionally, the reasoning agent is built based on a multimodal generative language model. When using the reasoning agent to generate candidate proposals and reasoning descriptions, the object information input to the reasoning agent is multimodal information, which includes object description text and object images. That is, using an object type matching reasoning agent, candidate proposals and reasoning descriptions matching the object type to be processed are generated based on multimodal information, where the multimodal information includes object description text and object images. Specifically, for example, the multimodal information includes: product name, product title, category, detailed description, and product image.
[0040] Sub-step A2: Based on the similarity of the object types corresponding to the nodes, retrieve nodes in the knowledge graph that correspond to a specified number of object types similar to the candidate proposal, and use them as candidate update nodes.
[0041] Optionally, the step of retrieving nodes corresponding to a specified number of object types similar to the candidate proposal in the knowledge graph based on the object type similarity of the nodes, as candidate update nodes, includes: obtaining vector representations of the object types associated with each object type node in the knowledge graph as a first vector representation, and obtaining vector representations of the candidate proposal as a second vector representation; calculating the semantic similarity between the object types associated with each object type node in the knowledge graph and the candidate proposal based on the first vector representation and the second vector representation; and selecting a specified number of object type nodes associated with each object type in the knowledge graph as candidate update nodes in descending order of semantic similarity. The specified number is less than or equal to a preset number, which is determined according to specific application requirements; for example, the preset number can be 10.
[0042] Optionally, existing multilingual text embedding models can be used to embed and encode the object types associated with each object type node in the knowledge graph to obtain vector representations of the object types associated with each object type node. The multilingual text embedding model can also be used to embed and encode the candidate proposals to obtain vector representations of the candidate proposals.
[0043] Optionally, the semantic similarity between the corresponding object type in the knowledge graph and the candidate proposal is obtained by calculating the Euclidean distance between each of the first vector representations and the second vector representations. The smaller the Euclidean distance, the higher the semantic similarity. The method for calculating the Euclidean distance is described in the prior art for calculating the Euclidean distance of multidimensional spatial vectors, and will not be repeated in this embodiment.
[0044] When selecting a preset number of object type nodes associated with object types in the knowledge graph according to the order of semantic similarity from largest to smallest, if the number of object type nodes is less than the preset number, then the specified number is equal to the number of object type nodes.
[0045] As mentioned earlier, the metadata stored in each node includes: the value of the corresponding node type and the inference description corresponding to the value. For example, the metadata stored in the object type node associated with the object type includes: the value of the object type and the inference description of the value of the object type obtained by the generative language model.
[0046] Sub-step A3 involves employing a decision-making agent to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node.
[0047] Optionally, the step of employing a decision-making agent to infer and select a node editing action based on the candidate proposal, the inference description, and the metadata recorded in each candidate update node includes: employing the decision-making agent to generate prompt information based on the candidate proposal, the inference description, and the metadata recorded in each candidate update node, and guiding a preset generative language model to infer and select a node editing action according to preset decision criteria through the prompt information. The decision-making agent can be a decision unit obtained by fine-tuning a generative language model.
[0048] Optionally, the prompt information may include the preset decision criteria.
[0049] Optionally, guiding a pre-defined generative language model to select node editing actions based on preset decision criteria through the prompt information includes: guiding the pre-defined generative language model to select node editing actions within a preset action space based on preset decision criteria through the prompt information. For example, the prompt information defines the node editing actions included in the preset action space, so that the pre-defined generative language model reasons within a finite set, thereby effectively reducing the illusion interference of the generative language model and improving the standardization and accuracy of the reasoning results.
[0050] Optionally, the preset action space includes the following node editing actions: a first node editing action, used to indicate abandoning the update of the knowledge graph based on the candidate proposal; a second node editing action, used to indicate creating a new node to record the candidate proposal; a third node editing action, used to indicate merging the candidate proposal into the specified candidate update node; and a fourth node editing action, used to indicate replacing the metadata in the specified candidate update node with the candidate proposal and the inference description.
[0051] Accordingly, the preset decision criteria include one or more of the following: when the first node editing action is selected, the invalidity condition satisfied by the candidate proposal and / or the reasoning description; when the second node editing action is selected, the value of the candidate proposal and the corresponding node type recorded in each of the candidate update nodes are different from the corresponding node type judgment condition; when the third node editing action is selected, the condition that the candidate proposal and the value of the corresponding node type recorded in the specified candidate update node are synonyms or variants; when the fourth node editing action is selected, the condition that the candidate proposal is a normalized description of the value of the corresponding node type recorded in the specified candidate update node.
[0052] The invalidity conditions include, but are not limited to, one or more of the following: the candidate proposal is an invalid value, the semantics are unclear, or the reasoning basis is incomplete. For example, this could be based on determining whether the candidate proposal is a valid attribute name or attribute value, whether the meaning of the candidate proposal is clear, or whether the reasoning process described in the reasoning description lacks a reasoning basis.
[0053] Optionally, the decision-making agent is a decision-making unit constructed based on a generative language model. The generative language model is selected based on indicators such as inference performance requirements, resource consumption, and running speed. A generative language model that meets the performance requirements, consumes few resources, and runs quickly is preferred.
[0054] In some alternative embodiments, the step of employing a decision-making agent to infer and select a node editing action based on the candidate proposal, the inference description, and the metadata recorded in each of the candidate update nodes includes: employing the decision-making agent to generate prompt information based on the candidate proposal, the inference description, and the metadata recorded in each of the candidate update nodes, and using the prompt information to guide a preset generative language model to infer and select a node editing action according to preset decision criteria and generate a confidence score for the selected node editing action. That is, the prompt information also includes an instruction instructing the preset generative language model to generate a confidence score for the selected node editing action.
[0055] Optionally, the preset generative language model, based on preset decision criteria, infers and selects a node editing action in a preset action space. This selection can be any of the following: a first node editing action, a second node editing action, a third node editing action, or a fourth node editing action. The selected node editing action can be represented by a node editing action number and / or an associated node identifier. For example, when the selected node editing action is the first node editing action, the preset generative language model will output the preset number of the selected node editing action. As another example, when the selected node editing action is the second node editing action, the preset generative language model will output the preset number of the selected node editing action. Furthermore, when the selected node editing action is the third or fourth node editing action, the preset generative language model will simultaneously output the preset number of the selected node editing action, as well as the associated node number (such as the number of the candidate update node to be merged or replaced).
[0056] The specific implementation of the pre-defined generative language model, guided by prompts, reasoning and selecting node editing actions in a pre-defined action space according to pre-defined decision criteria, and generating the confidence level of the selected node editing actions, is described in the prior art and will not be repeated here.
[0057] Sub-step A4: Execute the selected node editing action to edit the target node in the knowledge graph, as well as the edge between the object node and the target node, to obtain a locally updated knowledge graph, wherein the target node is: the node associated with the target object type.
[0058] After reasoning to obtain the node editing action to be performed for the current candidate proposal, the node editing action is further executed.
[0059] Optionally, the execution of the selected node editing action to edit the target node in the knowledge graph, as well as the edge between the object node and the target node, to obtain a locally updated knowledge graph, includes any of the following operations.
[0060] (a) Execute the first node editing action When the node editing action is the first node editing action, the operation of updating the knowledge graph based on the object information ends. For example, when a candidate proposal is invalid, the editing of the knowledge graph based on the candidate proposal is abandoned.
[0061] (ii) Execute the second node editing action When the node editing action is the second node editing action, an object type node associated with the candidate proposal is created as the target node. Then, an edge is established connecting the object node associated with the object to be processed and the target node.
[0062] (iii) Execute the third node editing action When the node editing action is the third node editing action, the object type node associated with the third node editing action is taken as the target node. Information merging processing is performed on the metadata, candidate proposals, and inference descriptions in the target node. Then, the metadata in the target node is updated based on the merging processing result. Afterwards, an edge connecting the object node associated with the object to be processed and the target node is established. The information merging processing includes, but is not limited to: using the candidate proposal as a synonym or variant of the value of the canonical node type in the target node; using the candidate proposal as a normalized value of the node type in the target node; and storing the original node type value as a synonym or variant of the node type in the target node.
[0063] Optionally, the method further includes storing object type merging processing information in the target node. The object type merging processing information may be a synonym or variant of a standard object type, or it may be tagging information indicating that the metadata stored in the target node is the result of the merging process.
[0064] Optionally, a generative language model can be used to perform information merging processing on the metadata, candidate proposals, and inference descriptions in the target node to obtain a merging result. The merging result includes: the value of the object type node and the inference description of that value.
[0065] (iv) Perform the fourth node editing action When the node editing action is the fourth node editing action, the object type node associated with the fourth node editing action is used as the target node, and the metadata in the target node is replaced with the candidate proposal and the inference description. Then, an edge is established connecting the object node associated with the object to be processed and the target node.
[0066] For specific implementation methods of creating nodes, edges, and updating node metadata in a knowledge graph, please refer to existing technologies, which will not be repeated here.
[0067] This concludes the operations of editing object type nodes based on the object information of the current object to be processed, as well as editing the edges connecting object type nodes to object nodes.
[0068] As mentioned above, the decision agent is a decision unit constructed based on a generative language model. Optionally, when the preset generative language model outputs the confidence level of selecting the node editing action while inferring the selection of the node editing action, after executing the adoption decision agent to infer the selection of the node editing action based on the candidate proposal, the inference description, and the metadata recorded in each of the candidate update nodes, the method further includes: determining whether the confidence level of the node editing action meets the preset decision agent switching conditions, and obtaining a determination result; if the determination result indicates that the confidence level is less than or equal to a preset confidence threshold, switching the generative language model used to construct the decision agent to the target generative language model, and re-executing the step of adopting the decision agent to infer the selection of the node editing action based on the candidate proposal, the inference description, and the metadata recorded in each of the candidate update nodes.
[0069] The preset confidence threshold can be determined based on the test results. For example, the preset confidence threshold can be set to 0.9. If the judgment result indicates that the confidence level is less than or equal to the preset confidence threshold, it means that the confidence level of the node editing action selected by the generative language model in the current decision agent is low, and a higher-performance generative language model is needed to select the node editing action. The inference performance of the target generative language model is higher than that of the generative language model currently invoked by the decision agent.
[0070] By switching the generative language model invoked by the decision agent to a higher-performance generative language model when the confidence of the selected node editing action is low, the confidence of the selected node editing action can be improved, the risk of erroneous writing and erroneous merging can be reduced, and thus the accuracy of knowledge in the knowledge graph can be improved.
[0071] In some optional embodiments, for node editing actions with a confidence level greater than or equal to the preset confidence threshold, sampling is performed according to a preset period and proportion. A decision agent built on a higher-performance generative language model is then used to infer and select node editing actions for verification. If the verification result indicates that the confidence level of a node editing action is low, the generative language model invoked by the decision agent is switched to a higher-performance generative language model to increase the confidence level of the selected node editing action, reduce the risk of erroneous writing and malfunctioning merging, and thus improve the accuracy of knowledge in the knowledge graph.
[0072] Step 106: Following a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, perform graph editing operations related to different node types on the locally updated knowledge graph in sequence to obtain the knowledge graph updated based on the object information.
[0073] After editing the object node and object type node of the knowledge graph based on a single object piece of information, the subsequent type nodes of the object type node are then edited. For example, the attribute name node and attribute value node are edited sequentially.
[0074] As mentioned above, when performing an object type node editing operation on a knowledge graph based on a piece of object information to obtain a partially updated knowledge graph, the object type node targeted by the editing operation has been determined, i.e., the target node described in the embodiments of this application. Optionally, the target node for editing based on a piece of object information can be one target node or multiple target nodes. For example, an electromagnetic stylus pen, or for an object to be processed with the product title "scanning pen with recording function," the inferred candidate object type proposals may be "scanning pen," "recording pen," or both. Accordingly, when performing an object type node editing operation on the knowledge graph based on the candidate proposal, the edited object type node may include one or two of the following: the object type node associated with the scanning pen, and the object type node associated with the recording pen.
[0075] Next, using the neighborhood subgraph of the target node as the subgraph of the target object type, the editing operations of attribute name nodes and associated edges, and the editing operations of attribute value nodes and associated edges are performed sequentially within the neighborhood subgraph.
[0076] Optionally, the step of sequentially performing editing operations on nodes of different node types and editing operations on the associated edges of corresponding node types in the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, includes: sequentially determining the current node type according to a preset node editing order, and performing knowledge graph editing operations under object type constraints for the current node type, wherein the knowledge graph editing operations include: sub-steps B1 to B6.
[0077] Sub-step B1: Determine the predecessor node of the current node type.
[0078] When the current node type is an attribute name node, the predecessor node of the current node type is the target node, that is, the node associated with the target object type. When the current node type is an attribute value node, the predecessor node of the current node type is the attribute name node that was edited based on the object information.
[0079] Sub-step B2: In the subgraph of the target object type in the locally updated knowledge graph, retrieve the node of the current node type.
[0080] Optionally, the subgraph of the target object type includes: the lower-level nodes of the target object type in the locally updated knowledge graph, and the edges connecting the target object type and each lower-level node. Optionally, by searching the locally updated knowledge graph, attribute name nodes connected to the target object type nodes by edges, and attribute value nodes connected to each attribute name node by edges, are obtained. The obtained connection relationships between the attribute name nodes, attribute value nodes, target object type nodes, and attribute name nodes, as well as the connection relationships between each attribute name node and attribute value node, are used as the subgraph of the target object type.
[0081] Next, in the subgraph of the target object type, nodes of the current node type are further retrieved. For example, when editing an attribute name node based on the object information of the object to be processed, i.e., when the current node type is an attribute name node, attribute name nodes are retrieved in the subgraph of the target object type, and a list of attribute name nodes that have edge connections with the target object type nodes is obtained, thus obtaining a list of attribute names adapted to the target object type. As another example, when editing an attribute value node based on the object information of the object to be processed, i.e., when the current node type is an attribute value node, attribute value nodes that have edge connections with specified attribute names are retrieved in the subgraph of the target object type, and a list of attribute value nodes that have edge connections with each attribute name node is obtained, thus obtaining the allowed attribute values for each attribute name adapted to the target object type.
[0082] The retrieval method for the locally updated knowledge graph is described in the prior art and will not be repeated in this embodiment.
[0083] Sub-step B3 involves employing a reasoning agent that matches the current node type to reason about candidate proposals and reasoning descriptions for the current node type based on the object information and / or the metadata of each retrieved node record.
[0084] Subsequently, an inference agent matching the current node type is used to infer candidate proposals and inference descriptions for the current node type based on the object information and the metadata of each retrieved node record. For example, a first inference agent matching the attribute name is used to infer candidate proposals and inference descriptions for the attribute name based on the metadata of each retrieved attribute name node record. As another example, a second inference agent matching the attribute value is used to infer candidate proposals and inference descriptions for allowed attribute values for a specified attribute name based on the object information and the metadata of each retrieved attribute value node record.
[0085] Optionally, the reasoning agent matching the current node type is built based on a multimodal generative language model. When the reasoning agent matching the current node type infers candidate proposals and reasoning descriptions for the current node type based on the object information and / or the metadata of each retrieved node record, the object information input to the reasoning agent is multimodal information, which includes: object description text and object image. That is, the reasoning agent matching the current node type infers candidate proposals and reasoning descriptions for the current node type based on multimodal information and / or the metadata of each retrieved node record.
[0086] The first reasoning agent and the second reasoning agent can be reasoning units obtained by fine-tuning a generative language model.
[0087] Sub-step B4: Based on the similarity between the candidate proposal and the current node type, select a specified number of nodes from the retrieved current node type nodes as candidate update nodes.
[0088] The similarity can be semantic similarity.
[0089] When the current node type is an attribute name node, the value of the current node type is the attribute name value. For example... Figure 2 As shown, taking a stylus as the target object type, the possible values for the attribute name include, but are not limited to, connection method and material. The attribute name value is stored in the attribute name node.
[0090] When the current node type is an attribute value node, the value of the current node type is an attribute value. For example... Figure 2 As shown, taking a stylus as the target object type, the allowed attribute values for the "Connection Method" attribute name include: wireless; the allowed attribute values for the "Material" attribute name include: ABS plastic. The attribute values are stored in the attribute value node.
[0091] Taking the retrieval of candidate update nodes for attribute names as an example, based on the similarity between the candidate proposal and the current node type value, a specified number of nodes are selected as candidate update nodes from the retrieved current node type nodes. This includes: obtaining the vector representation of the current node type value associated with each retrieved current node type node as a third vector representation, and obtaining the vector representation of the candidate proposal as a fourth vector representation; calculating the semantic similarity between the current node type associated with each current node type node and the candidate proposal based on the third and fourth vector representations; and selecting the specified number of current node type nodes as candidate update nodes in descending order of semantic similarity. The specified number is less than or equal to a preset number, which is determined according to specific application requirements; for example, the preset number can be 10.
[0092] The methods for obtaining the third and fourth vector representations are the same as those for obtaining the first and second vector representations described above, and will not be repeated here. The specific methods for calculating semantic similarity are described in the relevant embodiments above, and will not be repeated here. According to this method, when the current node type is an attribute name node, a specified number of attribute name nodes similar to the candidate proposals of the attribute name can be retrieved as candidate update nodes; when the current node type is an attribute value node, a specified number of attribute value nodes similar to the candidate proposals of the attribute value can be retrieved as candidate update nodes.
[0093] Sub-step B5 involves employing a decision-making agent to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node.
[0094] The decision-making agent, based on the candidate proposals, the reasoning descriptions, and the metadata recorded in each candidate update node, infers and selects the node editing action. For the specific implementation of this method, please refer to the relevant descriptions in the previous embodiments, which will not be repeated here.
[0095] Sub-step B6: Execute the selected node editing action to edit the nodes of the current node type and the associated edges of the nodes of the current node type in the locally updated knowledge graph, thereby obtaining the locally updated knowledge graph.
[0096] When the current node type is an attribute name node, the associated edges of the node of the current node type include: an edge connecting the attribute name node and the object type node, which indicates the compatibility between the object type and the attribute name. When the current node type is an attribute value node, the associated edges of the node of the current node type include: an edge connecting the attribute name node and the attribute value node, and an edge connecting the attribute value node and the object node. The edge connecting the attribute name node and the attribute value node indicates the allowed attribute values for the attribute name; the edge connecting the attribute value node and the object node indicates the attribute values of the object.
[0097] As mentioned above, the node editing action includes, but is not limited to, any one or more of the following: the first node editing action, the second node editing action, the third node editing action, and the fourth node editing action. Accordingly, the selected node editing action is executed to edit the nodes of the current node type and the associated edges of the nodes of the current node type in the locally updated knowledge graph, thereby obtaining the locally updated knowledge graph, including but not limited to any one of the following operations.
[0098] (a) Execute the first node editing action When the node editing action is the first node editing action, the operation of updating the knowledge graph based on the object information ends. For example, when a candidate proposal is invalid, the editing of the knowledge graph based on the candidate proposal is abandoned.
[0099] (ii) Execute the second node editing action When the node editing action is the second node editing action, a node of the current node type is created based on the candidate proposal and the inference description. Then, an edge is established connecting the created current node type node to its predecessor node and / or an edge is established connecting the created current node type node to the object node.
[0100] After the editing operation of the current node type is completed, the created current node type node will serve as the predecessor node of the next node type to be edited.
[0101] For example, for the object type "stylus", when the current node type is an attribute name node, an attribute name node associated with the attribute name "connection method" is created, and an edge is established connecting the created attribute name node (such as the attribute name node associated with the attribute name "connection method") and the object type node associated with the object type "stylus" (i.e., the target node described in this embodiment). Then, the attribute name node associated with the attribute name "connection method" is used as the predecessor node to continue the editing operation of the attribute value node.
[0102] For example, when the current node type is an attribute value node and the predecessor node is an attribute name node (such as the attribute name node associated with the attribute name "connection method"), an attribute value node associated with the attribute value "wireless" is created, and an edge is established connecting the created attribute value node (such as the attribute value node associated with the attribute value "wireless") and the current predecessor node (such as the attribute name node associated with the attribute name "connection method").
[0103] (iii) Execute the third node editing action When the node editing action is the third node editing action, information merging processing is performed on the metadata in the current node type node associated with the third node editing action, the current candidate proposal, and the current inference description. Then, the metadata in the current node type node associated with the third node editing action is updated based on the merging processing result. When the current node type is the last node type determined according to the node editing order, an edge is established between the created current node type node and the object node.
[0104] Optionally, information merging can be performed using a generative language model to obtain the merging result. The merging result includes: the value of the current node type and a reasoned description of that value.
[0105] For example, a generative language model is used to merge the metadata and candidate proposals for attribute names in the attribute name node associated with the third node's edit action, resulting in a merged attribute name knowledge. Then, the metadata in the attribute name node associated with the third node's edit action is updated based on this merged attribute name knowledge.
[0106] For example, a generative language model is used to merge the metadata and candidate proposals for attribute values in the attribute name node associated with the third node's edit action, resulting in a merged attribute value knowledge. Then, the metadata in the attribute value node associated with the third node's edit action is updated based on the merged attribute value knowledge. Finally, an edge is established between the updated attribute value node and the object node.
[0107] (iv) Perform the fourth node editing action When the node editing action is the fourth node editing action, the metadata in the current node type node associated with the fourth node editing action is replaced with the candidate proposal and the inference description. When the current node type is the last node type determined according to the node editing order, an edge is established between the created current node type node and the object node.
[0108] For example, candidate proposals based on attribute values and the inference description replace the metadata in the attribute value node associated with the fourth node editing action.
[0109] For example, candidate proposals based on attribute values and the inference description replace the metadata in the attribute value node associated with the fourth node editing action. Then, an edge is established connecting the attribute value node with the replaced metadata and the object node.
[0110] This completes one update of the knowledge graph based on the object information of a single object to be processed.
[0111] The knowledge graph constructed using the knowledge graph construction method disclosed in this application can be used as a knowledge base for generative language models, for retrieving object-related knowledge, and for providing a data foundation for downstream tasks during personalized recommendations. This application does not limit the specific usage of the knowledge graph constructed using the knowledge graph construction method disclosed in this application.
[0112] Optionally, after completing the graph update operation performed on each decision instance based on the decision-making agent, the system implementing this patented method automatically records the decision context of each decision instance as a system decision log, which serves as data support for system maintenance and quality monitoring. The decision context includes, but is not limited to, one or more of the following information: candidate proposals, inference descriptions, and metadata recorded in each candidate update node, as well as the node editing action selected for inference. The decision instance can be an instance making a decision on object type, an instance making a decision on attribute name, or an instance making a decision on attribute value.
[0113] by Figure 2 Taking the illustrated product knowledge graph construction process as an example, in the process of constructing the product knowledge graph, it is first initialized to empty. Then, when the product information of the product to be processed is obtained, the product knowledge graph is iteratively updated based on each piece of product information. The product knowledge graph after the i-th update can be denoted as PKG. iFor each piece of product information, the editing operations for the product node, product type node, attribute name node, and attribute value are performed sequentially.
[0114] Taking the (i+1)th product knowledge graph update operation as an example, the product knowledge graph at this time is the product knowledge graph after performing the i-th update operation, denoted as PKG. i The process of updating the knowledge graph of product 1 based on its product information includes the following four steps.
[0115] The first step is to edit the object node.
[0116] Product Knowledge Graph (PKG) i From the product nodes (i.e., object nodes), obtain the product knowledge graph PKG. i The system retrieves all existing product nodes and compares the product information recorded in the retrieved product nodes with the product information of product 1 to determine whether product 1 is a newly added product. If so, it adds the product to the product knowledge graph PKG. i Create a new object node, denoted as P1, to store the product information of product 1; otherwise, determine the product knowledge graph PKG. i The product node associated with product 1 is denoted as object node P1. The product knowledge graph PKG processed in this step is then... i This is recorded as a partial update of the knowledge graph PKG. i-1 .
[0117] The second step is to edit the object type node.
[0118] Based on the product information of product 1, product category reasoning is performed to obtain the product type, which serves as a candidate proposal for the object type. Then, the product knowledge graph PKG is retrieved. i The process begins by identifying nodes (i.e., object type nodes) that are highly similar to the inferred object type and using them as candidate update nodes for that object type. Then, based on the candidate object type proposals and the metadata recorded in the candidate update nodes, a generative language model is used to infer and select a node for editing. Finally, the selected node is edited, updating the product knowledge graph (PKG) with the product information for product 1. i The product type nodes (i.e., object type nodes) in the graph. Update operations on product type nodes include creating new product type nodes or updating the metadata within a product type node. The product type node operated on in this step is denoted as object type node T. The product knowledge graph PKG processed in this step... i This is recorded as a partial update of the knowledge graph PKG. i-2 .
[0119] The third step is to edit the attribute name node.
[0120] Knowledge graph PKG based on partial update i-2 The process begins by obtaining a subgraph of the object type node T from the second step. Next, the subgraph of object type node T is searched to obtain a list of attribute name nodes connected to object type node T. Then, based on the product information of product 1 and the metadata recorded in the attribute name nodes in the list, the attribute name of product 1 is inferred as a candidate proposal for the attribute name. The subgraph of object type node T is searched again, and based on the similarity of the values of the attribute name nodes, candidate update nodes for the attribute name are determined as the scope of node editing. Then, based on the candidate proposals for the attribute name and the metadata recorded in the candidate update nodes for the attribute name, a generative language model is used to infer and select the node editing operation. Finally, the selected node editing operation is executed, and the product information of product 1 is used to update the local update knowledge graph PKG. i-1 The knowledge graph consists of attribute name nodes and associated edges. Update operations on attribute name nodes include creating new attribute name nodes or updating metadata within attribute name nodes. The attribute name node operated on in this step is denoted as K, and the partially updated knowledge graph after this step is denoted as PKG. i-3 .
[0121] The fourth step is to edit the attribute value node.
[0122] The subgraph of object type node T is retrieved to obtain a list of attribute value nodes connected to attribute name node K. Then, based on the product information of product 1 and the metadata recorded in the attribute value nodes in the list, the attribute values of product 1 are inferred as candidate proposals for allowed attribute values by attribute name node K. Based on the similarity between the values of the attribute value nodes connected to attribute name node K and the candidate proposals, candidate update nodes for the attribute values are determined, serving as the scope for node editing. Next, based on the candidate proposals for the attribute values and the metadata recorded in the candidate update nodes, a generative language model is used to infer and select the node editing operation. Finally, the selected node editing operation is executed, and the product information of product 1 is used to update the local update knowledge graph PKG. i-3 The knowledge graph consists of attribute value nodes and associated edges. Update operations on attribute value nodes include creating new attribute value nodes or updating the metadata within attribute value nodes. The locally updated knowledge graph after this step is denoted as PKG. i+1 .
[0123] In summary, the knowledge graph construction method disclosed in this application, in response to obtaining object information of the object to be processed, performs object node update processing on the knowledge graph to be updated based on the object information to determine the object nodes associated with the object to be processed; then, based on the object information and the retrieval results of object types in the knowledge graph, performs graph editing operations related to object types on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type matched by the object to be processed; finally, according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, graph editing operations related to different node types are sequentially performed on the partially updated knowledge graph to obtain the knowledge graph updated based on the object information, thus realizing dynamic updating of the knowledge graph. In the process of constructing a knowledge graph using this method, it is not necessary to predefine a knowledge classification system. By combining the retrieval results of existing knowledge in the knowledge graph and the knowledge generation capabilities of a generative language model, the knowledge system is automatically expanded and the knowledge content is enriched, effectively improving the construction and updating efficiency of the knowledge graph. The knowledge graph constructed using this method can evolve in real time with the object database, continuously improving its accuracy, standardization, and coverage completeness.
[0124] The knowledge graph construction method disclosed in this application decouples object type induction, attribute name discovery, and attribute value extraction into multiple reasoning agents. Employing a multi-agent architecture, it forms an end-to-end automated process from object type induction to attribute name discovery, attribute value extraction, and finally, graph writing. Candidate proposals are uniformly represented as structured decisions (such as adding nodes, merging nodes, replacing canonical names, discarding noise, etc.), and written by a unified, action-constrained decision-making agent. This creates a closed loop between knowledge extraction and graph construction, enabling the system executing this method to run automatically, significantly reducing the manual cost and time consumption in knowledge graph construction. Furthermore, using a unified, action-constrained decision-making agent ensures global consistency while the knowledge graph dynamically evolves.
[0125] In the process of constructing a knowledge graph using the knowledge graph construction method disclosed in the embodiments of this application, a decision-making agent with restricted actions is used to make decisions, and each knowledge graph update is performed with constrained incremental operations to ensure that the evolution process is controllable and traceable, reduce the risk of error accumulation and structural drift, and enable the knowledge graph to have long-term maintainability and production availability.
[0126] On the other hand, this method first infers the object type, and then, under the constraints of the object type, infers related knowledge level by level, such as inferring attribute names and attribute values in sequence. This can reduce the binding of irrelevant attributes and incorrect attribute names. At the same time, it can reduce the decrease in accuracy caused by the illusion that the generative language model is prone to when inferring hierarchical knowledge at one time due to the complex and multi-hop problem of model inference.
[0127] Furthermore, this method retrieves similar knowledge (such as object type, attribute name, or attribute value) values and examples from existing knowledge graphs when reasoning about related knowledge, and inputs them as external knowledge into the reasoning agent. This reduces the illusion of generative language models, improves knowledge generalization and consistency in long-tail cases, and helps improve the accuracy of new knowledge extraction.
[0128] During the knowledge graph editing process, standardization and merging of object types, attribute names, or attribute values by executing third-node editing actions can reduce the fragmentation of knowledge representation and thus form a stable set of standard nodes.
[0129] See Figure 3 Based on the foregoing embodiments, in some optional embodiments, in order to improve the accuracy of the knowledge graph constructed using the knowledge graph construction method disclosed in the embodiments of this application, the method further includes step 108 during or after the knowledge graph is constructed.
[0130] Step 108: Evaluate each agent.
[0131] Optionally, the evaluation of each intelligent agent includes: evaluating the generation capabilities of each reasoning intelligent agent and evaluating the decision-making capabilities of the decision-making intelligent agent, so as to optimize each intelligent agent in a timely manner based on the evaluation results.
[0132] by Figure 4 Taking the system architecture shown as an example, the system for implementing the knowledge graph construction method disclosed in the embodiments of this application includes the following agents: an object type matching reasoning agent, a first reasoning agent (i.e., an attribute name matching reasoning agent), a second reasoning agent (i.e., an attribute value matching reasoning agent), a decision agent, a first evaluation agent, a second evaluation agent, and a third evaluation agent. The specific implementation methods of the object type matching reasoning agent, the first reasoning agent, the second reasoning agent, and the decision agent are described in the previous embodiments and will not be repeated here.
[0133] Optionally, the system further includes: an evaluation protocol configuration module, used to configure and store the evaluation protocols for the objects evaluated by the first evaluation agent, the second evaluation agent, and the third evaluation agent. The evaluation protocols include, but are not limited to, one or more of the following: evaluation metrics for object type generation capability, evaluation metrics for attribute name generation capability, evaluation metrics for attribute value generation capability, and knowledge graph evaluation metrics.
[0134] The specific implementation methods of the first evaluation agent, the second evaluation agent, and the third evaluation agent are described below.
[0135] The first evaluation agent is used to evaluate the generation capabilities of the inference agent matching the object type, the first inference agent, and the second inference agent.
[0136] (a) Evaluating reasoning agents that match object types Optionally, the node editing action includes a third node editing action. After the step of sequentially performing graph editing operations related to different node types on the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: obtaining object type effectiveness, object type compression rate, and object type coverage rate based on the number of object nodes in the knowledge graph, the number of object type nodes associated with the third node editing action, and the validity marking results of the object type nodes; using the weighted harmonic mean of the object type effectiveness, object type compression rate, and object type coverage rate as a comprehensive evaluation index for the object type matching reasoning agent; and evaluating the generation capability of the object type matching reasoning agent based on the comprehensive evaluation index. Wherein, the object type effectiveness represents the semantic correctness of the object type reasoning result, the object type compression rate represents the degree of redundancy removal of the object type reasoning result, and the object type coverage rate represents the practicality of the knowledge graph.
[0137] Optionally, based on the number of object nodes in the knowledge graph, the number of object type nodes associated with the third node editing action, and the validity marking results of the object type nodes, the object type effectiveness rate, object type compression rate, and object type coverage rate are obtained, including: obtaining the number of object nodes in the knowledge graph as a first quantity; obtaining the number of standard object type nodes in the knowledge graph as a second quantity, wherein the standard object type nodes are the object type nodes associated with the third node editing action; obtaining the number of object nodes in the knowledge graph that have edge connections with standard object type nodes as a third quantity, wherein the standard object type nodes are the object type nodes associated with the third node editing action; obtaining the object type effectiveness rate based on the validity marking results of sampled object type nodes in the knowledge graph; calculating the object type compression rate based on the ratio of the second quantity to the first quantity; and calculating the object type coverage rate based on the ratio of the third quantity to the first quantity. Optionally, when the node editing action is the third node editing action, the selected node editing action is executed to edit the target node in the knowledge graph, as well as the edge between the object node and the target node. In the resulting locally updated knowledge graph, the target node stores object type merging processing information. Correspondingly, it can be determined whether the object type node is a standard object type node by judging whether the object type node in the knowledge graph stores merging processing information.
[0138] Optionally, by sampling object type nodes in the knowledge graph and manually labeling the semantic correctness of the object types associated with the sampled object type nodes, a validity labeling result is obtained for the sampled object type nodes. For example, object type nodes associated with semantically correct object types are labeled as valid, while object type nodes associated with semantically incorrect object types are labeled as invalid. Furthermore, the proportion of valid object type nodes among the abstracted object type nodes can be used as the object type validity rate.
[0139] Optionally, when calculating the compression ratio of the object type, a formula can be used. Calculate the compression ratio of the object type ,in, This represents the second quantity (i.e., the number of object type nodes in the knowledge graph after normalization and merging). This represents the first quantity (i.e., the number of objects participating in the evaluation, which is also the number of existing object nodes in the knowledge graph).
[0140] Optionally, when calculating the object type coverage, the ratio of the third quantity to the first quantity can be used as the object type coverage.
[0141] Optionally, use the formula Calculate the weighted harmonic mean of the object type effectiveness, the object type compression rate, and the object type coverage, and use the weighted harmonic mean as a comprehensive evaluation index for the inference agent that matches the object type. .in, This indicates that the object type is efficient. Indicates the compression ratio of the object type. This indicates the coverage of the object type. The weight representing the efficiency of the object type. The weight representing the compression ratio of the object type. The weight representing the coverage of the object type. This is used to suppress inflated performance caused by excessive merging. Optionally, the weights of the object type effectiveness, object type compression ratio, and object type coverage can be set as follows: This is used to emphasize the semantic validity of object type reasoning results and suppress speculative strategies that improve compression ratios through aggressive merging but are semantically flawed.
[0142] The comprehensive evaluation index represents the overall knowledge efficiency of a knowledge graph after achieving a balance among semantic correctness, redundancy removal, and coverage. The larger the value of the comprehensive evaluation index, the higher the quality of object types in the knowledge graph, the more reasonable the merging of object types, the wider the applicability of the knowledge graph, and the higher its reliability.
[0143] (ii) Evaluating the generative capabilities of the first reasoning agent. The reasoning agent matching the current node type includes: a first reasoning agent for reasoning attribute names. Following a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, different node type-related graph editing operations are sequentially performed on the locally updated knowledge graph to obtain a knowledge graph updated based on the object information. The method further includes: evaluating the generation capability of the first reasoning agent by aggregating the attribute names and reliability priors generated by multiple first reasoning agents, using probabilistic precision and probabilistic recall.
[0144] Optionally, the step of evaluating the generation capability of the first inference agents by aggregating attribute names and reliability priors generated by multiple first inference agents and using probabilistic precision and probabilistic recall includes: forging attribute names based on pre-acquired attribute name inference instances for each of the first inference agents; aggregating the attribute names obtained by the first inference agents to obtain a set of attribute names; obtaining the attribute name effectiveness rate for each of the first inference agents based on the labeling results of the attribute names, and using the attribute name effectiveness rate as the reliability prior of the corresponding first inference agent; based on the... The reliability prior is described, and the probability that each attribute name in the set belongs to the true value of a preset potential attribute name is estimated. Based on the attribute name inferred by the first reasoning agent, the probability that the attribute name belongs to the true value of the preset potential attribute name, and the set, the probability precision and probability recall of the corresponding first reasoning agent are calculated respectively. For each first reasoning agent, the weighted harmonic mean of the reliability prior, the probability precision, and the probability recall of the first reasoning agent is used as the comprehensive evaluation index of the first reasoning agent. Based on the comprehensive evaluation index, the generation capability of the first reasoning agent is evaluated.
[0145] Optionally, the attribute name reasoning instance includes object type information. In some other optional embodiments, the attribute name reasoning instance may further include a reasoning description of the attribute name. The first reasoning agent is used to reason about the attribute name applicable to the object type based on the object type included in the attribute name reasoning instance.
[0146] Optionally, through the first reasoning agent The attribute names obtained through reasoning are sampled, and the semantic correctness of the sampled attribute names is manually labeled to obtain the labeling results of the attribute names. For example, the first push agent... Attribute names with correct semantics obtained through inference are marked as valid, while those with incorrect semantics are marked as invalid. Furthermore, the proportion of valid attribute names among the sampled attribute names can be used as the basis for determining the first inference agent. The attribute name validity rate is used to measure the credibility of attribute names generated by inference.
[0147] Optionally, the first-push intelligent agent The attribute name is effectively represented as For example, the first push intelligent agent The aforementioned reliability prior can be expressed as , .
[0148] Optionally, a Noisy-OR model can be used to estimate the probability that each attribute name in the set belongs to the true value of a preset latent attribute name, based on the aforementioned reliability prior. The formula for estimating the probability using the Noisy-OR model can be expressed as: ;in, Indicates the first push agent The attribute names obtained through reasoning. , This represents the set of attribute names. This indicates that the attribute name is obtained through reasoning. The first set of intelligent agents, This represents the set of truth values for predefined potential attribute names. Indicates the first push agent The aforementioned reliability prior.
[0149] Optionally, the step of calculating the probability precision and probability recall of the corresponding first inference agent based on the attribute name inferred by the first inference agent, the probability that the attribute name belongs to the true value of the preset potential attribute name, and the set, respectively, includes: calculating the probability true positive value of each first inference agent based on the probability that the attribute name inferred by the first inference agent belongs to the true value of the preset potential attribute name; calculating the expected size of the true value of the preset potential attribute name based on the probability that each attribute name in the set belongs to the true value of the preset potential attribute name; calculating the probability precision of the corresponding first inference agent based on the probability true positive value of the first inference agent and the size of the attribute name inferred by the first inference agent; and calculating the probability recall of the first inference agent based on the probability true positive value of the first inference agent and the expected size of the true value of the preset potential attribute name.
[0150] Optionally, the first reasoning agent The sum of the probabilities that each attribute name obtained through reasoning belongs to the true value of a preset latent attribute name is used as the first reasoning agent. The probability of a true positive value.
[0151] Optionally, the sum of the probabilities that each attribute name in the set belongs to the preset latent attribute name truth value is used as the expected size of the preset latent attribute name truth value.
[0152] Optionally, for a given first inference agent, the ratio of the probability of a true positive value of the first inference agent to the scale of the attribute names inferred by the first inference agent is used as the probability precision of the first inference agent. The probability precision represents the proportion of reliable attribute names among the attribute names generated by the first inference agent, and is used to measure the noise control capability of the first inference agent.
[0153] Optionally, the ratio of the probability of a true positive value to the expected size of the preset potential attribute name truth value of the first inference agent is used as the probability recall of the first inference agent. The probability recall represents the degree to which the attribute names generated by the first inference agent cover potential truth values, and is used to measure the exploration ability of the first inference agent.
[0154] Optionally, use the formula Calculate the comprehensive evaluation index of the first reasoning agent. . This indicates that specifying the attribute name of the first intelligent agent is effective. This represents the probability accuracy of the first reasoning agent. This indicates the coverage of the object type. This indicates the weight of the effectiveness of the attribute name. The weights representing the accuracy of probability. The weights represent the probability recall rate. Configurable. Optionally, the weights of the attribute name effectiveness, the probability precision, and the probability recall can be set as follows: It is used to emphasize the semantic validity of the reasoning results of attribute names and to suppress the artificially high comprehensive evaluation index caused by noisy attributes.
[0155] The comprehensive evaluation index represents the overall quality of the knowledge graph after achieving a balance among the credibility, precision, and recall of attribute names. A higher value for the comprehensive evaluation index indicates higher quality attribute names in the knowledge graph. A low value for any one of these indices will lead to a significant decrease in the comprehensive evaluation index.
[0156] (iii) Evaluating the generative capabilities of the second reasoning agent. Optionally, the reasoning agent matching the current node type includes: a second reasoning agent for reasoning attribute values. After obtaining the knowledge graph updated based on the object information and the subgraph of the target object type in the locally updated knowledge graph according to a preset node editing order, the method further includes: under attribute name constraints, by aggregating edge assertions associated with attribute values reasoned by multiple second reasoning agents, and evaluating the generation capability of the second reasoning agent based on the precision, recall, and harmonic mean of the precision and recall of the attribute values.
[0157] Under the constraint of attribute name, the method involves aggregating edge assertions associated with attribute values generated by multiple second inference agents, and evaluating the generation capability of the second inference agents based on the precision, recall, and harmonic mean of the precision and recall of the attribute values. This includes: forging attribute values for each pre-defined second inference agent based on pre-acquired attribute value inference instances, where each inference instance includes an attribute name; constructing edge assertions for the second inference agents based on the attribute values and attribute names obtained by the second inference agents; aggregating the edge assertions of all second inference agents to construct a first evaluation graph; and constructing a second evaluation graph corresponding to each second inference agent based on the edge assertions of the second inference agents. Graph estimation; based on the labeling results of attribute values in the edge assertions, obtain the attribute value effectiveness rate corresponding to each of the second inference agents, and use the attribute value effectiveness rate as the reliability prior of the corresponding second inference agent; based on the reliability prior, estimate the probability that each attribute value in the first evaluation graph matches the preset potential attribute value truth value; based on the attribute values in the second evaluation graph, the probability that the attribute values match the preset potential attribute value truth value, and the attribute values in the first evaluation graph, calculate the probability precision and probability recall of the corresponding second inference agent respectively; based on the probability precision, probability recall, and harmonic mean of the probability precision and probability recall of the second inference agent, evaluate the generation capability of the second inference agent.
[0158] Optionally, the attribute name reasoning instance includes object type information. In some other optional embodiments, the attribute name reasoning instance may further include a reasoning description of the attribute name. The second reasoning agent infers the attribute name applicable to the object type based on the object type included in the attribute name reasoning instance. The specific method by which the second reasoning agent infers the attribute value based on a pre-acquired attribute value reasoning instance is described in the relevant descriptions in the preceding embodiments, and will not be repeated here.
[0159] Subsequently, for each second reasoning agent, based on the attribute name and the attribute value obtained through reasoning, an edge assertion corresponding to the second reasoning agent is constructed. The edge assertion includes: an edge assertion representing the attribute value relationship allowed by the attribute name and an edge assertion representing the attribute value possessed by the object.
[0160] Furthermore, all the edge assertions are aggregated to obtain a set of edge assertions, and a first evaluation graph is constructed based on the edge assertions in the set. The first evaluation graph includes object nodes associated with objects in the edge assertions, attribute value nodes associated with attribute values in the edge assertions, attribute name nodes associated with attribute names in the edge assertions, as well as edges connecting attribute name nodes and attribute value nodes, and edges connecting attribute value nodes and object nodes.
[0161] On the other hand, based on the edge assertions corresponding to each second reasoning agent, and referring to the method for constructing the first evaluation graph, a second evaluation graph corresponding to each second reasoning agent is constructed.
[0162] Optionally, attribute values in each of the second evaluation graphs are sampled, and the sampled attribute values are manually labeled based on the edge assertions associated with the attribute values to obtain the labeling results of the attribute values. These labeling results indicate whether the attribute values are valid. For example, when an attribute value has an edge assertion with an object (i.e., the attribute value is supported by object data) and an attribute value has an edge assertion with an attribute name (i.e., the attribute value node associated with the attribute value is connected to an attribute name node associated with an attribute name), the attribute value is labeled as valid; otherwise, the attribute value is labeled as invalid. Furthermore, the proportion of labeled valid attribute values among the sampled attribute values can be used as the second push agent corresponding to the second evaluation graph. The attribute value validity rate. The attribute value validity rate is used to measure the credibility of the attribute values generated by inference.
[0163] Optionally, a second push agent can be used. The effectiveness of the attribute value is represented as For example, the second push agent The reliability prior can be expressed as , .
[0164] Optionally, a Noisy-OR model can be used to estimate the probability that each attribute value in the first evaluation graph belongs to the true value of a preset latent attribute value, based on the aforementioned reliability prior. The formula for estimating the probability using the Noisy-OR model can be expressed as: ;in, Indicates the second push agent The attribute values obtained through reasoning , This represents the set of attribute values in the second evaluation graph. This indicates that the attribute value is obtained through reasoning. The second set of intelligent agents, This represents the set of pre-defined true values for potential attributes. Indicates the second push agent The aforementioned reliability prior.
[0165] Optionally, based on the attribute values in the second evaluation graph, the probability that the attribute values match the true values of preset latent attribute values, and the attribute values in the first evaluation graph, the probability precision and probability recall of the corresponding second inference agent are calculated, including: calculating the probability true positive value of each second inference agent based on the probability that the attribute value inferred by the second inference agent belongs to the true value of the preset latent attribute value; calculating the expected size of the true value of the preset latent attribute value based on the probability that each attribute value in the first evaluation graph belongs to the true value of the preset latent attribute value; calculating the probability precision of the corresponding second inference agent based on the probability true positive value of the second inference agent and the size of the attribute value inferred by the second inference agent; and calculating the probability recall of the second inference agent based on the probability true positive value of the second inference agent and the expected size of the true value of the preset latent attribute value.
[0166] Optionally, the second reasoning agent The sum of the probabilities that each attribute value obtained through reasoning belongs to the true value of a preset latent attribute value is used as the second reasoning agent. The probability of a true positive value.
[0167] Optionally, the sum of the probabilities that each attribute value in the first evaluation graph belongs to the true value of the preset latent attribute value is used as the expected size of the true value of the preset latent attribute value.
[0168] Optionally, for a given second inference agent, the ratio of the probability of a true positive value to the scale of the attribute values inferred by the second inference agent is used as the probability accuracy of the second inference agent. The probability accuracy represents the proportion of reliable attribute values among the attribute values generated by the second inference agent and is used to measure the noise control capability of the second inference agent.
[0169] Optionally, the ratio of the probability of a true positive value to the expected size of the preset potential attribute values of the second reasoning agent is used as the probability recall of the second reasoning agent. The probability recall represents the degree to which the attribute values generated by the second reasoning agent cover the potential true values, and is used to measure the exploratory ability of the second reasoning agent.
[0170] The specific implementation method for evaluating the generative ability of the second reasoning agent based on the probability precision, the probability recall, and the harmonic mean of the probability precision and the probability recall is described in the prior art and will not be repeated in the embodiments of this application.
[0171] (iv) Evaluate the decision-making ability of the decision-making agent. The second evaluation agent is used to evaluate the decision-making ability of the decision-making agent.
[0172] Optionally, after employing a decision-making agent to infer and select a node editing action based on the candidate proposal, the inference description, and the metadata recorded in each candidate update node, the method further includes: using the candidate proposal, the inference description, and the metadata recorded in each candidate update node as the current decision instance, employing multiple independent referee models built based on a generative language model to infer and select a node editing action based on the current decision instance, obtaining the node editing action output by each referee model for the current decision instance; taking the node editing action jointly output by most of the referee models for the current decision instance as the consensus node editing action for the current decision instance; and evaluating the decision-making ability of the decision-making agent based on the consistency between the node editing action inferred and selected by the decision-making agent and the consensus node editing action.
[0173] Among them, the multiple independent referee models built based on the generative language model can be generative language models obtained by fine-tuning different model parameters. For the specific implementation of the multiple independent referee models built based on the generative language model, and their reasoning and selection of node editing actions based on the current decision instance, please refer to the specific implementation of the decision-making agent, which reasones and selects node editing actions based on the candidate proposal, the reasoning description, and the metadata recorded in each candidate update node. This will not be repeated in the embodiments of this application.
[0174] After obtaining the node editing actions output by each of the aforementioned referee models for the current decision instance, these actions can be used as votes for the corresponding node editing actions. The total number of votes for each node editing action output by all the referee models for the current decision instance is then tallied. The node editing action with the most votes is then taken as the consensus node editing action for the current decision instance. For example, if more than half of the referee models output the same node editing action, that node editing action is taken as the consensus node editing action for the current decision instance.
[0175] Subsequently, based on the consistency between the node editing action selected by the decision agent and the consensus node editing action, the decision score corresponding to the current decision instance is determined. The decision-making ability of the decision agent is evaluated based on the decision scores corresponding to all decision instances during the knowledge graph update process. For example, when the node editing action selected by the decision agent for decision instance i is consistent with the consensus node editing action, the decision score for decision instance i is determined to be 1; when the node editing action selected by the decision agent for decision instance i is consistent with the consensus node editing action, the decision score for decision instance i is determined to be 0. Then, the decision scores of all decision instances in the knowledge graph construction process are accumulated to obtain the total decision score. Finally, the quotient obtained by dividing the total decision score by the total number of decision instances in the knowledge graph construction process is used as the reasoning accuracy of the decision agent. The higher the reasoning accuracy, the higher the decision accuracy of the decision agent.
[0176] (v) Evaluate the quality of the knowledge graph The third evaluation agent is used to evaluate the quality of the generated knowledge graph.
[0177] Optional, such as Figure 4 As shown, after the step of performing graph editing operations related to different node types on the locally updated knowledge graph in a predetermined node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: step 110.
[0178] Step 110: Perform a quality assessment on the knowledge graph.
[0179] Optionally, the knowledge graph is subjected to quality evaluation, including: constructing a reference graph based on the object information of the objects associated with the object nodes in the knowledge graph, using a combination of automatic generation and manual annotation; extracting information from the knowledge graph to obtain a set of predicted attribute names and a set of predicted key-value facts; extracting information from the reference graph to obtain a set of reference attribute names and a set of reference key-value facts; calculating key-level evaluation metrics for the knowledge graph based on the set of predicted attribute names and the set of reference attribute names, wherein the key-level evaluation metrics include: attribute name precision and attribute name recall; calculating value-level evaluation metrics for the knowledge graph based on the set of reference key-value facts and the set of predicted key-value facts, wherein the value-level evaluation metrics include: attribute value precision and attribute value recall; and evaluating the knowledge graph from the dimensions of semantic correctness and structural normalization, using the reference graph as the result of the knowledge graph standardization process.
[0180] Optionally, when constructing the reference graph, a graph can be generated using graph retrieval enhancement generation technology based on the object information of objects associated with object nodes in the knowledge graph. Then, a generative language model is used to label the object types, attribute names, and attribute values in the graph. Afterwards, normalization processing is performed under manual constraints to obtain the reference graph. The embodiments of this application do not limit the construction method of the reference graph. The reference graph is the Silver Standard for knowledge graphs.
[0181] Furthermore, the reference graph is traversed to retrieve the attribute names associated with the attribute name nodes in the reference graph, which are used as reference attribute names. The edges connecting the attribute name nodes and attribute value nodes in the reference graph are retrieved, and corresponding reference key-value facts are constructed based on the attribute names associated with the attribute name nodes and the attribute values associated with the attribute value nodes, thus obtaining a set of reference key-value facts.
[0182] Traverse the knowledge graph to retrieve the attribute names associated with the attribute name nodes in the knowledge graph, and use them as predicted attribute names. Retrieve the edges connecting the attribute name nodes and attribute value nodes in the knowledge graph, and construct the corresponding predicted key-value facts based on the attribute names associated with the attribute name nodes and the attribute values associated with the attribute value nodes, thus obtaining a set of predicted key-value facts.
[0183] Next, we can use the formula Calculate the accuracy of the attribute name corresponding to object i in the knowledge graph. Using formula Calculate the recall rate of the attribute name corresponding to object i in the knowledge graph. .in, This represents the set of reference attribute names for object i in the reference graph; This represents the set of predicted attribute names for object i in the knowledge graph.
[0184] Optionally, it can be done through formula Calculate the accuracy of attribute values corresponding to object i in a knowledge graph. Using formula Calculate the recall rate of attribute values corresponding to object i in a knowledge graph. .in, Represents the set of reference key facts for object i in the reference graph; This represents the set of predicted key-value facts for object i in the knowledge graph; This represents the set of predicted key-value facts that successfully match the reference key-value facts. Optionally, for predicted key-value facts... If it exists and Then it can be considered that the predicted key-value facts are... The fact was successfully matched with the reference key value.
[0185] Optionally, using the reference graph as the result of the knowledge graph standardization process, the knowledge graph is evaluated from the dimensions of semantic correctness and structural normalization. This includes: obtaining the semantic correctness of the knowledge graph through manual evaluation; calculating the object type compression rate and attribute name compression rate of the knowledge graph using the reference graph as the result of the knowledge graph standardization process; and evaluating the knowledge graph based on the weighted harmonic mean of the semantic correctness, the object type compression rate, and the attribute name compression rate.
[0186] For example, when evaluating the knowledge graph from the dimensions of semantic correctness and structural normalization, a formula can be used. Overall evaluation metrics for computational knowledge graphs .in, The semantic accuracy of representing object type, property name, and property value; The object type compression rate of a knowledge graph can be represented by the ratio of the difference between the object type size in the knowledge graph and the reference graph to the object type size in the knowledge graph. The attribute name compression rate of a knowledge graph can be represented by the ratio of the difference between the attribute name size in the knowledge graph and the reference graph to the attribute name size in the knowledge graph. Weights representing semantic accuracy This represents the weights of object type compression rate and attribute name compression rate. The weights of semantic accuracy, object type compression rate, and attribute name compression rate are configurable. Optionally, the weight of semantic accuracy is greater than the weights of object type compression rate and attribute name compression rate to emphasize semantic effectiveness.
[0187] Optional, semantic accuracy It can be obtained through manual evaluation and is used to represent the effectiveness of the semantic dimension of the object types, attribute names, attribute values, and other content obtained through reasoning in the knowledge graph.
[0188] The attribute name compression rate reflects the merging effect of attribute names in the knowledge graph, while the object type compression rate reflects the merging and redundancy removal effect of object types in the knowledge graph. The combined attribute name compression rate and object type compression rate reflect the degree of structural normalization of the knowledge graph. Weighted harmonization of semantic accuracy, attribute name compression rate, and object type compression rate can effectively balance the semantic accuracy and structural normalization of the knowledge graph.
[0189] Based on the above overall evaluation indicators The calculation method can be used to derive the overall evaluation index. The larger the value, the higher the quality of the knowledge graph.
[0190] By evaluating the generation capabilities of each reasoning agent, the decision-making capabilities of the decision-making agent, and the quality of the knowledge graph, the corresponding reasoning agents or decision-making agents can be optimized in a timely manner based on the evaluation results. For example, a higher-performance generative language model can be used to construct the corresponding agents to improve the quality of the generated knowledge graph.
[0191] Based on the above embodiments, this embodiment also provides a knowledge graph construction apparatus, the apparatus comprising: The first knowledge update module is used to respond to the acquisition of object information of the object to be processed, perform object node update processing on the knowledge graph to be updated based on the object information, and determine the object nodes associated with the object to be processed. The second knowledge update module is used to perform graph editing operations related to object types on the knowledge graph based on the object information and the retrieval results of object types in the knowledge graph, so as to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, wherein the target object type is the object type that matches the object to be processed; The third knowledge update module is used to perform graph editing operations related to different node types on the locally updated knowledge graph in a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information.
[0192] Optionally, the second knowledge update module is further used for: An inference agent employing object type matching generates candidate proposals and inference descriptions of object types that match the object to be processed based on the object information. Based on the similarity of the object types corresponding to the nodes, nodes corresponding to a specified number of object types that are similar to the candidate proposal are retrieved in the knowledge graph and used as candidate update nodes. A decision-making agent is employed to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. Execute the selected node editing action to edit the target node in the knowledge graph, as well as the edge between the object node and the target node, to obtain a locally updated knowledge graph, wherein the target node is: the node associated with the target object type.
[0193] Optionally, the third knowledge update module is further used for: The current node type is determined sequentially according to a preset node editing order, and a knowledge graph editing operation under object type constraints is performed on the current node type. The knowledge graph editing operation includes: Determine the predecessor node of the current node type; In the subgraph of the target object type in the locally updated knowledge graph, retrieve the node of the current node type; Using an inference agent that matches the current node type, and based on the object information and / or the metadata of each node record retrieved, candidate proposals and inference descriptions for the current node type are inferred. Based on the similarity between the candidate proposal and the current node type, a specified number of nodes are selected from the retrieved nodes of the current node type as candidate update nodes; A decision-making agent is employed to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. Execute the selected node editing action to edit the nodes of the current node type and the associated edges of the nodes of the current node type in the locally updated knowledge graph, thereby obtaining the locally updated knowledge graph.
[0194] Optionally, the metadata includes: values for the corresponding node type and inference descriptions corresponding to the values. The step of employing a decision-making agent to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node includes: A decision-making intelligent agent is employed to generate prompt information based on the candidate proposals, the reasoning descriptions, and the metadata recorded in each candidate update node. The prompt information guides a preset generative language model to reason and select node editing actions according to preset decision criteria.
[0195] Optionally, the metadata includes: values for the corresponding node type and inference descriptions corresponding to the values. The step of employing a decision-making agent to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node includes: A decision-making agent is employed to generate prompt information based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. The prompt information guides a preset generative language model to infer and select a node editing action according to preset decision criteria and generates the confidence score of the selected node editing action.
[0196] Optionally, the node editing action includes one or more of the following: The first node editing action is used to indicate abandoning the update of the knowledge graph based on the candidate proposal; The second node editing action is used to instruct the creation of a new node that records the candidate proposal; The third node editing action is used to instruct the candidate proposal to be merged into the specified candidate update node; The fourth node edit action is used to instruct the replacement of the metadata in the specified candidate update node with the candidate proposal and the inference description.
[0197] Optionally, the decision agent is a decision unit constructed based on a generative language model. After the decision agent infers and selects a node editing action based on the candidate proposal, the inference description, and the metadata recorded in each candidate update node, the device further includes: The agent update module is used to determine whether the confidence level of the node editing action meets the preset decision agent switching conditions and obtain a judgment result; and when the judgment result indicates that the confidence level is less than or equal to a preset confidence threshold, the generative language model used to construct the decision agent is switched to the target generative language model, and the step of adopting the decision agent and inferring and selecting the node editing action based on the candidate proposal, the inference description and the metadata recorded in each candidate update node is re-executed.
[0198] Optionally, the node editing action includes: a third node editing action, wherein after the step of sequentially performing graph editing operations related to different node types on the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the device further includes: a first intelligent agent capability evaluation module.
[0199] The first intelligent agent capability evaluation module is used to obtain object type effectiveness, object type compression rate and object type coverage rate based on the number of object nodes in the knowledge graph, the number of object type nodes associated with the third node editing action, and the validity marking results of the object type nodes. The first agent capability evaluation module is further configured to use the weighted harmonic mean of the object type effectiveness rate, the object type compression rate, and the object type coverage rate as a comprehensive evaluation index for the object type matching reasoning agent; and to evaluate the generation capability of the object type matching reasoning agent based on the comprehensive evaluation index. Wherein, the object type effectiveness rate represents the semantic correctness of the object type reasoning result, the object type compression rate represents the degree of redundancy removal in the object type reasoning result, and the object type coverage rate represents the practicality of the knowledge graph.
[0200] Optionally, the reasoning agent matching the current node type includes: a first reasoning agent for reasoning attribute names; after the device performs graph editing operations related to different node types on the locally updated knowledge graph in a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the device further includes: a second agent capability evaluation module.
[0201] The second intelligent agent capability evaluation module is used to evaluate the generation capability of the first inference intelligent agent by aggregating the attribute names and reliability priors generated by multiple first inference intelligent agents and using probabilistic precision and probabilistic recall.
[0202] Optionally, the reasoning agent matching the current node type includes: a second reasoning agent for reasoning attribute values. After the device performs graph editing operations related to different node types on the locally updated knowledge graph in a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the device further includes: a third agent capability evaluation module.
[0203] The third agent capability evaluation module is used to evaluate the generation capability of the second inference agent by aggregating the edge assertions associated with the attribute values generated by multiple second inference agents under the constraint of attribute names, based on the precision, recall, and harmonic mean of the attribute values.
[0204] Optionally, after the decision-making agent, based on the candidate proposal, the inference description, and the metadata recorded in each candidate update node, infers and selects the node editing action, the device further includes a decision-making agent evaluation module.
[0205] The decision-making agent evaluation module is used to take the candidate proposal, the reasoning description, and the metadata recorded in each candidate update node as the current decision instance, and adopt multiple independent referee models built based on generative language models to reason and select node editing actions based on the current decision instance, so as to obtain the node editing actions output by each referee model for the current decision instance. The decision agent evaluation module is further configured to take the node editing action jointly output by most of the referee models for the current decision instance as the consensus node editing action of the current decision instance; and to evaluate the decision-making ability of the decision agent based on the consistency between the node editing action selected by the decision agent's reasoning and the consensus node editing action.
[0206] Optionally, after the step of sequentially performing graph editing operations related to different node types on the partially updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, to obtain the knowledge graph updated based on the object information, the device further includes: a knowledge graph evaluation module.
[0207] The knowledge graph evaluation module is used to construct a reference graph based on the object information of the objects associated with object nodes in the knowledge graph, using a combination of automatic generation and manual annotation; extract information from the knowledge graph to obtain a set of predicted attribute names and a set of predicted key-value facts; extract information from the reference graph to obtain a set of reference attribute names and a set of reference key-value facts; calculate key-level evaluation metrics for the knowledge graph based on the set of predicted attribute names and the set of reference attribute names, wherein the key-level evaluation metrics include: attribute name precision and attribute name recall; calculate value-level evaluation metrics for the knowledge graph based on the set of reference key-value facts and the set of predicted key-value facts, wherein the value-level evaluation metrics include: attribute value precision and attribute value recall; and evaluate the knowledge graph from the dimensions of semantic correctness and structural normalization, using the reference graph as the result of the knowledge graph standardization process.
[0208] Optionally, the reasoning agent is built based on a multimodal generative language model. When the reasoning agent is used to generate candidate proposals and reasoning descriptions, the object information input to the reasoning agent is multimodal information, which includes: object description text and object image.
[0209] The knowledge graph construction apparatus disclosed in this application is used to implement the above-described knowledge graph construction method. For the specific implementation of each module of the apparatus, please refer to the specific implementation of the corresponding steps in the foregoing method embodiments, which will not be repeated here.
[0210] In summary, the knowledge graph construction apparatus disclosed in this application, in response to obtaining object information of the object to be processed, performs object node update processing on the knowledge graph to be updated based on the object information, and determines the object nodes associated with the object to be processed; then, based on the object information and the retrieval results of object types in the knowledge graph, performs graph editing operations related to object types on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type matching the object to be processed; finally, according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, graph editing operations related to different node types are sequentially performed on the partially updated knowledge graph to obtain a knowledge graph updated based on the object information, thus realizing dynamic updating of the knowledge graph. In the process of constructing a knowledge graph using this apparatus, there is no need to predefine a knowledge classification system. By combining the retrieval results of existing knowledge in the knowledge graph and the knowledge generation capabilities of a generative language model, the knowledge system is automatically expanded and the knowledge content is enriched, effectively improving the construction and updating efficiency of the knowledge graph. The knowledge graph constructed using this device can evolve in real time with the object database, continuously improving its accuracy, standardization, and coverage completeness.
[0211] The knowledge graph construction apparatus disclosed in this application decouples object type induction, attribute name discovery, and attribute value extraction into multiple reasoning agents. Employing a multi-agent architecture, it forms an end-to-end automated process from object type induction to attribute name discovery, attribute value extraction, and finally, graph writing. Candidate proposals are uniformly represented as structured decisions (such as adding nodes, merging nodes, replacing canonical names, discarding noise, etc.), and written by a unified, action-constrained decision-making agent. This creates a closed loop between knowledge extraction and graph construction, enabling the system running this apparatus to operate automatically and significantly reducing the manual costs and time consumed in building the knowledge graph. Furthermore, using a unified, action-constrained decision-making agent ensures global consistency while the knowledge graph dynamically evolves.
[0212] In the process of constructing a knowledge graph using the knowledge graph construction device disclosed in the embodiments of this application, a decision-making agent with restricted actions is used to make decisions, and each knowledge graph update is performed with constrained incremental operations to ensure that the evolution process is controllable and traceable, reduce the risk of error accumulation and structural drift, and enable the knowledge graph to have long-term maintainability and production availability.
[0213] On the other hand, this device first infers the object type, and then, under the constraints of the object type, infers related knowledge level by level, such as inferring attribute names and attribute values in sequence. This can reduce the binding of irrelevant attributes and incorrect attribute names. At the same time, it can reduce the decrease in accuracy caused by the illusion that generative language models are prone to when inferring hierarchical knowledge at one time due to the complex and multi-hop problem of model inference.
[0214] Furthermore, this device retrieves similar knowledge (such as object type, attribute name, or attribute value) values and examples from existing knowledge graphs when reasoning about related knowledge, and inputs them as external knowledge into the reasoning agent. This reduces the illusion of generative language models, improves knowledge generalization and consistency in long-tail cases, and helps improve the accuracy of new knowledge extraction.
[0215] During the knowledge graph editing process, standardization and merging of object types, attribute names, or attribute values by executing third-node editing actions can reduce the fragmentation of knowledge representation and thus form a stable set of standard nodes.
[0216] Furthermore, by evaluating the generation capabilities of each reasoning agent, the decision-making capabilities of the decision-making agent, and the quality of the knowledge graph, the corresponding reasoning agents or decision-making agents can be optimized in a timely manner based on the evaluation results, thereby improving the quality of the generated knowledge graph.
[0217] This application also provides a non-volatile readable storage medium storing one or more modules (programs). When these modules are applied to a device, they enable the device to execute the instructions for the method steps in this application.
[0218] This application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the methods described in this application.
[0219] This application also provides an electronic device, including: a processor and a memory communicatively connected to the processor; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory to implement the method described in this application embodiment. In this application embodiment, the electronic device includes devices such as servers and terminal devices.
[0220] This application also discloses a computer program product, including a computer program / computer executable instructions, which, when executed by a processor in an electronic device, implement the method described in this application.
[0221] Embodiments of this disclosure can be implemented as an apparatus with any suitable hardware, firmware, software, or any combination thereof, configured as desired, and the apparatus may include electronic devices such as servers (clusters) and terminals. Figure 5 An exemplary apparatus 500 is schematically shown that can be used to implement the various embodiments described in this application.
[0222] In one embodiment, Figure 5 An exemplary device 500 is shown, which includes one or more processors 502, a control module (chipset) 504 coupled to at least one of the processors 502, a memory 506 coupled to the control module 504, a non-volatile memory (NVM) / storage device 508 coupled to the control module 504, one or more input / output devices 510 coupled to the control module 504, and a network interface 512 coupled to the control module 504.
[0223] Processor 502 may include one or more single-core or multi-core processors, and processor 502 may include any combination of general-purpose processors or special-purpose processors (e.g., graphics processors, application processors, baseband processors, etc.). In some embodiments, device 500 can serve as a server, terminal, or other device as described in the embodiments of this application.
[0224] In some embodiments, the apparatus 500 may include one or more computer-readable media (e.g., memory 506 or NVM / storage device 508) having instructions 514 and one or more processors 502 that are combined with the one or more computer-readable media and configured to execute the instructions 514 to implement the module and thus perform the actions described in this disclosure.
[0225] In one embodiment, the control module 504 may include any suitable interface controller to provide any suitable interface to at least one of the processors 502 and / or any suitable device or component communicating with the control module 504.
[0226] The control module 504 may include a memory controller module to provide an interface to the memory 506. The memory controller module may be a hardware module, a software module, and / or a firmware module.
[0227] Memory 506 may be used, for example, to load and store data and / or instructions 514 for device 500. In one embodiment, memory 506 may include any suitable volatile memory, such as suitable DRAM. In some embodiments, memory 506 may include double data rate type quad synchronous dynamic random access memory (DDR4 SDRAM).
[0228] In one embodiment, the control module 504 may include one or more input / output controllers to provide an interface to the NVM / storage device 508 and (one or more) input / output devices 510.
[0229] For example, NVM / storage device 508 may be used to store data and / or instructions 514. NVM / storage device 508 may include any suitable non-volatile memory (e.g., flash memory) and / or may include any suitable (one or more) non-volatile storage devices (e.g., one or more hard disk drives (HDDs), one or more optical disc drives (CDs), and / or one or more digital universal optical disc (DVD) drives).
[0230] NVM / storage device 508 may include storage resources that are part of a device on which device 500 is mounted, or that are accessible to the device but do not necessarily have to be part of the device. For example, NVM / storage device 508 may be accessed via a network through one or more input / output devices 510.
[0231] One or more input / output devices 510 may provide an interface for device 500 to communicate with any other suitable device. Input / output devices 510 may include communication components, audio components, sensor components, etc. A network interface 512 may provide an interface for device 500 to communicate via one or more networks. Device 500 may wirelessly communicate with one or more components of a wireless network according to any of one or more wireless network standards and / or protocols, such as accessing wireless networks based on communication standards, such as Bluetooth, WiFi, 2G, 3G, 4G, 5G, etc., or combinations thereof.
[0232] In one embodiment, at least one of the processors 502 may be logically packaged with one or more controllers (e.g., memory controller modules) of the control module 504. In one embodiment, at least one of the processors 502 may be logically packaged with one or more controllers of the control module 504 to form a system-in-package (SiP). In one embodiment, at least one of the processors 502 may be integrated with the logic of one or more controllers of the control module 504 on the same die. In one embodiment, at least one of the processors 502 may be integrated with the logic of one or more controllers of the control module 504 on the same die to form a system-on-a-chip (SoC).
[0233] In various embodiments, device 500 may be, but is not limited to, a component, integrated circuit, or chip in a terminal. The device may be a mobile electronic device or a non-mobile electronic device. For example, mobile electronic devices may be mobile phones, tablets, laptops, PDAs, in-vehicle electronic devices, wearable devices, ultra-mobile personal computers (UMPCs), netbooks, or personal digital assistants (PDAs), etc., while non-mobile electronic devices may be servers, network-attached storage (NAS), personal computers (PCs), televisions (TVs), ATMs, or self-service machines, etc. This application does not impose specific limitations on these embodiments.
[0234] In various embodiments, device 500 may have more or fewer components and / or different architectures. For example, in some embodiments, device 500 includes one or more cameras, a keyboard, a liquid crystal display (LCD) screen (including a touch screen display), a non-volatile memory port, multiple antennas, a graphics chip, an application-specific integrated circuit (ASIC), and a speaker.
[0235] The device can use a main control chip as a processor or control module, and sensor data, location information, etc. can be stored in a memory or NVM / storage device. The sensor group can be used as an input / output device, and the communication interface can include a network interface.
[0236] This application also provides an electronic device, including: a processor; and a memory storing executable code thereon. When the executable code is executed, the processor performs one or more methods as described in this application embodiment. In this application embodiment, the memory can store various types of data, such as target files, file-application association data, and user behavior data, thereby providing a data foundation for various processing operations.
[0237] This application also provides one or more machine-readable media having executable code stored thereon, which, when executed, causes a processor to perform one or more of the methods described in this application.
[0238] As the device embodiment is basically similar to the method embodiment, the description is relatively simple, and relevant parts can be found in the description of the method embodiment.
[0239] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.
[0240] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of this application. 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 program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0241] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing terminal device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0242] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal equipment, causing a series of operational steps to be performed on the computer or other programmable terminal equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable terminal equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0243] Although preferred embodiments of the present application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the embodiments of the present application.
[0244] Finally, it should be noted that the terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or terminal device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or terminal device. Without further limitations, an element defined by the phrase "comprising one…" does not exclude the presence of other identical elements in the process, method, article, or terminal device that includes said element. In the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following related objects are in an "or" relationship.
[0245] The foregoing has provided a detailed description of a knowledge graph construction method, an electronic device, a storage medium, and a computer program product provided by this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A method for constructing a knowledge graph, characterized in that, The method includes: In response to obtaining the object information of the object to be processed, the object node update process is performed on the knowledge graph to be updated based on the object information, and the object nodes associated with the object to be processed are determined. Based on the object information and the retrieval results of object types in the knowledge graph, an object type-related graph editing operation is performed on the knowledge graph to obtain a partially updated knowledge graph, such that the partially updated knowledge graph includes: object type nodes associated with the target object type, where the target object type is the object type that matches the object to be processed; Following a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, graph editing operations related to different node types are sequentially performed on the locally updated knowledge graph to obtain the knowledge graph updated based on the object information.
2. The method according to claim 1, characterized in that, The step of performing object type-related graph editing operations on the knowledge graph based on the object information and the retrieval results of object types in the knowledge graph to obtain a partially updated knowledge graph includes: An inference agent employing object type matching generates candidate proposals and inference descriptions of object types that match the object to be processed based on the object information. Based on the similarity of the object types corresponding to the nodes, nodes corresponding to a specified number of object types that are similar to the candidate proposal are retrieved in the knowledge graph and used as candidate update nodes. A decision-making agent is employed to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. Execute the selected node editing action to edit the target node in the knowledge graph, as well as the edge between the object node and the target node, to obtain a locally updated knowledge graph, wherein the target node is: the node associated with the target object type.
3. The method according to claim 1, characterized in that, The process involves sequentially performing graph editing operations related to different node types on the partially updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, to obtain a knowledge graph updated based on the object information. This includes: The current node type is determined sequentially according to a preset node editing order, and a knowledge graph editing operation under object type constraints is performed on the current node type. The knowledge graph editing operation includes: Determine the predecessor node of the current node type; In the subgraph of the target object type in the locally updated knowledge graph, retrieve the node of the current node type; Using an inference agent that matches the current node type, and based on the object information and / or the metadata of each node record retrieved, candidate proposals and inference descriptions for the current node type are inferred. Based on the similarity between the candidate proposal and the current node type, a specified number of nodes are selected from the retrieved nodes of the current node type as candidate update nodes; A decision-making agent is employed to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. Execute the selected node editing action to edit the nodes of the current node type and the associated edges of the nodes of the current node type in the locally updated knowledge graph, thereby obtaining the locally updated knowledge graph.
4. The method according to claim 2 or 3, characterized in that, The metadata includes: values for the corresponding node type and inference descriptions corresponding to the values. The decision-making agent, based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node, infers and selects node editing actions, including: A decision-making intelligent agent is employed to generate prompt information based on the candidate proposals, the reasoning descriptions, and the metadata recorded in each candidate update node. The prompt information guides a preset generative language model to reason and select node editing actions according to preset decision criteria.
5. The method according to claim 2 or 3, characterized in that, The metadata includes: values for the corresponding node type and inference descriptions corresponding to the values. The decision-making agent, based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node, infers and selects node editing actions, including: A decision-making agent is employed to generate prompt information based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node. The prompt information guides a preset generative language model to infer and select a node editing action according to preset decision criteria and generates the confidence score of the selected node editing action.
6. The method according to claim 2 or 3, characterized in that, The node editing action includes one or more of the following: The first node editing action is used to indicate abandoning the update of the knowledge graph based on the candidate proposal; The second node editing action is used to instruct the creation of a new node that records the candidate proposal; The third node editing action is used to instruct the candidate proposal to be merged into the specified candidate update node; The fourth node edit action is used to instruct the replacement of the metadata in the specified candidate update node with the candidate proposal and the inference description.
7. The method according to claim 5, characterized in that, The decision agent is a decision unit constructed based on a generative language model. After employing the decision agent to infer and select a node editing action based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node, the method further includes: Determine whether the confidence level of the node editing action meets the preset decision agent switching conditions, and obtain the determination result; If the judgment result indicates that the confidence level is less than or equal to a preset confidence threshold, the generative language model used to construct the decision agent is switched to the target generative language model, and the step of adopting the decision agent and reasoning to select the node editing action based on the candidate proposal, the reasoning description, and the metadata recorded in each candidate update node is re-executed.
8. The method according to claim 2, characterized in that, The node editing action includes: a third node editing action, wherein, after the step of sequentially performing graph editing operations related to different node types on the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: Based on the number of object nodes in the knowledge graph, the number of object type nodes associated with the third node editing action, and the validity marking results of the object type nodes, the object type validity rate, object type compression rate, and object type coverage rate are obtained. The weighted harmonic mean of the object type effectiveness, the object type compression rate, and the object type coverage rate is used as a comprehensive evaluation index for the inference agent that matches the object type. Based on the comprehensive evaluation index, the generation capability of the reasoning agent matching the object type is evaluated.
9. The method according to claim 3, characterized in that, The reasoning agent matching the current node type includes: a first reasoning agent for reasoning attribute names. After performing graph editing operations related to different node types on the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: By aggregating the attribute names and reliability priors generated by multiple first-inference agents, the generation capability of the first-inference agents is evaluated using probabilistic precision and probabilistic recall.
10. The method according to claim 3, characterized in that, The reasoning agent matching the current node type includes: a second reasoning agent for reasoning attribute values. After performing graph editing operations related to different node types on the locally updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the locally updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: Under the constraint of attribute name, by aggregating the edge assertions associated with attribute values generated by multiple second reasoning agents, the generation capability of the second reasoning agents is evaluated based on the precision, recall, and harmonic mean of the precision and recall of the attribute values.
11. The method according to claim 2 or 3, characterized in that, The method of employing a decision-making intelligent agent, based on the candidate proposals, the inference descriptions, and the metadata recorded in each candidate update node, after inferring and selecting the node editing action, further includes: Using the candidate proposal, the reasoning description, and the metadata recorded in each candidate update node as the current decision instance, multiple independent adjudicator models built based on generative language models are used to reason and select node editing actions based on the current decision instance, thereby obtaining the node editing actions output by each adjudicator model for the current decision instance. The node editing action jointly output by most of the aforementioned referee models for the current decision instance shall be taken as the consensus node editing action of the current decision instance; The decision-making ability of the decision-making agent is evaluated based on the consistency between the node editing action selected by the decision-making agent and the consensus node editing action.
12. The method according to claim 1, characterized in that, Following the step of sequentially performing graph editing operations related to different node types on the partially updated knowledge graph according to a preset node editing order, based on the object information and the subgraph of the target object type in the partially updated knowledge graph, to obtain the knowledge graph updated based on the object information, the method further includes: Based on the object information of the objects associated with the object nodes in the knowledge graph, a reference graph is constructed using a combination of automatic generation and manual annotation. Information is extracted from the knowledge graph to obtain a set of predicted attribute names and a set of predicted key-value facts; Information is extracted from the reference map to obtain a set of reference attribute names and a set of reference key-value facts; Based on the predicted attribute name set and the reference attribute name set, the key-level evaluation metrics of the knowledge graph are calculated, wherein the key-level evaluation metrics include: attribute name precision and attribute name recall. Based on the reference key-value fact set and the predicted key-value fact set, the value-level evaluation index of the knowledge graph is calculated, wherein the value-level evaluation index includes: attribute value precision and attribute value recall. Using the reference graph as the result of the knowledge graph standardization process, the knowledge graph is evaluated from the dimensions of semantic correctness and structural normalization.
13. The method according to claim 2 or 3, characterized in that, The reasoning agent is built on a multimodal generative language model. When the reasoning agent is used to generate candidate proposals and reasoning descriptions, the object information input to the reasoning agent is multimodal information, which includes: object description text and object image.
14. An electronic device, characterized in that, include: A processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of the method as described in any one of claims 1 to 13.
15. A computer-readable storage medium, characterized in that, The readable storage medium stores a program or instructions that, when executed by a processor, implement the method as described in any one of claims 1 to 13.
16. A computer program product comprising a computer program / computer-executable instructions, characterized in that, When the computer program / computer-executable instructions are executed by a processor in an electronic device, the method of any one of claims 1 to 13 is implemented.