Intelligent retrieval method and system for unstructured asset content based on large models
By adopting a large model-based method in the intelligent search system, semantic expansion, multimodal feature extraction, hierarchical index library construction and association analysis, the shortcomings of semantic understanding of non-structured asset content and multimodal asset content correlation analysis in the existing technology are solved, and more accurate and comprehensive search results are achieved.
Patent Information
- Application Number
- CN202510153894.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-12
- Publication Date
- 2025-04-22
- Estimated Expiration
- 2045-02-12
AI Technical Summary
The prior art has shortcomings in semantic understanding of unstructured asset content and unified representation and correlation analysis of multimodal asset content, resulting in undesirable accuracy and correlation of search results.
The intelligent search method based on the big model is adopted to expand semantics through the knowledge graph enhancement module, and a search vector is generated by combining the pre-trained encoder model; the multi-modal feature extraction model is used to extract multi-dimensional features of asset content based on the transformer architecture, a hierarchical asset feature index library is constructed, and similarity calculation is performed through the weighted fusion algorithm; finally, the semantic understanding and association analysis module of the big model is used for deep semantic analysis and association analysis, and the asset association network is built to optimize the search results.
It improves the accuracy and comprehensiveness of the search, enhances semantic understanding ability, better captures the implicit relationship between assets, optimizes the display method of search results, and improves user retrieval experience and efficiency.
Smart Images

Figure CN119646243B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to data retrieval technology, and in particular to an intelligent retrieval method and system for unstructured asset content based on a large model. Background Art
[0002] With the deepening of digital transformation, enterprises and organizations have accumulated a large amount of unstructured digital assets, including text documents, pictures, audio, video and other forms. These unstructured assets contain rich business value and knowledge information. How to achieve efficient retrieval and utilization of these heterogeneous assets has become an important challenge in the current field of digital asset management. Traditional asset retrieval methods are mainly based on keyword matching and metadata indexing, and the retrieval function is realized by establishing an inverted index. In recent years, with the development of artificial intelligence technology, retrieval methods based on deep learning have gradually been applied, extracting asset features through neural network models to achieve semantic retrieval and matching.
[0003] The existing technology has the following main problems and shortcomings:
[0004] First, existing retrieval methods have a relatively shallow understanding of the semantics of unstructured asset content, mainly relying on simple feature extraction and vector matching. It is difficult to accurately understand and express the deep semantic information of asset content, resulting in less than ideal accuracy and relevance of retrieval results.
[0005] Secondly, the existing retrieval system lacks the ability to uniformly represent and analyze the content of multimodal assets. It is difficult to effectively establish semantic associations between different types of assets, and it is impossible to achieve intelligent association retrieval of cross-modal assets, which limits the integrity and relevance of the retrieval results.
[0006] Third, existing retrieval methods generally adopt a single similarity calculation method and lack a multi-level and multi-dimensional similarity measurement mechanism, which makes it difficult to fully characterize the similarity relationship between asset content, affects the accuracy and diversity of retrieval results, and cannot meet users' personalized retrieval needs well. Summary of the invention
[0007] The embodiments of the present invention provide a method and system for intelligent retrieval of unstructured asset content based on a large model, which can solve the problems in the prior art.
[0008] A first aspect of an embodiment of the present invention provides an intelligent retrieval method for unstructured asset content based on a large model, comprising:
[0009] Receive a search instruction input by a user, wherein the search instruction includes a search keyword; call a knowledge graph enhancement module to perform semantic expansion on the search keyword to obtain an expanded keyword set; input the expanded keyword set into a pre-trained first encoder model to generate a search vector; use a data crawler module to obtain unstructured asset content to be retrieved, wherein the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; input the unstructured asset content into a pre-trained multimodal feature extraction model, extract multidimensional features of the unstructured asset content based on an attention mechanism of a transformer architecture, and generate an asset feature vector;
[0010] Based on the asset feature vector, a hierarchical asset feature index library is constructed, wherein the hierarchical asset feature index library includes feature indexes at three levels: subject layer, content layer, and attribute layer; similarity calculations are performed on the search vector and the feature vectors at each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; a weighted fusion algorithm is used to fuse the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score to generate a comprehensive similarity score; and the search results are sorted according to the comprehensive similarity score to obtain a candidate search result set;
[0011] The candidate search result set is input into a pre-trained big model, which is trained by contrastive learning method and has cross-modal understanding and reasoning capabilities; the semantic understanding module of the big model is called to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; the association analysis module of the big model is called to calculate the association strength between the unstructured asset content based on the semantic feature matrix to generate an asset association network; the candidate search result set is reordered and clustered according to the topological structure of the asset association network to generate optimized search results.
[0012] Calling the knowledge graph enhancement module to semantically expand the search keywords to obtain an expanded keyword set; inputting the expanded keyword set into a pre-trained first encoder model to generate a search vector includes:
[0013] Construct a domain knowledge graph, wherein the domain knowledge graph includes an entity node set and a relationship edge set, wherein each entity node in the entity node set includes an entity type, an entity name, an entity description, and an entity alias, and the relationship edges in the relationship edge set include synonymous relationships, hierarchical relationships, part-whole relationships, and attribute relationships; pre-train the domain knowledge graph using a TransE model to obtain entity vectors and relationship vectors;
[0014] Locate a target entity node corresponding to the search keyword in the domain knowledge graph; obtain a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; calculate the semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; and construct a set of candidate expansion words based on the semantic relevance;
[0015] Calculate the importance score of each candidate word in the candidate expansion word set, where the importance score is obtained by weighting the semantic relevance and the node centrality; select the top 5% of the candidate words in importance score as the expansion keyword set;
[0016] The expanded keyword set is input into a dual-tower Transformer encoder, which includes a word vector encoding layer, a position encoding layer, a word segmentation encoding layer, a multi-head attention layer, and a feedforward neural network layer; the inter-word attention weight matrix is calculated in the multi-head attention layer to obtain a word-level context representation; the word-level context representation is fused with the global feature to obtain a fused feature; the importance weight of the fused feature is calculated based on the attention mechanism; the fused feature is weighted averaged according to the importance weight to generate a retrieval vector.
[0017] Locating a target entity node corresponding to the search keyword in the domain knowledge graph; acquiring a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; calculating a semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; constructing a set of candidate expansion words based on the semantic relevance includes:
[0018] Constructing a search stack and an access tag set, pushing the target entity node into the search stack; taking out an entity node from the search stack, and adding the entity node to the access tag set; obtaining adjacent entity nodes of the entity node, and calculating a path importance score between the entity node and the adjacent entity node, wherein the path importance score is calculated based on the product of the node weight and the relationship weight;
[0019] Performing path evaluation on the adjacent entity nodes, the path evaluation includes calculating the visited path score and the heuristic estimation value; pruning the path based on the path evaluation result, retaining the path with the same path type; pushing the entity nodes that are not in the visited tag set among the pruned adjacent entity nodes into the search stack; repeatedly performing the operations of taking out the entity nodes, calculating the path importance score, path evaluation and pushing into the search stack until the search stack is empty or reaches the preset maximum number of hops;
[0020] The entity vector cosine similarity between the target entity node and each entity node in the access tag set is calculated, and the comprehensive semantic relevance is calculated based on the entity vector cosine similarity and the exponential decay value of the shortest path length; a dynamic threshold is set according to the mean and variance of the comprehensive semantic relevance, and the expanded entity nodes whose comprehensive semantic relevance is greater than the dynamic threshold are screened out, and a candidate expansion word set is constructed based on the expanded entity nodes.
[0021] Calculating the similarity of the search vector with the feature vectors of each level in the hierarchical asset feature index library in turn to obtain a similarity score of the subject layer, a similarity score of the content layer, and a similarity score of the attribute layer; and using a weighted fusion algorithm to fuse the similarity score of the subject layer, the similarity score of the content layer, and the similarity score of the attribute layer to generate a comprehensive similarity score, including:
[0022] Determine the cosine similarity between the retrieval vector and the subject layer feature vector in the hierarchical asset feature index library, and calculate the subject layer similarity score according to the cosine similarity of the subject layer feature vector and the weighted value of the subject layer depth; calculate the feature intersection and union ratio of the retrieval vector and the content layer feature vector based on the local sensitive hash function, and obtain the content layer similarity score according to the product of the feature intersection and union ratio and the content coverage; calculate the weighted Euclidean distance between the retrieval vector and the attribute layer feature vector, and use the weighted Euclidean distance as the attribute layer similarity score;
[0023] Calculate the information entropy of the subject layer, content layer, and attribute layer respectively, the information entropy is calculated according to the distribution probability of the feature categories of each layer; calculate the layer weight based on the information entropy of each layer, the layer weight is the normalized information entropy supplement value; count the mean and standard deviation of the similarity score of each layer, and standardize the similarity score of the subject layer, the similarity score of the content layer, and the similarity score of the attribute layer;
[0024] Calculate the correlation coefficient between the subject layer and the content layer, the subject layer and the attribute layer, and the content layer and the attribute layer, wherein the correlation coefficient is calculated by dividing the covariance of the similarity score by the product of the standard deviation; adjust the level weight based on the correlation coefficient, multiply the adjusted level weight by the similarity score of the corresponding level respectively, and sum them to obtain an initial fusion similarity score;
[0025] The confidence scores of each level are calculated, and the dynamic fusion weight is calculated according to the level weight and the confidence score; the initial fusion similarity score is weighted and normalized based on the dynamic fusion weight to obtain the optimized fusion similarity score; the Sigmoid function is used to perform nonlinear mapping on the optimized fusion similarity score to generate the final comprehensive similarity score.
[0026] Calling the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; calling the association analysis module of the large model to calculate the association strength between the unstructured asset content based on the semantic feature matrix includes:
[0027] Extracting contextual semantic features of the unstructured asset content based on a multi-head attention mechanism, inputting the contextual semantic features into a multi-layer semantic encoder for hierarchical processing to obtain multi-layer semantic features; calculating feature weights of the multi-layer semantic features, performing weighted fusion on the multi-layer semantic features based on the feature weights, and performing enhancement processing on the fused multi-layer semantic features through nonlinear transformation; normalizing the enhanced multi-layer semantic features, and organizing the normalized multi-layer semantic features into a semantic feature matrix;
[0028] Calculate the cosine similarity of any two unstructured asset feature vectors in the semantic feature matrix, and use the cosine similarity as the semantic similarity; construct a feature dimension weight vector, calculate the weighted Euclidean distance of any two unstructured asset feature vectors based on the feature dimension weight vector, and convert the weighted Euclidean distance into a semantic distance; perform weighted combination of the semantic similarity and the exponential decay value of the semantic distance to obtain the association strength between the unstructured asset contents.
[0029] The method further includes optimizing the asset association network:
[0030] Calculate the mean and standard deviation of the association strength, and standardize the association strength based on the mean and the standard deviation to obtain a Z score; compare the Z score with a preset significance level, screen the association strength with a significance greater than the preset significance level, and obtain a significant association strength set; count the number of nodes in the asset association network, calculate the ratio of the actual number of connections between nodes to the maximum number of connections to obtain the network density; construct an adaptive threshold based on the logarithmic term of the number of nodes and the network density;
[0031] Comparing the association strengths in the significant association strength set with the adaptive threshold, retaining the association strengths greater than the adaptive threshold, and constructing an initial asset association network with weights;
[0032] In a time window of preset length, a historical time series association strength sequence is obtained; a time decay weight is calculated based on an exponential decay function, and the time decay weight decreases as the time interval increases; the time decay weight is multiplied by the historical association strength at the corresponding moment and the sum is calculated to obtain the historical weighted association strength; the historical weighted association strength is linearly combined with the current association strength to generate the time series fusion association strength;
[0033] The correlation standard deviation of the temporal fusion correlation strength within the time window is calculated, and the correlation standard deviation is used as the fluctuation degree of the correlation relationship; a stability score is constructed based on the fluctuation degree, and the stability score decreases as the fluctuation degree increases; the stability score is used as an edge weight adjustment factor to adjust the edge weights in the initial asset association network to generate a final asset association network with temporal stability.
[0034] Reordering and clustering the candidate search result set according to the topological structure of the asset association network to generate optimized search results includes:
[0035] Calculate the weighted degree centrality of nodes in the asset association network, where the weighted degree centrality is the sum of the edge weights connected to the node; calculate the eigenvector centrality of the node based on eigenvector decomposition; calculate the frequency of occurrence of the node in the shortest path to obtain the path centrality; perform weighted combination of the weighted degree centrality, the eigenvector centrality, and the path centrality to obtain the comprehensive importance score of the node; perform maximum and minimum value normalization processing on the comprehensive importance score to obtain a normalized importance score;
[0036] Obtain the neighborhood set of the node, multiply the normalized importance score of the neighborhood node by the edge weight and sum them to obtain the neighborhood influence of the node; count the number of common neighborhood nodes of any two nodes, and calculate the structural similarity between the nodes based on the number of common neighborhood nodes and the size of the neighborhood set; perform preliminary clustering of the nodes based on the structural similarity to obtain preliminary clustering results;
[0037] Calculate the difference between the actual connection weight and the expected connection weight between nodes, and construct a modularity objective function based on the difference; optimize the preliminary clustering result by optimizing the modularity objective function to obtain the network community division result; calculate the average connection weight between the nodes within each network community to obtain the community closeness; and calculate the average connection weight of the nodes between the network communities to obtain the distance between the communities;
[0038] The normalized importance score, the neighborhood influence, the community closeness and the distance between communities are weighted and summed to obtain a comprehensive ranking score of the node; a time decay factor is introduced to adjust the time sequence of the comprehensive ranking score to generate the final retrieval result ranking.
[0039] A second aspect of an embodiment of the present invention provides an intelligent retrieval system for unstructured asset content based on a large model, comprising:
[0040] The first unit is used to receive a search instruction input by a user, wherein the search instruction includes a search keyword; call the knowledge graph enhancement module to perform semantic expansion on the search keyword to obtain an expanded keyword set; input the expanded keyword set into a pre-trained first encoder model to generate a search vector; use a data crawler module to obtain unstructured asset content to be retrieved, wherein the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; input the unstructured asset content into a pre-trained multimodal feature extraction model, extract multidimensional features of the unstructured asset content based on an attention mechanism of a transformer architecture, and generate an asset feature vector;
[0041] The second unit is used to construct a hierarchical asset feature index library based on the asset feature vector, wherein the hierarchical asset feature index library includes feature indexes of three levels: subject layer, content layer, and attribute layer; perform similarity calculations on the search vector and the feature vectors of each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; perform fusion calculations on the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score using a weighted fusion algorithm to generate a comprehensive similarity score; sort the search results according to the comprehensive similarity score to obtain a candidate search result set;
[0042] The third unit is used to input the candidate retrieval result set into a pre-trained large model, where the large model is trained using a contrastive learning method and has cross-modal understanding and reasoning capabilities; call the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate retrieval result set to generate a semantic feature matrix; call the association analysis module of the large model to calculate the association strength between the unstructured asset content based on the semantic feature matrix to generate an asset association network; reorder and cluster the candidate retrieval result set according to the topological structure of the asset association network to generate optimized retrieval results.
[0043] A third aspect of the embodiments of the present invention
[0044] An electronic device is provided, comprising:
[0045] processor;
[0046] a memory for storing processor-executable instructions;
[0047] The processor is configured to call the instructions stored in the memory to execute the aforementioned method.
[0048] A fourth aspect of the embodiments of the present invention is:
[0049] A computer-readable storage medium is provided, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the aforementioned method is implemented.
[0050] The beneficial effects of this application are as follows:
[0051] The search keywords are semantically expanded through the knowledge graph enhancement module, and the search vectors are generated in combination with the pre-trained first encoder model. At the same time, the multimodal feature extraction model is used to extract the multi-dimensional features of unstructured asset content based on the transformer architecture, which can effectively improve the accuracy and comprehensiveness of the search and avoid the problem of missing search results due to single keywords.
[0052] By using a hierarchical asset feature index library to manage features in layers and using a weighted fusion algorithm to fuse similarity scores at different levels, the search results can be evaluated and sorted from multiple dimensions, improving the accuracy and reliability of the search results and making the search results more in line with user needs.
[0053] By leveraging the cross-modal understanding and reasoning capabilities of the pre-trained large model, we conduct deep semantic analysis and association analysis on candidate search results, build an asset association network, and reorder and cluster them based on the network topology. This can not only discover the implicit associations between assets, but also optimize the display of search results, thereby improving user search experience and search efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 A flowchart of an intelligent retrieval method for unstructured asset content based on a large model according to an embodiment of the present invention;
[0055] Figure 2 The diagram is a structural diagram of an intelligent retrieval system for unstructured asset content based on a large model according to an embodiment of the present invention. DETAILED DESCRIPTION
[0056] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0057] The technical solution of the present invention is described in detail with specific embodiments below. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0058] Figure 1FIG. 1 is a flow chart of an intelligent retrieval method for unstructured asset content based on a large model according to an embodiment of the present invention. Figure 1 As shown, the method includes:
[0059] S101. Receive a search instruction input by a user, wherein the search instruction includes a search keyword; call a knowledge graph enhancement module to semantically expand the search keyword to obtain an expanded keyword set; input the expanded keyword set into a pre-trained first encoder model to generate a search vector; use a data crawler module to obtain unstructured asset content to be retrieved, wherein the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; input the unstructured asset content into a pre-trained multimodal feature extraction model, extract multidimensional features of the unstructured asset content based on an attention mechanism of a transformer architecture, and generate an asset feature vector;
[0060] S102. construct a hierarchical asset feature index library based on the asset feature vector, wherein the hierarchical asset feature index library includes feature indexes at three levels: subject layer, content layer, and attribute layer; perform similarity calculations on the search vector and the feature vectors at each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; perform fusion calculations on the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score using a weighted fusion algorithm to generate a comprehensive similarity score; sort the search results according to the comprehensive similarity score to obtain a candidate search result set;
[0061] S103. Input the candidate retrieval result set into a pre-trained big model, which is trained using a contrastive learning method and has cross-modal understanding and reasoning capabilities; call the semantic understanding module of the big model to perform deep semantic analysis on the unstructured asset content in the candidate retrieval result set to generate a semantic feature matrix; call the association analysis module of the big model to calculate the association strength between the unstructured asset content based on the semantic feature matrix to generate an asset association network; reorder and cluster the candidate retrieval result set according to the topological structure of the asset association network to generate optimized retrieval results.
[0062] In an optional implementation, calling the knowledge graph enhancement module to semantically expand the search keywords to obtain an expanded keyword set; inputting the expanded keyword set into a pre-trained first encoder model to generate a search vector includes:
[0063] Construct a domain knowledge graph, wherein the domain knowledge graph includes an entity node set and a relationship edge set, wherein each entity node in the entity node set includes an entity type, an entity name, an entity description, and an entity alias, and the relationship edges in the relationship edge set include synonymous relationships, hierarchical relationships, part-whole relationships, and attribute relationships; pre-train the domain knowledge graph using a TransE model to obtain entity vectors and relationship vectors;
[0064] Locate a target entity node corresponding to the search keyword in the domain knowledge graph; obtain a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; calculate the semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; and construct a set of candidate expansion words based on the semantic relevance;
[0065] Calculate the importance score of each candidate word in the candidate expansion word set, where the importance score is obtained by weighting the semantic relevance and the node centrality; select the top 5% of the candidate words in importance score as the expansion keyword set;
[0066] The expanded keyword set is input into a dual-tower Transformer encoder, which includes a word vector encoding layer, a position encoding layer, a word segmentation encoding layer, a multi-head attention layer, and a feedforward neural network layer; the inter-word attention weight matrix is calculated in the multi-head attention layer to obtain a word-level context representation; the word-level context representation is fused with the global feature to obtain a fused feature; the importance weight of the fused feature is calculated based on the attention mechanism; the fused feature is weighted averaged according to the importance weight to generate a retrieval vector.
[0067] First, we construct a domain knowledge graph. In the entity node set, each entity node contains attribute information such as entity type (such as "product", "technology"), entity name (such as "smartphone", "5G communication"), entity description (such as "a mobile communication terminal device"), entity alias (such as "mobile phone", "mobile phone"), etc. The relationship edge set contains semantic relationships such as synonymous relationships (such as "smartphone-mobile phone"), hyponymous relationships (such as "smartphone-electronic device"), part-whole relationships (such as "processor-smartphone"), and attribute relationships (such as "smartphone-screen size"). The TransE model is used to pre-train the knowledge graph, map entities and relationships to a low-dimensional vector space, and obtain the representation of entity vectors and relationship vectors.
[0068] For the input search keywords, such as "5G mobile phone", locate the corresponding target entity node in the knowledge graph. Using the depth-first search algorithm, starting from the target entity node, search for neighbor nodes within 2-3 hops to obtain a set of neighbor nodes. Calculate the semantic relevance between the target entity node and the neighbor nodes, specifically through the weighted combination of the cosine similarity of the entity vector and the shortest path length. Construct a set of candidate expansion words based on semantic relevance screening.
[0069] The importance score is calculated for the words in the candidate expansion word set. The importance score is obtained by weighting the semantic relevance score (accounting for 0.7) and the node centrality score (accounting for 0.3). The node centrality is calculated by the in-degree, out-degree and betweenness centrality of the node. The top 5% of the candidate words in importance score ranking are selected as the final expansion keyword set.
[0070] The expanded keyword set is input into the dual-tower Transformer encoder for vector representation. First, the word is mapped to a dense vector through the word vector encoding layer, the position encoding layer adds position information, and the word segmentation encoding layer performs word segmentation. Then, the inter-word attention weight matrix is calculated through the 8-head attention mechanism to obtain the context-related word representation. The word-level representation is concatenated and fused with the global features (such as word frequency statistical features) to obtain the fused features. Based on the attention mechanism, the importance weights of each dimension of the fused feature are calculated, and the weighted average is performed to obtain the final retrieval vector.
[0071] This application enables:
[0072] The semantic expansion method enhanced by knowledge graph effectively expands the semantic scope of search keywords, improves the recall rate of search, and solves the semantic gap problem of keyword search. The multi-hop neighbor node selection strategy based on depth-first search and semantic relevance ensures the semantic relevance of the expanded words, avoids semantic drift, and improves the accuracy of search results. The dual-tower Transformer encoder and attention mechanism fully consider the contextual dependency between words, combine with global features for fusion, generate high-quality search vector representation, and enhance the semantic understanding ability of the retrieval system.
[0073] In an optional implementation, locating a target entity node corresponding to the search keyword in the domain knowledge graph; acquiring a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; calculating a semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; and constructing a set of candidate expansion words based on the semantic relevance includes:
[0074] Constructing a search stack and an access tag set, pushing the target entity node into the search stack; taking out an entity node from the search stack, and adding the entity node to the access tag set; obtaining adjacent entity nodes of the entity node, and calculating a path importance score between the entity node and the adjacent entity node, wherein the path importance score is calculated based on the product of the node weight and the relationship weight;
[0075] Performing path evaluation on the adjacent entity nodes, the path evaluation includes calculating the visited path score and the heuristic estimation value; pruning the path based on the path evaluation result, retaining the path with the same path type; pushing the entity nodes that are not in the visited tag set among the pruned adjacent entity nodes into the search stack; repeatedly performing the operations of taking out the entity nodes, calculating the path importance score, path evaluation and pushing into the search stack until the search stack is empty or reaches the preset maximum number of hops;
[0076] The entity vector cosine similarity between the target entity node and each entity node in the access tag set is calculated, and the comprehensive semantic relevance is calculated based on the entity vector cosine similarity and the exponential decay value of the shortest path length; a dynamic threshold is set according to the mean and variance of the comprehensive semantic relevance, and the expanded entity nodes whose comprehensive semantic relevance is greater than the dynamic threshold are screened out, and a candidate expansion word set is constructed based on the expanded entity nodes.
[0077] When locating the target entity node based on the search keyword in the knowledge graph, the search keyword is first segmented and entity linked to obtain the target entity node. For example, the search keyword "artificial intelligence" is located to the "artificial intelligence" entity node in the knowledge graph after entity linking.
[0078] When obtaining multi-hop neighbor nodes based on depth-first search, build a search stack and access tag set. Push the target entity node "artificial intelligence" into the search stack and add it to the access tag set. Obtain the neighboring nodes of "artificial intelligence", such as "machine learning", "deep learning", "computer vision", etc. When calculating the path importance score, consider the node weight and relationship weight. The node weight can be determined based on the degree centrality of the node, and the relationship weight can be determined based on the relationship type. For example, the relationship weight of "is an application field" is 0.8, and the relationship weight of "is a subfield" is 0.9.
[0079] When evaluating the paths of adjacent nodes, calculate the visited path scores. Taking the "artificial intelligence-machine learning" path as an example, the path score is the product of the weight of the node "artificial intelligence" 0.9 and the weight of the relationship "is a subdomain" 0.9, which is 0.81. At the same time, calculate the heuristic estimate to estimate the path score from the current node to the target node. Keep the paths with the same path type, such as "domain-subdomain" relationship paths. Push the evaluated unvisited node "machine learning" into the search stack.
[0080] The search process is repeated and stops when the search stack is empty or reaches the maximum number of hops (such as 3 hops). When calculating the semantic relevance between the target node and the visited node, the cosine similarity of the entity vector is calculated first. The entity vector can be obtained through the pre-trained model. For the shortest path length, an exponential decay function is used. The longer the path, the lower the semantic relevance. For example, the decay value of a one-hop path is 0.9, and that of a two-hop path is 0.81.
[0081] The dynamic threshold is set according to the mean and variance of semantic relevance. Assuming the mean is 0.6 and the variance is 0.1, the threshold can be set to 0.5. Nodes with semantic relevance greater than 0.5 are selected as expansion entities to construct a set of candidate expansion words.
[0082] This application can achieve:
[0083] Through depth-first search and path evaluation strategies, multi-hop neighbor nodes semantically related to the target entity can be effectively obtained, improving the accuracy and efficiency of retrieval expansion. The comprehensive semantic relevance calculation method based on entity vector similarity and path length fully considers the semantic association and structural distance between entities, making the expansion results more reasonable. The dynamic threshold screening mechanism is adopted to adaptively adjust the screening criteria according to the distribution of semantic relevance, which improves the flexibility and robustness of expansion word selection.
[0084] In an optional implementation, similarity calculation is performed on the search vector and the feature vectors of each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; and a weighted fusion algorithm is used to fuse the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score to generate a comprehensive similarity score, which includes:
[0085] Determine the cosine similarity between the retrieval vector and the subject layer feature vector in the hierarchical asset feature index library, and calculate the subject layer similarity score according to the cosine similarity of the subject layer feature vector and the weighted value of the subject layer depth; calculate the feature intersection and union ratio of the retrieval vector and the content layer feature vector based on the local sensitive hash function, and obtain the content layer similarity score according to the product of the feature intersection and union ratio and the content coverage; calculate the weighted Euclidean distance between the retrieval vector and the attribute layer feature vector, and use the weighted Euclidean distance as the attribute layer similarity score;
[0086] Calculate the information entropy of the subject layer, content layer, and attribute layer respectively, the information entropy is calculated according to the distribution probability of the feature categories of each layer; calculate the layer weight based on the information entropy of each layer, the layer weight is the normalized information entropy supplement value; count the mean and standard deviation of the similarity score of each layer, and standardize the similarity score of the subject layer, the similarity score of the content layer, and the similarity score of the attribute layer;
[0087] Calculate the correlation coefficient between the subject layer and the content layer, the subject layer and the attribute layer, and the content layer and the attribute layer, wherein the correlation coefficient is calculated by dividing the covariance of the similarity score by the product of the standard deviation; adjust the level weight based on the correlation coefficient, multiply the adjusted level weight by the similarity score of the corresponding level respectively, and sum them to obtain an initial fusion similarity score;
[0088] The confidence scores of each level are calculated, and the dynamic fusion weight is calculated according to the level weight and the confidence score; the initial fusion similarity score is weighted and normalized based on the dynamic fusion weight to obtain the optimized fusion similarity score; the Sigmoid function is used to perform nonlinear mapping on the optimized fusion similarity score to generate the final comprehensive similarity score.
[0089] First, a hierarchical asset feature index library is constructed, which includes three levels: subject layer, content layer and attribute layer. The similarity between the retrieval vector and the feature vectors of each level is calculated, and the comprehensive similarity score is obtained through weighted fusion.
[0090] For the topic layer similarity calculation, the cosine similarity method is used. The cosine similarity between the retrieval vector and the topic layer feature vector is 0.85, the topic layer depth is 3, and the weighted calculation results in a topic layer similarity score of 0.78.
[0091] The content layer similarity is based on the local sensitive hashing feature intersection and union ratio. The intersection and union ratio of the retrieval vector and the content layer feature vector is 0.72, and the content coverage is 0.9. The multiplication results in a content layer similarity score of 0.65.
[0092] The attribute layer similarity adopts weighted Euclidean distance. Taking the asset attribute "risk level - medium" as an example, the weighted Euclidean distance between the retrieval vector and the attribute feature vector is calculated to be 0.45, which is used as the attribute layer similarity score.
[0093] Then calculate the information entropy of each level. The distribution probability of the feature category at the topic level is [0.3, 0.4, 0.3], and the information entropy is calculated to be 1.58; the content level and attribute level are 1.42 and 1.35 respectively. After normalization, the level weights are 0.4, 0.35, and 0.25 respectively.
[0094] The similarity scores were standardized. The mean of the topic layer was 0.75 and the standard deviation was 0.12, the mean of the content layer was 0.68 and the standard deviation was 0.15, and the mean of the attribute layer was 0.52 and the standard deviation was 0.18. The correlation coefficients between the layers were calculated, which were 0.65 for the topic-content layer, 0.45 for the topic-attribute layer, and 0.55 for the content-attribute layer.
[0095] According to the correlation coefficient, the layer weights are adjusted to 0.38, 0.36, and 0.26. The initial fusion similarity score is calculated to be 0.72. The confidence scores of each layer are 0.85, 0.78, and 0.72, respectively, and the dynamic fusion weights are calculated to be 0.36, 0.35, and 0.29. Finally, the comprehensive similarity score is 0.68 after Sigmoid function mapping.
[0096] This application enables:
[0097] Through the hierarchical feature similarity calculation and multi-level weighted fusion, the accuracy and comprehensiveness of asset retrieval are improved, and similar features of assets at different levels can be better captured. The information entropy and correlation coefficient are used to dynamically adjust the hierarchical weights, making the feature fusion process more adaptable, avoiding the problem of single-level feature dominance, and improving the rationality of multi-level feature fusion. The introduction of confidence evaluation and nonlinear mapping mechanism enhances the reliability and discrimination of similarity calculation results, making the final comprehensive similarity score more valuable and practical.
[0098] In an optional implementation, calling the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; calling the association analysis module of the large model to calculate the association strength between the unstructured asset content based on the semantic feature matrix includes:
[0099] Extracting contextual semantic features of the unstructured asset content based on a multi-head attention mechanism, inputting the contextual semantic features into a multi-layer semantic encoder for hierarchical processing to obtain multi-layer semantic features; calculating feature weights of the multi-layer semantic features, performing weighted fusion on the multi-layer semantic features based on the feature weights, and performing enhancement processing on the fused multi-layer semantic features through nonlinear transformation; normalizing the enhanced multi-layer semantic features, and organizing the normalized multi-layer semantic features into a semantic feature matrix;
[0100] Calculate the cosine similarity of any two unstructured asset feature vectors in the semantic feature matrix, and use the cosine similarity as the semantic similarity; construct a feature dimension weight vector, calculate the weighted Euclidean distance of any two unstructured asset feature vectors based on the feature dimension weight vector, and convert the weighted Euclidean distance into a semantic distance; perform weighted combination of the semantic similarity and the exponential decay value of the semantic distance to obtain the association strength between the unstructured asset contents.
[0101] First, the unstructured asset content in the candidate search result set is obtained, and each asset content is deeply semantically analyzed. The contextual semantic features are extracted through the multi-head attention mechanism. The specific implementation process is as follows: the input text is divided into word sequences, and each word is mapped to a word vector; 8 attention heads are set, and each attention head independently calculates the query vector, key vector, and value vector; the attention score is calculated for each attention head and the weighted sum is performed to obtain the output of the head; the outputs of all attention heads are spliced and linearly transformed to obtain the output features of the multi-head attention.
[0102] Then the above features are input into a multi-layer semantic encoder for processing. The encoder contains three encoding layers, each of which contains a fully connected layer, a normalization layer, and a residual connection. The input features of each layer of the encoder are nonlinearly transformed through the fully connected layer, and then normalized, and finally residually connected with the input features to obtain the output of the layer. In this way, three layers of semantic features are obtained by layer-by-layer processing.
[0103] For the obtained three layers of semantic features, calculate the importance weight of each layer of features. Use the attention mechanism to calculate the weight score, and calculate the similarity between the three layers of features and a learnable query vector to obtain the weight. According to the weight, the three layers of features are weighted and summed to obtain the fused features. The fused features are then enhanced by a nonlinear activation function, and the enhanced features are normalized to obtain the final semantic feature vector. The semantic feature vectors of all asset contents are organized into a semantic feature matrix.
[0104] Calculate the cosine similarity of any two feature vectors in the semantic feature matrix as semantic similarity. For example, the cosine similarity of feature vectors A and B is 0.85. At the same time, construct a feature dimension weight vector and assign different weights to different dimensions of the feature. Calculate the weighted Euclidean distance between feature vectors based on the weight vector, and convert the distance value into a semantic distance value between 0 and 1, such as 0.3. Finally, perform a weighted combination of semantic similarity and the exponential decay value of semantic distance (such as 0.74), with weights of 0.6 and 0.4 respectively, to obtain the final association strength of 0.804.
[0105] This application enables:
[0106] The multi-head attention mechanism and multi-layer semantic encoder are used to perform deep semantic analysis on asset content, which can fully capture the contextual semantic information of the text and improve the expressiveness of semantic features. Through feature weighted fusion and nonlinear enhancement, multi-level semantic features are effectively integrated, the distinguishability of features is enhanced, and the semantic representation is made more robust. Combining the hybrid measurement method of semantic similarity and semantic distance, the correlation relationship between asset content is measured from multiple perspectives, making the calculation of correlation strength more accurate and reasonable.
[0107] In an optional implementation, the method further includes optimizing the asset association network:
[0108] Calculate the mean and standard deviation of the association strength, and standardize the association strength based on the mean and the standard deviation to obtain a Z score; compare the Z score with a preset significance level, screen the association strength with a significance greater than the preset significance level, and obtain a significant association strength set; count the number of nodes in the asset association network, calculate the ratio of the actual number of connections between nodes to the maximum number of connections to obtain the network density; construct an adaptive threshold based on the logarithmic term of the number of nodes and the network density;
[0109] Comparing the association strengths in the significant association strength set with the adaptive threshold, retaining the association strengths greater than the adaptive threshold, and constructing an initial asset association network with weights;
[0110] In a time window of preset length, a historical time series association strength sequence is obtained; a time decay weight is calculated based on an exponential decay function, and the time decay weight decreases as the time interval increases; the time decay weight is multiplied by the historical association strength at the corresponding moment and the sum is calculated to obtain the historical weighted association strength; the historical weighted association strength is linearly combined with the current association strength to generate the time series fusion association strength;
[0111] The correlation standard deviation of the temporal fusion correlation strength within the time window is calculated, and the correlation standard deviation is used as the fluctuation degree of the correlation relationship; a stability score is constructed based on the fluctuation degree, and the stability score decreases as the fluctuation degree increases; the stability score is used as an edge weight adjustment factor to adjust the edge weights in the initial asset association network to generate a final asset association network with temporal stability.
[0112] First, optimize the asset association network. By calculating the mean and standard deviation of the association strength, the association strength is standardized to obtain the Z score. In specific implementation, assume that an asset portfolio contains 50 assets, and the calculated association strength mean is 0.35 and the standard deviation is 0.15. Based on this, the Z score of each association strength is calculated. For example, if the association strength is 0.58, its standardized Z score is 1.53.
[0113] Compare the standardized Z score with the preset significance level (such as 0.05), screen the association strength with a significance greater than 0.05, and form a significant association strength set. The number of nodes in the asset association network is 50, and the ratio of the actual number of connections to the maximum number of connections is calculated to obtain a network density of 0.32. Based on the logarithm of the number of nodes (3.91) and the network density, an adaptive threshold is constructed, and the threshold value is 0.45.
[0114] Compare the correlation strength in the significant correlation strength set with the adaptive threshold of 0.45, retain the correlation strength greater than the threshold, and build a weighted initial asset correlation network. For example, if the correlation strength between two assets is 0.52, which is greater than the threshold of 0.45, then the correlation relationship is retained.
[0115] Get the historical time series correlation strength sequence within the 180-day time window. Use the exponential decay function to calculate the time decay weight, for example, the weight of the most recent day is 1, the weight of the previous day is 0.95, and so on. Multiply the time decay weight with the historical correlation strength at the corresponding moment and sum them to get the historical weighted correlation strength. For example, if the correlation strength of an asset pair in the last three days is 0.6, 0.55, and 0.5, respectively, and the corresponding weights are 1, 0.95, and 0.9, then the historical weighted correlation strength is 0.585. Perform a linear combination of 0.7:0.3 on the historical weighted correlation strength and the current correlation strength of 0.52 to generate a time series fusion correlation strength of 0.565.
[0116] The standard deviation of the correlation strength of time series fusion within the 180-day window is calculated to be 0.08, which is used as the volatility of the correlation relationship. A stability score is constructed based on the volatility, and the stability score corresponding to the volatility of 0.08 is 0.85. The stability score is used as the edge weight adjustment factor to adjust the edge weight of 0.565 in the initial asset association network, and finally a stable asset association with a weight of 0.48 is obtained.
[0117] This application enables:
[0118] By using adaptive thresholds to screen significant correlations, the network complexity is effectively reduced, and the interpretability and practicality of the correlation network are improved. By introducing time decay weights and historical correlation strengths, historical information is fully utilized to make the correlation network have temporal memory and improve the prediction ability of the network. Based on the degree of volatility, a stability score is constructed to adjust the edge weights, effectively suppressing the drastic fluctuations of the correlation relationship and improving the stability and reliability of the asset correlation network.
[0119] In an optional implementation, reordering and clustering the candidate search result set according to the topological structure of the asset association network to generate optimized search results includes:
[0120] Calculate the weighted degree centrality of nodes in the asset association network, where the weighted degree centrality is the sum of the edge weights connected to the node; calculate the eigenvector centrality of the node based on eigenvector decomposition; calculate the frequency of occurrence of the node in the shortest path to obtain the path centrality; perform weighted combination of the weighted degree centrality, the eigenvector centrality, and the path centrality to obtain the comprehensive importance score of the node; perform maximum and minimum value normalization processing on the comprehensive importance score to obtain a normalized importance score;
[0121] Obtain the neighborhood set of the node, multiply the normalized importance score of the neighborhood node by the edge weight and sum them to obtain the neighborhood influence of the node; count the number of common neighborhood nodes of any two nodes, and calculate the structural similarity between the nodes based on the number of common neighborhood nodes and the size of the neighborhood set; perform preliminary clustering of the nodes based on the structural similarity to obtain preliminary clustering results;
[0122] Calculate the difference between the actual connection weight and the expected connection weight between nodes, and construct a modularity objective function based on the difference; optimize the preliminary clustering result by optimizing the modularity objective function to obtain the network community division result; calculate the average connection weight between the nodes within each network community to obtain the community closeness; and calculate the average connection weight of the nodes between the network communities to obtain the distance between the communities;
[0123] The normalized importance score, the neighborhood influence, the community closeness and the distance between communities are weighted and summed to obtain a comprehensive ranking score of the node; a time decay factor is introduced to adjust the time sequence of the comprehensive ranking score to generate the final retrieval result ranking.
[0124] First, we construct the topological structure of the asset association network, where nodes represent different assets, edges represent the association between assets, and edge weights represent the strength of the association. For example, an asset network contains 100 nodes, and there are 2,000 weighted edges between nodes, with weights ranging from 0 to 1.
[0125] For each node, the sum of the weights of the edges directly connected to it is counted as the weighted degree centrality. For example, if node A is connected to 5 neighboring nodes, and the edge weights are 0.8, 0.6, 0.5, 0.3, and 0.2 respectively, its weighted degree centrality is 2.4. The eigenvector centrality of the node is calculated by eigenvector decomposition to reflect the importance of the node in the overall network structure. The path centrality is obtained by counting the number of times a node appears in all shortest paths, reflecting the intermediary role of the node.
[0126] The three centrality indicators are weighted and combined, and the weights can be set to 0.4, 0.3, and 0.3. For example, if the three indicators of a node are 2.4, 0.8, and 0.6, then its comprehensive importance score is 1.56. The scores of all nodes are normalized so that they are distributed in the range of 0-1.
[0127] Obtain the neighborhood set of each node and calculate the neighborhood influence. For example, if the normalized importance scores of the five neighbor nodes of node B are 0.8, 0.7, 0.5, 0.4, and 0.2, and the corresponding edge weights are 0.9, 0.8, 0.6, 0.5, and 0.3, then its neighborhood influence is 1.69. Count the number of common neighbors between nodes. For example, if the node pair (C, D) has three common neighbors and the sizes of their respective neighborhood sets are 6 and 8, then their structural similarity is 0.43. A hierarchical clustering method based on structural similarity is used to obtain preliminary clustering results.
[0128] The difference between the actual connection weight and the expected connection weight in the random network is calculated, and the modularity objective function is constructed and optimized to obtain the final network community division. The average connection weight between nodes within each community is calculated as the community closeness, and the average connection weight between nodes in the community is calculated as the distance between communities.
[0129] Taking into account the normalized importance score of the node, the influence of the neighborhood, the closeness of the community to which it belongs, and the distance from other communities, the weights can be set to 0.3, 0.3, 0.2, and 0.2. The time decay factor is introduced to adjust the ranking score, and the decay coefficient can be set to 0.9 to generate the final retrieval result ranking.
[0130] This application enables:
[0131] Through the combined calculation and normalization of multi-dimensional centrality indicators, the importance of asset nodes in the association network is comprehensively evaluated to improve the accuracy and reliability of search results. The community discovery method based on neighborhood influence and structural similarity effectively identifies the association groups between assets and enhances the clustering effect and association analysis ability of search results. The time decay factor is introduced to dynamically adjust the sorting results so that the search results can timely reflect the evolution characteristics of asset association relationships and improve the real-time and adaptability of the system.
[0132] Figure 2 FIG. 1 is a schematic diagram of the structure of an intelligent retrieval system for unstructured asset content based on a large model according to an embodiment of the present invention. Figure 2 As shown, the system comprises:
[0133] The first unit is used to receive a search instruction input by a user, wherein the search instruction includes a search keyword; call the knowledge graph enhancement module to perform semantic expansion on the search keyword to obtain an expanded keyword set; input the expanded keyword set into a pre-trained first encoder model to generate a search vector; use a data crawler module to obtain unstructured asset content to be retrieved, wherein the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; input the unstructured asset content into a pre-trained multimodal feature extraction model, extract multidimensional features of the unstructured asset content based on an attention mechanism of a transformer architecture, and generate an asset feature vector;
[0134] The second unit is used to construct a hierarchical asset feature index library based on the asset feature vector, wherein the hierarchical asset feature index library includes feature indexes of three levels: subject layer, content layer, and attribute layer; perform similarity calculations on the search vector and the feature vectors of each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; perform fusion calculations on the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score using a weighted fusion algorithm to generate a comprehensive similarity score; sort the search results according to the comprehensive similarity score to obtain a candidate search result set;
[0135] The third unit is used to input the candidate retrieval result set into a pre-trained large model, where the large model is trained using a contrastive learning method and has cross-modal understanding and reasoning capabilities; call the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate retrieval result set to generate a semantic feature matrix; call the association analysis module of the large model to calculate the association strength between the unstructured asset content based on the semantic feature matrix to generate an asset association network; reorder and cluster the candidate retrieval result set according to the topological structure of the asset association network to generate optimized retrieval results.
[0136] According to a third aspect of the embodiments of the present invention,
[0137] An electronic device is provided, comprising:
[0138] processor;
[0139] a memory for storing processor-executable instructions;
[0140] The processor is configured to call the instructions stored in the memory to execute the aforementioned method.
[0141] A fourth aspect of the embodiments of the present invention is:
[0142] A computer-readable storage medium is provided, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the aforementioned method is implemented.
[0143] The present invention may be a method, an apparatus, a system and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for executing various aspects of the present invention.
[0144] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. An intelligent retrieval method for unstructured asset content based on a large model, characterized in that: include: Receiving a search instruction input by a user, wherein the search instruction includes a search keyword; Calling the knowledge graph enhancement module to semantically expand the search keywords to obtain an expanded keyword set; inputting the expanded keyword set into the pre-trained first encoder model to generate a search vector; using the data crawler module to obtain the unstructured asset content to be retrieved, the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; inputting the unstructured asset content into the pre-trained multimodal feature extraction model, extracting the multidimensional features of the unstructured asset content based on the attention mechanism of the transformer architecture, and generating an asset feature vector; Based on the asset feature vector, a hierarchical asset feature index library is constructed, wherein the hierarchical asset feature index library includes feature indexes at three levels: subject layer, content layer, and attribute layer; similarity calculations are performed on the search vector and the feature vectors at each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; a weighted fusion algorithm is used to fuse the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score to generate a comprehensive similarity score; and the search results are sorted according to the comprehensive similarity score to obtain a candidate search result set; Input the candidate search result set into a pre-trained large model, which is trained using a contrastive learning method and has cross-modal understanding and reasoning capabilities; call the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; Calling the association analysis module of the large model to calculate the association strength between unstructured asset contents based on the semantic feature matrix to generate an asset association network; The candidate search result set is reordered and clustered according to the topological structure of the asset association network to generate optimized search results.
2. The method according to claim 1, characterized in that Calling the knowledge graph enhancement module to semantically expand the search keywords to obtain an expanded keyword set; inputting the expanded keyword set into a pre-trained first encoder model to generate a search vector includes: Construct a domain knowledge graph, wherein the domain knowledge graph includes an entity node set and a relationship edge set, wherein each entity node in the entity node set includes an entity type, an entity name, an entity description, and an entity alias, and the relationship edges in the relationship edge set include synonymous relationships, hierarchical relationships, part-whole relationships, and attribute relationships; pre-train the domain knowledge graph using a TransE model to obtain entity vectors and relationship vectors; Locate a target entity node corresponding to the search keyword in the domain knowledge graph; obtain a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; calculate the semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; and construct a set of candidate expansion words based on the semantic relevance; Calculate the importance score of each candidate word in the candidate expansion word set, where the importance score is weighted by semantic relevance and node centrality; select the top 5% of the candidate words in importance score as the expansion keyword set; The expanded keyword set is input into a dual-tower Transformer encoder, which includes a word vector encoding layer, a position encoding layer, a word segmentation encoding layer, a multi-head attention layer, and a feedforward neural network layer; the inter-word attention weight matrix is calculated in the multi-head attention layer to obtain a word-level context representation; the word-level context representation is fused with the global feature to obtain a fused feature; the importance weight of the fused feature is calculated based on the attention mechanism; the fused feature is weighted averaged according to the importance weight to generate a retrieval vector.
3. The method according to claim 2, characterized in that Locating a target entity node corresponding to the search keyword in the domain knowledge graph; acquiring a set of multi-hop neighbor nodes connected to the target entity node based on a depth-first search algorithm; Calculating the semantic relevance between the target entity node and each node in the multi-hop neighbor node set, wherein the semantic relevance is calculated based on entity vector cosine similarity and shortest path length; Constructing a candidate expansion word set based on the semantic relevance includes: Constructing a search stack and an access tag set, pushing the target entity node into the search stack; taking out an entity node from the search stack, and adding the entity node to the access tag set; obtaining adjacent entity nodes of the entity node, and calculating a path importance score between the entity node and the adjacent entity node, wherein the path importance score is calculated based on the product of the node weight and the relationship weight; Performing path evaluation on the adjacent entity nodes, the path evaluation includes calculating the visited path score and the heuristic estimation value; pruning the path based on the path evaluation result, retaining the path with the same path type; pushing the entity nodes that are not in the visited tag set among the pruned adjacent entity nodes into the search stack; repeatedly performing the operations of taking out the entity nodes, calculating the path importance score, path evaluation and pushing into the search stack until the search stack is empty or reaches the preset maximum number of hops; The entity vector cosine similarity between the target entity node and each entity node in the access tag set is calculated, and the comprehensive semantic relevance is calculated based on the entity vector cosine similarity and the exponential decay value of the shortest path length; a dynamic threshold is set according to the mean and variance of the comprehensive semantic relevance, and the expanded entity nodes whose comprehensive semantic relevance is greater than the dynamic threshold are screened out, and a candidate expansion word set is constructed based on the expanded entity nodes.
4. The method according to claim 1, characterized in that: Calculating the similarity of the search vector with the feature vectors of each level in the hierarchical asset feature index library in turn to obtain a similarity score of the subject layer, a similarity score of the content layer, and a similarity score of the attribute layer; and using a weighted fusion algorithm to fuse the similarity score of the subject layer, the similarity score of the content layer, and the similarity score of the attribute layer to generate a comprehensive similarity score, including: Determine the cosine similarity between the retrieval vector and the subject layer feature vector in the hierarchical asset feature index library, and calculate the subject layer similarity score according to the cosine similarity of the subject layer feature vector and the weighted value of the subject layer depth; calculate the feature intersection and union ratio of the retrieval vector and the content layer feature vector based on the local sensitive hash function, and obtain the content layer similarity score according to the product of the feature intersection and union ratio and the content coverage; calculate the weighted Euclidean distance between the retrieval vector and the attribute layer feature vector, and use the weighted Euclidean distance as the attribute layer similarity score; Calculate the information entropy of the subject layer, content layer, and attribute layer respectively, the information entropy is calculated according to the distribution probability of the feature categories of each layer; calculate the layer weight based on the information entropy of each layer, the layer weight is the normalized information entropy supplement value; count the mean and standard deviation of the similarity score of each layer, and standardize the similarity score of the subject layer, the similarity score of the content layer, and the similarity score of the attribute layer; Calculate the correlation coefficient between the subject layer and the content layer, the subject layer and the attribute layer, and the content layer and the attribute layer, wherein the correlation coefficient is calculated by dividing the covariance of the similarity score by the product of the standard deviation; adjust the level weight based on the correlation coefficient, multiply the adjusted level weight by the similarity score of the corresponding level respectively, and sum them to obtain an initial fusion similarity score; The confidence scores of each level are calculated, and the dynamic fusion weight is calculated according to the level weight and the confidence score; the initial fusion similarity score is weighted and normalized based on the dynamic fusion weight to obtain the optimized fusion similarity score; the Sigmoid function is used to perform nonlinear mapping on the optimized fusion similarity score to generate the final comprehensive similarity score.
5. The method according to claim 1, characterized in that Calling the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; Calling the association analysis module of the large model to calculate the association strength between unstructured asset contents based on the semantic feature matrix includes: Extracting contextual semantic features of the unstructured asset content based on a multi-head attention mechanism, inputting the contextual semantic features into a multi-layer semantic encoder for hierarchical processing to obtain multi-layer semantic features; calculating feature weights of the multi-layer semantic features, performing weighted fusion on the multi-layer semantic features based on the feature weights, and performing enhancement processing on the fused multi-layer semantic features through nonlinear transformation; normalizing the enhanced multi-layer semantic features, and organizing the normalized multi-layer semantic features into a semantic feature matrix; Calculate the cosine similarity of any two unstructured asset feature vectors in the semantic feature matrix, and use the cosine similarity as the semantic similarity; construct a feature dimension weight vector, calculate the weighted Euclidean distance of any two unstructured asset feature vectors based on the feature dimension weight vector, and convert the weighted Euclidean distance into a semantic distance; perform weighted combination of the semantic similarity and the exponential decay value of the semantic distance to obtain the association strength between the unstructured asset contents.
6. The method according to claim 5, characterized in that The method further includes optimizing the asset association network: Calculating the mean and standard deviation of the association strength, and normalizing the association strength based on the mean and the standard deviation to obtain a Z score; comparing the Z score with a preset significance level, screening association strengths with a significance greater than the preset significance level, and obtaining a set of significant association strengths; Counting the number of nodes in the asset-related network, calculating the ratio of the actual number of connections between the nodes to the maximum number of connections to obtain the network density; constructing an adaptive threshold based on the logarithmic term of the number of nodes and the network density; Comparing the association strengths in the significant association strength set with the adaptive threshold, retaining the association strengths greater than the adaptive threshold, and constructing an initial asset association network with weights; In a time window of preset length, a historical time series association strength sequence is obtained; a time decay weight is calculated based on an exponential decay function, and the time decay weight decreases as the time interval increases; the time decay weight is multiplied by the historical association strength at the corresponding moment and the sum is calculated to obtain the historical weighted association strength; the historical weighted association strength is linearly combined with the current association strength to generate the time series fusion association strength; Calculating the correlation standard deviation of the time series fusion correlation strength within the time window, and using the correlation standard deviation as the fluctuation degree of the correlation relationship; A stability score is constructed based on the volatility, and the stability score decreases as the volatility increases; the stability score is used as an edge weight adjustment factor to adjust the edge weights in the initial asset association network to generate a final asset association network with temporal stability.
7. The method according to claim 1, characterized in that Reordering and clustering the candidate search result set according to the topological structure of the asset association network to generate optimized search results includes: Calculate the weighted degree centrality of nodes in the asset association network, where the weighted degree centrality is the sum of the edge weights connected to the node; calculate the eigenvector centrality of the node based on eigenvector decomposition; calculate the frequency of occurrence of the node in the shortest path to obtain the path centrality; perform weighted combination of the weighted degree centrality, the eigenvector centrality, and the path centrality to obtain the comprehensive importance score of the node; perform maximum and minimum value normalization processing on the comprehensive importance score to obtain a normalized importance score; Obtain the neighborhood set of the node, multiply the normalized importance score of the neighborhood node by the edge weight and sum them to obtain the neighborhood influence of the node; count the number of common neighborhood nodes of any two nodes, and calculate the structural similarity between the nodes based on the number of common neighborhood nodes and the size of the neighborhood set; perform preliminary clustering of the nodes based on the structural similarity to obtain preliminary clustering results; Calculate the difference between the actual connection weight and the expected connection weight between nodes, and construct a modularity objective function based on the difference; optimize the preliminary clustering result by optimizing the modularity objective function to obtain the network community division result; calculate the average connection weight between the nodes within each network community to obtain the community closeness; and calculate the average connection weight of the nodes between the network communities to obtain the distance between the communities; The normalized importance score, the neighborhood influence, the community closeness and the distance between communities are weighted and summed to obtain a comprehensive ranking score of the node; a time decay factor is introduced to adjust the time sequence of the comprehensive ranking score to generate the final retrieval result ranking.
8. An intelligent retrieval system for unstructured asset content based on a large model, used to implement the method according to any one of claims 1 to 7, characterized in that: include: The first unit is used to receive a search instruction input by a user, wherein the search instruction includes a search keyword; Calling the knowledge graph enhancement module to semantically expand the search keywords to obtain an expanded keyword set; inputting the expanded keyword set into the pre-trained first encoder model to generate a search vector; using the data crawler module to obtain the unstructured asset content to be retrieved, the unstructured asset content includes at least one of a text document, an image file, an audio file, and a video file; inputting the unstructured asset content into the pre-trained multimodal feature extraction model, extracting the multidimensional features of the unstructured asset content based on the attention mechanism of the transformer architecture, and generating an asset feature vector; The second unit is used to construct a hierarchical asset feature index library based on the asset feature vector, wherein the hierarchical asset feature index library includes feature indexes at three levels: a subject layer, a content layer, and an attribute layer; perform similarity calculations on the retrieval vector and the feature vectors at each level in the hierarchical asset feature index library in turn to obtain a subject layer similarity score, a content layer similarity score, and an attribute layer similarity score; and perform fusion calculations on the subject layer similarity score, the content layer similarity score, and the attribute layer similarity score using a weighted fusion algorithm to generate a comprehensive similarity score; Sort the search results according to the comprehensive similarity scores to obtain a candidate search result set; The third unit is used to input the candidate search result set into a pre-trained large model, where the large model is trained using a contrastive learning method and has cross-modal understanding and reasoning capabilities; and call the semantic understanding module of the large model to perform deep semantic analysis on the unstructured asset content in the candidate search result set to generate a semantic feature matrix; Calling the association analysis module of the large model to calculate the association strength between unstructured asset contents based on the semantic feature matrix to generate an asset association network; The candidate search result set is reordered and clustered according to the topological structure of the asset association network to generate optimized search results.
9. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to call the instructions stored in the memory to execute the method described in any one of claims 1 to 7.
10. A computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Semantic-based data lake query system and method
CN114218400A
Cross-modal retrieval confrontation and defense method based on prompt learning
CN115658954A