Randomized test paper generation method and system
By using a pre-defined two-dimensional array and a reservoir sampling algorithm, the problems of poor randomness and low efficiency in existing random test paper generation methods are solved, achieving efficient and random test paper generation, and improving user experience and system performance.
Patent Information
- Application Number
- CN202211435275.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2021-12-21
- Filing Date
- 2022-11-16
- Publication Date
- 2026-01-06
- Estimated Expiration
- 2042-11-16
AI Technical Summary
Existing randomized test paper generation methods suffer from poor randomness, high system costs, and low extraction efficiency, which negatively impact the user experience.
The system uses a pre-set two-dimensional array to store the question bank information, and a reservoir sampling algorithm to randomly select questions. It also generates target test papers based on the needs of test paper compilation, including dynamic adjustments to question types, quantities, and difficulty scores, to ensure the randomness and efficiency of the test papers.
It improves the randomness and efficiency of test paper generation, reduces system costs, enhances the user's test paper generation experience, and has a high degree of automation, reducing manual intervention.
Smart Images

Figure CN115935251B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of exam paper generation technology, specifically to a random exam paper generation method and a random exam paper generation system. Background Technology
[0002] Exam requirements are common in daily life. Traditional exam paper preparation involves compiling all questions into a question bank, which is then treated as a question set. Teachers and other administrators manually create exam papers when needed, a process highly subjective. Manual paper creation typically involves extracting and compiling multiple exam papers into a question bank, then randomly selecting papers when an exam is required. This method lacks flexibility because the generated papers cannot be modified; new questions must be created and the process repeated. To address this, automated random exam paper creation methods have emerged. Currently, three main methods exist: backtracking algorithms, genetic algorithms, and random selection. All three methods have inherent problems, such as poor randomness, high system costs, and low extraction efficiency. Therefore, a new random exam paper creation method is needed to address these issues. Summary of the Invention
[0003] The purpose of this application is to provide a method and system for randomizing test papers, so as to at least solve the problems of poor randomness, high system cost and low extraction efficiency of existing randomizing test paper methods.
[0004] To achieve the above objectives, the first aspect of this application provides a method for randomly generating test papers, including obtaining test paper generation requirements; randomly selecting and matching each question of the target test paper according to a preset two-dimensional array and the test paper generation requirements to obtain proposed test paper questions; wherein, the preset two-dimensional array is generated according to a preset question bank and is used to map all question information in the preset question bank; the target test paper is generated according to the proposed test paper questions and a preset test paper template, and the target test paper is output.
[0005] In this embodiment of the application, the test paper requirements include: question types and the number of questions for each question type; the overall difficulty score of the test paper; wherein, the number of questions for each question type is used to determine the preset test paper template.
[0006] In this embodiment of the application, the preset two-dimensional array includes: a question count array and a difficulty array; the preset two-dimensional array is represented as:
[0007] inta[n][m], c[n][m]
[0008] Where a[n][m] is the number of questions; c[n][m] is the difficulty array; n is the question type in the preset question bank; m is the preset difficulty level in the preset question bank; a is the number of questions with difficulty level m in the nth question type; and c is the difficulty score of questions with difficulty level m in the nth question type.
[0009] In this embodiment of the application, the method further includes: classifying the questions in the preset question bank, including: classifying the questions according to a preset learning model or preset annotation results; wherein, the preset learning model is a type differentiation model constructed using historical test paper questions based on question completion type differentiation as training samples; and the preset annotation results are the question type annotation results collected when the reviewer enters the questions.
[0010] In this embodiment of the application, the method further includes: classifying the difficulty of each question in the preset question bank into difficulty levels, including: preset multiple difficulty levels and determining the difficulty score range corresponding to each difficulty level; obtaining the difficulty score of each question in the preset question bank; matching the difficulty score of each question in the preset question bank with the determined difficulty score range corresponding to each difficulty level, and classifying each question in the preset question bank into the corresponding difficulty level.
[0011] In this embodiment of the application, the step of randomly selecting and adapting each question according to the test paper requirements based on a preset two-dimensional array to obtain the proposed test paper questions includes: extracting a question count array according to the question type and the number of questions of each question type; and extracting a difficulty array according to the overall difficulty score of the test paper; wherein, the extraction process of the question count array and the difficulty array is as follows: randomly selecting questions one by one according to the preset question type order.
[0012] In this embodiment of the application, the step of extracting the difficulty array based on the overall difficulty score of the test paper includes: randomly splitting the overall difficulty score of the test paper into a target number of parts equal to the total number of questions; wherein, the total number of questions is the sum of question types and the number of questions for each question type; after splitting, the value of each split part is between the minimum and maximum difficulty scores of questions in the preset question bank; determining the corresponding difficulty level of each split part, and counting the number of split parts under each difficulty level as the target number of questions under that difficulty level; splitting the target number of questions under each difficulty level and randomly distributing them to each question type based on the allocation rule; wherein, the allocation rule is to ensure that each difficulty level appears at least once in each question type; randomly extracting questions for each question type based on the random allocation result until the number of questions for all question types has been extracted.
[0013] In this embodiment of the application, the step of extracting the difficulty array based on the overall difficulty score of the test paper includes: for each randomly selected type of question, updating and statistically analyzing the total difficulty score of the selected type of question; for each update and statistical analysis of the total difficulty score of the selected type of question, calculating the difference between the overall difficulty score of the test paper and the total difficulty score of the selected type of question to obtain the remaining required difficulty score; for each randomly selected type of question, determining the difficulty level of each question under the corresponding question type, and updating the total number of questions at the corresponding difficulty level; if all questions have been extracted and the absolute value of the remaining required difficulty score is greater than a preset over-limit threshold, then adjusting the questions within the difficulty level with the largest number of questions, and obtaining the adjusted remaining required difficulty score, until the absolute value of the adjusted remaining required difficulty score is less than the preset over-limit threshold.
[0014] In this embodiment of the application, the random algorithm for randomly selecting questions is the reservoir sampling algorithm.
[0015] A second aspect of this application provides a random test paper generation system, comprising: a data acquisition unit for acquiring test paper generation requirements; a processing unit for randomly selecting and matching questions from a target test paper according to a preset two-dimensional array and the test paper generation requirements to obtain proposed test paper questions; wherein the preset two-dimensional array is generated according to a preset question bank and is used to map all question information in the preset question bank; and an output unit for assembling the target test paper according to the proposed test paper questions and a preset test paper template, and outputting the target test paper.
[0016] In this embodiment of the application, the system further includes a storage unit for storing the preset question bank.
[0017] A third aspect of this application provides a machine-readable storage medium storing instructions that, when executed by a processor, configure the processor to perform the above-described random volume assembly method.
[0018] A fourth aspect of this application provides a computer program product, including a computer program that, when executed by a processor, implements the above-described random volume generation method.
[0019] The above technical solution uses a pre-defined two-dimensional array to store all question information in the question bank (e.g., multiple question types, configurations for each question type, difficulty level, and score). The configuration of the two-dimensional array is then used to randomly select test papers that conform to the configured strategy. Users only need to enter their test paper creation requirements to automatically complete the extraction of all proposed test paper questions. Because this invention utilizes arrays, and array storage and random access to objects are the most efficient way to reference sequences, and collection classes are also implemented using arrays, arrays offer significant performance and speed advantages. This greatly improves test paper creation efficiency while ensuring the randomness of question extraction.
[0020] Other features and advantages of the embodiments of this application will be described in detail in the following detailed description section. Attached Figure Description
[0021] The accompanying drawings are provided to further illustrate the embodiments of this application and form part of the specification. They are used together with the following detailed description to explain the embodiments of this application, but do not constitute a limitation on the embodiments of this application. In the drawings:
[0022] Figure 1 The flowchart illustrating the steps of a randomized test paper generation method according to an embodiment of this application is shown in the schematic diagram.
[0023] Figure 2 This illustration schematically shows a system architecture diagram of a randomized test paper generation system according to an embodiment of this application;
[0024] Figure 3 The diagram illustrates the internal structure of a computer device according to an embodiment of this application. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only for illustration and explanation of the embodiments of this application and are not intended to limit the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.
[0026] It should be noted that if the embodiments of this application involve directional indicators (such as up, down, left, right, front, back, etc.), the directional indicators are only used to explain the relative positional relationship and movement of the components in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indicators will also change accordingly.
[0027] Furthermore, if the embodiments of this application involve descriptions such as "first" or "second," these descriptions are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, features defined with "first" or "second" may explicitly or implicitly include at least one of those features. Additionally, the technical solutions of various embodiments can be combined with each other, but this must be based on the ability of those skilled in the art to implement them. If the combination of technical solutions is contradictory or impossible to implement, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed in this application.
[0028] Exam requirements are common in daily life. Traditionally, exam paper preparation involves compiling all questions into a question bank, which is then treated as a question set. Teachers and other administrators manually create exam papers when needed, a process highly subjective. Manual paper creation typically involves extracting and compiling multiple exam papers into a question bank, then randomly selecting papers when an exam is required. This method lacks flexibility because the generated exam papers cannot be modified; new questions must be created and the process repeated. To address this, automated random question generation methods have emerged. Currently, there are three main random question generation methods:
[0029] 1) Backtracking Algorithm. The idea is to record each state type generated by the random selection method. When a search fails, the previously recorded state type is released, and a new state type is tried based on a pre-defined pattern. This backtracking process continues until the test paper is generated or the process returns to the starting point. Because it requires state type changes based on a pre-defined pattern, it is not an absolutely random algorithm. This conditional depth-first search algorithm has a good success rate for question bank systems with few state types and a small number of questions. However, in practical applications, it has been found to consume a lot of memory, have a relatively complex program structure, lack randomness in question selection, and have a long test paper generation time. The latter two points are unacceptable to users, therefore it is not a good algorithm for automatic test paper generation.
[0030] 2) Genetic Algorithm. Essentially, a genetic algorithm is a search algorithm that combines the natural selection and survival-of-the-fittest evolutionary mechanism of organisms with the random information exchange mechanism between individuals within the same population. It is a parallel and effectively optimized algorithm. To solve a problem using a genetic algorithm, the problem is first represented as a binary code. Then, basic operations are performed based on the environment to continuously select and survive, finally converging to the individual best adapted to the environmental conditions, thus obtaining the optimal solution. Although it has good solving results, it has many shortcomings, requiring various algorithmic improvements, and its usage cost is too high.
[0031] 3) Random Selection Method. This method involves the computer randomly selecting a question and adding it to the question bank based on control indicators in the state space. This process is repeated until the test paper is completed or no more questions that meet the control indicators can be selected from the question bank. This method has a simple structure and runs quickly for selecting a single question. However, it requires repeated cyclical selection. While it is efficient when there are few questions, its efficiency decreases as a large number of questions need to be selected.
[0032] It is evident that the three current random test paper generation methods all have certain problems, which greatly affect the user experience during test paper generation. This invention addresses these problems by simultaneously considering the short test paper generation time and stability, automatically executing according to the test paper generation strategy configuration. This invention combines a two-dimensional array to store all question information, such as various question types, configurations for each question type, difficulty level, and score. The configuration of the two-dimensional array is used to randomly select test papers that conform to the configuration strategy. This invention utilizes arrays; array storage and random access to objects is the most efficient way to reference sequences, and the underlying implementation of collection classes is also through arrays. Arrays offer significant advantages in performance and speed. Two-dimensional arrays are relatively simple and easy to understand; their structure is easy to comprehend. A two-dimensional array is simply a one-dimensional array nested within another one-dimensional array. For example, initializing a two-dimensional array `int[][]arr = new int[4][2]`, where `[4]` represents four one-dimensional arrays, each nested within a two-element one-dimensional array. This can be represented in tabular form as 4 rows and 2 columns.
[0033] Figure 1 A schematic flowchart illustrating a randomized document generation method according to an embodiment of this application is shown. Figure 1 As shown, in one embodiment of this application, a method for randomly generating test papers is provided, including the following steps:
[0034] Step S10: Obtain the volume assembly requirements.
[0035] Specifically, in order to reduce their workload and improve the objectivity and efficiency of test paper preparation, teachers only need to submit their test paper preparation requirements. These requirements can include the types of questions, the number of questions in each type, and the overall difficulty score of the test paper.
[0036] The question types include specific categories such as multiple choice, fill-in-the-blank, true / false, short answer, and essay questions. The number of questions in each question type corresponds to the total number of questions required for the target exam paper; for example, 15 multiple choice questions and 10 true / false questions.
[0037] The overall difficulty score of a test paper reflects its level of difficulty. This characteristic often requires teachers to make subjective judgments regarding question extraction and test paper assembly. In this invention, teachers only need to assess the difficulty of the test paper based on the desired level of evaluation and their assessment of students' mastery, then enter the assessed difficulty score. The system automatically assembles the test paper based on this score. This ensures that the final component's question types, the number of questions in each type, and the overall difficulty score of the test paper all meet the teacher's expectations. No teacher intervention is required throughout the process, and the system's intelligence and efficiency are well guaranteed.
[0038] Step S20: Randomly select and match each question of the target test paper according to the preset two-dimensional array and the test paper assembly requirements to obtain the proposed test paper questions.
[0039] Specifically, as mentioned above, the present invention uses a two-dimensional array to store multiple question types in the exam paper, along with the configuration, difficulty level, and score for each question type. The configuration of the two-dimensional array is then used to randomly select exam papers that conform to the configuration strategy. Therefore, the present invention also requires question bank organization. In the case of a massive question bank, this method only stores specific questions, without distinguishing between question types, difficulty levels, and scores. For such a question bank, it is first necessary to differentiate between question types.
[0040] In one embodiment, historical exam questions are extracted as training samples. Since the question types are already defined in the exam papers, a type differentiation model can be trained simply by using the question types and target answer patterns as training samples. After obtaining this type differentiation model, questions from a massive question bank are used as input to train the model, outputting the corresponding question types. This automatically differentiates and organizes the question types from the massive question bank, completing the entire question bank organization process.
[0041] In one embodiment, when entering questions, a type input function is enabled, allowing teachers to select a type while entering the question, and then label the question based on the selected type. This labeling result can then serve as a type tag for the corresponding question, and the question can be categorized based on this tag.
[0042] After classifying the types of questions, it's necessary to classify them by difficulty level. Multiple difficulty levels can be preset, such as hard, medium, and easy. Each question has a specific difficulty score, determined by teacher annotations or the context during question generation. However, the score is only a quantitative condition. To better differentiate between questions, a qualitative distinction is needed, namely, differentiating between the different difficulty levels. Different difficulty levels correspond to different difficulty score ranges. Once the difficulty score for each question is obtained, the difficulty relationships for that question can be determined.
[0043] A two-dimensional array is essentially an array of arrays, that is, an "array of arrays". In this invention, the two component arrays are a question count array and a difficulty array. The question count array stores the number of questions for each question type and difficulty level, while the difficulty array stores the score for each question type and difficulty level. The specific expression is as follows:
[0044] inta[n][m], c[n][m]
[0045] Where a[n][m] is the number of questions; c[n][m] is the difficulty array; n is the question type in the preset question bank; m is the preset difficulty level in the preset question bank; a is the number of questions of difficulty level m in the nth type; and c is the difficulty score of questions of difficulty level m in the nth type. For example, if there are five question types in the question bank: single choice, multiple choice, true / false, fill-in-the-blank, and short answer, and the corresponding preset difficulty levels are hard, medium, and easy, then the corresponding number of questions array is int[5][3]a, and the corresponding difficulty array is int[5][3]c. Where [5] represents the five question types, and [3] represents the three difficulty levels.
[0046] After establishing the rules for the two-dimensional array, questions need to be extracted according to these rules. Preferably, in this invention, the random algorithm used is the reservoir sampling algorithm. This is because, with the continuous addition of historical questions and new questions, the number of questions in the question bank becomes enormous. If the entire question bank needs to be traversed every time a question is extracted, it will inevitably cause significant latency, which contradicts the requirement for efficient extraction of a large number of questions from a test paper. To solve this problem, the ideal condition is that all questions can be extracted by traversing the question bank only once. Suitable for this requirement, the random algorithm used in this invention is the reservoir sampling algorithm. This application scenario is generally in the case of data streams. Since the data can only be read once and the data volume is large, it cannot all be saved. Therefore, the data volume cannot be determined at the beginning of sampling, but randomness must be maintained. The core issue here is "randomness." The implementation is as follows: For example, a reservoir has a capacity of k. For n (n>k) elements, if the i-th element (i increasing from 1 to n) is added to the reservoir with a probability of k / i, then when i=n, the reservoir contains a uniform sample of n elements, and each number has an equal probability of being stored in the array, which is k / n. The goal is to randomly select k elements from N elements, where N is undetermined. Based on this method, given a large test bank, only one data iteration is needed to achieve the goal of random selection.
[0047] Based on the above method, questions are extracted from a pre-defined two-dimensional array.
[0048] Specifically, in one embodiment, the number of questions and their corresponding difficulty levels for each type of question are first determined, and questions are randomly selected based on the determined allocation rules. First, the overall difficulty score of the test paper in the teacher's test paper compilation requirements is divided into multiple parts, the specific number of parts being the same as the total number of questions, where the total number of questions is the sum of the question types and the number of questions for each question type.
[0049] For example, if the entire test paper has 50 questions, then the overall difficulty score of the test paper will be randomly divided into 50 parts. For example, if the difficulty score is 80 points, then the 80 points need to be randomly divided into 50 parts, and the score of each part is the difficulty score of the corresponding target question.
[0050] Preferably, to avoid extreme imbalances in difficulty, such as having 49 questions worth 1 point and one question worth 31 points, which would inevitably lead to an unbalanced exam paper, two methods are used to limit this. First, a maximum score limit is set for each question; the scores after splitting must fall between the minimum and maximum difficulty scores in the pre-defined question bank, preventing scores exceeding the upper limit. Second, thresholds are set for each difficulty level; for example, a high threshold for medium difficulty and low thresholds for low and high difficulty, ensuring that medium difficulty questions are more prevalent in the split portions. After obtaining the score for each portion, it is assigned to a matching difficulty range to determine the number of questions within that range. For example, low: 10; medium: 35; difficult: 5. Then, these target questions are assigned to corresponding question types. To avoid a clustering of easy or difficult questions within a particular question type, a pre-defined restriction rule ensures that each difficulty level appears at least once in each question type. For example, if there are 5 questions of high difficulty, these 5 questions will be evenly distributed among the 5 corresponding types, ensuring that each type contains one question of the highest difficulty level, thereby maintaining the balance of the test paper. After the distribution is completed, distribution rules are generated based on the simulated distribution process, and questions are randomly selected according to these rules.
[0051] For example, the selection of multiple-choice questions is first carried out in three steps, corresponding to the selection steps of three difficulty levels. First, easy-difficulty questions are selected, with a quantity of a[0][0] and a score of [0][0]. Then, medium-difficulty questions are selected, with a quantity of a[0][1] and a score of [0][1]. Finally, difficult-difficulty questions are selected, with a quantity of a[0][2] and a score of [0][2]. By combining two arrays to distinguish between the quantity and difficulty score, the purpose of random selection is achieved. Correspondingly, for the second type of question, the selection rules for the three steps are as follows: easy-difficulty questions are selected, with a quantity of a[1][0] and a score of [1][0]. Medium-difficulty questions are selected, with a quantity of a[1][1] and a score of [1][1]. Difficult-difficulty questions are selected, with a quantity of a[1][2] and a score of [1][2]. Similarly, for the fifth question type, the three steps of the selection rules are as follows: select easy questions, the quantity is a[4][0], and the score is [4][0]; select medium questions, the quantity is a[4][1], and the score is [4][1]; select difficult questions, the quantity is a[4][2], and the score is [4][2].
[0052] In one embodiment, instead of pre-setting allocation rules, the allocation rules are dynamically adjusted. Random selection begins directly based on the question number. For each randomly selected question, its difficulty score is determined, and the total difficulty score of the selected questions is updated. For example, if the difficulty scores of five selected questions are 2, 3, 4, 2, and 5, the corresponding updated total difficulty score is 16. Each time the total difficulty score of the selected questions is updated, the difference between the overall difficulty score of the exam and the total difficulty score of the selected questions is calculated to obtain the remaining required difficulty score.
[0053] For example, if the total difficulty score is 80 points, then the remaining required difficulty score after the third update is 64 points. Each randomly selected question determines its difficulty level, and the total number of questions at that difficulty level is updated. After selecting questions of each type and specific number, the final remaining required difficulty score is obtained. A score of 0 indicates that the final test paper's difficulty score is exactly 80 points; a negative score indicates that the final test paper's difficulty score is greater than 80 points; and a positive score indicates that the final test paper's difficulty score is less than 80 points. Difficulty level is a vague concept and does not necessarily guarantee a difficulty score of 80 points, so a certain fluctuation range can be preset, such as 80 ± 5. Therefore, when the absolute value of the remaining required difficulty score is greater than 5, it indicates that the current test paper is too easy or too complex compared to the expected test paper, requiring dynamic adjustment. Since the question types with the most medium difficulty are the most numerous, the type with the most questions is selected for adjustment. Several questions with the most difficulty levels are randomly selected for adjustment, and the remaining required difficulty score after adjustment is calculated until its absolute value is less than 5, at which point the component result is determined to meet expectations.
[0054] Step S30: Assemble the target test paper according to the proposed test paper questions and the preset test paper template, and output the target test paper.
[0055] Specifically, after the questions are extracted, the exam paper needs to be assembled based on these questions, and the paper is automatically formatted using a preset template. According to general patterns, the difficulty of the questions increases progressively, meaning the earlier questions are usually easier, with the difficulty gradually increasing as you move on. For example, the last question is often the most difficult and challenging one. To accommodate this rule, the extracted questions are sorted by difficulty score from lowest to highest. The exam paper is then automatically formatted based on this rule, and a complete exam paper is output after formatting. This allows for direct testing based on the complete exam paper, completely freeing up teachers' time and greatly improving the system's convenience.
[0056] like Figure 2 The present invention also provides a random test paper generation system, the system comprising: a data acquisition unit for acquiring test paper generation requirements; a processing unit for randomly selecting and matching questions of a target test paper according to a preset two-dimensional array and the test paper generation requirements to obtain proposed test paper questions; wherein the preset two-dimensional array is generated according to a preset question bank and is used to store all question information in the preset question bank; and an output unit for assembling the target test paper according to the proposed test paper questions and a preset test paper template, and outputting the target test paper.
[0057] In one embodiment, the system further includes a storage unit for storing the preset question bank.
[0058] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.
[0059] This application provides a storage medium storing a program that, when executed by a processor, implements the above-described random volume generation method.
[0060] This application provides a processor for running a program, wherein the program executes the above-described random volume generation method during runtime.
[0061] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 3 As shown in the figure, the computer device includes a processor A01, a network interface A02, a display screen A04, an input device A05, and a memory (not shown) connected via a system bus. The processor A01 provides computing and control capabilities. The memory includes internal memory A03 and a non-volatile storage medium A06. The non-volatile storage medium A06 stores an operating system B01 and a computer program B02. The internal memory A03 provides an environment for the operation of the operating system B01 and the computer program B02 stored in the non-volatile storage medium A06. The network interface A02 is used for communication with external terminals via a network connection. When the computer program is executed by the processor A01, it implements a randomized volume composition method. The display screen A04 can be a liquid crystal display (LCD) or an e-ink display. The input device A05 can be a touch layer covering the display screen, buttons, a trackball, or a touchpad mounted on the computer device casing, or an external keyboard, touchpad, or mouse.
[0062] Those skilled in the art will understand that Figure 3 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0063] In one embodiment, the random test paper generation system provided in this application can be implemented as a computer program, which can be implemented in the form of, for example... Figure 3 The system runs on the computer device shown. The computer device's memory can store the various program modules that make up the random volume generation system. The computer program, composed of the various program modules, causes the processor to execute the steps in the random volume generation methods of the various embodiments of this application described in this specification.
[0064] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0065] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0066] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0067] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0068] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0069] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0070] Computer-readable media include both permanent and non-permanent, removable and non-removable media, which can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0071] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0072] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method for random group drawing, characterized by, The method comprises: acquiring a test paper setting requirement; performing random extraction and adaptation of each question of a target test paper according to a preset two-dimensional array and the test paper setting requirement to obtain a draft test paper question; wherein the preset two-dimensional array is generated according to a preset question bank and is used to map all question information in the preset question bank; wherein the performing random extraction and adaptation of each question of the target test paper according to the preset two-dimensional array and the test paper setting requirement to obtain the draft test paper question comprises: performing question number array extraction according to question types and the number of questions of each question type; performing difficulty array extraction according to an overall difficulty score of the test paper; wherein the extraction process of the question number array extraction and the difficulty array extraction is: performing random extraction of questions one by one according to a preset question type order; the performing difficulty array extraction according to the overall difficulty score of the test paper comprises: updating the total difficulty score of the extracted type questions once for each random extraction of a question of the type; performing difference between the overall difficulty score of the test paper and the total difficulty score of the extracted type questions once for each update of the total difficulty score of the extracted type questions to obtain a remaining requirement difficulty score; determining the difficulty level of each question under the corresponding question type and updating the total number of questions of the corresponding difficulty level once for each random extraction of a question of the type; if all questions are extracted, the absolute value of the remaining requirement difficulty score is greater than a preset super threshold, then adjusting the questions in the difficulty level with the largest total number of questions, and obtaining an adjusted remaining requirement difficulty score, until the absolute value of the adjusted remaining requirement difficulty score is less than the preset super threshold; composing the target test paper according to the draft test paper question and a preset test paper template, and outputting the target test paper; wherein the outputting the target test paper comprises: sorting the difficulty scores of the extracted questions in ascending order, automatically typesetting the test paper based on the sorting result, and outputting a complete test paper after the typesetting is completed.
2. The method of claim 1, wherein, The test paper setting requirement comprises: question types and the number of questions of each question type; an overall difficulty score of the test paper; wherein the number of questions of each question type is used to determine the preset test paper template.
3. The method of claim 1, wherein, The preset two-dimensional array comprises: a question number array and a difficulty array; the preset two-dimensional array is represented as: wherein, is an array of topic numbers; difficulty array; n is a question type in the preset question bank; m is a preset difficulty level in the preset question bank; a is the number of questions of the nth question type with difficulty level m; c is the difficulty score of the question of the nth question type with difficulty level m.
4. The method of claim 3, wherein, The method further comprises: classifying each question in the preset question bank, comprising: classifying the questions according to a preset learning model or a preset annotation result; wherein the preset learning model is a type distinguishing model constructed by taking historical test paper questions distinguished based on question completion types as training samples; the preset annotation result is a question type annotation result corresponding to the question collected when an auditor enters the question.
5. The method of claim 3, wherein, The method further comprises: dividing the difficulty of each question of the preset question bank into difficulty levels, comprising: presetting a plurality of difficulty levels and determining the difficulty score range corresponding to each difficulty level; obtaining the difficulty score of each question in the preset question bank; The difficulty scores of the questions in the preset question bank are matched with the difficulty score ranges corresponding to the determined difficulty levels, and the questions in the preset question bank are divided into corresponding difficulty levels.
6. The method of claim 1, wherein, The difficulty array extraction according to the overall difficulty score of the test paper comprises: The overall difficulty score of the test paper is randomly split, and the target number of split parts is equal to the total number of questions; wherein the total number of questions is the sum of the number of question types and the number of questions of each question type; The numerical value of each split part after splitting is between the minimum value and the maximum value of the question difficulty scores in the preset question bank; The corresponding difficulty level of each split part after splitting is determined, and the number of split parts under each difficulty level is counted as the number of questions under the difficulty level; The number of questions under each difficulty level is split and randomly allocated to each question type based on the allocation rule; wherein the allocation rule is to ensure that each difficulty level appears at least once in each question type; Based on the random allocation result, the questions under each question type are randomly extracted until the number of questions of all question types is extracted.
7. The method of claim 1, wherein, The random algorithm for random question extraction is the reservoir sampling algorithm.
8. A random group building system, characterized by The system is applied to the random group test method of any one of claims 1-7, and the system comprises: The acquisition unit is configured to obtain group test requirements; The processing unit is configured to perform random extraction and adaptation of each question of the target test paper based on a preset two-dimensional array and the group test requirements, and obtain a draft test paper; wherein the preset two-dimensional array is generated based on a preset question bank and is used to map all question information in the preset question bank; The output unit is configured to form the target test paper based on the draft test paper and a preset test paper template, and output the target test paper.
9. The system of claim 8, wherein, The system further comprises: The storage unit is configured to store the preset question bank.
10. A computer-readable storage medium having instructions stored thereon, which, when executed on a computer, cause the computer to perform the random group test method of any one of claims 1-7.
11. A computer program product comprising a computer program, characterized in that, The computer program, when executed by a processor, implements the random group test method of any one of claims 1-7. The computer program, when executed by a processor, implements the random group test method of any one of claims 1-7.
Citation Information
Patent Citations
Automatic questions selecting method of examination system on network based on layered genetic algorithm
CN102663910A
Test paper question generation method, electronic device and readable storage medium
CN112182316A