CN110765752B - Test question generation method and device, electronic equipment and computer readable storage medium - Google Patents

Test question generation method and device, electronic equipment and computer readable storage medium Download PDF

Info

Publication number
CN110765752B
CN110765752B CN201911039007.3A CN201911039007A CN110765752B CN 110765752 B CN110765752 B CN 110765752B CN 201911039007 A CN201911039007 A CN 201911039007A CN 110765752 B CN110765752 B CN 110765752B
Authority
CN
China
Prior art keywords
test question
logic expression
variable parameter
variable
template
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.)
Active
Application number
CN201911039007.3A
Other languages
Chinese (zh)
Other versions
CN110765752A (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.)
Douyin Vision Co Ltd
Original Assignee
Douyin Vision 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 Douyin Vision Co Ltd filed Critical Douyin Vision Co Ltd
Priority to CN201911039007.3A priority Critical patent/CN110765752B/en
Publication of CN110765752A publication Critical patent/CN110765752A/en
Application granted granted Critical
Publication of CN110765752B publication Critical patent/CN110765752B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The disclosure provides a test question generation method, a test question generation device, electronic equipment and a computer readable storage medium, and relates to the field of information processing. The method comprises the following steps: determining whether a test question generation instruction is received; responding to a received test question generation instruction, and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template; determining whether an assignment for a variable parameter is received; acquiring a variable parameter value of a variable parameter in response to receiving an assignment for the variable parameter; determining whether the variable parameter value meets a logic expression; and generating the target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression. The method and the device not only save the time of the questions, but also solve the problem that students can obtain correct answers through back answers aiming at test questions of the same knowledge points, so that the students cannot know knowledge points skillfully.

Description

Test question generation method and device, electronic equipment and computer readable storage medium
Technical Field
The disclosure relates to the technical field of information processing, and in particular relates to a test question generation method, a test question generation device, electronic equipment and a computer readable storage medium.
Background
The test question library is an intelligent crystal of a question producer, and often a good test question needs to be designed and arranged before and after the question producer, so that a great deal of time is spent.
However, the test questions appearing in the examination are often used as practice questions of 'rotten street', and the correct result can be given by the back answers of the students, so that the students can still do the test questions without mastering the knowledge points and cannot be familiar with mastering the knowledge points. Moreover, in the prior art, the test questions are written manually, and a great deal of labor cost and time cost are required to be consumed.
Disclosure of Invention
This summary is provided to introduce a selection of concepts in a simplified form that are further described below in the detailed description. This summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
The disclosure provides a test question generation method, a device, electronic equipment and a computer readable storage medium, which can solve the problem that students can still do test questions and cannot be familiar with knowledge points under the condition that the students do not grasp the knowledge points. The technical scheme is as follows:
In a first aspect, a method for generating a test question is provided, the method comprising:
determining whether a test question generation instruction is received;
responding to a received test question generation instruction, and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template;
determining whether an assignment for the variable parameter is received;
acquiring a variable parameter value of the variable parameter in response to receiving an assignment for the variable parameter;
determining whether the variable parameter value satisfies the logic expression; and
and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value meeting the logic expression.
In a second aspect, there is provided a device for generating a test question, the device comprising:
the first determining module is used for determining whether a test question generating instruction is received or not;
the first acquisition module is used for responding to the received test question generation instruction and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template;
a second determining module, configured to determine whether an assignment for the variable parameter is received;
The second acquisition module is used for acquiring variable parameter values of the variable parameters in response to receiving assignment of the variable parameters;
a third determining module for determining whether the variable parameter value satisfies the logic expression;
and the first generation module is used for responding to the variable parameter value to meet the logic expression, and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value.
In a third aspect, an electronic device is provided, the electronic device comprising:
a processor, a memory, and a bus;
the bus is used for connecting the processor and the memory;
the memory is used for storing operation instructions;
the processor is configured to, by invoking the operation instruction, cause the processor to execute an operation corresponding to the method for generating a test question as shown in the first aspect of the present disclosure.
In a fourth aspect, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method for generating test questions shown in the first aspect of the present disclosure.
The beneficial effects that this disclosure provided technical scheme brought are:
In the embodiment of the disclosure, a terminal firstly determines whether a test question generation instruction is received, and in response to receiving the test question generation instruction, obtains a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template, then determines whether assignment for the variable parameters is received, and in response to receiving the assignment for the variable parameters, obtains variable parameter values of the variable parameters, and then determines whether the variable parameter values meet the logic expression; and generating the target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression. Therefore, on the premise of ensuring the consistency of the logics of the test questions, the user changes the results of the test questions by randomly changing the variable parameters in the test questions, so that a new test question is generated, a great amount of labor cost and time cost are saved, the problem that students can obtain correct answers through back answers aiming at the test questions with the same knowledge points is solved, the problem that the students cannot know the knowledge points skillfully is solved, and the flexible and changeable test questions with value can be automatically obtained.
Drawings
The above and other features, advantages, and aspects of embodiments of the present disclosure will become more apparent by reference to the following detailed description when taken in conjunction with the accompanying drawings. The same or similar reference numbers will be used throughout the drawings to refer to the same or like elements. It should be understood that the figures are schematic and that elements and components are not necessarily drawn to scale.
Fig. 1 is a schematic flow chart of a method for generating test questions according to an embodiment of the disclosure;
fig. 2 is a flow chart of a method for generating test questions according to another embodiment of the disclosure;
fig. 3 is a schematic structural diagram of a test question generating device according to another embodiment of the present disclosure;
fig. 4 is a schematic structural diagram of an electronic device for generating a test question according to another embodiment of the present disclosure.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure have been shown in the accompanying drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are for illustration purposes only and are not intended to limit the scope of the present disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order and/or performed in parallel. Furthermore, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "including" and variations thereof as used herein are intended to be open-ended, i.e., including, but not limited to. The term "based on" is based at least in part on. The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments. Related definitions of other terms will be given in the description below.
It should be noted that the terms "first," "second," and the like in this disclosure are used merely to distinguish one from another device, module, or unit, and are not intended to limit the device, module, or unit to the particular device, module, or unit or to limit the order or interdependence of functions performed by the devices, modules, or units.
It should be noted that references to "one", "a plurality" and "a plurality" in this disclosure are intended to be illustrative rather than limiting, and those of ordinary skill in the art will appreciate that "one or more" is intended to be understood as "one or more" unless the context clearly indicates otherwise.
The names of messages or information interacted between the various devices in the embodiments of the present disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
For the purposes of clarity, technical solutions and advantages of the present disclosure, the following further details the embodiments of the present disclosure with reference to the accompanying drawings.
The present disclosure provides a method, an apparatus, an electronic device, and a computer-readable storage medium for generating test questions, which aim to solve the above technical problems in the prior art.
The following describes the technical solutions of the present disclosure and how the technical solutions of the present disclosure solve the above technical problems in detail with specific embodiments. The following embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. Embodiments of the present disclosure will be described below with reference to the accompanying drawings.
In one embodiment, a method for generating a test question is provided, as shown in fig. 1, and the method includes:
step S101, determining whether a test question generation instruction is received;
step S102, a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template are obtained in response to receiving a test question generation instruction;
in practical applications, a user may generate a test question by interacting with a terminal. For example, a user opens a webpage or an application client for generating a test question on the terminal, an interactive interface can be preset in the webpage or the application client, a virtual button for generating the test question or the same function can be preset in the interactive interface, the virtual button can correspond to a test question generation instruction, the terminal can determine whether the test question generation instruction is received by monitoring whether the virtual button is clicked, when the terminal monitors that the user clicks the virtual button, the terminal can determine that the test question generation instruction is received, and then a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template can be obtained from a test question database. The logic expression is a condition which is required to be met by the variable parameters in the test question template to ensure that the generated test question logic is correct.
Step S103, determining whether assignment for variable parameters is received;
step S104, in response to receiving assignment for the variable parameter, obtaining a variable parameter value of the variable parameter;
after the user selects the test question template, variable parameters in the test question template can be obtained, text input boxes corresponding to the variable parameters are displayed in the interactive interface, the text input boxes are used for enabling the user to assign the variable parameters, and meanwhile, the terminal monitors whether the user initiates a confirmation instruction for assigning the variable parameters. When the user inputs the numerical value corresponding to each variable parameter in each text input box, and clicks the virtual button of 'determining' to initiate a confirmation instruction, the terminal monitors the confirmation instruction, and then the terminal can determine that the assignment for each variable parameter is received.
Step S105, determining whether the variable parameter value meets a logic expression;
and S106, when the variable parameter value meets the logic expression, generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value.
After the user inputs the values corresponding to the variable parameters, whether the variable parameter values meet the logic expression needs to be judged, and if yes, the target test questions can be generated based on the test question templates, the logic expression, the variable parameters and the variable parameter values.
In the embodiment of the disclosure, a terminal firstly determines whether a test question generation instruction is received, and in response to receiving the test question generation instruction, obtains a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template, then determines whether assignment for the variable parameters is received, and in response to receiving the assignment for the variable parameters, obtains variable parameter values of the variable parameters, and then determines whether the variable parameter values meet the logic expression; and generating the target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression. Therefore, on the premise of ensuring the consistency of the logics of the test questions, the user changes the results of the test questions by randomly changing the variable parameters in the test questions, so that a new test question is generated, a great amount of labor cost and time cost are saved, the problem that students can obtain correct answers through back answers aiming at the test questions with the same knowledge points is solved, the problem that the students cannot know the knowledge points skillfully is solved, and the flexible and changeable test questions with value can be automatically obtained.
In one embodiment, a method for generating a test question is provided, as shown in fig. 2, and the method includes:
Step S201, determining whether a test question generation instruction is received;
step S202, a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template are obtained in response to receiving a test question generation instruction;
in practical applications, a user may generate a test question by interacting with a terminal. For example, a user opens a webpage or an application client for generating a test question on the terminal, an interactive interface can be preset in the webpage or the application client, a virtual button for generating the test question or the same function can be preset in the interactive interface, the virtual button can correspond to a test question generation instruction, the terminal can determine whether the test question generation instruction is received by monitoring whether the virtual button is clicked, when the terminal monitors that the user clicks the virtual button, the terminal can determine that the test question generation instruction is received, and then a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template can be obtained from a test question database. The logic expression is a condition which is required to be met by the variable parameters in the test question template to ensure that the generated test question logic is correct.
For example, a test question template is "ax 2 +bx+c=0 ", wherein a, b, c are variable parameters, and the logical expression corresponding to the test question template is" a×c<0", when" a x c<When 0', ax 2 Logic of +bx+c=0 "is correct, and the equation has a real solution if a×c>0, then the generated title is erroneous. That is, the user needs to input the values of a, b, and c, respectively, and the input values of a and c need to satisfy "a×c<A logical expression of 0 ".
For another example, a test question template is "x 2 +d=0 ", wherein d is a variable parameter, and the logical expression corresponding to the test question template is" d<0", when" d<When 0", x 2 Logic of +d=0 "is correct, the equation has a real solution, if d>0, then the generated title is erroneous. That is, the user needs to input the value of d, and the input value of d needs to satisfy "d<A logical expression of 0 ".
In a preferred embodiment of the present disclosure, in response to receiving a test question generation instruction, obtaining a preset test question template, a logic expression corresponding to the test question template, and variable parameters in the test question template, including:
obtaining a matched test question template from a pre-constructed test question database according to a request identifier in a received test question generation instruction, wherein the test question template, variable parameters in the test question template, a logic expression corresponding to the test question template and a corresponding relation among the test question template, the variable parameters and the logic expression are stored in the test question database;
And obtaining the corresponding logic expression and variable parameters according to the corresponding relation.
Specifically, before generating the test questions, the user may construct a test question database in advance for storing test question templates, variable parameters in the test question templates, and logic expressions corresponding to the test question templates, wherein the test question templates, the variable parameters, and the logic expressions have a correspondence relationship of two-to-two, such as a test question template "ax 2 The logical expression corresponding to +bx+c=0 is "a×c<0", the corresponding variable parameter is" a, b, c ", the logic expression corresponding to the variable parameter" a, b, c "is" a×c<0", etc.
In the test question database, each test question template has a corresponding logic expression and variable parameters, and the variable parameters can be one or a plurality of variable parameters. For example, the test question template "ax 2 The +bx+c=0' comprises three variable parameters of a, b and c, and the test question template "x 2 +d=0 "includes d as a variable parameter.
Further, the test question template may also set a corresponding classification identifier, such as a test question template "ax 2 The classification identifier of +bx+c=0 may be a "unitary quadratic equation", and each classification identifier is displayed in the interactive interface, and before the user clicks on "generate test question", the classification identifier of the required test question template, for example, the "unitary quadratic equation", may be selected, so that the test question template, the variable parameters of the test question template, and the logic expression of the test question template may be selected from the unitary quadratic equation to generate the test question.
Alternatively, it may also be an ID identification, such as "a 2 +b 2 =c 2 The ID identification of "may be" pythagorean theorem ",the ID identification of (c) may be "triangle identity" or the like. Of course, other identifiers may be provided, and may be set according to actual requirements, which is not limited by the embodiments of the present disclosure.
In a preferred embodiment of the present disclosure, the logical expression is generated by:
receiving an original logic expression input by a user and based on natural language;
inputting the original logic expression into a preset conversion model to obtain a target logic expression based on the machine language.
Specifically, the generating a logical expression may use a preset conversion model, such as a seq2seq model, to convert a logical expression based on a natural language (such as "a×c < 0") into a logical expression based on a machine language, where an input of the conversion model is the logical expression based on the natural language, and an output is the logical expression based on the machine language, such as a logical expression in a code form.
In a preferred embodiment of the present disclosure, the logical expression is a machine language-based logical expression entered by a user.
Further, the machine language based logic expression may also be entered manually by a user. The conversion to a machine language based logical expression has the benefit of being useful for subsequent test question generation.
Step S203, determining whether assignment for variable parameters is received;
step S204, in response to receiving the assignment for the variable parameter, obtaining the variable parameter value of the variable parameter;
after the user selects the test question template, variable parameters in the test question template can be obtained, text input boxes corresponding to the variable parameters are displayed in the interactive interface, the text input boxes are used for enabling the user to assign the variable parameters, and meanwhile, the terminal monitors whether the user initiates a confirmation instruction for assigning the variable parameters. When the user inputs the numerical value corresponding to each variable parameter in each text input box, and clicks the virtual button of 'determining' to initiate a confirmation instruction, the terminal monitors the confirmation instruction, and then the terminal can determine that the assignment for each variable parameter is received. For example, "ax 2 If the variable parameters of +bx+c=0 are "a, b, c", the user can input "a, b,c "corresponding to the value of c". Then, the numerical value of each variable parameter input by the user is obtained from each text input box.
Step S205, determining whether the variable parameter value meets a logic expression;
Step S206, generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression;
specifically, after the user inputs the values corresponding to the variable parameters, it needs to determine whether the variable parameter values satisfy the logic expression, and if so, the target test question can be generated based on the test question template, the logic expression, the variable parameters and the variable parameter values. For example, template "ax" for test questions 2 +bx+c=0 ", the value of a is 5, the value of b is 8,c, the value of a is-3, a×c= -15, and is less than 0, and the logical expression corresponding to the test question template is satisfied, then the value of" 5,8, -3 "can be adopted to generate the target test question.
Step S207, generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression;
specifically, after the user inputs the values corresponding to the variable parameters, if the values of the variable parameters do not satisfy the logic expression, an error prompt may be generated and displayed to the user, for example, the values corresponding to "a, b, and c" input by the user are "5,8,3", and obviously "a×c <0" is not satisfied, so that an "error" may be generated: an error indication of a >0 "is presented to the user, which then lets the user reenter the value of a or the value of c.
After the user inputs the new value again, continuously judging whether the new value meets the logic expression corresponding to the test question template, if not, continuously generating an error prompt and displaying the error prompt to the user, enabling the user to input the new value again until the new value input again meets the logic expression, and then generating a target test question based on the test question template, the logic expression, the variable parameters and the new variable parameter values.
And step S208, solving the target test questions to obtain a solving result of the target test questions.
Specifically, after the target test question is generated, the target test question can be solved, and a corresponding solving result is obtained. Thus, the user can generate answers corresponding to the test questions while generating the test questions.
In the embodiment of the disclosure, a terminal firstly determines whether a test question generation instruction is received, and in response to receiving the test question generation instruction, obtains a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template, then determines whether assignment for the variable parameters is received, and in response to receiving the assignment for the variable parameters, obtains variable parameter values of the variable parameters, and then determines whether the variable parameter values meet the logic expression; and generating the target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression. Therefore, on the premise of ensuring the consistency of the logics of the test questions, the user changes the results of the test questions by randomly changing the variable parameters in the test questions, so that a new test question is generated, a great amount of labor cost and time cost are saved, the problem that students can obtain correct answers through back answers aiming at the test questions with the same knowledge points is solved, the problem that the students cannot know the knowledge points skillfully is solved, and the flexible and changeable test questions with value can be automatically obtained.
Meanwhile, the generated test questions can be solved, so that a solution result corresponding to the generated test questions is obtained, whether the generated test questions are correct or not can be checked, the step of solving the questions by a question-setting person is omitted, and the time of the question-setting person is further saved.
Fig. 3 is a schematic structural diagram of a test question generating device according to another embodiment of the present disclosure, where, as shown in fig. 3, the device in this embodiment may include:
a first determining module 301, configured to determine whether a test question generating instruction is received;
the first obtaining module 302 is configured to obtain a preset test question template, a logic expression corresponding to the test question template, and a variable parameter in the test question template in response to receiving a test question generation instruction;
a second determining module 303, configured to determine whether an assignment for the variable parameter is received;
a second obtaining module 304, configured to obtain a variable parameter value of the variable parameter in response to receiving an assignment for the variable parameter;
a third determining module 305, configured to determine whether the variable parameter value satisfies the logic expression;
a first generating module 306, configured to generate a target test question based on the test question template, the logic expression, the variable parameter, and the variable parameter value in response to the variable parameter value satisfying the logic expression.
In a preferred embodiment of the present disclosure, further comprising:
and the second generation module is used for generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression.
In a preferred embodiment of the present disclosure, the first acquisition module includes:
the test question template acquisition sub-module is used for acquiring matched test question templates from a pre-constructed test question database according to the request identification in the received test question generation instruction, wherein the test question templates, variable parameters in the test question templates, logic expressions corresponding to the test question templates and corresponding relations among the test question templates, the variable parameters and the logic expressions are stored in the test question database;
and the corresponding information acquisition sub-module is used for acquiring corresponding logic expressions and variable parameters according to the corresponding relation.
In a preferred embodiment of the present disclosure, the logical expression is generated by:
receiving an original logic expression input by a user and based on natural language;
and inputting the original logic expression into a preset conversion model to obtain a target logic expression based on machine language.
In a preferred embodiment of the present disclosure, the logical expression is a machine language-based logical expression entered by a user.
In a preferred embodiment of the present disclosure, further comprising:
and the solving module is used for solving the target test questions to obtain solving results of the target test questions.
The generating device of the test questions of the present embodiment may execute the generating methods of the test questions shown in the first embodiment and the second embodiment of the present disclosure, and the implementation principles are similar, and are not repeated here.
In the embodiment of the disclosure, a terminal firstly determines whether a test question generation instruction is received, and in response to receiving the test question generation instruction, obtains a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template, then determines whether assignment for the variable parameters is received, and in response to receiving the assignment for the variable parameters, obtains variable parameter values of the variable parameters, and then determines whether the variable parameter values meet the logic expression; and generating the target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value satisfying the logic expression. Therefore, on the premise of ensuring the consistency of the logics of the test questions, the user changes the results of the test questions by randomly changing the variable parameters in the test questions, so that a new test question is generated, a great amount of labor cost and time cost are saved, the problem that students can obtain correct answers through back answers aiming at the test questions with the same knowledge points is solved, the problem that the students cannot know the knowledge points skillfully is solved, and the flexible and changeable test questions with value can be automatically obtained.
Meanwhile, the generated test questions can be solved, so that a solution result corresponding to the generated test questions is obtained, whether the generated test questions are correct or not can be checked, the step of solving the questions by a question-setting person is omitted, and the time of the question-setting person is further saved.
Referring now to fig. 4, a schematic diagram of an electronic device 400 suitable for use in implementing embodiments of the present disclosure is shown. The electronic devices in the embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and the like, and stationary terminals such as digital TVs, desktop computers, and the like. The electronic device shown in fig. 4 is merely an example and should not be construed to limit the functionality and scope of use of the disclosed embodiments.
An electronic device includes: a memory and a processor, where the processor may be referred to as a processing device 401 described below, the memory may include at least one of a Read Only Memory (ROM) 402, a Random Access Memory (RAM) 403, and a storage device 408 described below, as follows:
As shown in fig. 4, the electronic device 400 may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 401, which may perform various suitable actions and processes according to a program stored in a Read Only Memory (ROM) 402 or a program loaded from a storage means 408 into a Random Access Memory (RAM) 403. In the RAM 403, various programs and data necessary for the operation of the electronic device 400 are also stored. The processing device 401, the ROM 402, and the RAM 403 are connected to each other by a bus 404. An input/output (I/O) interface 405 is also connected to bus 404.
In general, the following devices may be connected to the I/O interface 405: input devices 406 including, for example, a touch screen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; an output device 407 including, for example, a Liquid Crystal Display (LCD), a speaker, a vibrator, and the like; storage 408 including, for example, magnetic tape, hard disk, etc.; and a communication device 409. The communication means 409 may allow the electronic device 400 to communicate with other devices wirelessly or by wire to exchange data. While fig. 4 shows an electronic device 400 having various means, it is to be understood that not all of the illustrated means are required to be implemented or provided. More or fewer devices may be implemented or provided instead.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a non-transitory computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via communications device 409, or from storage 408, or from ROM 402. The above-described functions defined in the methods of the embodiments of the present disclosure are performed when the computer program is executed by the processing device 401.
It should be noted that the computer readable medium described in the present disclosure may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of the computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this disclosure, a computer-readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present disclosure, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, fiber optic cables, RF (radio frequency), and the like, or any suitable combination of the foregoing.
In some implementations, the clients, servers may communicate using any currently known or future developed network protocol, such as HTTP (HyperText Transfer Protocol ), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the internet (e.g., the internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed networks.
The computer readable medium may be contained in the electronic device; or may exist alone without being incorporated into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to: determining whether a test question generation instruction is received; responding to a received test question generation instruction, and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template; determining whether an assignment for the variable parameter is received; acquiring a variable parameter value of the variable parameter in response to receiving an assignment for the variable parameter; determining whether the variable parameter value satisfies the logic expression; and generating a target test question based on the test question template, the logic expression, the variable parameter, and the variable parameter value in response to the variable parameter value satisfying the logic expression.
Computer program code for carrying out operations of the present disclosure may be written in one or more programming languages, including, but not limited to, an object oriented programming language such as Java, smalltalk, C ++ and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computer (for example, through the Internet using an Internet service provider).
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules or units involved in the embodiments of the present disclosure may be implemented by means of software, or may be implemented by means of hardware.
The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: a Field Programmable Gate Array (FPGA), an Application Specific Integrated Circuit (ASIC), an Application Specific Standard Product (ASSP), a system on a chip (SOC), a Complex Programmable Logic Device (CPLD), and the like.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
According to one or more embodiments of the present disclosure, there is provided a method for generating a test question, including:
determining whether a test question generation instruction is received;
responding to a received test question generation instruction, and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template;
determining whether an assignment for the variable parameter is received;
acquiring a variable parameter value of the variable parameter in response to receiving an assignment for the variable parameter;
determining whether the variable parameter value satisfies the logic expression; and
and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value meeting the logic expression.
Preferably, the method further comprises:
and generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression.
Preferably, the responding to receiving the test question generating instruction, obtaining a preset test question template, a logic expression corresponding to the test question template and a variable parameter in the test question template, includes:
Obtaining a matched test question template from a pre-constructed test question database according to a request identifier in a received test question generation instruction, wherein the test question database stores the test question template, variable parameters in the test question template, a logic expression corresponding to the test question template and a pairwise corresponding relation among the test question template, the variable parameters and the logic expression;
and obtaining the corresponding logic expression and variable parameters according to the corresponding relation.
Preferably, the logical expression is generated by:
receiving an original logic expression input by a user and based on natural language;
and inputting the original logic expression into a preset conversion model to obtain a target logic expression based on machine language.
Preferably, the logical expression is a machine language based logical expression entered by a user.
Preferably, the method further comprises:
and solving the target test questions to obtain the solving results of the target test questions.
According to one or more embodiments of the present disclosure, there is provided an apparatus of example one, further comprising:
the first determining module is used for determining whether a test question generating instruction is received or not;
the first acquisition module is used for responding to the received test question generation instruction and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template;
A second determining module, configured to determine whether an assignment for the variable parameter is received;
the second acquisition module is used for acquiring variable parameter values of the variable parameters in response to receiving assignment of the variable parameters;
a third determining module for determining whether the variable parameter value satisfies the logic expression;
and the first generation module is used for responding to the variable parameter value to meet the logic expression, and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value.
Preferably, the method further comprises:
and the second generation module is used for generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression.
Preferably, the first acquisition module includes:
the test question template acquisition sub-module is used for acquiring matched test question templates from a pre-constructed test question database according to the request identification in the received test question generation instruction, wherein the test question templates, variable parameters in the test question templates, logic expressions corresponding to the test question templates and corresponding relations among the test question templates, the variable parameters and the logic expressions are stored in the test question database;
And the corresponding information acquisition sub-module is used for acquiring corresponding logic expressions and variable parameters according to the corresponding relation.
Preferably, the logical expression is generated by:
receiving an original logic expression input by a user and based on natural language;
and inputting the original logic expression into a preset conversion model to obtain a target logic expression based on machine language.
Preferably, the logical expression is a machine language based logical expression entered by a user.
Preferably, the method further comprises:
and the solving module is used for solving the target test questions to obtain solving results of the target test questions.
The foregoing description is only of the preferred embodiments of the present disclosure and description of the principles of the technology being employed. It will be appreciated by persons skilled in the art that the scope of the disclosure referred to in this disclosure is not limited to the specific combinations of features described above, but also covers other embodiments which may be formed by any combination of features described above or equivalents thereof without departing from the spirit of the disclosure. Such as those described above, are mutually substituted with the technical features having similar functions disclosed in the present disclosure (but not limited thereto).
Moreover, although operations are depicted in a particular order, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order. In certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of the present disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are example forms of implementing the claims.

Claims (10)

1. The test question generation method is characterized by comprising the following steps:
determining whether a test question generation instruction is received;
Responding to a received test question generation instruction, and acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template, wherein the test question template, the variable parameters and the logic expression have a pairwise corresponding relation;
determining whether an assignment for the variable parameter is received;
acquiring a variable parameter value of the variable parameter in response to receiving an assignment for the variable parameter;
determining whether the variable parameter value satisfies the logic expression; and
and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value in response to the variable parameter value meeting the logic expression.
2. The method for generating questions as claimed in claim 1, further comprising:
and generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression.
3. The method for generating a test question according to claim 1, wherein the obtaining a preset test question template, a logic expression corresponding to the test question template, and variable parameters in the test question template in response to receiving a test question generation instruction includes:
Obtaining a matched test question template from a pre-constructed test question database according to a request identifier in a received test question generation instruction, wherein the test question database stores the test question template, variable parameters in the test question template, a logic expression corresponding to the test question template and a pairwise corresponding relation among the test question template, the variable parameters and the logic expression;
and obtaining the corresponding logic expression and variable parameters according to the corresponding relation.
4. A method of generating questions as claimed in any one of claims 1 to 3, wherein the logic expression is generated by:
receiving an original logic expression input by a user and based on natural language;
and inputting the original logic expression into a preset conversion model to obtain a target logic expression based on machine language.
5. A method of generating questions as claimed in any one of claims 1 to 3, wherein the logic expression is a machine language based logic expression entered by a user.
6. The method for generating questions as claimed in claim 1, further comprising:
and solving the target test questions to obtain the solving results of the target test questions.
7. The utility model provides a generating device of test question which characterized in that includes:
the first determining module is used for determining whether a test question generating instruction is received or not;
the test question generation system comprises a first acquisition module, a second acquisition module and a test question generation module, wherein the first acquisition module is used for acquiring a preset test question template, a logic expression corresponding to the test question template and variable parameters in the test question template in response to receiving a test question generation instruction, and the test question template, the variable parameters and the logic expression have a pairwise corresponding relation;
a second determining module, configured to determine whether an assignment for the variable parameter is received;
the second acquisition module is used for acquiring variable parameter values of the variable parameters in response to receiving assignment of the variable parameters;
a third determining module for determining whether the variable parameter value satisfies the logic expression;
and the first generation module is used for responding to the variable parameter value to meet the logic expression, and generating a target test question based on the test question template, the logic expression, the variable parameter and the variable parameter value.
8. The apparatus for generating a test question according to claim 7, further comprising:
and the second generation module is used for generating an error prompt and displaying the error prompt in response to the variable parameter value not meeting the logic expression.
9. An electronic device, comprising:
a processor, a memory, and a bus;
the bus is used for connecting the processor and the memory;
the memory is used for storing operation instructions;
the processor is configured to execute the method for generating a test question according to any one of claims 1 to 6 by calling the operation instruction.
10. A computer-readable storage medium storing computer instructions that, when run on a computer, cause the computer to perform the method of generating a test question according to any one of the preceding claims 1-6.
CN201911039007.3A 2019-10-29 2019-10-29 Test question generation method and device, electronic equipment and computer readable storage medium Active CN110765752B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911039007.3A CN110765752B (en) 2019-10-29 2019-10-29 Test question generation method and device, electronic equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911039007.3A CN110765752B (en) 2019-10-29 2019-10-29 Test question generation method and device, electronic equipment and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN110765752A CN110765752A (en) 2020-02-07
CN110765752B true CN110765752B (en) 2023-09-01

Family

ID=69334445

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911039007.3A Active CN110765752B (en) 2019-10-29 2019-10-29 Test question generation method and device, electronic equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN110765752B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111968434A (en) * 2020-08-12 2020-11-20 福建师范大学协和学院 Method and storage medium for on-line paperless language training and evaluation
CN112579735B (en) * 2020-12-09 2023-04-28 北京字节跳动网络技术有限公司 Question generation method and device, computer equipment and storage medium
CN112863278B (en) * 2021-02-09 2022-07-01 柳州智视科技有限公司 Problem solving method after problem condition replacement

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101308486A (en) * 2008-03-21 2008-11-19 北京印刷学院 Test question automatic generation system and method
CN101727536A (en) * 2009-09-28 2010-06-09 江苏省电力试验研究院有限公司 Calculation problem variable parameter examination management system
EP2575123A1 (en) * 2011-09-30 2013-04-03 Tata Consultancy Services Limited Customized question paper generation
CN103761101A (en) * 2014-01-26 2014-04-30 国家电网公司 Method enabling parameters of computational problems in electricity test system to be changeable
KR101620818B1 (en) * 2015-07-14 2016-05-12 우병현 Method for providing mathematics question auto generating service
CN105678664A (en) * 2016-02-03 2016-06-15 成都爱易佰网络科技有限公司 Method for implementing intelligent change anti-cheating movable question bank
CN108052492A (en) * 2017-12-11 2018-05-18 上海启思教育科技服务有限公司 A kind of mathematical problem automatic creation system
WO2018094925A1 (en) * 2016-11-22 2018-05-31 深圳市鹰硕技术有限公司 Method and system for generating blank filling question and grading
CN108182052A (en) * 2017-12-07 2018-06-19 河南思维信息技术有限公司 A kind of railway implementation examination question generation method based on script
CN108628944A (en) * 2018-03-28 2018-10-09 北京大米科技有限公司 Online assignment input method, client, server, computer equipment and medium
CN109299220A (en) * 2018-09-03 2019-02-01 中国平安人寿保险股份有限公司 Worker's online testing test paper generation method and terminal device
CN109800256A (en) * 2019-01-07 2019-05-24 深圳中兴网信科技有限公司 Test paper generation method, creation system for test paper and computer readable storage medium
CN109885288A (en) * 2017-12-06 2019-06-14 张宗尚 A kind of system generating topic according to subject semantic network and the automation of corresponding semantic rules

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9028260B2 (en) * 2008-09-29 2015-05-12 Cisco Technology, Inc. Automated quiz generation system
US20150031011A1 (en) * 2013-04-29 2015-01-29 LTG Exam Prep Platform, Inc. Systems, methods, and computer-readable media for providing concept information associated with a body of text

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101308486A (en) * 2008-03-21 2008-11-19 北京印刷学院 Test question automatic generation system and method
CN101727536A (en) * 2009-09-28 2010-06-09 江苏省电力试验研究院有限公司 Calculation problem variable parameter examination management system
EP2575123A1 (en) * 2011-09-30 2013-04-03 Tata Consultancy Services Limited Customized question paper generation
CN103761101A (en) * 2014-01-26 2014-04-30 国家电网公司 Method enabling parameters of computational problems in electricity test system to be changeable
KR101620818B1 (en) * 2015-07-14 2016-05-12 우병현 Method for providing mathematics question auto generating service
CN105678664A (en) * 2016-02-03 2016-06-15 成都爱易佰网络科技有限公司 Method for implementing intelligent change anti-cheating movable question bank
WO2018094925A1 (en) * 2016-11-22 2018-05-31 深圳市鹰硕技术有限公司 Method and system for generating blank filling question and grading
CN109885288A (en) * 2017-12-06 2019-06-14 张宗尚 A kind of system generating topic according to subject semantic network and the automation of corresponding semantic rules
CN108182052A (en) * 2017-12-07 2018-06-19 河南思维信息技术有限公司 A kind of railway implementation examination question generation method based on script
CN108052492A (en) * 2017-12-11 2018-05-18 上海启思教育科技服务有限公司 A kind of mathematical problem automatic creation system
CN108628944A (en) * 2018-03-28 2018-10-09 北京大米科技有限公司 Online assignment input method, client, server, computer equipment and medium
CN109299220A (en) * 2018-09-03 2019-02-01 中国平安人寿保险股份有限公司 Worker's online testing test paper generation method and terminal device
CN109800256A (en) * 2019-01-07 2019-05-24 深圳中兴网信科技有限公司 Test paper generation method, creation system for test paper and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
试题智能提取技术的研究与实现;杜世瑾;中国优秀硕士学位论文全文数据库 信息科技辑;全文 *

Also Published As

Publication number Publication date
CN110765752A (en) 2020-02-07

Similar Documents

Publication Publication Date Title
CN111475298B (en) Task processing method, device, equipment and storage medium
CN110765752B (en) Test question generation method and device, electronic equipment and computer readable storage medium
CN111857720B (en) User interface state information generation method and device, electronic equipment and medium
CN111309304B (en) Method, device, medium and electronic equipment for generating IDL file
CN111738316B (en) Zero sample learning image classification method and device and electronic equipment
CN115357350A (en) Task configuration method and device, electronic equipment and computer readable medium
CN113392018B (en) Traffic distribution method and device, storage medium and electronic equipment
CN110888773B (en) Method, device, medium and electronic equipment for acquiring thread identification
CN111798251A (en) Verification method and device of house source data and electronic equipment
CN110689285A (en) Test method, test device, electronic equipment and computer readable storage medium
CN111680754B (en) Image classification method, device, electronic equipment and computer readable storage medium
CN113391860B (en) Service request processing method and device, electronic equipment and computer storage medium
CN111538717B (en) Data processing method, device, electronic equipment and computer readable medium
CN111563797A (en) House source information processing method and device, readable medium and electronic equipment
CN113792869B (en) Video processing method and device based on neural network chip and electronic equipment
CN111797932B (en) Image classification method, apparatus, device and computer readable medium
CN111026983B (en) Method, device, medium and electronic equipment for realizing hyperlink
CN116319322B (en) Power equipment node communication connection method, device, equipment and computer medium
CN112346728B (en) Device adaptation method, apparatus, device and computer readable medium
CN111399902B (en) Client source file processing method and device, readable medium and electronic equipment
CN111738415B (en) Model synchronous updating method and device and electronic equipment
CN111581305B (en) Feature processing method, device, electronic equipment and medium
CN114629821B (en) Internet of things consumption data generation method, device, equipment and medium
CN112036821B (en) Quantization method, quantization device, quantization medium and quantization electronic equipment based on grid map planning private line
CN116414359A (en) Card layout method, device, medium and electronic equipment

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
CB02 Change of applicant information

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: Douyin Vision Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant before: Tiktok vision (Beijing) Co.,Ltd.

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant after: Tiktok vision (Beijing) Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Applicant before: BEIJING BYTEDANCE NETWORK TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant