Association query system and method, electronic device, storage medium, and program product

By combining the data service module and the knowledge graph module, a graph of business object types and instance relationships is constructed, which solves the problem of low efficiency in cross-object association queries and enables fast and flexible cross-object queries.

WO2025251667A1PCT designated stage Publication Date: 2025-12-11ZTE CORP
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/076399
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-06-05
Filing Date
2025-02-08
Publication Date
2025-12-11

AI Technical Summary

Technical Problem

Existing technologies for cross-object association queries are inefficient and cannot adapt to rapid changes in business scenarios, making it impossible to quickly implement cross-object association queries.

Method used

By combining a data service module and a knowledge graph module, and using a business object relationship data model and instance relationship data, a business object type relationship graph and an instance relationship graph are constructed to determine the instance information of the associated query object and realize cross-object related queries.

Benefits of technology

Without modifying the data model or upgrading the data service software version, it improves query efficiency, adapts to rapid changes in business scenarios, and enables fast cross-object related queries.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025076399_11122025_PF_FP_ABST
    Figure CN2025076399_11122025_PF_FP_ABST
Patent Text Reader

Abstract

The present application provides an association query system and method, an electronic device, and a storage medium. The system comprises a data service module and a knowledge graph module. The data service module is used for providing a service object relationship data model and service object instance relationship data. The knowledge graph module is used for determining a service object type relationship graph on the basis of the service object relationship data model and determining a service object instance relationship graph on the basis of the service object instance relationship data, wherein the service object type relationship graph and the service object instance relationship graph are used for determining instance information of an associated query object, and the instance information of the associated query object is used for the data service module to determine an association query result.
Need to check novelty before this filing date? Find Prior Art

Description

System and method for association query, electronic device, storage medium and program product

[0001] Cross-reference to related applications

[0002] The present application claims priority to the Chinese patent application No. 202410722586.6, filed on June 5, 2024, and entitled "System and method for association query, electronic device, storage medium and program product", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD

[0003] The present application relates to the technical field of data query, and in particular to a system and method for association query, an electronic device, a storage medium and a program product. BACKGROUND

[0004] In some business systems, the data of business objects is usually instantiated and modeled to obtain a data model related to the business objects, and data services are provided based on the data model. For example, a data model for defining the relationship between two different business object types can be constructed, and when data query is performed on the business objects, the data of any two business objects having a direct business relationship can be queried according to the object type relationship defined by the data model.

[0005] In actual applications, when data query is performed on business objects, there can be a scenario of cross-object association query, for example, data of object type A and object type W needs to be associated and queried, and there is no direct business relationship between the business object type A and the business object type W. Since the data model defines the direct business relationship between two business object types, when cross-object association query is performed, the related data cannot be directly queried based on the data model. In related technologies, in order to implement cross-object association query, a new data model can be constructed or the software version of the data service can be upgraded. However, these methods are low in efficiency and usually cannot adapt to the rapid changes of business scenarios, resulting in the inability to quickly implement cross-object association query. SUMMARY

[0006] The present application provides a system and method for association query, an electronic device, a storage medium and a program product, which are used to solve the problem that the cross-object association query method in related technologies is low in efficiency and cannot adapt to the rapid changes of business scenarios, resulting in the inability to quickly implement cross-object association query.

[0007] In a first aspect, an associated query system is provided, comprising a data service module and a knowledge graph module, wherein: the data service module is configured to provide a business object relationship data model and business object instance relationship data, the business object relationship data model is configured to define the relationship between two different business object types, and the business object instance relationship data is configured to describe the relationship between object instances of two different business object types; the knowledge graph module is configured to determine a business object type relationship graph according to the business object relationship data model and determine a business object instance relationship graph according to the business object instance relationship data, and the business object type relationship graph and the business object instance relationship graph are configured to determine instance information of an associated query object, and the instance information is configured to be used by the data service module to determine an associated query result.

[0008] In a second aspect, an associated query method is provided, which is applied to the data service module of the associated query system in the first aspect, and the method comprises the following steps: sending an associated query request to the knowledge graph module, wherein the associated query request comprises type information and instance information of a first object and type information of an associated query object; receiving instance information of the associated query object returned by the knowledge graph module, wherein the instance information of the associated query object is determined by the knowledge graph module according to the associated query request, the business object type relationship graph and the business object instance relationship graph; and determining an associated query result according to the instance information of the associated query object.

[0009] In a third aspect, an associated query method is provided, which is applied to the knowledge graph module of the associated query system in the first aspect, and the method comprises the following steps: receiving an associated query request sent by the data service module, wherein the associated query request comprises type information and instance information of a first object and type information of an associated query object; determining instance information of the associated query object according to the associated query request, the business object type relationship graph and the business object instance relationship graph; and returning the instance information of the associated query object to the data service module.

[0010] In a fourth aspect, an electronic device is provided, comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to execute the instructions to implement the method of the second aspect or the third aspect.

[0011] In a fifth aspect, a computer-readable storage medium is provided, when instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the method of the second aspect or the third aspect.

[0012] In a sixth aspect, a computer program product is provided, which includes a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps in the method according to the second aspect, or to perform some or all of the steps in the method according to the third aspect. BRIEF DESCRIPTION OF DRAWINGS

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

[0014] FIG. 1 is a schematic diagram of performing cross-object association query in the related art;

[0015] FIG. 2 is a structural schematic diagram of an association query system according to an embodiment of the application;

[0016] FIG. 3 is a flow schematic diagram of an association query method according to an embodiment of the application;

[0017] FIG. 4 is a flow schematic diagram of an association query method according to an embodiment of the application;

[0018] FIG. 5 is a schematic diagram of performing cross-object association query according to an embodiment of the application;

[0019] FIG. 6 is a structural schematic diagram of an electronic device according to an embodiment of the application;

[0020] FIG. 7 is a structural schematic diagram of an association query apparatus according to an embodiment of the application;

[0021] FIG. 8 is a structural schematic diagram of an association query apparatus according to an embodiment of the application. DETAILED DESCRIPTION

[0022] In some business systems, when the data of a business object is instantiated and modeled, a data model is usually constructed for two different types of business objects having a direct business relationship, and the data model defines the business relationship between the two different business object types. When an association query needs to be performed across objects, since the data model defines the direct business relationship between the two business object types, the association query across objects cannot be realized through the data model. In the related art, in order to realize the association query across objects, a new data model is usually constructed or the software version of the data service is upgraded to perform the association query across objects, please refer to FIG. 1.

[0023] In FIG. 1, the data model built by the data service includes a data model of business object type A to business object type B (defining the business relationship between business object type A and business object type B), a data model of business object type S to business object type W (defining the business relationship between business object type S and business object type W), but no data model of business object type A to business object type W. Thus, when an instance A1 of business object type A needs to query the data of the object instance of business object type W related thereto (i.e., cross-object association query, the type of the object to be associated is W, and the data of the object instance of business object type W needs to be queried), the query result cannot be directly obtained according to the existing data model.

[0024] To implement the cross-object association query, one method is to add a data model of business object type A to business object type W (for defining the business relationship between business object type A and business object type W) in the data model. Thus, when the cross-object association query is performed, the object instance W11 can be found from the object instance A1 according to the newly added data model, and the data of the object instance W11 can be further queried. Another method is not to build a new data model, but to manually customize and develop an indirect business object association query rule. The indirect query path of object type A to object type W can be determined by the relationship between the business object types, such as: first querying the associated object type B from the object type A, then querying the associated object type E from the object type B, and so on, to finally find the object type W, and then manually customizing and developing the association query path. Thus, when the cross-object association query is performed, the object instance B1 of object type B can be first found according to the query path, then the object instance E1 of object type E can be found, and so on, to finally find the object instance W11 of object type W.

[0025] Both the above two methods can implement the cross-object association query. However, the first method needs to build a new data model, which leads to the need to upgrade the data model version of the data processing node, and the second method needs to manually customize and develop the association query rule, which leads to the need to upgrade the data service software version of the data processing node. Both methods have low efficiency, cannot adapt to the rapid changes of the business scenario, and cannot implement the rapid cross-object association query.

[0026] The embodiment of the application provides a kind of association query system and method, electronic equipment, storage medium and program product, the system includes data service module and knowledge graph module, data service module is used to provide business object relationship data model and business object instance relationship data, business object relationship data model is used to define the relationship between two different business object types, business object instance relationship data is used to describe the relationship between the object instance of two different business object types, knowledge graph module is used to determine business object type relationship graph according to business object relationship data model and determine business object instance relationship graph according to business object instance relationship data, business object type relationship graph and business object instance relationship graph are used to determine the instance information of the object to be associated query, the instance information of the object to be associated query is used to determine the association query result of data service module.The association query result can be obtained without modifying data model and upgrading the software version of data service when cross-object association query is carried out, therefore, the query efficiency is higher, can adapt to the rapid change of business scene, realize the rapid association query of cross-object.

[0027] In order to enable personnel in the art to better understand the technical solutions in the application, the technical solutions in the application will be clearly and completely described below in conjunction with the drawings in one or more embodiments of the application. Obviously, the described embodiments are only some of the embodiments of the application, not all the embodiments. Based on the embodiments in the application, all other embodiments obtained by those of ordinary skill in the art without creative labor should fall within the protection scope of the application.

[0028] The terms "first", "second", etc. in the application and claims are used to distinguish similar objects, not to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the application can be implemented in an order other than those illustrated or described herein. In addition, "and / or" in the application and claims indicates at least one of the connected objects, and the character " / " generally indicates that the front and rear associated objects are in an "or" relationship.

[0029] It should be noted that the technical solutions provided by the embodiments of the present application can be applied in a mobile communication network, such as a 5G, 6G or next-generation mobile communication network. In the mobile communication network, the service object can be an object involved in the mobile communication service, such as a carrier, a cell, and the like. In addition, the technical solutions provided by the embodiments of the present application can also be applied in other scenarios where service objects are instantiated and modeled and cross-object association queries exist. Here, the application scenarios to which the embodiments of the present application can be applied will not be illustrated one by one.

[0030] The technical solutions provided by the embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0031] FIG. 2 is a structural schematic diagram of an association query system according to an embodiment of the present application. Referring to FIG. 2, the association query system 20 shown in FIG. 2 includes a data service module 21 and a knowledge graph module 22. The data service module 21 is configured to provide a service object relationship data model and service object instance relationship data. The knowledge graph module 22 is configured to determine a service object type relationship graph according to the service object relationship data model provided by the data service module 21, and determine a service object instance relationship graph according to the service object instance relationship data provided by the data service module 21. The service object type relationship graph and the service object instance relationship graph are used to determine instance information of an associated query object, and the instance information can be used by the data service module 21 to determine an association query result.

[0032] In this way, when performing cross-object association queries, the instance information of the associated query object can be determined according to the service object type relationship graph and the service object instance relationship graph in the knowledge graph module, and the association query result can be determined according to the instance information of the associated query object. Therefore, the association query result can be obtained without modifying the data model or upgrading the software version of the data service, and thus the query efficiency is high, the rapid change of the business scenario can be adapted, and the rapid cross-object association query can be implemented.

[0033] The service object relationship data model described above can be used to define the relationship (or business relationship) between two different service object types. For example, the relationship between service object type A and service object type B, the relationship between service object type B and service object type C, and the like can be defined. It should be noted that the two different service object types here can be two service object types having a direct business relationship.

[0034] The business object instance relationship data described above can be used to describe the relationship (or business relationship) between object instances of two different business object types. For example, the relationship between an object instance of business object type A and an object instance of business object type B can be described. The object instances can include instance primary keys and instance characteristic fields, and the relationship between the object instances can be the relationship between the instance primary keys. It should be noted that the two different business object types here can be two business object types having a direct business relationship.

[0035] In some embodiments, in order to facilitate the description of the relationship between object instances of two different business object types, the business object instance relationship data can include a plurality of data tables, each data table being used to store instance relationship data between two business objects belonging to two different business object types, and the instance relationship data between the two business objects can include the corresponding relationship between the instance primary keys of the two business objects. That is, a data table can be established for each two business object types having a direct business relationship, and the data table is used to store instance relationship data between two business objects belonging to the two different business object types, and the instance relationship data can be relationship data between instance primary keys. Since each business object type can include a plurality of business objects, each data table can include a plurality of data records, and each data record is used to record the relationship data between the instance primary keys of two business objects belonging to two different business object types.

[0036] Taking business object type A and business object type B as an example for illustration. Assume that business object type A includes n business objects, which are a1, a2, …, an respectively, each business object corresponds to an object instance, and the instance primary keys of the object instances of the plurality of business objects are A1, A2, …, An respectively, and business object type B includes a plurality of business objects, which are b1, b2, …, bn respectively, each business object corresponds to an object instance, and the instance primary keys of the object instances of the plurality of business objects are B1, B2, …, Bn respectively, then when using a data table to store instance relationship data between two business objects belonging to business object type A and business object type B, the stored data can be as shown in Table 1.

[0037] Table 1

[0038] Table 1 includes n data records, and each data record is used to record the relationship between the instance primary keys of two business objects belonging to business object type A and business object type B. Taking the first data record as an example, the data record is used to record the instance relationship data between business object a1 and business object b1, which is the relationship between the instance primary key A1 of business object a1 and the instance primary key B1 of business object b1.

[0039] The business object type relationship graph is used to describe the relationship between different business object types. The business object type relationship graph can be composed of a plurality of entity nodes, each of which can represent a business object type, and the relationship between the entity nodes represents the relationship between the business object types.

[0040] The business object instance relationship graph is used to describe the relationship between object instances of different business object types. The business object instance relationship graph can be composed of a plurality of entity nodes, each of which can represent an instance of a business object, and the relationship between the entity nodes represents the relationship between instances of different business objects.

[0041] The business object type relationship graph and the business object instance relationship graph are used to determine the instance information of the associated query object. In some embodiments, the business object type relationship graph and the business object instance relationship graph are used to determine the instance information of the associated query object, which can be that the business object type relationship graph is used to determine the associated query path between the type of the first object and the type of the associated query object, and the business object instance relationship graph and the associated query path are used to determine the instance information of the associated query object. Wherein, the first object can be an object relied on when performing cross-object association query. For example, when the instance A1 of the business object type A needs to be associated with the object instance data of the related business object type W, the first object is the business object corresponding to the instance A1.

[0042] In some embodiments, the data service module 21 shown in FIG. 2 is also used to provide a business object data model and business object instance data. The business object data model is used to define the format of the business object instance data, that is, to define what content the business object instance data contains, such as defining that the business object instance data includes the business object type, the primary key and the characteristic field that need to be maintained by the business object type, etc. The business object instance data is the content corresponding to the format defined by the business object data model. For example, in the case of a carrier as a business object, the business object data model can define that the business object instance data of the carrier includes the carrier ID, the primary key and the characteristic field, and the business object instance data of the carrier can include carrier 1 (carrier ID), S1 (primary key) and 123 (characteristic field). In this embodiment, the business object data model is the basis for maintaining the business object relationship data model, the business object instance relationship data and the business object instance data in the data service module, and in the case of changes in the business object data model, the business object relationship data model, the business object instance relationship data and the business object instance data also need to be updated accordingly.

[0043] The business object type instance data can include instance data of multiple business object types. In some embodiments, the business object instance data can include multiple data tables, each data table being used to store instance data of multiple business objects belonging to the same business object type, and the instance data of each business object including an instance primary key and an instance characteristic field (which can be abbreviated as a primary key and a characteristic field). Since each business object type can include multiple business objects, each data table can include multiple data records, and each data record is used to record the instance data (including the instance primary key and the instance characteristic field) of a business object.

[0044] Taking the business object type A as an example, assuming that the business object type A includes n business objects, a1, a2, …, an, each business object corresponds to an object instance, and the instance primary keys of the object instances of the multiple business objects are A1, A2, …, An, and the instance characteristic fields are 12, 112, …, 456278, respectively, when using a data table to store the instance data of the multiple business objects belonging to the business object type A, the stored data can be as shown in Table 2.

[0045] Table 2

[0046] Table 2 includes n data records, and each data record is used to record the instance data of a business object belonging to the business object type A. Taking the first data record as an example, the data record is used to record the instance data of the business object a1, which is the instance primary key A1 and the instance characteristic field 12 of the business object a1.

[0047] In this embodiment, the business object instance data can be used by the data service module to determine the associated query result according to the instance information of the associated query object. In some implementations, the instance information of the associated query object can be the instance primary key of the associated query object, and accordingly, the associated query result can be the instance characteristic field of the associated query object. For example, if the type of the associated query object is the business object type A in Table 2, and the instance information of the associated query object is A1, then the associated query result is 12.

[0048] In the case where the data service module maintains the business object data model, the business object instance data, the business object relationship data model, and the business object instance relationship data, in some implementations, when at least one of the data changes, the knowledge graph module is further configured to update the business object type relationship graph and the business object instance relationship graph, so as to ensure the accuracy of the query result when performing cross-object association query according to the business object type relationship graph and the business object instance relationship graph.

[0049] Based on the association query system provided in the embodiments of the present application, when performing cross-object association query, the instance information of the associated query object can be determined according to the business object type relationship graph and the business object instance relationship graph in the knowledge graph module, and the association query result can be determined according to the instance information of the associated query object. Therefore, the association query result can be obtained without modifying the data model and upgrading the software version of the data service, and thus the query efficiency is high, the rapid change of the business scenario can be adapted, and the cross-object rapid association query is realized.

[0050] Based on the association query system provided in the embodiments of the present application, the present application further provides an association query method, which will be described below with reference to the embodiments shown in FIG. 3 and FIG. 4.

[0051] FIG. 3 is a flowchart of an association query method according to an embodiment of the present application. The method can be applied to the data service module in the association query system provided in the embodiments of the present application. The explanation of the data service module can refer to the corresponding content in the embodiment shown in FIG. 2, which will not be repeated here. The association query method shown in FIG. 3 includes the following steps.

[0052] S302: sending an association query request to the knowledge graph module, wherein the association query request includes the type information and the instance information of the first object, and the type information of the associated query object.

[0053] When performing cross-object association query, the data service module can send a cross-object association query request to the knowledge graph module, wherein the association query request carries the type information of the first object, the instance information of the first object, and the type information of the associated query object. For example, when the instance A1 of the business object type A needs to be associated with the object instance data of the business object type W, the association query request can carry the business object type A (i.e. the type information of the first object), the instance information A1 (i.e. the instance information of the first object), and the business object type W of the associated query object (i.e. the type information of the associated query object).

[0054] S304: receiving the instance information of the associated query object returned by the knowledge graph module, wherein the instance information of the associated query object is determined by the knowledge graph module according to the association query request, the business object type relationship graph, and the business object instance relationship graph.

[0055] The data service module sends an association query request to the knowledge graph module. The knowledge graph module can determine instance information of the associated query object according to the association query request, a business object type relationship graph maintained in the knowledge graph module, and a business object instance relationship graph, and the implementation can refer to the embodiment shown in FIG. 4, which will not be described in detail here. After obtaining the instance information of the associated query object, the knowledge graph module can send the instance information of the associated query object to the data service module. At this time, the data service module can receive the instance information of the associated query object returned by the knowledge graph module.

[0056] S306: Determine the association query result according to the instance information of the associated query object.

[0057] After receiving the instance information of the associated query object, the data service module can determine instance data corresponding to the instance information according to the instance information of the associated query object. The instance data is the association query result.

[0058] In some embodiments, the instance information of the associated query object can be an instance primary key of the associated query object. When determining the association query result according to the instance information of the associated query object, the following steps can be included: determining, according to the instance primary key of the associated query object, instance data of the associated query object from instance data of a business object type to which the associated query object belongs, the instance data of the associated query object including the instance primary key and an instance characteristic field; and determining the instance characteristic field of the associated query object as the association query result.

[0059] The instance data of the business object type to which the associated query object belongs includes the instance data of the associated query object and instance data of other business objects of the same type as the associated query object. The instance data of each business object includes an instance primary key and an instance characteristic field. After receiving the instance primary key of the associated query object returned by the knowledge graph module, the data service module can first determine, according to the business object type to which the associated query object belongs, instance data of the business object type to which the associated query object belongs from business object type instance data (including instance data of multiple business object types) maintained by the data service module, and then determine, according to the instance primary key of the associated query object, instance data of the associated query object from the instance data. The instance data of the associated query object includes an instance primary key and an instance characteristic field, and the instance characteristic field is the association query result.

[0060] For example, assuming that the type of the associated query object is W and the instance primary key of the associated query object is W11, when determining the association query result, the instance data of the business object type W can be determined from the business object instance data maintained by the data service module, as shown in Table 3, then the instance data of the associated query object is determined from Table 3 according to the instance primary key W11 of the associated query object, that is, the instance data recorded in the first data record in Table 3, and finally the instance feature field 12345 in the instance data of the associated query object is determined as the association query result.

[0061] Table 3

[0062] In the embodiment of the present application, when performing cross-object association query, the data service module can send an association query request to the knowledge graph module, the knowledge graph module determines the instance information of the associated query object according to the business object type relationship graph and the business object instance relationship graph in the knowledge graph module, and returns the instance information of the associated query object to the data service module, and the data service module determines the association query result according to the instance information of the associated query object. Therefore, when performing cross-object association query, the data service module can obtain the instance information of the associated query object by sending an association query request to the knowledge graph module, and then obtain the association query result, without modifying the data model and upgrading the software version of the data service, therefore, the query efficiency is high, which can adapt to the rapid changes of business scenarios and realize fast cross-object association query.

[0063] FIG. 4 is a flowchart of an association query method according to an embodiment of the present application, which can be applied to the knowledge graph module in the association query system provided by the embodiments of the present application. The explanation of the knowledge graph module can refer to the corresponding content in the embodiment shown in FIG. 2, which will not be repeated here. The association query method shown in FIG. 4 includes the following steps.

[0064] S402: receiving an association query request sent by the data service module, the association query request including the type information and instance information of the first object, and the type information of the associated query object.

[0065] When performing the cross-object association query, the data service module can send a cross-object association query request to the knowledge graph module, and the knowledge graph module can receive the association query request sent by the data service module. The association query request sent by the data service module carries the type information of the first object, the instance information of the first object, and the type information of the associated query object. For example, when the instance A1 of the business object type A needs to be associated with the object instance data of the business object type W, the association query request can carry the business object type A (i.e., the type information of the first object), the instance information A1 (i.e., the instance information of the first object), and the business object type W of the associated query object (i.e., the type information of the associated query object).

[0066] S404: Determine the instance information of the associated query object according to the association query request, the business object type relationship graph, and the business object instance relationship graph.

[0067] After receiving the association query request, the knowledge graph module can determine the instance information of the associated query object according to the association query request, the business object type relationship graph maintained in the knowledge graph module, and the business object instance relationship graph. The business object type relationship graph is constructed by the knowledge graph module according to the business object relationship data model maintained by the data service module, and the business object instance relationship graph is constructed by the knowledge graph module according to the business object instance relationship data maintained by the data service module. For details, please refer to the related content described in the embodiment shown in FIG. 2, which will not be described in detail here.

[0068] In some embodiments, the knowledge graph module determines the instance information of the associated query object according to the association query request, the business object type relationship graph, and the business object instance relationship graph, which can include the following steps: determining the association query path between the type of the first object and the type of the associated query object according to the type information of the first object, the type information of the associated query object, and the business object type relationship graph; determining the instance information of the associated query object according to the instance information of the first object, the association query path, and the business object instance relationship graph.

[0069] The business object type relationship graph is used to describe the relationship between different business object types. In the case that the type information of a first object and the type information of a correlated query object are known, the path information from the type entity node of the first object to the type entity node of the correlated query object can be obtained according to the business object type relationship graph, which is the association query path between the type of the first object and the type of the correlated query object. The association query path is a query path between N business object types, where N is an integer greater than or equal to 3. In the association query path, the first object type is the type of the first object, and the last object type is the type of the correlated query object. For example, assuming that the type of the first object is A and the type of the correlated query object is W, the association query path can be A→B→C→S→W. The association query path is a query path between 5 business object types, and includes 4 query paths, i.e., A→B, B→C, C→S, and S→W.

[0070] It should be noted that the number of association query paths can be one or more. In the case that the number of association query paths is more than one, in some embodiments, the shortest one (including the least number of business object type entity nodes) can be determined from the plurality of association query paths, and the shortest one is determined as the target association query path. In this way, when the instance information of the correlated query object is determined according to the association query path in the subsequent process, time can be saved and the query efficiency can be improved. In some possible embodiments, the number of association query paths can be 0, i.e., there is no association query path. In this case, a query failure information can be returned. The present embodiment is described by taking the case that there is an association query path as an example.

[0071] After the association query path (or the target association query path) is determined, the instance information of the correlated query object can be determined according to the instance information of the first object, the association query path (or the target association query path), and the business object instance relationship graph. In some embodiments, the following steps S1 and S2 can be included: the steps S1 and S2 are cyclically executed, and the object instance information determined in the last cycle is determined as the instance information of the correlated query object.

[0072] S1: determining the query path between the Mth object type and the (M+1)th object type in the N object types according to the association query path.

[0073] S2: determining the object instance information having a direct association relationship with the object instance information of the Mth object type from the plurality of object instance information of the (M+1)th object type according to the query path, the object instance information of the Mth object type, and the business object instance relationship graph.

[0074] The above S1 and S2 are executed for N-1 times (N is the number of business object types involved in the association query path). In the first loop, the initial value of M is 1, and the value of M is increased by 1 each time the loop is executed. In the last loop, the value of M is N-1. When M is equal to 1, the object instance information of the Mth object type is the instance information of the first object. When M is greater than 1 and less than or equal to N-1, the object instance information of the Mth object type is the object instance information determined in the last loop. After the above S1 and S2 are executed for N-1 times, the last obtained object instance information is the instance information of the object to be associated and queried.

[0075] Taking the association query path A→B→C→S→W and the instance information of the business object as the instance primary key as an example, assuming that the instance information of the first object is the instance primary key A1, when determining the instance information of the object to be associated and queried, the instance primary key having a direct association relationship with the instance primary key A1 can be determined from the object instance primary keys of the business object type B according to the instance primary key A1, the query path A→B and the business object instance relationship graph, assuming that the instance primary key is B1. After obtaining the instance primary key B1, the instance primary key having a direct association relationship with the instance primary key B1 can be determined from the object instance primary keys of the business object type C according to the instance primary key B1, the query path B→C and the business object instance relationship graph, assuming that the instance primary key is C1. After obtaining the instance primary key C1, the instance primary key having a direct association relationship with the instance primary key C1 can be determined from the object instance primary keys of the business object type S according to the instance primary key C1, the query path C→S and the business object instance relationship graph, assuming that the instance primary key is S1. After obtaining the instance primary key S1, the instance primary key having a direct association relationship with the instance primary key S1 can be determined from the object instance primary keys of the business object type W according to the instance primary key S1, the query path S→W and the business object instance relationship graph, assuming that the instance primary key is W11. Then, the instance primary key W11 is the instance information of the object to be associated and queried.

[0076] S406: Return the instance information of the object to be associated and queried to the data service module.

[0077] After obtaining the instance information of the object to be associated and queried, the knowledge graph module can return the instance information of the object to be associated and queried to the data graph module. After receiving the instance information of the object to be associated and queried, the data graph module can determine the association query result according to the instance information of the object to be associated and queried. The implementation can refer to the corresponding content in the embodiment shown in FIG. 3, which will not be repeated here.

[0078] In the embodiment of the present application, when performing cross-object association query, the instance information of the object to be associated is determined by the knowledge graph module according to the association query request sent by the data service module, the business object type relationship graph and the business object instance relationship graph in the knowledge graph module, and the association query result can be obtained by sending the instance information of the object to be associated to the data service module, so the query efficiency is high, the rapid change of the business scenario can be adapted, and the cross-object rapid association query is realized.

[0079] In order to facilitate understanding of the technical solutions provided by the embodiments of the present application, reference can be made to FIG. 5.

[0080] In FIG. 5, the data service module maintains the business object relationship data model, the business object instance data and the business object instance relationship data, the knowledge graph module maintains the business object type relationship graph and the business object instance relationship graph, the business object type relationship graph is generated according to the business object relationship data model maintained by the data service module, and the business object instance relationship graph is generated according to the business object instance relationship data maintained by the data service module. When the instance A1 of the business object type A needs to be associated with the object instance data of the business object type W related thereto, the data service module sends an association query request to the knowledge graph module, the knowledge graph module determines the association query path between the business object type A and the business object type W according to the business object type relationship graph, determines the instance information W11 of the object to be associated according to the association query path, the instance A1 and the business object instance relationship graph, and then returns W11 to the data service module. The data service module determines the instance data corresponding to W11 from the instance data of the business object type W according to W11, and determines the feature field 12345 in the instance data as the association query result.

[0081] The technical solutions provided by the embodiments of the present application can adaptively find the indirect association query path between any two business objects with indirect business relationship without updating the data model and upgrading the data service node, the association query result can be obtained according to the association query path, the query efficiency is high, the rapid change of the business scenario can be adapted, the cross-object rapid association query is realized, and the robustness of the data service is effectively improved.

[0082] The above describes specific embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims can be performed in an order other than that described in the embodiments and still achieve desirable results. In addition, the processes depicted in the figures do not necessarily require the particular order shown or sequential order in order to achieve the desired results. In some implementations, multitasking and parallel processing can be advantageous or necessary.

[0083] FIG. 6 is a structural schematic diagram of an electronic device according to an embodiment of the present application. Referring to FIG. 6, at the hardware level, the electronic device includes a processor, and further includes an internal bus, a network interface, and a memory. The memory can include a memory such as a random-access memory (RAM), and can further include a non-volatile memory such as at least one disk memory. Of course, the electronic device can further include other hardware required by a service.

[0084] The processor, the network interface, and the memory can be connected to each other through the internal bus, which can be an industry standard architecture (ISA) bus, a peripheral component interconnect (PCI) bus, or an extended industry standard architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one bidirectional arrow is used in FIG. 6, but it does not mean that there is only one bus or only one type of bus.

[0085] The memory is configured to store a program. The program can include program code including computer operation instructions. The memory can include a memory and a non-volatile memory, and provide instructions and data to the processor.

[0086] The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs, and forms an association query device at the logical level. The processor executes the program stored in the memory, and is configured to perform the following operations: sending an association query request to a knowledge graph module, the association query request including type information and instance information of a first object, and type information of an associated query object; receiving instance information of the associated query object returned by the knowledge graph module, the instance information of the associated query object being determined by the knowledge graph module according to the association query request, a business object type relationship graph, and a business object instance relationship graph; and determining an association query result according to the instance information of the associated query object.

[0087] Or for performing the following operations: receiving an association query request sent by a data service module, the association query request including type information and instance information of a first object, type information of the associated query object; determining instance information of the associated query object according to the association query request, a business object type relationship graph, and a business object instance relationship graph; and returning the instance information of the associated query object to the data service module.

[0088] The method performed by the association query device disclosed in the embodiment shown in FIG. 6 of the present application can be applied to a processor or implemented by the processor. The processor can be an integrated circuit chip having a signal processing capability. In the implementation process, each step of the above method can be completed by integrated logic circuits or instructions in the form of software in the processor. The processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), and the like; or can be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. Each method, step, and logic block diagram disclosed in the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in the present application can be directly embodied as a hardware code processor for execution, or a combination of hardware and software modules in the code processor for execution. The software module can be located in a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, or other mature storage media in the art. The storage medium is located in the memory, and the processor reads the information in the memory and combines the hardware to complete the steps of the above method.

[0089] The electronic device can also perform the methods of FIGS. 3 and 4 and implement the functions of the association query device in the embodiments shown in FIGS. 3 and 4, which will not be described herein.

[0090] Of course, in addition to the software implementation, the electronic device of the present application does not exclude other implementation manners, such as logic devices or a combination of software and hardware, and the like, that is, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or a logic device.

[0091] The application also provides a computer readable storage medium storing one or more programs including instructions which, when executed by a portable electronic device including a plurality of applications, enable the portable electronic device to perform the method of the embodiments shown in FIG. 3 and FIG. 4, and to perform the following operations: sending an association query request to a knowledge graph module, the association query request including type information and instance information of a first object, and type information of an associated query object; receiving instance information of the associated query object returned by the knowledge graph module, the instance information of the associated query object being determined by the knowledge graph module according to the association query request, a business object type relationship graph, and a business object instance relationship graph; and determining an association query result according to the instance information of the associated query object.

[0092] or for performing the following operations: receiving an association query request sent by a data service module, the association query request including type information and instance information of a first object, and type information of an associated query object; determining instance information of the associated query object according to the association query request, a business object type relationship graph, and a business object instance relationship graph; and returning the instance information of the associated query object to the data service module.

[0093] FIG. 7 is a structural schematic diagram of an association query device 70 according to an embodiment of the application. Referring to FIG. 7, in a software implementation, the association query device 70 can include a sending module 71, a receiving module 72, and a determining module 73, wherein: the sending module 71 sends an association query request to a knowledge graph module, the association query request including type information and instance information of a first object, and type information of an associated query object; the receiving module 72 receives instance information of the associated query object returned by the knowledge graph module, the instance information of the associated query object being determined by the knowledge graph module according to the association query request, the business object type relationship graph, and the business object instance relationship graph; and the determining module 73 determines an association query result according to the instance information of the associated query object.

[0094] In some embodiments, the instance information of the associated query object includes an instance primary key of the associated query object; and the determining module 73 determines an association query result according to the instance information of the associated query object, including: determining instance data of the associated query object from instance data of a business object type to which the associated query object belongs according to the instance primary key of the associated query object, the instance data of the associated query object including the instance primary key and instance characteristic fields of the associated query object; and determining the instance characteristic fields of the associated query object as the association query result.

[0095] The association query device 70 provided by the embodiments of the present application can also execute the method of FIG. 3 and realize the functions of the association query device 70 in the embodiment shown in FIG. 3. Details are not described herein again.

[0096] FIG. 8 is a structural schematic diagram of an association query device 80 according to an embodiment of the present application. Referring to FIG. 8, in a software implementation, the cross-association query device 80 can include a receiving module 81, a determining module 82 and a sending module 83, wherein: the receiving module 81 receives an association query request sent by the data service module, the association query request including type information and instance information of a first object and type information of an object to be queried; the determining module 82 determines instance information of the object to be queried according to the association query request, the business object type relationship graph and the business object instance relationship graph; and the sending module 83 returns the instance information of the object to be queried to the data service module.

[0097] In some embodiments, the determining module 82 determines the instance information of the object to be queried according to the association query request, the business object type relationship graph and the business object instance relationship graph, including: determining an association query path between the type of the first object and the type of the object to be queried according to the type information of the first object, the type information of the object to be queried and the business object type relationship graph; and determining the instance information of the object to be queried according to the instance information of the first object, the association query path and the business object instance relationship graph.

[0098] In some embodiments, the number of the association query paths is one or more; and when the number of the association query paths is more than one, the determining module 82 further determines a shortest association query path in the multiple association query paths as a target association query path.

[0099] In some embodiments, the association query path is a query path between N business object types, N being an integer greater than or equal to 3, in the association query path, a first object type is the type of the first object, and a last object type is the type of the associated query object; the determining module 82 determines the instance information of the associated query object according to the instance information of the first object, the association query path, and the business object instance relationship graph, including: cyclically performing the following operations, and determining the object instance information determined in the last cycle as the instance information of the associated query object: determining a query path between an Mth object type and an (M+1)th object type in the N object types according to the association query path; determining, from a plurality of object instance information of the (M+1)th object type, object instance information having a direct association relationship with the object instance information of the Mth object type according to the query path, the object instance information of the Mth object type, and the business object instance relationship graph; wherein the number of cycles is N-1, in the first cycle, the initial value of M is 1, and the value of M is increased by 1 each cycle, in the case that M is equal to 1, the object instance information of the Mth object type is the instance information of the first object, and in the case that M is greater than 1 and less than or equal to N-1, the object instance information of the Mth object type is the object instance information determined in the last cycle.

[0100] The association query device 80 provided by the embodiments of the present application can also perform the method of FIG. 4, and realize the functions of the association query device 80 in the embodiment shown in FIG. 4, which will not be repeated here.

[0101] The present application further provides a computer program product, which comprises a non-transitory computer-readable storage medium storing a computer program capable of operating a computer to perform some or all of the steps in the above-mentioned association query method embodiments.

[0102] In summary, the above only describes preferred embodiments of the present application and is not used to limit the protection scope of the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

[0103] The systems, devices, modules or units illustrated by the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. The computer may, for example, be a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

[0104] Computer-readable media includes permanent and non-permanent, movable and non-movable media that can implement information storage by any method or technology. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassette, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information accessible to a computing device. According to the definition herein, computer-readable media does not include transitory media such as modulated data signals and carriers.

[0105] It should also be noted that the terms "comprising", "containing", or any other variant thereof are intended to cover non-exclusive inclusions, so that a process, method, article or apparatus that includes a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or apparatus. Without more limitations, the element defined by the statement "comprising a" does not exclude the presence of other identical elements in the process, method, article or apparatus that includes the element.

[0106] The various embodiments in the present application are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on the difference from other embodiments. In particular, for system embodiments, since they are basically similar to method embodiments, the description is relatively simple, and the relevant parts can be referred to the part of the method embodiment.

Claims

1. An associated query system, comprising a data service module and a knowledge graph module, the data service module is configured to provide a business object relationship data model and business object instance relationship data, the business object relationship data model is configured to define the relationship between two different business object types, and the business object instance relationship data is configured to describe the relationship between object instances of two different business object types; the knowledge graph module is configured to determine a business object type relationship graph according to the business object relationship data model and a business object instance relationship graph according to the business object instance relationship data, the business object type relationship graph and the business object instance relationship graph are configured to determine instance information of an associated query object, and the instance information is configured to be used by the data service module to determine an associated query result.

2. The system of claim 1, wherein the business object type relationship graph is configured to determine an associated query path between the type of a first object and the type of the associated query object; and the business object instance relationship graph and the associated query path are configured to determine the instance information of the associated query object.

3. The system of claim 1, wherein the business object instance relationship data comprises a plurality of data tables, each data table is configured to store instance relationship data between two business objects belonging to two different business object types, the two different business object types have a direct business relationship, and the instance relationship data between the two business objects comprises a corresponding relationship between the instance primary keys of the two business objects.

4. The system of any one of claims 1 to 3, wherein the data service module is further configured to provide a business object data model and business object instance data, the business object data model is configured to define the format of the business object instance data, and the business object instance data is configured to be used by the data service module to determine the associated query result according to the instance information of the associated query object.

5. The system of claim 4, wherein the business object instance data comprises a plurality of data tables, each data table is configured to store instance data of a plurality of business objects belonging to the same business object type, and the instance data of each business object comprises an instance primary key and an instance characteristic field; wherein the instance information of the associated query object comprises an instance primary key of the associated query object, and the associated query result comprises an instance characteristic field of the associated query object.

6. The system of claim 4, wherein in the case that at least one of the business object data model, the business object instance data, the business object relationship data model, and the business object instance relationship data changes, the knowledge graph module is further configured to update the business object type relationship graph and the business object instance relationship graph.

7. An associated query method applied to the data service module of the associated query system of any one of claims 1 to 6, the method comprising: sending an associated query request to the knowledge graph module, the associated query request comprising type information and instance information of a first object, and type information of the associated query object. receiving the instance information of the associated query object returned by the knowledge graph module, the instance information of the associated query object being determined by the knowledge graph module according to the association query request, the business object type relationship graph, and the business object instance relationship graph; determining an association query result according to the instance information of the associated query object.

8. The method of claim 7, wherein the instance information of the associated query object comprises an instance primary key of the associated query object. The method further comprises: determining instance data of the associated query object from instance data of a business object type to which the associated query object belongs according to the instance primary key of the associated query object, the instance data of the associated query object comprising the instance primary key and instance characteristic fields of the associated query object; determining the instance characteristic fields of the associated query object as the association query result.

9. An association query method applied to a knowledge graph module in the association query system of any one of claims 1 to 6, the method comprising: receiving an association query request sent by the data service module, the association query request comprising type information and instance information of a first object and type information of the associated query object; determining instance information of the associated query object according to the association query request, the business object type relationship graph, and the business object instance relationship graph; returning the instance information of the associated query object to the data service module.

10. The method of claim 9, wherein determining the instance information of the associated query object according to the association query request, the business object type relationship graph, and the business object instance relationship graph comprises: determining an association query path between the type of the first object and the type of the associated query object according to the type information of the first object, the type information of the associated query object, and the business object type relationship graph; determining the instance information of the associated query object according to the instance information of the first object, the association query path, and the business object instance relationship graph.

11. The method of claim 10, wherein the number of the association query paths is one or more; and when the number of the association query paths is more than one, the method further comprises: determining a target association query path as the shortest one among the plurality of association query paths.

12. The method of claim 10 or 11, wherein the association query path is a query path between N business object types, N being an integer greater than or equal to 3, and in the association query path, the first object type is the type of the first object and the last object type is the type of the associated query object; and determining the instance information of the associated query object according to the instance information of the first object, the association query path, and the business object instance relationship graph comprises: performing the following operations in a loop and determining the instance information of the associated query object as the object instance information determined in the last loop: determining a query path between an Mth object type and an M+1th object type of the N object types according to the association query path; determining object instance information having a direct association relationship with the object instance information of the Mth object type from a plurality of object instance information of the M+1th object type according to the query path, the object instance information of the Mth object type and the business object instance relationship graph; wherein the number of cycles is N-1, in the first cycle, the initial value of M is 1, the value of M is increased by 1 each cycle, in the case of M equal to 1, the object instance information of the Mth object type is the instance information of the first object, in the case of M greater than 1 and less than or equal to N-1, the object instance information of the Mth object type is the object instance information determined in the last cycle. 13.An electronic device comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to execute the instructions to implement the method of any one of claims 7 to 12. 14.A computer readable storage medium, when instructions in the storage medium are executed by a processor of an electronic device, enabling the electronic device to perform the method of any one of claims 7 to 12. 15.A computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps of the method of any one of claims 7 to 12.

Citation Information

Patent Citations

  • Method and device for knowledge graph creation, and computer readable storage medium

    CN111191039A

  • Knowledge query method and device

    CN111930778A

  • Attribute graph-based industry knowledge graph modeling method and system

    CN117992619A

  • Aircraft support knowledge question-answering method based on knowledge graph

    CN118035400A

  • Query response service for business objects

    US20090164414A1