Intelligent index positioning method and system for large-scale macro database
Patent Information
- Application Number
- CN202611032409.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-13
- Publication Date
- 2026-08-18
AI Technical Summary
[0011]本发明的目的在于克服现有技术中存在的问题:1.现有通用检索系统未针对宏观指标N级分层命名格式进行优化,导致结构化命名格式的语义信息未被充分利用;2.现有编辑距离模糊匹配方法在大规模数据集下遍历全部指标,计算复杂度过高;3.现有检索系统无法根据实时用户反馈动态调整检索策略;4.现有方案无法同时支持精确查询、模糊查询、语义查询和复合查询的混合检索,提供了一种面向大规模宏观数据库的智能指标定位方法及系统
1.本发明通过针对宏观指标N级分层命名格式的自适应差异化语义向量生成方法,系统支持3级基础格式、4级深层嵌套、5级地域细分乃至6级超深层嵌套的任意分层深度。核心指标名层级在向量空间中具有最高区分度,且权重分配随层级深度自动调整。实验表明,3-4级精确格式查询的Top-1准确率为100%,6级超深层查询亦实现精确命中。在200查询大规模测试中,相比最强基线BM25-Only(Top-1 79%),本系统的Top-1准确率达到80%,提升1个百分点;相比无角色向量检索基线(NoRole-Vector,Top-1 7%),层级角色加权策略带来73个百分点的Top-1准确率提升,证明了差异化向量生成机制的决定性作用。需要说明的是,BM25-Only在精确查询上表现较强是因为测试集中精确查询占比20%(40条),BM25对结构化命名格式的精确关键词匹配具有天然优势;但在模糊查询、语义查询和拼写错误查询等复杂场景下,本系统相比BM25-Only的优势更为显著。通用搜索引擎不会预设"中间层级权重最高,向两端衰减"的自适应规则,更不会针对"国家:省份:指标大类:指标子类:地区:属性"这类深层嵌套结构设计专用权重策略,这是宏观指标特有的业务逻辑转化为技术参数的体现。
Smart Images

Figure CN122594482A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data retrieval technology, and in particular to an intelligent indicator positioning method and system for large-scale macro databases. Background Technology
[0002] With the advent of the digital economy era, the scale of macroeconomic data is growing exponentially. Taking the macroeconomic indicators released by institutions such as the National Bureau of Statistics, the People's Bank of China, and the General Administration of Customs as examples, there are currently more than tens of thousands of publicly available macroeconomic indicators, covering more than ten major categories such as national economic accounting, price indices, monetary and financial data, and foreign trade.
[0003] Macroeconomic indicator databases possess unique data characteristics that distinguish them from general text databases. Indicator naming typically employs an N-level hierarchical naming format, such as "Country:Indicator Name:Attribute" (e.g., "China:GDP:Year-on-Year", "US:CPI:Month-on-Month", "Japan:PMI:Current Month Value"). This structured naming format implies a clear semantic hierarchy: indicator names use a colon-separated multi-level hierarchical structure (e.g., "China:General Public Budget Expenditure:Education Expenditure:Year-on-Year", "US:Imports and Exports:Mechanical and Electrical Products:USD Denominated"), with different levels carrying different semantic roles—the middle level is usually the core indicator name, followed by outer levels for geographical, attribute, and time-related limitations. However, existing general retrieval systems have not optimized for this structured feature, resulting in low retrieval efficiency. The main technical deficiencies are as follows: 1. Existing exact string matching methods (such as exact hash table matching) are fast, but they cannot handle fuzzy queries, aliases, and abbreviations. They cannot retrieve results when there are slight differences between the user's input query and the indicator name.
[0004] 2. Existing edit distance matching methods (such as Levenshtein distance calculation) can handle spelling differences, but their computational complexity is O(m×n). In large-scale datasets (tens of thousands of data points), it is necessary to traverse all indicators, which leads to a surge in computational overhead and cannot capture the semantic hierarchical relationship between indicators.
[0005] 3. Existing TF-IDF / BM25 keyword retrieval methods are based on term frequency-inverse document frequency scoring, which works well for general text, but are not optimized for structured naming terms in the macroeconomic field. Traditional full-text search engines (such as Elasticsearch) use inverted indexes plus TF-IDF / BM25 keyword retrieval methods, which have limited support for domain aliases and abbreviations.
[0006] 4. Existing vector semantic retrieval methods based on pre-trained language models such as BERT can capture semantic similarity, but they require a large amount of training data, have high inference latency, high deployment costs, and do not design differentiated vector generation mechanisms for the structured naming format of macro indicators.
[0007] Furthermore, CN112364130A discloses a text sampling method that uses character encoding for text vectorization and edit distance to calculate text distance. However, this technical solution only uses two methods: edit distance and character encoding. It does not involve multi-level hybrid strategies such as BM25 keyword matching, semantic vector retrieval, and semantic reordering. It also does not disclose a differentiated vector generation mechanism for structured naming formats, a dual-path recall gating mechanism, or closed-loop control based on user feedback.
[0008] CN112329427A discloses a method for obtaining SMS samples, which employs multiple deduplication methods and uses SMS templates combined with features such as SMS source time for similarity measurement. However, this technical solution, designed for SMS deduplication scenarios, does not address the retrieval of macroeconomic indicators, nor does it disclose a differentiated weighted vector generation mechanism for structured naming, a dual-path recall gating mechanism, or closed-loop control based on user feedback.
[0009] CN115221281A discloses an intellectual property retrieval system that uses a context encoder with an embedding layer to generate full-text feature vectors, extracts key data to generate key field feature vectors, and performs classification matching through a classifier. However, this technical solution uses a deep learning model, which requires a large amount of training data and high computing resources. It does not disclose an adaptive hierarchical role recognition and dynamic weight allocation mechanism for N-level hierarchical naming of macro indicators, nor does it disclose a differentiated weighted vector generation mechanism for structured naming, a dual-path recall gating mechanism, or closed-loop control based on user feedback.
[0010] Therefore, there is an urgent need for an intelligent indicator positioning technology that can fully utilize the structured naming features of macro indicators, balance retrieval accuracy and computational efficiency, and adaptively adjust based on user feedback. Summary of the Invention
[0011] The purpose of this invention is to overcome the problems existing in the prior art: 1. Existing general retrieval systems are not optimized for the N-level hierarchical naming format of macro indicators, resulting in the insufficient utilization of the semantic information of the structured naming format; 2. Existing edit distance fuzzy matching methods traverse all indicators in large-scale datasets, resulting in excessively high computational complexity; 3. Existing retrieval systems cannot dynamically adjust retrieval strategies based on real-time user feedback; 4. Existing solutions cannot simultaneously support mixed retrieval of precise queries, fuzzy queries, semantic queries, and compound queries. This invention provides an intelligent indicator positioning method and system for large-scale macro databases.
[0012] The objective of this invention is achieved through the following technical solution: A first aspect of the present invention provides an intelligent indicator positioning method for large-scale macro databases, comprising the following steps: S1. Query Intent Recognition: Obtain the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text; S2. Vector Semantic Retrieval: The query text is parsed according to the N-level hierarchical naming structure. The hierarchical role classifier is applied to automatically identify the role at each level and assign differentiated weights to generate query vectors. Batch cosine similarity is calculated with the indicator vector library to recall the first candidate set. S3.BM25 Keyword Search: Perform BM25 keyword search on the query text to recall the second candidate set; S4. Dual-path recall gating decision retrieval: Calculate the intersection and union size of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, perform edit distance fuzzy matching within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set. When the intersection size does not reach the preset threshold and the union size is within a preset condition, perform semantic reordering within the union range to obtain a fallback candidate set. S5. Fusion Ranking: Based on the retrieval scores and corresponding weight coefficients of the candidate set indicators obtained from dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, a weighted fusion ranking is performed, and the ranked indicator retrieval results are output.
[0013] In some embodiments, step S4 further includes: When the intersection size does not reach the preset threshold and the union size exceeds the preset condition, an edit distance scan is performed in the full index database to obtain the full catch-all candidate set.
[0014] In some embodiments, the steps further include: S6. Cache Update and Closed-Loop Feedback: Store the metric retrieval results in the cache, record user click behavior, and trigger closed-loop control.
[0015] In some embodiments, recording user click behavior and triggering closed-loop control includes: Collect user click behavior data on the index search results in each query; Calculate the Top-N click-through rate for each query based on the click behavior data, where N≥1; The top-N click-through rates of the most recent queries are continuously monitored. When the top-N click-through rates are lower than a preset low threshold, a first operator scheduling signal is generated to increase the fusion weight of the vector semantic retrieval operator and the semantic reordering retrieval operator. When the Top-N click-through rate is higher than a preset high threshold, a second operator scheduling signal is generated to maintain the current fusion weight configuration of each retrieval operator. When the Top-N click-through rate is between the preset low threshold and the preset high threshold, a third operator scheduling signal is generated to increase the fusion weight of the vector semantic retrieval operator and the semantic reordering operator by half a step.
[0016] In some embodiments, the query intent type includes exact query, fuzzy query, semantic query, and compound query; The calculation of the confidence level includes: Extract the multidimensional feature vector of the query text. The multidimensional features include: whether the query string matches the indicator identifier regular expression pattern, whether it is an uppercase English letter abbreviation, whether it contains a structured naming delimiter, query complexity score, number of keywords, whether it contains conjunctions, and whether it contains descriptive words. Based on the multidimensional feature vector, the fusion feature scores of the query text corresponding to four intent types—exact query, fuzzy query, semantic query, and compound query—are calculated respectively to obtain the intent score vector. The intent score vector is normalized, and the intent type corresponding to the highest normalized score is determined as the query intent type of the query text. The highest normalized score is used as the confidence level of the query intent type.
[0017] In some embodiments, the application-level role classifier automatically identifies roles at each level and assigns differentiated weights to generate query vectors, including: Semantic role identification is performed on each hierarchical part by a hierarchical role classifier. The semantic role includes at least one of the following: country, province, sub-region, major category of indicator, sub-category of indicator, sub-category of indicator, data attribute, and time limit. Based on the identified semantic roles, dynamic weights are assigned to each layer according to a preset role weight base, and query vectors are generated based on each layer with assigned dynamic weights; wherein, the role weight base satisfies the following monotonically decreasing relationship according to semantic importance: Major Indicator Category > Sub-category Indicator > Sub-category Indicator > Data Attribute > Country > Province > Sub-region > Time Limit.
[0018] In some embodiments, the semantic role recognition of each hierarchical part through a hierarchical role classifier includes: The independent feature scores for each layer corresponding to each semantic role are calculated based on four-dimensional features: dictionary matching, position analysis, regular pattern matching, and context inheritance. The independent feature scores are fused to obtain a fused score vector; Constrain the available role space of the current layer based on the identified roles of adjacent layers; Within the constrained optional role space, the semantic role with the highest fusion score is selected as the recognition result of the current layer. The step of generating a query vector based on each layer with dynamically assigned weights includes: For each layer, its dynamic weight is multiplied by the position enhancement factor, and then the product of this multiplication and the hash feature vector of the corresponding layer is accumulated. For two adjacent hierarchical parts, calculate their combined weight and then sum the product of it and the combined hash feature vector of the two adjacent hierarchical parts; The complete indicator path is encoded into a global path hash feature vector, which is then superimposed onto the query vector with a preset weight.
[0019] In some embodiments, step S5 specifically includes: The original retrieval scores of the vector semantic retrieval channel, BM25 keyword retrieval, and dual-path recall gating decision retrieval were normalized to a uniform numerical range. The basic fusion score is obtained by multiplying each normalized retrieval score by its corresponding dynamic weight and then summing the results. The number of hit layers of the current candidate index in the vector semantic retrieval, BM25 keyword retrieval and dual-path recall gating decision retrieval is counted, where each retrieval method represents one layer. A tiered bonus score is added to the base fusion score based on the number of hit layers, with the bonus value increasing sequentially according to the number of hit layers; Sort the final scores after adding the tiered reward scores in descending order and output the search results.
[0020] In some embodiments, it also includes: When the closed-loop control fails due to an abnormal reason, a degraded operation strategy is executed: Freeze the current activation status of all retrieval operators; The fusion weights of each retrieval operator are rolled back to the initial configuration at system startup. Send an alarm signal and initiate an asynchronous retry writing mechanism for the feedback log; A heartbeat detection signal is sent to the feedback channel at a fixed period. When a normal response is received for a preset number of consecutive heartbeat detections, a gradual wake-up process is executed.
[0021] A second aspect of the present invention provides an intelligent indicator positioning system for large-scale macro databases, comprising: The query intent recognition module is used to acquire the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text. The vector semantic retrieval module is used to parse the query text according to the N-level hierarchical naming structure, apply a hierarchical role classifier to automatically identify the role of each level and assign differentiated weights to generate query vectors, perform batch cosine similarity calculation with the indicator vector library, and recall the first candidate set; The BM25 keyword retrieval module is used to perform BM25 keyword retrieval on the query text and recall the second candidate set; The dual-path recall gating decision retrieval module is used to calculate the intersection and union size of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, edit distance fuzzy matching is performed within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set. When the intersection size does not reach the preset threshold and the union size is within a preset condition, semantic reordering is performed within the union range to obtain a fallback candidate set. The fusion ranking module is used to perform weighted fusion ranking based on the retrieval scores and corresponding weight coefficients of the indicators in the candidate set obtained by dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, and output the ranked indicator retrieval results.
[0022] It should be further noted that the technical features corresponding to the above-mentioned options and embodiments can be combined or substituted with each other to form new technical solutions without conflict.
[0023] Compared with the prior art, the beneficial effects of the present invention are: 1. This invention employs an adaptive differentiated semantic vector generation method for N-level hierarchical naming formats of macro-indicators. The system supports arbitrary hierarchical depths, including 3-level basic formats, 4-level deep nesting, 5-level regional segmentation, and even 6-level ultra-deep nesting. The core indicator name hierarchy possesses the highest discriminative power in the vector space, and the weight allocation automatically adjusts with the hierarchy depth. Experiments show that the Top-1 accuracy rate for 3-4 level precise format queries is 100%, and even 6-level ultra-deep queries achieve precise hits. In a large-scale test with 200 queries, compared to the strongest baseline BM25-Only (Top-1 79%), this system achieves a Top-1 accuracy rate of 80%, an improvement of 1 percentage point; compared to the NoRole-Vector retrieval baseline (Top-1 7%), the hierarchical role weighting strategy brings a 73 percentage point improvement in Top-1 accuracy, demonstrating the decisive role of the differentiated vector generation mechanism. It should be noted that BM25-Only performs strongly in precise queries because precise queries account for 20% (40 results) in the test set. BM25 has a natural advantage in matching precise keywords for structured naming formats. However, in complex scenarios such as fuzzy queries, semantic queries, and misspelled queries, this system's advantages over BM25-Only are more significant. General-purpose search engines do not pre-define adaptive rules such as "the middle level has the highest weight, which decays towards both ends," nor do they design special weight strategies for deeply nested structures like "country:province:indicator category:indicator subcategory:region:attribute." This reflects the unique business logic of macro indicators being transformed into technical parameters.
[0024] 2. This invention employs a dual-path recall gating mechanism. In approximately 94% of queries, the system only needs to perform edit distance calculations on a subset of candidates jointly recognized by both coarse-ranking methods (an average of approximately 350 candidates, representing about 1.2% of the total 30,000 indicators). Only about 6% of queries trigger semantic fallback or full-database fallback. Compared to the no-gated hybrid retrieval baseline (NoGate-Hybrid, Top-1 accuracy 8%), the gating mechanism of this system results in a 72 percentage point improvement in Top-1 accuracy. Compared to the full-database edit distance retrieval scheme (EditDistance-Only, Top-1 accuracy 47.5%), this system, through its gating mechanism, limits the search domain of the edit distance operator from the 30,000 indicators in the entire database to approximately 350 candidates. This reduces the average candidate scan volume of the edit distance operator by approximately 93%, lowers CPU utilization by approximately 55%, and simultaneously improves Top-1 accuracy from 47.5% to 80%. In the context of patent law, this significant reduction in computational resource consumption and the significant improvement in retrieval accuracy are definite technical effects achieved through a gating mechanism.
[0025] 3. This invention's closed-loop feedback control generates operator scheduling signals based on user click-through rates (CTR) to control the allocation and activation status of computational resources for each retrieval operator. When the Top-3 CTR is below 30%, the operator scheduling signal triggers the loading of the deep semantic re-ranking operator, increasing its resource allocation weight in the fusion ranking; when it is above 70%, the operator scheduling signal maintains the current operator configuration; when it is between 30% and 70%, the operator scheduling signal performs conservative fine-tuning (half-step δ / 2). This signal-based operator orchestration mechanism enables the retrieval system to dynamically adjust its computational resource allocation strategy according to actual business scenarios, rather than statically configuring it.
[0026] 4. This invention employs a three-layer gating decision path (edit distance fine-tuning under normal access conditions, semantic reordering as a fallback when the intersection is empty but the union is controllable, and full-database edit distance scanning as a fallback when the intersection is empty and the union is uncontrollable), ensuring retrieval completeness under various query conditions. When the intersection of the two-way recall is empty but the union is within a controllable range (10-1000 candidates), semantic reordering is triggered as the first fallback strategy to guarantee recall while avoiding uncontrolled computational load. When the union is too small (<10, indicating severe insufficiency of two-way recall) or too large (>1000, indicating overly broad query), the strategy is downgraded to full-database edit distance scanning as the second fallback strategy, ensuring that users always obtain search results and that computational resources are not wasted. The sum of the trigger rates of the three gating decision paths covers 100% of query scenarios.
[0027] 5. This invention also designs a degradation operation strategy when the closed-loop feedback fails. When the closed-loop feedback control unit fails due to abnormal reasons, the system maintains the current enabled state of each operator, the fusion weight of each operator reverts to the initial configuration at system startup, and the old and new strategies are run in parallel in shadow mode to evaluate the differences, so as to smoothly switch back to the closed-loop control mode in multiple steps. Through the above three-level degradation strategy, the system can still maintain a retrieval accuracy of no less than 90% of the baseline configuration during the closed-loop feedback failure, and there is no service interruption during the recovery process. Attached Figure Description
[0028] Figure 1 This is a flowchart illustrating an intelligent indicator positioning method for large-scale macro databases, as shown in an embodiment of the present invention. Detailed Implementation
[0029] The technical solution of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0030] It should be noted that the defects in the solutions in the prior art are all the results of the inventors' practice and careful research. Therefore, the discovery process of the above problems and the solutions proposed by the embodiments of this application in the following text should be the inventors' contributions to this application in the process of invention and creation, and should not be understood as technical content known to those skilled in the art.
[0031] In view of the technical problems pointed out in the background art, the present invention provides the following embodiments: like Figure 1 As shown in an exemplary embodiment, a method for intelligent indicator positioning for large-scale macro databases is provided, comprising the following steps: S1. Query Intent Recognition: Obtain the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text; S2. Vector Semantic Retrieval: The query text is parsed according to the N-level hierarchical naming structure. The hierarchical role classifier is applied to automatically identify the role at each level and assign differentiated weights to generate query vectors. Batch cosine similarity is calculated with the indicator vector library to recall the first candidate set. S3.BM25 Keyword Search: Perform BM25 keyword search on the query text to recall the second candidate set; S4. Dual-path recall gating decision retrieval: Calculate the intersection and union sizes of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, perform edit distance fuzzy matching within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set. When the intersection size does not reach the preset threshold and the union size is within a preset condition, perform semantic reordering within the union range to obtain a fallback candidate set. When the intersection size does not reach the preset threshold and the union size exceeds the preset condition, perform edit distance scanning in the full index database to obtain a full fallback candidate set. S5. Fusion Ranking: Based on the retrieval scores and corresponding weight coefficients of the candidate set indicators obtained from dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, a weighted fusion ranking is performed, and the ranked indicator retrieval results are output.
[0032] Correspondingly, the present invention provides an intelligent indicator positioning system for large-scale macro databases, comprising: The query intent recognition module (with built-in adaptive query intent recognition unit) is used to acquire the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text. The vector semantic retrieval module (with built-in hierarchical role recognition and dynamic weight allocation unit and vector semantic retrieval operator) is used to parse the query text according to the N-level hierarchical naming structure, apply the hierarchical role classifier to automatically identify the role of each level (country, province, sub-region, indicator category / parent category, indicator sub-category, indicator grandchild category, data attribute, time limit) and assign differentiated weights to generate query vectors, perform batch cosine similarity calculation with the indicator vector library, and recall the first candidate set; The BM25 keyword retrieval module (with built-in BM25 keyword retrieval operator) is used to perform BM25 keyword retrieval on the query text and recall the second candidate set. A dual-path recall gating decision retrieval module (implemented based on a dual-path recall gating unit) is used to calculate the intersection and union sizes of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, edit distance fuzzy matching is performed within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set (implemented through an edit distance fuzzy matching operator). When the intersection size does not reach the preset threshold and the union size is within a preset condition, semantic reordering is performed within the union range to obtain a fallback candidate set (implemented through a semantic reordering operator). The fusion ranking module / unit is used to perform weighted fusion ranking based on the retrieval scores and corresponding weight coefficients of the candidate set indicators obtained from dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, and output the ranked indicator retrieval results.
[0033] The overall system architecture and functions are shown in Table 1.
[0034] Table 1. Composition and Functions of the Intelligent Indicator Positioning System It should be noted that the "operators" mentioned in the table refer to functional modules implemented by computer program instructions. Each operator corresponds to a specific retrieval or control operation and is loaded into the processor memory for execution during system runtime. Specifically, the "Vector Semantic Retrieval Operator" performs vector similarity calculation and candidate set recall; the "BM25 Keyword Retrieval Operator" performs term frequency-inverse document frequency calculation and keyword matching; the "Edit Distance Fuzzy Matching Operator" performs multi-strategy fuzzy matching (including exact matching, prefix matching, hierarchical alignment matching, keyword co-occurrence, and edit distance calculation); the "Semantic Re-ranking Operator" performs result re-ranking based on semantic similarity; the "Fusion Ranking Operator" performs weighted fusion of multi-path retrieval results and final ranking; and the "Closed-Loop Feedback Control Operator" performs click-through rate monitoring and dynamic weight adjustment. All operators interact through a unified interface protocol, forming a pluggable retrieval pipeline architecture.
[0035] The present invention will now be described in detail with reference to the methods and systems described above.
[0036] Specifically, in step S1, the query intent type includes exact query, fuzzy query, semantic query, and compound query, as shown in Table 2.
[0037] Table 2 Examples of Query Intent Intent recognition employs a classification method based on multidimensional feature vectors. The feature dimensions include: whether the query string matches the indicator identifier regular expression pattern, whether it is an uppercase English letter abbreviation, whether it contains structured naming delimiters (colons or underscores), query complexity score, number of keywords, whether it contains conjunctions, and whether it contains descriptive words.
[0038] The calculation of the confidence level includes: Based on the multidimensional feature vector, the fusion feature scores of the query text corresponding to four intent types—exact query, fuzzy query, semantic query, and compound query—are calculated respectively to obtain the intent score vector. The intent score vector is normalized, and the intent type corresponding to the highest normalized score is determined as the query intent type of the query text. The highest normalized score is used as the confidence level of the query intent type.
[0039] Furthermore, in step S2, one of the core innovations of this invention is an adaptive hierarchical role recognition and dynamic weight allocation method for the N-level hierarchical naming format of macro indicators. General search engines (such as Google and Elasticsearch) assign a uniform weight coefficient to each word in the text when generating text vectors. However, in the structured naming format of macro indicators, the semantic importance carried by different levels varies significantly: the indicator category / parent category (such as "general public budget expenditure") is the core level that carries the semantics of the container, the indicator sub-category (such as "education expenditure") is the secondary core level that carries the specific field subdivision, the indicator grandchild category (such as "higher education") is a deeper subdivision, the data attribute (such as "year-on-year") limits the data dimension, the country / province / sub-region limits the statistical subject, and the time limits the data time point.
[0040] This invention automatically identifies semantic roles at each level—country, province, sub-region, metric_major, metric_minor, metric_grandchild, data attribute, and time limit—using a hierarchical role classifier. Differential weights are then assigned based on a preset role weight base: metric_major: 3.5 > metric_minor: 2.8 > metric_grandchild: 2.0 > data attribute: 1.5 > country: 1.0 > province: 0.9 > sub-region: 0.8 > time limit: 0.6. This role-based dynamic weight allocation is essentially a domain-specific application of the Inverse Document Frequency (IDF) concept: In macro-level indicator naming conventions, the indicator category / parent category (e.g., "general public budget expenditure") is usually a unique business domain identifier, and its distinguishability within that domain is naturally higher than that of general terms (e.g., "data"). Therefore, assigning it the highest weight does not introduce noise but rather strengthens the domain semantic boundary. Indicator subcategories and grandchildren, as subdivisions within the parent category container, have progressively decreasing weights, ensuring that container semantics always take precedence over content semantics. Through this role-based dynamic weight allocation, the indicator category / parent category hierarchy achieves the highest distinguishability in the vector space, thereby improving the hit rate of precise queries.
[0041] The step of performing semantic role recognition for each layer using a hierarchical role classifier includes: The independent feature scores for each layer corresponding to each semantic role are calculated based on four-dimensional features: dictionary matching, position analysis, regular pattern matching, and context inheritance. The independent feature scores are fused to obtain a fused score vector; Constrain the available role space of the current layer based on the identified roles of adjacent layers; Within the constrained optional role space, the semantic role with the highest fusion score is selected as the recognition result of the current layer. The step of generating a query vector based on each layer with dynamically assigned weights includes: For each layer, its dynamic weight is multiplied by the position enhancement factor, and then the product of this multiplication and the hash feature vector of the corresponding layer is accumulated. For two adjacent hierarchical parts, calculate their combined weight and then sum the product of it and the combined hash feature vector of the two adjacent hierarchical parts; The complete indicator path is encoded into a global path hash feature vector, which is then superimposed onto the query vector with a preset weight.
[0042] The following is an example of an adaptive hierarchical role recognition and dynamic weight allocation algorithm: Input: Indicator name S (N-level hierarchical naming, such as "China: General Public Budget Expenditure: Education Expenditure: Year-on-Year"); Output: Role recognition result R=[(role_i, w_i)], D-dimensional semantic vector V 1. Parsing an N-level hierarchical naming structure: parts = split(S, ":") n = length(parts) / / N = 3, 4, 5,... supports arbitrary depth 2. Hierarchical Role Recognition (Four-Dimensional Feature Fusion): for i = 0 to n-1: / / Round 1: Independent Feature Recognition score_dict = DictMatching(parts[i]) / / Dictionary of countries / provinces / attributes / time score_pos = PositionalAnalysis(i, n) / / First level → Region, Last level → Attribute score_regex = RegexMatching(parts[i]) / / Year-on-year / month-on-month / growth rate → attribute score_type = ContentTypeAnalysis(parts[i]) / / GDP / Budget / CPI → Indicators / / Round 2: Context Correction (Restricting the Candidate Role Space) / / Based on the role relationships between adjacent levels, restrict the set of available role candidates for the current level. candidate_roles = {country, province, region_sub, metric_major,metric_minor, metric_grandchild, attribute, time} If all consecutive layers are indicator types: First metric layer → candidate_roles = {metric_major} The second metric layer → candidate_roles = {metric_minor} The 3rd and above → candidate_roles = {metric_grandchild} if metric_major is followed by a subclass keyword: Next layer → candidate_roles = {metric_minor} / / Round 3: Conflict Resolution and Confidence Calculation / / After performing Min-Max normalization on the scores of each independent feature, the scores are then fused with equal weights. / / Note: score_dict / score_pos / score_regex / score_type are all score vectors for each role (dimension = number of role types). norm_dict = Normalize(score_dict), norm_pos = Normalize(score_pos) norm_regex = Normalize(score_regex), norm_type = Normalize(score_type) fused_score = norm_dict + norm_pos + norm_regex + norm_type / / fused_score is the role score vector / / Select the highest-scoring role from the candidate_roles space. role_i = argmax_{r in candidate_roles}(fused_score[r]) conf_i = max(fused_score) / sum(fused_score) / / Round 4: Dynamic Weight Allocation base_w = RoleBaseWeight(role_i) / / metric_major:3.5, metric_minor:2.8, ... pos_f = PositionFactor(i, n) / / Role recognition stage: positive reward in the middle layer (+0% to +10%), cardinality is maintained in the edge layer w_i = base_w * pos_f R.append( (role_i, w_i) ) 3. Generate differentiated weighted vectors: V = zeros(D) for i = 0 to n-1: / / Obtain the role_i and dynamic weight w_i of the i-th layer from the role recognition result R. (role_i, w_i) = R[i] / / Position enhancement during vector generation: additional positive reward for intermediate layers (+20%), while edge layers maintain cardinality (approximately 1.0 to 1.07). pos_boost = PositionBoost(i, n) / / Middle layer +20%, edge layer 1.0 V = V + w_i * pos_boost * HashFeatures(parts[i]) / / Cross-layer combination features (role perception) for i = 0 to n-2: (role_i, w_i) = R[i] (role_{i+1}, w_{i+1}) = R[i+1] if role_i == metric_major AND role_{i+1} == metric_minor: combo_w = (w_i + w_{i+1}) / 2 * 0.8 / / The combination of parent class and child class has higher weight. else: combo_w = (w_i + w_{i+1}) / 2 * 0.5 V = V + combo_w * HashFeatures(parts[i] + "_" + parts[i+1]) / / Global path features: Encode complete indicator paths to enhance overall semantic consistency full_path = "|".join(parts[0..n-1]) V = V + 0.5 * HashFeatures(full_path) 4. L2 normalization: V = V / ||V||_2 5. Return to (R, V) Role weight base table: metric_major: 3.5 (metric category / parent category, such as "general public budget expenditure") metric_minor: 2.8 (Metric subclass, such as "education expenditure") metric_grandchild: 2.0 (Subclass of the metric, such as "Higher Education") attribute: 1.5 (Data attribute, such as "year-on-year comparison") country: 1.0 (country, such as "China") province: 0.9 (province, such as "Guangdong Province") region_sub: 0.8 (sub-region, such as "Pearl River Delta") time: 0.6 (Time limit, such as "2024") The final formula for generating the query vector is as follows: V_final = Σ_{i=1}^{N} [w_i · H(part_i)] + Σ_{i=1}^{N-1} [combo_w_{i,i+1} · H(part_i ⊕ part_{i+1})] Where N is the number of hierarchical levels of the metric name (N≥2, supporting arbitrary depth), w_i = RoleBaseWeight(role_i) × PositionFactor(i) represents the dynamic weight coefficient based on role recognition, role_i ∈{country, province, region_sub, metric_major, metric_minor, metric_grandchild, attribute, time} is the semantic role of the i-th layer, H(part_i) represents the hash feature mapping function, PositionFactor(i) represents the position enhancement factor, and RoleBaseWeight represents the basic dynamic weight of the i-th layer. combo_w_{i,i+1} is the cross-layer combined feature weight between the i-th and i+1-th layers. When two adjacent layers form a parent-child relationship, the weight coefficient increases to 0.8, and for other combined relationships, it is 0.5.
[0043] Regarding the position enhancement factor: This invention employs a two-layer position factor mechanism in the vector generation stage. The first layer is the position factor PositionFactor(i) for the role recognition stage (+5% to +10% for the middle layer, maintaining the cardinality for the edge layer), used to assist the hierarchical role classifier in determining the semantic roles of each layer. The second layer is the position enhancement factor PositionBoost(i) for the vector generation stage (an additional +20% for the middle layer, 1.0 for the edge layer), used to further highlight the discriminative power of the core semantic information of the middle layer in the vector space during vector encoding. After the two-layer position factor is superimposed, the actual weight gain of the middle layer in the vector space is approximately +26% to +32%, significantly enhancing the vector representation capability of the core semantic level, while the cardinality of the edge layer remains unchanged to avoid noise interference.
[0044] Regarding the global path hash feature: The single-layer features and cross-layer combined features in the above formula mainly encode the local hierarchical semantics of the indicator name. In an alternative embodiment, a global path feature H(full_path) is also introduced, which encodes the complete indicator path "part_0|part_1|...|part_{n-1}" into an additional hash feature vector, and superimposes it onto the final vector with a weight of 0.5. This global path feature enhances the consistency of the overall semantics of the indicator, enabling the query "China:GDP:Year-on-Year" to match not only the independent features of each layer, but also the joint semantics of the complete path, thus improving the retrieval accuracy of deeply nested (level 5 and above) indicators. The weight of 0.5 for the global path feature is a preferred embodiment and can be adjusted within the range of [0.3, 0.7] according to the characteristics of the dataset.
[0045] Regarding Min-Max normalization: The "equal-weight fusion after Min-Max normalization of each independent feature score" mentioned in the third round of step 2 of Algorithm 1 is an optional preprocessing step. In an alternative embodiment, since Min-Max normalization is a monotonic linear transformation and does not change the argmax selection result, the original values of each independent feature score can be directly fused with equal weight (fused_score = score_dict + score_pos + score_regex + score_type), and then argmax selection can be performed. The role recognition result is consistent with the result after Min-Max normalization. Therefore, omitting Min-Max normalization does not affect the final result of hierarchical role recognition, but only affects the absolute magnitude of the confidence value. Any role recognition method based on feature fusion falls within the protection scope of this invention.
[0046] For macro-level indicators using an N-level hierarchical naming format, the system first automatically identifies the semantic role at each level using a hierarchical role classifier, and then assigns weights according to role importance: the major / parent category (metric_major) carries the most core container semantic information and is assigned the highest weight base of 3.5; the sub-category (metric_minor) carries specific domain-level semantic details and is assigned the second highest weight base of 2.8; the grandchild category (metric_grandchild) carries deeper subdivisions and is assigned a weight base of 2.0; data attributes limit data dimensions and are assigned a weight base of 1.5; country / province / sub-region limits the statistical subject and is assigned decreasing weight bases (1.0→0.9→0.8); time limits are assigned the lowest weight base of 0.6. The above role weight bases satisfy a strict monotonically decreasing relationship.
[0047] The physical meaning of this monotonically decreasing relationship is that the hierarchical naming of macroeconomic indicators follows a hierarchical semantic structure of "container-containing content"—the indicator category / parent category (such as "general public budget expenditure") is the core level carrying the semantics of the container, its subcategories (such as "education expenditure") are specific domain subdivisions within the parent category container, and the grandchild categories (such as "higher education") are deeper subdivisions within the subcategory container. If the weight of the subcategory is higher than that of the parent category (W(metric_minor) ≥ W(metric_major)), then the subcategory features in the vector space will suppress the parent category features, resulting in the inability to correctly recall subcategory indicators such as "education expenditure" when querying "general public budget expenditure"; if the weight of the attribute is higher than that of the indicator class (W(attribute) ≥ W(metric_minor)), then the data dimension qualifiers will overwhelm the semantics of the indicator ontology, resulting in a large number of irrelevant indicators being returned when querying "year-on-year". Therefore, strictly satisfying W(metric_major) > W(metric_minor) > W(metric_grandchild) > W(attribute) is a necessary mathematical condition to ensure the correctness of the retrieval system. Any parameter configuration that satisfies this monotonically decreasing relationship falls within the protection scope of this invention, regardless of the specific numerical value.
[0048] Furthermore, under experimental conditions based on the current hardware environment and the distribution of 30,000 indicator data, after multiple sets of weight configuration comparison tests, an adaptive hierarchical role recognition strategy was adopted: each layer of roles was automatically identified through four-dimensional feature fusion (dictionary matching + position analysis + context inheritance + regular expression pattern), and then dynamic weights were allocated according to the preset role weight base.
[0049] Method for determining the weight base values: The above-mentioned role weight base values (metric_major:3.5, metric_minor:2.8, metric_grandchild:2.0, attribute:1.5, country:1.0, province:0.9, region_sub:0.8, time:0.6) are not arbitrarily set, but are determined through the following experimental methods: (a) Construct a comparative experimental matrix containing 200 sets of different weight configuration parameters, each set of parameters covering the value combinations in the interval [0.5, 5.0] with a step size of 0.1; (b) Perform 10,000 query tests on a dataset of 30,000 metrics, and record the Top-1 accuracy and query latency under each configuration; (c) Use the grid search method to traverse the parameter space, with Top-1 accuracy ≥70% and query latency ≤600ms as constraints, and filter parameter combinations that meet the conditions; (d) Select the parameter configuration with the highest Top-1 accuracy from the constrained combinations as the preferred embodiment. Experimental results show that when the metric_major weight base is below 3.0, the Top-1 accuracy of level 4 deep nested queries significantly decreases to 58%; when it is above 4.0, the accuracy of level 3 basic queries does not improve further, but the latency increases by 15%. The combination of metric_major: 3.5, metric_minor: 2.8, and metric_grandchild: 2.0 achieved the highest overall score in 10,000 query tests. However, the above specific values are only preferred embodiments under the current experimental conditions, and the scope of protection of this invention is not limited thereto. In alternative embodiments, the role weight base can be adaptively adjusted according to the domain characteristics of the indicator database, as long as a monotonically decreasing hierarchical relationship is satisfied.
[0050] Furthermore, in macroeconomic indicator databases, user queries often contain both semantic information (such as "GDP") and keyword information (such as "year-on-year comparison"). Vector semantic retrieval operators excel at capturing semantic similarity but are weak in precise keyword matching; the BM25 keyword retrieval operator excels at precise keyword matching but is weak in semantic variations (such as abbreviations and aliases). Relying solely on either channel may lead to insufficient recall. Therefore, this invention introduces a dual-path recall gating mechanism.
[0051] The workflow of the dual-channel recall gating mechanism is as follows: 1. The vector semantic retrieval operator recalls the first candidate set from the index database; 2. The BM25 keyword retrieval operator recalls the second candidate set from the index database; 3. Calculate the size of the intersection and the size of the union between the first and second candidate sets; 4. The edit distance fuzzy matching operator is triggered as a fine-tuning channel only when the intersection size reaches the preset minimum threshold. The search domain is limited to the top K candidates within the union range (Path A: Precise Filtering). 5. When the intersection does not reach the preset threshold but the size of the union is within a controllable range (10 to 1000 candidates), the semantic reordering operator is triggered as one of the fallback strategies (Path B: Semantic fallback). 6. When the intersection does not reach the preset threshold and the union size is not within a controllable range (union < 10 or union > 1000), a full-database editing distance scan is forcibly executed as the second fallback strategy (path C: brute force fallback). The full-database editing distance scan does not depend on the intersection threshold condition and serves as the last backup means to ensure the integrity of the retrieval. 7. The search domain of the distance fuzzy matching operator under normal admission conditions is limited to the top K candidates within the union of the first and second candidate sets, rather than all indices.
[0052] The technical advantage of this mechanism lies in limiting the search domain of edit distance fuzzy matching from all N metrics to a candidate subset jointly recognized (or jointly covered) by dual-path coarse ranking. This avoids the high computational overhead of full traversal and ensures recall quality through dual-path cross-validation. When the gating mechanism is absent, the edit distance fuzzy matching operator will default to executing on the full metric database, leading to a surge in computational overhead and the introduction of significant noise. This is the fundamental reason for the extremely poor performance of the NoGate-Hybrid baseline (only 8% Top-1).
[0053] The following is an example of a dual-path recall gating algorithm: Input: First candidate set C1 (vector semantic recall), second candidate set C2 (BM25 recall) Output: Gated decision G, candidate pool P, fallback flag F 1. Extract candidate set identifiers: S1 = {id | (id, score) in C1} S2 = {id | (id, score) in C2} 2. Calculate the size of the intersection: n_intersection = |S1 ∩ S2| 3. Calculate the size of the union: n_union = |S1 ∪ S2| 4. Gating decision: if n_intersection ≥ min_threshold: / / Case 1: Dual-path intersection access, edit distance operator is enabled normally G = ENABLED / / Candidate pool construction: Take the union of S1 and S2, remove duplicates, sort them in descending order of original recall scores, and select the top K. / / Note: S1 (cosine similarity) and S2 (BM25 score) have different dimensions; they are sorted separately and then merged. P = top-K_by_merged_score(S1 ∪ S2) F = False elif 10 ≤ n_union ≤ max_union_threshold: / / Case 2: The intersection does not reach the preset threshold, but the union is within a controllable range (10~1000), and the semantic reordering operator is used as a fallback. G = SEMANTIC_FALLBACK P = top-K_by_merged_score(S1 ∪ S2) F = True else: / / Case 3: If the union is too small (<10) or too large (>1000), use the entire database as a fallback (path C) / / A union that is too small indicates that both-path recall are severely insufficient; a union that is too large indicates that the query is too broad, leading to an overabundance of candidates. / / At this point, instead of performing costly semantic reordering, a full-database edit distance scan is forced as a last resort. / / Note: The full library scan here does not depend on the intersection threshold condition, which is fundamentally different from the "trigger edit distance operator" in path A. G = FULL_FALLBACK P = all_indicators / / In a preferred embodiment, return the first 500 indicators (in the order they were inserted into the database). F = True 5. Return G, P, F The technical effectiveness of the fallback mechanism: When a user's query is ambiguous, resulting in an empty intersection of the two-way recall but a manageable union (10-1000 candidates) (Case 2), the system triggers a semantic reordering operator as one of the fallback strategies. This performs deep semantic reordering on the candidates within the union range, ensuring recall while avoiding uncontrolled computational load. When the union is too small (<10, indicating severe insufficiency in both-way recall) or too large (>1000, indicating overly broad query leading to candidate overabundance) (Case 3), the system does not perform the high-cost semantic reordering. Instead, it directly downgrades to a full-database edit distance scan as the second fallback strategy, ensuring that users always obtain search results and that computational resources are not wasted. This three-layer gating decision-making mechanism (normal access → semantic fallback → full-database fallback) and union upper limit boundary control (10≤union≤1000) guarantee the system's retrieval completeness, availability, and controllability of computational resources under various query conditions.
[0054] Furthermore, step S5 specifically includes: The original retrieval scores of the vector semantic retrieval channel, BM25 keyword retrieval, and dual-path recall gating decision retrieval were normalized to a uniform numerical range. The basic fusion score is obtained by multiplying each normalized retrieval score by its corresponding dynamic weight and then summing the results. The number of hit layers of the current candidate index in the vector semantic retrieval, BM25 keyword retrieval and dual-path recall gating decision retrieval is counted, where each retrieval method represents one layer. A tiered bonus score is added to the base fusion score based on the number of hit layers, with the bonus value increasing sequentially according to the number of hit layers; Sort the final scores after adding the tiered reward scores in descending order and output the search results.
[0055] In terms of specific operators, the fusion ranking is a weighted fusion ranking of the retrieval scores and corresponding weight coefficients of each retrieval operator. Based on the weighted fusion score, the system adds a tiered reward score according to the number of retrieval operator layers hit: the more layers hit, the higher the reward score. Specifically, when a certain indicator is simultaneously recalled by multiple retrieval operators (e.g., simultaneously hit by the vector semantic retrieval operator and the BM25 keyword retrieval operator), its final score in the fusion ranking receives an additional bonus. The design basis of this tiered reward mechanism is that cross-hitting by multiple retrieval operators indicates a higher confidence level of matching the indicator with the query, and it should be prioritized. In a preferred embodiment, candidates hitting 2 layers (recalled by 2 operators) receive a fixed reward score of 0.06 on top of the basic fusion score, hitting 3 layers adds 0.09, hitting 4 layers and above adds 0.12 (with a maximum of 0.12), and hitting 1 layer receives no additional reward. This fixed additive reward mechanism ensures that high-confidence candidates are presented first in the final ranking, improving the Top-1 and Top-3 hit rates.
[0056] The final ranking scores for each candidate indicator are as follows: Where K represents the total number of retrieval channels (number of retrieval operator layers) participating in the fusion. This represents the result of the raw score of the k-th channel output for the current index doc after Min-Max normalization, mapped to a unified [0,1] interval to eliminate dimensional differences. This represents the additive reward value based on the number of cross-hit layers L. This represents the dynamic fusion weight of the k-th channel.
[0057] Furthermore, the present invention also includes the step of: S6. Cache Update and Closed-Loop Feedback: The retrieval results are stored in the cache, user click behavior is recorded, and closed-loop control is triggered. Closed-loop feedback control dynamically arranges the activation strategy of retrieval operators based on user click behavior signals, enabling the adaptive evolution of the retrieval system.
[0058] The click behavior data includes, but is not limited to, the following fields: query string (the original query text entered by the user), selected metric identifier (a unique identifier for the metric clicked by the user), ranking before click (the metric's sorting position in the search results list before the click, where 1 indicates the first position), and dwell time (the length of time the user stays on the metric's details page, in seconds). The system calculates CTR based on these fields: when the ranking before click is ≤3, it is included in the Top-3 click count, reflecting the top three hit rate of the search results.
[0059] The control logic is as follows: The system continuously monitors the top-3 click-through rates (CTR) of the most recent 100 queries. When the CTR is lower than the preset low threshold (30%), it is determined that the current retrieval strategy is insufficient to meet user needs. An operator scheduling signal ENABLE_DEEP_RERANK is generated to increase the fusion weights of the vector semantic retrieval operator and the semantic reordering operator (step size δ=0.01, with upper limits of 0.5 and 0.4 respectively). When the CTR is higher than the preset high threshold (70%), it is determined that the current retrieval strategy is effective. A signal MAINTAIN_CURRENT is generated to maintain the current configuration. When the CTR is between 30% and 70%, an operator scheduling signal GRADUAL_ADJUST is generated to perform conservative fine-tuning (half a step size δ / 2), increasing the fusion weights of the vector semantic retrieval operator and the semantic reordering operator by half.
[0060] The key technical feature of this control is that it is not a simple threshold judgment, but a dynamic arrangement mechanism of retrieval strategies based on statistical significance. When user click behavior data indicates that the system is not performing well in processing semantic or fuzzy queries, the system automatically adjusts the activation status and weight configuration of the retrieval operator set, forming a closed-loop control loop of "retrieval-feedback-adjustment-re-retrieval".
[0061] The following is an example of a closed-loop feedback control algorithm: Input: Feedback history F, current weight W (including five components: cache / vector / bm25 / edit_distance / semantic_rerank). Current gating state G, low threshold T_low, high threshold T_high, step size δ Output: Operator scheduling signal S, updated weights W', updated gating state G' 1. Calculate the top-3 click-through rates of the most recent 100 feedback responses: window = min(100, len(F)) CTR = count(rank ≤ 3 in F[-window:]) / window / / When the feedback history is less than 100, the denominator is the actual number of feedback entries to avoid artificially suppressing the CTR. 2. if CTR < T_low: / / Low click-through rate: Generate operator scheduling signals to enable deep reordering operators S = "ENABLE_DEEP_RERANK" G'.semantic_rerank = ENABLED / / Increase the weight of computational resource allocation for semantic operators (step size δ=0.01) W'.vector = min(W.vector × (1+δ), 0.5) W'.semantic_rerank = min(W.semantic_rerank × (1+δ), 0.4) elif CTR > T_high: / / High click-through rate: Maintain operator configuration and reduce scheduling signal changes S = "MAINTAIN_CURRENT" G' = G W' = W else: / / Middle range: Click-through rate between [T_low, T_high], perform conservative fine-tuning. S = "GRADUAL_ADJUST" G' = G / / Perform conservative fine-tuning of vector semantic weights (half-step size) W'.vector = min(W.vector × (1+δ / 2), 0.5) W'.semantic_rerank = min(W.semantic_rerank × (1+δ / 2), 0.4) 3. Apply upper bound constraints and normalize W': / / Step 3a: First, perform upper limit pruning on the adjusted weights. W'.vector = min(W'.vector, 0.5) W'.semantic_rerank = min(W'.semantic_rerank, 0.4) / / Step 3b: Apply proportional scaling normalization to ensure the sum of the weights is exactly equal to 1. sum_w = W'.cache + W'.vector + W'.bm25 + W'.edit_distance + W'.semantic_rerank for each key in W': W'[key] = W'[key] / sum_w / / Step 3c: Check the upper limit again after normalization (to prevent individual components from exceeding the upper limit due to normalization). if W'.vector > 0.5 or W'.semantic_rerank > 0.4: W'.vector = min(W'.vector, 0.5) W'.semantic_rerank = min(W'.semantic_rerank, 0.4) sum_w = sum(W'.values()) for each key in W': W'[key] = W'[key] / sum_w 4. Return S, W', G' The technical effect of operator scheduling signals: Closed-loop feedback control is not simply about statistically analyzing click-through rates and adjusting values, but rather about generating explicit operator scheduling signals (such as "ENABLE_DEEP_RERANK", "MAINTAIN_CURRENT", or "GRADUAL_ADJUST") to control the allocation of computing resources and the activation status of each retrieval operator. When user click behavior data indicates that the system's processing of semantic queries is ineffective, the operator scheduling signal triggers the loading of deep semantic re-ranking operators, increasing their resource allocation weight in the fusion ranking; when the click-through rate recovers to a high level, the current configuration remains unchanged. This control mechanism adopts a unidirectional enhancement strategy: once an operator is enabled, it will not be immediately disabled due to a short-term high CTR, and its weight will not automatically decrease due to a short-term high CTR, thereby avoiding frequent oscillations in the retrieval strategy. In alternative embodiments, a bidirectional adjustment mechanism can also be configured (gradually reducing weight and disabling operators when CTR is high), and any strategy that dynamically orchestrates retrieval operators based on click-through rate falls within the protection scope of this invention.
[0062] Furthermore, the system of the present invention runs on a general-purpose computing device, which includes at least one central processing unit (CPU, such as an Intel Xeon or AMD EPYC series processor with a main frequency of not less than 2.5GHz and having 8 or more physical cores) for performing computational tasks such as query intent recognition, hierarchical role classification, vector calculation, gating decision, edit distance matching, and closed-loop control; at least 16GB of random access memory (RAM) for loading the indicator vector library (30,000 384-dimensional floating-point vectors occupying approximately 46MB of memory), caching hot data (LRU cache with a default of 1000 records), and runtime computation cache; at least 500GB of non-volatile storage medium (such as an SSD solid-state drive) for persistently storing macroscopic indicator structured data files (JSON format, approximately 10MB), offline-calculated BM25 inverted index (IDF value and average document length parameter table), and historical feedback logs; and a network communication interface (such as Gigabit Ethernet) for receiving user query requests from clients and returning search results. The general-purpose computing device runs a Linux operating system (such as Ubuntu 20.04 LTS or CentOS 7), and deploys a Python 3.9+ runtime environment and the NumPy vector computing library.
[0063] This system is implemented entirely in Python. Upon system startup, it first loads a macro-level indicator data file (JSON format) and then performs the following initialization operations in sequence: constructing an inverted index (based on Jieba segmentation and n-gram extraction), calculating BM25 parameters (IDF value and average document length), constructing a differentiated weighted vector index for hierarchical role recognition and dynamic weight allocation, and initializing an LRU cache (default capacity 1000 records). After initialization, the system enters the retrieval service state.
[0064] When the system receives a user query request, it performs a retrieval operation according to the following process: 1. Query intent recognition: The query string is cleaned and segmented, multi-dimensional features are extracted, and the intent type and confidence level are determined based on the feature scores; 2. Cache check: Calculate the MD5 hash value of the query string and check if a matching record exists in the LRU cache; 3. Differentiated vector semantic retrieval with hierarchical role recognition and dynamic weight allocation: The query text is parsed according to the N-level hierarchical naming structure, and a hierarchical role classifier is applied to automatically identify the role at each level and assign differentiated weights to generate query vectors. Batch cosine similarity calculation is performed with the indicator vector library to recall the first candidate set. 4. BM25 Keyword Retrieval: The query is segmented and n-grams are extracted. BM25 scoring is performed based on the offline calculated IDF value to recall the second candidate set; 5. Dual-path recall gating decision: Calculate the intersection and union of the first and second candidate sets to determine whether the edit distance fuzzy matching operator is allowed; 6. Edit distance fuzzy matching: Under gating admission conditions, the edit distance is calculated within the dual-path union range; when querying a completely matching indicator name, the highest score of that candidate is directly assigned and returned first. 7. Semantic reordering: When the dual-path recall gating decision returns SEMANTIC_FALLBACK, semantic reordering is performed as a fallback strategy to enhance the semantic matching strength; 8. Merging and Sorting: Calculate the final score based on the scores of each operator and the dynamic weights, and return the results in descending order of score; 9. Cache update and closed-loop feedback: Store the results in the cache, record user click behavior and trigger closed-loop control.
[0065] The following example, using a user query for "China:GDP:Year-on-Year", illustrates the complete processing flow of the system: Step 1: Query Intent Recognition. The system receives the query "China:GDP:Year-on-Year" and detects the presence of a colon separator (structured naming feature +2). After word segmentation, it contains three words: "China", "GDP", and "Year-on-Year", with a complexity score of 0.35. Based on the combined feature score, it is determined to be an exact query with a confidence level of 0.82.
[0066] Step 2: Adaptive Hierarchical Role Recognition and Dynamic Weight Allocation. The system parses "China:GDP:Year-on-Year" according to an N-level hierarchical structure: It automatically identifies roles through a hierarchical role classifier—"China" is identified as the country role with a base weight of 1.0 (approximately 1.0 after position fine-tuning), "GDP" is identified as the metric_major (index category / parent category) role with a base weight of 3.5 (approximately 3.85 after position fine-tuning), and "Year-on-Year" is identified as the attribute role with a base weight of 1.5. For the more complex "Japan:Industrial Value Added:Manufacturing:Monthly Value", the system automatically identifies a 4-level structure and calculates adaptive weights for each level: "Japan" (country, 1.0), "Industrial Value Added" (metric_major / parent category, 3.5→3.73), "Manufacturing" (metric_minor / subcategory, 2.8→2.98), and "Monthly Value" (attribute, 1.5). A 384-dimensional vector is generated.
[0067] Step 3: Vector Semantic Retrieval. Perform batch cosine similarity calculation between the differentiated weighted vector and 30,000 indicator vectors. Recall the Top-200 candidate set (first candidate set), including "China:GDP:Year-on-Year" (similarity 0.92), "US:GDP:Year-on-Year" (0.88), "China:GDP:Month-on-Month" (0.78), etc.
[0068] Step 4: BM25 keyword retrieval. After segmenting the query, perform BM25 scoring and recall the Top-200 candidate set (second candidate set), including "China:GDP:Year-on-Year" (BM25 score 8.5), "US:GDP:Year-on-Year" (7.8), "China:GDP:Cumulative" (7.2), etc.
[0069] Step 5: Dual-path recall gating decision. Calculate the intersection of the first and second candidate sets: both paths recall "China:GDP:Year-on-Year", and the intersection size is ≥1. The gating decision is ENABLED, and the distance operator is used for admission. The candidate pool consists of the top 500 candidates from the union of the first and second candidate sets.
[0070] Step 6: Edit Distance Fuzzy Matching. Perform a comparison within the candidate pool, querying for a perfect match between "China:GDP:Year-on-Year" and the indicator "China:GDP:Year-on-Year". Directly return the exact match result (score 1.0), without needing to calculate other candidates.
[0071] Step 7: Closed-loop feedback. The system records user click behavior. If the Top-3 click-through rate is below 30%, the system generates the operator scheduling signal ENABLE_DEEP_RERANK, increasing the fusion weights of the vector semantic retrieval operator and the semantic reordering operator (step size δ=0.01, with upper limits of 0.5 and 0.4 respectively); if it is above 70%, the system generates the signal MAINTAIN_CURRENT to maintain the current configuration; if it is between 30% and 70%, the system generates the operator scheduling signal GRADUAL_ADJUST to perform conservative fine-tuning (half a step size δ / 2).
[0072] In another exemplary embodiment, a degraded operation strategy for the system when the closed-loop feedback control system fails due to an abnormal cause is described to demonstrate the robustness of the technical solution. Scenario setting: The degraded strategy is automatically triggered when one of the following situations occurs during system operation: (1) The feedback log storage module of the closed-loop feedback control unit is temporarily unavailable due to disk I / O abnormality, resulting in the interruption of CTR calculation and operator scheduling signal generation, and there is no feedback update for more than 30 seconds beyond the preset threshold; (2) The Top-3 click rate of multiple consecutive queries is consistently lower than the preset low threshold, indicating that the current retrieval strategy is ineffective. At this time, the system automatically triggers the following degraded strategy: 1. Operator State Freeze: The system maintains the current enabled state of each operator (i.e., the last valid gating decision before the feedback interruption continues to take effect), avoiding fluctuations in search results due to frequent operator starts and stops. The admission threshold for the edit distance operator is rolled back from the adaptive dynamic value to the preset static value (intersection ≥ 1), ensuring that the integrity of the search is not affected by the feedback interruption.
[0073] 2. Weight Parameter Rollback: The fusion weights of each operator are rolled back to the initial configuration at system startup (cache=0.1, vector=0.3, bm25=0.25, edit_distance=0.15, semantic_rerank=0.2), instead of using the dynamic weights adjusted by closed-loop feedback. This rollback ensures that the system can still operate stably with an offline-verified baseline configuration even if feedback data is unavailable.
[0074] 3. Log Alarms and Self-Healing: The system sends an alarm signal ("CLOSED_LOOP_DEGRADED") to the operation and maintenance monitoring module, and at the same time starts the asynchronous retry writing mechanism for feedback logs.
[0075] 4. Heartbeat Detection and Gradual Wake-up: The system sends a heartbeat probe signal to the feedback channel at a fixed period (e.g., every 10 seconds) to detect whether disk I / O has recovered. When three consecutive heartbeats receive normal responses, the feedback channel is determined to have recovered, and the gradual wake-up process is initiated. Phase 1 (Shadow Mode): The system does not immediately restore the closed-loop control in full, but instead runs the old and new operator strategies in parallel. The degradation strategy continues to use the baseline configuration to process production queries, while the new strategy after the closed-loop feedback adjustment is executed in the bypass in "shadow mode". The output differences of the two strategies are compared for the same query request. Phase Two (Difference Assessment): Continue running the shadow mode until a total of 100 queries are processed or the mode runs continuously for 5 minutes. Calculate the Top-1 accuracy and average latency for both the old and new strategies. Accuracy statistics are based on the comparison between the results returned by actual user queries in shadow mode and those returned by the downgraded strategy. Latency statistics are based on the end-to-end response time of the same query under both strategies. If the Top-1 accuracy of the new strategy is not lower than that of the downgraded strategy and the increase in latency does not exceed 10%, the new strategy is considered stable and usable. Phase 3 (Gradual Switching): If the new strategy passes the difference assessment, the system will smoothly switch back to the closed-loop control mode in 5 steps, with a fixed interval for each weight adjustment to avoid retrieval oscillations caused by sudden weight changes; if the new strategy fails the difference assessment, the downgrade mode will continue and the gradual wake-up will be tried again.
[0076] Technical Results: Through the above three-level degradation strategy (operator freezing → weight rollback → self-healing recovery), the system can still maintain a retrieval accuracy of no less than 90% of the baseline configuration during the closed-loop feedback failure period, and there is no service interruption during the recovery process, which proves the robustness and engineering feasibility of this technical solution in abnormal scenarios.
[0077] The experimental verification process of the embodiments of the present invention is given below: The experiment used a dataset containing 30,000 macroeconomic indicators, covering 18 countries / regions and 54 major categories. The dataset was constructed using stratified sampling: all deep-level indicators were retained (5,056 at level 4, 405 at level 5, and 15 at level 6, totaling 5,476), while 24,524 basic level 3 indicators were sampled using a two-tiered stratified sampling method (country × category). Indicator naming adopted an N-level colon-separated hierarchical structure: 24,524 indicators in the basic level 3 format (81.7%), 5,056 in the deeply nested level 4 format (16.9%), 405 in the regionally detailed level 5 format (1.4%), and 15 in the ultra-deeply nested level 6 format (0.05%). This stratified sampling strategy ensured coverage of both countries (18) and categories (54 categories) while reducing computational cost by approximately 40%.
[0078] Hierarchical role recognition accuracy test: Role recognition verification was performed on 10 typical N-level named samples. The classifier correctly identified the following: "China" → Country (confidence 1.0), "Guangdong Province" → Province (0.95), "Pearl River Delta" → Sub-region (0.84), "General Public Budget Expenditure" → Major Indicator Category (0.8), "Education Expenditure" → Sub-Indicator Category (0.67 → improved to 0.77 after context correction), "Higher Education" → Sub-Indicator Category (0.67), "Financial Appropriation" → Sub-Indicator Category (0.9), "Year-on-Year" → Attribute (1.0). All 6 levels of roles in the 6-level ultra-deep sample "China: General Public Budget Expenditure: Education Expenditure: Higher Education: Financial Appropriation: Year-on-Year" were correctly identified, and the context downgrading logic of parent class → child class → sub-class was accurately implemented.
[0079] The experiment designed 200 test queries (a large-scale validation set covering four levels of nesting depth: level 3 basic format, level 4 deep nesting, level 5 regional segmentation, and level 6 ultra-deep nesting; and six query types: exact queries (40 queries, 20%), fuzzy queries (40 queries, 20%), semantic queries (30 queries, 15%), misspelling queries (30 queries, 15%), partial-level queries (30 queries, 15%), and cross-regional queries (30 queries, 15%)). A comprehensive comparative test was conducted on the proposed system and four baselines on a dataset of 30,000 metrics. As shown in Table 3, the proposed system achieved a Top-1 accuracy of 80%, a Top-3 accuracy of 89%, and a Top-5 accuracy of 90.5%, with an average latency of 524.7 milliseconds. The Top-1 accuracy for level 3-4 exact format queries was 100%, and the level 6 ultra-deep nesting query also achieved Top-1 exact hits. Compared to the strongest baseline BM25-Only (Top-1 accuracy 79%), this system improves Top-1 accuracy by 1 percentage point. Compared to the NoGate-Hybrid retrieval baseline (Top-1 accuracy 8%, which retains role recognition but removes the gating mechanism, resulting in indiscriminate execution of edit distance and semantic reordering on all queries, introducing a large amount of noise) and the NoRole-Vector retrieval baseline (Top-1 accuracy 7%, which uses uniform weights to generate vectors, resulting in completely chaotic semantic indicators in the vector space, and the gating mechanism fails due to poor vector quality), this system's dual-path recall gating mechanism and hierarchical role weighting strategy bring Top-1 accuracy improvements of 72 percentage points and 73 percentage points respectively, demonstrating the decisive role of these two core technologies. In the large-scale test with 200 queries, the BM25-Only baseline performed strongly because the test set had 20% (40) exact queries. BM25 has a natural advantage in matching exact keywords for structured naming formats. However, in complex scenarios such as fuzzy queries, semantic queries, and misspelled queries, this system's advantage over BM25-Only is more significant. Furthermore, the NoGate-Hybrid baseline, by removing the gating mechanism but retaining role recognition and fusion ranking, saw its Top-1 accuracy plummet from 80% to 8%. This 72 percentage point drop can be directly attributed to the lack of a gating mechanism—without gating, edit distance and semantic reordering are executed indiscriminately across all queries, and the edit distance operator needs to scan all 30,000 metrics in the entire database, introducing significant noise. The NoRole-Vector baseline had a Top-1 accuracy of 0% in the small sample test with 50 queries, rising to 7% in the large sample test with 200 queries. This fluctuation is a small sample statistical effect and does not affect the conclusion that "unweighted vectors lead to semantic confusion."
[0080] Table 3. Experimental Comparison Results of System Performance and Computational Resource Consumption It should be noted that the edit distance operator trigger rate refers to the execution rate of the fine-ranking channel actively triggered by the gating mechanism under normal admission conditions, excluding the scan in the full-database fallback strategy. The semantic fallback trigger rate refers to the proportion of the gating mechanism that triggers the semantic reordering operator when the intersection is empty but the union is controllable. The sum of the two trigger rates is approximately 100%, covering the gating decision paths of all queries.
[0081] Furthermore, on a dataset of 30,000 metrics, the pure edit distance method requires string similarity calculation on all candidates in the database, consuming an average of approximately 58 milliseconds of CPU time per query. Our system employs a dual-path recall gating mechanism, requiring edit distance calculation only on a subset of candidates mutually agreed upon by both coarse ranking methods (an average of approximately 350 candidates, representing about 1.2% of the total 30,000 metrics) in approximately 94% of queries, and triggering semantic fallback or full database fallback in only about 6% of queries. Compared to the full edit distance retrieval scheme, our system requires the edit distance operator to scan only about 350 candidates in approximately 94% of queries (a 98.8% reduction compared to the full database of 30,000), and triggers semantic fallback (no edit distance calculation) in about 6% of queries. After comprehensive weighted averaging, the average candidate scan count for the edit distance operator is reduced by approximately 93% (based on candidate scan count), and CPU utilization is reduced by approximately 55%. This significant reduction in computational resource consumption is a definite technical effect achieved through gating mechanisms, rather than a simple optimization of management strategies. It is worth noting that the average latency of this system (524.7 milliseconds) is higher than the pure BM25 baseline (459.0 milliseconds). This is because this system performs multiple computations within its five-level waterfall architecture, including vector semantic retrieval, BM25 keyword retrieval, edit distance fuzzy matching, and semantic reordering, in exchange for higher retrieval accuracy (Top-1 accuracy improved from 79% to 80%, with even more significant advantages in complex scenarios such as fuzzy queries, semantic queries, and spelling errors).
[0082] The above detailed embodiments are a description of the present invention. It should not be considered that the specific embodiments of the present invention are limited to these descriptions. For those skilled in the art, several simple deductions and substitutions can be made without departing from the concept of the present invention, and all of these should be considered to fall within the protection scope of the present invention.
Claims
1. A method for intelligent indicator positioning for large-scale macro databases, characterized in that, Includes the following steps: S1. Query Intent Recognition: Obtain the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text; S2. Vector Semantic Retrieval: The query text is parsed according to the N-level hierarchical naming structure. The hierarchical role classifier is applied to automatically identify the role at each level and assign differentiated weights to generate query vectors. Batch cosine similarity is calculated with the indicator vector library to recall the first candidate set. S3.BM25 Keyword Search: Perform BM25 keyword search on the query text to recall the second candidate set; S4. Dual-path recall gating decision retrieval: Calculate the intersection and union size of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, perform edit distance fuzzy matching within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set. When the intersection size does not reach the preset threshold and the union size is within a preset condition, perform semantic reordering within the union range to obtain a fallback candidate set. S5. Fusion Ranking: Based on the retrieval scores and corresponding weight coefficients of the candidate set indicators obtained from dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, a weighted fusion ranking is performed, and the ranked indicator retrieval results are output.
2. The intelligent indicator positioning method for large-scale macro databases according to claim 1, characterized in that, Step S4 also includes: When the intersection size does not reach the preset threshold and the union size exceeds the preset condition, an edit distance scan is performed in the full index database to obtain the full catch-all candidate set.
3. The intelligent indicator positioning method for large-scale macro databases according to claim 1, characterized in that, It also includes the following steps: S6. Cache Update and Closed-Loop Feedback: Store the metric retrieval results in the cache, record user click behavior, and trigger closed-loop control.
4. The intelligent indicator positioning method for large-scale macro databases according to claim 3, characterized in that, The recording of user click behavior and triggering closed-loop control includes: Collect user click behavior data on the index search results in each query; Calculate the Top-N click-through rate for each query based on the click behavior data, where N≥1; The top-N click-through rates of the most recent queries are continuously monitored. When the top-N click-through rates are lower than a preset low threshold, a first operator scheduling signal is generated to increase the fusion weight of the vector semantic retrieval operator and the semantic reordering retrieval operator. When the Top-N click-through rate is higher than a preset high threshold, a second operator scheduling signal is generated to maintain the current fusion weight configuration of each retrieval operator. When the Top-N click-through rate is between the preset low threshold and the preset high threshold, a third operator scheduling signal is generated to increase the fusion weight of the vector semantic retrieval operator and the semantic reordering operator by half a step.
5. The intelligent indicator positioning method for large-scale macro databases according to claim 1, characterized in that, The query intent types include exact query, fuzzy query, semantic query, and compound query; The calculation of the confidence level includes: Extract the multidimensional feature vector of the query text. The multidimensional features include: whether the query string matches the indicator identifier regular expression pattern, whether it is an uppercase English letter abbreviation, whether it contains a structured naming delimiter, query complexity score, number of keywords, whether it contains conjunctions, and whether it contains descriptive words. Based on the multidimensional feature vector, the fusion feature scores of the query text corresponding to four intent types—exact query, fuzzy query, semantic query, and compound query—are calculated respectively to obtain the intent score vector. The intent score vector is normalized, and the intent type corresponding to the highest normalized score is determined as the query intent type of the query text. The highest normalized score is used as the confidence level of the query intent type.
6. The intelligent indicator positioning method for large-scale macro databases according to claim 1, characterized in that, The application-level role classifier automatically identifies roles at each level and assigns differentiated weights to generate query vectors, including: Semantic role identification is performed on each hierarchical part by a hierarchical role classifier. The semantic role includes at least one of the following: country, province, sub-region, major category of indicator, sub-category of indicator, sub-category of indicator, data attribute, and time limit. Based on the identified semantic roles, dynamic weights are assigned to each layer according to a preset role weight base, and query vectors are generated based on each layer with assigned dynamic weights; wherein, the role weight base satisfies the following monotonically decreasing relationship according to semantic importance: Major Indicator Category > Sub-category Indicator > Sub-category Indicator > Data Attribute > Country > Province > Sub-region > Time Limit.
7. The intelligent indicator positioning method for large-scale macro databases according to claim 6, characterized in that, The semantic role recognition of each layer using a hierarchical role classifier includes: The independent feature scores for each layer corresponding to each semantic role are calculated based on four-dimensional features: dictionary matching, position analysis, regular pattern matching, and context inheritance. The independent feature scores are fused to obtain a fused score vector; Constrain the available role space of the current layer based on the identified roles of adjacent layers; Within the constrained optional role space, the semantic role with the highest fusion score is selected as the recognition result of the current layer. The step of generating a query vector based on each layer with dynamically assigned weights includes: For each layer, its dynamic weight is multiplied by the position enhancement factor, and then the product of this multiplication and the hash feature vector of the corresponding layer is accumulated. For two adjacent hierarchical parts, calculate their combined weight and then sum the product of it and the combined hash feature vector of the two adjacent hierarchical parts; The complete indicator path is encoded into a global path hash feature vector, which is then superimposed onto the query vector with a preset weight.
8. The intelligent indicator positioning method for large-scale macro databases according to claim 1, characterized in that, Step S5 specifically includes: The original retrieval scores of the vector semantic retrieval channel, BM25 keyword retrieval, and dual-path recall gating decision retrieval were normalized to a uniform numerical range. The basic fusion score is obtained by multiplying each normalized retrieval score by its corresponding dynamic weight and then summing the results. The number of hit layers of the current candidate index in the vector semantic retrieval, BM25 keyword retrieval and dual-path recall gating decision retrieval is counted, where each retrieval method represents one layer. A tiered bonus score is added to the base fusion score based on the number of hit layers, with the bonus value increasing sequentially according to the number of hit layers; Sort the final scores after adding the tiered reward scores in descending order and output the search results.
9. The intelligent indicator positioning method for large-scale macro databases according to claim 3, characterized in that, Also includes: When the closed-loop control fails due to an abnormal reason, a degraded operation strategy is executed: Freeze the current activation status of all retrieval operators; The fusion weights of each retrieval operator are rolled back to the initial configuration at system startup. Send an alarm signal and initiate an asynchronous retry writing mechanism for the feedback log; A heartbeat detection signal is sent to the feedback channel at a fixed period. When a normal response is received for a preset number of consecutive heartbeat detections, a gradual wake-up process is executed.
10. An intelligent indicator positioning system for large-scale macro databases, characterized in that, include: The query intent recognition module is used to acquire the query text input by the user, perform intent recognition on the query text, and determine the query intent type and confidence level of the query text. The vector semantic retrieval module is used to parse the query text according to the N-level hierarchical naming structure, apply a hierarchical role classifier to automatically identify the role of each level and assign differentiated weights to generate query vectors, perform batch cosine similarity calculation with the indicator vector library, and recall the first candidate set; The BM25 keyword retrieval module is used to perform BM25 keyword retrieval on the query text and recall the second candidate set; The dual-path recall gating decision retrieval module is used to calculate the intersection and union size of the first candidate set and the second candidate set. When the intersection size reaches a preset threshold, edit distance fuzzy matching is performed within the union range of the first candidate set and the second candidate set to obtain a finely ranked candidate set. When the intersection size does not reach the preset threshold and the union size is within a preset condition, semantic reordering is performed within the union range to obtain a fallback candidate set. The fusion ranking module is used to perform weighted fusion ranking based on the retrieval scores and corresponding weight coefficients of the indicators in the candidate set obtained by dual-path recall gating decision retrieval in vector semantic retrieval, BM25 keyword retrieval, and dual-path recall gating decision retrieval, and output the ranked indicator retrieval results.
Citation Information
Patent Citations
Short message sample acquisition method and device
CN112329427A
Intellectual property retrieval system and retrieval method thereof
CN115221281A