Content recommendation method, device and electronic device
By retrieving the designated event in the electronic device, and generating personalized prompt words, the problem of lack of personalization of feedback content of the large language model is solved, and the acquisition of personalized recommended content is achieved.
Patent Information
- Application Number
- CN202311297446.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-10-08
- Publication Date
- 2025-04-08
AI Technical Summary
When the existing large language model processes natural language input, the feedback content lacks personalization and cannot meet the personalized needs of users.
By responding to a designated event in the electronic device, personalized data of the target user is obtained, and prompt words are generated based on the data, triggering the large language model to obtain personalized recommended content.
It realizes that when a specified event is triggered, the target user's personalized data is obtained and personalized prompt words are generated, so that the recommended content of the large language model has personalized characteristics and meets the user's personalized needs.
Smart Images

Figure CN119782601A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and more specifically, to a content recommendation method, device and electronic device. Background Art
[0002] With the technological advancement and vigorous development of large language models, large language models can process more complex and diverse natural language inputs, extract key information from them, and perform effective semantic understanding. However, the content fed back by relevant large language models is still relatively lacking in personalization. Summary of the invention
[0003] In view of the above problems, the present application proposes a content recommendation method, device and electronic device to improve the above problems.
[0004] In a first aspect, the present application provides a content recommendation method, which is applied to an electronic device, the method comprising: in response to triggering a specified event, obtaining target personalized data corresponding to the specified event and a target user; generating a prompt word corresponding to the specified event based on the target personalized data;
[0005] The large language model is triggered to obtain recommended content corresponding to the designated event based on the prompt word; and the recommended content is displayed.
[0006] In a second aspect, the present application provides a content recommendation device that runs on an electronic device, the device comprising: a personalized data acquisition unit, for acquiring target personalized data corresponding to the designated event and the target user in response to triggering a designated event; a prompt word determination unit, for generating a prompt word corresponding to the designated event based on the target personalized data; a content acquisition unit, for triggering a large language model to acquire recommended content corresponding to the designated event based on the prompt word; and a content display unit, for displaying the recommended content.
[0007] In a third aspect, the present application provides an electronic device comprising one or more processors and a memory; one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the above-mentioned method.
[0008] In a fourth aspect, the present application provides a computer-readable storage medium storing a program code executable by a processor, wherein the computer-readable storage medium includes the stored program code, wherein the above method is executed when the program code is run.
[0009] The present application provides a content recommendation method, device, and electronic device. After obtaining the target personalized data corresponding to the specified event and the target user in response to triggering a specified event, a prompt word corresponding to the specified event can be generated based on the target personalized data to trigger the large language model to obtain the recommended content corresponding to the specified event based on the prompt word, and then display the recommended content. Thus, in the above manner, when a specified event is triggered, the target personalized data corresponding to the specified event in the personalized data of the target user can be obtained, and then the corresponding prompt word can be generated based on the target personalized data, so that when the large language model obtains the recommended content based on the prompt word, it can obtain the recommended content based on the personalized data of the target user, so that the content fed back by the large language model is personalized. BRIEF DESCRIPTION OF THE DRAWINGS
[0010] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0011] Figure 1 A flow chart of a content recommendation method proposed in an embodiment of the present application is shown;
[0012] Figure 2 A schematic diagram of configuring a specified event in an embodiment of the present application is shown;
[0013] Figure 3 A schematic diagram showing a display of recommended content in an embodiment of the present application is shown;
[0014] Figure 4 Another schematic diagram showing the display of recommended content in an embodiment of the present application is shown;
[0015] Figure 5 A flowchart of a content recommendation method proposed in another embodiment of the present application is shown;
[0016] Figure 6 The flowchart of the personalized data acquisition module in the embodiment of the present application is shown;
[0017] Figure 7 A flowchart of a content recommendation method proposed in another embodiment of the present application is shown;
[0018] Figure 8 The following is a flowchart of the service set processing module in an embodiment of the present application;
[0019] Fig. 9 A flowchart of a content recommendation method proposed in another embodiment of the present application is shown;
[0020] Fig.10 A schematic diagram showing the generation of prompt words based on a prompt word template in an embodiment of the present application is shown;
[0021] Fig.11 A schematic diagram showing the interactive relationship between multiple modules in an embodiment of the present application;
[0022] Fig.12 A structural block diagram of a content recommendation device proposed in an embodiment of the present application is shown;
[0023] Fig.13 A structural block diagram of an electronic device for executing a content recommendation method according to an embodiment of the present application is shown;
[0024] Fig.14 It is a storage unit of an embodiment of the present application for storing or carrying a program code for implementing a content recommendation method according to an embodiment of the present application. DETAILED DESCRIPTION
[0025] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0026] Large Language Model refers to a deep learning model trained with a large amount of text data. Large language models can handle a variety of natural language tasks, such as text classification, question answering, and dialogue, and are an important path to artificial intelligence. With the technological advancement and vigorous development of large language models, large language models can handle more complex and diverse natural language inputs, extract key information from them, and perform effective semantic understanding.
[0027] However, the inventors found in their research that the content fed back by the relevant large language model is still relatively lacking in personalization. Therefore, the inventors proposed a content recommendation method, device, and electronic device in this application. In this method, in response to triggering a specified event, after obtaining the target personalized data corresponding to the specified event and the target user, a prompt word corresponding to the specified event can be generated based on the target personalized data to trigger the large language model to obtain the recommended content corresponding to the specified event based on the prompt word, and then display the recommended content. Thus, through the above-mentioned method, when a specified event is triggered, the target personalized data corresponding to the specified event in the personalized data of the target user can be obtained, and then the corresponding prompt word can be generated based on the target personalized data, so that when the large language model obtains the recommended content based on the prompt word, it can obtain the recommended content based on the personalized data of the target user, so that the content fed back by the large language model is personalized.
[0028] The embodiments of the present application will be described in detail below with reference to the accompanying drawings.
[0029] See also Figure 1 The present application provides a content recommendation method, which is applied to an electronic device, and the method includes:
[0030] S110: In response to triggering a designated event, obtaining target personalized data corresponding to the designated event and the target user.
[0031] In the embodiments of the present application, events can be understood as operations performed by users or electronic devices themselves, or events can also be understood as some specific situations, which can be recognized and processed by programming languages, frameworks, applications, etc. For example, a user clicking a button, moving a mouse, keyboard input, etc. can all be regarded as events. Among them, the specified event can be understood as an event used to trigger the large language model to provide content feedback. When a specified event is triggered, in order to make the content fed back by the large language model not only related to the specified event, but also have a certain degree of personalization, the target personalized data corresponding to the specified event and the target user can be obtained first.
[0032] In the embodiment of the present application, there may be multiple categories of designated events.
[0033] Optionally, the specified event may include a content input event. When a content input event is triggered, it indicates that the user has input content through the input interface provided by the electronic device. For example, if the user expects the large language model to feedback nearby delicacies, then the user can input "I want to try nearby delicacies" through the input interface provided by the electronic device.
[0034] Optionally, the designated event may include a control event about a designated device of the electronic device. The designated device may include a screen, a camera, and other devices. The control event of the designated device may include an event for changing the state of the designated device. Changing the state of the designated device may include switching the device from an off state to an on state, or may include switching the working state of the designated device after startup. For example, in the case where the designated device is a screen, the control event may include unlocking the screen, or may include switching the screen from an off state to an on state.
[0035] It should be noted that when there are multiple events that can be triggered in an electronic device, which event is used as a designated event can be pre-configured by a developer or can be personalized by a user of the electronic device according to his or her own needs.
[0036] As a method, a designated event configuration interface may be provided in the electronic device. Through the designated event configuration interface, the user may select an event from candidate events as a designated event, or delete the designated event. Figure 2 As shown, Figure 2 The designated event configuration interface shown in FIG. 1 includes a designated event display area 11 and a candidate event display area 12. Figure 2 The change between the left image and the right image indicates that if the user moves the unlock screen event from the candidate event display area 12 to the designated event display area 11 , the electronic device may use the unlock screen event as the designated event.
[0037] In the embodiments of the present application, personalized data can be understood as data representing the habits or preferences of a user. Alternatively, it can also be understood as data representing a user portrait of a user. Among them, the target user can be understood as the user referred to when obtaining personalized data, so that the obtained target personalized data corresponds to the target user. Among them, the target personalized data corresponds to the target user, and it can be understood that the obtained target personalized data represents the habits or preferences of the target user.
[0038] In the embodiment of the present application, the target user can be understood as the user of the electronic device, or the user who is currently using the electronic device. The user of the electronic device can be understood as the user corresponding to the identification information recorded in the electronic device. The identification information can include a user account or a current phone number.
[0039] As a method, personalized data of the user to whom the electronic device belongs can be stored in the electronic device. Among them, the personalized data stored locally in the electronic device can be personalized data about multiple aspects. For example, it can include personalized data on diet, personalized data on travel, personalized data on sports, and personalized data on health. In the case of a designated event trigger, the personalized data corresponding to the designated event can be obtained as the target personalized data. For example, if the designated event is related to diet, personalized data related to diet can be obtained locally as the target personalized data.
[0040] As another way, the identification information of the user can be stored locally on the electronic device. In this case, the user represented by the identification information can be used as the target user. Optionally, the identification information can be an account number or a phone number. Optionally, the personalized data of all users can be centrally stored in the cloud. In this way, when a specified event is triggered, the target personalized data can be obtained from the cloud based on the stored identification information and the triggered specified event.
[0041] As another way, the current user of the electronic device may not be the original user of the electronic device. For example, in some cases, the original user of the electronic device may lend the electronic device to other users for use. In this case, if the target personalized data is directly acquired based on the original user of the electronic device, the acquired target personalized data may not meet the needs of the current user. For example, the original user of the electronic device C1 is user P1, and user P1 lends the electronic device C1 to user P2 for use. If user P2 triggers a specified event during the use of the electronic device C1, but the electronic device C1 still uses the personalized data of user P1 as the basis for the subsequent generation of prompt words, it will not only cause the privacy of user P1 to be leaked, but also make user P2 unable to obtain the required feedback content. In this way, when a specified event is triggered, the electronic device can first perform user identification to use the identified user as the target user.
[0042] Among them, the method for performing user identification is not specifically limited in the embodiments of the present application. For example, as a user identification method, the electronic device can collect identity features through a functional device when a specified event is triggered, and then identify the user's identity by matching the identity features. Optionally, the functional device can be a camera or a structured light module. For example, the electronic device can perform image acquisition through a front camera, and then perform face recognition on the acquired image to use the identified user as the target user. Based on the aforementioned example of electronic device C1, if user P1 lends electronic device C1 to user P2 for use, the electronic device identifies the current user as user P2 through user identification, and the electronic device can obtain the personalized data of user P2, and the personalized data about the specified event is used as the target personalized data.
[0043] It should be noted that after the electronic device obtains the identity feature, in order to facilitate the electronic device to successfully complete the user identification, the electronic device may store multiple user identity features. The identity feature may include a face feature, a fingerprint feature, or other identifiable features. For example, as shown in the following table:
[0044] ID Identity User ID 1 Feature T1 User 1 2 Feature T2 User 2 3 Features T3 User 3
[0045] As shown in the above table, the electronic device stores features T1, T2, and T3, wherein the user ID corresponding to feature T1 is user 1, the user ID corresponding to feature T2 is user 2, and the user ID corresponding to feature T3 is user 3. If the identity feature collected by the electronic device through the functional device is feature T2, it can be identified that user 2 is currently using the electronic device.
[0046] It should be noted that, in the case where there are multiple ways to determine the target user, as one way, the electronic device can determine which way to use to determine the target user based on the current operating mode. For example, if the electronic device is currently in the guest mode, the target user can be determined by collecting identity features through functional devices. For another example, if the electronic device is currently in the master mode, the target user can be determined by obtaining the identification information recorded in the electronic device.
[0047] S120: Generate a prompt word corresponding to a designated event based on the target personalized data.
[0048] After obtaining the target personalized data, a prompt word corresponding to the specified event can be generated based on the target personalized data. The prompt word can be used to guide and instruct the model to perform a specific task or operation.
[0049] For example, the prompt word can be a word or a sentence. In this case, the prompt word generated based on the target personalized data and the specified event can be used to trigger the large language model to obtain content related to the specified event and the target personalized data for feedback.
[0050] In an electronic device, there may be multiple designated events that are triggered. Moreover, different intentions may correspond to different types of designated events, and even different intentions may exist for the same designated event. For example, for a content input event, if the user inputs "I want to eat", then the intention expressed by the user may be that the electronic device is expected to provide feedback on nearby delicacies; if the user inputs "I want to buy something", then the intention expressed by the user may be that the electronic device is expected to provide feedback on nearby shopping malls. In this case, when a designated event is triggered, the triggering intention of the designated event can be identified, and then the prompt word can be obtained by combining the intention of the designated event and the target personalized data.
[0051] Exemplarily, if the electronic device detects that the triggered designated event is a content input event, and the content input by the user is "I'm hungry, please recommend me some places to eat", the acquired intent may be that I want to eat, and the acquired target personalized data may be that the user likes to eat noodles and braised pork rice. In this case, the generated prompt word may be "I want to eat noodles and braised pork rice", or the generated prompt word may be "I want to eat noodles or braised pork rice".
[0052] It should be noted that if the triggered designated event is a content input event, the user will input the content. In this case, when generating prompt words, the content input by the user can be combined with the keywords obtained according to the personalized data to obtain prompt words. For example, the content input by the user is "Please recommend me a few places to eat", and the keywords extracted according to the target personalized data are "small noodles" and "braised pork rice", then the prompt words obtained after the combination are "Please recommend me a few places to eat small noodles and pork rice". Alternatively, the electronic device can regenerate content with the same semantics based on the content input by the user and the keywords obtained according to the personalized data to obtain prompt words. For example, the content input by the user is "Please recommend me a few places to eat", and the keywords extracted according to the target personalized data are "small noodles" and "braised pork rice", then the content with the same semantics regenerated can be "Please recommend me a place to eat small noodles or braised pork rice".
[0053] S130: Triggering the large language model to obtain recommended content corresponding to the specified event based on the prompt word.
[0054] In an embodiment of the present application, the large language model can be deployed locally on the electronic device or in the cloud.
[0055] S140: Display recommended content.
[0056] For example, Figure 3 As shown in FIG. 1 , when the generated prompt word is “I want to eat noodles and braised pork rice”, or the generated prompt word may be “I want to eat noodles or braised pork rice”, the displayed recommended content may be as follows: Figure 3 As shown in the interface 20.
[0057] For example, Figure 4 As shown in FIG. 1 , when the generated prompt word is “I want to read news and finance” or “I want to read financial information”, the recommended content displayed may be as follows: Figure 4 As shown in area 30.
[0058] The present embodiment provides a content recommendation method, which enables, through the above-mentioned method, when a designated event is triggered, to obtain target personalized data corresponding to the designated event in the personalized data of the target user, and then generate corresponding prompt words based on the target personalized data, so that when the large language model obtains recommended content based on the prompt word, it can obtain recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized.
[0059] See also Figure 5 The present application provides a content recommendation method, which is applied to an electronic device, and the method includes:
[0060] S210: In response to triggering a designated event, obtaining event intent information corresponding to the designated event.
[0061] In the embodiment of the present application, event intent information can be understood as information used to characterize the intent of the triggered designated event. When a designated event is detected to be triggered, the target personalized data can be more accurately determined by obtaining event intent information. Among them, for different types of designated events, the method of obtaining the corresponding event intent information may be different.
[0062] As a method, when the designated event is a content input event, obtaining the event intent information corresponding to the designated event may include: obtaining the input content corresponding to the content input event, and obtaining the event intent information based on the input content. Among them, if the user triggers the content input event, it indicates that the user expects to control the electronic device by means of content input, and the purpose of the control is to expect the electronic device to feedback content related to the input content. In this case, the event intent information can be obtained by identifying the input content. Optionally, the acquired input content can be input into a pre-trained neural network model to perform semantic recognition through the neural network model to obtain event intent information. Optionally, keywords can be obtained from the acquired input content to use the keywords as event intent information.
[0063] For example, if the input content obtained by the electronic device is "I am hungry, please recommend me some places to eat", after the content is input into the neural network model, the event intention information output by the neural network model may be "I want to eat", or "I want to know about nearby restaurants".
[0064] When the user inputs content, he can directly input the content in text form or in audio form. When the user directly inputs the content in text form, the electronic device will directly obtain the input content in text form, so that it can directly recognize it based on the input content in text form. When the user inputs the content in audio form, the electronic device can first convert the audio content into text content, and then recognize it based on the text content.
[0065] As another way, when the designated event is a control event about a designated device of an electronic device, obtaining event intent information corresponding to the designated event may include: obtaining event trigger parameters corresponding to the control event, and obtaining event intent information corresponding to the control event based on the event trigger parameters.
[0066] In the embodiment of the present application, the event trigger parameter can be understood as a parameter used to describe the triggered control event. Optionally, the specified trigger parameter may include at least one of the trigger time, time location and trigger frequency of the control event. It should be noted that for different control events, the corresponding control intentions may be different. For example, when the user controls the screen to light up, but does not unlock the screen, the user may just want to check the time. For another example, when the user unlocks the screen, the user's intention may be to check some information. Moreover, even for the same category of control events, triggering at different times or places may also express different user intentions. For example, if the electronic device detects that the control event is to unlock the screen, and the trigger time is in the morning, the user may want to check some information. If the control event of the electronic device is to unlock the screen, and the trigger time is at noon, then the user may want to check some information about lunch. For example, if the user unlocks the screen at a station, he may want to check the traffic conditions or inquire about the road conditions. If the user unlocks the screen in a shopping mall, he may want to check the product information.
[0067] Optionally, the electronic device may store a correspondence between event trigger parameters and event intent information. In this case, when a control event is triggered, after obtaining the event trigger parameters of the control event, the corresponding time intent information may be obtained in combination with the correspondence. For example, as shown in the following table:
[0068]
[0069] As shown in the above table, the control events included are unlocking the screen and lighting up the screen to start the camera. Among them, there are two control parameters corresponding to each control event, namely, event control parameter 1 and event control parameter 2, wherein event touch parameter 1 represents the trigger time of the control event, and event control parameter 2 represents the trigger location of the control event. For example, for the control event of unlocking the screen, in the case of corresponding trigger time S1 and corresponding touch location D1, the corresponding event intent information is intent information I1. Similarly, for the control event of unlocking the screen, in the case of corresponding trigger time S2 and corresponding touch location D2, the corresponding event intent information is intent information I2. In addition, if it is detected that the control event is to start the camera, and the trigger time is S2 and the trigger location is D4, it can be determined that the corresponding event intent information is intent information I4.
[0070] It should be noted that, in the embodiment of the present application, the obtained event intent information may be information describing the triggered designated event. For example, in this case, the obtained event intent information may be "I want to eat", "I want to know about nearby restaurants", "I want to know about nearby attractions". Alternatively, the obtained time intent information may characterize the scene to which the triggered designated event belongs. In this case, the obtained event intent information may be "eating scene", "travel scene", etc.
[0071] S220: Based on the event intention information, obtain target personalized data corresponding to the designated event from the personalized data of the target user.
[0072] After obtaining the event intent information of the triggered designated event, the target personalized data can be obtained based on the event intent information. It should be noted that when collecting the personalized data of the user in advance, it can be collected separately based on multiple dimensions. In this case, there may be multiple personalized data corresponding to the same user. For example, the user's multiple personalized data may include: the user's age, the user's health status, the user's dietary preferences, the user's preferred dining place, the user's preferred dining time, important festivals about the user, the user's travel preferences, etc. In this case, after obtaining the event intent information, the event intent information can be matched one by one with each personalized data of the target user, and the successfully matched personalized data can be used as the target personalized data. Exemplary, as shown in the following table:
[0073] ID Personalized data content User 1 Personalized data 1 User 1 2 Personalized data 2 User 1 3 Personalized data 3 User 1
[0074] As shown in the above table, there are three personalized data for user 1, including personalized data 1, personalized data 2, and personalized data 3. In this case, after obtaining the event intent information, the event intent information can be matched with personalized data 1, personalized data 2, and personalized data 3 respectively to obtain the target personalized data.
[0075] As a matching method, in the process of matching the event intent information with the personalized data of the target user, the similarity between the event intent information and each personalized data can be calculated, and then whether the match is successful is determined based on the calculated similarity. Optionally, in an embodiment of the present application, there can be multiple ways to calculate the similarity between the event intent information and the personalized data.
[0076] As a calculation method, the similarity between event intent information and personalized data can be calculated based on a vector method. In this calculation method, the vector representation corresponding to the event intent information and the vector representation of each personalized data can be obtained, so that the similarity between the event intent information and the personalized data can be calculated by calculating the similarity of the two vector representations.
[0077] It should be noted that vector representation is a technology that converts text data into numerical vectors. It represents words or sentences in the text as vectors with fixed dimensions so that computers and other machine devices can understand and process text data. In an embodiment of the present application, there are multiple methods for obtaining vector representation. Optionally, the vector representation can be obtained based on the vector representation of the bag-of-words model, the vector representation can be obtained based on the TF-IDF weight distribution method, and the vector representation can also be obtained based on the word embedding vector.
[0078] Among them, the vector representation method based on the bag-of-words model represents each word in the text as a vector, where each dimension of the vector corresponds to a word, and the value on the dimension represents the frequency or weight of the word in the text. The TF-IDF method takes into account the frequency of occurrence of words in the text and the length of the text, and obtains a TF-IDF vector representation by weighted calculation of the weights of different words in different texts. The vector representation method based on word embedding uses a neural network model to map words into a low-dimensional vector space, so that semantically similar words have similar vector representations. This vector representation method can handle the similarity and contextual relationship of words well.
[0079] Optionally, the method for calculating the similarity between the vector representations may be cosine similarity, dot product similarity, Euclidean similarity, or the like.
[0080] It should be noted that, when similarity is calculated by vector representation, the vector representation of each personalized data of the target user may be obtained in real time, or the vector representation of each personalized data may be calculated in advance.
[0081] Among them, in this method of obtaining vector representation in real time, after obtaining the event intention information, the vector representation corresponding to the event intention information can be obtained first, and then after obtaining the personalized data that currently needs to be calculated for similarity, the vector representation corresponding to the personalized data that currently needs to be calculated for similarity can be obtained to perform similarity calculation. By analogy, the similarity between the event intention information and each personalized data can be calculated.
[0082] In addition, a vector database of user personalized data can be pre-established. In the vector database, multiple personalized data of users can be directly stored in the form of vector representation. Therefore, when similarity calculation is required, only the vector representation of event intention information can be obtained in real time, without calculating the vector representation of personalized data in real time, so as to reduce the amount of calculation in the process of calculating similarity, thereby improving the efficiency of obtaining target personalized data.
[0083] After obtaining the similarity between the event intention information and each personalized data of the target user, the target personalized data can be determined based on the similarity. Optionally, the similarity corresponding to each personalized data can be sorted, and then the personalized data with a designated ranking at the front of the sorting can be used as the target personalized data. Exemplarily, if the personalized data of the target user includes: personalized data 1, personalized data 2, and personalized data 3, wherein the similarity corresponding to personalized data 1 is X1, the similarity corresponding to personalized data 2 is X2, and the similarity corresponding to personalized data 3 is X3, if X1 is greater than X2, and X2 is greater than X3, and the current rule is to select the personalized data with the highest similarity as the target personalized data, then personalized data 1 will be used as the target personalized data. Alternatively, the similarity of each personalized data can be compared with the first similarity threshold, and then the corresponding personalized data with a similarity greater than the first similarity threshold is used as the target personalized data.
[0084] It should be noted that the size of the first similarity threshold will affect the matching degree between the determined target personalized data and the triggered designated event. Therefore, in the embodiment of the present application, the first similarity threshold can be determined according to the determination method of the event intention information.
[0085] Optionally, taking the designated event as a content input event as an example, if the input content is directly used as event intent information, the configured first similarity threshold can be relatively low. If the event intent information is obtained by performing intent recognition on the input content, the first similarity threshold can be configured relatively higher.
[0086] As another matching method, matching can be performed by including the same keywords. In this matching method, the more the number of the same keywords included between the event intention information and the personalized data is, the more the personalized data and the event intention information are matched.
[0087] It should be noted that, when a user includes multiple personalized data, although the multiple personalized data describe the user's preferences or habits from multiple dimensions, some of the personalized data may still have certain associations. For example, a user may have personalized data about dietary preferences and personalized data about health conditions, where the content of the personalized data about health conditions may be: the user is currently not suitable for eating greasy food. In this case, the personalized data about health conditions will still involve content about diet. Furthermore, when the event intent information is information about diet, the target personalized data obtained may include personalized data about the user's health condition. However, in some cases, the user may not expect the electronic device to obtain feedback content based on personalized data about health conditions. In this case, some personalized data can be filtered by configuring the target conditions.
[0088] As a method, personalized data can be obtained from the personalized data of the target user based on the event intent information, and the obtained personalized data corresponding to the event intent information is used as candidate personalized data. The candidate personalized data is filtered based on the target condition, and the filtered personalized data is used as the target personalized data. It should be noted that for each personalized data, metadata can be corresponding, so that the metadata of the candidate personalized data can be filtered by the target condition to obtain the target personalized data.
[0089] Optionally, the metadata of the personalized data may be the scene corresponding to the personalized data. In this case, when a specified event is triggered, the scene triggered by the specified event may be first obtained as the target scene. After obtaining the candidate personalized data, the scene corresponding to the candidate personalized data may be compared with the target scene, and then the candidate personalized data whose corresponding scenes are different from the target personalized scene may be filtered out, so that the unfiltered personalized data may be used as the target personalized data. Exemplary, as shown in the following table:
[0090] ID Personalized data content Scenario User 1 Personalized data 1 Scenario 1 User 1 2 Personalized data 2 Scenario 1 User 1 3 Personalized data 3 Scenario 2 User 1
[0091] If the candidate personalized data obtained based on the above table include personalized data 2 and personalized data 3, when it is determined that the scene corresponding to the triggered designated event is scene 1, scene 1 can be used as the target scene, and then in the filtering process, personalized data 3 belonging to scene 2 will be filtered out so that personalized data 2 can be used as the target personalized data.
[0092] Optionally, based on the aforementioned method of calculating similarity, personalized data having a similarity with the event intent information greater than a first similarity threshold may be used as candidate personalized data.
[0093] It should be noted that in the method of filtering personalized data based on target conditions, all personalized data of the target user can also be filtered based on the target conditions to obtain candidate personalized data, and then the target personalized data is determined from the candidate personalized data based on similarity. In this way, it is helpful to filter unnecessary information in advance, thereby reducing data processing costs.
[0094] In the embodiment of the present application, a vector database can be established and target personalized data can be acquired through a personalized data acquisition module. Figure 6 As shown, the personalized data acquisition module can obtain user personalized data based on historical triggered events, and then classify the user personalized data through preprocessing, and then obtain the corresponding vector representation for each category of user personalized data, and store the obtained vector representation. Figure 6 In the situation shown, after obtaining the currently triggered designated event, the obtained event intention information can be transmitted to the personalized data acquisition module, so that the personalized data acquisition module can obtain the target personalized data through three processes: vector index processing, vector similarity calculation and metadata filtering.
[0095] S230: Generate a prompt word corresponding to the designated event based on the target personalized data.
[0096] S240: Triggering the large language model to obtain recommended content corresponding to the specified event based on the prompt word.
[0097] S250: Display recommended content.
[0098] A content recommendation method provided in this embodiment can obtain recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized. In addition, in this embodiment, after obtaining the specified event, the event intent information of the specified event can be obtained, and then the personalized data of the target user can be obtained based on the event intent information, which is conducive to more accurate and comprehensive personalized data of the target user. In addition, in this embodiment, in the process of obtaining the target user data of the target user, the initially obtained personalized data will also be filtered by the target condition to obtain the final target personalized data, so that the final target personalized data has a higher correlation with the specified time.
[0099] See also Figure 7 The present application provides a content recommendation method, which is applied to an electronic device, and the method includes:
[0100] S310: In response to triggering a designated event, obtaining target personalized data corresponding to the designated event and the target user.
[0101] S320: Acquire a service corresponding to the designated event from services included in the electronic device as a candidate service.
[0102] It should be noted that when obtaining feedback content through the large language model, the content fed back by the large language model can be services. For example, you can provide feedback to users about meal ordering services, navigation services, takeaway services, etc. In this case, the action of obtaining candidate services can be used to limit the categories of services recommended by the large language model, so that the large language model can select services from the services included in the electronic device for recommendation, and will not recommend services that do not exist in the electronic device, so as to avoid inconvenience to the user.
[0103] Among them, in the embodiments of the present application, there may be multiple ways to obtain candidate services.
[0104] As a method, the service in the electronic device may have corresponding service description information. In this method, after obtaining the event intent information corresponding to the specified event, the electronic device may obtain the service corresponding to the specified event as a candidate service based on the event intent information and the service description information of the service included in the electronic device. The service description information may be understood as information used to introduce the content of the service.
[0105] Optionally, the candidate services may be obtained by vector representation. In this way, the vector representation corresponding to the event intent information and the vector representation of each service description information may be obtained, and the similarity between the two vector representations may be calculated as the similarity between the event intent information and the service description information.
[0106] It should be noted that, when calculating the similarity through vector representation, the vector representation of each service in the electronic device may be obtained in real time, or the vector representation of each service in the electronic device may be calculated in advance.
[0107] Among them, in the method of obtaining the vector representation of each service in real time, after obtaining the event intent information, the vector representation corresponding to the event intent information can be obtained first, and then the service description information that currently needs to be calculated for similarity is obtained, and the vector representation of the service description information that currently needs to be calculated for similarity is obtained, and then the similarity calculation is performed. By analogy, the similarity between the event intent information and the service description information of each service can be calculated.
[0108] In addition, a vector database of service description information about services in electronic devices can be pre-established. In the vector database, the service description information of multiple services can be directly stored in the form of vector representation. Therefore, when similarity calculation is required, only the vector representation of event intent information can be obtained in real time, without calculating the vector representation of service description information in real time, so as to reduce the amount of calculation in the process of calculating similarity, thereby improving the efficiency of obtaining candidate services.
[0109] After obtaining the similarity between the event intention information and the service description information of the service, the candidate service can be determined based on the similarity. Optionally, the similarity corresponding to each service description information can be sorted, and then the service corresponding to the service description information with a specified ranking in the front order is used as a candidate service. Exemplarily, if the services in the electronic device include: service 1, service 2 and service 3, wherein the similarity corresponding to the service description information of service 1 is X4, the similarity corresponding to the service description information of service 2 is X5, and the similarity corresponding to the service description information of service 3 is X6, if X4 is greater than X5, and X5 is greater than X6, and the current rule is to select the service corresponding to the service description information with the highest similarity as the candidate service, then service 1 will be used as a candidate service. Alternatively, the similarity of each service description information can be compared with the second similarity threshold, and the service whose corresponding similarity is greater than the second similarity threshold is used as a candidate service. For example, if the aforementioned X4 and X5 are both greater than the second similarity threshold, both service 1 and service 2 can be used as candidate services.
[0110] S330: Generate a prompt word corresponding to the designated event based on the target personalized data and the candidate services.
[0111] S340: Triggering the large language model to obtain recommended content corresponding to the specified event based on the prompt word.
[0112] S350: Display recommended content.
[0113] Optionally, in this embodiment, a vector database about services can be established by the service set processing module and used to determine candidate services. Figure 8As shown, the service set processing module can discover services in the electronic device through the service management stage. Among them, the services in the electronic device may include system services and third-party services. Optionally, the service set processing module can discover services in the electronic device through multiple interfaces. The multiple interfaces may include a system setting interface, a system installation application interface, and a third-party service interface. After obtaining the services in the electronic device, service filtering can be performed, wherein the service filtering can filter out similar services in the electronic device. For the remaining services after service filtering, natural language description processing can be performed to obtain service description information for each service. Afterwards, the remaining services can be classified to determine the scenario corresponding to each service. In addition, for the service description information of each service, the corresponding vector representation can be obtained for storage.
[0114] After acquiring the currently triggered designated event, the acquired event intent information can be transmitted to the service set processing module, so that the service set processing module can obtain candidate services through three processes: vector index processing, vector similarity calculation and metadata filtering.
[0115] The content recommendation method provided in this embodiment can obtain recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized. In addition, in this embodiment, before generating the prompt word, the service corresponding to the triggered designated correspondence in the service included in the electronic device is also obtained as a candidate service, so that the large language model can obtain the feedback content according to the candidate service during the process of obtaining the feedback content, so that the content or service recommended by the large language model is a service that can be used by the user of the electronic device.
[0116] See also Fig. 9 The present application provides a content recommendation method, which is applied to an electronic device, and the method includes:
[0117] S410: In response to triggering a designated event, obtaining target personalized data corresponding to the designated event and the target user.
[0118] S420: Generate a prompt word corresponding to the designated event based on the target personalized data and the prompt word template.
[0119] In the embodiment of the present application, the prompt word template can be used to determine what content in the input data can be used as the prompt word, and to standardize the format of the output prompt word. Among them, the input data can be understood as the data referenced by the generated prompt word, for example, it can be the target personalized data.
[0120] In addition, it should be noted that, in the embodiment of the present application, in the process of generating prompt words based on the prompt word template, the input data may include other data in addition to the target personalized data.
[0121] As a method, the input data may include target personalized data and historical data, and the historical data may include historical user input data and / or cache records of a large language model. In this method, generating a prompt word corresponding to a specified event based on the target personalized data and the prompt word template may include: generating a prompt word corresponding to the specified event based on the target personalized data, the historical data, and the prompt word template.
[0122] As another way, the input data may also include target personalized data, historical data, and candidate services. In this way, generating a prompt word corresponding to a specified event based on the target personalized data and the prompt word template may include: generating a prompt word corresponding to the specified event based on the target personalized data, historical data, candidate services, and the prompt word template.
[0123] For example, Fig.10 As shown, the global object may carry the aforementioned input data, and then transmit the input data to the prompt word template engine, so that the prompt word template engine uses the prompt word template to obtain the prompt word according to the input data. After obtaining the prompt word output by the prompt word template, the prompt word can be output to the large language model.
[0124] The input data input into the prompt word template engine may also have a context, and the context may include the content input into the large language model last time and / or the content input by the user this time.
[0125] The templates in the template library may include general templates and customized templates.
[0126] S430: Triggering the large language model to obtain recommended content corresponding to the specified event based on the prompt word.
[0127] S440: Display recommended content.
[0128] The content recommendation method provided in this embodiment can obtain recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized. In addition, in this embodiment, in the process of generating prompt words, the prompt words can be generated with the help of a pre-configured prompt word template, so that the generated prompt words can be more standardized, which is also conducive to the recognition of the large language model.
[0129] As a method, the content recommendation method provided in the embodiment of the present application can be completed by multiple modules cooperating with each other. Optionally, in addition to the aforementioned personalized data acquisition module and service set processing module, the multiple modules can also include an interactive data processing module, a prompt word generation module, and a recommendation result generation module. The workflow of the multiple modules can be as follows: Fig.11 shown.
[0130] in, Fig.11 The input shown in can be characterized by a specified event trigger, and the interactive data processing module will obtain the event intent information of the specified event, and then the interactive data processing module will transmit the event intent information to the personalized data acquisition module and the service set processing module respectively. Among them, the personalized data acquisition module can obtain the target personalized data based on the aforementioned method, and the service set processing module can obtain the candidate services. After that, the target personalized data and the candidate services will be transmitted to the prompt word generation module, so that the prompt word generation module can generate prompt words based on the method provided in the embodiment of the present application. Then, the large language model can be triggered by the prompt word to obtain content, and the obtained feedback content can be transmitted to the recommendation result generation module. The recommendation result generation module can then display the feedback content.
[0131] In addition, it should be noted that in the embodiment of the present application, the feedback content obtained by the large language model can be directly displayed. Alternatively, the content fed back by the large language model can be filtered and the filtered content can be displayed. For example, if the large language model feeds back multiple recommended services, the multiple recommended services can be sorted first, and then the recommended services of a specified number with the top rankings can be displayed. For example, the recommended services with the top 3 rankings can be displayed.
[0132] See also Fig.12 The present application provides a content recommendation device 500, which runs on an electronic device. The device 500 includes:
[0133] The personalized data acquisition unit 510 is used to acquire target personalized data corresponding to the designated event and the target user in response to triggering the designated event.
[0134] The prompt word determination unit 520 is used to generate a prompt word corresponding to a specified event based on the target personalized data.
[0135] The content acquisition unit 530 is used to trigger the large language model to acquire recommended content corresponding to the specified event based on the prompt word.
[0136] The content display unit 540 is used to display recommended content.
[0137] As a method, the personalized data acquisition unit 510 is specifically used to obtain event intention information corresponding to a specified event; based on the event intention information, the target personalized data corresponding to the specified event is obtained from the personalized data of the target user.
[0138] Optionally, the personalized data acquisition unit 510 is specifically used to acquire personalized data from the personalized data of the target user based on the event intent information, and use the acquired personalized data corresponding to the event intent information as candidate personalized data; filter the candidate personalized data based on the target condition, and use the filtered personalized data as the target personalized data, and the target condition corresponds to the specified event.
[0139] Optionally, the personalized data acquisition unit 510 is specifically used to acquire input content corresponding to the content input event; and acquire event intention information based on the input content.
[0140] Optionally, the designated event includes a control event of a designated device of the electronic device. The personalized data acquisition unit 510 is specifically configured to acquire event trigger parameters corresponding to the control event; and acquire event intention information corresponding to the control event based on the event trigger parameters.
[0141] As a method, the prompt word determination unit 520 is also used to obtain a service corresponding to the specified event from the services included in the electronic device as a candidate service. The prompt word determination unit 520 is specifically used to generate a prompt word corresponding to the specified event based on the target personalized data and the candidate services.
[0142] Optionally, the services in the electronic device have corresponding service description information, and the prompt word determination unit 520 is specifically used to obtain event intention information corresponding to the specified event; based on the event intention information and the service description information of the services included in the electronic device, the service corresponding to the specified event is obtained as a candidate service.
[0143] As a method, the prompt word determination unit 520 is specifically used to generate a prompt word corresponding to a specified event based on the target personalized data and the prompt word template. Optionally, the prompt word determination unit 520 is also specifically used to obtain historical data. In this way, the prompt word determination unit 520 is specifically used to generate a prompt word corresponding to a specified event based on the target personalized data, the historical data and the prompt word template.
[0144] The present embodiment provides a content recommendation device, through which, when a designated event is triggered, the target personalized data corresponding to the designated event in the personalized data of the target user can be obtained, and then the corresponding prompt word can be generated based on the target personalized data, so that when the large language model obtains recommended content based on the prompt word, it can obtain recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized.
[0145] It should be noted that the device embodiments in the present application correspond to the aforementioned method embodiments, and the specific implementation principles of each unit in the device embodiments are similar to the principles in the aforementioned method embodiments. The specific contents in the device embodiments can be found in the method embodiments, and will not be repeated in the device embodiments.
[0146] The following will be combined Fig.13 An electronic device provided by the present application is described.
[0147] See also Fig.13 Based on the above content recommendation method and device, the embodiment of the present application also provides an electronic device 1000 that can execute the above content recommendation method. The electronic device 1000 includes one or more (only one is shown in the figure) processors 105, a memory 104, an audio playback module 106 and an audio acquisition device 108 that are coupled to each other. Among them, the memory 104 stores a program that can execute the content of the above embodiment, and the processor 105 can execute the program stored in the memory 104.
[0148] Among them, the processor 105 may include one or more processing cores. The processor 105 uses various interfaces and lines to connect various parts of the entire electronic device 1000, and executes various functions and processes data of the electronic device 1000 by running or executing instructions, programs, code sets or instruction sets stored in the memory 104, and calling data stored in the memory 104. Optionally, the processor 105 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). The processor 105 can integrate one or a combination of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU) and a modem. Among them, the CPU mainly processes the operating system, user interface and application programs; the GPU is responsible for rendering and drawing display content; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 105, but may be implemented separately through a communication chip.
[0149] The memory 104 may include a random access memory (RAM) or a read-only memory (ROM). The memory 104 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 104 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc.
[0150] Furthermore, in addition to the aforementioned components, the electronic device 1000 may further include a network module 110 and a sensor module 112 .
[0151] The network module 110 is used to realize information interaction between the electronic device 1000 and other devices. For example, a connection can be established with other audio playback devices or other electronic devices, and information interaction is performed based on the established connection. As a way, the network module 110 of the electronic device 1000 is a radio frequency module, which is used to receive and send electromagnetic waves, realize the mutual conversion of electromagnetic waves and electrical signals, and thus communicate with a communication network or other devices. The radio frequency module may include various existing circuit elements for performing these functions, such as antennas, radio frequency transceivers, digital signal processors, encryption / decryption chips, user identity modules (SIM) cards, memories, etc. For example, the radio frequency module can interact with external devices through electromagnetic waves sent or received.
[0152] The sensor module 112 may include at least one sensor. Specifically, the sensor module 112 may include but is not limited to: a pressure sensor, a motion sensor, an acceleration sensor, and other sensors.
[0153] Among them, the pressure sensor may be a sensor that detects the pressure generated by pressing on the electronic device 1000. That is, the pressure sensor detects the pressure generated by contact or pressing between the user and the electronic device 1000, for example, the pressure generated by contact or pressing between the user's ear and the electronic device 1000. Therefore, the pressure sensor can be used to determine whether contact or pressing occurs between the user and the electronic device 1000, and the magnitude of the pressure.
[0154] Among them, the acceleration sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary, and can be used for applications that recognize the posture of the electronic device 1000 (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc. In addition, the electronic device 1000 can also be equipped with other sensors such as gyroscopes, barometers, hygrometers, thermometers, etc., which will not be repeated here.
[0155] The audio collection device 108 is used to collect audio signals. Optionally, the audio collection device 110 includes a plurality of audio collection devices, which may be microphones.
[0156] Please refer to Fig.14 , which shows a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable medium 1100 stores program codes, which can be called by a processor to execute the method described in the above method embodiment.
[0157] The computer readable storage medium 1100 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk, or a ROM. Optionally, the computer readable storage medium 1100 includes a non-transitory computer-readable storage medium. The computer readable storage medium 1100 has storage space for program code 1110 that executes any method step in the above method. These program codes can be read from or written to one or more computer program products. The program code 1110 can be compressed, for example, in an appropriate form.
[0158] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0159] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0160] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.
[0161] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.
[0162] It should be understood that the various parts of the present application can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0163] In summary, the content recommendation method, device and electronic device provided by the present application can generate a prompt word corresponding to the specified event based on the target personalized data after obtaining the target personalized data corresponding to the specified event and the target user in response to triggering a specified event, so as to trigger the large language model to obtain the recommended content corresponding to the specified event based on the prompt word, and then display the recommended content. Thus, through the above method, when a specified event is triggered, the target personalized data corresponding to the specified event in the personalized data of the target user can be obtained, and then the corresponding prompt word can be generated based on the target personalized data, so that when the large language model obtains the recommended content based on the prompt word, it can obtain the recommended content based on the personalized data of the target user, so that the content fed back by the large language model is also personalized.
[0164] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical feature diagrams therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A content recommendation method, characterized in that: Applied to electronic equipment, the method comprises: In response to triggering a designated event, obtaining target personalized data corresponding to the designated event and the target user; generating a prompt word corresponding to the designated event based on the target personalized data; Triggering the large language model to obtain recommended content corresponding to the specified event based on the prompt word; The recommended content is displayed.
2. The method according to claim 1, characterized in that The obtaining of target personalized data corresponding to the designated event and the target user includes: Obtaining event intention information corresponding to the specified event; Based on the event intention information, target personalized data corresponding to the designated event is acquired from the personalized data of the target user.
3. The method according to claim 2, characterized in that The acquiring, based on the event intention information, target personalized data corresponding to the designated event from the personalized data of the target user includes: Based on the event intention information, personalized data is acquired from the personalized data of the target user, and the acquired personalized data corresponding to the event intention information is used as candidate personalized data; The candidate personalized data are filtered based on a target condition, and the filtered personalized data are used as target personalized data, wherein the target condition corresponds to the designated event.
4. The method according to claim 2, characterized in that: The designated event includes a content input event, and obtaining event intent information corresponding to the designated event includes: Get the input content corresponding to the content input event; Event intention information is obtained based on the input content.
5. The method according to claim 2, characterized in that: The designated event includes a control event of a designated device of the electronic device, and the acquiring event intention information corresponding to the designated event includes: Acquire event trigger parameters corresponding to the control event; Event intention information corresponding to the control event is acquired based on the event trigger parameter.
6. The method according to claim 1, characterized in that The method further includes: acquiring a service corresponding to the specified event from services included in the electronic device as a candidate service; The generating a prompt word corresponding to the designated event based on the target personalized data includes: Based on the target personalized data and the candidate services, a prompt word corresponding to the designated event is generated.
7. The method according to claim 6, characterized in that The service in the electronic device has corresponding service description information, and acquiring the service corresponding to the specified event as a candidate service from the services included in the electronic device includes: Obtaining event intention information corresponding to the specified event; Based on the event intention information and the service description information of the services included in the electronic device, a service corresponding to the designated event is acquired as a candidate service.
8. The method according to any one of claims 1 to 7, characterized in that: The generating a prompt word corresponding to the designated event based on the target personalized data includes: Based on the target personalized data and the prompt word template, a prompt word corresponding to the designated event is generated.
9. The method according to claim 8, characterized in that The method further comprises: acquiring historical data, wherein the historical data comprises historical input data of the user and / or cache records of the large language model; Generating a prompt word corresponding to the specified event based on the target personalized data and the prompt word template includes: Based on the target personalized data, the historical data and the prompt word template, a prompt word corresponding to the designated event is generated.
10. A content recommendation device, characterized in that: Running on an electronic device, the device comprises: A personalized data acquisition unit, configured to acquire, in response to triggering a designated event, target personalized data corresponding to the designated event and a target user; a prompt word determination unit, configured to generate a prompt word corresponding to the designated event based on the target personalized data; A content acquisition unit, used for triggering the large language model to acquire recommended content corresponding to the specified event based on the prompt word; A content display unit is used to display the recommended content.
11. An electronic device, characterized in that: including one or more processors and memory; One or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method according to any one of claims 1 to 9.
12. A computer-readable storage medium storing a program code executable by a processor, characterized in that: The computer-readable storage medium includes stored program code, wherein when the program code is executed, the method according to any one of claims 1 to 9 is executed.