Application usage prediction and supervision methods, systems, devices, and media

By analyzing application usage data using an LSTM neural network model, the system predicts and alerts users to potential undisciplined behaviors, solving the problem of the inability to provide early warnings in existing technologies and improving user self-discipline and application usage management.

CN117170992BActive Publication Date: 2026-06-23SOUTH CHINA UNIV OF TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SOUTH CHINA UNIV OF TECH
Filing Date
2023-08-09
Publication Date
2026-06-23

AI Technical Summary

Technical Problem

Existing technologies cannot effectively predict and provide early warnings of users' inappropriate application usage behaviors, making it impossible to avoid such behaviors.

Method used

By analyzing user application usage data using an LSTM neural network model, the system predicts application usage time and provides advance notice of undisciplined behavior based on user-defined monitoring options, using application notifications to remind users.

Benefits of technology

It enables users to be alerted before inappropriate behavior occurs, helping them to prevent problems before they happen, improve self-discipline, manage and control application usage behavior, and form healthy usage habits.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117170992B_ABST
    Figure CN117170992B_ABST
Patent Text Reader

Abstract

Embodiments of the application disclose an application use case prediction and supervision method, system, device and medium, the method comprises: obtaining application use duration according to application use data of a user and an LSTM neural network model; filtering out the application use duration that needs to be supervised and reminded according to a supervision option set by the user, and informing the user in advance of the expected self-discipline behavior. Embodiments of the application obtain the next application use duration of the user through a prediction mechanism, and warn according to the self-discipline behavior, so as to achieve the effect of reminding before the bad behavior starts, and prevent problems from occurring.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a method, system, device, and medium for predicting and monitoring application usage, belonging to the field of user monitoring and prediction. Background Technology

[0002] With the development of mobile internet and the popularization of smart terminals, mobile phone apps are emerging in endless streams. These apps are full of massive amounts of information, audio and video, constantly guiding netizens to click and visit. While this enriches people's entertainment, it also changes people's online habits. Therefore, it is necessary to monitor and predict mobile phone users' app usage and provide reminders.

[0003] Many current methods for predicting app behavior only predict the user's current behavior or can only issue warnings after inappropriate app usage occurs, failing to effectively prevent similar situations from happening. Chinese invention patent publication number CN 109522197 A discloses "a method for predicting user app behavior," which obtains user app behavior prediction probability P based on acquired user app behavior data, and finally predicts the user app behavior; however, this only analyzes and predicts app behavior and cannot provide monitoring and reminders before inappropriate behavior occurs. Summary of the Invention

[0004] In view of this, the present invention provides an application usage prediction and monitoring method, system, computer device and storage medium, which obtains the user's next application usage time through a prediction mechanism and issues warnings based on undisciplined behavior, so as to remind the user before the bad behavior begins and prevent problems before they occur.

[0005] The first objective of this invention is to provide a method for predicting and monitoring application usage.

[0006] The second objective of this invention is to provide an application usage prediction and monitoring system.

[0007] A third objective of this invention is to provide a computer device.

[0008] A fourth objective of this invention is to provide a storage medium.

[0009] The first objective of this invention can be achieved by adopting the following technical solution:

[0010] A method for predicting and monitoring application usage, the method comprising:

[0011] The application usage duration is obtained based on the user's application usage data and the LSTM neural network model;

[0012] Based on the monitoring options set by the user, the app usage time that needs to be monitored and reminded is selected, and the user is informed in advance of the expected undisciplined behavior.

[0013] Preferably, the application usage data includes the application start time, application name, and application usage duration;

[0014] The process of obtaining application usage duration based on user application usage data and the LSTM neural network model includes:

[0015] The application in the application usage data is feature-encoded, the record data is stored by constructing a continuous timetable, and it is classified and labeled. The classified and labeled record data includes a 0 / 1 label for whether it has timed out, the duration, the feature number of the application, and the corresponding hour.

[0016] The continuous time schedule is input into the LSTM neural network model for training;

[0017] Based on the application usage data to be predicted and the trained LSTM neural network model, the classification results of application usage are obtained;

[0018] Based on the corresponding duration data and weighting method of the classification results, the application usage duration is obtained, and the classification result is either timeout or no timeout.

[0019] Preferably, the step of storing and classifying the recorded data by constructing a continuous timeline includes:

[0020] Merge duration records that are close in time and belong to the same application;

[0021] Filter out records with durations below a certain threshold based on the duration.

[0022] The recorded data is categorized and labeled based on the filtered data;

[0023] Store the categorized and labeled record data by constructing a continuous timeline.

[0024] Preferably, obtaining the application usage duration based on the corresponding duration data and weighting method according to the classification result includes:

[0025] A two-dimensional matrix table is constructed using the application's feature ID and time points. In the table, each value represents the duration of the application used at a certain time point.

[0026] Assign a history record table and a previous day record table to each user;

[0027] The current day's record is obtained by weighting the historical records with the newly acquired previous day's record. The current day's record is used to indicate the specific application to which the predicted timeout belongs and its expected usage duration.

[0028] Preferably, the data in the continuous time schedule is organized in a 96x24x5 format, where 96 refers to the batch size, 24 refers to the sequence length, and 5 refers to the feature input length.

[0029] Preferably, the LSTM neural network model includes one LSTM layer and one linear layer. The LSTM layer includes five hidden layers with 64 hidden nodes each. When training the LSTM neural network model, Adam is used as the optimizer and cross-entropy is used as the loss function.

[0030] Preferably, the continuous timetable divides the data to be predicted into multiple parts, with each part storing corresponding record data.

[0031] The second objective of this invention can be achieved by adopting the following technical solution:

[0032] An application usage prediction and monitoring system, the system comprising:

[0033] The prediction unit is used to obtain the application usage duration based on the user's application usage data and the LSTM neural network model;

[0034] The monitoring unit is used to filter the application usage time that needs to be monitored and reminded based on the monitoring options set by the user, and to inform the user in advance of the expected undisciplined behavior.

[0035] The third objective of this invention can be achieved by adopting the following technical solution:

[0036] A computer device includes a processor and a memory for storing a processor-executable program, wherein when the processor executes the program stored in the memory, it implements the above-described application usage prediction and monitoring method.

[0037] The fourth objective of this invention can be achieved by adopting the following technical solution:

[0038] A storage medium storing a program that, when executed by a processor, implements the above-described application usage prediction and monitoring method.

[0039] The embodiments of the present invention have the following beneficial effects compared with the prior art:

[0040] This invention predicts application usage time based on user application usage data and an LSTM neural network model. Then, it filters the application usage time requiring monitoring and reminders according to user-defined monitoring options and informs the user in advance of anticipated undisciplined behaviors. This serves as a reminder before undesirable behaviors occur, helping users prevent problems and improve self-discipline. Users can better manage and control their application usage behavior to achieve healthier and more reasonable mobile phone usage habits. Attached Figure Description

[0041] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.

[0042] Figure 1 This is a flowchart of the application usage prediction and monitoring method of Embodiment 1 of the present invention.

[0043] Figure 2 This is a flowchart of the application usage prediction and monitoring method of Embodiment 1 of the present invention.

[0044] Figure 3 This is a block diagram of the LSTM neural network model in Embodiment 1 of the present invention.

[0045] Figure 4 This is a structural block diagram of the application usage prediction and monitoring system of Embodiment 2 of the present invention.

[0046] Figure 5 This is a structural block diagram of the computer device according to Embodiment 3 of the present invention. Detailed Implementation

[0047] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0048] Example 1:

[0049] like Figure 1 and Figure 2 As shown, this embodiment provides a method for predicting and monitoring application usage, which includes the following steps:

[0050] S101. Based on the user's application usage data and the LSTM neural network model, obtain the application usage duration.

[0051] Preferably, the application usage data includes the application start time, application name, and duration of application usage. For example, the application usage data is collected through a monitoring app, which can be an Android app or an iOS app; no limitation is made here. Please refer to Table 1, which shows the collected application usage data.

[0052] Table 1

[0053]

[0054] The process of obtaining application usage duration based on user application usage data and the LSTM neural network model includes:

[0055] S1011. The application in the application usage data is feature-encoded, the record data is stored by constructing a continuous timetable, and the record data is classified and marked. The classified and marked record data includes a 0 / 1 tag indicating whether it has timed out, the duration, the feature number of the application, and the corresponding hour.

[0056] Preferably, constructing a continuous timetable involves dividing a day into 24 parts, or 24 hours, and then those skilled in the art fill in the data dimensions to be predicted into this table. The corresponding application information is entered into the timetable, which could be self-disciplined and non-self-disciplined behavior in a binary classification scenario, the recorded APP ID, or the APP ID and usage duration. It should be noted that the corresponding hour corresponds to a specific point in time within the timetable.

[0057] Preferably, the step of storing and classifying the recorded data by constructing a continuous timeline includes:

[0058] S11. Merge duration records that are close in time and belong to the same application.

[0059] S12. Filter out duration records that are below the duration threshold based on the duration setting threshold.

[0060] The data that is retained represents timeout records.

[0061] S13. Classify and label the recorded data based on the filtered data;

[0062] S14. Store the categorized and labeled record data by constructing a continuous timeline.

[0063] S1012. Input the continuous time schedule into the LSTM neural network model for training.

[0064] Preferably, the data in the continuous time schedule is organized into a 96x24x5 format and then input into the LSTM neural network model for training, where 96 refers to the batch size, 24 refers to the sequence length, and 5 refers to the feature input length.

[0065] Preferred, such as Figure 3 As shown, the LSTM neural network model consists of one LSTM layer and one linear layer. The LSTM layer comprises five hidden layers with 64 hidden nodes each. During training, the LSTM neural network model uses Adam as the optimizer and cross-entropy as the loss function. It's worth noting that the Adam optimizer can adaptively adjust the learning rate, allowing the network to adjust the network node parameters with appropriate step sizes during backpropagation. The cross-entropy loss function is suitable for classification problems; its loss value is small when the predicted result matches the label value, and large when the predicted result differs from the label value, thus penalizing incorrect predictions. The entire network training process moves towards minimizing the total loss value until the set number of training epochs is completed or a sufficiently small loss value is reached.

[0066] The basic idea behind the training is that each data point has a feature vector and an actual label. Initially, all the network parameters are randomly initialized, and predictions can begin. However, the results are still quite poor at this stage, so the parameters need to be adjusted during continuous training to fit the data. During training, the actual labels are continuously used to correct the network's prediction results. "Correction" means adjusting the network parameters based on the loss function value through backpropagation.

[0067] The 96x24x5 data is transformed through hidden layers to reach the linear layer, which maps the 96x24x5 data to a specified dimension. The output of the trained LSTM neural network model is 96x2, where 96 refers to the batch size and 2 refers to the feature length. The model predicts a binary classification, that is, it predicts the probability of timeout and non-timeout, and the class with the higher score is regarded as the next prediction result.

[0068] After training, the application usage in the next time slice can be predicted. The predicted results are then put into the original dataset, and the next one is predicted. This achieves the effect of a sliding window, which can predict the application usage for each subsequent day.

[0069] It is worth noting that the main function of the LSTM layer is to memorize and selectively forget sequential data. It contains three key gating units: an input gate, a forget gate, and an output gate, as well as a memory unit. Through the gating mechanism, the LSTM layer can selectively remember, forget, and output relevant information, allowing the network to better handle long-term dependencies. Simultaneously, since user habits are typically more regular in the recent short period, records closer to the current time should have a greater impact on the network's prediction results. The LSTM layer is essentially a recurrent neural network; the network weights are updated over time, and later data has a greater impact on the network, better fitting recent user habits and making the prediction results more accurate. Therefore, this embodiment fully considers the impact of time on data. In traditional neural networks, the order of input has little impact on the network, but in practical problems, user habits are constantly changing, and more recent data reflects habits more effectively in the short future period. Therefore, it is necessary to consider the impact of the difference in the order of data input on the network. Furthermore, it also solves the problem of long-term data dependencies. Traditional RNNs are prone to gradient vanishing or exploding problems when processing long sequences, making it difficult to capture long-term dependencies. LSTM can effectively solve this problem through its unique gating structure.

[0070] S1013. Based on the application usage data to be predicted and the trained LSTM neural network model, obtain the classification results of application usage.

[0071] S1014. Based on the corresponding duration data and weighting method of the classification result, the application usage duration is obtained, and the classification result is either timeout or no timeout.

[0072] Preferably, obtaining the application usage duration based on the corresponding duration data and weighting method according to the classification result includes:

[0073] S21. Construct a two-dimensional matrix table using the application's feature number and time point. In the table, each value represents the duration of the application used at a certain time point.

[0074] S22. Assign a history record table and a previous day record table to each user.

[0075] S23. The historical records and the newly acquired previous day's records are weighted to obtain the current day's records, wherein the current day's records are used to indicate the specific application to which the predicted timeout belongs and its expected usage duration (possible usage duration).

[0076] The weighting method is a statistical weighting method. Specifically, it assigns a percentage to the duration of application usage based on the number of days remaining until the prediction date, and then adds these percentages together to obtain the predicted duration for that day. For example, data from a certain time yesterday will have a greater impact on today's time, and will be assigned a larger percentage. The records include the following information: the time when excessive mobile application usage occurred (recorded as a timestamp), the application ID, and the estimated usage duration.

[0077] S102. Filter the application usage time that needs to be monitored and reminded according to the monitoring options set by the user, and inform the user in advance of the expected undisciplined behavior.

[0078] This step is communicated to the user via an application notification.

[0079] In practical applications, when a user (userId) opens the supervised app, the server receives a front-end model training request (once a day). It then exports the user's usage data (a continuous timeline built into the database) as a CSV file, named "{userId}.csv" in the corresponding directory of the server's file system, and stores it in the server's model directory. The server's console is then launched, and the command `train.py` is run to train the LSTM neural network model. After the LSTM neural network model training is complete, it first receives a front-end model prediction request (once an hour), then launches the server's console, and runs the command `predict.py` to invoke the model for prediction. Finally, the CSV file containing the prediction results generated by `predict.py` is read from the server's model directory and inserted into the user's prediction results (the `result` table in the database). The front-end then retrieves the prediction result data from the back-end through a lookup request. When a user opens the supervised app, the back-end interface is called to return today's prediction results, and the user is informed in advance of potential undisciplined behaviors, one by one, according to the order of the events.

[0080] Those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing related hardware, and the corresponding program can be stored in a computer-readable storage medium.

[0081] It should be noted that although the method operations of the above embodiments are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. On the contrary, the order of execution of the described steps may be changed. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0082] Example 2:

[0083] like Figure 4 As shown, this embodiment provides an application usage prediction and monitoring system. The system includes a prediction unit 401 and a monitoring unit 402. The specific functions of each unit are as follows:

[0084] The prediction unit 401 is used to obtain the application usage duration based on the user's application usage data and the LSTM neural network model.

[0085] The monitoring unit 402 is used to filter the application usage time that needs to be monitored and reminded according to the monitoring options set by the user, and to inform the user in advance of the expected undisciplined behavior.

[0086] Example 3:

[0087] like Figure 5 As shown, this embodiment provides a computer device, which includes a processor 502, a memory, an input device 503, a display device 504, and a network interface 505 connected via a system bus 501. The processor 502 provides computing and control capabilities. The memory includes a non-volatile storage medium 506 and internal memory 507. The non-volatile storage medium 506 stores an operating system, computer programs, and a database. The internal memory 507 provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium 506. When the computer program is executed by the processor 502, the application usage prediction and monitoring method of Embodiment 1 described above is implemented, as follows:

[0088] The application usage duration is obtained based on the user's application usage data and the LSTM neural network model;

[0089] Based on the monitoring options set by the user, the app usage time that needs to be monitored and reminded is selected, and the user is informed in advance of the expected undisciplined behavior.

[0090] Example 4:

[0091] This embodiment provides a storage medium, which is a computer-readable storage medium, storing a computer program. When the computer program is executed by a processor, it implements the application usage prediction and monitoring method of Embodiment 1 above, as follows:

[0092] The application usage duration is obtained based on the user's application usage data and the LSTM neural network model;

[0093] Based on the monitoring options set by the user, the app usage time that needs to be monitored and reminded is selected, and the user is informed in advance of the expected undisciplined behavior.

[0094] It should be noted that the computer-readable storage medium in this embodiment can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof.

[0095] In this embodiment, the computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this embodiment, the computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying a computer-readable program. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The computer-readable signal medium can also be any computer-readable storage medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The computer program contained on the computer-readable storage medium can be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination thereof.

[0096] The computer-readable storage medium described above can be used to write computer programs for executing this embodiment in one or more programming languages ​​or combinations thereof. These programming languages ​​include object-oriented programming languages—such as Java, Python, and C++—and conventional procedural programming languages—such as C or similar programming languages. The program can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0097] In summary, this invention predicts application usage time based on user application usage data and an LSTM neural network model. Then, it filters the application usage time requiring monitoring and reminders based on user-defined monitoring options and informs the user in advance of anticipated undisciplined behaviors. This serves as a reminder before undesirable behaviors occur, helping users prevent problems and improve self-discipline. Users can better manage and control their application usage behavior to achieve healthier and more reasonable mobile phone usage habits.

[0098] The above description is merely a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope disclosed in the present invention, based on the technical solution and inventive concept of the present invention, shall fall within the scope of protection of the present invention.

Claims

1. A method for predicting and monitoring application usage, characterized in that, The method includes: The application usage duration is obtained based on the user's application usage data and the LSTM neural network model; The application usage data includes the application start time, application name, and duration of application usage. The process of obtaining application usage duration based on user application usage data and the LSTM neural network model includes: The application in the application usage data is feature-encoded, the record data is stored by constructing a continuous timetable, and it is classified and labeled. The classified and labeled record data includes a 0 / 1 label for whether it has timed out, the duration, the feature number of the application, and the corresponding hour. The continuous time schedule is input into the LSTM neural network model for training; Based on the application usage data to be predicted and the trained LSTM neural network model, the classification results of application usage are obtained; Based on the corresponding duration data and weighting method of the classification results, the application usage duration is obtained, and the classification result is either timeout or no timeout. The process of storing and classifying recorded data by constructing a continuous timeline includes: Merge duration records that are close in time and belong to the same application; Filter out records with durations below a certain threshold based on the duration. The recorded data is categorized and labeled based on the filtered data; Store the categorized and labeled record data by constructing a continuous timeline; The process of obtaining application usage time based on the corresponding duration data and weighting method according to the classification results includes: A two-dimensional matrix table is constructed using the application's feature ID and time points. Each value in the table represents the duration of the application used at a certain time point. Assign a history record table and a previous day record table to each user; The current day's record is obtained by weighting the historical records and the newly acquired previous day's record. The current day's record is used to indicate the specific application to which the predicted timeout belongs and its expected usage duration. The data in the continuous time table is organized into a 96x24x5 format, where 96 refers to the batch size, 24 refers to the sequence length, and 5 refers to the feature input length. The continuous timetable divides the data to be predicted into multiple parts, and each part stores corresponding record data; The LSTM neural network model consists of one LSTM layer and one linear layer. The LSTM layer has five hidden layers with 64 hidden nodes each. During training, the LSTM neural network model uses Adam as the optimizer and cross-entropy as the loss function. Based on the monitoring options set by the user, the app usage time that needs to be monitored and reminded is selected, and the user is informed in advance of the expected timeout behavior.

2. An application usage prediction and monitoring system, characterized in that, The system includes: The prediction unit is used to determine the application usage duration based on the user's application usage data and the LSTM neural network model. The application usage data includes the application start time, application name, and duration of application usage. The process of obtaining application usage duration based on user application usage data and the LSTM neural network model includes: The application in the application usage data is feature-encoded, the record data is stored by constructing a continuous timetable, and it is classified and labeled. The classified and labeled record data includes a 0 / 1 label for whether it has timed out, the duration, the feature number of the application, and the corresponding hour. The continuous time schedule is input into the LSTM neural network model for training; Based on the application usage data to be predicted and the trained LSTM neural network model, the classification results of application usage are obtained; Based on the corresponding duration data and weighting method of the classification results, the application usage duration is obtained, and the classification result is either timeout or no timeout. The process of storing and classifying recorded data by constructing a continuous timeline includes: Merge duration records that are close in time and belong to the same application; Filter out records with durations below a certain threshold based on the duration. The recorded data is categorized and labeled based on the filtered data; Store the categorized and labeled record data by constructing a continuous timeline; The process of obtaining application usage time based on the corresponding duration data and weighting method according to the classification results includes: A two-dimensional matrix table is constructed using the application's feature ID and time points. Each value in the table represents the duration of the application used at a certain time point. Assign a history record table and a previous day record table to each user; The current day's record is obtained by weighting the historical records and the newly acquired previous day's record. The current day's record is used to indicate the specific application to which the predicted timeout belongs and its expected usage duration. The data in the continuous time table is organized into a 96x24x5 format, where 96 refers to the batch size, 24 refers to the sequence length, and 5 refers to the feature input length. The continuous timetable divides the data to be predicted into multiple parts, and each part stores corresponding record data; The LSTM neural network model consists of one LSTM layer and one linear layer. The LSTM layer has five hidden layers with 64 hidden nodes each. During training, the LSTM neural network model uses Adam as the optimizer and cross-entropy as the loss function. The monitoring unit is used to filter the application usage time that needs to be monitored and reminded based on the monitoring options set by the user, and to inform the user in advance of the expected timeout behavior.

3. A computer device, comprising a processor and a memory for storing a processor-executable program, characterized in that, When the processor executes the program stored in the memory, it implements the application usage prediction and monitoring method of claim 1.

4. A storage medium storing a program, characterized in that, When the program is executed by the processor, it implements the application usage prediction and monitoring method of claim 1.