Document generation method, document generation device, electronic equipment and storage medium

By matching the contents of the initial software design document with software design elements and adding them to the structured template, the problem of inconsistent format of the software design document is solved, and the maintainability and information symmetry of the document are improved.

CN119105741APending Publication Date: 2024-12-10GREAT WALL MOTOR CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411036729.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-31
Publication Date
2024-12-10

AI Technical Summary

Technical Problem

During the software development process, handwritten software design documents lead to inconsistent formats, difficult to manage and maintain, and there is a lack of a way to improve the maintainability of documents.

Method used

By matching the document content in the initial software design document with multiple software design elements, adding it to a structured target template, generating target software design documents with clear logic and hierarchy, including module division, database design, interface design and interaction, including module division, database design, interface design and interaction Design elements to ensure the integrity and standardization of document content.

Benefits of technology

It improves the maintainability of software design documents, ensures the structured structure of documents, facilitates understanding, modification and expansion, avoids loss and inconsistency of document content, and enhances information symmetry between teams.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119105741A_ABST
    Figure CN119105741A_ABST
Patent Text Reader

Abstract

The invention provides a document generation method and device, electronic equipment and a storage medium, and relates to the technical field of software engineering. The method comprises the following steps: matching document contents in an initial software design document with a plurality of software design elements to obtain document contents corresponding to the plurality of software design elements; the software design elements are core building blocks forming the target software design document. Furthermore, the target template comprises a structured design framework provided for generation of the target software design document, the structured design framework is constructed through logical structures of different levels, and after document contents corresponding to the multiple software design elements are added to the positions of the corresponding software design elements in the target template, the target software design document is generated. It can be ensured that the obtained document also has a structured framework and has clear logic and hierarchy. Therefore, the target software design document in the method has a clear structured architecture and is easy to understand, modify and expand, so that the maintainability of the target software design document can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of software engineering technology, and more specifically, to a document generation method, a document generation device, an electronic device and a storage medium in the field of software engineering technology. Background Art

[0002] In the process of software development, writing software design documents is a crucial task, but it is also a rather tedious and error-prone process.

[0003] At present, software design documents are usually written by hand. However, the R&D team consists of multiple R&D personnel, and different R&D personnel may have different document writing habits, which will lead to different formats of software design documents. This is not convenient for managing multiple software design documents, making maintenance complicated.

[0004] Therefore, there is an urgent need for a document generation method to improve the maintainability of software design documents. Summary of the invention

[0005] The present application provides a document generation method, a document generation device, an electronic device and a storage medium, which can improve the maintainability of the target software design document.

[0006] In a first aspect, a document generation method is provided, the method comprising: in response to a conversion operation on an initial software design document, matching the document content in the initial software design document with a plurality of software design elements to obtain document content corresponding to the plurality of software design elements, the initial software design document being a software design document that has not been converted after writing, and the software design elements being core building blocks constituting a target software design document; adding the document content corresponding to the plurality of software design elements in the initial software design document to positions of corresponding software design elements in a target template to obtain a target software design document, the target template comprising a structured design framework provided for the generation of the target software design document.

[0007] In the above technical solution, the method transforms the software design document that has not been transformed after writing, and matches the document content in the initial software design document with multiple software design elements. Since the software design element is the core building block constituting the target software design document, in this way, the document content corresponding to each software design element can be matched from the initial software design document, which is helpful to generate the document content of the core building block of the target software design document. Furthermore, the target template includes a structured design framework provided for the generation of the target software design document, and the structured design framework is constructed through logical structures (such as titles) at different levels. Therefore, after adding the document content corresponding to the multiple software design elements in the initial software design document to the position of the corresponding software design elements in the target template, it can be ensured that the obtained document also has a structured framework, with clear logic and hierarchy. Therefore, the target software design document finally generated by the method has a clear structured architecture, which is easy to understand, modify and expand, which can improve the maintainability of the target software design document.

[0008] In combination with the first aspect, in some possible implementations, the multiple software design elements include a module division element, which indicates the functional modules into which the software program corresponding to the target software design document is divided, and the document content corresponding to the multiple software design elements in the initial software design document is added to the position of the corresponding software design element in the target template, including: based on the software architecture of the software program corresponding to the initial software design document, module-dividing the first document content corresponding to the module division element in the initial software design document to obtain multiple functional modules, and adding the multiple functional modules to the position of the corresponding module division element in the target template; based on the relationship between the multiple functional modules, generating a module relationship diagram, and adding the module relationship diagram to the position of the corresponding module division element in the target template.

[0009] In the above technical solution, when multiple software design elements include module division elements, the method performs module division on the first document content corresponding to the module division element in the initial software design document based on the software architecture of the software program corresponding to the initial software design document, obtains multiple functional modules and adds the multiple functional modules to the position of the corresponding module division element in the target template. In this way, the target software design document finally obtained includes the document content corresponding to the module division element in the initial software design document, which fully restores the document content in the initial software design document and avoids the loss of the document content in the initial software design document. In addition, the method also generates a module relationship diagram based on the relationship between the multiple functional modules, and adds the module relationship diagram to the position of the corresponding module division element in the target template. This enables R&D personnel to clearly understand the relationship between functional modules, which is convenient for R&D personnel other than those who write the initial software design document to understand the initial software design document.

[0010] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the multiple software design elements also include database design elements and / or interface design elements, the database design elements indicate data used by the software program corresponding to the target software design document, and the interface design elements indicate the interface used by the software program, and the document content corresponding to the multiple software design elements in the initial software design document is added to the position of the corresponding software design elements in the target template, including: adding the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table, the target table including multiple preset fields; based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces, adding the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template, the target interface information being the information describing the interface after standardized processing.

[0011] In the above technical solution, when multiple software design elements include database design elements, the method adds the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table. In this way, the target software design document finally obtained includes the document content corresponding to the database design element in the initial software design document, which fully restores the document content in the initial software design document and avoids the loss of the document content in the initial software design document. Further, the method adds the second document content to the position of the corresponding database design element in the target template in the form of a target table. This enables the R&D personnel to clearly and clearly view the data used by the software program corresponding to the initial software design document and the specific purpose of each data. In addition, when multiple software design elements include interface design elements, the method adds the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces. In this way, the final target software design document includes standard interface description information of multiple interfaces used by the software program, which makes it easier for R&D personnel other than those who write the initial software design document to understand the interfaces used by the software program corresponding to the initial software design document.

[0012] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces, the target interface information corresponding to the initial software design document is added to the position of the corresponding interface design element in the target template, including: comparing the interface design element in the third document content with the multiple sample interfaces, and determining multiple target interfaces that match the interface design element from the multiple sample interfaces; determining the interface information corresponding to the multiple target interfaces as the target interface information, and adding the target interface information to the position of the corresponding interface design element in the target template.

[0013] In the above technical scheme, different R&D personnel have different document writing habits, and the interface description information of the same interface used by the software program written in the initial software design document may be different. The method compares the interface design elements in the content of the third document with the multiple sample interfaces, and determines multiple target interfaces that match the interface design elements from the multiple sample interfaces. In other words, the interface (multiple target interfaces) used in the software program corresponding to the initial software design document is clarified. Further, the interface information corresponding to the multiple target interfaces is determined as the target interface information, and the target interface information is added to the position of the corresponding interface design element in the target template. In this way, standard interface description information can be obtained, and the target software design document includes standard interface description information of multiple interfaces used by the software program, which is convenient for R&D personnel other than those who write the initial software design document to understand the interface used by the software program corresponding to the initial software design document, and improve the comprehensibility of the target software design document.

[0014] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the multiple software design elements also include an interaction design element, which indicates the interaction between interfaces or functional modules in the software program corresponding to the target software design document, and the document content corresponding to the multiple software design elements in the initial software design document is added to the position of the corresponding software design element in the target template, including: determining upstream and downstream interaction content used to indicate the interaction relationship between module division elements or interface design elements from the initial software design document; based on the upstream and downstream interaction content, generating a target graphic and adding it to the position of the corresponding module division element or interface design element in the target template, and the target graphic is used to display the interaction relationship between the module division elements or interface design elements.

[0015] In the above technical solution, when multiple software design elements include interactive design elements, the method determines the upstream and downstream interactive content used to indicate the interactive relationship between module division elements or interface design elements from the initial software design document, and based on the upstream and downstream interactive content, generates a target graphic and adds it to the position of the corresponding module division element or interface design element in the target template. In this way, the target software design document finally obtained includes the interactive relationship and interactive logic between multiple functional modules and / or multiple interfaces used by the software program. Furthermore, this enables R&D personnel to better understand the software program corresponding to the initial software design document.

[0016] In combination with the first aspect and the above-mentioned implementation methods, in some possible implementation methods, the document content corresponding to the multiple software design elements in the initial software design document is added to the positions of the corresponding software design elements in the target template to obtain the target software design document, including: adding the document content corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template; configuring a change history record table in the target area in the target template to obtain the target software design document, the change history record table including the change items and change time when the content of the position in the target template is changed.

[0017] In the above technical solution, the document contents corresponding to the multiple software design elements in the initial software design document are added to the positions of the corresponding software design elements in the target template; a change history record table is configured in the target area of ​​the target template to obtain the target software design document. In this way, the target software design document finally obtained includes the changed items and change time when the content in the target template is changed, so that the R&D personnel can clearly understand the change records of the software design document, the change time and the changed items, and can make the software design document information symmetrical for different R&D personnel, which is conducive to the smooth progress of the software project and achieve the expected results.

[0018] In combination with the first aspect and the above-mentioned implementation methods, in certain possible implementation methods, in response to a conversion operation on an initial software design document, the document content in the initial software design document is matched with a plurality of software design elements, including any one of the following: in response to the conversion operation triggered by a manual operation of a target object, the document content in the initial software design document is matched with a plurality of software design elements; in response to a conversion operation on the initial software design document when the current moment matches a preset moment, the document content in the initial software design document is matched with a plurality of software design elements; in response to the conversion operation triggered by an upload operation of the initial software design document, the document content in the initial software design document is matched with a plurality of software design elements.

[0019] In the above technical solution, the method describes several triggering operations that can transform the initial software design document. Specifically, the manual operation of the target object can trigger the transformation operation (the operation of transforming the initial software design document), the current moment can trigger the transformation operation when it matches the preset moment, and the upload operation of the initial software design document can trigger the transformation operation. The method triggers the transformation operation in a variety of ways, which can not only meet the manual triggering requirements of the object (R&D personnel), but also meet the automatic triggering requirements of different software projects.

[0020] In a second aspect, a document generation device is provided, which includes: a determination module, which is used to match the document content in the initial software design document with multiple software design elements in response to a conversion operation on an initial software design document to obtain document content corresponding to the multiple software design elements, wherein the initial software design document is a software design document that has not been converted after writing, and the software design elements are core building blocks that constitute a target software design document; and a generation module, which is used to add the document content corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain the target software design document, wherein the target template includes a structured design framework provided for the generation of the target software design document.

[0021] In combination with the second aspect, in some possible implementations, the multiple software design elements include a module division element, which indicates the functional modules into which the software program corresponding to the target software design document is divided. The device also includes: an adding module, which is used to perform module division on the first document content corresponding to the module division element in the initial software design document based on the software architecture of the software program corresponding to the initial software design document, to obtain multiple functional modules, and add the multiple functional modules to the corresponding module division element positions in the target template; based on the relationship between the multiple functional modules, generate a module relationship diagram, and add the module relationship diagram to the corresponding module division element position in the target template.

[0022] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the multiple software design elements also include database design elements and / or interface design elements, the database design elements indicate the data used by the software program corresponding to the target software design document, and the interface design elements indicate the interface used by the software program, and the adding module is specifically used to: add the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table, and the target table includes multiple preset fields; based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces, add the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template, and the target interface information is the information describing the interface after standardized processing.

[0023] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the determination module is specifically used to compare the interface design element in the third document content with the multiple sample interfaces, and determine multiple target interfaces that match the interface design element from the multiple sample interfaces; the adding module is also specifically used to determine the interface information corresponding to the multiple target interfaces as the target interface information, and add the target interface information to the position of the corresponding interface design element in the target template.

[0024] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the multiple software design elements also include an interaction design element, which indicates the interaction between interfaces or functional modules in the software program corresponding to the target software design document. The determination module is specifically used to determine the upstream and downstream interaction content used to indicate the interaction relationship between module division elements or interface design elements from the initial software design document; the addition module is specifically used to generate a target graphic based on the upstream and downstream interaction content and add it to the position of the corresponding module division element or interface design element in the target template, and the target graphic is used to display the interaction relationship between the module division elements or interface design elements.

[0025] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the adding module is specifically used to add the document content corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template; the generating module is specifically used to configure a change history record table in the target area of ​​the target template to obtain the target software design document, and the change history record table includes the change items and change time when the content of the position in the target template is changed.

[0026] In combination with the second aspect and the above-mentioned implementation methods, in some possible implementation methods, the device also includes: a matching module, used for any one of the following: matching the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by the manual operation of the target object; matching the document content in the initial software design document with multiple software design elements in response to the conversion operation on the initial software design document when the current moment matches the preset moment; matching the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by the upload operation of the initial software design document.

[0027] In a third aspect, an electronic device is provided, comprising a memory and a processor. The memory is used to store executable program code, and the processor is used to call and run the executable program code from the memory, so that the electronic device executes the method in the first aspect or any possible implementation of the first aspect.

[0028] In a fourth aspect, a computer-readable storage medium is provided, which stores an executable program code. When the executable program code runs on a computer, the computer executes the method in the above-mentioned first aspect or any possible implementation of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 This is a schematic diagram of a scenario of using an electronic device provided in an embodiment of the present application;

[0030] Figure 2 is a schematic flow chart of a document generation method provided in an embodiment of the present application;

[0031] Figure 3 It is a schematic diagram of generating a layered architecture diagram provided by an embodiment of the present application;

[0032] Figure 4 It is a schematic diagram of a generation module block diagram provided in an embodiment of the present application;

[0033] Figure 5 is a schematic diagram of a home page of a target software design document provided in an embodiment of the present application;

[0034] Figure 6 It is a structural schematic diagram of a document generation device provided in an embodiment of the present application;

[0035] Figure 7 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0036] The technical solution in the present application will be described clearly and in detail below in conjunction with the accompanying drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B: "and / or" in the text is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.

[0037] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features.

[0038] Figure 1 It is a schematic diagram of a scenario for using an electronic device provided in an embodiment of the present application.

[0039] For example, Figure 1 As shown, usually, different R&D personnel write software design documents through electronic devices based on the development requirements of the software project. However, different R&D personnel may have different document writing habits, which will lead to different formats of software design documents. This is not convenient for managing multiple software design documents, making maintenance more complicated.

[0040] Therefore, this application proposes a document generation method to improve the maintainability of software design documents. For details, please refer to the following Figure 2 .

[0041] Figure 2 It is a schematic flowchart of a document generation method provided in an embodiment of the present application.

[0042] It should be understood that a document generation method in the present application is applied to an electronic device. In some embodiments, the electronic device includes but is not limited to: a personal computer, a tablet computer, a computing device, or other processing device connected to a wireless modem, etc. The electronic device can also be a server.

[0043] For example, Figure 2 As shown, the method 200 includes:

[0044] Step 201, the electronic device responds to the conversion operation of the initial software design document by matching the document content in the initial software design document with multiple software design elements to obtain the document content corresponding to the multiple software design elements. The initial software design document is a software design document that has not been converted after writing, and the software design elements are the core building blocks that constitute the target software design document.

[0045] It should be understood that the "conversion operation" in the above step 201 is specifically an operation to convert the initial software design document to obtain the target software design document. Among them, the initial software design document is specifically a software design document written by any R&D personnel without conversion processing (not responding to the conversion operation). The software design document is a document that guides R&D personnel (software developers) to develop the software program corresponding to the software system during the software development process. The software design document is used to describe the design decisions, overall architecture, module division, interface design and database design of the software system. The software program corresponding to the software system is the software program used to implement the software system.

[0046] In some embodiments, the software design elements include module division elements, database design elements, interface design elements, and interaction design elements. The module division elements indicate the functional modules into which the software program corresponding to the target software design document is divided, the database design elements indicate the data used by the software program corresponding to the target software design document, the interface design elements indicate the interfaces used by the software program corresponding to the target software design document, and the interaction design elements indicate the interactions between the interfaces in the software program corresponding to the target software design document. The software program corresponding to the target software design document refers to the software program corresponding to the software system described in the target software design document.

[0047] In some embodiments, each software design element has its own management tool. The management tool for the module partitioning element is the Unified Modeling Language (UML) generation tool. The management tool for the database design element is the database client tool. The management tool for the interface design element is the swagger tool, which is used to design, build, write and use APIs. It provides a complete Application Programming Interface (API) specification, which defines the structure, parameters, responses and other information of the API. The management tool for the interactive design element is the Axure RP interactive design tool, which provides rich interactive elements and effects.

[0048] In some embodiments, the electronic device in step 201 matches the document content in the initial software design document with multiple software design elements to obtain document content corresponding to the multiple software design elements, including: for any software design element among the multiple software design elements, if there is a text title in the initial software design document, the electronic device determines the text title that matches the software design element, and determines multiple text segments with the same text title in the initial software design document as the document content corresponding to the software design element; for any software design element among the multiple software design elements, if there is no text title in the initial software design document, the electronic device performs semantic recognition on the document content in the initial software design document to determine the text title corresponding to each text segment in the initial software design document; the electronic device executes the step of the electronic device determining the text title that matches the software design element, and determining multiple text segments with the same text title in the initial software design document as the document content corresponding to the software design element.

[0049] It should be understood that the "initial software design document" in the above scheme is written by a certain R&D personnel, who may have the habit of writing text titles, or may not have the habit of writing text titles. Therefore, the above scheme is divided into two cases (the text title exists in the initial software design document and the text title does not exist in the initial software design document). The document content in the initial software design document is matched with multiple software design elements to obtain the document content corresponding to the multiple software design elements.

[0050] In the above technical solution, the initial software design document is written by R&D personnel, and the writing habits of each R&D personnel are different. Therefore, there may be a text title in the initial software design document, or there may not be a text title. Therefore, the method further discusses whether there is a text title in the initial software design document, and discusses the process of matching the document content in the initial software design document with multiple software design elements in two cases (the existence of a text title and the absence of a text title) to obtain the document content corresponding to the multiple software design elements. For any software design element among the multiple software design elements, when there is a text title in the initial software design document, multiple text segments of multiple text titles that match the software design element in the initial software design document can be determined as the document content corresponding to the software design element. This method can quickly and accurately obtain the document content corresponding to the software design element through the text title. When there is no text title in the initial software design document, the method needs to identify the text title. Therefore, this method can avoid the problem of not being able to obtain the document content corresponding to multiple software design elements due to the absence of a text title in the initial software design document.

[0051] In one possible implementation, the electronic device in step 201 matches the document content in the initial software design document with multiple software design elements in response to a conversion operation on the initial software design document, including any of the following: the electronic device matches the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by a manual operation of the target object; when the current moment matches the preset moment, the electronic device matches the document content in the initial software design document with multiple software design elements in response to the conversion operation on the initial software design document; the electronic device matches the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by an upload operation of the initial software design document.

[0052] It should be understood that the above schemes describe different ways to trigger the conversion operation. In the first way, the electronic device responds to the conversion operation triggered by the manual operation of the target object, and matches the document content in the initial software design document with multiple software design elements. This can be regarded as the target object's needs being prioritized, and the conversion operation is manually triggered by the target object. In the second way, when the current moment matches the preset moment, the electronic device responds to the conversion operation of the initial software design document, and matches the document content in the initial software design document with multiple software design elements. And in the third way, the electronic device responds to the conversion operation triggered by the upload operation of the initial software design document, and matches the document content in the initial software design document with multiple software design elements. Both the second and third ways can be regarded as ways to automatically trigger the conversion operation. The automatic triggering of the second way is only related to time and is periodic; the automatic triggering of the third way is only related to whether the initial software design document is uploaded, and may not be periodic.

[0053] In the above technical solution, the method describes several triggering operations that can transform the initial software design document. Specifically, the manual operation of the target object can trigger the transformation operation (the operation of transforming the initial software design document), the current moment can trigger the transformation operation when it matches the preset moment, and the upload operation of the initial software design document can trigger the transformation operation. The method triggers the transformation operation in a variety of ways, which can not only meet the manual triggering requirements of the object (R&D personnel), but also meet the automatic triggering requirements of different software projects.

[0054] In some embodiments, the manual operation is a click operation on a target function control, and the target function control is used to control the conversion of the initial software design document when being clicked.

[0055] In some embodiments, the preset time is a preset week in any week or a day in a preset position in any month.

[0056] In some embodiments, the preset time is Wednesday of every week or the third day of every month.

[0057] Step 202, the electronic device adds the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain a target software design document, wherein the target template includes a structured design framework provided for the generation of the target software design document.

[0058] It should be understood that the "target template" in the above step 202 is a software design document template used to generate a target software design document. The target template includes a structured design framework and multiple software design elements. The design framework specifies the position of each software design element.

[0059] In some embodiments, the design framework corresponding to the target template is a tree structure.

[0060] In one possible implementation, the multiple software design elements include a module division element, which indicates the functional modules into which the software program corresponding to the target software design document is divided. The electronic device in step 202 adds the document content corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template, including: the electronic device performs module division on the first document content corresponding to the module division element in the initial software design document based on the software architecture of the software program corresponding to the initial software design document to obtain multiple functional modules, and adds the multiple functional modules to the positions of the corresponding module division elements in the target template; the electronic device generates a module relationship diagram based on the relationship between the multiple functional modules, and adds the module relationship diagram to the positions of the corresponding module division elements in the target template.

[0061] In the above technical solution, when multiple software design elements include module division elements, the method performs module division on the first document content corresponding to the module division element in the initial software design document based on the software architecture of the software program corresponding to the initial software design document, obtains multiple functional modules and adds the multiple functional modules to the position of the corresponding module division element in the target template. In this way, the target software design document finally obtained includes the document content corresponding to the module division element in the initial software design document, which fully restores the document content in the initial software design document and avoids the loss of the document content in the initial software design document. In addition, the method also generates a module relationship diagram based on the relationship between the multiple functional modules, and adds the module relationship diagram to the position of the corresponding module division element in the target template. This enables R&D personnel to clearly understand the relationship between functional modules, which is convenient for R&D personnel other than those who write the initial software design document to understand the initial software design document.

[0062] In some embodiments, when the software system is used to implement connection management between a telematics terminal (Telematics-Box, T-BOX) in a vehicle and a service platform, the multiple functional modules include a platform management layer, an application service layer, a data distribution layer and a vehicle access layer.

[0063] In some embodiments, the electronic device generates a module relationship diagram based on the relationship between the multiple functional modules, including at least one of the following: the electronic device generates a layered architecture diagram based on the relationship between the multiple functional modules; the electronic device generates a module block diagram based on the relationship between the multiple functional modules.

[0064] It should be understood that the "layered architecture diagram" in the above scheme is used to show the different hierarchical structures of the software system, which may include multiple functional modules and the relationship between them. The "module block diagram" in the above scheme focuses on showing the internal structure of a single functional module and the calling relationship between functional modules.

[0065] Figure 3 It is a schematic diagram of generating a layered architecture diagram provided in an embodiment of the present application.

[0066] For example, Figure 3 As shown, a layered architecture diagram of the software system used to realize the connection management between the T-BOX in the vehicle and the service platform is shown. The layered architecture diagram includes functional modules such as the platform management layer, the application service layer, the data distribution layer and the vehicle access layer. Among them, the platform management layer includes authentication and authorization services, communication management services, device management services, event and alarm services and log and audit services. The authentication and authorization service is used to ensure that only legitimate T-BOX can connect to the service platform; the communication management service is responsible for the data transmission protocol management between the T-BOX and the service platform; the device management service is used to track and manage all T-BOXs; the event and alarm service is used to monitor the status of the T-BOX and output alarm information when the status is abnormal; the log and audit service is used to record the history of all operations and transactions for troubleshooting and security auditing. Among them, the application service layer includes communication services, data management services, business logic services and API gateway services. The communication service is responsible for the data exchange between the T-BOX and the service platform; the data management service is used to process the data from the T-BOX; the business logic service is used to implement specific business functions; the API gateway service provides users with an interface for interacting with the internal system. Among them, the data distribution layer includes data routing service, data aggregation service and data caching service. The data routing service is responsible for routing data to the destination based on predefined rules; the data aggregation service integrates data from multiple sources for subsequent analysis and processing; the data caching service is used to store frequently accessed data. Among them, the vehicle access layer includes data collection service, logging and analysis service and protocol conversion service. The data collection service is used to collect vehicle status data from T-BOX; the logging and analysis service is used to record the operation log and communication log of the vehicle access layer for subsequent analysis and auditing; the protocol conversion service is used to uniformly convert the vehicle status data from different vehicles into a data format that can be understood by the service platform.

[0067] It should be understood that Figure 3 The following is an example of a software system for realizing the connection management between the T-BOX in the vehicle and the service platform to describe the layered architecture diagram in the module relationship diagram. The module relationship diagram can also be a module block diagram, as shown below Figure 4Taking the software system as a new energy vehicle procurement system and the new energy vehicle procurement system including a procurement management module as an example, the module block diagram in the module relationship diagram is described.

[0068] Figure 4 It is a schematic diagram of a generation module block diagram provided in an embodiment of the present application.

[0069] For example, Figure 4 As shown, a module block diagram when the software system is a new energy vehicle procurement system and includes a procurement management module is shown, and the module block diagram is used to show the internal structure of the procurement management module and the calling relationship between the functional modules. Specifically, the procurement management module provides business processing services, which include a purchase order sub-service, a purchase receipt sub-service, a purchase invoice sub-service, a purchase return sub-service, a consignment sales warehousing sub-service, and a consignment sales return sub-service. The procurement management service also provides a document write-off service, which includes a purchase document write-off sub-service and a purchase order write-off sub-service. The procurement management service also provides a report analysis service, which includes a procurement summary table sub-service, a procurement detail table sub-service, a procurement order tracking table sub-service, a procurement price comparison table sub-service, a procurement type statistics table sub-service, and a procurement perspective analysis table sub-service. The procurement management service also provides a system maintenance service, which includes a network security sub-service and a data backup sub-service.

[0070] In one possible implementation, the multiple software design elements also include database design elements and / or interface design elements, the database design elements indicating data used by a software program corresponding to the target software design document, and the interface design elements indicating interfaces used by the software program. The electronic device in step 202 adds document content corresponding to the multiple software design elements in the initial software design document to positions of corresponding software design elements in the target template, including: the electronic device adds second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table, the target table including multiple preset fields; the electronic device adds target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template based on third document content corresponding to the interface design element in the initial software design document and interface information corresponding to multiple sample interfaces, the target interface information being information describing the interface after standardized processing.

[0071] It should be understood that the "interface design elements" in the above scheme can be regarded as APIs and interactive interfaces between users and software systems.

[0072] It should also be understood that the "multiple sample interfaces" in the above scheme refer to all interfaces used by software programs corresponding to multiple existing software systems, and the interface information corresponding to the sample interface is used to describe the basic functions and uses of the sample interface in a standardized manner, indicating the request format and request parameters of the sample interface, as well as the format of the response data.

[0073] In the above technical solution, when multiple software design elements include database design elements, the method adds the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table. In this way, the target software design document finally obtained includes the document content corresponding to the database design element in the initial software design document, which fully restores the document content in the initial software design document and avoids the loss of the document content in the initial software design document. Further, the method adds the second document content to the position of the corresponding database design element in the target template in the form of a target table. This enables the R&D personnel to clearly and clearly view the data used by the software program corresponding to the initial software design document and the specific purpose of each data. In addition, when multiple software design elements include interface design elements, the method adds the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces. In this way, the final target software design document includes standard interface description information of multiple interfaces used by the software program, which makes it easier for R&D personnel other than those who write the initial software design document to understand the interfaces used by the software program corresponding to the initial software design document.

[0074] In some embodiments, the plurality of preset fields include field name, field type, whether it is a primary key, data length, enumeration value, field description, and whether it is stored encrypted.

[0075] In one possible implementation, the electronic device adds the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces, including: the electronic device compares the interface design element in the third document content with the multiple sample interfaces, and determines multiple target interfaces that match the interface design element from the multiple sample interfaces; the electronic device determines the interface information corresponding to the multiple target interfaces as the target interface information, and adds the target interface information to the position of the corresponding interface design element in the target template.

[0076] It should be understood that the "target interface information" in the above solution is used to describe the basic functions and uses of the multiple target interfaces in a standardized manner, indicating the request format and request parameters of the multiple target interfaces, and the format of the response data.

[0077] In the above technical scheme, different R&D personnel have different document writing habits, and the interface description information of the same interface used by the software program written in the initial software design document may be different. The method compares the interface design elements in the content of the third document with the multiple sample interfaces, and determines multiple target interfaces that match the interface design elements from the multiple sample interfaces. In other words, the interface (multiple target interfaces) used in the software program corresponding to the initial software design document is clarified. Further, the interface information corresponding to the multiple target interfaces is determined as the target interface information, and the target interface information is added to the position of the corresponding interface design element in the target template. In this way, standard interface description information can be obtained, and the target software design document includes standard interface description information of multiple interfaces used by the software program, which is convenient for R&D personnel other than those who write the initial software design document to understand the interface used by the software program corresponding to the initial software design document, and improve the comprehensibility of the target software design document.

[0078] In one possible implementation, the multiple software design elements also include an interaction design element, which indicates the interaction between interfaces or functional modules in the software program corresponding to the target software design document. The electronic device in step 202 adds the document content corresponding to the multiple software design elements in the initial software design document to the position of the corresponding software design element in the target template, including: the electronic device determines from the initial software design document upstream and downstream interaction content used to indicate the interaction relationship between module division elements or interface design elements; the electronic device generates a target graphic based on the upstream and downstream interaction content and adds it to the position of the corresponding module division element or interface design element in the target template, and the target graphic is used to display the interaction relationship between the module division elements or interface design elements.

[0079] It should be understood that the "interaction design elements" in the above scheme can be simply understood as: the specific steps for interaction between interfaces or functional modules. The "upstream and downstream interaction content" in the above scheme generally refers to the data exchange and control flow between functional modules or interfaces in the software program corresponding to the software system. These interaction contents describe the flow path of information in the software system, the type of data transmitted, the triggering conditions of the interaction, and the responsibilities and behaviors of each component (functional module or interface) during the interaction process.

[0080] In the above technical solution, when multiple software design elements include interactive design elements, the method determines the upstream and downstream interactive content used to indicate the interactive relationship between module division elements or interface design elements from the initial software design document, and based on the upstream and downstream interactive content, generates a target graphic and adds it to the position of the corresponding module division element or interface design element in the target template. In this way, the target software design document finally obtained includes the interactive relationship and interactive logic between multiple functional modules and / or multiple interfaces used by the software program. Furthermore, this enables R&D personnel to better understand the software program corresponding to the initial software design document.

[0081] In some embodiments, the electronic device generates a target graphic based on the upstream and downstream interaction content and adds it to the position of the corresponding module division element or interface design element in the target template, including at least one of the following: the electronic device generates a Sankey diagram based on the upstream and downstream interaction content and adds it to the position of the corresponding module division element or interface design element in the target template; the electronic device generates a timing diagram based on the upstream and downstream interaction content and adds it to the position of the corresponding module division element or interface design element in the target template.

[0082] It should be understood that the "Sankey diagram" in the above scheme is used to visualize the size of data flow, so as to show the magnitude of flow between different functional modules or between different interfaces, and help software developers understand the flow path and distribution of data in the software system. The characteristic of the Sankey diagram is that the sum of the branch widths at the beginning and end is equal, that is, the sum of the widths of all main branches is equal to the sum of the widths of all branches branching out. The "timing diagram" in the above scheme is a UML interaction diagram, which describes the interaction and dynamic collaboration between multiple functional modules or multiple interfaces by showing the time sequence of sending information between functional modules or interfaces.

[0083] In one possible implementation, the electronic device in step 202 adds the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain the target software design document, including: the electronic device adds the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template; the electronic device configures a change history record table in the target area of ​​the target template to obtain the target software design document, the change history record table including the change items and change time when the content of the position in the target template is changed.

[0084] It should be understood that the "change items" in the above scheme include the specific content and method of change.

[0085] In the above technical solution, the document contents corresponding to the multiple software design elements in the initial software design document are added to the positions of the corresponding software design elements in the target template; a change history record table is configured in the target area of ​​the target template to obtain the target software design document. In this way, the target software design document finally obtained includes the changed items and change time when the content in the target template is changed, so that the R&D personnel can clearly understand the change records of the software design document, the change time and the changed items, and can make the software design document information symmetrical for different R&D personnel, which is conducive to the smooth progress of the software project and achieve the expected results.

[0086] In some embodiments, the change history record table also includes the person who made the change and the person who reviewed the change when the content of the location in the target template was changed.

[0087] In some embodiments, the target area is a top area of ​​a page in a home page of a target software design document.

[0088] In some embodiments, the electronic device in step 202 adds the document content corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain the target software design document, including: the electronic device divides the software system described in the initial software design document into modules to obtain the module level; the electronic device adds the document content corresponding to the multiple software design elements to the positions of the corresponding software design elements in the branch corresponding to the module level in the target template to obtain the target software design document.

[0089] In the above technical solution, the software system has corresponding module-level divisions. The method adds the document contents corresponding to the multiple software design elements to the positions of the corresponding software design elements in the corresponding branches at the module level in the target template, so that the contents at the corresponding module levels are added to the corresponding positions. This ultimately generates a modular target software design document. When the R&D personnel need to maintain the initial software design document later, they can quickly match the corresponding document contents.

[0090] In some embodiments, the module level includes any one of a service level, a platform level, a system level, and a function level.

[0091] It should be understood that the method 200 is used to transform an initial software design document into a target software design document through a plurality of software design elements and a target template.

[0092] In order to more clearly understand the structured framework of the target software design document in this application, as follows Figure 5 A detailed description is given using the home page of the target software design document as an example.

[0093] Figure 5It is a schematic diagram of the home page of a target software design document provided in an embodiment of the present application.

[0094] For example, Figure 5 As shown, the top area of ​​the page in the homepage of the target software design document is configured with a change history record table, which may include the change time, change items, change personnel and review personnel when the content in the target template corresponding to the target software design document is changed. The middle area in the homepage includes a structured design framework provided for the generation of the target software design document, which is a tree structure. All the contents in "2.4 System Functional Architecture" can be regarded as module division elements, "2.4.1 Internal Structure" can be regarded as the document content corresponding to the module division element in the target software design document is divided into multiple functional modules, and "2.4.1 Dependency" can be regarded as the relationship between the multiple functional modules. This branch may include a module relationship diagram generated based on the relationship between the multiple functional modules. All the contents in "3 Data Model Design" can be regarded as database design elements, and "3.1.1 Real-time Vehicle Status Table" can be regarded as a target table generated based on the document content corresponding to the database design element in the target software design document. All the contents in "4 Interface Model Design" can be regarded as interface design elements. All the contents in "5 Interaction Model Design" can be regarded as interaction design elements.

[0095] Figure 6 It is a structural schematic diagram of a document generation device provided in an embodiment of the present application.

[0096] For example, Figure 6 As shown, the device 600 includes:

[0097] Determining module 601: used for matching the document content in the initial software design document with a plurality of software design elements in response to the conversion operation on the initial software design document, and obtaining the document content corresponding to the plurality of software design elements, wherein the initial software design document is a software design document that has not been converted after being written, and the software design elements are core building blocks constituting the target software design document;

[0098] Generation module 602: used to add the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain the target software design document, which includes a structured design framework provided for the generation of the target software design document.

[0099] Optionally, the multiple software design elements include a module division element, which indicates the functional modules into which the software program corresponding to the target software design document is divided. The device 600 also includes: an adding module, which is used to perform module division on the first document content corresponding to the module division element in the initial software design document based on the software architecture of the software program corresponding to the initial software design document, to obtain multiple functional modules, and add the multiple functional modules to the positions of the corresponding module division elements in the target template; based on the relationship between the multiple functional modules, generate a module relationship diagram, and add the module relationship diagram to the positions of the corresponding module division elements in the target template.

[0100] Optionally, the multiple software design elements also include database design elements and / or interface design elements, the database design elements indicating data used by the software program corresponding to the target software design document, and the interface design elements indicating interfaces used by the software program, and the adding module is specifically used to: add the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table, the target table including multiple preset fields; based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to multiple sample interfaces, add the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template, the target interface information being information describing the interface after standardized processing.

[0101] Optionally, the determination module 601 is specifically used to compare the interface design elements in the third document content with the multiple sample interfaces, and determine multiple target interfaces that match the interface design elements from the multiple sample interfaces; the adding module is also specifically used to determine the interface information corresponding to the multiple target interfaces as the target interface information, and add the target interface information to the position of the corresponding interface design element in the target template.

[0102] Optionally, the multiple software design elements also include an interaction design element, which indicates the interaction between interfaces or functional modules in the software program corresponding to the target software design document. The determination module is specifically used to determine, from the initial software design document, upstream and downstream interaction content indicating the interaction relationship between module division elements or interface design elements; the adding module is specifically used to generate a target graphic based on the upstream and downstream interaction content and add it to the position of the corresponding module division element or interface design element in the target template, and the target graphic is used to display the interaction relationship between the module division elements or interface design elements.

[0103] Optionally, the adding module is further used to add the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template; the generating module 602 is specifically used to configure a change history record table in the target area of ​​the target template to obtain the target software design document, wherein the change history record table includes the change items and change time when the content of the position in the target template is changed.

[0104] Optionally, the device 600 also includes: a matching module, used for any of the following: matching the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by manual operation of the target object; matching the document content in the initial software design document with multiple software design elements in response to the conversion operation on the initial software design document when the current moment matches the preset moment; matching the document content in the initial software design document with multiple software design elements in response to the conversion operation triggered by an upload operation of the initial software design document.

[0105] Figure 7 It is a structural schematic diagram of an electronic device provided in an embodiment of the present application.

[0106] For example, Figure 7 As shown, the electronic device 700 includes: a memory 701 and a processor 702, wherein the memory 701 stores an executable program code 703, and the processor 702 is used to call and execute the executable program code 703 to perform a document generation method.

[0107] In addition, an embodiment of the present application also protects a device, which may include a memory and a processor, wherein the memory stores executable program code, and the processor is used to call and execute the executable program code to execute a document generation method provided by an embodiment of the present application.

[0108] In this embodiment, the functional modules of the device can be divided according to the above method example. For example, each functional module can be corresponded, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware. It should be noted that the division of modules in this embodiment is schematic and is only a logical function division. There may be other division methods in actual implementation.

[0109] In the case of dividing each functional module according to each function, the device may also include a determination module, a generation module, an addition module, an extraction module, a matching module, etc. It should be noted that all relevant contents involved in the above method embodiment can be referred to the functional description of the corresponding functional module, which will not be repeated here.

[0110] It should be understood that the device provided in this embodiment is used to execute the above-mentioned document generation method, and thus can achieve the same effect as the above-mentioned implementation method.

[0111] In the case of an integrated unit, the device may include a processing module and a storage module. When the device is applied to an electronic device, the processing module may be used to control and manage the actions of the electronic device. The storage module may be used to support the electronic device in executing related executable program codes, etc.

[0112] The processing module may be a processor or a controller, which may implement or execute various exemplary logic blocks, modules and circuits shown in conjunction with the disclosure of the present application. The processor may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc. The storage module may be a memory.

[0113] In addition, the device provided in the embodiments of the present application may specifically be a chip, component or module, and the chip may include a connected processor and memory; wherein the memory is used to store instructions, and when the processor calls and executes the instructions, the chip can execute a document generation method provided in the above embodiments.

[0114] This embodiment also provides a computer-readable storage medium, in which executable program code is stored. When the executable program code is run on a computer, the computer executes the above-mentioned related method steps to implement a document generation method provided by the above embodiment.

[0115] This embodiment also provides a computer program product. When the computer program product runs on a computer, it enables the computer to execute the above-mentioned related steps to implement a document generation method provided by the above embodiment.

[0116] Among them, the device, computer-readable storage medium, computer program product or chip provided in this embodiment is used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here.

[0117] Through the description of the above implementation methods, technical personnel in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0118] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0119] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A document generation method, characterized in that: The method comprises: In response to a conversion operation on an initial software design document, matching the document content in the initial software design document with a plurality of software design elements to obtain document content corresponding to the plurality of software design elements, wherein the initial software design document is a software design document that has not been converted after being written, and the software design elements are core building blocks constituting the target software design document; The document contents corresponding to the multiple software design elements in the initial software design document are added to the positions of the corresponding software design elements in the target template to obtain a target software design document, wherein the target template includes a structured design framework provided for the generation of the target software design document.

2. The method according to claim 1, characterized in that The multiple software design elements include module division elements, the module division elements indicating functional modules into which the software program corresponding to the target software design document is divided, and adding the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template includes: Based on the software architecture of the software program corresponding to the initial software design document, module-dividing the first document content corresponding to the module division element in the initial software design document to obtain a plurality of functional modules, and adding the plurality of functional modules to the positions of the corresponding module division elements in the target template; Based on the relationship between the multiple functional modules, a module relationship diagram is generated, and the module relationship diagram is added to the position of the corresponding module division element in the target template.

3. The method according to claim 2, characterized in that The multiple software design elements further include database design elements and / or interface design elements, wherein the database design elements indicate data used by a software program corresponding to the target software design document, and the interface design elements indicate an interface used by the software program, and the adding of document contents corresponding to the multiple software design elements in the initial software design document to positions of corresponding software design elements in the target template comprises: Adding the second document content corresponding to the database design element in the initial software design document to the position of the corresponding database design element in the target template in the form of a target table, wherein the target table includes a plurality of preset fields; Based on the third document content corresponding to the interface design elements in the initial software design document and the interface information corresponding to multiple sample interfaces, the target interface information corresponding to the initial software design document is added to the position of the corresponding interface design elements in the target template, and the target interface information is the information describing the interface after standardized processing.

4. The method according to claim 3, characterized in that The adding the target interface information corresponding to the initial software design document to the position of the corresponding interface design element in the target template based on the third document content corresponding to the interface design element in the initial software design document and the interface information corresponding to the plurality of sample interfaces comprises: Comparing the interface design elements in the third document content with the multiple sample interfaces, and determining multiple target interfaces matching the interface design elements from the multiple sample interfaces; The interface information corresponding to the multiple target interfaces is determined as the target interface information, and the target interface information is added to the position of the corresponding interface design element in the target template.

5. The method according to claim 1, characterized in that The plurality of software design elements further include interactive design elements, wherein the interactive design elements indicate interactions between interfaces or functional modules in a software program corresponding to the target software design document, and the adding of document contents corresponding to the plurality of software design elements in the initial software design document to positions of corresponding software design elements in the target template comprises: Determining upstream and downstream interaction content for indicating the interaction relationship between module division elements or interface design elements from the initial software design document; Based on the upstream and downstream interaction content, a target graphic is generated and added to the position of the corresponding module division element or interface design element in the target template, and the target graphic is used to display the interaction relationship between the module division elements or interface design elements.

6. The method according to claim 1, characterized in that The step of adding the document contents corresponding to the plurality of software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain the target software design document comprises: Adding document contents corresponding to the plurality of software design elements in the initial software design document to positions of corresponding software design elements in the target template; A change history record table is configured in the target area in the target template to obtain a target software design document, wherein the change history record table includes the change items and change time when the content of the position in the target template is changed.

7. The method according to any one of claims 1 to 6, characterized in that In response to the conversion operation on the initial software design document, matching the document content in the initial software design document with a plurality of software design elements includes any one of the following: In response to the conversion operation triggered by a manual operation of the target object, matching the document content in the initial software design document with a plurality of software design elements; When the current time matches the preset time, in response to the conversion operation on the initial software design document, matching the document content in the initial software design document with a plurality of software design elements; In response to the conversion operation triggered by the upload operation of the initial software design document, the document content in the initial software design document is matched with a plurality of software design elements.

8. A document generation device, characterized in that: The device comprises: A determination module is used for matching the document content in the initial software design document with a plurality of software design elements in response to a conversion operation on an initial software design document, so as to obtain the document content corresponding to the plurality of software design elements, wherein the initial software design document is a software design document that has not been converted after being written, and the software design elements are core building blocks constituting the target software design document; A generation module is used to add the document contents corresponding to the multiple software design elements in the initial software design document to the positions of the corresponding software design elements in the target template to obtain a target software design document, wherein the target template includes a structured design framework provided for the generation of the target software design document.

9. An electronic device, characterized in that: The electronic device comprises: A memory for storing executable program codes; A processor, configured to call and run the executable program code from the memory, so that the electronic device executes the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores an executable program code, and when the executable program code is executed, the method according to any one of claims 1 to 7 is implemented.