A knowledge base dynamic synthesis method and device based on wisdom base theory integration, and an electronic device
Patent Information
- Application Number
- CN202511538953.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-27
- Publication Date
- 2026-08-21
- Estimated Expiration
- 2045-10-27
AI Technical Summary
问题1:数据信息获取渠道面窄,无法形成稳定体系化知识库;
[0018]本申请提供的基于智库理论集成的知识库动态合成方案,将用户输入的非结构化自然语言的产业咨询信息转化为结构化场景标签;基于结构化场景标签和预先设定的智库规则知识图谱,生成业务场景下的结构化特征指标集;基于所述结构化特征指标集、已设定的底层数据库数据字典以及指标和字段映射关系样本数据,生成特征指标与数据库字段映射表;从用户输入的非结构化自然语言的产业咨询信息中提取时间范围信息和空间范围信息;依据特征指标与数据库字段映射表,把时间范围和空间范围转化为数据库可执行的筛选条件;基于筛选条件、数据库查询结果以及业务场景下的结构化特征指标集生成结构化产业知识库。本发明提供的知识库动态合成方案,一方面,获取数据信息的渠道宽泛,能够形成稳定体系化知识库;第二方面,无需让人工梳理规则更新知识库,更新周期短,且可实现自动更新迭代;第三方面,相比现有的通过通用大模型生成知识库的方案,能够提升知识生成的准确率和专业性。
Smart Images

Figure CN121436115B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of interdisciplinary technology of machine learning and knowledge graphs, and in particular to a method, apparatus, and electronic device for dynamic synthesis of knowledge bases based on think tank theory integration. Background Technology
[0002] Current knowledge base construction is based on annotating and segmenting internal enterprise documents, relying on the enterprise's own accumulation, and cannot guarantee dynamic updates. Industry knowledge bases rely even more on experts to organize reports through surveys and research, which takes a long time and has a narrow range of information acquisition channels.
[0003] Existing methods for generating industry knowledge bases have the following problems: Problem 1: The channels for obtaining data and information are narrow, making it impossible to form a stable and systematic knowledge base; Question 2: Traditional solutions require manual revision of rules to update the knowledge base, which has a very long update cycle; Question 3: The rule base of the knowledge graph solution is statically stored. When a new scenario appears, rules need to be added manually and cannot be automatically updated and iterated, which causes the knowledge base to be unable to keep up with the needs of the scenario in a timely manner. Summary of the Invention
[0004] The purpose of this invention is to provide a method, apparatus, and electronic device for dynamic synthesis of knowledge bases based on think tank theory integration, which can solve at least one of the above-mentioned problems in the prior art.
[0005] To solve the above-mentioned technical problems, the present invention provides the following technical solution: This invention provides a method for dynamic synthesis of a knowledge base based on think tank theory integration, wherein the method includes: The unstructured natural language industry consulting information input by the user is transformed into structured scene tags; wherein, the structured scene tags include: industry field sub-tags and business scene sub-tags; Based on the structured scene tags and the pre-defined think tank rule knowledge graph, a set of structured feature indicators for business scenarios is generated, wherein the set of structured feature indicators includes the correspondence between business scenarios, industry ontology, and feature attributes. Based on the structured feature index set, the established underlying database data dictionary, and sample data of the index and field mapping relationship, a feature index and database field mapping table is generated. Extract time and spatial range information from the unstructured natural language industry consulting information input by the user; and convert the time and spatial range into database-executable filtering conditions based on the feature indicators and database field mapping table. A structured industry knowledge base is generated based on the filtering criteria, database query results, and the structured feature index set under the business scenario.
[0006] Optionally, the step of converting unstructured natural language industry consulting information input by the user into structured tags includes: Build a corpus of industry sectors and business scenarios, and construct a dictionary of industry-specific terms; The industry sectors and business scenarios of a predetermined number of unstructured natural language industry consulting information are labeled and classified in order to construct training sample data; A basic classification model is constructed, and the two classification models in the basic classification model are trained using the training sample data to generate a target classification model; wherein, the two classification models include an industry domain classification model and a business scenario classification model, and the classification accuracy of the two classification models is calculated using the cross-entropy loss function during the training process and the corresponding indicators are optimized. The trained target classification model is used to predict industry consulting information in unstructured natural language input by users and generate structured scene labels.
[0007] Optionally, the step of generating a set of structured feature indicators based on the structured scene labels and a pre-defined think tank rule knowledge graph includes: Construct an industry-based think tank rule knowledge graph; wherein the think tank rule knowledge graph includes: entities and relationships; the entities include: industry ontology, industry relationships and industry events; the relationships include: the relationship between business scenarios and industry ontology, the relationship between industry ontology and its characteristic attributes, the relationship between characteristic attributes and decomposed characteristic indicators, the relationship between characteristic indicators and think tank weights, and the relationship between characteristic indicators and data fields. The knowledge graph of the think tank rules is stored in a preset database; When a business scenario exists in the knowledge graph of the think tank rules that matches its authentication indicators, a structured set of feature indicators is generated by matching the correspondence between the business scenario and the feature indicators based on the database query statement. When there is no matching authentication indicator for the business scenario in the think tank rule knowledge graph, the target business scenario with the highest similarity in the think tank rule knowledge graph is determined, and the feature indicators of the target business scenario with the highest similarity are mapped to the business scenario to generate a structured feature indicator set.
[0008] Optionally, the step of generating a feature index-database field mapping table based on the structured feature index set, the pre-defined underlying database data dictionary, and sample data of the index-field mapping relationship includes: Construct a feature matching algorithm that enhances think tank theory; The feature matching algorithm enhanced by the aforementioned think tank theory is used to perform bidirectional matching between candidate fields and feature indicators to obtain semantic similarity, rule matching degree, and effectiveness. The confidence level of candidate fields is determined based on the semantic similarity, rule matching degree, and validity, and the feature index and database field mapping table is obtained by filtering based on the confidence level of candidate fields.
[0009] Optionally, the steps of extracting time-range and spatial-range information from the unstructured natural language industry consulting information input by the user, and converting the time-range and spatial-range information into database-executable filtering conditions based on the feature indicators and database field mapping table, include: The time and spatial information are extracted from industry consulting information in unstructured natural language input by users through a preset model; The time range information is converted into a standard date format using regular expressions, and the spatial range information is converted into a standard administrative region using regular expressions and the national administrative division knowledge base. The standard date format and the standard administrative region are the database's executable filtering criteria.
[0010] Optionally, the step of generating a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set under the business scenario includes: By using the feature indicators and the database field mapping table and the filtering conditions, raw data is extracted from the database to generate a structured data matrix; Based on the structured feature indicators in the business scenario, the target feature indicators whose weights meet the preset conditions; Find the index values corresponding to each target feature index from the structured data matrix to generate structured information points; An industrial knowledge base is generated based on a pre-defined think tank rule knowledge graph and the structured information points.
[0011] This application embodiment also provides a dynamic knowledge base synthesis device based on think tank theory integration, wherein the device includes: The conversion module is used to convert unstructured natural language industry consulting information input by the user into structured scene tags; wherein, the structured scene tags include: industry field sub-tags and business scene sub-tags; The first generation module is used to generate a set of structured feature indicators for a business scenario based on the structured scenario tags and a pre-set think tank rule knowledge graph. The set of structured feature indicators includes the correspondence between the business scenario, the industry ontology, and the feature attributes. The second generation module is used to generate a feature index and database field mapping table based on the structured feature index set, the established underlying database data dictionary, and sample data of the index and field mapping relationship. The filtering condition determination module is used to extract time range information and spatial range information from the unstructured natural language industry consulting information input by the user; and to convert the time range and spatial range into database-executable filtering conditions based on the feature indicators and the database field mapping table. The knowledge base generation module is used to generate a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set under the business scenario.
[0012] Optionally, the conversion module includes: The first submodule is used to build a corpus of industry sectors and business scenarios, and to build a dictionary of industry professional terms; The second submodule is used to label and classify the industry sectors and business scenarios of a preset number of unstructured natural language industry consulting information in order to construct training sample data. The third submodule is used to construct a basic classification model and train two classification models in the basic classification model using the training sample data to generate a target classification model. The two classification models include an industry domain classification model and a business scenario classification model. During the training process, the cross-entropy loss function is used to calculate the classification accuracy of the two classification models and optimize the corresponding indicators. The fourth submodule is used to predict industry consulting information in unstructured natural language input by users using the trained target classification model, and generate structured scene labels.
[0013] Optionally, the first generation module includes: The fifth submodule is used to construct an industry-based think tank rule knowledge graph. This graph includes entities and relationships. Entities include industry ontology, industry relationships, and industry events. Relationships include: the association between business scenarios and industry ontology; the association between industry ontology and its characteristic attributes; the association between characteristic attributes and their decomposed characteristic indicators; the association between characteristic indicators and think tank weights; and the association between characteristic indicators and data fields. The sixth submodule is used to store the think tank rule knowledge graph into a preset database; The seventh submodule is used to generate a structured feature indicator set by matching the business scenario and the feature indicator based on the database query statement when the business scenario has a matching authentication indicator in the think tank rule knowledge graph; when the business scenario does not have a matching authentication indicator in the think tank rule knowledge graph, it determines the target business scenario with the highest similarity in the think tank rule knowledge graph, maps the feature indicator of the target business scenario with the highest similarity to the business scenario, and generates a structured feature indicator set.
[0014] Optionally, the second generation module includes: The eighth submodule is used to construct a feature matching algorithm to enhance think tank theory; The ninth submodule is used to perform bidirectional matching of candidate fields and feature indicators using the feature matching algorithm enhanced by the think tank theory, so as to obtain semantic similarity, rule matching degree and effectiveness; The tenth submodule is used to determine the confidence level of candidate fields based on the semantic similarity, rule matching degree and validity, and to filter the candidate field confidence level to obtain the feature index and database field mapping table.
[0015] Optionally, the filter criteria determination module is specifically used for: The time and spatial information are extracted from industry consulting information in unstructured natural language input by users through a preset model; The time range information is converted into a standard date format using regular expressions, and the spatial range information is converted into a standard administrative region using regular expressions and the national administrative division knowledge base. The standard date format and the standard administrative region are the database's executable filtering criteria.
[0016] Optionally, the knowledge base generation module is specifically used for: By using the feature indicators and the database field mapping table and the filtering conditions, raw data is extracted from the database to generate a structured data matrix; Based on the structured feature indicators in the business scenario, the target feature indicators whose weights meet the preset conditions; Find the index values corresponding to each target feature index from the structured data matrix to generate structured information points; An industrial knowledge base is generated based on a pre-defined think tank rule knowledge graph and the structured information points.
[0017] This invention also provides an electronic device, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the steps of any of the above-described knowledge base dynamic synthesis methods based on think tank theory integration.
[0018] This application provides a dynamic knowledge base synthesis scheme based on think tank theory integration. It transforms user-inputted unstructured natural language industry consulting information into structured scenario tags; generates a set of structured feature indicators for business scenarios based on the structured scenario tags and a pre-defined think tank rule knowledge graph; generates a feature indicator-database field mapping table based on the structured feature indicator set, a pre-defined underlying database data dictionary, and sample data of indicator-field mapping relationships; extracts time and spatial range information from the user-inputted unstructured natural language industry consulting information; transforms the time and spatial ranges into database-executable filtering conditions according to the feature indicator-database field mapping table; and generates a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set for business scenarios. The dynamic knowledge base synthesis scheme provided by this invention has several advantages: firstly, it has broad channels for acquiring data information, enabling the formation of a stable and systematic knowledge base; secondly, it eliminates the need for manual rule updates, resulting in a short update cycle and automatic iteration; and thirdly, compared to existing schemes that generate knowledge bases through general large models, it improves the accuracy and professionalism of knowledge generation. Attached Figure Description
[0019] Figure 1 This is a flowchart illustrating the steps of a dynamic knowledge base synthesis method based on think tank theory integration, according to an embodiment of this application. Figure 2 This is a structural block diagram illustrating a knowledge base dynamic synthesis device based on think tank theory integration, according to an embodiment of this application. Detailed Implementation
[0020] To make the technical problems, technical solutions and advantages of the present invention clearer, a detailed description will be given below in conjunction with the accompanying drawings and specific embodiments.
[0021] This invention provides a dynamic knowledge base synthesis scheme based on think tank theory, involving the interdisciplinary fields of industrial knowledge engineering, natural language processing, machine learning, and knowledge graphs. It integrates industrial analysis think tank theory to achieve dynamic generation of industrial knowledge bases through "business scenario analysis - feature attribute mapping - data field association - knowledge synthesis," applicable to various industrial consulting scenarios such as investment promotion analysis, industrial chain graph construction, and risk warning. The core objective of this invention's dynamic knowledge base synthesis scheme is to construct a closed-loop system of "ontology definition - knowledge modeling - algorithm matching - knowledge synthesis," solving the core problem of industrial knowledge base generation through four modules and two innovative algorithms. The overall model design philosophy is based on "think tank theory as the core constraint, machine learning as the mining tool, and a large model as the knowledge synthesis carrier," achieving two core logics: 1. Scenario-driven: parsing business scenarios from user natural language and dynamically matching the think tank rules for that scenario; 2. Data anchoring: accurately associating scenario features with underlying database fields to ensure knowledge generation is based on real data.
[0022] The following description, in conjunction with the accompanying drawings, details the dynamic synthesis scheme for knowledge base based on think tank theory integration provided in this application through specific embodiments and application scenarios.
[0023] As attached Figure 1 As shown in the figure, the knowledge base dynamic synthesis method based on think tank theory integration in this application includes the following steps: Step 101: Convert the unstructured natural language industry consulting information input by the user into structured scene tags.
[0024] The structured scenario tags include: industry sector sub-tags and business scenario sub-tags.
[0025] This step primarily involves identifying the user's industry consulting intent and analyzing the business scenario. This part transforms the user's unstructured natural language (industry consulting language) into structured tags of "industry sector + business scenario," providing crucial information for subsequent feature attribute and database association. For example, if the user inputs the industry consulting information: "Analyze the characteristics of high-growth investment enterprises in the Yangtze River Delta region's artificial intelligence industry in 2023-2024," then the transformed structured scenario tags would have the industry sector sub-tag as "Artificial Intelligence" and the business scenario sub-tag as "Investment Analysis - High-Growth Enterprise Screening."
[0026] In one optional embodiment, converting unstructured natural language industry consulting information input by the user into structured tags may include the following sub-steps: Sub-step 1: Construct a corpus of industry sectors and business scenarios, and construct a dictionary of industry-specific terms.
[0027] Sub-step 2: Label and classify the industry sectors and business scenarios of a preset number of unstructured natural language industry consulting information to construct training sample data.
[0028] The specific value of the preset quantity can be set by those skilled in the art according to actual needs, and no specific limitation is made in this embodiment. For example, the preset quantity can be set to 5000, 2000, or 1000, etc.
[0029] Sub-steps 1 and 2 constitute the data preprocessing process. In actual implementation, a corpus of industry sectors and business scenarios can be built first, covering more than 100 industry maps and various business scenarios such as investment promotion, risk warning, enterprise cultivation, and relocation. Next, an enhanced domain dictionary is constructed: an industry-specific terminology dictionary is built, and the dictionary is prioritized for word segmentation using WordPiece to avoid industry-specific terms being split by the segmenter. Finally, the data is labeled: over 5000 natural language industry consulting questions categorized by industry sector and business scenario. WordPiece is the word segmentation algorithm used to pre-train BERT.
[0030] Sub-step 3: Construct a basic classification model, and use the training sample data to train the two classification models in the basic classification model to generate the target classification model.
[0031] The two classification models include an industry sector classification model and a business scenario classification model. During training, the cross-entropy loss function is used to calculate the classification accuracy of the two models and optimize the corresponding indicators.
[0032] Sub-step 3 involves model training. In the specific implementation, a basic classification model can be constructed first: a pre-trained multi-class BERT model, bert-base-chinese-classification-sst2, is used, and fine-tuned for industry domains and business scenarios, with two classification models fine-tuned respectively. Then, a loss function is constructed: the cross-entropy loss function is used to calculate the two indicators of industry domain classification accuracy and business scenario classification accuracy optimization target.
[0033] Sub-step 4: Use the trained target classification model to predict the unstructured natural language industry consulting information input by the user and generate structured scene labels.
[0034] In practical implementation, the input text is segmented, and the segmentation results are encoded using a fine-tuned BERT model. The classification head outputs a probability distribution, and the industry sector and business scenario with the highest probability are selected to form structured labels. For example, after inputting "Yangtze River Delta AI Investment Promotion High-Growth Enterprises", the probability of "Artificial Intelligence" is 0.95; the probability of "Investment Promotion Analysis - High-Growth Enterprise Screening" is 0.92; the output labels are: Artificial Intelligence, Investment Promotion Analysis - High-Growth Enterprise Screening.
[0035] Step 102: Based on structured scene tags and pre-defined think tank rule knowledge graphs, generate a set of structured feature indicators for business scenarios.
[0036] The structured feature index set includes the correspondence between business scenarios, industry ontology, and feature attributes.
[0037] This step involves mining the relationships between business scenarios, industry ontology, and feature attributes based on think tank theory. This process establishes an industry think tank relationship system based on industry analysis think tank theory, defining "business scenario → industry ontology → feature attributes → feature indicators," and clarifying the core dimensions to be analyzed in the current scenario. The target inputs are: the structured scenario tags output from step 101 and the pre-defined think tank rule knowledge graph; the target output is: a set of structured feature indicators. For example, the target output could be: Ontology: Enterprise, Feature Attribute: Innovation Capability, Feature Indicator: Number of Authorized Invention Patents, Think Tank Weight: 0.6.
[0038] In one optional embodiment, the method of generating a set of structured feature indicators based on structured scene labels and a pre-defined think tank rule knowledge graph may include the following sub-steps: Sub-step 1: Construct an industry-based think tank rule knowledge graph.
[0039] The think tank rule knowledge graph includes entities and relationships. The entities include industry ontology, industry relationships, and industry events. The relationships include: the relationship between business scenarios and industry ontology, the relationship between industry ontology and its characteristic attributes, the relationship between characteristic attributes and decomposed characteristic indicators, the relationship between characteristic indicators and think tank weights, and the relationship between characteristic indicators and data fields.
[0040] The industry itself can include, but is not limited to: enterprises, talents, universities, governments, and innovation platforms; industry relationships can include, but are not limited to: industrial chains, supply chains, talent chains, technology chains, and capital chains; and industry events can include, but are not limited to: relocation and investment promotion.
[0041] Sub-step 2: Store the industry-based think tank rule knowledge graph in a preset database.
[0042] After the industry-based think tank rule knowledge graph is constructed and stored, the rule query of business scenario-ontology-feature attribute is realized by combining rule reasoning (RBR) and new scenario adaptation (CBR). The specific execution process is shown in sub-steps 3 and 4.
[0043] Sub-step 3: When a business scenario has matching authentication indicators in the knowledge graph of the think tank rules, a structured feature indicator set is generated based on the database query statement to match the correspondence between the business scenario and the feature indicators. For the defined rule-based reasoning (RBR), based on the SPARQL query statement of the preset database, the relationship between business scenarios and feature indicators is matched to generate a set of structured feature indicators.
[0044] Sub-step 4: When there is no matching authentication indicator for the business scenario in the think tank rule knowledge graph, determine the target business scenario with the highest similarity in the think tank rule knowledge graph, map the feature indicators of the target business scenario with the highest similarity to the business scenario, and generate a structured feature indicator set.
[0045] When no matching rules exist for a business scenario in the think tank rule knowledge graph, it can be derived through case-based reasoning, i.e., new scenario adaptation CBR. The similarity between the new business scenario and the semantic descriptions of existing scenarios in the think tank rule knowledge graph is calculated. Word vector embeddings are then performed on the new and existing business scenario descriptions. This model supports multiple languages and can handle input data of different granularities, enabling text-embedded intensive retrieval, sparse / lexical retrieval, and multi-vector retrieval. Similarity is calculated based on cosine distance or Euclidean distance. Based on the calculated similarity, the feature mapping logic of the scenario with the highest similarity is reused to generate an initial set of structured feature indicators.
[0046] Step 103: Based on the structured feature indicator set, the established underlying database data dictionary, and the sample data of the indicator and field mapping relationship, generate a feature indicator and database field mapping table.
[0047] This step involves mining the mapping relationship between feature attributes and the industry data dictionary. This process can associate feature indicators with underlying database fields, supporting both direct and combined mapping. Examples of direct mapping include a one-to-one correspondence between indicators and fields, such as the mapping relationship between the number of financing rounds indicator and the number of financing rounds in the enterprise table. Examples of combined mapping include a one-to-many correspondence between indicators and multiple fields, such as the mapping relationship between the number of invention patents in 2023 and the applicant, application date, and patent type fields in the patent table. This ensures that feature indicators can be queried and calculated in the database. The target inputs for this step are the structured feature indicator set output from step 102, the pre-defined underlying database data dictionary, and sample data of indicator and field mapping relationships. The underlying database data dictionary contains information such as table names, table definitions, field names, field meanings, and data types. The target output for this step is the feature indicator-database field mapping table. For example: Feature indicator: Number of invention patents in 2023, associated table name: Patent table, associated field group: [Enterprise ID, Patent type, Application time], calculation rule: Patent type = 'Invention' and application time ∈ [2023-01-01, 2023-12-31].
[0048] In one optional embodiment, the method of generating a feature index to database field mapping table based on a structured feature index set, a pre-defined underlying database data dictionary, and sample data of index and field mapping relationships includes the following sub-steps: Sub-step 1: Construct a feature matching algorithm that enhances think tank theory.
[0049] A feature matching algorithm enhanced with think tank theory is constructed. This is mainly achieved through four steps: semantic embedding -> rule constraint -> bidirectional matching -> confidence calculation. Appropriate query fields are derived by combining semantic and industry rules. Semantic embedding: The training environment encodes feature metrics and database fields separately, using the BGEM3embedding model from Zhiyuan. The similarity S1 between the feature vector and the field vector is calculated based on cosine similarity. The formula is as follows:
[0050] in, For feature index vectors, S1 is a field vector, where S1 ∈ [0,1]. The larger S1 is, the stronger the correlation and semantic correlation.
[0051] Constraints of the think tank theoretical system: Extract constraint rules for current feature indicators from the already constructed think tank rule knowledge graph; Transform rules into field constraints: Map constraint rules to filtering conditions for database fields. Calculate the rule matching degree S2: The percentage of each field that satisfies the feature indicator constraint rules. The formula is as follows: S2 = N 满足约束条件的字段 / N特征指标关联的总字段 For example, the feature indicator "Number of Invention Patents in 2023" has two constraint rules: Rule 1: patent_type='Invention'; Rule 2: apply_date>='2023-01-01' AND apply_date<='2023-12-31'. This involves two fields: apply_date and patent_type, with S2 values of 0.5 and 0.5 respectively.
[0052] Sub-step 2: Employ a feature matching algorithm enhanced by think tank theory to perform bidirectional matching between candidate fields and feature indicators, obtaining semantic similarity, rule matching degree, and effectiveness.
[0053] This step is a two-way matching process, including forward verification and reverse verification. Forward verification: Candidate fields are selected based on semantic similarity S1 and rule matching degree S2. Reverse verification: Feature index values are actually calculated using the candidate fields to verify whether valid results can be retrieved. If the reverse verification passes, S3=1; otherwise, S3=0.
[0054] Sub-step 3: Determine the confidence level of candidate fields based on semantic similarity, rule matching degree, and validity, and filter the candidate fields based on their confidence level to obtain the feature index and database field mapping table.
[0055] This sub-step involves confidence calculation and mapping output. One feasible implementation is to take a weighted average of S1, S2, and S3, with the weights flexibly set by industry experts. For example, the weight of semantic similarity S1 is 0.4, the weight of rule matching S2 is 0.3, and the weight of reverse matching S3 is 0.3. Finally, the confidence score of each candidate field is calculated, and fields with a confidence score ≥ 0.7 are retained as query fields. It should be noted that the above weight values and the confidence threshold of 0.7 are merely illustrative examples. In actual implementation, those skilled in the art can flexibly set these values, and this application embodiment does not impose specific limitations on them.
[0056] Step 104: Extract time range and spatial range information from the unstructured natural language industry consulting information input by the user; based on the feature index and database field mapping table, convert the time range and spatial range into database-executable filtering conditions.
[0057] This step involves identifying and implementing the spatiotemporal range and filtering conditions. The aim is to extract time and spatial constraints from the user's natural language input and, combined with the field mapping table from the third step, transform the range into database-executable filtering conditions. In one optional embodiment, extracting time and spatial range information from unstructured natural language industry consulting information input by the user, and transforming the time and spatial range into database-executable filtering conditions based on feature indicators and the database field mapping table, may include the following sub-steps: Sub-step 1: Extract time-range and spatial-range information from the unstructured natural language industry consulting information input by the user using a preset model; The default model can be the BERT-NER model.
[0058] Sub-step 2: Convert the time range information into a standard date format using regular expressions, and convert the spatial range information into standard administrative regions using regular expressions and the national administrative division knowledge base.
[0059] The standard date format and standard administrative region are the database's executable filtering criteria. Sub-steps 1 and 2 ultimately generate the filtering criteria for the data query.
[0060] Step 105: Generate a structured industry knowledge base based on the filtering conditions, database query results, and structured feature indicator set under the business scenario.
[0061] This step primarily involves generating a knowledge base. The goal is to aggregate data, extract information, and generate knowledge based on database query results and think tank theories. The target input consists of the filtering criteria output from step 104, the database query results, and the characteristic indicators and think tank theoretical framework applicable to the business scenario. The target output is a structured industry knowledge base.
[0062] The construction of a structured industry knowledge base is essentially the construction of a knowledge generation model under a think tank constraint system. Specifically, it includes constructing a basic data layer, an information extraction layer, and a knowledge synthesis layer.
[0063] In one optional embodiment, the method of generating a structured industry knowledge base based on filtering conditions, database query results, and a set of structured feature indicators in the business scenario may include the following sub-steps: Sub-step 1: Extract raw data from the database and generate a structured data matrix by mapping feature indicators to database fields and filtering conditions; This sub-step involves building the basic data layer.
[0064] Sub-step 2: Based on the structured feature indicators in the business scenario, select the target feature indicators whose weights meet the preset conditions; Sub-step 3: Find the corresponding indicator values of each target feature indicator from the structured data matrix and generate structured information points; This sub-step involves constructing an information extraction layer.
[0065] Sub-step 4: Generate an industrial knowledge base based on the pre-defined think tank rule knowledge graph and structured information points.
[0066] This sub-step is the synthesis of the knowledge layer. One feasible implementation method is to input the think tank weights and analysis framework, as well as the structured information points generated in the information extraction layer, into the large model, combine the information points and the think tank analysis framework to generate a logical industrial knowledge representation, and finally output a structured industrial knowledge base.
[0067] The dynamic knowledge base synthesis method based on think tank theory integration provided in this application transforms unstructured natural language industry consulting information input by users into structured scene tags; generates a set of structured feature indicators for business scenarios based on the structured scene tags and a pre-defined think tank rule knowledge graph; generates a feature indicator-database field mapping table based on the structured feature indicator set, a pre-defined underlying database data dictionary, and sample data of indicator-field mapping relationships; extracts time range and spatial range information from the unstructured natural language industry consulting information input by users; transforms the time range and spatial range into database-executable filtering conditions according to the feature indicator-database field mapping table; and generates a structured industry knowledge base based on the filtering conditions, database query results, and the set of structured feature indicators for business scenarios. The dynamic knowledge base synthesis method based on think tank theory integration provided in this application has the following advantages: firstly, it has a wide range of data information acquisition channels, enabling the formation of a stable and systematic knowledge base; secondly, it eliminates the need for manual rule updating of the knowledge base, resulting in a short update cycle and enabling automatic iteration; and thirdly, compared to existing solutions that generate knowledge bases through general large models, it improves the accuracy and professionalism of knowledge generation.
[0068] The core difference between the dynamic knowledge base synthesis method based on think tank theory integration proposed in this application and existing technologies lies in "constructing a closed-loop association between scenario, feature, and data, constrained by think tank theory". The specific key improvements are as follows: Improvement 1: Innovative think tank-themed enhanced feature matching algorithm to solve the problem of feature-field correlation gaps: Existing technologies rely on manual configuration or single semantic matching, failing to achieve association driven by both semantics and rules. The think tank-themed enhanced feature matching algorithm avoids the limitations of semantic matching by: 1) integrating think tank rule constraints; and 2) using bidirectional matching and confidence calculation to ensure the verifiability of the association results. Improvement Point 2: Innovate the knowledge generation model under the constraint system of the think tank to solve the problem of the professionalism and authenticity of knowledge generation: Existing large-scale models for generating knowledge suffer from "illusions" and a lack of professionalism. Knowledge generation models under the constraints of a think tank system address these issues by: 1) Layered architecture: Data layer aggregation ensures knowledge is based on real data, information layer extraction ensures key indicators are not missed, and knowledge layer synthesis injects think tank logic; 2) Think tank constraints: Industry analysis weights are used as input to ensure knowledge conforms to a professional analysis framework; 3) Effect optimization: Compared with general large models, the accuracy and professionalism of knowledge generation are significantly improved.
[0069] Improvement point 3: Integrate think tank theory and knowledge graphs to solve the problem of scenario adaptability: Existing knowledge graph solutions use static rules, while this invention uses: 1) Construct a knowledge graph of rules for industry sectors, business scenarios, ontology, features, indicators, and data fields to achieve dynamic matching of scenarios and features; 2) Case-based reasoning (CBR) adapts to new scenarios: reuse logic from similar scenarios when there are no rules to reduce manual costs.
[0070] Figure 2 The structural block diagram of a knowledge base dynamic synthesis device based on think tank theory integration is shown in the embodiment of this application.
[0071] The knowledge base dynamic synthesis device based on think tank theory integration provided in this application includes the following functional modules; The conversion module 201 is used to convert unstructured natural language industry consulting information input by the user into structured scene tags; wherein, the structured scene tags include: industry field sub-tags and business scene sub-tags; The first generation module 202 is used to generate a set of structured feature indicators for a business scenario based on the structured scenario tags and a pre-set think tank rule knowledge graph. The set of structured feature indicators includes the correspondence between the business scenario, the industry ontology, and the feature attributes. The second generation module 203 is used to generate a feature index and database field mapping table based on the structured feature index set, the set underlying database data dictionary, and sample data of the index and field mapping relationship. The filtering condition determination module 204 is used to extract time range information and spatial range information from the unstructured natural language industry consulting information input by the user; and convert the time range and spatial range into database-executable filtering conditions based on the feature indicators and database field mapping table. The knowledge base generation module 205 is used to generate a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set under the business scenario.
[0072] Optionally, the conversion module includes: The first submodule is used to build a corpus of industry sectors and business scenarios, and to build a dictionary of industry professional terms; The second submodule is used to label and classify the industry sectors and business scenarios of a preset number of unstructured natural language industry consulting information in order to construct training sample data. The third submodule is used to construct a basic classification model and train two classification models in the basic classification model using the training sample data to generate a target classification model. The two classification models include an industry domain classification model and a business scenario classification model. During the training process, the cross-entropy loss function is used to calculate the classification accuracy of the two classification models and optimize the corresponding indicators. The fourth submodule is used to predict industry consulting information in unstructured natural language input by users using the trained target classification model, and generate structured scene labels.
[0073] Optionally, the first generation module includes: The fifth submodule is used to construct an industry-based think tank rule knowledge graph. This graph includes entities and relationships. Entities include industry ontology, industry relationships, and industry events. Relationships include: the association between business scenarios and industry ontology; the association between industry ontology and its characteristic attributes; the association between characteristic attributes and their decomposed characteristic indicators; the association between characteristic indicators and think tank weights; and the association between characteristic indicators and data fields. The sixth submodule is used to store the industry-based think tank rule knowledge graph into a preset database; The seventh submodule is used to generate a structured feature indicator set by matching the business scenario and feature indicators based on a database query statement when a business scenario has matching authentication indicators in the think tank rule knowledge graph; when a business scenario does not have matching authentication indicators in the think tank rule knowledge graph, it determines the target business scenario with the highest similarity in the think tank rule knowledge graph, maps the feature indicators of the target business scenario with the highest similarity to the business scenario, and generates a structured feature indicator set.
[0074] Optionally, the second generation module includes: The eighth submodule is used to construct a feature matching algorithm to enhance think tank theory; The ninth submodule is used to perform bidirectional matching of candidate fields and feature indicators using the feature matching algorithm enhanced by the think tank theory, so as to obtain semantic similarity, rule matching degree and effectiveness; The tenth submodule is used to determine the confidence level of candidate fields based on the semantic similarity, rule matching degree and validity, and to filter the candidate field confidence level to obtain the feature index and database field mapping table.
[0075] Optionally, the filter criteria determination module is specifically used for: The time and spatial information are extracted from industry consulting information in unstructured natural language input by users through a preset model; The time range information is converted into a standard date format using regular expressions, and the spatial range information is converted into a standard administrative region using regular expressions and the national administrative division knowledge base. The standard date format and the standard administrative region are the database's executable filtering criteria.
[0076] Optionally, the knowledge base generation module is specifically used for: By using the feature indicators and the database field mapping table and the filtering conditions, raw data is extracted from the database to generate a structured data matrix; Based on the structured feature indicators in the business scenario, the target feature indicators whose weights meet the preset conditions; Find the index values corresponding to each target feature index from the structured data matrix to generate structured information points; An industrial knowledge base is generated based on a pre-defined think tank rule knowledge graph and the structured information points.
[0077] The embodiments provided in this application Figure 2 The knowledge base dynamic synthesis device based on think tank theory integration shown can achieve... Figure 1 The various processes implemented in the method implementation examples will not be described again here to avoid repetition.
[0078] Optionally, embodiments of this application also provide an electronic device, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the processes executed by the aforementioned knowledge base dynamic synthesis device based on think tank theory integration, and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0079] Memory, used to store computer programs; When the processor executes the program stored in the memory, it implements the dynamic synthesis method of knowledge base based on think tank theory integration, which is executed by the processor in the above method embodiment.
[0080] The communication bus mentioned above can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. The communication interface is used for communication between the aforementioned terminal and other devices.
[0081] The memory may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0082] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0083] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0084] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for dynamic synthesis of knowledge bases based on think tank theory integration, characterized in that, The method includes: The unstructured natural language industry consulting information input by the user is transformed into structured scene tags; wherein, the structured scene tags include: industry field sub-tags and business scene sub-tags; Based on the structured scene tags and the pre-defined think tank rule knowledge graph, a set of structured feature indicators for business scenarios is generated, wherein the set of structured feature indicators includes the correspondence between business scenarios, industry ontology, and feature attributes. Based on the structured feature index set, the established underlying database data dictionary, and sample data of the index and field mapping relationship, a feature index and database field mapping table is generated. Extract time and spatial range information from the unstructured natural language industry consulting information input by the user; and convert the time and spatial range into database-executable filtering conditions based on the feature indicators and database field mapping table. A structured industry knowledge base is generated based on the filtering conditions, database query results, and the structured feature index set under the business scenario. The steps for generating a feature index-database field mapping table based on the structured feature index set, the established underlying database data dictionary, and sample data of index-field mapping relationships include: Construct a feature matching algorithm that enhances think tank theory; The feature matching algorithm enhanced by the aforementioned think tank theory is used to perform bidirectional matching between candidate fields and feature indicators to obtain semantic similarity, rule matching degree, and effectiveness. The confidence level of candidate fields is determined based on the semantic similarity, rule matching degree, and validity, and the mapping table between feature indicators and database fields is obtained by filtering based on the confidence level of candidate fields; The steps for generating a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set under the business scenario include: By using the feature indicators and the database field mapping table and the filtering conditions, raw data is extracted from the database to generate a structured data matrix; Based on the structured feature indicators in the business scenario, the target feature indicators whose weights meet the preset conditions; Find the index values corresponding to each target feature index from the structured data matrix to generate structured information points; Based on the pre-defined think tank rule knowledge graph and the structured information points, a structured industry knowledge base is generated; The steps for generating a set of structured feature indicators for a business scenario based on the structured scene tags and a pre-defined think tank rule knowledge graph include: When a business scenario has matching authentication indicators in the knowledge graph of the think tank rules, rule reasoning is used to match the correspondence between the business scenario and the feature indicators to generate a set of structured feature indicators. When there are no matching authentication indicators for a business scenario in the think tank rule knowledge graph, a new scenario adaptation method is used to determine the target business scenario with the highest similarity in the think tank rule knowledge graph. The feature indicators of the target business scenario with the highest similarity are then mapped to the business scenario to generate a structured feature indicator set.
2. The method according to claim 1, characterized in that, The steps to transform unstructured natural language industry consulting information input by users into structured tags include: Build a corpus of industry sectors and business scenarios, and construct a dictionary of industry-specific terms; The industry sectors and business scenarios of a predetermined number of unstructured natural language industry consulting information are labeled and classified in order to construct training sample data; A basic classification model is constructed, and the two classification models in the basic classification model are trained using the training sample data to generate a target classification model; wherein, the two classification models include an industry domain classification model and a business scenario classification model, and the classification accuracy of the two classification models is calculated using the cross-entropy loss function during the training process and the corresponding indicators are optimized. The trained target classification model is used to predict industry consulting information in unstructured natural language input by users and generate structured scene labels.
3. The method according to claim 1, characterized in that, The step of generating a set of structured feature indicators based on the structured scene labels and the pre-defined think tank rule knowledge graph further includes: Construct an industry-based think tank rule knowledge graph; wherein the think tank rule knowledge graph includes: entities and relationships; the entities include: industry ontology, industry relationships and industry events; the relationships include: the relationship between business scenarios and industry ontology, the relationship between industry ontology and its characteristic attributes, the relationship between characteristic attributes and decomposed characteristic indicators, the relationship between characteristic indicators and think tank weights, and the relationship between characteristic indicators and data fields. The knowledge graph of the think tank rules is stored in a preset database.
4. The method according to claim 1, characterized in that, The steps of extracting time and spatial range information from the unstructured natural language industry consulting information input by the user, and converting the time and spatial range into database-executable filtering conditions based on the feature indicators and database field mapping table, include: The time and spatial information are extracted from industry consulting information in unstructured natural language input by users through a preset model; The time range information is converted into a standard date format using regular expressions, and the spatial range information is converted into a standard administrative region using regular expressions and the national administrative division knowledge base. The standard date format and the standard administrative region are the database's executable filtering criteria.
5. A dynamic knowledge base synthesis device based on think tank theory integration, characterized in that, The device includes: The conversion module is used to convert unstructured natural language industry consulting information input by the user into structured scene tags; wherein, the structured scene tags include: industry field sub-tags and business scene sub-tags; The first generation module is used to generate a set of structured feature indicators for a business scenario based on the structured scenario tags and a pre-set think tank rule knowledge graph. The set of structured feature indicators includes the correspondence between the business scenario, the industry ontology, and the feature attributes. The second generation module is used to generate a feature index and database field mapping table based on the structured feature index set, the established underlying database data dictionary, and sample data of the index and field mapping relationship. The filtering condition determination module is used to extract time range information and spatial range information from the unstructured natural language industry consulting information input by the user; and to convert the time range and spatial range into database-executable filtering conditions based on the feature indicators and the database field mapping table. The knowledge base generation module is used to generate a structured industry knowledge base based on the filtering conditions, database query results, and the structured feature indicator set under the business scenario. The knowledge base generation module is specifically used for: By using the feature indicators and the database field mapping table and the filtering conditions, raw data is extracted from the database to generate a structured data matrix; Based on the structured feature indicators in the business scenario, the target feature indicators whose weights meet the preset conditions; Find the index values corresponding to each target feature index from the structured data matrix to generate structured information points; Based on the pre-defined think tank rule knowledge graph and the structured information points, a structured industry knowledge base is generated; The second generation module includes: The eighth submodule is used to construct a feature matching algorithm to enhance think tank theory; The ninth submodule is used to perform bidirectional matching of candidate fields and feature indicators using the feature matching algorithm enhanced by the think tank theory, so as to obtain semantic similarity, rule matching degree and effectiveness; The tenth submodule is used to determine the confidence level of candidate fields based on the semantic similarity, rule matching degree and validity, and to filter and obtain the feature index and database field mapping table based on the confidence level of candidate fields; The first generation module includes: The seventh submodule is used to generate a structured feature indicator set by using rule reasoning to match the correspondence between the business scenario and the feature indicators when the business scenario has matching authentication indicators in the think tank rule knowledge graph; when the business scenario does not have matching authentication indicators in the think tank rule knowledge graph, it determines the target business scenario with the highest similarity in the think tank rule knowledge graph through a new scenario adaptation method, maps the feature indicators of the target business scenario with the highest similarity to the business scenario, and generates a structured feature indicator set.
6. The apparatus according to claim 5, characterized in that, The conversion module includes: The first submodule is used to build a corpus of industry sectors and business scenarios, and to build a dictionary of industry professional terms; The second submodule is used to label and classify the industry sectors and business scenarios of a preset number of unstructured natural language industry consulting information in order to construct training sample data. The third submodule is used to construct a basic classification model and train two classification models in the basic classification model using the training sample data to generate a target classification model. The two classification models include an industry domain classification model and a business scenario classification model. During the training process, the cross-entropy loss function is used to calculate the classification accuracy of the two classification models and optimize the corresponding indicators. The fourth submodule is used to predict industry consulting information in unstructured natural language input by users using the trained target classification model, and generate structured scene labels.
7. The apparatus according to claim 6, characterized in that, The first generation module also includes: The fifth submodule is used to construct an industry-based think tank rule knowledge graph. This graph includes entities and relationships. Entities include industry ontology, industry relationships, and industry events. Relationships include: the association between business scenarios and industry ontology; the association between industry ontology and its characteristic attributes; the association between characteristic attributes and their decomposed characteristic indicators; the association between characteristic indicators and think tank weights; and the association between characteristic indicators and data fields. The sixth submodule is used to store the think tank rule knowledge graph into a preset database.
8. An electronic device, comprising a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of the knowledge base dynamic synthesis method based on think tank theory integration as described in any one of claims 1-4.
Citation Information
Patent Citations
Industrial manufacturing general intelligent decision collaborative optimization system based on brain-like inspiration
CN113743883A
Scientific and technological service field knowledge base construction method and system based on knowledge graph and RAG
CN119940500A