File cleaning method and device, storage medium and electronic equipment
By scanning and simulating the cleaning of files on electronic devices, and combining this with an artificial intelligence model to identify abnormal operating interfaces, the problem of accidentally deleting important files during the file cleaning process has been solved, achieving safe and efficient file cleaning.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
- Filing Date
- 2023-10-27
- Publication Date
- 2026-07-21
AI Technical Summary
In existing technologies, important files are easily deleted accidentally during the file cleanup process of electronic devices, leading to malfunctions.
By scanning the files of the application under test and simulating cleaning, and using an artificial intelligence model to determine whether there are any abnormalities in the running interface, it can be determined whether the files to be cleaned can be cleaned.
The security of file cleanup has been improved, preventing file cleanup from affecting the normal functioning of applications.
Smart Images

Figure CN117472395B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic equipment technology, and in particular to a file cleaning method, apparatus, storage medium and electronic equipment. Background Technology
[0002] Electronic devices such as smartphones are becoming increasingly feature-rich, supporting a growing number of applications, including communication apps, camera apps, browsers, shopping apps, games, and mini-programs. These applications generate various files during user interaction, consuming significant amounts of storage space on the devices.
[0003] To save storage space on electronic devices, it is necessary to clean up files on these devices regularly or irregularly. However, during file cleanup, important files may be accidentally deleted, leading to malfunctions in the electronic device. Summary of the Invention
[0004] This application provides a file cleaning method, apparatus, storage medium, and electronic device, which can improve the security of file cleaning.
[0005] This application provides a file cleaning method, including:
[0006] The files of the application under test are scanned to obtain at least one file of the application under test that needs to be cleaned.
[0007] Simulated cleaning is performed on the files to be cleaned;
[0008] Run the application under test and obtain the running interface of the application under test;
[0009] An artificial intelligence model is used to determine whether the running interface is abnormal, in order to determine whether the file to be cleaned can be cleaned.
[0010] This application also provides a file cleaning device, including:
[0011] The file scanning module is used to scan the files of the application under test to obtain at least one file of the application under test that needs to be cleaned.
[0012] The simulation cleaning module is used to simulate cleaning the files to be cleaned.
[0013] The interface acquisition module is used to run the application under test and acquire the running interface of the application under test.
[0014] The cleanup determination module is used to determine whether there are any abnormalities in the running interface through an artificial intelligence model, so as to determine whether the file to be cleaned can be cleaned.
[0015] This application embodiment also provides a storage medium storing a computer program, which, when run on a computer, causes the computer to perform the above-described file cleaning method.
[0016] This application also provides an electronic device, which includes a processor and a memory. The memory stores a computer program, and the processor executes the above-described file cleaning method by calling the computer program stored in the memory.
[0017] The file cleaning method provided in this application can simulate the cleaning of files in the application under test, and use an artificial intelligence model to determine whether there are any abnormalities in the running interface of the application under test after the simulated cleaning, thereby determining whether each file can be cleaned. Therefore, it can clean up the files of the application under test while improving the security of file cleaning and avoiding any impact on the normal function of the application under test after file cleaning. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is a schematic diagram illustrating an application scenario of the file cleaning method according to an embodiment of this application.
[0020] Figure 2 This is a schematic diagram of the first process of the file cleaning method according to an embodiment of this application.
[0021] Figure 3 This is a schematic diagram of a second process for a file cleaning method according to an embodiment of this application.
[0022] Figure 4 This is a schematic diagram of the third process of the file cleaning method according to an embodiment of this application.
[0023] Figure 5 This is a flowchart illustrating the process of determining whether an interface is abnormal in the file cleaning method of this application embodiment.
[0024] Figure 6 This is a schematic diagram of the file cleaning device according to an embodiment of this application.
[0025] Figure 7 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation
[0026] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the protection scope of this application.
[0027] This application provides a file cleaning method that can be applied to electronic devices. These electronic devices can be smartphones, tablets, gaming devices, AR (Augmented Reality) devices, data storage devices, video playback devices, laptops, desktop computing devices, etc.
[0028] refer to Figure 1 , Figure 1 This diagram illustrates an application scenario of the file cleanup method according to an embodiment of this application. The file cleanup method is applied to electronic devices. During the use of an electronic device, applications generate and store a large number of files, such as files a through i. Files a through i can include various types of files, such as program files, configuration files, log files, cache files, and downloaded files. To save storage space on the electronic device, it is necessary to clean up the files stored on the device periodically or irregularly.
[0029] In a practical application example, file cleanup methods can be integrated into a file cleanup tool (SDK), or some implementation steps of the file cleanup method can be integrated into a file cleanup tool (SDK). The file cleanup tool (SDK) can, for example, be a phone manager or a module within a phone manager. The file cleanup tool (SDK) can be used to clean up files stored on electronic devices periodically or irregularly, thereby saving storage space on the electronic devices.
[0030] refer to Figure 2 , Figure 2 This is a schematic diagram of a first embodiment of the file cleaning method of this application. The file cleaning method includes the following steps 110-140:
[0031] 110. Scan the files of the application under test to obtain at least one file to be cleaned.
[0032] In practical applications, electronic devices typically have multiple applications installed, such as communication apps, camera apps, browsers, shopping apps, game apps, and mini-programs. When cleaning up files on an electronic device, each application can be cleaned up individually. Once files for a specific application are being cleaned, that application can be considered the application to be tested.
[0033] When cleaning up files of an application under test, an electronic device first needs to scan the files of the application under test to obtain at least one file of the application under test that needs to be cleaned.
[0034] The files in the application under test can include all files related to that application, such as program files, configuration files, log files, cache files, downloaded files, and other file types. The electronic device can scan these files to identify those to be cleaned. These files can include one or more files. These files can be understood as suspected junk files, i.e., files that need to be cleaned, but it cannot be determined whether cleaning them will affect the normal functionality of the application under test.
[0035] Understandably, in order to maximize the use of storage space on electronic devices, in a feasible application example, as many files as possible can be designated as files to be cleaned up. For example, files that cannot be determined to be junk files during a scan can be designated as files to be cleaned up.
[0036] 120. Simulate cleaning of the files to be cleaned.
[0037] Once an electronic device identifies files to be cleaned, it can simulate cleaning those files. This simulated cleaning can be understood as mimicking deletion, but it doesn't actually delete the files. Instead, it disables them, for example, by preventing any process on the electronic device from accessing or calling the files to be cleaned.
[0038] Understandably, when there are multiple files to be cleaned, during simulated cleanup, one file can be cleaned at a time and subsequent operations can be performed; alternatively, multiple or all files can be cleaned at once and subsequent operations can be performed simultaneously to improve the efficiency of file cleanup.
[0039] 130. Run the application under test and obtain the running interface of the application under test.
[0040] After simulating file cleanup on the electronic device, the application under test is run, and its interface is captured. In practical applications, the application under test can be run using automated scripts, thus reducing user intervention and improving file cleanup efficiency. Understandably, these automated scripts can be integrated into file cleanup tools (SDKs).
[0041] 140. Use an artificial intelligence model to determine if there are any abnormalities in the running interface in order to determine whether the files to be cleaned can be cleaned.
[0042] After an electronic device obtains the running interface of the application under test, it can use an artificial intelligence (AI) model to determine whether the running interface is abnormal, thereby determining whether the file to be cleaned can be cleaned. The AI model can be pre-trained, for example, by training on the running interfaces obtained after cleaning different files from a large number of applications. Based on this model, it can determine whether the running interface of the application under test is abnormal.
[0043] After all files in the application under test have undergone the above processing, it can be determined which files can be cleaned and which cannot. The electronic device then compiles all cleanable files into a set and outputs either a list of cleanable files or a list of file cleanup rules. Once the user confirms the cleanup, the electronic device deletes these cleanable files, thereby freeing up the storage space they occupy.
[0044] In practical applications, after electronic devices output all files that can be cleaned as file cleanup rules, they can also upload the file cleanup rules to the network. Other electronic devices can download the file cleanup rules and clean up files according to the file cleanup rules to free up storage space on the electronic devices.
[0045] The file cleaning method of this application embodiment can simulate cleaning the files of the application under test, and use an artificial intelligence model to determine whether there are any abnormalities in the running interface of the application under test after the simulated cleaning, thereby determining whether each file can be cleaned. Therefore, it can clean the files of the application under test while improving the security of file cleaning and avoiding the impact on the normal function of the application under test after file cleaning.
[0046] In some embodiments, reference Figure 3 , Figure 3 This is a schematic diagram of a second flowchart of the file cleaning method according to an embodiment of this application. Step 130: Running the application under test and obtaining the running interface of the application under test includes the following steps:
[0047] 131. Run each function of the application under test in sequence to display the interface of each function of the application under test;
[0048] 132. During the sequential execution of each function of the application under test, the functional interface displayed by the application under test is collected at a preset frequency to obtain the running interface of the application under test.
[0049] Understandably, in practical applications, the application under test may have multiple functions. For example, for a communication application, it may have functions such as viewing contacts, editing contacts, communication functions, viewing communication records, and application settings.
[0050] Therefore, when running the application under test, each function of the application can be run sequentially to display its interface. For example, this could involve displaying the contact viewing interface, contact editing interface, communication interface, call log viewing interface, and application settings interface of a communication application. During the sequential running of each function, the displayed interface of the application under test is captured at a preset frequency to obtain the application's running interface. For instance, the interface can be captured by taking screenshots, and the captured images are loaded into a cache for further processing.
[0051] In practical applications, the preset frequency can be set according to requirements. Considering the system performance of electronic devices, if the sampling frequency is too high, it will consume a large amount of system resources; while if the sampling frequency is too low, it will be difficult to accurately process the application under test. Therefore, in a feasible application example, the preset frequency can be once per second, that is, the functional interface of the application under test is sampled once every second.
[0052] In some embodiments, reference Figure 4 , Figure 4 This is a schematic diagram of the third process of the file cleaning method according to an embodiment of this application. Step 140: Determining whether the file to be cleaned can be cleaned by using an artificial intelligence model to check for anomalies in the running interface, including the following steps:
[0053] 141. Use an artificial intelligence model to sequentially determine whether there are any anomalies on each interface;
[0054] 142. If there are no abnormalities on any of the interfaces, it is determined that the file to be cleaned can be cleaned; if at least one of the multiple interfaces has an abnormality, the application under test is scored according to the abnormal interface, and the file to be cleaned can be determined according to the score.
[0055] In practical applications, the running interface of the application under test includes multiple interfaces. For example, for a communication application, it includes a contact viewing interface, a contact editing interface, a communication interface, a communication record viewing interface, and an application settings interface.
[0056] Electronic devices can use an artificial intelligence model to sequentially determine whether each interface has any anomalies. If no interface has any anomalies, it means that the simulated cleaning of the files to be cleaned will not affect the normal function of the application under test, and in this case, the files to be cleaned can be determined to be cleaned. If at least one of the multiple interfaces has an anomaly, it means that the simulated cleaning of the files to be cleaned has affected the normal function of the application under test. In this case, the application under test needs to be scored based on the anomaly interface, and the score is used to determine whether the files to be cleaned can be cleaned.
[0057] In some embodiments, when the artificial intelligence model sequentially determines whether each interface has an anomaly, it sequentially determines whether each interface has screen cutoff, abnormal exit, unresponsive function, or blank screen. If the interface does not have screen cutoff, abnormal exit, unresponsive function, or blank screen, the determination result is that the interface does not have an anomaly; if the interface has at least one of screen cutoff, abnormal exit, unresponsive function, or blank screen, the determination result is that the interface has an anomaly.
[0058] Specifically, refer to Figure 5 , Figure 5 This is a flowchart illustrating the process of determining whether an interface is abnormal in the file cleaning method of this application embodiment. The electronic device performs the following steps S1 to S7:
[0059] S1, The automated script runs the application under test and obtains the running interface;
[0060] S2, determine if there is a break in the interface;
[0061] S3, determine if the interface has exited abnormally;
[0062] S4, determine if the interface has any unresponsive functions;
[0063] S5, determine if there is a blank screen on the interface;
[0064] S6. If steps S2, S3, S4, and S5 are all determined to be no, then it is determined that there is no abnormality in the interface.
[0065] S7. If any one of steps S2, S3, S4, or S5 is correct, then the interface is determined to be abnormal.
[0066] Understandably, step S1 can be executed by the electronic device via an automated script, and steps S2 to S7 can be executed by the electronic device via an artificial intelligence model. Specifically, if a screen that should normally be connected is broken in some parts, it is considered a screen break. If the screen contains abnormal keywords such as "unable," "abnormal," or "sorry," or if there is an application crash pop-up, it is considered an abnormal exit. If the screen remains in a loading state for an extended period or is unresponsive for a long time, it is considered a functional unresponsiveness. If a position where content should normally be present on the screen is not displayed, it is considered a blank screen.
[0067] After the multiple checks in steps S2 to S5 above, it can be determined whether there is an anomaly in the interface. It should be noted that in practical applications, the checks in steps S2 to S5 can also be performed in other orders. Figure 5The execution order shown is merely a possible example and does not constitute a limitation on the embodiments of this application.
[0068] Understandably, the presence of an abnormal interface indicates that the normal functionality of the application under test has been affected. In some cases, this impact is temporary or a minor, permissible effect that will not cause inconvenience or disruption to user experience; in such cases, the files to be cleaned are considered safe to clean. However, in other cases, the impact is more severe and will cause inconvenience or disruption to user experience; in such cases, the files to be cleaned are considered unsafe to clean. In this embodiment, when simulated cleaning of the files to be cleaned affects the normal functionality of the application under test, the application is scored based on the abnormal interface. The score reflects the degree of impact, thus determining whether the files to be cleaned can be cleaned based on the score.
[0069] In some embodiments, when scoring an application under test based on an abnormal interface, the electronic device may perform the following steps:
[0070] Determine the type of abnormality present in the abnormal interface. The abnormality types include screen splitting, abnormal exit, unresponsive function, and blank screen.
[0071] Determine the number of anomalies for each anomaly type;
[0072] Each anomaly type is scored based on the number of anomalies in each anomaly type and the preset score corresponding to each anomaly type.
[0073] The scores of multiple anomaly types are summed to obtain the score of the application under test.
[0074] In practical applications, electronic devices can be pre-set with corresponding preset scores for each type of anomaly. These scores reflect the degree of impact of the anomaly type on the application under test; a higher score indicates a greater impact. Anomaly types include screen cutoff, abnormal exit, unresponsive function, and blank screen. For example, the preset score for an abnormal exit is 8 points, for unresponsive function is 6 points, for screen cutoff is 3 points, and for blank screen is 2 points.
[0075] If the interface of the application under test is abnormal, the electronic device can first determine the types of abnormalities present in the abnormal interface and the number of abnormalities for each type when scoring. Then, it scores each abnormality type based on the number of abnormalities for each type and the preset score corresponding to each abnormality type, and adds up the scores of multiple abnormality types to obtain the score of the application under test.
[0076] For example, if the exception types include abnormal exit and no response, and the number of abnormal exit exceptions is 1 and the number of no response exceptions is also 1, then the score corresponding to abnormal exit is 8 points and the score corresponding to no response is 6 points, thus the score of the application under test can be obtained as 14 points.
[0077] For example, if the only exception type is blank screen, and the number of blank screen exceptions is 2, then the score for blank screen is 4 points, and thus the score for the application under test is also 4 points.
[0078] After receiving a score from the application under test, the electronic device can compare this score with a preset scoring threshold to determine whether the files to be cleaned can be cleaned. The preset scoring threshold is a pre-set score that reflects the degree of impact of abnormal interfaces on the application under test.
[0079] If the rating of the application under test is less than the preset rating threshold, it means that the impact of the abnormal interface on the application under test is within an acceptable range, and in this case, the file to be cleaned can be cleaned. If the rating of the application under test is greater than or equal to the preset rating threshold, it means that the impact of the abnormal interface on the application under test exceeds an acceptable range and will seriously affect the user's use of the application under test. Therefore, in this case, the file to be cleaned cannot be cleaned.
[0080] In practice, this application is not limited by the execution order of the described steps. Without causing conflicts, some steps may be performed in other orders or simultaneously.
[0081] As can be seen from the above, the file cleaning method provided in this application includes: scanning the files of the application under test to obtain at least one file to be cleaned; simulating the cleaning of the file; running the application under test and obtaining its running interface; and using an artificial intelligence model to determine whether the running interface is abnormal, thereby determining whether the file to be cleaned can be cleaned. In this file cleaning method, the files to be cleaned in the application under test can be simulated for cleaning, and an artificial intelligence model can be used to determine whether the running interface of the application under test is abnormal after the simulated cleaning, thereby determining whether each file to be cleaned can be cleaned. Therefore, this method can both clean the files of the application under test and improve the security of file cleaning, avoiding any impact on the normal function of the application under test after file cleaning.
[0082] This application also provides a file cleaning device that can be integrated into an electronic device. The electronic device can be a smartphone, tablet, gaming device, AR (Augmented Reality) device, data storage device, video playback device, laptop, desktop computing device, etc.
[0083] refer to Figure 6 , Figure 6 This is a schematic diagram of the structure of a file cleaning device 200 according to an embodiment of this application. The file cleaning device 200 includes: a file scanning module 210, a simulation cleaning module 220, an interface acquisition module 230, and a cleaning determination module 240.
[0084] The file scanning module 210 is used to scan the files of the application under test to obtain at least one file to be cleaned from the application under test.
[0085] The simulation cleanup module 220 is used to simulate the cleanup of files to be cleaned.
[0086] The interface acquisition module 230 is used to run the application under test and acquire the running interface of the application under test;
[0087] The cleaning determination module 240 is used to determine whether there are any abnormalities in the running interface through an artificial intelligence model, so as to determine whether the files to be cleaned can be cleaned.
[0088] In some embodiments, the interface acquisition module 230 is used for:
[0089] Run each function of the application under test in sequence to display the interface of each function of the application under test;
[0090] During the sequential execution of each function of the application under test, the functional interface displayed by the application under test is collected at a preset frequency to obtain the running interface of the application under test.
[0091] In some embodiments, the cleanup determination module 240 is used to:
[0092] The artificial intelligence model is used to sequentially determine whether there are any anomalies in each interface;
[0093] If no abnormalities are found on any of the interfaces, the file to be cleaned can be cleaned; if at least one of the multiple interfaces has an abnormality, the application under test is scored based on the abnormal interface, and the score determines whether the file to be cleaned can be cleaned.
[0094] As you can understand, the specific implementation methods of the above modules can be found in the description of the file cleanup method above, and will not be repeated here.
[0095] In practice, the above modules can be implemented as independent entities or combined in any way to be implemented as the same or several entities.
[0096] As described above, the file cleaning device 200 provided in this application embodiment scans the files of the application under test using a file scanning module 210 to obtain at least one file to be cleaned; a simulation cleaning module 220 performs simulated cleaning of the file to be cleaned; an interface acquisition module 230 runs the application under test and acquires its running interface; and a cleaning determination module 240 uses an artificial intelligence model to determine whether the running interface is abnormal, thereby determining whether the file to be cleaned can be cleaned. This file cleaning device can simulate cleaning the files to be cleaned in the application under test and use an artificial intelligence model to determine whether the running interface of the application under test is abnormal after the simulated cleaning, thus determining whether each file to be cleaned can be cleaned. Therefore, it can both clean the files of the application under test and improve the security of file cleaning, avoiding any impact on the normal function of the application under test after file cleaning.
[0097] This application also provides an electronic device. The electronic device can be a smartphone, tablet computer, gaming device, AR (Augmented Reality) device, data storage device, video playback device, laptop computer, desktop computing device, etc.
[0098] refer to Figure 7 , Figure 7 This is a schematic diagram of the structure of the electronic device 300 according to an embodiment of this application.
[0099] Electronic device 300 includes processor 310 and memory 320. Processor 310 and memory 320 are electrically connected.
[0100] The processor 310 is the control center of the electronic device 300. It connects various parts of the electronic device through various interfaces and lines. By running or calling computer programs stored in the memory 320 and calling data stored in the memory 320, it performs various functions of the electronic device and processes data, thereby monitoring the electronic device as a whole.
[0101] Memory 320 can be used to store computer programs and data. The computer programs stored in memory 320 contain instructions that can be executed in the processor. Computer programs can be composed of various functional modules. Processor 310 executes various functional applications and data processing by calling the computer programs stored in memory 320.
[0102] In this embodiment, the processor 310 in the electronic device 300 loads the instructions corresponding to the processes of one or more computer programs into the memory 320 according to the following steps, and the processor 310 runs the computer programs stored in the memory 320 to perform the following steps:
[0103] Scan the files of the application under test to obtain at least one file that needs to be cleaned.
[0104] Simulate cleaning up the files to be cleaned;
[0105] Run the application under test and obtain its running interface;
[0106] An artificial intelligence model is used to determine if there are any abnormalities in the running interface in order to determine whether the files to be cleaned can be cleaned.
[0107] In some embodiments, when running the application under test and obtaining the running interface of the application under test, the processor 310 performs the following steps:
[0108] Run each function of the application under test in sequence to display the interface of each function of the application under test;
[0109] During the sequential execution of each function of the application under test, the functional interface displayed by the application under test is collected at a preset frequency to obtain the running interface of the application under test.
[0110] In some embodiments, when the processor 310 determines whether the file to be cleaned can be cleaned by using an artificial intelligence model to determine whether the running interface is abnormal, the processor 310 performs the following steps:
[0111] The artificial intelligence model is used to sequentially determine whether there are any anomalies in each interface;
[0112] If no abnormalities are found on any of the interfaces, the file to be cleaned can be cleaned; if at least one of the multiple interfaces has an abnormality, the application under test is scored based on the abnormal interface, and the score determines whether the file to be cleaned can be cleaned.
[0113] although Figure 7 As not shown in the diagram, the electronic device 300 may also include a display screen, camera, Bluetooth module, etc., which will not be described in detail here.
[0114] As described above, this application provides an electronic device that performs the following steps: scanning the files of the application under test to obtain at least one file to be cleaned; simulating the cleaning of the file; running the application under test and obtaining its interface; and using an artificial intelligence model to determine whether the interface is abnormal, thereby determining whether the file to be cleaned can be cleaned. This electronic device can simulate the cleaning of the files of the application under test and use an artificial intelligence model to determine whether the application's interface is abnormal after the simulated cleaning, thus determining whether each file can be cleaned. Therefore, it can clean the files of the application under test while improving the security of file cleaning and avoiding any impact on the normal function of the application under test after file cleaning.
[0115] This application also provides a storage medium storing a computer program, which, when run on a computer, causes the computer to execute the file cleaning method of any of the above embodiments.
[0116] It should be noted that those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, which may include, but is not limited to, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, etc.
[0117] The file cleaning method, apparatus, storage medium, and electronic device provided in the embodiments of this application have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are only for the purpose of helping to understand the method and its core ideas. Furthermore, those skilled in the art will recognize that, based on the ideas of this application, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A file cleaning method, characterized in that, include: The files of the application under test are scanned to obtain at least one file of the application under test that needs to be cleaned. Simulated cleaning is performed on the files to be cleaned; Run the application under test and obtain the running interface of the application under test; An artificial intelligence model is used to determine whether the running interface is abnormal, in order to determine whether the file to be cleaned can be cleaned.
2. The file cleaning method according to claim 1, characterized in that, The operating interface includes multiple interfaces. The step of using an artificial intelligence model to determine whether the operating interface exhibits anomalies, in order to determine whether the file to be cleaned can be cleaned, includes: The artificial intelligence model is used to determine whether each interface is abnormal. If no abnormalities are found in any of the interfaces described, then the file to be cleaned is determined to be cleanable. If at least one of the multiple interfaces is abnormal, the application under test is scored based on the abnormal interface, and the file to be cleaned is determined based on the score.
3. The file cleaning method according to claim 2, characterized in that, The step of using an artificial intelligence model to sequentially determine whether each interface has any anomalies includes: The artificial intelligence model is used to determine whether each interface has issues such as screen cut-offs, abnormal exits, unresponsive functions, or blank screens. If the interface does not exhibit screen tearing, abnormal exit, unresponsive functions, or blank screen, then the judgment result is that the interface does not have any abnormalities. If the interface exhibits at least one of the following: screen splitting, abnormal exit, unresponsive function, or blank screen, the result is that the interface is abnormal.
4. The file cleaning method according to claim 3, characterized in that, The scoring of the application under test based on the abnormal interface includes: Determine the type of abnormality present in the abnormal interface, including screen splitting, abnormal exit, no function response, and blank screen. Determine the number of anomalies for each of the aforementioned anomaly types; Each anomaly type is scored based on the number of anomalies in each anomaly type and the preset score corresponding to each anomaly type. The scores of multiple anomaly types are summed to obtain the score of the application under test.
5. The file cleaning method according to claim 4, characterized in that, The step of determining whether the file to be cleaned can be cleaned based on the score includes: If the score is less than a preset score threshold, then the file to be cleaned is determined to be cleanable. If the score is greater than or equal to the preset score threshold, then the file to be cleaned is determined to be uncleanable.
6. The file cleaning method according to any one of claims 1 to 5, characterized in that, The process of running the application under test and obtaining the running interface of the application under test includes: Run each function of the application under test in sequence to display the interface of each function of the application under test; During the sequential execution of each function of the application under test, the functional interface displayed by the application under test is collected at a preset frequency to obtain the running interface of the application under test.
7. The file cleaning method according to claim 6, characterized in that, The preset frequency is once per second.
8. A file cleaning device, characterized in that, include: The file scanning module is used to scan the files of the application under test to obtain at least one file of the application under test that needs to be cleaned. The simulation cleaning module is used to simulate cleaning the files to be cleaned. The interface acquisition module is used to run the application under test and acquire the running interface of the application under test. The cleanup determination module is used to determine whether there are any abnormalities in the running interface through an artificial intelligence model, so as to determine whether the file to be cleaned can be cleaned.
9. A storage medium, characterized in that, The storage medium stores a computer program that, when run on a computer, causes the computer to perform the file cleaning method according to any one of claims 1 to 7.
10. An electronic device, characterized in that, The electronic device includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program stored in the memory to perform the file cleaning method according to any one of claims 1 to 7.