Method, device, electronic device and storage medium for generating a presentation document

By automatically generating presentation document outlines and content, and combining deep learning models and chart/image data, the problem of low efficiency in generating presentation documents in existing technologies has been solved, achieving efficient and aesthetically pleasing presentation document generation.

CN116306492BActive Publication Date: 2026-03-27BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-27
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

The process of generating presentation documents in the existing technology is inefficient, requires a lot of work from users, and necessitates the collection and editing of a large amount of materials, resulting in low writing efficiency.

Method used

By responding to the input text, the presentation document outline is determined, the target layout is selected based on the attribute information of the chapter content text, and the presentation document is generated. The initial outline and content text are automatically generated using a deep learning model, and the generation process of the presentation document is optimized by combining charts and image data.

Benefits of technology

It improves the efficiency of creating presentation documents, reduces the workload for users, and generates aesthetically pleasing documents suitable for scenarios such as business presentations and course sharing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116306492B_ABST
    Figure CN116306492B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method and device for generating a presentation document, an electronic device and a storage medium, relating to the technical field of artificial intelligence, in particular to the field of natural language processing. The specific implementation scheme is: in response to receiving an input text, determining a presentation document outline according to the input text; determining a chapter content text according to the presentation document outline; determining a target format from a plurality of predetermined formats according to attribute information of the chapter content text; and generating a presentation document according to the chapter content text and the target format.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of artificial intelligence, in particular to the field of natural language processing, and more particularly, the present disclosure provides a method, an apparatus, an electronic device, a storage medium and a computer program product for generating a presentation document. BACKGROUND

[0002] In the scenarios of business speeches, course sharing, etc., a user sometimes needs to make a presentation document. In the actual making process, the user needs to collect a large amount of original materials such as texts and pictures, and also needs to make contents such as charts and flowcharts according to actual needs, search for appropriate images in the network, and edit the above-mentioned original materials, charts, flowcharts, images and other information into a presentation document. It can be seen that, by using the above-mentioned making process, the writing efficiency of the presentation document is low, and the workload of the user is large. SUMMARY

[0003] The present disclosure provides a method, an apparatus, an electronic device, a storage medium and a computer program product for generating a presentation document.

[0004] According to an aspect of the present disclosure, a method for generating a presentation document is provided, comprising: in response to receiving an input text, determining a presentation document outline according to the input text; determining a chapter content text according to the presentation document outline; determining a target format from a plurality of predetermined formats according to attribute information of the chapter content text; and generating a presentation document according to the chapter content text and the target format.

[0005] According to another aspect of the present disclosure, an apparatus for generating a presentation document is provided, comprising: a first determining module, a second determining module, a third determining module and a production module. The first determining module is configured to determine a presentation document outline according to an input text in response to receiving the input text. The second determining module is configured to determine a chapter content text according to the presentation document outline. The third determining module is configured to determine a target format from a plurality of predetermined formats according to attribute information of the chapter content text. The production module is configured to generate a presentation document according to the chapter content text and the target format.

[0006] According to another aspect of the present disclosure, an electronic device is provided, comprising: at least one processor; and a memory connected with the at least one processor in communication; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method provided by the present disclosure.

[0007] According to another aspect of the present disclosure, a non-transitory computer readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable a computer to perform the method provided by the present disclosure.

[0008] According to another aspect of the present disclosure, there is provided a computer program product comprising a computer program which, when executed by a processor, implements the method provided by the present disclosure.

[0009] It should be understood that the contents described in this part are not intended to identify key or important features of the embodiments of the present disclosure, nor to limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS

[0010] The accompanying drawings are used to better understand the present scheme, and do not constitute a limitation on the present disclosure. Among them:

[0011] Figure 1 is an application scenario diagram of the method and device for generating a presentation document according to an embodiment of the present disclosure;

[0012] Figure 2 is a schematic flowchart of the method for generating a presentation document according to an embodiment of the present disclosure;

[0013] Figure 3 is a schematic diagram of the method for generating a presentation document according to another embodiment of the present disclosure;

[0014] Figure 4 is a schematic flowchart of the method for determining an initial presentation document outline according to an embodiment of the present disclosure;

[0015] Figure 5 is a schematic flowchart of the method for chapter content text according to an embodiment of the present disclosure;

[0016] Figure 6 is a schematic structural block diagram of the device for generating a presentation document according to an embodiment of the present disclosure; and

[0017] Figure 7 is a structural block diagram of an electronic device for implementing the method for generating a presentation document according to an embodiment of the present disclosure. DETAILED DESCRIPTION

[0018] Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, which include various details of the embodiments of the present disclosure to help understanding, and should be considered as merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Also, in order to be clear and concise, the description below omits the description of well-known functions and structures.

[0019] Figure 1 is an application scenario diagram of the method and device for generating a presentation document according to an embodiment of the present disclosure.

[0020] It should be noted that Figure 1 The system architecture shown is merely an example of a system architecture to which the embodiments of the present disclosure can be applied, to help those skilled in the art understand the technical content of the present disclosure, but does not mean that the embodiments of the present disclosure cannot be used in other devices, systems, environments or scenarios.

[0021] As Figure 1 shown, the system architecture 100 according to this embodiment can include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is a medium for providing a communication link between the terminal devices 101, 102, 103 and the server 105. The network 104 can include various connection types, such as wired and / or wireless communication links, etc.

[0022] The user can use the terminal devices 101, 102, 103 to interact with the server 105 through the network 104 to receive or send messages, etc. The terminal devices 101, 102, 103 can be various electronic devices with a display screen and supporting web browsing, including but not limited to smartphones, tablet computers, laptop computers and desktop computers, etc.

[0023] The server 105 can be a server providing various services, such as a background management server (only as an example) providing support for the website browsed by the user using the terminal devices 101, 102, 103. The background management server can analyze and process the received user request data, etc., and feed back the processing result (such as a presentation document generated according to the input text of the user, etc.) to the terminal device.

[0024] It should be noted that the method for generating a presentation document provided by the embodiments of the present disclosure can generally be executed by the server 105. Accordingly, the apparatus for generating a presentation document provided by the embodiments of the present disclosure can generally be arranged in the server 105. The method for generating a presentation document provided by the embodiments of the present disclosure can also be executed by a server or a server cluster different from the server 105 and capable of communicating with the terminal devices 101, 102, 103 and / or the server 105. Accordingly, the apparatus for generating a presentation document provided by the embodiments of the present disclosure can also be arranged in a server or a server cluster different from the server 105 and capable of communicating with the terminal devices 101, 102, 103 and / or the server 105.

[0025] It should be understood that Figure 1 the number of terminal devices, networks and servers in may be merely illustrative. According to the needs of implementation, there can be any number of terminal devices, networks and servers.

[0026] Figure 2 is a schematic flowchart of the method for generating a presentation document according to the embodiments of the present disclosure.

[0027] As Figure 2 shown, the method 200 of generating a presentation document can include operation S210 to operation S240.

[0028] In operation S210, in response to receiving input text, a presentation document outline is determined according to the input text.

[0029] For example, a user can perform an input operation on a front-end page, and the electronic device can take the information input by the user as input text. The input text can be processed for entity recognition, element extraction, word segmentation, etc., to obtain keywords in the input text. The correspondence between the keywords and the presentation document outline can be pre-configured, and then the presentation document outline corresponding to the keywords is searched.

[0030] In operation S220, according to the presentation document outline, a chapter content text is determined.

[0031] For example, the presentation document outline can include multiple title information, a piece of text related to each title can be generated for each title information, and then multiple pieces of text related to multiple title information are determined as the chapter content text.

[0032] In operation S230, according to the attribute information of the chapter content text, a target format is determined from multiple predetermined formats.

[0033] For example, the attribute information of the chapter content text includes at least one of the following: the category of the chapter content text, the length of the chapter content text, and the structure of the chapter content text. The category of the chapter content text can include industry categories, such as sports, tourism, food, etc.

[0034] For example, multiple predetermined formats can be pre-configured, and the category (such as the industry category) applicable to each predetermined format, the applicable length, and the format category to which it belongs can be configured. For example, a certain predetermined format is applicable to short chapter content of the sports industry, and the format category to which the predetermined format belongs is “left picture right text format”.

[0035] For example, if the category of the chapter content text is consistent with the category applicable to the predetermined format, and the length of the chapter content text is consistent with the length applicable to the predetermined format, the predetermined format can be determined as the target format. In addition, the user can specify the category of the target format, for example, the user specifies the “simple style” format, and the target format can be filtered from the predetermined format of the simple style.

[0036] In operation S240, according to the chapter content text and the target format, a presentation document is generated.

[0037] For example, a plurality of display regions can be configured in advance for a predetermined template, each display region corresponding to attribute information, the attribute information of the display region can include what kind of element the display region is used to display, for example, a certain display region is used to display an image, and another display region is used to display text. The attribute information of the display region can also include font size, font, color, line spacing, etc. in each display region.

[0038] For example, the chapter text content can be filled into the target template according to the attribute information of each display region in the target template, so as to obtain the presentation document.

[0039] The embodiments of the present disclosure can generate a presentation document outline according to the input text of the user, then generate chapter content text based on the presentation document outline, and generate a presentation document based on the chapter content text and the target template, so as to improve the efficiency of compiling the presentation document and reduce the workload of the user.

[0040] Figure 3 is a schematic diagram of a method for generating a presentation document according to another embodiment of the present disclosure.

[0041] As shown in Figure 3 In this embodiment, the method for generating a presentation document involves a client 310 and a server 320, and the method for generating a presentation document in this embodiment will be described in detail below.

[0042] The user can perform an input operation on the front-end page, and then the client 310 obtains the input text input by the user based on the front-end page, and sends a first request for generating a presentation document to the client 310, the first request including the input text.

[0043] After the server 320 receives the first request, the server 320 parses the first request and generates an initial presentation document outline based on the input text in the first request, and then outputs the initial presentation document outline to the client 310.

[0044] The client displays the received initial presentation document outline, and the user can manually adjust the initial presentation document outline on the front-end page, and the client 310 can generate a second request based on the adjustment operation of the user and send the second request to the server 320. The second request can include a modification instruction, and the modification instruction can include a modification method of the initial presentation document outline or a modification result of the initial presentation document outline.

[0045] After receiving the second request, the server 320 parses the second request to obtain the modification instruction. Then, the server 320 modifies the initial presentation document outline based on the modification instruction in the second request, for example, the server 320 modifies the initial presentation document outline according to the modification manner in the modification instruction, and for another example, the server 320 replaces the initial presentation document outline with the modification result in the modification instruction, and obtains the presentation document outline after modification. In this embodiment, the user can calibrate during the generation of the presentation document, and manually intervene in the initial presentation document outline according to actual needs, so as to improve the generation quality of the content of the presentation document, and make the generated presentation document more consistent with the user's expectation.

[0046] It should be noted that in other examples, after generating the initial presentation document outline, the server 320 can omit the operations of outputting the initial presentation document outline by the server 320, displaying the initial presentation document outline by the client 310, and manually modifying the initial presentation document outline by the user, and the server 320 can directly use the initial presentation document outline as the presentation document outline.

[0047] Next, the server 320 can also determine the chapter text content according to the presentation document outline. The server 320 can also determine the chart, image data and target format according to the chapter text content, and generate the presentation document based on the chapter text content, the chart, the image data and the target format, and send the presentation document to the client 310. By adapting the appropriate target format to the chapter text content, the elements such as text, image and report can be reasonably and beautifully displayed. It should be noted that the order of determining the chart, image data and target format by the server 320 is not limited in this embodiment.

[0048] The client 310 can display the presentation document, and in addition, if the user inputs the conversion instruction, the server 320 can also extract the text content in the presentation document, and convert the text content into images such as flowchart and relationship diagram, to optimize the display effect of the presentation document.

[0049] This embodiment can encapsulate the content format of the presentation document, and the generated presentation document not only includes pure text type content, but also includes elements such as chart and image data, and the elements are arranged according to the target format in the generated presentation document, so as to improve the aesthetic degree of the content of the presentation document, and the user can directly apply the generated presentation document to the scene of business speech, course sharing and the like.

[0050] In actual application, a client plug-in can be developed for a user to install into a local client. When in use, the user can open a presentation document software for editing content to generate a presentation document. Then the plug-in is loaded and some input text is input through the plug-in, so as to automatically generate a presentation document, thereby achieving the effect of improving the presentation document writing efficiency and reducing the user workload. In addition, after the user integrates the plug-in in the presentation document software, the user can directly use the presentation document software without using other additional software. It can be seen that the generation and editing of the presentation document are completed in the same client software, which can solve the problem of complicated operation of file export and import due to the use of multiple software, improve the user's interactive experience, and realize the end-to-end encapsulation of the presentation document generation technology.

[0051] Figure 4 is a schematic flowchart of a method for determining an initial presentation document outline according to an embodiment of the present disclosure.

[0052] As Figure 4 shown, the following describes the process of determining an initial presentation document outline. In the present embodiment, the method 410 for determining an initial presentation document outline according to input text described above can include operation S411 to operation S414.

[0053] In operation S411, intent information is determined according to the input text.

[0054] For example, intent recognition can be performed on the input text to determine the intent information. For example, the input text is "generate a presentation document of Beijing tourism introduction", and the intent information can include "Beijing", "tourism", etc.

[0055] In operation S412, a first target template is determined from a plurality of intent context templates according to the category of the intent information.

[0056] For example, the category of the intent information can include an industry category, such as sports, tourism, food, etc. The category of the intent information can be the same as the category of the chapter content text.

[0057] For example, a plurality of intent context templates and a corresponding relationship between the intent context templates and the category of the intent information can be pre-configured. Therefore, after the category of the intent information is determined, the first target template can be determined based on the corresponding relationship.

[0058] In operation S413, the intent information and the first target template are combined to obtain a first prompt text Prompt_1.

[0059] For example, the intent context template can be a piece of natural language containing several texts, and a predetermined position in the intent context template is in a vacancy state. The intent information is filled into the predetermined position in the vacancy state in the first target template, so as to combine the intent information and the first target template into the first prompt information.

[0060] In operation S414, the initial presentation document outline is determined according to the first prompt text Prompt_l.

[0061] For example, the first prompt text Prompt_1 can be input into a deep learning model, and the deep learning model outputs the initial presentation document outline. The deep learning model can be a pre-trained language model, and the embodiments of the present disclosure do not limit the deep learning model.

[0062] The embodiments of the present disclosure use the above operations S411-S414, which can adjust the intent information into the first prompt information by using the first target template. The first target template can be configured according to actual needs. Compared with the intent information, the first prompt information is closer to the training sample used in the training process of the language model, so that the language model can obtain the initial presentation document outline with more accurate content based on the first prompt information, so that the generated initial outline of the presentation document is more in line with the needs of the user.

[0063] Figure 5 is a schematic flowchart of a method for determining a chapter content text according to an embodiment of the present disclosure.

[0064] As shown in Figure 5 The embodiments of the present disclosure illustrate the process of determining a chapter content text. In the embodiments, the above method 520 for determining a chapter content text according to a presentation document outline can include operations S521-S524.

[0065] In operation S521, intent information is determined according to input text.

[0066] For example, intent recognition can be performed on the input text to determine the intent information. For example, if the intent information has been determined in the process of determining the initial presentation document outline, the operation S521 can be omitted.

[0067] In operation S522, a second target template is determined from a plurality of outline context templates according to the category of the intent information.

[0068] For example, a plurality of outline context templates and a corresponding relationship between the outline context templates and the category of the intent information can be pre-configured. Therefore, after the category of the intent information is determined, the second target template can be determined based on the corresponding relationship.

[0069] In operation S523, the presentation document outline and the second target template are combined to obtain a second prompt text Prompt_2.

[0070] For example, the outline context template can be a piece of natural language containing several texts, and a predetermined position in the outline context template is in a vacancy state. The presentation document outline is filled into the predetermined position in the second target template in the vacancy state, so that the presentation document outline and the second target template are combined into the second prompt information Prompt_2.

[0071] In operation S524, according to the second prompt text Prompt_2, a chapter content text is determined.

[0072] For example, the second prompt text Prompt_2 can be input into a deep learning model, and the deep learning model outputs the chapter content text. The deep learning model can be a pre-trained language model, such as a text-to-text model, and the present disclosure does not limit the deep learning model.

[0073] In this embodiment, the presentation document outline is adjusted into the second prompt information by using the second target template. Compared with the presentation document outline, the second prompt information is closer to the training sample used in the training process of the text-to-text model, so that the text-to-text model can obtain the chapter content text with more accurate content based on the second prompt information.

[0074] In another embodiment of the present disclosure, after the chapter content text is determined, a chart can also be determined based on the chapter content text. The process of determining the chart is described below.

[0075] For example, the process of determining the chart can include: in response to detecting that the chapter content text includes a plurality of data elements, the data elements can include texts of a numerical category, a plurality of key-value pairs can be extracted from the chapter content text, each key-value pair includes a key name and a key value, and the key value can include texts of a numerical category. Next, the chart can be determined according to the plurality of key-value pairs.

[0076] For example, if a plurality of key names in the plurality of key-value pairs are numerical categories, at least one of a column chart and a line chart can be generated according to the plurality of key-value pairs. For example, the chapter content text includes “The number of tourists in a certain region in 2020 is 1 million, the number of tourists in 2021 is 1.1 million, and the number of tourists in 2022 is 1.3 million”, and the extracted “key name-key value” (i.e., key-value pair) can include “2020-1 million”, “2021-1.1 million”, and “2023-1.3 million”. Since the key names in the key-value pairs include numerical category data, and the numerical category data conforms to an arithmetic progression or other predetermined rules, a column chart or a line chart can be generated based on the above key-value pairs.

[0077] For example, if the multiple key names in the multiple key-value pairs are non-numeric categories, a pie chart can be generated according to the multiple key-value pairs. For example, the text of the chapter content includes "the number of business department is 10, the number of sales department is 25, and the number of process department is 5". The extracted "key name-key value" (i.e., key-value pair) can include "business department-10", "sales department-25", and "process department-5". Since the key name is a non-numeric category and the text of the key name has some language meaning, a pie chart can be generated based on the above key-value pairs.

[0078] After generating the chart, a presentation document can be generated based on the chart, for example, the chart is displayed in the presentation document, so that the relevant data in the presentation document is more intuitive, and the display effect of the presentation document is optimized.

[0079] In another embodiment of the present disclosure, image data matching the chapter content text can also be determined after the chapter content text is determined. Matching can mean that the information described by the image data is consistent with the information described by the chapter content text. The process of determining the image data is described below.

[0080] For example, named entity recognition, key element extraction, and other processing can be performed on the chapter content text to obtain keywords in the chapter content. The correspondence between the keywords and the image data can be pre-set, and then the image data corresponding to the key elements can be found based on the correspondence.

[0081] For another example, the chapter content text can be input into a deep learning model, and the deep learning model outputs image data. The deep learning model can be a pre-trained text-to-image model, for example, ERNIE (Enhanced Language Representation with Informative Entities). The deep learning model is not limited in the embodiments of the present disclosure.

[0082] The embodiments of the present disclosure can also automatically generate image data based on the chapter content text, and the image data can be newly generated images, without the need for users to purchase additional copyright materials, reducing the cost of users. After generating the image data, a presentation document can be generated based on the image data, for example, the image data is displayed in the presentation document, thereby enriching the content display effect of the presentation document.

[0083] It should be noted that in actual application, the above embodiments can be combined with each other, for example, a generative model such as text-to-text or text-to-image can be used to generate the content of the presentation document, instead of performing secondary processing based on the original material provided by the user, which includes, for example, abstract generation, element extraction, structured data matching, etc. Therefore, the method provided by the embodiments of the present disclosure can generate a presentation document based on a small amount of input text without the need for the user to provide a large amount of original material.

[0084] Figure 6 is a schematic structural block diagram of a device for generating a presentation document according to an embodiment of the present disclosure.

[0085] As shown in Figure 6 , the device 600 for generating a presentation document can include a first determination module 610, a second determination module 620, a third determination module 630, and a production module 640.

[0086] The first determination module 610 is configured to determine a presentation document outline according to the input text in response to receiving the input text. In an embodiment, the first determination module 610 can be configured to perform the operation S210 described above, and details are not repeated here.

[0087] The second determination module 620 is configured to determine a chapter content text according to the presentation document outline. In an embodiment, the second determination module 620 can be configured to perform the operation S220 described above, and details are not repeated here.

[0088] The third determination module 630 is configured to determine a target format from a plurality of predetermined formats according to the attribute information of the chapter content text. The third determination module 630 can be configured to perform the operation S230 described above, and details are not repeated here.

[0089] The production module 640 is configured to generate a presentation document according to the chapter content text and the target format. In an embodiment, the production module 640 can be configured to perform the operation S240 described above, and details are not repeated here.

[0090] According to another embodiment of the present disclosure, the first determination module includes a first determination submodule, a second determination submodule, a first combination submodule, and a third determination submodule. The first determination submodule is configured to determine intent information according to the input text. The second determination submodule is configured to determine a first target template from a plurality of intent context templates according to the category of the intent information. The first combination submodule is configured to combine the intent information and the first target template to obtain a first prompt text. The third determination submodule is configured to determine a presentation document outline according to the first prompt text.

[0091] According to another embodiment of the present disclosure, the third determining sub-module comprises a determining unit, an output unit and a modifying unit. The determining unit is configured to determine an initial presentation document outline according to the first prompt text. The output unit is configured to output the initial presentation document outline. The modifying unit is configured to modify the initial presentation document outline according to a modifying instruction received for the initial presentation document outline, to obtain the presentation document outline.

[0092] According to another embodiment of the present disclosure, the second determining module comprises a fourth determining sub-module, a fifth determining sub-module, a second combining sub-module and a sixth determining sub-module. The fourth determining sub-module is configured to determine the intention information according to the input text. The fifth determining sub-module is configured to determine the second target template from the plurality of outline context templates according to the category of the intention information. The second combining sub-module is configured to combine the presentation document outline and the second target template to obtain the second prompt text. The sixth determining sub-module is configured to determine the chapter content text according to the second prompt text.

[0093] According to another embodiment of the present disclosure, the attribute information of the chapter content text comprises at least one of a category of the chapter content text and a length of the chapter content text.

[0094] According to another embodiment of the present disclosure, the apparatus further comprises an extracting module and a fourth determining module. The extracting module is configured to, after determining the chapter content text, extract a plurality of key-value pairs from the chapter content text in response to detecting that the chapter content text comprises a plurality of numerical category texts, wherein a key value in each key-value pair comprises a numerical category text. The fourth determining module is configured to determine a graph according to the plurality of key-value pairs.

[0095] According to another embodiment of the present disclosure, the fourth determining module comprises a first generating sub-module and a second generating sub-module. The first generating sub-module is configured to, in response to detecting that a plurality of key names in the plurality of key-value pairs are numerical categories, generate at least one of a column chart and a line chart according to the plurality of key-value pairs. The second generating sub-module is configured to, in response to detecting that a plurality of key names in the plurality of key-value pairs are non-numerical categories, generate a pie chart according to the plurality of key-value pairs.

[0096] According to another embodiment of the present disclosure, the apparatus further comprises a fifth determining module configured to, after determining the chapter content text, determine image data matched with the chapter content text according to the chapter content text.

[0097] In the technical solution of the present disclosure, the collection, storage, use, processing, transmission, provision and disclosure of user personal information involved in the technical solution of the present disclosure all comply with relevant laws and regulations and do not violate public order and good customs.

[0098] In the technical solution of the present disclosure, the authorization or consent of the user is obtained before the user's personal information is acquired or collected.

[0099] According to an embodiment of the present disclosure, the present disclosure further provides an electronic device, comprising at least one processor; and a memory connected with the at least one processor in communication; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method for generating a presentation document.

[0100] According to an embodiment of the present disclosure, the present disclosure further provides a non-transitory computer readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to perform the method for generating a presentation document.

[0101] According to an embodiment of the present disclosure, the present disclosure further provides a computer program product comprising a computer program, wherein the computer program, when executed by a processor, implements the method for generating a presentation document.

[0102] Figure 7 is a structural block diagram of an electronic device for implementing the method for generating a presentation document according to an embodiment of the present disclosure. The electronic device is intended to represent various forms including a laptop computer, a desktop computer, a workstation, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device can also represent various forms of mobile devices such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections, and relationships, and their functions, are meant only as examples, and are not meant to limit implementations of the present disclosure described and / or claimed in this document.

[0103] As shown in Figure 7 , the device 700 includes a computing unit 701 that can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 702 or a computer program loaded into a random access memory (RAM) 703 from a storage unit 708. In the RAM 703, various programs and data required for the operation of the device 700 can also be stored. The computing unit 701, the ROM 702, and the RAM 703 are connected to each other through a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.

[0104] Various components in the device 700 are connected to the I / O interface 705, including an input unit 706 such as a keyboard, a mouse, etc., an output unit 707 such as various types of displays, a speaker, etc., a storage unit 708 such as a magnetic disk, an optical disk, etc., and a communication unit 709 such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 709 allows the device 700 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunications networks.

[0105] The computing unit 701 can be various general and / or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various specialized artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 701 performs various methods and processes described above, such as the method of generating a presentation document. For example, in some embodiments, the method of generating a presentation document can be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 708. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 700 via the ROM 702 and / or the communication unit 709. When the computer program is loaded onto the RAM 703 and executed by the computing unit 701, one or more steps of the method of generating a presentation document described above can be performed. Alternatively, in other embodiments, the computing unit 701 can be configured to perform the method of generating a presentation document by any other suitable means, such as by means of firmware.

[0106] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a complex programmable logic device (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0107] Program code for carrying out methods of the present disclosure can be written in any combination of one or more programming languages. The program code can be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the program code, when executed by the processor or controller, produces a means for implementing the functions / acts specified in the flowcharts and / or block diagrams. The program code can be executed entirely on a machine, partially on a machine, partially on a machine as a stand-alone software package, partially on a machine and partially on a remote machine or entirely on a remote machine or server.

[0108] In the context of this disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include but is not limited to an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0109] To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0110] The systems and techniques described here can be implemented in a computing system that includes a back end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front end component (e.g., a user computer having a graphical user interface or a Web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0111] The computing system can include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.

[0112] It should be understood that the various forms of flow shown above can be used to reorder, add, or remove steps. For example, the steps described in the present disclosure can be performed in parallel, in series, or in a different order, as long as the desired results of the technology disclosed in the present disclosure are achieved, which is not limited herein.

[0113] The specific implementation described above does not constitute a limitation on the protection scope of the present disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent replacements, and improvements made within the spirit and principles of the present disclosure shall be included in the protection scope of the present disclosure.

Claims

1. A method for generating a presentation document, comprising: In response to receiving input text, determining a presentation document outline based on the input text includes: determining intent information based on the input text; determining a first target template from multiple intent context templates based on the category of the intent information; combining the intent information and the first target template to obtain a first prompt text; and determining the presentation document outline based on the first prompt text. Determining the chapter content text based on the presentation document outline includes: determining a second target template from multiple outline context templates based on the category of the intent information; combining the presentation document outline and the second target template to obtain a second prompt text; and determining the chapter content text based on the second prompt text. Based on the attribute information of the text content, a target layout is determined from multiple predetermined layouts; the attribute information of the text content includes at least one of the following: the category of the text content and the length of the text content; and A presentation document is generated based on the text content of the chapter and the target layout.

2. The method according to claim 1, wherein, Determining the presentation document outline based on the first prompt text includes: Based on the first prompt text, determine the initial presentation document outline; Output the initial presentation document outline; and In response to receiving a modification instruction for the initial presentation document outline, the initial presentation document outline is modified according to the modification instruction to obtain the presentation document outline.

3. The method according to any one of claims 1 to 2, further comprising: After determining the text content of the chapter In response to detecting that the text content includes text with multiple numeric categories, multiple key-value pairs are extracted from the text content, wherein the key value in each key-value pair includes text with numeric categories; as well as The graph is determined based on the multiple key-value pairs.

4. The method according to claim 3, wherein, The step of determining the chart based on the multiple key-value pairs includes: In response to detecting that multiple key names in the plurality of key-value pairs are of the numeric category, at least one of a bar chart and a line chart is generated based on the plurality of key-value pairs; and In response to the detection that multiple key names in the plurality of key-value pairs are non-numeric categories, a pie chart is generated based on the plurality of key-value pairs.

5. The method according to any one of claims 1 to 2, further comprising: After determining the text content of the chapter Based on the text content of the chapter, determine the image data that matches the text content of the chapter.

6. An apparatus for generating a presentation document, comprising: The first determining module is used to determine the outline of the presentation document based on the input text received in response to the input text. The second determining module is used to determine the text content of the chapters based on the outline of the presentation document; The third determining module is used to determine the target layout from multiple predetermined layouts based on the attribute information of the chapter content text; the attribute information of the chapter content text includes at least one of the following: the category of the chapter content text and the length of the chapter content text; as well as The production module is used to generate a presentation document based on the text content of the chapter and the target layout; The first determining module includes: The first determining submodule is used to determine intent information based on the input text; The second determining submodule is used to determine a first target template from multiple intent context templates based on the category of the intent information; A first combination submodule is used to combine the intent information and the first target template to obtain a first prompt text; and The third determining submodule is used to determine the outline of the presentation document based on the first prompt text; The second determining module includes: The fifth determining submodule is used to determine a second target template from multiple outline context templates based on the category of the intent information; The second combination submodule is used to combine the presentation document outline and the second target template to obtain the second prompt text; and The sixth determination submodule is used to determine the chapter content text based on the second prompt text.

7. The apparatus according to claim 6, wherein, The third determining submodule includes: The determining unit is used to determine the initial presentation document outline based on the first prompt text; Output unit, used to output the initial presentation document outline; and The modification unit is configured to respond to receiving a modification instruction for the initial presentation document outline, modify the initial presentation document outline according to the modification instruction, and obtain the presentation document outline.

8. The apparatus according to any one of claims 6 to 7, further comprising: An extraction module is configured to, after determining the text content, extract multiple key-value pairs from the text content in response to detecting that the text content includes text of multiple numeric categories, wherein the key value in each key-value pair includes text of numeric categories; as well as The fourth determination module is used to determine the chart based on the multiple key-value pairs.

9. The apparatus according to claim 8, wherein, The fourth determining module includes: A first generation submodule is configured to, in response to detecting that multiple key names among the multiple key-value pairs are numeric categories, generate at least one of a bar chart and a line chart based on the multiple key-value pairs; and The second generation submodule is used to generate a pie chart based on the multiple key-value pairs in response to detecting that multiple key names in the multiple key-value pairs are of the non-numeric category.

10. The apparatus according to any one of claims 6 to 7, further comprising: The fifth determining module is used to determine image data that matches the text content after determining the text content.

11. An electronic device, comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 5.

12. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1 to 5.

13. A computer program product comprising a computer program that, when executed by a processor, implements the method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Powerpoint generation method, apparatus and device

    CN110489735A

  • Powerpoint generation method and device, computer equipment and storage medium

    CN111881307A