Entity spatio-temporal information and topological relation retrieval method based on spatio-temporal knowledge graph

By constructing an entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph, and utilizing large language models and BeiDou grid coding, the problem of insufficient semantic understanding and spatial index adaptability of spatiotemporal knowledge graph is solved, realizing high-precision multi-dimensional retrieval and association analysis, and supporting intelligent decision-making in multiple scenarios.

CN121996853APending Publication Date: 2026-05-08ZHEJIANG SHIZIZHIZI BIG DATA CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG SHIZIZHIZI BIG DATA CO LTD
Filing Date
2026-01-26
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing spatiotemporal knowledge graphs suffer from insufficient spatiotemporal semantic understanding, weak multi-dimensional retrieval capabilities, and inadequate adaptability to spatial indexing standards, resulting in low retrieval accuracy and efficiency in complex spatiotemporal scenarios.

Method used

A method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs is constructed. The method utilizes large language model LLM for semantic segmentation and factual statement extraction, combines BeiDou grid coding for spatial geographic entity coding, and creates multiple parallel retrieval paths to achieve collaborative processing of triplet, time retrieval and spatial geographic retrieval.

Benefits of technology

It improves the accuracy and generalization of complex spatiotemporal semantic understanding, realizes multi-dimensional collaborative retrieval, and can perform high-precision entity matching and association analysis across scales, time granularities and business scenarios, supporting highly reliable data support for scenarios such as smart transportation, urban governance and emergency command.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121996853A_ABST
    Figure CN121996853A_ABST
Patent Text Reader

Abstract

The invention discloses an entity spatio-temporal information and topological relation retrieval method based on a spatio-temporal knowledge graph, and the method comprises the steps: constructing a knowledge source database, and carrying out spatio-temporal knowledge graph processing to obtain a spatio-temporal knowledge graph database, the spatio-temporal knowledge graph comprising a time entity, a spatial geographic entity and a triple; the method comprises the following steps of: carrying out semantic partitioning on input query data by utilizing a large language model (LLM), carrying out fact declarative sentence extraction on each block, and extracting a query combination comprising a triple, a time entity and a spatial geographic entity from the fact declarative sentences; and a space-time retrieval planner is utilized to create a multi-path parallel retrieval path matched with the query combination, the multi-path parallel retrieval path comprises triple retrieval, time retrieval and spatial geographic retrieval, and the multi-path parallel retrieval path is utilized to perform multi-path parallel search in the space-time knowledge graph database and summarize and output retrieval results in a layered manner. According to the method, the precision and generalization of complex space-time semantic understanding are improved, and multi-dimensional collaborative retrieval optimization is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of spatiotemporal query retrieval, and in particular to a method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs. Background Technology

[0002] With the rapid development of artificial intelligence and big data technologies, knowledge graphs, as a core technology for integrating data and semantic relationships, have been widely applied in fields such as smart transportation, urban governance, and environmental monitoring. Knowledge graphs are an information extraction technology that extracts important entities and relationships from massive amounts of information and constructs a connected graph network structure. Because of their ability to mine deep-level relational information and understand global semantics, the application of knowledge graphs significantly improves the output accuracy and reliability of Retrieval-Augmented Generation (RAG) and addresses issues such as knowledge obsolescence and illusion generation in Large Language Models (LLMs). In recent years, spatio-temporal knowledge graphs have emerged. Research shows that constructing spatio-temporal knowledge graphs with spatio-temporal characteristics can enhance spatio-temporal semantic understanding capabilities and enable complex spatio-temporal reasoning (such as predicting the future spatial distribution of entities and tracing temporal relationships), providing direct decision-making basis for scenario-based business. However, traditional spatio-temporal knowledge graphs have two shortcomings in technology implementation and business adaptation: firstly, their spatio-temporal reasoning capabilities are weak and their generalization is poor. Traditional spatiotemporal reasoning is often limited to simple temporal associations (e.g., "Event A occurs after Event B") or spatial proximity judgments (e.g., "Location C is close to Location D"), lacking in-depth exploration of complex spatiotemporal dependencies across scales (e.g., "city-level planning and street-level management") and scenarios (e.g., "daily monitoring and emergency dispatch"). Furthermore, existing spatiotemporal reasoning models often rely on fixed rule designs or training on specific datasets, resulting in significantly insufficient model adaptability and generalization capabilities when facing dynamically changing real-world business needs (e.g., resource allocation scenarios after sudden disasters). Secondly, spatial labeling is inconsistent and entity adaptability is poor. On the one hand, traditional spatiotemporal knowledge graphs have not introduced a unified spatial labeling standard, lacking unified spatial specifications. Different data sources have varying spatial labeling formats, leading to problems such as coordinate conflicts, duplicate annotations, and difficulties in data fusion when integrating multi-source data. On the other hand, they struggle to achieve multi-scale adaptation for different types of geographical entities, such as points (e.g., individual monitoring devices), lines (e.g., roads, rivers), and areas (e.g., administrative regions, lakes), especially for irregularly shaped geographical entities like rivers and complex administrative regions, failing to accurately describe their spatial extent and relationships.

[0003] With the rapid development of knowledge graph technology, graph retrieval technology is moving towards greater precision and intelligence. However, existing knowledge graph retrieval technologies still have significant shortcomings in spatiotemporal knowledge graph scenarios, specifically in the following four aspects: First, the ability to analyze complex semantics is insufficient. Traditional knowledge graph retrieval methods rely on exact matching and single-word queries, which makes it difficult to analyze unstructured query requirements such as fuzzy time descriptions (e.g., "before and after the flood season") and fuzzy spatial descriptions (e.g., "around the science park"), resulting in insufficient discovery of users' core query intent and low relevance of search results.

[0004] Secondly, the multi-dimensional retrieval capability is insufficient; traditional retrieval methods generally ignore the consideration of spatiotemporal dimensions and cannot systematically process spatiotemporal information; especially in complex spatiotemporal scenarios such as cross-scale spatiotemporal queries (such as city-level planning and street control analysis) and multi-condition composite retrieval, the bottlenecks of low retrieval accuracy and low efficiency are particularly prominent.

[0005] Third, the adaptability of multi-scale spatial indexing standards is poor. Traditional spatial retrieval relies excessively on latitude and longitude coordinates or administrative boundaries, lacking native support for gridded spatial representation methods such as BeiDou grid coding. This results in significant accuracy deviations in scenarios such as queries for irregular geographical entities (e.g., "a farm within a mountainous protected area with irregular boundaries") and cross-administrative boundary searches (e.g., "sewage outlets along a river spanning cities A and B"). At the same time, differentiated retrieval strategies for spatial entities of different forms, such as points, lines, and surfaces, are lacking (e.g., "finding schools (points) and forest parks (areas) within 5 kilometers of a railway (line)"), failing to fully leverage the advantages of multi-scale grid coding in spatial retrieval. Summary of the Invention

[0006] The purpose of this invention is to address the core pain points of existing technologies, such as insufficient spatiotemporal semantic understanding, weak multi-dimensional retrieval capabilities, and inadequate adaptability of spatial indexing standards, and to provide a method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs.

[0007] The objective of this invention is achieved through the following technical solution: A method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs, the method comprising: S1. Construct a knowledge source database and perform spatiotemporal knowledge graph processing to obtain a spatiotemporal knowledge graph database. The spatiotemporal knowledge graph includes time entities, spatial geographic entities, and triples. S2. Use the Large Language Model (LLM) to semantically segment the input query data, extract factual statements from each segment, and extract query combinations that include triples, time entities, and spatial geographic entities from the factual statements. S3. Use the spatiotemporal retrieval planner to create multi-path parallel retrieval that matches the query combination. The multi-path parallel retrieval includes triplet retrieval, time retrieval and spatial geographic retrieval. Use the multi-path parallel retrieval to perform multi-path parallel searches in the spatiotemporal knowledge graph database and summarize and output the retrieval results in a hierarchical manner.

[0008] To better implement this invention, in method S1, the spatiotemporal knowledge graph database is obtained as follows: S11. Use the Large Language Model (LLM) to semantically segment the data in the knowledge source database, extract factual statements for each semantic segment, and extract triples, time entities, and spatial geographic entities from the factual statements. Triples contain entities and entity relationships. S12. Encode the time attributes of time entities; construct a gridded BeiDou satellite geographic map, and form a BeiDou grid coding dataset by matching the geographic codes of all grids in the BeiDou satellite geographic map with the associated grids. Use the BeiDou grid coding dataset to perform associated grid matching coding of spatial geographic entities to form the corresponding spatial attributes. S13. Associate and aggregate time entities with time attributes and spatial geographic entities with spatial attributes from the knowledge source database with triples to construct a spatiotemporal knowledge graph database.

[0009] Preferably, in method S3, the triplet retrieval utilizes the triples in the query combination to create parallel retrieval tasks for entity retrieval, relation retrieval, and clustering retrieval. The entity retrieval task uses entities in the triples of the query combination as keywords for keyword retrieval; the relation retrieval task uses the entity relations in the triples of the query combination to perform similarity retrieval using vector representation; and the clustering retrieval task uses entities in the triples of the query combination to perform clustering of similar entities and retrieves results based on the clustering of similar entities. The time retrieval utilizes the time entities in the query combination to create time retrieval tasks and time inference retrieval tasks. The time retrieval task uses the time entities in the query combination as keywords for keyword retrieval; and the time inference retrieval task uses the time entities in the query combination to perform inference calculations for absolute time, relative time, and fuzzy time and retrieves results. The spatial geographic retrieval utilizes the spatial geographic entities in the query combination to create parallel retrieval tasks for spatial retrieval and spatial attribute retrieval of spatial geographic entities. The spatial retrieval uses the spatial geographic entities in the query combination as keywords for keyword retrieval; and the spatial attribute retrieval of spatial geographic entities uses the spatial attributes of the spatial geographic entities in the query combination for retrieval.

[0010] Preferably, the triplet retrieval further includes a multi-hop path retrieval task, which creates several entity hop neighborhoods centered on the entities in the triplet of the query combination for retrieval; the time retrieval further includes a time multi-hop retrieval task, which creates several time entity multi-hop neighborhoods centered on the time entities in the query combination for retrieval; the spatial geographic retrieval further includes a spatial multi-hop retrieval task, which creates several spatial geographic entity multi-hop neighborhoods centered on the spatial geographic entities in the query combination for retrieval; the triplet retrieval, time retrieval, and spatial geographic retrieval are executed in parallel, and the retrieval tasks are marked according to the hierarchical weight parameters set according to the entity similarity in the query combination, and the retrieval results output by the triplet retrieval, time retrieval, and spatial geographic retrieval are summarized and hierarchically processed.

[0011] Preferably, the time-based retrieval further includes a time event analysis module and a time trend analysis module. The time event analysis module is used to perform association analysis of the same or / and similar entities on the retrieval results output by the time-based retrieval. The time trend analysis module is used to perform trend analysis of the same entities and / or trend comparison analysis of similar entities on the retrieval results output by the time-based retrieval. The spatial geographic retrieval further includes spatial attribute granular hierarchical retrieval and spatial attribute encoding topology retrieval tasks. The spatial attribute granular hierarchical retrieval task performs granular hierarchical retrieval centered on the spatial attributes of spatial geographic entities. The spatial attribute encoding topology retrieval task performs spatial topology relationship retrieval centered on the spatial attributes of spatial geographic entities. Spatial topology relationships include spatial positional relationships including inclusion, intersection, adjacency, and relative orientation with spatial geographic entities as references. The spatial geographic retrieval further includes a spatial event analysis module and a spatial trend analysis module. The spatial event analysis module is used to perform association analysis of the same or / and similar entities on the retrieval results output by the spatial retrieval. The spatial trend analysis module is used to perform trend analysis of the same entities and / or trend comparison analysis of similar entities on the retrieval results output by the spatial retrieval.

[0012] Preferably, in method S11, a statement extraction is performed on the blocks, and the statements are extracted from the blocks. The function extracts a set of atomic fact statements. The expression is as follows: ,in For large language models, For semantic segmentation, To extract prompt words, in method S13, time entities containing time attributes are associated sequentially according to time attribute codes, and spatial geographic entities containing spatial attributes are associated spatially based on BeiDou satellite geographic maps.

[0013] Preferably, in method S12, the time entity The encoding time attribute expression is as follows: , For entities Unique identifier Represents entity description information, For time type, , These represent the time start boundary, respectively; the spatial attribute expressions for spatial geographic entities are as follows: ,in For entities Unique identifier Represents entity description information, It is a spatial geographic type. This refers to the geographic coordinates (latitude, longitude, and altitude) corresponding to the entity. and These represent the BeiDou grid coding set and BeiDou grid level corresponding to spatial geographic entities, respectively. Preferably, method S12 further includes the following method: S121, Through Functions retrieve a set of spatially or geographically related geographic locations. ;pass Function to determine and obtain spatial geographic location Spatial geographic types and BeiDou grid hierarchy; obtaining spatial geographic locations The corresponding latitude, longitude and altitude data are combined with the BeiDou grid hierarchy to perform corresponding encoding of the BeiDou grid encoding set; S122, Constructing a spatial geographic location As a parent node, spatial geographic entity Spatial geographic association is performed as a child node.

[0014] Preferably, the grid in the BeiDou satellite geographic map is divided into hierarchical levels based on spatial location resolution, and the BeiDou grid coded dataset is correspondingly divided into BeiDou grid levels belonging to different scales.

[0015] Preferably, the spatial geographic locations and spatial geographic entities include spatial geographic information of types such as points, lines, and areas, where a point represents a spatial geographic location point, a line represents a linear set of spatial geographic location points, and an area represents a planar set of spatial geographic location points.

[0016] Compared with the prior art, the present invention has the following advantages and beneficial effects: (1) This invention solves the technical problems of existing graph retrieval, such as insufficient spatiotemporal semantic understanding, weak multi-dimensional retrieval capabilities, and insufficient adaptability of spatial index standards. It improves the accuracy and generalization of complex spatiotemporal semantic understanding, realizes multi-dimensional collaborative retrieval optimization, and can empower the implementation of scenario-based applications and intelligent decision support.

[0017] (2) This invention relies on the context awareness and logical reasoning capabilities of the large language model to improve the parsing difficulties of fuzzy time descriptions and implicit spatial relationships. Through semantic alignment, spatiotemporal constraint extraction and other methods, the natural language query input by the user is accurately transformed into structured search conditions. This invention innovatively integrates the collaborative search architecture of the triple semantic dimension (entity-relationship-attribute), time dimension (instantaneous / period / trend) and spatial dimension (point / line / surface) to build a spatiotemporal semantic integrated search system. Relying on the multi-level and high-precision spatial indexing characteristics of Beidou grid coding, it breaks through the bottleneck of composite condition search across scale spatial range, time granularity and business scenarios, and realizes multi-dimensional search and matching of different types of entities.

[0018] (3) This invention deeply integrates the spatiotemporal reasoning and association capabilities of spatiotemporal knowledge graphs, and extends the search results to provide value-added services such as spatiotemporal association analysis, potential risk warning and development trend prediction; accurately matches the core business needs of intelligent traffic scheduling, refined urban governance, emergency command and control, and natural resource management, providing high-precision and high-reliability data support and scientific decision-making basis for various scenarios, promoting the upgrade of the search system from "data query" to "decision empowerment", and improving the engineering application value and implementation capability of search technology.

[0019] (4) This invention creatively integrates the advantages of standardized spatial representation of Beidou grid coding with the structured information extraction capability of large language model. The large language model performs semantic segmentation and factual statement extraction on the text. Then, it extracts triples, time entities and spatial geographic entities from the factual statements. The time entities and spatial geographic entities are respectively attribute-encoded. The encoded time entities, spatial geographic entities and triples are collected to construct a spatiotemporal knowledge graph. It solves the core pain points of traditional knowledge graphs, such as inconsistent spatial benchmarks, inefficient multi-source data fusion, insufficient accuracy of irregular geographic entity representation, insufficient spatiotemporal semantic reasoning ability, and reliance on manual annotation or model training. Attached Figure Description

[0020] Figure 1 This is a flowchart of the entity spatiotemporal information and topological relationship retrieval method of the present invention; Figure 2 This is a schematic diagram illustrating the principle of the spatiotemporal retrieval planner receiving query data or user queries in this embodiment. Figure 3This is a flowchart illustrating the method for obtaining the spatiotemporal knowledge graph database in this embodiment. Figure 4 This is a schematic diagram illustrating the principle of triplet retrieval in the embodiment; Figure 5 This is a schematic diagram illustrating the principle of the time retrieval method in the embodiment; Figure 6 This is a schematic diagram illustrating the principle of spatial geographic retrieval in the embodiment. Figure 7 This is a schematic diagram illustrating the principle of the method for obtaining the spatiotemporal knowledge graph in the embodiment. Figure 8 This is a schematic diagram illustrating the principle of spatial geographic entity extraction and spatial attribute encoding using a river as an example in the embodiment. Detailed Implementation

[0021] The present invention will be further described in detail below with reference to embodiments: Example like Figure 1 As shown, a method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs includes the following steps: S1. Construct a knowledge source database and perform spatiotemporal knowledge graph processing to obtain a spatiotemporal knowledge graph database. The spatiotemporal knowledge graph includes time entities, spatial geographic entities, and triples.

[0022] In some embodiments, such as Figure 3 As shown, the spatiotemporal knowledge graph database is obtained using the following method: S11. Utilize a Large Language Model (LLM) to semantically segment the input text, and extract factual statements from each segment, such as... Figure 3 , Figure 7 As shown, factual statements are extracted into triples, temporal entities, and spatial geographic entities, with triples containing entities and entity relationships. In some embodiments, a Large Language Model (LLM) (which leverages contextual understanding and few-shot learning capabilities to automatically perform complex semantic understanding and reasoning) performs semantic chunking on the input text. (chunk) performs statement extraction, using... The function extracts a set of atomic fact statements. For the set of factual statements The expression is as follows: ,in For large language models, For semantic segmentation, To extract prompt words; The function transforms natural language (unstructured text) into reasonable, structured, independent statements. A triple contains entities (including a head entity and a tail entity) and relationships between entities (i.e., the relationship between the head and tail entities). ,in, This is a collection of head entities. A set of relations; This is a collection of tail entities. and Together they form a spectral triplet structure. This is a template for extracting prompts from triples. This is a function driven by a large language model (LLM) that outputs structured target content. , where the function This refers to the process of extracting target triples by leveraging the analytical reasoning capabilities of Large Language Modeling (LLM). This refers to the entity resolution process, which involves eliminating and merging entities with similar or recurring meanings. Large Language Modeling (LLM) addresses temporal entities in factual statements. The extraction process focuses on extracting time-related information, and the output is a set of time-related entities. The Large Language Model (LLM) extracts spatial entities from factual statements. Extraction focuses on extracting spatially relevant information, and the output is a collection of spatial entities.

[0023] S12. Encode the time attribute of the time entity. Encode the time attribute of the time entity, such as... Figure 3 , Figure 7 As shown, assume the set of time entities output by the Large Language Model (LLM) is... Using a specific time entity from the set of time entities This section uses an example to introduce time attribute encoding. In some embodiments, time entities... The time attribute expression encoded for a specific time entity in the time entity set is as follows: , For entities Unique identifier Represents entity description information, For time type, , These represent the time start boundary ( Indicates the start time. (Indicates the end time). Time type , ,in To describe a single time event (an event biased towards a specific point in time), such as "being appointed" or "happening". For the time type of a persistent state, associate the start time. With end time If the current period continues, then the end time is... It can be recorded as continuous or infinite. For example, a continuous state is when someone started “serving” as a leader and has been in that position ever since. This indicates a state with no clear time association (leaning towards unrelated time information). Generally, the start time... With end time It can be recorded as None.

[0024] Time Entity Set The extraction expression is as follows: , Enter a declarative sentence; Will be All time entities Extract and populate unique identifiers Description content Time type Time start and Information such as; It is a function for detecting and validating time conflicts between old and new languages ​​based on a large language model; Extract prompt words for time entities.

[0025] A gridded BeiDou satellite geographic map is constructed, and all grids in the BeiDou satellite geographic map correspond to geocoding to form a BeiDou grid-coded dataset. Preferably, the grids in the BeiDou satellite geographic map are hierarchically divided according to spatial location resolution, and the BeiDou grid-coded dataset is correspondingly divided into BeiDou grid levels belonging to different scales. The BeiDou grid-coded dataset is used to perform grid-matching encoding on spatial geographic entities to form their corresponding spatial attributes, such as... Figure 2 As shown, assume that the set of spatial geographic entities output by the Large Language Model (LLM) is... Using a specific time entity within a set of spatial geographic entities This section uses an example to introduce spatial attribute encoding. In some embodiments, spatial geographic entities... The spatial attribute expressions are as follows: ,in For entities Unique identifier Represents entity description information, It is a spatial geographic type. , ,like Refers to the location or coordinates of a specific point; Linear locations (length), such as rivers, streets, etc. This refers to a geographical location, such as an administrative district or a lake. This refers to the geographic coordinates (latitude, longitude, and altitude) corresponding to the entity. and These represent the BeiDou grid coding set and BeiDou grid level corresponding to spatial geographic entities, respectively. , For the BeiDou Navigation Satellite System.

[0026] The present invention further includes the following method in method S12: S121, Through Functions retrieve a set of spatially or geographically related geographic locations. ;pass Function to determine and obtain spatial geographic location Spatial geographic types, BeiDou grid levels; , Enter a declarative sentence; Extract prompts for geographic locations (names) by... Function to determine geographical location Corresponding Type and BeiDou grid level , , The system provides prompts for spatial geographic types and BeiDou grid levels. Leveraging the inherent pre-training knowledge of LLM, it autonomously completes the process of determining... of Type determination (e.g., "Temple of Heaven" corresponding to a single landmark) Type, "Nanjing Road" corresponding linear channel Type, corresponding area of ​​"Qinghai Lake" Type). Secondly, based on Type, semantic features (e.g., "city-level main roads" need to be adapted to a coarser grid level, "street-level monitoring points" need to be adapted to a finer grid level), and Few-shots mesh adaptation example, intelligent estimation BeiDou grid hierarchy Furthermore, for complex and irregularly shaped geographical entities (such as "inter-provincial rivers"), this invention evaluates reasonable [measures] based on entity size, application scenario, and implicit requirements (derived through context). value.

[0027] Obtaining spatial geolocation The corresponding latitude, longitude, and altitude data are combined with the BeiDou grid hierarchy to perform corresponding encoding of the BeiDou grid coding set. Spatial geographic location is then obtained. Corresponding latitude, longitude, and altitude data (set) ,according to As can be seen from the definition, Type-based geographic locations are treated as a point or a single entity, therefore requiring only a single coordinate point for representation; while and Geographical locations of different types need to be represented by a "set of coordinate points" due to their length and area. For example... Figure 8 As shown in the three smaller images a, b, and c, a single coordinate point cannot completely represent the entire river; therefore, it is necessary to follow... The hierarchical distribution of the BeiDou grid evenly samples multiple coordinate points passing through the river and converges them into a coordinate point set to represent the irregular river morphology. Similarly, The type of geographic location should retrieve the set of coordinate points passing through its boundary contour and within the contour. Query or retrieve... Data can also be obtained in two other ways: first, by using data query and boundary extraction tools on a GIS (Geographic Information System) platform; and second, through geocoding APIs provided by various map service providers.

[0028] Get Beidou grid coding set . In the known of and In this case, the mapping method from latitude and longitude coordinates to BeiDou two-dimensional (or three-dimensional) grid location codes. This invention is carried out with reference to the method disclosed in Appendix B of the national standard "BeiDou Grid Location Code" (GB / T 39409-2020) (this standard was published on November 19, 2020 and implemented on June 1, 2021).

[0029] The spatial geographic entities in this embodiment can also be encoded using the above-described encoding method.

[0030] S122, Constructing a spatial geographic location As a parent node, spatial geographic entity Spatial geographic association is performed as a child node. For example... Figure 8 The small diagram in the middle shows all of them. Create complete spatial geographic entity nodes (Each node corresponds to a BeiDou grid), and the results of the above steps are sequentially filled into its corresponding attributes to complete the spatial geographic entity set. The extraction. Secondly, to better organize subsequent queries. Information, new representative The entity node (parent node), and all its corresponding entities Connected (child nodes). The node will be responsible for recording geographic summary information, Index information, supplementary explanations, etc. The Large Language Model (LLM) is used to perform spatial geographic location and / or spatial geographic entity spatial geographic association, which includes spatial attribute association and semantic association. This embodiment can also utilize the Large Language Model (LLM) for each geographic location. A spatial community report based on the Ledian algorithm is generated, integrating related entity, relationship, and attribute data, and additionally summarizing information related to "spatial distribution" and "geographical extent," providing a concise and intuitive reference for subsequent scenario-based decision-making and in-depth insights. In some embodiments, spatial geographic locations and spatial geographic entities include spatial geographic information of point, line, and polygon types, where a point represents a spatial geographic location point, a line represents a linear set of spatial geographic location points, and a polygon represents a polygon set of spatial geographic location points.

[0031] S13. By associating and aggregating time entities with time attributes and spatial geographic entities with spatial attributes with triples in the knowledge source database, a spatiotemporal knowledge graph database is constructed. All spatiotemporal knowledge graphs constitute a spatiotemporal knowledge graph set. Its expression is as follows: , For a set of triples, A collection of time entities that include time attributes. This is a collection of spatial geographic entities containing spatial attributes (including grid matching coding information), relationships, and hierarchical relationships. All temporal entities in each block are sequentially associated according to their temporal attribute codes, and the spatial attribute codes of all spatial geographic entities in each block are spatially associated based on the BeiDou satellite geographic map. This embodiment relies on BeiDou grid coding to structurally represent different forms of spatial geographic entities at spatial geographic latitude. After the spatiotemporal knowledge graph is constructed, the geographic entities represented by the grid decomposition possess natural independence and geographic matching. Therefore, when data changes, this embodiment only needs to dynamically and incrementally update the information of the "part" of grid nodes corresponding to the "new data," without requiring a full reconstruction of the entire spatial geographic entity, ensuring the efficiency and accuracy of the graph update. For example, the information "A new purified water plant is being built upstream of River A" has a clear geographic orientation (specifically referring to the upstream area). In this invention, only the entity data in the "upstream part" of the River A associated geographic entity needs to be focused on and updated, recording "new purified water plant." Similarly, for the information "the green area of ​​Administrative Region B increased by 10% year-on-year", it is only necessary to update the green area data in the geographic entity referring to Administrative Region B.

[0032] S2. Use the Large Language Model (LLM) to semantically segment the input query data, extract factual statements from each segment, and extract query combinations from the factual statements that include triples, time entities, and spatial geographic entities.

[0033] S3. A spatiotemporal retrieval planner is used to create multiple parallel retrieval paths that match the query combinations. These paths include triplet retrieval, time retrieval, and spatial geographic retrieval. The results are then used to perform parallel searches in the spatiotemporal knowledge graph database and aggregated hierarchically. In some embodiments, such as... Figure 2 As shown, when a user queries (inputs query data), the Large Language Model (LLM) combined with prompt words is used to perform semantic understanding and intent recognition reasoning on the user's input query data. The Spatiotemporal Retrieval Planner (STRP) outputs a structured retrieval plan. If the user's query involves time or space dimensions, additional time retrieval and spatial geographic retrieval are performed on top of the triplet retrieval, thus forming a multi-parallel retrieval path that includes triplet retrieval, time retrieval, and spatial geographic retrieval. The Spatiotemporal Retrieval Planner (STRP) performs multi-parallel retrieval in the spatiotemporal knowledge graph database. Each retrieval path uses an independent retrieval module (triplet retrieval, time retrieval, spatial geographic retrieval). Then, in the result integration stage, the retrieval results of each path are aggregated and output in a structured manner.

[0034] In some embodiments, triplet retrieval utilizes triples in the query combination to create parallel retrieval tasks for entity retrieval, relation retrieval, and clustering retrieval. The entity retrieval task uses entities in the triples of the query combination as keywords for keyword retrieval; the relation retrieval task uses vector representations of entity relations in the triples of the query combination for similarity retrieval; and the clustering retrieval task clusters entities in the triples of the query combination into similar entities and retrieves results based on these clusters. Preferably, triplet retrieval also includes a multi-hop path retrieval task, which creates several entity hop neighborhoods centered on the entities in the triples of the query combination for retrieval. Time retrieval also includes a time multi-hop retrieval task, which creates several time entity multi-hop neighborhoods centered on the time entities in the query combination for retrieval. See also Figure 4 The system utilizes a Large Language Model (LLM) to refine and summarize the input query data, extracting query intent or necessary information (such as keywords, type, target, and scope). In triplet retrieval, keyword retrieval transforms input keywords into query vectors (Embeddings) and calculates vector similarity (cosine similarity) with graph entity elements. The results are sorted by similarity from high to low, returning the entities most semantically relevant to the input keywords. Relationship retrieval uses the vector representation of the question text for semantic similarity retrieval, retaining several relationships with similarity exceeding a predetermined threshold, and returning information including start and end entities, similarity scores, and relationship descriptions. Multi-hop path retrieval creates 1-3 entity hop neighborhoods centered on the entities in the query triplet combination. It can utilize relation weight multiplication and / or hop decay mechanisms to evaluate path relevance, capturing indirectly related entities and relationships. Each hop builds a new query based on the previous hop's result, overcoming the drawback of "direct recall" which easily misses related entities. This embodiment of triplet retrieval can also include type retrieval and community report retrieval. Type retrieval uses a linear combination function of entity type, entity importance weight (PageRank), and / or the number of entity relationships as the relevance scoring criterion, and returns several entities of the same type. Community report retrieval is based on entity clustering summaries generated by the Leiden community detection algorithm. It matches the communities to which the query entities belong and returns structured reports (including titles, summaries, and evidence) generated by LLM, providing the user's question with global context and high-level semantic information of the entity set.

[0035] In some embodiments, time retrieval utilizes time entities in the query combination to create time retrieval tasks and time inference retrieval tasks. The time retrieval task uses the time entities in the query combination as keywords for keyword retrieval, while the time inference retrieval task uses the time entities in the query combination to perform inference calculations for absolute time, relative time, and fuzzy time and then performs retrieval. The absolute time inference task is responsible for standardizing definite time points (such as "2025-12-4") into computable numerical representations. Through timestamp encoding and vector embedding techniques, it realizes time index construction and fast retrieval, providing support for precise time queries. The relative time inference task processes common relative time expressions in natural language (such as "three years ago" or "next quarter"). By identifying reference time anchors (such as "current absolute moment"), it performs time arithmetic operations to convert relative expressions into absolute time coordinates, enabling the system to understand context-based temporal descriptions. The fuzzy time inference task uses methods such as time interval mapping, probability distribution representation, and fuzzy logic inference to convert fuzzy expressions into queryable time ranges for imprecise time semantics (such as "late 1990s" or "spring"), effectively handling the problem of time uncertainty. Preferably, the time-based retrieval also includes a time event analysis module and a time trend analysis module. The time event analysis module is used to perform association analysis on the search results output by the time-based retrieval, analyzing the relationships between similar and related entities. For example, it answers explicit factual questions involving a specific "point in time" or "time range" (such as "fact summary" or "event explanation"). This satisfies the need for precise queries regarding "when, who, and what." The time trend analysis module is used to perform trend analysis on the search results output by the time-based retrieval, comparing the trends of similar and related entities. For example, it identifies the dynamic patterns and trend characteristics of entities and relationships evolving over time. This enables the mining of time-series patterns and summarizes time-series knowledge regarding "how things change, why they change, and future trends" (such as "stock market trends" or "global temperatures"). See also... Figure 5 It utilizes a large language model (LLM) to perform semantic understanding and reasoning analysis on the input query data, querying related time nodes (focusing on analyzing factors such as time logic, temporal relationships, and causal chains, and outputting time-related temporal information such as "keywords," "types," and "ranges"). The time retrieval module mainly consists of two parts: the first is the time information extraction stage, which includes the "time query rewriting" and "time retrieval" modules; the second is the time reasoning analysis stage, which includes the "time calculation and reasoning" and "tool call analysis" (time event analysis and time trend analysis) modules.

[0036] In some embodiments, spatial geographic retrieval utilizes spatial geographic entities in the query combination to create parallel retrieval tasks of spatial retrieval and spatial attribute retrieval of spatial geographic entities. Spatial retrieval uses spatial geographic entities in the query combination as keywords for keyword retrieval, and spatial attribute retrieval of spatial geographic entities uses the spatial attributes of spatial geographic entities in the query combination for retrieval. Preferably, spatial geographic retrieval also includes a spatial multi-hop retrieval task, which creates several spatial geographic entity multi-hop neighborhoods centered on the spatial geographic entities in the query combination for retrieval; for example, adding "spatial topological relationship constraints" (adjacency, containment, intersection, distance threshold), each hop retrieval must satisfy spatial logic rules. For example, when querying "supermarkets along the subway line around Science Park in City A", the first hop retrieves "subway stations" around "Science Park in City A" (adjacency relationship), and the second hop retrieves "supermarkets" along the line of "subway stations" (line relationship). The path relevance is evaluated through spatial relationship weight and hop count decay mechanism to capture indirectly related spatial entities and relationships. Triplet retrieval, time retrieval, and spatial geographic retrieval are executed in parallel. Layered weight parameters are set according to entity similarity in the query combination to label the retrieval tasks. The retrieval results output by triplet retrieval, time retrieval, and spatial geographic retrieval are summarized and layered. Spatial geographic retrieval also includes spatial attribute granular hierarchical retrieval and spatial attribute coding topology retrieval tasks. Spatial attribute granular hierarchical retrieval tasks search at upper and lower granular levels centered on the spatial attributes of spatial geographic entities. BeiDou grid hierarchical matching: Based on "user intent" and "spatial geographic type," LLM automatically determines and matches a suitable BeiDou grid level (coarse-grained for large-scale queries such as city-level planning, fine-grained for precise needs such as street-level facility searches), determines the initial grid level, and obtains (or calculates) the corresponding BeiDou grid code. Cross-granularity dynamic query: Relying on the natural "coarse-grained-fine-grained" hierarchical parent-child relationship of BeiDou grid coding, intelligent matching and dynamic scaling of retrieval granularity are achieved. The system dynamically drills down (narrowing the scope when there are too many results) or rolls up (expanding the scope when there are too few results) based on the number of query results, balancing efficiency and accuracy. For example, when querying "transportation hub planning of a certain city (city-level)," the system automatically selects level 4-6 (tens of kilometers / kilometers) to quickly locate entities within the city, avoiding redundant calculations. If further viewing of hub distribution in a specific district is required, it automatically drills down to level 7-8 (kilometers / hundreds of meters). When querying "distribution of emergency shelters in a certain street (fine-grained)," it directly matches level 9-10 (hundreds of meters / tens of meters) for precise retrieval; if the results are insufficient, it automatically rolls up to level 8 (kilometers) to expand the search scope and avoid omissions.

[0037] The spatial attribute coding topology retrieval task focuses on retrieving spatial topological relationships centered on the spatial attributes of spatial geographic entities. These relationships include spatial locational relationships such as inclusion, intersection, adjacency, and relative orientation, with spatial geographic entities as references. For example, relying on the rules of BeiDou grid coding (GB / T 39409-2020) such as "prefix association," "set matching," and "latitude and longitude binding," it directly determines the topological relationships (inclusion, intersection, adjacency) and relative and absolute orientations of "north, south, east, and west" between different entities, achieving rapid and accurate positioning and querying within spatial constraints. For instance, querying "drinking water source within 3 kilometers due east of a chemical plant" extracts the latitude / longitude code elements corresponding to the chemical plant's code, locks the range of three adjacent grids at the same level to the east, and directly filters the water source entities within that range. Spatial geographic retrieval also includes a spatial event analysis module and a spatial trend analysis module. The spatial event analysis module performs association analysis on the same and / or similar entities in the retrieval results, while the spatial trend analysis module performs trend analysis on the same entities and / or comparative trend analysis on similar entities in the retrieval results. The spatial geographic retrieval of this invention also includes type retrieval and spatial community report retrieval. Type retrieval requires matching related spatial entities of the same type (point, line, area, etc.). Spatial community report retrieval: matches the spatial community reports to which the spatial entity belongs and returns the Top-N related community reports (including summary information, spatial distribution, geographical range, list of related entities, etc.), providing regional global context and high-level semantic information, making up for the limitations of single entity retrieval.

[0038] In some embodiments, such as Figure 6As shown, the Large Language Model (LLM) is used to perform semantic understanding and reasoning analysis on the input query data. This mainly consists of four parts: "Spatial Query Rewriting" (building upon traditional query rewriting methods, it enhances the semantic understanding and constraint extraction of spatial dimensions. LLM analyzes the spatial logic, topological relationships, and directional descriptions of user queries, outputting spatial association "keywords," "types" (points / lines / areas), and "relationships" (surroundings, along lines, inclusion, intersection, etc.), "Spatial Retrieval," "BeiDou Grid Retrieval," and "Tool Call Analysis." Before spatial geographic retrieval, spatial attribute parsing and spatial topology parsing are performed. Spatial attribute parsing: LLM expands the dimensions of spatial attribute parsing, outputting a structured "spatial attribute constraint set." For example, if a user queries "hydropower stations surrounding ecological protection zones in southern mountainous areas below 500 meters above sea level," the parsed result will be attribute information such as "altitude ≤ 500," "administrative region = southern province," and "land type = ecological protection zone." Spatial topology parsing: aims to transform unstructured "spatial topological descriptions" from user natural language queries into structured "spatial topological constraints" through the logical reasoning and semantic understanding capabilities of LLM. Common topological constraints are as follows: Basic topological relationships: containment (e.g., "park within city A"), intersection (e.g., "road crossing an ecological protection zone"), adjacency (e.g., "street adjacent to area A"), etc. Orientation topological relationships: relative orientation (e.g., "industrial area east of a river"), absolute orientation (e.g., "power plant north of 30 degrees North latitude"); Distance topological relationships: precise distance (e.g., "service area within 5 kilometers of a highway exit"), fuzzy distance (e.g., "surrounding area of ​​a school", "near an airport").

[0039] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for retrieving entity spatiotemporal information and topological relationships based on spatiotemporal knowledge graphs, characterized in that: The methods include: S1. Construct a knowledge source database and perform spatiotemporal knowledge graph processing to obtain a spatiotemporal knowledge graph database. The spatiotemporal knowledge graph includes time entities, spatial geographic entities, and triples. S2. Use the Large Language Model (LLM) to semantically segment the input query data, extract factual statements from each segment, and extract query combinations that include triples, time entities, and spatial geographic entities from the factual statements. S3. Use the spatiotemporal retrieval planner to create multi-path parallel retrieval that matches the query combination. The multi-path parallel retrieval includes triplet retrieval, time retrieval and spatial geographic retrieval. Use the multi-path parallel retrieval to perform multi-path parallel searches in the spatiotemporal knowledge graph database and summarize and output the retrieval results in a hierarchical manner.

2. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 1, characterized in that: In method S1, the spatiotemporal knowledge graph database is obtained as follows: S11. Use the Large Language Model (LLM) to semantically segment the data in the knowledge source database, extract factual statements for each semantic segment, and extract triples, time entities, and spatial geographic entities from the factual statements. Triples contain entities and entity relationships. S12. Encode the time attributes of time entities; construct a gridded BeiDou satellite geographic map, and form a BeiDou grid coding dataset by matching the geographic codes of all grids in the BeiDou satellite geographic map with the associated grids. Use the BeiDou grid coding dataset to perform associated grid matching coding of spatial geographic entities to form the corresponding spatial attributes. S13. Associate and aggregate time entities with time attributes and spatial geographic entities with spatial attributes from the knowledge source database with triples to construct a spatiotemporal knowledge graph database.

3. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 1, characterized in that: In method S3, the triplet retrieval utilizes the triples in the query combination to create parallel retrieval tasks for entity retrieval, relation retrieval, and clustering retrieval. The entity retrieval task uses entities in the triples of the query combination as keywords for keyword retrieval. The relation retrieval task uses the entity relations in the triples of the query combination to perform similarity retrieval by vector representation. The clustering retrieval task uses entities in the triples of the query combination to perform clustering of similar entities and retrieves them according to the clustering results. The time retrieval utilizes the time entities in the query combination to create time retrieval tasks and time inference retrieval tasks. The time retrieval task uses the time entities in the query combination as keywords for keyword retrieval. The time inference retrieval task uses the time entities in the query combination to perform inference calculations for absolute time, relative time, and fuzzy time and retrieves them. The spatial geographic retrieval utilizes the spatial geographic entities in the query combination to create parallel retrieval tasks for spatial retrieval and spatial attribute retrieval of spatial geographic entities. The spatial retrieval task uses the spatial geographic entities in the query combination as keywords for keyword retrieval. The spatial attribute retrieval task retrieves the spatial attributes of the spatial geographic entities in the query combination.

4. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 3, characterized in that: The triplet retrieval also includes a multi-hop path retrieval task, which creates several entity hop neighborhoods centered on the entities in the triplet of the query combination for retrieval; the time retrieval also includes a time multi-hop retrieval task, which creates several time entity multi-hop neighborhoods centered on the time entities in the query combination for retrieval; the spatial geographic retrieval also includes a spatial multi-hop retrieval task, which creates several spatial geographic entity multi-hop neighborhoods centered on the spatial geographic entities in the query combination for retrieval; the triplet retrieval, time retrieval, and spatial geographic retrieval are executed in parallel, and the retrieval tasks are labeled according to the hierarchical weight parameters set according to the entity similarity in the query combination, and the retrieval results output by the triplet retrieval, time retrieval, and spatial geographic retrieval are summarized and hierarchically processed.

5. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 4, characterized in that: The time-based retrieval also includes a time event analysis module and a time trend analysis module. The time event analysis module is used to perform association analysis of the same or / and similar entities on the retrieval results output by the time-based retrieval. The time trend analysis module is used to perform trend analysis of the same entities and / or trend comparison analysis of similar entities on the retrieval results output by the time-based retrieval. The spatial geographic retrieval also includes spatial attribute granular hierarchical retrieval and spatial attribute encoding topology retrieval tasks. The spatial attribute granular hierarchical retrieval task performs granular hierarchical retrieval centered on the spatial attributes of spatial geographic entities. The spatial attribute encoding topology retrieval task performs spatial topology relationship retrieval centered on the spatial attributes of spatial geographic entities. Spatial topology relationships include spatial positional relationships including inclusion, intersection, adjacency, and relative orientation with spatial geographic entities as references. The spatial geographic retrieval also includes a spatial event analysis module and a spatial trend analysis module. The spatial event analysis module is used to perform association analysis of the same or / and similar entities on the retrieval results output by the spatial retrieval. The spatial trend analysis module is used to perform trend analysis of the same entities and / or trend comparison analysis of similar entities on the retrieval results output by the spatial retrieval.

6. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 2, characterized in that: In method S11, the block is described by extracting statements from the blocks. The function extracts a set of atomic fact statements. The expression is as follows: ,in For large language models, For semantic segmentation, To extract prompt words, in method S13, time entities containing time attributes are associated sequentially according to time attribute codes, and spatial geographic entities containing spatial attributes are associated spatially based on BeiDou satellite geographic maps.

7. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 2, characterized in that: In method S12, the time entity The encoding time attribute expression is as follows: , For entities Unique identifier Represents entity description information, For time type, , These represent the time start boundary, respectively; the spatial attribute expressions for spatial geographic entities are as follows: ,in For entities Unique identifier Represents entity description information, It is a spatial geographic type. This refers to the geographic coordinates (latitude, longitude, and altitude) corresponding to the entity. and These represent the BeiDou grid coding set and BeiDou grid level corresponding to spatial geographic entities, respectively.

8. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 2, characterized in that: Method S12 also includes the following methods: S121, Through Functions retrieve a set of spatially or geographically related geographic locations. ;pass Function to determine and obtain spatial geographic location Spatial geographic types and BeiDou grid hierarchy; obtaining spatial geographic locations The corresponding latitude, longitude and altitude data are combined with the BeiDou grid hierarchy to perform corresponding encoding of the BeiDou grid encoding set; S122, Constructing a spatial geographic location As a parent node, spatial geographic entity Spatial geographic association is performed as a child node.

9. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 2, characterized in that: The grid in the BeiDou satellite geographic map is divided into hierarchical levels based on spatial location resolution, and the BeiDou grid coding dataset is correspondingly divided into BeiDou grid levels belonging to different scales.

10. The entity spatiotemporal information and topological relationship retrieval method based on spatiotemporal knowledge graph according to claim 8, characterized in that: The spatial geographic locations and spatial geographic entities include spatial geographic information of types such as points, lines, and areas. A point represents a spatial geographic location point, a line represents a linear set of spatial geographic location points, and an area represents a planar set of spatial geographic location points.