Intelligent retrieval method and system for enterprise knowledge base based on AI

By constructing a query semantic graph and calculating the stability coefficient and contribution weight of semantic nodes, dominant nodes are selected, and a dynamic focusing window is constructed. This solves the problem of existing technologies being unable to understand the graph-like semantic structure of query statements, and improves the accuracy and efficiency of enterprise knowledge base retrieval.

CN122019756APending Publication Date: 2026-05-12HEILONGJIANG ZHENNING TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HEILONGJIANG ZHENNING TECH CO LTD
Filing Date
2026-01-29
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Existing technologies cannot effectively understand the inherent graph-like semantic structure of query statements, resulting in low retrieval accuracy in complex query scenarios, inability to dynamically adjust the retrieval focus, and inability to accurately focus on the user's core retrieval intent.

Method used

By deconstructing the query statement to generate a query semantic graph, calculating the stability coefficient of semantic nodes and the contribution weight of related nodes, selecting the set of dominant semantic nodes, constructing a dynamic focusing window, and reconstructing the core query statement, the core query statement is used to perform retrieval in the enterprise knowledge base.

Benefits of technology

It enables quantitative evaluation of the internal semantic structure of queries, dynamically identifies and focuses on the most stable semantic nodes, improves retrieval accuracy and precision in complex query scenarios, removes redundant embellishments and divergent intentions, and ensures that the retrieval target is refined.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122019756A_ABST
    Figure CN122019756A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of enterprise knowledge base intelligent retrieval, in particular to an AI-based enterprise knowledge base intelligent retrieval method and system, and the method comprises the steps: receiving an original query statement, and carrying out the structural deconstruction of the original query statement to generate a query semantic graph containing a plurality of semantic nodes; traversing the query semantic graph, calculating a stability coefficient of each semantic node and a contribution weight of an associated node, and screening out a dominant semantic node set according to the stability coefficient and the contribution weight; and constructing a dynamic focusing window according to the connection strength between the dominant nodes and the distribution discrete degree of the non-dominant nodes, and reconstructing the semantic structure of the original query by using the window to generate a core query statement. And performing retrieval in an enterprise knowledge base based on the core query statement and outputting a matching result. According to the method, the internal semantic structure can be deeply analyzed and queried, and the core retrieval intention is dynamically focused, so that the accuracy and efficiency of enterprise knowledge base retrieval are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent retrieval technology for enterprise knowledge bases, and in particular to an AI-based intelligent retrieval method and system for enterprise knowledge bases. Background Technology

[0002] In the field of intelligent retrieval of enterprise knowledge bases, existing technologies mainly revolve around keyword matching and semantic vector matching. Keyword matching technology relies on the apparent consistency between query terms and document terms, performing retrieval through Boolean logic or weighted calculations based on term frequency-inverse document frequency. Semantic vector matching technology, on the other hand, utilizes pre-trained language models to convert queries and documents into high-dimensional vectors, obtaining results by calculating the similarity between vectors. These two types of technologies constitute the current mainstream retrieval paradigm.

[0003] Existing technical solutions have shortcomings. Keyword matching methods completely fail to understand the semantics, synonym relationships, and contextual logic behind words, resulting in low accuracy of search results. While semantic vector matching technology can capture a certain degree of semantic association, it essentially encodes the entire query statement as a single, static vector representation. This approach ignores the rich structural information within the query statement and cannot distinguish the primary and secondary relationships, stability, and complex support or constraint networks between different semantic components. When faced with lengthy, ambiguous, or multi-sub-intent user queries, existing technologies either introduce noise due to keyword ambiguity or fail to accurately focus on the user's core and most stable search intent by treating the query as a chaotic semantic whole.

[0004] Current technologies lack the ability to perform deep, structured semantic deconstruction and analysis of query statements, and are even less capable of dynamically adjusting the focus of retrieval based on the unique internal semantic relationships of each query. The technical problem this invention aims to solve is how to break through the traditional approach of treating queries as a bag of words or a whole vector, and improve retrieval accuracy in complex query scenarios by parsing their inherent graph-like semantic structure and achieving intelligent semantic focusing based on the dynamic characteristics of this structure. Summary of the Invention

[0005] The purpose of this invention is to address the shortcomings of existing technologies by proposing an AI-based intelligent retrieval method and system for enterprise knowledge bases.

[0006] To achieve the above objectives, the present invention adopts the following technical solution: an intelligent retrieval method for an AI-based enterprise knowledge base, comprising: Receive the input raw query statement, destructure the raw query statement into a structured form, and generate a query semantic graph containing multiple semantic nodes; Traverse all semantic nodes in the semantic graph and calculate the stability coefficient of the semantic nodes and the contribution weight of the associated nodes. Based on the stability coefficient of semantic nodes and the contribution weight of associated nodes, the set of dominant semantic nodes is selected from the query semantic graph. Based on the connection strength between nodes in the dominant semantic node set and the degree of dispersion of the remaining nodes in the query semantic graph that were not selected into the dominant semantic node set, a dynamic focusing window for the query semantic graph is constructed. The semantic structure of the original query statement is reconstructed using a dynamic focus window to generate a core query statement with semantic focus. The system retrieves matching knowledge entries from the enterprise knowledge base based on the core query statement.

[0007] Preferably, the steps for constructing the query semantic graph include: The original query statement is segmented into words and tagged with parts of speech, and all entity words, action words and modifier words are identified and tagged. Each labeled word is used as an initial semantic node, and sequential connection edges are established between the initial semantic nodes based on the linear order of the words in the original query statement; Analyze the dependency syntactic relationships between words and establish dependency connection edges between initial semantic nodes with dependency relationships; By merging the sequential and dependency connections between the initial semantic nodes, a query semantic graph containing nodes and various types of connections is formed.

[0008] Preferably, the method for calculating the stability coefficient of semantic nodes is as follows: For each semantic node in the query semantic graph, count the number of all connecting edges that start or end with it, and use this count as the local connectivity of the semantic node. Analyze the part-of-speech category distribution of all connecting edges of the semantic node that point to or originate from other semantic nodes, and calculate the uniformity of the part-of-speech category distribution; The local connectivity of the semantic node is multiplied by the uniformity of the part-of-speech category distribution, and the product is used as the structural stability value of the semantic node. The variance of the occurrence probability of the semantic node in multiple pre-built general language models is calculated as the context stability value of the semantic node. The stability coefficient of a semantic node is obtained by adding its structural stability value to its contextual stability value.

[0009] Preferably, the method for calculating the contribution weight of the associated nodes is as follows: For any two semantic nodes in the query semantic graph that have a direct connection edge, they are defined as an associated node pair; Count the number of types of all direct connecting edges between the associated node pairs, and calculate the edge type richness of the associated node pairs; Find the shortest path length of the associated node pair in the query semantic graph, and calculate the reciprocal of the shortest path length as the path proximity. Multiply the edge type richness by the path proximity to obtain the original contribution value of each node in the associated node pair to the other node. For a target semantic node, the original contribution values ​​of all associated node pairs are normalized to obtain the contribution weight of each associated node relative to the target semantic node.

[0010] Preferably, the method for filtering the set of dominant semantic nodes from the query semantic graph is as follows: Set an initial stability coefficient threshold, and select all semantic nodes whose stability coefficient is greater than the initial stability coefficient threshold into the candidate node set; For each node in the candidate node set, calculate the sum of the contribution weights of all its associated nodes as the node's aggregate influence. The stability coefficient of each node in the candidate node set is multiplied by its aggregate influence to obtain the overall significance value of the node. Based on the distribution of the comprehensive significance values ​​of all candidate nodes, the final comprehensive significance value threshold is determined using an adaptive quantile method. Candidate nodes whose comprehensive significance value is greater than or equal to the final comprehensive significance value threshold are identified as dominant semantic nodes, and all dominant semantic nodes constitute the dominant semantic node set.

[0011] Preferably, the method for constructing the dynamic focusing window of the query semantic graph is as follows: Calculate the average weight of all connecting edges on the shortest path in the query semantic graph between each pair of nodes in the dominant semantic node set, and use it as the connection strength between each pair of nodes. Identify all semantic nodes in the query semantic graph that are not included in the dominant semantic node set, and calculate the standard deviation of the shortest path length between the unincluded semantic nodes and each node in the dominant semantic node set as a measure of the dispersion of the distribution; The average connection strength between all node pairs in the dominant semantic node set is weighted and fused with the measure of the dispersion of the distribution to generate a focus strength coefficient. With the dominant semantic node set as the core, the number of layers of neighboring nodes that need to be included in the focus range in the query semantic graph is dynamically determined according to the magnitude of the focus intensity coefficient. This delineates a subgraph structure that includes the core node and its specific range of neighboring nodes, and the subgraph structure is the dynamic focus window.

[0012] Preferably, the method for generating the semantically focused core query statement is as follows: Arrange all semantic nodes in the subgraph structure defined by the dynamic focus window according to the original word order in the original query statement; Check whether there are any words in the original query statement that are not included in the dynamic focus window between adjacent semantic nodes. If so, decide whether to insert them as conjunctions or modifiers based on the part of speech of the words and their syntactic relationship with the semantic nodes before and after them. Based on the type of connecting edges between nodes within the dynamic focus window, adjust the logical relationship between words in the generated statement and reconstruct the grammatical structure. Integrate all words after sequential arrangement, insertion of necessary words, and adjustment of grammatical structure to form a core query statement that is grammatically correct and semantically complete.

[0013] Preferably, the method for retrieving information from the enterprise knowledge base based on the core query statement is as follows: The core query statement is input into the semantic encoding model to obtain a high-dimensional semantic vector representation; Calculate the cosine similarity between the high-dimensional semantic vector and the pre-stored semantic vectors of all knowledge entries in the enterprise knowledge base; Sort all knowledge items in descending order based on cosine similarity; An adaptive similarity threshold related to the focus intensity coefficient of the dynamic focus window is set, and knowledge items with a cosine similarity greater than the adaptive similarity threshold are selected as the preliminary result set.

[0014] Preferably, after generating the preliminary result set, the method further includes: Extract the keyword set for each knowledge item in the preliminary results set; Calculate the Jaccard similarity coefficient between the core query and the keyword set of each knowledge entry; The cosine similarity of each knowledge item is weighted and harmonic averaged with its Jaccard similarity coefficient to obtain the final relevance score for each knowledge item. The knowledge items in the preliminary results set are reordered according to the final relevance score, and the sorted list is used as the final output of matching knowledge items.

[0015] Preferably, the present invention also includes an AI-based intelligent retrieval system for an enterprise knowledge base, the system including a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor executes the computer program to implement the steps of the AI-based intelligent retrieval method for an enterprise knowledge base as described above.

[0016] Compared with the prior art, the advantages and positive effects of the present invention are as follows: By structuring and deconstructing the original query statement to generate a query semantic graph, and calculating the stability coefficient of each semantic node in the graph and the contribution weight of its associated nodes, a quantitative evaluation of the internal semantic structure of the query is achieved. This technique can dynamically identify the dominant semantic nodes that are semantically most stable and have the highest support from other nodes in the graph, effectively filtering out those interfering nodes that appear but are semantically ambiguous, isolated, or have low support. Compared to conventional static keyword extraction or statistical weight allocation, this method achieves accurate extraction of the core skeleton of the query from the perspective of graph relationships, ensuring that the search intent is anchored on the set of concepts with the most solid semantics and the highest consensus, directly improving the accuracy of the search from the source of the semantic structure.

[0017] Based on the internal connection strength of the selected dominant semantic node set and the dispersion of the remaining nodes outside the set, a dynamic focusing window is constructed and the core query statement is reconstructed. Connection strength ensures the cohesion and integrity of the core semantics, avoiding fragmentation of the core intent; while the dispersion of external nodes quantifies the dispersion of secondary or interfering semantics, providing a basis for the reasonable delineation of the focusing scope. This makes the semantic reconstruction process no longer a fixed application of rules or blind expansion, but rather an adaptive semantic convergence and scope adjustment based on the unique graph topology of each query. This technique can effectively strip away redundant modifications and divergent intents in the original query, dynamically focusing the retrieval target on the refined semantic expression of the core entries most likely to match in the knowledge base, thus improving the precision of complex and lengthy queries. Attached Figure Description

[0018] Figure 1 This is a flowchart of the AI-based intelligent retrieval method for enterprise knowledge bases as described in this invention; Figure 2 A flowchart for constructing a query semantic graph; Figure 3 A flowchart for calculating the stability coefficient of semantic nodes; Figure 4 A combined analysis diagram of the performance of each stage in the entire process of intelligent retrieval of AI enterprise knowledge base; Figure 5 A quantitative analysis diagram of the dominant semantic node selection in AI enterprise knowledge base intelligent retrieval. Detailed Implementation

[0019] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0020] In the description of this invention, it should be understood that the terms "length," "width," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientation or positional relationships, are based on the orientation or positional relationships shown in the accompanying drawings and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, in the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0021] See Figure 1 An AI-based intelligent retrieval method for enterprise knowledge bases includes the following steps: receiving a user-inputted original query statement; destructuring the original query statement to generate a query semantic graph containing multiple semantic nodes; traversing all semantic nodes in the query semantic graph, calculating the stability coefficient of each semantic node and the contribution weight of its associated nodes; selecting a set of dominant semantic nodes from the query semantic graph based on the stability coefficient of the semantic nodes and the contribution weight of the associated nodes; constructing a dynamic focusing window for the query semantic graph based on the connection strength between nodes in the set of dominant semantic nodes and the distribution dispersion of the remaining nodes in the query semantic graph that were not selected into the set of dominant semantic nodes; reconstructing the semantic structure of the original query statement using the dynamic focusing window to generate a core query statement that has undergone semantic focusing; and finally, retrieving and outputting matching knowledge entries from the enterprise knowledge base based on the core query statement.

[0022] In one embodiment of the present invention, see [reference] Figure 2 Word segmentation and part-of-speech tagging of the original query statement are fundamental steps in constructing a query semantic graph. Given the original query statement "Please search for the sales report of new energy vehicles in East China in the third quarter of 2023", word segmentation yields a sequence of words ["please", "search", "2023", "third quarter", "East China", "new energy vehicles", "of", "sales report"]. Part-of-speech tagging is then performed on these words to identify and label entity words, action words, and modifiers. In some embodiments, after word segmentation and part-of-speech tagging, each tagged word is treated as an initial semantic node. Each initial semantic node contains the word text and its part-of-speech tag information. Based on the linear order of the words in the original query statement, sequential connections are established between adjacent initial semantic nodes. For example, a sequential connection is established between the initial semantic node "search" and the initial semantic node "2023", and another sequential connection is established between the initial semantic node "2023" and the initial semantic node "third quarter", thus forming a chain structure reflecting the original word order.

[0023] In specific implementation, analyzing the dependency syntactic relationships between words is the key to deepening semantic representation. Dependency syntactic analysis can reveal the grammatical relationships such as modification, verb-object, attributive-middle, etc. between words. For the same example query sentence "Please find the sales report of new energy vehicles in the East China region in the third quarter of 2023", dependency analysis may identify "find" as the core predicate, forming a verb-object relationship with "sales report", "2023" and "the third quarter" jointly modifying "sales report" to form a time attributive relationship, and "East China region" and "new energy vehicles" jointly modifying "sales report" through the "de" structure to form a possessive or attributive relationship. Dependency relationship connection edges are established between the initial semantic nodes with dependency relationships. For example, a dependency relationship connection edge of the type "verb-object relationship" is established between the initial semantic node "find" and the initial semantic node "sales report", a dependency relationship connection edge of the type "time modification" is established between the initial semantic node "2023" and the initial semantic node "sales report", a dependency relationship connection edge of the type "attributive-middle relationship" is established between the initial semantic node "East China region" and the initial semantic node "new energy vehicles", and another dependency relationship connection edge of the type "attributive-middle relationship" is established between the initial semantic node "new energy vehicles" and the initial semantic node "sales report". It can be understood that these dependency relationship connection edges and the previously established sequential connection edges jointly depict the semantic structure of the query sentence.

[0024] In specific implementation, the sequential connection edges and dependency relationship connection edges between the initial semantic nodes are fused to form a query semantic graph that includes nodes and various types of connection edges. The node set of this query semantic graph consists of all initial semantic nodes, and the connection edge set is the union of the sequential connection edges and the dependency relationship connection edges. Each connection edge records its type information and the identifiers of the two initial semantic nodes it connects. For example, there is both a sequential connection edge and a dependency relationship connection edge of the type "verb-object relationship" between the initial semantic node "find" and the initial semantic node "sales report", which indicates that in the query semantic graph, there can be multiple connection edges of different types or the same type between two nodes. In some embodiments, the query semantic graph is stored in memory in the form of a graph data structure, and the information of each initial semantic node and all the connection edges connected to it is recorded through an adjacency list or an adjacency matrix.至此,一个从原始文本转化而来、融合了表层顺序与深层语法关系的结构化语义表示即查询语义图构建完成,为后续的语义节点分析与筛选提供了直接的操作对象。

[0025] In one embodiment of the present invention, refer to Figure 3 需要注意的是,原文中“至此,一个从原始文本转化而来、融合了表层顺序与深层语法关系的结构化语义表示即查询语义图构建完成,为后续的语义节点分析与筛选提供了直接的操作对象。”这段话在英文翻译中没有完整对应,可能是原文表述有误,我按照英文逻辑进行了适当调整,你可根据实际情况进行检查。The stability coefficient of a semantic node is calculated by determining the local connectivity of each semantic node in the query semantic graph. For the semantic node "search", the number of all connecting edges originating from or ending with it is counted. In the example, the semantic node "search" may have a sequential connecting edge with the semantic node "2023" and a dependency connecting edge with the semantic node "sales report". Therefore, the local connectivity of the semantic node "search" is counted as 2. The part-of-speech (POS) distribution of other semantic nodes pointed to or originating from by all connecting edges of the semantic node "search" is analyzed. Connecting edges may point to the noun "sales report" and the noun "2023". In this case, the POS category is noun. The calculation of the distribution uniformity needs to measure the degree of concentration or dispersion of the distribution. The structural stability value of a semantic node is obtained by multiplying the local connectivity by the POS distribution uniformity. For example, if the local connectivity of the semantic node "search" is 2, and the POS distribution uniformity of its connected nodes is calculated to be 0.8, then the structural stability value of the semantic node "search" is 1.6.

[0026] In some embodiments, calculating the contextual stability value of a semantic node involves querying the probability of the semantic node's occurrence in multiple pre-built general language models. For example, the probability values ​​of the semantic node "new energy vehicles" in similar contexts under different models such as BERT and GPT are obtained as 0.05, 0.06, and 0.04, respectively. The variance of these three probability values ​​is then calculated as the contextual stability value of the semantic node "new energy vehicles". The stability coefficient of a semantic node is obtained by adding its structural stability value to its contextual stability value. Assuming the structural stability value of the semantic node "new energy vehicles" is 2.1 and its contextual stability value is 0.0002, then the stability coefficient of the semantic node "new energy vehicles" is 2.1002. It can be understood that this process iterates through all semantic nodes in the query semantic graph, generating a quantified stability coefficient for each semantic node.

[0027] In practice, calculating the contribution weight of associated nodes first requires identifying any two semantic nodes in the query semantic graph that have a direct connection edge and defining them as an associated node pair. For example, semantic nodes "East China" and "New Energy Vehicles" have a direct "fixed-center relationship" dependency edge, thus forming an associated node pair. The number of all types of direct connection edges between the associated node pairs is counted to calculate edge type richness. If there is only one "fixed-center relationship" edge between "East China" and "New Energy Vehicles," the edge type richness is 1; if both sequential and dependency edges exist between the two nodes, the edge type richness is greater than 1. The shortest path length of the associated node pair in the query semantic graph is found. For two nodes with a direct connection edge, the shortest path length is usually 1, and its reciprocal, the path proximity, is also 1. The edge type richness is multiplied by the path proximity to obtain the original contribution value of each node in the associated node pair to the other node.

[0028] Optionally, for a target semantic node, such as the semantic node "sales report", it is necessary to find all other semantic nodes in the query semantic graph that have direct connections to the semantic node "sales report", forming multiple associated node pairs. The original contribution value of the semantic node "sales report" in each associated node pair is calculated. The original contribution values ​​of all associated node pairs with the target semantic node "sales report" are summed, and then each original contribution value is divided by the sum and normalized to obtain the contribution weight of each associated node relative to the target semantic node "sales report". In some embodiments, the uniformity of the part-of-speech category distribution... It can be calculated using the following formula:

[0029] in: This indicates that among all edges connected to the target semantic node, the one that points to or originates from the first semantic node is the one that... The proportion of edges belonging to nodes with word-class attributes. This indicates the total number of different parts of speech that appear. The base of the logarithm is H, and the uniformity H ranges between 0 and 1.

[0030] In one embodiment of the present invention, an initial stability coefficient threshold is set as the starting point of the screening process. The initial stability coefficient threshold is a preset numerical parameter used for the initial screening. For example, the initial stability coefficient threshold is set to 2.0. After the stability coefficients of all semantic nodes in the query semantic graph are calculated, all semantic nodes with stability coefficients greater than the initial stability coefficient threshold are selected into the candidate node set. Assuming that the stability coefficient of the semantic node "search" is 1.9, the stability coefficient of the semantic node "sales report" is 2.5, and the stability coefficient of the semantic node "new energy vehicle" is 2.1, then the semantic node "search" will not be selected, while the semantic nodes "sales report" and "new energy vehicle" will enter the candidate node set, which at this time contains these two nodes. For each node in the candidate node set, the sum of the contribution weights of all its associated nodes needs to be calculated as the node's aggregate influence. For example, for the candidate node "Sales Report", it has associated nodes "Search", "2023", "Third Quarter", "East China Region", and "New Energy Vehicles" in the query semantic graph. Assuming that the contribution weights of these associated nodes relative to "Sales Report" are 0.3, 0.1, 0.1, 0.1, and 0.4 respectively, the aggregate influence of the semantic node "Sales Report" is the sum of these contribution weights, which is 1.0.

[0031] In some embodiments, the comprehensive significance value of a node is obtained by multiplying its stability coefficient by its aggregation influence. For example, the candidate node "Sales Report" has a stability coefficient of 2.5 and an aggregation influence of 1.0, resulting in a comprehensive significance value of 2.5. The candidate node "New Energy Vehicle" has a stability coefficient of 2.1, and its aggregation influence, assuming the sum of the contribution weights of its associated nodes is 0.8, results in a comprehensive significance value of 1.68. In this case, the comprehensive significance values ​​of all nodes within the candidate node set constitute a numerical set. Based on the distribution of the comprehensive significance values ​​of all candidate nodes, an adaptive quantile method is used to determine the final comprehensive significance value threshold. This adaptive quantile method dynamically adjusts the quantiles according to the statistical characteristics of the numerical set. Optionally, one calculation method for the adaptive quantile method is as follows:

[0032] in: This represents the final comprehensive significance threshold. Indicates in The value at the quantile, Indicates in The value at the quantile, It is a basic quantile parameter. It is a fluctuation range parameter. It is an adjustment coefficient between 0 and 1, whose value is determined by the coefficient of variation of the comprehensive saliency set of candidate nodes. It can be understood that this formula, by combining information from the upper and lower quantiles and introducing an adjustment based on the degree of data dispersion, can adapt to the numerical distribution characteristics of different queries and calculate an adaptive filtering threshold.

[0033] In practice, candidate nodes whose comprehensive significance value is greater than or equal to the final comprehensive significance value threshold are identified as dominant semantic nodes. It is assumed that the final comprehensive significance value threshold is calculated using the adaptive quantile method. If the overall significance value is 2.0, then the candidate node "Sales Report" with a comprehensive significance value of 2.5 will be determined as the dominant semantic node, while the candidate node "New Energy Vehicle" with a comprehensive significance value of 1.68 will not be determined as the dominant semantic node. All nodes determined as dominant semantic nodes constitute the dominant semantic node set. In some embodiments, the number of nodes in the dominant semantic node set can be one or more, depending on the stability and influence distribution of nodes in the specific query semantic graph. If the comprehensive significance value of all candidate nodes is lower than the final comprehensive significance value threshold, the dominant semantic node set may be empty. In this case, it is necessary to return and adjust the initial stability coefficient threshold or related calculation parameters.

[0034] In one embodiment of the present invention, the average weight of all connecting edges on the shortest path in the query semantic graph between each pair of nodes in the dominant semantic node set is calculated as the connection strength between each pair of nodes. The dominant semantic node set may only contain the node "Sales Report," therefore there are no node pairs, and the connection strength calculation step is omitted. If the dominant semantic node set contains two nodes, "Sales Report" and "Search," then the shortest path between these two nodes in the query semantic graph needs to be calculated. Assuming the shortest path is "Search" -> "Sales Report," and the path contains only one connecting edge, if the weight of this connecting edge is 0.9, then the connection strength between this pair of nodes is 0.9. All semantic nodes in the query semantic graph not included in the dominant semantic node set are identified. These nodes can be called non-dominant nodes, such as nodes like "2023," "Third Quarter," "East China," "New Energy Vehicles," and "of." The shortest path length between each non-dominant node and each node in the dominant semantic node set is calculated. Refer to Table 1, which shows a hypothetical calculation example.

[0035] Table 1: Shortest path length from non-dominant nodes to dominant semantic nodes Non-dominant nodes Shortest path length to node "Sales Report" The shortest path length to the node "search" 2023 1 2 Third quarter 1 2 East China 2 3 New energy vehicles 1 2 of 1 2 In some embodiments, calculating the measure of distribution dispersion requires calculating the standard deviation of the shortest path length from each non-dominant node to all nodes in the dominant semantic node set. For example, for the non-dominant node "East China," its shortest path lengths to "Sales Report" and "Search" are 2 and 3 respectively, with an average of 2.5 and a standard deviation of approximately 0.71. The average of the standard deviations of all non-dominant nodes is then used as a measure of overall distribution dispersion, reflecting the distribution of non-dominant nodes around the dominant node. The average connection strength between all node pairs in the dominant semantic node set is weighted and fused with the distribution dispersion measure to generate a focus strength coefficient. The average connection strength is denoted as... The measure of the dispersion of the distribution is denoted as The weighted fusion formula is:

[0036] in: Indicates the focus intensity coefficient. It is a preset weighting factor between 0 and 1, in the formula The degree of dispersion of the distribution is transformed into an inverse proportional measure, such that the value decreases as the degree of dispersion increases.

[0037] In practice, the set of dominant semantic nodes is used as the core, and the number of layers of neighboring nodes that need to be additionally included in the focus range in the query semantic graph is dynamically determined based on the magnitude of the focus strength coefficient. The larger it is, the more concentrated the focus range should be, and the fewer layers of neighbor nodes that need to be additionally included The fewer; A method for determining the number of layers The mapping relationship is as follows:

[0038] Where: is a preset maximum expansion layer constant represents rounding up, thus delimiting a subgraph structure that includes the core node and its neighbor nodes within a specific range. This subgraph structure is the dynamic focus window. Arrange all the semantic nodes in the subgraph structure delimited by the dynamic focus window in the order of their original words in the original query statement. Suppose the dynamic focus window includes nodes such as "search", "sales report", "2023", and "third quarter", and the original word order is "search", "2023", "third quarter", "sales report", then arrange them in this order. Check whether there are words in the original query statement that are not included in the dynamic focus window between adjacent semantic nodes. For example, there is a word "of" between "third quarter" and "sales report". Since "of" is not included in the window, it is necessary to decide whether to insert it according to the词性 of the word "of" and its syntactic relationship with the front and back semantic nodes. As a structural particle, the word "of" usually needs to be inserted to maintain grammatical integrity. It can be understood that according to the type of connection edges between nodes in the dynamic focus window, it is necessary to adjust the logical relationship expression between words in the generated statement and reconstruct the grammatical structure. For example, if there is a "time modification" dependency edge between nodes, time prepositions may need to be added or clarified during reconstruction. In some embodiments, integrate all the words after sequential arrangement, necessary word insertion, and grammatical structure adjustment to form a core query statement with smooth grammar and complete semantics. For example, it may generate "Search for the sales report in the third quarter of 2023". The nodes "East China region" and "new energy vehicles" outside the dynamic focus window are not reflected in this core query statement, thus achieving semantic focus

[0039] Refer to Figure 4 , which is a combined analysis chart of the performance of each stage of the intelligent retrieval process of the AI enterprise knowledge base. Overall, it shows a trend of "increasing accuracy and decreasing response time", indicating that while this method improves the accuracy, it also reduces redundant calculations by focusing on the core semantics and achieves efficiency optimization. "Dominant node screening" and "focus window construction" are the key stages for the significant increase in accuracy, which verifies the effectiveness of the dynamic focus mechanism in improving the retrieval quality. The response time fluctuates in the early stage and then tends to be stable, indicating that the algorithm can quickly converge after complex calculation stages and the overall performance is stable. The accuracy continues to rise, directly verifying the rationality of the technical path of "semantic graph construction → dominant node screening → dynamic focus window → core query generation", and proving that the dynamic focus mechanism can indeed effectively improve the retrieval accuracy

[0040] In one embodiment of the present invention, the core query statement is input into a semantic encoding model to obtain a high-dimensional semantic vector representation. The semantic encoding model maps the text sequence into a fixed-dimensional real-number vector. The cosine similarity between the high-dimensional semantic vector and the pre-stored semantic vectors of all knowledge entries in the enterprise knowledge base is calculated. The cosine similarity measures the closeness of the vectors in spatial direction. All knowledge entries are sorted in descending order based on the cosine similarity, with knowledge entries having higher similarity appearing at the top of the list. An adaptive similarity threshold related to the focus intensity coefficient of the dynamic focus window is set, and knowledge entries with cosine similarity greater than the adaptive similarity threshold are selected as the initial result set. The adaptive similarity threshold is dynamically adjusted according to the semantic focus of the query. In some embodiments, the semantic encoding model adopts a dual-tower structure based on a deep neural network. The core query statement and enterprise knowledge base entries are respectively generated into vector representations by an encoder. The pre-stored semantic vectors of the enterprise knowledge base have been indexed offline to support efficient similarity retrieval.

[0041] In practical implementation, the construction of the semantic encoding model begins with the selection and design of the model architecture. A dual-tower model structure based on the Transformer architecture is adopted as the foundation. One tower encodes the query statement, and the other tower encodes knowledge base entries. The two towers share the same parameters to achieve a unified semantic mapping of the text. The model's output layer aggregates variable-length text sequences into a fixed-dimensional high-dimensional semantic vector. Domain-specific corpus data is prepared for model training. Raw text data is collected from internal enterprise documents, reports, emails, product manuals, and FAQs. The raw text data is cleaned to remove irrelevant symbols and formatting errors, and word segmentation and sub-word partitioning are performed. When constructing training sample pairs, semantically related text fragments are combined into positive sample pairs, such as the title and summary paragraphs of the same document, or different expressions addressing the same question. Semantically unrelated text pairs are generated as negative samples through random replacement, sampling fragments from documents on different topics, or using back-translation techniques.

[0042] In the specific implementation, the keyword set for each knowledge item in the preliminary result set is extracted. The keyword set is constructed by segmenting the full text of the knowledge item, filtering by part-of-speech, and retaining core terms such as nouns and verbs. The Jaccard similarity coefficient between the core query and the keyword set of each knowledge item is calculated. The Jaccard similarity coefficient is obtained by dividing the intersection of the two sets by the union. The keyword set for the core query needs to be extracted from the core query text using the same method. The cosine similarity of each knowledge item and its Jaccard similarity coefficient are then weighted and averaged to obtain the final relevance score for each knowledge item. The weighted harmonic average integrates semantic and lexical matching information. The formula for calculating the weighted harmonic average is:

[0043] in: This represents the final relevance score. Represents cosine similarity. The Jaccard similarity coefficient is represented by the coefficient of similarity. This is a non-negative weighting parameter used to adjust the contribution ratio of the two similarities in the calculation. It can be understood that the knowledge items in the preliminary result set are reordered according to the final relevance score, and the reordered list is used as the final output of matching knowledge items. This reordering changes the initial order that relied solely on cosine similarity.

[0044] In some embodiments, the adaptive similarity threshold can be calculated using linear interpolation based on the focus intensity coefficient. For example, a lower and upper limit can be set for the threshold; the larger the focus intensity coefficient, the closer the threshold is to the upper limit, thus allowing queries with high semantic focus to correspond to stricter filtering conditions. Optionally, the calculation of the Jaccard similarity coefficient can ignore the order and repetition of terms, based solely on the comparison of unique terms. Common stop words should be removed when extracting the keyword set of the core query to improve calculation efficiency. After sorting by the final relevance score in descending order, the final output list of matched knowledge items can include a preset number of top results or all items with scores exceeding a certain benchmark value. It can be understood that the weight parameters in the weighted harmonic average... Pre-training or manual settings are required based on the domain characteristics of the enterprise knowledge base to optimize the relevance of search results.

[0045] See Figure 5 This is a quantitative analysis chart used for selecting dominant semantic nodes in AI-powered enterprise knowledge base intelligent retrieval. It visually displays the distribution of the stability coefficient, aggregation influence, and comprehensive significance value of 12 semantic nodes. The comprehensive significance value is not determined by a single indicator. For example, node 3 has a low stability coefficient, but due to its extremely high aggregation influence, it still achieves a high comprehensive significance value; node 6 has a high stability coefficient, but its aggregation influence is relatively low, resulting in a comprehensive significance value at a moderate level. The significant differences in comprehensive significance values ​​among different nodes provide a data foundation for determining thresholds using the adaptive quantile method, effectively distinguishing between "dominant nodes" and "non-dominant nodes." This chart quantifies the importance of semantic nodes, providing a clear basis for constructing dynamic focusing windows and is a crucial step in ensuring the accuracy of subsequent semantic focusing and core query generation.

[0046] The above are merely preferred embodiments of the present invention and are not intended to limit the present invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments that can be applied to other fields. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.

Claims

1. An AI-based intelligent retrieval method for enterprise knowledge bases, characterized in that, include: Receive the input raw query statement, destructure the raw query statement into a structured form, and generate a query semantic graph containing multiple semantic nodes; Traverse all semantic nodes in the semantic graph and calculate the stability coefficient of the semantic nodes and the contribution weight of the associated nodes. Based on the stability coefficient of semantic nodes and the contribution weight of associated nodes, the set of dominant semantic nodes is selected from the query semantic graph. Based on the connection strength between nodes in the dominant semantic node set and the degree of dispersion of the remaining nodes in the query semantic graph that were not selected into the dominant semantic node set, a dynamic focusing window for the query semantic graph is constructed. The semantic structure of the original query statement is reconstructed using a dynamic focus window to generate a core query statement with semantic focus. The system retrieves matching knowledge entries from the enterprise knowledge base based on the core query statement.

2. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 1, characterized in that, The steps for constructing the query semantic graph include: The original query statement is segmented into words and tagged with parts of speech, and all entity words, action words and modifier words are identified and tagged. Each labeled word is used as an initial semantic node, and sequential connection edges are established between the initial semantic nodes based on the linear order of the words in the original query statement; Analyze the dependency syntactic relationships between words and establish dependency connection edges between initial semantic nodes with dependency relationships; By merging the sequential and dependency connections between the initial semantic nodes, a query semantic graph containing nodes and various types of connections is formed.

3. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 2, characterized in that, The method for calculating the stability coefficient of semantic nodes is as follows: For each semantic node in the query semantic graph, count the number of all connecting edges that start or end with it, and use this count as the local connectivity of the semantic node. Analyze the part-of-speech category distribution of all connecting edges of the semantic node that point to or originate from other semantic nodes, and calculate the uniformity of the part-of-speech category distribution; The local connectivity of the semantic node is multiplied by the uniformity of the part-of-speech category distribution, and the product is used as the structural stability value of the semantic node. The variance of the occurrence probability of the semantic node in multiple pre-built general language models is calculated as the context stability value of the semantic node. The stability coefficient of a semantic node is obtained by adding its structural stability value to its contextual stability value.

4. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 3, characterized in that, The method for calculating the contribution weight of the associated nodes is as follows: For any two semantic nodes in the query semantic graph that have a direct connection edge, they are defined as an associated node pair; Count the number of types of all direct connecting edges between the associated node pairs, and calculate the edge type richness of the associated node pairs; Find the shortest path length of the associated node pair in the query semantic graph, and calculate the reciprocal of the shortest path length as the path proximity. Multiply the edge type richness by the path proximity to obtain the original contribution value of each node in the associated node pair to the other node. For a target semantic node, the original contribution values ​​of all associated node pairs are normalized to obtain the contribution weight of each associated node relative to the target semantic node.

5. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 4, characterized in that, The method for filtering the set of dominant semantic nodes from the query semantic graph is as follows: Set an initial stability coefficient threshold, and select all semantic nodes whose stability coefficient is greater than the initial stability coefficient threshold into the candidate node set; For each node in the candidate node set, calculate the sum of the contribution weights of all its associated nodes as the node's aggregate influence. The stability coefficient of each node in the candidate node set is multiplied by its aggregate influence to obtain the overall significance value of the node. Based on the distribution of the comprehensive significance values ​​of all candidate nodes, the final comprehensive significance value threshold is determined using an adaptive quantile method. Candidate nodes whose comprehensive significance value is greater than or equal to the final comprehensive significance value threshold are identified as dominant semantic nodes, and all dominant semantic nodes constitute the dominant semantic node set.

6. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 5, characterized in that, The method for constructing the dynamic focusing window of the query semantic graph is as follows: Calculate the average weight of all connecting edges on the shortest path in the query semantic graph between each pair of nodes in the dominant semantic node set, and use it as the connection strength between each pair of nodes. Identify all semantic nodes in the query semantic graph that are not included in the dominant semantic node set, and calculate the standard deviation of the shortest path length between the unincluded semantic nodes and each node in the dominant semantic node set as a measure of the dispersion of the distribution; The average connection strength between all node pairs in the dominant semantic node set is weighted and fused with the measure of the dispersion of the distribution to generate a focus strength coefficient. With the dominant semantic node set as the core, the number of layers of neighboring nodes that need to be included in the focus range in the query semantic graph is dynamically determined according to the magnitude of the focus intensity coefficient. This delineates a subgraph structure that includes the core node and its specific range of neighboring nodes, which is the dynamic focus window.

7. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 6, characterized in that, The method for generating semantically focused core query statements is as follows: Arrange all semantic nodes in the subgraph structure defined by the dynamic focus window according to the original word order in the original query statement; Check whether there are any words in the original query statement that are not included in the dynamic focus window between adjacent semantic nodes. If so, decide whether to insert them as conjunctions or modifiers based on the part of speech of the words and their syntactic relationship with the semantic nodes before and after them. Based on the type of connecting edges between nodes within the dynamic focus window, adjust the logical relationship between words in the generated statement and reconstruct the grammatical structure. Integrate all words after sequential arrangement, insertion of necessary words, and adjustment of grammatical structure to form a core query statement that is grammatically correct and semantically complete.

8. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 7, characterized in that, The method for retrieving information from the enterprise knowledge base based on core query statements is as follows: The core query statement is input into the semantic encoding model to obtain a high-dimensional semantic vector representation; Calculate the cosine similarity between the high-dimensional semantic vector and the pre-stored semantic vectors of all knowledge entries in the enterprise knowledge base; Sort all knowledge items in descending order based on cosine similarity; An adaptive similarity threshold related to the focus intensity coefficient of the dynamic focus window is set, and knowledge items with a cosine similarity greater than the adaptive similarity threshold are selected as the preliminary result set.

9. The intelligent retrieval method for an AI-based enterprise knowledge base as described in claim 8, characterized in that, After generating the preliminary result set, the process also includes: Extract the keyword set for each knowledge item in the preliminary results set; Calculate the Jaccard similarity coefficient between the core query and the keyword set of each knowledge entry; The cosine similarity of each knowledge item is weighted and harmonic averaged with its Jaccard similarity coefficient to obtain the final relevance score for each knowledge item. The knowledge items in the preliminary results set are reordered according to the final relevance score, and the sorted list is used as the final output of matching knowledge items.

10. An AI-based intelligent retrieval system for an enterprise knowledge base, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the intelligent retrieval method for an AI-based enterprise knowledge base as described in any one of claims 1 to 9.