Intelligent retrieval method and system for educational resources

By using a multi-stage unified optimization framework driven by educational semantics and reinforcement learning with multi-dimensional consistency rewards, the problems of format errors and logical confusion in complex queries of educational resource retrieval systems are solved, achieving intelligent retrieval results with high accuracy and low computational overhead.

CN121501968APending Publication Date: 2026-02-10CHENGDOU HUAQIYUN TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202610040598.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-01-13
Publication Date
2026-02-10

AI Technical Summary

Technical Problem

Existing educational resource retrieval systems cannot deeply understand the semantic structure unique to the education field, making it difficult to handle complex queries. Furthermore, existing models suffer from formatting errors, logical confusion, and semantic drift under complex tasks, failing to meet users' requirements for high accuracy and robustness.

Method used

We adopt a multi-stage unified optimization framework driven by educational semantics. Through a multi-modal, multi-dimensional structured data construction process and LoRA lightweight fine-tuning combined with multi-dimensional consistency rewards, we optimize the generation results of large language models and achieve intelligent retrieval of educational resources and knowledge questions with high accuracy and low computational overhead.

Benefits of technology

It significantly improved the relevance and accuracy of search results, resolved issues of formatting errors and logical inconsistencies, and enhanced the model's cross-task generalization ability and efficient utilization of computing resources in educational scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121501968A_ABST
    Figure CN121501968A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of data processing, in particular to an intelligent retrieval method and system for educational resources. The method comprises the following steps: firstly, generating structured samples of three task modes of Base, Explore and Resource through a multi-mode and multi-dimensional structured data construction process; then, a LoRA lightweight parameter adjustment method is adopted to carry out instruction fine adjustment on the Decoder-Only large language model, and low-cost education semantic adaptation is achieved; finally, a reinforcement learning optimization framework based on multi-dimensional consistency rewards is innovatively proposed, and the normalization and accuracy of model output are remarkably improved by jointly optimizing four reward dimensions of structural rationality, entity matching, stage logicality and semantic consistency; according to the method, high precision, high robustness and low calculation overhead of an educational resource retrieval task are realized, and the practicability and expandability of an intelligent educational system are remarkably improved.
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 intelligent retrieval method and system for educational resources. Background Technology

[0002] With the rapid development of intelligent education platforms and online knowledge services, students, teachers, and other educational participants are placing higher demands on the intelligence and accuracy of educational resource retrieval systems. In the specific context of education, user queries are often highly complex and ambiguous in intent, manifesting as multi-turn dialogues, nested task intents across multiple stages, and complex queries containing parallel entities. For example, a student might request, "Find PPT slides on content C from teacher A's presentation on week B, and explain the connection and differences between knowledge points D and E"—a complex request that integrates resource location and knowledge exploration.

[0003] Currently, traditional educational resource retrieval systems mainly rely on the following two technological approaches: Keyword-based retrieval methods rely on precise or fuzzy matching of words between queries and resource documents. However, they cannot understand the semantics of time and person entities such as "Week B" and "Teacher A," nor can they resolve the deep-seated knowledge association intent of "connection and difference," resulting in low relevance of search results and failing to meet users' real needs.

[0004] Retrieval methods based on shallow semantic analysis: While these methods incorporate some natural language processing techniques, such as calculating sentence vector similarity through pre-trained language models or using basic intent recognition modules, they typically lack a deep understanding of the semantic structures specific to the educational domain, particularly in terms of insufficient modeling of the intrinsic relationships between "learning objectives—knowledge points—teaching resources." When faced with complex queries requiring task decomposition, existing systems often treat them as a whole, failing to effectively break them down into ordered subtasks such as "resource retrieval" and "knowledge question answering," resulting in chaotic task execution logic and coarse granularity.

[0005] Furthermore, existing solutions have significant limitations in model optimization. To adapt to educational tasks, some systems employ Specialized Instruction Fine-tuning (SFT) of large language models; however, full-parameter fine-tuning is costly and it's difficult to guarantee that the model output strictly adheres to the preset structured format. A more prominent problem is that even after fine-tuning, models commonly suffer from format generation errors, incomplete entity extraction, confused stage-level logical dependencies, and semantic drift (i.e., the rewritten query deviates from the original meaning) under complex tasks. These deficiencies severely restrict the accuracy and reliability of retrieval systems in real-world teaching environments.

[0006] Although existing research has attempted to introduce reinforcement learning to optimize generation quality, traditional reward function designs are simplistic, often focusing only on the accuracy of the final result while neglecting the structure, logic, and consistency of the generation process. This makes it impossible to perform detailed, multi-dimensional joint optimization of the structured procedures generated by the model, which may lead to format distortion or illogical results when the model pursues a single reward metric.

[0007] Therefore, existing technologies cannot provide a high-precision, high-robustness, and low-computational-overhead intelligent retrieval solution. There is an urgent need for a new solution that can deeply understand educational semantics, support complex task decomposition and structured output, and ensure output consistency through efficient optimization mechanisms. Summary of the Invention

[0008] The purpose of this invention is to overcome the shortcomings of existing technologies and provide an intelligent retrieval method and system for educational resources. It aims to construct a multi-stage unified optimization framework driven by educational semantics. Through the collaborative efforts of data construction, model adaptation and reinforcement optimization, combined with multi-mode task processing, LoRA lightweight fine-tuning and multidimensional consistent reward reinforcement learning (MDCR-GRPO), it achieves high accuracy, high robustness and low computational cost in educational resource retrieval.

[0009] To achieve the above objectives, this application proposes an intelligent retrieval method for educational resources, used for retrieving educational resources and knowledge-based question-and-answer formats, including: Educational semantic structure construction steps: Through an automatic construction process using multi-modal and multi-dimensional structured data, the user's natural language query is processed to generate semantically structured educational task samples; Educational task instruction adaptation steps: Based on the educational task samples, a dual-mechanism fusion method of SFT instruction fine-tuning and LoRA lightweight training is used to fine-tune the large language model of the Decoder-Only architecture, so as to achieve unified modeling for different educational task types; Educational semantic consistency reinforcement optimization steps: Based on the fine-tuned large language model, the GRPO reinforcement learning strategy is introduced to optimize the generation results of the large language model; among them, reinforcement learning training is carried out through a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards, and the model generation results are dynamically evaluated through a composite reward function.

[0010] As a further solution, the automatic construction process of multi-modal, multi-dimensional structured data in the educational semantic structure construction step includes: Natural language queries are defined by task scenarios and broken down into educational resource queries and educational knowledge question-and-answer queries. Set task modes for natural language queries; wherein, the educational resource query is set to Resource mode, and the educational knowledge question and answer query is set to Base mode or Explore mode; The original statement of the natural language query is semantically rewritten in combination with the context; in Base mode or Explore mode, intent completion is further performed to obtain the rewritten statement. Parallel intent generation and entity extraction are performed on natural language queries; among them, a structured semantic modeling scheme is designed according to the differentiated objectives of the task mode, and the natural language query is mapped into a supervision signal; Based on the task pattern, corresponding structured fields are generated, and combined with the rewritten statements for unified standardization processing to construct semantically structured educational task samples.

[0011] As a further solution, when generating structured fields: Base mode: Generates structured fields that perform phased semantic structure decomposition of natural language queries; Explore mode: Based on the Base mode, it adds structured fields for in-depth decomposition of natural language queries; Resource mode: Generates structured fields for accurately extracting educational resource entities from natural language queries.

[0012] As a further solution, the training dataset is obtained by filtering educational task samples through the following sub-steps: The educational task samples are represented as a set of structured triples: in, The statement refers to either the original statement or the rewritten statement. Represents the semantic structure of stages. N represents the set of entities; N represents the number of educational task samples, and i represents the sample number of the educational task. Calculate the heuristic matching function value and retain only entities that are above the heuristic matching threshold; Perform a field integrity check on each structured field of the stage semantic structure, and retain only the structured fields that are complete. Calculate the semantic cosine similarity value and retain only statements that are higher than the semantic matching threshold; Calculate the overall matching score function Only educational task samples that are above the overall matching threshold are retained; in, The fusion coefficient of the matching strategy is represented by... ; Indicates the value of the heuristic matching function; Represents the semantic cosine similarity value; This represents the entity with entity number j.

[0013] As a further solution, the heuristic matching function value is calculated based on the heuristic matching function of term overlap: in, and They represent and The word segmentation results This represents a heuristic matching function used to characterize entities. exist The degree to which it is mentioned.

[0014] As a further solution, the semantic cosine similarity value is calculated through the following steps: For the statement and entity set Using a vector representation model to represent statements With entity Encode them separately to obtain vectors sum vector The encoding process is as follows: Calculate semantic cosine similarity: Set semantic matching threshold , among which, if If so, it is considered a semantic match.

[0015] As a further solution, in the educational task instruction adaptation step, the large language model of the Decoder-Only architecture is fine-tuned through the following sub-steps: By introducing additional low-rank matrices A and B through the LoRA algorithm, the updated weight matrix reduces memory usage and speeds up training. Where W represents the original weight matrix in the pre-trained model; This represents the updated weight matrix, where A and B are additional low-rank matrices. This is the scaling factor. It is a low-rank matrix; The text generation loss function based on the Decoder Only architecture is calculated as follows: in, This represents the real token at position t; This indicates the model's prediction probability of the true token at position t based on the first t-1 positions; T represents the sequence length or the number of valid tokens.

[0016] As a further solution, in the reinforcement optimization step of educational semantic consistency, the reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards consists of a composite reward function composed of multiple sub-reward dimensions weighted together, formally defined as follows: in, The structured output representing the model's predictions. This indicates manually annotated answers. Indicates a reward for structural rationality. Indicates entity matching reward, Indicates a stage-based logical reward. Represents a semantic consistency reward. , , , These are the weighting coefficients for each dimension.

[0017] As a further solution, in the optimization step of strengthening educational semantic consistency, the dynamic evaluation of the model-generated results through a composite reward function specifically includes: The fine-tuned large language model is considered as the policy network. ;in, Indicates the current state. This represents the output action generated by the model. This refers to the strategy itself; In multi-stage, multi-task scenarios, samples in the training dataset are grouped according to task patterns or stage sub-tasks to form sets. : in, This represents the total number of groups, and each sample group... Includes samples of similar tasks to ensure that relative optimization within the group can be performed during gradient updates; For each sample and its model prediction, the sample reward is calculated using the aforementioned composite reward function: Where i is the corresponding sample number; Define the within-group relative advantage function in GRPO: in, This indicates that sample i is in the sample group. The relative advantage of China Let i represent the composite reward function for sample i; The policy network optimizes by maximizing the expected relative reward within the group, with the update formula being: in, Describe the objective function Regarding model parameters gradient, This represents the gradient of the scoring function; By introducing KL regularization constraints, we prevent policy updates from causing the generated results to deviate from the distribution of the training dataset. The final optimization goal is: in, This represents the KL regularization loss term. For adjustment coefficients, For relative entropy, For the current policy network, This represents the base strategy after LoRA fine-tuning.

[0018] On the other hand, the present invention also provides an intelligent retrieval system for educational resources, used for retrieving educational resources and knowledge-based question-and-answer questions as described in any of the preceding claims, including: Educational Semantic Structure Construction Module: Through an automatic construction process using multi-modal and multi-dimensional structured data, this module processes users' natural language queries to generate semantically structured educational task samples. Educational task instruction adaptation module: Based on the educational task samples, a dual-mechanism fusion method of SFT instruction fine-tuning and LoRA lightweight training is used to fine-tune the large language model of the Decoder-Only architecture, so as to achieve unified modeling for different educational task types; Educational semantic consistency reinforcement optimization module: Based on the fine-tuned large language model, the GRPO reinforcement learning strategy is introduced to optimize the generation results of the large language model; in particular, reinforcement learning training is carried out through a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards, and the model generation results are dynamically evaluated through a composite reward function.

[0019] Compared with related technologies, the intelligent retrieval method and system for educational resources provided by this invention have the following advantages: 1. This invention introduces a multi-mode, multi-dimensional structured data construction process oriented towards educational tasks, and performs in-depth analysis of user queries based on a three-layer semantic structure of "learning objectives—knowledge points—teaching resources," enabling the system to accurately depict the user's true intent. In particular, the division and targeted processing of three task modes—Base, Explore, and Resource—enables the system to effectively handle various educational scenarios, from simple question-and-answer to complex multi-turn dialogues, and from knowledge queries to resource location, significantly improving the relevance and accuracy of search results. 2. This invention creatively designs a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards. Through joint optimization of four types of reward signals—structural rationality, entity matching, stage logic, and semantic consistency—it constrains and guides the model's generative behavior from multiple dimensions. This ensures that the model output not only has a standardized format conforming to the preset JSON schema, but also performs excellently in terms of task decomposition granularity, entity extraction completeness, and logical coherence between stages, effectively solving common problems in traditional methods such as formatting errors, logical confusion, and semantic drift. 3. The multi-stage unified modeling framework and GRPO grouping relative optimization mechanism of this invention enable the model to quickly adapt to retrieval tasks of different types and complexities in the education field. By performing relative advantage calculation and gradient update within different task groups, the model maintains high performance and stability in Base, Explore, and Resource modes, demonstrating excellent cross-task generalization ability and effectively addressing the challenges of varied query intents and diverse expression methods in real teaching environments.

[0020] 4. This invention employs the LoRA lightweight parameter tuning method for fine-tuning large-scale language models, achieving high-quality adaptation of educational semantics with only a tiny parameter subspace update, significantly reducing the computational and storage requirements of model training. Simultaneously, this lightweight design makes the optimized model easier to deploy and infer online in real-world teaching environments, achieving an effective balance between high performance and low resource consumption. Attached Figure Description

[0021] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0022] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, those skilled in the art can obtain other drawings based on these drawings without creative effort.

[0023] Figure 1 A schematic diagram illustrating the steps of an intelligent retrieval method for educational resources provided by this invention; The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0024] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0025] Example 1 Please see Figure 1 This embodiment achieves accurate characterization and dynamic optimization of users' true query intent in the specific semantic space of education through a three-ring collaborative mechanism of data construction, model adaptation and reinforcement optimization, thereby significantly improving the generalization, accuracy and robustness of the educational resource and knowledge question answering retrieval system in real teaching deployment scenarios; Its technical process includes the following steps: Educational Semantic Structure Construction Steps (Step 1): This step is responsible for establishing the semantic foundation of the entire system. In response to the problems of multi-turn dialogue, ambiguous intent and data scarcity in educational scenarios, a multi-mode and multi-dimensional structured data automatic construction process oriented towards educational tasks is proposed. Step 1 takes the three-layer educational semantic structure of "learning objectives - knowledge points - teaching resources" as the core and performs the following on user queries: (1) decomposition of educational semantic sub-tasks; (2) entity salience and context dependency annotation; (3) educational semantic rewriting (structural reorganization). By mining historical contextual semantic information, "semantically structured educational task samples" are generated.

[0026] These samples are not only used for index optimization, but also serve as input feature templates for subsequent model fine-tuning. Therefore, the output of step 1 directly determines the model's task adaptability in step 2.

[0027] Educational Task Instruction Adaptation Steps (Step 2): Step 2 builds upon the educational semantic structure generated in Step 1 to construct a task structure expression space with instruction templates. Using a Decoder-Only architecture large language model (Qwen3_14b) as a foundation, a dual-mechanism fusion method combining instruction fine-tuning (SFT) and LoRA lightweight training is employed to achieve unified modeling for different educational task types. SFT is used to learn educational semantic templates, task structure constraints, and intent dependencies; LoRA only updates the parameter subspace related to educational semantics, achieving educational semantic adaptation at low cost. The fine-tuning data comes directly from the educational semantic structured corpus of step 1, ensuring semantic consistency and task structure continuity between steps. Therefore, step 2 depends on the output of step 1, while providing structural rationality and saliency reference signals for step 3.

[0028] Educational semantic consistency reinforcement optimization steps (step 3): After fine-tuning in step 2, although the model possesses a certain ability to understand educational semantics, problems such as ambiguous subtask granularity and disordered entity dependencies may still occur in complex task structures. To address this, this invention proposes a reinforcement learning optimization framework based on multidimensional educational semantic consistency rewards (EDU-MDCR-GRPO). Reinforcement learning uses this as a multidimensional dynamic reward signal to perform gradient feedback optimization on the model generation strategy, continuously improving the task decomposition granularity and structural rationality.

[0029] Specifically, in the educational semantic structure construction step, the automatic construction process of multi-modal, multi-dimensional structured data includes: Natural language queries are defined by task scenarios and broken down into educational resource queries and educational knowledge question-and-answer queries. Set task modes for natural language queries; wherein, the educational resource query is set to Resource mode, and the educational knowledge question and answer query is set to Base mode or Explore mode; The original statement of the natural language query is semantically rewritten in combination with the context; in Base mode or Explore mode, intent completion is further performed to obtain the rewritten statement. Parallel intent generation and entity extraction are performed on natural language queries; among them, a structured semantic modeling scheme is designed according to the differentiated objectives of the task mode, and the natural language query is mapped into a supervision signal; Based on the task pattern, corresponding structured fields are generated, and combined with the rewritten statements for unified standardization processing to construct semantically structured educational task samples.

[0030] It should be noted that the educational resource search (Resource) focuses on searches for resources by students and teachers, such as: "Teacher A's PPT on Content C from Week B". Entity extraction enhances the accuracy of the search. The Educational Knowledge Question and Answer Query (Base / Explore) scenario focuses on students, teachers, and others' queries and answers regarding knowledge. Its features include multi-turn contextual dialogue, complex intent decomposition, etc. For example: "Query the definition and relationship between knowledge point D and knowledge point E".

[0031] The raw corpus collection involves gathering large-scale multi-turn dialogue records from real question-and-answer systems, educational platforms, and user simulation tasks. Supplementary data is generated using API prompts such as Qwen and OpenAI. The samples are divided into three categories according to the task intent. This step lays the foundation for multi-turn contextual data and provides a standard business model structure for subsequent task modeling.

[0032] Furthermore, explicit semantic rewriting is performed on the user's current natural language query and in conjunction with the context to eliminate omissions, ambiguities, and semantic drift. In addition, the user's deeper query intent is restored and omitted contextual information is supplemented in the Base / Explorer mode. The rewriting goal helps to build a unified and clear query expression paradigm, and also lays a stable input for subsequent structured modeling.

[0033] Next, this embodiment performs parallel intent generation and entity extraction. Based on the differentiated objectives of the three task modes (Base / Explore / Resource), a targeted structured semantic modeling scheme is designed. The core of this stage is to map natural language queries into semantically clear and structurally standardized supervision signals for downstream models to train for intent recognition and entity extraction.

[0034] Since user queries often involve complex task requirements with multiple entity objectives (such as "someone wants to know the key knowledge points of content D and content E"), such queries contain parallel semantic structures. If they are directly processed by the model, it is easy to cause semantic confusion and a decrease in generation quality. Therefore, "parallel intent generation" is introduced to realize the semantic expansion and task decomposition of multiple entity objectives, thereby improving the model's ability to model the structure of multi-objective tasks.

[0035] When generating structured fields, this invention defines structured fields for three task modes (Base / Explore / Resource) as follows: Base mode: focuses on the phased decomposition of user queries; {"rewrite_query":xx,"similarity":true / false, "query_stages":[ {"stage":1,"stage_query":"xx", "abstract_entities":["xx"],"specific_entities":["xx"],"entities_query":["xx"]}, {{"stage":2,"stage_query":"xx", "abstract_entities":["xx"],"specific_entities":["xx"],"entities_query":["xx"]}, }]} Explore mode: Focuses on in-depth breakdown of user queries, supporting complex task breakdown, intent rewriting, stage recognition, entity extraction and parallel generation; {"rewrite_query":xx,"similarity":true / false, "query_stages":[ {"stage":1,"stage_query":"xx","sub_queries":[{"query":"xx", "abstract_entities":["xx"],"specific_entities":["xx"],"entities_query":["xx"]}]}, {{"stage":2,"stage_query":"xx","sub_queries":[{"query":"xx", "abstract_entities":["xx"],"specific_entities":["xx"],"entities_query":["xx"]}]}, }]} Here, `rewrite_query` represents rewriting the current query in conjunction with its context, performing referential resolution; `similarity` represents whether the current query is related to the historical context; `query_stages` represents decomposing the steps for `rewrite_query`; `stage` represents stage type 1 (retrieval) and 2 (tool invocation), and `stage_query` represents a sub-stage query; `sub_queries` represents a deep breakdown of sub-stage queries; `abstract_entities` represents extracting high-dimensional abstract entities from the queries in the current `sub_queries`; `specific_entities` represents extracting fine-grained specific entities from the queries in the current `sub_queries`; and `entities_query` represents the entity queries that make up the query.

[0036] Resource mode: Designed for scenarios where users search for resources, it focuses on the accurate extraction of entities such as people, courses, and time for educational resources, making them available as search criteria to assist the retrieval system in retrieving data.

[0037] "resource_entities":{"college":"xx",…,} The above fields demonstrate good intent recognition and retrieval enhancement effects when used in educational scenarios. Furthermore, this solution can be generalized to general scenarios, exhibiting good generalization ability.

[0038] In this embodiment, after completing structured annotation and semantic decomposition, to ensure high data availability during supervised fine-tuning (SFT), reward function training (RFT), and evaluation stages, the sample structure needs to be standardized. This step aims to ensure the accuracy of semantic annotation, the consistency of structural fields, and the cleanliness and integrity of the format.

[0039] Furthermore, queries in educational scenarios often involve entities such as knowledge points, textbook chapters, or exercises, which are closely related to the query statement. To accurately capture user intent, this invention proposes a multi-granularity weighted matching function. Simultaneously considering both word-level direct matching and contextual semantic similarity, this approach achieves high-precision relevance modeling between educational entities and query statements, demonstrating good robustness and interpretability across diverse educational tasks. This embodiment obtains the training dataset by filtering educational task samples through the following sub-steps: The educational task samples are represented as a set of structured triples: in, The statement refers to either the original statement or the rewritten statement. Represents the semantic structure of stages (such as stage division query_stages or intent type stage_type). N represents the set of entities (e.g., specific_entities); N represents the number of educational task samples, and i represents the sample number of the educational task. To improve matching efficiency and reduce model computational overhead, this invention first defines a heuristic matching function based on word overlap: in, and They represent and The word segmentation results This represents a heuristic matching function used to characterize entities. exist The degree to which an entity is mentioned in the context allows this function to act as a coarse-screening mechanism, providing an effective filter for constructing a candidate set of entities.

[0040] To more comprehensively capture implicit information in query intent, especially linguistic phenomena such as pronouns and ellipsis, a field integrity check is further performed on each field for the query. and entity set Using a vector representation model to represent statements With entity Encode them separately to obtain vectors sum vector The encoding process is as follows: Calculate semantic cosine similarity: Set semantic matching threshold , among which, if If so, it is considered a semantic match.

[0041] To further balance character-level precise matching with semantic-level generalization capability, this invention ultimately adopts the following weighted hybrid strategy to define the overall matching score function: in, This represents the fusion coefficient of the matching strategy, with empirical values ​​between 0.3 and 0.5. Indicates the value of the heuristic matching function; Represents the semantic cosine similarity value; This represents the entity with entity number j.

[0042] Furthermore, to improve the model's task adaptability in educational scenarios, this invention employs the LoRA method for lightweight parameter fine-tuning on a Decoder-only architecture (Qwen3_14b in this invention). Combined with diverse structured instruction data, the model can simultaneously complete instruction learning and low-rank parameter updates in a single training session, reducing training costs, improving efficiency, and enhancing the model's ability to accurately understand educational queries.

[0043] Specifically, in the educational task instruction adaptation step, the large language model of the Decoder-Only architecture is fine-tuned through the following sub-steps: LoRA technology inserts two low-rank matrices into the model's attention module. and Instead of the original parameter matrix A full update, only and When participating in gradient updates, all original model parameters are frozen, thereby reducing GPU memory usage and speeding up training. Where W represents the original weight matrix in the pre-trained model; This represents the updated weight matrix, where A and B are additional low-rank matrices. This is the scaling factor. It is a low-rank matrix (in this invention, r is set to 8). (16) The text generation loss function based on the Decoder Only architecture is calculated as follows: in, This represents the real token at position t; This represents the model's prediction probability of the true token at position t based on the first t-1 positions; T represents the sequence length or the number of valid tokens (excluding padding positions).

[0044] Furthermore, after fine-tuning with LoRA, this invention, through model testing and online deployment inference testing, discovered that the LoRA-tuned model suffers from defects such as format generation errors and weak decomposition granularity. Therefore, to address these issues, this invention introduces the GRPO reinforcement learning strategy and optimizes the model generation results through the following sub-steps to improve the model's structured consistency and robustness in educational query and resource recommendation tasks.

[0045] Specifically, in the reinforcement optimization step of educational semantic consistency, the reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards consists of a composite reward function composed of multiple sub-reward dimensions weighted together, formally defined as follows: in, The structured output representing the model's predictions. This indicates manually annotated answers. Indicates a reward for structural rationality. Indicates entity matching reward, Indicates a stage-based logical reward. Represents a semantic consistency reward. , , , These are the weighting coefficients for each dimension; Format Correctness Reward: Used to constrain whether the model's generated results conform to a preset JSON schema. If the output... If all field and type constraints are met, a full score is awarded; otherwise, a penalty is imposed based on the number of errors. in, This indicates the number of fields with incorrect formatting. The total number of fields specified in the schema.

[0046] Entity Matching Reward: Uses a multi-granularity weighted matching function Combining lexical and semantic similarity, the precision and recall of the extracted entities are calculated compared to those in the standard answer, and then mapped to a reward score. .

[0047] Stage Logic Reward: For the sequence of stages after task decomposition. To ensure logical coherence and executability, this invention defines a classifier. The probability that its output stage sequence is logically correct is: If heuristic rules are used instead of classifiers, then a logical consistency scoring function can be defined. For example, based on stage dependency constraints (such as "entity extraction" must precede "semantic rewriting").

[0048] Semantic Consistency Reward: To ensure that the rewrite query does not deviate from the original intent, this invention utilizes independent pre-trained sentence vector models to calculate similarity. in, For sentence vector encoder, For the original user query, This is the rewritten query.

[0049] Furthermore, the core idea of ​​GRPO is to relatively optimize the policy gradient under multi-task grouping, and to dynamically evaluate the model's generated results through a composite reward function, thereby guiding the model to output semantic programs that better conform to the expected structure.

[0050] Specifically, in the step of strengthening and optimizing the semantic consistency of education, the dynamic evaluation of the model's generated results through a composite reward function includes: The fine-tuned large language model is considered as the policy network. ;in, Indicates the current state (input query and context code). This represents the output action (structured intent and entity set) generated by the model. This refers to the strategy itself; In multi-stage, multi-task scenarios, samples in the training dataset are grouped according to task patterns or stage sub-tasks to form sets. : in, This represents the total number of groups, and each sample group... Includes samples of similar tasks to ensure that relative optimization within the group can be performed during gradient updates; For each sample and its model prediction, the sample reward is calculated using the aforementioned composite reward function: Where i is the corresponding sample number; Define the within-group relative advantage function in GRPO: in, This indicates that sample i is in the sample group. The relative advantage of China Let i represent the composite reward function for sample i; this advantage function measures the potential for improvement of the current sample relative to the group average performance, thereby enhancing the stability and fairness of the group optimization during gradient updates. The policy network optimizes by maximizing the expected relative reward within the group, with the update formula being: in, Describe the objective function Regarding model parameters gradient, This represents the gradient of the scoring function; the formula reflects how GRPO, in multi-task scenarios, balances global stability and intra-group local adaptability through a relatively reward-oriented gradient optimization approach.

[0051] By introducing KL regularization constraints, we prevent policy updates from causing the generated results to deviate from the distribution of the training dataset. The final optimization goal is: in, This represents the KL regularization loss term. For adjustment coefficients, For relative entropy, For the current policy network, This represents the base strategy after LoRA fine-tuning.

[0052] Example 2 Based on Embodiment 1, this embodiment also provides an intelligent retrieval system for educational resources, which retrieves educational resources and knowledge-based question-and-answer formats, including: Educational Semantic Structure Construction Module: Through an automatic construction process using multi-modal and multi-dimensional structured data, this module processes users' natural language queries to generate semantically structured educational task samples. Educational task instruction adaptation module: Based on the educational task samples, a dual-mechanism fusion method of SFT instruction fine-tuning and LoRA lightweight training is used to fine-tune the large language model of the Decoder-Only architecture, so as to achieve unified modeling for different educational task types; Educational semantic consistency reinforcement optimization module: Based on the fine-tuned large language model, the GRPO reinforcement learning strategy is introduced to optimize the generation results of the large language model; in particular, reinforcement learning training is carried out through a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards, and the model generation results are dynamically evaluated through a composite reward function.

[0053] It should be noted that: based on the training performed by the above algorithm, the model performance of this invention is evaluated, and the results of the three tasks are shown in Tables 1, 2 and 3 below; where qwenplus represents a large model on a certain cloud platform with strong performance, Qwen3_14b represents an untrained large model, Qwen3_14b_lora represents a large model fine-tuned by LoRA, and Qwen3_14b_grpo represents a large model trained by grpo based on LoRA fine-tuning; Table 1. Resource Mode Test Results Table 2 Base Mode Test Results Table 3. Test Results of Explore Mode (1) Resource mode In the task of extracting entities from educational resources, the EDU-MDCR-GRPO model proposed in this invention significantly outperforms other models in terms of precision, recall, and F1 score.

[0054] Specifically, the Qwen3_14b_grpo model achieved a precision of 0.8307, a recall of 0.8771, and an F1 score of 0.8502, representing an improvement of approximately 2.2% compared to qwenplus (F1=0.8318) and approximately 5.1% compared to the Qwen3_14b pedestal model (F1=0.8092).

[0055] The results show that the reinforcement learning optimization strategy of multidimensional consistency reward effectively improves the model's extraction accuracy and coverage of multiple types of entities in educational resources, and enhances the system's robustness and generalization ability under complex educational queries.

[0056] (2) Results of Base Mode In the basic intent recognition and query structuring tasks, the EDU-MDCR-GRPO model outperforms LoRA and the base model in both stage query semantic similarity (stage_query_sim) and recall, reaching 0.9734 and 0.8402 respectively, which is close to or even slightly higher than the performance of qwenplus.

[0057] Overall, the model of this invention can maintain rewrite consistency with commercial models in Base mode, while improving the robustness of semantic stage recognition.

[0058] (3) Results in Explore mode In multi-stage task decomposition and intent rewriting scenarios, the stage_query_sim index of the EDU-MDCR-GRPO model improved from 0.9028 in the base model to 0.9494, with a similarity improvement of about 5.2%, which significantly improved the semantic preservation and contextual consistency of complex task decomposition.

[0059] The results from the three models show that the method of the present invention has the following technical advantages in educational scenarios: Strong structured understanding capability—significantly improves the accuracy and completeness of entity recognition in Resource mode; Superior multi-task consistency—maintaining high semantic consistency and stable performance in both Base and Explore modes; Excellent generalization and robustness – Through multi-dimensional reward-guided reinforcement learning optimization, the model exhibits high stability and scalability across various educational tasks.

[0060] The above are only some embodiments of this application and do not limit the patent scope of this application. All equivalent structural transformations made under the technical concept of this application and using the contents of the specification and drawings of this application, or direct / indirect applications in other related technical fields, are included in the patent protection scope of this application.

Claims

1. An intelligent retrieval method for educational resources, used for retrieving educational resources and knowledge-based question-and-answer formats, characterized in that, include: Educational semantic structure construction steps: Through an automatic construction process using multi-modal and multi-dimensional structured data, the user's natural language query is processed to generate semantically structured educational task samples; Educational task instruction adaptation steps: Based on the educational task samples, a dual-mechanism fusion method of SFT instruction fine-tuning and LoRA lightweight training is used to fine-tune the large language model of the Decoder-Only architecture, so as to achieve unified modeling for different educational task types; Educational semantic consistency reinforcement optimization steps: Based on the fine-tuned large language model, the GRPO reinforcement learning strategy is introduced to optimize the generation results of the large language model; among them, reinforcement learning training is carried out through a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards, and the model generation results are dynamically evaluated through a composite reward function.

2. The intelligent retrieval method for educational resources according to claim 1, characterized in that, In the educational semantic structure construction step, the automatic construction process of multi-modal, multi-dimensional structured data includes: Natural language queries are defined by task scenarios and broken down into educational resource queries and educational knowledge question-and-answer queries. Set task modes for natural language queries; wherein, the educational resource query is set to Resource mode, and the educational knowledge question and answer query is set to Base mode or Explore mode; The original statement of the natural language query is semantically rewritten in combination with the context; in Base mode or Explore mode, intent completion is further performed to obtain the rewritten statement. Parallel intent generation and entity extraction are performed on natural language queries; among them, a structured semantic modeling scheme is designed according to the differentiated objectives of the task mode, and the natural language query is mapped into a supervision signal; Based on the task pattern, corresponding structured fields are generated, and combined with the rewritten statements for unified standardization processing to construct semantically structured educational task samples.

3. The intelligent retrieval method for educational resources according to claim 2, characterized in that, When generating structured fields: Base mode: Generates structured fields that perform phased semantic structure decomposition of natural language queries; Explore mode: Based on the Base mode, it adds structured fields for in-depth decomposition of natural language queries; Resource mode: Generates structured fields for accurately extracting educational resource entities from natural language queries.

4. The intelligent retrieval method for educational resources according to claim 2, characterized in that, The training dataset is obtained by filtering educational task samples through the following sub-steps: The educational task samples are represented as a set of structured triples: in, The statement refers to either the original statement or the rewritten statement. Represents the semantic structure of stages. N represents the set of entities; N represents the number of educational task samples, and i represents the sample number of the educational task. Calculate the heuristic matching function value and retain only entities that are above the heuristic matching threshold; Perform a field integrity check on each structured field of the stage semantic structure, and retain only the structured fields that are complete. Calculate the semantic cosine similarity value and retain only statements that are higher than the semantic matching threshold; Calculate the overall matching score function Only educational task samples that are above the overall matching threshold are retained; in, The fusion coefficient of the matching strategy is represented by... ; This represents the value of the heuristic matching function; Represents the semantic cosine similarity value; This represents the entity with entity number j.

5. The intelligent retrieval method for educational resources according to claim 4, characterized in that, The heuristic matching function value is calculated based on the heuristic matching function for term overlap: in, and They represent and The word segmentation results This represents a heuristic matching function used to characterize entities. exist The degree to which it is mentioned.

6. The intelligent retrieval method for educational resources according to claim 4, characterized in that, The semantic cosine similarity value is calculated through the following steps: For the statement and entity set Using a vector representation model to represent statements With entity Encode them separately to obtain vectors sum vector The encoding process is as follows: Calculate semantic cosine similarity: Set semantic matching threshold , among which, if If so, it is considered a semantic match.

7. The intelligent retrieval method for educational resources according to claim 1, characterized in that, In the educational task instruction adaptation step, the large language model of the Decoder-Only architecture is fine-tuned through the following sub-steps: By introducing additional low-rank matrices A and B through the LoRA algorithm, the updated weight matrix reduces memory usage and speeds up training. Where W represents the original weight matrix in the pre-trained model; This represents the updated weight matrix, where A and B are additional low-rank matrices. This is the scaling factor. It is a low-rank matrix; The text generation loss function based on the Decoder Only architecture is calculated as follows: in, This represents the real token at position t; This indicates the model's prediction probability of the true token at position t based on the first t-1 positions; T represents the sequence length or the number of valid tokens.

8. The intelligent retrieval method for educational resources according to claim 1, characterized in that, In the reinforcement optimization step of educational semantic consistency, the reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards consists of a composite reward function composed of multiple sub-reward dimensions weighted together, and is formally defined as follows: in, This represents the structured output of the model's predictions. This indicates manually annotated answers. Indicates a reward for structural rationality. Indicates entity matching reward, Indicates a stage-based logical reward. Represents a semantic consistency reward. , , , These are the weighting coefficients for each dimension.

9. The intelligent retrieval method for educational resources according to claim 8, characterized in that, In the optimization step of enhancing semantic consistency in education, the dynamic evaluation of the model's generated results through a composite reward function specifically includes: The fine-tuned large language model is represented as the policy network. ;in, Indicates the current state. This represents the output action generated by the model. This refers to the strategy itself; In multi-stage, multi-task scenarios, samples in the training dataset are grouped according to task patterns or stage sub-tasks to form sets. : in, This represents the total number of groups, and each sample group... Includes samples of similar tasks to ensure that relative optimization within the group can be performed during gradient updates; For each sample and its model prediction, the sample reward is calculated using the aforementioned composite reward function: Where i is the corresponding sample number; Define the within-group relative advantage function in GRPO: in, This indicates that sample i is in the sample group. The relative advantage of China Let i represent the composite reward function for sample i; The policy network optimizes by maximizing the expected relative reward within the group, with the update formula being: in, Describe the objective function Regarding model parameters gradient, This represents the gradient of the scoring function; By introducing KL regularization constraints, we prevent policy updates from causing the generated results to deviate from the distribution of the training dataset. The final optimization goal is: in, This represents the KL regularization loss term. For adjustment coefficients, For relative entropy, For the current policy network, This represents the base strategy after LoRA fine-tuning.

10. An intelligent retrieval system for educational resources, used to retrieve educational resources and knowledge Q&A according to the intelligent retrieval method for educational resources as described in any one of claims 1 to 9, characterized in that, include: Educational Semantic Structure Construction Module: Through an automatic construction process using multi-modal and multi-dimensional structured data, this module processes users' natural language queries to generate semantically structured educational task samples. Educational task instruction adaptation module: Based on the educational task samples, a dual-mechanism fusion method of SFT instruction fine-tuning and LoRA lightweight training is used to fine-tune the large language model of the Decoder-Only architecture, so as to achieve unified modeling for different educational task types; Educational semantic consistency reinforcement optimization module: Based on the fine-tuned large language model, the GRPO reinforcement learning strategy is introduced to optimize the generation results of the large language model; in particular, reinforcement learning training is carried out through a reinforcement learning optimization framework based on multi-dimensional educational semantic consistency rewards, and the model generation results are dynamically evaluated through a composite reward function.

Citation Information

Patent Citations

  • Large anesthesia model training method and device

    CN117095827A

  • Enhanced retrieval generation method based on potential fusion LoRA

    CN120596624A

  • Foundation generative artificial intelligence (AI) model with transformer architecture for environmental, social, and governance (ESG) impact

    US20250299059A1