A literature reference content extraction method based on a generative large model
By fine-tuning the generative large language model and replacing special symbols, the problems of slow extraction speed and inconsistency of literature citation content were solved, and efficient and accurate extraction of citation content was achieved.
Patent Information
- Application Number
- CN202510525209.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-25
- Publication Date
- 2026-01-13
- Estimated Expiration
- 2045-04-25
AI Technical Summary
Generative large language models are slow in extracting citations from documents, and the output citations may have some inconsistencies with the original document content in terms of words and symbols.
By constructing data content containing special symbols, the generative large model is fine-tuned, its input and output forms are changed, and reference fragments are replaced with reference identifiers. Sentence recognition and mapping are performed in combination with segmentation marker numbers to achieve accurate extraction of reference content.
It improves the speed and accuracy of extracting literature citations, reduces the model input length, and ensures that the output citations are completely consistent with the original literature. It is suitable for various generative large models.
Smart Images

Figure CN120046583B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of natural language processing technology, specifically relating to a method, apparatus, and electronic device for extracting literature citations based on a generative large model. Background Technology
[0002] Citations in literature reflect the connections, inheritance, and development relationships between different documents. Extracting citations plays a crucial role in areas such as content review and summarization, content evaluation, academic tracking, and knowledge graph construction. However, with the continuous development of academic research and the massive increase in the number of documents, higher demands are placed on the accuracy, efficiency, and adaptability of citation extraction.
[0003] Traditional methods for extracting citation content mainly rely on pattern matching, indicator word search, and shallow machine learning models. Pattern matching identifies citation content by manually summarizing footnote and endnote identifiers (such as "[1]", "[1]", "(Smith, 2020)") and various document identifier features; indicator word search relies on manually summarizing a large number of citation indicators (such as "an author pointed out", "a study shows") for extraction. The above methods heavily rely on manually summarized data rules and features. However, the forms of citation content in literature from different disciplines vary greatly, and there are a large number of indirect paraphrasing and other citation forms, making it difficult for these methods based on manually summarized rules and features to identify citation types not covered by manually summarized identifiers, resulting in poor adaptability.
[0004] Shallow machine learning models, after being annotated with a certain amount of cited content data and trained using supervised methods, can automatically learn the characteristics of cited content representation, thereby effectively improving the recall rate of cited content. However, this method heavily relies on the scale and quality of the annotated cited content data, and its generalization ability across different fields and types of citation data is poor, making it unable to effectively cope with complex and ever-changing citation scenarios.
[0005] Generative large language models, exemplified by ChatGPT, are trained on massive datasets and with extremely large network parameters, possessing powerful content understanding capabilities. They can comprehend complex sentence structures and semantic relationships within documents. Using only prompts or examples of citation extraction, these models can globally model the text within documents, better capturing the contextual semantic information of citations and demonstrating strong generalization ability. They can achieve high accuracy and recall in extracting citations of various types from diverse documents.
[0006] However, generative large language models also have shortcomings in extracting citations from documents: on the one hand, some words or symbols in the output citations may not be output as is, making it impossible to guarantee that all output citations are completely consistent with the original document sentences, thus failing to guarantee complete restoration; on the other hand, the need to output the complete identified citation sentences slows down the citation extraction speed. Often, to improve the extraction performance of generative large models, users provide complex and detailed instructions and citation extraction examples, which increases the model's input length and also affects the processing speed of citation extraction. New methods are urgently needed to overcome these problems and improve the overall performance of document citation extraction. Summary of the Invention
[0007] To address the aforementioned problems in existing technologies, namely the slow speed of citation extraction in generative large language models and the potential inconsistencies between the extracted citations and the original document content in terms of words and symbols, the first aspect of this invention proposes a method for extracting document citations based on a generative large language model. This method includes the following steps:
[0008] S100: Obtain the document to be processed, and obtain a set of text paragraphs based on the document to be processed;
[0009] S200. For each text paragraph in the text paragraph set, add a segmentation marker number by sentence, and replace the content containing the quoted fragment with the quoted marker symbol based on the preset citation identification rule to obtain the converted text paragraph set.
[0010] S300. Input the converted text paragraph set into the pre-tuned citation extraction model to identify sentences containing citations and extract segmentation marker numbers;
[0011] The reference extraction model is obtained by fine-tuning the parameters of a generative large model based on pre-built model fine-tuning data, and the reference extraction model incorporates reference identifiers into the reference recognition rules.
[0012] S400. After mapping the extracted segmentation marker sequence number to the sentence position information of the document to be processed, the content is extracted and the final cited content is output.
[0013] In some preferred embodiments, the method for obtaining the converted text paragraph set is as follows:
[0014] S210. Based on preset citation identification rules, identify and extract citation segments with citation identification features from all text paragraphs to form a citation segment set, and record the position information of the text corresponding to the citation segment;
[0015] S220. Add segmentation marker numbers to each text paragraph sentence by sentence, and record the position information of the sentences corresponding to the segmentation marker numbers;
[0016] S230. Replace the content containing quoted segments in the text paragraphs with added separator markers with the quoted marker symbols to obtain the converted text paragraph set.
[0017] In some preferred embodiments, the segmentation marker number includes a sentence beginning segmentation marker and a sentence ending segmentation marker.
[0018] In some preferred embodiments, the content containing quoted segments in the text paragraphs with added separator numbers is replaced with quotation symbols, and the method is as follows:
[0019] If a certain quoted segment belongs to the same sentence as a sentence within a certain segmentation number, the sentence within that segmentation number is replaced with the quoted symbol.
[0020] If a quoted segment is part of a sentence within a certain segmentation number, the corresponding part of the content within that segmentation number is directly replaced with the quoted symbol.
[0021] If a quoted segment spans multiple segmentation numbers, the parts of the sentences corresponding to the multiple segmentation numbers that are repeated with the quoted segment will be replaced with the quoted symbol.
[0022] In some preferred embodiments, the segmentation marker number of sentences containing the set of quoted sentences and / or containing the quoted identifier is extracted by means of:
[0023] Extract the sentence beginning segmentation markers of sentences containing citation symbols from the converted text paragraph set; extract the sentence beginning segmentation markers of sentences with similar content to the citation sentence set from the converted text paragraph set based on a matching algorithm;
[0024] Output all extracted sentence beginning segmentation markers one by one; if no citation marker is identified and no sentence similar to the content of the citation sentence set is matched, output None.
[0025] In some preferred embodiments, the parameters of the generative large model are fine-tuned based on pre-built model fine-tuning data, and the method is as follows:
[0026] A. Obtain various types of literature, and based on these literatures, obtain a set of text paragraphs;
[0027] B. Given an extraction instruction, use a generative large model to extract all quoted sentences containing quoted content from the text paragraph set obtained in A, forming a set of quoted sentences;
[0028] C. For each text segment in the text segment set, obtain the converted text segment set using the method described in S200;
[0029] D. Extract the segmentation marker numbers of sentences containing quotation sentences and / or sentences containing quotation symbols from the converted text paragraph set obtained in C, and obtain the segmentation marker number set;
[0030] E. Using the converted text paragraph set obtained in C as the input of the model and the segmentation marker sequence set obtained in D as the output of the model, construct fine-tuning data pairs. Based on the fine-tuning data pairs, fine-tune the parameters of the generative large model to obtain the reference extraction model.
[0031] In some preferred embodiments, the matching algorithm is specifically as follows:
[0032] Perform complete character matching on the sentences in the converted text paragraph set and the quoted sentence set. If the match is successful, extract the sentence beginning segmentation tag of the matching sentence.
[0033] If no match is found, the similarity between the converted text paragraph set and the sentences in the quoted sentence set is calculated. The similarity calculation results of each sentence to be processed are filtered. When the similarity is greater than a pre-set specific threshold, the sentence beginning segmentation tag of the sentence is extracted.
[0034] In some preferred embodiments, when outputting the extracted segmentation marker numbers, if there are duplicate segmentation marker numbers, only one is retained.
[0035] A second aspect of the present invention provides a document citation extraction device based on a generative large model, the device comprising:
[0036] The model building module is configured to fine-tune the parameters of a generative large model based on pre-built model fine-tuning data to obtain a reference extraction model; the reference extraction model incorporates reference identifiers into reference recognition rules.
[0037] The text acquisition module is configured to acquire documents to be processed and obtain a set of text paragraphs based on the documents to be processed.
[0038] The format conversion module is configured to add segmentation marker numbers to the text paragraphs in the text paragraph set, and replace the content containing quoted segments with quoted marker symbols based on preset citation identification rules, so as to obtain the converted text paragraph set.
[0039] The tag extraction unit is configured to input the converted set of text paragraphs into the citation extraction model, and use the citation extraction model to identify sentences containing citations and extract segmentation tag numbers;
[0040] The citation display module is configured to map the output segmentation marker sequence number to the sentence position information of the document to be processed, then extract the content and output the final citation content.
[0041] A third aspect of the present invention provides an electronic device comprising:
[0042] At least one processor; and
[0043] A memory communicatively connected to at least one of the processors; wherein,
[0044] The memory stores instructions that can be executed by the processor to implement the above-described method for extracting literature citations based on a generative large model.
[0045] The beneficial effects of this invention are:
[0046] (1) The present invention constructs data content containing special symbols for fine-tuning of large models, changes the input and output forms of the extracted reference content, reduces the input length of large models, and thus improves the extraction speed and extraction effect;
[0047] (2) The speed and effect of extracting referenced content can be improved by simply changing the input and output forms of the large model. It is applicable to all types of generative large models. The input and output forms are simple, easy for the model to understand and implement model fine-tuning. The expected effect can be achieved by constructing a small amount of fine-tuning data.
[0048] (3) The added steps consume very little time and can be ignored; the fine-tuned model input not only does not require the construction of reference content extraction instructions, but also replaces multiple characters with reference identifier features with a single special symbol, which greatly saves the input and output length of the model and effectively improves the reference extraction speed of large models.
[0049] (4) The sentence segmentation markers output by the model can be accurately mapped to the original literature citations, avoiding the possibility of word and symbol errors in the output of the large model before fine-tuning, and ensuring the correctness of the citation content extraction. Attached Figure Description
[0050] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings:
[0051] Figure 1 This is a flowchart of the literature citation content extraction method based on a generative large model in an embodiment of the present invention;
[0052] Figure 2This is a flowchart of obtaining a reference extraction model by fine-tuning the parameters of a generative large model in an embodiment of the present invention. Detailed Implementation
[0053] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the invention. Furthermore, it should be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings.
[0054] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0055] This invention addresses two shortcomings of generative large language models: slow speed in extracting citations and potential discrepancies between extracted citations and original documents. By modifying the input and output formats of the large model, the speed and effectiveness of citation extraction are improved, ensuring complete consistency between the extracted citations and the original documents.
[0056] To more clearly explain the literature citation extraction method based on generative large models of this invention, the following will be combined with... Figure 1-2 The steps in the embodiments of the present invention will be described in detail below.
[0057] The first embodiment of the present invention provides a method for extracting citation content based on a generative large model, comprising steps S100-S500, each step of which is described in detail below:
[0058] S100. Based on the pre-built model fine-tuning data, the parameters of the generative large model are fine-tuned to obtain the citation extraction model; the citation extraction model adds citation symbols to the citation recognition rules, which can quickly identify sentences containing citation content, including citation symbols.
[0059] Preferably, the reference extraction model is obtained by fine-tuning the parameters of a generative large model based on pre-built model fine-tuning data, and the method is as follows:
[0060] 1) Obtain various types of documents and obtain a set of text paragraphs A based on the various types of documents.
[0061] Alternatively, in this embodiment, the various types of documents refer to collections of documents, which can be papers, reports, monographs, patents, etc., in various electronic formats. The scope of the document content is not limited and can include various types of content such as natural sciences and social sciences. All documents in the collection are segmented according to conditions to obtain a set A of academic text paragraphs.
[0062] More preferably, dividing all documents in the document collection according to conditions can improve the efficiency of concurrent data processing. The division conditions can be based on natural paragraphs, logical paragraphs, or other methods, and this invention is not limited thereto. Alternatively, division can be omitted, but segmentation is beneficial for concurrent execution and speeds up processing.
[0063] 2) Given an extraction instruction P, use a generative large model to extract all quoted sentences containing quoted content from the text paragraph set, forming a set of quoted sentences B;
[0064] The reference content extraction instruction P given for a generative large model can be a detailed extraction description, a set of multiple explicit reference content extraction reference examples, or a combination of both.
[0065] 3) For academic text paragraph A in set A i Perform formalized special symbol label transformation to obtain a set of transformed text paragraphs, which serve as the input to the model.
[0066] The method to obtain the converted set of text paragraphs is as follows:
[0067] 301) Identify and extract quotations with quotation identifiers from text paragraphs to form a set of quotations C, and record the position information of the text corresponding to the quotations.
[0068] Preferably, the citation identification rules include, but are not limited to, footnote and endnote identifiers, quotation mark identifiers, and various other document identifiers. (The last sentence appears to be incomplete and possibly refers to a different document.) i The reference fragments containing the above reference identification rules are extracted to obtain a reference fragment set C, and all reference fragments are recorded in A. i The beginning and end positions of the original text. In C, a quoted segment can be a single sentence containing citation rules, a portion of a sentence containing citation rules, or multiple sentences containing citation rules. For example, taking the citation rule "", it may span multiple sentences or only a portion of a single sentence.
[0069] 302) In text paragraph A i Add segmentation marker numbers to each sentence and record the position information of the sentence corresponding to the segmentation marker number.
[0070] Preferably, the segmentation marker sequence number includes a sentence beginning segmentation marker and a sentence ending segmentation marker. With the aim of achieving sentence semantic segmentation, the segmentation can be strictly based on punctuation marks, or other more flexible segmentation methods can be adopted.
[0071] As an alternative, in this embodiment, [Bn] is used as the sentence beginning segmentation marker, and [En] is used as the sentence ending segmentation marker. No specific segmentation method is specified here, and n represents A. i The sentence sequence number is included, and during the segmentation process, the sentence represented by each segmentation number is recorded in A. i The location information within A. For example:
B2
[0072] 303) Replace the content containing quoted segments in the paragraphs with added separator numbers with the quoted symbols to obtain the converted text paragraph set. The specific method is as follows:
[0073] If a reference fragment in set C belongs to the same sentence as a sentence within a certain segmentation number [Bn][En], directly replace the sentence within the segmentation number with [CI];
[0074] If a reference fragment in set C is part of a sentence within a certain segmentation number [Bn][En], then directly replace that part of the content within the segmentation number with [CI].
[0075] If a reference fragment in set C spans multiple delimiters [Bn] and [En], then the parts of the reference fragment that overlap with the reference fragment in the multiple delimiters [Bn] and [En] will be replaced with [CI].
[0076] Example as follows:
[0077] [B1]...[E1][B2]...[E2][B3][CI][E3][B4][CI][E4];
[0078] The two [CI] could be two reference fragments in set C, or they could be a single reference fragment spanning multiple sentences.
[0079] 4) Extract the segmentation marker numbers of sentences containing quoted sentences and / or sentences containing quoted symbols from the converted text paragraph set to obtain the segmentation marker number set. The method is as follows:
[0080] Extract the sentence beginning segmentation markers of sentences containing citation symbols from the converted text paragraph set;
[0081] The sentence beginning segmentation markers of sentences similar to the content of the quoted sentences in the converted text paragraph set are extracted based on the matching algorithm; all extracted sentence beginning segmentation markers are output one by one;
[0082] If no reference identifier is detected and no sentence similar to the content of the reference sentence set is matched, the output is None.
[0083] More preferably, the matching algorithm is as follows:
[0084] Perform complete character matching on the sentences in the converted text paragraph set and the quoted sentence set. If the match is successful, extract the sentence beginning segmentation tag of the matching sentence.
[0085] If no match is found, the similarity between the converted text paragraph set and the sentences in the quoted sentence set is calculated. The similarity calculation results of each sentence to be processed are filtered. When the similarity is greater than a pre-set specific threshold, the sentence beginning segmentation tag of the sentence is extracted.
[0086] Specifically, since sentence set B may contain some characters, words, and symbols that differ from the original sentences, the sentence segmentation sequence number is first extracted by matching complete characters of the sentences. For sentences that fail to match, sentence segmentation symbols are obtained through sentence similarity calculation. The similarity calculation method is not limited and can use any method such as common string length, word repetition ratio, vector similarity, etc. Only the first segmentation sequence number of sentences with similarity greater than a specific threshold is obtained.
[0087] Preferably, when outputting all extracted segmentation marker numbers, the contents of set B and set C may be duplicated. If duplicate segmentation marker numbers exist, only one is retained.
[0088] 5) Using the converted text paragraph set obtained in 303) as the input of the model and the segmentation marker sequence set obtained in 4) as the output of the model, construct fine-tuning data pairs. Based on the fine-tuning data pairs, fine-tune the parameters of the generative large model to obtain the reference extraction model.
[0089] Preferably, in this embodiment, a certain paragraph of a paper is used as a type of literature, and various types of literature are obtained. Based on these various types of literature, a model is constructed and fine-tuned.
[0090] Get the text paragraph set A i for:
[0091] AI can never and should never become an independent rights holder; technology should not be alienated, otherwise it will challenge human rights and dignity. As early as 1950, Asimov clearly stated the first law in his Three Laws of Robotics: a robot may not injure a human being or, through inaction, allow a human being to come to harm. His second and third laws clearly demonstrate his focus on the functional design and rights protection of robots. The first law can be considered the most fundamental principle in the development of robotics and has been adopted by many researchers. It should also become the basic viewpoint of humanity regarding robots or AI. The prohibition against harming human beings should be extended to the protection of intellectual property rights as times and technology develop. [1]If the second law is considered the basis for positioning AI's functions as serving humanity, then the third law serves as a basis, to some extent, for advocating for the rights of AI-created content.
[0092] The set of quoted sentences B is obtained as follows:
[0093] "As early as 1950, Asimov clearly stated the first law in his Three Laws of Robotics: A robot may not injure a human being or, through inaction, allow a human being to come to harm." "The first law can be considered the most fundamental principle in the development of robotics and has been adopted by many researchers. It should also become the basic viewpoint of humanity regarding robots or AI. The prohibition against harming human beings should be extended to the protection of intellectual property as times and technology develop." [1] 。 ”}
[0094] The collection of reference fragments C is obtained as follows:
[0095] "The First Law can be considered the most fundamental principle in the development of robotics and has been adopted by many researchers. It should also become the basic viewpoint of humanity regarding robots or AI. The protection against harmful individual human behavior should be extended to the protection of intellectual property as times and technology develop." [1] .}
[0096] For A i Add the separator marker [Bn] and [En] as follows:
[0097] {
B1
E1
B2
E2
B3
E3
B4
CI
E4
B5
E5
[0098] The segmentation marker numbers for sentences containing quotations and / or quotation symbols in the extracted and transformed text paragraph set are:
[0099] {[B2]、[B4]}
[0100] The fine-tuning data pairs are constructed as follows:
[0101] Input: [B1] AI can never and should never become an independent rights holder; technology should not be alienated, otherwise it will challenge human rights and dignity. [E1][B2] As early as 1950, Asimov clearly stated the first law in his Three Laws of Robotics, which states that a robot may not injure a human being or, through inaction, allow a human being to come to harm. [E2][B3] The second and third laws clearly demonstrate his functional design and rights protection for robots. [E3][B4][CI][E4][B5] If the second law is considered the basis for positioning AI functions as serving humanity, then the third law, to a certain extent, is the basis for securing rights for AI-created objects. [E5]
[0102] Output: [B2], [B4]}.
[0103] 5) Based on the fine-tuned data pairs, fine-tune the parameters of the generative large model to obtain the reference extraction model.
[0104] Preferably, the model fine-tuning method can employ any approach, such as full parameter fine-tuning, adjusting only some parameters, or adding small-scale trainable modules. After model fine-tuning, the original output format, which quoted sentence content, is changed to output in the form of sentence beginning segment sequence numbers.
[0105] Further optimization allows the generative large model to be any model capable of extracting referenced content; and adds multiple special symbols such as segmentation symbols [B1], [E1], [B2], [E2]... as well as the symbols [CI] and [None] to the basic vocabulary of the large model.
[0106] After training and fine-tuning, the reference extraction model incorporates reference identifiers into the reference recognition rules, enabling it to understand and recognize the meaning of pre-defined delimiters, special delimiter serial numbers, reference identifiers, and the entire formalized special symbol label conversion method.
[0107] Step S200: Obtain the document to be processed, and obtain a set of text paragraphs of the document to be processed based on the document to be processed;
[0108] Based on the acquired documents to be processed, the content of the documents is segmented according to conditions to obtain a set of academic text paragraphs. Segmentation can improve the efficiency of concurrent data processing. The segmentation conditions can be based on natural paragraphs, logical paragraphs, or other methods.
[0109] Furthermore, in this embodiment, segmentation is not required.
[0110] Step S300: Perform formalized special symbol label transformation on each text paragraph in the set of text paragraphs of the document to be processed:
[0111] Add segmentation markers to the text paragraphs of the document to be processed sentence by sentence, and replace the content containing cited fragments with citation markers based on preset citation identification rules to obtain the converted set of text paragraphs of the document to be processed.
[0112] Preferably, the method for obtaining the set of text paragraphs of the document to be processed after conversion is as follows:
[0113] S310. Based on preset citation identification rules, identify and extract citation segments with citation identification features from text paragraphs to form a citation segment set, and record the position information of the text corresponding to the citation segment;
[0114] S320. Add segmentation marker numbers to the text paragraphs sentence by sentence, and record the position information of the sentences corresponding to the segmentation marker numbers;
[0115] S330. Replace the content containing quoted segments in the paragraphs with added separator numbers with the quoted symbols to obtain the converted text paragraph set.
[0116] Preferably, the content containing quoted segments in the text paragraphs with added separator markers is replaced with quotation marker symbols, and the method is as follows:
[0117] If a certain quoted segment belongs to the same sentence as a sentence within a certain segmentation number, the sentence within that segmentation number is replaced with the quoted symbol.
[0118] If a quoted segment is part of a sentence within a certain segmentation number, the corresponding part of the content within that segmentation number is directly replaced with the quoted symbol.
[0119] If a quoted segment spans multiple segmentation numbers, the parts of the sentences corresponding to the multiple segmentation numbers that are repeated with the quoted segment will be replaced with the quoted symbol.
[0120] Step S400: Input the converted text paragraph set of the document to be processed into the pre-tuned citation extraction model to identify sentences containing citations and extract segmentation marker numbers. The citation extraction model identifies all sentences containing citations in the input text paragraph set. After training, the model adds citation identifiers to the citation recognition rules. The identified sentences containing citations include sentences containing citation identifiers. Then, the segmentation marker numbers of all identified sentences are extracted.
[0121] Step S500: After mapping the segmentation marker number to the sentence position information of the document to be processed, the content is extracted and the final cited content is output.
[0122] When a user inputs text to be processed, the text undergoes a formal transformation. Citation fragments that can be identified using citation identification rules are replaced with citation identifiers, and the entire text is given a corresponding segmentation marker number. When the processed text is processed by the citation extraction model to identify all citation content, it is not necessary to repeatedly identify content that has already had its citation identifiers replaced. Furthermore, multiple characters with citation identifier features are replaced with a single special symbol, which greatly reduces the input length of the model and improves the recognition speed. After all citation content has been identified, the corresponding segmentation marker number is output. The original literature citation content is obtained through position mapping, avoiding the possibility of word and symbol errors in the output of the large model before fine-tuning, thus ensuring the accuracy of citation content extraction.
[0123] Although the steps in the above embodiments are described in the above order, those skilled in the art will understand that in order to achieve the effect of this embodiment, different steps do not need to be executed in such an order. They can be executed simultaneously (in parallel) or in a reverse order. These simple variations are all within the protection scope of this invention.
[0124] A second embodiment of the present invention provides a document citation extraction device based on a generative large model, the device comprising:
[0125] The model building module is configured to fine-tune the parameters of a generative large model based on pre-built model fine-tuning data to obtain a reference extraction model.
[0126] The text acquisition module is configured to acquire documents to be processed and obtain a set of text paragraphs based on the documents to be processed.
[0127] The format conversion module is configured to add segmentation marker numbers to the text paragraphs in the text paragraph set, and replace the content containing quoted segments with quoted marker symbols based on preset citation identification rules, so as to obtain the converted text paragraph set.
[0128] The tag extraction unit is configured to input the converted set of text paragraphs into the citation extraction model, and use the citation extraction model to identify sentences containing citations and extract segmentation tag numbers;
[0129] The citation display module is configured to map the output segmentation marker sequence number to the sentence position information of the document to be processed, then extract the content and output the final citation content.
[0130] The method for constructing model fine-tuning data is as follows:
[0131] A. Obtain various types of documents and, based on these documents, obtain a set of text paragraphs;
[0132] B. Given an extraction instruction, use a generative large model to extract all quoted sentences containing quoted content from the text paragraph set obtained in A, forming a set of quoted sentences;
[0133] C. For each text segment in the text segment set, obtain the converted text segment set using the method described in S200;
[0134] D. Extract the segmentation marker numbers of sentences containing quotation sentences and / or sentences containing quotation symbols from the converted text paragraph set obtained in C, and obtain the segmentation marker number set;
[0135] E. Using the converted text paragraph set obtained in C as the input of the model and the segmentation marker sequence set obtained in D as the output of the model, construct fine-tuning data pairs.
[0136] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working process and related descriptions of the system described above can be found in the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0137] It should be noted that the literature citation extraction device based on a generative large model provided in the above embodiments is only an example of the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the modules or steps in the embodiments of the present invention can be further decomposed or combined. For example, the modules in the above embodiments can be merged into one module, or further divided into multiple sub-modules to complete all or part of the functions described above. The names of the modules and steps involved in the embodiments of the present invention are only for distinguishing the various modules or steps and are not considered as an improper limitation of the present invention.
[0138] An electronic device according to a third embodiment of the present invention includes:
[0139] At least one processor; and
[0140] A memory communicatively connected to at least one of the processors; wherein,
[0141] The memory stores instructions that can be executed by the processor to implement the above-described method for extracting literature citations based on a generative large model.
[0142] A fourth embodiment of the present invention provides a computer-readable storage medium storing computer instructions, which are executed by the computer to implement the above-described method for extracting citation content based on a generative large model.
[0143] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working process and related descriptions of the electronic device and computer-readable storage medium described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0144] Those skilled in the art will recognize that the modules and method steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. The programs corresponding to the software modules and method steps can be placed in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or any other form of storage medium known in the art. To clearly illustrate the interchangeability of electronic hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in electronic hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the invention.
[0145] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0146] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0147] The terms “first”, “second”, etc., are used to distinguish similar objects, not to describe or indicate a specific order or sequence.
[0148] The term "comprising" or any other similar term is intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus / device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent in such process, method, article, or apparatus / device.
[0149] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.
Claims
1. A method for extracting citation content from literature based on a generative large model, characterized in that, Includes the following steps: S100: Obtain the document to be processed, and obtain a set of text paragraphs based on the document to be processed; S200. For each text paragraph in the text paragraph set, add a segmentation marker number by sentence, and replace the content containing the quoted fragment with the quoted marker symbol based on the preset citation identification rule to obtain the converted text paragraph set. S300. Input the converted text paragraph set into the pre-tuned citation extraction model to identify sentences containing citations and extract segmentation marker numbers; The reference extraction model is obtained by fine-tuning the parameters of a generative large model based on pre-built model fine-tuning data, and the reference extraction model adds reference identifiers to the reference recognition rules. S400. After mapping the extracted segmentation marker sequence number to the sentence position information of the document to be processed, the content is extracted and the final cited content is output. The method for fine-tuning the parameters of a large generative model is as follows: A. Obtain various types of documents and, based on these documents, obtain a set of text paragraphs; B. Given the extraction instructions, use a generative large model to extract all quoted sentences containing quoted content from the text paragraph set in A, forming a set of quoted sentences; C. For each text segment in the text segment set, obtain the transformed text segment set using the S200 method; D. Extract the segmentation marker numbers of sentences containing quotation sentences and / or sentences containing quotation symbols from the converted text paragraph set obtained in C, and obtain the segmentation marker number set; E. Using the converted text paragraph set obtained in C as the input of the model and the segmentation tag sequence set obtained in D as the output of the model, construct fine-tuning data pairs. Based on the fine-tuning data pairs, fine-tune the parameters of the generative large model to obtain the reference extraction model.
2. The method for extracting citation content based on a generative large model according to claim 1, characterized in that, The method to obtain the collection of converted text paragraphs is as follows: S210. Based on preset citation identification rules, identify and extract citation segments with citation identification features from all text paragraphs to form a citation segment set, and record the position information of the text corresponding to the citation segment; S220. Add segmentation marker numbers to each text paragraph sentence by sentence, and record the position information of the sentences corresponding to the segmentation marker numbers; S230. Replace the content containing quoted segments in the text paragraphs with added separator markers with the quoted marker symbols to obtain the converted text paragraph set.
3. The method for extracting citation content based on a generative large model according to claim 2, characterized in that, The segmentation marker sequence number includes the sentence beginning segmentation marker and the sentence ending segmentation marker.
4. The method for extracting citation content based on a generative large model according to claim 3, characterized in that, To replace quoted content in a text paragraph with a separator mark number with a quotation mark symbol, the method is as follows: If a certain quoted segment belongs to the same sentence as a sentence within a certain segmentation number, the sentence within that segmentation number is replaced with the quoted symbol. If a quoted segment is part of a sentence within a certain segmentation number, the corresponding part of the content within that segmentation number is directly replaced with the quoted symbol. If a quoted segment spans multiple segmentation numbers, the parts of the sentences corresponding to the multiple segmentation numbers that are repeated with the quoted segment will be replaced with the quoted symbol.
5. The method for extracting citation content based on a generative large model according to claim 2, characterized in that, The method for extracting the segmentation marker numbers of sentences containing quotations and / or sentences containing quotation symbols is as follows: Extract the sentence beginning segmentation markers of sentences containing citation symbols from the converted text paragraph set; extract the sentence beginning segmentation markers of sentences with similar content to the citation sentence set from the converted text paragraph set based on a matching algorithm; Output all extracted sentence beginning segmentation markers one by one; If no reference identifier is detected and no sentence similar to the content of the reference sentence set is matched, the output is None.
6. The method for extracting citation content based on a generative large model according to claim 5, characterized in that, The matching algorithm is specifically as follows: Perform complete character matching on the sentences in the converted text paragraph set and the quoted sentence set. If the match is successful, extract the sentence beginning segmentation tag of the matching sentence. If no match is found, the similarity between the converted text paragraph set and the sentences in the quoted sentence set is calculated. The similarity calculation results of each sentence to be processed are filtered. When the similarity is greater than a pre-set specific threshold, the sentence beginning segmentation tag of the sentence is extracted.
7. The method for extracting citation content based on a generative large model according to claim 1, characterized in that, When outputting the extracted segmentation marker numbers, if there are duplicate segmentation marker numbers, only one will be retained.
8. A document citation extraction device based on a generative large model, comprising the document citation extraction method based on a generative large model according to any one of claims 1-7, characterized in that, The device includes: The model building module is configured to fine-tune the parameters of a generative large model based on pre-built model fine-tuning data to obtain a reference extraction model; the reference extraction model incorporates reference identifiers into reference recognition rules. The text acquisition module is configured to acquire documents to be processed and obtain a set of text paragraphs based on the documents to be processed. The format conversion module is configured to add segmentation marker numbers to the text paragraphs in the text paragraph set, and replace the content containing quoted segments with quoted marker symbols based on preset citation identification rules, so as to obtain the converted text paragraph set. The tag extraction unit is configured to input the converted set of text paragraphs into the citation extraction model, and use the citation extraction model to identify sentences containing citations and extract segmentation tag numbers; The citation display module is configured to map the output segmentation marker sequence number to the sentence position information of the document to be processed, then extract the content and output the final citation content.
9. An electronic device, characterized in that, include: At least one processor; as well as A memory communicatively connected to at least one of the processors; wherein, The memory stores instructions that can be executed by the processor to implement the literature citation content extraction method based on a generative large model as described in any one of claims 1-7.
Citation Information
Patent Citations
Time word extraction method and device
CN109657237A
Legal provision information recommendation system based on knowledge base and large model
CN117370539A