Program for generating explanatory text for drawings, and device for generating explanatory text for drawings.
The program addresses the challenge of generating accurate natural language descriptions for complex diagrams by converting drawings to Mermaid notation and then to text, enhancing the efficiency and quality of explanatory text generation.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- 绫木 健一郎
- Filing Date
- 2024-11-20
- Publication Date
- 2026-06-01
AI Technical Summary
Existing AI systems struggle to generate accurate natural language descriptions of complex flowcharts and diagrams, often omitting explanations of branches and loops due to inherent ambiguity in natural language processing, and require manual conversion from drawings to text format definitions, which is not labor-saving.
A drawing description generation program that utilizes a two-step process involving conversion of drawings to Mermaid notation text and then to natural language, using prompts to guide a generative AI system for accurate and detailed explanations.
Generates accurate and detailed explanatory text from drawings, reducing manual labor and improving the quality of descriptions for complex diagrams.
Smart Images

Figure 2026089175000001_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a drawing description generation program and a drawing description generation device.
Background Art
[0002] With the recent development of AI technology, it has been proposed to support the generation of various contents with the assistance of generative AI. For example, Patent Document 1 describes an invention that suppresses variations in the quality when creating claims or reduces the time required for preparing a patent application manuscript including claims. Thus, many techniques for humans to create sentences are being implemented with the assistance of generative AI.
[0003] Patent Document 2 describes an invention for assisting in creating an explanation regarding an invention, which simplifies the creation of the explanation. Patent Document 2 generates the explanation from a text format definition using a predetermined syntax that defines a drawing representing the invention.
Prior Art Documents
Patent Documents
[0004]
Patent Document 1
Patent Document 2
Summary of the Invention
Problems to be Solved by the Invention
[0005] In the invention described in Patent Document 2, a drawing description is generated from a text format definition regarding the drawing, rather than from the drawing itself. However, in actual cases of creating a description, the drawing itself is often provided. In such a case, a person has to manually describe a text format definition regarding the drawing from the drawing, and there is a problem that it is not much more labor-saving than the case where a person describes a drawing description.
[0006] Furthermore, generative AIs such as OpenAI's ChatGPT (registered trademark) and Google's Gemini can accept images and, in the case of simple flowcharts, generate natural language descriptions of the images to a certain extent by providing prompts related to those images. However, with flowcharts containing complex branches and loops, they often fail to generate descriptive text effectively, frequently omitting explanations of branches and loops. This is likely due to the inherent ambiguity of natural language. Therefore, the object of the present invention is to generate explanatory text relating to a drawing from that drawing. [Means for solving the problem]
[0007] In other words, the above-mentioned problems of the present invention are solved by the following configuration. The present invention provides a drawing description generation program that causes a computer to perform the following steps: input a first prompt to a generation AI that includes an instruction to convert the drawing into text in a predetermined Markdown notation, and obtain a first response from the generation AI that includes text written in the predetermined Markdown notation; extract text written in the predetermined Markdown notation from the first response; and input a second prompt to the generation AI that includes an instruction to generate the text and the drawing description, and obtain a second response from the generation AI that includes the drawing description.
[0008] The present invention provides a drawing description generation program that causes a computer to input prompts including instructions to convert a drawing into text in a predetermined Markdown notation, and instructions to generate a drawing description from the text, and to perform the following steps: obtain a response including text written in the predetermined Markdown notation and a description of the text; extract text written in the predetermined Markdown notation from the response; and extract a drawing description from the response. Other configurations will be explained in the respective embodiments. [Effects of the Invention]
[0009] According to the present invention, it is possible to generate explanatory text relating to a drawing from that drawing. [Brief explanation of the drawing]
[0010] [Figure 1] This is a logical configuration diagram showing the explanatory text generation device according to the first embodiment. [Figure 2] This is a hardware configuration diagram showing the explanatory text generation device. [Figure 3] This is the screen displayed by the explanatory text generator. [Figure 4] This is a flowchart of the process for generating explanatory text. [Figure 5] This diagram shows the request sent to the generation AI system. [Figure 6] This is a diagram illustrating the content of the first prompt. [Figure 7] This diagram shows chat completion objects received from the generation AI system. [Figure 8] This is a diagram illustrating the content of the responses included in the chat completion object. [Figure 9] This figure shows the JSON data of the request sent to the generation AI system. [Figure 10] This is a diagram illustrating the content of the second prompt. [Figure 11] This figure shows the JSON data of the chat completion object received from the generation AI system. [Figure 12] This is a diagram illustrating an example of an explanatory text. [Figure 13] This is a logical configuration diagram showing the explanatory text generation device according to the second embodiment. [Figure 14] This is a flowchart of the process for generating explanatory text. [Figure 15] This diagram shows the request sent to the generation AI system. [Figure 16] This is a diagram explaining the content of the prompt. [Figure 17] This diagram shows chat completion objects received from the generation AI system. [Figure 18] It is a diagram for explaining the content of the answer included in the chat completion object. [Figure 19] It is an example of a mode transition diagram. [Figure 20] It is the Mermaid notation text generated from the mode transition diagram. [Figure 21] It is an example of a sequence diagram. [Figure 22] It is the Mermaid notation text generated from the sequence diagram.
Embodiments for Carrying Out the Invention
[0011] Hereinafter, embodiments for carrying out the present invention will be described in detail with reference to the respective drawings. FIG. 1 is a logical configuration diagram showing an explanatory text generation device 1 according to the first embodiment. The explanatory text generation device 1 includes a Markdown notation conversion unit 11, a Markdown notation extraction unit 12, an explanatory text conversion unit 13, and an explanatory text extraction unit 14. The explanatory text generation device 1 is a device that collaborates with the generation AI system 3 to generate the explanatory text 25 from the drawing 21.
[0012] When the drawing 21 and the drawing type 22 are input, the Markdown notation conversion unit 11 instructs the generation AI system 3 to convert this drawing 21 into the Mermaid notation text 23 by the requirement body 51 including the first prompt. The Mermaid notation is a kind of Markdown notation. Note that the notation of the text converted by the Markdown notation conversion unit 11 is not limited to the Mermaid notation, and any Markdown notation that expresses various drawings in text may be used, and it is not limited.
[0013] Natural language descriptions of drawings are often ambiguous, with omissions in details of nodes and topology. Therefore, when a generating AI learns drawings and the natural language descriptions of them, the natural language descriptions it generates based on the drawings are also ambiguous and may contain omissions. In contrast, Mermaid notation text accurately represents the nodes and topology of the drawing. Furthermore, the method for converting Mermaid notation text to natural language is simple. Therefore, by first converting the drawing into Mermaid notation text, and then converting this Mermaid notation text back into natural language, the explanatory text generator 1 can generate more accurate explanatory texts for drawings.
[0014] Furthermore, the explanatory text generation device 1 is divided into two processes: one for generating Mermaid notation text from a drawing, and another for generating an explanatory text from the Mermaid notation text. This reduces the number of tokens required by the generation AI system 3 compared to executing both processes with a single prompt, increasing the likelihood of successful processing.
[0015] Figure 21 is, for example, a flowchart, a sequence diagram, or a mode transition diagram. Figure type 22 is information that describes the type of figure 21, and is, for example, the string of characters "flowchart", "sequence diagram", or "mode transition diagram".
[0016] This request 51 is written in JSON format. The request 51 is executed by the generation AI system 3, for example, by calling the API (Application Programming Interface) of the generation AI system 3, and a chat completion object 52 is generated. Then, the generation AI system 3 sends the chat completion object 52 in JSON format to the Markdown notation conversion unit 11. This chat completion object 52 corresponds to the first response, which contains the Mermaid notation text 23.
[0017] The Markdown notation extraction unit 12 extracts Mermaid notation text 23 from the chat completion object 52. Specifically, when it finds a line in Markdown notation that contains three backticks indicating the start of a code block and the word "mermaid", it extracts the text from there up to the line containing three backticks indicating the end of a code block as Mermaid notation text 23.
[0018] When the explanatory text conversion unit 13 receives Mermaid notation text 23, an operating entity 24, and a writing style 26 as input, it instructs the generation AI system 3, via a request body 53 including a second prompt, to convert the Mermaid notation text 23 into an explanatory text 25. The operating entity is, for example, the operating entity of the flowchart if the drawing 21 is a flowchart. If the drawing 21 is a mode transition diagram, it is the operating entity of the mode transition diagram. If the drawing 21 is a sequence diagram, its operating entity is already illustrated, so there is no need to specify the operating entity.
[0019] Style 26 is either a plain style ending in "dearu / da" or a polite style ending in "desu / masu". The explanatory text conversion unit 13 generates the explanatory text in the specified style 26, allowing the user to choose between a plain style suitable for official documents and a polite style suitable for user manuals, etc.
[0020] The request 53 is written in JSON format. This request 53 is executed by the generation AI system 3, for example, by calling the API of the generation AI system 3, and a chat completion object 54 is generated. The generation AI system 3 then returns the chat completion object 54 in JSON format to the description conversion unit 13. This chat completion object 54 is the second response, which includes the description 25 of the drawing 21.
[0021] The description extraction unit 14 extracts the description 25 from the chat completion object 54. As a result, the description generation device 1 can generate a description 25 that explains the drawing 21 from the drawing 21 and the drawing type 22.
[0022] Figure 2 is a hardware configuration diagram showing the explanatory text generation device 1. The explanatory text generation device 1 is equipped with a CPU (Central Processing Unit) 101, RAM (Random Access Memory) 102, and ROM (Read Only Memory) 103. The CPU 101 is a processing unit that executes computer programs and provides overall control over the explanatory text generation device 1. The RAM 102 is a volatile read / write memory used by the CPU 101 as a workspace for computer programs. The ROM 103 is a non-volatile read-only memory that stores, for example, the BIOS (Basic I / O System).
[0023] The explanatory text generation device 1 further includes a display unit 104, an input unit 105, a communication unit 106, and a storage unit 107. The display unit 104 is, for example, a liquid crystal display, which displays characters, figures, images, etc. The input unit 105 is, for example, a mouse, keyboard, or touch panel, which the user inputs information into. The communication unit 106 is, for example, a network interface card, which communicates information with, for example, the generation AI system 3.
[0024] The memory unit 107 is a large-capacity storage device such as a hard disk or an SSD (Solid State Drive). The explanatory text generation program 1071 is stored in this memory unit 107. When the CPU 101 executes the explanatory text generation program 1071, each of the functional units in Figure 1 is realized.
[0025] Figure 3 shows the explanatory text generation screen 41 displayed on the display unit 104 by the explanatory text generation device 1. The description generation screen 41 consists of a type combo box 411, an action subject text box 412, a drawing area 413, a Mermaid notation text area 414, a description area 415, a Mermaid notation text generation button 416, and a description generation button 417. This description generation screen 41 is a screen for generating a description of a drawing by inputting the drawing, the drawing type, the action subject, and the style of the description.
[0026] The Type combo box 411 is a combo box for selecting the type of drawing. The Style combo box 418 is a combo box for selecting whether to use the plain style or the formal style for the explanatory text.
[0027] The drawing area 413 is the area where the entered drawing is displayed. For example, a drawing is registered in the drawing area 413 by the user dragging and dropping a drawing file into the drawing area 413. The Mermaid notation text generation button 416 is a button that generates Mermaid notation text from the registered drawing.
[0028] The Mermaid notation text area 414 is an area that displays Mermaid notation text generated from the drawing displayed in the drawing area 413. The action subject text box 412 is a text box for entering the action subject, such as a flowchart, that is explained in the drawing. Note that the text in the Mermaid notation text area 414 is displayed in an editable format. This allows for manual correction of the Mermaid notation text generated by the generation AI system 3 to obtain the correct explanation, even if there are errors in the Mermaid notation text.
[0029] The description generation button 417 is a button that generates a description from the Mermaid notation text displayed in the Mermaid notation text area 414. The description area 415 is an area that displays the description generated from the Mermaid notation text displayed in the Mermaid notation text area 414.
[0030] Figure 4 is a flowchart of the explanatory text generation process. First, the Markdown notation conversion unit 11 accepts input of a drawing, its type, and the operator (step S10). Then, the Markdown notation conversion unit 11 creates a prompt that specifies the drawing and its type and converts it to Mermaid notation text (step S11). The Markdown notation conversion unit 11 sends the request body containing the generated prompt to the generation AI system 3 via API (step S12), and receives a chat completion object from the generation AI system 3 (step S13).
[0031] Next, the Markdown notation extraction unit 12 extracts Mermaid notation text from the chat completion object (step S14). Next, the descriptive text conversion unit 13 creates a prompt to be converted into a descriptive text from the Mermaid notation text, the agent, and the writing style (step S15). Then, the descriptive text conversion unit 13 sends the request body containing the generated prompt to the generation AI system 3 via API (step S16), and receives a chat completion object from the generation AI system 3 via API (step S17).
[0032] Next, the description extraction unit 14 extracts the description from the chat completion object (step S18), and displays the extracted description of the drawing on the description generation screen 41 (step S19), after which the process shown in Figure 4 is terminated.
[0033] Figure 5 shows a request body 51 including a first prompt 31 to be sent to the generating AI system 3. This request 51 consists of a model item and a messages item. The Model item specifies the ID of the generating AI model, followed by a semicolon. The Messages item stores a list of messages that make up the conversation so far, and various message types such as text, images, and audio can be set. The Messages item contains a role item and a content item in curly braces, followed by a semicolon.
[0034] For the role field, enter either system or user. For the contents field, enter text for the type field and enter the first prompt 31 from Figure 6 for the text field. For the contents field, enter image_url for the type field and enter BASE64-formatted image data or an image URL (Uniform Resource Locator) for the image_url field.
[0035] Figure 6 is a diagram illustrating the content of the first prompt 31. The first prompt 31 contains the instruction text: "The attached drawing is {drawing type}. Please convert this drawing to Mermaid notation text." and "{drawing type} = flowchart". The generating AI system 3 interprets the attached drawing as a flowchart and converts it to text.
[0036] Figure 7 shows a chat completion object 52 received from the generation AI system 3. This chat completion object 52 consists of the following fields: id, object, created, model, choices, and usage.
[0037] The `id` field is an identifier that uniquely identifies the chat completion object 52. The `object` field indicates the object type, which is always `chat.completion`. The `created` field shows the Unix timestamp in seconds when the chat completion was created. The `model` field is the model used for the chat completion. The `choices` field is a list of choices for the chat completion, which may be multiple. The `usage` field is the usage statistics for the completion request.
[0038] The `choices` field consists of the `index` field, the `role` and `content` fields included in the `message` field, and the `finish_reason` field. The `index` field is the number of the option to complete the chat. The `role` field within the `message` field stores the `assistant`. The `content` field within the `message` field stores the response 32 generated by the AI generation system 3.
[0039] Figure 8 is a diagram illustrating the content of the response 32 included in the chat completion object 52. This answer, number 32, contains Mermaid notation text within a Markdown code block. This Mermaid notation text is a description of a drawing.
[0040] The Mermaid notation text for Figure 8 is shown below. flowchart TD Start(["Start"]) S101{"Control decision?"} S102 ["Acquisition of population density"] S103 {"Overall control?"} S104 ["Determination of Supply Space"] S105 ["Control based on the decision result"] S106 ["Independent Control"] Start --> S101 S101 -- "Y" --> S102 S101 -- "N" --> S106 S102 --> S103 S103 -- "Y" --> S104 S103 -- "N" --> S106 S104 --> S105 S105 --> S106
[0041] Figure 9 shows a request body 53 that includes a second prompt 33 to be sent to the generating AI system 3. This request 53 consists of a model item and a messages item. The Model item specifies the ID of the generating AI model, followed by a semicolon. The Messages item stores a list of messages that make up the conversation so far, and various message types such as text, images, and audio can be set. The Messages item contains a role item and a content item in curly braces, followed by a semicolon.
[0042] For the role field, enter either system or user. For the contents field, enter text for the type field and enter the second prompt 33 from Figure 10 for the text field.
[0043] Figure 10 is a diagram illustrating the content of the second prompt 33. The second prompt 33 contains the following instruction text on the first line: "The Markdown notation text is in Mermaid notation. Generate a description of the [drawing type] shown in this Markdown notation text, with {operating entity} as the subject. The writing style should be {writing style}." The second line contains "{operating entity}=terminal". The third line contains "{writing style}=plain style". The fourth line contains "#Markdown notation text" indicating the Markdown notation text. From the fifth line onward, the Mermaid notation text is written. As a result, the generation AI system 3 converts the Mermaid notation text from the fourth line onward into a description with the operating entity as the subject and the writing style specified.
[0044] Figure 11 shows a chat completion object 54 received from the generation AI system 3. This chat completion object 54 consists of the following fields: id, object, created, model, choices, and usage.
[0045] The `id` field is an identifier that uniquely identifies the chat completion object 54. The `object` field indicates the object type, which is always `chat.completion`. The `created` field shows the Unix timestamp in seconds when the chat completion was created. The `model` field is the model used for the chat completion. The `choices` field is a list of choices for the chat completion, which may be multiple. The `usage` field is the usage statistics for the completion request.
[0046] The `choices` field consists of the `index` field, the `role` and `content` fields included in the `message` field, and the `finish_reason` field. The `index` field is the number of the option to complete the chat. The `role` field within the `message` field stores the `assistant`. The `content` field within the `message` field stores the response 34 generated by the AI generation system.
[0047] Figure 12 is a diagram illustrating the content of the response included in the chat completion object 54. This answer 34 contains an explanatory text. This explanatory text is a description of the drawing. Below is a transcription of the explanatory text actually generated by the generation AI system 3.
[0048] The flowchart according to the present invention shows the procedure for determining whether control by a terminal is necessary and for executing appropriate control according to the situation. Each step is described in detail below. First, the terminal starts processing (step "start"). Next, the terminal makes a decision about the need for control (step S101). If it is determined that control is necessary, the terminal proceeds to the process of acquiring the population density (step S102). On the other hand, if it is determined that control is not necessary, the terminal performs direct independent control (step S106). In step S102, the terminal acquires information about the surrounding population density. Next, the terminal determines whether overall control is necessary (step S103). If overall control is determined to be necessary, the terminal proceeds to determine the supply space (step S104) and selects an appropriate supply space. On the other hand, if overall control is determined to be unnecessary, the terminal proceeds to independent control (step S106). After the supply space is determined, the terminal performs appropriate control based on the determination (step S105). Finally, the terminal completes the control flow by performing independent control (step S106). The flowchart of this invention allows the terminal to appropriately determine the need for situation-specific control and overall control, and to determine the supply space as needed. This enables efficient control and allows the terminal to perform optimal operations appropriate to the surrounding conditions.
[0049] Figure 13 is a logical configuration diagram showing the explanatory text generation device 1A according to the second embodiment. The explanatory text generation device 1A comprises a conversion unit 15, a Markdown notation extraction unit 12, and an explanatory text extraction unit 14. The explanatory text generation device 1A works in cooperation with the generation AI system 3 to generate an explanatory text 25 from a drawing 21.
[0050] When the conversion unit 15 receives the drawing 21, the drawing type 22, the operating entity 24, and the writing style 26 as input, it instructs the generation AI system 3, via a request body 55 including a prompt, to convert the drawing 21 into Mermaid notation text 23 and explanatory text 25. The drawing 21 may be, for example, a flowchart, a sequence diagram, or a mode transition diagram.
[0051] The drawing type 22 is information that describes the type of drawing 21, and is, for example, a string of characters such as "flowchart," "sequence diagram," or "mode transition diagram." The operating entity 24 is, for example, the operating entity of the flowchart if drawing 21 is a flowchart. If drawing 21 is a mode transition diagram, it is the operating entity of the mode transition diagram. Note that if drawing 21 is a sequence diagram, its operating entity is shown in the diagram, so it is not necessary to specify the operating entity. The writing style 26 is either the plain style with "である / だ" at the end of sentences, or the polite style with "ですます" at the end of sentences. The conversion unit 15 generates the explanatory text in the specified writing style 26, making it possible to select either the plain style suitable for official documents or the polite style suitable for user manuals, etc.
[0052] This request 55 is written in JSON (JavaScript Object Notation) format. The request 55 is executed by the generation AI system 3, for example, by calling the API of the generation AI system 3, and a chat completion object 56 is generated. The generation AI system 3 then returns the chat completion object 56 in JSON format to the conversion unit 15. This chat completion object 56 contains Mermaid notation text 23.
[0053] The Markdown notation extraction unit 12 extracts the Mermaid notation text 23 from the chat completion object 56. The description extraction unit 14 extracts the description 25 from the chat completion object 56. As a result, the description generation device 1 can generate a description 25 that explains the drawing 21 from the drawing 21 and the drawing type 22.
[0054] Figure 14 is a flowchart of the explanatory text generation process. First, the conversion unit 15 accepts input of a drawing, its type, and the operating entity (step S30). Then, the conversion unit 15 specifies the drawing, its type, and the operating entity, converts them into Mermaid notation text, and creates a prompt that is then converted into a description of the drawing (step S31). The conversion unit 15 sends the request body containing the generated prompt to the generation AI system 3 via API (step S32), and receives a chat completion object from the generation AI system 3 (step S33).
[0055] Next, the Markdown notation extraction unit 12 extracts Mermaid notation text from the chat completion object (step S34).
[0056] Next, the description extraction unit 14 extracts the description from the chat completion object (step S35), and displays the extracted description of the drawing on the description generation screen 41 (step S36), after which the process in Figure 14 is terminated.
[0057] Figure 15 shows the request 55 to be sent to the generating AI system 3. This request 55 consists of a model item and a messages item. The Model item specifies the ID of the generating AI model, followed by a semicolon. The Messages item stores a list of messages that make up the conversation so far, and various message types such as text, images, and audio can be set. The Messages item contains a role item and a content item in curly braces, followed by a semicolon.
[0058] For the role field, enter either system or user. For the contents field, enter text for the type field and enter prompt 35 from Figure 16 for the text field. For the contents field, enter image_url for the type field and enter BASE64-formatted image data or an image URL (Uniform Resource Locator) for the image_url field.
[0059] Figure 16 is a diagram illustrating the content of prompt 35. Prompt 35 contains the instruction text: "The attached drawing is {drawing type}. Convert this drawing to Mermaid notation text. Then, generate a patent specification description for the {drawing type} shown in this Mermaid notation text, with {operating entity} as the operating entity. Use {writing style}. Include the Mermaid notation text and the description in your answer." and "{drawing type} = flowchart", "{operating entity] = terminal", and "{writing style} = plain style". As a result, the generating AI system 3 interprets the attached drawing as a flowchart and converts it to Mermaid notation text. Then, it generates a patent specification description for the flowchart shown in Mermaid notation text, with terminal as the operating entity.
[0060] Figure 17 shows a chat completion object 56 received from the generation AI system 3. This chat completion object 56 consists of the following fields: id, object, created, model, choices, and usage.
[0061] The `id` field is an identifier that uniquely identifies the chat completion object 56. The `object` field indicates the object type, which is always `chat.completion`. The `created` field shows the Unix timestamp in seconds when the chat completion was created. The `model` field is the model used for the chat completion. The `choices` field is a list of choices for the chat completion, which may be multiple. The `usage` field is the usage statistics for the completion request.
[0062] The `choices` field consists of the `index` field, the `role` and `content` fields included in the `message` field, and the `finish_reason` field. The `index` field is the number of the option to complete the chat. The `role` field within the `message` field stores the `assistant`. The `content` field within the `message` field stores the response 36 generated by the AI generation system.
[0063] Figure 18 is a diagram illustrating the content of the response 36 included in the chat completion object 56. This answer 36 contains Mermaid notation text within a Markdown code block. This Mermaid notation text is a description of the drawing. Following this is a description of the drawing.
[0064] Figure 19 shows an example of a mode transition diagram. The device starts in battery operation mode. When the power is turned on, the device transitions to the first main power operation mode. If an attendance error occurs while in the first main power operation mode, the device returns to battery operation mode. After a certain period of time, the device transitions from the first main power operation mode to the second main power operation mode. If the power is turned off while in the second main power operation mode, the device returns to battery operation mode.
[0065] Figure 20 is the Mermaid notation text generated from the mode transition diagram. The Mermaid notation text is transcribed below. Note that the explanation for Figure 19 was automatically generated from this Mermaid notation text. stateDiagram [*] --> Battery operation Battery operation --> Main power supply operation: Power ON Main power supply operation --> Battery operation: Attendance error First main power supply operation --> Second main power supply operation: for a certain period of time Second main power supply operation --> Battery operation: Power OFF
[0066] Figure 21 is an example of a sequence diagram. The sequence diagram according to the present invention illustrates a series of steps in which a server responds to a processing request from a user terminal and stores the processing result in a cache database. The details of each step are described below.
[0067] First, the user terminal sends a processing request to the server. Upon receiving this processing request, the server sends a processing request to the cache database to check if the corresponding processing result exists in the cache.
[0068] Next, if the processing result cache database does not exist in the relevant cache, it returns a "cache not found" response to the server. Upon receiving this response, the server executes the processing required for the request and generates the processing result.
[0069] Once processing is complete, the server saves the generated processing results to a processing result cache database, allowing it to quickly respond to similar future requests using the cache. The server then returns the processing results to the user's terminal, allowing the user to verify the results.
[0070] Finally, the processing result cache database stores the processing results received from the server as a record. This reduces response time to future processing requests and improves system efficiency. This invention, by utilizing a caching function, achieves a reduction in processing time for similar requests, resulting in improved overall system performance.
[0071] Figure 22 shows the Mermaid notation text generated from the sequence diagram. The Mermaid notation text is transcribed below. Note that the explanation for Figure 21 was automatically generated from this Mermaid notation text. sequenceDiagram participant user terminal Application Server Subject Processing Result Cache DB User terminal ->> Server: Processing request Server ->> Processing Result Cache DB: Processing Request Processing result cache DB -->> Server: Cache not found Server ->> Server: Processing Execution Server ->> Processing Result Cache DB: Processing Result Server -->> User Terminal: Processing Result Processing result cache DB ->> Processing result cache DB: Record
[0072] (modified version) The present invention is not limited to the embodiments described above, and can be modified without departing from the spirit of the invention, for example, (a) to (d) below.
[0073] (a) The text converted from the drawing by the generating AI is not limited to Mermaid notation text, but can be any Markdown notation that uniquely represents the nodes and topology of the drawing. (b) The generation AI system is not limited to a cloud environment; it may also operate in an on-premises environment. (c) The drawings' descriptions are not limited to those for patent specifications; they may also be descriptions for software specifications or user manuals. In such cases, it is recommended to specify in the prompt "Generate a description for software specifications" or "Generate a description for user manuals." (d) The generative AI system that sends the first prompt and the generative AI system that sends the second prompt may be the same or different, and are not limited to such systems. [Explanation of Symbols]
[0074] 1. Description Generator 1A Description Generator 101 CPU 102 RAM 103 ROM 104 Display section 105 Input section 106 Communications Department 107 Storage section 1071 Description Generation Program 11 Markdown Notation Conversion Section 12 Markdown notation extraction section 13. Explanation text conversion section 14. Description Extraction Unit 15 Conversion section 21 Drawings 22 Types of Drawings 23 Mermaid Notation Text 24 Actor 25 Description 3. Generative AI System 31 First Prompt 32 answers 33 Second Prompt 34 answers 35 Prompts 36 answers 51 Request body 52 Chat Completed Object (First Answer) 53 Request body 54. Chat completed object (2nd response) 55 Request body 56 Chat Completed Objects 41 Description generation screen 411-Type Combo Box 412 Action Subject Text Box 413 Drawing Area 414 Mermaid notation text area 415 Description Area 416 Mermaid notation text generation button 417 Description Generation Button
Claims
1. On the computer, A procedure for inputting a first prompt to a generating AI, which includes instructions to convert a drawing into text in a predetermined Markdown notation, and obtaining a first response from the generating AI that includes text written in the predetermined Markdown notation. A procedure for extracting text written in the specified Markdown notation from the first answer, A procedure for inputting a second prompt to a generating AI, which includes instructions to generate the aforementioned text and the description of the drawing, and obtaining a second response from the generating AI, which includes the description of the drawing. A program for generating explanatory text for drawings to be implemented.
2. The type of drawing mentioned above is one of the following: flowchart, sequence diagram, or mode transition diagram. The second prompt includes the subject of the operation indicated by the type of drawing, and an instruction to make that subject the subject of the description of the drawing. A program for generating explanatory text for drawings as described in claim 1.
3. The second prompt includes instructions for the style of the descriptive text of the drawing. A program for generating explanatory text for drawings as described in claim 1.
4. The first prompt includes information indicating the type of drawing. A program for generating explanatory text for drawings as described in claim 1.
5. On the computer, A procedure for obtaining a response containing text written in the predetermined Markdown format and an explanation of the text, by inputting prompts to the generating AI, including instructions to convert the drawing into text in a predetermined Markdown format, and instructions to generate the text and the description of the drawing. A procedure for extracting text written in the specified Markdown format from the above response, Procedure for extracting the explanatory text for the drawing from the above answer, A program for generating explanatory text for drawings to be implemented.
6. The type of drawing mentioned above is one of the following: flowchart, sequence diagram, or mode transition diagram. The prompt includes the subject of the operation indicated by the type of drawing, and an instruction to make that subject the subject of the description of the drawing. A program for generating explanatory text for drawings according to claim 5.
7. The prompt includes information indicating the type of drawing. A program for generating explanatory text for drawings according to claim 5.
8. A Markdown notation conversion unit inputs a first prompt to a generating AI, which includes instructions to convert a drawing into a predetermined Markdown notation, and obtains a first response from the generating AI, which includes text written in the predetermined Markdown notation. A Markdown notation extraction unit extracts text written in the predetermined Markdown notation from the first answer, A description conversion unit inputs a second prompt to a generating AI, which includes the aforementioned text and an instruction to generate a description of the drawing, and obtains a second response, which includes the description of the drawing, from the generating AI. A drawing description generation device characterized by comprising the following features.
9. A conversion unit receives prompts from a generating AI that include instructions to convert a drawing into text in a predetermined Markdown notation, and instructions to generate a description of the text and the drawing, and obtains a response that includes text written in the predetermined Markdown notation and a description of the text. A Markdown notation extraction unit extracts text written in the predetermined Markdown notation from the aforementioned answer, An explanatory text extraction unit that extracts the explanatory text for the drawing from the above answer, A device for generating explanatory text for drawings to implement the process.