Research questionnaire generation method and device, electronic equipment and storage medium

By analyzing the document content uploaded by users and identifying and mapping questionnaire templates, the problem of low efficiency in generating research questionnaires in the existing technology is solved, and the questionnaire generation is automatically generated and efficiency is improved.

CN119623430APending Publication Date: 2025-03-14BEIJING QINGSONG HEALTH NETWORK TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411704507.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-26
Publication Date
2025-03-14

AI Technical Summary

Technical Problem

In the prior art, the generation of research questionnaires is inefficient, and it is necessary to manually formulate a word manuscript and manually generate a questionnaires, resulting in duplicate work and inefficient efficiency.

Method used

By obtaining the target document uploaded by the user, analyzing the questionnaire content, identifying the questionnaire content and type, and mapping it into the questionnaire template, a survey questionnaire that conforms to the questionnaire format is generated.

Benefits of technology

This realizes an automated process without manually generating research questionnaires, improving the efficiency of survey questionnaires generation, and users only need to edit the document once.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119623430A_ABST
    Figure CN119623430A_ABST
Patent Text Reader

Abstract

The invention relates to a questionnaire generation method and device, electronic equipment and a storage medium, and the method comprises the steps: obtaining a target document uploaded by a user, and the target document comprises prepared questionnaire content; analyzing the questionnaire content in the target document to obtain an analysis result; if the analysis is successful, identifying the question content and the question type of each question in the questionnaire content; and mapping the questionnaire content into a questionnaire template according to the question content and the question type, and generating an investigation questionnaire conforming to a questionnaire format. The questionnaire generation efficiency can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of text generation, and in particular to a method, device, electronic device and storage medium for generating a survey questionnaire. Background Art

[0002] In research projects, a large number of survey questionnaires are a necessary way to collect useful information. This is followed by batch creation of various questionnaires, which is a repetitive and tedious task. Currently, in the process of creating questionnaires, a Word draft is first drafted, and then various components are dragged and dropped in the questionnaire system to realize a complete survey questionnaire.

[0003] After manually drafting the word draft, a feasible survey questionnaire is manually generated. There is obvious duplication of work between the two, resulting in low efficiency in generating the survey questionnaire. Summary of the invention

[0004] The present application provides a method, device, electronic device and storage medium for generating a survey questionnaire to solve the problem of low efficiency in generating survey questionnaires.

[0005] In a first aspect, the present application provides a method for generating a survey questionnaire, the method comprising:

[0006] Obtaining a target document uploaded by a user, wherein the target document contains the prepared questionnaire content;

[0007] Parsing the questionnaire content in the target document to obtain parsing results;

[0008] If the analysis is successful, the content and type of each question in the questionnaire are identified;

[0009] The questionnaire content is mapped into a questionnaire template according to the topic content and the topic type, and a survey questionnaire conforming to the questionnaire format is generated.

[0010] Optionally, parsing the questionnaire content in the target document to obtain the parsing result includes:

[0011] Read the question content in the questionnaire content, and parse the question type and additional information, wherein the additional information is used to indicate additional constraints and descriptions of the question;

[0012] If the question content is read, and the question type and additional information are parsed, then the parsing is determined to be successful;

[0013] If the question content is not read, or the question type or additional information is not parsed, it is determined that the parsing has failed.

[0014] Optionally, identifying the content and type of each question in the questionnaire includes:

[0015] Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document;

[0016] Parsing the document format to obtain a first separator and a topic type identifier;

[0017] The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

[0018] Optionally, after determining the question type of each question through the question type identifier, the method further includes:

[0019] If the question type identifier indicates that the question is a single-choice question or a multiple-choice question, each option of the question is identified by a second separator in the document format of the question.

[0020] Optionally, after determining that the parsing is successful, the method further includes:

[0021] Identify additional information of questions in the questionnaire content;

[0022] The questionnaire content is mapped into a questionnaire template according to the topic content, the topic type and the additional information to generate a survey questionnaire that complies with the questionnaire format.

[0023] Optionally, after parsing the questionnaire content in the target document, the method further includes:

[0024] If the parsing fails, the artificial intelligence algorithm is called to obtain the pre-set document format and document specifications;

[0025] Analyzing structural errors or formatting issues in the questionnaire content through the artificial intelligence algorithm;

[0026] The pre-set document format and document specification are used to repair structural errors or format problems in the questionnaire content until the parsing is successful.

[0027] In a second aspect, the present application provides a device for generating a survey questionnaire, the device comprising:

[0028] An acquisition module is used to acquire a target document uploaded by a user, wherein the target document contains the prepared questionnaire content;

[0029] A parsing module, used to parse the questionnaire content in the target document to obtain a parsing result;

[0030] An identification module, for identifying the content and type of each question in the questionnaire if the analysis is successful;

[0031] A generation module is used to map the questionnaire content into a questionnaire template according to the topic content and the topic type, and generate a survey questionnaire that conforms to the questionnaire format.

[0032] Optionally, the identification module is used to:

[0033] Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document;

[0034] Parsing the document format to obtain a first separator and a topic type identifier;

[0035] The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

[0036] In a third aspect, the present application provides an electronic device comprising: at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor connected to the at least one bus; and at least one memory connected to the at least one bus.

[0037] In a fourth aspect, the present application further provides a computer storage medium storing computer executable instructions, wherein the computer executable instructions are used to execute the method for generating a survey questionnaire as described in any one of the above items of the present application.

[0038] The above technical solution provided by the embodiment of the present application has the following advantages compared with the prior art: by parsing the questionnaire content prepared in the document, the questionnaire content is mapped to the questionnaire template using the question content and the question type, thereby generating a survey questionnaire that conforms to the questionnaire format. In this way, the user only needs to edit the document once and no longer needs to manually generate the survey questionnaire. By automatically generating the survey questionnaire, the efficiency of generating the survey questionnaire is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0040] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0041] One or more embodiments are exemplarily described by pictures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and unless otherwise stated, the figures in the drawings do not constitute proportional limitations.

[0042] Figure 1 A schematic diagram of a system for generating a survey questionnaire provided in an embodiment of the present application;

[0043] Figure 2 A flow chart of a method for generating a survey questionnaire provided in an embodiment of the present application;

[0044] Figure 3 A schematic diagram of the questionnaire content in the document provided in the embodiment of the present application;

[0045] Figure 4 A schematic diagram of a survey questionnaire generated according to an embodiment of the present application;

[0046] Figure 5 A schematic diagram of the document format and document specification provided for the embodiment of the present application;

[0047] Figure 6 A schematic diagram of the overall process of generating a survey questionnaire provided in an embodiment of the present application;

[0048] Figure 7 A schematic diagram of the structure of a survey questionnaire generation device provided in an embodiment of the present application;

[0049] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0050] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0051] The disclosure below provides many different embodiments or examples to implement different structures of the present invention. In order to simplify the disclosure of the present invention, the parts and settings of specific examples are described below. Of course, they are only examples, and the purpose is not to limit the present invention. In addition, the present invention can repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed.

[0052] In order to solve the problem mentioned in the background technology, according to one aspect of the embodiments of the present application, an embodiment of generating a survey questionnaire is provided.

[0053] Optionally, in the embodiment of the present application, the above survey questionnaire generation method can be applied to Figure 1 In the hardware environment composed of the terminal 101 and the server 103 shown in FIG. Figure 1 As shown, the server 103 is connected to the terminal 101 via a network, and can be used to provide services for the terminal or a client installed on the terminal. A database 105 can be set on the server or independently of the server to provide data storage services for the server 103. The above-mentioned network includes but is not limited to: a wide area network, a metropolitan area network or a local area network, and the terminal 101 includes but is not limited to a PC, a mobile phone, a tablet computer, etc.

[0054] The following will be combined with a specific implementation method to describe in detail a method for generating a survey questionnaire provided in an embodiment of the present application, which is applied to a server, such as Figure 2 As shown, the specific steps are as follows:

[0055] Step 201: Obtain the target document uploaded by the user, wherein the target document contains the prepared questionnaire content;

[0056] Step 202: Parse the questionnaire content in the target document to obtain a parsing result;

[0057] Step 203: If the analysis is successful, identify the content and type of each question in the questionnaire;

[0058] Step 204: Map the questionnaire content to the questionnaire template according to the topic content and topic type, and generate a survey questionnaire that complies with the questionnaire format.

[0059] After the user has edited the questionnaire content in the target document and completed the questionnaire design, he / she can select and upload the document through the upload function provided by the front-end interface. Figure 3 At this point, the front-end interface will send the files uploaded by the user to the back-end server for processing. On the back-end server, the Node.js service (Node server) is specifically responsible for receiving and parsing these document data streams.

[0060] During the parsing process, the Node server first extracts the structured data in the document, including questions, options, and descriptions. It then performs a detailed analysis of the data to determine whether it can successfully parse the required information. If any errors or problems occur during the parsing process, the system automatically enters the AI ​​repair process to ensure that the complete survey questionnaire can be successfully output in the end.

[0061] Once parsing is successful, the system will further identify the content and type of each question in the questionnaire. Specifically, the content of the question refers to the specific expression of the question, while the question type is used to reflect the form of the question and restrict the user input content. The system will map this information to a pre-defined questionnaire template based on the identified content and type of the question. In this way, a survey questionnaire that conforms to the questionnaire format can be generated, such as Figure 4 Finally, the generated questionnaire data will be returned to the questionnaire system to support subsequent data display, storage and analysis functions. Users can view and edit the questionnaire in the questionnaire system.

[0062] Figure 3 This is a schematic diagram of the questionnaire content in a word document. It can be seen that the target document is a specific embodiment of the content in the survey questionnaire and meets certain rule requirements so that the survey questionnaire can be parsed and generated in a certain way. The target document can be an editable document such as a word document, a wps document, an xml document, or a non-editable document such as a PDF document. This application does not limit the format of the target document.

[0063] Optionally, the question type is used to reflect the format of the question and to restrict the user input content. The question types include but are not limited to: entering a single line of text, entering multiple lines of text, single choice, multiple choice, entering a number, entering time, entering a mobile phone number, entering an ID card, etc. Figure 5 The document format and document specifications defined in the target document are defined in the textarea box. It can be seen that input means entering a single line of text in the input box, textareal means entering multiple lines of text in the input box, number means entering a numerical value, radio means a single option, checkbox means multiple options, etc. Figure 3 Mainly to indicate the content of the document, Figure 3 The types of questions in the Figure 5 To express in.

[0064] This application parses the questionnaire content prepared in the document, maps the questionnaire content to the questionnaire template using the title content and title type, and thus generates a survey questionnaire that conforms to the questionnaire format. In this way, users only need to edit the document once and no longer need to manually generate the survey questionnaire. By automatically generating the survey questionnaire, the efficiency of generating the survey questionnaire is improved.

[0065] As an optional implementation, parsing the questionnaire content in the target document to obtain the parsing results includes: reading the question content in the questionnaire content, and parsing the question type and additional information, wherein the additional information is used to indicate additional constraints and descriptions of the question; if the question content is read, and the question type and additional information are parsed, then the parsing is determined to be successful; if the question content is not read, or the question type or additional information is not parsed, then the parsing is determined to be a failure.

[0066] After the server successfully reads the questionnaire content and converts it into plain text format, it will further analyze the specific information of each question. First, the system will accurately identify the content of each question to ensure that the question is clearly stated and complete. Then, the system will analyze the question type and additional information of each question in detail.

[0067] During the parsing process, the system will operate strictly in accordance with the specifications. Specifically, the system will divide the question content into specific parts according to the specifications, and identify the question type and other relevant information. The parsing is successful only when the server successfully reads the question content, can divide the specific question type according to the specifications, and identifies all necessary additional information. If any link does not meet the requirements, the system will consider the parsing to have failed.

[0068] For documents that fail to parse, the system will automatically use AI technology to repair them. The AI ​​repair process will intelligently adjust and optimize the target document according to the specific situation to ensure that the final generated questionnaire data meets the standardized format requirements. In this way, the system can greatly improve the success rate of questionnaire generation and ensure that users can obtain high-quality survey questionnaires.

[0069] Optionally, the additional information is additional constraints and descriptions on the questions, which are used to determine whether each question is required or whether each question has a detailed description, etc. For example, the additional information is "This question is not required" or "This question is only for people under 30 years old, and those who do not meet the conditions do not need to fill it out."

[0070] As an optional implementation, in step 203, identifying the question content and question type of each question in the questionnaire content includes: reading the question content in the questionnaire content, wherein the question content retains the document format in the target document; parsing the document format to obtain a first separator and a question type identifier; separating each question by the first separator, and determining the question type of each question by the question type identifier.

[0071] The server reads the specific text content in the questionnaire content and obtains all the question content. At the same time, each question content retains a certain document format, such as line breaks. For the read text content, each question will first be separated by the first separator (for example, double line breaks \n\n, which are the separators between each question in the standard agreement). Then, for each question, the specific question type is obtained according to the question type identifier (for example, input or textareal), and the question type identifier is removed through regular matching, so that the generated survey questionnaire does not contain the question type identifier.

[0072] If the question type indicator indicates that the question is a single-choice question or a multiple-choice question, each option of the question is also identified by a second separator (such as a single line break), for example Figure 3 The options for question 5 include single and married.

[0073] Optionally, the server may also identify additional information of the topic in the questionnaire content, thereby achieving a more detailed description of the topic.

[0074] After parsing all the questions, the server outputs them in the standard data format of the questionnaire. Specifically, the server generates a questionnaire question data format object containing multiple fields. These fields include: label, desc, type, options, and props. Among them, label represents the title of the question; desc represents the description of the question; type represents the type of question; options represents the sub-items of the question, such as single-choice, multiple-choice, etc.; props is an additional information object, including the required attribute, indicating whether the question is required.

[0075] This application first identifies the content of the question, then separates each question, and then identifies the type of each question. For single-choice or multiple-choice questions, each option needs to be identified, and additional information of the question can also be identified, thus completing the analysis of the questionnaire content. By accurately and detailed analysis of the questionnaire content, the generated survey questionnaire is more standardized and meets the user's expectations.

[0076] Exemplarily, the process of generating a survey questionnaire includes the following steps:

[0077] 1. Identify the question content: Read the questionnaire content from the uploaded document and extract the text content of each question. This step ensures that the basic information of all questions is read correctly.

[0078] 2. Split questions: Use double line breaks \n\n to separate each question and ensure that each question is processed as an independent unit.

[0079] 3. Identify the question type: For each question, use the question type identifier <[]> to identify the question type. For example, <[Single Choice]> indicates a single-choice question, <[Multiple Choice]> indicates a multiple-choice question, etc.

[0080] 4. Identify options: For single-choice or multiple-choice questions, further identify each option. Separate the options with a single line break character \n and remove extra blank characters to ensure that each option is correctly identified.

[0081] 5. Identify additional information: Extract additional information of the question, which is usually placed in brackets after the title of the question, for example, "What is your favorite fruit? (10 points, easy, basic)". Match this additional information through regular expressions and parse it into structured data.

[0082] 6. Generate standardized questionnaire data: Map the parsed question content, question type, options and additional information to the standard data format of the questionnaire. The data format of each question includes the question title, description, question type, options and additional information, etc., to ensure that the generated questionnaire data format is unified and standardized.

[0083] This application can accurately extract questionnaire content from documents and generate standardized survey questionnaires that meet user expectations, which not only improves the efficiency of questionnaire generation, but also ensures the integrity and accuracy of questionnaire data.

[0084] As an optional implementation, after parsing the questionnaire content in the target document, the method also includes: if the parsing fails, calling an artificial intelligence algorithm to obtain a preset document format and document specifications; analyzing the structural errors or format problems in the questionnaire content through an artificial intelligence algorithm; and using a preset document format and document specifications to repair the structural errors or format problems in the questionnaire content until the parsing is successful.

[0085] During the initial parsing process, if the server fails to read the question content, or fails to parse the question type or additional information, it determines that the parsing has failed and records the reason for the parsing failure, such as incorrect document format, missing content, etc.

[0086] The server calls a pre-trained artificial intelligence algorithm (such as GPT-4) to obtain pre-set document formats and document specifications. These formats and specifications include delimiters between questions (such as double line breaks \n\n), question type identifiers (such as <[input]>), option separators (such as single line breaks \n), etc.

[0087] The AI ​​algorithm analyzes the document content and identifies structural errors or formatting issues. For example, it identifies missing double line breaks between questions, incorrect use of question type identifiers, missing option separators, etc. Based on the identified issues, it generates specific repair suggestions. For example, it recommends adding double line breaks between questions, correcting question type identifiers, or adding single line breaks between options.

[0088] The server reparses the repaired document content to check whether the parsing is successful. If the parsing is successful, the repair process ends; if the parsing still fails, the artificial intelligence algorithm is continued to be called for further repair until the parsing is successful.

[0089] This application solves the problem of tedious and error-prone manual processing in traditional document parsing by introducing AI technology. The system can not only automatically parse documents and convert them into standardized questionnaire formats, but also has the ability to automatically repair documents when parsing fails, greatly improving the efficiency and accuracy of data processing. At the same time, the AI ​​repair function improves the system's tolerance for non-standard documents and enhances the system's applicability and stability.

[0090] This application provides a schematic diagram of the overall process of generating a survey questionnaire, such as Figure 6 As shown, the following steps are included:

[0091] After the user uploads the document, the node server reads the questionnaire content in the document and parses the questionnaire content. If the parsing fails, the AI ​​algorithm is called to repair the document according to the specified format and specifications. If the parsing is successful, the question content, type and additional information are identified, and then the parsed data is converted into standard questionnaire information, and the questionnaire data format required by the questionnaire system is returned.

[0092] The overall process of this application is explained below, including the following steps.

[0093] 1. User uploads a Word document.

[0094] The system first receives the Word format document uploaded by the user. The user document contains the questionnaire information to be processed. The user selects and uploads the Word document through the front-end interface. The front-end sends the uploaded file to the back-end server. After receiving the uploaded file, the back-end server saves it to a temporary directory or memory and records the path or file stream of the uploaded file.

[0095] 2. The Node service reads the Word document and parses the document content.

[0096] The system uses the Node.js service to read the uploaded Word document and parse the document content. During the parsing process, the Node service is responsible for extracting structured data such as questions, options, descriptions, etc. in the document. Specifically, the system reads the content of the Word document, converts it into plain text format, and then uses double line breaks \n\n to separate each question, ensuring that each question is processed as an independent unit.

[0097] 3. Determine whether the document parsing is successful.

[0098] After parsing is completed, the system checks whether the parsing results meet expectations. The specific check includes whether the question list is empty, and whether the question content, question type, options, etc. are complete and correct. If the parsing fails, the system will enter the AI ​​repair process; if the parsing is successful, the system will directly proceed to the next step.

[0099] 4. AI repairs the document according to the format and specifications (if parsing fails).

[0100] When the Node service fails to parse a document successfully, the system calls AI technology to repair the document according to the pre-set format and specifications. AI automatically adjusts the document format to facilitate parsing by analyzing structural errors or format problems in the document. The specific steps include:

[0101] Calling AI algorithm: The system calls the pre-trained artificial intelligence algorithm to obtain the pre-set document format and document specifications, such as the separator between questions, question type identifier, option separator, etc.

[0102] Analyze document content: AI algorithms analyze document content and identify structural errors or formatting issues, such as missing double line breaks between questions, incorrect use of question type identifiers, missing option separators, etc.

[0103] Generate repair suggestions: Based on the identified problems, AI generates specific repair suggestions, such as adding double line breaks between questions, correcting question type identifiers, adding single line breaks between options, etc.

[0104] Repair document content: Repair the document content one by one according to the generated repair suggestions until the parsing is successful.

[0105] 5. Identify the question type and additional information of the question.

[0106] Whether it is a successfully parsed document or a document repaired by AI, the system will then identify the question type. Specifically, the system will use a custom delimiter <[]> to identify the specific question type of each question, such as single-choice questions, multiple-choice questions, etc. In addition, the system will also extract additional information about the question, such as score, difficulty, category, etc. This additional information is usually placed in brackets after the question title, such as "What is your favorite fruit? (10 points, easy, basic)".

[0107] 6. Convert document data into questionnaire data.

[0108] The system converts the parsed document data into a standardized questionnaire data format. Specifically, the system maps the content, question type, options, and additional information of each question to the standard data format of the questionnaire, generating a survey questionnaire that conforms to the questionnaire format. The converted data can be directly used in the questionnaire system for display and processing, ensuring that the detailed information of each question is correctly mapped to the questionnaire template.

[0109] 7. Return the data format required by the questionnaire system.

[0110] Finally, the system returns the standardized questionnaire data to the questionnaire system to support subsequent data display, storage, analysis and other functions. Specifically, the system returns the generated questionnaire data to the questionnaire system in JSON or other standard formats to ensure that the data format meets the requirements of the questionnaire system and supports operations such as questionnaire display, storage and analysis.

[0111] Through this series of detailed steps, this application can ensure that the questionnaire data extracted from the Word document uploaded by the user is complete and accurate, thereby generating a standardized questionnaire data format that meets the user's expectations.

[0112] Based on the same technical concept, the present application provides a device for generating a survey questionnaire, such as Figure 7 As shown, the device comprises:

[0113] The acquisition module 701 is used to acquire the target document uploaded by the user, wherein the target document contains the prepared questionnaire content;

[0114] The parsing module 702 is used to parse the questionnaire content in the target document and obtain the parsing result;

[0115] Identification module 703, for identifying the content and type of each question in the questionnaire if the analysis is successful;

[0116] The generation module 704 is used to map the questionnaire content to the questionnaire template according to the topic content and topic type, and generate a survey questionnaire that complies with the questionnaire format.

[0117] Optionally, the parsing module 702 is used to:

[0118] Read the question content in the questionnaire content and parse the question type and additional information, where the additional information is used to indicate additional constraints and descriptions of the question;

[0119] If the question content is read, and the question type and additional information are parsed, then the parsing is determined to be successful;

[0120] If the question content is not read, or the question type or additional information is not parsed, it is determined that the parsing has failed.

[0121] Optionally, the identification module 703 is used to:

[0122] Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document;

[0123] Parse the document format to obtain the first separator and the topic type identifier;

[0124] The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

[0125] Optionally, the identification module 703 is used to:

[0126] Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document;

[0127] Parse the document format to obtain the first separator and the topic type identifier;

[0128] The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

[0129] Optionally, the device is also used for:

[0130] If the question type identifier indicates that the question is a single-choice question or a multiple-choice question, each option of the question is identified by the second separator in the document format of the question.

[0131] Optionally, the device is also used for:

[0132] Identify additional information about questions in the questionnaire content;

[0133] The questionnaire content is mapped to the questionnaire template according to the question content, question type and additional information to generate a survey questionnaire that conforms to the questionnaire format.

[0134] Optionally, the device is also used for:

[0135] If the parsing fails, the artificial intelligence algorithm is called to obtain the pre-set document format and document specifications;

[0136] Analyze structural errors or formatting issues in questionnaire content through artificial intelligence algorithms;

[0137] Use pre-set document formats and document specifications to fix structural errors or formatting issues in the questionnaire content until the parsing is successful.

[0138] like Figure 8 As shown, an embodiment of the present application provides an electronic device, including a processor 801, a communication interface 802, a memory 803 and a communication bus 804, wherein the processor 801, the communication interface 802, and the memory 803 communicate with each other through the communication bus 804.

[0139] The memory 803 is used to store computer programs.

[0140] In one embodiment of the present application, the processor 801 is used to execute the program stored in the memory 803 to implement the method for generating a survey questionnaire provided by any of the above method embodiments, including:

[0141] Obtain the target document uploaded by the user, wherein the target document contains the prepared questionnaire content;

[0142] Parse the questionnaire content in the target document and obtain the parsing result;

[0143] If the analysis is successful, the content and type of each question in the questionnaire are identified;

[0144] Map the questionnaire content to the questionnaire template according to the topic content and topic type to generate a survey questionnaire that conforms to the questionnaire format.

[0145] Optionally, the questionnaire content in the target document is parsed to obtain parsing results including:

[0146] Read the question content in the questionnaire content and parse the question type and additional information, where the additional information is used to indicate additional constraints and descriptions of the question;

[0147] If the question content is read, and the question type and additional information are parsed, then the parsing is determined to be successful;

[0148] If the question content is not read, or the question type or additional information is not parsed, it is determined that the parsing has failed.

[0149] Optionally, identifying the content and type of each question in the questionnaire content includes:

[0150] Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document;

[0151] Parse the document format to obtain the first separator and the topic type identifier;

[0152] The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

[0153] Optionally, after determining the question type of each question through the question type identifier, the method further includes:

[0154] If the question type identifier indicates that the question is a single-choice question or a multiple-choice question, each option of the question is identified by the second separator in the document format of the question.

[0155] Optionally, after determining that the parsing is successful, the method further includes:

[0156] Identify additional information about questions in the questionnaire content;

[0157] The questionnaire content is mapped to the questionnaire template according to the question content, question type and additional information to generate a survey questionnaire that conforms to the questionnaire format.

[0158] Optionally, after parsing the questionnaire content in the target document, the method further includes:

[0159] If the parsing fails, the artificial intelligence algorithm is called to obtain the pre-set document format and document specifications;

[0160] Analyze structural errors or formatting issues in questionnaire content through artificial intelligence algorithms;

[0161] Use pre-set document formats and document specifications to fix structural errors or formatting issues in the questionnaire content until the parsing is successful.

[0162] An embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for generating a survey questionnaire provided in any of the aforementioned method embodiments are implemented.

[0163] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, i.e., they may be located in one place, or may be distributed over multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0164] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a general hardware platform, and of course, by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the relevant technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0165] It should be understood that the terms used in the text are only for the purpose of describing specific example embodiments, and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "one", "an" and "said" as used in the text may also be meant to include plural forms. The terms "include", "comprise", "contain", and "have" are inclusive, and therefore specify the existence of stated features, steps, operations, elements and / or parts, but do not exclude the existence or addition of one or more other features, steps, operations, elements, parts, and / or combinations thereof. The method steps, processes, and operations described herein are not interpreted as necessarily requiring them to be performed in the specific order described or illustrated, unless the execution order is clearly indicated. It should also be understood that additional or alternative steps may be used.

[0166] The foregoing is merely a specific embodiment of the present invention, which enables those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features claimed herein.

Claims

1. A method for generating a survey questionnaire, characterized in that: The method comprises: Obtaining a target document uploaded by a user, wherein the target document contains the prepared questionnaire content; Parsing the questionnaire content in the target document to obtain parsing results; If the analysis is successful, the content and type of each question in the questionnaire are identified; The questionnaire content is mapped into a questionnaire template according to the topic content and the topic type, and a survey questionnaire conforming to the questionnaire format is generated.

2. The method according to claim 1, characterized in that Parsing the questionnaire content in the target document, obtaining parsing results including: Read the question content in the questionnaire content, and parse the question type and additional information, wherein the additional information is used to indicate additional constraints and descriptions of the question; If the question content is read, and the question type and additional information are parsed, then the parsing is determined to be successful; If the question content is not read, or the question type or additional information is not parsed, it is determined that the parsing has failed.

3. The method according to claim 1, characterized in that Identifying the content and type of each question in the questionnaire includes: Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document; Parsing the document format to obtain a first separator and a topic type identifier; The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

4. The method according to claim 3, characterized in that After determining the question type of each question through the question type identifier, the method further includes: If the question type identifier indicates that the question is a single-choice question or a multiple-choice question, each option of the question is identified by a second separator in the document format of the question.

5. The method according to any one of claims 1 to 4, characterized in that: After determining that the parsing is successful, the method further includes: Identify additional information of questions in the questionnaire content; The questionnaire content is mapped into a questionnaire template according to the topic content, the topic type and the additional information to generate a survey questionnaire that complies with the questionnaire format.

6. The method according to claim 1, characterized in that After parsing the questionnaire content in the target document, the method further includes: If the parsing fails, the artificial intelligence algorithm is called to obtain the pre-set document format and document specifications; Analyzing structural errors or formatting issues in the questionnaire content through the artificial intelligence algorithm; The pre-set document format and document specification are used to repair structural errors or format problems in the questionnaire content until the parsing is successful.

7. A device for generating a survey questionnaire, characterized in that: The device comprises: An acquisition module is used to acquire a target document uploaded by a user, wherein the target document contains the prepared questionnaire content; A parsing module, used to parse the questionnaire content in the target document to obtain a parsing result; An identification module, for identifying the content and type of each question in the questionnaire if the analysis is successful; A generation module is used to map the questionnaire content into a questionnaire template according to the topic content and the topic type, and generate a survey questionnaire that conforms to the questionnaire format.

8. The device according to claim 7, characterized in that The identification module is used for: Reading the question content in the questionnaire content, wherein the question content retains the document format in the target document; Parsing the document format to obtain a first separator and a topic type identifier; The first separator is used to separate the questions, and the question type of each question is determined by the question type identifier.

9. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing any of the methods described in claims 1-6 when executing a program stored in a memory.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.