English discourse generation method and device, model training method and device, equipment and medium

Through the adjustment of discourse generation model and user feedback-driven adjustment, the problem of time-consuming and labor-intensive acquisition of English discourse is solved, and fast and accurate discourse generation is achieved to meet teachers' teaching needs.

CN120337866APending Publication Date: 2025-07-18IFLYTEK CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510189102.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-20
Publication Date
2025-07-18

AI Technical Summary

Technical Problem

The acquisition of English discourse in the prior art is labor-intensive and difficult to fully meet the teachers' expected needs. The traditional search method is time-consuming and has poor results.

Method used

By determining the discourse generation description text, applying the discourse generation model to generate English discourse, obtaining the initial English discourse, and adjusting the description text based on user feedback to generate target English discourse, including sentence transformation, tense change, vocabulary replacement and other adjustments.

Benefits of technology

It realizes fast, accurate and effective English discourse generation, and can be adjusted according to user needs and feedback to ensure that the generated discourse better meets teaching needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120337866A_ABST
    Figure CN120337866A_ABST
Patent Text Reader

Abstract

The invention provides an English discourse generation method and device, a model training method and device, equipment and a medium, and the method comprises the steps: generating a description text based on a discourse of a user, carrying out the English discourse generation through a discourse generation model, and obtaining an initial English discourse; the discourse adjustment description text fed back by the user aiming at the initial English discourse is obtained, the English discourse is adjusted by applying the discourse generation model based on the discourse adjustment description text, and the target English discourse corresponding to the discourse generation requirement is obtained. According to the method and the device, the defects of difficulty in accurately obtaining the discourse meeting the user demand and difficulty in accurately obtaining the discourse meeting the user demand are overcome, the discourse can be generated according to the user demand, and the discourse can be adjusted according to the adjustment intention fed back by the user, so that the finally obtained target English discourse can better meet the discourse generation demand of the user, and rapid, accurate and effective discourse generation is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and particularly to an English discourse generation method, a model training method, a device, a device and a medium. Background Art

[0002] In current English education, especially under the guidance of the new curriculum standards in recent years, discourse, as the basic unit of English learning, has become increasingly prominent in importance. The new curriculum standards emphasize that by optimizing the presentation of curriculum content, using discourse to help students understand the development and changes of events, identify the relevance between information, so as to grasp the overall meaning of the discourse, and further promote the all-round development of students. However, in the actual teaching process, it is not easy to obtain discourse, especially the acquisition of discourse that meets specific requirements is still a major problem in the field of English teaching.

[0003] Currently, teachers mainly obtain discourse through retrieval, but this method has many limitations. First, the discourse retrieval process based on multi-keyword constraints often takes teachers a lot of time and effort, mainly because it takes a lot of time to compare and screen each retrieved discourse to see if it meets the requirements; further, even if relatively close discourse is obtained through a large amount of screening and comparison, it often still needs to be modified and adjusted to make it closer to the teacher's needs and more suitable for English teaching, and the process of manual modification and adjustment is also time-consuming and laborious, and it is also very difficult to actually modify it to fully meet the teacher's expectations. Summary of the Invention

[0004] The present invention provides an English discourse generation method, a model training method, a device, a device and a medium, which are used to solve the defect that it is time-consuming and laborious to obtain English discourse in the prior art and it is difficult to fully meet the expectations / appeals of teachers, and to achieve fast, accurate and effective English discourse generation.

[0005] The present invention provides an English discourse generation method, including: Determine a discourse generation description text, which is used to describe the user's discourse generation requirements; Based on the discourse generation description text, apply a discourse generation model to generate an initial English discourse; Obtain a discourse adjustment description text feedback by the user for the initial English discourse, and based on the discourse adjustment description text, apply the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements.

[0006] According to an English discourse generation method provided by the present invention, the step of applying the discourse generation model to adjust the English discourse based on the discourse adjustment description text to obtain the target English discourse corresponding to the discourse generation requirements includes: Determine the discourse adjustment type corresponding to the discourse adjustment description text, and the discourse content to be adjusted in the initial English discourse; Based on the discourse adjustment type, the discourse content to be adjusted, and the discourse adjustment description text, determine the discourse adjustment prompt text; Based on the discourse adjustment prompt text, apply the discourse generation model to perform English discourse adjustment to obtain the target English discourse corresponding to the discourse generation requirement.

[0007] According to an English discourse generation method provided by the present invention, the determining the discourse adjustment prompt text based on the discourse adjustment type, the discourse content to be adjusted, and the discourse adjustment description text includes: Perform text intention recognition based on the discourse adjustment description text to obtain the user's discourse adjustment intention; Based on the discourse adjustment intention, the discourse adjustment type, and the discourse content to be adjusted, determine the discourse adjustment prompt text.

[0008] According to an English discourse generation method provided by the present invention, the applying the discourse generation model to perform English discourse adjustment based on the discourse adjustment prompt text to obtain the target English discourse corresponding to the discourse generation requirement includes: Based on the discourse adjustment prompt text, apply the discourse generation model to perform English discourse adjustment to obtain the adjusted content corresponding to the discourse content to be adjusted; Based on the adjusted content and the initial English discourse, determine the target English discourse corresponding to the discourse generation requirement.

[0009] According to an English discourse generation method provided by the present invention, the discourse adjustment type includes at least one of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging.

[0010] According to an English discourse generation method provided by the present invention, the applying the discourse generation model to perform English discourse generation based on the discourse generation description text to obtain the initial English discourse includes: Perform text intention recognition based on the discourse generation description text to obtain the user's discourse generation intention; Based on the discourse generation intention, determine the discourse generation prompt text; Based on the discourse generation prompt text, apply the discourse generation model to perform English discourse generation to obtain the initial English discourse.

[0011] The present invention also provides a training method for a discourse generation model, including: Obtain a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; Based on each of the sample discourse description texts and their corresponding sample English discourses, determine the discourse scores of each sample English discourse; Based on the discourse scores, determine high-quality sample English discourses from each of the sample English discourses, and based on the high-quality sample English discourses and their corresponding sample discourse description texts, train an initial discourse model to obtain a discourse generation model; Among them, the initial discourse model is constructed based on a large language model.

[0012] According to a training method of a discourse generation model provided by the present invention, each sample discourse description text in the sample data set corresponds to at least one knowledge point under a knowledge point hierarchy relationship, and each knowledge point corresponds to one of the topic requirements in the discourse generation requirement, and the knowledge point hierarchy relationship represents the upper and lower hierarchical relationships between each knowledge point in a tree structure.

[0013] The present invention also provides an English discourse generation device, including: A text determination unit, configured to determine a discourse generation description text, where the discourse generation description text is used to describe the user's discourse generation requirement; A discourse generation unit, configured to generate an initial English discourse by applying a discourse generation model based on the discourse generation description text; A discourse adjustment unit, configured to obtain a discourse adjustment description text fed back by the user for the initial English discourse, and based on the discourse adjustment description text, apply the discourse generation model to adjust the English discourse to obtain a target English discourse corresponding to the discourse generation requirement.

[0014] The present invention also provides a training device for a discourse generation model, including: An acquisition unit, configured to acquire a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; A scoring unit, configured to determine the discourse scores of each sample English discourse based on each of the sample discourse description texts and their corresponding sample English discourses; A training unit, configured to determine high-quality sample English discourses from each of the sample English discourses based on the discourse scores, and based on the high-quality sample English discourses and their corresponding sample discourse description texts, train an initial discourse model to obtain a discourse generation model; Among them, the initial discourse model is constructed based on a large language model.

[0015] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored on the memory and running on the processor. When the processor executes the computer program, the method for generating an English discourse or the method for training a discourse generation model as described in any one of the above is implemented.

[0016] The present invention also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method for generating an English discourse or the method for training a discourse generation model as described in any one of the above is implemented.

[0017] The English discourse generation method, model training method, device, equipment, and medium provided by the present invention generate a description text based on the user's discourse, apply the discourse generation model to generate an English discourse, and obtain an initial English discourse; based on the discourse adjustment description text fed back by the user for the initial English discourse, apply the discourse generation model to adjust the English discourse, and obtain the target English discourse corresponding to the discourse generation requirement, realizing automated English discourse generation. It overcomes the defects that in the traditional solution, obtaining a discourse through a retrieval method is not only laborious and time-consuming, but also difficult to accurately obtain a discourse that meets the user's needs. It can not only generate a discourse according to the user's needs, but also adjust the discourse according to the adjustment intention fed back by the user, so that the finally obtained target English discourse can better meet the user's discourse generation requirement, realizing fast, accurate, and effective discourse generation. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0019] Figure 1 is a schematic flowchart of the English discourse generation method provided by the present invention; Figure 2 is an overall flowchart of the English discourse generation method provided by the present invention; Figure 3 is a schematic flowchart of the method for training a discourse generation model provided by the present invention; Figure 4 is a schematic structural diagram of the English discourse generation device provided by the present invention; Figure 5 is a schematic structural diagram of the device for training a discourse generation model provided by the present invention; Figure 6 is a schematic structural diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0020] To make the objectives, technical solutions and advantages of the present invention clearer, the technical solutions in the present invention will be clearly and completely described below with reference to the accompanying drawings in the present invention. Apparently, the described embodiments are some but not all of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present invention without creative efforts shall fall within the protection scope of the present invention.

[0021] Currently, most teachers obtain discourse by retrieval. For example, when retrieving discourse, keywords are usually given, such as "give me a discourse about 150 words expressing the relationship between humans and nature, which must not exceed the junior high school level, use imperative sentences, and use the word 'popular'". Retrieval is carried out based on this. However, under the constraints of multiple keywords, it is difficult to retrieve a discourse that meets the requirements, and the process of retrieval and screening comparison also requires a lot of time and effort. Further, even if a relatively close discourse is obtained through a large amount of retrieval and comparison, it often needs to be further modified and adjusted, and the process of manual modification requires a lot of time and effort and it is difficult to achieve a relatively excellent effect.

[0022] In view of this, the present invention provides an English discourse generation method, aiming to quickly and accurately generate a corresponding English text according to the user's discourse requirements, and can adjust the generated English discourse according to the user's further feedback to make it more in line with the user's needs, so as to obtain the final target English discourse.

[0023] Figure 1 is a schematic flowchart of the English discourse generation method provided by the present invention. As Figure 1 shown, the method includes: Step 110, determining a discourse generation description text, which is used to describe the user's discourse generation requirements; Step 120, based on the discourse generation description text, applying a discourse generation model to generate an initial English discourse; Step 130, obtaining a discourse adjustment description text feedback by the user for the initial English discourse, and based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain a target English discourse corresponding to the discourse generation requirements.

[0024] Specifically, considering that it is difficult for the current retrieval-based discourse acquisition to fully meet the constraints of multiple keywords. For example, when the user's discourse requirements are complex, diverse and relatively detailed, it is very difficult to obtain a discourse that is very close and in line with the user's discourse requirements based on retrieval. Even if a relatively close discourse is obtained with difficulty, a lot of time is required for later modification and adjustment, and the process of manual modification is time-consuming and laborious and the effect is limited.

[0025] In view of this, the present invention proposes an automated discourse generation method, which automatically generates English discourse according to the discourse demands of users, and can adjust the generated English discourse according to the discourse adjustment needs fed back by users when there are inappropriate parts (such as inappropriate words, incoherent context, etc.) or questions in the generated English discourse, so as to better meet the discourse demands of users, and finally obtain English discourse that meets the discourse generation needs of users.

[0026] It is understandable that in actual application, before generating English text, the first thing that needs to be determined is the user's text appeal, that is, the user's text generation demand, which can be presented in the form of text. Specifically, it can be to obtain the user's text generation description text, which describes the user's text generation demand, and the text generation demand can be the user's requirement for a certain aspect of the text to be generated, such as the text length requirement or vocabulary requirement, and can also include multiple requirements, such as the text theme requirement, style requirement, vocabulary requirement, grammar requirement, etc., which is not specifically limited in the embodiment of the present invention.

[0027] In the actual teaching process, in order to better teach English, users (teachers) can determine the text generation requirements based on their own lesson preparation, such as the reading materials, listening materials, writing materials, question materials, etc., as well as the content to be taught and the knowledge points to be tested. The text generation requirements can include any one or more of the requirements of the learning stage, theme, style, length, grammar, and vocabulary; and it must be ensured that there is no conflict or contradiction between these requirements.

[0028] After determining the text for discourse generation description, in the embodiment of the present invention, discourse generation can be performed based on this to obtain the required English discourse. However, considering the difficulty of accurate matching, time-consuming and labor-intensive, and poor results in current discourse acquisition, as well as the current popularity and excellent capabilities of large language models (referred to as large models), in the embodiment of the present invention, English discourse acquisition is performed with the help of this, so as to understand the user's discourse generation description text through the large model's excellent understanding and interaction capabilities, as well as its powerful learning, calculation and thinking capabilities, and perform English discourse generation on this basis, thereby obtaining an English discourse that preliminarily meets the user's discourse generation needs, which is referred to as the initial English discourse.

[0029] Specifically, here it can be to first build a model for English discourse generation through a large model, that is, a discourse generation model. Here, specifically, it can be directly using the large model as the discourse generation model; it can also be to first build an initial model for English discourse generation based on the large model, and then fine-tune and train the initial model through instance data, such as actual discourse generation requirements and corresponding English discourses, to obtain the discourse generation model; it can also be to build other networks, algorithms, etc. on the basis of the large model to build the discourse generation model, and the embodiments of the present invention do not make specific limitations on this.

[0030] Here, the large model is a large language model (LLM) deployed in a terminal device / smart device (chatbot) with human-like characteristics or independently deployed from the terminal, for example, the Spark Cognition large model. The large model can understand and learn human language to communicate with users; and it can also interact with users according to the context of the conversation, with real human-like communication and writing abilities. In addition, it also has other human-like abilities, such as code ability, medical ability, literature ability, answering questions ability, navigation ability, shopping ability, etc.

[0031] After determining the discourse generation model, in the embodiments of the present invention, this discourse generation model can be applied to generate English discourses to obtain initial English discourses. Here, specifically, it can be to input the discourse generation description text into the discourse generation model, so that the discourse generation model can generate English discourses according to the information in the input text to generate an English discourse corresponding to the user's discourse generation requirements, that is, the initial English discourse. In this way, automated English discourse generation is realized, and it can be ensured that the initially generated English discourse basically conforms to the user's discourse requirements, providing a data basis for the generation of the ultimately accurately matched English discourse and solving the problem of difficult and time-consuming discourse acquisition currently.

[0032] After that, considering that the initially generated English discourse may not fully meet the user's discourse requirements, such as possible knowledge hallucination problems, keyword omissions, etc., resulting in the result of a single generation not being guaranteed to fully meet the user's needs, it usually needs to be further adjusted. Therefore, in order to make the generated English discourse accurately match the user's discourse generation requirements, in the embodiments of the present invention, the initial English discourse can also be adjusted to make it fully meet the user's discourse requirements, so as to obtain the final English discourse, that is, the target English discourse.

[0033] Specifically, after generating the initial English discourse, it can be first presented. For example, the generated initial English discourse can be displayed on a display screen, or played through a player, or returned to the user terminal that sent the discourse generation description text, so that the user can timely learn the initial English discourse generated by the model, thereby confirming whether the generated initial English discourse meets the expectations, whether there are any improprieties, or whether there are any doubts, etc.

[0034] Furthermore, when it is confirmed that there are inconsistencies with the requirements, or there are other improprieties, or there are doubts in the initial English discourse, the user can give targeted feedback to indicate the improprieties or express doubts, and elaborate on the requirements for modification and adjustment. That is, at this time, the adjustment information feedback by the user for the initial English discourse can be obtained, that is, the discourse adjustment description text. The discourse adjustment description text can include the content that needs to be adjusted in the initial English discourse by the user, as well as the specific requirements for adjustment, such as the adjustment type, intention, etc.

[0035] Immediately afterwards, the generated initial English discourse can be adjusted according to the obtained discourse adjustment description text to obtain the target English discourse. Here, specifically, based on the discourse adjustment description text, with the help of the discourse generation model, the initial English discourse can be modified and adjusted to make it more in line with the user's needs, so as to obtain an English discourse that accurately matches the user's discourse generation requirements, that is, the target English discourse and output it.

[0036] Specifically, here, the discourse adjustment description text can be input into the discourse generation model, so that the discourse generation model can adjust the initial English discourse according to the requirements in the discourse adjustment description text, obtain the target English discourse and output it. In this way, an English discourse that accurately matches the user's discourse generation requirements is obtained, realizing accurate and reliable English discourse generation, and avoiding the problems of great difficulty in accurately matching the discourse and being difficult to obtain.

[0037] In the embodiments of the present invention, based on the discourse generation model for English discourse generation and adjustment, corresponding English discourses can be generated according to multiple keywords input by the user, such as grade difficulty, discourse theme, style type, word count, grammar knowledge points to be covered, key vocabulary to be included, etc., and can be targeted for modification according to the user's feedback for the dissatisfied parts to obtain an accurate target English discourse. The user (teacher) can copy this target English discourse with one key or directly export the document to be used as teaching materials for various lesson types such as reading, grammar, and writing.

[0038] In addition, it should be noted that the method provided by the present invention can not only be applied to English discourse generation to assist teachers in English teaching, but also be applied to other languages such as Chinese, Korean, French, etc., and can also assist in teaching other languages.

[0039] The English discourse generation method provided by the present invention generates an initial English discourse based on the user's discourse generation description text by applying a discourse generation model; based on the discourse adjustment description text fed back by the user for the initial English discourse, it applies the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirement, realizing automated English discourse generation, overcoming the defects in the traditional solution that obtaining discourse through retrieval is not only time-consuming and laborious, but also difficult to accurately obtain a discourse that meets the user's needs. It can not only generate a discourse according to the user's needs, but also adjust the discourse according to the adjustment intention fed back by the user, so that the finally obtained target English discourse can better fit the user's discourse generation requirement, realizing fast, accurate and effective discourse generation.

[0040] Based on the above embodiment, in step 130, based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirement includes: Determine the discourse adjustment type corresponding to the discourse adjustment description text and the discourse content to be adjusted in the initial English discourse; Based on the discourse adjustment type, the to-be-adjusted discourse content, and the discourse adjustment description text, determine the discourse adjustment prompt text; Based on the discourse adjustment prompt text, apply the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirement.

[0041] Among them, the discourse adjustment type includes at least one of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging.

[0042] Specifically, the process of applying the discourse generation model to adjust the English discourse according to the discourse adjustment description text to obtain the target English discourse corresponding to the discourse generation requirement specifically includes the following steps: After obtaining the user's discourse adjustment description text, first, the adjustment type involved by the user in English discourse adjustment, that is, the discourse adjustment type, can be determined according to this; at the same time, the specific content that needs to be adjusted in the initial English discourse, that is, the to-be-adjusted discourse content, can also be determined. Here, specifically, according to the discourse adjustment description text fed back by the user, the to-be-adjusted discourse content in the initial English discourse and the specific discourse adjustment type can be determined. The discourse adjustment type here can include any one or more of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging (sentence splitting and sentence merging).

[0043] After determining the discourse content to be adjusted and the type of discourse adjustment, in the embodiments of the present invention, English discourse adjustment can be performed accordingly to obtain the target English discourse. However, considering that the model has learned a large number of sample English discourses and language norms during training, it has relatively strict requirements for the input information and needs to conform to the language forms, norms, etc. that it can receive and understand, so that the model can understand and correspondingly output the English discourse. Based on this, before applying the discourse generation model to perform English discourse adjustment, the information input into the model also needs to be converted into a form that the model can understand, that is, normalized, to be refined into structured information, so as to obtain the text for prompting the model to perform English discourse adjustment, that is, the discourse adjustment prompt text.

[0044] Specifically, at this time, the discourse generation description text, the type of discourse adjustment, and the discourse content to be adjusted can be processed to refine the above information into structured statements, so as to obtain the text for prompting the model to perform English discourse adjustment, that is, the discourse adjustment prompt text. The discourse adjustment prompt text here is essentially a kind of data carrying the above information. For example, it can be a prompt, which is data that the model can receive and understand. After inputting it into the model, the model can automatically perform English discourse adjustment according to the input information and output the adjusted English discourse, and finally obtain the target English discourse corresponding to the user's discourse generation requirements.

[0045] After that, this prompt text can be input into the discourse generation model, so that the discourse generation model automatically adjusts the discourse content to be adjusted in the initial English discourse according to the input information according to the type of discourse adjustment and outputs the adjusted target English discourse.

[0046] Based on the above embodiments, determining the discourse adjustment prompt text based on the type of discourse adjustment, the discourse content to be adjusted, and the discourse adjustment description text includes: Performing text intention recognition based on the discourse adjustment description text to obtain the user's discourse adjustment intention; Determining the discourse adjustment prompt text based on the discourse adjustment intention, the type of discourse adjustment, and the discourse content to be adjusted.

[0047] Specifically, the process of determining the discourse adjustment prompt text according to the type of discourse adjustment, the discourse content to be adjusted, and the discourse adjustment description text specifically includes: First, text intention recognition can be performed on the discourse adjustment description text to identify the specific intention of the user in English discourse adjustment, so as to obtain the user's discourse adjustment intention. It can be understood that the purpose of text intention recognition is to better extract the key information in the discourse adjustment description text, so as to avoid the problems of missing key information and inappropriate details in the prompt text during the construction of the prompt text. Through text intention recognition, the intention of the user in English discourse adjustment can be accurately obtained, and English discourse adjustment can be carried out with this as the guidance, which can make the purpose more clear, the adjustment process faster, and the adjusted result more in line with expectations.

[0048] Subsequently, according to the identified discourse adjustment intention, the type of discourse adjustment involved, and the discourse content to be adjusted, the discourse adjustment prompt text can be determined. Here, specifically, the discourse adjustment intention, the type of discourse adjustment, and the discourse content to be adjusted can be processed to refine the above information into structured statements, so as to obtain the discourse adjustment prompt text.

[0049] It should be noted that in the embodiments of the present invention, the purpose of text intention recognition and prompt text construction is to convert the user's natural description language into structured language that can be understood by the model, and use the structured language as the input of the model, so that the model can more accurately understand the user's adjustment requirements, and thus make targeted adjustments to give results that meet the user's expectations.

[0050] Based on the above embodiments, based on the discourse adjustment prompt text, a discourse generation model is applied to perform English discourse adjustment to obtain the target English discourse corresponding to the discourse generation requirement, including: Based on the discourse adjustment prompt text, a discourse generation model is applied to perform English discourse adjustment to obtain the adjusted content corresponding to the discourse content to be adjusted; Based on the adjusted content and the initial English discourse, the target English discourse corresponding to the discourse generation requirement is determined.

[0051] Specifically, when performing discourse adjustment according to the discourse adjustment prompt text, the discourse adjustment prompt text can be directly used as the input and input into the discourse generation model. The discourse generation model can then adjust the discourse content to be adjusted in the initial English discourse according to the input discourse adjustment prompt text, so as to obtain the adjusted content corresponding to these discourse contents, that is, the adjusted content corresponding to the discourse content to be adjusted. Then, based on this adjusted content and the initial English discourse, the final target English discourse can be determined; that is, the discourse content to be adjusted in the initial English discourse can be directly replaced with its corresponding adjusted content to obtain the target English discourse.

[0052] It should be noted that the replacement process here can be executed by a discourse generation model. That is, after obtaining the adjustment content corresponding to the discourse content to be adjusted through English discourse adjustment, the discourse generation model can directly perform content replacement in the initial English discourse according to the correspondence between the discourse content to be adjusted and the adjustment content, and output the replaced English discourse, which is the target English discourse; it can also be executed by a non-discourse generation model, and the embodiments of the present invention do not make specific limitations on this.

[0053] The following takes a specific example to illustrate the process of English discourse adjustment: For the discourse generation description text "Give me a discourse of about 150 words expressing the relationship between humans and nature, which is required not to exceed the junior high school level, use imperative sentences, and use the word 'popular'", the discourse generation model gives the initial English discourse, specifically: "Boys and girls, do you have the habit of making resolutions before the new term starts? Read and have a look at the resolutions of Andy and three of her classmates. Name Resolutions Tony Now, I go to school by bus every day. I'm going to move to a new house soon. It is close to school. In the new term, I'm going to learn how to ride a bicycle. And I will ride to school every day. Linda In the new term, I'm going to take up a new hobby - cooking. My parents' favourite food is fish. I want to cook fish for them. I am going to learn how to cook from Aunt Susan. Jimmy I'm kind of heavy. So in the new term, I'm going to do more exercise. I run for fifteen minutes every day now. In the new term, I'll run for more than fifteen minutes every day. Andy My father is a scientist and my mother works as a teacher. They are always very busy. In the new term, I'm going to help them do more housework.”。

[0054] At this time, if the user provides the discourse adjustment description text "Can more advanced vocabulary be used in the sentence 'My parents' favourite food is fish. I want to cook fish for them.' and the two sentences be combined into one sentence", a discourse adjustment prompt text can be generated accordingly and input into the discourse generation model. The discourse generation model can then adjust the English discourse based on this prompt text in combination with the initial English discourse to obtain the adjusted content "My parents have a predilection for fish, thus I intend to prepare it for them.".

[0055] If the user provides the discourse adjustment description text "‘do you have the habit of making resolutions before the new term starts? ’ Please change it to an affirmative sentence and use more advanced vocabulary", a discourse adjustment prompt text can be generated first and input into the discourse generation model. The discourse generation model can then adjust the English discourse based on this prompt text in combination with the initial English discourse to obtain the adjusted content "I possess the custom of setting goals prior to the commencement of the new term.".

[0056] If the user provides the discourse adjustment description text "‘In the new term, I'm going to learn how to ride a bicycle. ’ Please change it to the past tense and change 'I' to'she'", a discourse adjustment prompt text can be generated first and input into the discourse generation model. The discourse generation model can combine the initial English discourse and adjust the English discourse to obtain the adjusted content "She learned how to ride a bicycle in the new term.".

[0057] Based on the above embodiments, step 120 includes: Perform text intention recognition based on the discourse generation description text to obtain the user's discourse generation intention; Determine the discourse generation prompt text based on the discourse generation intention; Apply the discourse generation model to generate an initial English discourse based on the discourse generation prompt text.

[0058] Specifically, the process of generating descriptive text based on the discourse and applying the discourse generation model to generate an initial English discourse can specifically include: First, text intention recognition can be performed on the descriptive text for discourse generation to identify the specific intention of the user in English discourse generation, and the user's discourse generation intention can be obtained. It can be understood that similar to the English discourse adjustment process, the purpose of text intention recognition here is to better extract the key information in the descriptive text for discourse generation, so that the model can more quickly and accurately understand the user's purpose, and thus generate English discourse more precisely.

[0059] Next, the discourse generation prompt text can be determined according to the recognized discourse generation intention. Here, specifically, the discourse adjustment intention can be processed to refine it into a structured statement, thereby obtaining the discourse generation prompt text. Obviously, the natural language description "Give me a discourse of about 150 words expressing the relationship between humans and nature, which should not exceed the junior high school level, use imperative sentences, and use the word 'popular'" is far less clear and concise than the structured statement "Theme requirement: the relationship between humans and nature, Word count requirement: about 150 words, Academic level: junior high school, Grammar requirement: use imperative sentences, Keyword requirement: use 'popular'". Therefore, in the embodiments of the present invention, performing text intention recognition on the descriptive text for discourse generation and constructing the discourse generation prompt text can enable the model to better understand the user's intention, and thus generate English discourse more accurately, obtaining an initial English discourse that better meets expectations.

[0060] After that, the discourse generation prompt text can be input into the discourse generation model, so that the discourse generation model automatically generates an English discourse according to the information contained in this prompt text, that is, the model generates an English discourse according to the requirements in the discourse generation prompt text and outputs the generated English discourse, that is, the initial English discourse.

[0061] For example, for the descriptive text for discourse generation "Give me a discourse of 150 to 200 words expressing self - management and self - improvement, which should not exceed the junior high school level, and the tenses are present continuous tense and simple present tense", the discourse generation prompt text "Theme requirement: self - management and self - improvement, Word count requirement: between 150 and 200 words, Academic level: junior high school, Grammar requirement: present continuous tense, simple present tense" can be constructed. Inputting this prompt text into the discourse generation model, the following initial English discourse can be obtained: "Boys and girls, do you have the habit of making resolutions before the new term starts? Read and have a look at the resolutions of Andy and three of her classmates. Name Resolutions Tony Now, I go to school by bus every day. I'm going to move to a new house soon. It is close to school. In the new term, I'm going to learn how to ride a bicycle. And I will ride to school every day. Linda In the new term, I'm going to take up a new hobby - cooking. My parents' favourite food is fish. I want to cook fish for them. I am going to learn how to cook from Aunt Susan. Jimmy I'm kind of heavy. So in the new term, I'm going to do more exercise. I run for fifteen minutes every day now. In the new term, I'll run for more than fifteen minutes every day. Andy My father is a scientist and my mother works as a teacher. They are always very busy. In the new term, I'm going to help them do more housework.”。

[0062] Figure 2 It is the overall flowchart of the English discourse generation method provided by the present invention. As Figure 2 shown, the method includes: First, determine the discourse generation description text, where the discourse generation description text is used to describe the user's discourse generation requirements.

[0063] Next, perform text intention recognition based on the discourse generation description text to obtain the user's discourse generation intention, and determine the discourse generation prompt text based on the discourse generation intention.

[0064] Immediately afterwards, based on the discourse generation prompt text, apply the discourse generation model to generate an English discourse to obtain an initial English discourse.

[0065] Subsequently, obtain the discourse adjustment description text feedback by the user for the initial English discourse.

[0066] Then, determine the discourse adjustment type corresponding to the discourse adjustment description text, and the discourse content to be adjusted in the initial English discourse; perform text intention recognition based on the discourse adjustment description text to obtain the user's discourse adjustment intention.

[0067] After that, based on the discourse adjustment intention, the discourse adjustment type, and the discourse content to be adjusted, determine the discourse adjustment prompt text.

[0068] Then, based on the discourse adjustment prompt text, apply the discourse generation model to adjust the English discourse to obtain the adjustment content corresponding to the discourse content to be adjusted.

[0069] Finally, based on the adjustment content and the initial English discourse, determine the target English discourse corresponding to the discourse generation requirements.

[0070] Among them, the discourse adjustment type includes at least one of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging.

[0071] The method provided by the embodiments of the present invention determines the discourse generation description text, and the discourse generation description text is used to describe the user's discourse generation requirements; based on the discourse generation description text, apply the discourse generation model to generate an English discourse to obtain an initial English discourse; based on the discourse adjustment description text feedback by the user for the initial English discourse, apply the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements, realizing automated English discourse generation, overcoming the defects that in the traditional solution, obtaining a discourse through a retrieval method is not only time-consuming and laborious, but also difficult to accurately obtain a discourse that meets the user's needs. It can not only generate a discourse according to the user's needs, but also adjust the discourse according to the adjustment intention feedback by the user, so that the finally obtained target English discourse can better fit the user's discourse generation requirements, realizing fast, accurate and effective discourse generation.

[0072] The present invention also provides a training method for a discourse generation model. Figure 3It is a schematic flowchart of the training method of the discourse generation model provided by the present invention. As Figure 3 shown, the method includes: Step 310: Obtain a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; Step 320: Determine the discourse scores of each sample English discourse based on each sample discourse description text and its corresponding sample English discourse; Step 330: Determine high-quality sample English discourses from each sample English discourse based on the discourse scores, and train an initial discourse model based on the high-quality sample English discourses and their corresponding sample discourse description texts to obtain a discourse generation model; Among them, the initial discourse model is constructed based on a large language model.

[0073] Specifically, to enable the model to have excellent discourse generation ability and automatically generate corresponding English discourses according to the user's discourse requirements, in the embodiments of the present invention, the model needs to be trained first, and the data used for training, that is, the sample data set, needs to be collected in advance. Here, it can be to obtain a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and each sample discourse description text corresponds to one or more sample English discourses.

[0074] It should be noted that the sample discourse description texts here can be the text presentations of the discourse requirements of multiple pre-collected teachers, and the corresponding sample English discourses can be written by experienced teachers, experts, etc. according to the corresponding discourse generation requirements.

[0075] After determining the paired training data, that is, each sample discourse description text in the sample data set and its corresponding sample English discourse, in the embodiments of the present invention, scoring can be performed to determine the quality of each sample English discourse through scoring, so as to decide whether to adjust it and whether to select it as training data for model training.

[0076] Specifically, here it can be to use a scoring model to score each sample English discourse in the sample data set, and score it according to its matching degree with the corresponding sample discourse description text, its own fluency, word usage, sentence pattern, grammar, etc., to judge the quality of the discourse, so as to obtain the discourse scores of each sample English discourse. Among them, the scoring model can be a commonly used model for scoring articles at present.

[0077] Furthermore, high-quality sample English texts can be selected from the sample dataset according to this text score. Specifically, here, several top sample English texts can be selected from the sample dataset in descending order of the text score as high-quality sample English texts; alternatively, a standard value, such as 88 points, 90 points, etc., can be set, and the sample English texts with text scores higher than this value can be used as high-quality sample English texts.

[0078] After that, model training can be carried out based on the selected high-quality sample English texts. That is, the initial text model can be trained using the high-quality sample English texts and their corresponding sample text description texts. The training objective is to minimize the difference between the model prediction result and the label, so that the prediction result output by the model is as consistent as possible with the label, and thus an accurate and reliable English text can be generated by the trained text generation model in the subsequent application process. The initial text generation model here can be constructed based on a large language model.

[0079] Specifically, the training process of the text generation model here can take the sample text description text corresponding to the high-quality sample English text as the input and the high-quality sample English text as the output, or take the high-quality sample English text as the input and its corresponding sample text description text as the output. The model obtains the text generation ability by learning the mapping relationship between the input and the output, and thus can directly rely on this ability to output the English text corresponding to the text generation description text during the application process.

[0080] In addition, it should be noted that for the sample English texts not selected in the sample dataset, that is, low-quality sample English texts, they can be modified by experienced teachers, experts, etc. to improve the quality. After the modification, the scoring can be carried out again. If they are determined to be high-quality sample English texts through the new text score, they can be selected for model training. If they are still low-quality sample English texts, they can be modified again.

[0081] The training method of the text generation model provided by the present invention screens out high-quality sample English texts from the sample dataset by scoring, and trains the model based on this high-quality sample English text and its corresponding sample text description text, enabling the model to accurately learn the corresponding relationship between the text and the description text from high-quality data, thus having a good text generation ability. Furthermore, the required English text can be automatically generated according to the user's text requirements, providing support for fast and accurate text generation and a basis for high-quality English teaching.

[0082] Based on the above embodiments, each sample discourse description text in the sample dataset corresponds to at least one knowledge point under the knowledge point hierarchy relationship. Each knowledge point corresponds to a theme requirement in the discourse generation requirements. The knowledge point hierarchy relationship represents the upper and lower hierarchical relationships between knowledge points in a tree structure.

[0083] Specifically, each type of discourse generation requirement in the sample dataset may include one or more requirements, such as theme requirements, educational stage requirements, vocabulary requirements, etc. Each theme requirement / theme demand corresponds to a knowledge point. Each type of discourse generation requirement may have one or more themes, that is, the sample discourse description text corresponding to each type of discourse generation requirement contains one or more knowledge points. There is an upper and lower hierarchical relationship between different knowledge points, and this relationship can be represented by a tree structure.

[0084] For example, for the knowledge point hierarchy relationship, which includes multiple knowledge point levels. For the first-level knowledge points, that is, the first-level themes, there are "Man and Self", "Man and Society", "Man and Nature", etc.; for the second-level knowledge points under the first-level knowledge point "Man and Nature", that is, the second-level themes, there are "Ecological Nature", "Environmental Protection", "Disaster Prevention", "Cosmic Exploration", etc.; for the third-level knowledge points under the second-level knowledge point "Ecological Nature", that is, the third-level themes, there are "Natural Environment", "Seasons and Climate", "Animals and Plants", etc.

[0085] Here, by explicitly showing the relationship between knowledge points through a tree structure, and enumerating and classifying various types of knowledge points, the model can gradually learn the corresponding knowledge during the training process, so as to "from shallow to deep", gradually expand the knowledge reserve, improve its performance, and then can give an accurate response to the user's discourse request.

[0086] In addition, it should be noted that in order to enable the model to have a certain "cutting-edge" ability in English discourse generation, during model training, a small amount of out-of-syllabus data can be provided. For example, under the corresponding educational stage requirements, sample English discourses with an out-of-syllabus word ratio of less than 3% are provided for model training to improve its performance, so that the English discourses output by the model during actual application are more "cutting-edge" and more advanced in terms of word usage, and thus contribute to actual English teaching.

[0087] Next, the English discourse generation device provided by the present invention will be described. The English discourse generation device described below can be correspondingly referred to the English discourse generation method described above.

[0088] Figure 4 is a schematic structural diagram of the English discourse generation device provided by the present invention, as Figure 4 shown, the device includes: A text determination unit 410 is configured to determine a discourse generation description text for describing a user's discourse generation requirement. A discourse generation unit 420 is configured to generate an initial English discourse by applying a discourse generation model based on the discourse generation description text. A discourse adjustment unit 430 is configured to obtain a discourse adjustment description text fed back by the user for the initial English discourse, and perform English discourse adjustment by applying a discourse generation model based on the discourse adjustment description text to obtain a target English discourse corresponding to the discourse generation requirement.

[0089] The English discourse generation device provided by the present invention generates an initial English discourse by applying a discourse generation model based on a user's discourse generation description text, and performs English discourse adjustment by applying a discourse generation model based on a discourse adjustment description text fed back by the user for the initial English discourse to obtain a target English discourse corresponding to the discourse generation requirement, realizing automated English discourse generation, overcoming the defects that in the traditional solution, obtaining a discourse by means of retrieval is not only laborious and time-consuming, but also difficult to accurately obtain a discourse that meets the user's requirements. It can not only generate a discourse according to the user's requirements, but also adjust the discourse according to the adjustment intention fed back by the user, so that the finally obtained target English discourse can better match the user's discourse generation requirement, realizing fast, accurate and effective discourse generation.

[0090] Based on the above embodiments, the discourse adjustment unit 430 is configured to: Determine a discourse adjustment type corresponding to the discourse adjustment description text, and discourse content to be adjusted in the initial English discourse; Determine a discourse adjustment prompt text based on the discourse adjustment type, the discourse content to be adjusted, and the discourse adjustment description text; Perform English discourse adjustment by applying a discourse generation model based on the discourse adjustment prompt text to obtain a target English discourse corresponding to the discourse generation requirement.

[0091] Based on the above embodiments, the discourse adjustment unit 430 is configured to: Perform text intention recognition based on the discourse adjustment description text to obtain the user's discourse adjustment intention; Determine a discourse adjustment prompt text based on the discourse adjustment intention, the discourse adjustment type, and the discourse content to be adjusted.

[0092] Based on the above embodiments, the discourse adjustment unit 430 is configured to: Perform English discourse adjustment by applying a discourse generation model based on the discourse adjustment prompt text to obtain adjustment content corresponding to the discourse content to be adjusted; Based on the adjusted content and the initial English discourse, determine the target English discourse corresponding to the discourse generation requirement.

[0093] Based on the above embodiments, the types of discourse adjustment include at least one of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging.

[0094] Based on the above embodiments, the discourse generation unit 420 is configured to: Perform text intention recognition based on the discourse generation description text to obtain the user's discourse generation intention; Determine a discourse generation prompt text based on the discourse generation intention; Based on the discourse generation prompt text, apply the discourse generation model to generate an initial English discourse.

[0095] The training device of the discourse generation model provided by the present invention is described below. The training device of the discourse generation model described below can be correspondingly referred to the training method of the discourse generation model described above.

[0096] Figure 5 It is a schematic structural diagram of the training device of the discourse generation model provided by the present invention, as Figure 5 shown. The device includes: An acquisition unit 510, configured to acquire a sample data set, where the sample data set includes sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; A scoring unit 520, configured to determine the discourse score of each sample English discourse based on each sample discourse description text and its corresponding sample English discourse; A training unit 530, configured to determine high-quality sample English discourses from each sample English discourse based on the discourse score, and train an initial discourse model based on the high-quality sample English discourses and their corresponding sample discourse description texts to obtain a discourse generation model; Wherein, the initial discourse model is constructed based on a large language model.

[0097] The training device of the discourse generation model provided by the present invention screens high-quality sample English discourses from the sample data set by scoring, and performs model training according to the high-quality sample English discourses and their corresponding sample discourse description texts, so that the model can accurately learn the corresponding relationship between the discourse and the description text from high-quality data, thereby having good discourse generation ability, and further can automatically generate the required English discourse according to the user's discourse requirements, providing support for fast and accurate discourse generation and providing a basis for high-quality English teaching.

[0098] Based on the above embodiments, each sample discourse description text in the sample data set corresponds to at least one knowledge point under the knowledge point hierarchy relationship, and each knowledge point corresponds to one topic requirement in the discourse generation requirements. The knowledge point hierarchy relationship represents the hierarchical relationship between knowledge points in a tree structure.

[0099] Figure 6 An example of a schematic diagram of the physical structure of an electronic device is shown as Figure 6 shown. The electronic device may include: a processor 610, a communication interface 620, a memory 630, and a communication bus 640. Among them, the processor 610, the communication interface 620, and the memory 630 complete communication with each other through the communication bus 640. The processor 610 can call the logical instructions in the memory 630 to execute the English discourse generation method or the training method of the discourse generation model. The English discourse generation method includes: determining a discourse generation description text for describing the user's discourse generation requirements; based on the discourse generation description text, applying the discourse generation model to generate an initial English discourse; obtaining the discourse adjustment description text fed back by the user for the initial English discourse, and based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements. The training method of the discourse generation model includes: obtaining a sample data set, where the sample data set contains sample discourse description texts corresponding to various discourse generation requirements and sample English discourses corresponding to each sample discourse description text; determining the discourse scores of each sample English discourse based on each sample discourse description text and its corresponding sample English discourse; based on the discourse scores, determining high-quality sample English discourses from each sample English discourse, and training an initial discourse model based on the high-quality sample English discourses and their corresponding sample discourse description texts to obtain a discourse generation model; where the initial discourse model is constructed based on a large language model.

[0100] In addition, when the logical instructions in the above-mentioned memory 630 are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks, or optical discs.

[0101] On the other hand, the present invention also provides a computer program product. The computer program product includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the English discourse generation method or the training method of the discourse generation model provided by the above-mentioned various methods. The English discourse generation method includes: determining a discourse generation description text, which is used to describe the user's discourse generation requirements; based on the discourse generation description text, applying a discourse generation model to generate an initial English discourse; obtaining a discourse adjustment description text fed back by the user for the initial English discourse, and based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements. The training method of the discourse generation model includes: obtaining a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements and sample English discourses corresponding to each sample discourse description text; based on each sample discourse description text and its corresponding sample English discourse, determining the discourse score of each sample English discourse; based on the discourse score, determining high-quality sample English discourses from each sample English discourse, and based on the high-quality sample English discourses and their corresponding sample discourse description texts, training an initial discourse model to obtain a discourse generation model; wherein, the initial discourse model is constructed based on a large language model.

[0102] In another aspect, the present invention also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the English discourse generation method or the training method of the discourse generation model provided by the above-mentioned various methods. The English discourse generation method includes: determining a discourse generation description text, which is used to describe the user's discourse generation requirements; based on the discourse generation description text, applying a discourse generation model to generate an initial English discourse; obtaining a discourse adjustment description text fed back by the user for the initial English discourse, and based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain a target English discourse corresponding to the discourse generation requirements. The training method of the discourse generation model includes: obtaining a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; based on each sample discourse description text and its corresponding sample English discourse, determining the discourse score of each sample English discourse; based on the discourse score, determining high-quality sample English discourses from each sample English discourse, and based on the high-quality sample English discourses and their corresponding sample discourse description texts, training an initial discourse model to obtain a discourse generation model; wherein, the initial discourse model is constructed based on a large language model.

[0103] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art can understand and implement it without creative effort.

[0104] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on such an understanding, the above technical solution, in essence, or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0105] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. An English discourse generation method, characterized in that, It includes: Determine the discourse generation description text, which is used to describe the user's discourse generation requirements; Based on the discourse generation description text, apply a discourse generation model to generate an initial English discourse; Obtain the discourse adjustment description text feedback by the user for the initial English discourse, and based on the discourse adjustment description text, apply the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements.

2. The English discourse generation method according to claim 1, wherein The step of, based on the discourse adjustment description text, applying the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements includes: Determine the discourse adjustment type corresponding to the discourse adjustment description text, and the discourse content to be adjusted in the initial English discourse; Based on the discourse adjustment type, the discourse content to be adjusted, and the discourse adjustment description text, determine the discourse adjustment prompt text; Based on the discourse adjustment prompt text, apply the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements.

3. The English discourse generation method according to claim 2, wherein The step of, based on the discourse adjustment type, the discourse content to be adjusted, and the discourse adjustment description text, determining the discourse adjustment prompt text includes: Perform text intention recognition based on the discourse adjustment description text to obtain the user's discourse adjustment intention; Based on the discourse adjustment intention, the discourse adjustment type, and the discourse content to be adjusted, determine the discourse adjustment prompt text.

4. The English discourse generation method according to claim 2, characterized in that The step of, based on the discourse adjustment prompt text, applying the discourse generation model to adjust the English discourse to obtain the target English discourse corresponding to the discourse generation requirements includes: Based on the discourse adjustment prompt text, apply the discourse generation model to adjust the English discourse to obtain the adjusted content corresponding to the discourse content to be adjusted; Based on the adjusted content and the initial English discourse, determine the target English discourse corresponding to the discourse generation requirements.

5. The English discourse generation method according to any one of claims 2 to 4, characterized in that, The discourse adjustment type includes at least one of sentence pattern transformation, tense change, vocabulary replacement, and sentence splitting and merging.

6. The method for generating an English discourse according to any one of claims 1 to 4, characterized in that The step of, based on the discourse generation description text, applying the discourse generation model to generate an initial English discourse includes: Perform text intention recognition based on the discourse generation description text to obtain the user's discourse generation intention; Based on the discourse generation intention, determine the discourse generation prompt text; Based on the discourse generation prompt text, apply the discourse generation model to generate an initial English discourse.

7. A training method for a discourse generation model, characterized in that, It includes: Obtain a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements, and sample English discourses corresponding to each sample discourse description text; Based on each sample discourse description text and its corresponding sample English discourse, determine the discourse scores of each sample English discourse; Based on the discourse scores, determine high-quality sample English discourses from each sample English discourse, and based on the high-quality sample English discourses and their corresponding sample discourse description texts, train the initial discourse model to obtain a discourse generation model; Among them, the initial discourse model is constructed based on a large language model.

8. The training method of the discourse generation model according to claim 7, wherein each sample discourse description text in the sample data set corresponds to at least one knowledge point under the knowledge point hierarchical relationship, each knowledge point corresponds to one topic requirement in the discourse generation requirement, and the knowledge point hierarchical relationship represents the hierarchical relationship between knowledge points in a tree structure.

9. An English discourse generation device, characterized in that, It includes: a text determination unit for determining a discourse generation description text for describing the user's discourse generation requirement; a discourse generation unit for generating an initial English discourse by applying a discourse generation model based on the discourse generation description text; a discourse adjustment unit for obtaining a discourse adjustment description text fed back by the user for the initial English discourse, and applying the discourse generation model to adjust the English discourse based on the discourse adjustment description text to obtain the target English discourse corresponding to the discourse generation requirement.

10. A training device for a discourse generation model, characterized in that It includes: an acquisition unit for acquiring a sample data set, which contains sample discourse description texts corresponding to various discourse generation requirements and sample English discourses corresponding to each sample discourse description text; a scoring unit for determining the discourse scores of the sample English discourses based on the sample discourse description texts and their corresponding sample English discourses; a training unit for determining high-quality sample English discourses from the sample English discourses based on the discourse scores, and training the initial discourse model based on the high-quality sample English discourses and their corresponding sample discourse description texts to obtain a discourse generation model; Among them, the initial discourse model is constructed based on a large language model.

11. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the English discourse generation method according to any one of claims 1 to 6, or the training method of the discourse generation model according to claim 7 or 8.

12. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the English discourse generation method according to any one of claims 1 to 6, or the training method of the discourse generation model according to claim 7 or 8.