A knowledge graph analysis method and device based on transportation scheduling, and a storage medium

CN122733828BActive Publication Date: 2026-11-03NAT UNIV OF DEFENSE TECH
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202511764380.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-11-27
Publication Date
2026-11-03
Estimated Expiration
2045-11-27

AI Technical Summary

Technical Problem

In existing technologies, centralized knowledge graph construction and management methods suffer from poor scalability, difficulty in maintaining consistency, fragmented processing flow, and limited query efficiency in large-scale heterogeneous data scenarios, making it difficult to meet the needs of high-concurrency access and large-scale data synchronization processing.

Method used

A distributed architecture is adopted to build a transportation scheduling knowledge model, define ontology and relationships, configure attributes, establish a field mapping table, construct a distributed graph, perform entity indexing and path analysis, and realize unified scheduling and analysis of the graph.

Benefits of technology

It achieves the unification of knowledge modeling and data organization, improves the schedulability of graph construction tasks and the efficiency of distributed data entry, supports deep path query and analysis, and improves transportation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122733828B_ABST
    Figure CN122733828B_ABST
Patent Text Reader

Abstract

The application discloses a kind of knowledge graph analysis methods, equipment and storage medium based on transportation scheduling, it is related to knowledge construction, management and data analysis field, the method includes: constructing transportation scheduling knowledge model, setting field identification, defining ontology and relationship and attribute, form hierarchical model template;Create dataset, extract field from structured data source, complete cleaning and format uniformity, generate corresponding dataset;Establish the mapping relationship of field and attribute and generate index;Configuration graph construction task, organize structured data as graph node and edge, write into distributed graph library;Based on graph data, execute entity index, relationship path and topology analysis.Through constructing uniform transportation scheduling knowledge model template, configuration schedulable graph construction task and distributed warehousing mechanism, integrate the path query and relationship analysis capability of graph, realize the fusion of knowledge and data, graph construction efficient distributed execution and depth analysis support of graph content.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of knowledge construction, management, and data analysis, and specifically to a knowledge graph analysis method, device, and storage medium based on transportation scheduling. Background Technology

[0002] Knowledge storage and analysis technologies are crucial supporting tools for complex information modeling, semantic computation, and intelligent reasoning, and are widely used in fields such as intelligent question answering, recommendation systems, data governance, and industrial knowledge management. Among existing technologies, knowledge graphs, as a typical knowledge representation method, organize ontology entities and relational chains through graphs to achieve semantic fusion and logical connection of structured and unstructured data.

[0003] However, in scenarios with large-scale heterogeneous data, traditional knowledge graph construction and management methods mostly rely on centralized computing architectures. These architectures have the following technical limitations when facing requirements such as high-concurrency access, large-scale data synchronization processing, and cross-source heterogeneous field alignment: First, it has poor scalability. The centralized architecture is limited by the computing and storage resources of a single node, making it difficult to meet the performance requirements of multi-task scheduling, large-scale field mapping, and synchronous storage of entity nodes during the graph construction process; Second, maintaining consistency is difficult. In the task of knowledge graph construction, there are complex mappings and associations between multiple relation edges and ontology nodes. In a centralized environment, consistency problems such as edge-node mapping conflicts and relation chain misalignment are prone to occur. Third, the processing flow is fragmented. In existing technologies, the definition of transportation scheduling knowledge models, data extraction, field mapping, graph construction and analysis are often handled by different modules, lacking a unified task collaboration mechanism, making it difficult to achieve efficient and controllable cross-stage data flow; Fourth, query efficiency is limited. Graph indexes under centralized storage cannot effectively support multi-hop path calculation, large-scale entity relationship chain filtering, and semantic analysis, which severely restricts graph analysis capabilities and response speed. Summary of the Invention

[0004] The technical problem to be solved by the present invention is to provide a knowledge graph analysis method, device and storage medium based on transportation scheduling, so as to solve the above-mentioned technical problem.

[0005] A knowledge graph analysis method based on transportation scheduling includes: Constructing a transportation scheduling knowledge model: Set knowledge domain identifiers, define ontology and relations, configure ontology attributes and relation attributes, and construct a transportation scheduling knowledge model. The ontology includes transportation vehicles, waybills, scheduling events, and infrastructure. The relations include carrier, traveling, connecting, and being delayed. Create model dataset: Based on the ontology and relations defined in the transportation scheduling knowledge model, extract data fields from the structured data source, clean and unify the format of the data fields to obtain processed fields, and store the processed fields into the datasets corresponding to the ontology and relations respectively to obtain ontology dataset and relation dataset, and use ontology dataset and relation dataset as model dataset. The processing fields in the model dataset are mapped to the attribute fields in the transportation scheduling knowledge model. An index mapping table between fields and attributes is established, and the consistency of the mapping relationship in the semantic dimension is verified. If the consistency is passed, the mapping binding relationship between the transportation scheduling knowledge model and the model dataset is established. The attribute fields are obtained through ontology attributes and relation attributes. Construct a graph data ingestion task to obtain a distributed graph: Configure the graph ingestion task based on the mapping and binding relationship, set task scheduling parameters and execution rules, transform the model dataset into graph node data and edge data in a distributed environment, write node data and edge data to the distributed graph library nodes, and obtain a distributed graph; Distributed graph query and analysis: Entity index, relationship index and path index are built on the distributed graph. The connection methods, jump paths and overall topological relationships between entities in the distributed graph are analyzed to obtain entity data, relationship data between entities and the shortest path between entities.

[0006] Specifically, knowledge graph analysis involves building entity indexes, relationship indexes, and path indexes on a distributed graph. This allows for analysis of the connection methods, jump paths, and overall topological relationships between entities within the distributed graph, thereby identifying the shortest paths between entities to improve transportation efficiency.

[0007] Optionally, constructing a transportation scheduling knowledge model includes: Configure knowledge domain identifiers: including setting the domain name, domain number, and domain description; Create an ontology: Configure the ontology name, ontology index, and attribute set; Establishing relationships: Configure relationship direction, ontology connection method, relationship index, and attribute set; A transportation scheduling knowledge model is constructed based on knowledge domain identifiers, ontology, and relationships.

[0008] Optionally, creating a model dataset includes: Determine the data source type, extract the data fields corresponding to the model fields, and obtain the extracted fields; The extracted fields are subjected to field format conversion, data redundancy removal and syntax standardization to obtain the processed fields; The processed fields are stored in the datasets corresponding to the ontology and the relation, respectively, to obtain the ontology dataset and the relation dataset. The ontology dataset and the relation dataset are then used as the model dataset.

[0009] Optionally, establishing a mapping relationship between the transportation scheduling knowledge model and the model dataset includes: Bind the ontology and relations of the transportation scheduling knowledge model to the corresponding model dataset; Create an index mapping table between the model dataset and the transportation scheduling knowledge model; The consistency of the mapping relationship is verified based on the index mapping table. If the consistency check passes, the mapping and binding relationship between the transportation scheduling knowledge model and the model dataset is established through the index mapping table and the model dataset.

[0010] Optional tasks for constructing and storing map data include: Based on the mapping and binding relationship of the model dataset and the transportation scheduling knowledge model, a graph construction task is established. The task number and storage strategy of the graph construction task are set, and the relevant information of the graph construction task is configured, including the task name, execution time and execution frequency. Based on the task number, data import strategy, and relevant information, execute the map data import task. The map data import task specifically includes: Based on the mapping and binding relationships of the model dataset, the data in the model dataset is converted into the graph format required for the knowledge graph, resulting in graph-converted data; The graph transformation data is constructed into a knowledge graph according to the transportation scheduling knowledge model, and node data and edge data are generated according to ontology attributes and relation attributes; Write node data and edge data into the distributed graph database nodes to complete the task of storing graph data.

[0011] The process of writing node data and edge data to the distributed graph nodes and obtaining the distributed graph before the following steps are included: Implementing a relation edge partitioning strategy and a cross-node consistency buffering mechanism in a distributed environment optimizes the sharded storage layout of graph data and ensures the integrity of the graph structure during concurrent writes across multiple nodes. Specifically, this includes: The relation edge partitioning strategy includes: obtaining the connectivity and connection tension of each relation edge based on the topological connectivity characteristics of the relation edges in the graph, and substituting the connectivity and connection tension into the edge partitioning function to obtain the evaluation value; The distribution priority of each relation edge is obtained through the evaluation value, the target storage shard of the relation edge is determined according to the distribution priority, and the relation edge shard identifier is generated. When the ontology nodes connected by the relation edge are located on different storage nodes, a cross-shard write strategy is formulated based on the relation edge shard identifier to ensure that the physical storage location of the edge data and its associated node is as close as possible to reduce cross-node access overhead. The cross-node consistency buffer mechanism includes: during the graph data import process, establishing a temporary buffer for relation edges involving cross-node writing, which is used to temporarily store the relation edge records to be written and their associated ontology node status information; Based on the aforementioned relational edge partitioning strategy and cross-node consistency buffering mechanism, the integrity of the graph structure is ensured during concurrent writes across multiple nodes.

[0012] Optionally, after converting the model dataset into graph node data and edge data in a distributed environment, and before writing the node data and edge data to the distributed graph node, the following steps are included: Before writing data to the distributed map library nodes, a preprocessing process is performed to ensure the structural standardization of the map data, the traceability of metadata, and the compliance of the writing operation. The preprocessing procedure includes: Graph write request parsing: Receive graph data write requests from the task scheduling module, perform syntax and semantic parsing on the write requests, extract the ontology, relations and fields contained therein, and use the ontology, relations and fields as the parsing results; Metadata index registration: Based on the parsing results, a metadata index is established for the graph nodes and relation edges to be written, recording the original data source fields, attribute mapping relationships and endpoint information of the associated edges of each node; Pre-write structural integrity verification: The graph data is verified for compliance based on a preset set of verification rules. The set of verification rules includes structural consistency conditions and topological rationality conditions. The structural consistency conditions include node attribute coverage, uniqueness of relation direction, and completeness of mapping field filling. The topological rationality conditions include edge endpoint existence, uniqueness of node identifier, and edge label repetition rate threshold.

[0013] Optionally, the distributed graph query and analysis includes: By constructing multi-dimensional indexes, performing restricted path searches, and generating comprehensive analysis indicators, deep semantic mining of entity relationships in the graph is achieved, specifically including: Build multi-dimensional indexes: respond to query requests from business systems, identify and determine the target entity pairs to be analyzed as the starting and ending points of path exploration; Based on the query request, relevant ontology indexes, relation indexes, and attribute information are extracted to limit the search space; Hop-limited path search: Based on the extracted relation index and attribute information, a hop-limited path search algorithm is adopted to traverse the graph within a preset maximum hop count range, generate all reachable paths connecting the start and end points of the target entity pair, and form a path set containing multiple semantic paths. Multi-dimensional graph analysis index generation: Perform graph analysis on the generated path set to obtain the connection method, connection path and overall graph topology.

[0014] A terminal device includes a memory and a processor. The memory stores a computer program that can run on the processor. When the processor loads and executes the computer program, it employs a knowledge graph analysis method based on transportation scheduling.

[0015] A computer-readable storage medium storing a computer program, which, when loaded and executed by a processor, employs a knowledge graph analysis method based on transportation scheduling.

[0016] The beneficial effects of this invention are: This invention provides a knowledge storage and analysis method and apparatus based on a distributed architecture. The method constructs a transportation scheduling knowledge model, sets knowledge domain identifiers, defines ontology and relationships, configures ontology attributes and relationship attributes, and constructs a model template with hierarchical logic. It creates a dataset, extracts fields from a structured data source based on the ontology and relationships defined in the transportation scheduling knowledge model, performs data cleaning and format unification, and stores the field results into datasets corresponding to the ontology and relationships. It establishes a mapping and binding relationship between the model and data, mapping field elements in the dataset to attributes in the transportation scheduling knowledge model, establishing an index mapping table between fields and attributes, and verifying the consistency of the mapping relationship in the semantic dimension. It constructs a graph data import task, configuring the graph import task based on the model and mapping fields, setting task scheduling parameters and execution rules, organizing structured data into graph nodes and edges in a distributed environment, and writing graph data to distributed graph nodes. It performs graph query and analysis, constructing entity indexes, relationship indexes, and path indexes based on the graph data, and analyzing the connection methods, jump paths, and overall topological relationships between entities in the graph. The beneficial effects include: 1. Achieve unity between knowledge modeling and data organization: By setting knowledge domain identifiers, defining ontology, relations and their attributes, and constructing a model template with hierarchical logic, knowledge and data are kept consistent, providing a unified basic framework for subsequent data binding, graph construction and semantic query; 2. Implement schedulable and distributed graph construction tasks: By configuring graph construction tasks and combining models and mapping relationships, structured data is converted into graph nodes and relational edges, and the data is stored in a distributed graph library environment, thereby improving task processing efficiency and the system capacity of graph construction. 3. Supports deep path query and analysis capabilities for graphs: During the graph analysis phase, by extracting ontology indexes, relation indexes, and paths, hop count limit queries and relation chain analysis are performed, supporting the rapid identification of connection methods and topology between entities in the graph.

[0017] 4. Entity data, relationship data between entities, and the shortest path between entities can quickly find available transportation vehicles and the shortest path from the available transportation vehicles to the destination, thereby improving transportation efficiency. Attached Figure Description

[0018] Figure 1 This is a flowchart of a knowledge graph analysis method based on transportation scheduling according to the present invention. Detailed Implementation

[0019] A knowledge graph analysis method based on transportation scheduling, such as Figure 1 As shown, the present invention includes: S1. Construct a transportation scheduling knowledge model: Set knowledge domain identifiers, define ontology and relations, configure ontology attributes and relation attributes, and construct a transportation scheduling knowledge model. The ontology includes transportation vehicles, waybills, scheduling events, and infrastructure. The relations include carrier, traveling, connecting, and being delayed.

[0020] For example, in the transportation of flood relief supplies, truck No. XX was transporting medical supplies from the Eastern Theater Command. It took the Shanghai-Nanjing Expressway and then the Nanjing-Luoyang Expressway, passing through stations A, B, and C. It was originally scheduled to arrive at 8 p.m., but due to a heavy rainstorm along the way, it finally arrived at the Central Theater Command at 10 p.m. and was stored in warehouse A.

[0021] Main components: transportation vehicle (truck No. XX), waybill (medical supplies), dispatch event (transportation of flood relief supplies), infrastructure (warehouse A).

[0022] Relationship: Carrying (truck No. XX carrying medical supplies), traveling on (truck No. XX traveling on the Shanghai-Nanjing Expressway and Nanjing-Luoyang Expressway), passing through (truck No. XX passing through stations A, B, and C), delayed (original plan delayed due to heavy rain).

[0023] Constructing a transportation scheduling knowledge model includes: Configure knowledge domain identifiers: including setting the domain name, domain number, and domain description; Create an ontology: Configure the ontology name, ontology index, and attribute set; Establishing relationships: Configure relationship direction, ontology connection method, relationship index, and attribute set; A transportation scheduling knowledge model is constructed based on knowledge domain identifiers, ontology, and relationships.

[0024] Specifically, configure the knowledge domain identifier, including setting the domain name, domain number, and domain description; specifically, create a domain transportation scheduling knowledge model, construct the attributes and relationships of the ontology based on the content of the business domain, construct the domain unique identifier DomainID and the transportation scheduling knowledge model unique identifier ModelID, and specify the unique display name of the ontology name.

[0025] Configure the ontology name, ontology index, and attribute set; define the ontology and attributes. An ontology refers to an entity concept in a knowledge graph. Based on the determined knowledge domain, list all relevant ontology and ontology-related attributes. The index vid and display name name need to be specified.

[0026] Configure the relationship direction, ontology connection method, relationship index and attribute set; define the relationship and attributes. The relationship represents the connection between the ontology. It is necessary to specify the type and direction of the relationship, as well as the relationship-related attributes. It is necessary to specify the vid of the index and the display name name.

[0027] The organization uses a unified model template for ontologies and relationships, assigning template numbers and domain numbers to construct a transportation scheduling knowledge model framework. The defined ontologies and relationships are organized logically to form a complete transportation scheduling knowledge model template. Subsequent data will be integrated and organized based on this template to ensure the clarity and rationality of the knowledge graph. Template IDs are assigned, along with corresponding domain IDs.

[0028] S2. Create model dataset: Based on the ontology and relations defined in the transportation scheduling knowledge model, extract data fields from the structured data source, clean and unify the data fields to obtain processed fields, and store the processed fields into datasets corresponding to the ontology and relations respectively to obtain ontology dataset and relation dataset, and use ontology dataset and relation dataset as model dataset.

[0029] Creating the model dataset includes: Determine the data source type, extract the data fields corresponding to the model fields, and obtain the extracted fields; The extracted fields are subjected to field format conversion, data redundancy removal and syntax standardization to obtain the processed fields; The processed fields are stored in the datasets corresponding to the ontology and the relation, respectively, to obtain the ontology dataset and the relation dataset. The ontology dataset and the relation dataset are then used as the model dataset.

[0030] Specifically, for the ontology and relations in the transportation scheduling knowledge model, it is determined which data sources can be obtained. The data sources can be structured data, such as tabular data in a database, or semi-structured data, such as data in XML or JSON format. Perform field format conversion, data redundancy removal, and syntax standardization; based on the determined data source, use ETL to collect data. The collected data may have problems such as inconsistent data formats, missing data, and data errors, which require preprocessing. For data with inconsistent formats, perform format conversion to make it conform to the unified format requirements; For missing data, fill in or delete it according to the actual situation; For erroneous data, correct or remove it; clean the data to remove duplicate data, noisy data, etc., and improve data quality. Based on the processing results, an ontology dataset table and a relation dataset table are generated. Dataset indexes are assigned, and the preprocessed data is stored in the corresponding datasets according to the categories of ontology and relation. The processed data fields are written into the ontology dataset table and the relation dataset table respectively, and a dataset index ID is assigned to each dataset for tracking and binding. Specifically, from the original data source, ETL tools are used to extract, clean, and transform the data to form the datasets required for graph construction. Dataset tables for each ontology are created, and a unique identifier btVid is created for each table. Data tables for each relation are created, and a unique identifier relationVid is created for each relation table.

[0031] S3. Map the processing fields in the model dataset to the attribute fields in the transportation scheduling knowledge model, establish an index mapping table between fields and attributes, verify the consistency of the mapping relationship in the semantic dimension, and if the consistency is passed, establish the mapping binding relationship between the transportation scheduling knowledge model and the model dataset. The attribute fields are obtained through ontology attributes and relation attributes. Establishing a mapping relationship between the transportation scheduling knowledge model and the model dataset includes: Bind the ontology and relations of the transportation scheduling knowledge model to the corresponding model dataset; Create an index mapping table between the model dataset and the transportation scheduling knowledge model; The consistency of the mapping relationship is verified based on the index mapping table. If the consistency check passes, the mapping and binding relationship between the transportation scheduling knowledge model and the model dataset is established through the index mapping table and the model dataset.

[0032] Specifically, after determining the correspondence between the dataset and the elements of the transportation scheduling knowledge model, a mapping relationship is established between them. The mapping relationship specifies that the fields in the dataset correspond to the attributes of the ontology or relation in the transportation scheduling knowledge model. Consistency checks are performed on the mapping relationships to verify the type matching and logical coupling between fields and attributes. After the mapping relationships are established, they are verified to ensure that the data can be correctly mapped from the dataset to the transportation scheduling knowledge model. The fields of the dataset tables of the created ontology and relations are mapped and bound one-to-one with the attributes of the ontology and relations in the transportation scheduling knowledge model.

[0033] S4. Construct a graph data import task to obtain a distributed graph: Configure the graph import task based on the mapping and binding relationship, set the task scheduling parameters and execution rules, transform the model dataset into graph node data and edge data in a distributed environment, and write the node data and edge data to the distributed graph library nodes to obtain a distributed graph.

[0034] The task of constructing and storing the map data includes: Based on the mapping and binding relationship of the model dataset and the transportation scheduling knowledge model, a graph construction task is established. The task number and storage strategy of the graph construction task are set, and the relevant information of the graph construction task is configured, including the task name, execution time and execution frequency. Based on the task number, data import strategy, and relevant information, execute the map data import task. The map data import task specifically includes: Based on the mapping and binding relationships of the model dataset, the data in the model dataset is converted into the graph format required for the knowledge graph, resulting in graph-converted data; The graph transformation data is constructed into a knowledge graph according to the transportation scheduling knowledge model, and node data and edge data are generated according to ontology attributes and relation attributes; Write node data and edge data into the distributed graph database nodes to complete the task of storing graph data.

[0035] Specifically, the transformed data is constructed into a knowledge graph according to the transportation scheduling knowledge model, and the node data and edge data are organized according to ontology and relation attributes; Graph data is written to distributed graph repository nodes, recording task status information and node distribution identifiers. Specifically, three storage nodes are deployed, each with three parts: a graph repository service, a node metadata service, and a storage service. The graph repository service constructs executable statements in the graph repository based on the `btVid` of the ontology table and its attributes. Similarly, the relation table constructs executable statements in the graph repository based on the `relationVid` and its attributes. The node metadata service records node status, data sharding, and other information. The storage service stores the formatted knowledge data and the constructed data to be imported into the graph; it also constructs relevant indexes based on the unique identifier `btVid` and unique display attribute `name` of the ontology table, and the unique identifier `relationVid` of the relation table for the data to be imported into the graph. Execution status and results are recorded in the node metadata.

[0036] The process of writing node data and edge data to the distributed graph nodes and obtaining the distributed graph before the following steps are included: Implementing a relation edge partitioning strategy and a cross-node consistency buffering mechanism in a distributed environment optimizes the sharded storage layout of graph data and ensures the integrity of the graph structure during concurrent writes across multiple nodes. Specifically, this includes: The relation edge partitioning strategy includes: obtaining the connectivity and connection tension of each relation edge based on the topological connectivity characteristics of the relation edges in the graph, and substituting the connectivity and connection tension into the edge partitioning function to obtain the evaluation value; The distribution priority of each relation edge is obtained through the evaluation value, the target storage shard of the relation edge is determined according to the distribution priority, and the relation edge shard identifier is generated. When the ontology nodes connected by the relation edge are located on different storage nodes, a cross-shard write strategy is formulated based on the relation edge shard identifier to ensure that the physical storage location of the edge data and its associated node is as close as possible to reduce cross-node access overhead. The cross-node consistency buffer mechanism includes: during the graph data import process, establishing a temporary buffer for relation edges involving cross-node writing, which is used to temporarily store the relation edge records to be written and their associated ontology node status information; Based on the aforementioned relational edge partitioning strategy and cross-node consistency buffering mechanism, the integrity of the graph structure is ensured during concurrent writes across multiple nodes.

[0037] Specifically, the map construction task has a piecewise control mechanism, which includes: Graph node distribution mapping allocates graph nodes in the construction task to target nodes in the distributed storage system based on the source location of the ontology and fields in the transportation scheduling knowledge model. This mapping process generates a graph node distribution index based on the node distribution weight factor and the data source path offset. Specifically, graph node distribution mapping is used to reasonably allocate graph nodes in the construction task to multiple target storage nodes in order to achieve load balancing and maximize path adjacency among nodes.

[0038] Distribution mapping is performed based on node distribution weight factors and data source path offsets; The node distribution weighting factor reflects the current storage load capacity or capacity fit of each target node; Data source path offset measures the physical or network path migration distance between the source data field and the target node, reflecting the cost across storage. For each node to be assigned, calculate its mapping priority value: ,in, This is a control coefficient used to balance capacity and path factors. For node distribution weight factors, Given the data source path offset, set the node with the highest priority value as the target storage node, generate the corresponding graph node distribution index table, and record the landing address and label of each node, where i is the node; The relation edge partitioning factor generation performs connectivity evaluation on the relation edges in the construction task, determines the cross-shard delivery strategy of the edge through the edge partitioning function, and generates the shard identifier corresponding to the edge node. Specifically, the relation edge in the graph connects two ontology nodes. In a distributed storage environment, there may be cross-node edge writing issues. In order to optimize the edge writing path and read / write efficiency, an edge partitioning function is introduced to control its sharding landing strategy. The connectivity coefficient and connection tension of each edge are calculated. The latter reflects the distance between connected nodes, access frequency, semantic heterogeneity, etc. The connectivity function is: Where A and B are adjustment coefficients. For path depth, For access frequency, i and j are different nodes; The connection tension function is: Where C and D are adjustment coefficients, The distance between nodes. Access frequency; The edge partitioning function is constructed as follows: ,in, and For adjustment coefficients, The connectivity coefficient, For connection tension; according to Sort by value, group edges and specify their corresponding target segments, and generate an edge node segment identifier table; Cross-node consistency buffering buffers intermediate construction states and relation edge mapping tables when a construction task involves multiple storage nodes. Based on the node mapping sequence, the synchronization order of the construction task execution is controlled to ensure the alignment and path integrity of ontology nodes and relation edges during graph writing. Specifically, since graph nodes and relation edges may be distributed across multiple physical nodes, an intermediate construction buffering mechanism needs to be established to coordinate consistency issues during concurrent writing across multiple nodes.

[0039] During the graph construction process, the system maintains a relation edge mapping buffer table to record the start and end node addresses, status, and edge type of each edge. The control graph writing process follows a node-first → edge-last writing strategy, and determines the writing order based on the node mapping sequence. Synchronization relies on locking mechanisms or transaction control to ensure that the edge table is updated only after the node is successfully written, thus avoiding problems such as "orphan edges" and "broken links" and maintaining the path integrity of the graph.

[0040] The node distribution weight factor represents the capacity adaptability of each target node to the graph node distribution density, the data source path offset represents the path migration span between the data field source and the physical distribution of the target nodes, and the edge partitioning function is used to calculate its distribution position in the partitioning system based on the connection tension of the relation edges.

[0041] After transforming the model dataset into graph node and edge data in a distributed environment, the process before writing the node and edge data to the distributed graph library nodes includes: Before writing data to the distributed map library nodes, a preprocessing process is performed to ensure the structural standardization of the map data, the traceability of metadata, and the compliance of the writing operation. The preprocessing procedure includes: Graph write request parsing: Receive graph data write requests from the task scheduling module, perform syntax and semantic parsing on the write requests, extract the ontology, relations and fields contained therein, and use the ontology, relations and fields as the parsing results; Metadata index registration: Based on the parsing results, a metadata index is established for the graph nodes and relation edges to be written, recording the original data source fields, attribute mapping relationships and endpoint information of the associated edges of each node; Pre-write structural integrity verification: The graph data is verified for compliance based on a preset set of verification rules. The set of verification rules includes structural consistency conditions and topological rationality conditions. The structural consistency conditions include node attribute coverage, uniqueness of relation direction, and completeness of mapping field filling. The topological rationality conditions include edge endpoint existence, uniqueness of node identifier, and edge label repetition rate threshold.

[0042] S5. Distributed graph query and analysis: Construct entity indexes, relationship indexes, and path indexes on the distributed graph, analyze the connection methods, jump paths, and overall topological relationships between entities in the distributed graph, and obtain entity data, relationship data between entities, and the shortest path between entities.

[0043] The distributed graph query and analysis includes: By constructing multi-dimensional indexes, performing restricted path searches, and generating comprehensive analysis indicators, deep semantic mining of entity relationships in the graph is achieved, specifically including: Build multi-dimensional indexes: respond to query requests from business systems, identify and determine the target entity pairs to be analyzed as the starting and ending points of path exploration; Based on the query request, relevant ontology indexes, relation indexes, and attribute information are extracted to limit the search space; Hop-limited path search: Based on the extracted relation index and attribute information, a hop-limited path search algorithm is adopted to traverse the graph within a preset maximum hop count range, generate all reachable paths connecting the start and end points of the target entity pair, and form a path set containing multiple semantic paths. Multi-dimensional graph analysis index generation: Perform graph analysis on the generated path set to obtain the connection method, connection path and overall graph topology.

[0044] Specifically, path extraction involves constructing a set of path sequences between the origin and destination of entities, extracting all paths that satisfy the node reachability condition, and combining the relationship type in the path chain with the path to form a relationship chain signature. In essence, the first step in graph analysis is path extraction, which requires identifying all reachable paths between entity pairs in the graph and abstracting them. For any set of entity nodes (Starting point) and (Destination), construct the path set: Each path It is converted into a relational chain signature, defined as follows: ,in, Indicates the first The type and direction of each relation edge are defined by the superscript arrow, which indicates whether the relation is traversed from the starting point to the ending point along the original direction of the relation (forward) or in the reverse direction (backward). By abstracting the path, we can capture the complex semantic connection patterns between entities in the graph. Hop count constraint analysis involves pruning and categorizing paths exceeding the hop count limit in the path chain. A path influence matrix is ​​constructed for each valid path chain, where each element characterizes the semantic penetration degree of each edge at each level of the path between the starting and ending nodes. Specifically, because excessively long paths may introduce redundancy and noise, the system performs hop count constraint analysis. Set jump limit Trim all paths ,satisfy: The set of valid paths after clipping ,in, The path length is the number of relations traversed in the path (i.e., the number of hops). For example, the path A→r1→B→r2→C→r1→B→r2→C has a length of 2 because it contains two relations (r1 and r2). A, B, and C are entity nodes. A path influence matrix is ​​constructed for each path. , k represents the total number of paths, indicating the semantic penetration degree of each level edge in the path; for each path The elements of its influence matrix are calculated as follows: each level of edge The semantic penetration is expressed as: , Representing relation edges Leading to the end entity Attributes Access accessibility (such as index hit rate, attribute aggregation density). The relation sparsity factor is used to penalize path edges with high connectivity. Each element in the path influence matrix represents the degree of contribution of that edge to the semantic transmission of the path. The relational coupling path scoring system calculates path scores based on the path influence matrix. These scores identify the path chain's relational representation ability within the graph, generating a path ranking index for subsequent question-answering inference and recommendation service calls. Specifically, based on the path influence matrix... The overall score for the calculation path is as follows: ,in, This is a semantic perturbation suppression term, ensuring that sparse paths are not affected by minimal factors. Over-inhibited To ultimately represent the relational representation capability of paths within a graph, according to For all Sort the data and generate a path-sorted index. It is used for path reasoning in question-answering systems, entity relationship scoring in recommendation systems, and path highlighting in graph visualization; The relation chain signature is composed of the relation type and direction of consecutive edges in the path; Semantic penetration refers to the level of influence of relationships in a path on the accessibility of the target attribute index; The path score is a composite index of path and semantic density in the graph.

[0045] This application also discloses a terminal device, including a memory and a processor. The memory stores a computer program that can run on the processor. When the processor loads and executes the computer program, it employs a knowledge graph analysis method based on transportation scheduling.

[0046] The terminal device can be a computer device such as a desktop computer, a laptop computer, or a cloud server. The terminal device includes, but is not limited to, a processor and a memory. For example, the terminal device may also include input / output devices, network access devices, and buses.

[0047] The processor can be a central processing unit (CPU). Of course, depending on the actual use, it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), off-the-shelf programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc., and this application does not limit it.

[0048] The memory can be an internal storage unit of the terminal device, such as a hard disk or RAM of the terminal device, or an external storage device of the terminal device, such as a plug-in hard disk, smart memory card (SMC), secure digital card (SD), or flash memory card (FC) equipped on the terminal device. Furthermore, the memory can be a combination of internal storage units and external storage devices of the terminal device. The memory is used to store computer programs and other programs and data required by the terminal device. The memory can also be used to temporarily store data that has been output or will be output. This application does not limit this.

[0049] In this terminal device, a knowledge graph analysis method based on transportation scheduling in the above embodiments is stored in the memory of the terminal device and loaded and executed on the processor of the terminal device for convenient use.

[0050] This application also discloses a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it employs a knowledge graph analysis method based on transportation scheduling as described in the above embodiments.

[0051] The computer program can be stored in a computer-readable medium. The computer program includes computer program code, which can be in the form of source code, object code, executable file, or certain middleware. The computer-readable medium includes any entity or device capable of carrying computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the computer-readable medium includes, but is not limited to, the above-mentioned components.

[0052] The knowledge graph analysis method based on transportation scheduling described in the above embodiments is stored in the computer-readable storage medium and loaded and executed on the processor to facilitate the storage and application of the above method.

[0053] Those skilled in the art should understand that the discussion of any of the above embodiments is merely exemplary and is not intended to imply that the scope of protection of this application is limited to these examples; within the framework of this application, the technical features of the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other variations of different aspects of one or more embodiments of this application as described above, which are not provided in detail for the sake of brevity.

[0054] One or more embodiments in this application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of this application. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of one or more embodiments in this application should be included within the protection scope of this application.

Claims

1. A knowledge graph analysis method based on transportation scheduling, characterized in that, include: Constructing a transportation scheduling knowledge model: Set knowledge domain identifiers, define ontology and relations, configure ontology attributes and relation attributes, and construct a transportation scheduling knowledge model. The ontology includes transportation vehicles, waybills, scheduling events, and infrastructure. The relations include carrier, traveling, connecting, and being delayed. Create model dataset: Based on the ontology and relations defined in the transportation scheduling knowledge model, extract data fields from the structured data source, clean and unify the format of the data fields to obtain processed fields, and store the processed fields into the datasets corresponding to the ontology and relations respectively to obtain ontology dataset and relation dataset, and use ontology dataset and relation dataset as model dataset. The processing fields in the model dataset are mapped to the attribute fields in the transportation scheduling knowledge model. An index mapping table between fields and attributes is established, and the consistency of the mapping relationship in the semantic dimension is verified. If the consistency is passed, the mapping binding relationship between the transportation scheduling knowledge model and the model dataset is established. The attribute fields are obtained through ontology attributes and relation attributes. Construct a graph data ingestion task to obtain a distributed graph: Configure the graph ingestion task based on the mapping and binding relationship, set task scheduling parameters and execution rules, transform the model dataset into graph node data and edge data in a distributed environment, write node data and edge data to the distributed graph library nodes, and obtain a distributed graph; Distributed graph query and analysis: Build entity index, relationship index and path index on the distributed graph, analyze the connection mode between entities in the distributed graph, jump path and the overall topological relationship of the graph, and obtain entity data, relationship data between entities and the shortest path between entities; The process of writing node data and edge data to the distributed graph nodes and obtaining the distributed graph before the following steps are included: Implementing a relation edge partitioning strategy and a cross-node consistency buffering mechanism in a distributed environment optimizes the sharded storage layout of graph data and ensures the integrity of the graph structure during concurrent writes across multiple nodes. Specifically, this includes: The relation edge partitioning strategy includes: obtaining the connectivity and connection tension of each relation edge based on the topological connectivity characteristics of the relation edges in the graph, and substituting the connectivity and connection tension into the edge partitioning function to obtain the evaluation value; The distribution priority of each relation edge is obtained through the evaluation value, the target storage shard of the relation edge is determined according to the distribution priority, and the relation edge shard identifier is generated. When the ontology nodes connected by the relation edge are located on different storage nodes, a cross-shard write strategy is formulated based on the relation edge shard identifier to ensure that the physical storage location of the edge data and its associated node is as close as possible to reduce cross-node access overhead. The cross-node consistency buffer mechanism includes: during the graph data import process, establishing a temporary buffer for relation edges involving cross-node writing, which is used to temporarily store the relation edge records to be written and their associated ontology node status information; Based on the aforementioned relational edge partitioning strategy and cross-node consistency buffering mechanism, the integrity of the graph structure is ensured during the concurrent write process of multiple nodes; The connection tension function is: ,in, and For adjustment coefficients, The distance between nodes. This refers to the access frequency.

2. The knowledge graph analysis method based on transportation scheduling according to claim 1, characterized in that, Constructing a transportation scheduling knowledge model includes: Configure knowledge domain identifiers: including setting the domain name, domain number, and domain description; Create an ontology: Configure the ontology name, ontology index, and attribute set; Establishing relationships: Configure relationship direction, ontology connection method, relationship index, and attribute set; A transportation scheduling knowledge model is constructed based on knowledge domain identifiers, ontology, and relationships.

3. The knowledge graph analysis method based on transportation scheduling according to claim 1, characterized in that, Creating the model dataset includes: Determine the data source type, extract the data fields corresponding to the model fields, and obtain the extracted fields; The extracted fields are subjected to field format conversion, data redundancy removal and syntax standardization to obtain the processed fields; The processed fields are stored in the datasets corresponding to the ontology and the relation, respectively, to obtain the ontology dataset and the relation dataset. The ontology dataset and the relation dataset are then used as the model dataset.

4. The knowledge graph analysis method based on transportation scheduling according to claim 1, characterized in that, Establishing a mapping relationship between the transportation scheduling knowledge model and the model dataset includes: Bind the ontology and relations of the transportation scheduling knowledge model to the corresponding model dataset; Create an index mapping table between the model dataset and the transportation scheduling knowledge model; The consistency of the mapping relationship is verified based on the index mapping table. If the consistency check passes, the mapping and binding relationship between the transportation scheduling knowledge model and the model dataset is established through the index mapping table and the model dataset.

5. The knowledge graph analysis method based on transportation scheduling according to claim 4, characterized in that, The task of constructing and storing the map data includes: Based on the mapping and binding relationship of the model dataset and the transportation scheduling knowledge model, a graph construction task is established. The task number and storage strategy of the graph construction task are set, and the relevant information of the graph construction task is configured, including the task name, execution time and execution frequency. Based on the task number, data import strategy, and relevant information, execute the map data import task. The map data import task specifically includes: Based on the mapping and binding relationships of the model dataset, the data in the model dataset is converted into the graph format required for the knowledge graph, resulting in graph-converted data; The graph transformation data is constructed into a knowledge graph according to the transportation scheduling knowledge model, and node data and edge data are generated according to ontology attributes and relation attributes; Write node data and edge data into the distributed graph database nodes to complete the task of storing graph data.

6. The knowledge graph analysis method based on transportation scheduling according to claim 1, characterized in that, After transforming the model dataset into graph node and edge data in a distributed environment, the process before writing the node and edge data to the distributed graph library nodes includes: Before writing data to the distributed map library nodes, a preprocessing process is performed to ensure the structural standardization of the map data, the traceability of metadata, and the compliance of the writing operation. The preprocessing procedure includes: Graph write request parsing: Receive graph data write requests from the task scheduling module, perform syntax and semantic parsing on the write requests, extract the ontology, relations and fields contained therein, and use the ontology, relations and fields as the parsing results; Metadata index registration: Based on the parsing results, a metadata index is established for the graph nodes and relation edges to be written, recording the original data source fields, attribute mapping relationships and endpoint information of the associated edges of each node; Pre-write structural integrity verification: The graph data is verified for compliance based on a preset set of verification rules. The set of verification rules includes structural consistency conditions and topological rationality conditions. The structural consistency conditions include node attribute coverage, uniqueness of relation direction, and completeness of mapping field filling. The topological rationality conditions include edge endpoint existence, uniqueness of node identifier, and edge label repetition rate threshold.

7. The knowledge graph analysis method based on transportation scheduling according to claim 1, characterized in that, The distributed graph query and analysis includes: By constructing multi-dimensional indexes, performing restricted path searches, and generating comprehensive analysis indicators, deep semantic mining of entity relationships in the graph is achieved, specifically including: Build multi-dimensional indexes: respond to query requests from business systems, identify and determine the target entity pairs to be analyzed as the starting and ending points of path exploration; Based on the query request, relevant ontology indexes, relation indexes, and attribute information are extracted to limit the search space; Hop-limited path search: Based on the extracted relation index and attribute information, a hop-limited path search algorithm is adopted to traverse the graph within a preset maximum hop count range, generate all reachable paths connecting the start and end points of the target entity pair, and form a path set containing multiple semantic paths. Multi-dimensional graph analysis index generation: Perform graph analysis on the generated path set to obtain the connection method, connection path and overall graph topology.

8. A terminal device, comprising a memory and a processor, characterized in that, The memory stores a computer program that can run on a processor, and when the processor loads and executes the computer program, it employs the method described in any one of claims 1 to 7.

9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is loaded and executed by the processor, it employs the method described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Mass structured data-oriented knowledge graph parallel construction method

    CN116383318A

  • Knowledge graph construction method and device based on artificial intelligence, equipment and medium

    CN119250191A

  • Heterogeneous knowledge-based medical multi-hop text question and answer retrieval enhancement method

    CN120821802A