Target UUID generation method and device, storage medium and electronic equipment

By using the target large language model and hash function during the UUID generation process, combining the basic UUID and hash value to generate the target UUID, the conflict risk problem caused by UUID is solved, and the uniqueness of UUID is improved. It is suitable for smart homes and Smart home and other scenarios.

CN119128295APending Publication Date: 2024-12-13QINGDAO HAIER TECH +3
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411123602.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-15
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

In some application scenarios, the generated UUID is not unique, resulting in conflict risk, and the existing technology has not effectively solved this problem.

Method used

Generate enhanced information through the target large language model as the basis UUID, and use hash function to generate hash values, combine basic UUID and hash values ​​to generate target UUID, and add separators and hash values ​​to ensure the uniqueness of UUID.

Benefits of technology

It significantly improves the uniqueness of UUID, reduces the risk of conflict, and is suitable for scenarios such as smart homes and smart homes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119128295A_ABST
    Figure CN119128295A_ABST
Patent Text Reader

Abstract

The invention discloses a target UUID generation method and device, a storage medium and electronic equipment, and relates to the technical field of smart homes. The target UUID generation method comprises the following steps: acquiring a to-be-processed basic UUID (Universal Unique Identifier); generating enhanced information for the basic UUID through a target large language model, and generating a hash value corresponding to the enhanced information through a hash function; and generating a target UUID according to the basic UUID and the hash value. By adopting the above technical scheme, the problem that the generated UUID is not unique in certain specific application scenarios in the related technology and further causes a conflict risk is solved, so that the uniqueness of the UUID is remarkably improved, and the conflict risk is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of smart home technology, and more specifically, to a method and device for generating a target UUID, a storage medium, and an electronic device. Background Art

[0002] Universally unique identifiers (UUIDs) are widely used in distributed systems. In complex application scenarios with high concurrency and across systems, related technologies may generate non-unique UUIDs due to identical timestamps and repeated MAC addresses, which increases the risk of conflicts.

[0003] In the related technology, in certain specific application scenarios, the generated UUID is not unique, which leads to the risk of conflict. No effective solution has been proposed yet. Summary of the invention

[0004] The embodiments of the present application provide a method and device for generating a target UUID, a storage medium, and an electronic device, so as to at least solve the problem in the related art that, in certain specific application scenarios, the generated UUID is not unique, thereby causing the risk of conflict.

[0005] According to an embodiment of the embodiments of the present application, a method for generating a target UUID is provided, including: obtaining a basic universal unique identifier UUID to be processed; generating enhanced information for the basic UUID through a target large language model, and generating a hash value corresponding to the enhanced information through a hash function; generating a target UUID based on the basic UUID and the hash value.

[0006] In an optional embodiment, enhanced information is generated for the basic UUID through a target large language model, including: obtaining a target large language model that has been trained with multiple groups of data, wherein each group of the multiple groups of data includes: a basic UUID and enhanced information; inputting the basic UUID to be processed into the trained target large language model to obtain the enhanced information corresponding to the basic UUID to be processed.

[0007] In an optional embodiment, generating a target UUID based on the base UUID and the hash value includes: determining a first character position of the last character in the base UUID; adding a separator at a second character position after the first character position; adding the hash value at N character positions after the second character position, wherein N is the same as the number of characters included in the hash value; and determining the base UUID to which the separator and the hash value are added as the target UUID.

[0008] In an optional embodiment, after generating the target UUID according to the base UUID and the hash value, the method further includes: obtaining format requirements for the target UUID, wherein the format requirements include: the total string length of the target UUID, the number N of substrings included in the target UUID, the character length of each string in the N substrings, and the arrangement order of the N strings in the target UUID; formatting the target UUID according to the format requirements to obtain a target UUID that meets the format requirements.

[0009] In an optional embodiment, a hash value corresponding to the enhanced information is generated by a hash function, including: obtaining the length of the data contained in the enhanced information; when the data length of the enhanced information is not an integer multiple of the target value, padding the enhanced information with data; and performing hash calculation on the enhanced information after data padding to generate a hash value in the target base.

[0010] In an optional embodiment, after generating a hash value corresponding to the enhanced information through a hash function, the method further includes: when the number of the enhanced information is at least two, generating hash values ​​corresponding to at least two of the enhanced information respectively through a hash function; generating at least two target UUIDs based on the base UUID and at least two hash values; and when the base UUID is obtained again, determining the required target UUID from the at least two target UUIDs.

[0011] In an optional embodiment, determining a required target UUID from the at least two target UUIDs includes: determining a feature of the required target UUID; and screening the at least two target UUIDs according to the feature to determine the required target UUID.

[0012] According to another aspect of the present invention, a device for generating a target UUID is also provided, including: an acquisition module for acquiring a basic universal unique identifier UUID; a first generation module for generating enhanced information for the basic UUID through a target large language model, and generating a hash value corresponding to the enhanced information through a hash function; a second generation module for generating a target UUID based on the basic UUID and the hash value.

[0013] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned method for generating a target UUID when running.

[0014] According to another aspect of an embodiment of the present application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the method for generating the target UUID through the computer program.

[0015] According to another aspect of the embodiments of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the method for generating the target UUID is implemented.

[0016] In an embodiment of the present application, a basic universal unique identifier UUID to be processed is obtained; enhanced information is generated for the basic UUID through a target large language model, and a hash value corresponding to the enhanced information is generated through a hash function; a target UUID is generated according to the basic UUID and the hash value. The above technical solution solves the problem that the generated UUID is not unique in certain specific application scenarios in the related technology, which leads to the risk of conflict, thereby significantly improving the uniqueness of the UUID and reducing the risk of conflict. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0019] Figure 1 It is a hardware environment diagram of a method for generating a target UUID according to an embodiment of the present application;

[0020] Figure 2 is a flowchart of a method for generating a target UUID according to an embodiment of the present application;

[0021] Figure 3 This is a flowchart of a method for generating a target UUID according to an optional embodiment of the present application;

[0022] Figure 4 It is a structural block diagram of a target UUID generation device according to an embodiment of the present application. DETAILED DESCRIPTION

[0023] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0025] According to one aspect of an embodiment of the present application, a method for generating a target UUID is provided. The method for generating the target UUID is widely used in smart home, smart home, smart home device ecology, smart residential (Intelligence House) ecology and other whole-house intelligent digital control application scenarios. Optionally, in this embodiment, the above-mentioned method for generating the target UUID can be applied to Figure 1 In the hardware environment composed of the Internet of Things device 102 and the home appliance device 104 shown in FIG. Figure 1 As shown, the IoT device 102 is connected to the home appliance 104 via a network, and can be used to provide services (such as application services, etc.) for the IoT device 102 or a client installed on the IoT device 102. A database can be set on the IoT device 102 or independently of the IoT device 102 to provide data storage services for the IoT device 102 and the home appliance 104. Cloud computing and / or edge computing services can be configured on the IoT device 102 or independently of the IoT device 102 to provide data computing services for the IoT device 102 and the home appliance 104.

[0026] The above network may include but is not limited to at least one of the following: wired network, wireless network. The above wired network may include but is not limited to at least one of the following: wide area network, metropolitan area network, local area network, and the above wireless network may include but is not limited to at least one of the following: WIFI (Wireless Fidelity), Bluetooth. The Internet of Things device 102 and the home appliance device 104 may not be limited to PC, mobile phone, tablet computer, smart air conditioner, smart range hood, smart refrigerator, smart oven, smart stove, smart washing machine, smart water heater, smart washing equipment, smart dishwasher, smart projection equipment, smart TV, smart clothes drying rack, smart curtain, smart audio and video, smart socket, smart audio, smart speaker, smart fresh air equipment, smart kitchen and bathroom equipment, smart bathroom equipment, smart sweeping robot, smart window cleaning robot, smart mopping robot, smart air purification equipment, smart steamer, smart microwave oven, smart kitchen treasure, smart purifier, smart water dispenser, system platform, etc.

[0027] In this embodiment, a method for generating a target UUID is provided, which is applied to the above-mentioned IoT device. Figure 2 : is a flowchart of a method for generating a target UUID according to an embodiment of the present application, the process comprising the following steps:

[0028] Step S202, obtaining a basic universal unique identifier UUID to be processed;

[0029] Step S204, generating enhanced information for the basic UUID by using a target large language model, and generating a hash value corresponding to the enhanced information by using a hash function;

[0030] Step S206: Generate a target UUID according to the base UUID and the hash value.

[0031] In an embodiment of the present application, a basic universal unique identifier UUID to be processed is obtained; enhanced information is generated for the basic UUID through a target large language model, and a hash value corresponding to the enhanced information is generated through a hash function; a target UUID is generated according to the basic UUID and the hash value. The above technical solution solves the problem that the generated UUID is not unique in certain specific application scenarios in the related technology, which leads to the risk of conflict, thereby significantly improving the uniqueness of the UUID and reducing the risk of conflict.

[0032] In an optional embodiment, enhanced information is generated for the basic UUID through a target large language model, including: obtaining a target large language model that has been trained with multiple groups of data, wherein each group of the multiple groups of data includes: a basic UUID and enhanced information; inputting the basic UUID to be processed into the trained target large language model to obtain the enhanced information corresponding to the basic UUID to be processed.

[0033] Before training, multiple sets of data need to be prepared, each set of data includes a basic UUID and related enhanced information. The above-mentioned related enhanced information may include the generation context, metadata, and associated data of the UUID. Use these data to train the target large language model. The target large language model learns how to extract useful features from the association between the basic UUID and the enhanced information, and predict new enhanced information. When the target large language model is trained, the basic UUID to be processed can be input into the target large language model to obtain the enhanced information corresponding to the basic UUID.

[0034] In an optional embodiment, generating a target UUID based on the base UUID and the hash value includes: determining a first character position of the last character in the base UUID; adding a separator at a second character position after the first character position; adding the hash value at N character positions after the second character position, wherein N is the same as the number of characters included in the hash value; and determining the base UUID to which the separator and the hash value are added as the target UUID.

[0035] The base UUID consists of 32 hexadecimal characters separated by hyphens. Optionally, the base UUID is divided into five parts: the first part contains 8 hexadecimal digits, the second part contains 4 hexadecimal digits, the third part contains 4 hexadecimal digits, the fourth part contains 4 hexadecimal digits, and the fifth part contains 12 hexadecimal digits, with hyphens inserted between each two parts. Determine the position of the last hexadecimal character, add a separator after this position, and insert the hash value after the separator, ensuring that the length of the hash value is the same as N. Based on the above operations, the target UUID can be obtained, which is composed of the base UUID, the separator and the hash value in sequence.

[0036] Alternatively, assuming there is a base UUID: "123e4567-e89b-12d3-a456-426614174000", the last character of the base UUID is "0", add a hyphen "-" after "0" as a separator, assuming the hash value is "abc123", the length N is 6, then add the hash value "abc123" after the hyphen "-". The final generated target UUID is "123e4567-e89b-12d3-a456-426614174000-abc123".

[0037] In an optional embodiment, after generating the target UUID according to the base UUID and the hash value, the method further includes: obtaining format requirements for the target UUID, wherein the format requirements include: the total string length of the target UUID, the number N of substrings included in the target UUID, the character length of each string in the N substrings, and the arrangement order of the N strings in the target UUID; formatting the target UUID according to the format requirements to obtain a target UUID that meets the format requirements.

[0038] The total string length in the basic UUID standard format is 36, including 32 hexadecimal characters and 4 separators. The basic UUID is divided into five parts, that is, the number of substrings N included in the UUID is 5. The first part contains 8 hexadecimal digits, the second part contains 4 hexadecimal digits, the third part contains 4 hexadecimal digits, the fourth part contains 4 hexadecimal digits, and the fifth part contains 12 hexadecimal digits. After the target UUID is generated, the total string length of the target UUID is obtained and checked. When the string length is 36 characters, check whether the number of substrings included in the target UUID is 5. When the number of substrings included in the target UUID is 5, check whether the arrangement order in the target UUID is arranged according to the first part of 8 hexadecimal digits, the second part of 4 hexadecimal digits, the third part of 4 hexadecimal digits, the fourth part of 4 hexadecimal digits, and the fifth part of 12 hexadecimal digits. If the above steps are all checked correctly, the target UUID conforms to the standard format. Otherwise, you can add, delete, or rearrange substrings as needed to meet the format requirements.

[0039] In an optional embodiment, a hash value corresponding to the enhanced information is generated by a hash function, including: obtaining the length of the data contained in the enhanced information; when the data length of the enhanced information is not an integer multiple of the target value, padding the enhanced information with data; and performing hash calculation on the enhanced information after data padding to generate a hash value in the target base.

[0040] Optionally, assuming that the enhanced information is "20240725T11:00:00", the target value is 16, and SHA-256 is used as the hash function of this embodiment. First, the data length of the enhanced information is 17, which is not an integer multiple of the target value 16, so 15 "0"s need to be padded after the enhanced information, and the padded enhanced information is hashed by SHA-256, and the first 8 bits of the result are taken as the hash value.

[0041] In an optional embodiment, after generating a hash value corresponding to the enhanced information through a hash function, the method further includes: when the number of the enhanced information is at least two, generating hash values ​​corresponding to at least two of the enhanced information respectively through a hash function; generating at least two target UUIDs based on the base UUID and at least two hash values; and when the base UUID is obtained again, determining the required target UUID from the at least two target UUIDs.

[0042] Assume that there are two enhanced information instances: enhanced information 1 and enhanced information 2. A hash function is used to generate corresponding hash values ​​1 and 2 for each enhanced information. The base UUID and the two hash values ​​are combined to generate two target UUIDs: target UUID 1 and target UUID 2. When the base UUID is obtained again, the required target UUID is determined from the two target UUIDs according to specific conditions or logic. For example, if enhanced information 1 is related to a specific user and enhanced information 2 is related to another user, the corresponding target UUID can be selected according to the user currently being processed.

[0043] In an optional embodiment, determining a required target UUID from the at least two target UUIDs includes: determining a feature of the required target UUID; and screening the at least two target UUIDs according to the feature to determine the required target UUID.

[0044] First, determine which features will be used to distinguish different target UUIDs. These features can be: Hash value: The hash part of the target UUID used to ensure uniqueness. Timestamp: The creation or update time associated with the target UUID. User ID: The identifier of a specific user or entity associated with the target UUID. Metadata: Other relevant information, such as version number, application ID, or other custom attributes. Based on the above features, you need to define filtering conditions to narrow the scope of the target UUID, for example, filtering UUIDs created within 24 hours, or filtering UUIDs associated with a specific user ID, and finally determine the required target UUID.

[0045] For example, suppose there are three target UUIDs, each associated with a different user and timestamp:

[0046] UUID1: "45a9-11b5-22c3-d44e-f00d-uuid-user123-20230101T12:00:00";

[0047] UUID2: "45a9-11b5-22c3-d44e-f00d-uuid-user456-20230102T15:30:00";

[0048] UUID3: "45a9-11b5-22c3-d44e-f00d-uuid-user789-20230103T08:45:00";

[0049] Need to find the UUID associated with user ID "user123" and updated in the last 24 hours.

[0050] First, determine that the features may include but are not limited to user ID and timestamp. Second, define the filtering conditions as user ID including "user123" and timestamp must be 24 hours before the current time. Filter UUID, assuming that the current time is "2023-01-02T16:00:00", only UUID1 meets all the filtering conditions, and determine UUID1 as the target UUID.

[0051] In order to better understand the process of the target UUID generation method, the target UUID generation implementation method flow is described below in conjunction with an optional embodiment, but it is not intended to limit the technical solution of the embodiment of the present application.

[0052] Figure 3 is a flow chart of a method for generating a target UUID according to an optional embodiment of the present invention, such as Figure 3 As shown, the specific steps include:

[0053] Through the UUID module provided in the programming language, a UUID based on random numbers is generated as the basic UUID to be processed. Select a target large language model for model training. Before training, you need to prepare multiple sets of data, each set of data includes a basic UUID and related enhanced information. The target large language model learns how to extract useful features from the association between the basic UUID and the enhanced information, and predict new enhanced information. When the target large language model is trained, the basic UUID to be processed can be input into the target large language model to obtain the enhanced information corresponding to the basic UUID.

[0054] Get the length of the data contained in the enhanced information. If the data length is not an integer multiple of 512, fill the enhanced information with 0 at the end. Use SHA-256 hash calculation to generate a hexadecimal hash result. Take the first 8 bits of the hash result as the hash value. Determine the position of the last character of the base UUID, add a separator after this position, and insert the hash value after the separator. Based on the above operations, the target UUID (equivalent to Figure 3 The summary information of the UUID is composed of the base UUID, the separator, and the hash value.

[0055] The above target UUID is formatted, and the total string length in the standard format of the basic UUID is 36, consisting of 32 hexadecimal characters separated by hyphens. Optionally, the basic UUID is divided into five parts: the first part contains 8 hexadecimal digits, the second part contains 4 hexadecimal digits, the third part contains 4 hexadecimal digits, the fourth part contains 4 hexadecimal digits, and the fifth part contains 12 hexadecimal digits. After generating the target UUID, the total string length of the target UUID is obtained and checked. When the string length is 36 characters, check whether the number of substrings included in the target UUID is 5. When the number of substrings included in the target UUID is 5, check whether the arrangement order in the target UUID is arranged according to the first part being 8 hexadecimal digits, the second part being 4 hexadecimal digits, the third part being 4 hexadecimal digits, the fourth part being 4 hexadecimal digits, and the fifth part being 12 hexadecimal digits. If the above steps are all checked correctly, the target UUID conforms to the standard format. Otherwise, you can add, delete, or rearrange substrings as needed to meet the format requirements.

[0056] Optionally, a basic UUID to be processed is generated by a programming language, assuming it is "123e4567-e89b-12d3-a456-426614174000". The above basic UUID is input into the trained target large language model, and the basic UUID is analyzed according to its characteristics to generate relevant enhanced information. Assume that the large language model returns the following enhanced information: "This is a random UUID for testing purposes, which was generated on March 29, 2023.".

[0057] The end of the enhanced information is padded with 0, so that the data length of the enhanced information after the data is padded is an integer multiple of 512. The enhanced information after the data is padded is hashed using SHA-256, and the first eight bits of the calculation result are taken as the hash value. In this embodiment, the hash value is "a0f12345".

[0058] The base UUID and the hash value are connected by hyphens to form the target UUID "123e4567-e89b-12d3-a456-426614174000-a0f12345". The above target UUID is formatted to check whether the format of the target UUID conforms to the standard format, and the final target UUID is determined to be "123e4567-e89b-12d3-a456-426614174000a0f12345".

[0059] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, a computer, an operating terminal, or a network device, etc.) to execute the methods of each embodiment of the present application.

[0060] Figure 4 is a structural block diagram of a device for generating a target UUID according to an embodiment of the present application; Figure 4 As shown, including:

[0061] An acquisition module 40 is used to acquire a basic universal unique identifier UUID;

[0062] A first generating module 42, configured to generate enhanced information for the basic UUID by using a target large language model, and to generate a hash value corresponding to the enhanced information by using a hash function;

[0063] The second generating module 44 is used to generate a target UUID according to the base UUID and the hash value.

[0064] In an embodiment of the present application, a basic universal unique identifier UUID to be processed is obtained; enhanced information is generated for the basic UUID through a target large language model, and a hash value corresponding to the enhanced information is generated through a hash function; a target UUID is generated according to the basic UUID and the hash value. The above technical solution solves the problem that the generated UUID is not unique in certain specific application scenarios in the related technology, which leads to the risk of conflict, thereby significantly improving the uniqueness of the UUID and reducing the risk of conflict.

[0065] In an optional embodiment, the first generation module 42 is also used to obtain a target large language model that has been trained with multiple groups of data, wherein each group of the multiple groups of data includes: a basic UUID and enhanced information; the basic UUID to be processed is input into the trained target large language model to obtain the enhanced information corresponding to the basic UUID to be processed.

[0066] In an optional embodiment, the second generation module 44 is also used to determine the first character position of the last character in the base UUID; add a separator at the second character position after the first character position; add the hash value at N character positions after the second character position, wherein N is the same as the number of characters included in the hash value; and determine the base UUID after adding the separator and the hash value as the target UUID.

[0067] In an optional embodiment, the second generation module 44 is further used to obtain format requirements for the target UUID, wherein the format requirements include: the total string length of the target UUID, the number N of substrings included in the target UUID, the character length of each string in the N substrings, and the arrangement order of the N strings in the target UUID; the target UUID is formatted according to the format requirements to obtain a target UUID that meets the format requirements.

[0068] In an optional embodiment, the first generation module 42 is further used to obtain the length of the data contained in the enhanced information; when the data length of the enhanced information is not an integer multiple of the target value, the enhanced information is padded with data; and the enhanced information after data padded is hashed to generate a hash value in the target base.

[0069] In an optional embodiment, the second generation module 44 is also used to generate, through a hash function, hash values ​​corresponding to at least two of the enhanced information when the number of the enhanced information is at least two; generate at least two target UUIDs according to the basic UUID and at least two of the hash values; and determine the required target UUID from the at least two target UUIDs when the basic UUID is obtained again.

[0070] In an optional embodiment, the second generating module 44 is further configured to determine a feature of the required target UUID; and screen the at least two target UUIDs according to the feature to determine the required target UUID.

[0071] An embodiment of the present application further provides a storage medium, which includes a stored program, wherein the program executes any of the above methods when it is run.

[0072] Optionally, in this embodiment, the storage medium may be configured to store program codes for executing the following steps:

[0073] S1, obtain the basic universal unique identifier UUID to be processed;

[0074] S2, generating enhanced information for the basic UUID by using a target large language model, and generating a hash value corresponding to the enhanced information by using a hash function;

[0075] S3, generating a target UUID according to the base UUID and the hash value.

[0076] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0077] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0078] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:

[0079] S1, obtain the basic universal unique identifier UUID to be processed;

[0080] S2, generating enhanced information for the basic UUID by using a target large language model, and generating a hash value corresponding to the enhanced information by using a hash function;

[0081] S3, generating a target UUID according to the base UUID and the hash value.

[0082] Optionally, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store program codes.

[0083] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps in any one of the above method embodiments are implemented.

[0084] An embodiment of the present application further provides another computer program product, including a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.

[0085] The embodiments of the present application also provide a computer program, which includes computer instructions, which are stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the steps in any one of the above method embodiments.

[0086] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.

[0087] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.

[0088] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A method for generating a target UUID, characterized in that: include: Get the basic universal unique identifier UUID to be processed; Generate enhanced information for the basic UUID by using a target large language model, and generate a hash value corresponding to the enhanced information by using a hash function; A target UUID is generated based on the base UUID and the hash value.

2. The method for generating a target UUID according to claim 1, characterized in that: Generate enhanced information for the basic UUID using a target large language model, including: Obtain a target large language model that has been trained using multiple sets of data, wherein each set of data in the multiple sets of data includes: a basic UUID and enhanced information; The basic UUID to be processed is input into the trained target large language model to obtain enhanced information corresponding to the basic UUID to be processed.

3. The method for generating a target UUID according to claim 1, characterized in that: Generating a target UUID according to the base UUID and the hash value includes: Determine the first character position of the last character in the base UUID; adding a separator at a second character position after the first character position; adding the hash value at N character positions after the second character position, wherein N is the same as the number of characters included in the hash value; The base UUID to which the separator and the hash value are added is determined as the target UUID.

4. The method for generating a target UUID according to claim 1, characterized in that: After generating the target UUID according to the base UUID and the hash value, the method further includes: Obtaining format requirements for the target UUID, wherein the format requirements include: the total string length of the target UUID, the number N of substrings included in the target UUID, the length of characters included in each of the N substrings, and the arrangement order of the N substrings in the target UUID; The target UUID is formatted according to the format requirement to obtain a target UUID that meets the format requirement.

5. The method for generating a target UUID according to claim 1, characterized in that: Generating a hash value corresponding to the enhanced information by using a hash function includes: Obtaining the length of the data contained in the enhanced information; When the data length of the enhanced information is not an integer multiple of the target value, performing data padding on the enhanced information; The enhanced information after data filling is hashed to generate a hash value in the target base.

6. The method for generating a target UUID according to claim 1, characterized in that: After generating a hash value corresponding to the enhancement information by using a hash function, the method further includes: When the number of the enhanced information is at least two, generating hash values ​​respectively corresponding to at least two pieces of the enhanced information by a hash function; At least two target UUIDs are generated according to the basic UUID and at least two hash values; when the basic UUID is obtained again, the required target UUID is determined from the at least two target UUIDs.

7. The method for generating a target UUID according to claim 6, characterized in that: Determining a required target UUID from the at least two target UUIDs includes: Determining characteristics of the desired target UUID; The at least two target UUIDs are screened according to the feature to determine the required target UUID.

8. A device for generating a target UUID, characterized in that: include: The acquisition module is used to obtain the basic universal unique identifier UUID; A first generating module, configured to generate enhanced information for the basic UUID by using a target large language model, and to generate a hash value corresponding to the enhanced information by using a hash function; The second generating module is used to generate a target UUID according to the basic UUID and the hash value.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program executes the method described in any one of claims 1 to 7 when executed.

10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 7 through the computer program.