Cache management method and device for embedding data and electronic equipment

By merging and mapping multiple batches of feature identifiers (IDs) to determine the target cache slot ID, the problem of duplicate lookup and retrieval of embedding data in deep learning recommendation systems is solved, thereby improving the system's concurrent throughput and resource utilization efficiency.

CN123178458APending Publication Date: 2026-11-27KUNWANG (SHANGHAI) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611445817.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-16
Publication Date
2026-11-27

AI Technical Summary

Technical Problem

In deep learning recommendation systems, under high-frequency concurrent scenarios with multiple batches, the traditional batch processing mode cannot detect the data overlap between batches, resulting in repeated searching and fetching of embedding data, which wastes system bandwidth and computing resources and leads to low processing efficiency.

Method used

By merging the feature identifiers IDs of multiple batches, a global ID set and mapping information are generated to determine the target cache slot ID. Based on the mapping information, the embedding data is located. A batch processing and reverse distribution mechanism is adopted to eliminate the overhead of repeated addressing and data retrieval.

Benefits of technology

It significantly improves the system's concurrent throughput, reduces cross-node communication latency, optimizes resource utilization, and enhances training stability and throughput.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123178458A_ABST
    Figure CN123178458A_ABST
Patent Text Reader

Abstract

The disclosure provides a cache management method and device for embedding data and electronic equipment, relates to the technical fields of artificial intelligence, deep learning models and cache management, and comprises the following steps: performing merging processing on a plurality of batches of feature identifiers ID to obtain a global ID set and first mapping information, wherein the global ID set comprises at least one global ID, and the first mapping information comprises a mapping relationship between the feature identifiers ID and the global ID; determining a target cache slot ID corresponding to the global ID; determining the Embedding data corresponding to the global ID based on the target cache slot ID; and determining the cache slot ID where the Embedding data required by each feature identifier ID is located according to the first mapping information. Through the batch processing and reverse distribution mechanism, the application can eliminate the repeated addressing and data pulling overhead in the multi-batch high-frequency concurrent scene, improve the system concurrent throughput capacity and reduce the cross-node communication delay.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of artificial intelligence technology, and in particular to the fields of deep learning models and cache management technology. Background Technology

[0002] With the evolution of deep learning recommendation systems and large-scale artificial intelligence (AI) models, the access patterns of feature (Embedding) data exhibit significant characteristics of "high concurrency" and "high overlap": On the one hand, during model training or inference, feature query requests are usually generated intensively and continuously in batches, and the frequent lookup and remote retrieval of massive feature IDs require a large amount of computing and communication resources; on the other hand, there are often a large number of duplicate feature IDs among the continuously generated batches. The traditional batch-by-batch independent processing mode lacks a global perspective and cannot perceive the data overlap between batches, resulting in the same embedding data being repeatedly looked up, allocated to cache, or even repeatedly retrieved, which not only reduces processing efficiency but also causes a serious waste of system bandwidth and computing resources.

[0003] Therefore, in scenarios with multiple batches and high-frequency concurrency, how to break through the scheduling barriers of traditional batch processing, realize the overall merging and deduplication of cross-batch feature identification data, eliminate repeated addressing and fetching overhead, and accurately reverse map the cached results back to each original request after obtaining the data has become one of the important research directions. Summary of the Invention

[0004] This disclosure provides a cache management method, apparatus, and electronic device for embedding data.

[0005] According to a first aspect of this disclosure, a cache management method for embedded embedding data is provided, characterized in that the method includes: Multiple batches of feature identifier IDs are merged to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier ID and the global ID; Determine the target cache slot ID corresponding to the global ID; Based on the target cache slot ID, determine the Embedding data corresponding to the global ID; Based on the first mapping information, determine the cache slot ID where the Embedding data required for each of the feature identifier IDs is located.

[0006] According to a second aspect of this disclosure, a cache management apparatus for embedded embedding data is provided, characterized in that the apparatus comprises: The processing module is used to merge feature identifiers IDs from multiple batches to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifiers IDs and the global IDs; The first determining module is used to determine the target cache slot ID corresponding to the global ID; The second determining module is used to determine the Embedding data corresponding to the global ID based on the target cache slot ID; The third determining module is used to determine the cache slot ID where the Embedding data required for each of the feature identifiers is located, based on the first mapping information.

[0007] According to a third aspect of this 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, the instructions being executed by the at least one processor to enable the at least one processor to perform the cache management method for embedded embedding data described above.

[0008] According to a fourth aspect of this disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause the computer to execute the above-described cache management method for embedding data.

[0009] According to a fifth aspect of this disclosure, a computer program product is provided, comprising a computer program that, when executed by a processor, implements the above-described cache management method for embedded embedding data.

[0010] This application merges multiple batches of feature identifier IDs to obtain a global ID set and first mapping information. The global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier IDs and the global IDs. It then determines the target cache slot ID corresponding to each global ID; based on the target cache slot ID, it determines the embedding data corresponding to each global ID; and according to the first mapping information, it determines the cache slot ID where the required embedding data for each feature identifier ID resides. This application, through batch processing and reverse distribution mechanisms, can eliminate the overhead of repeated addressing and data fetching in high-frequency concurrent scenarios with multiple batches, significantly improving system concurrency throughput and reducing cross-node communication latency.

[0011] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description

[0012] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this disclosure. Wherein: Figure 1 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data as shown in this application; Figure 2 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data as shown in this application; Figure 3 This is an overall flowchart of the Batch fusion processing according to an embodiment of this application; Figure 4 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data as shown in this application; Figure 5 This is a flowchart of the Pass / elimination decision process according to an embodiment of this application; Figure 6 This is a schematic diagram of a cross-pass reuse and reference counting mechanism according to an embodiment of this application; Figure 7 This is a system architecture diagram of an embodiment of this application; Figure 8 This is a timing diagram of the Pass lifecycle according to an embodiment of this application; Figure 9 This is a block diagram of a cache management apparatus for embedded embedding data according to an embodiment of the present disclosure; Figure 10 This is a schematic diagram of an electronic device according to an exemplary embodiment of the present disclosure. Detailed Implementation

[0013] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.

[0014] Artificial Intelligence (AI) is a new technological science that studies and develops theories, methods, technologies, and application systems to simulate, extend, and expand human intelligence. AI is a branch of computer science that attempts to understand the nature of intelligence and produce new intelligent machines that can react in a way similar to human intelligence. Research in this field includes robotics, speech recognition, image recognition, natural language processing, and expert systems.

[0015] Deep learning (DL) is a collection of algorithms and computational architectures in the field of machine learning that use multi-layered artificial neural networks to learn data representations. Deep learning is an important branch of artificial intelligence and computer science. It attempts to simulate the hierarchical processing mechanism of neurons in the human brain, extracting and abstracting multi-dimensional, non-linear features from massive amounts of data to produce intelligent systems capable of automatically learning the inherent patterns of complex data and making high-precision predictions or decisions. Research and typical architectures in this field include Convolutional Neural Networks (CNNs), Recurrent Neural Networks (RNNs), Transformer models, recommender systems, and generative large-scale models.

[0016] Cache management is a fundamental system technology that studies, designs, and optimizes the data exchange patterns and resource allocation between high-speed, small-capacity memory (cache) and low-speed, large-capacity memory in a computer's storage hierarchy. Cache management is a core branch of computer architecture and operating systems. It attempts to leverage the principle of locality of reference in program access, using intelligent scheduling mechanisms (such as data prefetching, reuse, and eviction) to keep the most frequently accessed data in the fastest-accessing storage medium. This masks the read / write speed barriers between different hardware levels, maximizing the computer's internal data throughput and processing performance. Research in this field includes cache eviction algorithms (such as LRU and LFU), concurrent data control, multi-level cache coherence protocols, and distributed caching systems.

[0017] The acquisition, storage, and application of user personal information involved in the technical solution disclosed herein comply with relevant laws and regulations and do not violate public order and good morals.

[0018] Figure 1 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data, as shown in this application. Figure 1 As shown, the cache management method for embedded embedding data includes the following steps: S101, merge the feature identifiers IDs of multiple batches to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier ID and the global ID.

[0019] In this application, the feature identifier ID refers to the original unique identifier used to represent a specific feature sample in the original input batch. The global ID refers to the unique feature identifier obtained after performing a deduplication operation on the feature identifier IDs of all batches within the same scheduling unit.

[0020] Optionally, an ID filter can be configured in the system to deduplicate the feature identifier IDs of each batch in order to obtain a global ID set and the first mapping information.

[0021] Optionally, a popularity ranking table based on the access frequency of feature identifiers can be established, and feature identifiers that appear frequently in multiple batches can be merged and extracted into a global ID set first, while low-frequency feature identifiers can be temporarily deferred for merging.

[0022] In this application, the feature identifiers IDs of multiple batches are merged to obtain a global ID set and first mapping information. By concatenating and deduplicating across batches, redundant calculation and communication overhead caused by overlapping feature IDs between multiple batches can be eliminated, while preserving the original data structure relationship.

[0023] S102, determine the target cache slot ID corresponding to the global ID.

[0024] In this application, the target cache slot ID refers to the specific storage block index or address in video memory or local memory that is assigned to a specific global ID to store the corresponding embedding data.

[0025] Optionally, a consistent hashing algorithm is used to directly map the global ID to a pre-allocated circular cache slot space through a hash function, and the target slot ID is calculated.

[0026] Alternatively, a prefix tree can be used to perform hierarchical parsing of the string or binary prefix of the global ID, matching to reach the leaf node to determine the corresponding target cache slot ID.

[0027] S103, based on the target cache slot ID, determine the Embedding data corresponding to the global ID.

[0028] In this application, Embedding data can refer to high-dimensional dense vector data corresponding to specific feature identifiers, used to participate in forward or backward computation of the model.

[0029] Optionally, a direct memory access controller is used to directly move the Embedding data block in the video memory to the compute unit register according to the target cache slot ID.

[0030] S104, based on the first mapping information, determine the cache slot ID where the Embedding data required for each feature identifier ID is located.

[0031] Optionally, by constructing a reverse pointer linked list, each global ID carries a linked list, with the linked list nodes pointing to the original batch positions of all data that depend on it. Once loading is complete, the linked list is traversed and distributed.

[0032] This application merges feature identifier IDs from multiple batches to obtain a global ID set and first mapping information. The global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between feature identifier IDs and global IDs. It then determines the target cache slot ID corresponding to each global ID; based on the target cache slot ID, it determines the embedding data corresponding to each global ID; and according to the first mapping information, it determines the cache slot ID where the required embedding data for each feature identifier ID resides. This application, through batch processing and reverse distribution mechanisms, can eliminate the overhead of repeated addressing and data fetching in high-frequency concurrent scenarios with multiple batches, significantly improving system concurrency throughput and reducing cross-node communication latency.

[0033] Figure 2 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data, as shown in this application. Figure 2 As shown, the cache management method for embedded embedding data includes the following steps: S201, add the feature identifiers IDs of multiple consecutive batches to the collection buffer of the same scheduling unit until the preset merging trigger condition is met.

[0034] For example, this application can introduce a Pass as a new scheduling object layer (i.e., the aforementioned scheduling unit) to merge multiple consecutive batches into a unified processing unit, realizing a multi-input, single-output batch processing mode, fundamentally eliminating the problems of batch-by-batch serial waiting and duplicate processing. This eliminates batch-level serial waiting, merges N Transform calls into one, reduces the number of distributed synchronizations and Python-C++ cross-language calls by N times, and eliminates duplicate calculations and communication of overlapping IDs through cross-batch deduplication.

[0035] It should be noted that Pass is the core scheduling object introduced in this application, defined as a complete data collection and processing cycle, containing multiple batches of feature ID data. Pass is the basic unit of BatchFusion, and its lifecycle starts from creation (create_pass), goes through multiple data additions (add_batch), unified processing (transform), and finally releases (free_pass).

[0036] Optionally, the merge triggering conditions include at least one of the following: The cumulative number of batches within the scheduling unit reaches the preset batch threshold; The cumulative number of feature identifiers (IDs) within the scheduling unit reaches a preset threshold for the total number of IDs. The waiting time of the scheduling unit exceeds the preset timeout threshold.

[0037] Alternatively, a sliding time window can be used, where the buffer continuously receives data and maintains a window with a fixed time width. Each time the window slides, the data within the current window is captured and processed.

[0038] S202, concatenate and deduplicate all feature identifier IDs within the scheduling unit to obtain a deduplicated global ID set and the first mapping information used to record the position of the original feature identifier ID.

[0039] Optionally, all the concatenated feature identifiers IDs are sorted in linear time complexity, and then adjacent elements are traversed to complete deduplication and mapping generation.

[0040] S203, determine the lookup result of the global ID in the second mapping information, wherein the second mapping information includes the mapping relationship between the global ID and the cache slot ID in the video memory.

[0041] Optionally, a second mapping information is maintained in remote memory based on a distributed key-value database, and the node initiates an RPC lookup over the network.

[0042] S204. Based on the search results, determine the target cache slot ID corresponding to the global ID.

[0043] Optionally, a heat feedback mechanism for the slot can be introduced. After determining the target slot ID, the temperature value of the slot is updated simultaneously, and the heat data is allocated to the high-frequency zone.

[0044] S205, based on the target cache slot ID, determine the Embedding data corresponding to the global ID.

[0045] S206, Based on the first mapping information, determine the cache slot ID where the Embedding data required for each feature identifier ID is located.

[0046] For a description of steps S206 to S206, please refer to the relevant content in the above embodiments, which will not be repeated here.

[0047] This application adds multiple consecutive batches of feature identifier IDs to the collection buffer of the same scheduling unit until a preset merging trigger condition is met. All feature identifier IDs within the scheduling unit are concatenated and deduplicated to obtain a deduplicated global ID set and first mapping information for recording the original feature identifier ID positions. The search result for the global ID in the second mapping information is determined, where the second mapping information includes the mapping relationship between the global ID and the cache slot ID in video memory. Based on the search result, the target cache slot ID corresponding to the global ID is determined. Based on the target cache slot ID, the embedding data corresponding to the global ID is determined. Based on the first mapping information, the cache slot ID where the required embedding data for each feature identifier ID is located is determined. Thus, by clarifying the specific execution method and lifecycle boundary (i.e., the scheduling unit) of the merging process, and by constructing a collection buffer, effective management of streaming data is achieved. By providing a multi-dimensional merging trigger mechanism, the system can dynamically balance throughput and processing latency based on the actual load when merging multiple batches of data. By introducing the second mapping information, rapid location and status awareness of the global ID to local storage space can be achieved.

[0048] For example, such as Figure 3 As shown, Figure 3 This is an overall flowchart of a batch fusion processing embodiment of this application, which includes the following steps: Step 1 - Pass Creation and Data Collection: The system creates a new Pass object and assigns a globally unique pass_id; the data loader continuously generates feature ID data for multiple batches; the add_batch(global_ids) operation adds the global_id tensor of each batch to the collection buffer of the current Pass one by one; the system continuously monitors the fusion trigger conditions.

[0049] Step 2 - Fusion Trigger Judgment: Pass processing is triggered when any of the following conditions are met: (a) The number of accumulated batches reaches the preset max_batches (e.g., 4 batches); (b) The total number of accumulated IDs reaches the preset max_ids threshold (e.g., 100,000 IDs); (c) The waiting time exceeds the preset timeout_ms timeout threshold (e.g., 100ms).

[0050] Step 3 - Cross-Batch Merging and Deduplication: Concatenate the global_id tensors of all batches within a Pass into a single total tensor; perform a unique operation on the XPU side (fully utilizing the parallel computing capabilities of the XPU to avoid irregular data transfer from the CPU to the XPU) to generate a unique set of deduplicated global_ids: unique_global_ids; simultaneously generate an inverse mapping index (recording the position of each original ID in the deduplicated set) for subsequent result distribution.

[0051] Step 4 - Unified Transform Processing: Perform a Transform operation on unique_global_ids; perform a batch lookup of existing mappings in GlobalIDCache (global mapping table); allocate new cache_id slots in batches for IDs that are not found, generate a unified Fetch request list (containing all [global_id, cache_id] pairs that need to be fetched remotely); and send a batch Fetch request to the parameter server.

[0052] Step 5 - Reverse Distribution of Results: Using the inverse mapping index generated in Step 3, the results of the unified Transform (unique_cache_ids) are distributed back to each original batch; each batch obtains its own cache_id tensor through the index operation cache_ids = unique_cache_ids[inverse[batch_start:batch_end]]; the cache_id tensor of each batch is used to retrieve the corresponding Embedding vector from the GPU memory Embedding table and pass it into the model for forward computation.

[0053] Data flow direction: Input Batch_1.global_ids, Batch_2.global_ids, ..., Batch_N.global_ids → Concatenate to get all_global_ids = concat(Batch_1..N) → Remove duplicates to get unique_global_ids, inverse_indices=unique(all_global_ids) → Transform to get unique_cache_ids = transform(unique_global_ids) → Batch Fetch (PS.batch_fetch needs to fetch the list of [global_id, cache_id]) → Reverse distribute to get each Batch_i.cache_ids=unique_cache_ids[inverse_indices[offset_i:offset_i+len_i]]; Output is Batch_1.cache_ids, Batch_2.cache_ids, ..., Batch_N.cache_ids.

[0054] Figure 4 This is a schematic diagram illustrating an exemplary implementation of a cache management method for embedded embedding data, as shown in this application. Figure 4 As shown, the cache management method for embedded embedding data includes the following steps: S401, merge the feature identifiers IDs of multiple batches to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier ID and the global ID.

[0055] S402, determine the lookup result of the global ID in the second mapping information, wherein the second mapping information includes the mapping relationship between the global ID and the cache slot ID in the video memory, the data validity identifier of the cache slot, the reference count, and the set of scheduling unit identifiers that reference the cache slot.

[0056] For a description of steps S401 to S402, please refer to the relevant content in the above embodiments, which will not be repeated here.

[0057] S403 If the search result is a hit and the data validity indicator indicates that the corresponding data is valid, then the corresponding cache slot ID is used as the target cache slot ID.

[0058] Optionally, after confirming a valid hit, the timestamp of the data needs to be verified. If the data is valid but has exceeded the set validity period, the background will trigger an asynchronous refresh, and the front end will still reuse the current slot ID.

[0059] Optionally, after using the corresponding cache slot ID as the target cache slot ID, the reference count of the cache slot corresponding to the target cache slot ID can be incremented; the identifier of the current scheduling unit can be added to the scheduling unit identifier set of the cache slot corresponding to the target cache slot ID. Thus, by incrementing the reference count and recording the scheduling unit identifier, a data basis can be provided for cache reuse and eviction operations across scheduling units.

[0060] S404 If the search result is a miss and / or the data validity indicator indicates that the corresponding data is invalid, then a new cache slot is allocated for the global ID, the corresponding cache slot ID is used as the target cache slot ID, and the corresponding global ID is added to the list to be fetched.

[0061] Optionally, when allocating a new cache slot, priority is given to allocating the new slot in the data page where an existing slot with a similar semantic meaning to the current global ID is located.

[0062] Optionally, after setting the corresponding cache slot ID as the target cache slot ID, the reference count of the cache slot corresponding to the target cache slot ID can be set to 1; the data validity flag of the cache slot corresponding to the target cache slot ID can be set to invalid; and the flag of the current scheduling unit can be added to the scheduling unit flag set of the cache slot corresponding to the target cache slot ID. Thus, for miss scenarios, state initialization can be completed atomically, ensuring that newly allocated slots have placeholder protection during fetching and avoiding state conflicts under high concurrency.

[0063] S405 determines the Embedding data corresponding to the global ID based on the target cache slot ID.

[0064] Optionally, if the search result is a hit and the data validity identifier indicates that the corresponding data is valid, the Embedding data corresponding to the global ID can be determined from the corresponding video memory slot based on the target cache slot ID.

[0065] Optionally, if the search result is a miss and / or the data validity flag indicates that the corresponding data is invalid, a fetch request is initiated to the remote server according to the fetch list to obtain the corresponding Embedding data. After the Embedding data is obtained, the corresponding data validity flag is updated to valid. This ensures data consistency during the asynchronous fetch process and prevents data that has not been fully loaded from being accessed prematurely.

[0066] S406, Based on the first mapping information, determine the cache slot ID where the Embedding data required for each feature identifier ID is located.

[0067] For a description of step S406, please refer to the relevant content in the above embodiments, which will not be repeated here.

[0068] S407 After the computation task of the scheduling unit is completed, the global ID set corresponding to the scheduling unit is traversed, the reference count corresponding to each global ID is reduced in turn, and the identifier of the scheduling unit is removed from the scheduling unit identifier set.

[0069] Optionally, the traversal task can be packaged into a closure and submitted asynchronously to a dedicated background garbage collection thread pool for execution.

[0070] Optionally, the scheduling unit accumulates all counts that need to be reduced locally, and then submits an aggregate subtraction operation to the global mapping table.

[0071] Optionally, the identifier of the scheduling unit can be marked as disabled, and then cleared in a unified manner when the set touches the capacity threshold for expansion the next time.

[0072] Optionally, a queue can be maintained to record all active scheduling units; in response to the satisfaction of preset eviction conditions, the scheduling unit at the head of the queue is identified as the eviction target; the reference count corresponding to each global ID in the eviction target is determined; in response to the reference count reaching zero, the corresponding cache slot is reclaimed, and the corresponding mapping entry is deleted from the second mapping information. By triggering eviction in batches at the scheduling unit level, the management overhead of the eviction algorithm can be significantly reduced; at the same time, relying on the reference count reaching zero ensures the absolute safety of active data.

[0073] Optionally, preset elimination criteria include at least one of the following: The queue length has reached the preset limit; The cache slot utilization rate exceeds the preset utilization rate threshold.

[0074] This application provides two elimination conditions: queue length and video memory usage. This ensures that the elimination mechanism is triggered only when resources are scarce or the lifecycle is reached, thus guaranteeing the smooth operation of the system.

[0075] For example, the eviction process for a scheduling unit (Pass) can be as follows: Figure 5 As shown, Figure 5 This is a flowchart of the Pass / elimination decision process according to an embodiment of this application.

[0076] In this application, multiple batches of feature identifier IDs are merged to obtain a global ID set and a first mapping information. The global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between feature identifier IDs and global IDs. The search result of the global ID in the second mapping information is determined. The second mapping information includes the mapping relationship between the global ID and the cache slot ID in the video memory, the data validity identifier of the cache slot, the reference count, and the set of scheduling unit identifiers referencing the cache slot. If the search result is a hit and the data validity identifier indicates that the corresponding data is valid, the corresponding cache slot ID is used as the target cache slot ID. If the search result is a miss and / or the data validity identifier indicates that the corresponding data is invalid, a new cache slot is allocated for the global ID, the corresponding cache slot ID is used as the target cache slot ID, and the corresponding global ID is added to the list to be retrieved. Based on the target cache slot ID, the embedding data corresponding to the global ID is determined. According to the first mapping information, the cache slot ID where the embedding data required for each feature identifier ID resides is determined. After the scheduling unit's computation task is completed, the global ID set corresponding to the scheduling unit is traversed, the reference count corresponding to each global ID is decreased sequentially, and the scheduling unit's identifier is removed from the scheduling unit identifier set. By combining data validity identifiers to refine the execution logic of data hit and miss branches, it can be ensured that the system only initiates fetching for missing or invalid data, avoiding repeated consumption of network bandwidth and GPU memory resources. By combining task lifecycle, the scheduling unit's reference to the cache slot can be released promptly after computation, achieving real-time and dynamic updates to memory usage status.

[0077] In other words, this application achieves both cross-Pass embedding reuse and precise lifecycle protection through persistent global ID caching (i.e., the second mapping information mentioned above) and reference counting. Embeddings with a reference count greater than zero will never be evicted, while embeddings with a reference count of zero are released in batches at the Pass level. This solves two problems: First, reuse: avoids repeated Transform lookups and repeated Fetch operations for overlapping IDs in adjacent Passes. In actual recommendation scenarios, the ID overlap rate between adjacent Passes is usually 30%-60%, and this mechanism can save a corresponding proportion of Fetch requests. Second, precise eviction: protects embeddings currently being used by active training tasks from being mistakenly evicted, ensuring training stability, while reducing eviction management overhead by releasing in batches at the Pass level.

[0078] For example, such as Figure 6 As shown, Figure 6 This is a schematic diagram of a cross-pass reuse and reference counting mechanism according to an embodiment of this application. The specific steps include: Step 1 - Global ID Cache Structure Definition: Maintain GlobalIDCache, whose core data structure is HashMap.<global_id → CacheSlot> The CacheSlot contains the following fields: cache_id (memory slot index), ref_count (current reference count, i.e. how many active passes reference it), in_passes (the set of pass IDs referencing this slot), is_valid (whether the Embedding data has been fetched from the PS to the memory), and total_freq (cumulative access frequency, used for statistics).

[0079] Step 2 - Transform Lookup and Reuse of New Pass: For each unique_global_id in the new Pass, execute the following logic: Look up the global_id in GlobalIDCache; if a match is found (cache entry exists) and is_valid is true, directly reuse the corresponding cache_id (no need to allocate a new slot), execute ref_count += 1, add the current pass_id to the in_passes set, this ID does not need to be added to the Fetch list (Embedding data is already in video memory); if a match is not found or is_valid is false, allocate a new cache_id slot, create a new CacheSlot and set ref_count = 1 and is_valid = false, add the ID to the Fetch list, and set is_valid = true in a callback after the Fetch is completed.

[0080] Step 3 - Pass Release and Reference Decrease: When the forward / backward computation of training is completed and the data of the Pass is no longer needed, iterate through all unique_global_ids of the Pass; execute ref_count-= 1 for the CacheSlot of each global_id; remove the pass_id from the in_passes set.

[0081] Step 4 - Eviction Triggering and Precise Judgment: Maintain a Pass queue (FIFO) to record all active Passes; Trigger condition one is that the Pass queue length reaches the max_passes limit (e.g., 8); Trigger condition two is that the cache slot utilization rate exceeds the eviction_threshold threshold (e.g., 80%); Select the Pass at the head of the Pass queue (the earliest created) as the eviction target.

[0082] Step 5 - Perform precise eviction: For each global_id of the target Pass, check if the ref_count is 0: If ref_count == 0, the Embedding is no longer used by any active Pass, the corresponding memory slot is reclaimed (marked as free and reusable), the mapping entry is deleted from the GlobalIDCache, and optionally the Embedding data is asynchronously written to host memory as a second-level cache; if ref_count > 0, the Embedding is still used by other active Passes and is retained without eviction. If capacity is still insufficient after eviction of a Pass, continue eviction of the next head Pass in the queue, repeating until the capacity requirement is met.

[0083] Step 6 - Asynchronous Execution: The elimination operation is executed asynchronously through a background thread, running in parallel with the main training process, without blocking the forward / backward computation of the current batch.

[0084] Capacity planning formula: capacity = max_pass_size × max_passes × overlap_factor, where max_pass_size is the maximum number of unique IDs per pass, max_passes is the maximum number of passes that can reside simultaneously (e.g., 4~8), and overlap_factor is the overlap factor (usually 1.5~2.0, considering overlap across pass IDs). Example: 100000 × 4 × 2.0 = 800000 slots.

[0085] It should be noted that the single-point technologies such as batch fusion, reference counting, and cache eviction in this application are themselves an inseparable combination of technologies.

[0086] Based on the above embodiments, this application proposes a dynamic Embedding cache management method based on a Pass scheduling unit. The core technical solution comprises two key components that form a progressive relationship: technical means one addresses the problem of efficient processing, while technical means two addresses the problem of precise lifecycle management. Figure 7 As shown, Figure 7 This is a system architecture diagram of an embodiment of this application.

[0087] For example, the cache management method for embedded embedding data proposed in this application is applicable to the following large-scale recommender system training scenarios.

[0088] (1) Search recommendation ranking model training: In the ranking model training of search engines and e-commerce platforms, the feature space usually contains sparse features such as user IDs, product IDs, and query term IDs in the billions, which require dynamic management of the Embedding cache.

[0089] (2) Training of the advertising click-through rate prediction model: The advertising CTR / CVR model contains a large number of features such as advertising creative IDs, advertiser IDs, and user behavior sequences. When conducting distributed training on a multi-XPU cluster, efficient Embedding cache management is required.

[0090] (3) Information flow recommendation model training: In the content recommendation scenario, the user behavior sequence is long, the item pool is large, and the overlap rate of users / items between consecutive batches is high. The cross-pass reuse mechanism of this invention is particularly suitable.

[0091] For example, taking the training of a search recommendation ranking model as an example, such as Figure 8 As shown, Figure 8 This is a Pass lifecycle timing diagram according to an embodiment of this application, which includes the following processes: Step 1 - Initialization at Training Startup: PassConfig(pass_size=4, timeout_ms=100, max_ids_per_pass=100000); CacheConfig(max_passes=8, capacity=800000, eviction_threshold=0.8); This invention can be integrated into the training framework via the wrap() interface.

[0092] Step 2 - Training Loop: The DataLoader generates training data from Batch_1 to Batch_4 (each batch contains global_ids such as user ID and product ID); the BatchFusion module of this invention merges the four batches into Pass_k; Pass_k is processed by merging and deduplication → unified Transform → batch Fetch → result distribution; after each batch obtains cache_ids, it retrieves vectors from the GPU memory Embedding table index; the model performs forward computation, loss calculation, backpropagation, and parameter update; after training is completed, free_pass(Pass_k) is called to release the reference.

[0093] Step 3 - Continuous Training: When Pass_k+1 is created, the IDs that overlap with Pass_k are directly reused in the cache (no need to re-fetch); when the Pass queue is full, the oldest Pass is automatically evicted, releasing its exclusive cache slot.

[0094] User interface example: By completing the configuration once using wrap(url,dataloader,model,configs, batch_fusion_config=PassConfig(pass_size=4,timeout_ms=100,max_ids_per_pass=100000,enable_dedup=True), cache_config=CacheConfig(max_passes=8, capacity=800000,eviction_threshold=0.8)), all the capabilities of this invention can be enabled. The training loop code does not need any modification, and BatchFusion is transparently completed at the underlying level.

[0095] Based on the cache management method for embedded embedding data provided in the above embodiments, this application can achieve at least the following technical effects: (1) Improved training throughput: By merging N Transform calls into one through batch fusion, the number of distributed synchronizations and Python-C++ cross-language calls is reduced by N times (N=pass_size). Cross-pass reuse can further reduce Fetch requests by about 50% with a 50% ID overlap rate. Under the combined effect, the training throughput is theoretically improved by 2-4 times.

[0096] (2) Improved training stability: The precise elimination mechanism based on reference counting eliminates the problem of active embeddings being mistakenly eliminated, and eliminates training loss jitter and performance fluctuation caused by mistaken elimination. Compared with the existing coarse-grained elimination scheme based on LRU, it is more precise and controllable.

[0097] (3) Improved XPU resource utilization: The idle time of XPU waiting for Transform in batch queues is eliminated. After Pass fusion, XPU can continuously process multiple batches of data, and the computing utilization is significantly improved.

[0098] (4) Improved development efficiency: This invention is transparently integrated into the existing training framework through the wrap() interface. Users do not need to modify the training loop code, but only need to configure parameters to enable all optimization capabilities. The migration cost for existing recommendation training tasks is extremely low.

[0099] (5) Compared with the static sharding scheme of Meta TorchRec / DLRM, this application has dynamic caching capability and can adapt to scenarios where the feature space far exceeds the video memory capacity; compared with the batch LRU caching scheme of NVIDIA HugeCTR, this application eliminates the serial bottleneck through Pass fusion and avoids the erroneous elimination of active data through reference counting; compared with the schemes such as Alibaba PAI-HybridBackend that focus on distributed storage and communication, this invention focuses on batch fusion and cache reuse in the training phase, and can be orthogonally superimposed with existing distributed schemes.

[0100] According to embodiments of this disclosure, this disclosure also provides a cache management device for embedding data, used to implement the above-described cache management method for embedding data.

[0101] Figure 9 This is a block diagram of a cache management apparatus for embedded embedding data according to an embodiment of the present disclosure.

[0102] like Figure 9 As shown, the cache management device 900 for embedding data includes: a first processing module 901, a first determining module 902, a second determining module 903, and a third determining module 904.

[0103] The processing module 901 is used to merge multiple batches of feature identifier IDs to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier ID and the global ID; The first determining module 902 is used to determine the target cache slot ID corresponding to the global ID; The second determining module 903 is used to determine the Embedding data corresponding to the global ID based on the target cache slot ID; The third determining module 904 is used to determine the cache slot ID where the Embedding data required for each of the feature identifiers is located, based on the first mapping information.

[0104] In one embodiment of this disclosure, the processing module 901 is specifically used for: The feature identifiers ID of multiple consecutive batches are added to the collection buffer of the same scheduling unit until the preset merging trigger condition is met; All the feature identifier IDs within the scheduling unit are concatenated and deduplicated to obtain the deduplicated global ID set and the first mapping information used to record the position of the original feature identifier IDs.

[0105] In one embodiment of this disclosure, the merge triggering condition includes at least one of the following: The cumulative number of the batch within the scheduling unit reaches a preset batch threshold. The cumulative number of the feature identifier IDs in the scheduling unit reaches a preset threshold for the total number of IDs. The waiting time of the scheduling unit exceeds the preset timeout threshold.

[0106] In one embodiment of this disclosure, the first determining module 902 is specifically used for: Determine the lookup result of the global ID in the second mapping information, wherein the second mapping information includes the mapping relationship between the global ID and the cache slot ID in the video memory; Based on the search results, determine the target cache slot ID corresponding to the global ID.

[0107] In one embodiment of this disclosure, the second mapping information further includes a data validity identifier of the cache slot, a reference count, and a set of scheduling unit identifiers referencing the cache slot; Specifically, the first determining module 902 is used for: If the search result is a match and the data validity identifier indicates that the corresponding data is valid, then the corresponding cache slot ID is used as the target cache slot ID; If the search result is a miss and / or the data validity identifier indicates that the corresponding data is invalid, then a new cache slot is allocated for the global ID, the corresponding cache slot ID is used as the target cache slot ID, and the corresponding global ID is added to the list to be fetched.

[0108] In one embodiment of this disclosure, if the search result is a match and the data validity identifier indicates that the corresponding data is valid, the first determining module 902 is further configured to: Increase the reference count of the cache slot corresponding to the target cache slot ID; Add the identifier of the current scheduling unit to the set of scheduling unit identifiers of the cache slot corresponding to the target cache slot ID.

[0109] In one embodiment of this disclosure, if the search result is a no-match and / or the data validity identifier indicates that the corresponding data is invalid, the first determining module 902 is further configured to: Set the reference count of the cache slot corresponding to the target cache slot ID to 1; Set the data validity flag of the cache slot corresponding to the target cache slot ID to invalid; Add the identifier of the current scheduling unit to the set of scheduling unit identifiers of the cache slot corresponding to the target cache slot ID.

[0110] In one embodiment of this disclosure, the second determining module 903 is specifically used for: If the search result is a miss and / or the data validity identifier indicates that the corresponding data is invalid, then a pull request is initiated to the remote server according to the list to be pulled to obtain the corresponding Embedding data; After the Embedding data is acquired, the corresponding data validity flag is updated to valid.

[0111] In one embodiment of this disclosure, the device 900 is further configured to: After the computation task of the scheduling unit is completed, the global ID set corresponding to the scheduling unit is traversed, the reference count corresponding to each global ID is decremented in turn, and the identifier of the scheduling unit is removed from the scheduling unit identifier set.

[0112] In one embodiment of this disclosure, the device 900 is further configured to: Maintain a queue to record all active scheduling units; When a preset elimination condition is met, the scheduling unit located at the head of the queue is identified as the elimination target; Determine the reference count corresponding to each of the global IDs in the elimination targets; In response to the reference count reaching zero, the corresponding cache slot is reclaimed, and the corresponding mapping entry is deleted from the second mapping information.

[0113] In one embodiment of this disclosure, the preset elimination condition includes at least one of the following: The length of the queue has reached a preset upper limit; The cache slot utilization rate exceeds the preset utilization rate threshold.

[0114] The cache management device for embedded embedding data proposed in this application merges multiple batches of feature identifier IDs to obtain a global ID set and first mapping information. The global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier IDs and the global IDs. The device then determines the target cache slot ID corresponding to the global ID; based on the target cache slot ID, it determines the embedding data corresponding to the global ID; and according to the first mapping information, it determines the cache slot ID where the required embedding data for each feature identifier ID resides. This application, through batch processing and reverse distribution mechanisms, can eliminate the overhead of repeated addressing and data fetching in high-frequency concurrent scenarios with multiple batches, significantly improving system concurrency throughput and reducing cross-node communication latency.

[0115] According to embodiments of this disclosure, this disclosure also provides an electronic device, a readable storage medium, and a computer program product.

[0116] Figure 10 A schematic block diagram of an example electronic device 1000 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 may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0117] like Figure 10 As shown, device 1000 includes a computing unit 1001, which can perform various appropriate actions and processes according to a computer program stored in read-only memory (ROM) 1002 or a computer program loaded into random access memory (RAM) 1003 from storage unit 1008. The RAM 1003 may also store various programs and data required for the operation of device 1000. The computing unit 1001, ROM 1002, and RAM 1003 are interconnected via bus 1004. Input / output (I / O) interface 1005 is also connected to bus 1004.

[0118] Multiple components in device 1000 are connected to I / O interface 1005, including: input unit 1006, such as keyboard, mouse, etc.; output unit 1007, such as various types of monitors, speakers, etc.; storage unit 1008, such as disk, optical disk, etc.; and communication unit 1009, such as network card, modem, wireless transceiver, etc. Communication unit 1009 allows device 1000 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0119] The computing unit 1001 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 1001 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 1001 performs the various methods and processes described above, such as the cache management method for embedded embedding data. For example, in some embodiments, the cache management method for embedded embedding data can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 1008. In some embodiments, part or all of the computer program can be loaded and / or installed on device 1000 via ROM 1002 and / or communication unit 1009. When the computer program is loaded into RAM 1003 and executed by the computing unit 1001, one or more steps of the cache management method for embedded embedding data described above can be performed. Alternatively, in other embodiments, the computing unit 1001 may be configured to perform a cache management method for embedded embedding data by any other suitable means (e.g., by means of firmware).

[0120] Various embodiments of the systems and techniques described above 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), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0121] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0122] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0123] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, 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 sound input, voice input, or tactile input).

[0124] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0125] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, servers in distributed systems, or servers incorporating blockchain technology.

[0126] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.

[0127] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.

Claims

1. A cache management method for embedded embedding data, characterized in that, The method includes: Multiple batches of feature identifier IDs are merged to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifier ID and the global ID; Determine the target cache slot ID corresponding to the global ID; Based on the target cache slot ID, determine the Embedding data corresponding to the global ID; Based on the first mapping information, determine the cache slot ID where the Embedding data required for each of the feature identifier IDs is located.

2. The method according to claim 1, characterized in that, The process of merging feature identifiers from multiple batches to obtain a global ID set and first mapping information includes: The feature identifiers ID of multiple consecutive batches are added to the collection buffer of the same scheduling unit until the preset merging trigger condition is met; All the feature identifier IDs within the scheduling unit are concatenated and deduplicated to obtain the deduplicated global ID set and the first mapping information used to record the position of the original feature identifier IDs.

3. The method according to claim 2, characterized in that, The merge triggering condition includes at least one of the following: The cumulative number of the batch within the scheduling unit reaches a preset batch threshold. The cumulative number of the feature identifier IDs in the scheduling unit reaches a preset threshold for the total number of IDs. The waiting time of the scheduling unit exceeds the preset timeout threshold.

4. The method according to claim 1, characterized in that, Determining the target cache slot ID corresponding to the global ID includes: Determine the lookup result of the global ID in the second mapping information, wherein the second mapping information includes the mapping relationship between the global ID and the cache slot ID in the video memory; Based on the search results, determine the target cache slot ID corresponding to the global ID.

5. The method according to claim 4, characterized in that, The second mapping information also includes the data validity identifier of the cache slot, the reference count, and the set of scheduling unit identifiers that reference the cache slot; The step of determining the target cache slot ID corresponding to the global ID based on the search result includes: If the search result is a match and the data validity identifier indicates that the corresponding data is valid, then the corresponding cache slot ID is used as the target cache slot ID; If the search result is a miss and / or the data validity identifier indicates that the corresponding data is invalid, then a new cache slot is allocated for the global ID, the corresponding cache slot ID is used as the target cache slot ID, and the corresponding global ID is added to the list to be fetched.

6. The method according to claim 5, characterized in that, If the search result is a match and the data validity identifier indicates that the corresponding data is valid, the method further includes: Increase the reference count of the cache slot corresponding to the target cache slot ID; Add the identifier of the current scheduling unit to the set of scheduling unit identifiers of the cache slot corresponding to the target cache slot ID.

7. The method according to claim 5, characterized in that, If the search result is a no-match and / or the data validity identifier indicates that the corresponding data is invalid, the method further includes: Set the reference count of the cache slot corresponding to the target cache slot ID to 1; Set the data validity flag of the cache slot corresponding to the target cache slot ID to invalid; Add the identifier of the current scheduling unit to the set of scheduling unit identifiers of the cache slot corresponding to the target cache slot ID.

8. The method according to claim 5, characterized in that, The step of determining the Embedding data corresponding to the global ID based on the target cache slot ID includes: If the search result is a miss and / or the data validity identifier indicates that the corresponding data is invalid, then a pull request is initiated to the remote server according to the list to be pulled to obtain the corresponding Embedding data; After the Embedding data is acquired, the corresponding data validity flag is updated to valid.

9. The method according to claim 5, characterized in that, The method further includes: After the computation task of the scheduling unit is completed, the global ID set corresponding to the scheduling unit is traversed, the reference count corresponding to each global ID is decremented in turn, and the identifier of the scheduling unit is removed from the scheduling unit identifier set.

10. The method according to claim 5, characterized in that, The method further includes: Maintain a queue to record all active scheduling units; When a preset elimination condition is met, the scheduling unit located at the head of the queue is identified as the elimination target; Determine the reference count corresponding to each of the global IDs in the elimination targets; In response to the reference count reaching zero, the corresponding cache slot is reclaimed, and the corresponding mapping entry is deleted from the second mapping information.

11. The method according to claim 10, characterized in that, The preset elimination conditions include at least one of the following: The length of the queue has reached a preset upper limit; The cache slot utilization rate exceeds the preset utilization rate threshold.

12. A cache management device for embedded embedding data, characterized in that, The device includes: The processing module is used to merge feature identifiers IDs from multiple batches to obtain a global ID set and a first mapping information, wherein the global ID set includes at least one global ID, and the first mapping information includes the mapping relationship between the feature identifiers IDs and the global IDs; The first determining module is used to determine the target cache slot ID corresponding to the global ID; The second determining module is used to determine the Embedding data corresponding to the global ID based on the target cache slot ID; The third determining module is used to determine the cache slot ID where the Embedding data required for each of the feature identifiers is located, based on the first mapping information.

13. An electronic device, characterized in that, Including processor and memory; The processor reads executable program code stored in the memory to run a program corresponding to the executable program code, so as to implement the method as described in any one of claims 1-11.

14. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the method as described in any one of claims 1-11.

15. A computer program product comprising a computer program that, when executed by a processor, implements the method according to any one of claims 1-11.