Teaching video link fine-grained intelligent disassembling method and system based on semantic-time sequence retrieval enhancement generation
By using a semantic-temporal retrieval-enhanced generation method, the problem of inaccurate segment boundary localization in teaching videos was solved, achieving fine-grained segmentation and temporal consistency of teaching videos, and improving the accuracy and stability of teaching video analysis.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-02-03
- Publication Date
- 2026-03-10
AI Technical Summary
Existing technologies struggle to reliably locate the boundaries of key elements in teaching videos in real classroom scenarios. Furthermore, the contextual redundancy and time dependencies resulting from long text transcription lead to false positives and false negatives in retrieval solutions, failing to meet the needs of large-scale course resource management and precise teaching analysis.
We adopt a semantic-temporal retrieval-enhanced generation method. By preprocessing teaching video data to extract semantic and temporal features, we generate dense vectors and build an index. We combine multi-tree knowledge forest retrieval and context window compression strategies to perform hybrid retrieval and generation. We use a parallel discriminant network for correction and finally achieve fine-grained segmentation of teaching segments.
It significantly improves the accuracy of positioning the boundaries of teaching video segments and the consistency of timing, suppresses model illusion, enhances the system's cross-scenario generalization ability and long-term stability, and provides an efficient and reliable video analysis solution for educational informatization platforms.
Smart Images

Figure CN121640352A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of educational informatization technology, and in particular relates to a method and system for fine-grained intelligent decomposition of teaching video segments based on semantic-temporal retrieval enhancement. Background Technology
[0002] With the popularization of online teaching and smart classrooms, the volume of classroom videos has grown rapidly, and teaching activities exhibit high heterogeneity across multiple disciplines, lesson types, and scenarios. Real classroom data often suffers from issues such as colloquial language, noise interference, and device differences, making it difficult for segmentation methods based on single semantic features or relying solely on visual cues to reliably pinpoint the boundaries of key stages such as "introduction—lecture—questioning—practice—summary / homework." Simultaneously, the contextual redundancy, cross-topic jumps, and time dependencies brought about by long text transcription make traditional segmentation strategies based on fixed windows or rule templates prone to false positives and false negatives, failing to meet the needs of large-scale course resource management and precise teaching analysis.
[0003] In recent years, deep learning has made significant progress in video understanding and multimodal retrieval. Video language models and retrieval augmentation generation (RAG) frameworks have been used for educational content parsing. However, existing solutions still face two bottlenecks in real classroom scenarios: First, they neglect the coupling of the semantic and temporal structures of teaching texts, and the retrieval side lacks joint modeling of teaching and temporal patterns, leading to inconsistencies in evidence selection and stage boundaries. Second, small models are prone to illusions and drift under long context conditions, and reordering and thresholding strategies are not sufficiently adaptive, while knowledge slicing granularity and context window compression lack unified constraints. Therefore, there is an urgent need for a retrieval augmentation generation method and system that balances semantic consistency and temporal alignment, enabling fine-grained segmentation and stable localization of teaching case videos without relying on ultra-large models. Summary of the Invention
[0004] This invention proposes a fine-grained intelligent decomposition method and system for teaching video segments based on semantic-temporal retrieval enhancement, in order to solve the problems existing in the prior art.
[0005] To achieve the above objectives, this invention provides a fine-grained intelligent decomposition method for teaching video segments based on semantic-temporal retrieval enhancement, comprising the following steps:
[0006] The teaching video data is preprocessed to obtain time-stamped text. Fine-grained segmentation is performed based on sentence boundaries and pauses to extract semantic and temporal features. Temporal features are enhanced by time position encoding to generate dense vectors and construct a vector database index.
[0007] Based on the semantic and temporal features, a structured teaching summary is generated, and multiple semantic queries are constructed based on the summary;
[0008] Based on the multiple semantic queries, a mixed search is performed on the three knowledge trees of teaching mode, time mode, and lesson type template to obtain search results;
[0009] The search results are reordered, and the optimal subset is selected using a context window compression strategy to form a reference suggestion block;
[0010] Based on the reference hint block, the retrieval enhancement generation is performed, and the teaching process sequence with timestamps is output. At the same time, a parallel discriminant network is used to correct the generated results.
[0011] The generated results are evaluated in three dimensions based on semantic similarity, temporal alignment, and structural matching. The retrieval threshold and knowledge tree weights are then dynamically adjusted based on the evaluation results.
[0012] Optionally, the step of enhancing the representation of temporal features using time position encoding includes:
[0013] Linear transformation of time series characteristics is performed using sine and cosine functions;
[0014] The transformed position vector is added to the semantic encoding vector to form an enhanced temporal feature representation.
[0015] Optionally, the step of constructing multiple semantic queries based on the summary includes:
[0016] Extract teaching mode queries, time mode queries, and lesson type template queries from structured teaching summaries;
[0017] Establish a three-level semantic routing mechanism that drives query generation and query execution.
[0018] Optionally, the step of performing hybrid retrieval on the three types of knowledge trees includes:
[0019] Construct a multi-tree knowledge forest consisting of a teaching model tree, a time model tree, and a lesson type template tree;
[0020] Dense vector retrieval and keyword filtering are performed simultaneously on each knowledge tree;
[0021] Search results are filtered based on dynamic search thresholds, and a comprehensive score is calculated for each search result.
[0022] Optionally, the step of calculating the overall score includes:
[0023] Calculate the semantic similarity between the query and the retrieval results;
[0024] The semantic similarity is weighted and fused by combining the context relevance weight;
[0025] The search results are reordered based on the overall score.
[0026] Optionally, the step of selecting the optimal subset using a context window compression strategy includes:
[0027] Assign importance weights to each search result;
[0028] Within the window capacity constraint, select the subset with the largest sum of the products of importance weight and semantic similarity;
[0029] Organize the selected subset into a reference hint block.
[0030] Optionally, the step of correcting the generated results using a parallel discriminant network includes:
[0031] Construct a discriminative subnetwork containing fully connected layers and activation functions;
[0032] The discriminant subnetwork is used to perform parallel discrimination of teaching segment categories and time boundary probabilities;
[0033] The discrimination result and the generated result are then checked for consistency.
[0034] Optionally, the step of evaluating the generated results based on three-dimensional evaluation metrics includes:
[0035] Calculate the semantic similarity, temporal alignment, and structural matching between the generated results and the standard answer, respectively.
[0036] The evaluation results from the three dimensions are combined into a comprehensive score according to their weights.
[0037] Optionally, the step of dynamically adjusting the retrieval threshold and knowledge tree weights includes:
[0038] Adjust the dynamic retrieval threshold according to the error distribution;
[0039] The weights of knowledge trees are adjusted based on their contribution to the retrieval process.
[0040] The adjusted parameters are then fed back to update the retrieval system.
[0041] The present invention also provides a system for implementing the method, comprising:
[0042] The preprocessing module is used to preprocess the teaching video data and generate enhanced temporal feature representations;
[0043] The summary and query construction module is used to generate structured summaries and establish a three-level semantic routing mechanism;
[0044] The multi-tree knowledge forest retrieval module is used to perform hybrid retrieval on three types of knowledge trees;
[0045] The reordering and compression module is used to reorder search results and compress the context window;
[0046] The generation and discrimination module is used to perform retrieval enhancement generation and parallel discrimination correction;
[0047] The evaluation and adaptation module is used for 3D evaluation and dynamic parameter adjustment.
[0048] Compared with the prior art, the present invention has the following advantages and technical effects:
[0049] This invention effectively solves the problem of insufficient coupling between semantic and temporal features in the segmentation of teaching videos by using semantic-temporal joint modeling and a multi-tree knowledge forest retrieval mechanism, significantly improving the accuracy of segment boundary localization and temporal consistency. It employs a strategy combining context window compression and retrieval-enhanced generation to achieve stable processing of long-duration videos with limited resources. Through the collaborative work of parallel discriminative networks and generative models, it effectively suppresses model illusions and improves the segmentation accuracy of small models in real classrooms. The established three-dimensional evaluation and adaptive mechanism enhances the system's cross-scenario generalization ability and long-term stability, providing an efficient and reliable video analysis solution for educational informatization platforms. Attached Figure Description
[0050] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:
[0051] Figure 1 This is a flowchart of a method according to an embodiment of the present invention;
[0052] Figure 2 This is a schematic diagram of the system structure according to an embodiment of the present invention;
[0053] Figure 3 This is a schematic diagram of the preprocessing flow according to an embodiment of the present invention;
[0054] Figure 4 This is a schematic diagram of encoding attention and retrieval emphasis in an embodiment of the present invention;
[0055] Figure 5 This is a schematic diagram of the decoding and discrimination output of an embodiment of the present invention;
[0056] Figure 6 This is a schematic diagram of the evaluation and adaptive module structure in an embodiment of the present invention. Detailed Implementation
[0057] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0058] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0059] Example 1
[0060] like Figure 1 As shown, this embodiment provides a method for fine-grained intelligent decomposition of teaching video segments based on semantic-temporal retrieval enhancement, including the following steps:
[0061] The teaching video data is preprocessed to obtain time-stamped text. Fine-grained segmentation is performed based on sentence boundaries and pauses to extract semantic and temporal features. Temporal features are enhanced by time position encoding to generate dense vectors and construct a vector database index.
[0062] Based on the semantic and temporal features, a structured teaching summary is generated, and multiple semantic queries are constructed based on the summary;
[0063] Based on the multiple semantic queries, a mixed search is performed on the three knowledge trees of teaching mode, time mode, and lesson type template to obtain search results;
[0064] The search results are reordered, and the optimal subset is selected using a context window compression strategy to form a reference suggestion block;
[0065] Based on the reference hint block, the retrieval enhancement generation is performed, and the teaching process sequence with timestamps is output. At the same time, a parallel discriminant network is used to correct the generated results.
[0066] The generated results are evaluated in three dimensions based on semantic similarity, temporal alignment, and structural matching. The retrieval threshold and knowledge tree weights are then dynamically adjusted based on the evaluation results.
[0067] Specifically, it can be divided into the following steps:
[0068] S1. Preprocessing and vectorization of teaching video data: Extract audio from teaching case videos and perform automatic speech recognition (ASR) transcription to obtain timestamped text; perform fine-grained segmentation based on sentence boundaries and pauses; perform denoising and deduplication operations; extract teaching keywords, semantic features and temporal features; use the BGE-M3 model to generate dense vectors and write them into the vector database index to control the granularity of knowledge slices and construct a semantic-temporal retrieval index structure.
[0069] S2. Structured Summary Generation and Semantic Query Construction: Using a small-parameter language model (Qwen2.5-7B-Instruct, Qwen3-4B, or GLM-4-9B-0414), structured teaching thought summaries are generated, and three types of retrieval queries are extracted from the summaries: teaching model queries. Time pattern query Course type template search .
[0070] S3, Multi-tree Knowledge Forest Semantic Routing and Hybrid Retrieval, Constructing Teaching Pattern Trees Time pattern tree With Lesson Template Tree These correspond to the three types of queries mentioned above; a hybrid retrieval method combining dense vector retrieval and keyword Boolean filtering is performed on each tree; and dynamic retrieval threshold control and reordering mechanisms are used to suppress... Irrelevant matching yields a Top-K candidate set of teaching patterns. Specifically, for each teaching segment, a vector q is queried within the knowledge tree node vector set. The above performs intensive retrieval, and the similarity calculation formula is as follows:
[0071] ;
[0072] in This represents the cosine similarity.
[0073] when (Dynamic retrieval threshold) Node It was determined to be a semantic match;
[0074] By rearranging functions:
[0075] ;
[0076] in For context-related weights, This is an adjustable balancing parameter used to dynamically optimize Top-K search results.
[0077] S4. Context Window Compression and Retrieval Enhancement Generation: Redundancy removal, sorting, and window compression are performed on multi-source retrieval results, retaining key information blocks. Reference suggestion blocks are formed based on knowledge slices and injected into the generation context to achieve retrieval enhancement generation (RAG). Simultaneously, the context window size is constrained to ensure temporal consistency. Let the retrieval result set be... Its corresponding importance weight is .
[0078] The system selects the optimal subset within the window based on the following scoring function:
[0079] ;
[0080] Where L is the context window capacity limit, This indicates the semantic similarity between the fragment and the query. This optimization process enables "context window compression," preserving the knowledge fragments that contribute most to the generation.
[0081] S5. Controlled generation and structured output: Based on the input text Q and compressed evidence E*, controlled decoding is performed to generate a sequence of teaching segments; the output includes stage names, timestamp boundaries and descriptions of teaching actions; a query rewriting and reordering mechanism is used to achieve illusion suppression and temporal consistency constraints.
[0082] S6. Online evaluation and adaptive optimization: The system evaluates the generated results based on three-dimensional indicators: semantic similarity, time alignment, and structural matching; it dynamically adjusts the retrieval threshold and knowledge tree weights according to the error distribution to achieve incremental optimization and adaptive system updates.
[0083] Furthermore, preprocessing of the teaching video data includes:
[0084] Sentence boundary / pause detection and noise filtering are used to perform fine-grained segmentation of the teaching transcription text while preserving temporal information;
[0085] Dense vector representations are generated for the segmented teaching segments, and a vector database index is established to support subsequent retrieval and rearrangement.
[0086] Semantic labels are encoded in the order of "introduction, lecture, question, practice, summary / homework". Duplicate and conflicting samples are cleaned, and temporal and semantic features are extracted from the teaching text.
[0087] Furthermore, the step of enhancing the representation of temporal features using time-position encoding includes:
[0088] Linear transformation of time series characteristics is performed using sine and cosine functions;
[0089] The transformed position vector is added to the semantic encoding vector to form an enhanced temporal feature representation.
[0090] Methods for linear transformations using sine and cosine functions include:
[0091] ;
[0092] Here, sin and cos represent the dimensions of a set of odd and even indices, respectively; pos represents the temporal position of the segment in the sequence. d_model represents the encoding dimension, set to 64; the output period of the position embedding function is designed to be... arrive Within a certain range, different locations can obtain distinctive location codes in each dimension to enhance temporal separability.
[0093] Specifically, the temporal and semantic features are input into the encoding layer to expand the dimension, and the discrete teaching tags and keywords are converted into continuous vector representations to obtain the encoding vector;
[0094] The temporal features are input into the time position embedding encoding layer, and linear transformation using sine and cosine functions is used to provide position information to obtain a position vector.
[0095] The encoded vector is added to the position vector and used as the encoder input; wherein the encoder consists of 6 identical sub-layers, each sub-layer including a multi-head attention layer and a feedforward neural network layer, and is connected by residual connections and normalization.
[0096] After encoding, the data is connected to a Softmax sublayer to output evidence-related location weight information. Based on this weight information, and combined with the retrieved evidence fragments, controlled generation is performed at the decoding end, or a DNN subnetwork is used to jointly determine segment classes and boundaries of high-dimensional features.
[0097] The DNN subnetwork contains two hidden layers, each containing a fully connected layer, a ReLU activation function, and a Dropout function, used to perform parallel discrimination of segment class labels and boundary probabilities outside of controlled generation.
[0098] Furthermore, the step of constructing multiple semantic queries based on the summary includes:
[0099] Extract teaching mode queries, time mode queries, and lesson type template queries from structured teaching summaries;
[0100] Establish a three-level semantic routing mechanism that drives query generation and query execution.
[0101] Specifically, firstly, the encoded vector of the input sequence is linearly mapped to a high-dimensional space to obtain three matrices: query, key, and value. The similarity between each query vector and all key vectors is calculated and normalized to obtain an attention score. The attention score is multiplied by the value matrix to obtain the attention weight. The attention weight is then calculated through multiple different heads to obtain multiple weighted sum vectors, which are then concatenated. Finally, the result is linearly mapped back to a low-dimensional space to obtain the output of the multi-head self-attention layer, which is used to guide the selection of retrieval evidence and context fusion.
[0102] Furthermore, the step of performing hybrid retrieval on the three types of knowledge trees includes:
[0103] Construct a multi-tree knowledge forest consisting of a teaching model tree, a time model tree, and a lesson type template tree;
[0104] Dense vector retrieval and keyword filtering are performed simultaneously on each knowledge tree;
[0105] Search results are filtered based on dynamic search thresholds, and a comprehensive score is calculated for each search result.
[0106] Furthermore, the step of calculating the overall score includes:
[0107] Calculate the semantic similarity between the query and the retrieval results;
[0108] The semantic similarity is weighted and fused by combining the context relevance weight;
[0109] The search results are reordered based on the overall score.
[0110] Furthermore, the step of selecting the optimal subset using the context window compression strategy includes:
[0111] Assign importance weights to each search result;
[0112] Within the window capacity constraint, select the subset with the largest sum of the products of importance weight and semantic similarity;
[0113] Organize the selected subset into a reference hint block.
[0114] Furthermore, the step of correcting the generated results using a parallel discriminant network includes:
[0115] Construct a discriminative subnetwork containing fully connected layers and activation functions;
[0116] The discriminant subnetwork is used to perform parallel discrimination of teaching segment categories and time boundary probabilities;
[0117] The discrimination result and the generated result are then checked for consistency.
[0118] Furthermore, the step of evaluating the generated results based on three-dimensional evaluation metrics includes:
[0119] Calculate the semantic similarity, temporal alignment, and structural matching between the generated results and the standard answer;
[0120] The evaluation results from the three dimensions are combined into a comprehensive score according to their weights.
[0121] Furthermore, the step of dynamically adjusting the retrieval threshold and knowledge tree weights includes:
[0122] Adjust the dynamic retrieval threshold according to the error distribution;
[0123] The weights of knowledge trees are adjusted based on their contribution to the retrieval process.
[0124] The adjusted parameters are then fed back to update the retrieval system.
[0125] This implementation also included ablation experiments, which involved using the “retrieval enhancement generation + encoder-decoder” method as a baseline, conducting experiments on multi-course datasets with decoder-only generation, retrieval-only discrimination, and the complete ViSeg model, and comparing the removal of components such as dynamic retrieval thresholding, reordering, context window compression, and query rewriting. Finally, the best-performing model through multiple rounds of testing was encapsulated to construct a teaching video segmentation system.
[0126] Example 2
[0127] This embodiment discloses a fine-grained intelligent decomposition method for teaching video segments based on semantic-temporal retrieval enhancement, such as... Figure 1 As shown, it includes:
[0128] S1. Perform data preprocessing on the teaching videos, extract temporal and semantic features from the transcribed text, perform noise and deduplication, fine segmentation of sentence boundaries / pauses, and use BGE-M3 to generate dense vectors, establish a vector database index, and set configurable knowledge slice granularity for subsequent retrieval.
[0129] S2. Input the semantic and temporal features obtained in S1 into the retrieval enhancement generation framework: First, the small model (Qwen2.5-7B-Instruct / Qwen3-4B / GLM-4-9B-0414) generates a summary of "teaching ideas", automatically constructs three types of queries: teaching mode, time mode and lesson type template, and performs hybrid retrieval on the three knowledge trees;
[0130] S3. The candidate evidence set obtained in S2 is filtered and rearranged according to the dynamic retrieval threshold, and reference hint blocks are selected using the context window compression (CWC) strategy. These blocks are then injected into the controlled decoder, and the overall error of the model on the development set is calculated. The hints and weights are then fine-tuned.
[0131] S4. The intelligent decomposition method adjusted in S3 was used for zero-sample inference (≤8192 tokens) on 371 real classroom video benchmarks, and compared and evaluated with large models without retrieval (GPT-4o-0513, DeepSeek-V3, Gemini-1.5-Pro) and structured retrieval baselines (Flat-RAG / ThinkRAG / BlendedRAG) to further refine the retrieval threshold and tree weights.
[0132] S5. Based on the multi-round evaluation results of S4, select the model configuration with the best comprehensive score from the three small models Qwen2.5-7B-Instruct, Qwen3-4B, and GLM-4-9B-0414, and save the best model together with the search index and prompt template.
[0133] S6. To verify the necessity and effectiveness of the key design, an ablation experiment was conducted: the time pattern tree T, the teaching pattern tree M, the lesson template tree Tp, and any combination thereof were removed, and the impact on indicators such as semantic similarity, time alignment, and structural matching was evaluated. Finally, the intelligent decomposition small model scheme that performed best after multiple rounds of testing was encapsulated to form a stable and highly generalizable teaching video segmentation system.
[0134] In the embodiments of this application, the preprocessing stage is performed according to... Figure 3 The illustrated process completes audio extraction, ASR transcription, and fine-grained segmentation, and generates dense vectors using BGE-M3 to construct a vector database index, ensuring the efficiency and accuracy of subsequent dense vector retrieval and hybrid retrieval. Compared to methods relying solely on fixed windows or pure prompts, this scheme significantly improves temporal alignment and semantic consistency through a chain structure of small model summarization—multi-tree retrieval—context compression—controlled generation. Given that segment identification is essentially a structured sequence determination task, this embodiment simultaneously sets up a parallel discriminant subnet (two fully connected layers + ReLU + Dropout) at the decoding end to perform consistency correction with the generated results (see...). Figure 5 To evaluate the model's generalization ability on long, real-world classroom texts, all 371 videos were inferred under zero-shot conditions, with a context window not exceeding 8192 tokens. Experiments show that ViSeg enables small models to reach or exceed the performance of large models without retrieval on multidimensional metrics.
[0135] See Figure 4 ViSeg's retrieval and encoding module includes three core computations, which are given by equations (1)-(3):
[0136] Firstly, dense vector retrieval uses cosine similarity:
[0137]
[0138] And through dynamic retrieval thresholds Adaptive selection of hit samples Secondly, the reordered scores fuse similarity and contextual relevance:
[0139]
[0140] Third, top-K ordered evidence is obtained; and fourth, context window compression selects the optimal subset under capacity (L) constraints.
[0141]
[0142] The reference cue block is formed as the input decoder. The encoder still adopts the standard position embedding and multi-head attention structure. The relevant equations (4)-(5) refer to the Transformer definition mentioned above in the specification, and will not be repeated here.
[0143]
[0144]
[0145] See Figure 5 The decoding / discrimination output module first receives Retrieval Enhancement Generation (RAG) is performed, and robustness is further improved with "illusion suppression" and "query rewriting"; the parallel segment class and boundary discrimination heads achieve joint correction with the generation results by minimizing the cross-entropy (CE / BCE) objective. The comprehensive evaluation score adopts multidimensional linear weighting (Equation (6)), among which semantic similarity has the highest weight:
[0146]
[0147] Furthermore, this embodiment defines the exact match rate (EMR) and structural consistency gap (SCG) to measure the rationality of the boundary and sequence structure. and These represent the segment number deviation, duration feasibility penalty, and stage sequence violation rate, respectively. (For normalized weights).
[0148] Experimental Results: On 371 annotated classroom videos, ViSeg-Qwen2.5-7B achieved an EMR of 31.8, semantic similarity of 0.635, structural matching of 0.745, and a comprehensive score of 0.622. ViSeg-Qwen3-4B had the highest semantic similarity at 0.687 and a comprehensive score of 0.630. ViSeg-GLM-4-9B achieved a comprehensive score of 0.576. Compared with large models without retrieval, GPT-4o-0513 (Prompt-only) achieved a comprehensive score of 0.610, DeepSeek-V3 0.585, and Gemini-1.5-Pro 0.561. This demonstrates that under conditions of no fine-tuning and limited context, the ViSeg-driven small models match and surpass large models in most metrics. Compared to the structured retrieval baseline, ViSeg achieved a comprehensive score increase of 0.038 (0.622 vs 0.584) and an EMR increase of 11.3 (31.8 vs 20.5) on Qwen2.5-7B, with significant improvements in both semantic and structural metrics. On Qwen3-4B, ViSeg achieved a comprehensive score increase of 0.172 (0.630 vs 0.458) compared to Flat-Retrieval, validating the advantages of multi-tree semantic-temporal retrieval over flat retrieval.
[0149] Ablation test ( Figure 6 Closed loop and Figure 5 Parallel discrimination and combination): Remove the three trees one by one by combination:
[0150] On Qwen2.5-7B, the optimal overall score for "Full(T+M+Tp)" is 0.622; removing Tp reduces the overall score to 0.555; retaining only M or T yields overall scores of 0.609 and 0.604, respectively.
[0151] On Qwen3-4B, the overall score for "Full" is 0.630, with only M scoring 0.603, only T scoring 0.539, and only Tp scoring 0.420. Removing Tp has the most significant impact on structural matching.
[0152] On GLM-4-9B, the overall score for "Full" is 0.576, with only M at 0.535 and T at 0.468, indicating that the smaller model is more sensitive to the three-tree collaboration.
[0153] These results are consistent with the selection-reordering mechanism of equations (2)–(3): removing any semantic route will reduce This could weaken the optimal subset of S*, leading to a decrease in EMR and structural consistency.
[0154] In summary, this invention, through a full-link design of "three-tree query → dynamic threshold and rearrangement → window compression → controlled RAG generation → parallel discrimination → online evaluation backflow", stably achieves fine-grained segmentation and temporal boundary localization of long-duration teaching videos without relying on ultra-large models and training data expansion. It also demonstrates high semantic consistency, strong structural rationality and excellent generalization on public benchmarks.
[0155] Example 3
[0156] like Figure 2 As shown, this embodiment provides a fine-grained intelligent decomposition system for teaching video segments based on semantic-temporal retrieval enhancement, including: a preprocessing module, used to preprocess teaching video data and generate enhanced temporal feature representations;
[0157] The summary and query construction module is used to generate structured summaries and establish a three-level semantic routing mechanism;
[0158] The multi-tree knowledge forest retrieval module is used to perform hybrid retrieval on three types of knowledge trees;
[0159] Context window compression and controlled generation module (including rearrangement and compression module and generation and discrimination module);
[0160] The reordering and compression module is used to reorder search results and compress the context window;
[0161] The generation and discrimination module is used to perform retrieval enhancement generation and parallel discrimination correction;
[0162] The evaluation and adaptation module is used for 3D evaluation and dynamic parameter adjustment.
[0163] The detection and encapsulation module is used to compare different model configurations and conduct ablation experiments.
[0164] The preprocessing module extracts audio from teaching videos and performs ASR transcription, combining sentence boundaries / pauses to achieve fine-grained segmentation and noise and deduplication, extracting keywords and time features, and using BGE-M3 to generate dense vectors to establish a vector database index to control the granularity of knowledge slices. The summary and query construction module uses small models (Qwen2.5-7B-Instruct, Qwen3-4B, GLM-4-9B-0414) to generate "teaching ideas" summaries and automatically constructs three types of queries: teaching mode, time mode, and lesson type template. The multi-tree knowledge forest retrieval module uses the teaching mode tree... Time pattern tree With Lesson Template Tree The system employs a hybrid strategy of dense vector retrieval and keyword filtering, along with dynamic retrieval thresholds and rearrangement to suppress noise. The context window compression and controlled generation module performs redundancy removal and window compression (CWC) on candidate evidence, forming reference hint blocks that are injected into the decoding end to complete retrieval augmentation generation (RAG) and output the link sequence and time boundaries. It also includes illusion suppression and query rewriting mechanisms. The evaluation and adaptation module generates a comprehensive score based on three dimensions: semantic similarity, time alignment, and structural matching, and performs backflow updates on the retrieval threshold, knowledge tree weights, and vector indexes. The detection and encapsulation module compares and ablation experiments with different model configurations, selecting the ViSeg small model scheme with the best overall performance for encapsulation and deployment.
[0165] This embodiment discloses a retrieval enhancement generation system for teaching scenarios, decomposing the system into two main parts: data preprocessing and semantic-temporal retrieval generation. Unlike methods relying solely on fixed windows or pure prompts, this system employs a chain design of small model summarization → multi-tree retrieval → window compression → controlled generation → parallel discrimination → online evaluation feedback. Even under limited context and zero-sample conditions, it can stably output fine-grained stages and accurate temporal boundaries. Specifically, multi-tree routing explicitly encodes prior teaching structures, dynamic thresholding and rearrangement improve evidence relevance, window compression ensures generation quality under long texts, and illusion suppression and query rewriting enhance robustness. The system as a whole is lightweight, deployable, and capable of online adaptation, making it suitable for operation on educational platforms or classroom terminals. ViSeg achieves comparable or better performance than large-model solutions without retrieval in core metrics such as semantic consistency, temporal alignment, and structural matching, meeting the real-time needs of classroom data governance and teaching research analysis.
[0166] This invention is applicable to fine-grained segmentation and temporal boundary localization of long-duration teaching case videos in real classroom scenarios, serving course resource governance and teaching process analysis. Unlike methods that rely solely on visual or fixed-window segmentation, this invention jointly models along two paths: semantic and temporal. On the one hand, it addresses the hierarchical semantic structure of the teaching text; on the other hand, it characterizes the temporal dependencies across sentences, thereby improving robustness across multiple stages such as "introduction—lecture—questioning—exercise—summary / homework." Addressing the problems of traditional solutions neglecting semantic-temporal coupling, relying on manual pre-segmentation, or experiencing illusions and drifts due to large contextual inputs, this invention proposes a structured intelligent decomposition framework. Through retrieval-enhanced generation and knowledge forest routing, it achieves stable inference of small models on long texts.
[0167] In practice, given a timestamped transcription sequence The objective of this invention is to predict the corresponding stage sequence. ,in Tags are used for teaching segments. To alleviate the constraints of long contexts, semantic summarization is first performed on the transcription. Then, extract three types of queries from the summary. Connect to the teaching model tree respectively Time pattern tree With Lesson Template Tree In the structured retrieval phase, dense vector retrieval and keyword Boolean filtering are performed on the corresponding knowledge tree for each query, and the structure-aware retrieval function is denoted as follows. The evidence set is then Subsequently, a dynamic retrieval threshold is applied and rearrangement is performed to suppress low-relevance noise and improve matching accuracy. To meet the context window constraint of the small model, the retrieved evidence is prioritized and compressed into a window, forming a structured reference cue block that is injected into the decoding end. Finally, the time-stamped sequence of links and boundaries are output. In implementation, the embedding side uses BGE-M3 to generate dense vectors and establish a vector database index; the generation side uses a small parameter model (such as Qwen2.5-7B-Instruct, Qwen3-4B, GLM-4-9B-0414) to complete structured generation and boundary determination under zero-sample inference conditions without fine-tuning; the evaluation side uses a three-dimensional index system of semantic similarity, time alignment, and structure matching to measure and adaptively update the results online. The above process can be implemented and run on 371 labeled teaching videos of more than 45 minutes each, and maintains stable performance under the context constraint of no more than 8192 tokens.
[0168] The above are merely preferred embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for fine-grained intelligent disassembly of enhanced generated teaching video segments based on semantic-temporal retrieval, characterized in that, The method comprises the following steps: Preprocessing the teaching video data, obtaining timestamped text, fine-grained segmentation based on sentence boundaries and pauses, extracting semantic features and timing features, and enhancing the representation of timing features using time position encoding to generate dense vectors and build vector database index; Based on the semantic features and timing features, generate a structured teaching summary, and construct multiple semantic queries according to the summary; According to the multiple semantic queries, perform mixed retrieval on three types of knowledge trees: teaching mode, time mode and course type template, and obtain retrieval results; Re-ranking the retrieval results and selecting the optimal subset using the context window compression strategy to form the reference prompt block; Based on the reference prompt block, perform retrieval enhancement generation, output the timestamped teaching segment sequence, and use a parallel discriminant network to correct the generated results; Based on semantic similarity, time alignment and structure matching, evaluate the generated results in three dimensions, and dynamically adjust the retrieval threshold and knowledge tree weight according to the evaluation results.
2. The method of claim 1, wherein, The step of enhancing the representation of timing features using time position encoding comprises: Using sine and cosine functions to linearly transform timing features; Add the transformed position vector to the semantic encoding vector to form enhanced timing feature representation.
3. The method of claim 1, wherein, The step of constructing multiple semantic queries according to the summary comprises: Extract teaching mode queries, time mode queries and course type template queries from the structured teaching summary; Establish a three-level semantic routing mechanism for summary-driven query generation and query-driven retrieval execution.
4. The method of claim 1, wherein, The step of performing mixed retrieval on three types of knowledge trees comprises: Build a multi-tree knowledge forest composed of teaching mode tree, time mode tree and course type template tree; Perform dense vector retrieval and keyword filtering simultaneously on each knowledge tree; According to the dynamic retrieval threshold, filter the retrieval results and calculate the comprehensive score of each retrieval result.
5. The method of claim 4, wherein, The step of calculating the comprehensive score comprises: Calculate the semantic similarity between the query and the retrieval result; Combine the context correlation weight to weight and fuse the semantic similarity; According to the comprehensive score, reorder the retrieval results.
6. The method of claim 1, wherein, The step of selecting the optimal subset using the context window compression strategy comprises: Assign importance weights to each retrieval result; Under the window capacity limit, select the subset with the maximum sum of importance weight and semantic similarity product; Organize the selected subset into a reference prompt block.
7. The method of claim 1, wherein, The step of using a parallel discriminant network to correct the generated results comprises: Build a discriminant subnetwork containing fully connected layers and activation functions; Use the discriminant subnetwork to perform parallel discrimination on teaching segment categories and time boundary probabilities; Consistency correction between discriminant results and generated results.
8. The method of claim 1, wherein, The step of evaluating the generated results based on three-dimensional evaluation indicators comprises: Calculate the semantic similarity, time alignment and structure matching between the generated results and the standard answer respectively; Fuse the evaluation results of the three dimensions into a comprehensive score according to the weight.
9. The method of claim 1, wherein, The step of dynamically adjusting the retrieval threshold and the knowledge tree weight comprises: Adjust the dynamic retrieval threshold according to the error distribution; Adjust the knowledge tree weight according to the contribution of each knowledge tree in retrieval; Update the adjusted parameters back to the retrieval system.
10. A system for implementing the method of any one of claims 1 to 9, characterized in that, Comprise: a preprocessing module for preprocessing teaching video data and generating enhanced temporal feature representation; an abstract and query construction module for generating structured abstract and establishing a three-level semantic routing mechanism; a multi-tree knowledge forest retrieval module for performing hybrid retrieval on three types of knowledge trees; a rearrangement and compression module for reordering and context window compression of retrieval results; a generation and discrimination module for performing retrieval enhancement generation and parallel discrimination correction; an evaluation and adaptive module for three-dimensional evaluation and dynamic parameter adjustment.