CN-121979839-A - External memory enhancement method and system based on memory entropy dynamic management
Abstract
The application provides an external memory enhancement method and system based on memory entropy dynamic management, belongs to the technical field of artificial intelligence, and aims to solve the problems of inaccurate evaluation of external memory management value and single management means. The method dynamically calculates a quantized memory entropy value for memory entries through a memory entropy calculation and management engine. The entropy value is based on a weighted formula and integrates multiple dimensions including access frequency, time decay, correlation strength, and value confidence dynamically adjusted based on historical feedback. The system divides memory entries into different value levels according to entropy values and performs differentiated management operations including storage migration, content compression, archiving, or deletion. The application can evaluate the memory value more accurately, and realize comprehensive life cycle management, thereby improving the quality of the external memory library and the decision efficiency of the large language model.
Inventors
- YANG YONG
- QIAN WEIDONG
- CHEN XIAOWU
- QIANG XUGANG
- YU YUNLE
Assignees
- 上海宝信软件股份有限公司
Dates
- Publication Date
- 20260505
- Application Date
- 20260115
Claims (10)
- 1. An external memory enhancement method based on memory entropy dynamic management, which is applied to a system comprising a large language model core and a structured external memory module, is characterized by comprising the following steps: Dynamically calculating a quantized memory entropy value for memory items in the structured external memory module through a memory entropy calculation and management engine, wherein the calculation of the memory entropy value is based on a preset weighting formula, and metadata of a plurality of dimensions including at least value confidence is synthesized; dividing the memory entries into different value levels according to the memory entropy value; And executing differentiated memory management operation on the memory entry according to the value level to which the memory entry belongs, wherein the differentiated memory management operation comprises at least one of migration of a storage position, compression of content, archiving or deleting.
- 2. The method for enhancing external memory based on dynamic management of memory entropy as claimed in claim 1, wherein the plurality of dimensions comprises at least access frequency, time decay, association strength and value confidence.
- 3. The external memory enhancement method based on memory entropy dynamic management of claim 2, wherein the value confidence is dynamically adjusted based on positive or negative feedback obtained by the memory entry in historical usage.
- 4. The external memory enhancement method based on memory entropy dynamic management according to claim 1, wherein the differentiated memory management operation comprises: For memory entries that are partitioned to a high value level, they are stored in a high-speed storage medium and are preferentially retrieved as the large language model core processes tasks.
- 5. The external memory enhancement method based on memory entropy dynamic management according to claim 1, wherein the differentiated memory management operation comprises: For memory entries partitioned to low value levels, at least one of a compression, archiving, or deletion operation is performed according to at least one of a memory entropy value of the memory entry, a duration of time that it is at a low value level.
- 6. An external memory enhancement system based on dynamic management of memory entropy, comprising: a large language model core; a structured external memory module for storing memory entries; a memory entropy calculation and management engine, the memory entropy calculation and management engine is configured to: dynamically calculating a quantized memory entropy value for memory entries in the structured external memory module, wherein the calculation of the memory entropy value is based on a preset weighting formula and integrates metadata of a plurality of dimensions including at least value confidence; dividing the memory entries into different value levels according to the memory entropy value; And executing differentiated memory management operation on the memory entry according to the value level to which the memory entry belongs, wherein the differentiated memory management operation comprises at least one of migration of a storage position, compression of content, archiving or deleting.
- 7. The external memory enhancement system based on dynamic management of memory entropy according to claim 6, wherein the memory entropy calculation and management engine is configured to calculate the memory entropy value based on a plurality of dimensions including at least access frequency, time decay, association strength, and value confidence.
- 8. The external memory enhancement system based on dynamic management of memory entropy according to claim 7, wherein the memory entropy calculation and management engine is configured to dynamically adjust the value confidence based on positive or negative feedback obtained by the memory entry in historical use.
- 9. The external memory enhancement system based on dynamic management of memory entropy of claim 6, wherein the memory entropy calculation and management engine is further configured to: for memory entries that are partitioned into high value levels, they are stored in a high-speed storage medium and are preferentially provided to the large language model core when processing tasks.
- 10. The external memory enhancement system based on dynamic management of memory entropy of claim 6, wherein the memory entropy calculation and management engine is further configured to: For memory entries partitioned to low value levels, at least one of a compression, archiving, or deletion operation is performed according to at least one of a memory entropy value of the memory entry, a duration of time that it is at a low value level.
Description
External memory enhancement method and system based on memory entropy dynamic management Technical Field The invention relates to the technical field of artificial intelligence, in particular to an external memory enhancement method and system based on memory entropy dynamic management. Background With the increasing use of large language models in long-period, complex tasks, they require the storage of interaction history, knowledge segments, and environmental states by means of external memory systems to assist in their reasoning and decision making. However, as memory continues to accumulate, the size of the external memory bank will expand, causing a "memory explosion" problem. This not only increases the storage costs dramatically, but more importantly, a large number of redundant, stale or low value memory entries overwhelm a small number of core critical information, resulting in inefficiency in retrieving relevant memory for the model, and even decreasing the accuracy and stability of decisions due to interference from irrelevant information. To address this challenge, some memory management schemes have been proposed in the prior art. For example, there is a scheme that a comprehensive data value score is calculated according to objective attributes such as the access frequency, the last access time, and the semantic association degree of the memory entries, and data is migrated between storage media with different speeds according to the score, for example, data with high value score is stored in a cache, and data with low value score is migrated to a hard disk with lower cost. However, this type of approach has significant drawbacks. Firstly, the value evaluation dimension is single, and the value evaluation dimension is mainly dependent on indirect indexes such as access modes, and the actual utility or correctness of a memory entry for completing a task cannot be truly measured. For example, a memory that is frequently accessed but has incorrect content may instead be erroneously determined to be of high value, thereby having a persistent negative impact on the decision making of a large language model. Second, existing management approaches are typically limited to migration of storage locations, lacking a more comprehensive and thorough lifecycle management mechanism such as content compression, archival isolation, or complete deletion for memories that have proven useless or of extremely low value. This results in the overall quality of the memory pool still being continuously degraded over time, and the problem of resource waste is not fundamentally solved. Disclosure of Invention Aiming at the defects in the prior art, the invention aims to provide an external memory enhancement method and system based on memory entropy dynamic management. The external memory enhancement method based on memory entropy dynamic management, provided by the invention, is applied to a system comprising a large language model core and a structured external memory module, and comprises the following steps: Dynamically calculating a quantized memory entropy value for memory items in the structured external memory module through a memory entropy calculation and management engine, wherein the calculation of the memory entropy value is based on a preset weighting formula, and metadata of a plurality of dimensions including at least value confidence is synthesized; dividing the memory entries into different value levels according to the memory entropy value; And executing differentiated memory management operation on the memory entry according to the value level to which the memory entry belongs, wherein the differentiated memory management operation comprises at least one of migration of a storage position, compression of content, archiving or deleting. Preferably, the plurality of dimensions includes at least access frequency, time decay, correlation strength, and value confidence. Preferably, the value confidence is dynamically adjusted based on positive or negative feedback obtained by the memory entry over historical use. Preferably, the differentiated memory management operation includes: For memory entries that are partitioned to a high value level, they are stored in a high-speed storage medium and are preferentially retrieved as the large language model core processes tasks. Preferably, the differentiated memory management operation includes: For memory entries partitioned to low value levels, at least one of a compression, archiving, or deletion operation is performed according to at least one of a memory entropy value of the memory entry, a duration of time that it is at a low value level. The invention provides an external memory enhancement system based on memory entropy dynamic management, which comprises: a large language model core; a structured external memory module for storing memory entries; a memory entropy calculation and management engine, the memory entropy calculation and management engine is