Resource pushing method and apparatus, storage medium, and electronic device
Patent Information
- Application Number
- CN202610880964.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-16
- Publication Date
- 2026-09-22
AI Technical Summary
[0005]本申请实施例提供了一种资源推送方法和装置、存储介质及电子装置,以至少解决相关技术中基于标签精准匹配课程的方法无法有效识别和利用学员与课程之间的非线性关系,导致的推送精度低的问题
[0015]根据本申请实施例的又一方面,还提供了一种电子装置,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其中,上述处理器通过计算机程序执行上述的资源推送方法。
Smart Images

Figure CN122796291A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of smart home technology, and more specifically, to a resource push method and apparatus, storage medium and electronic device. Background Technology
[0002] In enterprise training digital systems, two core data objects are typically included: learners (employees) and courses. To achieve personalized learning, suitable courses need to be matched and recommended to learners. This relies on a deep understanding and matching of the attributes of these two types of objects. Existing tag-based precise matching rules cannot effectively identify and utilize the potential, non-linear semantic relationships between learners and courses (e.g., implicit relationships through skill advancement paths and job competency models). This results in recommendations that remain at a superficial level of matching, with limited personalization and accuracy.
[0003] Therefore, the tag-based precise course matching method in related technologies cannot effectively identify and utilize the non-linear relationship between students and courses, resulting in low push accuracy.
[0004] There is no effective solution yet to address the problem that tag-based courses cannot effectively identify and utilize the non-linear relationship between students and courses, resulting in low push accuracy. Summary of the Invention
[0005] This application provides a resource push method and apparatus, storage medium and electronic device to at least solve the problem of low push accuracy caused by the inability of tag-based precise course matching methods in related technologies to effectively identify and utilize the nonlinear relationship between students and courses.
[0006] According to one embodiment of this application, a resource push method is provided, comprising: determining a first instance node corresponding to a target object in an instance data layer of a target knowledge graph, and determining a target node connected to the first instance node through a target edge, wherein the target edge is used to connect entity instance nodes and attribute value nodes in the instance data layer, and / or to connect multiple entity instance nodes in the instance data layer, wherein the entity instance nodes include at least one of the following: object entity instance nodes, resource entity instance nodes, and other entity instance nodes; constructing a local subgraph corresponding to the target object based on the first instance node and the target node; determining a target rule entity matching the local subgraph among multiple rule entities in the rule layer based on the triggering condition of each rule entity, and determining a target resource instance node in the instance data layer according to the execution logic of the target rule entity, wherein the target knowledge graph includes: a rule layer, and the entity instance nodes include: the target resource instance node; and determining a target resource to be pushed to the target object based on the target resource instance node.
[0007] In an exemplary embodiment, before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, the method includes: obtaining first business data corresponding to each ontology contained in the ontology layer from multiple data sources, and converting the first business data into a target format to obtain second business data, wherein the target knowledge graph includes: the ontology layer, and the multiple ontology in the ontology layer includes at least one of the following: entity type nodes and attribute type nodes; matching the second business data with each ontology to determine the graph semantic category corresponding to each second business data, and constructing an element mapping relationship table based on the first matching result of the second business data and each ontology, wherein the element mapping relationship table is used to indicate the mapping relationship between each second business data and each ontology; creating entity instance nodes with mapping relationships to each entity type and / or attribute value nodes with mapping relationships to each attribute type in the instance data layer according to the element mapping relationship table; writing the second business data into the entity instance nodes or the attribute value nodes based on the element mapping relationship table; and constructing an instance graph contained in the instance data layer according to the entity instance nodes and / or attribute value nodes containing the second business data.
[0008] In an exemplary embodiment, before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, the method includes: upon receiving a business request sent by any object, extracting keywords from the business request according to a semantic segmentation model; parsing each business request according to the keywords in the business request to determine the triggering condition and execution logic corresponding to each business request; constructing a first rule entity corresponding to each business request according to the triggering condition and execution logic corresponding to each business request; and constructing multiple rule entities in the rule layer based on multiple first rule entities.
[0009] In an exemplary embodiment, constructing multiple rule entities in the rule layer based on multiple first rule entities includes: matching keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, wherein the multiple ontologies in the ontology layer include at least one of the following: entity type nodes and attribute type nodes; if it is determined that the keywords in each first rule entity match any ontology, establishing a first association relationship between each first rule entity and the ontology matching each first rule entity; and determining a second instance node and / or a first attribute value node matching each first rule entity in the instance data layer, and establishing a second association relationship between each first rule entity and the data in the second instance node, and / or between each rule entity and the data in the first attribute value node; and determining each first rule entity after establishing the first association relationship and the second association relationship as a rule entity in the rule layer.
[0010] In an exemplary embodiment, after matching keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, the method further includes: if it is determined that keywords in a second rule entity do not match any ontology in the ontology layer, constructing a target ontology in the ontology layer based on the keywords in the second rule entity, and constructing a third instance node or a second attribute value node corresponding to the target ontology in the instance data layer, wherein the multiple first rule entities include: the second rule entity; establishing a third association relationship between the second rule entity and the target ontology, and establishing a fourth association relationship between the second rule entity and data in the third instance node or between the second rule entity and data in the second attribute value node; determining the second rule entity after establishing the third association relationship and the fourth association relationship as a rule entity in the rule layer.
[0011] In an exemplary embodiment, determining the target resource to be pushed to the target object based on the target resource instance node includes: determining the candidate resource corresponding to each target resource instance node; deduplicating multiple candidate resources; and determining the deduplicated candidate resource as the target resource.
[0012] In an exemplary embodiment, after determining the target resources to be pushed to the target object based on the target resource instance nodes, the method further includes: determining the association edges between the target object and the target resource instance nodes corresponding to each target resource, and obtaining the weight corresponding to each association edge; calculating the matching degree score between each target resource and the target object based on the weight, and sorting the multiple target resources based on the matching degree score; constructing a resource push list according to the sorting order of the multiple target resources, and pushing the resource push list to the target object, wherein the resource push list contains multiple target resources sorted based on the sorting order.
[0013] According to another embodiment of the present application, a resource push device is also provided, comprising: a first determining module, configured to determine a first instance node corresponding to a target object in an instance data layer of a target knowledge graph, and to determine a target node connected to the first instance node through a target edge, wherein the target edge is used to connect entity instance nodes and attribute value nodes in the instance data layer, and / or to connect multiple entity instance nodes in the instance data layer, wherein the entity instance nodes include at least one of the following: object entity instance nodes, resource entity instance nodes, and other entity instance nodes; a construction module, configured to construct a local subgraph corresponding to the target object based on the first instance node and the target node; a second determining module, configured to determine a target rule entity matching the local subgraph among multiple rule entities in a rule layer based on the triggering conditions of each rule entity, and to determine a target resource instance node in the instance data layer according to the execution logic of the target rule entity, wherein the target knowledge graph includes: a rule layer, and the entity instance nodes include: the target resource instance node; and a third determining module, configured to determine a target resource to be pushed to the target object based on the target resource instance node.
[0014] According to another aspect of the embodiments of this application, a computer-readable storage medium is also provided, wherein a computer program is stored in the computer-readable storage medium, and the computer program is configured to execute the above-described resource push method at runtime.
[0015] According to another aspect of the embodiments of this application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the resource push method described above through the computer program.
[0016] According to another aspect of the embodiments of this application, a computer program product is also provided, including a computer program, wherein the computer program is executed by a processor using the resource push method described above.
[0017] In this embodiment, a first instance node corresponding to the target object is determined in the instance data layer of the target knowledge graph, and a target node connected to the first instance node through a target edge is also determined. A local subgraph corresponding to the target object is constructed based on the first instance node and the target node. Then, based on the triggering conditions of each rule entity, a target rule entity matching the local subgraph is determined from multiple rule entities in the rule layer of the target knowledge graph. A target resource instance node is determined in the instance data layer based on the execution logic of the target rule entity. Finally, the target resource to be pushed to the target object is determined based on the target resource instance node. In other words, this application constructs a target knowledge graph that includes at least an instance data layer and a rule layer. After determining the first instance node corresponding to the target object in the instance data layer, a target node connected to the first instance node can be determined. The target node can be a resource entity instance node, an object entity instance node, or other entity instance nodes. Furthermore, the local subgraph constructed based on the first instance node and the target node can quickly match the target rule entity in the rule layer. Then, based on the execution logic of the target rule entity, the target resource instance node is determined in the instance data layer. Finally, the target resource (e.g., a course) is determined based on the target resource instance node. This application addresses the problem of low push accuracy caused by the inability of tag-based precise course matching methods in related technologies to effectively identify and utilize the non-linear relationship between students and courses. Furthermore, by constructing a local subgraph in the target knowledge graph, matching target rule entities based on the local subgraph, and determining target resources based on the execution logic of the target rule entities, this technical solution can identify the non-linear relationship between students and courses (e.g., student-resource-course) and improve push accuracy. Attached Figure Description
[0018] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0019] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1 This is a schematic diagram of the hardware environment for a resource push method according to an embodiment of this application;
[0021] Figure 2 This is a flowchart of a resource push method according to an embodiment of this application;
[0022] Figure 3 This is an architecture diagram of a course recommendation system based on SPG knowledge graph according to an optional embodiment of this application;
[0023] Figure 4 This is a schematic diagram illustrating an example of dynamic tag and rule expansion according to an optional embodiment of this application;
[0024] Figure 5 This is a schematic diagram (a) of the intelligent recommendation process according to an optional embodiment of this application;
[0025] Figure 6 This is a schematic diagram (II) of the intelligent recommendation process according to an optional embodiment of this application;
[0026] Figure 7 This is a structural block diagram of a resource push device according to an embodiment of this application. Detailed Implementation
[0027] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0028] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0029] According to one aspect of the embodiments of this application, a resource push method is provided. This resource push method is widely used in whole-house intelligent digital control application scenarios such as smart homes, smart home device ecosystems, and intelligencehouse ecosystems. Optionally, Figure 1 This is a schematic diagram of the hardware environment for a resource push method according to an embodiment of this application. In this embodiment, the above-described resource push method can be applied to a computer device, and the computer device can be applied to, for example, Figure 1 The hardware environment shown consists of home appliance 102 and server 104. Figure 1 As shown, server 104 is connected to home appliance 102 via a network and can be used to provide services (such as application services) to nodes or clients installed on nodes. A database can be set up on the server or independently to provide data storage services for server 104. Cloud computing and / or edge computing services can be configured on the server or independently to provide data processing services for server 104.
[0030] The aforementioned networks may include, but are not limited to, at least one of the following: wired network, wireless network. The aforementioned wired network may include, but is not limited to, at least one of the following: wide area network (WAN), metropolitan area network (MAN), local area network (LAN). The aforementioned wireless network may include, but is not limited to, at least one of the following: Wi-Fi (Wireless Fidelity), Bluetooth. Home appliances 102 may not be limited to smart air conditioners, smart range hoods, smart refrigerators, smart ovens, smart stoves, smart washing machines, smart water heaters, smart washing equipment, smart dishwashers, smart projectors, smart TVs, smart clothes racks, smart curtains, smart audio-visual equipment, smart sockets, smart speakers, smart speakers, smart fresh air systems, smart kitchen and bathroom equipment, smart bathroom fixtures, smart robot vacuum cleaners, smart window cleaning robots, smart mopping robots, smart air purifiers, smart steam ovens, smart microwave ovens, smart water heaters, smart air purifiers, smart water dispensers, smart door locks, etc.
[0031] This embodiment provides a resource push method, applied to the aforementioned computer device. Figure 2 This is a flowchart of a resource push method according to an embodiment of this application, which includes the following steps:
[0032] Step S202: In the instance data layer of the target knowledge graph, determine the first instance node corresponding to the target object, and determine the target node connected to the first instance node through the target edge. The target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or to connect multiple entity instance nodes in the instance data layer. The entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node.
[0033] The target knowledge graph includes: ontology layer, instance data layer, and rule layer.
[0034] The ontology layer includes metadata nodes such as entity type definition, relation type definition, and attribute definition, which form an ontology network through edges such as isTypeOf and hasProperty.
[0035] The instance data layer includes entities such as students (target objects include students), courses (target resources include courses), and skills, as well as the relationships between them. These entity attributes can reference definitions in the ontology layer.
[0036] The rules layer can reference entities, attributes, and relationships defined in the dynamic ontology layer, thereby decoupling the rules from the data model.
[0037] Step S204: Construct a local subgraph corresponding to the target object based on the first instance node and the target node;
[0038] Step S206: Based on the triggering conditions of each rule entity, determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer, and determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node.
[0039] Step S208: Determine the target resource to be pushed to the target object based on the target resource instance node.
[0040] In this embodiment, a first instance node corresponding to the target object is determined in the instance data layer of the target knowledge graph, and a target node connected to the first instance node through a target edge is also determined. A local subgraph corresponding to the target object is constructed based on the first instance node and the target node. Then, based on the triggering conditions of each rule entity, a target rule entity matching the local subgraph is determined from multiple rule entities in the rule layer of the target knowledge graph. A target resource instance node is determined in the instance data layer based on the execution logic of the target rule entity. Finally, the target resource to be pushed to the target object is determined based on the target resource instance node. In other words, this application constructs a target knowledge graph that includes at least an instance data layer and a rule layer. After determining the first instance node corresponding to the target object in the instance data layer, a target node connected to the first instance node can be determined. The target node can be a resource entity instance node, an object entity instance node, or other entity instance nodes. Furthermore, the local subgraph constructed based on the first instance node and the target node can quickly match the target rule entity in the rule layer. Then, based on the execution logic of the target rule entity, the target resource instance node is determined in the instance data layer. Finally, the target resource (e.g., a course) is determined based on the target resource instance node. This application addresses the problem of low push accuracy caused by the inability of tag-based precise course matching methods in related technologies to effectively identify and utilize the non-linear relationship between students and courses. Furthermore, by constructing a local subgraph in the target knowledge graph, matching target rule entities based on the local subgraph, and determining target resources based on the execution logic of the target rule entities, this technical solution can identify the non-linear relationship between students and courses (e.g., student-resource-course) and improve push accuracy.
[0041] Optionally, before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph in step S202, the method includes: obtaining first business data corresponding to each ontology contained in the ontology layer from multiple data sources, and converting the first business data into a target format to obtain second business data, wherein the target knowledge graph includes: the ontology layer, and the multiple ontology in the ontology layer includes at least one of the following: entity type nodes and attribute type nodes; matching the second business data with each ontology to determine the graph semantic category corresponding to each second business data, and constructing an element mapping relationship table based on the first matching result of the second business data and each ontology, wherein the element mapping relationship table is used to indicate the mapping relationship between each second business data and each ontology; creating entity instance nodes with mapping relationships to each entity type and / or attribute value nodes with mapping relationships to each attribute type in the instance data layer according to the element mapping relationship table; writing the second business data into the entity instance nodes or the attribute value nodes based on the element mapping relationship table; and constructing an instance graph contained in the instance data layer according to the entity instance nodes and / or attribute value nodes containing the second business data.
[0042] Understandably, the technical solution for constructing the instance graph is as follows:
[0043] The system collects raw data corresponding to the entity from multiple business systems: The enterprise has multiple business systems, such as a human resources management system, employee training platform, performance appraisal system, and talent development archive. Each system independently records business information related to employees and courses, but the data format, naming rules, and storage methods are not uniform. The system periodically or triggerively collects primary business data from these systems through a standard interface.
[0044] For example, the human resources system provides: Employee ID: E1001, Position: Product Manager, Date of Joining: 2024-03-15, Job Level: P6.
[0045] The system transforms raw data into a structured target format: Based on predefined semantic specifications in the dynamic ontology layer (i.e., the ontology layer), each piece of first-level business data is converted into a standardized second-level business data format that can be recognized by the graph engine. This target format is a triple structure: (Subject ID, Relationship or Attribute Type, Target Value). For example: Raw data, Job Title: Product Manager - transformed into: (E1001, Belongs to Job Title, Product Manager).
[0046] The conversion process includes: field semantic mapping: uniformly identifying "position" as "belongs to position"; data type standardization: converting the character type "0.85" to the numeric type; enumeration normalization: mapping "P6" to the system-defined job level; deduplication and cleaning: removing null values, invalid values, and duplicate records.
[0047] The transformed data is semantically matched with the ontology layer nodes to establish a mapping relationship: the relationship or attribute type in each piece of second business data is automatically compared with the core semantic nodes in the dynamic ontology layer.
[0048] The dynamic ontology layer contains two types of core nodes: entity type nodes, such as “employee”, “course”, “position”, and “skill type”; and attribute type nodes, such as “date of employment”, “proficiency”, “course difficulty”, and “department”.
[0049] The system determines whether "E1001" belongs to the "Employee" type - Yes; whether "belongs to the position" is a system-defined relationship type - Yes; whether "Product Manager" is a valid instance under the "Position" type - Yes; whether "Skill Proficiency" is a system-defined attribute type - Yes; when the match is successful, a mapping relationship is established between the second business data and the corresponding ontology node, and it is recorded in an internal element mapping relationship table.
[0050] Based on the mapping relationship, instance nodes and attribute value nodes are automatically created: missing nodes are automatically created in the instance data layer according to the element mapping relationship table. If an entity identifier (such as "E1001") does not yet exist in the graph, an entity instance node is created and bound to its entity type (such as "employee"); if an attribute value (such as "0.85") needs to be attached to a relationship edge, an attribute value node is created as additional information for that edge.
[0051] Write data and build a complete instance graph: After all nodes and relationships are created, the specific values from the second business data are written to the corresponding nodes or relationship edges, ultimately forming a structurally complete and semantically coherent instance graph. In this graph, each node is a real business object, each edge carries a semantic association, and each attribute value originates from real data.
[0052] Optionally, before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph in step S202, the method includes: upon receiving a business request sent by any object, extracting keywords from the business request according to a semantic segmentation model; parsing each business request according to the keywords in the business request to determine the triggering condition and execution logic corresponding to each business request; constructing a first rule entity corresponding to each business request according to the triggering condition and execution logic corresponding to each business request; and constructing multiple rule entities in the rule layer based on multiple first rule entities.
[0053] The method of constructing multiple rule entities in the rule layer based on multiple first rule entities includes: matching keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, wherein the multiple ontologies in the ontology layer include at least one of the following: entity type nodes and attribute type nodes; if it is determined that the keywords in each first rule entity match any ontology, establishing a first association relationship between each first rule entity and the ontology that matches each first rule entity; and determining a second instance node and / or a first attribute value node that matches each first rule entity in the instance data layer, and establishing a second association relationship between each first rule entity and the data in the second instance node, and / or between each rule entity and the data in the first attribute value node; and determining each first rule entity after establishing the first association relationship and the second association relationship as a rule entity in the rule layer.
[0054] Understandably, rule entities can be automatically generated based on business requirements for semantic parsing. Specifically:
[0055] Receive business requirements and extract semantic keywords: When business personnel submit a business description through a graphical interface, voice input, or text box, the system receives the business requirement. Using a semantic segmentation model, the natural language statement is broken down into semantically meaningful keyword combinations. These keywords are not simply the results of word segmentation, but rather core semantic units such as business actions, objects, conditions, and attributes extracted after semantic understanding.
[0056] For example, a business person might input: "Recommend corporate culture courses for employees who are product managers and have been with the company for less than a year."
[0057] The system extracts keywords: Object type: employee, course; Attribute type: position, start date; Condition type: yes, less than one year; Action type: recommendation; Goal type: corporate culture.
[0058] Analyze business requirements and determine triggering conditions and execution logic: Based on extracted keywords, automatically identify the triggering conditions and execution logic within the business requirement. Triggering conditions: Describe "under what circumstances the rule is triggered," i.e., the constraints for filtering target objects; Execution logic: Describe "what to do after triggering," i.e., the recommended action or operational goal to be executed.
[0059] Construct the first rule entity and bind its semantic structure: Based on the parsed triggering conditions and execution logic, create a first rule entity, which is a structured data object containing: the logical expression of the triggering conditions (e.g., job title = product manager and employment time < 365 days); the target description of the execution logic (e.g., matching course type = corporate culture); and the original source of the semantic keywords (for tracing). The first rule entity is not yet bound to the graph semantics; it is merely a semantically structured container of rules to be verified.
[0060] The rule entities are dynamically associated with the graph ontology layer and instance layer to form executable rules: each first rule entity undergoes dual semantic verification and binding to ensure that all objects and attributes it references exist in the semantic system of the graph.
[0061] Keyword and ontology layer node matching verification: Each keyword in the first rule entity is matched with the semantic nodes in the "dynamic ontology layer" to determine whether it is a valid entity type, attribute type, or relation type. The dynamic ontology layer includes: entity type nodes: employee, course, position, course type; attribute type nodes: start date, proficiency, difficulty level; relation type nodes: belongs to position, possesses skills, belongs to course type.
[0062] Establish the first association between the rule and the ontology layer: After confirming the semantic legality, establish the first association in the rule entity: "Job position" in the rule points to the "Job position" entity type node in the ontology layer; "Job start date" in the rule points to the "Job start date" attribute type node in the ontology layer; "Corporate culture" in the rule points to the "Corporate culture" instance node under the "Course type" entity type node in the ontology layer.
[0063] In the instance data layer, find matching data and establish a second association: In the instance data layer, find specific instance data corresponding to the keywords in the rules and establish a second association: In the instance data layer, check if there is an "employee" entity node with the "position" attribute value of "product manager"; check if there is a "course" entity node with the "course type" attribute value of "corporate culture".
[0064] Complete the final generation of the rule entity: After the first association (with ontology layer semantics) and the second association (with instance layer data) are established, the first rule entity is formally upgraded to an "executable rule entity in the rule layer".
[0065] The method further includes, after matching the keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, the method further includes: if it is determined that the keywords in a second rule entity do not match any ontology in the ontology layer, constructing a target ontology in the ontology layer based on the keywords in the second rule entity, and constructing a third instance node or a second attribute value node corresponding to the target ontology in the instance data layer, wherein the multiple first rule entities include: the second rule entity; establishing a third association relationship between the second rule entity and the target ontology, and establishing a fourth association relationship between the second rule entity and the data in the third instance node or the second rule entity and the data in the second attribute value node; and determining the second rule entity after establishing the third association relationship and the fourth association relationship as the rule entity in the rule layer.
[0066] It is understandable that the steps of identifying unknown semantics, dynamically constructing the ontology, synchronously generating instances, and finally forming executable rules are as follows:
[0067] Identifying Semantic Missing Points: Keywords have no corresponding counterparts in the ontology layer. A business user inputs a new requirement via natural language, such as: "Recommend 'Sustainable Development Management' related courses to employees who have participated in 'Green Transformation Projects'." Semantic parsing of this sentence extracts key semantic units: "Green Transformation Projects": representing a specific project type; "Participation": representing the relationship between employees and projects; "Sustainable Development Management": representing a type of course theme. Semantic retrieval is performed in the dynamic ontology layer: Does a "Project Type" node exist with the value "Green Transformation Projects"? No; Does a relationship type like "Participation in Projects" exist? No; Does "Sustainable Development Management" exist as a course type? No. When all keywords cannot match any entity type node, attribute type node, or relationship type node in the ontology layer, it is determined that the requirement introduces entirely new business semantics that are not yet recognized by the system.
[0068] Semantic-based target ontology generation: Based on semantic logic, the following target ontology is generated: A new entity type node is created: Project Experience Type, used to classify the various projects that employees have participated in; Under this type, an instance node is created: Green Transformation Project, serving as the semantic carrier of the specific project name; A new relationship type node is created: Participation Project, used to establish the association between employees and project experience; A new entity type node is created: Course Topic; Under this type, an instance node is created: Sustainable Development Management.
[0069] After expanding the ontology layer, immediately create corresponding instance nodes or attribute value nodes in the instance data layer. In the instance data layer, check if there is already data linking employees to the "Green Transformation Project" (e.g., from the project management system or HR files). If relevant records exist, create an instance node: Employee A Participating in Project: Green Transformation Project, retaining the original attributes (e.g., participation time, role). If no such data exists, create an empty node to be filled, retaining only the structural relationship, awaiting subsequent data injection. Simultaneously, at the course level, create: Course Instance: Sustainable Development Management, and bind its type to "Course Topic"; at this point, even if the relevant employee has not yet been recorded as participating in the project.
[0070] Two key relationships are established within the rule entities: Third relationship: Semantic binding between rules and the ontology layer: In the rule, "Green Transformation Project" is associated with the newly created "Green Transformation Project" instance node under "Project Experience Type" in the ontology layer; in the rule, "Participation" is associated with the newly created "Participation in Projects" relationship type in the ontology layer; in the rule, "Sustainable Development Management" is associated with the newly created "Sustainable Development Management" instance node under "Course Theme" in the ontology layer. Fourth relationship: Data binding between rules and the instance layer: In the rule, "Employee Participation in Green Transformation Projects" is associated with the existing "Employee A - Participation in Projects - Green Transformation Projects" relationship in the instance layer; in the rule, "Recommended Course: Sustainable Development Management" is associated with the "Course: Sustainable Development Management" node in the instance layer.
[0071] Generate an executable rule entity: Once the above dual associations are established, the system will formally upgrade the original rule entity (i.e., the second rule entity) into a valid rule entity in the rule layer.
[0072] The rule entity has a complete structure: Triggering condition: Employees have participated in green transformation projects; Execution logic: Recommend sustainable development management courses; Semantic source: All are bound to the ontology nodes automatically generated by the system; Data anchor: Project and course nodes in the associated instance layer.
[0073] Optionally, step S208 above, which determines the target resource to be pushed to the target object based on the target resource instance node, includes: determining the candidate resource corresponding to each target resource instance node; deduplicating multiple candidate resources; and determining the deduplicated candidate resource as the target resource.
[0074] Understandably, based on the activation rules, starting from the target student node, a multi-hop traversal is performed along the semantic relationships in the graph to gradually expand to all possible course nodes that meet the conditions. The endpoint of each path is a potential recommendation candidate, i.e., a candidate resource. All identified candidate resources are uniformly collected and compared based on the unique identifier of the resource entity (such as course ID, course name, version number, and other semantically unique attributes), automatically identifying and eliminating duplicates. After deduplication, the remaining set of unique candidate resources is confirmed as the final target resource for this recommendation.
[0075] Optionally, after determining the target resources to be pushed to the target object based on the target resource instance nodes in step S208 above, the method further includes: determining the association edges between the target object and the target resource instance nodes corresponding to each target resource, and obtaining the weight corresponding to each association edge; calculating the matching degree score between each target resource and the target object based on the weight, and sorting the multiple target resources according to the matching degree score; constructing a resource push list according to the arrangement order of the multiple target resources, and pushing the resource push list to the target object, wherein the resource push list contains multiple target resources sorted according to the arrangement order.
[0076] Understandably, after identifying a set of course resources that are potentially relevant to the target audience (such as employees), the system does not directly output all candidate courses as recommendations. Instead, it further analyzes the semantic connection paths established between the target audience and each course in the graph structure and the strength of their associations. By quantifying the weights of these paths, the system calculates the matching degree of each course and sorts them according to their matching degree, ultimately generating a personalized push list with priority order.
[0077] To better understand the process of the above resource push method, the flow of the above resource push method will be described below in conjunction with optional embodiments, but this is not intended to limit the technical solution of the embodiments of this application.
[0078] In corporate training digital systems, two core data objects are typically included: learners (employees) and courses. To achieve personalized learning, suitable courses need to be matched and pushed to learners. This relies on a deep understanding and matching of the attributes of these two types of objects. Learner profiles include basic attributes (department, job level), career path attributes (age group), length of service (n years), skill attributes (skills acquired, proficiency), job attributes (job responsibilities, competency model), and development intentions (personal development plan). Course profiles include course metadata (name, description), skill tags (skills to be developed, prerequisites), target audience (target position, suggested job level), and difficulty level.
[0079] Currently, the relevant technical solutions are course recommendation systems based on relational database storage and manual rule engines. This solution typically includes the following components: A data storage layer uses relational databases such as MySQL (one database system) or Oracle (another database system). Separate tables are created for "Student Information," "Course Information," and possibly "Tag Association Tables." Student and course tags are usually stored as multi-valued fields or association tables. A rule configuration layer provides a management interface or configuration file, allowing administrators (usually with technical backgrounds) to write matching rules. Rules are represented as SQL statement fragments or "condition-action" pairs (IF-THEN statements). The rule execution engine parses the rules, connects to the database at a specified time or when an event is triggered, executes the corresponding query, and obtains the matching results. Finally, the push execution layer pushes the matching results (a list of student identifiers (IDs) and course IDs) to users via a message interface.
[0080] Its workflow generally consists of three steps: First, the administrator defines the rules, analyzes business needs, and manually configures the rules. For example, it specifies that if the position is product manager and the level is intermediate or above, all users need to learn courses with tags including digitalization and artificial intelligence (AI) at a beginner level or above. Second, the system performs regular data queries, executing SQL queries generated according to the corresponding rules for each student or target student group. Finally, after the results are generated and pushed, the query results are deduplicated and sorted (possibly based on simple rules such as publication time), a push list is generated, and the results are sent.
[0081] However, course recommendation systems based on relational databases and manual rule configuration in related technologies suffer from the following problems: High technical barriers and low efficiency in rule configuration and maintenance: Solutions in these technologies require technicians to manually write complex Structured Query Language (SQL) queries or configure logical rules to define the matching relationship between students and courses. As the number of business dimensions and tags increases, rule combinations explode, resulting in a huge workload for manual configuration, testing, and maintenance, leading to low efficiency. Poor system scalability and flexibility: The technical architecture (relational database table structure) of solutions in these technologies is tightly coupled with business logic (hard-coded rules). When business requirements change (such as adding student attributes or course tags), the database schema and application code must be modified, resulting in long development cycles, inability to quickly respond to business changes, and poor system scalability. Low matching query efficiency, making it difficult to support real-time and accurate recommendations: As the amount of student and course data grows, the performance of SQL queries based on multi-table joins (JOIN) and complex conditions (WHERE) drops sharply. When performing deep, multi-condition matching, the response latency is high, making it difficult to achieve real-time or near real-time personalized course recommendations. Insufficient precision in push notifications hinders the uncovering of deep semantic connections: Existing rules based on precise tag matching cannot effectively identify and utilize the potential, non-linear semantic connections between learners and courses (e.g., connections implicit in skill advancement paths and job competency models). This results in push notifications remaining at a superficial level of matching, with limited personalization and accuracy.
[0082] To address the aforementioned issues, this application proposes an optional embodiment of a course recommendation method and system based on a Semantic-enhanced Programmable Graph (SPG) knowledge graph. This method treats volatile business data (such as multiple tags for students and courses) and the business rules themselves as programmable data for unified modeling and management, thereby achieving decoupling between core architecture stability and flexible business expansion.
[0083] Figure 3 This is an architecture diagram of a course recommendation system based on the SPG knowledge graph according to an optional embodiment of this application, such as... Figure 3 As shown:
[0084] The course recommendation system based on SPG knowledge graph includes: AI interaction and rule building layer, SPG knowledge graph storage and computing layer and application service layer;
[0085] The AI interaction and rule building layer includes: a natural language interface for defining new rules / label types; a visual rule / ontology editor for visually defining entities, relationships, attributes, and constraints; the AI interaction and rule building layer is also used for rule / ontology version management; the application service layer is used to store student profiles, course matching, and execution push; the SPG knowledge graph storage and computation layer includes: a unified graph query and computation engine (used to interpret and execute dynamic ontologies, data, and rules in the graph) and three interconnected sub-layers: the dynamic ontology layer, the instance data layer, and the programmable rule layer. Specifically: the dynamic ontology layer (i.e., the ontology layer) includes: entity type definitions (e.g., job label classes), relationship type definitions (e.g., possessed skills), and attribute definitions (types, constraints); the instance data layer includes: student entities (with dynamic attributes), course entities (with dynamic attributes), skill / job entities, and their relationships; the programmable rule layer includes: trigger condition entities (logical expressions), computation function entities (algorithm logic), and execution flow entities (flowcharts).
[0086] In this layer, the dynamic ontology no longer uses a fixed, predefined database schema. All data model definitions (such as new tag types like "Innovative Thinking" and new relationships like "Area of Interest") are stored and managed as nodes and edges in the graph. This means that adding new tag types or relationship types simply adds a new "type definition" node to this layer, without modifying the database table structure or the application's class definitions. Stored entities include metadata nodes such as "entity type definitions" (e.g., EntityType: Employee, EntityType: Course), "relation type definitions" (e.g., RelationType: hasSkill, RelationType: targetAudience), and "attribute definitions" (e.g., Property: proficiencyLevel, Property: difficulty). These nodes form the ontology network through edges such as isTypeOf (belongs to type) and hasProperty (has attribute).
[0087] The instance data layer stores specific entities such as students, courses, and skills, as well as the relationships between them. The attributes of these entities can reference definitions in the dynamic ontology layer, thus enabling dynamic attribute expansion. For example, a student entity can have an attribute called "Innovative Thinking Level" defined according to the dynamic ontology. The stored entities are concrete "instances," such as a specific student (EmployeeInstance: Zhang San) or a specific course (CourseInstance: Introduction to AI). They are associated with the corresponding type definition nodes in the dynamic ontology layer through instanceOf edges and possess specific attribute values.
[0088] Programmable Rule Layer: This layer models business rules as special entities within a graph. Rules can reference entities, attributes, and relationships defined in the dynamic ontology layer, thus decoupling rules from the data model. Adding a new rule involves adding a new rule entity. The stored entity is the "Rule Definition" (Rule: Rule_ProductManager_Training, product manager training rule). This entity contains structured fields such as triggerCondition (triggering condition, such as Employee.position (employee position) == "Product Manager") and executionLogic (execution logic, such as a reference to a graph traversal pattern).
[0089] The data flow between each layer is as follows:
[0090] Injection Stream (AI Interaction and Rule Building Layer - Core Layer (i.e., Dynamic Ontology Layer, Instance Data Layer, and Programmable Rule Layer)): Information configured by business users in the AI Interaction and Rule Building Layer using natural language or forms is converted into structured data entities corresponding to the above three layers and written to the SPG core layer through the "Dynamic Injection" interface. For example, adding a "Soft Skill" tag creates a new EntityType:SoftSkill node in the Dynamic Ontology Layer.
[0091] Query Flow (Application Service Layer - Core Layer): After receiving a push request, the Application Service Layer initiates a query to the Unified Graph Query and Computation Engine. The data flow of the Unified Graph Query and Computation Engine is as follows: Load the relevant rule entities from the programmable rule layer; parse the conditions in the rules and convert them into one or more "graph patterns"; perform matching and traversal of the graph pattern in the full graph that integrates dynamic ontology and instance data; and return the matched set of course instance nodes as the result to the application layer.
[0092] In summary, the unified graph query and computation engine can understand and manipulate the three sub-layers contained in the core layer. The AI interaction and rule building layer, as an extensible configuration entry point, allows users to dynamically modify the ontology and rules, and these modifications are "dynamically injected" into the core SPG layer. The application service layer interacts with the core layer through stable interfaces, unaffected by changes in the underlying data and rules.
[0093] Figure 4 This is an example diagram illustrating dynamic tagging and rule expansion according to an optional embodiment of this application, such as... Figure 4 As shown:
[0094] The student instance (student instance type) is: Product Manager\n, Attributes: Job Level = Junior, Tenure = 0.5 years; Based on trigger conditions, select rule instances (actual entity types), for example: Rule Instance: Novice Product Manager Rules\n, Conditions: Job = Product Manager AND Tenure < 1 year\n, Action: Recommend Corporate Culture Courses; and / or; Rule Instance: Intermediate Product Manager Rules\n, Conditions: Job ∈ Product Manager AND Job Level ∈ [Intermediate, Senior]\n, Action: Recommend Digital / AI Courses. Execute the corresponding action based on the rule instance, i.e., select the course instance corresponding to the course entity type. For example: Course Instance: Introduction to Corporate Culture\n, Attributes: Category = Corporate Culture; and / or; Course Instance: Digital Fundamentals\n, Attributes: Category = Digital; and / or; Course Instance: AI Application Practice\n, Attributes: Category = AI.
[0095] The specific steps of dynamic tagging and rule expansion include:
[0096] Ontology Confirmation and Data Association: The system pre-defines common business ontologies, such as "Job Title," "Job Level," "Start Date," and "Course Type." At the instance data layer, the student "Wang Wu" entity is already associated with the "Product Manager" job title node and includes attributes such as "Job Level" (e.g., intermediate) and "Start Date." The course entity has also been tagged with type labels such as "Corporate Culture," "Digitalization," and "AI."
[0097] Dynamic rule creation: Business personnel interact with the AI-powered rule-building layer to describe business rules in natural language: "For trainees with the position of 'Product Manager,' if they have been with the company for less than one year, push 'Corporate Culture' courses; if their position is 'Intermediate' or higher, push 'Digitalization' and 'AI' courses." The system decomposes this requirement and transforms it into executable logic, creating corresponding rule entities in the programmable rule layer (e.g., rule - Product Manager course push). This rule entity precisely defines: Trigger condition: Trainee - Position == "Product Manager". Branch logic: Condition 1: Current date - Trainee's start date < 365 days → Action: Match course; Type == "Corporate Culture". Condition 2: Trainee's position ≥ "Intermediate" - Action: Match course type IN ["Digitalization", "AI"].
[0098] Dynamic rule binding and activation: Newly created rule entities are dynamically bound to attributes defined in the dynamic ontology layer (such as "position", "job level", "date of employment", "course type") and specific values in the instance data layer (such as "product manager", "P6", "corporate culture"). This process does not require modification of the database structure or application code.
[0099] The new rule is executed in real time: When a push task is triggered, the unified graph query and calculation engine loads and interprets the execution rule "Product Manager Course Push". The engine quickly traverses the knowledge graph, identifies all student nodes that satisfy "Job Title = Product Manager", and then calculates different branch conditions based on each student's specific attributes (years of service, job level), ultimately matching the corresponding course. The entire matching and calculation process is completed in a single graph traversal, and the new rule takes effect immediately after creation without requiring a system restart.
[0100] In an alternative embodiment regarding the expansion of a dynamic skills system, it is assumed that the company's existing skills tags are only "programming languages" and "databases", and now it needs to add "soft skills" categories (such as "communication skills" and "project management").
[0101] First, the ontology is dynamically expanded: Administrators use the visual editor in the AI interaction layer to add a new entity type, SkillCategory - SoftSkill, to the dynamic ontology layer, and define subtypes for it: SoftSkill - Communication Skills and SoftSkill - Project Management. Simultaneously, the skill-possession relationship between "Students" and "Skills" is expanded so that they can be associated with the new skill category. For example, a new node, EntityType: SkillCategory_SoftSkill, is added to the dynamic ontology layer, and child nodes EntityType: SoftSkill_Communication and EntityType: SoftSkill_ProjectManagement are added to it. Furthermore, in the relationship type definition, it is ensured that the constraint RelationType: possessesSkill allows connections from Employee to the new skill type node.
[0102] Secondly, dynamic data injection is performed: through an Extract, Transform, Load (ETL) process or manual input, employee soft skills evaluation data is transformed into facts within the graph. For example, in the instance data layer, the node for trainee "Li Si" (EmployeeInstance: Li Si) is located, and an edge of type possessesSkill is created, pointing to a new instance node SoftSkillInstance: Project Management. This edge contains the attribute {"proficiency": 0.7}. Simultaneously, external data sources (such as HR systems, talent development systems, etc.) need to be read from the management backend, and the data is converted into a four-tuple format of "(subject, relation, object, attribute)" and written to the instance data layer through the data injection interface.
[0103] Then, rules are dynamically created: A business department wants to recommend relevant courses to employees whose "project management ability is below 0.5 and whose job level is P7 or higher." Business personnel describe this requirement in the AI interactive interface, and the system automatically creates a corresponding rule entity in the programmable rule layer. Its conditional expression references the dynamically added soft skill - project management entity and proficiency attribute. For example, creating a new node Rule: Rule_SoftSkill_Training (soft skills training rule), whose triggerCondition field value is a complex logical expression, such as: Employee.possessesSkill[?(@.target==SoftSkill_ProjectManagement&&@.proficiency<0.5)]&&Employee.level>=“P7” (The employee possesses the soft skill instance of "project management" with a proficiency below 0.5, and the employee's job level is not lower than P7).
[0104] Finally, execution proceeds: When a push task is triggered, the unified graph query and calculation engine seamlessly identifies and processes these newly added entity types, attributes, and rules to complete the recommendation calculation. Throughout the process, the application service layer code does not need to be aware of the newly added dimension of "soft skills." The overall data flow is as follows: When a push task is triggered, the engine loads the Rule: Rule_SoftSkill_Training, and parses the conditions into a graph pattern: It finds an Employee node that is connected to a SoftSkill_ProjectManagement node through a possibleSkill edge, and the probability attribute of this edge is <0.5. At the same time, the level attribute of this Employee node is "P7". The pattern matching is performed in the graph to find all student nodes that meet the conditions. According to the "action" part defined in the rule (e.g., recommend related courses), the graph traversal is further expanded to find the relevant courses and return the results.
[0105] Figure 5 This is a schematic diagram (a) of the intelligent recommendation process according to an optional embodiment of this application, such as... Figure 5 As shown: It begins with the administrator inputting specific business scenarios and descriptions, followed by the AI automatically creating a structural framework for metadata models such as students, student tags, and courses. Based on this, the administrator sets constraint types and inputs natural language rules, which the system uses to construct model relationships and verify the accuracy of the rule tag input. The AI further creates rule nodes, then injects actual data to generate instance relationships. Finally, through relationship deletion and correction adjustments, the model is ensured to be complete and reliable, ultimately outputting the expected configuration result.
[0106] Figure 6 This is a schematic diagram (II) of the intelligent recommendation process according to an optional embodiment of this application, as shown below. Figure 6 As shown: After a student logs into the system, the system automatically retrieves the user's basic information. It then queries the student instance node and iterates through matching internal tag nodes to filter out students who meet the criteria. Next, the system iterates through and calculates the matching constraint nodes to determine the range of courses the student can access. Finally, the system generates personalized push content based on the calculations and returns the results, completing the entire push process.
[0107] The overall data flow for intelligent recommendations is as follows:
[0108] Step 1: First, a triggering event (such as a scheduled task or student login) generates a request containing the target student ID or target group conditions.
[0109] Step 2: Identity Recognition and Data Loading. The application service layer forwards the request to the unified graph query and calculation engine. The engine first locates the corresponding EmployeeInstance node based on the student ID, and then loads all attributes and relationships (i.e., its first-degree neighbor nodes) related to that student node at once to build a local subgraph view.
[0110] Step 3: Rule Matching and Graph Traversal. The engine checks all active rule entities in parallel. For each rule, the student local subgraph loaded in the previous step is used to match the rule's triggerCondition graph pattern. If a match is found, the rule is activated.
[0111] Step 4: For execution and result aggregation, for each activated rule, the engine performs a graph traversal defined in its executionLogic. For example, starting from the current student node, it searches for the skill nodes that need to be mastered along the requiresSkill relationship, and then searches backward along the teachersSkill relationship to find the course nodes that teach these skills. This is a multi-hop, conditionally constrained graph traversal process starting from the student node.
[0112] Step 5: Result Sorting and Output. All traversed course nodes are collected. The system may sort and deduplicate based on edge weights and attribute values (such as course popularity and matching score) in the graph.
[0113] Step 6: Generate a structured "recommendation results list", with each entry containing the course entity ID and matching criteria (such as which rule was triggered), and return it to the application service layer for push notifications.
[0114] In summary, the unified storage of metadata and data, where the SPG graph stores both "data describing the data" (metadata, i.e., ontology) and "the data itself" in the same way (nodes and edges), forms the basis for dynamic expansion. The separation of rule conditions and logic: the "triggering conditions" in the rule entity are parsable logical expression strings or structured query templates, with their variables bound to the dynamic ontology. The "computation logic" points to reusable function entities or custom computation flows. This separation allows for flexible changes in conditions while maintaining relative stability in the computation logic. Graph pattern-based rule matching: the essence of the recommendation inference engine executing rules is to find subgraphs in the graph that satisfy a specific graph pattern. Dynamically added tags and relationships only expand the types of matching graph patterns and do not change the working mechanism of the matching engine.
[0115] The optional embodiments of this application employ a three-layer decoupled SPG knowledge graph model consisting of a "dynamic ontology layer," an "instance data layer," and a "programmable rule layer." This model stores the volatile business data model (multiple types of tags) and the business rules themselves as graph data, decoupling them from the core engine. This allows for unlimited business expansion while maintaining a stable core system architecture. It supports dynamic ontology injection and a rule execution engine that takes effect in real-time. The system allows for the dynamic creation and modification of entity types, relationship types, and their attribute definitions (ontologies) through a configuration interface, and allows for the dynamic creation of rules based on new ontology. The recommendation inference engine can instantly interpret and execute these newly injected ontology and rules without restarting or redeploying. It provides a unified representation and interaction method for multi-type tag and rule expansion. Various tags are abstracted into a graph pattern of "entity type-relationship-attribute," and various rule constraints are abstracted into a graph pattern of "conditional expression-computation logic-execution flow." A unified extended interaction interface is provided through natural language or a visual interface, shielding the complexity of the underlying technology and reducing the cost of expansion and maintenance. It also features a hybrid recommendation inference mechanism based on a dynamic graph pattern. The recommendation process involves the engine matching, traversing, and calculating across the entire graph, which includes dynamic ontologies and instance data, based on dynamic graph patterns defined by rule entities. This mechanism simultaneously satisfies the requirements for high-precision semantic association mining and high-efficiency dynamic querying.
[0116] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods of the various embodiments of this application.
[0117] Figure 7 This is a structural block diagram of a resource push device according to an embodiment of this application; as shown below. Figure 7 As shown, it includes:
[0118] The first determining module 72 is used to determine the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, and to determine the target node connected to the first instance node through the target edge, wherein the target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or to connect multiple entity instance nodes in the instance data layer, wherein the entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node;
[0119] Construction module 74 is used to construct a local subgraph corresponding to the target object based on the first instance node and the target node;
[0120] The second determining module 76 is used to determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer based on the triggering conditions of each rule entity, and to determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity, wherein the target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node;
[0121] The third determining module 78 is used to determine the target resource to be pushed to the target object based on the target resource instance node.
[0122] According to the above apparatus, a first instance node corresponding to the target object is determined in the instance data layer of the target knowledge graph, and a target node connected to the first instance node through a target edge is determined. A local subgraph corresponding to the target object is constructed based on the first instance node and the target node. Then, based on the triggering conditions of each rule entity, a target rule entity matching the local subgraph is determined from multiple rule entities in the rule layer of the target knowledge graph. A target resource instance node is determined in the instance data layer based on the execution logic of the target rule entity. The target resource to be pushed to the target object is determined based on the target resource instance node. In other words, this application constructs a target knowledge graph that includes at least an instance data layer and a rule layer. After determining the first instance node corresponding to the target object in the instance data layer, a target node connected to the first instance node can be determined. The target node can be a resource entity instance node, an object entity instance node, or other entity instance node. Furthermore, the local subgraph constructed based on the first instance node and the target node can quickly match target rule entities in the rule layer. Then, based on the execution logic of the target rule entity, a target resource instance node is determined in the instance data layer. The target resource (e.g., a course) is determined based on the target resource instance node. This application addresses the problem of low push accuracy caused by the inability of tag-based precise course matching methods in related technologies to effectively identify and utilize the non-linear relationship between students and courses. Furthermore, by constructing a local subgraph in the target knowledge graph, matching target rule entities based on the local subgraph, and determining target resources based on the execution logic of the target rule entities, this technical solution can identify the non-linear relationship between students and courses (e.g., student-resource-course) and improve push accuracy.
[0123] In an exemplary embodiment, the first determining module 72 is further configured to obtain first business data corresponding to each ontology contained in the ontology layer from multiple data sources, and convert the first business data into a target format to obtain second business data, wherein the target knowledge graph includes: the ontology layer, wherein the multiple ontology in the ontology layer includes at least one of the following: entity type nodes and attribute type nodes; match the second business data with each ontology to determine the graph semantic category corresponding to each second business data, and construct an element mapping relationship table based on the first matching result of the second business data and each ontology, wherein the element mapping relationship table is used to indicate the mapping relationship between each second business data and each ontology; create entity instance nodes with mapping relationships to each entity type and / or attribute value nodes with mapping relationships to each attribute type in the instance data layer according to the element mapping relationship table; write the second business data into the entity instance nodes or the attribute value nodes based on the element mapping relationship table; and construct an instance graph contained in the instance data layer according to the entity instance nodes and / or attribute value nodes containing the second business data.
[0124] In an exemplary embodiment, the first determining module 72 is further configured to, upon receiving a business request sent by any object, extract keywords from the business request according to a semantic segmentation model; parse each business request according to the keywords in the business request to determine the triggering condition and execution logic corresponding to each business request; construct a first rule entity corresponding to each business request according to the triggering condition and execution logic corresponding to each business request; and construct multiple rule entities in the rule layer according to multiple first rule entities.
[0125] In an exemplary embodiment, the first determining module 72 is further configured to match keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, wherein the multiple ontologies in the ontology layer include at least one of the following: entity type nodes and attribute type nodes; if it is determined that the keywords in each first rule entity match any ontology, establishing a first association relationship between each first rule entity and the ontology that matches each first rule entity; and determining a second instance node and / or a first attribute value node that matches each first rule entity in the instance data layer, and establishing a second association relationship between each first rule entity and the data in the second instance node, and / or between each rule entity and the data in the first attribute value node; and determining each first rule entity after establishing the first association relationship and the second association relationship as a rule entity in the rule layer.
[0126] In an exemplary embodiment, the first determining module 72 is further configured to, when determining that the keywords in the second rule entity do not match any of the ontologies in the ontology layer, construct a target ontology in the ontology layer based on the keywords in the second rule entity, and construct a third instance node or a second attribute value node corresponding to the target ontology in the instance data layer, wherein the plurality of first rule entities include: the second rule entity; establishing a third association relationship between the second rule entity and the target ontology, and establishing a fourth association relationship between the second rule entity and the data in the third instance node or the second rule entity and the data in the second attribute value node; and determining the second rule entity after establishing the third association relationship and the fourth association relationship as the rule entity in the rule layer.
[0127] In an exemplary embodiment, the third determining module 78 is further configured to determine the candidate resources corresponding to each target resource instance node; deduplicate multiple candidate resources; and determine the deduplicated candidate resources as the target resources.
[0128] In an exemplary embodiment, the third determining module 78 is further configured to determine the association edges between the target object and the target resource instance nodes corresponding to each target resource, and obtain the weight corresponding to each association edge; calculate the matching degree score between each target resource and the target object according to the weight, and sort the multiple target resources according to the matching degree score; construct a resource push list according to the arrangement order of the multiple target resources, and push the resource push list to the target object, wherein the resource push list contains multiple target resources sorted according to the arrangement order.
[0129] Embodiments of this application also provide a storage medium including a stored program, wherein the program executes any of the methods described above when it is run.
[0130] Optionally, in this embodiment, the storage medium may be configured to store program code for performing the following steps:
[0131] S1, in the instance data layer of the target knowledge graph, determine the first instance node corresponding to the target object, and determine the target node connected to the first instance node through the target edge, wherein the target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or, to connect multiple entity instance nodes in the instance data layer, wherein the entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node;
[0132] S2, construct a local subgraph corresponding to the target object based on the first instance node and the target node;
[0133] S3, based on the triggering conditions of each rule entity, determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer, and determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node.
[0134] S4, determine the target resource to be pushed to the target object based on the target resource instance node.
[0135] Embodiments of this application also provide an electronic device including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.
[0136] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.
[0137] Optionally, in this embodiment, the processor can be configured to perform the following steps via a computer program:
[0138] S1, in the instance data layer of the target knowledge graph, determine the first instance node corresponding to the target object, and determine the target node connected to the first instance node through the target edge, wherein the target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or, to connect multiple entity instance nodes in the instance data layer, wherein the entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node;
[0139] S2, construct a local subgraph corresponding to the target object based on the first instance node and the target node;
[0140] S3, based on the triggering conditions of each rule entity, determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer, and determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node.
[0141] S4, determine the target resource to be pushed to the target object based on the target resource instance node.
[0142] Embodiments of this application also provide a computer program product, including a computer program that is executed by a processor through the steps of any of the above method embodiments.
[0143] Optionally, in this embodiment, the above-mentioned computer program product can be executed by a processor using the following steps:
[0144] S1, in the instance data layer of the target knowledge graph, determine the first instance node corresponding to the target object, and determine the target node connected to the first instance node through the target edge, wherein the target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or, to connect multiple entity instance nodes in the instance data layer, wherein the entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node;
[0145] S2, construct a local subgraph corresponding to the target object based on the first instance node and the target node;
[0146] S3, based on the triggering conditions of each rule entity, determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer, and determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node.
[0147] S4, determine the target resource to be pushed to the target object based on the target resource instance node.
[0148] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0149] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated here.
[0150] Obviously, those skilled in the art should understand that the modules or steps of this application described above can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. Optionally, they can be implemented using computer-executable program code, thereby storing them in a storage device for execution by a computing device. In some cases, the steps shown or described can be performed in a different order than those presented here, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, this application is not limited to any particular combination of hardware and software.
[0151] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A resource push method, characterized in that, include: In the instance data layer of the target knowledge graph, a first instance node corresponding to the target object is determined, and a target node connected to the first instance node through a target edge is determined. The target edge is used to connect entity instance nodes and attribute value nodes in the instance data layer, and / or to connect multiple entity instance nodes in the instance data layer. The entity instance nodes include at least one of the following: object entity instance nodes, resource entity instance nodes, and other entity instance nodes. Construct a local subgraph corresponding to the target object based on the first instance node and the target node; Based on the triggering conditions of each rule entity, a target rule entity matching the local subgraph is determined from multiple rule entities in the rule layer, and a target resource instance node is determined in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node. The target resource to be pushed to the target object is determined based on the target resource instance node.
2. The resource push method according to claim 1, characterized in that, Before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, the method includes: First business data corresponding to each ontology contained in the ontology layer is obtained from multiple data sources, and the first business data is converted into a target format to obtain second business data. The target knowledge graph includes the ontology layer, and the multiple ontology in the ontology layer includes at least one of the following: entity type node and attribute type node. The second business data is matched with each ontology to determine the graph semantic category corresponding to each second business data, and an element mapping relationship table is constructed based on the first matching result of the second business data and each ontology, wherein the element mapping relationship table is used to indicate the mapping relationship between each second business data and each ontology; Based on the element mapping relationship table, entity instance nodes with mapping relationships to each entity type and / or attribute value nodes with mapping relationships to each attribute type are created in the instance data layer. The second business data is written to the entity instance node or the attribute value node based on the element mapping relationship table; The instance graph contained in the instance data layer is constructed based on the entity instance nodes and / or attribute value nodes that contain the second business data.
3. The resource push method according to claim 1, characterized in that, Before determining the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, the method includes: Upon receiving a business request from any object, extract keywords from the business request based on a semantic segmentation model; Each business requirement is parsed based on the keywords in the business requirements to determine the triggering conditions and execution logic corresponding to each business requirement; Construct a first rule entity corresponding to each business requirement based on the triggering conditions and execution logic corresponding to each business requirement; Multiple rule entities are constructed in the rule layer based on multiple first rule entities.
4. The resource push method according to claim 3, characterized in that, Multiple rule entities are constructed in the rule layer based on multiple first rule entities, including: The keywords in each first rule entity are matched with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, wherein the multiple ontologies in the ontology layer include at least one of the following: entity type nodes and attribute type nodes; If it is determined that the keywords in each of the first rule entities match any of the ontology, a first association relationship is established between each of the first rule entities and the ontology that matches each of the first rule entities; and, In the instance data layer, a second instance node and / or a first attribute value node that matches each first rule entity is determined, and a second association relationship is established between each first rule entity and the data in the second instance node, and / or between each rule entity and the data in the first attribute value node; Each first rule entity established after establishing the first association relationship and the second association relationship is determined as a rule entity in the rule layer.
5. The resource push method according to claim 4, characterized in that, After matching the keywords in each first rule entity with multiple ontologies in the ontology layer to determine whether the keywords in each first rule entity match any ontology in the ontology layer, the method further includes: If it is determined that the keywords in the second rule entity do not match any of the ontologies in the ontology layer, a target ontology is constructed in the ontology layer based on the keywords in the second rule entity, and a third instance node or a second attribute value node corresponding to the target ontology is constructed in the instance data layer, wherein the plurality of first rule entities include: the second rule entity; Establish a third association between the second rule entity and the target ontology, and establish a fourth association between the second rule entity and the data in the third instance node or between the second rule entity and the data in the second attribute value node; The second rule entity, after establishing the third and fourth association relationships, is determined as the rule entity in the rule layer.
6. The resource push method according to claim 1, characterized in that, Based on the target resource instance node, the target resource to be pushed to the target object is determined, including: Determine the candidate resources corresponding to each target resource instance node; Multiple candidate resources are deduplicated, and the deduplicated candidate resources are determined as the target resource.
7. The resource push method according to claim 1, characterized in that, After determining the target resource to be pushed to the target object based on the target resource instance node, the method further includes: Determine the associated edges between the target object and the target resource instance node corresponding to each target resource, and obtain the weight corresponding to each associated edge; Calculate the matching score between each target resource and the target object based on the weight, and sort the multiple target resources according to the matching score; A resource push list is constructed based on the arrangement order of the multiple target resources, and the resource push list is pushed to the target object. The resource push list contains multiple target resources sorted according to the arrangement order.
8. A resource delivery device, characterized in that, include: The first determining module is used to determine the first instance node corresponding to the target object in the instance data layer of the target knowledge graph, and to determine the target node connected to the first instance node through the target edge, wherein the target edge is used to connect the entity instance node and the attribute value node in the instance data layer, and / or, to connect multiple entity instance nodes in the instance data layer, wherein the entity instance node includes at least one of the following: object entity instance node, resource entity instance node, and other entity instance node; The construction module is used to construct a local subgraph corresponding to the target object based on the first instance node and the target node; The second determining module is used to determine the target rule entity that matches the local subgraph among multiple rule entities in the rule layer based on the triggering conditions of each rule entity, and to determine the target resource instance node in the instance data layer according to the execution logic of the target rule entity. The target knowledge graph includes: the rule layer, and the entity instance node includes: the target resource instance node. The third determining module is used to determine the target resource to be pushed to the target object based on the target resource instance node.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program, when executed, performs the method described in any one of claims 1 to 7.
10. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to execute the method described in any one of claims 1 to 7 through the computer program.