A document generation method and device based on a multi-agent large model system

By leveraging the collaborative efforts of a multi-agent large model system, the problem of low document generation efficiency in single-agent systems was solved, enabling paragraph-by-paragraph writing and review, thus improving document quality and efficiency.

CN122452509APending Publication Date: 2026-07-24BEIJING ACAD OF ARTIFICIAL INTELLLIGENCE
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
BEIJING ACAD OF ARTIFICIAL INTELLLIGENCE
Filing Date
2026-04-15
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

Existing document generation methods are based on a single agent, which makes it difficult to simultaneously take into account personalized structural planning, language style control, and content accuracy. Furthermore, when a document is modified, it needs to be regenerated from scratch, resulting in low efficiency.

Method used

A multi-agent large model system is adopted, in which a planning agent generates a writing outline, a writing agent writes paragraph by paragraph and a review agent reviews the document, forming a document generation process in which multiple agents work together.

Benefits of technology

It enables paragraph-by-paragraph writing and review, improving the quality and efficiency of document generation, reducing issues such as content deviating from the topic and logical inconsistencies, and closely resembling the human writing process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122452509A_ABST
    Figure CN122452509A_ABST
Patent Text Reader

Abstract

The application provides a document generation method and device based on a multi-agent large model system, and relates to the technical field of artificial intelligence. The method comprises the following steps: an agent plans an outline according to an obtained writing task, and sends the outline to a writing agent; the outline indicates a plurality of writing paragraphs, a writing theme of each writing paragraph, and a writing order between the writing paragraphs; the following process is repeatedly executed until all the writing paragraphs are completed: the writing agent determines a current writing paragraph from the writing paragraphs according to the writing order, generates first content according to the writing theme of the current writing paragraph, and sends the first content to an auditing agent; the auditing agent audits the quality of the first content, and determines whether the current writing paragraph is completed according to an auditing result. In this embodiment, a plurality of agents work together, can write and audit paragraph by paragraph according to the outline, effectively reduce the problems of content deviating from the theme and logical confusion, and improve the overall quality.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to a document generation method and apparatus based on a multi-agent large model system. Background Technology

[0002] With the rapid development of natural language processing technology, there are already some methods for automatic document generation based on large language models, which can automatically generate corresponding text content by having users input topics or keywords.

[0003] However, existing document generation methods typically rely on a single agent to generate text, and the document is generated only once. Even if the model within the agent is trained across multiple dimensions, including structure, language style, and content, the performance limitations of a single model make it difficult to simultaneously address the needs for personalized structural planning, language style control, and content accuracy. Furthermore, because the document is generated only once, any modifications or optimizations require a complete regeneration, resulting in low document generation efficiency and failing to meet users' actual needs. Summary of the Invention

[0004] This invention provides a document generation method and apparatus based on a multi-agent large-scale model system. Through the collaborative mechanism of multiple agents within the system, the document generation process involves a planning agent first generating a writing outline, followed by interaction between the writing and reviewing agents to write and review the document paragraph by paragraph. Compared to existing methods that generate the entire document at once, this approach allows for writing at the paragraph level, with each paragraph undergoing quality review, effectively reducing issues such as content deviation from the topic and logical inconsistencies. Furthermore, utilizing agents with different functions to perform different operations more closely resembles the human writing process, improving overall document generation quality.

[0005] This invention provides a document generation method based on a multi-agent large model system, the multi-agent large model system including a planning agent, a writing agent, and a review agent, comprising the following steps: the planning agent generates a writing outline based on an acquired writing task and sends the writing outline to the writing agent; wherein, the writing outline indicates multiple writing paragraphs, the writing theme of each writing paragraph, and the writing order between the writing paragraphs; the following process is repeated until all the writing paragraphs are completed to obtain the target document: the writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content according to the writing theme of the current writing paragraph, and sends the first content to the review agent; the review agent performs a quality review on the first content and determines whether the current writing paragraph is completed based on the review result.

[0006] Optionally, the method further includes: receiving a writing request input by a user via an interactive page; the planning agent generating a writing task based on a correlation analysis of at least one target field included in the writing request; wherein the correlation analysis includes at least one of the following: scene localization, job matching, intent recognition, material retrieval, and style matching.

[0007] Optionally, the planning agent generates a writing outline based on the acquired writing task and sends the writing outline to the writing agent, including: the planning agent generates a first writing outline based on the acquired writing task and displays the first writing outline to the user using an interactive page; in response to the user triggering an editing function on the interactive page, the planning agent obtains a second writing outline after the user has finished editing and sends the second writing outline to the writing agent.

[0008] Optionally, the writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, and generates first content based on the writing theme of the current writing paragraph, including: the writing agent determines the current writing paragraph from multiple writing paragraphs according to the writing order; obtains writing tags corresponding to the current writing paragraph; wherein the writing tags include at least one of the following: style tags, logic tags, and constraint tags; and generates first content based on the writing theme of the current writing paragraph and the writing tags.

[0009] Optionally, the review agent performs a quality review on the first content and determines whether to complete the current writing paragraph based on the review result, including: if the review result indicates that the review is not passed, generating modification suggestions and feeding the modification suggestions back to the writing agent so that the writing agent regenerates the first content; and if the review result indicates that the review is passed, completing the current writing paragraph.

[0010] Optionally, the multi-agent large model system further includes an optimization agent; after the writing agent generates first content based on the writing theme of the current writing paragraph, it sends the first content to the optimization agent; the optimization agent optimizes the first content to obtain second content, and sends the second content to the review agent, so that the review agent can perform quality review based on the second content.

[0011] Optionally, after obtaining the target document, the method further includes: displaying the target document using an interactive page; and in response to a user making modification annotations to the target document using the interactive page, sending the modification annotations to the optimization agent so that the optimization agent optimizes the target document based on the modification annotations.

[0012] The present invention also provides a document generation device based on a multi-agent large model system, wherein the multi-agent large model system includes a planning agent, a writing agent, and a reviewing agent, and includes the following modules: The outline writing module is used to generate a writing outline based on the acquired writing task using the planning agent, and send the writing outline to the writing agent; wherein, the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between the writing paragraphs. The writing module is used to repeatedly execute the following process until all the writing paragraphs are completed, resulting in the target document: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content based on the writing theme of the current writing paragraph, and sends the first content to the review agent. The review agent is used to review the quality of the first content, and the current writing paragraph is determined based on the review results.

[0013] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the document generation method based on a multi-agent large model system as described above.

[0014] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the document generation method based on a multi-agent large model system as described above.

[0015] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the document generation method based on a multi-agent large model system as described above.

[0016] This invention provides a document generation method and apparatus based on a multi-agent large-scale model system. Through a collaborative mechanism among multiple agents within the system, the document generation process involves a planning agent generating a writing outline, followed by interaction between the writing and reviewing agents to write and review the document paragraph by paragraph. Compared to existing methods that generate the entire document at once, this approach allows for paragraph-level writing with quality review at each stage, effectively reducing issues of content deviation from the topic and logical inconsistencies. Furthermore, utilizing agents with different functions to perform different operations more closely approximates the human writing process, improving overall document generation quality. Attached Figure Description

[0017] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0018] Figure 1 This is one of the flowcharts of a document generation method based on a multi-agent large model system provided by the present invention.

[0019] Figure 2 This is a schematic diagram of the writing task generation process provided by the present invention.

[0020] Figure 3 This is a schematic diagram of the interactive page provided by the present invention.

[0021] Figure 4 This is a schematic diagram of the process for generating the first content provided by the present invention.

[0022] Figure 5 This is the second flowchart of a document generation method based on a multi-agent large model system provided by the present invention.

[0023] Figure 6 This is the third flowchart of a document generation method based on a multi-agent large model system provided by the present invention.

[0024] Figure 7 This is a schematic diagram of an intelligent agent interaction provided by the present invention.

[0025] Figure 8 This is a schematic diagram of the process after generating the target document provided by the present invention.

[0026] Figure 9 This invention provides a schematic diagram of a document generation device based on a multi-agent large model system.

[0027] Figure 10 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0028] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0029] Figure 1 This is a flowchart illustrating a document generation method based on a multi-agent large-scale model system provided by the present invention. Specifically, the multi-agent large-scale model system includes a planning agent, a writing agent, and a reviewing agent, such as... Figure 1 As shown, the method includes the following: Step 101: The planning agent generates a writing outline based on the acquired writing task and sends the writing outline to the writing agent; the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between each writing paragraph. Repeat steps 102 and 103 until all paragraphs are written, resulting in the target document: Step 102: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates the first content according to the writing theme of the current writing paragraph, and sends the first content to the review agent. Step 103: The review agent conducts a quality review of the first content and determines whether to complete the current writing paragraph based on the review results.

[0030] Among them, writing tasks refer to task information that indicates core requirements in multiple dimensions such as writing topic, target audience, occasion, time, and word count. The more dimensions there are, the clearer and more detailed the task description will be, and the more closely the final target document will fit the user's actual needs.

[0031] As can be seen from steps 101 to 103 above, this embodiment of the invention breaks down the document generation process by setting up a planning agent, a writing agent, and a review agent respectively. First, the planning agent generates a writing outline, which clarifies the overall writing logic of the entire document and ensures that the document does not deviate from the topic or become logically confused during the generation process. Compared with the existing technology of generating a document all at once based on the writing task, this greatly improves the organization and logic of the generated document. After generating the writing outline, this embodiment of the invention further utilizes the writing agent to realize paragraph-by-paragraph writing, which is completely different from the one-time document generation process in the prior art. By writing and reviewing paragraph by paragraph, the writing quality of each paragraph can be guaranteed, improving the overall writing quality of the document at a fine granular level.

[0032] In one alternative embodiment, the writing task is automatically generated based on a writing request input by the user; specifically, it can be as follows: Figure 2 As shown, it includes: Step 201: Receive the writing request input by the user using the interactive page; Step 202: The planning agent generates a writing task based on the relevance analysis of at least one target field included in the writing request; wherein the relevance analysis includes at least one of the following: scene localization, job matching, intent recognition, material retrieval, and style matching.

[0033] For example, taking the application scenario where the target document is a speech draft as an example, the interactive page is as follows: Figure 3 As shown, in practical applications, users need to fill in at least the core information required to generate the target document on the interactive page (i.e., Figure 3 The input boxes marked with * on the interactive page), and fill in the appropriate supplementary information according to the actual needs (i.e. Figure 3 The interactive page (without an asterisk in the input box) generates a writing request with various information to be filled in (core information and supplementary information) after clicking the "Next" button. This writing request is then sent to the server, which is deployed with a multi-agent large model system. Upon receiving the writing request, the server uses a planning agent to perform relevance analysis on at least one target field included in the writing request, aiming to expand the content based on the information provided by the user as much as possible. Specifically, scene localization refers to locating the application scenario of the target document, such as a speech scenario or a press conference scenario; job matching refers to querying and matching the job title of the speaker; intent recognition refers to identifying the purpose and intent of the target document to be generated; material retrieval refers to querying various materials related to the target field; and style matching refers to matching different speaking styles to the target document based on the target field.

[0034] In one optional embodiment, the planning agent can extract keywords based on the information included in the writing request to obtain multiple keywords that reflect the core requirements of the document in multiple dimensions, such as the writing theme, target audience, occasion, time, and word count. Then, by analyzing the semantic relationship between multiple keywords, the theme hierarchy between the target keywords corresponding to different writing themes is obtained, forming a theme structure tree. Furthermore, a writing task is generated based on the theme structure tree, where each theme is a node in the theme structure tree.

[0035] Furthermore, writing tags can be added to each node in the topic structure tree or to the entire writing outline based on various input information such as the speaking occasion and the audience, resulting in a structured writing task with tags. In one optional embodiment, writing tags may include at least one of the following: style tags, logic tags, and constraint tags; wherein, style tags can be pre-set and selected by the user through an interactive page, with different style tags corresponding to different sentence structures and tones; logic tags are used to identify the logical relationships between different writing paragraphs; constraint tags are used to ensure consistency between writing paragraphs and the writing topic, facts, or cited articles. By incorporating writing tags corresponding to each writing paragraph, the writing agent can generate a more personalized text style based on the writing tags when generating the first content.

[0036] In an optional embodiment, the process of generating the first content in step 102 can be as follows: Figure 4 As shown, it specifically includes: Step 401: The writing agent determines the current writing paragraph from multiple writing paragraphs according to the writing order; Step 402: Obtain the writing tags corresponding to the current writing paragraph; Step 403: Generate the first content based on the writing theme and writing tags of the current writing paragraph.

[0037] By labeling each writing paragraph with corresponding writing tags, the writing agent will simultaneously consider the writing theme and writing tags when writing the current paragraph, so as to generate primary content that closely matches the user's expression.

[0038] Furthermore, when a user fills in only core information or only a small amount of supplementary information, the server can analyze the user's core information in conjunction with their historical data to expand the missing information or correct the filled information, thereby improving the accuracy of the generated document. For example, the server can analyze whether the user-input title is suitable as a speech title; if not, it can generate a suitable title. It can also analyze the user's job title and speaker information based on historical data to predict any missing supplementary information (such as the appropriate speaking occasion and audience).

[0039] In this embodiment of the invention, to maximize the accuracy of the target document and minimize unnecessary modifications, the user can confirm the writing outline after it is generated. The target document is then generated only after ensuring the accuracy of the framework, which significantly improves the accuracy and efficiency of the target document generation. Specifically, the document generation method based on a multi-agent large model system provided in this embodiment of the invention can also be as follows: Figure 5 As shown, it includes: Step 501: Receive the writing request input by the user using the interactive page; Step 502: Extract keywords from the writing request to obtain multiple keywords; Step 503: Generate writing tasks based on the relationships between the keywords and send the writing tasks to the planning AI agent; Step 504: The planning agent generates a first writing outline based on the writing task and displays the first writing outline to the user through an interactive page. Step 505: In response to the user triggering the editing function on the interactive page, obtain the second writing outline after the user has finished editing, and send the second writing outline to the writing agent; Repeat steps 506 and 507 until all paragraphs are written, resulting in the target document: Step 506: The writing agent determines the current writing paragraph from multiple writing paragraphs according to the writing order, generates the first content based on the writing theme of the current writing paragraph, and sends the first content to the review agent. Step 507: The review agent conducts a quality review of the first content and determines whether to complete the current writing paragraph based on the review results.

[0040] The editing functions for the first writing outline include: rewriting, deleting, reordering, adding, expanding the outline hierarchy, selecting materials, and selecting key phrases. Specifically, a writing outline typically includes multiple levels, such as first-level headings (I, II, III, ...), second-level headings ((I), (II), (III), ...), and third-level headings (1, 2, 3, ...), etc., with each level corresponding to one or more writing paragraphs. Therefore, the editing functions allow users to arbitrarily modify the generated first writing outline to ensure a satisfactory second writing outline.

[0041] The review process of the reviewing agent on the first content can specifically include: if the review result indicates that the review is not passed, generating modification suggestions and feeding them back to the writing agent so that the writing agent can regenerate the first content; if the review result indicates that the review is passed, completing the current writing paragraph. That is to say, in this embodiment of the invention, the target document is generated and reviewed segment by segment, and the next writing paragraph is only generated after the previous writing paragraph has passed review. This segment-by-segment generation and review method can achieve precise control over the granularity of paragraphs, ensuring the writing quality of each writing paragraph. The quality review can be a content-related review, specifically including: checking whether key facts and citations are correct, analyzing whether the logical relationships between various writing paragraphs are correct, whether the document format is correct, whether the citation method is correct, and whether it contains sensitive words, etc. It is understood that if the review result is not passed, it means that the first content has obvious errors or is unreasonable, and therefore it will be fed back to the writing agent for rewriting.

[0042] In summary, through the division of labor and cooperation mechanism among multiple agents in the multi-agent large model system, high-quality target documents can be automatically generated through the interaction process between the planning agent, the writing agent, and the review agent.

[0043] In one alternative embodiment, Figure 6 This invention also provides a document generation method based on a multi-agent large model system, wherein the multi-agent large model system includes a planning agent, a writing agent, an optimization agent, and a review agent. A schematic diagram illustrating the interactions between the multiple agents is shown below. Figure 7 As shown.

[0044] like Figure 6 and Figure 7 As shown, the document generation method based on a multi-agent large model system provided in this embodiment of the invention includes: Step 601: The planning agent generates a writing outline based on the acquired writing task and sends the writing outline to the writing agent; the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between each writing paragraph. Repeat steps 602 to 604 until all paragraphs are written, resulting in the target document: Step 602: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates the first content according to the writing theme of the current writing paragraph, and sends the first content to the optimization agent. Step 603: The optimization agent optimizes the first content to obtain the second content, and sends the second content to the review agent; Step 604: The review agent conducts a quality review of the second content and determines whether to complete the current writing paragraph based on the review results.

[0045] The optimization agent can perform language-level optimization on the initial content, complementing the review agent. For example, sentence optimization can include grammar checking, sentence rewriting, synonym replacement, and content expansion or reduction. Understandably, after receiving the initial content, the optimization agent can score it. If the score is higher than a preset score, it means the initial content written by the writing agent is linguistically sound and does not require further optimization; in this case, the initial content can be directly sent to the review agent. If the score is lower than the preset score, step 603 is executed.

[0046] In this embodiment of the invention, although the writing outline is modified and confirmed by the user after generation, which can basically guarantee the writing quality of the target document, considering the different needs of different users for language expression, local optimization at the language level can still be achieved through user interaction after the target document is generated. Specifically, another document generation method based on a multi-agent large model system provided in this embodiment of the invention, such as... Figure 8 As shown, after generating the target document, the following steps are also included: Step 801: Display the target document using the interactive page; Step 802: In response to the user making modification comments on the target document using the interactive page, send the modification comments to the optimization agent so that the optimization agent can optimize the target document based on the modification comments.

[0047] The annotations can be specific modifications made by the user to a sentence or paragraph in the target document, such as changing "Hello everyone" to "Good afternoon, colleagues." They can also be suggestions for improvement, such as "Please refine the language of this section." This invention does not impose specific limitations on these suggestions. Through multiple interactions with the user, adjustments can be made based on the user's actual needs both before and after the target document is generated, resulting in a target document that fully meets the user's requirements.

[0048] In a further optional embodiment, the multi-agent large model system provided by this invention may further include a learning agent for learning the user's expression style and language style. Specifically, the aforementioned user's modification annotations on the target document, the first content generated by the writing agent, the second content generated by the optimization agent, and the modification opinions generated by the review agent can all be sent to the learning agent so that the learning agent can learn the user's desired language style and expression, and provide a reference for the writing agent when generating the target document for the user again in the future.

[0049] In a further optional embodiment, in response to the user selecting a document generation format (e.g., Word document, PDF document, or other text format) based on the interactive interface and clicking the "Confirm Generation" button, the target document is output according to the document generation format selected by the user.

[0050] In a further optional embodiment, a knowledge base can be pre-built to manage materials in multiple dimensions, including but not limited to updating and adding / deleting materials. After each piece of material is uploaded to the knowledge base, a corresponding knowledge base agent can understand, split, and vectorize the material, so that when the writing agent is writing the first piece of content, it can directly select, call, and cite relevant materials from the knowledge base.

[0051] In summary, the document generation method based on a multi-agent large-scale model system provided by this invention utilizes the division of labor and cooperation mechanism among multiple agents within the system. This allows the planning agent to first generate a writing outline, followed by interaction between the writing agent and the review agent to write and review the document paragraph by paragraph. Compared to existing methods that generate the entire document at once, this method allows for writing at the paragraph level, with quality review performed on each paragraph, effectively reducing issues such as content deviation from the topic and logical inconsistencies. Furthermore, by utilizing agents with different functions to perform different operations, the document generation process more closely resembles human writing, improving overall generation quality.

[0052] The following describes a document generation device based on a multi-agent large model system provided by the present invention. The document generation device based on a multi-agent large model system described below and the document generation method based on a multi-agent large model system described above can be referred to and correspond to each other.

[0053] like Figure 9 As shown, the document generation device 900 based on a multi-agent large model system provided by the present invention includes: The outline writing module 901 is used to generate a writing outline based on the acquired writing task using the planning agent, and send the writing outline to the writing agent; wherein, the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between each writing paragraph. Writing module 902 is used to repeatedly execute the following process until all the writing paragraphs are completed, resulting in the target document: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content based on the writing theme of the current writing paragraph, and sends the first content to the review agent. The review agent is used to review the quality of the first content, and the current writing paragraph is determined based on the review results.

[0054] In an optional embodiment of the present invention, the device further includes a receiving module and a task generation module; wherein the receiving module is used to receive a writing request input by a user via an interactive page; the task generation module is used to generate a writing task by using the planning agent to perform a correlation analysis on at least one target field included in the writing request; wherein the correlation analysis includes at least one of the following: scene localization, job matching, intent recognition, material retrieval, and style matching.

[0055] In an optional embodiment of the present invention, the writing module 902 is further configured to: generate a first writing outline based on the acquired writing task, and display the first writing outline to the user using an interactive page; in response to the user triggering an editing function on the interactive page, obtain a second writing outline after the user has finished editing, and send the second writing outline to the writing agent.

[0056] In an optional embodiment of the present invention, the writing module 902 is further configured to: determine the current writing paragraph from the writing paragraphs according to the writing order; obtain writing tags corresponding to the current writing paragraph; wherein the writing tags include at least one of the following: style tags, logic tags, and constraint tags; and generate first content based on the writing theme of the current writing paragraph and the writing tags.

[0057] In an optional embodiment of the present invention, the writing module 902 is further configured to, if the review result indicates that the review is not approved, generate modification suggestions and feed the modification suggestions back to the writing agent so that the writing agent regenerates the first content; and if the review result indicates that the review is approved, complete the current writing paragraph.

[0058] In an optional embodiment of the present invention, the multi-agent large model system further includes an optimization agent; the writing module 902 is further configured to: after the writing agent generates first content based on the writing theme of the current writing paragraph, send the first content to the optimization agent; the optimization agent optimizes the first content to obtain second content, and sends the second content to the review agent, so that the review agent performs quality review based on the second content.

[0059] In an optional embodiment of the present invention, the writing module 902 is further configured to, after obtaining the target document, display the target document using an interactive page; and, in response to a user making modification annotations to the target document using the interactive page, send the modification annotations to the optimization agent so that the optimization agent optimizes the target document based on the modification annotations.

[0060] Figure 10 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 10 As shown, the electronic device may include: a processor 1010, a communications interface 1020, a memory 1030, and a communications bus 1040, wherein the processor 1010, the communications interface 1020, and the memory 1030 communicate with each other through the communications bus 1040. Processor 1010 can call logical instructions in memory 1030 to execute a document generation method based on a multi-agent large model system. The method includes: the planning agent generating a writing outline based on an acquired writing task, and sending the writing outline to the writing agent; wherein the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between the writing paragraphs; repeating the following process until all the writing paragraphs are completed to obtain a target document: the writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content based on the main idea of ​​the current writing paragraph, and sends the first content to the reviewing agent; the reviewing agent performs a quality review on the first content and determines whether the current writing paragraph is complete based on the review result.

[0061] Furthermore, the logical instructions in the aforementioned memory 1030 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this 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. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0062] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer is able to execute a document generation method based on a multi-agent large model system provided by the above methods. The method includes: the planning agent generating a writing outline according to the acquired writing task, and sending the writing outline to the writing agent; wherein the writing outline indicates multiple writing paragraphs, the writing theme of each writing paragraph, and the writing order between each writing paragraph; repeating the following process until all the writing paragraphs are completed to obtain a target document: the writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content according to the writing theme of the current writing paragraph, and sends the first content to the review agent; the review agent performs a quality review on the first content and determines whether the current writing paragraph is completed based on the review result.

[0063] In another aspect, the present invention also provides a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements a document generation method based on a multi-agent large model system provided by the methods described above. The method includes: the planning agent generating a writing outline based on an acquired writing task, and sending the writing outline to the writing agent; wherein the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between the writing paragraphs; repeating the following process until all the writing paragraphs are completed to obtain a target document: the writing agent determining the current writing paragraph from the writing paragraphs according to the writing order, generating first content based on the main idea of ​​the current writing paragraph, and sending the first content to the review agent; the review agent performing a quality review on the first content, and determining whether the current writing paragraph is complete based on the review result.

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

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

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

Claims

1. A document generation method based on a multi-agent large model system, characterized in that, The multi-agent large model system includes a planning agent, a writing agent, and a reviewing agent, including: The planning agent generates a writing outline based on the acquired writing task and sends the writing outline to the writing agent; wherein, the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between each writing paragraph. Repeat the following process until all the written paragraphs are completed, resulting in the target document: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content according to the writing theme of the current writing paragraph, and sends the first content to the review agent. The review agent performs a quality review on the first content and determines whether to complete the current writing paragraph based on the review results.

2. The document generation method based on a multi-agent large model system according to claim 1, characterized in that, Also includes: Utilize interactive pages to receive writing requests from users; The planning agent generates a writing task based on a correlation analysis of at least one target field included in the writing request. The correlation analysis includes at least one of the following: scene location, job matching, intent recognition, material retrieval, and style matching.

3. The document generation method based on a multi-agent large model system according to claim 1, characterized in that, The planning agent generates a writing outline based on the acquired writing task, and sends the writing outline to the writing agent, including: The planning agent generates a first writing outline based on the acquired writing task and displays the first writing outline to the user through an interactive page. In response to the user triggering the editing function on the interactive page, the system obtains the second writing outline after the user has finished editing and sends the second writing outline to the writing agent.

4. The document generation method based on a multi-agent large model system according to claim 1, characterized in that, The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, and generates first content based on the writing theme of the current writing paragraph, including: The writing agent determines the current writing paragraph from among the multiple writing paragraphs according to the writing order; Obtain the writing tags corresponding to the current writing paragraph; wherein the writing tags include at least one of the following: style tags, logic tags, and constraint tags; The first content is generated based on the main idea of ​​the current writing paragraph and the writing tags.

5. The document generation method based on a multi-agent large model system according to claim 1, characterized in that, The review agent performs a quality review on the first content and determines whether the current writing paragraph is completed based on the review result, including: If the review result indicates that the review is not approved, modification suggestions are generated and fed back to the writing agent so that the writing agent can regenerate the first content. If the review result indicates that the review has passed, complete the current writing paragraph.

6. The document generation method based on a multi-agent large model system according to claim 1, characterized in that, The multi-agent large model system also includes an optimized agent; After generating the first content based on the writing theme of the current writing paragraph, the writing agent sends the first content to the optimization agent. The optimization agent optimizes the first content to obtain the second content, and sends the second content to the review agent so that the review agent can perform quality review based on the second content.

7. The document generation method based on a multi-agent large model system according to claim 6, characterized in that, After obtaining the target document, the following is also included: The target document is displayed using an interactive page; In response to a user making modification annotations to the target document using an interactive page, the modification annotations are sent to the optimization agent so that the optimization agent optimizes the target document based on the modification annotations.

8. A document generation device based on a multi-agent large model system, characterized in that, The multi-agent large model system includes a planning agent, a writing agent, and a reviewing agent, including: The outline writing module is used to generate a writing outline based on the acquired writing task using the planning agent, and send the writing outline to the writing agent; wherein, the writing outline indicates multiple writing paragraphs, the main idea of ​​each writing paragraph, and the writing order between the writing paragraphs. The writing module is used to repeatedly execute the following process until all the writing paragraphs are completed, resulting in the target document: The writing agent determines the current writing paragraph from the writing paragraphs according to the writing order, generates first content based on the writing theme of the current writing paragraph, and sends the first content to the review agent. The review agent is used to review the quality of the first content, and the current writing paragraph is determined based on the review results.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the document generation method based on a multi-agent large model system as described in any one of claims 1 to 7.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the document generation method based on a multi-agent large model system as described in any one of claims 1 to 7.