File renaming method and device
By receiving file renaming requests, using a large model to analyze file features and output a renaming plan, file renaming is automatically performed, solving the time-consuming and error-prone problem of manual renaming in personal cloud storage, and achieving efficient and flexible batch file renaming.
Patent Information
- Application Number
- CN202510733915.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-03
- Publication Date
- 2025-09-19
AI Technical Summary
In the prior art, renaming personal cloud storage files requires manual modification, which is time-consuming and prone to errors.
By receiving file renaming requests, the system uses a large model to analyze file features and output a renaming plan. After user confirmation, renaming is automatically performed, supporting batch file renaming.
Improves file renaming efficiency, reduces labor costs, and enhances renaming flexibility and accuracy.
Smart Images

Figure CN120670387A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of artificial intelligence, in particular to the field of cloud storage, and specifically to a file renaming method and device. Background Art
[0002] With the in-depth application of cloud computing in various fields, cloud storage resource management (personal cloud storage) has emerged. More and more users are using personal cloud storage to store and manage files. This prevents problems such as fragmented file resource storage, file loss due to hard drive damage, and lack of backups, while also facilitating file resource sharing and utilization in daily work.
[0003] In the prior art, renaming files in personal cloud storage usually requires manual modification. There are a large number of files in personal cloud storage that need to be renamed, and manual modification takes a lot of time and effort, and is prone to errors. Summary of the Invention
[0004] The present disclosure provides a file renaming method, apparatus, device, storage medium, and computer program product.
[0005] According to a first aspect of the present disclosure, a file renaming method is provided, comprising: in response to receiving a file renaming request, determining a file to be renamed according to the file renaming request; outputting a renaming scheme based on characteristics of the file to be renamed and the file renaming request; in response to detecting that the renaming scheme is confirmed, modifying the file name of the file to be renamed according to the renaming scheme.
[0006] According to a second aspect of the present disclosure, a file renaming device is provided, comprising: a determination unit, configured to, in response to receiving a file renaming request, determine a file to be renamed according to the file renaming request; an output unit, configured to output a renaming scheme based on features of the file to be renamed and the file renaming request; and a modification unit, configured to, in response to detecting that the renaming scheme is confirmed, modify the file name of the file to be renamed according to the renaming scheme.
[0007] According to a third aspect of the present disclosure, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute any one of the methods described in the first aspect.
[0008] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute any one of the methods according to the first aspect.
[0009] According to a fifth aspect of the present disclosure, a computer program product is provided, comprising a computer program, wherein the computer program implements any one of the methods according to the first aspect when executed by a processor.
[0010] According to a sixth aspect of the present disclosure, a network disk is provided, comprising: a file renaming component, wherein the file renaming component implements any one of the methods according to the first aspect when executed by a processor.
[0011] The file renaming method and device provided by the embodiments of the present disclosure analyze file renaming requests, output a renaming plan, and then perform the renaming after the user confirms it. This can achieve batch file renaming, improve renaming efficiency, and reduce labor costs.
[0012] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] The accompanying drawings are used to better understand the present invention and do not constitute a limitation of the present invention.
[0014] Figure 1 is an exemplary system architecture diagram in which an embodiment of the present disclosure may be applied;
[0015] Figure 2 is a flowchart of an embodiment of a file renaming method according to the present disclosure;
[0016] Figure 3 is a schematic diagram of an application scenario of the file renaming method according to the present disclosure;
[0017] Figure 4 is a flowchart of another embodiment of the file renaming method according to the present disclosure;
[0018] Figure 5 is a structural diagram of an embodiment of a file renaming device according to the present disclosure;
[0019] Figure 6 It is a structural diagram of a computer system of an electronic device suitable for implementing the embodiments of the present disclosure. DETAILED DESCRIPTION
[0020] The following description of exemplary embodiments of the present disclosure is made in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding. These details should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.
[0021] Figure 1 An exemplary system architecture 100 is shown to which an embodiment of the file renaming method or file renaming apparatus disclosed herein can be applied.
[0022] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, 103, a network 104, and a server 105. Network 104 is a medium for providing communication links between terminal devices 101, 102, 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links or fiber optic cables.
[0023] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as personal cloud storage apps, 3D video players, web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0024] Terminal devices 101, 102, 103 can be hardware or software. When terminal devices 101, 102, 103 are hardware, they can be various electronic devices with display screens and support personal cloud storage APP, including but not limited to smart phones, tablet computers, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III, Moving Picture Experts Compression Standard Audio Layer 3), MP4 (Moving Picture Experts Group Audio Layer IV, Moving Picture Experts Compression Standard Audio Layer 4) players, laptop computers and desktop computers, etc. When terminal devices 101, 102, 103 are software, they can be installed in the electronic devices listed above. It can be implemented as multiple software or software modules (for example, to provide distributed services), or it can be implemented as a single software or software module. No specific limitation is made here.
[0025] The server 105 may be a server that provides various services, such as a personal cloud storage server that provides personal cloud storage services for the terminal devices 101 , 102 , and 103 .
[0026] It should be noted that a server can be either hardware or software. When a server is hardware, it can be implemented as a distributed server cluster consisting of multiple servers, or as a single server. When a server is software, it can be implemented as multiple software programs or software modules (for example, multiple software programs or software modules used to provide distributed services), or as a single software program or software module. This is not specifically limited here. The server can also be a server in a distributed system, or a server integrated with blockchain. The server can also be a cloud server, or an intelligent cloud computing server or intelligent cloud host with artificial intelligence technology.
[0027] It should be noted that the file renaming method provided in the embodiments of the present disclosure is generally executed by a terminal device, and accordingly, the file renaming apparatus is generally provided in the terminal device.
[0028] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is merely illustrative. Any number of terminal devices, networks and servers may be provided as required.
[0029] Continue to refer Figure 2 , shows a process 200 of an embodiment of a file renaming method according to the present disclosure. The file renaming method includes the following steps:
[0030] Step 201, in response to receiving a file renaming request, determining a file to be renamed according to the file renaming request;
[0031] In this embodiment, the execution subject of the file renaming method (eg Figure 1 The personal cloud storage APP running on the terminal device shown in the figure can receive file renaming requests initiated by the user through voice or text. The file renaming request is used to indicate the file to be renamed. For example, the user says: "Add a date prefix to the files in my resource folder", and the voice data can be converted into text to identify the file to be renamed. The user can clearly tell the path of the file to be renamed, and then search for the file to be renamed based on the path. If the user does not clearly tell the path of the file to be renamed, the pre-trained semantic understanding model can be used to identify the intention in the file renaming request, and then search for the file to be renamed. For example, if the user says: "Rename the photos taken yesterday", the photo files with a date of yesterday can be searched out.
[0032] Step 202: output a renaming scheme based on the characteristics of the file to be renamed and the file renaming request;
[0033] In this embodiment, the features may include file name, storage path, format, time information, etc. The renaming scheme includes the format of the renamed file name.
[0034] For example, if a user says, "Add a time suffix to the photos in my resources," the photo files in my resources can be searched out, and then the time suffix is added to each photo file name. For example, the "X Park.jpg" file uploaded on June 1, 2025 can be renamed to "X Park 20250601.jpg."
[0035] The user said: "Add a time prefix to files whose file names include 'learning'", which can search for all files whose file names contain "learning", and then add a time prefix to each file name. For example, the "First Grade Mathematics Learning.pdf" file uploaded on June 1, 2025 is renamed to "20250601First Grade Mathematics Learning.pdf".
[0036] If a user asks, "Rename files containing 20250601 to Children's Day xxx," the system searches for files containing 20250601 (either as a prefix or a suffix). Then, the prefix "Children's Day" is added to each file name, and the original date is deleted (this is determined based on the user's semantics in the file rename request, and duplicate dates are removed). For example, a file named "20250601YYTPark.jpg" is renamed "Children's Day YYTPark.jpg."
[0037] These renaming schemes can be displayed in the form of a file list on a semi-floating panel, and multiple schemes can be listed for the user to choose from.
[0038] Optionally, features of the file to be renamed may be extracted using a pre-trained large model, and then a renaming scheme may be generated based on the features of the file to be renamed and the file renaming request.
[0039] Step 203 : In response to detecting that the renaming scheme is confirmed, modify the file name of the file to be renamed according to the renaming scheme.
[0040] In this embodiment, the output renaming scheme is only displayed to the user and requires user confirmation before execution. This allows the user to know what the file name will be changed to, and whether the file name is too long and the suffix is only displayed by clicking the file name, or the prefix is too long and the name keywords are only displayed by clicking the file name. After the user confirms the renaming scheme, the open files can be automatically saved and closed, so that all related files are in a state where the file name can be modified. The file names can then be modified in batches according to the renaming scheme.
[0041] If the user doesn't select a renaming plan within the scheduled time, the user is considered to have abandoned the renaming plan. If the user provides feedback on the renaming plan, a new renaming plan will be generated based on their feedback. For example, if the original renaming plan used the time as a suffix, and the user complains that the time is no longer visible, a renaming plan can be generated with the time as the prefix.
[0042] Optionally, if more than a predetermined proportion of files in a folder are renamed, the folder may be automatically renamed based on the common characteristics of these renamed files. For example, if all files have a time suffix, the folder may also have a time suffix.
[0043] The method provided by the above-mentioned embodiments of the present disclosure can rename files in batches according to user needs, thereby improving the flexibility and efficiency of file renaming.
[0044] In some optional implementations of this embodiment, determining the file to be renamed based on the file renaming request includes: matching the file renaming request with the file attribute information of each candidate file in the candidate file set, wherein the file attribute information includes at least one of the following: file name, storage path, format, and time information; and determining the candidate file that has successfully matched as the file to be renamed.
[0045] You can directly perform string matching on the file rename request against the file attribute information of each candidate file in the candidate file set. Alternatively, you can use a pre-trained model to identify information such as the file name, storage path, format, and time information in the file rename request, and then perform string matching on the file attribute information of each candidate file in the candidate file set.
[0046] You can quickly group files to be renamed according to their attribute information to increase the speed of file renaming.
[0047] In some optional implementations of this embodiment, determining the file to be renamed based on the file renaming request includes: in response to receiving authorization to read the file content, matching the file renaming request with the file content of each candidate file in the candidate file set; and determining the successfully matched candidate file as the file to be renamed.
[0048] The user can be asked whether to authorize reading file contents. If the user allows reading file contents, the file rename request can be string-matched against the file contents of each candidate file in the candidate file set. A pre-trained model can also be used to identify information such as the file name, storage path, format, and time information in the file rename request, and then string-matched against the content of each candidate file in the candidate file set. For example, if the user says "add the suffix 'Literary Appreciation' to files containing 'Literary Appreciation'," the keyword "Literary Appreciation" can be searched for in the file contents of each candidate file, and the file names of all the searched files can be suffixed with "Literary Appreciation."
[0049] Users can automatically add the key information of the file to the file name without having to open the file to view the content, which not only makes it easier for users to view, but also improves the efficiency of file renaming.
[0050] In some optional implementations of this embodiment, the file renaming request is matched with the file content of each candidate file in the candidate file set, including: extracting summary information from the file content of each candidate file in the candidate file set; matching the file renaming request with the summary information of each candidate file in the candidate file set; and determining the successfully matched candidate file as the file to be renamed.
[0051] The large model can be used to extract summary information, titles, outlines, and other information from the file content of each candidate file in the candidate file set. A string match is performed between the file rename request and the summary information, titles, or outlines of each candidate file in the candidate file set. The candidate file that successfully matches is determined as the file to be renamed.
[0052] Users do not need to open the file to view the content, nor do they need to match the full text of the file. They only need to match the summary and other information to automatically add the key information of the file to the file name, which is convenient for users to view and improves the efficiency of file renaming.
[0053] In some optional implementations of this embodiment, a renaming scheme is output based on the characteristics of the file to be renamed and a file renaming request, including: determining the characteristics of the file to be renamed based on the file attribute information of the file to be renamed; determining the file name format of the file to be renamed with the same characteristics based on the file renaming request, wherein the file name format includes a file name prefix and / or a file name suffix; determining a new file name after renaming based on the file name format, and displaying the file to be renamed with the new file name in a preview manner.
[0054] File attribute information includes at least one of the following: file name, storage path, format, and time information. A file rename request can specify the basis for the file name change and a specific target for the change. Alternatively, the target can be left unspecified, allowing the macro model to determine the target based on the common characteristics of the files to be renamed.
[0055] For example, if a user says "Rename the video files in my resource folder according to their length," the videos can be divided into long and short categories based on their length, with "Long Video" or "Short Video" suffixed to the file names. For example, a video longer than 5 minutes is classified as a long video, and the original file name "Mathematical Mysteries 1" is changed to "Mathematical Mysteries 1 - Long Video."
[0056] Optionally, a file name format template may be pre-set, such as the length of the agreed date, a connecting symbol, etc. for the user to select, for example, a template with a prefix: "YYMMDD_original file name", "YYYYMMDD_original file name", "YYMMDD-original file name", a template with a suffix: "original file name_YYMMDD", "original file name@YYMMDD", "original file name by author", etc. A template with both a prefix and a suffix: "YYMMDD_original file name by author".
[0057] YY represents a two-digit year, YYYY represents a four-digit year, MM represents the month, and DD represents the day.
[0058] You can set names or numbers for different templates, and users can directly specify which template to use to modify file names. For example, a user can say "Use Prefix Template 1 to rename the files in my resource folder."
[0059] Optionally, the user's file naming habits can be counted to automatically generate a file name format template. For example, if the user likes to add a suffix and uses a hyphen "_" between the file name and the date, a template of "original file name_YYMMDD" can be generated.
[0060] For example, if a user enjoys reading novels and has a clear preference for genre or author, a file name format template like "Original Filename_Romance by Author" can be automatically generated. After obtaining user authorization, the personal cloud storage app can read the file content, identify the file type as a romance novel, and extract the author information, which can then be used to rename the file.
[0061] A large model allows users to interact with the computer to select a file name format template. If the user does not select a file name format template or does not specify a file name format, a default file name format template will be used. The most frequently used file name format template can be selected as the default template based on user usage frequency. Alternatively, user-favorite file names can be collected from existing file names and used as the default file name format template. This improves convenience and modification efficiency.
[0062] In some optional implementations of this embodiment, the method further includes: outputting file renaming progress information; and in response to detecting that the file renaming is complete, outputting an option to undo the file renaming.
[0063] The file renaming progress information can be displayed, allowing users to understand the file renaming completion rate, estimate the end time, and improve the user experience.
[0064] In some optional implementations of this embodiment, the method further includes: in response to the undo file renaming option being selected, restoring the file to be renamed to the original file name.
[0065] By recording the original and modified file names, you can restore the original file names in batches. This is essentially a renaming operation, with the renamed file names remaining the same as the original. Batch processing reduces user workload and improves user experience.
[0066] In some optional implementations of this embodiment, the method further includes: in response to detecting that the renamed file name conflicts with the file name of other files, adding a number to the new file name and using it as the file name of the file to be renamed.
[0067] File name conflicts can be automatically numbered or renamed separately to distinguish them. This prevents batch processing interruptions caused by a single file conflict. A file name conflict warning message can be output. If the user is dissatisfied with the automatic numbering method, they can initiate another file rename request after renaming all pending files.
[0068] Alternatively, the two conflicting file names can be renamed to differentiate them. For example, after the user initially adds the time suffix 250601 to the file "abc.docx", the file name "abc250601.docx" conflicts with the existing file name. The system automatically adds a number to the file name, changing it to "abc2506011.docx". The user is dissatisfied with this and requests to rename the file again to differentiate them clearly. In this case, the original file name "abc250601.docx" can be changed to "abc250601_V1.docx", and the original file name "abc.docx" can be changed to "abc250601_V2.docx".
[0069] In some optional implementations of this embodiment, the method further includes: in response to detecting a rename failure, marking the file for which renaming failed and outputting the reason for the failure. For example, if a file is open and cannot be renamed, the reason for the failure can be output, and the user can subsequently close the file and manually rename it, or re-initiate the file rename request. This ensures that all files to be renamed can ultimately be renamed, preventing omissions.
[0070] In some optional implementations of this embodiment, outputting an undo file rename option includes: recording the correspondence between the file name of the file to be renamed before renaming and the file name after renaming; outputting a batch undo file rename option for file renaming requests and an independent undo file rename option for each renamed file.
[0071] Each renamed file will have its original and new names recorded, allowing you to undo the rename. Both batch and individual undo options are available, allowing you to choose the file you want. Choosing a batch undo restores all files to their original names. Undoing a single file restores only that file to its original name.
[0072] Continue to see Figure 3 , Figure 3 FIG. 1 is a schematic diagram of an application scenario of the file renaming method according to this embodiment. Figure 3 In this application scenario, a user enters the command "Help me add the prefix 2025 to the names of the next level files in the psychology folder" through a personal cloud storage app. The personal cloud storage app uses the big model to conduct in-depth analysis and determines that the following steps are required to complete the task:
[0073] 1. Search for files in personal cloud storage: First, the user explicitly mentions "psychology" and confirms that the folder they are searching for is the "psychology" folder.
[0074] 2. Batch rename: Rename the related files found in step 1 in batches, adding the prefix 2025 to them.
[0075] The renamed file list can be displayed in preview mode, and the actual file name modification will be performed after the user confirms.
[0076] After executing the batch rename, you can output the undo option. If the user is not satisfied with the renaming result, you can undo the renaming and restore the original name.
[0077] Further references Figure 4 , which shows a process 400 of another embodiment of a file renaming method. The process 400 of the file renaming method includes the following steps:
[0078] Step 401, in response to receiving a file renaming request, determining a file to be renamed according to the file renaming request;
[0079] Step 402: output a renaming scheme based on the characteristics of the file to be renamed and the file renaming request;
[0080] Step 403: In response to detecting that the renaming scheme is confirmed, modify the file name of the file to be renamed according to the renaming scheme.
[0081] Steps 401-403 are substantially the same as steps 201-203, and therefore are not described in detail.
[0082] Step 404: In response to detecting that the file renaming is complete, outputting an option to undo the file renaming.
[0083] In this embodiment, the renaming process cannot be interrupted, but after the renaming is completed, an undo file renaming option can be output. The undo file renaming option can be in two forms: one-click batch undo all and undo only the checked files.
[0084] Step 405 : In response to the undo file rename option being selected, the file to be renamed is restored to its original file name.
[0085] In this embodiment, if the user selects to undo all changes in batches with one click, all files modified this time will be restored to their original file names. If the user only selects to undo some files, only the file names of these selected files will be restored.
[0086] The existing personal cloud storage does not provide a function to undo renaming, and can only be modified manually. However, this application can undo renaming and restore the original file name, which not only saves time, but also ensures the restoration of the original state and improves the user experience.
[0087] Further references Figure 5As an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of a file renaming device. Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0088] like Figure 5 As shown, the file renaming device 500 of this embodiment includes: a determination unit 501, an output unit 502, and a modification unit 503. The determination unit 501 is configured to, in response to receiving a file renaming request, determine a file to be renamed according to the file renaming request; the output unit 502 is configured to output a renaming scheme based on the characteristics of the file to be renamed and the file renaming request; and the modification unit 503 is configured to, in response to detecting that the renaming scheme is confirmed, modify the file name of the file to be renamed according to the renaming scheme.
[0089] In this embodiment, the specific processing of the determining unit 501, the output unit 502 and the modifying unit 503 of the file renaming device 500 can be referred to Figure 2 This corresponds to step 201, step 202 and step 203 in the embodiment.
[0090] In some optional implementations of this embodiment, the determination unit is further configured to: match the file renaming request with the file attribute information of each candidate file in the candidate file set, wherein the file attribute information includes at least one of the following: file name, storage path, format, and time information; and determine the candidate file that has successfully matched as the file to be renamed.
[0091] In some optional implementations of this embodiment, the determination unit is further configured to: in response to receiving authorization to read file content, match the file renaming request with the file content of each candidate file in the candidate file set; and determine the candidate file that has successfully matched as the file to be renamed.
[0092] In some optional implementations of this embodiment, the determination unit is further configured to: extract summary information from the file content of each candidate file in the candidate file set; match the file renaming request with the summary information of each candidate file in the candidate file set; and determine the candidate file that has successfully matched as the file to be renamed.
[0093] In some optional implementations of this embodiment, the output unit is further configured to: determine the characteristics of the file to be renamed based on the file attribute information of the file to be renamed; determine the file name format of the file to be renamed with the same characteristics based on the file renaming request, wherein the file name format includes a file name prefix and / or a file name suffix; determine the new file name after renaming based on the file name format, and display the file to be renamed with the new file name in a preview manner.
[0094] In some optional implementations of this embodiment, the output unit 502 is further configured to: output file renaming progress information; and output an option to undo the file renaming in response to detecting that the file renaming is complete.
[0095] In some optional implementations of this embodiment, the modifying unit 503 is further configured to: in response to the undo file renaming option being selected, restore the file to be renamed to the original file name.
[0096] In some optional implementations of this embodiment, the modifying unit 503 is further configured to: in response to detecting that the renamed new file name conflicts with the file name of other files, add a number to the new file name as the file name of the file to be renamed.
[0097] In some optional implementations of this embodiment, the output unit 502 is further configured to: in response to detecting a renaming failure, mark the file that failed to be renamed and output the reason for the failure.
[0098] In some optional implementations of this embodiment, the output unit 502 is further configured to: record the correspondence between the file name of the file to be renamed before renaming and the file name after renaming; output a batch undo file renaming option for the file renaming request and an independent undo file renaming option for each renamed file.
[0099] In the technical solutions disclosed herein, the collection, storage, use, processing, transmission, provision and disclosure of user personal information involved comply with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0100] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.
[0101] An electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method described in process 200.
[0102] A non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute the method described in process 200.
[0103] A computer program product includes a computer program, which implements the method described in process 200 when executed by a processor.
[0104] Figure 6 A schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are provided as examples only and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0105] like Figure 6 As shown, the device 600 includes a computing unit 601, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. Various programs and data required for the operation of the device 600 can also be stored in the RAM 603. The computing unit 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0106] Various components in device 600 are connected to I / O interface 605, including an input unit 606, such as a keyboard, mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic disk, optical disk, etc.; and a communication unit 609, such as a network card, modem, wireless communication transceiver, etc. The communication unit 609 allows device 600 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.
[0107] The computing unit 601 can be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units that run machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 601 performs the various methods and processes described above, such as the file renaming method. For example, in some embodiments, the file renaming method can be implemented as a computer software program that is tangibly contained in a machine-readable medium, such as a storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed on the device 600 via the ROM 602 and / or the communication unit 609. When the computer program is loaded into the RAM 603 and executed by the computing unit 601, one or more steps of the file renaming method described above can be performed. Alternatively, in other embodiments, the computing unit 601 can be configured to perform the file renaming method by any other appropriate means (e.g., by means of firmware).
[0108] Various embodiments of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), system-on-chip systems (SOCs), programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0109] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.
[0110] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in conjunction with an instruction execution system, device or equipment. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium can include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0111] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0112] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.
[0113] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact through a communication network. The client-server relationship arises through computer programs running on the respective computers and having a client-server relationship with each other. The server may be a cloud server, a server in a distributed system, or a server integrated with a blockchain.
[0114] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved. This is not a limitation herein.
[0115] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.
Claims
1. A file renaming method, comprising: In response to receiving a file renaming request, determining a file to be renamed according to the file renaming request; Outputting a renaming scheme based on the characteristics of the file to be renamed and the file renaming request; In response to detecting that the renaming scheme is confirmed, the file name of the to-be-renamed file is modified according to the renaming scheme.
2. The method according to claim 1, wherein Determining the file to be renamed according to the file renaming request includes: Matching the file renaming request with the file attribute information of each candidate file in the candidate file set, wherein the file attribute information includes at least one of the following: file name, storage path, format, and time information; The candidate files that are successfully matched are determined as files to be renamed.
3. The method according to claim 1, wherein Determining the file to be renamed according to the file renaming request includes: In response to receiving authorization to read file content, matching the file renaming request with the file content of each candidate file in the candidate file set; The candidate files that are successfully matched are determined as files to be renamed.
4. The method according to claim 3, wherein: The matching of the file renaming request with the file content of each candidate file in the candidate file set includes: Extract summary information from the file content of each candidate file in the candidate file set; Matching the file renaming request with summary information of each candidate file in the candidate file set; The candidate files that are successfully matched are determined as files to be renamed.
5. The method according to claim 1, wherein Outputting a renaming scheme based on the characteristics of the file to be renamed and the file renaming request includes: Determining the characteristics of the file to be renamed based on the file attribute information of the file to be renamed; Determining, based on the file renaming request, file name formats of files to be renamed that have the same characteristics, wherein the file name formats include a file name prefix and / or a file name suffix; A new file name after the renaming is determined based on the file name format, and the file to be renamed using the new file name is displayed in a preview manner.
6. The method according to claim 1, wherein The method further comprises: Output file renaming progress information; In response to detecting that the file rename is complete, an undo file rename option is output.
7. The method according to claim 6, wherein: The method further comprises: In response to the undo file renaming option being selected, the file to be renamed is restored to its original file name.
8. The method according to claim 1, wherein The method further comprises: In response to detecting that the renamed file name conflicts with the file name of another file, a number is added to the new file name and used as the file name of the file to be renamed.
9. The method according to claim 1, wherein: The method further comprises: In response to detecting a rename failure, the file for which renaming failed is marked, and a reason for the failure is output.
10. The method according to claim 6, wherein: The output undo file renaming options include: Recording the correspondence between the file name of the file to be renamed before the renaming and the file name after the renaming; Outputs a batch undo file rename option for the file rename request and an independent undo file rename option for each renamed file.
11. A file renaming device, comprising: a determining unit, configured to, in response to receiving a file renaming request, determine a file to be renamed according to the file renaming request; an output unit configured to output a renaming scheme based on the characteristics of the file to be renamed and the file renaming request; The modifying unit is configured to modify the file name of the to-be-renamed file according to the renaming scheme in response to detecting that the renaming scheme is confirmed.
12. An electronic device comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 10.
13. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-10.
14. A computer program product comprising a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 10.
15. A network disk comprising: A file renaming component, wherein when executed by a processor, the file renaming component implements the method according to any one of claims 1 to 10.