Informatization construction function point retrieval and comparison method based on large language model

By adopting a functional point search comparison method based on a large language model in information construction projects, the problem of difficult to efficiently identify and avoid duplicate construction of functional points in the existing technology is solved, and more efficient and accurate functional point search and comparison are achieved, improving the efficiency of information construction projects.

CN119719337APending Publication Date: 2025-03-28UNIV OF ELECTRONICS SCI & TECH OF CHINA
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411789756.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

It is difficult for the existing technology to efficiently identify and avoid duplicate construction of functional points in informatization construction projects, especially in massive project documents, and it is difficult to accurately capture the subtle semantic differences between texts.

Method used

A method of information-based functional point search and comparison based on large language models is adopted to achieve efficient retrieval and comparison of functional point description text, multilingual synonym transcription, vector processing, construction vector database index, similar vector search, word meaning similarity calculation and semantic similarity evaluation.

Benefits of technology

It significantly improves the accuracy and efficiency of functional point search comparison, can more accurately evaluate the semantic similarity between different texts, reduce the probability of duplicate construction, and improve the overall efficiency of information construction projects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119719337A_ABST
    Figure CN119719337A_ABST
Patent Text Reader

Abstract

The invention introduces a multi-stage similar function point description text retrieval and comparison algorithm which combines the excellent semantic understanding ability of a large language model with the traditional vocabulary comparison technology. By adopting a multi-language synonym transcription technology, a possible synonym expression text library is constructed in advance; and then, the texts are converted into vector forms by utilizing a vector library technology, and indexes are established, so that the retrieval speed and accuracy are improved. And finally, by fusing a large language model and a traditional word meaning comparison algorithm, the similarity between texts can be comprehensively evaluated. According to the method, the core significance of the function point description text can be accurately extracted, and similar function points and different function points can be effectively distinguished, so that more accurate and efficient function point comparison is realized. The application of the system helps to reduce the work of repeated construction in the informatization construction process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of natural language processing, and in particular relates to a function point retrieval and comparison method based on a large language model. Background Art

[0002] With the widespread application of information technology in various industries, information construction is advancing at an unprecedented speed, and the demand for the construction of various systems is growing. However, in this process, it is common to see repeated construction of the same functional points in different departments or even different sections of the same unit, which not only causes a huge waste of resources, but also significantly affects the overall efficiency of information construction. In view of this, it is particularly urgent to study an information retrieval and comparison algorithm that can effectively avoid the repeated construction of functional points. The algorithm needs to identify and prevent the occurrence of duplicate construction from the project start-up stage, so as to improve the implementation effect of information projects and the efficiency of financial funds.

[0003] Existing text comparison and duplicate checking technologies mainly focus on the comparison of meaning at the lexical level. Even if a pre-trained model is used to extract the deep semantic features of the text, it is difficult to accurately capture the subtle semantic differences between texts. Especially in information construction projects, it is necessary not only to accurately match the semantics of the function point description, but also to perform similarity analysis on its keywords and identify synonym substitutions for keywords. Considering the long cycle and wide range of information construction, how to efficiently screen out potential duplicate construction function points from massive project documents is another challenge.

[0004] To address the above challenges, this paper proposes a method for retrieval and comparison of information construction function points that combines a large language model with traditional word meaning comparison technology. This method can not only simultaneously evaluate the semantic and lexical similarities of function points, but also use vector database technology to quickly retrieve similar function point description texts. In this way, it is expected to significantly improve the accuracy and efficiency of function point retrieval and comparison in information construction projects, and provide strong support for promoting the sustainable development of information construction. Summary of the invention

[0005] The purpose of the present invention is to provide an information construction function point retrieval and comparison method based on a large language model, which can effectively improve the efficiency and accuracy of function point retrieval and comparison. The purpose of the present invention is achieved through the following technical solutions:

[0006] S1, extraction and multi-language synonymous transcription of function point description text: First, extract the function point description text from the historical project documents, and use the large language model to perform multi-language synonymous transcription on it. Each function point forms three synonymous text descriptions in different expressions.

[0007] S2, vectorization processing of function point description text: apply the vectorization model to process all function point description texts obtained in the above steps, convert them into vector form, and preliminarily extract their semantic information.

[0008] S3, building a function point index vector database: loading the function point text vector and its synonymous version into the vector database, and building the corresponding index structure to form a special function point index vector database and a synonymous function point index vector database.

[0009] S4, vectorization of the function point description text to be compared: When a new function point description needs to be compared, first use the same vectorization model to convert it into a vector form.

[0010] S5, similarity vector retrieval: Subsequently, in the established function point vector index library and synonymous function point index vector database, a similarity search is performed on the converted function point vectors to be compared, and a similar candidate vector set and a similar synonym candidate vector set are obtained. After that, the vectors in the two candidate vector sets are restored to text form to form a similar candidate text set and a similar candidate synonym text set.

[0011] S6, word meaning similarity calculation: use the word meaning similarity algorithm to calculate the word meaning similarity between the function point description text to be compared and all the texts in the two similar candidate text sets.

[0012] S7, semantic similarity assessment: match the function point description text to be compared with all the texts in the two similar candidate text sets one by one to construct text pairs, input the text pairs into the large language model, and based on the prompt word engineering of the large language model, make the large language model output the semantic similarity of the text pairs.

[0013] S8, similarity fusion: map the word meaning similarity and semantic similarity in the similar synonym candidate text set back to the original function point text. For the original function point text that has appeared in the similar candidate text set, select the highest word meaning similarity and semantic similarity as the final similarity result.

[0014] S9, similarity threshold determination: perform weighted average calculation on the word meaning similarity and semantic similarity of each similar candidate function point text to determine the final similarity score. If the score exceeds the preset threshold, it is determined that the function point text is similar to the function point description text to be compared.

[0015] Specifically, the process of extracting the function point description text and transcribing it into multiple languages ​​in step S1 includes the following sub-steps:

[0016] S11, the function point description text T extracted from the historical project documents zhInput the translator and translate it into one or more non-Chinese languages ​​(such as English, Japanese, German, etc.). Let L be the set of target languages ​​for translation, and the translation result be T L .

[0017] T L = translate(T zh ,L)

[0018] S12, the translated result text T L Enter the translator again and translate it back to Chinese text T′ zh .

[0019] T′ zh = translate(T L ,zh)

[0020] S13, the original Chinese text T zh and the Chinese text T′ obtained after translation zh Constructed as a text pair (T zh ,T′ zh ), and input it into the large language model in step S7 for semantic similarity judgment. Let similarity(T zh ,T′ zh ) is the semantic similarity score calculated by the large language model, and the threshold is θ.

[0021] similarity(T zh ,T′ zh )=model(T zh ,T′ zh )

[0022] If the semantic similarity is below a specified criterion θ, the result is discarded:

[0023] if similarity(T zh ,T′ zh )<θ,discard T′ zh

[0024] Repeat steps S11, S12, and S13 until each function point text obtains three synonymous text descriptions with semantic similarity higher than the threshold θ.

[0025] while|{T′ zh ∣similarity(T zh ,T′ zh )≥θ}|<3,repeat S11,S12,S13

[0026] Through this process, it is ensured that each function point description text can obtain multiple high-quality synonymous transcription versions, thereby improving the accuracy and robustness of subsequent processing.

[0027] Specifically, the process of vectorizing the function point description text in step S2 includes the following sub-steps:

[0028] S21, first load the pre-trained model suitable for Chinese text vectorization.

[0029] S22, let T be the function point description text, and M be the vectorization model. Model M maps text T to a digital array V composed of tokenIDs, that is, the vector corresponding to text T. This process can be formally expressed as:

[0030] V=M(T)

[0031] Where V = [v 1 ,v 2 ,…,v n ] is a vector, each element v i Represents the tokenID of the corresponding position in the text T. Here n is the length of the vector, corresponding to the number of tokens after the text T is segmented.

[0032] Specifically, the process of constructing the function point index vector database in step S3 includes the following sub-steps:

[0033] S31, configure a vector database framework. Input the dimension n of the vector constructed in step S2 into the vector database to ensure that the database can correctly process these vectors. Let V = {V 1 ,V 2 ,V 3 ,...,V n} is the vector set constructed in step S2, where each vector V i ∈R d have the same dimension d. Configure the vector database framework (such as Faiss) so that it can accept and process vectors of dimension n, that is, for all i∈{1,2,...n}, the vector database framework can effectively store and retrieve V i .

[0034] S32, set the algorithm for calculating vector similarity. We use cosine similarity to measure the similarity between two vectors. Cosine similarity evaluates the directional similarity of two non-zero vectors by calculating the cosine value of the angle between them in multidimensional space. The specific calculation formula is as follows. Among them, A·B represents the dot product of vectors A and B. ∥A∥ and ∥B∥ represent the Euclidean norm of vectors A and B respectively. The value range of cosine similarity is [-1,1], where 1 means that the two vectors are exactly the same, -1 means that the directions of the two vectors are completely opposite, and 0 means that the two vectors are orthogonal (that is, the directions are independent).

[0035]

[0036] S33, loading the function point text vector and its synonymous version into the vector database, constructing the corresponding index structure, and forming a special function point index vector database and a synonymous function point index vector database.

[0037] Specifically, the similarity vector retrieval process in step S5 includes the following sub-steps:

[0038] S51, input the function point text vector q to be compared into the function point index vector database and the synonymous function point index vector database for retrieval, and obtain a similar candidate vector set V candidates and similar candidate synonym vector set V synonyms The retrieval process is represented as follows, where index _ main is the function point index vector database, index_synonyms is the synonymous function point index vector database, and ef is the exploration factor during search.

[0039] V candidates =searchindex(q,index _ main,ef)

[0040] V synonyms =searchindex(q,index_synonyms,ef)

[0041] S52, load the Tokenizer module of the pre-trained model used in step S2, and restore the vectors in the similar candidate vector set to text according to their token IDs to obtain a similar candidate text set T synonyms and similar candidate synonym text set T candidates .

[0042] T candidates =Tokenizer.decode(V candidates )

[0043] T synonyms=Tokenizer.decode(V synonyms )

[0044] Specifically, the word meaning similarity calculation in step S6 includes the following sub-steps:

[0045] S61, using the Chinese word segmentation library to segment the function point description text to be compared, and obtain the word set U of the function point description text to be compared. 1 and other similar candidate texts respectively i (i=1,2,…,n).

[0046] S62, use the word meaning similarity algorithm to sort the word set U 1 and word set U i Perform similarity calculation to obtain the word meaning similarity S word (U 1 ,U i ).

[0047] Specifically, the semantic similarity evaluation in step S7 includes the following sub-steps:

[0048] S71, the function point description text T to be compared 1 And each text T in the candidate set i (i=1,2,…,n) is constructed as a text pair (T 1 ,T i ).

[0049] pairs={(T 1 ,T i )|i=1,2,…,n}

[0050] S72, use the large language model deployment platform to load the large language model, use the large language model to perform reasoning and output structured results.

[0051] S73, construct a prompt word template for judging the semantic similarity of text pairs using a large language model. The prompt word template should clearly instruct the model to evaluate the semantic similarity between two texts and output a value between 0 and 1.

[0052] S74, input the prompt word template and the text pair into the large language model, and output the semantic similarity result S semantic (T 1 ,T i ).

[0053] Specifically, the similarity threshold determination process in step S9 includes the following sub-steps:

[0054] S91, perform fusion calculation on the word meaning similarity and semantic similarity to obtain the final similarity. The specific fusion method can adopt weighted average or other combination strategies. Assume that the word meaning similarity is S word , the semantic similarity is S semantic , the weights are w word and w semantic , then the final similarity S final It can be calculated by the following formula, where w semantic +w word = 1 to ensure that the weights sum to 1.

[0055] S final =w word ·S word +w semantic ·S semantic

[0056] S92, set a similarity threshold according to the function point similarity judgment requirement, and output the function point text whose final similarity is higher than the threshold. Set a similarity threshold θ according to the function point similarity judgment requirement, and output the function point text whose final similarity is higher than the threshold. The details are as follows:

[0057] similar score={T i ∣S final (T 1 ,T i )≥θ,i=1,2,…,n}

[0058] Compared with the prior art, the present invention has the following beneficial effects:

[0059] 1. This invention gives full play to the excellent ability of large language models in semantic understanding, and can more accurately evaluate the semantic similarity between different texts. Compared with traditional methods based on keyword matching or shallow grammatical analysis, this invention significantly improves the accuracy of semantic similarity judgment by deeply understanding the text content, bringing innovative progress to the field of natural language processing.

[0060] 2. In order to further enhance the flexibility and robustness of the system, the present invention introduces an innovative mechanism of multilingual synonymous transcription. This mechanism can generate multiple semantically equivalent variant texts for specific function point descriptions. This strategy not only enriches the expression of text, but also effectively reduces the probability of omissions or errors in the retrieval process of similar function points, greatly improving the quality and efficiency of information retrieval.

[0061] 3. In terms of technical implementation, the present invention cleverly combines a vector database with an efficient graph-based retrieval algorithm, namely the HNSW (Hierarchical Navigable Small World) index structure. This combination ensures that the system can maintain extremely high retrieval accuracy when faced with massive amounts of data, while controlling the retrieval time complexity to a logarithmic level. This means that even when performing complex similar function point text retrieval tasks in large-scale data sets, the present invention can provide fast and accurate services, saving users a lot of time and resources. In this way, the present invention not only solves the performance bottleneck problem existing in traditional retrieval methods, but also lays a solid foundation for the future development of high-dimensional data processing and intelligent search technologies. BRIEF DESCRIPTION OF THE DRAWINGS

[0062] Figure 1 A schematic diagram of a process of an embodiment of the present invention

[0063] Figure 2 Flow chart of function point description text extraction and multi-language synonym transcription in the embodiment of the present invention

[0064] Figure 3 Flow chart of similarity calculation in the embodiment of the present invention DETAILED DESCRIPTION

[0065] The present invention is further described below in conjunction with the accompanying drawings and examples. The embodiments of the present invention include but are not limited to the following examples.

[0066] like Figures 1 to 3 As shown, in an embodiment of the present invention, an information function retrieval and comparison method based on a large language model is implemented, including:

[0067] S10, extraction and multi-language synonymous transcription of function point description text: First, extract the function point description text from the historical project documents, and use the large language model to perform multi-language synonymous transcription on it. Each function point forms three synonymous text descriptions in different expressions.

[0068] S11, the function point description text T extracted from the historical project documents zh Input the translator and translate it into one or more non-Chinese languages ​​(such as English, Japanese, German, etc.). Let L be the target language set {English, Japanese, German}, and the translation result be T L .

[0069] T L(English,Japanese,German) = translate(T zh ,L)

[0070] S12, the translated result text T L Enter the translator again and translate it back to Chinese text T′ zh .

[0071] T′ zh = translate(T L ,zh)

[0072] S13, the original Chinese text T zh and the Chinese text T′ obtained after translation zh Constructed as a text pair (T zh ,T′ zh ), and input it into the large language model in step S7 for semantic similarity judgment. Let similarity(T zh ,T′ zh ) is the semantic similarity score calculated by the large language model, and the threshold is θ.

[0073] similarity(T zh ,T′ zh )=model(T zh ,T′ zh )

[0074] If the semantic similarity is below a specified criterion θ, the result is discarded:

[0075] if similarity(T zh ,T′ zh )<θ,discard T′ zh

[0076] Repeat steps S11, S12, and S13 until each function point text obtains three synonymous text descriptions with semantic similarity higher than the threshold θ.

[0077] while|{T′ zh ∣similarity(T zh ,T′ zh )≥θ}|<3,repeat S11,S12,S13

[0078] S20, vectorization processing of function point description text: applying a vectorization model to process all function point description texts obtained in the above steps, converting them into vector form, and preliminarily extracting their semantic information.

[0079] S21, first load the pre-trained BGE (BAAI General Embedding) model adapted for Chinese text vectorization.

[0080] S22, let T be the function point description text, and M be the vectorization model. Model M maps text T to a digital array V composed of tokenIDs, that is, the vector corresponding to text T. This process can be formally expressed as:

[0081] V=M(T)

[0082] Where V = [v 1 ,v 2 ,…,v n ] is a vector, each element v i Represents the tokenID of the corresponding position in the text T. Here n is the length of the vector, corresponding to the number of tokens after the text T is segmented. When using the BGE model, n = 1024.

[0083] S30, constructing a function point index vector database: loading the function point text vector and its synonymous version into the vector database, and constructing a corresponding index structure to form a special function point index vector database and a synonymous function point index vector database.

[0084] S31, configure the vector database framework Faiss. Input the dimension n=1024 of the vector constructed in step S2 into the vector database to ensure that the database can correctly process these vectors. Let V={V 1 ,V 2 ,V 3 ,...,V n} is the vector set constructed in step S2, where each vector V i ∈R d The vector database framework Faiss is configured so that it can accept and process vectors with a dimension of n = 1024, that is, for all i∈{1,2,...n}, the vector database framework can effectively store and retrieve V i .

[0085] S32, in order to improve the efficiency of vector retrieval in the vector database, the HNSWx index structure based on graph retrieval is used in the Faiss vector library. The HNSWx index can efficiently perform approximate nearest neighbor search by constructing a multi-layer graph structure. Let G = (V, E) be a hierarchical graph structure, where V represents the node set and E represents the edge set. G contains multiple levels, denoted by L 1 ,L 2 ,…,L m , where L 1 It is the top layer, L m is the bottom layer. Each node v i ∈V is located at a certain layer L k , and each node v iIt is connected to several nodes on the same layer or the next layer. The construction and search processes of the HNSWx index can be formalized as follows:

[0086] 1. Index construction: Let v new be the new node to be inserted, and d(v i , v j ) be the function to measure the distance between two nodes. The index construction process can be formalized as: For each layer k from 1 to m, find the nearest neighbor node new of v in layer L k

[0087] such that holds for all v ∈ L j ∈ L k . If k < m, then continue to perform the same operation in the next layer L k +1. Otherwise, insert v m into the bottom layer L new , and establish a connection with .

[0088] 2. Search process: Let q be the query point, and N(q) be the set of nearest neighbor nodes to be found.. The search process can be formalized as: Starting from the topmost layer L 1 , select the nearest neighbor node of q as the entry point, satisfying for all v j ∈ L 1 . Then, for each layer k from 1 to m - 1, based on the current node v c urrent (k) , select the nearest neighbor node k+1 of q in the next layer L as the next access target, satisfying for all v j directly connected to and v j ∈ L k+1 . Finally, perform a local search in the bottom layer L m , centered on , find all nodes v satisfying i , and add these nodes to N(q).

[0089] S33, set the algorithm for calculating vector similarity. We use cosine similarity to measure the similarity between two vectors. Cosine similarity evaluates the directional similarity of two non-zero vectors by calculating the cosine value of the angle between them in multidimensional space. The specific calculation formula is as follows. Among them, A·B represents the dot product of vectors A and B. ∥A∥ and ∥B∥ represent the Euclidean norm of vectors A and B respectively. The value range of cosine similarity is [-1,1], where 1 means that the two vectors are exactly the same, -1 means that the directions of the two vectors are completely opposite, and 0 means that the two vectors are orthogonal (that is, the directions are independent) 。

[0090]

[0091] S34, let F be the set of function point texts, and S be the set of all synonymous versions of these function point texts. Through the vectorized mapping φ, each function point text f∈F and its synonymous version s∈S are converted into a vector form v f =φ(f) and v s =φ(s). Next, the function point vector database Contains all v f , and a synonymous function point vector database Contains all v s Finally, the HNSWx index structure is established on the two vector databases to support efficient vector search. In this way, a dedicated function point index vector database and a synonymous function point index vector database are formed.

[0092] S40, vectorization of the function point description text to be compared: when a new function point description needs to be compared, it is first converted into a vector form using the same vectorization model BGE.

[0093] S50, similarity vector retrieval: Subsequently, in the established function point vector index library and synonymous function point index vector database, similarity search is performed on the converted function point vectors to be compared, and a similar candidate vector set and a similar synonymous candidate vector set are obtained. After that, the vectors in the two candidate vector sets are restored to text form to form a similar candidate text set and a similar candidate synonymous text set.

[0094] S51, input the function point text vector q to be compared into the function point index vector database and the synonymous function point index vector database for retrieval, and obtain a similar candidate vector set V candidates and similar candidate synonym vector set V synonyms The retrieval process is represented as follows, where is the function point index vector database, is the synonymous function point index vector database, and ef is the exploration factor during search.

[0095]

[0096] S52, load the Tokenizer module of the pre-trained model BGE used in step S2, and restore the vectors in the similar candidate vector set to text according to their token IDs to obtain a similar candidate text set T synonyms and similar candidate synonym text set T candidates .

[0097] T candidates =Tokenizer.decode(V candidates )

[0098] T synonyms =Tokenizer.decode(V synonyms )

[0099] S60, word meaning similarity calculation: using the word meaning similarity algorithm Jaccard, calculate the word meaning similarity between the function point description text to be compared and all the texts in the two similar candidate text sets.

[0100] S61, using the Chinese word segmentation library Jieba, segment the function point description text to be compared to obtain the word set U of the function point description text to be compared. 1 and other similar candidate texts respectively i (i=1,2,…,n). The word segmentation process is as follows:

[0101] U 1 =jieba.cut(T 1 )

[0102] U i =jieba.cut(T i ),i=1,2,…,n

[0103] S62, use the Jaccard algorithm to sort the word set U 1 and word set U i Perform similarity calculation to obtain the word meaning similarity S word (U 1 ,U i ). Jaccard similarity is defined as the ratio of the intersection and union of two sets. The specific calculation formula is as follows. 1 ∩U i || represents the word set U 1 and U i The number of elements in the intersection of |U 1 ∪U i |Represents word set U 1 and U i The number of elements in the union of .

[0104]

[0105] S7, semantic similarity assessment: match the function point description text to be compared with all the texts in the two similar candidate text sets one by one to construct text pairs, input the text pairs into the large language model, and based on the prompt word engineering of the large language model, make the large language model output the semantic similarity of the text pairs.

[0106] S71, the function point description text T to be compared 1 And each text T in the candidate set i (i=1,2,…,n) is constructed as a text pair (T 1 ,T i ).

[0107] pairs={(T 1 ,T i )|i=1,2,…,n}

[0108] S72, use the large language model deployment platform Xinference to load the large language model Qwen2.5-7B, and use the LangChain framework to use the large language model for reasoning and output structured results.

[0109] S73, construct a prompt word template for using a large language model to judge the semantic similarity of text pairs. The prompt word template should clearly instruct the model to evaluate the semantic similarity between two texts and output a value between 0 and 1. At the same time, the output of the model is required to follow the json format so that the program can be executed in a standardized manner. An example of a prompt word template is as follows:

[0110]

[0111] S74, input the prompt word template and the text pair into the large language model, and output the semantic similarity result S semantic (T 1 ,T i ).

[0112] S8, similarity fusion: map the word meaning similarity and semantic similarity in the similar synonym candidate text set back to the original function point text. For the original function point text that has appeared in the similar candidate text set, select the highest word meaning similarity and semantic similarity as the final similarity result.

[0113] S9, similarity threshold determination: perform weighted average calculation on the word meaning similarity and semantic similarity of each similar candidate function point text to determine the final similarity score. If the score exceeds the preset threshold, it is determined that the function point text is similar to the function point description text to be compared.

[0114] S91, perform fusion calculation on the word meaning similarity and semantic similarity to obtain the final similarity. The specific fusion method can adopt weighted average or other combination strategies. Assume that the word meaning similarity is S word , the semantic similarity is S semantic , the weights are w word and w semantic , then the final similarity S final It can be calculated by the following formula, where w semantic +w word = 1 to ensure that the sum of the weights is 1. At the same time, when the meanings of the words are completely similar, it means that the two texts are exactly the same. In this case, we directly take the similarity as 1.

[0115] IfS word <1:

[0116] S final =w word ·S word +w semantic ·S semantic

[0117] Else:

[0118] S final =1

[0119] S92, set a similarity threshold according to the function point similarity judgment requirement, and output the function point text whose final similarity is higher than the threshold. Set a similarity threshold θ according to the function point similarity judgment requirement, and output the function point text whose final similarity is higher than the threshold. The details are as follows:

[0120] similar score={T i ∣S final (T 1 ,T i )≥θ,i=1,2,…,n}

[0121] The above embodiments are only preferred embodiments of the present invention and are not intended to limit the protection scope of the present invention. Any changes made by adopting the design principles of the present invention and performing non-creative work on this basis should fall within the protection scope of the present invention.

Claims

1. A method for retrieving and comparing information construction function points based on a large language model, characterized in that: The following steps are involved: S1, extraction and multi-language synonymous transcription of function point description text: First, extract the function point description text from the historical project documents, and use the large language model to perform multi-language synonymous transcription on it. Each function point forms three synonymous text descriptions in different expressions. S2, vectorization processing of function point description text: apply the vectorization model to process all function point description texts obtained in the above steps, convert them into vector form, and preliminarily extract their semantic information. S3, building a function point index vector database: loading the function point text vector and its synonymous version into the vector database, and building the corresponding index structure to form a special function point index vector database and a synonymous function point index vector database. S4, vectorization of the function point description text to be compared: When a new function point description needs to be compared, first use the same vectorization model to convert it into a vector form. S5, similarity vector retrieval: Subsequently, in the established function point vector index library and synonymous function point index vector database, a similarity search is performed on the converted function point vectors to be compared, and a similar candidate vector set and a similar synonym candidate vector set are obtained. After that, the vectors in the two candidate vector sets are restored to text form to form a similar candidate text set and a similar candidate synonym text set. S6, word meaning similarity calculation: use the word meaning similarity algorithm to calculate the word meaning similarity between the function point description text to be compared and all the texts in the two similar candidate text sets. S7, semantic similarity assessment: match the function point description text to be compared with all the texts in the two similar candidate text sets one by one to construct text pairs, input the text pairs into the large language model, and based on the prompt word engineering of the large language model, make the large language model output the semantic similarity of the text pairs. S8, similarity fusion: map the word meaning similarity and semantic similarity in the similar synonym candidate text set back to the original function point text. For the original function point text that has appeared in the similar candidate text set, select the highest word meaning similarity and semantic similarity as the final similarity result. S9, similarity threshold determination: perform weighted average calculation on the word meaning similarity and semantic similarity of each similar candidate function point text to determine the final similarity score. If the score exceeds the preset threshold, it is determined that the function point text is similar to the function point description text to be compared.

2. According to claim 1, a method for retrieving and comparing information construction function points based on a large language model is characterized in that: The S1 step comprises the following sub-steps: S11, the function point description text T extracted from the historical project documents zh Input the translator and translate it into one or more non-Chinese languages ​​(such as English, Japanese, German, etc.). Let L be the set of target languages ​​for translation, and the translation result be T L . T L =translate(T zh ,L) S12, the translated result text T L Enter the translator again and translate it back to Chinese text T′ zh . T′ zh =translate(T L ,zh) S13, the original Chinese text T zh and the Chinese text T′ obtained after translation zh Constructed as a text pair (T zh ,T′ zh ), and input it into the large language model in step S7 for semantic similarity judgment. Let similarity(T zh ,T′ zh ) is the semantic similarity score calculated by the large language model, and the threshold is θ. similarity(T zh ,T′ zh )=model(T zh ,T′ zh ) If the semantic similarity is below a specified criterion θ, the result is discarded: ifsimilarity(T zh ,T′ zh )<θ,discard T′ zh Repeat steps S11, S12, and S13 until each function point text obtains three synonymous text descriptions with semantic similarity higher than the threshold θ. while|{T′ zh ∣similarity(T zh ,T′ zh )≥θ}|<3,repeat S11,S12,S13 Through this process, it is ensured that each function point description text can obtain multiple high-quality synonymous transcription versions, thereby improving the accuracy and robustness of subsequent processing.

3. The information construction function point retrieval and comparison method based on a large language model according to claim 1 is characterized in that: The S7 step includes the following sub-steps: S71, compare the function point description text T1 to be compared with each text T in the candidate set i (i=1,2,…,n) is constructed as a text pair (T1,T i ). pairs={(T1,T i )∣i=1,2,…,n} S72, use the large language model deployment platform to load the large language model, use the large language model to perform reasoning and output structured results. S73, construct a prompt word template for judging the semantic similarity of text pairs using a large language model. The prompt word template should clearly instruct the model to evaluate the semantic similarity between two texts and output a value between 0 and 1. S74, input the prompt word template and the text pair into the large language model, and output the semantic similarity result S semantic (T1,T i ).

Citation Information

Cited By

  • Two-stage electronic contract element extraction method based on large model

    CN120911437A

  • A Two-Stage Electronic Contract Element Extraction Method Based on a Large Model

    CN120911437B