Method and device for constructing self-adaptive large model seat partner training ability in government affair hotline scene, and medium
By adopting an automatic switching mechanism for prompt words and parameter matrices in government hotline scenarios, combined with LoRa fine-tuning and prompt word engineering, the adaptability problem of the model in government hotline scenarios was solved, achieving the effect of quickly adapting to multi-scenario dialogue and reducing resource costs.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-23
- Publication Date
- 2026-03-27
AI Technical Summary
In the context of government hotlines, existing technologies for building large-scale models for call center assistant training suffer from problems such as model illusion, bias, and leaked prompts. In addition, high-quality labeled data is scarce, resource consumption is high, and generalization ability is insufficient.
By adopting an automatic switching mechanism for prompt words and parameter matrices, combined with LoRa fine-tuning and prompt word engineering, the appropriate method is selected to stimulate the model's capabilities through an adaptive switching mechanism. Data is automatically labeled and training datasets are constructed, thus solving the problem of model adaptability in government hotline scenarios.
It enables government hotline dialogues to quickly adapt to multiple scenarios, reduces manual preparation work, improves the model's generalization ability and dialogue accuracy, and reduces resource and labor costs.
Smart Images

Figure CN121745951A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of natural language processing technology, specifically relating to a method, device, and medium for constructing an adaptive large-scale model for call center agent training in a government hotline scenario. Background Technology
[0002] LLM stands for Large Language Model. These models are built on deep neural networks and typically contain hundreds of billions or more parameters. They are trained using massive amounts of unlabeled text data through self-supervised learning. Currently, many representative models have emerged in the LLM field, such as ChatGPT, Qwen, ChatGLM, LLaMA, BaiChuan, and Wenxin Yiyan.
[0003] Prompt engineering, in the field of large language models, is a crucial guidance mechanism. It typically takes the form of text and instructs the model to generate specific output content. A prompt can be a simple question, a short sentence, a long paragraph, or even an entire article. The design of the prompt is paramount, as its quality directly impacts the relevance, accuracy, and style of the content generated by the model.
[0004] RLHF, short for Reinforcement Learning from Human Feedback, is an important technique for improving the quality of model output and user satisfaction. It introduces subjective human evaluations of the model's output as feedback signals, constructing a reward mechanism to guide model learning. Specifically, human annotators first rate or rank various outputs of the model. Based on this human feedback, the model uses reinforcement learning algorithms to adjust its parameters to maximize expected rewards. This mechanism allows the model to learn human preferences and value judgments, optimizing the rationality, accuracy, and suitability of generated content, making the model's output more in line with human expectations and usage needs.
[0005] SFT, short for Supervised Fine-Tuning, is a fundamental step in optimizing large language models, aiming to better adapt pre-trained models to specific tasks and domains. It relies on large amounts of well-labeled, high-quality data containing explicit inputs and corresponding correct outputs. The pre-trained model is fine-tuned on this labeled data, adjusting model parameters to allow the model to learn the mapping relationship between inputs and outputs, thereby enhancing its understanding and processing capabilities for specific tasks. Supervised fine-tuning effectively improves model performance in specific scenarios, making model outputs more accurate and better suited to real-world application needs. It is a crucial step in transitioning large language models from general-purpose capabilities to specialized domain applications.
[0006] Lora, short for Low-Rank Adaptation, is an efficient fine-tuning technique for large language models within Supervised Language Functional Theory (SFT). It aims to adapt pre-trained models to specific tasks and domains in a lightweight manner. Based on task-specific labeled data, it freezes most of the parameters of the pre-trained model, inserting only trainable low-rank matrix parameters into key layers, significantly reducing the number of parameters that need to be updated. During fine-tuning, the model learns the parameters of the low-rank matrix to capture the mapping relationship between input and output, while retaining the general capabilities of the pre-trained model. Lora fine-tuning can effectively improve the performance of a model on a specific task while significantly reducing computational resource consumption. It is an efficient implementation of supervised fine-tuning (SFT) for large language models, particularly suitable for model adaptation needs in resource-constrained scenarios.
[0007] In the field of government hotlines, call center training is a key element in improving hotline service capabilities. By simulating real citizen call scenarios, it helps call center agents master policy-related language, standardize response procedures, and handle complex requests. Meanwhile, Large Language Models (LLM) demonstrate strong advantages in dialogue and question-and-answer processing. Therefore, call center training is a very important practical application of LLM in government hotline scenarios.
[0008] Currently, there are two main methods for building large-scale model-based training capabilities: 1. Enhancing the ability of large-scale models to provide interactive training through prompt word engineering. Prompt engineering studies how to construct and adjust prompts to enable large language models to generate content that meets user expectations. In government hotline operator training applications, prompts typically include multiple dimensions such as citizen information, contextual background, purpose of the request, language style, and emotional tendency. For example, to simulate an emotionally agitated citizen calling, the prompt could be: "You are a citizen who has repeatedly complained about heating issues without resolution, is angry, demands an immediate solution, and questions the government's inaction." Through such prompts, the large model can generate realistic, high-intensity dialogue scenarios, effectively improving the operator's ability to cope under pressure.
[0009] 2. The model learns the ability to provide seated training through fine-tuning. Model fine-tuning, by updating model parameters, can fundamentally change the behavior of a large model. Currently, supervised fine-tuning (SFT) with efficient parameter tuning such as LoRa is the mainstream model fine-tuning method. In the context of government hotlines, fine-tuning data typically includes transcribed texts of historical call recordings, typical complaint cases, standard response scripts, and emotion classification corpora. By cleaning, labeling, and structuring this high-quality, task-oriented data, a training set for fine-tuning is constructed. During the fine-tuning process, the model not only learns how to simulate citizen roles but also distinguishes different complaint types (such as inquiries, complaints, suggestions, and requests for help) according to the training objectives, and generates dialogue content with logical structure, emotional depth, and linguistic diversity.
[0010] In the context of government hotline scenarios, when using prompt word engineering to build the ability to provide dialogue support for agents, the model itself is stimulating the ability to simulate dialogue under specific conditions. This ability to follow instructions is learned by the model during the instruction fine-tuning stage and the RLHF stage after the large model is pre-trained. In this stage, most of the training data involves the model acting as an assistant to respond to the user's specified requirements in a way that meets expectations. Therefore, the ability learned by the model is to generate content from the perspective of answering questions. However, in the context of dialogue support for agents in government hotlines, when the model interacts with agents from the perspective of a citizen, it is often the one asking the question rather than the one providing the answer. There are even application needs in scenarios where emotions or remarks are too extreme. At this time, due to the inconsistency between training and application modes, the model is prone to problems such as illusion, bias, and prompt leakage.
[0011] Meanwhile, there are also many challenges in building call center coaching capabilities using fine-tuning. First, high-quality labeled data is scarce. Dialogue data in real-world scenarios often requires a lot of manual labeling and verification work, which is costly and difficult to guarantee label consistency. Second, supervised fine-tuning, especially full-parameter fine-tuning, places great demands on hardware storage, bandwidth, and computing power if full-parameter fine-tuning is performed for a large number of coaching scenarios. Third, even if LoRa fine-tuning can alleviate the problem of limited resources, it will lead to insufficient generalization ability. In the scenario of coaching government hotlines, the model needs to simulate citizens in various call situations. If there are situations that have not been trained, inaccurate performance and overfitting are likely to occur. Summary of the Invention
[0012] This invention addresses the shortcomings of existing technologies by providing a method, device, and medium for constructing an adaptive large-scale model for agent training in government hotline scenarios. Through an automatic switching mechanism for prompt words and parameter matrices, it achieves adaptive switching between fine-tuning model construction and prompt word engineering for building a large-scale model for agent training. When encountering new training scenarios, prompt word engineering is used. A prompt word construction method adapted to agent training scenarios significantly alleviates problems such as illusions, deviations, and leaks in the model, allowing the overall system to be deployed quickly. This enables rapid collection of training dialogue information that fits the actual scenario. Furthermore, a data validity processing algorithm achieves automatic annotation and filtering of real-world data, solving the problem of high-quality labeled data and high manual costs required for model fine-tuning. The LoRa fine-tuning method is chosen to address the issue of large amounts of data and computing power required for model fine-tuning. Simultaneously, the adaptive switching mechanism solves the problem of insufficient generalization ability that can occur when relying solely on model fine-tuning.
[0013] To achieve the above objectives, the present invention adopts the following technical solution: A method for building an adaptive large-scale model for agent training in a government hotline scenario includes the following steps: S1. Configure the government hotline training scenario and citizen role information; S2. Based on the scene and citizen role information, through retrieval enhancement generation, adaptively select whether to use the LoRa parameter matrix or the prompt words to stimulate the large model's seated training ability. S3. Based on the set scene information and citizen information, generate prompt words for the input model according to the prompt word template; S4. The large model generates training content based on the prompts, and the agents interact with the large model as users. S5. Collect data during the interaction between users and the large model through a feedback collection mechanism; S6. Automatically filter and label the data collected during the interaction process to obtain dialogue data that meets the requirements; S7. Construct a training dataset based on dialogue data, and use it to fine-tune the large model with LoRa to obtain a trained large model for use as a seated tutor.
[0014] To optimize the above technical solution, the specific measures also include: Furthermore, S1 specifically refers to: S101. Configure scenario information for government hotline tutoring, including environmental information, event information, rules to be followed, and relevant policy information; S102. Configure the citizen role information for the training partner, including the citizen's name, address, reason for calling, and preset mood.
[0015] Furthermore, S2 specifically includes: S201. For each LoRa parameter matrix in the model library, perform text embedding and index construction on the corresponding scene description information to form an adaptation scene description library. Based on the training scenario information and role information configured in S1, a query is formed. ; S202. Use the Faiss tool to perform similarity retrieval and obtain the query. With Adaptation Scene Description Library The Middle Cosine semantic similarity score of scene description information ; S203, Calculate the query using the BM25 algorithm. For the adaptation scenario description library The correlation was obtained. and The Middle Relevance score of scene description information ; S204, Regarding the correlation score Z-score standardization is performed, and then the standardized score is mapped to the [0,1] interval using the Sigmoid function to obtain the normalized correlation score. ; S205. The cosine semantic similarity score and the normalized relevance score are linearly weighted and fused, as shown in the following formula:
[0016] In the formula, It is the fusion score of the i-th scene description information. It is the weight of the cosine semantic similarity score. It is the weight of the normalized correlation score; Based on fusion score The k scene descriptions with the highest fusion scores are selected as the candidate scene description set. S206. Combine the configured training scenarios, citizen role information, and candidate scenario description set into the input of the large model according to the prompt word template; S207. Extract the selection result from the response content of the large model. If it is 0, it means that the existing adaptation scenario description library is not suitable for the current training scenario. In this case, the pure prompt words are used to stimulate the training ability of the large model. If it is a sequence number from 1 to k, the Lora parameter matrix corresponding to the sequence number is used.
[0017] Furthermore, in S3, the content of the prompt word template includes system prompt words and user input. The system prompt words include role, user personal information, dialogue purpose, goal, dialogue strategy, identity constraints, content constraints, format constraints, end constraints, and output requirements.
[0018] Furthermore, the specific steps of S4 are as follows: The content generated by the large model based on the prompt words is used as the dialogue to communicate with the agent, thus enabling interaction with the agent. Based on the agent's response, prompts are reconstructed to obtain new content generated by the large model. This process is repeated until the large model or one of the agents actively stops the conversation.
[0019] Furthermore, the specific steps of S5 are as follows: S501. Through the feedback collection mechanism, collect the dialogue content between the user and the large model, as well as other information about the user during the interaction process, including: response time and number of dialogue rounds; S502. Create a candidate dialogue dataset by combining the content of each dialogue with the relevant scenarios, response times, and number of dialogue turns. .
[0020] Furthermore, S6 specifically includes: S601. Analyze the candidate dialogue dataset based on response time and dialogue rounds. Perform preliminary validity screening, filtering data with more than 3 rounds of dialogue and an average user response time of more than 6 seconds; S602. Using a structured prompting word scheme, data filtering prompting words are compiled, allowing the large model to determine whether each set of dialogue data meets the requirements based on the description of the training scenario. This enables a re-filtering of the dialogue dataset obtained from the initial screening, thereby obtaining dialogue data for fine-tuning the training capabilities of the large model's agent training.
[0021] Furthermore, S7 specifically includes: S701. Construct prompt words, allowing the large model to filter dialogue data based on these prompt words. Constructing a training dataset ; S702. Compile data augmentation prompts, allowing the large model to augment the training dataset based on these prompts. The data from the large model generating citizen statements is augmented to obtain an enhanced training dataset. ; S703, according to The size of the data volume determines whether LoRa tuning should be enabled; S704. The large model, after being fine-tuned with LoRa, generates a summary description of its suitable scene based on the scene description of the enhanced training data. This summary description serves as the metadata of the LoRa parameter matrix and is stored in the model library along with the large model. It is used in S2 for adaptive selection of the large model.
[0022] The present invention also proposes an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the method described above for constructing an adaptive large-model call center agent training capability in the context of a government hotline.
[0023] The present invention also proposes a computer-readable storage medium storing a computer program that enables a computer to execute the method described above for constructing an adaptive large-scale model of call center agent training capabilities in a government hotline scenario.
[0024] The beneficial effects of this invention are: (1) A method for constructing prompts and data to replace dialogue in a seated tutoring scenario is proposed. Instead of using the traditional method of having the model play a certain role in system prompts to stimulate the large model's ability to act as a citizen and engage in dialogue with the agent, the default "user / assistant" mode of the large model is used. This maintains the consistency between the training ability and the original question and answer, thereby avoiding problems such as model prompt leakage and role illusion. At the same time, the entire system based on the large model's agent training ability can achieve initial deployment and data collection and accumulation in various scenarios without the need for tedious manual preparation in the early stages.
[0025] Meanwhile, the dialogue data collected subsequently is also used to construct fine-tuned training data, thereby further improving the model's ability to practice dialogue.
[0026] (2) A data validation algorithm is proposed. This algorithm integrates expert rules and the understanding and judgment capabilities of large models, and can automatically perform validity analysis on the collected dialogue data, thereby filtering out high-quality dialogue data suitable for model fine-tuning and saving a lot of manual input in data annotation.
[0027] (3) An adaptive switching mechanism for prompt words and parameter matrices is proposed. Based on the fine-tuning data, a corresponding capability application scenario description is automatically generated for each parameter matrix obtained through LoRa fine-tuning. At the same time, corresponding descriptions are generated for prompt words in various scenarios, forming an adaptation scenario description library. When training is enabled, the large model is allowed to autonomously determine which parameter matrix or prompt word to use by combining the retrieval enhancement generation method. For scenarios that have not been trained, prompt word engineering will be selected to solve the problem of low generalization in LoRa fine-tuning.
[0028] The combination of the above three points forms an adaptive method for building large-scale model-based call center assistant training capabilities. This method can effectively combine the advantages of prompt word engineering and model fine-tuning when applying large-scale models to call center assistant training in government hotline scenarios, while also avoiding and solving the shortcomings of the two strategies through the above-mentioned innovations. Attached Figure Description
[0029] Figure 1 This is a flowchart illustrating the overall process of building an adaptive large-scale model for call center agent training in government hotline scenarios. Detailed Implementation
[0030] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.
[0031] Example 1 This invention proposes a method for constructing an adaptive large-scale model for agent training in government hotline scenarios. The process of this method is as follows: Figure 1 As shown, it includes the following steps: S1. Configure the government hotline tutoring scenario and citizen role information; S1 specifically includes: S101. Configure scenario information for government hotline tutoring, including environmental information, event information, rules to be followed, and relevant policy information; S102. Configure the citizen role information for the training partner, including the citizen's name, address, reason for calling, and preset mood.
[0032] S2. Based on the scene and citizen role information, through retrieval-enhanced generation, adaptively select whether to use the LoRa parameter matrix or prompt words to stimulate the large model's agent training capabilities; S2 specifically includes: S201. For each LoRa parameter matrix in the model library, perform text embedding and index construction on the corresponding scene description information to form an adaptation scene description library. Based on the training scenario information and role information configured in S1, a query is formed. ; S202. Use the Faiss tool to perform similarity retrieval and obtain the query. With Adaptation Scene Description Library The Middle Cosine semantic similarity score of scene description information ; S203, Calculate the query using the BM25 algorithm. For the adaptation scenario description library The correlation was obtained. and The Middle Relevance score of scene description information ; S204, Regarding the correlation score Z-score standardization is performed, and then the standardized score is mapped to the [0,1] interval using the Sigmoid function to obtain the normalized correlation score. ; S205. The cosine semantic similarity score and the normalized relevance score are linearly weighted and fused, as shown in the following formula:
[0033] In the formula, It is the fusion score of the i-th scene description information. It is the weight of the cosine semantic similarity score. It is the weight of the normalized correlation score; Based on fusion score The k scene descriptions with the highest fusion scores are selected as the candidate scene description set. S206. Combine the configured training scenarios, citizen role information, and candidate scenario description set into the input of the large model according to the prompt word template; the specific prompt word template is as follows:
[0034] S207. Extract the selection result from the large model's response. If it's 0, it means the existing adaptation scenario description library is not suitable for the current training scenario, so pure prompt words are used to stimulate the large model's training ability. If it's a sequence number from 1 to k, the corresponding Lora parameter matrix is used. An inference framework such as vLLM, which supports dynamic loading of the Lora parameter matrix, is used to achieve adaptive hot switching of different capabilities.
[0035] S3. Following the set scene information and citizen information, generate prompts for the input model according to the prompt template; In S3, the content of the prompt template includes system prompts and user input, and the system prompts include role, user personal information, dialogue purpose, goal, dialogue strategy, identity constraints, content constraints, format constraints, end constraints and output requirements.
[0036] Construct prompts for inputting large models using the following template:
[0037]
[0038] In the above content, the system prompts, "{Personal Information}" and "{Scene Information}," represent the requirements for the model, acting as a citizen, to engage in dialogue with the agent in different training scenarios. The user input section requires concatenating the multi-turn dialogue between the agent and the citizen represented by the model.
[0039] Currently, the mainstream large-scale models are all based on " <system>The model input is constructed using a paradigm like "+system prompt + user + user's first round of input + assistant + large model's first round of response + ... + assistant". This shows that if the model is assigned a role in the system prompt section as is commonly done, the user input is simply dialogue. In a government service training scenario, the model needs to understand that it acts as an assistant, behaving like a citizen asking questions—a behavior typically performed by the user. Conversely, the user input is the actual agent's response. In this scenario, the input is structured as assistant asking and user answering. However, the training data during instruction fine-tuning and RLHF phases often consists of assistant answering user questions. This complete reversal of role behavior is the root cause of illusion problems such as role deviation and prompt leakage in the model.
[0040] Therefore, this step uses a cue word construction method to replace the dialogue. The assistant role of the large model is still to answer questions, but the content of the answer is to speak on behalf of the user. The user part is to package the dialogue record between the agent and the model and ask questions, requiring the large model to answer what kind of words to use to reply based on the chat content. This solves the problem that the role's position and behavior are inconsistent with the interaction mode of the large model during training, and avoids hallucinations during training.
[0041] S4. The large model generates practice content based on the prompts, and the agent interacts with the large model as the user. The specific steps of S4 are as follows: The content generated by the large model based on the prompt words is used as the dialogue to communicate with the agent, thus enabling interaction with the agent. Based on the agent's response, prompts are reconstructed to obtain new content generated by the large model. This process is repeated until the large model or one of the agents actively stops the conversation.
[0042] S5. Collect data on the interaction process between users and the large model through a feedback collection mechanism; the specific steps of S5 are as follows: S501. Through the feedback collection mechanism, collect the dialogue content between the user and the large model, as well as other information about the user during the interaction process, including: response time and number of dialogue rounds; S502. Create a candidate dialogue dataset by combining the content of each dialogue with the relevant scenarios, response times, and number of dialogue turns. .
[0043] S6. Automatically filter and label the data collected during the interaction process to obtain dialogue data that meets the requirements; S6 specifically includes: S601. Analyze the candidate dialogue dataset based on response time and dialogue rounds. Perform preliminary validity screening, filtering data with more than 3 rounds of dialogue and an average user response time of more than 6 seconds; S602. Using a structured prompting word scheme, data filtering prompting words are compiled, allowing the large model to determine whether each set of dialogue data meets the requirements based on the description of the training scenario. This enables a re-filtering of the dialogue dataset obtained from the initial screening, thereby obtaining dialogue data for fine-tuning the training capabilities of the large model's agent training.
[0044] S7. Construct a training dataset based on dialogue data, and use it to fine-tune the large model with LoRa to obtain a trained large model for agent training. S7 specifically includes: S701. Construct prompt words in S3 to replace the dialogue format, allowing the large model to filter the dialogue data based on the prompt words. Constructing a training dataset ; S702. Compile data augmentation prompts, allowing the large model to augment the training dataset based on these prompts. The data from the large model generating citizen statements is augmented to obtain an enhanced training dataset. Based on the experimental results, generating 3-5 similar data points from each dialogue often yields higher quality data.
[0045] S703, according to The size of the data volume determines whether to enable LoRa tuning; based on experimental test results, for the Qwen3-32b model, when When the amount of data reaches 30,000 tokens, LoRa fine-tuning can be quite effective, and of course, the more data there is, the better the effect.
[0046] S704. The large model, after being fine-tuned with LoRa, generates a summary description of its suitable scene based on the scene description of the enhanced training data. This summary description serves as the metadata of the LoRa parameter matrix and is stored in the model library along with the large model. It is used in S2 for adaptive selection of the large model.
[0047] Example 2 This invention proposes an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the method for constructing an adaptive large-model call center agent training capability in the government hotline scenario as described in Embodiment 1.
[0048] Example 3 This invention proposes a computer-readable storage medium storing a computer program that enables a computer to execute a method for constructing an adaptive large-model call center agent training capability in a government hotline scenario, as described in Embodiment 1.
[0049] In the embodiments disclosed in this application, a computer storage medium may be a tangible medium that may contain or store programs for use by or in conjunction with an instruction execution system, apparatus, or device. The computer storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of computer storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0050] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed in this application can be implemented in electronic hardware or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0051] The above are merely preferred embodiments of the present invention. The scope of protection of the present invention is not limited to the above embodiments. All technical solutions falling within the scope of the present invention's concept are within the scope of protection of the present invention. It should be noted that for those skilled in the art, any improvements and modifications made without departing from the principles of the present invention should be considered within the scope of protection of the present invention.< / system>
Claims
1. A method for constructing an adaptive large-scale model for agent training in a government hotline scenario, characterized in that, Includes the following steps: S1. Configure the government hotline training scenario and citizen role information; S2. Based on the scene and citizen role information, through retrieval enhancement generation, adaptively select whether to use the LoRa parameter matrix or the prompt words to stimulate the large model's seated training ability. S3. Based on the set scene information and citizen information, generate prompt words for the input model according to the prompt word template; S4. The large model generates training content based on the prompts, and the agents interact with the large model as users. S5. Collect data during the interaction between users and the large model through a feedback collection mechanism; S6. Automatically filter and label the data collected during the interaction process to obtain dialogue data that meets the requirements; S7. Construct a training dataset based on dialogue data, and use it to fine-tune the large model with LoRa to obtain a trained large model for use as a seated tutor.
2. The method for constructing adaptive large-scale model-based agent training capabilities in a government hotline scenario as described in claim 1, characterized in that, S1 specifically refers to: S101. Configure scenario information for government hotline tutoring, including environmental information, event information, rules to be followed, and relevant policy information; S102. Configure the citizen role information for the training partner, including the citizen's name, address, reason for calling, and preset mood.
3. The method for constructing adaptive large-scale model agent training capabilities in the government hotline scenario as described in claim 1, characterized in that, S2 specifically includes: S201. For each LoRa parameter matrix in the model library, perform text embedding and index construction on the corresponding scene description information to form an adaptation scene description library. Based on the training scenario information and role information configured in S1, a query is formed. ; S202. Use the Faiss tool to perform similarity retrieval and obtain the query. With Adaptation Scene Description Library The Middle Cosine semantic similarity score of scene description information ; S203, Calculate the query using the BM25 algorithm. For the adaptation scenario description library The correlation was obtained. and The Middle Relevance score of scene description information ; S204, Regarding the correlation score Z-score standardization is performed, and then the standardized score is mapped to the [0,1] interval using the Sigmoid function to obtain the normalized correlation score. ; S205. The cosine semantic similarity score and the normalized relevance score are linearly weighted and fused, as shown in the following formula: In the formula, It is the fusion score of the i-th scene description information. It is the weight of the cosine semantic similarity score. It is the weight of the normalized correlation score; Based on fusion score The k scene descriptions with the highest fusion scores are selected as the candidate scene description set. S206. Combine the configured training scenarios, citizen role information, and candidate scenario description set into the input of the large model according to the prompt word template; S207. Extract the selection result from the response content of the large model. If it is 0, it means that the existing adaptation scenario description library is not suitable for the current training scenario. In this case, the pure prompt words are used to stimulate the training ability of the large model. If it is a sequence number from 1 to k, the Lora parameter matrix corresponding to the sequence number is used.
4. The method for constructing adaptive large-scale model-based agent training capabilities in a government hotline scenario as described in claim 1, characterized in that... In S3, the content of the prompt word template includes system prompt words and user input. The system prompt words include role, user personal information, dialogue purpose, goal, dialogue strategy, identity constraints, content constraints, format constraints, end constraints, and output requirements.
5. The method for constructing adaptive large-scale model-based agent training capabilities in a government hotline scenario as described in claim 1, characterized in that, The specific steps for S4 are as follows: The content generated by the large model based on the prompt words is used as the dialogue to communicate with the agent, thus enabling interaction with the agent. Based on the agent's response, prompts are reconstructed to obtain new content generated by the large model. This process is repeated until the large model or one of the agents actively stops the conversation.
6. The method for constructing adaptive large-scale model-based agent training capabilities in a government hotline scenario as described in claim 1, characterized in that, The specific steps for S5 are as follows: S501. Through the feedback collection mechanism, collect the dialogue content between the user and the large model, as well as other information about the user during the interaction process, including: response time and number of dialogue rounds; S502. Create a candidate dialogue dataset by combining the content of each dialogue with the relevant scenarios, response times, and number of dialogue turns. .
7. The method for constructing adaptive large-scale model-based agent training capabilities in a government hotline scenario as described in claim 1, characterized in that, S6 specifically includes: S601. Analyze the candidate dialogue dataset based on response time and dialogue rounds. Perform preliminary validity screening, filtering data with more than 3 rounds of dialogue and an average user response time of more than 6 seconds; S602. Using a structured prompting word scheme, data filtering prompting words are compiled, allowing the large model to determine whether each set of dialogue data meets the requirements based on the description of the training scenario. This enables a re-filtering of the dialogue dataset obtained from the initial screening, thereby obtaining dialogue data for fine-tuning the training capabilities of the large model's agent training.
8. The method for constructing adaptive large-scale model agent training capabilities in the government hotline scenario as described in claim 1, characterized in that, S7 specifically includes: S701. Construct prompt words, allowing the large model to filter dialogue data based on these prompt words. Constructing a training dataset ; S702. Compile data augmentation prompts, allowing the large model to augment the training dataset based on these prompts. The data from the large model generating citizen statements is augmented to obtain an enhanced training dataset. ; S703, according to The size of the data volume determines whether LoRa tuning should be enabled; S704. The large model, after being fine-tuned with LoRa, generates a summary description of its suitable scene based on the scene description of the enhanced training data. This summary description serves as the metadata of the LoRa parameter matrix and is stored in the model library along with the large model. It is used in S2 for adaptive selection of the large model.
9. An electronic device, characterized in that, include: The method for constructing an adaptive large-model call center assistant training capability in a government hotline scenario as described in any one of claims 1-8 includes a memory, a processor, and a computer program stored in the memory and executable on the processor.
10. A computer-readable storage medium storing a computer program, characterized in that, The computer program enables the computer to execute the method for constructing an adaptive large-model seat training capability in the context of a government hotline as described in any one of claims 1-8.