An efficient interaction method and system for connecting a large model with multi-source data
By constructing dynamic parsing templates and semantic association graphs, the problem of integrating large models with multi-source heterogeneous data was solved, achieving efficient and accurate data interaction, improving the response quality and adaptability of large models, and promoting the in-depth application of artificial intelligence technology.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-23
- Publication Date
- 2026-03-20
AI Technical Summary
Existing technologies lack a unified and efficient processing framework when connecting large models with multi-source heterogeneous data. They cannot effectively integrate the format features and semantic connotations of different types of data, resulting in one-sided or redundant information. Furthermore, they lack dynamic adaptability and are unable to cope with changes in data format and semantics, thus affecting the response quality of large models.
We construct dynamic parsing templates and semantic association graphs, and perform hierarchical parsing of multi-source heterogeneous data through format constraint sub-templates and semantic mapping sub-templates to generate multi-source data interaction sequences. We also optimize the generation strategy by dynamically adjusting attention weights and interaction response results to achieve efficient interaction between large models and multi-source data.
It improves the ability of large models to process complex data and the consistency of response results, enhances the adaptability and accuracy of models, provides precise decision support for professional users in different fields, and promotes the widespread application of artificial intelligence technology.
Smart Images

Figure CN120996012B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of artificial intelligence, more specifically, the present application relates to an efficient interaction method and system connecting large models and multi-source data. BACKGROUND
[0002] With the rapid development of artificial intelligence technology, large models have been widely applied in natural language processing, image recognition, intelligent decision-making and other fields. In the modern information environment, data presents multi-source heterogeneous characteristics, including structured data (such as database records), semi-structured data (such as XML / JSON files) and unstructured data (such as text, images). Efficiently connecting large models and multi-source data has become a key challenge for the landing of artificial intelligence applications. In recent years, various data processing and model interaction technologies have emerged, aiming to improve the understanding and processing ability of large models for complex data. However, the existing technology still has many shortcomings in practical application.
[0003] Traditional large model data interaction methods often lack a unified and efficient processing framework when facing heterogeneous data. For example, in the enterprise intelligent analysis scene, data may come from structured business databases, semi-structured API interfaces and unstructured document materials, while existing methods usually adopt fragmented processing strategies, which cannot effectively integrate the format characteristics and semantic connotations of different types of data, resulting in one-sided or redundant information input into the large model. In addition, existing technologies rely too much on preset templates in data parsing, lack of dynamic adaptation ability, and are difficult to adapt to changes in data format and semantics, which may lead to the loss or misunderstanding of important information, affecting the response quality of the large model.
[0004] At the same time, the existing technology has obvious shortcomings in the semantic association analysis of multi-source data. The key to large models understanding data lies in capturing the semantic relationship between different data sources, such as the association between customer records in business data and user feedback on social media. However, existing systems lack the ability to model such cross-source semantic relationships, often treating data from different sources in isolation, and cannot build a comprehensive view reflecting real-world semantic associations. This lack of semantic integration of interaction methods may lead to one-sided or contradictory responses of the large model, especially in complex scenarios that require comprehensive judgment, which seriously limits the practicality of the model.
[0005] Moreover, the existing large model interaction method often adopts a static input strategy, which is difficult to adaptively adjust according to the model response. For example, the system may not be able to dynamically optimize the input method of data or reorganize the information structure according to the preliminary response of the large model, resulting in low interaction efficiency. In terms of attention mechanism, the existing technology adopts fixed weight allocation, lacks dynamic evaluation of data importance, and cannot flexibly adjust the focus according to the semantic changes in the interaction process. This lack of feedback optimization of the interaction mechanism not only reduces the response quality of the system, but also wastes computing resources, and even produces misleading results due to the neglect of key information.
[0006] In view of this, the present application proposes an efficient interaction method and system connecting large models and multi-source data to solve the above problems. SUMMARY
[0007] In order to overcome the above-mentioned defects of the prior art, in order to achieve the above-mentioned purpose, the present application provides the following technical solutions:
[0008] An efficient interaction method connecting large models and multi-source data, comprising:
[0009] Step S1: collecting data from data sources connected to the target large model to obtain multi-source heterogeneous data, the multi-source heterogeneous data including three types of data: structured data, semi-structured data and unstructured data;
[0010] Step S2: constructing a dynamic parsing template according to the format characteristics and semantic characteristics of each type of data in the multi-source heterogeneous data, the dynamic parsing template including a format constraint sub-template and a semantic mapping sub-template;
[0011] Step S3: based on the constructed dynamic parsing template, performing hierarchical parsing on the corresponding multi-source heterogeneous data to obtain standard data units corresponding to each type of data, the standard data units including formatted data segments and semantic labels;
[0012] Step S4: constructing a multi-source data semantic association graph according to the obtained semantic labels, and generating a multi-source data interaction sequence according to the topological structure of the multi-source data semantic association graph and combining the obtained formatted data segments;
[0013] Step S5: inputting the multi-source data interaction sequence into the target large model, and updating the input attention weight of the target large model to obtain the interaction response result between the corresponding large model and the multi-source data interaction sequence, the interaction response result including classification results, generation results and reasoning results;
[0014] Step S6: optimizing the generation strategy of the corresponding multi-source data interaction sequence according to the semantic consistency between the interaction response result and the multi-source data semantic association graph.
[0015] Further, the construction process of the dynamic parsing template includes:
[0016] The format features of each type of data in the collected multi-source heterogeneous data are extracted, and a format constraint sub-template is constructed based on the extracted format features; the format constraint sub-template includes separator matching rules and nested level parsing rules; the format features include data separators, nested levels, and field lengths;
[0017] Meanwhile, the semantic features of each type of data in the collected multi-source heterogeneous data are extracted, and a semantic mapping sub-template is constructed according to the semantic features; the semantic mapping sub-template includes keyword semantic vectors and entity relationship weights;
[0018] The format constraint sub-template and the semantic mapping sub-template are combined to obtain a dynamic parsing template corresponding to the data type.
[0019] Further, the process of hierarchical parsing of the corresponding multi-source heterogeneous data based on the constructed dynamic parsing template includes:
[0020] The format constraint sub-template is used to perform format feature segmentation on the type data to obtain initial data segments; and the semantic mapping sub-template is used to perform semantic feature extraction on the corresponding initial data segments to obtain semantic labels;
[0021] According to the correspondence between the initial data segments and the semantic labels, a standard data unit is constructed; and the constructed standard data unit is stored hierarchically.
[0022] Further, the construction process of the multi-source data semantic association graph includes:
[0023] The semantic labels in the standard data unit are taken as nodes to construct an initial semantic node set; the semantic association strength between any two nodes in the initial semantic node set is obtained, and a directed edge between the semantic labels is constructed according to the semantic association strength;
[0024] The initial semantic node set and the directed edge are topologically optimized to obtain a multi-source data semantic association graph; the topological optimization includes semantic sub-graph division based on the initial semantic node set, and local clustering of the divided semantic sub-graphs.
[0025] Further, the process of obtaining a multi-source data interaction sequence includes:
[0026] The multi-source data semantic association graph is path traversed to obtain a plurality of semantic association paths, the semantic association paths including node sequences sorted according to the weights of the directed edges;
[0027] According to the node sequence in the semantic association path, a formatted data segment of a corresponding standard data unit is extracted to generate an initial interaction data block, and semantic compression is performed on the initial interaction data block to obtain a compressed interaction data block;
[0028] According to the edge weight of each semantic association path in the multi-source data semantic association graph, the compressed interaction data block is sorted to generate a multi-source data interaction sequence.
[0029] Further, the process of obtaining an interaction response result includes:
[0030] For each compressed interaction data block in the obtained multi-source data interaction sequence, a semantic feature vector corresponding to the compressed interaction data block is extracted;
[0031] According to the type data corresponding to the compressed interaction data block, the field weight of the structured data corresponding to the compressed interaction data block, the hierarchical weight of the semi-structured data corresponding to the compressed interaction data block, and the semantic weight of the unstructured data corresponding to the compressed interaction data block are calculated respectively;
[0032] According to the correlation between the semantic feature vector and the input layer neuron of the large model, the field weight, the hierarchical weight, and the semantic weight are combined to calculate the attention weight of each interaction data block;
[0033] The semantic feature vector of the compressed interaction data block is enhanced to obtain an enhanced semantic feature vector, and the attention weight is updated based on the dot product of the enhanced semantic feature vector and the weight vector of the input layer neuron;
[0034] Based on the attention weight, the multi-source data interaction sequence is inputted with weight to obtain an initial response result of the large model, and the initial response result is subjected to semantic consistency verification to obtain a final interaction response result.
[0035] Further, the process of optimizing the generation process of the corresponding multi-source data interaction sequence includes:
[0036] According to the matching degree between the semantic vector corresponding to the interaction response result and the semantic vector corresponding to each semantic label in the multi-source data semantic association graph, redundant interaction data blocks in the multi-source data interaction sequence are identified;
[0037] According to the confidence distribution corresponding to the interaction response result, compressed interaction data blocks with low semantic importance in the multi-source data interaction sequence are identified, and corresponding data optimization suggestions are generated through internal gradient analysis of the large model;
[0038] The semantic association paths corresponding to the redundant interaction data blocks and the compressed interaction data blocks with low semantic importance are pruned, and the multi-source data interaction sequence is regenerated according to the pruned multi-source data semantic association graph.
[0039] The generation strategy of the multi-source data interaction sequence is updated by comparing the semantic consistency between the regenerated multi-source data interaction sequence and the corresponding interaction response result of the original multi-source data interaction sequence.
[0040] Further, the process of semantic consistency checking includes:
[0041] The semantic vector of the initial response result is obtained, and the cosine similarity between the semantic vector corresponding to the initial response result and the semantic vector corresponding to the original multi-source data interaction sequence is obtained.
[0042] A preset consistency threshold is set. If the consistency degree is less than the preset consistency threshold, the response result of the large model is reacquired, and the process is repeated. If the consistency degree is not less than the preset consistency threshold, the corresponding initial response result is output as the final interaction response result.
[0043] Further, the process of dividing the semantic subgraph based on the initial semantic node set and locally clustering the divided semantic subgraph includes:
[0044] The nodes corresponding to each semantic label in the initial semantic node set are clustered to obtain the local clustering coefficient corresponding thereto. The initial directed weighted graph corresponding to the initial semantic node set is divided into a plurality of semantic subgraphs according to the local clustering coefficient.
[0045] The semantic importance score corresponding to each node in the semantic subgraph is obtained. The directed edge weight corresponding to the node is also obtained, and the semantic centrality is calculated based thereon. The nodes in the semantic subgraph are locally clustered according to the semantic centrality, and the structured representation of the semantic cluster is established, including cluster members, boundaries and representative node information.
[0046] An efficient interaction system connecting a large model and multi-source data includes:
[0047] A data acquisition module for acquiring data from a data source connected to a target large model to obtain multi-source heterogeneous data, the multi-source heterogeneous data including three types of data: structured data, semi-structured data and unstructured data.
[0048] A template construction module for constructing a dynamic parsing template according to the format characteristics and semantic characteristics of each type of data in the multi-source heterogeneous data, the dynamic parsing template including a format constraint sub-template and a semantic mapping sub-template.
[0049] A data parsing module for hierarchical parsing of corresponding multi-source heterogeneous data based on the constructed dynamic parsing template to obtain standard data units corresponding to each type of data, the standard data units including formatted data segments and semantic labels.
[0050] a topology analysis module configured to construct a multi-source data semantic association graph based on the obtained semantic labels, and generate a multi-source data interaction sequence based on the topology of the multi-source data semantic association graph and in combination with the obtained formatted data segments;
[0051] a data interaction module configured to input the multi-source data interaction sequence into a target large model, and obtain an interaction response result between the corresponding large model and the multi-source data interaction sequence by updating the input attention weight of the target large model, the interaction response result including a classification result, a generation result, and an inference result;
[0052] an interaction feedback module configured to optimize the generation strategy of the corresponding multi-source data interaction sequence based on the semantic consistency between the interaction response result and the multi-source data semantic association graph.
[0053] The technical effects and advantages of the efficient interaction method and system connecting a large model and multi-source data of the present application are as follows:
[0054] The present application addresses the challenges of large model processing multi-source heterogeneous data, improves the adaptability and accuracy of data interaction, and provides strong support for the application of large models in complex data environments. By constructing dynamic parsing templates and semantic association graphs, the system can accurately identify the semantic relationships between different types of data, avoiding information understanding bias or omission caused by data format and structure differences. This not only improves the processing capacity of large models for complex data, but also enhances the consistency and reliability of the response results, enabling the model to more effectively integrate multi-source information and generate more comprehensive and accurate analysis results;
[0055] In addition, the dynamic attention weight adjustment and interaction sequence optimization mechanism enables the system to adaptively adjust according to actual needs, providing more accurate decision support for professional users in different fields. This intelligent data interaction framework not only improves the accuracy and reliability of large model applications, but also provides a technical foundation for cross-domain knowledge integration and innovation exploration, promoting the expansion of artificial intelligence technology to deeper levels and wider application scenarios. BRIEF DESCRIPTION OF DRAWINGS
[0056] Figure 1 Fig. 1 is a schematic diagram of an efficient interaction method connecting a large model and multi-source data of the present application;
[0057] Figure 2 Fig. 2 is a schematic diagram of an efficient interaction system connecting a large model and multi-source data of the present application. DETAILED DESCRIPTION
[0058] With reference to the accompanying drawings, the technical solutions in the embodiments of the present application will be described clearly and completely. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of the present application.
[0059] Embodiment 1
[0060] Please refer to Figure 1 The high-efficiency interaction method for connecting a large model and multi-source data described in the embodiment includes the following steps.
[0061] Step S1: data collection is performed on data sources connected to a target large model to obtain multi-source heterogeneous data, and the multi-source heterogeneous data includes three types of data, i.e., structured data, semi-structured data and unstructured data.
[0062] Step S2: a dynamic analysis template is constructed according to the format characteristics and semantic characteristics of each type of data in the multi-source heterogeneous data, and the dynamic analysis template includes a format constraint sub-template and a semantic mapping sub-template.
[0063] Step S3: hierarchical analysis is performed on the corresponding multi-source heterogeneous data based on the constructed dynamic analysis template to obtain standard data units corresponding to each type of data, and the standard data units include formatted data segments and semantic labels.
[0064] Step S4: a multi-source data semantic association graph is constructed according to the obtained semantic labels, and a multi-source data interaction sequence is generated according to the topological structure of the multi-source data semantic association graph and in combination with the obtained formatted data segments.
[0065] Step S5: the multi-source data interaction sequence is input into the target large model, and an interaction response result between the corresponding large model and the multi-source data interaction sequence is obtained by updating the input attention weight of the target large model, and the interaction response result includes a classification result, a generation result and a reasoning result.
[0066] Step S6: the generation process of the corresponding multi-source data interaction sequence is optimized according to the semantic consistency between the interaction response result and the multi-source data semantic association graph.
[0067] The application realizes efficient input of a large model through multi-source heterogeneous data collection and processing, constructs a dynamic analysis template and a semantic association graph to provide a structured basis for multi-source data interaction, generates an interaction sequence based on semantic association strength to enable input to have semantic organization ability, dynamically divides data units to adapt to the format and semantic characteristics of different types of data, combines format constraints and semantic mapping to extract cross-modal features, improves the comprehensiveness of data interaction, the semantic association graph analysis considers the semantic connection between data to ensure the consistency of interaction, solves the limitations of traditional single feature interaction through deep change feature and semantic consistency analysis, the multi-source data interaction sequence enhances the reliability and accuracy of the large model response, and the generation strategy optimization based on the interaction response result improves the system adaptability and efficiency.
[0068] It should be further pointed out that, in the specific implementation process, the acquisition process of multi-source heterogeneous data includes the following steps:
[0069] Obtain structured data from the data source connected to the target large model, obtain a structured data set, and perform field type identification and data cleaning on the structured data set to obtain standardized structured data;
[0070] Obtain semi-structured data from the data source connected to the target large model, obtain a semi-structured data set, and perform label extraction and nested level analysis on the semi-structured data set to obtain standardized semi-structured data;
[0071] Obtain unstructured data from the data source connected to the target large model, obtain an unstructured data set, and perform content segmentation and key information extraction on the unstructured data set to obtain standardized unstructured data;
[0072] Perform metadata labeling on the standardized structured data, standardized semi-structured data and standardized unstructured data to obtain multi-source heterogeneous data with metadata labels, and organize the multi-source heterogeneous data with metadata labels according to the collection time and data source.
[0073] In this embodiment, first, data collection terminals are deployed in various data sources (such as databases, API interfaces, file systems, etc.) connected to the target large model, which are used to capture various structured data. Structured data is obtained through SQL query, database connector or structured API call to form a structured data set containing explicit fields and records. The obtained structured data set is processed to identify the data types of each field (such as numeric type, character type, time type, etc.), and abnormal values, missing values and duplicate records are removed to ensure data quality, forming structured data;
[0074] Meanwhile, semi-structured data is collected in the target data source, the semi-structured data is obtained through an XML / JSON parser, a web crawler or a document API, a semi-structured data set containing labels and hierarchical structures is generated, label extraction is performed on the obtained semi-structured data set, key nodes and attributes are identified, nested levels of the data are analyzed, a tree structure representation is constructed, and semi-structured data is formed;
[0075] Unstructured data is collected in the related data source, the unstructured data is obtained through a text extractor, an image processing API or an audio transcription service, an unstructured data set containing natural language text, images, audio and other contents is formed, content segmentation is performed on the obtained unstructured data set, long text is divided into paragraphs or semantic units, key information (such as topics, entities, relationships, etc.) is extracted, and unstructured data is formed;
[0076] Then, metadata labeling technology is used to add uniform metadata labels to the three types of data, including data source information, timestamps, data types, topic classifications and the like, so that different types of data have a uniform meta-information framework, multi-source heterogeneous data with metadata labels is formed, and finally the multi-source heterogeneous data with metadata labels is organized according to collection time and data source, time sequence index and data source index are constructed, and structured multi-source heterogeneous data sets are formed. These multi-source heterogeneous data collectively constitute the basic data source for large model interaction, and provide a comprehensive data basis for subsequent dynamic parsing template construction and semantic analysis.
[0077] It should be further explained that, in the specific implementation process, the construction process of the dynamic parsing template includes the following steps:
[0078] Format feature extraction is performed on each type of data in the collected multi-source heterogeneous data, and a format constraint sub-template is constructed based on the extracted format features; the format constraint sub-template includes separator matching rules and nested level analysis rules; the format features include data separators, nested levels and field lengths;
[0079] Meanwhile, semantic feature extraction is performed on each type of data in the collected multi-source heterogeneous data, and a semantic mapping sub-template is constructed according to the semantic features; the semantic mapping sub-template includes keyword semantic vectors and entity relationship weights;
[0080] The format constraint sub-template and the semantic mapping sub-template are combined to obtain a dynamic parsing template corresponding to the data type.
[0081] In this embodiment, first, format analysis (such as field splitter, type identifier) is applied to structured data, data separator (such as comma, tab, semicolon, etc.) is identified, field length distribution and value range are analyzed, and data format features are extracted; for semi-structured data, a pre-built structure parser (such as XML / JSON parser) is applied, label hierarchy, nesting relationship and tree structure features are identified, and nesting level information is extracted; for unstructured data, text format analysis (such as paragraph analysis, syntax parsing, etc.) is applied, the structure division and data format of the content are identified; and based on this, format features corresponding to each type of data are formed, including data separator, nesting level and field length, etc.
[0082] Based on the extracted format features, different separator matching rules and nesting level analysis rules are set for each type of data; for example: for structured data, regular expression patterns are constructed for accurate matching of field separators and data formats; for semi-structured data, tree parsing rules are constructed, including node path expression and nesting level navigation rules; for unstructured data, content segmentation rules are constructed, such as segmentation patterns based on paragraph markers, chapter division or semantic boundaries; and by combining these rules, format constraint sub-templates are formed;
[0083] At the same time, key field recognition is performed on structured data, and the semantic meaning of field name and value is analyzed; for semi-structured data, label semantic analysis is performed to identify the hierarchical relationship and semantic connection between semantic labels; for unstructured data, natural language processing techniques (such as named entity recognition, relation extraction, dependency syntax analysis, etc.) are applied to extract key word distribution, entity relationship and context dependency structure in the text, obtain semantic features of each type of data, then convert the key words into semantic vector representation, capture the semantic information and context relationship of the words; graph network is applied to model entity relationships, learn the relationship strength and semantic importance between entities, calculate the context dependency degree, and use it as the entity relationship weight to quantify the importance and dependency of words or entities in the context, and combine these semantic representations to form semantic mapping sub-templates; during the semantic extraction process of each type of data, pre-trained language models and knowledge graphs are used for assistance to improve the semantic richness and accuracy of the features;
[0084] Finally, according to the type of data and feature distribution, the weight proportion of format constraint and semantic mapping is dynamically adjusted; and based on this, the parsing results of the format constraint sub-template and the semantic results of the semantic mapping sub-template are integrated; a dynamic parsing template specific to the type of data is constructed, which contains format constraint rules and semantic mapping relationships, forming a complete dynamic parsing framework. This dual-template construction method based on format features and semantic features can accurately capture the structural features and semantic connotations of different types of data, providing accurate guidance for subsequent hierarchical parsing and improving the adaptability of the system to complex heterogeneous data.
[0085] It needs to be further explained that, in the specific implementation process, the process of hierarchical parsing of the corresponding multi-source heterogeneous data based on the constructed dynamic parsing template includes:
[0086] Based on the constructed format constraint sub-template, the type data is segmented according to format features to obtain initial data segments; and based on the constructed semantic mapping sub-template, the semantic features of the corresponding initial data segments are extracted to obtain semantic labels;
[0087] According to the corresponding relationship between the initial data segments and the semantic labels, a standard data unit is constructed; and the constructed standard data unit is stored hierarchically, including storing the standard data unit to different cache layers based on the priority of the semantic labels, wherein the priority is determined by the semantic importance score of the semantic labels, and the semantic importance score is calculated by the occurrence frequency and context dependence of the semantic labels in the multi-source heterogeneous data.
[0088] In this embodiment, the data type is segmented according to format features based on the constructed format constraint template to obtain initial data segments. Format feature segmentation divides data into basic units according to the identified separators and nested structures, and these units are the smallest processing granularity of data. The segmentation process adopts a bottom-up strategy, first identifies the most basic field separator, and then processes the nested structure level by level to ensure the integrity and accuracy of the segmentation; for example: for structured data, apply the separator matching rule in the format constraint sub-template to split the data into multiple field values according to the field separator; for semi-structured data, apply the nested level parsing rule to parse XML / JSON and other data into node and attribute sets; for unstructured data, apply content segmentation to segment text into paragraphs, sentences or semantic units;
[0089] Based on the constructed semantic mapping template, the semantic features of the corresponding initial data segments are extracted to obtain semantic labels; the semantic labels include entity categories (such as people, organizations, places, times, etc.) and relationship categories (such as subordinate relationship, causal relationship, time sequence relationship, etc.); the extraction process uses pre-trained language models and knowledge graphs to map data segments to semantic space, identify their semantic categories and relationship attributes; for example: apply the semantic mapping template to the obtained initial data segments to identify key concepts and semantic units, and mark entity categories (such as names, places, times, organizations, etc.); use relationship extraction technology to identify the relationship categories (such as subordinate relationship, causal relationship, etc.) between entities to obtain the semantic labels of the initial data segments;
[0090] According to the correspondence between the initial data segments and the semantic labels, a standard data unit is constructed; the construction process establishes the correspondence between the fields and the entities / relationships by analyzing the mapping relationship between the initial data segments and the semantic labels; the integrity index of each field is calculated, including the field missing rate (proportion of null values) and the redundancy rate (proportion of repeated information); the integrity threshold (such as missing rate <10% and redundancy rate <20%) is set, and the initial data segments that meet the threshold are screened; the screened field set and the corresponding semantic labels are combined to construct a standard data unit, and each standard data unit contains a formatted data segment and a corresponding semantic label;
[0091] Then, by analyzing the occurrence frequency and context dependence of each semantic label in the corresponding multi-source heterogeneous data, and by weighting and summing the occurrence frequency and context dependence, a semantic importance score is obtained to determine the priority of the semantic label.
[0092] A multi-layer cache storage architecture is designed, such as a high-priority cache layer (for storing standard data units corresponding to high-importance semantic labels), a medium-priority cache layer, and a low-priority cache layer; according to the priority of the semantic labels, the standard data units are allocated to the corresponding cache layers; and the cache strategy is optimized, such as using faster storage media or higher access frequency for the high-priority layer. Through this hierarchical storage method based on semantic importance, the standard data units of heterogeneous data can be efficiently managed and accessed, providing a structured and prioritized data foundation for subsequent semantic association graph construction and interactive sequence generation, improving the efficiency of large models interacting with multi-source data.
[0093] It should be further explained that in the specific implementation process, the construction process of the multi-source data semantic association graph includes the following steps:
[0094] The semantic labels in the standard data unit are taken as nodes to construct an initial semantic node set; the semantic association strength between any two nodes in the initial semantic node set is obtained, and a directed edge between the semantic labels is constructed according to the semantic association strength;
[0095] Based on the initial semantic node set and the directed edge, topological optimization is performed to obtain a multi-source data semantic association graph; the topological optimization includes semantic subgraph division based on the initial semantic node set, and local clustering of the divided semantic subgraphs.
[0096] In this embodiment, first, the semantic labels in all standard data units are collected, duplicate labels are removed, unique identifiers are established, and an initial semantic node set is formed. The semantic node set is composed of a plurality of nodes, and the nodes contain label ID, semantic category, semantic vector, and semantic importance score, etc.
[0097] For each node in the set, extract its semantic vector, and calculate the cosine similarity between the semantic vectors of any two nodes; analyze the co-occurrence frequency of any two nodes in multi-source heterogeneous data, i.e., the frequency of two labels appearing in the same standard data unit or context at the same time; design a weighted formula, such as semantic correlation strength = a x cosine similarity + b x normalized co-occurrence frequency, where a and b are weight parameters, to obtain the semantic correlation strength between the corresponding nodes; wherein the weight parameters are dynamically adjusted according to the data characteristics, and the semantic similarity weight is usually 0.6-0.7, and the co-occurrence frequency weight is usually 0.3-0.4, to ensure that the correlation strength considers both semantic and statistical factors.
[0098] Then analyze the context relationship of the semantic labels in the original data, such as determining the dependency direction between the semantic labels through dependency syntax analysis or sequence position relationship;
[0099] Set direction determination rules, such as information flow direction (from descriptive labels to specific instances) or causal relationship (from cause to result), etc.; determine the direction based on the direction determination rules, and create directed edges for each pair of related semantic labels based on the direction;
[0100] Normalize the calculated semantic correlation strength (such as Min-Max normalization or Softmax normalization) to convert it to a weight value between 0 and 1; assign the normalized weight to each directed edge to obtain an initial directed weighted graph;
[0101] Based on the initial semantic node set and the directed edges, perform topological optimization to obtain a multi-source data semantic correlation graph. Specifically, based on the initial semantic node set, divide the initial directed weighted graph into semantic subgraphs with tight internal connections and sparse external connections, and perform local clustering on the internal nodes in the divided semantic subgraphs; reduce the overall complexity and edge density of the graph through node clustering, and the optimized graph structure retains the most important semantic relationships while reducing redundant connections, forming a multi-source data semantic correlation graph. This graph is a directed graph structure with semantic labels as nodes and semantic correlation strength as edge weights, accurately representing the semantic relationship network in multi-source heterogeneous data. Through this semantic correlation graph construction method, the semantic connections in different data sources and types can be captured, providing a structured semantic navigation framework for subsequent interactive sequence generation, and improving the understanding ability of large models for data semantic structure.
[0102] It should be further noted that in the specific implementation process, the process of obtaining the multi-source data interactive sequence includes the following steps:
[0103] Perform path traversal on the multi-source data semantic correlation graph to obtain multiple semantic correlation paths, wherein the semantic correlation path includes a node sequence sorted by the weight of the directed edge;
[0104] According to the node sequence in the semantic association path, a formatted data segment of a corresponding standard data unit is extracted to generate an initial interaction data block, and semantic compression is performed on the initial interaction data block to obtain a compressed interaction data block;
[0105] According to the edge weight of each semantic association path in the multi-source data semantic association graph, the compressed interaction data block is sorted to generate a multi-source data interaction sequence.
[0106] In this embodiment, first, the constructed multi-source data semantic association graph is graph traversed (implemented by depth-first search DFS, breadth-first search BFS, random walk, etc.);
[0107] According to the semantic importance score of the semantic label, a high-score node is started, and path exploration is performed along the directed edge; and path selection is performed based on the edge weight (semantic association strength), and edges with high weights are preferentially selected for traversal; a plurality of paths with high semantic association are obtained, each path is composed of a series of node sequences sorted according to the association strength, and a semantic association path set is formed;
[0108] Then, for the node sequence in each semantic association path, the matching of the corresponding semantic label in the standard data unit is found, and the formatted data segment is extracted from the matched standard data unit; the data segments on the same path are combined into an initial interaction data block, and the order relationship of the node sequence is maintained to form a structured initial interaction data representation; the initial interaction data block contains original formatted data and necessary metadata (such as data source, semantic label, etc.);
[0109] Next, the semantic vector of the obtained initial interaction data block is reduced in dimension based on a pre-selected variational autoencoder, the main components of the semantic vector are retained, and redundant and noise information is removed to generate an interaction data block after semantic compression; the dimension reduction degree needs to be adjusted according to the semantic information retention rate during the dimension reduction process; usually, 80% to 90% of the semantic information is retained, which reduces the data amount while ensuring the semantic integrity.
[0110] Finally, according to the weight of each semantic association path in the multi-source data semantic association graph, the compressed interaction data block is sorted; the sorting basis is the product of the weight of the semantic association path and the semantic importance score of the compressed interaction data block, and a comprehensive priority score is obtained;
[0111] The compressed interaction data blocks are sorted according to the comprehensive priority scores, the data blocks with high priority are arranged at the front of the sequence, and the sorted compressed interaction data blocks are organized to form a multi-source data interaction sequence with semantic order, the sequence is sorted according to the semantic correlation strength, and contains the most relevant and important information extracted from the multi-source heterogeneous data. Through the interaction sequence generation method based on the semantic correlation graph, structured, high information density and semantically coherent input data can be provided for the large model, the understanding and processing efficiency of the large model for multi-source data is improved, and a basis is provided for generating high-quality interaction responses.
[0112] It should be further explained that, in the specific implementation process, the obtaining process of the interaction response result includes the following steps:
[0113] For each compressed interaction data block in the obtained multi-source data interaction sequence, a semantic feature vector corresponding to the compressed interaction data block is extracted;
[0114] According to the type data corresponding to the compressed interaction data block, the field weight of the structured data corresponding to the compressed interaction data block, the hierarchical weight of the semi-structured data corresponding to the compressed interaction data block, and the semantic weight of the unstructured data corresponding to the compressed interaction data block are calculated respectively;
[0115] According to the correlation between the semantic feature vector and the input layer neuron of the large model, the field weight, the hierarchical weight and the semantic weight are combined to calculate the attention weight of each interaction data block;
[0116] The semantic feature vector of the compressed interaction data block is enhanced in a graph structure, an enhanced semantic feature vector is obtained, and the attention weight is updated based on the dot product of the enhanced semantic feature vector and the weight vector of the input layer neuron;
[0117] The multi-source data interaction sequence is input based on the attention weight, the initial response result of the large model is obtained, and the initial response result is checked for semantic consistency to obtain the final interaction response result.
[0118] In this embodiment, first, the semantic vector analysis is performed on each compressed interaction data block in the multi-source data interaction sequence, and the semantic representation in the context perception is extracted; and the word embedding representation (such as Word2Vec, GloVe, etc.) of the corresponding semantic label of the corresponding compressed interaction data block is obtained; the corresponding semantic representation and word embedding representation are converted into encoding vectors, and the vectors are spliced to obtain a semantic feature vector;
[0119] Then the integrity of the fields of the structured data corresponding to the compressed interaction data block is analyzed, and the proportion of non-empty fields and the data quality indicators are calculated to obtain the field integrity score, which is normalized as the field weight; for the semi-structured data corresponding to the compressed interaction data block, the nesting level depth of the XML / JSON structure is analyzed to obtain the level weight, and the information with deeper level may be more specific or important; for the unstructured data corresponding to the compressed interaction data block, the distribution entropy of the semantic vector is calculated to quantify the richness and diversity of information, and the semantic weight is obtained;
[0120] Then, the input layer structure of the target large model is analyzed, the weight vector of the neurons in the input layer is extracted, the dot product of the semantic feature vector corresponding to the compressed interaction data block and the input layer weight vector is calculated, and the correlation between the semantic feature vector and the input layer neurons of the large model is obtained; combining the type data specific weight (including field weight, level weight or semantic weight), the initial attention weight corresponding to each compressed interaction data block is calculated by weighted summation;
[0121] The semantic feature vector of the compressed interaction data block is enhanced by graph structure, and an enhanced semantic feature vector is obtained. The graph structure enhancement utilizes the topological information of the multi-source data semantic association graph, fuses the features of related nodes through a message passing mechanism, and enriches the semantic representation of each compressed interaction data block. During the enhancement process, the system dynamically adjusts the weight of the message passing according to the relationship strength between nodes to ensure that important relationships are fully reflected. The enhanced semantic feature vector contains richer context information, which helps to improve the interaction effect with the large model. And the correlation between the enhanced semantic feature vector and the input layer neuron weight vector is recalculated to update the attention weight; wherein, the message passing mechanism refers to an existing technology method for fusing the features of related nodes by utilizing the topological information of the multi-source data semantic association graph in the graph structure enhancement process;
[0122] Then the updated attention weight is applied to the multi-source data interaction sequence to realize the weighted input of data, and the compressed interaction data block with high attention obtains more attention of the large model; the weighted processed interaction sequence is input into the target large model to obtain the initial response result, including classification result, generation result and reasoning result;
[0123] Finally, the semantic vector of the initial response result is obtained (for reference, the process of obtaining the semantic vector is described above); and the cosine similarity between the semantic vector corresponding to the initial response result and the semantic vector corresponding to the original multi-source data interaction sequence is obtained, quantifying the degree of semantic consistency; a preset consistency threshold (such as 0.7 or 0.8) is set; if the degree of consistency is less than the preset consistency threshold, the attention weight is dynamically adjusted through gradient backpropagation, and the response result of the large model is reobtained, and the process is repeated until the consistency requirement is met, and the final interactive response result is obtained; if the degree of consistency is not less than the preset consistency threshold, the corresponding initial response result is output as the final interactive response result; through this method of dynamically adjusting the attention weight, the system can optimize the attention allocation of the large model to the multi-source data, improve the semantic consistency between the model output and the input data, and ensure the quality and relevance of the interactive response, providing reliable feedback signals for subsequent interactive strategy optimization.
[0124] It needs to be further explained that, in the specific implementation process, the process of optimizing the generation process of the corresponding multi-source data interaction sequence includes the following steps:
[0125] According to the matching degree between the semantic vector corresponding to the interactive response result and the semantic vector corresponding to each semantic label in the multi-source data semantic association graph, the redundant interactive data blocks in the multi-source data interaction sequence are identified;
[0126] According to the confidence distribution corresponding to the interactive response result, the compressed interactive data blocks with low semantic importance in the multi-source data interaction sequence are identified, and the corresponding data optimization suggestions are generated through internal gradient analysis of the large model;
[0127] The semantic association paths corresponding to the redundant interactive data blocks and the compressed interactive data blocks with low semantic importance are pruned, and the multi-source data interaction sequence is regenerated according to the pruned multi-source data semantic association graph;
[0128] By comparing the semantic consistency between the regenerated multi-source data interaction sequence and the corresponding interactive response result of the original multi-source data interaction sequence, the generation strategy of the multi-source data interaction sequence is updated.
[0129] In this embodiment, first, the semantic vector corresponding to the interactive response result is obtained, and the semantic vectors of each semantic label in the multi-source data semantic association graph are extracted; the Euclidean distance between the semantic vector corresponding to the interactive response result and the semantic vector corresponding to each semantic label is obtained; wherein the smaller the Euclidean distance, the higher the matching degree;
[0130] A matching threshold is set, the obtained Euclidean distance is compared with the corresponding matching threshold, and based on the comparison result, the semantic labels with high matching degree are identified; and the compressed data blocks corresponding to the non-highly-matched semantic labels within the multi-source data interaction sequence are taken as potential redundant data blocks;
[0131] Then, the low confidence area is identified by analyzing the interaction response result of the large model, such as the class probability distribution of the classification result, the token prediction probability of the generation result, and the logical link strength of the reasoning result, the low confidence area refers to the input part corresponding to the large model which is uncertain or difficult to process; the attention allocation of each compressed interaction data block to the input is analyzed by reverse propagation or attention visualization technology; a number of compressed interaction data blocks with low semantic importance are identified and obtained, which can be regarded as compressed interaction data blocks with low semantic importance;
[0132] Further, based on the internal gradient and attention analysis, data optimization suggestions are generated, such as adjusting the weight of a specific semantic mapping relationship, modifying the analysis strategy of a specific type of data, etc.
[0133] Then, the redundant interaction data blocks and the compressed interaction data blocks with low semantic importance are marked, and the semantic association paths corresponding to these data blocks are traced back; the directed edges with weights less than a preset weight threshold (the threshold is set based on the statistical distribution of edge weights, usually 60%-70% of the distribution mean, to ensure that only edges with small contribution are pruned) in these paths are identified; the edges with weights less than the preset weight threshold are deleted from the multi-source data semantic association graph, and the pruning optimization of the graph structure is realized.
[0134] Finally, the multi-source data interaction sequence is regenerated based on the pruned semantic association graph, and input into the large model to obtain a new interaction response result; the semantic consistency between the new interaction response result and the original interaction response result is obtained by the cosine similarity between the semantic vectors; if the consistency remains within a preset consistency range, it means that the pruning is effective and the redundant information is successfully removed; and the weight of the semantic association path is adjusted based on it to update the generation strategy of the multi-source data interaction sequence, and the interaction efficiency is improved; the generation strategy includes adjusting the weight calculation formula of the semantic association path, optimizing the path traversal algorithm, and improving the data block sorting mechanism.
[0135] One embodiment of the present application also includes updating the dynamic analysis template according to the semantic consistency of the interaction response result, and the specific implementation process includes:
[0136] According to the semantic consistency of the interaction response result, the labeling error of the semantic label in the standard data unit is identified; the labeling error refers to the case that the entity category of the semantic label is inconsistent with the semantic category of the interaction response result, and such inconsistency may be caused by inaccurate initial labeling or data feature change. The identification process compares the label category with the semantic category of the corresponding content in the response, calculates the inconsistency rate, and labels the labels exceeding the preset threshold as potential errors.
[0137] The dynamic parsing template corresponding to the semantic label with the annotation error is acquired, and the keyword semantic vector and the entity relationship weight in the semantic mapping sub-template in the corresponding dynamic parsing template are adjusted; the keyword semantic vector is fine-tuned by using a back propagation algorithm to make it more consistent with the correct semantic category; and the entity relationship weight is optimized by using an edge weight updating rule of a graph neural network; the edge weight updating rule includes strengthening the weight of the correct relationship and weakening the weight of the error relationship.
[0138] According to the format integrity of the interactive response result, an analysis error of a formatted data segment in the standard data unit is identified; the analysis error includes a field missing (an expected field is not identified) or redundancy (an illegal field is incorrectly included); the identification method is to compare the actual structure of the formatted data segment with an expected structure to detect differences; the error type, frequency and distribution characteristics are recorded to form an error characteristic map to provide detailed basis for adjusting the format constraint sub-template.
[0139] The dynamic parsing template corresponding to the formatted data segment with the analysis error is acquired, and the separator matching rule and the nested level parsing rule in the format constraint sub-template are adjusted; the adjustment process first counts the distribution characteristics of the field set with the analysis error, such as the error position, the frequency distribution of the error type, etc.; then the regular expression of the separator matching rule is updated to optimize the pattern recognition capability; and finally the nested level parsing rule is improved by retraining the parsing model of the tree structure.
[0140] According to the analysis result of the interactive response result (such as the category probability distribution of the classification result, the token prediction probability of the generation result, the logical link strength of the reasoning result, etc.), active optimization suggestions for the dynamic parsing template are generated; the active optimization suggestions refer to the template improvement scheme actively proposed based on the interactive response result, including the priority adjustment suggestion for the separator matching rule of the format constraint sub-template and the enhancement suggestion for the entity relationship weight of the semantic mapping sub-template. The suggestion generation adopts a reinforcement learning method, and the quality of the interactive response result is taken as a reward signal to guide the exploration of a better template configuration.
[0141] It needs to be further explained that the process of specifically implementing the semantic sub-graph division based on the initial semantic node set and locally clustering the divided semantic sub-graphs includes:
[0142] The nodes corresponding to each semantic label in the initial semantic node set are clustered to obtain the local clustering coefficients corresponding thereto; the local clustering coefficient is an index for measuring the connection tightness of the neighborhood of a node, and is calculated by the ratio of the number of directed edges between the neighbors of the node to the possible number of directed edges; the corresponding mathematical calculation formula is: ; in the formula, denotes the local clustering coefficient corresponding to the i th node. denotes the number of nodes that have an edge with the ith node; denotes the number of nodes adjacent to the ith node;
[0143] According to the local clustering coefficient, the initial directed weighted graph corresponding to the initial semantic node set is divided into a plurality of semantic subgraphs; the division process adopts the principle of maximizing the sum of local clustering coefficients in the subgraph, and the optimal division scheme is found by using an optimization algorithm (such as a greedy algorithm, simulated annealing, etc.) for iterative optimization; the final boundary of the semantic subgraph is determined by iteratively adjusting the node allocation; the initial semantic node set is divided into a plurality of semantic subgraphs with high internal connection density;
[0144] For each node in the semantic subgraph, the semantic importance score thereof in the graph is calculated, such as by a centrality index (PageRank, intermediate centrality, etc.) or a semantic importance score; the directed edge weight corresponding to the node is obtained, and the semantic centrality is calculated based thereon; the index comprehensively considers the connection strength and semantic importance of the node, and the corresponding mathematical calculation formula is as follows: ; wherein, is the directed edge edge weight between the node and the adjacent node , and is the semantic importance score of the node ;
[0145] According to the semantic centrality, the nodes in the semantic subgraph are locally clustered; the clustering process is based on the semantic similarity and connection mode between nodes, and the nodes are gradually merged from bottom to top; specifically, by identifying the node with the highest semantic centrality in each semantic cluster, the node is set as the representative node or center node of the cluster, and a structured representation of the semantic cluster is established, including cluster members, boundaries and representative node information; through this community detection and local clustering method based on the local clustering coefficient and the semantic centrality, the system can identify the cohesive semantic concept group in the semantic correlation graph, reduce the complexity of the graph, while retaining the core semantic structure, providing an optimized semantic navigation framework for subsequent interactive sequence generation, and improving the understanding and processing efficiency of the large model for the semantic structure of multi-source data.
[0146] Embodiment 2
[0147] Please refer to Figure 2 , and the part not described in detail in this embodiment is described in embodiment 1. An efficient interactive system connecting a large model and multi-source data is provided, which includes:
[0148] A data acquisition module is configured to acquire data from a data source connected to a target large model, and obtain multi-source heterogeneous data, wherein the multi-source heterogeneous data includes three types of data: structured data, semi-structured data and unstructured data;
[0149] A template construction module is configured to construct a dynamic parsing template according to format characteristics and semantic characteristics of each type of data in the multi-source heterogeneous data, and the dynamic parsing template comprises a format constraint sub-template and a semantic mapping sub-template.
[0150] A data parsing module is configured to perform hierarchical parsing on the corresponding multi-source heterogeneous data based on the constructed dynamic parsing template, and obtain a standard data unit corresponding to each type of data, and the standard data unit comprises a formatted data segment and a semantic label.
[0151] A topology analysis module is configured to construct a multi-source data semantic association graph according to the obtained semantic label, and generate a multi-source data interaction sequence according to a topology structure of the multi-source data semantic association graph and in combination with the obtained formatted data segment.
[0152] A data interaction module is configured to input the multi-source data interaction sequence into a target large model, and obtain an interaction response result between the corresponding large model and the multi-source data interaction sequence by updating an input attention weight of the target large model, and the interaction response result comprises a classification result, a generation result and an inference result.
[0153] An interaction feedback module is configured to optimize a generation strategy of the corresponding multi-source data interaction sequence according to semantic consistency between the interaction response result and the multi-source data semantic association graph.
[0154] Each module is connected through wired and / or wireless means to realize data transmission between the modules.
[0155] The above only describes preferred embodiments of the present application and is not intended to limit the present application. Although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent replacements to some technical features. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.
[0156] It should be noted that in this document, the term "comprises", "comprising", or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or device. Without more limitations, the element defined by the statement "comprises a" does not exclude the presence of additional identical elements in the process, method, article or device including the element.
[0157] In the description of the application, it should be understood that the terms "first", "second" and the like are used to distinguish descriptions and are not intended to imply or imply relative importance.
[0158] In the description of the application, the meaning of "a plurality of" is two or more, unless otherwise specified.
[0159] In the description of the application, the meaning of "a plurality of" is two or more, unless otherwise specified.
[0160] In the description of the application, the description of the terms "one embodiment", "some embodiments", "example", "specific example" or "some examples" means that the specific features, structures, materials or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the application. In this specification, the illustrative description of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0161] For the formula of the present application, the value is calculated by de-dimensioning, the formula is obtained by collecting a large amount of data to simulate the most real situation, and the preset parameters and threshold values in the formula are set by the person skilled in the art according to the actual situation.
[0162] Although the embodiments of the present application have been shown and described, those skilled in the art can understand that various changes, modifications, replacements and variations can be made to these embodiments without departing from the principles and purposes of the present application, and the scope of the present application is defined by the claims and their equivalents.
Claims
1. An efficient interaction method for connecting large models and multi-source data, characterized in that, include: Step S1: Collect data from the data source connected to the target large model to obtain multi-source heterogeneous data, which includes three types of data: structured data, semi-structured data, and unstructured data. Step S2: Based on the format and semantic features of each type of data in the multi-source heterogeneous data, construct a dynamic parsing template, which includes a format constraint sub-template and a semantic mapping sub-template; Step S3: Based on the constructed dynamic parsing template, perform hierarchical parsing on the corresponding multi-source heterogeneous data to obtain the standard data units corresponding to each type of data. The standard data units include formatted data fragments and semantic tags. Step S4: Construct a multi-source data semantic association graph based on the obtained semantic tags, and generate a multi-source data interaction sequence based on the topological structure of the multi-source data semantic association graph and the obtained formatted data fragments; Step S5: Input the multi-source data interaction sequence into the target large model, and obtain the interaction response results between the corresponding large model and the multi-source data interaction sequence by updating the input attention weight of the target large model. The interaction response results include classification results, generation results and inference results. The process of obtaining the interactive response result includes: For each compressed interactive data block in the obtained multi-source data interaction sequence, extract its corresponding semantic feature vector; Based on the type of data corresponding to the compressed interactive data block, calculate the field weights of the compressed interactive data block corresponding to structured data, the hierarchical weights of the compressed interactive data block corresponding to semi-structured data, and the semantic weights of the compressed interactive data block corresponding to unstructured data. Based on the correlation between the semantic feature vector and the input layer neurons of the large model, and combined with the field weights, hierarchical weights, and semantic weights, the attention weight of each interactive data block is calculated. Graph structure enhancement is performed on the semantic feature vector of the compressed interactive data block to obtain the enhanced semantic feature vector, and the attention weights are updated based on the dot product of the enhanced semantic feature vector and the weight vector of the input layer neuron. The multi-source data interaction sequence is weighted based on the attention weights to obtain the initial response result of the large model, and the semantic consistency of the initial response result is checked to obtain the final interaction response result. Step S6: Optimize the generation strategy of the corresponding multi-source data interaction sequence based on the semantic consistency between the interaction response results and the semantic association graph of multi-source data.
2. The efficient interaction method for connecting large models and multi-source data according to claim 1, characterized in that, The process of constructing a dynamically parsed template includes: Format features are extracted from various types of data collected from multiple sources and heterogeneous data, and format constraint sub-templates are constructed based on the extracted format features; the format constraint sub-templates include delimiter matching rules and nesting level parsing rules; the format features include data delimiters, nesting levels, and field lengths; Simultaneously, semantic features are extracted from each data type in the collected multi-source heterogeneous data, and a semantic mapping sub-template is constructed based on the semantic features. The semantic mapping sub-template includes keyword semantic vectors and entity relationship weights. The format constraint sub-template is combined with the semantic mapping sub-template to obtain a dynamic parsing template for the corresponding data type.
3. The efficient interaction method for connecting large models and multi-source data according to claim 2, characterized in that, The process of performing hierarchical parsing of corresponding multi-source heterogeneous data based on the constructed dynamic parsing template includes: Based on the constructed format constraint sub-template, the type data is segmented by format features to obtain initial data fragments; and based on the constructed semantic mapping sub-template, semantic features are extracted from the corresponding initial data fragments to obtain semantic labels. Based on the correspondence between the initial data fragments and semantic tags, standard data units are constructed; and the constructed standard data units are stored in a hierarchical manner.
4. The efficient interaction method for connecting large models and multi-source data according to claim 3, characterized in that, The process of constructing a semantic association graph of multi-source data includes: The semantic labels within the standard data unit are used as nodes to construct an initial semantic node set; the semantic association strength between any two nodes in the initial semantic node set is obtained, and a directed edge between semantic labels is constructed based on the semantic association strength. The initial set of semantic nodes and the directed edges are subjected to topology optimization to obtain a semantic association graph of multi-source data; the topology optimization includes dividing the semantic subgraph based on the initial set of semantic nodes and performing local clustering on the divided semantic subgraph.
5. The efficient interaction method for connecting large models and multi-source data according to claim 4, characterized in that, The process of obtaining multi-source data interaction sequences includes: The semantic association graph of the multi-source data is traversed to obtain multiple semantic association paths, which include a sequence of nodes sorted by the weight of the directed edges. Based on the node sequence within the semantic association path, formatted data fragments of corresponding standard data units are extracted to generate an initial interactive data block; and the initial interactive data block is semantically compressed to obtain a compressed interactive data block. Based on the edge weights of each semantic association path in the multi-source data semantic association graph, the compressed interactive data blocks are sorted to generate a multi-source data interaction sequence.
6. The efficient interaction method for connecting large models and multi-source data according to claim 1, characterized in that, The process of optimizing the generation of the corresponding multi-source data interaction sequence includes: Based on the matching degree between the semantic vector corresponding to the interactive response result and the semantic vector corresponding to each semantic label in the semantic association graph of multi-source data, redundant interactive data blocks in the multi-source data interaction sequence are identified. Based on the confidence distribution corresponding to the interaction response results, low semantic importance compressed interaction data blocks in the multi-source data interaction sequence are identified, and corresponding data optimization suggestions are generated through the internal gradient analysis of the large model. The semantic association paths corresponding to redundant interactive data blocks and compressed interactive data blocks with low semantic importance are pruned, and the multi-source data interaction sequence is regenerated based on the pruned multi-source data semantic association graph. The generation strategy for multi-source data interaction sequences is updated by comparing the semantic consistency between the regenerated multi-source data interaction sequences and the corresponding interaction response results of the original multi-source data interaction sequences.
7. The efficient interaction method for connecting large models and multi-source data according to claim 1, characterized in that, The process of performing semantic consistency verification includes: Obtain the semantic vector of the initial response result; and obtain the cosine similarity between the semantic vector corresponding to the initial response result and the semantic vector corresponding to the original multi-source data interaction sequence; Set a preset consistency threshold; if the consistency level is less than the preset consistency threshold, reacquire the response results of the large model and repeat this process; if the consistency level is not less than the preset consistency threshold, output the corresponding initial response results as the final interactive response results.
8. The efficient interaction method for connecting large models and multi-source data according to claim 4, characterized in that, The process of partitioning a semantic subgraph based on an initial set of semantic nodes and then performing local clustering on the partitioned semantic subgraphs includes: Cluster the nodes corresponding to each semantic label in the initial semantic node set to obtain their corresponding local clustering coefficients; based on the local clustering coefficients, divide the initial directed weighted graph corresponding to the initial semantic node set into multiple semantic subgraphs; Obtain the semantic importance score of each node in the semantic subgraph; simultaneously obtain the directed edge weights corresponding to the nodes and calculate the semantic centrality based on them; perform local clustering of the nodes in the semantic subgraph according to the semantic centrality to establish a structured representation of the semantic cluster, which includes cluster members, boundaries and representative node information.
9. A highly efficient interactive system for connecting large models and multi-source data, used to implement the highly efficient interactive method for connecting large models and multi-source data as described in any one of claims 1 to 8, characterized in that, include: The data acquisition module is used to acquire data from the data source connected to the target large model to obtain multi-source heterogeneous data, which includes three types of data: structured data, semi-structured data, and unstructured data. The template construction module is used to construct a dynamic parsing template based on the format and semantic features of various types of data in multi-source heterogeneous data. The dynamic parsing template includes a format constraint sub-template and a semantic mapping sub-template. The data parsing module performs hierarchical parsing of the corresponding multi-source heterogeneous data based on the constructed dynamic parsing template, and obtains the standard data units corresponding to each type of data. The standard data units include formatted data fragments and semantic tags. The topology analysis module is used to construct a multi-source data semantic association graph based on the obtained semantic tags, and generate a multi-source data interaction sequence based on the topological structure of the multi-source data semantic association graph and the obtained formatted data fragments. The data interaction module is used to input the multi-source data interaction sequence into the target large model, and obtain the interaction response results between the corresponding large model and the multi-source data interaction sequence by updating the input attention weight of the target large model. The interaction response results include classification results, generation results and inference results. The interactive feedback module is used to optimize the generation strategy of the corresponding multi-source data interaction sequence based on the semantic consistency between the interactive response results and the semantic association graph of multi-source data.
Citation Information
Patent Citations
Fusion method for automatic cooperative processing of multi-source heterogeneous data
CN120469967A
Multi-source heterogeneous corpus fusion method and system based on government affair service data
CN120493159A
Customer data processing and insight system based on large language model
CN120705704A