Test question generation method and device, computer device and readable storage medium
By collecting learner behavior data and learning objective information, test question texts are generated and verified, solving the problems of applicability and personalized generation in existing technologies, and achieving highly professional and adaptable test question generation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGZHOU POWER SUPPLY BUREAU GUANGDONG POWER GRID CO LTD
- Filing Date
- 2026-04-17
- Publication Date
- 2026-07-21
AI Technical Summary
Existing test question generation methods are not suitable for highly specialized and structurally complex technical fields, and lack the ability to be deeply integrated with the individual learning process of learners.
The system collects learners' behavioral data on the learning platform, generates learning state vectors through feature fusion processing, concatenates these vectors with learning target information, inputs them into a pre-built test question generation model, generates and verifies initial test question texts, and finally determines target test question texts relevant to the learners.
It generates personalized test questions applicable to various professional fields, which can be combined with learners' current knowledge and learning objectives, and have high professionalism and adaptability.
Smart Images

Figure CN122432327A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to a test question generation method, apparatus, computer device, computer-readable storage medium, and computer program product. Background Technology
[0002] With the rapid development of artificial intelligence and large language models (LLMs) technology, automated test item generation methods based on language models have received widespread attention in the field of education.
[0003] Current mainstream test question generation methods mostly rely on pre-trained language models, which generate question stems and answer choices by inputting topics or keywords. However, existing test question generation methods are not suitable for highly specialized and structurally complex technical fields, and lack the ability to deeply integrate with the individual learning process of learners.
[0004] Therefore, how to generate test questions that are applicable to various professional fields and can be combined with learners' own learning situations is an urgent problem to be solved. Summary of the Invention
[0005] Therefore, it is necessary to provide a test question generation method, device, computer equipment, computer-readable storage medium, and computer program product that can be applied to various professional fields and combined with the learner's own learning situation to address the above-mentioned technical problems.
[0006] Firstly, this application provides a method for generating test questions, including:
[0007] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0008] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0009] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target learner.
[0010] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0011] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0012] In one embodiment, the learning behavior data includes learning behavior sub-data at different timestamps. Feature fusion processing is performed on the learning behavior data to obtain the learning state vector of the target learner, including:
[0013] The learning behavior data is sorted according to timestamp order to generate a time series of the target learner's learning behavior.
[0014] Temporal feature modeling is performed on the learning behavior time series to obtain the hidden state sequence of the target learner. The hidden state sequence is used to characterize the evolutionary features of the target learner's learning behavior in the temporal sequence.
[0015] Based on the hidden state sequence, the learning state vector of the target learner is generated by performing first attention interaction on the hidden states at different time steps.
[0016] In one embodiment, the learning target standard sequence includes multiple words; the learning target standard sequence is vectorized and encoded to obtain the learning target vector of the target learner, including:
[0017] Multiple words in the standard sequence of the learning target are vectorized and encoded to obtain the word vector sequence of the target learner;
[0018] Based on word vector sequences, a learning target vector for the target learner is generated by performing a second attention interaction on multiple word vectors.
[0019] In one embodiment, the steps for constructing the question generation model include:
[0020] Obtain structured question bank data and real feedback data from teaching scenarios, and use the structured question bank data and real feedback data from teaching scenarios as sample data;
[0021] A portion of the sample data is used as fine-tuning sample data, and random perturbation is applied to the remaining sample data to obtain perturbed sample data.
[0022] Obtain the conditional language generation model to be trained, input the fine-tuned sample data and perturbation sample data into the conditional language generation model, and calculate the cross-entropy loss of the fine-tuned sample data and perturbation sample data through the loss function.
[0023] Based on the cross-entropy loss of the fine-tuned sample data and the perturbed sample data, the parameters of the conditional language generation model are updated to obtain the test item generation model.
[0024] In one embodiment, the conditional control vector is input into a pre-built question generation model to generate initial question text, including:
[0025] Input the conditional control vector into the pre-built question generation model, and the question generation model performs the following operations:
[0026] Calculate the conditional probability distribution of multiple word units based on the conditional control vector;
[0027] The conditional probability distribution is adjusted using professional vocabulary vectors to obtain the target probability distribution. The professional vocabulary vectors are obtained by mapping the professional terminology set to the vocabulary space of the test item generation model. The professional terminology set includes professional terms in the teaching field of the learning objectives.
[0028] Based on the target probability distribution of multiple word units, target word units are selected from multiple word units, and initial test text is generated based on the target word units.
[0029] In one embodiment, based on the validated initial test text, a target test text relevant to the target learner is determined, including:
[0030] Based on the standardized structure of the test questions, the initial test question text that has passed the verification is segmented to obtain the target test question text that is relevant to the target students.
[0031] Secondly, this application also provides a test question generation device, comprising:
[0032] The data acquisition module is used to collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0033] The encoding module is used to obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0034] The concatenation module is used to concatenate the learning state vector and the learning target vector to obtain the conditional control vector of the target learner.
[0035] The generation module is used to input the conditional control vector into the pre-built question generation model to generate the initial question text.
[0036] The verification module is used to verify the professional knowledge of the initial test question text, and based on the verified initial test question text, to determine the target test question text that is relevant to the target students.
[0037] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:
[0038] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0039] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0040] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target student.
[0041] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0042] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0043] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:
[0044] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0045] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0046] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target learner.
[0047] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0048] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0049] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps:
[0050] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0051] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0052] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target student.
[0053] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0054] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0055] The aforementioned test question generation method, apparatus, computer equipment, computer-readable storage medium, and computer program product collect learning behavior data of target learners on a learning platform, perform feature fusion processing on the learning behavior data to obtain the learning state vector of the target learners; obtain the target description information of the target learners' learning objectives, perform semantic analysis on the target description information to obtain a standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners; concatenate the learning state vector and the learning objective vector to obtain the conditional control vector of the target learners. The conditional control vector obtained through the above process can maintain the independence of the two types of information, namely state and objective, so that the subsequent test question generation model can focus on the target learners' ability foundation and problem orientation respectively. The conditional control vector is input into a pre-constructed test question generation model to generate initial test question text; the initial test question text is verified for professional knowledge, and based on the verified initial test question text, target test question texts related to the target learners are determined. The above process comprehensively models the target learners' historical learning behavior to extract their current knowledge mastery, ability characteristics, and interest preferences. This information, combined with learning objective information, serves as input for the generation of the large model. This enables a more targeted and adaptive generation process based on the dual information of "who the learner is" (status) and "what the learner wants to do" (objective). Ultimately, it generates personalized test questions that fit the individual ability structure of the target learners, have clear goal orientation, and possess high professionalism. Attached Figure Description
[0056] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0057] Figure 1 This is a diagram illustrating the application environment of a question generation method in one embodiment;
[0058] Figure 2This is a flowchart illustrating a test question generation method in one embodiment;
[0059] Figure 3 This is a flowchart illustrating the question generation method in another embodiment;
[0060] Figure 4 This is a structural block diagram of a test question generation device in one embodiment;
[0061] Figure 5 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0062] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0063] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.
[0064] The test question generation method provided in this application embodiment can be applied to, for example, Figure 1The application environment shown is illustrated. Terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104 or located on the cloud or other network servers. A learning platform exists on terminal 102 or server 104. This learning platform can be an intelligent education platform, an adaptive training system, or a professional qualification examination simulation system, etc., and is particularly suitable for deployment in professional technical fields (such as secondary protection of power systems) where high requirements for knowledge structure and terminology accuracy are necessary. Specifically, terminal 102 or server 104 executes a test question generation method on the existing learning platform. The method includes: collecting learning behavior data of the target learner on the learning platform; performing feature fusion processing on the learning behavior data to obtain the learning state vector of the target learner; obtaining the target description information of the target learner's learning objectives; performing semantic analysis on the target description information to obtain a standard sequence of learning objectives; vectorizing the standard sequence of learning objectives to obtain the learning objective vector of the target learner; concatenating the learning state vector and the learning objective vector to obtain the conditional control vector of the target learner; inputting the conditional control vector into a pre-constructed test question generation model to generate initial test question text; performing professional knowledge verification on the initial test question text; and determining the target test question text related to the target learner based on the verified initial test question text.
[0065] Terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, drones, low-altitude aircraft, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, and projection equipment. Portable wearable devices can include smartwatches, smart bracelets, and head-mounted displays. Head-mounted displays can be virtual reality (VR) devices, augmented reality (AR) devices, and smart glasses. Server 104 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.
[0066] In one exemplary embodiment, such as Figure 2 As shown, a test question generation method is provided, which can be applied to... Figure 1 Taking terminal 102 as an example, the explanation includes the following steps 202 to 210. Wherein:
[0067] Step 202: Collect learning behavior data of the target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0068] Learning behavior data refers to the behavioral data recorded by the learning platform when students are learning, including answer records, knowledge point tags, correctness of answers, timestamps, question type preferences, and sets of incorrect questions. The learning state vector is a state vector representing the current knowledge structure and behavioral patterns of the target student.
[0069] Optionally, by obtaining the target learner's identifier, the learning platform can query and obtain the target learner's learning behavior data based on the target learner's identifier.
[0070] For example, the learning behavior data is sorted according to timestamp order to obtain a learning behavior time series. By modeling the learning behavior time series and introducing a self-attention mechanism, the learning state vector of the target learner is obtained.
[0071] Step 204: Obtain the target description information of the target learner's learning objectives, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learner.
[0072] The target description information describes the current learning objectives of the learners, and the information is expressed primarily in natural language, outputting with a unified structure. The learning objective vector represents the semantic focus, knowledge point bias, and expression intensity within the learning objectives.
[0073] For example, information such as platform settings (e.g., "Specialized training: distance protection"), teaching information assigned by teachers (e.g., "Review Chapter 5"), and target information entered by students themselves (e.g., "Prepare for the relay protection exam") can be obtained, and the platform settings, teaching information, and target information can be used as target description information.
[0074] For example, word segmentation, embedding, and semantic extraction operations are performed sequentially on the target description information to obtain the standard sequence of learning targets. .
[0075] For example, by using an embedding function and a self-attention mechanism, the standard sequence of learning objectives is vectorized to obtain the learning state vector of the target learner.
[0076] Step 206: Concatenate the learning state vector and the learning target vector to obtain the conditional control vector of the target student.
[0077] Among them, the conditional control vector is the core control signal that acts on the test item generation model, and is used to characterize the target learners' ability base and task direction.
[0078] Optionally, "vector concatenation" can achieve a good balance between expressive power and modeling simplicity. By combining the learning state vector and the learning target vector, the generated conditional control vector for the target learner is:
[0079]
[0080] in, For conditional control vectors, To learn the state vector, The target vector is to be learned.
[0081] Optionally, in complex task scenarios requiring high-precision control of generated content, to further enhance semantic fusion capabilities, a nonlinear fusion method can be used to transform and combine the learning state vector and the learning target vector, for example:
[0082]
[0083] in, , For fusion layer parameters, For example, ReLU is an activation function.
[0084] Step 208: Input the conditional control vector into the pre-built question generation model to generate the initial question text.
[0085] Among them, the learning state vector in the conditional control vector is used to guide the test question generation model to generate test questions that match the current ability level characteristics of the target learner, and the learning target vector in the conditional control vector is used to control the generation direction of the test question generation model.
[0086] Optionally, the pre-built test item generation model can be a pre-trained conditional language mode (CLM) based on the Transformer decoder structure. The conditional language generation model can achieve personalized text generation by introducing conditional control vectors.
[0087] For example, the conditional control vector is input into a pre-built question generation model, which then performs the following operations: Based on the target expression in the conditional control vector, it generates specific question types, such as multiple choice, true / false, and fill-in-the-blank questions; based on the knowledge weakness areas represented by the learning state vector in the conditional control vector, it constrains the terminology selection and knowledge boundaries of the generated question text content to guide the generation of initial question text targeting the areas that the target learner needs to improve; based on the learning state vector in the conditional control vector, it controls the language style of the initial question text, for example, based on the learning state vector in the conditional control vector, it determines the learning stage of the target learner and outputs different expression granularities for learners at different stages—beginners generate more concise question stems, while advanced learners focus more on logical rigor and conceptual connections; based on parameters such as the success rate and error density represented by the learning state vector in the conditional control vector, it dynamically adjusts dimensions such as sentence complexity, distractor density, and trap logic design of the initial question text.
[0088] Step 210: Perform professional knowledge verification on the initial test text, and based on the verified initial test text, determine the target test text that is relevant to the target students.
[0089] Among them, professional knowledge verification includes terminology consistency verification, symbol and formula consistency verification, knowledge point association matching verification, and language structure integrity verification.
[0090] For example, to enable the verification process to dynamically complete the professional verification process without introducing explicit rule templates, and to improve the interpretability, accuracy, and adaptability of the initial test text and the test generation model, the verification data can come from the intermediate variable states retained by the test generation model during the generation of the initial test text, including but not limited to: the decoder state used to determine the content generation path. The conditional vector interaction matrix represents whether the current content deviates from the target knowledge point region, and the word-level generation distribution is used to explain whether the generated token deviates.
[0091] For example, the initial test text is subjected to terminology consistency check, symbol and formula consistency check, knowledge point association matching check, and language structure integrity check. If all the above checks pass, the target test text related to the target learner is determined based on the initial test text that has passed the checks.
[0092] Optionally, the initial test text is subjected to Named Entity Recognition (NER) and professional dictionary matching to determine whether the correct terminology is used in the initial test text and to check whether the terminology is consistent with the context, such as preventing the confusion between "current transformer" and "voltage transformer". If the correct terminology is used and the terminology is consistent with the context, the initial test text is determined to have passed the terminology consistency check.
[0093] Optionally, the system checks whether commonly used formulas (such as electricity formulas) and symbols in the initial test text are written correctly (such as units, subscripts and superscripts, and symbol consistency), and whether the variables in the question stem and options match. If no problems are found, the initial test text is confirmed to have passed the symbol and formula consistency check.
[0094] Optionally, a knowledge point graph or hierarchical tagging system can be invoked. Based on the knowledge points within the knowledge point graph or hierarchical tagging system, it can be determined whether the initial test question text covers the specified knowledge point area, and whether the question type in the initial test question text matches the target knowledge target logic (e.g., whether analytical questions involve causal chains). If the initial test question text covers the specified knowledge point area and the question type matches the target knowledge target logic, it can be determined that the initial test question text has passed the knowledge point association matching verification.
[0095] Optionally, check whether the question stem in the initial test text has a clear question structure (guidance + question), determine whether there is semantic ambiguity or expression in the initial test text, and confirm that the initial test text passes the language structure integrity check if the question stem in the initial test text has a clear question structure and there is no semantic ambiguity or expression incompleteness.
[0096] For example, in all the above checks, if an error is detected, minor errors (such as spelling of terms) can be automatically corrected, vague expressions can be suggested to be replaced, or the problematic text can be marked as "suspicious content" and pushed to the teacher for review.
[0097] In the above question generation method, learning behavior data of target learners on the learning platform is collected, and feature fusion processing is performed on the learning behavior data to obtain the learning state vector of the target learners. The target description information of the learning objectives of the target learners is obtained, and semantic analysis is performed on the target description information to obtain a standard sequence of learning objectives. The standard sequence of learning objectives is vectorized and encoded to obtain the learning objective vector of the target learners. The learning state vector and the learning objective vector are concatenated to obtain the conditional control vector of the target learners. The conditional control vector obtained through the above process can maintain the independence of the two types of information, state and objective, which facilitates the subsequent question generation model to focus on the target learners' ability foundation and problem orientation respectively. The conditional control vector is input into a pre-constructed question generation model to generate initial question text. The initial question text is then subjected to professional knowledge verification. Based on the verified initial question text, target question texts relevant to the target learners are determined. The above process comprehensively models the target learners' historical learning behavior to extract their current knowledge mastery, ability characteristics, and interest preferences. This information, combined with learning objective information, serves as input for the generation of the large model. This enables a more targeted and adaptive generation process based on the dual information of "who the learner is" (status) and "what the learner wants to do" (objective). Ultimately, it generates personalized test questions that fit the individual ability structure of the target learners, have clear goal orientation, and possess high professionalism.
[0098] In an exemplary embodiment, the learning behavior data includes learning behavior sub-data at different timestamps. Feature fusion processing is performed on the learning behavior data to obtain the learning state vector of the target learner. This includes: sorting multiple learning behavior sub-data in the learning behavior data according to timestamp order to generate a learning behavior time series of the target learner; performing temporal feature modeling on the learning behavior time series to obtain a hidden state sequence of the target learner, whereby the hidden state sequence is used to characterize the temporal evolution of the target learner's learning behavior; and generating the learning state vector of the target learner based on the hidden state sequence by performing a first attention interaction on the hidden states at different time steps.
[0099] The learning behavior sub-data includes behavioral data such as answer records, knowledge point tags, correct and incorrect answers, question type preferences, and sets of incorrect questions corresponding to each timestamp. A timestamp is a character sequence or numerical information that can identify a certain moment and is used to record the time when each learning behavior sub-data occurs.
[0100] For example, sorting multiple learning behavior sub-data in the learning behavior data according to timestamp order to form a time series of the target learner's learning behavior can be represented as follows:
[0101]
[0102] in, A learning behavior unit includes a vector of question content. Answer results Answering time Features such as...
[0103] Optionally, a Bidirectional Long Short-Term Memory (BiLSTM) network can be used to model the temporal features of the learning behavior time series, obtaining multiple hidden states:
[0104]
[0105] Combine multiple hidden states into a hidden state sequence:
[0106]
[0107] in, The hidden state sequence is used to characterize the temporal evolution of the learning behavior of the target learners.
[0108] For example, based on the hidden state sequence, by performing a first attention interaction on the hidden states at different time steps, different weights are assigned to the hidden states at different time steps according to the self-attention mechanism:
[0109]
[0110] in, and For trainable parameters, This operation is used to ensure weight normalization.
[0111] For example, by weighting and summing the hidden states at each time step with different weights to fuse the hidden states, the learning state vector of the target learner can be generated, which can be expressed as:
[0112]
[0113] in, To learn the state vector, As weight, It is in a hidden state.
[0114] In this embodiment, the learning state vector generated through the above process can be used to characterize the current ability level features of the target learner. This vector serves as the input basis for the subsequently constructed test question generation model, enabling the model to dynamically generate personalized test questions for the target learner based on their knowledge mastery, ability weaknesses, and learning goals. This effectively improves the relevance and adaptability of the generated test questions. Furthermore, the introduction of a self-attention mechanism in the above process overcomes the limitation of existing technologies that cannot correlate with individual learning data, thus improving the relevance between the generated content and the learner's current needs.
[0115] In one embodiment, the learning target standard sequence includes multiple words; the learning target standard sequence is vectorized to obtain the learning target vector of the target learner, including: vectorizing multiple words in the learning target standard sequence to obtain the word vector sequence of the target learner; and generating the learning target vector of the target learner by performing a second attention interaction on multiple word vectors based on the word vector sequence.
[0116] For example, by using an embedding function, multiple words in the target standard sequence are encoded to obtain the word vector sequence of the target learner. The word vector sequence is as follows:
[0117]
[0118] in, This represents the pre-trained word vector mapping function, derived from the low-level embedding layer of the LLM. For the first Embedding vectors of words.
[0119] For example, a word vector matrix is constructed based on multiple word vector sequences. To extract key guiding words from the target description information, such as "exam point," "improvement," and "differential protection," different weights are assigned to multiple word vectors through a second attention interaction based on the word vector matrix.
[0120]
[0121] in, For word vector matrix, , For trainable parameters, A score is given for attention.
[0122] For example, by performing a weighted summation on the word vector sequence, the learning target vector for the target learner is obtained as follows:
[0123]
[0124] in, To learn the target vector, .
[0125] In this embodiment, the semantic embedding and attention extraction processes described above enable structured modeling of the current learning objective. This serves as the input basis for the subsequently constructed test question generation model, allowing the model to execute a more targeted and adaptive generation process based on the target learners' information. This lays the foundation for subsequent professional control and feedback loops, guiding the test question generation model to dynamically adjust its output strategy during the generation process and generate personalized content that better meets actual teaching needs.
[0126] In one embodiment, the steps for constructing the test item generation model include: acquiring structured question bank data and real feedback data from teaching scenarios, using the structured question bank data and real feedback data from teaching scenarios as sample data; using a portion of the sample data as fine-tuning sample data, and applying random perturbation to the remaining sample data to obtain perturbed sample data; acquiring the conditional language generation model to be trained, inputting the fine-tuned sample data and perturbed sample data into the conditional language generation model, and calculating the cross-entropy loss of the fine-tuned sample data and perturbed sample data through a loss function; and updating the parameters of the conditional language generation model based on the cross-entropy loss of the fine-tuned sample data and the perturbed sample data to obtain the test item generation model.
[0127] Structured question bank data refers to a tagged database of questions that can be read by the terminal. Real-world feedback data from teaching scenarios refers to non-pre-set, dynamic, and objective behavioral records generated by interactions between students, teachers, or learning platforms during real teaching processes (classroom, homework, exams, or online learning). Fine-tuning sample data is used for supervised fine-tuning of the conditional language generation model to be trained. Perturbation sample data consists of new samples similar to but not identical to the original samples, used to simulate imperfect inputs in the real world and enhance the robustness of the conditional language generation model to be trained. The conditional language generation model to be trained can be a conditional language generation model based on a Transformer decoder structure.
[0128] Optionally, based on the sample data, perturbed sample data can be generated by adding controllable random noise, transformations, occlusions, or semantically equivalent substitutions. For example, during the generation process, scenarios such as subtle changes in the target (e.g., switching from Chapter 5 to Chapter 6) or behavioral regressions (e.g., intentionally omitting some information from the state vector) can be simulated to train the model to maintain the stability of the conditional response.
[0129] For example, fine-tuned sample data and perturbation sample data are input into the conditional language generation model, and the cross-entropy loss of the fine-tuned sample data and perturbation sample data is calculated using a loss function; the sum of the cross-entropy losses of the fine-tuned sample data and perturbation sample data is calculated to obtain the total loss; based on the total loss, the parameters of the conditional language generation model can be updated through backpropagation or other methods to obtain the test item generation model.
[0130] In this embodiment, the conditional language model is fine-tuned using a large amount of structured question bank data and real-world feedback data from teaching scenarios during the model training phase. A target condition perturbation mechanism enhances the model's robustness, enabling the generated question generation model to accurately capture core needs even when faced with complex or ambiguous learning objective descriptions. This reduces generation bias caused by incomplete or ambiguous input information, ensuring the model's stability and generalization ability. Furthermore, continuous optimization using real-world teaching feedback data allows the model to adapt to diverse needs in actual teaching scenarios, such as differences in teaching focus across subjects and the cognitive characteristics of students at different grade levels. This results in high-quality questions that conform to subject standards and are closely aligned with actual teaching practices.
[0131] In one embodiment, a conditional control vector is input into a pre-built question generation model to generate initial question text. This includes: inputting the conditional control vector into the pre-built question generation model, and the question generation model performing the following operations: calculating the conditional probability distribution of multiple word units based on the conditional control vector; adjusting the conditional probability distribution using a professional vocabulary vector to obtain a target probability distribution, wherein the professional vocabulary vector is obtained by mapping a set of professional terms to the vocabulary space of the question generation model, and the set of professional terms includes professional terms in the teaching field of the learning objective; selecting target word units from the multiple word units based on the target probability distribution of the multiple word units, and generating initial question text based on the target word units.
[0132] Here, "word unit" refers to the word, sub-word, or symbol in the question generation model, i.e., "token." The professional vocabulary vector is a mask vector used to adjust the probability distribution of the softmax output at each step during the decoding phase of the question generation model.
[0133] For example, in generating the first When dealing with a single token, the model references previously generated sequences based on the conditional control vector. With condition vector Calculate the conditional probability distribution of the current token:
[0134]
[0135] in, The token to be generated at this time; For preceding context; This represents the current hidden state of the Transformer decoder, indicating the state up to the [number]th [number]. Context encoding of the step; It is a function used to fuse context state and control vector, and is usually implemented as a cross-attention module; and These are the output layer parameters, used to map the fused features to a vocabulary probability space.
[0136] Among them, the function This is used to dynamically reference individualized information at each step of the test question generation model's output, including question type control, knowledge point focus, language expression style control, and difficulty adaptation.
[0137] For example, to facilitate subsequent verification of the terminology validity, structural consistency, and knowledge point coverage of the generated content, the question generation model retains some intermediate layer structural information during the process of generating the initial question text, including: the hidden state of the decoder at each step. Conditional interaction weights That is, the attention matrix between the conditional vector and the decoding state; the token-level embedding mapping result.
[0138] Optionally, a terminology set can be extracted from standard textbooks, examination outlines, and authoritative technical documents, and a professional terminology set can be generated based on this terminology set. Combined with a question bank annotated by teachers, high-frequency expressions can be extracted, and synonyms can be automatically expanded using terminology clustering and topic modeling techniques (such as LDA). The professional terminology set can be maintained based on high-frequency expressions and synonyms.
[0139] For example, a set of technical terms is mapped to the vocabulary space of the test item generation model to generate a mask vector. ,in, The vocabulary size for the test item generation model. The specific adjustment method is as follows:
[0140]
[0141] in, For the target probability distribution, For conditional probability distribution, , indicating the first This token is prohibited in professional contexts. This is an element-wise multiplication operation used to ensure that invalid or erroneous terms are masked.
[0142] For example, in standard courses or exam scenarios, the conditional probability distribution can be adjusted directly by generating professional vocabulary vectors from a static vocabulary list, i.e., a set of professional terms. When different sub-vocabularies need to be enabled as needed (such as chapter-level control or knowledge domain switching), the professional vocabulary vectors generated by the set of professional terms will be dynamically adjusted in combination with the current input learning state vector. When unstructured content such as open-ended subjective questions needs to be generated, a probability suppression form with a penalty term will be used instead of a hard masking form of professional vocabulary vectors.
[0143] Optionally, when the target probability distribution of a word unit is greater than the preset probability distribution, the word unit is taken as the target word unit; multiple target word units are obtained, and an initial test text is composed based on the multiple target word units.
[0144] In this embodiment, a test question generation model with significant context adaptation capabilities and generation flexibility is used to accurately respond to the dual control of individual learning status and teaching objectives when facing fields with strong professionalism, large content span, or complex question structure (such as power secondary protection), and generate personalized test questions with clear teaching orientation.
[0145] In one embodiment, determining the target test text related to the target learner based on the verified initial test text includes: dividing the verified initial test text into text segments according to the standardized structure of the test questions to obtain the target test text related to the target learner.
[0146] The standardized structure of the test questions includes information such as the question stem, options, explanation, question type, difficulty level, related knowledge point number, and personalized tags.
[0147] For example, target test texts related to the target learners can be input into the learning platform. Specifically, this can be connected to an intelligent learning system for personalized training, a teacher-aided system for test paper generation or teaching resource preparation, and a learning management system (LMS) for assessment analysis and feedback management, etc.
[0148] Optionally, to optimize the generation strategy and adaptively adjust the learning path, the conditional state vector can be re-feeded and adjusted based on the subsequent answering behavior of the target learner.
[0149] In this embodiment, by segmenting the initial test question text that has passed the verification, target test question text related to the target students is obtained, thus realizing a unified structure output of the test question results.
[0150] In one of the most specific embodiments, such as Figure 3 As shown, the complete implementation steps of a test question generation method according to this application are as follows:
[0151] Step 1: Collect learning behavior data of the target learners on the learning platform, and calculate the learning state vector of the target learners through self-attention mechanism and feature modeling (BiLSTM encoding).
[0152] Step 2: Encode the target description information of the target learner's learning objectives to obtain the learning objective vector. Then, concatenate the learning objective vector with the learning state vector to obtain the condition control vector of the target learner.
[0153] Step 3: Use the Transformer structure decoder as the question generation model, input the conditional control vector into the question generation model, and the question generation model will generate the initial question text under the guidance of the conditional control vector.
[0154] In the language generation stage of the test question generation model, terminology control and structural consistency checks are introduced. Specifically, the professional knowledge vocabulary construction module, based on domain textbooks and teaching syllabi, generates a structured terminology set through methods such as terminology extraction, expert annotation, and semantic clustering. This set is then mapped to the lexical space of the language model to form a dynamic mask vector used to control the generation stage. Based on this, illegal word units (tokens) are masked and filtered by element-wise fusion of the mask vector with the output probability distribution of each step of the softmax algorithm.
[0155] Step 4: Perform terminology consistency check, symbol and formula consistency check, knowledge point association matching check, and language structure integrity check on the initial test text. If all checks pass, obtain the initial test text that has passed the checks. Divide the initial test text that has passed the checks into text segments according to the standardized structure of the test questions, and determine the target test text that is relevant to the target students.
[0156] Furthermore, based on named entity recognition and symbol consistency rules, multi-level terminology detection and structural analysis are performed. Combining decoder state information and conditional interaction weights extracted from the generative model, the system evaluates from multiple perspectives whether terms are used correctly, match contextual semantics, and are consistent with target knowledge points. Automatic correction or annotation prompts are used to improve text quality. After generating the initial test text, potential terminology misuse, symbol errors, and ambiguities are automatically identified. Based on the constructed teaching graph and tagging system, the generated text is mapped to a set of knowledge points, and the system assesses whether the question content is distributed within the target scope, whether core concepts are omitted, and whether there is overlap or confusion.
[0157] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.
[0158] Based on the same inventive concept, this application also provides a test question generation device for implementing the test question generation method described above. The solution provided by this device is similar to the solution described in the above method. Therefore, the specific limitations of one or more test question generation device embodiments provided below can be found in the limitations of the test question generation method above, and will not be repeated here.
[0159] In one exemplary embodiment, such as Figure 4 As shown, a test question generation device 400 is provided, including: a data acquisition module 402, an encoding module 404, a splicing module 406, a generation module 408, and a verification module 410, wherein:
[0160] The acquisition module 402 is used to collect learning behavior data of the target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0161] The encoding module 404 is used to obtain the target description information of the target learner's learning objectives, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learner.
[0162] The splicing module 406 is used to splice the learning state vector and the learning target vector to obtain the conditional control vector of the target learner.
[0163] The generation module 408 is used to input the conditional control vector into the pre-built question generation model to generate the initial question text.
[0164] The verification module 410 is used to perform professional knowledge verification on the initial test question text, and based on the verified initial test question text, to determine the target test question text related to the target students.
[0165] In one embodiment, the learning behavior data includes learning behavior sub-data at different timestamps. The acquisition module 402 is further configured to sort multiple learning behavior sub-data in the learning behavior data according to the timestamp order to generate a learning behavior time series of the target learner; perform temporal feature modeling on the learning behavior time series to obtain a hidden state sequence of the target learner. The hidden state sequence is used to characterize the evolutionary features of the target learner's learning behavior in the temporal sequence; based on the hidden state sequence, generate the learning state vector of the target learner by performing first attention interaction on the hidden states at different time steps.
[0166] In one embodiment, the learning target standard sequence includes multiple words, and the encoding module 404 is further used to vectorize and encode the multiple words in the learning target standard sequence to obtain the word vector sequence of the target learner; based on the word vector sequence, the learning target vector of the target learner is generated by performing a second attention interaction on the multiple word vectors.
[0167] In one embodiment, the generation module 408 is further configured to acquire structured question bank data and real feedback data from teaching scenarios, using the structured question bank data and real feedback data from teaching scenarios as sample data; using a portion of the sample data as fine-tuning sample data, applying random perturbation to the remaining sample data to obtain perturbed sample data; acquiring the conditional language generation model to be trained, inputting the fine-tuning sample data and perturbed sample data into the conditional language generation model, calculating the cross-entropy loss of the fine-tuning sample data and the perturbed sample data through a loss function; and updating the parameters of the conditional language generation model based on the cross-entropy loss of the fine-tuning sample data and the perturbed sample data to obtain the test question generation model.
[0168] In one embodiment, the generation module 408 is further configured to input the conditional control vector into a pre-built test question generation model, which performs the following operations: calculates the conditional probability distribution of multiple word units based on the conditional control vector; adjusts the conditional probability distribution using a professional vocabulary vector to obtain a target probability distribution, wherein the professional vocabulary vector is obtained by mapping a set of professional terms to the vocabulary space of the test question generation model, and the set of professional terms includes professional terms in the teaching field of the learning objectives; selects target word units from the multiple word units based on the target probability distribution of the multiple word units, and generates initial test question text based on the target word units.
[0169] In one embodiment, the verification module 410 is further configured to perform text segmentation on the verified initial test question text according to the standardized structure of the test questions, so as to obtain the target test question text related to the target learner.
[0170] Each module in the aforementioned test question generation device 400 can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0171] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 5 As shown, the computer device includes a processor, memory, input / output interface, communication interface, display unit, and input device. The processor, memory, and input / output interface are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interface. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interface is used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a test question generation method. The display unit is used to form a visually visible image and can be a display screen, projection device, or virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.
[0172] Those skilled in the art will understand that Figure 5 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.
[0173] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:
[0174] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0175] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0176] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target student.
[0177] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0178] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0179] In one embodiment, when the processor executes the computer program, it further performs the following steps: sorting multiple learning behavior sub-data in the learning behavior data according to the timestamp order to generate a learning behavior time series of the target learner; performing temporal feature modeling on the learning behavior time series to obtain a hidden state sequence of the target learner, the hidden state sequence being used to characterize the temporal evolution characteristics of the target learner's learning behavior; and generating a learning state vector of the target learner by performing a first attention interaction on the hidden states at different time steps based on the hidden state sequence.
[0180] In one embodiment, when the processor executes the computer program, it further performs the following steps: vectorizing and encoding multiple words in the standard sequence of learning targets to obtain a word vector sequence of the target learner; and generating a learning target vector of the target learner by performing a second attention interaction on multiple word vectors based on the word vector sequence.
[0181] In one embodiment, when the processor executes the computer program, it further performs the following steps: acquiring structured question bank data and real feedback data from teaching scenarios, and using the structured question bank data and real feedback data from teaching scenarios as sample data; using a portion of the sample data as fine-tuning sample data, and applying random perturbation to the remaining sample data to obtain perturbed sample data; acquiring the conditional language generation model to be trained, inputting the fine-tuning sample data and perturbed sample data into the conditional language generation model, and calculating the cross-entropy loss of the fine-tuning sample data and the perturbed sample data through a loss function; updating the parameters of the conditional language generation model based on the cross-entropy loss of the fine-tuning sample data and the perturbed sample data to obtain the test item generation model.
[0182] In one embodiment, when the processor executes the computer program, it further performs the following steps: inputting a conditional control vector into a pre-built test item generation model, the test item generation model performing the following operations: calculating the conditional probability distribution of multiple word units based on the conditional control vector; adjusting the conditional probability distribution using a professional vocabulary vector to obtain a target probability distribution, the professional vocabulary vector being obtained by mapping a set of professional terms to the vocabulary space of the test item generation model, the set of professional terms including professional terms in the teaching field of the learning objectives; selecting target word units from the multiple word units based on the target probability distribution of the multiple word units, and generating initial test item text based on the target word units.
[0183] In one embodiment, when the processor executes the computer program, it further performs the following steps: according to the standardized structure of the test questions, it performs text segmentation on the initial test question text that has passed the verification to obtain the target test question text related to the target learner.
[0184] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor:
[0185] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0186] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0187] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target learner.
[0188] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0189] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0190] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: sorting multiple learning behavior sub-data in the learning behavior data according to the timestamp order to generate a learning behavior time series of the target learner; performing temporal feature modeling on the learning behavior time series to obtain a hidden state sequence of the target learner, the hidden state sequence being used to characterize the temporal evolution characteristics of the target learner's learning behavior; and generating a learning state vector of the target learner by performing a first attention interaction on the hidden states at different time steps based on the hidden state sequence.
[0191] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: vectorizing and encoding multiple words in the standard sequence of learning targets to obtain a word vector sequence of the target learner; and generating a learning target vector of the target learner by performing a second attention interaction on multiple word vectors based on the word vector sequence.
[0192] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: acquiring structured question bank data and real feedback data from teaching scenarios, using the structured question bank data and real feedback data from teaching scenarios as sample data; using a portion of the sample data as fine-tuning sample data, applying random perturbation to the remaining sample data to obtain perturbed sample data; acquiring the conditional language generation model to be trained, inputting the fine-tuning sample data and perturbed sample data into the conditional language generation model, calculating the cross-entropy loss of the fine-tuning sample data and the perturbed sample data through a loss function; updating the parameters of the conditional language generation model based on the cross-entropy loss of the fine-tuning sample data and the perturbed sample data to obtain the test item generation model.
[0193] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: inputting a conditional control vector into a pre-built test item generation model, the test item generation model performing the following operations: calculating the conditional probability distribution of multiple word units based on the conditional control vector; adjusting the conditional probability distribution using a professional vocabulary vector, wherein the professional vocabulary vector is obtained by mapping a set of professional terms to the vocabulary space of the test item generation model, and the set of professional terms includes professional terms in the teaching field of the learning objectives; selecting target word units from the multiple word units based on the target probability distribution of the multiple word units, and generating initial test item text based on the target word units.
[0194] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: according to the standardized structure of the test questions, it performs text segmentation on the initial test question text that has passed the verification to obtain the target test question text related to the target learner.
[0195] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, performs the following steps:
[0196] Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners.
[0197] Obtain the target description information of the learning objectives of the target learners, perform semantic analysis on the target description information to obtain the standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learners.
[0198] The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target student.
[0199] Input the conditional control vector into the pre-built question generation model to generate the initial question text;
[0200] The initial test text is verified for professional knowledge. Based on the verified initial test text, target test texts relevant to the target learners are determined.
[0201] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: sorting multiple learning behavior sub-data in the learning behavior data according to the timestamp order to generate a learning behavior time series of the target learner; performing temporal feature modeling on the learning behavior time series to obtain a hidden state sequence of the target learner, the hidden state sequence being used to characterize the temporal evolution characteristics of the target learner's learning behavior; and generating a learning state vector of the target learner by performing a first attention interaction on the hidden states at different time steps based on the hidden state sequence.
[0202] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: vectorizing and encoding multiple words in the standard sequence of learning targets to obtain a word vector sequence of the target learner; and generating a learning target vector of the target learner by performing a second attention interaction on multiple word vectors based on the word vector sequence.
[0203] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: acquiring structured question bank data and real feedback data from teaching scenarios, using the structured question bank data and real feedback data from teaching scenarios as sample data; using a portion of the sample data as fine-tuning sample data, applying random perturbation to the remaining sample data to obtain perturbed sample data; acquiring the conditional language generation model to be trained, inputting the fine-tuning sample data and perturbed sample data into the conditional language generation model, calculating the cross-entropy loss of the fine-tuning sample data and the perturbed sample data through a loss function; updating the parameters of the conditional language generation model based on the cross-entropy loss of the fine-tuning sample data and the perturbed sample data to obtain the test item generation model.
[0204] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: inputting a conditional control vector into a pre-built test item generation model, the test item generation model performing the following operations: calculating the conditional probability distribution of multiple word units based on the conditional control vector; adjusting the conditional probability distribution using a professional vocabulary vector, wherein the professional vocabulary vector is obtained by mapping a set of professional terms to the vocabulary space of the test item generation model, and the set of professional terms includes professional terms in the teaching field of the learning objectives; selecting target word units from the multiple word units based on the target probability distribution of the multiple word units, and generating initial test item text based on the target word units.
[0205] In one embodiment, when the computer program is executed by the processor, it further performs the following steps: according to the standardized structure of the test questions, it performs text segmentation on the initial test question text that has passed the verification to obtain the target test question text related to the target learner.
[0206] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0207] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0208] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0209] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method for generating test questions, characterized in that, The method includes: Collect learning behavior data of target learners on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learners; Obtain the target description information of the learning objectives of the target learner, perform semantic analysis on the target description information to obtain a standard sequence of learning objectives, and vectorize and encode the standard sequence of learning objectives to obtain the learning objective vector of the target learner. The learning state vector and the learning target vector are concatenated to obtain the conditional control vector of the target student. The conditional control vector is input into a pre-built question generation model to generate initial question text. The initial test text is subjected to professional knowledge verification. Based on the verified initial test text, the target test text related to the target student is determined.
2. The method according to claim 1, characterized in that, The learning behavior data includes learning behavior sub-data at different timestamps. The feature fusion processing of the learning behavior data to obtain the learning state vector of the target learner includes: The learning behavior data is sorted according to timestamp order to generate the learning behavior time series of the target learner. The learning behavior time series is modeled with temporal features to obtain the hidden state sequence of the target learner. The hidden state sequence is used to characterize the temporal evolution of the learning behavior of the target learner. Based on the hidden state sequence, the learning state vector of the target learner is generated by performing a first attention interaction on the hidden states at different time steps.
3. The method according to claim 1, characterized in that, The learning objective standard sequence includes multiple words; the step of vectorizing the learning objective standard sequence to obtain the learning objective vector of the target learner includes: The word vector sequence of the target learner is obtained by vectorizing and encoding multiple words in the standard sequence of the learning target. Based on the word vector sequence, a learning target vector for the target learner is generated by performing a second attention interaction on multiple word vectors.
4. The method according to claim 1, characterized in that, The steps for constructing the test question generation model include: Obtain structured question bank data and real feedback data from teaching scenarios, and use the structured question bank data and the real feedback data from teaching scenarios as sample data; A portion of the sample data is used as fine-tuning sample data, and random perturbation is applied to the remaining sample data to obtain perturbed sample data; Obtain the conditional language generation model to be trained, input the fine-tuned sample data and the perturbation sample data into the conditional language generation model, and calculate the cross-entropy loss of the fine-tuned sample data and the perturbation sample data through the loss function; Based on the cross-entropy loss of the fine-tuned sample data and the perturbation sample data, the parameters of the conditional language generation model are updated to obtain the test item generation model.
5. The method according to claim 1, characterized in that, The step of inputting the conditional control vector into a pre-constructed question generation model to generate initial question text includes: The conditional control vector is input into a pre-built question generation model, which performs the following operations: Based on the conditional control vector, calculate the conditional probability distribution of multiple word units; The conditional probability distribution is adjusted using professional vocabulary vectors to obtain the target probability distribution. The professional vocabulary vectors are obtained by mapping a set of professional terms to the vocabulary space of the test question generation model. The set of professional terms includes professional terms in the teaching field of the learning objective. Based on the target probability distribution of multiple word units, target word units are selected from the multiple word units, and an initial test text is generated based on the target word units.
6. The method according to claim 1, characterized in that, The step of determining the target test text related to the target student based on the verified initial test text includes: According to the standardized structure of the test questions, the initial test question text that has passed the verification is divided into text segments to obtain the target test question text related to the target students.
7. A test question generation device, characterized in that, The device includes: The acquisition module is used to collect learning behavior data of the target learner on the learning platform, perform feature fusion processing on the learning behavior data, and obtain the learning state vector of the target learner. The encoding module is used to obtain the target description information of the learning objectives of the target learner, perform semantic analysis on the target description information to obtain a standard sequence of learning objectives, and perform vectorization encoding on the standard sequence of learning objectives to obtain the learning objective vector of the target learner. The concatenation module is used to concatenate the learning state vector and the learning target vector to obtain the conditional control vector of the target student. The generation module is used to input the conditional control vector into a pre-built question generation model to generate initial question text; The verification module is used to perform professional knowledge verification on the initial test question text, and based on the verified initial test question text, determine the target test question text related to the target student.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.