Method and device for determining prompt tone, electronic equipment and storage medium
By determining the current usage scenario in the electronic device and dynamically obtaining the prompt sound according to the scene, device type and message type, the problem of fixed prompt sounds being poor in different scenarios is solved, and better notification message prompt effect and User experience.
Patent Information
- Application Number
- CN202310968403.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-02
- Publication Date
- 2025-02-14
AI Technical Summary
When setting prompt sounds, existing electronic devices usually use fixed prompt sounds, resulting in poor prompt sound effects in different usage scenarios.
By determining the current usage scenario of the electronic device and obtaining and setting the corresponding target prompt tone based on the scenario, device type, and message type of notification message.
It improves the sound prompt effect of notification messages, reduces the operation of users setting notification messages prompt sounds, and improves the user experience.
Smart Images

Figure CN119449755A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electronic devices, and more specifically, to a method, device, electronic device and storage medium for determining a prompt tone. Background Art
[0002] With the rapid advancement of technology and living standards, electronic devices (such as smart phones, tablet computers, etc.) have become one of the commonly used electronic products in people's lives. Among them, reminding of notifications is a common function of electronic devices, and users can set corresponding reminder tones for notification messages (such as receiving calls, receiving text messages, receiving new emails, completing download tasks, etc.), but the set reminder tones are generally fixed, resulting in poor reminder effects of reminder tones in some cases. Summary of the invention
[0003] The present application proposes a method, device, electronic device and storage medium for determining a prompt tone, which can improve the sound prompt effect of a notification message.
[0004] In a first aspect, an embodiment of the present application provides a method for determining a prompt tone, which is applied to an electronic device, and the method includes: determining a current usage scenario of the electronic device; based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtaining a target prompt tone corresponding to the first notification message; and determining the target prompt tone as the current prompt tone of the first notification message.
[0005] In a second aspect, an embodiment of the present application provides a device for determining a prompt tone, which is applied to an electronic device, and the device includes: a scene recognition module, a prompt tone acquisition module and a prompt tone setting module, wherein the scene recognition module is used to determine a current usage scenario of the electronic device; the prompt tone acquisition module is used to obtain a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device and the message type of the first notification message; the prompt tone setting module is used to determine the target prompt tone as the current prompt tone of the first notification message.
[0006] In a third aspect, an embodiment of the present application provides an electronic device, comprising: one or more processors; a memory; one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, and the one or more applications are configured to execute the method for determining a prompt tone provided in the first aspect above.
[0007] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a program code is stored. The program code can be called by a processor to execute the method for determining a prompt tone provided in the first aspect above.
[0008] The solution provided by the present application determines the current usage scenario of the electronic device; based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtains the target prompt tone corresponding to the first notification message; and determines the target prompt tone as the current prompt tone of the first notification message. In this way, it is possible to determine the corresponding prompt tone for the notification message according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operations in setting the notification message, and improving the user's experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] 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.
[0010] Figure 1 A flow chart of a method for determining a prompt tone according to an embodiment of the present application is shown.
[0011] Figure 2 A schematic diagram of an interface provided in an embodiment of the present application is shown.
[0012] Figure 3 A flow chart of a method for determining a prompt tone according to another embodiment of the present application is shown.
[0013] Figure 4 A schematic diagram of the principle of the prompt tone generation model provided in an embodiment of the present application is shown.
[0014] Figure 5 A flow chart of a method for determining a prompt tone according to yet another embodiment of the present application is shown.
[0015] Figure 6 A flow chart of a method for determining a prompt tone according to yet another embodiment of the present application is shown.
[0016] Figure 7 A flow chart of a method for determining a prompt tone according to yet another embodiment of the present application is shown.
[0017] Figure 8 A block diagram of a device for determining a prompt tone according to an embodiment of the present application is shown.
[0018] Fig. 9 It is a block diagram of an electronic device for executing the method for determining a prompt tone according to an embodiment of the present application.
[0019] Fig.10 It is a storage unit of an embodiment of the present application for storing or carrying a program code for implementing a method for determining a prompt tone according to an embodiment of the present application. DETAILED DESCRIPTION
[0020] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.
[0021] With the rapid advancement of science and technology and living standards, electronic devices have gradually become popular. Electronic devices can usually provide sound prompts for generated notification messages by playing prompt tones. In the relevant technology, the prompt tones for text messages, incoming calls, system application notifications, third-party application notifications, etc. in electronic devices can usually be set by the user to meet the user's needs for prompt tones of different notification messages. However, in the relevant technology, after the user sets the prompt tone of the notification message, the prompt tone is usually fixed, and the user's needs for the prompt tone may be different in different usage scenarios, and the prompt needs for different prompt tones may also be different. Therefore, the prompt effect of using a fixed prompt tone to prompt the notification message is not good.
[0022] In response to the above problems, the inventors have proposed a method, device, electronic device, and storage medium for determining a prompt tone provided in the embodiments of the present application, which can determine a corresponding prompt tone for a notification message according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operation of setting the notification message, and improving the user's experience. The specific method for determining the prompt tone is described in detail in the subsequent embodiments.
[0023] The method for determining a prompt tone provided in an embodiment of the present application is described in detail below in conjunction with the accompanying drawings.
[0024] See also Figure 1 , Figure 1 A flow chart of a method for determining a prompt tone provided by an embodiment of the present application is shown. In a specific embodiment, the method for determining a prompt tone is applied to Figure 8 The device 600 for determining the prompt tone and the electronic device 100 ( Fig. 9). The following will take an electronic device as an example to illustrate the specific process of this embodiment. Of course, it can be understood that the electronic device used in this embodiment can be a smart phone, a tablet computer, a smart watch, a smart home appliance, a laptop computer, etc., which is not limited here. Figure 1 The process shown is described in detail, and the method for determining the prompt tone may specifically include the following steps:
[0025] Step S110: Determine the current usage scenario of the electronic device.
[0026] In an embodiment of the present application, when an electronic device determines a prompt tone for a notification message, it can determine the current usage scenario of the electronic device, so as to determine the prompt tone for the notification message according to the determined usage scenario, thereby satisfying the user's need for the prompt tone in the current usage scenario. Among them, the usage scenario of the electronic device can be a scenario divided according to the different needs of the user for the prompt tone in different situations. For example, the usage scenario can be a scene during a meeting, a scene during driving, a scene during work, a scene during sleep, a scene during exercise, a scene during a party, an indoor scene, an outdoor scene, etc. In the above different scenarios, the user may have different needs for the prompt tone of the notification message. Therefore, by determining the usage scenario of the electronic device, the prompt tone of the notification message is further determined, which can ensure the accuracy and applicability of the prompt tone.
[0027] In some embodiments, when determining the current usage scenario of the electronic device, the electronic device may obtain the current system time, current location, wireless network connection status, Bluetooth connection status, motion data collected by motion sensors (such as accelerometers, gyroscopes, etc.), schedule data, memo data, etc.; then determine the current usage scenario of the electronic device based on the above data obtained. It can be understood that the system time can reflect the current working day and time period (such as morning, afternoon, evening, etc.), the location data can reflect the user's environment (such as at home, at the company, in the mall, etc.), the motion data collected by the motion sensor can reflect the user's dynamic and static state, the schedule data and memo data can reflect the things that the user may do at different times, etc., so based on the above data, the current usage scenario of the electronic device (i.e., the current usage scenario) can be determined.
[0028] In one possible implementation, the system time, location data, wireless network connection status, Bluetooth connection status, motion data of motion sensors, schedule data, and memo data under different usage scenarios can be acquired in advance; then, a mapping relationship between the above data and the usage scenarios can be established through clustering; when the electronic device actually determines the current usage scenario of the electronic device, it can determine the current usage scenario of the electronic device based on the acquired current system time, current location, wireless network connection status, Bluetooth connection status, motion data collected by motion sensors, schedule data, and memo data, and based on the above mapping relationship.
[0029] In some embodiments, the electronic device can determine the current usage scenario of the electronic device at each target duration interval, and perform subsequent steps, namely, the step of obtaining the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, and the step of determining the target prompt tone as the current prompt tone of the first notification message. Among them, the target duration can be 30 minutes, 60 minutes, 2 hours, 5 hours, etc., and the specific duration value of the target duration may not be limited. Thus, it is possible to determine the prompt tone of the notification message at each target duration interval, so that when the usage scenario changes, it can be ensured that the prompt tone corresponding to the notification message can match the usage scenario.
[0030] In some implementations, the electronic device may also determine the current usage scenario of the electronic device in real time; after each determination of the current usage scenario, it may be determined whether the current usage scenario determined this time has changed compared to the usage scenario determined last time; if the current usage scenario determined this time has changed compared to the usage scenario determined last time, the step of obtaining the target prompt tone corresponding to the first notification message and the step of determining the target prompt tone as the current prompt tone of the first notification message may be performed; if the current usage scenario determined this time has not changed compared to the usage scenario determined last time, the subsequent steps may not be performed. In this way, when the usage scenario changes, it can be achieved that the prompt tone corresponding to the notification message can match the usage scenario.
[0031] Step S120: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtain a target prompt tone corresponding to the first notification message.
[0032] In an embodiment of the present application, after the electronic device determines the current usage scenario, it can obtain the corresponding prompt tone (as the target prompt tone) for the first notification message based on the determined current usage scenario. Wherein, the first notification message is any notification message that needs to be prompted by sound in the notification message existing in the electronic device (that is, the notification message that needs to be prompted by the prompt tone), for example, the first notification message is a call notification message, a text message notification message, a chat application notification message, a content push notification message, etc.; the device type of the electronic device may include a smart phone, a tablet computer, a smart watch, an e-book, a smart home appliance, a laptop computer, etc.; the message type of the notification message can be divided according to the source application or service of the notification message, for example, it can be a call notification of a call application, a new email notification of an email application, a chat notification of a social software, etc. After the electronic device determines the current usage scenario, it can obtain the device type of the electronic device, and determine the message type of the first notification message for the first notification message, and then obtain the prompt tone corresponding to the first notification message as the target prompt tone based on the current usage scenario, the device type and the message type of the first notification message. It can be understood that in addition to the usage scenario of the electronic device affecting the user's demand for the prompt tone, the device type of different electronic devices will also affect the user's choice of prompt tone. For example, when the device type is a smart watch, a short and easy-to-recognize prompt tone is more suitable; in addition, for the user, the importance of notification messages of different message types is also different, so the message type will also affect the user's choice of prompt tone. Therefore, in addition to determining the usage scenario, when determining the prompt tone, the device type of the electronic device and the message type of the notification message can also be obtained, so as to determine the prompt tone corresponding to the first notification message in combination with the current usage scenario, the device type of the electronic device and the message type of the notification message.
[0033] In some embodiments, the electronic device can obtain a prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message from the stored prompt tones, and use the obtained matching prompt tone as the target prompt tone. Among them, the electronic device can store the correspondence between different parameter combinations and prompt tones, wherein the parameter combination is a combination of the usage scenario, the device type, and the message type of the notification message, and if any of the parameters in the usage scenario, the device type, and the message type of the notification message is different, then the parameter combination composed of the usage scenario, the device type, and the message type of the notification message is different; according to the correspondence, the prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message can be determined from the stored prompt tones.
[0034] In a possible implementation, the correspondence between the above different parameter combinations and the prompt tones may be determined by the electronic device according to the user's setting operation. Figure 2 The electronic device can display a configuration interface A1 of the correspondence between usage scenarios, device types, message types and prompt sounds. The electronic device can obtain a parameter combination of the configured display usage scenarios, device types and message types, and a prompt sound corresponding to the parameter combination according to the setting operation input in A1 in the configuration interface, thereby obtaining the above correspondence.
[0035] In a possible implementation, the correspondence between the above different parameter combinations and prompt tones can be a system default configuration. In this way, the server can collect or generate corresponding prompt tones for different combinations of usage scenarios, device types, and message types in advance, and obtain the correspondence between the parameter combinations and prompt tones formed by different usage scenarios, device types, and message types, and send the correspondence and the above prompt tones to the electronic device, so that the electronic device can determine the prompt tone according to the correspondence when determining the prompt tone, and determine the prompt tone corresponding to the parameter combination formed by the current usage scenario, the device type of the electronic device, and the message type of the first notification message.
[0036] In some embodiments, the electronic device may also generate a prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message through a pre-trained sound generation model, and use it as the target prompt tone. For example, the electronic device may generate a corresponding description text based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, and then send the description text to the server. The server inputs the received description text into the deployed sound generation model, obtains the audio output by the sound generation model, and then returns the audio as a prompt tone to the electronic device, so that the electronic device obtains a prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message.
[0037] Step S130: Determine the target prompt tone as the current prompt tone of the first notification message.
[0038] In an embodiment of the present application, after the electronic device obtains the target prompt tone corresponding to the first notification message, it can determine the target prompt tone as the current prompt tone of the first notification message. Among them, the electronic device can set the target prompt tone as the current prompt tone of the first notification message, so that in the current usage scenario, when a sound prompt is required for the first notification message, the electronic device performs a sound prompt by playing the above target prompt tone. Since the target prompt tone is determined based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the target prompt tone can be suitable for the electronic device of the device type to perform a sound prompt for the first notification message of the message type in the current usage scenario, thereby improving the prompt effect of the sound prompt.
[0039] In some embodiments, the electronic device can also treat each notification message that needs to be prompted by a prompt tone as the first notification message, and then perform the above steps of obtaining the target prompt tone corresponding to the first notification message, and determining the target prompt tone as the current prompt tone of the first notification message, thereby ensuring that each notification message that needs to be prompted by a prompt tone can determine the corresponding prompt tone.
[0040] The method for determining a prompt tone provided in an embodiment of the present application determines a corresponding prompt tone for a notification message according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operations in setting notification messages, and improving the user's usage experience.
[0041] See also Figure 3 , Figure 3 A flow chart of a method for determining a prompt tone provided by another embodiment of the present application is shown. The method for determining a prompt tone is applied to the above electronic device. Figure 3 The process shown is described in detail, and the method for determining the prompt tone may specifically include the following steps:
[0042] Step S210: Determine the current usage scenario of the electronic device.
[0043] In the embodiment of the present application, step S210 can refer to the contents of other embodiments and will not be repeated here.
[0044] Step S220: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, generate a target prompt tone corresponding to the first notification message.
[0045] In the embodiment of the present application, after the electronic device determines the current usage scenario, based on the determined current usage scenario, when obtaining the corresponding prompt tone for the first notification message, the prompt tone corresponding to the first notification message is generated, and based on the current usage scenario, the device type of the electronic device and the message type of the first notification message, the target prompt tone corresponding to the first notification message is generated. In other words, the electronic device can determine the prompt tone corresponding to the first notification message by generating a prompt tone.
[0046] In some embodiments, when the electronic device generates a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, it can generate the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, and using a pre-trained prompt tone generation model.
[0047] In a possible implementation, the above prompt tone generation model can be a text-to-speech generative large model, such as Tacotron 2, WaveNet, FastSpeech and other models. When generating the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device and the message type of the first notification message, and using the pre-trained prompt tone generation model, the prompt content can be generated according to the current usage scenario, the device type of the electronic device and the message type of the first notification message, and then the prompt content is input into the prompt tone generation model to obtain the audio output by the prompt tone generation model, and use it as the target prompt tone corresponding to the first notification message. Among them, the above prompt content is the prompt (prompt word) that needs to be input into the generative large model when realizing artificial intelligence generated content (AI generated content, AIGC). After providing the prompt to the generative large model, the generative large model can understand the user intent of the prompt, and then output the audio that matches the recognized user intent, thereby obtaining the target prompt tone corresponding to the above first notification message. For example, the current usage scenario is a work scenario, the device type is a smartphone, and the message type of the first notification message is an incoming call notification. The generated prompt content can be "Generate a prompt tone for incoming call notifications on smartphones, which must be suitable for playing in work scenarios." After the generated prompt content is input into the generative big model, the generative big model can recognize, based on the prompt content, that the user's intention is to generate a prompt tone, and the requirement for the prompt tone is "played on a smartphone to prompt incoming call notifications, and suitable for playing in work scenarios."
[0048] In a possible implementation, the above prompt tone generation model may include a feature extraction module and an audio generation module. The feature extraction module is used to extract features for characterizing the usage scenario, features for characterizing the device type, and features for characterizing the message type from the prompt content for describing the current usage scenario, the device type of the electronic device, and the message type of the first notification message; the audio generation module is used to output corresponding audio according to the input features for characterizing the usage scenario, features for characterizing the device type, and features for characterizing the message type. For example, please refer to Figure 4 The prompt content generated based on the current usage scenario, the device type of the electronic device, and the message type of the notification message can be input into the feature extraction module 310 of the prompt sound generation model 300. After the feature extraction module 310 extracts the above features for the prompt content, the features are input into the audio generation module 320 of the prompt sound generation model 300. The audio generation module 320 then outputs the generated audio according to the input features.
[0049] When training the above prompt tone generation model, a large amount of sample text data and sample prompt tones can be obtained. The sample text data can be annotated with a scenario label for characterizing a usage scenario, a device type label for characterizing a device type, and a message type label for characterizing a message type, and the sample prompt tones are annotated with a scenario label for characterizing a usage scenario, a device type label for characterizing a device type, and a message type label for characterizing a message type.
[0050] Optionally, when obtaining sample text data, a large amount of text data about task prompts can be collected through various channels, and these texts can come from multiple fields such as text messages, incoming call notifications, event reminders, etc. For example, relevant open text data sets can be collected and obtained from the Internet under the premise of complying with laws, regulations and privacy policies; or text data permitted by users can be obtained from mobile phone manufacturers, operators, etc.
[0051] Optionally, when obtaining the sample prompt tone, the real prompt tone used for the sound prompt on the electronic device can be obtained from an open source audio database, or the real prompt tone used for the sound prompt on the electronic device can be obtained from a server of a mobile phone manufacturer.
[0052] After obtaining the above sample text data and sample prompt sounds, the sample text data and sample prompt sounds can be annotated with scene tags for characterizing usage scenarios, device type tags for characterizing device types, and message type tags for characterizing message types. Among them, the usage scenarios, device types of electronic devices, and message types of notification messages corresponding to the sample text data can be determined based on the keywords, semantics, etc. in the sample text data, and the above scene tags, device type tags, and message type tags can be annotated for them; in addition, the scene tags, device type tags, and message type tags corresponding to the sample prompt sounds can be obtained by playing the obtained sample prompt sounds and performing the annotation operations performed by the user after hearing the sample prompt sounds.
[0053] When training the prompt tone generation model, the sample text data can be input into the feature extraction module, and the feature extraction module identifies the features used to characterize the usage scenario, the features used to characterize the device type, and the features used to characterize the message type for the sample text data, and then inputs the identified features into the audio generation module, and the audio generation module outputs the generated audio according to the input features; then, according to the scene labels, device type labels, and message type labels annotated by the sample text data, the sample prompt tone corresponding to the scene labels, device type labels, and message type labels is determined, and the generated loss value is determined according to the determined sample prompt tone and the generated audio output by the audio generation module; after determining the generated loss value, the prompt tone generation model is iteratively updated according to the generated loss value until the prompt tone generation model meets the training termination condition, and the trained prompt tone generation model is obtained. Among them, the generated loss value can be determined according to the difference in audio features between the above sample prompt tone and the generated audio. That is to say, the sample text data and the sample prompt tone with the same scene label, device type label, and message type label are used as a group of training samples, the sample text data is used as input data, and the sample prompt tone is used as a reference for the output data to train the prompt tone generation model.
[0054] Optionally, the Adam optimizer can be used to iteratively train the prompt sound generation model according to the total loss value until the total loss value corresponding to the prompt sound generation model converges, and the model at this time is saved to obtain the trained prompt sound generation model. Among them, the Adam optimizer combines the advantages of the two optimization algorithms AdaGra (Adaptive Gradient) and RMSProp, comprehensively considers the first moment estimation (First Moment Estimation, i.e. the mean of the gradient) and the second moment estimation (Second Moment Estimation, i.e. the uncentered variance of the gradient), and calculates the update step size.
[0055] Optionally, the training termination condition may include: the number of iterative training reaches the target number; or the total loss value corresponding to the prompt tone generation model meets the set conditions. Optionally, the convergence condition is to make the total loss value as small as possible, using an initial learning rate of 1e-3, the learning rate decays with the cosine of the step number, batch_size=8, and after training for 16 epochs, the convergence is considered complete. Among them, batch_size can be understood as a batch processing parameter, and its limit value is the total number of samples in the training set. Epoch refers to the number of times all the samples in the training set are used for training. In layman's terms, the value of epoch is how many times the entire data set is rounded, and 1 epoch is equal to using all the samples in the training set for training once. Optionally, the total loss value meeting the set conditions may include: the total loss value is less than a set threshold. Of course, the specific set conditions may not be used as a limitation.
[0056] Optionally, a discriminative network can be added when training the prompt sound generation model. That is to say, the initial prompt sound generation model before training can be a generative adversarial network (GAN). The GAN model is a deep learning model that produces a fairly good output through mutual game learning between at least two models in the framework: a generative model and a discriminative model.
[0057] In the training process of GAN, the feature extraction module and the audio generation module are the generation model of GAN, and the above discriminant network is the discriminant model of GAN. The goal of GAN is to generate real prompt sounds as much as possible to deceive the discriminant network, and the goal of the discriminant network is to separate the audio generated by the generation model from the real prompt sound (i.e. sample prompt one) as much as possible. In this way, a dynamic "game process" is formed between the generation model and the discriminant network. During the training process, the generated audio output by the generation network can be input into the discriminant network, and the above sample prompt sound can be input into the discriminant network, thereby obtaining the discriminant network's discriminant result for the generated audio output by the generation model and the discriminant result for the sample prompt sound; then, based on the discriminant network's discriminant result for the generated audio output by the generation model and the discriminant result for the sample prompt sound, the discriminant loss of the discriminant network can be determined; after each time the sample text data is input into the above model, the above generation loss and the discriminant loss of the discriminant network can be obtained, thereby, the total loss value can be determined based on the generation loss and the discriminant loss, and the prompt sound generation model can be iteratively trained based on the total loss value, thereby obtaining the above feature extraction module, audio generation module and discriminant network after training, and the above feature extraction module and audio generation module after training are used as the trained prompt sound generation model.
[0058] Optionally, the above sample text data and sample prompt sounds can also be annotated with emotional labels representing emotions, such as emotional labels representing sadness, happiness, excitement, and excitement; in this way, for the trained prompt sound generation model, when generating prompt content for input into the prompt sound generation model, content describing emotional information can also be added, so that the prompt sound generation model can generate prompt sounds corresponding to the usage scenario, device type, message type of the notification message, and emotional information according to the prompt content. Among them, the emotional information used when generating prompt content for input into the prompt sound generation model can identify emotional information based on the collected voices of users in the environment, chat information of users when chatting in the current usage scenario, etc.
[0059] Optionally, the above sample text data and sample prompt sound can also be marked with a priority label of the notification message, wherein the priority of notification messages of different message types can be different, and the priority can be determined according to the user's setting operation of the priority of each message type. Emergency calls and work emails can have higher priorities, while social media notifications and application update prompts can have lower priorities; in this way, for the trained prompt sound generation model, when generating prompt content for input into the prompt sound generation model, content describing the priority can also be added, so that the prompt sound generation model can generate a prompt sound that matches the priority, usage scenario, device type and message type of the notification message corresponding to the prompt content. For example, for high-priority notifications such as emergency calls or important emails, a more prominent and easy-to-attract prompt sound can be generated through the above method; for low-priority notifications such as social media notifications or application updates, a more relaxed and low-key prompt sound can be generated. In this way, users can distinguish and identify notification messages of different message types more quickly and accurately.
[0060] Optionally, the duration of the above sample prompt sound is within the target duration range. In the process of training the prompt sound generation model, when determining the above generation loss, the generation loss can also be determined based on the difference between the duration of the generated audio and the duration of the sample prompt sound. Thus, the trained prompt sound generation model can ensure that the duration of the generated prompt sound is within the target duration range, so that the generated prompt sound is both recognizable and can ensure the user experience in different scenarios.
[0061] In a possible implementation, it is possible to train prompt tone generation models of different prompt tone styles, such as prompt tone generation models of hardcore, soft language, funny, etc. When the electronic device generates the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the electronic device can call the prompt tone generation model corresponding to the selected target style according to the target style pre-selected by the user to generate the target prompt tone of the target style corresponding to the first notification message. In this way, the user's needs for prompt tones of different styles can be met.
[0062] In a possible implementation, it is also possible to train prompt sound generation models with different timbres, such as prompt sound generation models with male voice, female voice, machine voice, etc. When the electronic device generates the target prompt sound corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the electronic device can call the prompt sound generation model corresponding to the selected target timbre according to the target timbre pre-selected by the user to generate the target prompt sound of the target timbre corresponding to the first notification message. In this way, the user's demand for prompt sounds with different timbres can be met.
[0063] In a possible implementation, the above prompt tone generation model can be deployed in an electronic device, so that when the electronic device needs to generate a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the prompt tone generation model deployed in the electronic device can be called to generate the prompt tone. In this way, the speed at which the electronic device determines the prompt tone of the first notification message can be improved.
[0064] In a possible implementation, the above prompt tone generation model can also be deployed on a server. When the electronic device needs to generate a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the current usage scenario, the device type of the electronic device, and the message type of the first notification message can be sent to the server. The server generates a corresponding prompt tone according to the deployed prompt tone generation model and the received usage scenario, device type, and message type, and returns the generated prompt tone to the electronic device; correspondingly, the electronic device can receive the prompt tone returned by the server, and use the received prompt tone as the target prompt tone corresponding to the first notification message. In this way, the storage space of the electronic device and the computing resources of the electronic device can be reduced.
[0065] In some embodiments, when the electronic device generates the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, it can also obtain the first candidate prompt tone that matches the device type of the electronic device and the message type of the first notification message from the first candidate prompt tone corresponding to the first notification message as the second candidate prompt tone; based on the current usage scenario and the second candidate prompt tone, the target prompt tone corresponding to the first notification message is generated. Among them, the above first candidate prompt tone can be the basic prompt tone corresponding to each notification message stored in the electronic device, and the above first candidate prompt tone is corresponding to the device type of the electronic device, such as the basic prompt tone corresponding to the notification message such as the incoming call notification, email notification, notification of social software, emergency notification, etc. in the smart phone; after determining the corresponding candidate prompt tone, the target prompt tone corresponding to the first notification message can be further generated according to the current usage scenario and the candidate prompt tone.
[0066] In a possible implementation, when generating a target prompt tone corresponding to the first notification message based on the current usage scenario and the second candidate prompt tone, the second candidate prompt tone can be adjusted based on the current usage scenario to obtain the adjusted second candidate prompt tone as the target prompt tone corresponding to the first notification message. It can be understood that in different usage scenarios, users have different requirements for the volume, pitch, rhythm and other audio parameters of the prompt tone of notification messages of the same message type in different usage scenarios. Therefore, based on the current usage scenario, the audio parameters of the determined first candidate prompt tone can be further adjusted. For example, in an office scenario, the volume of the first candidate prompt tone can be reduced so that the audio parameters of the obtained prompt tone match the current usage scenario.
[0067] Optionally, the electronic device may also determine the target priority corresponding to the message type of the first notification message, wherein the priorities corresponding to different message types may be different, and the priority may be determined according to the user's setting operation for the priority of each message type, and emergency calls and work emails may have higher priorities, while social media notifications and application update prompts may have lower priorities. When adjusting the first candidate audio, the electronic device may also adjust the audio parameters such as the volume, pitch, and rhythm of the first candidate audio according to the above target priority, wherein the volume, pitch, and rhythm of the first candidate audio are positively correlated with the above target priority. For example, for high-priority notifications such as emergency calls or important emails, the volume, pitch changes, and rhythm may be increased to make them easier to attract the user's attention; for low-priority notifications such as social media notifications or application updates, the volume, pitch changes, and rhythm may be reduced to minimize interference with the user. In this way, users can more quickly and accurately distinguish and identify notification messages of different message types.
[0068] Step S230: Determine the target prompt tone as the current prompt tone of the first notification message.
[0069] In the embodiment of the present application, step S230 can refer to the contents of other embodiments and will not be repeated here.
[0070] The method for determining the prompt tone provided in the embodiment of the present application generates a corresponding prompt tone according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, so that the prompt tone determined for the notification message can be suitable for the current usage scenario and the sound prompt of the notification message of this message type, thereby improving the sound prompt effect of the notification message, and also reducing the user's operations in setting the notification message, thereby improving the user's usage experience.
[0071] See also Figure 5 , Figure 5 A flow chart of a method for determining a prompt tone provided by another embodiment of the present application is shown. The method for determining a prompt tone is applied to the above electronic device. Figure 5 The process shown is described in detail, and the method for determining the prompt tone may specifically include the following steps:
[0072] Step S310: Based on the device type of the electronic device, the message type of each notification message in the electronic device, and different usage scenarios, generate a first prompt tone for each notification message in the electronic device in different usage scenarios.
[0073] In an embodiment of the present application, the electronic device may also generate a first prompt tone for each notification message in the electronic device in different usage scenarios according to its device type, the message type of each notification message in the electronic device, and different usage scenarios. That is, for each notification message, a first prompt tone corresponding to the message type and device type in different usage scenarios is generated, and the generated first prompt tone is stored, and the correspondence between the first prompt tone and the device type, message type, and usage scenario is stored. Among them, the way in which the electronic device generates the first prompt tone can refer to the way in which the electronic device generates the prompt tone according to the usage scenario, message type, and device type in the previous embodiment, and will not be repeated here.
[0074] In some implementations, when a new notification message is added to the electronic device, a first prompt tone corresponding to the new notification message may also be generated for the new notification message. For example, when a new application is installed on the electronic device, and the new application can generate a notification message, a new notification message is added to the electronic device, and a first prompt tone corresponding to the new notification message is required.
[0075] Step S320: Determine the current usage scenario of the electronic device.
[0076] In the embodiment of the present application, step S320 can refer to the contents of other embodiments and will not be repeated here.
[0077] Step S330: Obtain, from the pre-generated first prompt tones, a first prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message as a target prompt tone corresponding to the first notification message.
[0078] In an embodiment of the present application, after the electronic device determines the current usage scenario, based on the determined current usage scenario, when obtaining the corresponding prompt tone for the first notification message, the first prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message can be obtained from the pre-generated first prompt tones as the target prompt tone corresponding to the first notification message. The electronic device can determine the first prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message based on the stored correspondence between the first prompt tone and the device type, the message type, and the usage scenario.
[0079] In some embodiments, among the first prompt tones pre-generated above, for each notification message, a first prompt tone corresponding to the message type, device type and different usage scenarios can also be generated for each notification message for different regions and languages. For example, a first prompt tone in Mandarin and a local language can be generated for China. In this way, when determining the prompt tone corresponding to the notification message, the first prompt tone corresponding to the target region and language can also be determined based on the target region and language to which the user corresponding to the electronic device belongs, and then the first prompt tone that matches the current usage scenario, the device type of the electronic device and the message type of the first notification message can be determined from the first prompt tones corresponding to the target region and language. As a result, the prompt tone determined for the notification message can conform to local cultural habits and language environment.
[0080] Step S340: Determine the target prompt tone as the current prompt tone of the first notification message.
[0081] In the embodiment of the present application, step S340 can refer to the contents of other embodiments and will not be repeated here.
[0082] The method for determining a prompt tone provided in an embodiment of the present application pre-generates a prompt tone corresponding to the message type of the notification message, the device type of the electronic device, and different usage scenarios for each notification message. When the electronic device actually needs to determine the prompt tone, a matching prompt tone is determined from the pre-generated prompt tones according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device. The prompt tone determined for the notification message can be applicable to the current usage scenario, and the sound prompt for notification messages of this message type can be improved, thereby reducing the user's operations in setting notification messages and improving the user experience. In addition, by directly determining the matching prompt tone from the pre-generated prompt tones, the speed at which the electronic device determines the prompt tone can also be improved.
[0083] See also Figure 6 , Figure 6 A flow chart of a method for determining a prompt tone provided by another embodiment of the present application is shown. The method for determining a prompt tone is applied to the above electronic device. Figure 6 The process shown is described in detail, and the method for determining the prompt tone may specifically include the following steps:
[0084] Step S410: Determine the current usage scenario of the electronic device.
[0085] In the embodiment of the present application, step S410 can refer to the contents of other embodiments and will not be repeated here.
[0086] Step S420: Based on the current usage scenario, determine a first notification message that needs to be prompted by a prompt tone from the notification messages of the electronic device.
[0087] In an embodiment of the present application, taking into account that in some usage scenarios, for notification messages of some message types, it may not be necessary to play a prompt tone, but rather to mute or vibrate to prompt. For example, in a usage scenario during a meeting, it is not necessary to play a prompt tone for all notification messages. For another example, in a usage scenario during sleep, a lower volume prompt tone is required for notification messages of emergency calls, and it is not necessary to play a prompt tone for notification messages such as news push. Therefore, before determining the prompt tone corresponding to the notification message, it is also possible to determine the first notification message that needs to be prompted by a prompt tone based on the current usage scenario and the message type of each notification message in the electronic device.
[0088] In some embodiments, the electronic device may store a correspondence between different usage scenarios and message types that need to be prompted by a prompt tone. The electronic device may determine the target message type that needs to be prompted by a prompt tone corresponding to the current usage scenario based on the current usage scenario, and then determine the notification message of the target message type, that is, obtain the first notification message that needs to be prompted by a prompt tone in the notification message of the electronic device.
[0089] Step S430: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtain a target prompt tone corresponding to the first notification message.
[0090] In an embodiment of the present application, after determining the first notification message that needs to be prompted by a prompt tone, the target prompt tone corresponding to the first notification message can be obtained based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message. The method of obtaining the prompt tone based on the usage scenario, device type, and message type can refer to the contents of the aforementioned embodiment and will not be repeated here.
[0091] Step S440: Determine the target prompt tone as the current prompt tone of the first notification message.
[0092] In the embodiment of the present application, step S440 can refer to the contents of other embodiments and will not be repeated here.
[0093] Step S450: In response to the received first notification message, play the current prompt tone of the first notification message.
[0094] In an embodiment of the present application, after the target prompt tone is determined as the current prompt tone of the first notification message, the electronic device, upon receiving the first notification message, can play the current prompt tone of the first notification message in response to the received first notification message, thereby realizing a sound prompt for the first notification message through the determined prompt tone.
[0095] In some embodiments, when the electronic device plays the current prompt tone of the first notification message in response to the received first notification message, the electronic device may determine the first prompt volume based on at least one of the current usage scenario, the device type, and the message type of the first notification message; and play the current prompt tone of the first notification message based on the first prompt volume. That is, in addition to determining the prompt tone corresponding to the first notification message based on the determined current usage scenario, the device type, and the message type of the first notification message, the electronic device may also control the playback volume of the prompt tone of the first notification message based on at least one of the current usage scenario, the device type, and the message type of the first notification message, so as to better provide sound prompts. For example, the playback volume can be determined according to the usage scenario. In a quiet usage scenario (such as an office, library, etc.), a lower volume can be used, and in a noisy usage scenario (such as public transportation, cafes, etc.), a higher volume can be used to ensure that the user can notice the notification message. For another example, the playback volume can be determined according to the message type. For example, in a driving usage scenario, a higher volume can be used for notification messages related to driving, such as traffic condition updates and navigation information, and a lower volume can be used for notification messages that are not related to driving (such as notification messages pushed by social software or applications) to avoid interfering with driving. For another example, the playback volume can be determined according to the device type. For example, for a smart watch, a higher volume can be used due to its small speaker, and for a tablet computer, a lower volume can be used.
[0096] In some embodiments, in addition to playing the prompt tone, a vibration prompt may also be required for some notification message prompts. Therefore, the electronic device can also determine the second vibration intensity based on at least one of the current usage scenario, device type, and message type of the first notification message; according to the second vibration intensity, a vibration prompt is performed for the first target notification message. For example, the vibration intensity can be determined according to the usage scenario. In a quiet usage scenario (such as an office, library, etc.), a lower vibration intensity can be used, and in a noisy usage scenario (such as public transportation, cafes, etc.), a higher vibration intensity can be used to ensure that the user can notice the notification message.
[0097] Step S460: In response to the received first target notification message, a vibration prompt is provided for the first target notification message, where the first target notification message is any notification message of the electronic device except the first notification message.
[0098] In the embodiment of the present application, for notification messages other than the first notification message in the notification message of the electronic device, that is, notification messages that do not need to be prompted by playing a prompt tone in the current usage scenario, a vibration prompt can be used for prompting. If the electronic device receives any notification message other than the above first notification message in the notification message of the electronic device (as the first target notification message), it can respond to the received first target notification message and vibrate the first target notification message.
[0099] In some implementations, the first vibration intensity may be determined based on at least one of the current usage scenario, the device type, and the message type of the first target notification message; and the first target notification message may be vibrated according to the first vibration intensity. For example, the vibration intensity may be determined according to the message type, and specifically, the priority corresponding to the message type may be determined. The priorities of notification messages of different message types may be different, and the priority may be determined according to the user's setting operation for the priority of each message type. The vibration intensity may be positively correlated with the above priority.
[0100] The method for determining a prompt tone provided in an embodiment of the present application determines the actual usage scenario of the electronic device, and then determines the notification message that needs to be prompted by playing the prompt tone in the current usage scenario, and determines the corresponding prompt tone for the notification message according to the actual usage scenario of the electronic device, the message type of the notification message and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operations in setting notification messages, and improving the user's usage experience; and for notification messages that do not need to be prompted by playing the prompt tone, when prompting these notification messages, prompts are given by vibration prompts, thereby meeting the user's prompt requirements for notification messages in different usage scenarios.
[0101] See also Figure 7 , Figure 7 A flow chart of a method for determining a prompt tone provided by another embodiment of the present application is shown. The method for determining a prompt tone is applied to the above electronic device. Figure 7 The process shown is described in detail, and the method for determining the prompt tone may specifically include the following steps:
[0102] Step S510: Acquire the current system time of the electronic device, location data of the current location, sensor data collected by the target sensor, device status data, schedule data, and behavior log data.
[0103] In the embodiment of the present application, when determining the current usage scenario, the electronic device can obtain the current system time of the electronic device, the location data of the current location, the sensor data collected by the target sensor, the device status data, the schedule data and the behavior log data. Among them, the target sensor can be a motion sensor, a brightness sensor, etc.; the device status data can include the connection status of the wireless network, the connection status of Bluetooth, etc. It can be understood that the system time can reflect the current working day and time period (such as morning, afternoon, evening, etc.), the location data can reflect the user's environment (such as at home, in the company, in the mall, etc.), the motion data collected by the target sensor can reflect the user's dynamic and static state, the schedule data can reflect the things that the user may do at different times, etc., and the behavior log data can reflect the user's habits and preferences, so the behavior log data can also provide references for the things that the user may do at different times, the location, etc., so the above data can be obtained so that the electronic device can be determined in the current usage scenario (i.e., the current usage scenario) according to the above data.
[0104] Step S520: Input the current system time, location data, sensor data, device status data, schedule data, and behavior log data into a pre-trained scene recognition model to obtain the current usage scene of the electronic device output by the scene recognition model.
[0105] In the embodiment of the present application, after obtaining the current system time, location data, sensor data, device status data, schedule data and behavior log data, the current system time, location data, sensor data, device status data, schedule data and behavior log data can be input into a pre-trained scene recognition model to obtain a scene recognition result output by the scene recognition model, and the scene recognition result includes the current usage scene of the electronic device. Among them, the scene recognition model can be a decision tree, a support vector machine, a neural network, etc., and the specific model type of the scene recognition model may not be limited.
[0106] In one possible implementation, the scene recognition model can be trained in the following manner: obtaining system time, location data, sensor data, device status data, schedule data, and behavior log data in different usage scenarios, and using the obtained data as sample data to obtain a sample data set; based on the sample data set, training the initial recognition model to obtain a trained scene recognition model.
[0107] Optionally, after obtaining the sample data set, the sample data in the sample data set may be preprocessed. The preprocessing may include preliminary processing and cleaning of the sample data, such as removing outliers, filling missing values, data standardization, etc., so as to improve the data quality of the sample data and make the trained scene recognition model more accurate in identifying usage scenarios.
[0108] Step S530: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtain a target prompt tone corresponding to the first notification message.
[0109] Step S540: Determine the target prompt tone as the current prompt tone of the first notification message.
[0110] In the embodiment of the present application, step S530 and step S540 can refer to the contents of the aforementioned embodiment and will not be described again here.
[0111] The method for determining a prompt tone provided in an embodiment of the present application determines a corresponding prompt tone for a notification message according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operations for setting notification messages, and improving the user's usage experience; in addition, when determining the current usage scenario of the electronic device, by obtaining the current system time of the electronic device, the location data of the current location, the sensor data collected by the target sensor, the device status data, the schedule data, and the behavior log data, and using a pre-trained scenario recognition model to identify the usage scenario, the accuracy of the determined usage scenario is ensured, thereby improving the accuracy of the determined prompt tone.
[0112] See also Figure 8 , which shows a structural block diagram of a device 600 for determining a prompt tone provided in an embodiment of the present application. The device 600 for determining a prompt tone applies the above-mentioned electronic device, and the device 600 for determining a prompt tone includes: a scene recognition module 610, a prompt tone acquisition module 620, and a prompt tone setting module 630. Among them, the scene recognition module 610 is used to determine the current usage scenario of the electronic device; the prompt tone acquisition module 620 is used to obtain the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message; the prompt tone setting 630 module is used to determine the target prompt tone as the current prompt tone of the first notification message.
[0113] In some implementations, the prompt tone acquisition module 620 may be specifically configured to generate a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message.
[0114] In a possible implementation, the prompt tone acquisition module 620 can be specifically used to generate a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, and using a pre-trained prompt tone generation model.
[0115] In a possible implementation, the prompt tone acquisition module 620 can be specifically used to obtain a first candidate prompt tone that matches the device type of the electronic device and the message type of the first notification message from the first candidate prompt tone corresponding to the first notification message, as the second candidate prompt tone; and generate a target prompt tone corresponding to the first notification message based on the current usage scenario and the second candidate prompt tone.
[0116] Optionally, the prompt tone acquisition module 620 may also adjust the second candidate prompt tone based on the current usage scenario to obtain an adjusted second candidate prompt tone as the target prompt tone corresponding to the first notification message.
[0117] In some embodiments, the prompt tone acquisition module 620 can be specifically used to obtain a first prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message from a pre-generated first prompt tone, as a target prompt tone corresponding to the first notification message.
[0118] In a possible implementation, the device 600 for determining a prompt tone may further include a prompt tone generation module. The prompt tone generation module is used to generate a first prompt tone for each notification message in the electronic device in different usage scenarios based on the device type, the message type of each notification message in the electronic device, and different usage scenarios.
[0119] In some embodiments, the device 600 for determining the prompt tone may also include a message determination module, which is used to determine the first notification message that needs to be prompted by a prompt tone from the notification messages of the electronic device based on the current usage scenario, before obtaining the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message.
[0120] In a possible implementation, the device 600 for determining the prompt tone may also include a first prompt module, which is used to vibrate and prompt the first target notification message in response to a received first target notification message, wherein the first target notification message is any notification message in the notification message of the electronic device except the first notification message.
[0121] In a possible implementation, the first prompt module can be specifically used to determine a first vibration intensity in response to a received first target notification message based on the current usage scenario, the device type, and at least one of the message types of the first target notification message; and to vibrate the first target notification message according to the first vibration intensity.
[0122] In some embodiments, the device 600 for determining the prompt tone may also include a second prompt module, which is used to play the current prompt tone of the first notification message in response to the received first notification message after the target prompt tone is determined as the current prompt tone of the first notification message.
[0123] In a possible implementation, the second prompt module can be specifically used to determine a first prompt volume in response to a received first notification message based on the current usage scenario, the device type, and at least one of the message types of the first notification message; and based on the first prompt volume, play the current prompt sound of the first notification message.
[0124] In some embodiments, the scene recognition module 610 can be specifically used to obtain the current system time of the electronic device, location data of the current location, sensor data collected by the target sensor, device status data, schedule data, and behavior log data; input the current system time, location data, sensor data, device status data, schedule data, and behavior log data into a pre-trained scene recognition model to obtain the current usage scenario of the electronic device output by the scene recognition model.
[0125] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and modules can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here.
[0126] In several embodiments provided in the present application, the coupling between modules may be electrical, mechanical or other forms of coupling.
[0127] In addition, each functional module in each embodiment of the present application can be integrated into a processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The above integrated modules can be implemented in the form of hardware or software functional modules.
[0128] In summary, the solution provided by the present application determines the current usage scenario of the electronic device; based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtains the target prompt tone corresponding to the first notification message; and determines the target prompt tone as the current prompt tone of the first notification message. In this way, it is possible to determine the corresponding prompt tone for the notification message according to the actual usage scenario of the electronic device, the message type of the notification message, and the device type of the electronic device, thereby improving the sound prompt effect of the notification message, reducing the user's operations in setting the notification message, and improving the user's experience.
[0129] Please refer to Fig. 9 , which shows a structural block diagram of an electronic device provided in an embodiment of the present application. The electronic device 100 may be an electronic device capable of running applications, such as a smart phone, a tablet computer, a smart watch, a smart home appliance, a laptop computer, etc. The electronic device 100 in the present application may include one or more of the following components: a processor 110, a memory 120, and one or more applications, wherein the one or more applications may be stored in the memory 120 and configured to be executed by one or more processors 110, and the one or more applications are configured to execute the method described in the aforementioned method embodiment.
[0130] The processor 110 may include one or more processing cores. The processor 110 uses various interfaces and lines to connect various parts of the entire electronic device 100, and executes various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 120, and calling data stored in the memory 120. Optionally, the processor 110 can be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 110 can integrate one or a combination of a central processing unit (CPU), a 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 110, but may be implemented separately through a communication chip.
[0131] The memory 120 may include a random access memory (RAM) or a read-only memory (ROM). The memory 120 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 120 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. The data storage area may also store data (such as a phone book, audio and video data, chat record data) created by the electronic device 100 during use.
[0132] Please refer to Fig.10 , which shows a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable medium 800 stores program codes, which can be called by a processor to execute the method described in the above method embodiment.
[0133] The computer readable storage medium 800 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 800 includes a non-transitory computer-readable storage medium. The computer readable storage medium 800 has storage space for program code 810 that performs 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 810 can be compressed, for example, in an appropriate form.
[0134] 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 features 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 method for determining a prompt tone, characterized in that: Applied to electronic equipment, the method comprises: Determining a current usage scenario of the electronic device; Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, obtaining a target prompt tone corresponding to the first notification message; The target prompt tone is determined as the current prompt tone of the first notification message.
2. The method according to claim 1, characterized in that The acquiring, based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, a target prompt tone corresponding to the first notification message includes: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, a target prompt tone corresponding to the first notification message is generated.
3. The method according to claim 2, characterized in that The generating a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message includes: Based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, and using a pre-trained prompt tone generation model, a target prompt tone corresponding to the first notification message is generated.
4. The method according to claim 2, characterized in that: The generating a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message includes: From the first candidate prompt tones corresponding to the first notification message, obtaining a first candidate prompt tone that matches the device type of the electronic device and the message type of the first notification message as a second candidate prompt tone; Based on the current usage scenario and the second candidate prompt tone, a target prompt tone corresponding to the first notification message is generated.
5. The method according to claim 4, characterized in that The generating, based on the current usage scenario and the second candidate prompt tone, a target prompt tone corresponding to the first notification message includes: Based on the current usage scenario, the second candidate prompt tone is adjusted to obtain the adjusted second candidate prompt tone as the target prompt tone corresponding to the first notification message.
6. The method according to claim 1, characterized in that The acquiring, based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, a target prompt tone corresponding to the first notification message includes: From the pre-generated first prompt tones, a first prompt tone that matches the current usage scenario, the device type of the electronic device, and the message type of the first notification message is obtained as a target prompt tone corresponding to the first notification message.
7. The method according to claim 6, characterized in that The first prompt tone is obtained in the following manner: Based on the device type, the message type of each notification message in the electronic device, and different usage scenarios, a first prompt tone for each notification message in the electronic device in different usage scenarios is generated.
8. The method according to claim 1, characterized in that Before acquiring the target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message, the method further includes: Based on the current usage scenario, a first notification message that needs to be prompted by a prompt tone is determined from the notification messages of the electronic device.
9. The method according to claim 8, characterized in that The method further comprises: In response to a received first target notification message, a vibration prompt is performed for the first target notification message, where the first target notification message is any notification message of the electronic device except the first notification message.
10. The method according to claim 9, characterized in that The step of providing a vibration prompt for the first target notification message in response to the received first target notification message includes: In response to the received first target notification message, determining a first vibration intensity based on at least one of the current usage scenario, the device type, and a message type of the first target notification message; According to the first vibration intensity, a vibration prompt is performed for the first target notification message.
11. The method according to any one of claims 1 to 10, characterized in that: After determining the target prompt tone as the current prompt tone of the first notification message, the method further includes: In response to the received first notification message, a current prompt tone of the first notification message is played.
12. The method according to claim 11, characterized in that The step of playing the current prompt tone of the first notification message in response to the received first notification message includes: In response to the received first notification message, determining a first prompt volume based on at least one of the current usage scenario, the device type, and a message type of the first notification message; Based on the first prompt volume, play the current prompt tone of the first notification message.
13. The method according to any one of claims 1 to 10, characterized in that: The determining the current usage scenario of the electronic device includes: Acquire the current system time of the electronic device, location data of the current location, sensor data collected by the target sensor, device status data, schedule data, and behavior log data; The current system time, location data, sensor data, device status data, schedule data, and behavior log data are input into a pre-trained scene recognition model to obtain the current usage scene of the electronic device output by the scene recognition model.
14. A device for determining a prompt tone, characterized in that: Applied to electronic equipment, the device comprises: a scene recognition module, a prompt sound acquisition module and a prompt sound setting module, wherein: The scene recognition module is used to determine the current usage scene of the electronic device; The prompt tone acquisition module is used to acquire a target prompt tone corresponding to the first notification message based on the current usage scenario, the device type of the electronic device, and the message type of the first notification message; The prompt tone setting module is used to determine the target prompt tone as the current prompt tone of the first notification message.
15. An electronic device, characterized in that: include: one or more processors; Memory; One or more programs, wherein the 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 13.
16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores program codes, which can be called by a processor to execute the method according to any one of claims 1 to 13.