CN110837727A - Document template generation method and device, terminal equipment and medium - Google Patents

Document template generation method and device, terminal equipment and medium Download PDF

Info

Publication number
CN110837727A
CN110837727A CN201911012417.9A CN201911012417A CN110837727A CN 110837727 A CN110837727 A CN 110837727A CN 201911012417 A CN201911012417 A CN 201911012417A CN 110837727 A CN110837727 A CN 110837727A
Authority
CN
China
Prior art keywords
document
identification data
text content
information
attribute information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911012417.9A
Other languages
Chinese (zh)
Other versions
CN110837727B (en
Inventor
林俊杰
王建华
徐潇
顾鹏
韩巍
金钰鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Value Online Information Technology Co Ltd
Original Assignee
Shenzhen Value Online Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Value Online Information Technology Co Ltd filed Critical Shenzhen Value Online Information Technology Co Ltd
Priority to CN201911012417.9A priority Critical patent/CN110837727B/en
Publication of CN110837727A publication Critical patent/CN110837727A/en
Application granted granted Critical
Publication of CN110837727B publication Critical patent/CN110837727B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Document Processing Apparatus (AREA)

Abstract

The application is applicable to the technical field of computers, and provides a document template generation method, a device, a terminal device and a medium, wherein the method comprises the following steps: acquiring generated document identification data; receiving a document of a template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data; replacing each identified text content in the document by adopting the name of the attribute information; and saving the replaced document as a document template. The method can reduce the difficulty of making the document template.

Description

Document template generation method and device, terminal equipment and medium
Technical Field
The present application belongs to the field of computer technologies, and in particular, to a method and an apparatus for generating a document template, a terminal device, and a medium.
Background
Various documents are often used in various office scenarios today to record information or send notifications, such as meeting notifications, meeting minutes, etc., and such documents are often in a fixed format. If the documents with fixed formats can be written according to the document template, much time is saved. For the situation, a template can be manufactured by adopting a template manufacturing language, but the template manufacturing language has the problems of high manufacturing difficulty, high programming thinking requirement and the like, and is difficult to realize by non-technical personnel.
Disclosure of Invention
The embodiment of the application provides a document template generation method, a document template generation device, terminal equipment and a medium, and the document template matched with a document can be generated by utilizing the existing document.
In a first aspect, an embodiment of the present application provides a document template generating method, including:
acquiring generated document identification data;
receiving a document of a template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data;
replacing each identified text content in the document by adopting the name of the attribute information;
and saving the replaced document as a document template.
In a second aspect, an embodiment of the present application provides a document template generating apparatus, including:
an acquisition module for acquiring the generated document identification data;
the identification module is used for receiving the document of the template to be generated and identifying the attribute information corresponding to each text content in the document according to the document identification data;
the replacing module is used for replacing each identified text content in the document by adopting the name of the attribute information;
and the storage module is used for storing the replaced document as a document template.
In a third aspect, an embodiment of the present application provides a terminal device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the document template generating method according to the first aspect when executing the computer program.
In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, where a computer program is stored, and when being executed by a processor, the computer program implements the document template generating method according to the first aspect.
In a fifth aspect, an embodiment of the present application provides a computer program product, which, when run on a terminal device, causes the terminal device to execute the document template method according to any one of the first aspect.
Compared with the prior art, the embodiment of the application has the advantages that: identifying the document of the template to be generated through the generated document identification data, identifying attribute information corresponding to each text content in the document, then replacing each identified text content in the document by adopting the name of the attribute information, and saving the replaced document as the document template. The document template is generated through the document, so that the difficulty of making the document template can be reduced, and non-technical personnel can also quickly generate the template file
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
FIG. 1 is a flowchart illustrating a document template generating method according to an embodiment of the present application;
FIG. 2 is a flowchart illustrating a document template generating method according to a second embodiment of the present application;
FIG. 3 is a flowchart illustrating a document template generating method according to a third embodiment of the present application;
FIG. 4 is a schematic structural diagram of a document template generating apparatus according to a fourth embodiment of the present application;
fig. 5 is a schematic structural diagram of a terminal device according to a fifth embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
Fig. 1 is a schematic flowchart of a document template generating method provided in an embodiment of the present application, and as shown in fig. 1, the method includes the following steps:
s101, acquiring generated document identification data;
in this embodiment, an execution subject of the document template generating method is a terminal device with a document editing and identifying function, which may be a computer, a mobile phone, a tablet computer, or a server.
The document identification data may be regarded as a specification or rule for subsequently identifying the document content, and may be obtained through machine learning. Document identification data may be obtained through machine learning prior to document template generation.
S102, receiving a document of a template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data;
the document to be generated is generally in a fixed format, such as a company meeting notification file, a meeting record file, and the like, and is also commonly used in enterprises.
Specifically, a document of the template to be generated is received, and the machine identifies the content of the document according to the document identification data, and identifies attribute information corresponding to each text content in the document.
Illustratively, a conference notification file is selected as a document of a template to be generated, and if the document includes "host: mr. zhang for president "for the president's position," mr. zhang "for the president's name, and" major "for the president's gender when the template is generated.
S103, replacing each identified text content in the document by adopting the name of the attribute information;
specifically, after the attribute information corresponding to each text content in the document is identified, each text content identified in the original document may be replaced with the name of the attribute information corresponding to the text content. Illustratively, when it is recognized that the attribute information corresponding to "president" in the text content is "president position", the president in the document is replaced with "president position".
Furthermore, each text content can be replaced by adopting a Jinja (a template making language based on Python) template language corresponding to the attribute information, so that the text content can be conveniently edited by utilizing a computer technology in the subsequent template using process. Illustratively, for "president" in a document, replace with "{ { president position } }".
And S104, saving the replaced document as a document template.
Specifically, after each text content in the document is identified and replaced, the obtained document is a document template, and may be stored in a preset position.
In the embodiment, the document template is generated by performing text recognition and replacement on the original document, so that the technical threshold required for editing the document template is reduced, and the generation process of the document template is simplified.
Fig. 2 is a flowchart of a document template generating method provided in the second embodiment of the present application, and as shown in fig. 2, the method includes the following steps:
s201, acquiring a first preset number of first documents, wherein each first document comprises a plurality of marking information, any marking information corresponds to one text content in the first document, and the marking information is used for identifying attribute information of the corresponding text content;
in this embodiment, an execution subject of the document template generating method is a terminal device with a document editing and identifying function, which may be a computer, a mobile phone, a tablet computer, or a server, and the specific type of the device is not limited in this embodiment.
In particular, a certain number of related files may be obtained through the board secret of the enterprise or other related organization. For example, if a conference document template needs to be generated from a conference-related document, a certain number of conference-related files such as a conference notification, a conference record, and a conference check-in table may be obtained from the board of director. Selecting a certain number of documents from the documents as first documents, labeling the first documents, and labeling attribute information corresponding to text contents in the documents.
S202, generating initial document identification data according to the first document;
s202 may specifically include the following sub-steps:
s2021, identifying associated information of each text content labeled in the first document, wherein the associated information comprises position information, preposition content information, postition content information and grammar information of each text content;
specifically, the associated information may include the content of each text content marked, syntax information, position information in the document, preposition content information, postition content information, and the like. Illustratively, if the first document is a meeting notification file, there is a "recorder: the secretary of president, lie four ", where" secretary of president "is labeled" president job "; in the machine identification process, the associated information of "board leader secretary" including words having a job feature such as "secretary" itself can be identified, and "recorder: "so may have a sentence with identifying information followed by a name such as" Liquan ".
S2022, according to the associated information of each labeled text content and the label corresponding to the associated information, establishing a corresponding relation between the associated information and the attribute information, and generating initial document identification data.
Specifically, after the machine identifies the associated information of the labeled content in the document, machine learning can be performed through the associated information of the labeled content and the corresponding label, and the corresponding relationship between the associated information and the attribute information can be established. Illustratively, when the related information content includes a word having a job feature such as "secretary", a "recorder: the sentence with the identification information is arranged, and when the name of the person such as "Liquan" is arranged behind the sentence, the corresponding attribute information is used for recording the job title of the person. The document identification data may be formed to include that when a certain text content includes a word with a title, information with a colon is positioned in front of the word, and a name is positioned behind the word, the text content may be identified as information before the colon is positioned in front of the word plus the title.
It should be noted that there are various algorithms and implementations of the machine learning process, which are not limited in this embodiment.
S203, acquiring a second preset number of second documents, adopting the initial document identification data to sequentially identify each second document, and marking attribute information corresponding to each text content in the second documents;
the initial document identification data may be obtained by machine learning a first preset number of first documents with labels, but the identification rate of the initial identification data to the document content may not be high, and thus the initial document identification data needs to be updated.
A second predetermined number of second documents, which may be documents obtained from the board of directors or other company departments, or documents that have been manually created, such as by combining the first documents differently, or by adding some other form of presentation, may be selected to update the initial document identification data.
Specifically, the initial document identification data is used for carrying out machine identification on the second document, attribute information corresponding to text content in the second document is identified through a machine, and the attribute information is written in the document as a label.
S204, acquiring label correction information aiming at the second document, and updating the initial document identification data according to attribute information corresponding to each text content in the second document and the label correction information;
specifically, the label of the second document by the machine is not necessarily correct, so that the label needs to be corrected to obtain the label correction information of the second document, and then the initial document identification data can be updated according to the label correction information, the second document and the label of the second document by the machine.
S204 may specifically include the following substeps:
s2041, marking each text content of any second document by adopting the initial document identification data;
specifically, one second document is randomly selected from the second documents with the second preset number, the second document is identified by using the initial document identification data, the attribute information corresponding to each text content is identified, and the attribute information is marked in the document.
S2042, updating the initial document identification data according to the label correction information and the label information in the second document to obtain intermediate document identification data;
specifically, since the machine does not necessarily label the second document correctly, label correction information is acquired, where the label of the second document is revised, for example, text content that is not recognized by the machine is labeled, and wrong content labeled by the machine is corrected. The initial document identification data can be updated to obtain intermediate document identification data through machine learning according to the label correction information and the label of the machine to the second document.
And S2043, labeling the text contents of the rest second documents one by adopting the intermediate document identification data, and updating the intermediate document identification data according to the label correction information and the label information in each second document.
Specifically, the remaining second documents are selected, the second documents are subjected to sum labeling by adopting the intermediate document identification data, the labeling correction information is obtained, and the intermediate document identification specification is updated according to the labeling correction information and the labeling information of the second documents. The machine labels the remaining second documents one by one, and then updates the identification data of the intermediate documents through machine learning, wherein it needs to be noted that each time a new second document is identified and labeled, an intermediate document identification specification updated according to the previous second document is adopted during identification and labeling; once a second document is identified and labeled, the label correction information is acquired and the intermediate document identification data is updated.
Further, the intermediate document identification data may be updated once according to a preset number of second documents. For example, if the preset number is 5, the labeling correction information of 5 second documents may be obtained after the 5 second documents are identified and labeled, then the intermediate document identification data is updated once according to the labeling correction information and the labeling information of the 5 second documents, and then the 5 second documents are identified and labeled by the updated intermediate document identification data, which is repeated in this way, and the intermediate document identification data is updated once every 5 second documents.
S205, when the initial document identification data is updated by adopting all the second documents, outputting document identification data;
specifically, when the last second document is identified, the second document is marked by adopting the current intermediate document identification specification or the initial document identification specification, then marking correction information is obtained, and the current initial document identification data or the intermediate document identification data is updated according to the marking correction information and the marking information to obtain document identification data.
Furthermore, after the annotation correction information is obtained each time, the annotation accuracy can be calculated according to the annotation correction information and the annotation of the machine to the second document. If the marking accuracy rate exceeds the preset value, after the intermediate document identification data or the initial document identification data is updated at this time, the remaining second documents are not marked any more. Illustratively, the annotation accuracy preset value may represent a usage criterion, such as 98%.
S206, acquiring the generated document identification data;
s207, receiving a document of the template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data;
s208, replacing each identified text content in the document by adopting the name of the attribute information;
s209, saving the replaced document as a document template.
The above-mentioned S206-209 are similar to the above-mentioned S101-104, and may refer to each other, which are not described again in this embodiment.
In the embodiment, a large number of files and combinations of the files are adopted for machine learning, so that the accurate identification of the documents is realized, the identified text contents are correspondingly replaced, the corresponding document templates can be simply generated by the documents, the document template editing process is simplified, and the technical threshold of document template editing is reduced.
Fig. 3 is a flowchart of a document template generating method provided in a third embodiment of the present application, and as shown in fig. 3, the method includes the following steps:
s301, acquiring generated document identification data;
in this embodiment, an execution subject of the document template generating method is a terminal device with a document editing and identifying function, which may be a computer, a mobile phone, a tablet computer, or a server, and the specific type of the device is not limited in this embodiment.
Specifically, a large number of documents may be subjected to text recognition learning in a machine learning manner, so as to obtain document recognition data. It should be noted that there are many ways and algorithms for machine learning, and text recognition can be learned through any machine learning way and algorithm, and this embodiment does not limit the way of machine learning.
S302, receiving a document of a template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data;
specifically, a document of the template to be generated is received, and attribute information corresponding to each text content in the document is identified according to the document identification data. For example, there is a "hold mode: and communication, namely identifying the attribute information corresponding to the communication as a 'holding mode'.
The text recognition data is generated based on a large number of files, and in the process of recognizing the text, the attribute value corresponding to the attribute information can be recognized in various situations. For example, it can be recognized that the attribute information "holding mode" corresponds to two attribute values "video conference" and "live conference".
S303, replacing each identified text content in the document by adopting the name of the attribute information;
specifically, after the attribute information corresponding to each text content in the document is identified, each text content identified in the original document may be replaced with the name of the attribute information corresponding thereto. In the replacement process, data in a specific format can be used for replacement, for example, Jinja template language can be used, and double braces ({ }) are added before and after the attribute information to replace the text content.
S304, identifying target text content in the document, wherein the target text content is associated with at least one other text content, the target name of the attribute information of the target text content comprises a plurality of target names, and any target name is associated with the name of the attribute information of at least one other text content;
in particular, at the time of replacement, there is a value of some target text content that may determine the value of one or more text contents. For example, it can be recognized that if the holding time is "monday", the holding mode is "live meeting"; if the holding time is "weekday", the holding mode is "video conference".
S305, replacing the target text content by adopting the plurality of target names and the associated names of the attribute information of the other text contents;
specifically, it may be written as replacement information in the document template at the time of replacement. Illustratively, it is recognized that if the holding time is "monday", the holding mode is "live meeting"; if the holding time is "weekday", the holding mode is "video conference", and when the replacement is performed, the holding mode may be written in the document template by using a selection sentence, and when the document is edited by using the generated document template, if the holding time is selected, the holding mode may be determined accordingly.
Further, the text content in the document may exist in multiple forms of expression, identifying the target text content in the document. One expression form in the multiple expression forms can be determined as a target expression form, the name corresponding to the attribute information of the target text content is processed according to the target expression form, and the processed name is adopted to replace the target text content. Illustratively, there are a variety of expressions of time, such as "1 month 1 day of 2018", "2018-1-1", and "2018.1.1", all expressing the same meaning. During identification, if time is identified, the form of 'M month and D day in Y year' and attribute information are adopted for replacement. For example, "1/2018", "2018-1-1" and "2018.1.1" are each replaced with { 'Y year M/month d/day' | date format conversion (summons date) }.
S306, saving the replaced document as a document template.
Specifically, the replaced document is a document template which is finally needed, and is stored in a preset position.
In the embodiment, the document template is generated by recognizing and replacing the document content through the text, so that the generation process of the document template is simplified; in the process of generating the document template, the text content association relation and the options are written into the document template, so that the document template is convenient to use.
FIG. 4 is a schematic structural diagram of a document template generating apparatus according to a fourth embodiment of the present application;
an acquisition module 41 for acquiring the generated document identification data;
the identification module 42 is configured to receive a document of a template to be generated, and identify attribute information corresponding to each text content in the document according to the document identification data;
a replacing module 43, configured to replace each text content identified in the document with a name of the attribute information;
and a storage module 44, configured to store the replaced document as a document template.
In this embodiment, the document template generating apparatus further includes the following modules:
the first document acquisition module is used for acquiring a first document with a first preset number, wherein the first document comprises a plurality of marking information, any marking information corresponds to one text content in the first document, and the marking information is used for identifying attribute information of the corresponding text content;
the initial document identification data generation module is used for generating initial document identification data according to the first document;
the second document acquisition module is used for acquiring a second preset number of second documents, sequentially identifying each second document by adopting the initial document identification data, and marking attribute information corresponding to each text content in each second document;
an initial document identification data updating module, configured to acquire label correction information for the second document, and update the initial document identification data according to attribute information corresponding to each text content in the second document and the label correction information;
and the document identification data output module is used for outputting the document identification data after the initial document identification data is updated by adopting all the second documents.
In this embodiment, the initial document identification data generating module may specifically include the following sub-modules:
the first document identification submodule is used for identifying the associated information of each text content marked in the first document, wherein the associated information comprises the position information, the front set content information, the rear set content information and the grammar information of each text content;
and the initial document identification data generation submodule is used for establishing a corresponding relation between the associated information and the attribute information according to the associated information of each marked text content and the corresponding mark thereof, and generating initial document identification data.
In this embodiment, the initial document identification data updating module may specifically include the following sub-modules:
the marking submodule is used for marking each text content of any second document by adopting the initial document identification data;
the intermediate document identification data generation submodule is used for updating the initial document identification data according to the label correction information and the label information in the second document to obtain intermediate document identification data;
and the intermediate document identification data updating sub-module is used for marking the text contents of the rest second documents one by adopting the intermediate document identification data, and updating the intermediate document identification data according to the marking correction information and the marking information in each second document.
In this embodiment, the document template generating apparatus may further include the following modules:
the marking accuracy rate calculating module is used for calculating the marking accuracy rate of each text content of the marked second document;
and the marking termination module is used for taking initial document identification data or intermediate document identification data obtained by updating according to the current second document as document identification data and terminating marking of the rest second document if the marking accuracy exceeds a preset value.
In this embodiment, the document generating apparatus may further include the following modules:
the target text content identification module is used for identifying target text content in the document, the target text content is associated with at least one other text content, the target name of the attribute information of the target text content comprises a plurality of target names, and any target name is associated with the name of the attribute information of at least one other text content;
and the target text content replacing module is used for replacing the target text content by adopting the plurality of target names and the associated names of the attribute information of the other text contents.
In this embodiment, the target text content identification module is further configured to identify target text content in the document, where the target text content includes multiple expression forms;
the target text content replacing module is further configured to determine a target expression form of the multiple expression forms, process a name corresponding to the attribute information of the target text content according to the target expression form, and replace the text content with the processed name.
Fig. 5 is a schematic structural diagram of a terminal device according to a fifth embodiment of the present application. As shown in fig. 5, the terminal device 5 of this embodiment includes: at least one processor 50 (only one shown in fig. 5), a memory 51, and a computer program 52 stored in the memory 51 and operable on the at least one processor 50, the processor 50 implementing the steps in any of the various document template generation method embodiments described above when executing the computer program 52.
The terminal device 5 may be a computing terminal device such as a desktop computer, a notebook computer, a palm computer, and a cloud server. The terminal device may include, but is not limited to, a processor 50, a memory 51. Those skilled in the art will appreciate that fig. 5 is merely an example of the terminal device 5, and does not constitute a limitation of the terminal device 5, and may include more or less components than those shown, or combine some components, or different components, such as input and output terminal devices, network access terminal devices, and the like.
The Processor 50 may be a Central Processing Unit (CPU), and the Processor 50 may be other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 51 may in some embodiments be an internal storage unit of the terminal device 5, such as a hard disk or a memory of the terminal device 5. The memory 51 may also be an external storage terminal device of the terminal device 5 in other embodiments, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash card (FlashCard), and the like, which are provided on the terminal device 5. Further, the memory 51 may also include both an internal storage unit of the terminal device 5 and an external storage terminal device. The memory 51 is used for storing an operating system, an application program, a BootLoader (BootLoader), data, and other programs, such as program codes of the computer program. The memory 51 may also be used to temporarily store data that has been output or is to be output.
It should be noted that, for the information interaction, execution process, and other contents between the above-mentioned devices/units, the specific functions and technical effects thereof are based on the same concept as those of the embodiment of the method of the present application, and specific reference may be made to the part of the embodiment of the method, which is not described herein again.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the steps in the above-mentioned method embodiments.
The embodiments of the present application provide a computer program product, which when running on a mobile terminal, enables the mobile terminal to implement the steps in the above method embodiments when executed.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium and can implement the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer readable medium may include at least: any entity or device capable of carrying computer program code to a photographing apparatus/terminal apparatus, a recording medium, computer memory, Read-only memory (ROM), random-access memory (RAM), an electrical carrier signal, a telecommunications signal, and a software distribution medium. Such as a usb-disk, a removable hard disk, a magnetic or optical disk, etc. In certain jurisdictions, computer-readable media may not be an electrical carrier signal or a telecommunications signal in accordance with legislative and patent practice.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/network device and method may be implemented in other ways. For example, the above-described apparatus/network device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implementing, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.

Claims (10)

1. A document template generation method is characterized by comprising the following steps:
acquiring generated document identification data;
receiving a document of a template to be generated, and identifying attribute information corresponding to each text content in the document according to the document identification data;
replacing each identified text content in the document by adopting the name of the attribute information;
and saving the replaced document as a document template.
2. The method of claim 1, prior to said obtaining generated document identification data, further comprising:
acquiring a first document with a first preset number, wherein the first document comprises a plurality of marking information, any marking information corresponds to one text content in the first document, and the marking information is used for identifying attribute information of the corresponding text content;
generating initial document identification data according to the first document;
acquiring a second preset number of second documents, sequentially identifying each second document by adopting the initial document identification data, and marking out attribute information corresponding to each text content in the second documents;
acquiring label correction information aiming at the second document, and updating the initial document identification data according to attribute information corresponding to each text content in the second document and the label correction information;
and outputting the document identification data after the initial document identification data is updated by all the second documents.
3. The method of claim 2, wherein generating initial document identification data from the first document comprises:
identifying the associated information of each text content marked in the first document, wherein the associated information comprises position information, prepositioned content information, postpositioned content information and grammar information of each text content;
and establishing a corresponding relation between the associated information and the attribute information according to the associated information of each labeled text content and the label corresponding to the associated information, and generating initial document identification data.
4. The method according to claim 2, wherein the updating the initial document data based on the attribute information and the annotation correction information corresponding to each text content in the second document comprises:
marking each text content of any second document by adopting the initial document identification data;
updating the initial document identification data according to the label correction information and the label information in the second document to obtain intermediate document identification data;
and marking the text contents of the rest second documents one by adopting the intermediate document identification data, and updating the intermediate document identification data according to the marking correction information and the marking information in each second document.
5. The method of claim 4, further comprising:
calculating the labeling accuracy of each text content of the labeled second document;
and if the marking accuracy rate exceeds a preset value, using initial document identification data or intermediate document identification data obtained by updating according to the current second document as document identification data, and stopping marking the rest of the second document.
6. The method of claim 1, further comprising;
identifying target text content in the document, wherein the target text content is associated with at least one other text content, the target name of the attribute information of the target text content comprises a plurality of target names, and any target name is associated with the name of the attribute information of at least one other text content;
and replacing the target text content by adopting the plurality of target names and the associated names of the attribute information of the other text contents.
7. The method of claim 1, further comprising:
identifying target textual content in the document, the target textual content including a plurality of expressions;
and determining a target expression form in the multiple expression forms, processing the name corresponding to the attribute information of the target text content according to the target expression form, and replacing the text content by adopting the processed name.
8. A document template generation apparatus, comprising:
an acquisition module for acquiring the generated document identification data;
the identification module is used for receiving the document of the template to be generated and identifying the attribute information corresponding to each text content in the document according to the document identification data;
the replacing module is used for replacing each identified text content in the document by adopting the name of the attribute information;
and the storage module is used for storing the replaced document as a document template.
9. A terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the method according to any of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1 to 7.
CN201911012417.9A 2019-10-23 2019-10-23 Document template generation method, device, terminal equipment and medium Active CN110837727B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911012417.9A CN110837727B (en) 2019-10-23 2019-10-23 Document template generation method, device, terminal equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911012417.9A CN110837727B (en) 2019-10-23 2019-10-23 Document template generation method, device, terminal equipment and medium

Publications (2)

Publication Number Publication Date
CN110837727A true CN110837727A (en) 2020-02-25
CN110837727B CN110837727B (en) 2023-12-01

Family

ID=69575771

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911012417.9A Active CN110837727B (en) 2019-10-23 2019-10-23 Document template generation method, device, terminal equipment and medium

Country Status (1)

Country Link
CN (1) CN110837727B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111581937A (en) * 2020-05-15 2020-08-25 航天科工智慧产业发展有限公司 Document generation method and device, computer readable medium and electronic equipment
CN113011151A (en) * 2021-04-20 2021-06-22 平安科技(深圳)有限公司 Method, device and equipment for generating requirement document template and storage medium
WO2023160578A1 (en) * 2022-02-22 2023-08-31 北京字跳网络技术有限公司 Information processing method and apparatus, and terminal and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107783949A (en) * 2016-08-24 2018-03-09 北京神州泰岳软件股份有限公司 A kind for the treatment of method and apparatus of PPT documents
CN109657209A (en) * 2018-10-16 2019-04-19 深圳壹账通智能科技有限公司 Replacement method, device, equipment and the computer storage medium of content of text
CN110134959A (en) * 2019-05-15 2019-08-16 第四范式(北京)技术有限公司 Named Entity Extraction Model training method and equipment, information extraction method and equipment
CN110263338A (en) * 2019-06-18 2019-09-20 北京明略软件系统有限公司 Replace entity name method, apparatus, storage medium and electronic device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107783949A (en) * 2016-08-24 2018-03-09 北京神州泰岳软件股份有限公司 A kind for the treatment of method and apparatus of PPT documents
CN109657209A (en) * 2018-10-16 2019-04-19 深圳壹账通智能科技有限公司 Replacement method, device, equipment and the computer storage medium of content of text
CN110134959A (en) * 2019-05-15 2019-08-16 第四范式(北京)技术有限公司 Named Entity Extraction Model training method and equipment, information extraction method and equipment
CN110263338A (en) * 2019-06-18 2019-09-20 北京明略软件系统有限公司 Replace entity name method, apparatus, storage medium and electronic device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111581937A (en) * 2020-05-15 2020-08-25 航天科工智慧产业发展有限公司 Document generation method and device, computer readable medium and electronic equipment
CN113011151A (en) * 2021-04-20 2021-06-22 平安科技(深圳)有限公司 Method, device and equipment for generating requirement document template and storage medium
CN113011151B (en) * 2021-04-20 2022-03-18 平安科技(深圳)有限公司 Method, device and equipment for generating requirement document template and storage medium
WO2023160578A1 (en) * 2022-02-22 2023-08-31 北京字跳网络技术有限公司 Information processing method and apparatus, and terminal and storage medium

Also Published As

Publication number Publication date
CN110837727B (en) 2023-12-01

Similar Documents

Publication Publication Date Title
CN110837727B (en) Document template generation method, device, terminal equipment and medium
CN107657051B (en) Picture label generation method, terminal device and storage medium
US20210365421A1 (en) Data analysis method, computer device and storage medium
US20210049711A1 (en) Method of automatically transmitting data information and device of automatically transmitting data information
CN110472109B (en) Dynamic data quality analysis method and platform system
CN111159329A (en) Sensitive word detection method and device, terminal equipment and computer-readable storage medium
CN110347984B (en) Policy page changing method and device, computer equipment and storage medium
CN111126010B (en) Freemaker template file restoration method and device, computer equipment and storage medium
CN110866382A (en) Document generation method, device, terminal equipment and medium
CN110688844A (en) Text labeling method and device
CN107885781B (en) Version management method and system
CN110377891B (en) Method, device and equipment for generating event analysis article and computer readable storage medium
CN115544214B (en) Event processing method, device and computer readable storage medium
CN115904482B (en) Interface document generation method, device, equipment and storage medium
CN111581937A (en) Document generation method and device, computer readable medium and electronic equipment
CN108196921B (en) Document development method and device, computer equipment and storage medium
CN117033309A (en) Data conversion method and device, electronic equipment and readable storage medium
CN115618838A (en) Report generation method and equipment
US11741055B2 (en) Managing file revisions from multiple reviewers
CN110909112B (en) Data extraction method, device, terminal equipment and medium
CN114170451A (en) Text recognition method and device
CN108415814B (en) Method for automatically recording field change, application server and computer readable storage medium
CN110457659B (en) Clause document generation method and terminal equipment
CN114282510B (en) Document generation method and device, storage medium and electronic equipment
CN110347953B (en) Page generation method, page generation device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant