Large model training method and device, function recommendation method and device, equipment and medium

By acquiring sample dialogue information and its corresponding positive and negative sample labels, and using the erroneous recommendation results generated by the initial large model itself to train the large model, the problem of insufficient accuracy of the large model in functional recommendation tasks is solved, and efficient preference alignment and accuracy improvement are achieved.

CN121882271APending Publication Date: 2026-04-17BAIDU COM TIMES TECH (BEIJING) CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
BAIDU COM TIMES TECH (BEIJING) CO LTD
Filing Date
2026-01-07
Publication Date
2026-04-17

AI Technical Summary

Technical Problem

Existing large models lack accuracy in function recommendation tasks and struggle to effectively correct erroneous tendencies, resulting in poor human-computer interaction performance.

Method used

By acquiring sample dialogue information and its corresponding positive and negative sample labels, the initial large model generates incorrect recommendation results as negative sample labels using its own sampling operation, constructs specific positive and negative sample pairs, and trains the initial large model to improve its accuracy in functional recommendation tasks.

Benefits of technology

It significantly improves the accuracy of large models in functional recommendation tasks, achieves efficient preference alignment, corrects the model's erroneous tendencies, and improves the smoothness of human-computer interaction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121882271A_ABST
    Figure CN121882271A_ABST
Patent Text Reader

Abstract

The invention provides a large model training method and device, a function recommendation method and device, equipment and a medium, and relates to the technical field of artificial intelligence, in particular to the technical fields of natural language processing, deep learning, large language models, information recommendation, intelligent agents, intelligent agents and the like. According to the implementation scheme, first sample data are obtained, the first sample data comprise sample dialogue information and corresponding positive sample labels and negative sample labels, and the positive sample labels indicate target function recommendation results determined according to the sample dialogue information; the negative sample label is a function recommendation result which is inconsistent with the positive sample label and is obtained by inputting sample dialogue information into an initial large model to execute sampling operation; and training the initial large model based on the first sample data to obtain a target large model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of artificial intelligence technology, particularly to the fields of natural language processing, deep learning, large language models, information recommendation, intelligent agents, and intelligent agents. Specifically, it relates to a training method for large models, a function recommendation method, an apparatus, an electronic device, a computer-readable storage medium, and a computer program product. Background Technology

[0002] Artificial intelligence (AI) is the study of enabling computers to simulate certain human thought processes and intelligent behaviors (such as learning, reasoning, thinking, and planning). It encompasses both hardware and software technologies. AI hardware technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, and big data processing. AI software technologies mainly include computer vision, speech recognition, natural language processing, machine learning / deep learning, big data processing, and knowledge graph technologies.

[0003] Human-computer interaction (HCI) is a way for humans to interact with machines using natural language. With the continuous development of artificial intelligence technology, machines have become capable of understanding human-generated information, comprehending its inherent meaning, and providing corresponding feedback. In these operations, the accuracy of semantic understanding, the speed of feedback, and the provision of appropriate opinions or suggestions all influence the smoothness of HCI interaction.

[0004] The methods described in this section are not necessarily methods that had been previously conceived or adopted. Unless otherwise specified, no method described in this section should be assumed to be prior art simply because it is included in this section. Similarly, unless otherwise specified, the issues mentioned in this section should not be considered to be accepted in any prior art. Summary of the Invention

[0005] This disclosure provides a method for training large models, a method for recommending features, an apparatus, an electronic device, a computer-readable storage medium, and a computer program product.

[0006] According to one aspect of this disclosure, a method for training a large model is provided, comprising: acquiring first sample data, the first sample data including sample dialogue information and corresponding positive sample labels and negative sample labels, the positive sample labels indicating target function recommendation results determined based on the sample dialogue information, and the negative sample labels being function recommendation results that are inconsistent with the positive sample labels obtained by inputting the sample dialogue information into an initial large model and performing a sampling operation; and training an initial large model based on the first sample data to obtain a target large model.

[0007] According to another aspect of this disclosure, a function recommendation method is provided, comprising: acquiring target dialogue information; and using a target large model to acquire target function recommendation results based on the target dialogue information, wherein the target large model is trained using the large model training method of this disclosure.

[0008] According to another aspect of this disclosure, a training apparatus for a large model is provided, comprising: a first acquisition unit configured to acquire first sample data, the first sample data including sample dialogue information and corresponding positive sample labels and negative sample labels, the positive sample labels indicating target function recommendation results determined based on the sample dialogue information, and the negative sample labels being function recommendation results that are inconsistent with the positive sample labels obtained by inputting the sample dialogue information into an initial large model and performing a sampling operation; and a training unit configured to train the initial large model based on the first sample data to obtain a target large model.

[0009] According to another aspect of this disclosure, a function recommendation apparatus is provided, comprising: a first acquisition unit configured to acquire target dialogue information; and a second acquisition unit configured to acquire target function recommendation results for the target dialogue information using a target large model, wherein the target large model is trained using the large model training method of this disclosure.

[0010] According to another aspect of this disclosure, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the training method for a large model of this disclosure or the function recommendation method of this disclosure.

[0011] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions, wherein the computer instructions are used to cause a computer to execute the training method of the large model of this disclosure or the function recommendation method of this disclosure.

[0012] According to another aspect of this disclosure, a computer program product is provided, including a computer program, wherein the computer program, when executed by a processor, implements the training method for the large model of this disclosure or the function recommendation method of this disclosure.

[0013] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description

[0014] The accompanying drawings exemplify embodiments and form part of the specification, serving together with the textual description to explain exemplary implementations of the embodiments. The illustrated embodiments are for illustrative purposes only and do not limit the scope of the claims. Throughout the drawings, the same reference numerals refer to similar but not necessarily identical elements.

[0015] Figure 1 A schematic diagram of an exemplary system in which the various methods described herein may be implemented according to embodiments of the present disclosure is shown; Figure 2 A flowchart illustrating a training method for a large model according to an embodiment of the present disclosure is shown; Figure 3 A flowchart illustrating the acquisition of recommendation trigger class sample data according to an embodiment of the present disclosure is shown; Figure 4 A flowchart illustrating the acquisition of second sample data according to an exemplary embodiment of the present disclosure is shown; Figure 5 A flowchart illustrating the function of obtaining genuine recommendations according to an embodiment of the present disclosure is shown; Figure 6 A flowchart illustrating the function of obtaining genuine recommendations according to an exemplary embodiment of the present disclosure is shown; Figure 7 A flowchart illustrating a training method for a large model according to an embodiment of the present disclosure is shown; Figure 8 A flowchart illustrating the acquisition of recommendation trigger class sample data and third sample data according to an exemplary embodiment of the present disclosure is shown; Figure 9 A flowchart illustrating the acquisition of recommendation suppression class sample data according to embodiments of the present disclosure is shown; Figure 10 A flowchart illustrating the acquisition of fourth sample data according to an embodiment of the present disclosure is shown; Figure 11 A flowchart illustrating the acquisition of fourth sample data according to an exemplary embodiment of the present disclosure is shown; Figure 12 A flowchart illustrating the training of an initial large model according to an exemplary embodiment of the present disclosure is shown; Figure 13 A flowchart illustrating the training of an initial large model according to an embodiment of the present disclosure is shown; Figure 14 A flowchart illustrating a training method for a large model according to an exemplary embodiment of the present disclosure is shown; Figure 15 A flowchart of a function recommendation method according to an embodiment of the present disclosure is shown; Figure 16 A schematic diagram of a functional recommendation scenario according to an exemplary embodiment of the present disclosure is shown; Figure 17 A structural block diagram of a training apparatus for a large model according to an embodiment of the present disclosure is shown; Figure 18 A structural block diagram of a functional recommendation device according to an embodiment of the present disclosure is shown; Figure 19 A structural block diagram of an exemplary electronic device that can be used to implement embodiments of the present disclosure is shown. Detailed Implementation

[0016] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.

[0017] In this disclosure, unless otherwise stated, the use of terms such as "first," "second," etc., to describe various elements is not intended to limit the positional, temporal, or importance relationships of these elements; such terms are merely used to distinguish one element from another. In some examples, the first element and the second element may refer to the same instance of that element, while in other cases, based on the context, they may refer to different instances.

[0018] The terminology used in the description of the various examples described in this disclosure is for the purpose of describing particular examples only and is not intended to be limiting. Unless the context explicitly indicates otherwise, an element may be one or more unless the number of elements is specifically limited. Furthermore, the term "and / or" as used in this disclosure covers any one of the listed items and all possible combinations thereof.

[0019] The embodiments of this disclosure will now be described in detail with reference to the accompanying drawings.

[0020] Figure 1 A schematic diagram of an exemplary system 100 in which the various methods and apparatus described herein can be implemented according to embodiments of this disclosure is shown. Reference Figure 1 The system 100 includes one or more client devices 101, 102, 103, 104, 105 and 106, a server 120, and one or more communication networks 110 coupling the one or more client devices to the server 120. The client devices 101, 102, 103, 104, 105 and 106 can be configured to execute one or more applications.

[0021] In embodiments of this disclosure, server 120 may run one or more services or software applications that enable the execution of training methods for large models or feature recommendation methods of this disclosure.

[0022] In some embodiments, server 120 may also provide other services or software applications, which may include non-virtual and virtual environments. In some embodiments, these services may be provided as web-based services or cloud services, such as to users of client devices 101, 102, 103, 104, 105 and / or 106 under a Software as a Service (SaaS) model.

[0023] exist Figure 1 In the configuration shown, server 120 may include one or more components that implement the functions performed by server 120. These components may include software components, hardware components, or combinations thereof that can be executed by one or more processors. Users operating client devices 101, 102, 103, 104, 105, and / or 106 can sequentially interact with server 120 using one or more client applications to utilize the services provided by these components. It should be understood that various different system configurations are possible and may differ from system 100. Therefore, Figure 1 This is an example of a system used to implement the various methods described herein, and is not intended to be limiting.

[0024] Users can use client devices 101, 102, 103, 104, 105, and / or 106 to send queries and receive responses generated in response to dialogue messages. The client devices can provide an interface that allows users to interact with them. The client devices can also output information to the user through this interface. Although... Figure 1 Only six client devices are described, but those skilled in the art will understand that this disclosure can support any number of client devices.

[0025] Client devices 101, 102, 103, 104, 105, and / or 106 may include various types of computer devices, such as portable handheld devices, general-purpose computers (such as personal computers and laptops), workstation computers, wearable devices, smart screen devices, self-service terminal devices, service robots, gaming systems, thin clients, various messaging devices, sensors, or other sensing devices. These computer devices can run various types and versions of software applications and operating systems, such as Microsoft Windows, Apple iOS, UNIX-like operating systems, Linux or Linux-like operating systems (such as Google Chrome OS); or include various mobile operating systems, such as Microsoft Windows Mobile OS, iOS, Windows Phone, and Android. Portable handheld devices may include cellular phones, smartphones, tablets, personal digital assistants (PDAs), etc. Wearable devices may include head-mounted displays (such as smart glasses) and other devices. Gaming systems may include various handheld gaming devices, internet-enabled gaming devices, etc. Client devices are capable of executing various applications, such as various internet-related applications, communication applications (such as email applications), short message service (SMS) applications, and can use various communication protocols.

[0026] Network 110 can be any type of network well known to those skilled in the art, and can support data communication using any of a variety of available protocols (including but not limited to TCP / IP, SNA, IPX, etc.). By way of example only, one or more networks 110 can be a local area network (LAN), an Ethernet-based network, a token ring network, a wide area network (WAN), the Internet, a virtual network, a virtual private network (VPN), an intranet, an extranet, a blockchain network, a public switched telephone network (PSTN), an infrared network, a wireless network (e.g., Bluetooth, WIFI), and / or any combination of these and / or other networks.

[0027] Server 120 may include one or more general-purpose computers, special-purpose server computers (e.g., PC (personal computer) servers, UNIX servers, mid-range servers), blade servers, mainframe computers, server clusters, or any other suitable arrangement and / or combination. Server 120 may include one or more virtual machines running a virtual operating system, or other computing architectures involving virtualization (e.g., one or more flexible pools of logical storage devices that can be virtualized to maintain virtual storage devices for servers). In various embodiments, server 120 may run one or more services or software applications that provide the functionality described below.

[0028] The computing unit in server 120 can run one or more operating systems, including any of the aforementioned operating systems and any commercially available server operating system. Server 120 can also run any of a variety of additional server applications and / or middleware applications, including HTTP servers, FTP servers, CGI servers, JAVA servers, database servers, etc.

[0029] In some implementations, server 120 may include one or more applications to analyze and merge data feeds and / or event updates received from users of client devices 101, 102, 103, 104, 105 and / or 106. Server 120 may also include one or more applications to display data feeds and / or real-time events via one or more display devices of client devices 101, 102, 103, 104, 105 and / or 106.

[0030] In some implementations, server 120 can be a server for a distributed system or a server integrated with blockchain. Server 120 can also be a cloud server, or an intelligent cloud computing server or intelligent cloud host with artificial intelligence technology. A cloud server is a host product in the cloud computing service system, designed to address the shortcomings of traditional physical hosts and Virtual Private Server (VPS) services, such as high management difficulty and weak business scalability.

[0031] System 100 may also include one or more databases 130. In some embodiments, these databases may be used to store data and other information. For example, one or more of the databases 130 may be used to store information such as audio files and video files. Databases 130 may reside in various locations. For example, a database used by server 120 may be local to server 120, or it may be located away from server 120 and may communicate with server 120 via a network-based or dedicated connection. Databases 130 may be of different types. In some embodiments, the database used by server 120 may be, for example, a relational database. One or more of these databases may store, update, and retrieve data from and from the databases in response to commands.

[0032] In some embodiments, one or more of the databases 130 may also be used by an application to store application data. The databases used by the application may be of different types, such as key-value stores, object stores, or regular stores supported by a file system.

[0033] Figure 1The system 100 can be configured and operated in various ways to enable the application of the various methods and apparatus described in this disclosure.

[0034] According to embodiments of this disclosure, such as Figure 2 As shown, a method for training a large model is provided, including: step S201, obtaining first sample data, the first sample data including sample dialogue information and corresponding positive sample labels and negative sample labels, the positive sample labels indicating the target function recommendation results determined based on the sample dialogue information, and the negative sample labels being function recommendation results that are inconsistent with the positive sample labels obtained by inputting the sample dialogue information into the initial large model and performing a sampling operation; and step S202, training the initial large model based on the first sample data to obtain the target large model.

[0035] Therefore, by inputting sample dialogue information into the initial large model to be trained to perform sampling operations and filtering out erroneous recommendation results that are inconsistent with the positive sample labels as negative sample labels, specific positive and negative sample pairs are constructed and used for training the initial large model. This allows the model to use its own sampling output to construct negative samples, uncover difficult negative samples that the model currently considers to have a high probability but are actually wrong. This forces the model to distinguish between correct target recommendation results and its own generated erroneous results during training, which can effectively correct the model's error tendencies and achieve efficient preference alignment, thereby significantly improving the accuracy of the large model in performing functional recommendation tasks.

[0036] like Figure 2 As shown in the embodiments of this specification, a training method for a large model is provided. This method mainly aims to optimize the performance of a large model on a functional recommendation task by constructing high-quality preference pair data. The method first executes step S201 to obtain first sample data. The first sample data is the basic material used for subsequent model fine-tuning or preference alignment, and it mainly consists of three core parts: sample dialogue information, positive sample labels, and negative sample labels.

[0037] The aforementioned sample dialogue information essentially serves as the contextual input relied upon by the large model being trained when making recommendation decisions. Specifically, this sample dialogue information can be historical dialogue information generated during past interactions between the user and the large model, carrying the user's intent, needs, and the current dialogue context. In terms of specific forms, sample dialogue information can include a question-and-answer pair (i.e., a user's input command and the model's response) during an intelligent dialogue between the user and the large model, or it can include a sequence of multiple consecutive question-and-answer pairs. The model uses this contextual information to analyze whether the user implicitly has a need for a specific tool or function, thereby deciding whether to make a feature recommendation.

[0038] Regarding the label portion of the first sample data mentioned above, positive and negative sample labels together constitute directional signals guiding model optimization. Positive sample labels refer to the target function recommendation results that the system expects the model to accurately output, determined based on the sample dialogue information. Specifically, a positive sample label can be a specific recommendation function identifier (e.g., "XX function" or "XX tool"), indicating that recommending this function to the user in this dialogue context is accurate and appropriate. A positive sample label can also be an instruction or label indicating no recommendation (e.g., "no recommendation" or "empty character"), representing that the user has no need for the function in this dialogue context, or that there are no candidate functions matching the user's current needs.

[0039] Correspondingly, negative sample labels refer to the erroneous results that the system expects the model to avoid outputting under the same sample dialogue information. In this embodiment, negative sample labels have a specific source, namely, they are obtained by performing a sampling operation on the sample dialogue information input into the initial large model.

[0040] In some embodiments, inputting the sample dialogue information into an initial large model to perform a sampling operation can utilize the reasoning and generation capabilities of the initial large model to be trained to perform prediction and inference based on the input sample dialogue information. During this process, in order to comprehensively uncover potential cognitive biases in the model, and instead of being limited to generating only a single highest-probability result, an exploratory sampling strategy (such as beam search, Top-k sampling, or kernel sampling) is employed to control the initial large model to generate multiple candidate functional recommendation results in parallel or sequentially.

[0041] These candidate results obtained through sampling objectively reflect the initial large model's understanding and decision distribution regarding the sample dialogue information under the current parameter state. Since the model is not yet fully trained, these candidate results often contain a mixture of correct and incorrect decisions. Subsequent steps compare these model-generated candidate results with the "positive sample labels" that serve as the standard answers, accurately identifying prediction paths that the model deems feasible but are actually incorrect. This provides a direct source for constructing high-value negative sample labels. This self-sampling-based negative sample mining method effectively captures fuzzy samples on the model's decision boundary. Compared to randomly selected negative samples, it provides a larger gradient signal during training, thus optimizing the model's parameters more efficiently.

[0042] After constructing the preference data containing the aforementioned information, step S202 is executed to train the initial large model based on the first sample data. Through this training method, the model can learn to increase the probability of generating positive sample labels and decrease the probability of generating negative sample labels when faced with specific sample dialogue information, thereby obtaining a target large model with higher accuracy in functional recommendation tasks.

[0043] Therefore, by inputting sample dialogue information into the initial large model to be trained to perform sampling operations and filtering out erroneous recommendation results that are inconsistent with the positive sample labels as negative sample labels, specific positive and negative sample pairs are constructed and used for training the initial large model. This allows the model to use its own sampling output to construct negative samples, uncover difficult negative samples that the model currently considers to have a high probability but are actually wrong. This forces the model to distinguish between correct target recommendation results and its own generated erroneous results during training, which can effectively correct the model's error tendencies and achieve efficient preference alignment, thereby significantly improving the accuracy of the large model in performing functional recommendation tasks.

[0044] In some embodiments, the first sample data may include at least one of recommendation triggering sample data and recommendation suppression sample data. The target function recommendation result corresponding to the recommendation triggering sample data includes the recommended function determined based on the sample dialogue information, and the target function recommendation result corresponding to the recommendation suppression sample data includes a recommendation suppression label used to indicate that no function recommendation is made based on the sample dialogue information.

[0045] Therefore, by introducing recommendation trigger sample data and recommendation inhibition sample data, the initial large model not only learns the recommendation function that should be output for specific sample dialogue information, but also learns the ability to output recommendation inhibition labels when it is not suitable for recommendation. This not only improves the recall rate of the target function recommendation results, but also effectively prevents over-recommendation and achieves precise control over the boundary of the model's recommendation behavior.

[0046] In some embodiments, such as Figure 3As shown, the acquisition of recommendation trigger class sample data may include: step S301, acquiring second sample data, wherein the second sample data includes first real dialogue information from the internet and real recommendation functions corresponding to the first real dialogue information, and the second sample data is associated with positive interactive feedback generated by users for the real recommendation functions; step S302, determining the first real dialogue information and real recommendation functions as sample dialogue information and positive sample labels in the recommendation trigger class sample data, respectively; step S303, inputting the first real dialogue information into the initial large model to perform a first sampling operation to obtain multiple candidate function recommendation results; and step S304, filtering out candidate function recommendation results that are inconsistent with the positive sample labels from the multiple candidate function recommendation results and determining them as negative sample labels in the recommendation trigger class sample data.

[0047] Therefore, by constructing sample data using real online dialogue information that is associated with positive user interaction feedback, the authenticity and high value of the training objectives are ensured.

[0048] In some embodiments, obtaining the second sample data may include: performing functional recommendations based on the first real dialogue information using a first general large model according to preset rules to output real recommended functions; and determining the first real dialogue information and the real recommended functions as the second sample data in response to receiving positive interactive feedback from the user regarding the real recommended functions.

[0049] Therefore, by combining the strong reasoning ability of the first general large model with the constraint ability of preset rules to generate realistic recommendation functions, and using positive user interaction feedback as the final confirmation, the second sample data used to construct the recommendation trigger class sample data has extremely high quality and confidence, providing a reliable data foundation for the training of the initial large model and reducing training bias caused by low-quality data.

[0050] In some embodiments, the acquisition of the second sample data can rely on real online business scenarios. During actual dialogue interaction, the user first initiates a conversation and sends a query. The large dialogue model used to generate response information responds to the query and generates corresponding text response information. To determine whether the current dialogue context is suitable for recommending a specific function, the system concatenates or combines the user's query and the response information generated by the large model, inputting them as "first real dialogue information" into a general large model specifically used for function recommendation decisions.

[0051] In some embodiments, the general-purpose model may operate under the guidance of preset prompts when making recommendation decisions. The prompts explicitly instruct the general-purpose model to analyze the current dialogue semantics, user intent, and context, and require it to select the most suitable recommended function from a predefined set of multiple candidate functions; or, if it is determined that no recommendation is needed or there is no matching function, it instructs it to select a function not to recommend.

[0052] Once the general-purpose model outputs a specific, realistic recommendation function, the system will display this function to the user on the front-end interface. The user can then click on the recommendation function to use it. The system can record the aforementioned real dialogue information, real recommendation functions, and user feedback behavior in a log, and only the real dialogue information and real recommendation functions containing positive interactive feedback such as clicks and usage will be identified as the second sample data. This process ensures that the data used for training not only comes from the inference of the powerful general-purpose model, but has also been verified by the behavior of real users, possessing extremely high confidence.

[0053] In some embodiments, such as Figure 4 As shown, based on the first real dialogue information, the first general large model is used to perform function recommendation according to preset rules to output the real recommendation function. This can include performing the following operations using the first general large model: Step S401, identifying the input modality of the first real dialogue information; Step S402, in response to identifying that the input modality contains a non-text modality, identifying the processing requirements corresponding to the non-text modality; Step S403, in response to identifying that the input modality is a pure text modality, analyzing the semantic scene corresponding to the first real dialogue information; and Step S404, based on the processing requirements or semantic scene, determining the real recommendation function from a number of preset candidate functions.

[0054] Figure 5 A flowchart illustrating the function of obtaining genuine recommendations according to an exemplary embodiment of this disclosure is shown.

[0055] In some exemplary embodiments, see Figure 5 Based on the first real dialogue information, the first general model can be used to perform function recommendations according to preset rules. This can be done by using a first general model with a large parameter scale and strong understanding ability (such as a teacher model), through prompt word injection, combined with preset function filtering rules, to conduct in-depth analysis of the user's historical interaction data to determine the most matching real recommendation function.

[0056] See Figure 5First, a general large model can be used to identify the input modality of the first real dialogue information. The prompt words will guide the model to first determine whether there are other modal inputs besides plain text in the current one or more rounds of dialogue context, such as whether the user has uploaded image files or document files, or whether there are images in the reply information, etc.

[0057] In response to the recognition that the input modality contains a non-textual modality, the prompt word guides the model to further identify the processing requirements corresponding to the non-textual modality. See also Figure 5 When the input is an image, the model analyzes the user's intended command, such as the need to dynamically process the image or to beautify or modify it.

[0058] Upon recognizing the input modality as plain text, prompts guide the model to analyze the semantic context corresponding to the first real dialogue information. See also... Figure 5 When the input is only text, the first general model will analyze the current context based on the prompt words, such as the scenario of writing on professional and rigorous topics.

[0059] Finally, prompts guide the model to determine the true recommended function from multiple pre-defined candidate functions based on processing needs or semantic scenarios. The first general model performs semantic matching between the "user's current scenario / need" analyzed above and the "function description scenario" in the predefined function list. If a match is successful, the corresponding function identifier is output as the true recommended function.

[0060] For example, if a user expresses a need for dynamic image processing, video generation features can be recommended; if a user expresses a need for image enhancement or retouching, image editing features can be recommended; and if a user expresses a need for format conversion, presentation generation features can be recommended. Furthermore, if the model analyzes that the current scenario requires structured content presentation, presentation generation features can be recommended; and if the model analyzes that the user's conversation involves writing on professional and rigorous topics (such as official document writing or writing scenarios with extremely high requirements for the credibility of materials), professional writing assistance features can be recommended.

[0061] Therefore, by identifying the processing requirements corresponding to the input modality, the non-text modality, and the semantic scenarios corresponding to the pure text modality, fine-grained parsing of user intent in the first real dialogue information is achieved. This hierarchical processing logic ensures that under complex multimodal inputs and diverse semantic scenarios, the first general-purpose model can accurately match the real recommendation function that meets the user's actual needs, further improving the accuracy and coverage of the training samples.

[0062] In some embodiments, in response to receiving positive interactive feedback from the user regarding the authentic recommendation function, determining the first authentic dialogue information and the authentic recommendation function as the second sample data may include: in response to receiving positive interactive feedback from the user regarding the authentic recommendation function, inputting the first authentic dialogue information and the authentic recommendation function into a large-scale verification model to verify whether the first authentic dialogue information and the authentic recommendation function match based on the large-scale verification model; and in response to verifying that the first authentic dialogue information and the authentic recommendation function match, determining the first authentic dialogue information and the authentic recommendation function as the second sample data.

[0063] Therefore, by introducing a large-scale verification model to perform semantic matching verification of the first real dialogue information and the real recommendation function based on positive user interaction feedback, it is possible to effectively filter out noisy data (such as user misoperation or irrational random interaction) that do not match the actual content, even though there are user clicks. This greatly improves the purity of the second sample data, thereby improving the training efficiency and effect of the initial large-scale model.

[0064] Figure 6 A flowchart illustrating the acquisition of second sample data according to an exemplary embodiment of the present disclosure is shown.

[0065] Although the aforementioned steps have filtered out data that generates positive user interaction feedback (such as clicks), from a data quality assessment perspective, user behavior data may still contain noise such as misoperations or irrational interactions. Therefore, in some embodiments, see... Figure 6 After obtaining the first real dialogue information and real recommendation function with positive user interaction feedback, instead of directly confirming the first real dialogue information and real recommendation function as the final training samples, both can be input into the large verification model to perform the function check step.

[0066] In some embodiments, the validation model can be configured as a strict discriminator by guiding users with pre-designed, highly targeted prompts. The validation model performs deep semantic analysis on the user intent in the first real dialogue input, while simultaneously parsing the functional definition and applicable scenarios of the real recommendation function, thereby determining whether the two are logically highly compatible. For example, if the user dialogue only involves casual conversation, but a click record for outline generation is accidentally generated, the validation model will identify a mismatch between the "casual conversation intent" and the "outline generation function," thus determining that the data is noisy data with unreasonable recommendations.

[0067] In some embodiments, the aforementioned large-scale validation model can be a general-purpose large language model with a large parameter scale and powerful semantic understanding and logical reasoning capabilities. It can be the same model as the first general-purpose large-scale model for generating recommendation functions, or it can be another independent large-scale model that performs well in the discrimination task; there are no restrictions here.

[0068] Ultimately, only when the large validation model outputs a valid result, confirming that the first real dialogue information matches the real recommendation function semantically, will the system identify this pair of data as the second sample data. This dual filtering mechanism (user behavior filtering + model semantic filtering) effectively eliminates noisy data leading to incorrect recommendations, significantly improving the purity of the training data. This ensures that the subsequent initial large model can learn truly high-quality recommendation logic, improving model performance to approach its theoretical upper limit.

[0069] In some embodiments, obtaining the initial large model may include: training a second general large model using second sample data to obtain the initial large model, wherein the parameter size of the first general large model is larger than the parameter size of the second general large model.

[0070] The process of obtaining the aforementioned initial large model is essentially a knowledge distillation or model slimming process based on supervised fine-tuning. To optimize the user experience in practical applications, especially to drastically reduce the inference time of the system during real-time interaction, the embodiments of this disclosure do not directly use the large-scale first general-purpose model as the final online service model. Instead, they adopt a "Teacher-Student" training paradigm. Specifically, the aforementioned first general-purpose model acts as the "teacher model," leveraging its large parameter scale and powerful logical reasoning capabilities to produce high-quality second sample data that has been validated and includes positive user feedback.

[0071] Subsequently, a second general-purpose large model with a smaller parameter size can be selected as the base for the "student model." Here, the parameter size of the first general-purpose large model is significantly larger than that of the second general-purpose large model. Supervised fine-tuning of the second general-purpose large model is performed using the aforementioned second sample data, forcing the small model to fit the distribution of high-quality data generated by the large model. This allows the small model to mimic the recommendation decision-making logic of the large model when handling specific dialogue contexts. In this way, the rich generalization knowledge contained in the large model is effectively transferred to the small model, thereby obtaining the initial large model.

[0072] In some exemplary embodiments, the first general large model can be a general large language model with a parameter scale of 8 billion (8B) (e.g., Qwen3-8B), while the second general large model can be a lightweight large language model with a parameter scale of only 1.7 billion (1.7B) (e.g., Qwen3-1.7B). The initial large model after SFT data distillation (i.e., the fine-tuned Qwen3-1.7B) not only inherits the teacher model's good format compliance ability and high functional recommendation accuracy, but also significantly reduces its inference cost and greatly improves its response speed due to the significant reduction in its parameter count, thus better meeting the low latency requirements of mobile deployment or high-concurrency scenarios.

[0073] Figure 7 A flowchart illustrating the acquisition of sample data according to an exemplary embodiment of the present disclosure is shown.

[0074] like Figure 7 As shown, after obtaining the second sample data through the above method, recommendation trigger class sample data can be further constructed based on the second sample data. Specifically, the first real dialogue information and the real recommendation function in the second sample data can be identified as the sample dialogue information and positive sample label in the recommendation trigger class sample data, respectively.

[0075] Simultaneously, the aforementioned first real dialogue information (and corresponding prompts) can be input into the initial large model to be trained, instructing the initial large model to perform a first sampling operation. This sampling operation is not aimed at obtaining a single optimal solution, but rather at exploring the model's current prediction distribution. See also... Figure 7 In one specific implementation, the first sampling operation may employ a beam search algorithm and set a preset number of sampling times (e.g., 10 sampling times) to instruct the initial large model to generate multiple candidate feature recommendation results in parallel or serially for the same input.

[0076] After obtaining these candidate feature recommendation results, the system compares each of these candidate results generated by the initial large model with the previously determined positive sample labels (i.e., the actual recommended features clicked by the user). If a candidate feature recommendation result is inconsistent with the positive sample label, it indicates that this is a prediction that the model currently considers to have a high probability of success, but is actually incorrect. The system identifies these output results that are inconsistent with the positive sample labels as negative sample labels in the recommendation trigger class sample data. The negative samples mined in this way are "hard negative samples," which accurately expose the model's current cognitive blind spots. Compared to randomly generated negative samples, using these data for training can more efficiently correct the model's erroneous preferences.

[0077] In some embodiments, the second sample data may further include authentic guiding text corresponding to the authentic recommendation function, such as... Figure 8 As shown, the training method of the above-mentioned large model may further include: step S801, performing a second sampling operation using the initial large model based on the first real dialogue information and the real recommendation function to obtain multiple candidate guidance texts; step S802, using the text quality large model, selecting the target guidance text with the worst evaluation quality from the multiple candidate guidance texts and the real guidance texts; and step S803, in response to determining that the target guidance text is not a real guidance text, determining the target guidance text as a negative guidance text and the real guidance text as a positive guidance text, so as to form a third sample data with the first real dialogue information and the real recommendation function; and wherein, training the initial large model based on the first sample data may include: training the initial large model based on the first sample data and the third sample data.

[0078] Therefore, by introducing third-party sample data, the function recommendation task and the guidance copy generation task are jointly trained. In particular, by using the copy quality model to select the target guidance copy with the worst evaluation quality as negative guidance copy, the initial large model can be forced to learn to distinguish between high-quality copy (real guidance copy) and low-quality copy, thereby significantly improving the aesthetic level and user appeal of the guidance copy generated by the target large model, achieving a dual improvement in recommendation accuracy and copy quality.

[0079] In some embodiments, see continue to see Figure 7 Based on the first real dialogue information and the real recommendation function, performing a second sampling operation using the initial large model may include: inputting the first real dialogue information and the corresponding prompt words into the initial large model, instructing it to perform multiple samplings for the same input context. In this embodiment, the second sampling operation may employ a beam search strategy, and the number of samplings may be set to 3 to 4 times, thereby generating a copy pool consisting of multiple candidate guiding texts and real guiding texts.

[0080] Subsequently, a large-scale copywriting quality model can be used to select the target guiding copy with the worst evaluation quality from the copywriting pool. In some embodiments, the large-scale copywriting quality model can be a general-purpose language model with powerful textual aesthetics, logical judgment, and attractiveness evaluation capabilities, configured with specific prompting word engineering. It can be the aforementioned first general-purpose model (teacher model), or other high-parameter models specifically designed for evaluation tasks. Guided by corresponding prompting words, the large-scale copywriting quality model will uniformly rank or score the "multiple candidate guiding copies generated by the model" and the "actual guiding copies actually clicked by users," and select the worst-quality copy, the one that least conforms to user reading habits, or the least attractive, marking it as the target guiding copy.

[0081] Finally, in response to the determination that the target onboarding copy is not the actual onboarding copy, a third sample of data is constructed. This step incorporates a noise filtering mechanism. If the copy quality model determines that the "actual onboarding copy that users actually clicked" is the worst quality among all candidates, this usually means that the user's click behavior for this data is not due to the attractiveness of the copy, but is very likely due to random clicks, accidental touches, or other irrational factors. Therefore, this data is considered noise data and should be discarded directly, not used for training. Conversely, only when the quality of the actual onboarding copy is better than the selected worst copy (i.e., the target onboarding copy is not the actual onboarding copy) will the system identify the actual onboarding copy as positive onboarding copy and the worst target onboarding copy as negative onboarding copy, thus forming the third sample of data used for "onboarding optimization".

[0082] By jointly training the model based on first sample data (feature recommendation) and third sample data (copy generation), the model is forced to not only master accurate recommendation functions, but also distinguish between high-quality and low-quality copy through comparative learning, thereby significantly improving the aesthetic level and user appeal of the generated copy.

[0083] In some exemplary embodiments, see continue to see Figure 5 If the model's analysis reveals that the current context does not match any of the preset candidate functions (i.e., there is no multimodal requirement or specific text scenario), then no function recommendation will be made. This mechanism effectively prevents forced recommendations when the user has no explicit need or when there is no matching function, thus ensuring a good user experience.

[0084] In some embodiments, such as Figure 9 As shown, the acquisition of recommendation suppression sample data may include: step S901, acquiring fourth sample data, wherein the fourth sample data includes second real dialogue information from online sources that has not been recommended to users; step S902, inputting the second real dialogue information into the initial large model to perform a third sampling operation to obtain a preset number of function recommendation results; and step S903, in response to the determination that the number of function recommendation results that are not recommendation suppression labels among the preset number of function recommendation results meets a preset condition, constructing recommendation suppression sample data based on the fourth sample data, wherein the sample dialogue information in the recommendation suppression sample data is the second real dialogue information, the positive sample label of the recommendation suppression sample data is the recommendation suppression label, and the negative sample label of the recommendation suppression sample data is the function recommendation result that is not the recommendation suppression label among the preset number of function recommendation results.

[0085] Therefore, for the second real dialogue information without functional recommendations, recommendation suppression sample data is constructed by detecting the frequency of incorrect functional recommendation results output by the initial large model in multiple sampling operations. This allows for the accurate discovery of erroneous scenarios where the initial large model is prone to over-recall (i.e., recommending when it should not). By using these high-frequency erroneous results as negative sample labels for targeted training, the random recommendation behavior of the target large model in unnecessary scenarios can be effectively suppressed, thus solving the technical problem of "over-recall" in the model.

[0086] In some embodiments, such as Figure 10 As shown, obtaining the fourth sample data may include: step S1001, obtaining the second real dialogue information; step S1002, inputting the second real dialogue information into the verification model to verify whether the second real dialogue information matches any of the preset multiple candidate functions based on the verification model; and step S1003, in response to the verification that the second real dialogue information does not match any of the multiple candidate functions, determining the second real dialogue information as the fourth sample data.

[0087] Therefore, by using a large-scale validation model to verify that the second real dialogue information does not match any of the candidate functions, the accuracy of the positive sample labels (recommendation suppression labels) in the recommendation suppression sample data is ensured. This prevents data that should have been recommended but was not from being mistakenly used as suppression samples for training, thus ensuring that the model's judgment benchmark when learning the "not recommend" ability is correct and maintaining the logical consistency of the training data.

[0088] Figure 11 A flowchart illustrating the acquisition of fourth sample data according to an exemplary embodiment of the present disclosure is shown.

[0089] In some embodiments, the fourth sample data may be derived from the aforementioned online second real dialogue information that was not recommended to the user. In some embodiments, the aforementioned second real dialogue information may be directly determined as the fourth sample data.

[0090] In some embodiments, the second real dialogue information can be first verified and filtered using a large verification model to obtain the fourth sample data. See also Figure 11 Upon obtaining the second real dialogue information, it can first be input into a large-scale validation model. Guided by specific prompts, the validation model analyzes the second real dialogue information to verify whether it matches any of the preset candidate functions. Only when the validation model verifies that the dialogue information does not match any of the candidate functions is the data confirmed to be unnecessary for recommendation, thus identifying it as the fourth sample data. This process filters out samples that might actually match certain functions through the large model, ensuring the logical consistency and label accuracy of the recommendation suppression sample data.

[0091] In some embodiments, in response to acquiring fourth sample data, second real dialogue information can be input into the initial large model to perform a third sampling operation. See also... Figure 11 In order to uncover potential error tendencies in the model, a multiple sampling strategy is adopted here. For example, the data is input into the finely tuned initial large model, and the same input is sampled by beam search a preset number of times (e.g., 10 times) to observe the stability of the model under the current parameters.

[0092] In some embodiments, the number of times the initial large model incorrectly outputs a functional recommendation result (i.e., the result is not a recommendation suppression label) in the above-mentioned preset number of sampling results (e.g., 10 times) can be counted. If the number of times the incorrect output meets the preset condition, for example, if the recommended function is incorrectly output 5 or more times in 10 samplings, it indicates that the model has a high probability of "misrecommending" for this data, and this data belongs to the "hard sample" where the model is very prone to errors. At this time, the system constructs recommendation suppression class sample data based on the fourth sample data, determines the positive sample label as the recommendation suppression label (i.e., no functional recommendation is performed), and determines those incorrectly output functional recommendation results (i.e., the specific recommended functions output) as negative sample labels.

[0093] In some embodiments, the proportions of recommended trigger-type sample data, recommended inhibition-type sample data, and third-type sample data can be determined based on the distribution proportions of real online data.

[0094] In some embodiments, the proportions of recommendation trigger sample data, recommendation suppression sample data, and third-party sample data are not arbitrarily set, but determined based on the distribution proportions of real online data. For example, if in actual online interaction traffic, the vast majority (e.g., 70%) of dialogue scenarios do not actually require feature recommendations (i.e., belong to the "no-recommendation" scenario), then when constructing the training set, the system will correspondingly increase the weight or proportion of recommendation suppression sample data.

[0095] Therefore, by using this precise matching based on the real distribution, the distribution characteristics of the training data are highly consistent with the real business scenario, thereby preventing the model from overfitting on specific tasks (such as overly favoring the recommendation function) and ensuring that the model's decision probability of recommendation or suppression conforms to the real business logic when facing actual traffic.

[0096] Figure 12 A flowchart illustrating the training of an initial large model according to an exemplary embodiment of the present disclosure is shown.

[0097] In some embodiments, see Figure 12After determining the data ratio, these three sets of preference pairs can be mixed and input into the system, and the initial large model can be trained through Direct Preference Optimization (DPO).

[0098] In some embodiments, such as Figure 13 As shown, training the initial large model based on the first sample data may include: step S1301, using the initial large model to obtain the prediction function recommendation results for the sample dialogue information; step S1302, calculating the first loss based on the prediction function recommendation results, positive sample labels, and negative sample labels; step S1303, calculating the second loss based on the prediction function recommendation results and positive sample labels; and step S1304, updating the parameters of the initial large model based on the first loss and the second loss.

[0099] In some embodiments, the initial large model can be trained using a combination of direct preference optimization and supervised fine-tuning. First, the initial large model is used to obtain the prediction function recommendation results based on the sample dialogue information.

[0100] Next, the first loss can be calculated based on the prediction function's recommendation results, positive sample labels, and negative sample labels. In this embodiment, the first loss can specifically be the direct preference optimization loss. Direct preference optimization is an efficient model alignment technique that can directly utilize positive and negative sample pairs to optimize the strategy. Its core logic is to guide the model to increase the probability of generating positive samples while decreasing the probability of generating negative samples by comparing "preference output" (positive sample labels) and "non-preference output" (negative sample labels). Its mathematical expression is as follows:

[0101] in, Represents the preferred positive samples. This represents a non-optimal negative sample. By minimizing this loss, the model can learn a better generation direction.

[0102] Simultaneously, a second loss can be calculated based on the prediction function's recommendation results and positive sample labels. In this embodiment, this second loss is the Supervised Fine-Tuning Loss (SFT Loss), i.e., the standard cross-entropy loss. This loss focuses only on positive samples, aiming to maximize the probability that the model generates the correct labels.

[0103] Finally, the parameters of the initial large model can be updated based on the first and second losses. Specifically, the system uses a weighted sum of the DPO loss and the SFT loss as the final optimization objective to train the initial large model and obtain the target large model.

[0104] Therefore, by combining a first loss based on positive and negative sample labels (usually used for preference alignment) and a second loss based only on positive sample labels (usually used for supervised learning) to update the parameters, the model's discrimination boundary between correct and incorrect results is optimized by utilizing the contrast mechanism, and the model's stability in generating correct results is maintained by the supervision mechanism. This avoids the abnormal decrease in the probability of the model generating positive sample labels during preference alignment, thereby improving the stability of the training process and the robustness of the final model.

[0105] In some embodiments, the training method for the large model described above may further include: performing quantization processing on the target large model, wherein the quantization processing includes processing the activation value distribution of the target large model using a smoothing algorithm and performing channel-level bit-width quantization on the weights of the linear layers in the target large model.

[0106] Therefore, by using a smoothing algorithm to process the distribution of activation values, the accuracy loss caused by outliers in activation values ​​during quantization is effectively alleviated. Combined with channel-level bit-width quantization of linear layer weights, the storage requirements (model size) and inference computation of the target large model are significantly reduced, while the accuracy and performance of the model are preserved to the greatest extent. This enables the high-performance target large model to be adapted to resource-constrained computing environments and improves inference speed.

[0107] In some exemplary embodiments, the above quantization process can follow the W8A8 quantization standard (i.e., both weights and activation values ​​are 8 bits), mainly including key steps such as loading the original model, preparing calibration data, applying the quantization algorithm, and evaluating the quantization effect. In the core step of applying the quantization algorithm, this embodiment adopts a two-stage combined quantization strategy, aiming to balance the model's compression ratio and inference accuracy.

[0108] First, addressing the outlier activation values ​​commonly found in large models, this embodiment utilizes a smoothing algorithm to process the activation value distribution of the target large model. As a specific implementation example, the SmoothQuant algorithm can be used as a preprocessing method. This algorithm, through mathematical transformation, shifts the difficulty of quantization from activation values ​​to weights, thereby smoothing the numerical distribution of activation values, eliminating extreme outliers, making the subsequent quantization process more stable, and effectively mitigating the accuracy collapse problem that may result from direct quantization.

[0109] Subsequently, after smoothing the activation values, the system performs channel-level bit-width quantization on the weights of the linear layers in the target large model. As a specific implementation example, the GPTQ (Gradient-based Post-training Quantization) algorithm can be used to perform layer-by-layer channel-level 8-bit quantization on the linear layers in the model. Compared to coarse-grained layer-level quantization, channel-level quantization can more finely preserve the distribution characteristics of the weight information. Experimental data shows that through the quantization processing combining SmoothQuant and GPTQ, the target large model achieves a reduction in inference time of approximately 25% compared to the previous model, without a significant change in accuracy. This result demonstrates that this scheme significantly reduces the model's storage requirements and computational load while maximizing the preservation of model performance, thus enabling high-performance large models to efficiently adapt to various computing environments.

[0110] Figure 14 A flowchart illustrating a method for training a large model according to an exemplary embodiment of the present disclosure is shown.

[0111] In some exemplary embodiments, such as Figure 14 As shown, the training method for the large model can include the following steps: First, a data accumulation and foundation building step is performed, that is, collecting sample data and user interaction feedback based on the first general large model and preset rules. Then, the model initialization and distillation step is entered, training a second general large model based on the collected sample data to obtain the initial large model. This process typically involves transferring knowledge from the first general large model to the second general large model with a smaller parameter size, giving it preliminary functional recommendation capabilities. After obtaining the initial large model, the core preference alignment and optimization stage begins. This stage first constructs three types of preference pairs, namely, constructing positive and negative sample pairs for recommendation triggers, recommendation inhibition, and guiding copy based on the aforementioned methods. Finally, through a combination of direct preference optimization training and supervised fine-tuning, the initial large model is jointly trained based on these three types of preference pairs to obtain the final target large model.

[0112] In some embodiments, such as Figure 15 As shown, a function recommendation method is also provided, including: step S1501, obtaining target dialogue information; and step S1502, using a target large model to obtain target function recommendation results based on the target dialogue information, wherein the target large model is trained using any of the above-mentioned large model training methods.

[0113] Therefore, by applying the target large model trained based on the above-mentioned large model training method, the accuracy of function recommendations can be greatly improved by making function recommendations to users based on real-time dialogue information during the user's intelligent dialogue process, thereby enhancing the user experience.

[0114] Figure 16 A schematic diagram of a recommended functional scenario is shown according to an exemplary embodiment of the present disclosure.

[0115] In some embodiments, such as Figure 17 As shown, a large model training apparatus 1700 is provided, including: a first acquisition unit 1710 configured to acquire first sample data, the first sample data including sample dialogue information and corresponding positive sample labels and negative sample labels, the positive sample labels indicating the target function recommendation result determined based on the sample dialogue information, and the negative sample labels being function recommendation results that are inconsistent with the positive sample labels obtained by inputting the sample dialogue information into an initial large model and performing a sampling operation; and a training unit 1720 configured to train an initial large model based on the first sample data to obtain a target large model.

[0116] The operations performed by units 1710 and 1720 in the large model training device 1700 and the technical effects they can achieve are similar to steps S201 to S202 in the large model training method, and will not be described in detail here.

[0117] In some embodiments, the first sample data may include at least one of recommendation triggering sample data and recommendation suppression sample data. The target function recommendation result corresponding to the recommendation triggering sample data includes the recommended function determined based on the sample dialogue information, and the target function recommendation result corresponding to the recommendation suppression sample data includes a recommendation suppression label used to indicate that no function recommendation is made based on the sample dialogue information.

[0118] In some embodiments, obtaining recommendation trigger class sample data may include: obtaining second sample data, wherein the second sample data includes first real dialogue information from online sources and real recommendation functions corresponding to the first real dialogue information, and the second sample data is associated with positive interactive feedback generated by users for the real recommendation functions; determining the first real dialogue information and the real recommendation functions as sample dialogue information and positive sample labels in the recommendation trigger class sample data, respectively; inputting the first real dialogue information into an initial large model to perform a first sampling operation to obtain multiple candidate function recommendation results; and selecting candidate function recommendation results that are inconsistent with the positive sample labels from the multiple candidate function recommendation results to determine them as negative sample labels in the recommendation trigger class sample data.

[0119] In some embodiments, obtaining the second sample data may include: performing functional recommendations based on the first real dialogue information using a first general large model according to preset rules to output real recommended functions; and determining the first real dialogue information and the real recommended functions as the second sample data in response to receiving positive interactive feedback from the user regarding the real recommended functions.

[0120] In some embodiments, in response to receiving positive interactive feedback from the user regarding the authentic recommendation function, determining the first authentic dialogue information and the authentic recommendation function as the second sample data may include: in response to receiving positive interactive feedback from the user regarding the authentic recommendation function, inputting the first authentic dialogue information and the authentic recommendation function into a large-scale verification model to verify whether the first authentic dialogue information and the authentic recommendation function match based on the large-scale verification model; and in response to verifying that the first authentic dialogue information and the authentic recommendation function match, determining the first authentic dialogue information and the authentic recommendation function as the second sample data.

[0121] In some embodiments, obtaining the initial large model may include: training a second general large model using second sample data to obtain the initial large model, wherein the parameter size of the first general large model is larger than the parameter size of the second general large model.

[0122] In some embodiments, performing function recommendation based on a first real dialogue information and using a first general large model according to preset rules to output a real recommended function may include: using the first general large model to perform the following operations: identifying the input modality of the first real dialogue information; in response to identifying that the input modality contains a non-text modality, identifying the processing requirements corresponding to the non-text modality; in response to identifying that the input modality is a pure text modality, analyzing the semantic scenario corresponding to the first real dialogue information; and determining the real recommended function from a preset plurality of candidate functions based on the processing requirements or semantic scenario.

[0123] In some embodiments, the second sample data may further include real guidance text corresponding to the real recommendation function, and the training device of the aforementioned large model may further include: a second acquisition unit configured to perform a second sampling operation based on the first real dialogue information and the real recommendation function using an initial large model to obtain multiple candidate guidance texts; a selection unit configured to use a text quality large model to select the target guidance text with the worst evaluation quality from the multiple candidate guidance texts and the real guidance texts; and a determination unit configured to, in response to determining that the target guidance text is not a real guidance text, determine the target guidance text as a negative guidance text and determine the real guidance text as a positive guidance text, so as to form a third sample data with the first real dialogue information and the real recommendation function; and wherein the training unit may be further configured to: train an initial large model based on the first sample data and the third sample data.

[0124] In some embodiments, obtaining recommendation suppression sample data may include: obtaining fourth sample data, wherein the fourth sample data includes second real dialogue information from online sources that has not been recommended to the user; inputting the second real dialogue information into an initial large model to perform a third sampling operation to obtain a preset number of function recommendation results; and in response to the determination that the number of function recommendation results that are not recommendation suppression labels among the preset number of function recommendation results meets a preset condition, constructing recommendation suppression sample data based on the fourth sample data, wherein the sample dialogue information in the recommendation suppression sample data is the second real dialogue information, the positive sample labels of the recommendation suppression sample data are recommendation suppression labels, and the negative sample labels of the recommendation suppression sample data are function recommendation results that are not recommendation suppression labels among the preset number of function recommendation results.

[0125] In some embodiments, obtaining the fourth sample data may include: obtaining second real dialogue information; inputting the second real dialogue information into a large verification model to verify whether the second real dialogue information matches any of a plurality of preset candidate functions based on the large verification model; and in response to the verification that the second real dialogue information does not match any of the plurality of candidate functions, determining the second real dialogue information as the fourth sample data.

[0126] In some embodiments, the proportions of recommended trigger-type sample data, recommended inhibition-type sample data, and third-type sample data can be determined based on the distribution proportions of real online data.

[0127] In some embodiments, the training unit may be further configured to: use an initial large model to obtain prediction function recommendation results for sample dialogue information; calculate a first loss based on the prediction function recommendation results, positive sample labels, and negative sample labels; calculate a second loss based on the prediction function recommendation results and positive sample labels; and update the parameters of the initial large model based on the first loss and the second loss.

[0128] In some embodiments, the training apparatus for the large model may further include: a quantization unit configured to perform quantization processing on the target large model, wherein the quantization processing includes processing the activation value distribution of the target large model using a smoothing algorithm and performing channel-level bit-width quantization on the weights of the linear layers in the target large model.

[0129] In some embodiments, such as Figure 18 As shown, a function recommendation device 1800 is provided, including: a first acquisition unit 1810 configured to acquire target dialogue information; and a second acquisition unit 1820 configured to acquire target function recommendation results for the target dialogue information using a target large model, wherein the target large model is trained using any of the above-mentioned large model training methods.

[0130] The operations performed by units 1810 and 1820 in the aforementioned function recommendation device 1800 and the technical effects they can achieve are similar to steps S1501 to S1502 in the aforementioned function recommendation method, and will not be described in detail here.

[0131] The collection, storage, use, processing, transmission, provision, and disclosure of any type of information, such as user personal information, in this technical solution comply with relevant laws and regulations and do not violate public order and good morals.

[0132] According to embodiments of this disclosure, an electronic device, a readable storage medium, and a computer program product are also provided.

[0133] refer to Figure 19 The present invention describes a structural block diagram of an electronic device 1900 that can serve as a server or client of the present disclosure, which is an example of a hardware device that can be applied to various aspects of the present disclosure. The electronic device is intended to represent various forms of digital electronic computer devices, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0134] like Figure 19 As shown, the electronic device 1900 includes a computing unit 1901, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1902 or a computer program loaded into a random access memory (RAM) 1903 from a storage unit 1908. The RAM 1903 may also store various programs and data required for the operation of the electronic device 1900. The computing unit 1901, ROM 1902, and RAM 1903 are interconnected via a bus 1904. An input / output (I / O) interface 1905 is also connected to the bus 1904.

[0135] Multiple components in electronic device 1900 are connected to I / O interface 1905, including: input unit 1906, output unit 1907, storage unit 1908, and communication unit 1909. Input unit 1906 can be any type of device capable of inputting information to electronic device 1900. Input unit 1906 can receive input digital or character information and generate key signal inputs related to user settings and / or function control of the electronic device, and may include, but is not limited to, a mouse, keyboard, touchscreen, trackpad, trackball, joystick, microphone, and / or remote control. Output unit 1907 can be any type of device capable of presenting information, and may include, but is not limited to, a monitor, speaker, video / audio output terminal, vibrator, and / or printer. Storage unit 1908 may include, but is not limited to, a hard disk and an optical disk. The communication unit 1909 allows the electronic device 1900 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers and / or chipsets, such as Bluetooth devices, 802.11 devices, WiFi devices, WiMax devices, cellular communication devices and / or the like.

[0136] The computing unit 1901 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 1901 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 1901 performs the various methods and processes described above, such as the large model training method or feature recommendation method of this disclosure. For example, in some embodiments, the large model training method or feature recommendation method of this disclosure can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 1908. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 1900 via ROM 1902 and / or communication unit 1909. When the computer program is loaded into RAM 1903 and executed by the computing unit 1901, one or more steps of the large model training method or feature recommendation method of this disclosure described above can be performed. Alternatively, in other embodiments, computing unit 1901 may be configured by any other suitable means (e.g., by means of firmware) to perform the training method or feature recommendation method of the large model of this disclosure.

[0137] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0138] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0139] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, 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 machine-readable 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 fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0140] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0141] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0142] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, servers in distributed systems, or servers incorporating blockchain technology.

[0143] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.

[0144] While embodiments or examples of this disclosure have been described with reference to the accompanying drawings, it should be understood that the methods, systems, and devices described above are merely exemplary embodiments or examples, and the scope of the invention is not limited by these embodiments or examples, but only by the granted claims and their equivalents. Various elements in the embodiments or examples may be omitted or replaced by their equivalents. Furthermore, the steps may be performed in a different order than that described in this disclosure. Further, various elements in the embodiments or examples may be combined in various ways. Importantly, as the technology evolves, many elements described herein can be replaced by equivalents that appear after this disclosure.

Claims

1. A training method for a large model, comprising: Acquire first sample data, which includes sample dialogue information and corresponding positive and negative sample labels. The positive sample label indicates the target function recommendation result determined based on the sample dialogue information. The negative sample label is a function recommendation result that is inconsistent with the positive sample label, obtained by inputting the sample dialogue information into an initial large model and performing a sampling operation. as well as Based on the first sample data, the initial large model is trained to obtain the target large model.

2. The method according to claim 1, wherein, The first sample data includes at least one of recommendation triggering sample data and recommendation suppression sample data. The target function recommendation result corresponding to the recommendation triggering sample data includes the recommended function determined based on the sample dialogue information. The target function recommendation result corresponding to the recommendation suppression sample data includes a recommendation suppression label used to indicate that no function recommendation is made for the sample dialogue information.

3. The method according to claim 2, wherein, The acquisition of the recommendation trigger class sample data includes: Obtain second sample data, wherein the second sample data includes first real dialogue information from the internet and real recommendation function corresponding to the first real dialogue information, and the second sample data is associated with positive interactive feedback generated by users in response to the real recommendation function; The first real dialogue information and the real recommendation function are respectively determined as the sample dialogue information and positive sample label in the recommendation trigger class sample data; The first real dialogue information is input into the initial large model to perform a first sampling operation, thereby obtaining multiple candidate function recommendation results; and The candidate function recommendation results that are inconsistent with the positive sample labels from the multiple candidate function recommendation results are determined as the negative sample labels in the recommendation trigger class sample data.

4. The method according to claim 3, wherein, The acquisition of the second sample data includes: Based on the first real dialogue information, a first general large model is used to perform functional recommendations according to preset rules, so as to output the real recommendation function; and In response to receiving positive interactive feedback from the user regarding the real recommendation function, the first real dialogue information and the real recommendation function are determined as the second sample data.

5. The method according to claim 4, wherein, The step of responding to receiving positive interactive feedback from the user regarding the authentic recommendation function and determining the first authentic dialogue information and the authentic recommendation function as the second sample data includes: In response to receiving positive user feedback regarding the authentic recommendation function, the first authentic dialogue information and the authentic recommendation function are input into a large-scale verification model to verify whether the first authentic dialogue information and the authentic recommendation function match based on the large-scale verification model; and In response to verifying that the first real dialogue information and the real recommendation function match, the first real dialogue information and the real recommendation function are determined as the second sample data.

6. The method according to claim 5, wherein, The acquisition of the initial large model includes: The second general large model is trained using the second sample data to obtain the initial large model, wherein the parameter size of the first general large model is larger than the parameter size of the second general large model.

7. The method according to any one of claims 4 to 6, wherein, The step of performing functional recommendations based on the first real dialogue information and using a first general large model according to preset rules to output the real recommendation function includes: Perform the following operations using the first general large model: Identify the input modality of the first real dialogue information; In response to the recognition that the input modality contains a non-text modality, the processing requirement corresponding to the non-text modality is identified; In response to recognizing the input modality as a plain text modality, the semantic scene corresponding to the first real dialogue information is analyzed; and Based on the processing requirements or the semantic scenario, the actual recommendation function is determined from a set of multiple candidate functions.

8. The method according to any one of claims 3 to 7, wherein, The second sample data also includes authentic guiding text corresponding to the authentic recommendation function, and the method further includes: Based on the first real dialogue information and the real recommendation function, the second sampling operation is performed using the initial large model to obtain multiple candidate guiding texts; Using a large-scale copywriting quality model, the target lead-in copy with the lowest evaluation quality is selected from the multiple candidate lead-in copy and the actual lead-in copy; and In response to determining that the target guidance text is not the real guidance text, the target guidance text is defined as negative guidance text, and the real guidance text is defined as positive guidance text, to form third sample data together with the first real dialogue information and the real recommendation function; and wherein, Training the initial large model based on the first sample data includes: The initial large model is trained based on the first sample data and the third sample data.

9. The method according to any one of claims 2 to 8, wherein, The acquisition of the recommended suppression class sample data includes: Obtain fourth sample data, wherein the fourth sample data includes second real dialogue information from online sources where no function recommendations were made to the user; The second real dialogue information is input into the initial large model to perform a third sampling operation, thereby obtaining a preset number of function recommendation results; and In response to the determination that the number of function recommendation results that are not the recommendation suppression label among the preset number of function recommendation results meets the preset condition, the recommendation suppression class sample data is constructed based on the fourth sample data. The sample dialogue information in the recommendation suppression class sample data is the second real dialogue information, the positive sample label of the recommendation suppression class sample data is the recommendation suppression label, and the negative sample label of the recommendation suppression sample data is the function recommendation result that is not the recommendation suppression label among the preset number of function recommendation results.

10. The method according to claim 9, wherein, The acquisition of the fourth sample data includes: Obtain the second real dialogue information; The second real dialogue information is input into a large-scale verification model to verify whether the second real dialogue information matches any of the preset candidate functions; and In response to the verification that the second real dialogue information does not match any of the multiple candidate functions, the second real dialogue information is determined as the fourth sample data.

11. The method according to claim 8, wherein, The proportions of the recommendation trigger sample data, the recommendation inhibition sample data, and the third sample data are determined based on the distribution proportions of real online data.

12. The method according to any one of claims 1 to 11, wherein, Training the initial large model based on the first sample data includes: Using the initial large model, obtain the prediction function recommendation results for the sample dialogue information; Based on the prediction function recommendation results, the positive sample labels, and the negative sample labels, calculate the first loss; Based on the prediction function's recommendation results and the positive sample labels, a second loss is calculated; and The parameters of the initial large model are updated based on the first loss and the second loss.

13. The method according to any one of claims 1 to 12, further comprising: The target large model is subjected to quantization processing, wherein the quantization processing includes processing the activation value distribution of the target large model using a smoothing algorithm and performing channel-level bit-width quantization on the weights of the linear layers in the target large model.

14. A feature recommendation method, comprising: Obtain target dialogue information; as well as Using a target big model, target function recommendation results are obtained for the target dialogue information, wherein the target big model is trained using the method described in any one of claims 1 to 13.

15. A training device for a large model, comprising: The first acquisition unit is configured to acquire first sample data, which includes sample dialogue information and corresponding positive and negative sample labels. The positive sample label indicates the target function recommendation result determined based on the sample dialogue information, and the negative sample label is a function recommendation result that is inconsistent with the positive sample label, obtained by inputting the sample dialogue information into an initial large model and performing a sampling operation. as well as The training unit is configured to train the initial large model based on the first sample data to obtain the target large model.

16. A function recommendation device, comprising: The first acquisition unit is configured to acquire target dialogue information; as well as The second acquisition unit is configured to acquire target function recommendation results for the target dialogue information using a target large model, wherein the target large model is trained using the method described in any one of claims 1 to 13.

17. An electronic device comprising: At least one processor; as well as A memory that is communicatively connected to the at least one processor; in The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-13.

18. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1-13.

19. A computer program product comprising a computer program, wherein, When the computer program is executed by a processor, it implements the method of any one of claims 1-13.

Citation Information

Cited By

  • A large model calling detection method, device, medium and equipment

    CN122132274A