An online question-answering and grading method and an online question-answering system

By using counters and global sequence numbers to generate unique timestamps in the online question-answering system, and combining this with a language representation model to process subjective question answers, the system solves the performance problems in high-concurrency scenarios and the low scoring efficiency of subjective questions, thereby improving system performance and enhancing user interactivity.

CN119941468BActive Publication Date: 2025-11-14GUIZHOU WUJIANG HYDROPOWER DEV +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510397944.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-01
Publication Date
2025-11-14
Estimated Expiration
2045-04-01

AI Technical Summary

Technical Problem

Existing online real-time competition answering systems suffer from poor performance under high concurrency scenarios due to a large number of users answering questions simultaneously. They also cannot effectively handle subjective question answers, lack interactivity and fun, and fail to stimulate students' learning enthusiasm and competitive spirit.

Method used

Unique timestamps are generated using counters and global sequence numbers. Single-threaded load is reduced and competition issues are mitigated through thread polling and threshold control. Pre-trained language representation models are used to process subjective question answers. Combined with voice broadcasting and ranking update mechanisms, the system performance and scoring efficiency are improved.

Benefits of technology

Ensuring the uniqueness and order of timestamps in high-concurrency scenarios improves system performance, effectively handles both objective and subjective questions, enhances user interactivity and learning interest, and improves learning outcomes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119941468B_ABST
    Figure CN119941468B_ABST
Patent Text Reader

Abstract

This invention relates to an online question-answering and grading method and system, belonging to the field of data processing technology. The method includes: initializing settings for each node thread; responding to a received user's question-answering operation by performing a conditional judgment; if the counter count of the current node thread is less than a preset timestamp allocation count, generating a timestamp based on the current node thread, the current node thread's counter count, and a global sequence number, and incrementing the current node thread's counter by one; if the current node thread's counter count is greater than or equal to the preset timestamp allocation count, updating the node thread, incrementing the global sequence number by one, and generating a timestamp through the updated node thread. This method ensures the uniqueness and order of timestamps, thereby using the uniqueness and order of timestamps to determine the sequential processing order of grading operations, making it suitable for high-concurrency scenarios.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to an online question-answering and grading method and an online question-answering system. Background Technology

[0002] Traditional methods of knowledge and skills learning and assessment are relatively simplistic, relying primarily on paper-based exams or simple online tests. This model is mainly static assessment, with fixed content and mechanical processes, making it difficult to stimulate students' interest and initiative. Due to the lack of interactivity and engagement, students often passively receive knowledge during the learning process, making it difficult to form deep participation and long-term memory, resulting in limited learning outcomes. Furthermore, these methods fail to reflect students' learning levels in real time, making it impossible to provide targeted feedback and improvement suggestions to individuals.

[0003] With the rapid development of information technology, knowledge dissemination and assessment methods are gradually transforming towards intelligence and interactivity. Innovative learning and assessment methods based on real-time competition-style question-and-answer systems have emerged. These methods gamify the traditionally tedious learning process by introducing a competition mechanism, combining real-time interaction and ranking feedback to stimulate students' learning enthusiasm and competitive spirit. Students can not only consolidate their knowledge through answering questions but also experience a sense of participation and accomplishment in the competition, thereby significantly improving learning outcomes. This approach is more engaging and participatory, effectively meeting the diverse needs of modern education.

[0004] The research found that existing online real-time competition systems are primarily presented as online platforms. Users log in to the platform using a browser on their devices to answer questions. Each user's action requires a separate thread for processing. Current systems assign a timestamp to each user's action to verify the order of thread processing. However, in some scenarios, a large number of users simultaneously answer questions through the platform, such as company-organized business assessments, which may involve hundreds of employees answering the same test. Existing methods use mutexes in the critical section of the timestamp allocator, allowing numerous concurrent threads to access the critical section, leading to poor performance. Summary of the Invention

[0005] To address the aforementioned technical problems, this invention provides an online question-answering and grading method and an online question-answering system.

[0006] In a first aspect, embodiments of this application provide an online question-and-answer grading method, comprising: in response to the start of question-and-answer sessions, initialization settings are performed for each node thread; the initialization settings include initializing a counter corresponding to each node thread and initializing a global sequence number; in response to receiving a user's question-and-answer operation, a condition judgment is performed; if the count of the current node thread's counter is less than a preset timestamp allocation count, a timestamp is generated based on the current node thread, the count of the current node thread's counter, and the global sequence number, and the count of the current node thread's counter is incremented by one; if the count of the current node thread's counter is greater than or equal to the preset timestamp allocation count, the node thread is updated, the global sequence number is incremented by one, and a timestamp is generated through the updated node thread; the grading process is processed sequentially based on the timestamps of each thread.

[0007] Optionally, generating a timestamp based on the current node thread, the count of the current node thread's counter, and the global sequence number includes: calling the StringToInteger function and combining the current node thread, the count of the current node thread's counter, and the global sequence number to generate a timestamp; wherein, the StringToInteger function is used to concatenate the current node thread, the count of the current node thread's counter, and the global sequence number into a string in sequence, and convert it into an integer.

[0008] Optionally, updating the node thread includes: incrementing the current node thread by one; taking the modulo operation of the product of the incremented current node thread and the total number of node threads and the preset number of timestamp allocations to determine the updated node thread.

[0009] Optionally, generating a timestamp using the updated node thread includes: calling the StringToInteger function and combining the updated node thread, the number of times the updated node thread is counted, and the incremented global sequence number to generate a timestamp; wherein, the StringToInteger function is used to sequentially concatenate the timestamp generated by the updated node thread, the number of times the updated node thread is counted, and the incremented global sequence number into a string, and then convert it into an integer.

[0010] Optionally, the method further includes: in response to the question type being judged being a subjective question, receiving the subjective question answer submitted by the answering terminal; generating multiple levels of reference answers from the unique reference answer using a random masking method; wherein, the higher the masking ratio, the lower the corresponding level; inputting the subjective question answer submitted by the answering terminal and the multiple levels of reference answers into a pre-trained language representation model to determine the subjective question answer score of the answering terminal; wherein, the pre-trained language representation model is used to determine the matching probability between the subjective question answer submitted by the answering terminal and the reference answer of each level, and outputting the level of the reference answer with the highest matching probability; different levels correspond to different scores.

[0011] Optionally, the pre-trained language representation model is a pre-trained BERT model.

[0012] Optionally, the method further includes: in response to the question type being graded being a subjective question, receiving the subjective question answers submitted by the answering terminal; extracting key text from the unique reference answer; wherein the key text includes keywords or key phrases; for each keyword, determining synonyms for that keyword, and generating a word set corresponding to each keyword; extracting key text from the subjective question answers submitted by the answering terminal; performing similarity matching between the key text from the subjective question answers submitted by the answering terminal and the word set corresponding to each keyword; and determining the subjective question answer score of the answering terminal based on the matching results.

[0013] Optionally, the method further includes: after receiving answers from multiple answer terminals for the same question, displaying the answer result of each answer terminal and broadcasting it via voice.

[0014] Optionally, the method further includes: after every N rounds of answering questions, compiling the answering results of all answering terminals and updating the ranking once.

[0015] Secondly, embodiments of this application provide an online question-answering system, including:

[0016] A central control module is used to execute the online answering and grading method provided in the first aspect; multiple answering terminals are connected to the central control module respectively, and each answering terminal is used to upload answers to the central control module in response to user input.

[0017] The beneficial effects of this invention include:

[0018] First, upon receiving a response to the start of the question-answering process, initialization settings are performed for each node thread. These initialization settings include initializing the counter and global sequence number for each node thread. Then, upon receiving each user's answer, a conditional check is performed. If the count of the current node thread's counter is less than the preset timestamp allocation count, a timestamp is generated based on the current node thread, its counter count, and the global sequence number, and the current node thread's counter count is incremented. If the count of the current node thread's counter is greater than or equal to the preset timestamp allocation count, the node thread is updated, the global sequence number is incremented, and a timestamp is generated using the updated node thread. Finally, the judging process is processed sequentially based on the timestamps of each thread. First, this method reduces the load on a single thread and alleviates some contention issues through thread polling and threshold control (specifically through the set counter and global sequence number). Second, this method ensures the uniqueness and order of timestamps, thereby determining the sequential processing order of judging operations. This is suitable for high-concurrency scenarios (such as dozens of users answering questions simultaneously), eliminating the need for mutex locks in critical sections and improving overall performance. Attached Figure Description

[0019] Figure 1 This is a flowchart illustrating the steps of an online question-answering and grading method provided in an embodiment of the present invention.

[0020] Figure 2 This is a flowchart illustrating the steps of another online question-answering and grading method provided in an embodiment of the present invention;

[0021] Figure 3 This is a display effect diagram of an online question-answering method provided by an embodiment of the present invention;

[0022] Figure 4 This is a display effect diagram of another online question-answering method provided by an embodiment of the present invention;

[0023] Figure 5 This is a block diagram of an online question-answering system provided in an embodiment of the present invention;

[0024] Figure 6 This is a block diagram of another online question-answering system provided in an embodiment of the present invention;

[0025] Figure 7 This is a module block diagram of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0026] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application can also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.

[0027] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0028] Practical research revealed that existing online real-time competition systems primarily function as online platforms. Users log in via a browser on their devices to answer questions. Each user's action requires a separate thread for processing. Current systems assign a timestamp to each user's action to verify the processing order. However, in certain scenarios, a large number of users may simultaneously answer questions on the platform, such as company-organized performance reviews, where hundreds of employees may answer the same test. Existing methods use mutexes in the timestamp allocator's critical section, leading to a large number of concurrent threads accessing the critical section and consequently, poor performance.

[0029] In view of the above problems, this application proposes the following embodiments to solve the above technical problems.

[0030] Please see Figure 1 This application provides an online question-answering and grading method, including steps 101 to 104.

[0031] Step 101: In response to the start of the question-answering process, perform initialization settings for each node thread.

[0032] The initialization settings include initializing the counters for each node thread and initializing the global sequence number.

[0033] Specifically, initialize the counter corresponding to each node thread. and global serial number .

[0034] Step 102: In response to receiving a user's answer, perform a conditional judgment to determine whether the count of the current node thread's counter is less than the preset timestamp allocation count.

[0035] During the user's question-answering process, each answer requires a separate thread for processing. Since the central control module has a limited number of threads, timestamps are used to distinguish the processing order. Specifically, the conditional judgment is based on the number of times the current node's thread counter has been used. Is it less than the preset number of timestamps can be allocated? If the current node's thread counter counts... The number of times less than the preset timestamp allocation Then proceed to step 103. If the current node thread's counter count... Greater than or equal to (i.e., not less than) the preset number of timestamp allocations Then proceed to step 104.

[0036] It should be noted that the above-mentioned preset number of timestamp allocations... This indicates the maximum number of timestamps that a single thread can allocate.

[0037] Step 103: Generate a timestamp based on the current node thread, the count of the current node thread's counter, and the global sequence number, and increment the count of the current node thread's counter by one.

[0038] That is, if the current node thread's counter counts... The number of times less than the preset timestamp allocation Then, based on the current node thread and the number of times the current node thread's counter is used. The timestamp is generated together with the global sequence number. Meanwhile, the logic counter increments: .

[0039] Step 104: Update the node thread, increment the global sequence number once, and generate a timestamp using the updated node thread.

[0040] That is, if the counter of the current node thread is greater than or equal to the preset timestamp allocation count, the node thread needs to be updated, that is, another node thread is selected to execute the processing task. At this time, the global sequence number is incremented by one. Then, a timestamp is generated using the updated node thread.

[0041] It should be noted that the method for generating timestamps using the updated node thread is consistent with the aforementioned approach; that is, the timestamp is generated using the updated node thread, the count of the updated node thread's counter, and the global sequence number. The count of the updated node thread's counter is the initialized value. .

[0042] Step 105: Process the judging process sequentially based on the timestamps of each thread.

[0043] Finally, each thread can process the grading tasks sequentially according to the timestamp order.

[0044] In summary, the online question-answering and grading method provided in this application has the following beneficial effects:

[0045] First, upon receiving a response to the start of the question-answering process, initialization settings are performed for each node thread. These initialization settings include initializing the counter and global sequence number for each node thread. Then, upon receiving each user's answer, a conditional check is performed. If the count of the current node thread's counter is less than the preset timestamp allocation count, a timestamp is generated based on the current node thread, its counter count, and the global sequence number, and the current node thread's counter count is incremented. If the count of the current node thread's counter is greater than or equal to the preset timestamp allocation count, the node thread is updated, the global sequence number is incremented, and a timestamp is generated using the updated node thread. Finally, the judging process is processed sequentially based on the timestamps of each thread. First, this method reduces the load on a single thread and alleviates some contention issues through thread polling and threshold control (specifically through the set counter and global sequence number). Second, this method ensures the uniqueness and order of timestamps, thereby determining the sequential processing order of judging operations. This is suitable for high-concurrency scenarios (such as dozens of users answering questions simultaneously), eliminating the need for mutex locks in critical sections and improving overall performance.

[0046] Optionally, the above steps generate a timestamp based on the current node thread, the count of the current node thread's counter, and the global sequence number, including: calling the StringToInteger function and combining the current node thread, the count of the current node thread's counter, and the global sequence number to generate a timestamp; wherein, the StringToInteger function is used to concatenate the current node thread, the count of the current node thread's counter, and the global sequence number into a string, and convert it into an integer.

[0047] Specifically, calling the StringToInteger function to generate a timestamp can be represented as follows:

[0048] ;in, This represents the generated timestamp; StringToInteger represents the StringToInteger function. Represents the global serial number. This indicates the sequence number of the current node's thread. This represents the number of times the counter for the current node's thread has been used.

[0049] Specifically, the `StringToInteger` function takes a global sequence number, a node thread number, and a counter as input, and outputs an integer obtained by converting the concatenated characters to a unique timestamp. By concatenating the global sequence number, the node thread number, and the counter, a unique timestamp can be generated. Specifically, the global sequence number ensures uniqueness across threads, the node thread number ensures uniqueness within a thread, and the counter ensures uniqueness within a single allocation.

[0050] Optionally, the above steps for updating node threads include: incrementing the current node thread by one; taking the modulo operation of the product of the incremented current node thread and the total number of node threads and the preset number of timestamp allocations, to determine the updated node thread.

[0051] The above-mentioned update node thread can be referenced in the following formula:

[0052] ; where mod represents the modulo operation, This indicates the total number of node threads in the central control module. This indicates the preset number of times the timestamp will be allocated.

[0053] It should be noted that by using the modulo operation to implement the loop polling, it is possible to ensure that each thread is allocated a timestamp in order, thus maintaining fairness among the nodes and threads and avoiding resource waste.

[0054] Optionally, the above steps generate a timestamp using the updated node thread, including: calling the StringToInteger function and combining the updated node thread, the number of times the updated node thread is updated, and the incremented global sequence number to generate a timestamp; wherein, the StringToInteger function is used to concatenate the timestamp generated by the updated node thread, the number of times the updated node thread is updated, and the incremented global sequence number into a string, and then convert it into an integer.

[0055] It should be noted that the process and formula for generating timestamps using the updated node thread are the same as in the previous embodiments, and will not be repeated here. It can be understood that the updated node thread can be used as the current node thread in the future.

[0056] The above steps are described in full below. Specifically, the timestamp allocation mechanism provided in this application embodiment is as follows, including:

[0057] Step 1: For each node thread ,in, Initialize the counter and global serial number .

[0058] Step 2: If Then perform the following operation: Call the StringToInteger function to generate a timestamp: The logic counter increments automatically. .

[0059] Step 3: If Perform the following operations: Increment the global serial number: Update node sequence number: Fairness among node threads is maintained through modulo operations. The StringToInteger function is called to generate a timestamp. .

[0060] It should be noted that the explanation of the parameters in the above formula can be found in the description in the foregoing embodiments, and will not be repeated here.

[0061] Once the timestamps are allocated, the threads can process them sequentially according to the timestamp order.

[0062] Furthermore, the research found that the automatic grading function of existing online question-answering systems can usually only be used for objective questions and cannot quickly grade subjective questions. That is, subjective questions usually have diverse user answers, making it impossible to directly compare and derive the answer. Therefore, this application provides the following embodiments to solve this problem.

[0063] For the first option, please refer to [link / reference]. Figure 2 Optionally, the online competition answer grading method provided in this application further includes steps 201 to 203.

[0064] Step 201: In response to the fact that the question type for grading is subjective, receive the subjective question answers submitted by the answering terminal.

[0065] Step 202: Generate multiple levels of reference answers from the single reference answer using a random masking method.

[0066] The greater the proportion of coverage, the lower the corresponding grade.

[0067] For example, in the embodiments of this application, the occlusion can be classified as Level 1 for 50% occlusion, Level 2 for 40% occlusion, Level 3 for 30% occlusion, Level 4 for 20% occlusion, Level 5 for 10% occlusion, and Level 6 for 0% occlusion.

[0068] For example, the only correct answer is aaabbbcccd. Here, the characters abcd represent specific text content, so 20% obscuring corresponds to aa_bbb_cccd.

[0069] Step 203: Input the subjective question answers submitted by the answering terminal and the reference answers at multiple levels into the pre-trained language representation model to determine the subjective question answer scores of the answering terminal.

[0070] The pre-trained language representation model is used to determine the matching probability between the subjective question answers submitted by the answering terminal and the reference answers for each level, and outputs the level of the reference answer with the highest matching probability; different levels correspond to different scores.

[0071] In other words, the input to the pre-trained language representation model is the subjective answer submitted by the answering terminal and multiple levels of reference answers. The output of the pre-trained language representation model is the score of the subjective answer submitted by the answering terminal. Furthermore, the pre-trained language representation model is used to determine the matching probability between the subjective answer submitted by the answering terminal and the reference answer at each level, and outputs the level of the reference answer with the highest matching probability; different levels correspond to different scores. For example, level 1 corresponds to 1 point, level 2 corresponds to 2 points, level 3 corresponds to 3 points, and so on.

[0072] As a method for determining the matching probability between subjective question answers submitted by the answering terminal and reference answers at each level, the grading problem can be transformed into a text where the user's answer is the previous sentence and the reference answer is the next sentence. By predicting the probability of the reference answer being the next sentence at different levels, the matching probability can be determined. This method provides a reasonable way to grade subjective questions, characterized by low reasoning overhead and high real-time performance.

[0073] As another method to determine the matching probability between subjective question answers submitted by the answering terminal and the reference answers for each level, the matching probability can be determined by the similarity between the subjective question answers submitted by the answering terminal and the reference answers for each level. This method allows for a more convenient grading of subjective questions.

[0074] Optionally, the pre-trained language representation model is a pre-trained BERT model.

[0075] The mechanism of the BERT model can be summarized as follows:

[0076] In this formula, This represents the output of the pre-trained BERT model. This refers to the subjective question files submitted by the answering terminal. Indicates the level as The reference answer; and These represent two placeholders in a pre-trained BERT model; This indicates that the maximum value among multiple levels of reference answers is taken, which corresponds to the maximum matching probability.

[0077] Secondly, optionally, the online question-and-answer grading method provided in this application embodiment further includes: in response to the question type being graded being a subjective question, receiving the subjective question answers submitted by the answering terminal; extracting key text from the unique reference answer; wherein, the key text includes keywords or key phrases; for each keyword, determining synonyms of the keyword, and generating a word set corresponding to each keyword; extracting key text from the subjective question answers submitted by the answering terminal; performing similarity matching between the key text from the subjective question answers submitted by the answering terminal and the word set corresponding to each keyword; and determining the subjective question answer score of the answering terminal based on the matching results.

[0078] That is, this application embodiment also provides a method for grading subjective question answers. Its core is to extract key text from the reference answer, then generate a set of synonyms, then extract keyword text from the user's subjective question answers, and then perform similarity matching to determine the score of the subjective question answers of the answering terminal.

[0079] If there are 9 key texts matching the reference answer and 8 successful matches in the user's subjective question profile, then the score is: The maximum score is [value]. It should be noted that a successful match can be determined by a similarity greater than 80%. Of course, the above is merely an example; in other embodiments, the maximum score and similarity threshold can be set according to requirements, and are not limited here.

[0080] As can be seen, the embodiments of this application provide a subjective question grading mechanism based on synonym matching. This method can handle the diverse expressions of user answers, reduce the workload of manual grading, and improve grading efficiency.

[0081] Optionally, the online question-answering and grading method provided in this application embodiment further includes: after receiving answers from multiple answer terminals for the same question, displaying the answer result of each answer terminal and broadcasting it via voice.

[0082] Optionally, the online quiz grading method provided in this application embodiment further includes: after every N quizzes, compiling the quiz results of all quiz terminals and updating the ranking once.

[0083] The value of N can be set according to the requirements. For example, the value of N can be 8, 10, 20, etc., and there is no limitation here.

[0084] The following demonstrates the effect of the online question-answering and grading method provided in the embodiments of this application. Figure 3The image shows the quiz process across multiple terminals. It depicts a business competition hosted by Company A, with six terminals: terminal 1, terminal 2, terminal 3, terminal 4, terminal 5, and terminal 6. The image updates the current real-time leader and displays the remaining quiz time.

[0085] Figure 4 This displays the scores for this round of Company A's business competition. Every N rounds of question-and-answer sessions, the results from all terminals are compiled, and the rankings are updated. For example, the first place winner is terminal 5, which answered 8 questions correctly and scored 24 points. The sixth place winner is terminal 2, which answered 0 questions correctly and scored 0 points.

[0086] Please see Figure 5 Based on the same inventive concept, this application provides an online question-answering system, including: a central control module and multiple question-answering terminals.

[0087] The central control module is used to execute the online answer grading method provided in the above embodiments.

[0088] Multiple answer terminals are connected to the central control module. Each answer terminal is used to respond to user input and upload answers to the central control module.

[0089] Please see Figure 6 Optionally, the online quiz system may also include: a display module, a voice broadcast module, a data storage module, and a scoring module.

[0090] The display module, voice broadcast module, data storage module, and scoring module are all connected to the central control module.

[0091] The system includes the following modules: a display module for showing the questions, progress, and rankings of each answering terminal; this module can be a television or a projector. A voice broadcast module for providing voice announcements, such as the answering results, progress, rankings, and remaining time for each answering terminal; this module can be a speaker. A data storage module for storing the answering data from each answering terminal; and a scoring module for scoring.

[0092] Specifically, the central control module is responsible for scheduling tasks among the other modules in the system. For example, the central control module can connect to the answering terminal via a wireless network. The answering terminal can be any device with a browser, such as a mobile phone or laptop. After the user connects to the central control module through the answering terminal, the terminal obtains a unique ID for identification. The user can then select the exam paper to answer through the terminal. After selection, the central control module will connect to the data storage module and obtain the data required for the user-specified exam paper. The data module can be any storage device with database service capabilities, such as MySQL (Database Management System) or Oracle (Relational Database Management System). After the data is obtained, the central control module will parse the question portion of the data and dynamically generate HTML to be presented to the answering terminal. HTML (Hypertext Markup Language) includes the question display area, the answer area (including but not limited to text input boxes, list checkboxes, etc.), and the interactive operation area (including common exam system functions such as start exam, submit, and next page).

[0093] Please see Figure 7 Based on the same inventive concept, this application provides a module frame for an electronic device 700 that applies the above-described online question-answering and grading method. The electronic device 700 includes: at least one processor 701 ( Figure 7 (Only one is shown in the image), memory 702, computer program 703 stored in memory 702 and executable on at least one processor 701, processor 701 executing computer program 703 to implement the steps of the online answering and grading method in any of the foregoing embodiments.

[0094] The electronic device 700 can be a server, a personal computer, a laptop, etc.

[0095] Those skilled in the art will understand that Figure 7 This is merely an example of electronic device 700 and does not constitute a limitation on electronic device 700. It may include more or fewer components than shown, or combine certain components, or use different components.

[0096] The processor 701 may be a Central Processing Unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.

[0097] In some embodiments, the memory 702 may be an internal storage unit of the electronic device 700, such as a hard disk or memory of the electronic device 700. In other embodiments, the memory 702 may be an external storage device of the electronic device 700, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the electronic device 700. Furthermore, the memory 702 may include both internal storage units and external storage devices of the electronic device 700.

[0098] It should be noted that the above-mentioned systems, devices, etc. are based on the same concept as the method embodiments of this application. The modules designed in the system, as well as the steps performed by the device and the resulting technical effects, can all be found in the method embodiments section, and will not be repeated here.

[0099] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0100] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.

[0101] This application provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the above-described method embodiments.

[0102] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, 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 computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a photographic device / electronic device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks.

[0103] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0104] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0105] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0106] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0107] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.

Claims

1. An online question-and-answer grading method, characterized in that, include: In response to the start of the question-answering process, initialization settings are performed for each node thread; these initialization settings include initializing the counter corresponding to each node thread and initializing the global sequence number. In response to receiving a user's answer, a conditional judgment is performed. If the count of the current node thread's counter is less than the preset timestamp allocation count, a timestamp is generated based on the current node thread, the count of the current node thread's counter, and the global sequence number, and the count of the current node thread's counter is incremented by one. If the count of the current node thread's counter is greater than or equal to the preset timestamp allocation count, then the node thread is updated, the global sequence number is incremented by one, and a timestamp is generated through the updated node thread; The judging process is handled sequentially based on the timestamps of each thread.

2. The online question-and-answer grading method according to claim 1, characterized in that, The process of generating a timestamp based on the current node thread, the count of the current node thread's counter, and the global sequence number includes: Call the StringToInteger function and combine the current node thread, the number of times the current node thread's counter has been used, and the global sequence number to generate a timestamp; The StringToInteger function is used to concatenate the current node thread, the count of the current node thread's counter, and the global sequence number into a string, and then convert it into an integer.

3. The online question-and-answer grading method according to claim 1, characterized in that, The update node thread includes: Increment the current node's thread count by one; For the current node thread that increments by one, perform a modulo operation on the product of the total number of node threads and the preset number of times the timestamp is allocated, and determine the updated node thread.

4. The online question-and-answer grading method according to claim 3, characterized in that, The process of generating a timestamp through the updated node thread includes: Call the StringToInteger function and combine the updated node thread, the number of times the node thread was updated, and the auto-incremented global sequence number to generate a timestamp; The StringToInteger function is used to sequentially generate a timestamp from the updated node thread, the number of times the node thread was updated, and the auto-incremented global sequence number, concatenate them into a string, and then convert it into an integer.

5. The online question-answering and grading method according to claim 1, characterized in that, The method further includes: In response to the question type being graded being subjective, the system receives subjective question answers submitted by the answering terminal. The single reference answer is used to generate multiple levels of reference answers based on a random occlusion method; the higher the occlusion ratio, the lower the corresponding level. The subjective answers submitted by the answering terminal and the reference answers at multiple levels are input into a pre-trained language representation model to determine the subjective answer score of the answering terminal. The pre-trained language representation model is used to determine the matching probability between the subjective question answers submitted by the answering terminal and the reference answers for each level, and outputs the level of the reference answer with the highest matching probability; different levels correspond to different scores.

6. The online question-answering and grading method according to claim 5, characterized in that, The pre-trained language representation model is a pre-trained BERT model.

7. The online question-and-answer grading method according to claim 1, characterized in that, The method further includes: In response to the question type being graded being subjective, the system receives subjective question answers submitted by the answering terminal. Extract key text from the unique reference answer; wherein, the key text includes keywords or key phrases; For each keyword, identify synonyms for that keyword and generate a set of words corresponding to each keyword; Extract key text from the subjective question answers submitted by the answering terminal; The key text in the subjective question answers submitted by the answering terminal is matched with the word set corresponding to each keyword based on similarity. Based on the matching results, the scores of the subjective questions answered by the answering terminal are determined.

8. The online question-answering and grading method according to claim 1, characterized in that, The method further includes: After receiving answers to the same question from multiple answering terminals, the system displays the answer result from each terminal and provides a voice broadcast.

9. The online question-answering and grading method according to claim 8, characterized in that, The method further includes: After every N rounds of answering questions, the answering results from all answering terminals are compiled and the ranking is updated.

10. An online question-answering system, characterized in that, include: The central control module is used to execute the online answer grading method as described in any one of claims 1-9; Multiple answer terminals are connected to the central control module, and each answer terminal is used to upload answers to the central control module in response to user input.

Citation Information

Patent Citations

  • Knowledge competition method, system and device and storage medium

    CN110390068A

  • NLP-based test paper text automatic correction method and system

    CN115080690A