Target text processing method and device, equipment and medium
By using the enhanced prompt information processing target text in the target field in the large language model, the problem of insufficient information extraction during the extraction of conference topic content is solved, and higher information extraction richness and accuracy are achieved.
Patent Information
- Application Number
- CN202411775429.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2044-12-04
AI Technical Summary
In the conference listening and recording scenario, when extracting the conference theme content from the speech-transformed text, it is difficult for the prior art to effectively extract information, resulting in insufficient richness and accuracy of information extraction.
By obtaining the target prompt information corresponding to the target text and the target field, using a large language model for processing, and outputting the text summary content. The target prompt information is generated based on the strengthening constraint information corresponding to the strengthening type in the target field, and is used to enhance the attention of the corresponding content in the text summary content.
It improves the richness and accuracy of information extraction in the target text, enhances the proportion of relevant content in the target field in the text summary content, and reduces the emergence of irrelevant content.
Smart Images

Figure CN119719360A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of data processing, specifically to the fields of speech recognition, human-computer interaction, artificial intelligence and large model technology, and in particular to a target text processing method, device, equipment and medium. Background Art
[0002] In the conference recording scenario, the conference topic content can be extracted from the speech-converted text.
[0003] Large Language Model (LLM) can be used to extract topic content from the target text. Summary of the invention
[0004] The present invention provides a method, device, equipment and medium for processing a target text.
[0005] According to one aspect of the present disclosure, a target text processing method is provided, comprising:
[0006] Get the target text;
[0007] Obtaining target prompt information corresponding to the target field; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target field;
[0008] The target prompt information corresponding to the target field and the target text are input into the large language model for processing, and a text summary content is output. The target prompt information is used by the large language model to increase attention to the strengthened constraint information to enhance the corresponding content in the text summary content.
[0009] According to one aspect of the present disclosure, there is provided a target text processing device, comprising:
[0010] A target text acquisition module is used to acquire the target text;
[0011] A prompt information determination module is used to obtain target prompt information corresponding to the target field; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target field;
[0012] The text summary extraction module is used to input the target prompt information corresponding to the target field and the target text into the large language model for processing, and output the text summary content. The target prompt information is used by the large language model to increase the attention of the strengthened constraint information to enhance the corresponding content in the text summary content.
[0013] According to another aspect of the present disclosure, there is provided an electronic device, comprising:
[0014] at least one processor; and
[0015] a memory communicatively connected to the at least one processor; wherein,
[0016] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the target text processing method described in any embodiment of the present disclosure.
[0017] According to another aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the target text processing method described in any embodiment of the present disclosure.
[0018] According to another aspect of the present disclosure, a computer program product is provided, including a computer program, wherein when the computer program is executed by a processor, the target text processing method described in any embodiment of the present disclosure is implemented.
[0019] The embodiments of the present disclosure can enhance the richness and accuracy of information extraction in the target text.
[0020] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure.
[0022] Figure 1 is a flow chart of a target text processing method disclosed in an embodiment of the present disclosure;
[0023] Figure 2 is a flowchart of another target text processing method disclosed in an embodiment of the present disclosure;
[0024] Figure 3 is a flowchart of another target text processing method disclosed in an embodiment of the present disclosure;
[0025] Figure 4 is a schematic diagram of a page of text summary content disclosed according to an embodiment of the present disclosure;
[0026] Figure 5 is a schematic diagram of the structure of a target text processing device disclosed in an embodiment of the present disclosure;
[0027] Figure 6 It is a block diagram of an electronic device according to the target text processing method disclosed in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0028] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.
[0029] Figure 1 This is a flow chart of a target text processing method disclosed in an embodiment of the present disclosure. This embodiment can be applied to extracting key content from a target text. The method of this embodiment can be executed by a target text processing device, which can be implemented in software and / or hardware and is specifically configured in an electronic device with certain data computing capabilities, which can be a server device.
[0030] S101, obtaining target text.
[0031] The target text may be a conference text recording the content of the meeting. The speech is acquired, and the speech is recognized to obtain the target text. The speech may refer to the speech of the meeting. The speech of the meeting may be acquired, and the target text may be obtained through speech recognition. The target text generally includes attribute information and key information of the meeting. Among them, the attribute information of the meeting may include the meeting time, meeting location, participants and meeting name (meeting theme), etc. The key information of the meeting may refer to the information extracted from the substantive content of the meeting.
[0032] S102, obtaining target prompt information corresponding to the target domain; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target domain.
[0033] Among them, the target field may refer to the field to which the voice content to be processed belongs. In some embodiments, the target field is news, and the target text should be a conference text in the news field. Exemplarily, the target fields may include: finance, education, entertainment, transportation, construction, environmental protection, energy, information technology, medical care and media, etc. The target prompt information is used to prompt how to process the target text. The target prompt information may refer to the description information of the processing task for processing the target text. In some embodiments, a large language model may be used to process the target text, and the target text and the target prompt information are fused and input into the large language model for processing. In some embodiments, the target prompt information is used to prompt the large language model how to process the target text. The target prompt information may include a prompt template prompt.
[0034] Among them, the enhancement type may refer to the dimension of data enhancement. The enhancement constraint information corresponds to the enhancement type. The enhancement constraint information may refer to the description information corresponding to the enhancement type. In some embodiments, the enhancement constraint information may enhance the constraints on the output content, enhance the text comprehension ability, and enhance the ability to extract the content in the target field. At least one enhancement type may be preset for the target field, and the enhancement types corresponding to different fields are independent of each other. The enhancement constraint information corresponding to different enhancement types are independent of each other. In some embodiments, the target prompt information generated by the enhancement constraint information is used to provide to the large language model, and accordingly, the enhancement constraint information may be natural language content.
[0035] In some embodiments, generating target prompt information according to enhanced constraint information may be performed by acquiring standard prompt information, adding the enhanced constraint information to the standard prompt information, and obtaining the target prompt information.
[0036] S103, inputting the target prompt information corresponding to the target field and the target text into the large language model for processing, and outputting text summary content, wherein the target prompt information is used by the large language model to increase attention to the strengthened constraint information to enhance the corresponding content in the text summary content.
[0037] Among them, the text summary content may refer to the key and brief content representing the target text. In some embodiments, the text summary content may include target domain outline content, digital clustering summary content, and text summary content. The target prompt information and the target text are merged to obtain input data, and the input data is input into the large language model for processing, and the text summary content is output. In some embodiments, the target prompt information and the target text are input into the large language model, the large language model encodes the input data to obtain the encoding result, and the large language model decodes the encoding result to obtain the text summary content.
[0038] In fact, strengthening the constraint information can make the large language model pay more attention to the content of the strengthened constraint information, and then make the large language model impose strong constraints on the content of the text summary, extract accurate content from the target text to enhance the voice content, etc. Among them, strengthening the constraint information to be content related to the target field can make the large language model pay more attention to content related to the target field, reduce content irrelevant to the target field, and enhance the content of the target field in the text summary content generated by the large language model.
[0039] For example, the enhanced constraint information is used to constrain the output format of the text summary content, so that the text summary content output by the large language model is the content of the output format specified in the enhanced constraint information.
[0040] As another example, the enhanced constraint information is used to limit the content extracted from the target text, so that the text summary content output by the large language model includes the content specified in the enhanced constraint information.
[0041] For another example, strengthening constraint information is used to strengthen the accuracy of the content extracted from the target text, so that the large language model strengthens the accuracy of the content extracted from the text summary content.
[0042] According to the technical solution disclosed in the present invention, by generating target prompt information according to the reinforcement constraint information corresponding to the reinforcement type of the target field, the large language model increases its attention to the reinforcement constraint information, so that the large language model performs data enhancement on the text summary content, reduces auditory hallucinations and difficulty in understanding in the text summary content, reduces content in the text summary content that is irrelevant to the target field, increases content related to the target field in the text summary content, and improves the accuracy of the text summary content in the target field.
[0043] In an optional embodiment, the target prompt information corresponding to the target field and the target text are input into a large language model for processing, and a text summary content is output, including at least one of the following: the outline prompt information corresponding to the target field and the target text are input into a large language model for processing to generate the target field outline content; and the digital prompt information corresponding to the target field and the target text are input into a large language model for processing to generate the digital cluster summary content.
[0044] Among them, the target domain outline content may refer to the outline content adapted to the target domain. The digital cluster summary content may refer to the summary content of pure data in the target domain. The outline prompt information is used to prompt how to extract the target domain outline content from the target text. The digital prompt information is used to prompt how to extract the digital cluster summary content from the target text. In fact, some fields, such as finance, information technology, transportation or education, involve data statistical analysis. In these fields involving data analysis, data is a representative key content. The target domain outline content can be understood as extracting the summary content in the target text from the perspective of content. Exemplarily, the target domain outline content may include at least one directory, and the original text in the target text corresponding to each directory. The digital cluster summary content may extract the summary content in the target text from the perspective of data. Exemplarily, the digital cluster summary content may include at least one data class, and the attribute information and attribute values of the data included in each data class.
[0045] In one example, the target domain is the financial domain, and the text summary content includes target domain outline content and digital clustering summary content.
[0046] It can be seen that by configuring the text summary content as the target field outline content and / or the digital clustering summary content, it is possible to obtain the text summary content from multiple dimensions, flexibly increase the text summary content for the target field, enrich the text summary content, and improve the pertinence of the text content.
[0047] Figure 2 It is a flowchart of another target text processing method disclosed in accordance with the embodiment of the present disclosure, which is further optimized and expanded based on the above technical solution, and can be combined with the above optional implementation methods. The target prompt information corresponding to the target field and the target text are input into the large language model for processing, and the text summary content is output, which is specifically as follows: the outline prompt information corresponding to the target field and the target text are input into the large language model for processing to generate the target field outline content; and the digital prompt information corresponding to the target field and the target text are input into the large language model for processing to generate the digital cluster summary content; and when the enhanced type includes: when the segmented processing is performed, the outline prompt information corresponding to the target field and the target text are input into the large language model for processing to generate the target field outline content, which is specifically as follows: according to the first prompt information and the target text, a multi-level directory is generated; the multi-level directory is divided into tasks to generate at least one directory information extraction task; for each directory information extraction task, according to the directory information extraction task, the second prompt information and the target text, the target text corresponding to the directory of the directory information extraction task is generated.
[0048] S201, obtaining target text.
[0049] S202, obtaining target prompt information corresponding to the target domain; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target domain, and the reinforcement type includes: segmented processing.
[0050] Among them, the enhanced type of segmentation processing can refer to segmentation of the target text in the scenario of outline generation. In fact, since the large language model limits the length of the output text, when the length of the target text is too long and a longer or even longer output text is required, the large language model often has auditory hallucinations, output format errors, and outputs long sentences without punctuation marks.
[0051] Through the enhanced type of segmentation processing, the target text can be segmented and integrated, thereby avoiding the reduction in output accuracy caused by the output length limitation of the large language model.
[0052] S203: Generate a multi-level directory according to the first prompt information and the target text.
[0053] The first prompt information is used to generate a directory. A multi-level directory may refer to a directory of at least two levels. A multi-level directory includes multiple directories. Directories of adjacent levels have a subordinate relationship. Optionally, the multi-level directory includes two-level directories, wherein the first-level directory may include at least one second-level directory, and the first-level directory may not include the second-level directory. Optionally, the multi-level directory includes a third-level directory, wherein the second-level directory may include at least one third-level directory, and the second-level directory may not include the third-level directory.
[0054] In some embodiments, the first prompt information and the target text are merged to obtain input data, which is input into the large language model to output a multi-level directory. Exemplarily, the first prompt information is: please output the outline directory of the target text.
[0055] In an example, the outline directory generates the following structure:
[0056] #1 Level Directory
[0057] ##2nd level subdirectory
[0058] ##2nd level subdirectory
[0059] #1 Level Directory
[0060] ##2nd level subdirectory
[0061] ##2nd level subdirectory
[0062] ##2nd level subdirectory
[0063] S204: Divide the multi-level directories into tasks to generate at least one directory information extraction task.
[0064] Among them, task division can refer to processing multiple directories separately. The directory information extraction task can refer to the task of mapping the original text of the target text for the corresponding directory. In fact, different directories usually correspond to different paragraphs in the target text. Extracting the original text for a part of the directory is actually extracting the original text of some paragraphs in the target text, which is equivalent to extracting the target text in segments. It should be noted that different directories do not include directories with a subordinate relationship. For example, a first-level directory includes a second-level directory. The first-level directory is usually the integration result of the original text corresponding to the included second-level directory. Correspondingly, the original text corresponding to the first-level directory and the original text corresponding to the included second-level directory have repeated content. According to the hierarchical structure in the multi-level directory and the number of directories at the same level, the multi-level directory can be divided into directories of the same task, and a directory information extraction task is generated, which is used as the directory corresponding to the directory information extraction task.
[0065] In some embodiments, directories with subordinate relationships are divided into the same task. In the case where a primary directory includes a secondary directory, the secondary directory is actually a directory obtained by dividing and summarizing the original text corresponding to the primary directory. Therefore, the original text corresponding to the primary directory and the original text corresponding to the included secondary directory have repeated content. In order to avoid repeated redundant operations, the directories with subordinate relationships are divided into the same directory information extraction task for processing.
[0066] S205 . For each of the directory information extraction tasks, generate associated content corresponding to the directory of the directory information extraction task according to the directory information extraction task, the second prompt information and the target text.
[0067] Among them, the second prompt information is used to extract the text corresponding to the directory from the target text. The associated content of the directory can refer to the extracted content of the text corresponding to the directory in the target text, wherein the corresponding text in the target text includes at least one sentence. In fact, the associated content can be the content obtained by further subdividing the directory. The associated content is different from the original text of the target text, and the associated content is the summarized and refined content. The directory, the second prompt information and the target text corresponding to the directory information extraction task are merged to obtain input data, and the input data is input into the large language model to output the associated content corresponding to each directory in the directory information extraction task. Exemplarily, the second prompt information is: Please output the original text corresponding to the outline directory of the target text.
[0068] Among them, the original text corresponding to the high-level directory in the hierarchical directory of the affiliation relationship is further summarized in sections to obtain the included low-level directories. Accordingly, only the target text content can be extracted from the lowest-level directory, and the high-level directories can be integrated layer by layer to obtain their corresponding related content. Among them, the related contents corresponding to different directories without affiliation are different, and the directory information extraction tasks are independent of each other, so different directory information extraction tasks can be executed in parallel.
[0069] S206, generating target domain outline content according to the associated content corresponding to the directory of each directory information extraction task; and / or
[0070] Among them, all generated directories and the associated contents corresponding to each directory can be used to generate the target domain outline content. The directory structure is retained in the target domain outline content, and there is a corresponding relationship between the associated content and the directory, so that the directory can be extracted and filled with content from the continuous content of the target text, which can make the directory more focused on a small range of associated content in the target text.
[0071] The disclosed embodiment chooses to generate an outline rather than directly generate a report because the large language model has insufficient output capabilities for long texts. A single long text input cannot output content that meets the requirements. The contents extracted from different directory structures in the outline can be extracted separately, and the understanding and generation capabilities of the large language model can be fully utilized to split the outline into multiple directory structures that output accurate parts.
[0072] In addition, for scenarios where the target field is finance, we choose to generate an outline based on the document structure instead of directly generating financial topics, taking into account the non-orthogonal characteristics of the topic meaning. For example, although the content focus is different, the scope of content covered is roughly the same. If the large language model generates two topics, company performance and financial status, in the subsequent processing logic, the large language model will often extract completely identical content to fill the topic, making the financial report not only lack a logical structure, but also extracting a large amount of duplicate content, resulting in reduced accuracy of the extracted related content.
[0073] S207: Input the digital prompt information corresponding to the target field and the target text into a large language model for processing to generate digital clustering summary content.
[0074] According to the technical solution disclosed in the present invention, by generating a multi-level directory from the target text, the hierarchy of the directory can be increased, the situation where general topics cause the inability to distinguish different texts, and the situation where text duplication is caused by directory-based extraction can be avoided. By increasing the task of dividing the directory for information extraction, the extracted information can be made more focused, and the outline can be associated with information extracted from continuous directory texts to make the outline structure more reasonable and accurate. By dividing multiple tasks, it can be avoided that the output text exceeds the word count and the accurate content cannot be extracted.
[0075] In an optional embodiment, the multi-level directory is divided into tasks to generate at least one directory information extraction task, including: in the multi-level directory, obtaining multiple high-level directories; dividing each of the high-level directories into at least one task, with the upper limit of the number of divided tasks being a specified number; for each high-level directory, dividing the low-level directories associated with the high-level directory into the tasks divided by the high-level directory, to generate at least one directory information extraction task.
[0076] Among them, the high-level directory includes the low-level directory. Too many divided tasks will increase resource waste. Too few tasks and the length of the target text is too long will reduce the accuracy of the associated content under the condition of the length limit of the output text. It is necessary to set a reasonable number of tasks. The specified number can be determined based on experiments. For example, the specified number is 4.
[0077] In some embodiments, when the number of the highest-level directories is less than a specified number, the number of the highest-level directories can be used as the number of divided tasks; when the number of the highest-level directories is greater than or equal to the specified number, the specified number is used as the number of divided tasks. In some embodiments, when the length of the target text is short, a smaller number of tasks can be generated, for example, 1 task, 2 tasks, or 3 tasks. The number of divided tasks can be determined based on the length of the target text. For example, when the length of the target text is greater than or equal to a preset length threshold, the number of divided tasks is determined to be at most 4; for another example, based on the length of the target text, the length range is determined in a plurality of preset length ranges corresponding to the number of tasks, and the corresponding number of tasks is determined as the number of divided tasks.
[0078] Among them, the low-level directory associated with the high-level directory can refer to the directory subordinate to the high-level directory. Usually, the target text generates at least one high-level directory, and for each high-level directory, the content corresponding to the high-level directory is subdivided to generate at least one low-level directory. The generated low-level directory belongs to the high-level directory, and the low-level directory is associated with the high-level directory. Directly dividing the high-level directory and dividing the low-level directories included in the high-level directory into the same task of the high-level directory can extract continuous content, avoiding different tasks for the same continuous content resulting in repeated related content, which is easy to cause extraction errors.
[0079] It can be seen that by dividing the tasks of high-level directories, generating directory information extraction tasks, and dividing the low-level directories associated with the high-level directories into the tasks where the high-level directories are located, the task division operation can be simplified, and the extraction of the same continuous content can be focused on the same task, thereby improving the accuracy of the associated content and generating higher quality outline content.
[0080] In an optional embodiment, dividing each of the high-level directories into at least one task includes: obtaining a directory order between each of the high-level directories; and dividing each of the high-level directories into at least one task according to each of the directory orders, wherein the number of directories included in the task of the high-level directory with an earlier directory order is less than the number of directories included in the task of the high-level directory with a later directory order.
[0081] The directory order may indicate the order of the contents corresponding to each directory in the target text. Usually, when displaying high-level directories, the high-level directories are arranged in sequence according to the order of the contents in the target text. The high-level directories may be evenly divided into a specified number of tasks according to the principle of equal division, and different tasks may include different high-level directories. In the case of being unable to be evenly divided, some tasks may include more directories than some tasks.
[0082] Generally speaking, the content in the first half of the target text is relatively more important than the content in the second half of the target text. For the task of content extraction, for the large language model with the output capacity of long text and the product form, when the content to be processed increases, the extraction accuracy of the large language model will decrease. By making the number of directories included in the tasks of the high-level directories with the first directory order smaller than the number of directories included in the tasks of the high-level directories with the last directory order, the large language model can pay more attention to the content in the first half of the target text and extract better quality content.
[0083] The principle of task division is to divide according to the first-level directory, and then perform 1-4 LLM tasks in the second round based on the number of first-level directories generated. If more than 4 first-level directories are generated, which is the most common case, the first-level directories (combined with the built-in second-level directories) are evenly distributed to the subsequent 4 tasks. Considering the long text output capability and product form of the large language model, the number of generated directories is small at the beginning and large at the end.
[0084] It can be seen that by making the number of directories included in the tasks of the high-level directory with an earlier directory order smaller than the number of directories included in the tasks of the high-level directory with a later directory order, it is possible to divide the former tasks into fewer directories and the latter tasks into more tasks, so that the content extracted from the directory with an earlier directory order has higher quality and sufficient content extraction can be achieved.
[0085] In an optional embodiment, the multi-level directory includes: a primary directory and a secondary directory.
[0086] Among them, the first-level directory can be a high-level directory, and the second-level directory can be a low-level directory. Or the first-level directory can be a low-level directory, and the second-level directory can be a high-level directory.
[0087] In an example, the extracted multi-level directory is as follows:
[0088] #Company Financial Performance
[0089] First Quarter Financial Highlights
[0090] ##Revenue growth and gross profit margin improvement
[0091] ##Cost Control and Operational Efficiency
[0092] Among them, the first round of tasks is to generate a multi-level directory. The second round of tasks is to obtain the associated content of the directory (i.e., the directory information extraction task). If the first round only extracts the first-level directory, i.e., "company financial performance", the extracted directory is too general, making it difficult for the current LLM task to extract the specified content from a specific text. In this way, the information extraction between different topics will be very confusing and a large amount of information may be repeatedly extracted by similar topics. On the contrary, if the extracted directory is too detailed, for example, retaining the 3-4-level directory structure, it will increase the difficulty of LLM's understanding, especially the difference in LLM's understanding between the two rounds of tasks. When the second round of LLM cannot recognize a certain level of sub-directory extracted in the first round, it will easily produce auditory hallucinations in the process of information extraction, that is, LLM uses its own existing knowledge to freely express opinions on a certain topic, and is no longer loyal to the original text. Whether the extraction is loyal to the original text is difficult to avoid by adjusting the instructions of the current LLM. After experiments, the effect of retaining the 1st and 2nd level directories is the current optimal choice.
[0093] It can be seen that by adopting the first and second level directories as the outline structure, we can avoid general themes that cannot distinguish different texts, resulting in repeated extracted related content, and avoid auditory hallucinations and associations caused by detailed themes, resulting in inaccurate related content. Therefore, adopting the first and second level directories can improve the accuracy of the outline content.
[0094] In an optional embodiment, the enhancement type includes: character enhancement processing; the outline prompt information corresponding to the target field is generated by: obtaining general prompt information corresponding to the target field; obtaining enhancement prompt information corresponding to the target field; generating the outline prompt information corresponding to the target field based on the general prompt information and the enhancement prompt information.
[0095] Among them, the reinforcement type of the role reinforcement processing may refer to the type of strengthening the understanding of the large language model of its own role when generating the outline content of the target domain. Outline prompt information may refer to the outline content related to the target domain. General prompt information may refer to prompt information that is available in any field. Strengthened prompt information may refer to prompt information dedicated to the target domain. The strengthened prompt information for different target domains is different. In some embodiments, the general prompt information may be prompt information of prompt (prompt template). Strengthened prompt information may be prompt information of system. Among them, system is used to set the behavior, role and background of the large language model. Usually system is often used to start a conversation, give a general direction of a conversation, or set the tone and style of the conversation. It can help set the context of the conversation so that the large language model can better understand its role in the conversation. Add the strengthened prompt information system to the general prompt information prompt to generate the target prompt information.
[0096] In some embodiments, outline prompt information may be generated in real time during human-computer interaction, or may be generated in advance, and during human-computer interaction, when character enhancement is required, the outline prompt information with added enhancement prompt information may be directly used.
[0097] It can be seen that by adding enhanced prompt information to the general prompt information, the correlation between the output of the large language model and the target domain can be strongly constrained, the domain relevance of the target domain in the outline content can be improved, and redundant content irrelevant to the target domain can be reduced.
[0098] In an optional embodiment, the acquiring of the general prompt information corresponding to the target domain includes: acquiring an extended domain corresponding to the target domain; and generating the general prompt information corresponding to the target domain according to the description information of the target domain and the description information of the extended domain.
[0099] The extended domain may refer to a domain that is related to the target domain but outside the target domain. The extended domain may be regarded as a supplementary extension of the target domain. The descriptive information may refer to the content describing the domain. For example, the descriptive information may be an example of the domain.
[0100] In some embodiments, the target domain is the financial domain. For example, common financial topics may include: company profile, main products, industry analysis, development trends, competitive advantages, and team status, etc. Topics in the extended domain may include: information about the company, business, industry, finance, financial and product information, etc. The target domain and extended domain are added to the general prompt information to constrain the topic of the target text to be related to the target domain.
[0101] In one example, the large language model determines that the target text does not belong to the target domain and the extended domain based on the general prompt information, does not generate the target domain outline content for the target text, and can output the content that the target text does not belong to the target domain.
[0102] For example, based on general prompt information, the large language model determines that part of the target text does not belong to the target domain and the extended domain. This part of the content does not generate the target domain outline content, and the final output target domain outline content does not include this part of the content and related information.
[0103] In fact, in conference texts, especially in voice conference texts, there are opening remarks, introductions of participants, and greetings and questions. The large language model will generate an outline structure for these contents, but this is actually irrelevant to the target domain and is not the focus of the target domain. The extraction of the outline must be judged based on the subject information of the target domain, and content that does not conform to the subject of the target domain will not be included in the outline. The large language model has a large gap between the content of the target text input and all the topics involved in the description information of the target domain and the extended domain. This is equivalent to the user inputting irrelevant document content, and directly outputting information that cannot be extracted from the target domain, thereby terminating the human-computer interaction task.
[0104] It can be seen that by combining the target domain and the extended domain obtained by its supplementary extension, and constraining the description information of the domain in the general prompt information, the relevance of the output target domain outline content to the target domain can be strengthened, and redundant content irrelevant to the target domain can be reduced. The large language model can be inspired to generate a content outline that conforms to the subject context of the target domain and suppress the content of non-target domains.
[0105] In an optional embodiment, obtaining enhanced prompt information corresponding to the target domain includes: obtaining outline structure information, topic key information and output text length of the target domain, and generating enhanced prompt information corresponding to the target domain; wherein the outline structure information includes hierarchical identification, hierarchical depth and hierarchical structure.
[0106] The outline structure information is used to constrain the output format. The level identifier is used to identify the level of the directory. The level depth can be used to determine the number of levels of the directory. The level structure is used to determine the relationship between directories, for example, the existence of a subordinate relationship between directories.
[0107] In some embodiments, the directory is identified by #, and the number of hierarchical identifiers of the high-level directory is less than the number of hierarchical identifiers of the low-level directories. The number of hierarchical identifiers of adjacent high-level directories is less than the number of hierarchical identifiers of the low-level directories included in the high-level directory. For example, the first-level directory is identified by one #, the second-level directory is identified by two #s, and the third-level directory is identified by three #s. The hierarchical structure can be that the first-level directory includes the second-level directory, the second-level directory includes the third-level directory, and so on; and the next adjacent line of the high-level directory is the low-level directory included in the high-level directory. When the low-level directory no longer includes the low-level directory, the next adjacent line of the low-level directory is the directory that is adjacent in the directory order, the beginnings of sentences at the same level are aligned, and the indentation length of the beginnings of directories at different levels is adjusted according to the hierarchical depth. Usually, the indentation of the high-level directory is smaller than the indentation of the low-level directory.
[0108] In an example, the extracted multi-level directory is as follows:
[0109] #Company Financial Performance
[0110] First Quarter Financial Trends
[0111] ###First Quarter Highlights
[0112] #Business Update and Outlook
[0113] ##Content and Community Development
[0114] ##Commercialization progress and marginal expansion
[0115] ##Advertising Business Growth and Strategy
[0116] ##Gaming Business Outlook and Innovation
[0117] In the above example, the level depth is 3, that is, the multi-level directory includes a first-level directory, a second-level directory, and a third-level directory. The indentation length of the first-level directory is smaller than the indentation length of the second-level directory, and the indentation length of the second-level directory is smaller than the indentation length of the third-level directory.
[0118] The key information of the subject is used to constrain the outline catalog to be related to the target domain and the target text, thereby reducing the association of the large language model. The output text length is used to constrain the length of the output text. In some embodiments, the key information of the subject can be: directly output the content, prohibit the output of the catalog prompt, so as to reduce the association of the large language model, thereby reducing the output of content irrelevant to the target text or the target domain.
[0119] In one example, the enhanced tooltip looks like this:
[0120] #Level 1 directory (directly output content, prohibit output of level 1 directory prompt)
[0121] ##Level 2 subdirectory (directly output content, prohibit output of level 2 subdirectory prompt)
[0122] ##2nd level subdirectory
[0123] #1 Level Directory
[0124] ##2nd level subdirectory
[0125] ##2nd level subdirectory
[0126] ##2nd level subdirectory
[0127] Through experiments, the use of enhanced prompt information for constraints has achieved a 100% compliance rate in the test data with the output instructions (mainly referring to not including redundant prompts and description information).
[0128] In addition, the enhanced prompt information can also include data enhancement information, for example, the outline directory must be fully discussed in the original text to increase the large language model's attention to the target text and reduce hallucinations and associations.
[0129] It can be seen that by adding outline structure information, key topic information and output text length restrictions in the enhanced prompt information, it is possible to impose strong constraints on the outline content in the target field and improve the accuracy of the outline.
[0130] In an optional embodiment, after generating the target domain outline content according to the associated content corresponding to the directory of each directory information extraction task, it also includes: obtaining the positioning time corresponding to each sentence in the target text; and determining the positioning time corresponding to each associated content according to the positioning time corresponding to each sentence in the target text and the associated content corresponding to each directory.
[0131] Among them, the target text is the text obtained by speech recognition. The positioning time may refer to the starting time of the sentence in the speech. Specifically, the positioning time may be the time when the first word in the sentence is uttered in the speech. The sentences corresponding to the associated content in the target text may be associated. According to the positioning time corresponding to each sentence, the positioning time corresponding to the associated content is integrated. The positioning time of each sentence in the target text can be obtained by time positioning the sentence in the speech when the text of each sentence is obtained by recognizing the speech. In addition, the sentences corresponding to all the associated contents corresponding to the directory are the sentences corresponding to the directory. The sentences corresponding to all the directories included in the upper-level directory are the sentences corresponding to the upper-level directory. Thus, the sentence range of each directory and the positioning time of each directory can be determined based on the order of the directories from the bottom to the top of the associated content.
[0132] In some embodiments, for the speech recognized text, it is necessary to locate it based on the generated target domain outline content, locate it to the content position corresponding to each major outline directory, and / or locate it to the time position in the speech.
[0133] It should be noted that the step of obtaining the positioning time corresponding to the associated content may not be implemented through the large language model.
[0134] In some embodiments, when the associated content information is extracted and the outline content of the target field in markdown format is generated, it is necessary to locate the original text time of each specific content output of markdown (not the title) and return it to the server, so that the product side can click on each sentence of markdown output to display the corresponding original text and find the original time of the audio. Users can instantly browse the location of each directory in the audio.
[0135] It can be seen that by obtaining the positioning time corresponding to each sentence in the target text and the associated content corresponding to the directory, matching the associated content with each sentence, and obtaining the positioning time corresponding to the directory, the needs of time positioning of the outline directory in the speech can be met in the scenario of speech summary content generation, and time positioning based on precise associated content can improve the accuracy of positioning time.
[0136] In an optional embodiment, the method of determining the location time corresponding to each directory based on the location time corresponding to each sentence in the target text and the associated content corresponding to each directory includes: obtaining a sentence range corresponding to at least one associated content based on the associated content corresponding to each directory; for each associated content, calculating, within the sentence range of the associated content, the hit probability of the associated content for each candidate sentence within the sentence range of the associated content; screening out a target sentence based on the hit probability of each candidate sentence; querying the location time corresponding to the target sentence based on the location time corresponding to each sentence in the target text; and determining the location time of the associated content based on the location time of the target sentence.
[0137] Compared with related content and directory, directory has a wider content range, and it is difficult for users to quickly understand the original text corresponding to the directory from the larger content range; related content has a smaller content range, and users can quickly understand the original text corresponding to the related content from the smaller content range. Therefore, the positioning time of related content is more effective.
[0138] Get the sentence range of the associated content in the target text. The sentence range includes at least one alternative sentence. The hit probability may refer to the probability of correlation between the associated content and the alternative sentence. The hit probability may be expressed by similarity. The target sentence may refer to the sentence that best represents the associated content among the alternative sentences. For one associated content, a target sentence is correspondingly selected. The purpose of selecting a target sentence from the alternative sentences is to retain only one sentence to represent the associated content, which can achieve streamlined sentence positioning and accurate extraction of outline content.
[0139] It can be seen that by time locating related content and reducing time positioning of advanced directories, the effective time positioning data can be streamlined, and the positioning time of the most representative target sentence within the sentence range corresponding to the related content can be screened out as the positioning time of the related content. This can achieve accurate extraction of the positioning time and reduce the positioning time of redundant content, thereby achieving the refinement of the outline content.
[0140] In an optional embodiment, within the sentence scope of the associated content, the hit probability of the associated content for each alternative sentence within the sentence scope of the associated content is calculated, including: within the sentence scope of the associated content, calculating the hit probability of the associated content and the higher-level directory to which the associated content belongs for each alternative sentence within the sentence scope of the associated content.
[0141] The associated content is a directory obtained by subdividing the content of the higher-level directory to which the associated content belongs. Accordingly, the content of the higher-level directory is related to the associated content. The associated content and the higher-level directory to which it belongs can both be used as hit objects to calculate the hit probability.
[0142] In some embodiments, the hit probability may refer to calculating the text length of the alternative statement and two consecutive directories respectively. Optionally, the total hit length of the higher-level directory in the alternative statement and the total hit length of the associated content in the alternative statement are calculated. The weighted sum of the two total hit lengths is calculated as the hit probability. In some embodiments, the associated content is segmented to obtain at least one segmented text, each segmented text is matched with the alternative statement, and it is detected whether there are words hit by each segmented text in the alternative statement, and the lengths of the hit words are accumulated to obtain the total length of the segmented text of the associated content in the alternative statement. Among them, the hit words can be the same as the segmented text or the same semantics as the word. Similarly, by replacing the associated content with a higher-level directory, the total length of the segmented text of the higher-level directory in the alternative statement can be calculated.
[0143] In one example, the hit probability score is calculated using the following formula (1):
[0144] score=len_term_last+weight*len_term_target(1)
[0145] Among them, len_term_last is the total length of the segmented text of the higher-level directory in the candidate sentence hits, and len_term_target is the total length of the segmented text of the associated content in the candidate sentence hits. Weight is the weight, and the experiment results in weight = 2.
[0146] It can be seen that by calculating the hit probability between the associated content and its higher-level directory and the same alternative statement as the hit probability between the associated content and the alternative statement, the relevant semantics of the associated content can be expanded, and the hit probability can be calculated based on the expanded semantics. This can improve the calculation accuracy of the hit probability of the alternative statement, thereby improving the accuracy of the alternative statement screening.
[0147] In an optional embodiment, the candidate sentences include: a single sentence and a continuous double sentence.
[0148] In fact, valid information related to the associated content may be simultaneously located in two adjacent sentences, so the two adjacent sentences can be used as an alternative sentence.
[0149] In an example, the statement range includes 10 statements, and each single sentence can be used as an alternative statement to obtain 10 alternative statements, and every two adjacent single sentences can be used as alternative statements to obtain 9 alternative statements. Accordingly, the statement range can determine 19 alternative statements.
[0150] Accordingly, the hit probability score of each single sentence is calculated using formula (1), and is used as the hit probability of the associated content for the single sentence. The penalty probability penalty of consecutive double sentences is calculated using the following formula (2):
[0151] penalty=(total_len_last+weight*total_len_target) / 6(2)
[0152] The hit probability score of each sentence in the continuous double sentence calculated based on formula (1) is subtracted from the penalty probability penalty calculated based on formula (2) to obtain the hit probability of the continuous double sentence, which is used as the hit probability of the associated content for the continuous double sentence.
[0153] It can be seen that by configuring the alternative sentences as single sentences or consecutive double sentences, different situations of sentences where valid information is located can be covered, so that one alternative sentence can completely cover the valid information, thereby screening the alternative sentences to obtain the target sentence, increasing the representativeness of the target sentence, and accurately locating the time of the related content.
[0154] In one example, the target text contains time information. The content of the target text is as follows:
[0155] 00:03:33A
[0156] 00:03:45B
[0157] 00:03:50C
[0158] 00:04:07D
[0159] 00:04:13E
[0160] 00:04:27F
[0161] The low-level directories that need to obtain positioning time include the following:
[0162] ##2nd level subdirectory
[0163] ###3 level subdirectory
[0164] - **Time**: XX
[0165] - **Reaction**: ZZ
[0166] -**Location**: YY
[0167] ##2nd level subdirectory
[0168] In fact, -**time**:XX is the associated content, where time and XX contain less information. You can first find the higher-level directory of this content, for example, the 3rd-level subdirectory. Record XX as sent_target and the 3rd-level subdirectory as sent_last.
[0169] Segment sent_target and sent_last, and remove information that does not contribute much to similarity calculation. For example, information that does not contribute much to similarity calculation includes: punctuation and markdown symbols. The text set after segmentation is recorded as: term_target, term_last.
[0170] The hit probability of each sentence A, sentence B, sentence C, sentence D, sentence E and sentence F.
[0171] For example, for a single sentence A, "XX" appears in the original sentence A, and the hit length is 2. If the level 3 subdirectory appears in the original sentence A, the hit length is 3. Calculate the hit probability of term_target for single sentence A and the hit probability of term_last for single sentence A respectively, and get the hit probability of term_target and term_last for single sentence A.
[0172] For consecutive double sentences AB, BC, CD, DE and EF, the hit probability of the double sentences is calculated.
[0173] For example, the penalty probability of consecutive double sentences AB is calculated. The hit probability of double sentences AB is the sum of the hit probability of single sentence A and the hit probability of single sentence B, minus the penalty probability of AB, to obtain the hit probability for consecutive double sentences AB.
[0174] Find the alternative sentence with the highest hit probability among single sentences A, single sentence B, single sentence C, single sentence D, single sentence E, single sentence F, AB, BC, CD, DE and EF, and use it as the target sentence. Determine the positioning time of the target sentence as the positioning time of the associated content.
[0175] In one example,
[0176] The low-level directories that need to obtain positioning time include the following:
[0177] ##2nd level subdirectory
[0178] ###3 level subdirectory
[0179] -**Time**: XX(00:03:50)
[0180] - **Reaction**: ZZ (00:04:07)
[0181] - **Location**: YY(00:04:27)
[0182] ##2nd level subdirectory
[0183] In fact, during the calculation of the positioning time, because the content to be retrieved has already clearly defined the retrieval time range in advance (generated in the LLM process), the retrieval time of the server can be controlled within 1ms, including the time for word segmentation and retrieval, which fully meets the requirements of real-time retrieval.
[0184] Figure 3 It is a flowchart of another target text processing method disclosed in an embodiment of the present disclosure, which is further optimized and expanded based on the above technical solution, and can be combined with the above optional implementation methods. The target prompt information corresponding to the target field and the target text are input into the large language model for processing, and the text summary content is output, which is specifically as follows: the outline prompt information corresponding to the target field and the target text are input into the large language model for processing to generate the target field outline content; and the digital prompt information corresponding to the target field and the target text are input into the large language model for processing to generate the digital cluster summary content; and the generation method of the digital prompt information corresponding to the target field is specifically as follows: when the enhancement type includes contrast enhancement, the contrast subject enhancement extraction information of the target field is generated and added to the digital prompt information corresponding to the target field; when the enhancement type includes output description enhancement, the output description information of the target field is generated and added to the digital prompt information corresponding to the target field, wherein the output description information includes a description field and an attribute value field; when the enhancement type includes translation enhancement, the translation enhancement information of the target field is generated and added to the digital prompt information corresponding to the target field.
[0185] S301, obtaining target text.
[0186] S302, obtaining target prompt information corresponding to the target domain; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target domain.
[0187] S303, inputting the outline prompt information corresponding to the target domain and the target text into a large language model for processing to generate the outline content of the target domain; and / or
[0188] S304: Input the digital prompt information corresponding to the target field and the target text into a large language model for processing to generate digital clustering summary content.
[0189] S305, the digital prompt information corresponding to the target area is generated in the following manner: when the enhancement type includes contrast enhancement, contrast subject enhancement extraction information of the target area is generated and added to the digital prompt information corresponding to the target area.
[0190] The enhancement type of contrast enhancement may refer to the type of contrast data that needs to be enhanced in the scenario of data comparison and analysis. The contrast subject enhancement extraction information may refer to the information of extracting the main content of the contrast before and after in the target text. The digital prompt information may refer to the prompt information that prompts the large language model to extract the digital summary content from the target text.
[0191] In one example, the target field is the financial field. When year-on-year and / or quarter-on-quarter data descriptions appear in the target text, the main information for comparison must be extracted from the context of the target text, such as: a year-on-year increase of 15%, and the year-on-year time range must be included, such as year-on-year growth in 2024, or year-on-year growth in the third quarter.
[0192] S306: When the enhancement type includes output description enhancement, generate output description information of the target field and add it to the digital prompt information corresponding to the target field, wherein the output description information includes a description field and an attribute value field.
[0193] The enhanced type of output description enhancement may refer to the need to limit (or constrain) the data output format and output content in the scenario of data analysis. The output description information may refer to the description information of the data extracted from the target text. The description field is used to describe the content of the data, and the attribute value field is used to describe the value of the data.
[0194] In some embodiments, two fields, name and value, are used to express a specific data content. The description of the data required in the output description information is placed in the name as much as possible, and the specific numerical information is placed in the value. In the implementation process, different few shots can be added in sequence to improve the expressiveness of the numbers.
[0195] In an optional embodiment, the target field is the financial field, and the attribute value field includes: numbers and statistical units.
[0196] The numbers indicate the values. In one example, the data description information is fully extracted through a few shots and put into the name; the data value is as clear as possible and put into the value, and the value in the value is: 15%, or 1.3 million US dollars, etc., which only contains numbers and statistical units.
[0197] It can be seen that by configuring the attribute value field as numbers and statistical units, data information can be extracted reasonably and appropriately, and key information can be extracted and redundant information can be reduced.
[0198] S307: When the enhancement type includes translation enhancement, generate translation enhancement information of the target domain and add the translation enhancement information to the digital prompt information corresponding to the target domain.
[0199] The enhancement type of translation enhancement may refer to the need to limit the output format and output content of the language to be translated in the data analysis scenario. The translation enhancement information may refer to the information of the target language of the translation.
[0200] In an optional embodiment, the target field is the financial field, and the translation enhancement information includes: content that the format of numbers is a common format of the language and / or correct enhancement prompt content of ambiguous statistical units.
[0201] The language-general format may refer to a format that is common in multiple languages. For example, the language-general format of numbers may refer to Arabic numerals.
[0202] In one example, the target text is in English and the generated text summary is in Chinese. The numbers in the English text need to be converted into corresponding Arabic numerals instead of Chinese descriptions.
[0203] The correct reinforcement prompt content of the ambiguous statistical unit may refer to the content of the correct translation of the statistical unit that strengthens the translation ambiguity.
[0204] In one example, easily confused English units, such as billion, require the large language model to focus on whether the translation is correct, by adding the correct reinforcement prompt content of the ambiguous statistical unit in the digital prompt information: "**billion is one billion, which needs to be converted correctly**".
[0205] It can be seen that by limiting the direction of digital conversion in different languages, the accuracy of English parsing and the ability of expression can be improved, and by limiting the translation of ambiguous statistical units, the translation accuracy can be improved.
[0206] The existing large model with small number of parameters cannot reasonably express the data description information by adjusting the prompt, such as:
[0207] "name":"Year-on-year growth rate of users",
[0208] "value":"130%"
[0209] The related content failed to effectively extract the data expression of year-on-year growth rate. Another example:
[0210] "name":"Number of users",
[0211] "value":"Year-on-year growth rate of 130% in 2023 compared to 2022"
[0212] This method is inappropriate in terms of data description and data value extraction. The reasonable extraction method should be:
[0213] "name":"Year-on-year growth rate of the number of users in 2023",
[0214] "value":"130%"
[0215] By strengthening the comparison, the data representation of year-on-year growth can be effectively extracted.
[0216] Another problem with large model data extraction with a small number of parameters is the poor parsing accuracy and expression ability of English description data extraction. For example, the original text is: seventy six point five billion dollars. The large model related content is: seventy six and a half billion dollars. First of all, the data is parsed incorrectly. Billion should be in the order of one billion, not one billion. Secondly, a better expression is the Arabic numerals, so the reasonable generation mode should be: 67.5 billion dollars. By limiting the English number conversion direction, the English parsing accuracy and expression ability can be improved, and by limiting the translation of ambiguous English units to strengthen the sentence, the translation accuracy can be improved.
[0217] In some embodiments, the large language model outputs the extracted digital clustering summary content in JSON format as follows:
[0218] {"class":"User Data",
[0219] "data": [
[0220] {"name":"Year-on-year growth rate of practitioners' identity authentication",
[0221] "value":"130%"}
[0222] {"name":"Average monthly subscription numbers of paid members in the first quarter",
[0223] "value":"1480"}
[0224] {"name":"Year-on-year growth rate of paid members in the first quarter",
[0225] "value":"0.8%"}
[0226] {"name":"Q1 quarterly growth rate of paid members",
[0227] "value":"4.1%"}]}
[0228] {"class":"Financial data",
[0229] "data": [
[0230] {"name":"Marketing service revenue in the first quarter",
[0231] "value":"100 coins"}
[0232] {"name":"The year-on-year decrease in marketing service revenue in the first quarter",
[0233] "value":"15.78%"}
[0234] {"name":"Year-on-year growth rate of advertising revenue in the first quarter",
[0235] "value":"4%"}
[0236] {"name":"Q1 performance-based advertising business grew quarter-on-quarter",
[0237] "value":"Unknown"}
[0238] {"name":"First quarter paid membership income",
[0239] "value":"4.45 coins"}]}
[0240] According to the technical solution disclosed in the present invention, by configuring the enhancement type as comparison enhancement, output description enhancement and translation enhancement, the digital prompt information is enhanced in different enhancement scenarios respectively, so that the digital prompt information can be enhanced from multiple dimensions, and the digital prompt information can be adaptively enhanced for data comparison scenarios, output scenarios and translation scenarios of different languages. The data description and numerical value can be effectively extracted, and the representation of the data, language analysis, language expression and translation accuracy can be compared.
[0241] In one example, a schematic diagram of the generated text summary content is as follows Figure 4As shown in the figure, the left frame is the target text, which includes the role, speech time and content. The right frame includes the target domain outline content and the digital clustering summary content, where the target domain outline content includes multi-level directories, and the lowest level directory includes related content. The digital clustering summary content includes n classes obtained by aggregation, and each class includes a description field and a corresponding attribute value field.
[0242] According to an embodiment of the present disclosure, Figure 5 1 is a structural diagram of a target text processing device in an embodiment of the present disclosure, and the present disclosure embodiment is applicable to extracting key content from a target text. The device is implemented by software and / or hardware and is specifically configured in an electronic device with certain data computing capabilities.
[0243] like Figure 5 The target text processing device 500 shown in the figure comprises: a target text acquisition module 501, a prompt information determination module 502 and a text summary extraction module 503.
[0244] A target text acquisition module 501 is used to acquire the target text;
[0245] The prompt information determination module 502 is used to obtain target prompt information corresponding to the target field; the target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target field;
[0246] The text summary extraction module 503 is used to input the target prompt information corresponding to the target field and the target text into the large language model for processing, and output the text summary content. The target prompt information is used by the large language model to increase the attention of the strengthened constraint information to enhance the corresponding content in the text summary content.
[0247] According to the technical solution disclosed in the present invention, by generating target prompt information according to the reinforcement constraint information corresponding to the reinforcement type of the target field, the large language model increases its attention to the reinforcement constraint information, so that the large language model performs data enhancement on the text summary content, reduces auditory hallucinations and difficulty in understanding in the text summary content, reduces content in the text summary content that is irrelevant to the target field, increases content related to the target field in the text summary content, and improves the accuracy of the text summary content in the target field.
[0248] Optionally, the text summary extraction module includes at least one of the following:
[0249] An outline content generating unit, configured to input the outline prompt information corresponding to the target domain and the target text into a large language model for processing to generate the outline content of the target domain; and
[0250] The data content generating unit is used to input the digital prompt information corresponding to the target field and the target text into the large language model for processing to generate digital clustering summary content.
[0251] Optionally, the enhancement type includes: segmented processing;
[0252] The outline content generating unit comprises:
[0253] A multi-level directory generating subunit, used for generating a multi-level directory according to the first prompt information and the target text;
[0254] A directory task division subunit, used to divide the tasks of the multi-level directories to generate at least one directory information extraction task;
[0255] A directory content extraction subunit, for generating, for each directory information extraction task, related content corresponding to the directory of the directory information extraction task according to the directory information extraction task, the second prompt information and the target text;
[0256] The directory outline generation subunit is used to generate target domain outline content according to the associated content corresponding to the directory of each directory information extraction task.
[0257] Optionally, the directory task division subunit is specifically used to:
[0258] In the multi-level directory, obtain multiple high-level directories;
[0259] Divide each of the high-level directories into at least one task, where the upper limit of the number of divided tasks is a specified number;
[0260] For each of the high-level directories, the low-level directories associated with the high-level directory are divided into the tasks divided by the high-level directory, and at least one directory information extraction task is generated.
[0261] Optionally, the directory task division subunit is specifically used to:
[0262] Obtaining the directory order between the high-level directories;
[0263] According to the order of each of the directories, each of the high-level directories is divided into at least one task, and the upper limit of the number of divided tasks is a specified number, wherein the number of directories included in the task of the high-level directory with an earlier directory order is less than the number of directories included in the task of the high-level directory with a later directory order.
[0264] Optionally, the multi-level directory includes: a first-level directory and a second-level directory.
[0265] Optionally, the enhancement types include: role enhancement processing;
[0266] The device further comprises: an outline prompt information generating module, wherein the outline prompt information generating module is used to:
[0267] Obtaining general prompt information corresponding to the target field;
[0268] Obtaining enhanced prompt information corresponding to the target area;
[0269] Generate outline prompt information corresponding to the target field according to the general prompt information and the enhanced prompt information.
[0270] Optionally, the outline prompt information generating module is used to:
[0271] Obtaining an extended field corresponding to the target field;
[0272] Generate general prompt information corresponding to the target domain according to the description information of the target domain and the description information of the extended domain.
[0273] Optionally, the outline prompt information generating module is used to:
[0274] The outline structure information, key subject information and output text length of the target domain are obtained, and enhanced prompt information corresponding to the target domain is generated; wherein the outline structure information includes a level identifier, a level depth and a level structure.
[0275] Optionally, the target text processing device further includes: a digital prompt information generating module, the digital prompt information generating module is used to:
[0276] When the enhancement type includes contrast enhancement, generating contrast subject enhancement extraction information of the target area and adding it to digital prompt information corresponding to the target area;
[0277] When the enhancement type includes output description enhancement, generating output description information of the target field and adding it to the digital prompt information corresponding to the target field, wherein the output description information includes a description field and an attribute value field;
[0278] When the enhancement type includes translation enhancement, translation enhancement information of the target domain is generated and added to the digital prompt information corresponding to the target domain.
[0279] Optionally, the target field is the financial field, and the attribute value field includes: numbers and statistical units.
[0280] Optionally, the target field is the financial field, and the translation enhancement information includes: content that the format of numbers is a common format of the language and / or correct enhancement prompt content of ambiguous statistical units.
[0281] Optionally, the target text processing device further includes:
[0282] A positioning time acquisition module is used to obtain the positioning time corresponding to each sentence in the target text after generating the target domain outline content according to the associated content corresponding to the directory of each directory information extraction task;
[0283] The directory time positioning module is used to determine the positioning time corresponding to each directory according to the positioning time corresponding to each sentence in the target text and the associated content corresponding to each directory.
[0284] Optionally, the directory time positioning module includes:
[0285] A statement range determination unit, configured to obtain a statement range corresponding to at least one associated content according to the associated content corresponding to each of the directories;
[0286] A hit probability determination unit, configured to calculate, for each of the associated contents, within a sentence range of the associated contents, a hit probability of the associated contents for each candidate sentence within the sentence range of the associated contents;
[0287] A hit statement screening unit, used for screening out a target statement according to the hit probability of each candidate statement;
[0288] A positioning time query unit, used for querying the positioning time corresponding to the target sentence according to the positioning time corresponding to each sentence in the target text;
[0289] The positioning time determining unit is used to determine the positioning time of the associated content according to the positioning time of the target sentence.
[0290] Optionally, the hit probability determination unit includes:
[0291] The association probability calculation subunit is used to calculate the hit probability of each candidate sentence in the sentence range of the associated content and the higher-level directory to which the associated content belongs within the sentence range of the associated content.
[0292] Optionally, the alternative sentences include: a single sentence and consecutive double sentences.
[0293] The above-mentioned target text processing device can execute the target text processing method provided by any embodiment of the present disclosure, and has corresponding functional modules and beneficial effects for executing the target text processing method.
[0294] In the technical solution of the present disclosure, the collection, storage, use, processing, transmission, provision and disclosure of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0295] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium and a computer program product.
[0296] Figure 6 A schematic area diagram of an example electronic device 600 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0297] like Figure 6 As shown, the device 600 includes a computing unit 601, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the device 600 instructions can also be stored. The computing unit 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0298] A number of components in the device 600 are connected to the I / O interface 605, including: an input unit 606, such as a keyboard, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a disk, an optical disk, etc.; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 609 allows the device 600 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0299] The computing unit 601 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 601 performs the various methods and processes described above, such as the target text processing method. For example, in some embodiments, the target text processing method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 608. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 600 via the ROM 602 and / or the communication unit 609. When the computer program is loaded into the RAM 603 and executed by the computing unit 601, one or more steps of the target text processing method described above may be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to perform the target text processing method in any other appropriate manner (e.g., by means of firmware).
[0300] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard objects (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0301] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, implements the functions / instructions specified in the flow chart and / or the area diagram. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0302] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0303] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0304] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0305] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship between the client and the server is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services. The server may also be a server of a distributed system, or a server combined with a blockchain.
[0306] Artificial intelligence is a discipline that studies how to use computers to simulate certain human thought processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.). It includes both hardware-level and software-level technologies. Artificial intelligence hardware technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, and big data processing; artificial intelligence software technologies mainly include computer vision technology, speech recognition technology, natural language processing technology, machine learning / deep learning technology, big data processing technology, knowledge graph technology, and other major directions.
[0307] Cloud computing refers to a technology system that uses network access to elastically scalable shared physical or virtual resource pools. Resources can include servers, instruction systems, networks, software, applications, and storage devices, and can be deployed and managed on demand and in a self-service manner. Cloud computing technology can provide efficient and powerful data processing capabilities for the application of technologies such as artificial intelligence and blockchain, as well as model training.
[0308] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution provided by this disclosure can be achieved, and this document does not limit this.
[0309] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. A target text processing method, comprising: Get the target text; Obtain target prompt information corresponding to the target field; The target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target field; The target prompt information corresponding to the target field and the target text are input into the large language model for processing, and a text summary content is output. The target prompt information is used by the large language model to increase attention to the strengthened constraint information to enhance the corresponding content in the text summary content.
2. The method according to claim 1, wherein: The step of inputting the target prompt information corresponding to the target field and the target text into a large language model for processing and outputting text summary content includes at least one of the following: Inputting the outline prompt information corresponding to the target domain and the target text into the large language model for processing to generate the outline content of the target domain; as well as The digital prompt information corresponding to the target field and the target text are input into a large language model for processing to generate digital clustering summary content.
3. The method according to claim 2, wherein: The types of enhancement include: segmented processing; The step of inputting the outline prompt information corresponding to the target domain and the target text into a large language model for processing to generate the outline content of the target domain includes: Generate a multi-level directory according to the first prompt information and the target text; Dividing the multi-level directories into tasks to generate at least one directory information extraction task; For each of the directory information extraction tasks, generating associated content corresponding to the directory of the directory information extraction task according to the directory information extraction task, the second prompt information and the target text; Generate target domain outline content based on the associated content corresponding to the directory of each directory information extraction task.
4. The method according to claim 3, wherein: The step of dividing the multi-level directories into tasks to generate at least one directory information extraction task includes: In the multi-level directory, obtain multiple high-level directories; Divide each of the high-level directories into at least one task, where the upper limit of the number of divided tasks is a specified number; For each of the high-level directories, the low-level directories associated with the high-level directory are divided into the tasks divided by the high-level directory, and at least one directory information extraction task is generated.
5. The method according to claim 4, wherein: The dividing each of the high-level directories into at least one task includes: Obtaining the directory order between the high-level directories; According to the order of each of the directories, each of the high-level directories is divided into at least one task, wherein the number of directories included in the task of the high-level directory with an earlier directory order is smaller than the number of directories included in the task of the high-level directory with a later directory order.
6. The method according to claim 3 or 4, wherein: The multi-level directory includes: a first-level directory and a second-level directory.
7. The method according to claim 2, wherein: The enhancement types include: role enhancement processing; the outline prompt information corresponding to the target field is generated in the following way: Obtaining general prompt information corresponding to the target field; Obtaining enhanced prompt information corresponding to the target area; Generate outline prompt information corresponding to the target field according to the general prompt information and the enhanced prompt information.
8. The method according to claim 7, wherein: The obtaining of general prompt information corresponding to the target field includes: Obtaining an extended field corresponding to the target field; Generate general prompt information corresponding to the target domain according to the description information of the target domain and the description information of the extended domain.
9. The method according to claim 7, wherein: The obtaining of enhanced prompt information corresponding to the target field includes: The outline structure information, key subject information and output text length of the target domain are obtained, and enhanced prompt information corresponding to the target domain is generated; wherein the outline structure information includes a level identifier, a level depth and a level structure.
10. The method according to claim 2, wherein: The digital prompt information corresponding to the target field is generated in the following way: When the enhancement type includes contrast enhancement, generating contrast subject enhancement extraction information of the target area and adding it to digital prompt information corresponding to the target area; When the enhancement type includes output description enhancement, generating output description information of the target field and adding it to the digital prompt information corresponding to the target field, wherein the output description information includes a description field and an attribute value field; When the enhancement type includes translation enhancement, translation enhancement information of the target domain is generated and added to the digital prompt information corresponding to the target domain.
11. The method according to claim 10, wherein: The target field is the financial field, and the attribute value field includes: numbers and statistical units.
12. The method according to claim 10, wherein: The target domain is the financial domain, and the translation enhancement information includes: content that the format of numbers is a common format of the language and / or correct enhancement prompt content of ambiguous statistical units.
13. The method according to claim 3, after generating target domain outline content according to the associated content corresponding to the directory of each directory information extraction task, further comprises: Obtaining the location time corresponding to each sentence in the target text; The positioning time corresponding to each associated content is determined according to the positioning time corresponding to each sentence in the target text and the associated content corresponding to each directory.
14. The method according to claim 13, wherein: Determining the location time corresponding to each associated content according to the location time corresponding to each sentence in the target text and the associated content corresponding to each directory includes: According to the associated contents corresponding to the directories, obtaining a statement range corresponding to at least one associated content; For each of the related contents, within the sentence range of the related content, calculating the hit probability of the related content for each candidate sentence within the sentence range of the related content; Filtering out a target sentence according to the hit probability of each of the candidate sentences; According to the positioning time corresponding to each sentence in the target text, query the positioning time corresponding to the target sentence; The location time of the associated content is determined according to the location time of the target sentence.
15. The method according to claim 14, wherein: The calculating, within the sentence range of the associated content, the hit probability of the associated content for each candidate sentence within the sentence range of the associated content comprises: Within the sentence range of the associated content, the hit probabilities of the associated content and the higher-level directory to which the associated content belongs for each candidate sentence within the sentence range of the associated content are calculated.
16. The method according to claim 14 or 15, wherein: The alternative sentences include: a single sentence and a continuous double sentence.
17. A target text processing device, comprising: A target text acquisition module is used to acquire the target text; A prompt information determination module is used to obtain target prompt information corresponding to the target field; The target prompt information is generated according to the reinforcement constraint information corresponding to the reinforcement type in the target field; The text summary extraction module is used to input the target prompt information corresponding to the target field and the target text into the large language model for processing, and output the text summary content. The target prompt information is used by the large language model to increase the attention of the strengthened constraint information to enhance the corresponding content in the text summary content.
18. The device according to claim 17, wherein: The text summary extraction module includes at least one of the following: An outline content generating unit, configured to input the outline prompt information corresponding to the target domain and the target text into a large language model for processing, so as to generate the outline content of the target domain; as well as The data content generating unit is used to input the digital prompt information corresponding to the target field and the target text into the large language model for processing to generate digital clustering summary content.
19. The device according to claim 18, wherein: The types of enhancement include: segmented processing; The outline content generating unit comprises: A multi-level directory generating subunit, used for generating a multi-level directory according to the first prompt information and the target text; A directory task division subunit, used to divide the tasks of the multi-level directories to generate at least one directory information extraction task; A directory content extraction subunit, for generating, for each directory information extraction task, related content corresponding to the directory of the directory information extraction task according to the directory information extraction task, the second prompt information and the target text; The directory outline generation subunit is used to generate target domain outline content according to the associated content corresponding to the directory of each directory information extraction task.
20. The device according to claim 19, wherein The directory task division subunit is specifically used for: In the multi-level directory, obtain multiple high-level directories; Divide each of the high-level directories into at least one task, where the upper limit of the number of divided tasks is a specified number; For each of the high-level directories, the low-level directories associated with the high-level directory are divided into the tasks divided by the high-level directory, and at least one directory information extraction task is generated.
21. The device according to claim 20, wherein: The directory task division subunit is specifically used for: Obtaining the directory order between the high-level directories; According to the order of each of the directories, each of the high-level directories is divided into at least one task, wherein the number of directories included in the task of the high-level directory with an earlier directory order is smaller than the number of directories included in the task of the high-level directory with a later directory order.
22. The device according to claim 19 or 20, wherein: The multi-level directory includes: a first-level directory and a second-level directory.
23. The device according to claim 18, wherein The types of enhancement include: role enhancement processing; The device further comprises: an outline prompt information generating module, wherein the outline prompt information generating module is used to: Obtaining general prompt information corresponding to the target field; Obtaining enhanced prompt information corresponding to the target area; Generate outline prompt information corresponding to the target field according to the general prompt information and the enhanced prompt information.
24. The device according to claim 23, wherein: The outline prompt information generating module is used to: Obtaining an extended field corresponding to the target field; Generate general prompt information corresponding to the target domain according to the description information of the target domain and the description information of the extended domain.
25. The device according to claim 23, wherein: The outline prompt information generating module is used to: The outline structure information, key subject information and output text length of the target domain are obtained, and enhanced prompt information corresponding to the target domain is generated; wherein the outline structure information includes a level identifier, a level depth and a level structure.
26. The apparatus of claim 18, further comprising: A digital prompt information generation module, wherein the digital prompt information generation module is used to: When the enhancement type includes contrast enhancement, generating contrast subject enhancement extraction information of the target area and adding it to digital prompt information corresponding to the target area; When the enhancement type includes output description enhancement, generating output description information of the target field and adding it to the digital prompt information corresponding to the target field, wherein the output description information includes a description field and an attribute value field; When the enhancement type includes translation enhancement, translation enhancement information of the target domain is generated and added to the digital prompt information corresponding to the target domain.
27. The device according to claim 26, wherein: The target field is the financial field, and the attribute value field includes: numbers and statistical units.
28. The device according to claim 26, wherein The target domain is the financial domain, and the translation enhancement information includes: content that the format of numbers is a common format of the language and / or correct enhancement prompt content of ambiguous statistical units.
29. The apparatus of claim 19, further comprising: A positioning time acquisition module is used to obtain the positioning time corresponding to each sentence in the target text after generating the target domain outline content according to the associated content corresponding to the directory of each directory information extraction task; The directory time positioning module is used to determine the positioning time corresponding to each associated content according to the positioning time corresponding to each sentence in the target text and the associated content corresponding to each directory.
30. The device according to claim 29, wherein: The directory time positioning module includes: A statement range determination unit, configured to obtain a statement range corresponding to at least one associated content according to the associated content corresponding to each of the directories; A hit probability determination unit, configured to calculate, for each of the associated contents, within a sentence range of the associated contents, a hit probability of the associated contents for each candidate sentence within the sentence range of the associated contents; A hit statement screening unit, used for screening out a target statement according to the hit probability of each candidate statement; A positioning time query unit, used for querying the positioning time corresponding to the target sentence according to the positioning time corresponding to each sentence in the target text; The positioning time determining unit is used to determine the positioning time of the associated content according to the positioning time of the target sentence.
31. The device according to claim 30, wherein The hit probability determination unit includes: The association probability calculation subunit is used to calculate the hit probability of each candidate sentence in the sentence range of the associated content and the higher-level directory to which the associated content belongs within the sentence range of the associated content.
32. The device according to claim 30 or 31, wherein: The alternative sentences include: a single sentence and a continuous double sentence.
33. An electronic device comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute any target text processing method according to claims 1-16.
34. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to enable the computer to execute the target text processing method according to any one of claims 1-16.
35. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the target text processing method according to any one of claims 1 to 16.
Citation Information
Patent Citations
Audio and video data processing method and device, equipment and storage medium
CN112860939A
Voice control method and device, electronic equipment and readable storage medium
CN116705018A
Abstract generation method and device, equipment, storage medium and product
CN116894089A
Conversation content summarization method and device, computer equipment and storage medium
CN118332100A
Article generation method and device, equipment and storage medium
CN118550997A