An intelligent agent personal memory management method and system based on evidence binding
The intelligent agent memory management method, which uses evidence binding and quantitative evaluation, solves the problems of unexplainable and irrevocable intelligent agent memories, and realizes the trustworthy governance and traceability of memories.
Patent Information
- Application Number
- CN202611329651.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-31
- Publication Date
- 2026-11-24
AI Technical Summary
The existing intelligent agent's memory lacks structured evidence binding and state management, resulting in memory that is untraceable and unexplainable. Errors or temporary inferences are easily solidified, and once the memory is corrected or revoked, its continuous impact on downstream content cannot be stopped.
By extracting candidate memories from the dialogue between the user and the intelligent agent and binding them with evidence tags, and combining quantitative evaluations of evidence completeness, memory conflict penalties and user authorization strength, a comprehensive score and conflict detection are used as the entry threshold. The memory state is managed using append-only snapshot storage and a four-state machine to ensure the interpretability, auditability and revocability of the memory.
It achieves trusted governance of the entire lifecycle of intelligent agent memory, ensuring the interpretability, auditability, and revocability of memory, preventing error solidification, and blocking the impact of revocation on downstream content.
Smart Images

Figure CN123157724A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and specifically to an intelligent agent personal memory management method and system based on evidence binding. Background Technology
[0002] In the long-term process of serving users, intelligent agents need to continuously accumulate personalized knowledge such as user preferences, project background, and historical decisions in order to provide more accurate auxiliary services.
[0003] In existing technologies, pagination management schemes based on memory streams can save historical interactions as text summaries, while memory bank schemes based on vector retrieval can enable the retrieval of personalized information. However, these schemes share a common drawback: the lack of structured evidence binding and state management of memories leads to memories being untraceable and uninterpretable, errors or temporary inferences being easily solidified, and the inability to prevent the continued impact of memories on downstream content after they are corrected or revoked.
[0004] It is evident that how to enable intelligent agents to possess the ability to govern assets in a way that is explainable, auditable, and revocable is a pressing technical problem that needs to be solved. Summary of the Invention
[0005] In view of this, the purpose of this invention is to provide a method and system for managing personal memories of intelligent agents based on evidence binding, which enables the memories of intelligent agents to have the ability to be explained, reviewed, and revoked as assets.
[0006] According to a first aspect of the present invention, a method for managing personal memories of an intelligent agent based on evidence binding is provided, comprising: Candidate memories are extracted from the dialogue between the user and the intelligent agent, and each candidate memory is bound to an evidence tag; wherein, the evidence tag includes at least the memory source and memory permissions; Based on the evidence tags, determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory; Based on the completeness of the evidence, the penalty for memory conflict, and the strength of user authorization, a comprehensive score is calculated for the candidate memory; If the overall score reaches a preset score threshold and the candidate memory passes conflict detection, the memory status of the candidate memory is confirmed from the candidate status to the verified status and written into the memory bank; wherein, the memory status includes at least the candidate status, the verified status, the archived status, and the revocation status, the revocation status indicating that it has been marked as invalid and the content referencing the memory has been notified that it is invalid; the memory bank is an append-only snapshot storage; A context projection is generated based on the real-time dialogue questions between the user and the intelligent agent, as well as the verified memories in the memory bank. Based on the context projection, the intelligent agent is assisted in generating an answer.
[0007] According to a second aspect of the present invention, an intelligent agent personal memory management system based on evidence binding is provided, comprising: The memory extraction and evidence binding module is used to extract candidate memories from the dialogue between the user and the intelligent agent, and bind evidence tags to each candidate memory; wherein, the evidence tags include at least the memory source and memory permissions; The comprehensive scoring calculation module is used to determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory based on the evidence tags; and to calculate the comprehensive score of the candidate memory based on the evidence completeness, the memory conflict penalty, and the user authorization strength. The memory storage processing module is used to confirm the memory status of the candidate memory from the candidate state to the verified state and write it into the memory bank if the comprehensive score reaches a preset score threshold and the candidate memory passes the conflict detection; wherein, the memory status includes at least the candidate state, the verified state, the archived state, and the revocation state, and the revocation state indicates that it has been marked as invalid and the content referencing the memory has been notified of invalidity; the memory bank is an append-only snapshot storage; The intelligent agent dialogue module is used to generate a context projection based on real-time dialogue questions between the user and the intelligent agent, as well as verified memories in the memory bank; and to assist the intelligent agent in generating answers based on the context projection.
[0008] According to a third aspect of the present invention, an electronic device capable of executing an evidence-based intelligent agent personal memory management method is provided, comprising: At least one processor; and a memory communicatively connected to said at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the method described above.
[0009] According to a fourth aspect of the present invention, a non-transitory computer-readable storage medium is provided storing computer instructions for causing a computer to perform the above-described method. This invention extracts candidate memories from dialogues and binds them with evidence tags containing the memory's source and permissions, ensuring that each memory is verifiable and traceable. Combined with append-only snapshot storage in the memory bank, it achieves complete traceability of memories from their creation to modification, solving the problems of unexplainable and unauditable memories in existing technologies. By using evidence tags to drive quantitative evaluation of evidence completeness, conflict penalties, and authorization strength, a comprehensive score is calculated as an entry threshold. Only when the score meets the threshold and conflict detection passes can a candidate memory be confirmed as verified and written into the memory bank. This multi-stage evaluation-before-confirmation approach... The dimensional review mechanism eliminates the risk of imputed or erroneous conclusions being silently solidified at the source, solving the problems of unreviewable memories and susceptibility to erroneous writing in existing technologies. Furthermore, by combining the state transitions of a four-state memory state machine with append-only snapshot storage, verified memories can be precisely rolled back to any historical version when replaced or revoked. Simultaneously, the revocation state explicitly associates the invalidation of content referencing that memory, ensuring that the revocation of a memory does not contaminate the generated context projection and historical responses. This solves the problem in existing technologies where the continued impact of corrected or revoked memories on downstream content cannot be prevented. In summary, evidence tags provide a quantitative basis for review, the review mechanism provides access control for the state machine, and the state machine and snapshot storage provide traceability for revocation propagation, collectively achieving trusted governance of intelligent proxy memories throughout their entire lifecycle.
[0010] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit the invention. Attached Figure Description
[0011] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0012] Figure 1 This is a flowchart illustrating an evidence-based intelligent agent personal memory management method according to an exemplary embodiment; Figure 2 This is a schematic block diagram illustrating an evidence-based intelligent agent personal memory management system according to an exemplary embodiment; Figure 3 This is a schematic diagram of the internal control circuit of an electronic device according to an exemplary embodiment. Detailed Implementation
[0013] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the invention as detailed in the appended claims.
[0014] Figure 1 This is a flowchart illustrating an evidence-based intelligent agent personal memory management method according to an exemplary embodiment, including: S1. Extract candidate memories from the dialogue between the user and the intelligent agent, and bind an evidence tag to each candidate memory; wherein, the evidence tag includes at least the memory source and memory permission; S2. Determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory based on the evidence tags; S3. Calculate the comprehensive score of the candidate memory based on the completeness of the evidence, the memory conflict penalty, and the strength of the user authorization; S4. If the overall score reaches a preset score threshold and the candidate memory passes the conflict detection, the memory status of the candidate memory is confirmed from the candidate status to the verified status and written into the memory bank; wherein, the memory status includes at least the candidate status, the verified status, the archived status, and the revocation status, the revocation status indicating that it has been marked as invalid and the content referencing the memory has been notified that it is invalid; the memory bank is an append-only snapshot storage; S5. Based on the real-time dialogue questions between the user and the intelligent agent, and the verified memories in the memory bank, generate a context projection; S6. Based on the context projection, assist the intelligent agent in generating an answer.
[0015] In this embodiment, the executing entity can be an electronic device such as a terminal or server, and this embodiment does not limit this.
[0016] During the interaction between the intelligent agent and the user, the system collects various usage events in real time through an event listening mechanism, including dialogue messages, data import, user error correction feedback, tool calls, and task execution results. Then, the system extracts personal knowledge fragments with long-term preservation value from these events as candidate memories according to preset rules. Specific extraction rules may include: when the user expresses preferences, facts, or rules in the form of explicit instructions, such as statements containing trigger words like "remember," "every future," or "my habit is," the system directly extracts that statement as a candidate memory; when the same type of information appears repeatedly in multiple dialogues, the system identifies it as a candidate memory with long-term value; when the user corrects the intelligent agent's output, the system extracts the corrected information as a candidate memory; when the user repeatedly calls the same tool or uses the same operating procedure, the system extracts the corresponding tool preference or process habit as a candidate memory. Each extracted candidate memory needs to be bound to an evidence tag, which is a structured metadata set attached to the candidate memory, containing at least two core fields: memory source and memory permissions. The memory source records the origin of the candidate memory, including source ID, source type, timestamp, and excerpt of the original statement, which is the foundation for memory interpretability. Memory permissions record the access permission level for the candidate memory, including session-level, project-level, global-level, or disabled levels, each corresponding to different usage restrictions. This is crucial for ensuring privacy and security while maintaining accurate access. Optionally, the evidence label may also include additional fields such as sensitivity level, scope of application, verification method, semantic feature vector, time validity range, and list of key entities to further support subsequent accurate evaluation and conflict detection.
[0017] After the evidence tags are bound, the system needs to determine three core evaluation dimensions based on the tag content. The method for determining evidence completeness is to check whether the information regarding the memory source in the evidence tag is sufficient and valid. This includes whether the source ID points to a real conversation turn or event, whether the source type can clearly distinguish between what the user said directly and what the system inferred, whether the timestamp can pinpoint a specific moment, and whether the original statement excerpt retains sufficient context for verification. The more valid information items, the higher the evidence completeness. Determining the memory conflict penalty requires comparing the candidate memory with existing memories in the memory bank that have been verified. Semantic similarity calculations are used to identify memories with similar content, and then further, it is determined whether the conclusions are opposite. If the candidate memory and existing memory give opposite conclusions regarding the same fact, preference, or rule, the conflict penalty value is determined based on the degree of opposite conclusions. The more severe the conflict, the greater the penalty value. If there is a conflict with multiple existing memories, the final penalty value is derived by combining the degree of conflict among all memories. The determination of user authorization strength takes into account two factors: the level of memory permissions and the confirmation method. Global level permissions are given the highest basic authorization strength, followed by project level, then session level, and disabled level is the lowest. At the same time, explicit command confirmation has a higher weight than implicit inferred confirmation, and user confirmation after system prompt has a relatively lower weight. The final user authorization strength value is obtained by combining the two factors.
[0018] The comprehensive score calculation incorporates the evaluation results of three dimensions—evidence completeness, memory conflict penalty, and user authorization strength—within a unified quantitative framework to form a comparable numerical result, thereby objectively determining whether a candidate memory deserves to be recognized as a valid memory. These three dimensions evaluate candidate memories from the perspectives of evidence reliability, content consistency, and user willingness, respectively. However, they are independent and have different dimensions, thus requiring a comprehensive scoring mechanism to weigh various factors and avoid extreme values from a single dimension dominating the decision. Evidence completeness reflects the sufficiency and traceability of the memory source; the more complete the source, the more credible the memory, and this is a positive influencing factor in the comprehensive score. Memory conflict penalty reflects the degree of contradiction between the candidate memory and existing memories; the smaller the conflict, the more reliable the memory, and this factor is a deduction item in the comprehensive score. User authorization strength reflects the user's recognition and importance of the memory; the higher the authorization strength, the more the system should adopt the memory, and this is also a positive influencing factor in the comprehensive score. The comprehensive score maps the evaluation results of these three dimensions to a range of 0 to 1 after unified mathematical processing. The higher the score, the better the candidate memory performs overall in terms of evidence reliability, content consistency, and user intention, and the more qualified it is to be recognized as a valid memory. When the comprehensive score reaches the preset score threshold, it means that the overall performance of the candidate memory in the three dimensions has met the basic requirements for writing into the memory bank, and it can proceed to the subsequent conflict detection stage for further adjudication.
[0019] In other embodiments, the weights of the three dimensions in the overall score can be dynamically configured according to the application scenario. For example, in privacy-sensitive scenarios, the weight of the user's authorization strength can be increased to strengthen the user's control over memory writing. In long-term stable project backgrounds, the weight of evidence integrity can be increased to ensure the reliability of memory sources. In scenarios where user preferences change frequently, the weight of memory conflict penalty can be increased to avoid the mixing of contradictory memories. The specific weight configuration is adaptively set by the system according to the scenario or customized by the user.
[0020] After a candidate memory's overall score reaches a preset threshold, the system performs an independent conflict detection process. This step is separate from the scoring mechanism and serves as a strict entry requirement. While the scoring already includes conflict penalties as deductions to quantify contradictory candidate memories, these penalties alone cannot handle special cases involving severe conflicts or core factual clashes. Even if a memory scores highly in terms of evidence completeness and user authorization strength, it should not be automatically written if it directly contradicts existing memories on key facts. Therefore, conflict detection directly compares the candidate memory with existing verified memories in the memory bank, checking for contradictions or conflicts in factual conclusions, user preferences, scope of application, or time dimensions. If no conflict is found after the system completes the comparison, the detection is considered successful. If a conflict is found but the user has previously given explicit confirmation of the candidate memory, the system also considers the detection successful. If a conflict exists without user confirmation, the detection is considered unsuccessful, and the candidate memory is temporarily suspended from writing pending further user decision. The rigid access control system ensures that even if the scoring model has flaws or the weights are improperly configured, major memory contradictions will not be missed or misjudged, thus forming a double guarantee together with the comprehensive scoring mechanism.
[0021] Once the overall score meets the requirements and conflict detection passes, the system confirms the candidate memory's state as verified and officially writes it into the memory bank. The memory state design includes four states and their transition paths: Candidate state is a temporary state where a memory has just been extracted and has not yet been reviewed and confirmed; memories in this state do not participate in task projection. Verified state is an active state where a memory has been reviewed and confirmed and is considered valid; it can participate in task projection. Archived state is a sealed state where a memory was once valid but is now deemed inapplicable or outdated; although it does not participate in task projection, it retains historical records for auditing purposes. Revoked state is the final state where a memory has been explicitly revoked by the user; this indicates that the memory has been marked invalid and the content referencing it has been notified of its invalidity, and migration to other states is prohibited. The legal transition paths between states are as follows: Candidate states can migrate to verified states after meeting the score and passing conflict detection; verified states can migrate to archived or revoked states; archived states can migrate to revoked states; and revoked states, as final states, are irreversible. The memory uses an append-only snapshot storage method. Each change operation only stores the difference data of this change and appends it to the end of the snapshot chain. In this way, the snapshot chain completely records the history of every change in the memory, supports tracing back the historical state of any memory in chronological order, and realizes accurate audit traceability and version rollback.
[0022] After candidate memories are verified through a dual review process of comprehensive scoring and conflict detection and written into the memory bank, the system still needs to effectively call upon these memories in subsequent dialogue interactions to truly serve the intelligent agent's response generation. When a user poses a new real-time dialogue question to the intelligent agent, the system first parses the semantic content and task scope of the question, and based on this, filters out all memories in the memory bank that are in a verified state and have the authority to be invoked in the current task scenario. On this basis, the system further evaluates and ranks these selected verified memories, selecting the few most relevant to the current question, the most timely, and the highest overall quality, and organizes their content into a structured context projection. This context projection is not a simple splicing of the original memory text, but rather combines the content, source information, and credibility indicators of the memory into text fragments that can be directly used by the large language model according to a preset format.
[0023] After receiving a user's real-time dialogue question, the intelligent agent inputs the generated context projection along with the current dialogue context into the large language model. This allows the model to simultaneously reference the user's current dialogue context and the system's long-term accumulated personal knowledge memory when generating a response. The context projection acts as an external knowledge source in the response generation process. The model can extract information related to the current question, such as user preferences, project background, historical decisions, or established rules, and integrate this information into the final response. In this way, users do not need to repeat their preferences and background information in every conversation; the intelligent agent can automatically provide a personalized and continuous service experience based on its accumulated memory. Furthermore, in some embodiments, the context projection may also include the source information of the memory, allowing the intelligent agent to indicate "according to your request at a certain time..." when generating a response, thereby enhancing the interpretability and credibility of the answer. Because the context projection retains the source information of the memory, the intelligent agent can indicate the source of information as needed when generating a response, resulting in better interpretability and credibility of the answer. Throughout the response generation process, only verified and authorized memories are included in the projection scope. Archived and revoked memories are excluded, ensuring both response quality and the compliance and security of memory usage. When a user subsequently modifies or revokes a memory, the system simultaneously notifies all generated responses referencing that memory of its invalidation, ensuring that revoked memories do not propagate erroneous information through historical responses.
[0024] In summary, this invention binds the source and permissions of memories to evidence tags, coupled with append-only snapshot storage, ensuring that each memory is verifiable and fully traceable, thus solving the problem of unexplainable memories. By using evidence tags to drive quantitative evaluation of evidence completeness, conflict penalties, and authorization strength, and employing comprehensive scoring and conflict detection as entry thresholds, candidate memories are only confirmed as verified and written into the memory bank after meeting these criteria, preventing temporary inferences from being silently solidified and solving the problem of unverifiable memories. Furthermore, by setting up a four-state machine including a revocation state, memories can be precisely rolled back when replaced or revoked. The revocation state is explicitly limited to notifying the referenced content of invalidity, ensuring that revoked memories do not pollute the generated context projections and historical replies, thus solving the problem of memories continuing to affect downstream content after revocation. These collectively achieve trusted governance of the entire lifecycle of intelligent proxy memories.
[0025] As an optional implementation, the following steps may also be performed: In response to a user's command to revoke a target memory, the memory state of the target memory is switched to the revoke state; wherein the memory state of the target memory is either the verified state or the archived state; Retrieve all downstream products that reference the target memory, wherein the downstream products include at least the generated context projection and the generated response content; An invalidation notification is sent to the retrieved downstream product to block the continued reference of the target memory in the downstream product.
[0026] In this implementation, when a memory is revoked, the system performs three core actions. The first action is to switch the target memory's state to the revoked state. However, this action can only be performed on memories currently in the verified or archived state; candidate states are simply discarded, and the revoked state is the final state and cannot be revoked further. A verified memory, once revoked, is removed from the valid library and no longer participates in subsequent projections and response generation; the revocation of an archived memory means that historical archived records are completely erased. The second action is to retrieve all downstream products that reference the target memory. Downstream products refer to various output contents generated by the system based on the target memory while it was in the verified state, including at least generated context projections and generated response content. For example, if a user requested that "all weekly reports be written in Chinese," the system would generate corresponding context projections and multiple Chinese weekly report responses in multiple weekly report generation tasks based on this memory. These projections and responses all reference the hash value or content identifier of the memory and therefore will be retrieved. The third action is to send an invalidation notification to all retrieved downstream products. This notification, appended as a tag or message to downstream outputs, identifies these projections and responses as "generated based on a revoked memory; content may be invalid." When users subsequently view historical responses, the system can use this information to prompt them to verify, thus preventing revoked memories from continuously spreading incorrect information through historical content. For example, if a user revoks the memory "all weekly reports should be written in Chinese," all previously generated Chinese weekly report responses will be marked with "The weekly report writing language preference upon which this response was based was revoked at some point; please verify," ensuring that revoked memories do not continue to mislead users in the form of historical responses.
[0027] As an optional implementation, when performing the revocation propagation, the method further includes detecting breaks in the evidence chain of downstream products referencing the target memory. The break detection includes at least one or more of the following: detecting whether the source of the target memory is still reachable; detecting whether the hash value of the target memory is consistent; detecting whether the audit record of the target memory is complete; detecting whether the authorization of the target memory is still valid; and detecting whether the propagation path of the target memory to each downstream product is complete. If a break is detected, corresponding repair operations are performed according to the break type: for unreachable sources, supplementary evidence collection is performed; for inconsistent hash values, hash binding is rebuilt; for incomplete audits, supplementary audits are performed; for broken propagation paths, alternative evidence blocks or proactive retirement operations are performed. After repair, the repair record is entered into the system and the health score is updated.
[0028] As an optional implementation, the conflict detection includes: performing at least one of the following on the candidate memory and the verified memory in the memory bank: fact conflict detection, preference conflict detection, range conflict detection, and time conflict detection; The fact conflict detection is used to determine whether the candidate memory and the verified memory have opposite conclusions on the same factual content; The preference conflict detection is used to determine whether the candidate memory and the verified memory are inconsistent in terms of user preference settings; The range conflict detection is used to determine whether the conclusions of the candidate memory and the verified memory differ when their applicable ranges overlap. The time conflict detection is used to determine whether there is any overlap or contradiction between the candidate memory and the verified memory in the time dimension.
[0029] In this embodiment, conflict detection includes four specific types: factual conflict detection determines whether the candidate memory and the verified memory have contradictory conclusions on the same fact, for example, one says the deadline is December 31st while the other says the deadline is October 1st; preference conflict detection determines whether the two are inconsistent in their user preference settings, for example, one says the user prefers detailed replies while the other says the user prefers concise replies; scope conflict detection determines whether the two have different conclusions when their applicable scopes overlap, for example, one says all documents for Project A are in Chinese while the other says technical documents for Project A are in English; and time conflict detection determines whether there is an overlap and contradiction in the time dimension, for example, one says Process V1.0 is used all year round while the other says Process V2.0 is used from September. Conflict detection is considered successful only when none of the above four types of conflict exist, or when any existing conflict has been explicitly confirmed by the user. In other embodiments, if a conflict exists but the conflict penalty value is below a certain sub-threshold, it can be considered a minor conflict and passed directly without user confirmation, thus reducing frequent disturbance to the user.
[0030] As an optional implementation, the user authorization strength includes memory permission levels and sensitivity levels; and, based on the evidence completeness, the memory conflict penalty, and the user authorization strength, a comprehensive score for the candidate memory is calculated, including: Based on the extraction quality of the candidate memory, an extraction quality penalty is determined; wherein, the lower the extraction quality, the greater the extraction quality penalty. The memory permission penalty is determined based on the memory permission level, and the sensitivity penalty is determined based on the sensitivity level; wherein, the higher the memory permission level, the smaller the memory permission penalty; and the higher the sensitivity level, the larger the sensitivity penalty. Based on the completeness of the evidence, a penalty for the completeness of the evidence is determined; wherein, the higher the completeness of the evidence, the smaller the penalty for the completeness of the evidence. Based on the sensitivity penalty, the memory access penalty, the evidence completeness penalty, the memory conflict penalty, and the extraction quality penalty, the comprehensive score of the candidate memory is calculated according to the following formula: =1 in, The overall score is as follows. For the aforementioned sensitivity penalty, Penalty for the completeness of the evidence. The memory permission penalty, The penalty for the aforementioned memory conflict, The extraction quality penalty is applied.
[0031] In this implementation, after obtaining the three dimensions of evidence completeness, memory conflict penalty, and user authorization strength, the system incorporates these dimensions into a unified quantitative framework to calculate a comprehensive score. Specifically, the system first obtains five penalty values: sensitivity penalty is determined based on the sensitivity level of the candidate memory, with higher sensitivity levels resulting in greater penalties; evidence completeness penalty is determined based on evidence completeness, with higher evidence completeness resulting in smaller penalties, and the two are inversely proportional; memory permission penalty is determined based on the level of memory permission, with global-level permission penalties being the smallest, and session-level and disabled-level permission penalties increasing sequentially; memory conflict penalty directly uses the conflict penalty value determined in the aforementioned steps; extraction quality penalty is determined based on the clarity of the candidate memory's expression, the degree of contextual support, and whether it is an explicit statement rather than a vague guess, with lower extraction quality resulting in greater penalties. The value range of each penalty value is 0 to 1. Subsequently, the system calculates the comprehensive score according to a formula, which uses a maximum score of 1 as the baseline, takes the average of the five penalties as the total deduction, and subtracts the total deduction from 1 to obtain the final score. If a memory has sufficient evidence, reasonable permissions, credible content, and no serious conflict with existing memories, its overall score will be high; otherwise, it will be low. In other embodiments, the weights of each penalty can be different. For example, a higher weight can be given to sensitivity penalties to strengthen privacy protection. In this case, the overall score can be calculated using a weighted average method, with the sum of each weight being 1.
[0032] As an optional implementation, a context projection is generated based on real-time dialogue questions between the user and the intelligent agent, as well as verified memories in the memory bank, including: Based on the task scope of the real-time dialogue question, determine the memory scope that needs to be invoked; Filter out candidate verified memories that match the memory range and have valid authorization from the memory bank; Calculate the task injection score for each of the selected candidate verified memories; Based on the task injection score, the target verified memory is determined from each of the candidate verified memories; The context projection is generated based on the verified memory of the target.
[0033] In this implementation, when a user poses a new question to the intelligent agent, the system first determines the scope of memories to be accessed based on the task scope of the question. Then, based on memory permissions, it filters from the memory bank to select verified memories that match the task scope and have valid authorization. Global-level memories can be accessed in all tasks, project-level memories are limited to the corresponding project task, session-level memories are limited to the same session, and disabled-level memories cannot be accessed by any task.
[0034] As an optional implementation, the calculation of the task injection score for each candidate verified memory selected includes: The task injection score for each candidate verified memory selected is calculated based on the following formula: = in, Inject a score into the task. The overall score is as follows. The correlation between the candidate verified memories and the real-time dialogue question. As a time-sensitive factor, The expiration penalty is defined by α, β, γ, and λ as weighting coefficients. The more recent the generation time of the candidate verified memory, the higher the expiration factor. The expiration penalty is a penalty value imposed on memories that have exceeded the preset validity period. The longer the time exceeds the preset validity period, the greater the penalty value.
[0035] In this embodiment, for each verified memory selected, the system calculates its task injection score. This score comprehensively considers factors such as the memory's overall score, its semantic relevance to the current problem, the degree of value decay over time, and whether it has exceeded a preset validity period. The memory's overall score comes from the calculation results of previous steps. The relevance to the current problem is calculated through semantic similarity. The timeliness factor measures that the more recent the memory was generated, the higher its freshness and reference value. The expiration penalty applies a deduction to memories that have exceeded their validity period. The weight design can be configured differently depending on the specific scenario. After the calculation is completed, the system selects several memories with the highest scores or selects all memories with scores higher than a certain threshold, and organizes their structured summaries into a context projection. In other embodiments, the context projection may also include a confidence level label for the memory, so that the intelligent agent can determine the degree of acceptance based on the confidence level.
[0036] As an optional implementation, the following steps may also be performed: In response to each write or state change operation of the memory bank, generate the difference data of the current change; The difference data is appended to the end of the snapshot chain to preserve historical snapshots from being overwritten; and the snapshot chain supports tracing back the historical state of any memory in the memory bank in chronological order.
[0037] In this implementation, whenever a write operation or state change occurs in the memory, the system does not overwrite the original data. Instead, it extracts the differences from the change, packages them into a single difference data block, and appends it to the end of the snapshot chain, while preserving the complete state of all previous historical snapshots. In this way, each node in the snapshot chain records the details of the changes to the memory at a given moment, and all historical nodes are fully preserved without overwriting each other. The system can precisely locate the content and state of any memory at any historical moment by traversing the snapshot chain in chronological order, thereby achieving accurate version tracking and rollback. For example, when the permissions of a memory change from "global" to "project," a difference record "Permissions: Global → Project" is appended to the end of the snapshot chain. The original global permission record of that memory, as well as all intermediate change records, are retained in the snapshot chain, allowing the system to revert to the permission state of that memory at any historical moment.
[0038] As an optional implementation, the evidence label further includes at least one of the following: Scope of application is used to limit the types of tasks or project range to which the candidate memory applies; A timestamp is used to record the time when the candidate memory was generated; The confirmation method is used to record how the user confirms the candidate memory. The confirmation method includes explicit command confirmation, implicit inference confirmation, or confirmation after system prompt.
[0039] In this implementation, the scope of application is used to limit the task type or project context under which the candidate memory can be invoked. For example, if a memory is marked as applicable to "Project A", then that memory will not be included in the projection during a dialogue involving Project B. Through this field, the system can isolate memories in a contextualized manner, avoiding interference between preferences of different projects or task types. The timestamp is used to record the generation time of the candidate memory, that is, the specific point in time when the memory was extracted from the usage event. This field provides a basis for subsequent timeliness evaluation. For example, the system can use this to determine the freshness of the memory to calculate the timeliness factor, or to determine whether the memory has exceeded the preset validity period to impose an expiration penalty. The confirmation method records how a user confirms a candidate memory. Specifically, it includes three types: explicit command confirmation, implicit inference confirmation, and confirmation after system prompt. Explicit command confirmation refers to the user clearly stating that the memory should be remembered. Implicit inference confirmation refers to the system inferring the memory from the user's repeated actions or statements and pushing it to the user for confirmation. Confirmation after system prompt refers to the system actively identifying potential recordable information, requesting confirmation from the user, and obtaining the user's approval. Different confirmation methods reflect different levels of authorization from the user regarding the memory. Explicit command confirmation typically corresponds to the highest level of authorization, while confirmation after system prompt corresponds to a relatively lower level of authorization. For example, if a user directly says, "Remember, I like concise replies," the confirmation method is explicit command confirmation. If the system infers this preference from the user's repeated emphasis on conciseness and requests confirmation from the user, receiving an affirmative response, it is either implicit inference confirmation or confirmation after system prompt. These two methods will be assigned different weights in the subsequent assessment of authorization strength.
[0040] As an optional implementation, the memory state flows between the candidate state, the verified state, the archived state, and the revocation state according to a preset path, the preset path including: After confirmation, the candidate state is transitioned to the verified state. The verified state is migrated to the archived state via the archive command; The verified state is transferred to the revoked state via the revocation command; The archived state is transferred to the revoked state via the revocation command; The revocation state is the final state, and transitioning to other states is prohibited.
[0041] Based on the same inventive concept Figure 2 This is a schematic block diagram illustrating an evidence-based intelligent agent personal memory management system, as shown in an exemplary embodiment. Figure 2 As shown, the system 200 includes: The memory extraction and evidence binding module 201 is used to extract candidate memories from the dialogue between the user and the intelligent agent, and bind an evidence tag to each candidate memory; wherein, the evidence tag includes at least the memory source and memory permission; The comprehensive scoring calculation module 202 is used to determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory based on the evidence tags; and to calculate the comprehensive score of the candidate memory based on the evidence completeness, the memory conflict penalty, and the user authorization strength. The memory storage processing module 203 is used to confirm the memory status of the candidate memory from the candidate state to the verified state and write it into the memory bank if the comprehensive score reaches a preset score threshold and the candidate memory passes the conflict detection; wherein, the memory status includes at least the candidate state, the verified state, the archived state, and the revocation state, and the revocation state indicates that it has been marked as invalid and the content referencing the memory has been notified that it is invalid; the memory bank is an append-only snapshot storage; The intelligent agent dialogue module 204 is used to generate a context projection based on real-time dialogue questions between the user and the intelligent agent, as well as verified memories in the memory bank; and to assist the intelligent agent in generating answers based on the context projection.
[0042] This invention binds memory sources and permissions through evidence tags, coupled with append-only snapshot storage, ensuring that each memory is verifiable and fully traceable, thus solving the problem of unexplainable memories. By using evidence tags to drive quantitative evaluation of evidence completeness, conflict penalties, and authorization strength, and employing comprehensive scoring and conflict detection as entry thresholds, candidate memories are only confirmed as verified and written into the memory bank after meeting these criteria, preventing temporary inferences from being silently solidified and solving the problem of unverifiable memories. Furthermore, by setting up a four-state machine including a revocation state, memories can be precisely rolled back when replaced or revoked. The revocation state is explicitly limited to notifying the referenced content of invalidity, ensuring that revoked memories do not pollute the generated context projections and historical replies, thus solving the problem of memories continuing to affect downstream content after revocation. Together, these features achieve trusted governance of the entire lifecycle of intelligent proxy memories.
[0043] As an optional implementation, the system may also include a memory state management module, which can be used for: In response to a user's command to revoke a target memory, the memory state of the target memory is switched to the revoke state; wherein the memory state of the target memory is either the verified state or the archived state; Retrieve all downstream products that reference the target memory, wherein the downstream products include at least the generated context projection and the generated response content; An invalidation notification is sent to the retrieved downstream product to block the continued reference of the target memory in the downstream product.
[0044] As an optional implementation, the conflict detection includes: performing at least one of the following on the candidate memory and the verified memory in the memory bank: fact conflict detection, preference conflict detection, range conflict detection, and time conflict detection; The fact conflict detection is used to determine whether the candidate memory and the verified memory have opposite conclusions on the same factual content; The preference conflict detection is used to determine whether the candidate memory and the verified memory are inconsistent in terms of user preference settings; The range conflict detection is used to determine whether the conclusions of the candidate memory and the verified memory differ when their applicable ranges overlap. The time conflict detection is used to determine whether there is any overlap or contradiction between the candidate memory and the verified memory in the time dimension.
[0045] As an optional implementation, the user authorization strength includes memory permission levels and sensitivity levels; and the comprehensive scoring calculation module 202 can specifically be used for: Based on the extraction quality of the candidate memory, an extraction quality penalty is determined; wherein, the lower the extraction quality, the greater the extraction quality penalty. The memory permission penalty is determined based on the memory permission level, and the sensitivity penalty is determined based on the sensitivity level; wherein, the higher the memory permission level, the smaller the memory permission penalty; and the higher the sensitivity level, the larger the sensitivity penalty. Based on the completeness of the evidence, a penalty for the completeness of the evidence is determined; wherein, the higher the completeness of the evidence, the smaller the penalty for the completeness of the evidence. Based on the sensitivity penalty, the memory access penalty, the evidence completeness penalty, the memory conflict penalty, and the extraction quality penalty, the comprehensive score of the candidate memory is calculated according to the following formula: =1 in, The overall score is as follows. For the aforementioned sensitivity penalty, Penalty for the completeness of the evidence. The memory permission penalty, The penalty for the aforementioned memory conflict, The extraction quality penalty is applied.
[0046] As an optional implementation, the intelligent agent dialogue module 204 can specifically be used for: Based on the task scope of the real-time dialogue question, determine the memory scope that needs to be invoked; Filter out candidate verified memories that match the memory range and have valid authorization from the memory bank; Calculate the task injection score for each of the selected candidate verified memories; Based on the task injection score, the target verified memory is determined from each of the candidate verified memories; The context projection is generated based on the verified memory of the target.
[0047] As an optional implementation, the calculation of the task injection score for each candidate verified memory selected includes: The task injection score for each candidate verified memory selected is calculated based on the following formula: = in, Inject a score into the task. The overall score is as follows. The correlation between the candidate verified memories and the real-time dialogue question. As a time-sensitive factor, The expiration penalty is defined by α, β, γ, and λ as weighting coefficients. The more recent the generation time of the candidate verified memory, the higher the expiration factor. The expiration penalty is a penalty value imposed on memories that have exceeded the preset validity period. The longer the time exceeds the preset validity period, the greater the penalty value.
[0048] As an optional implementation, the memory storage processing module 203 can also be used for: In response to each write or state change operation of the memory bank, generate the difference data of the current change; The difference data is appended to the end of the snapshot chain to preserve historical snapshots from being overwritten; and the snapshot chain supports tracing back the historical state of any memory in the memory bank in chronological order.
[0049] As an optional implementation, the evidence label further includes at least one of the following: Scope of application is used to limit the types of tasks or project range to which the candidate memory applies; A timestamp is used to record the time when the candidate memory was generated; The confirmation method is used to record how the user confirms the candidate memory. The confirmation method includes explicit command confirmation, implicit inference confirmation, or confirmation after system prompt.
[0050] As an optional implementation, the memory state flows between the candidate state, the verified state, the archived state, and the revocation state according to a preset path, the preset path including: After confirmation, the candidate state is transitioned to the verified state. The verified state is migrated to the archived state via the archive command; The verified state is transferred to the revoked state via the revocation command; The archived state is transferred to the revoked state via the revocation command; The revocation state is the final state, and transitioning to other states is prohibited.
[0051] The implementation methods and beneficial effects of each module in this embodiment can be found in the description of the corresponding method steps in the above embodiments, and will not be repeated in this embodiment.
[0052] Based on the same inventive concept Figure 3 This is a schematic diagram of the internal control circuit of an electronic device capable of executing an evidence-based intelligent agent personal memory management method, according to an exemplary embodiment. Figure 3 As shown, it includes: At least one processor 301, a communication interface 302; and a memory 303 communicatively connected to the at least one processor 301; The processor 301, communication interface 302, and memory 303 communicate with each other via communication bus 304; the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the above-described method.
[0053] A non-transitory computer-readable storage medium storing computer instructions is shown according to an exemplary embodiment, characterized in that the computer instructions are used to cause a computer to perform the above-described method.
[0054] The computer-readable storage media disclosed in this embodiment include, but are not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatuses, or devices, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: electrical connections having 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 fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this invention, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.
[0055] It is understood that the same or similar parts in the above embodiments can be referred to each other, and the contents not described in detail in some embodiments can be referred to the same or similar contents in other embodiments.
[0056] It should be noted that in the description of this invention, the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Herein, in the description of this invention, unless otherwise stated, "a plurality of" means at least two.
[0057] Any process or method description in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process, and the scope of preferred embodiments of the invention includes implementations thereof in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as will be understood by those skilled in the art to which embodiments of the invention pertain.
[0058] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0059] Those skilled in the art will understand that all or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, the program includes one or a combination of the steps of the method embodiments.
[0060] In this invention, the functional units in various embodiments can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium.
[0061] The storage media mentioned above can be read-only memory, disk, or optical disk, etc.
[0062] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0063] Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of the present invention.
Claims
1. A method for managing personal memories using intelligent agents based on evidence binding, characterized in that, include: Candidate memories are extracted from the dialogue between the user and the intelligent agent, and each candidate memory is bound to an evidence tag; wherein, the evidence tag includes at least the memory source and memory permissions; Based on the evidence tags, determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory; Based on the completeness of the evidence, the penalty for memory conflict, and the strength of user authorization, a comprehensive score is calculated for the candidate memory; If the overall score reaches a preset score threshold and the candidate memory passes conflict detection, the memory status of the candidate memory is confirmed from the candidate status to the verified status and written into the memory bank; wherein, the memory status includes at least the candidate status, the verified status, the archived status, and the revocation status, the revocation status indicating that it has been marked as invalid and the content referencing the memory has been notified that it is invalid; the memory bank is an append-only snapshot storage; A context projection is generated based on the real-time dialogue questions between the user and the intelligent agent, as well as the verified memories in the memory bank. Based on the context projection, the intelligent agent is assisted in generating an answer.
2. The method according to claim 1, characterized in that, The method further includes: In response to a user's command to revoke a target memory, the memory state of the target memory is switched to the revoke state; wherein the memory state of the target memory is either the verified state or the archived state; Retrieve all downstream products that reference the target memory, wherein the downstream products include at least the generated context projection and the generated response content; An invalidation notification is sent to the retrieved downstream product to block the continued reference of the target memory in the downstream product.
3. The method according to claim 1, characterized in that, The conflict detection includes: performing at least one of the following methods on the candidate memory and the verified memory in the memory bank: fact conflict detection, preference conflict detection, range conflict detection, and time conflict detection; The fact conflict detection is used to determine whether the candidate memory and the verified memory have opposite conclusions on the same factual content; The preference conflict detection is used to determine whether the candidate memory and the verified memory are inconsistent in terms of user preference settings; The range conflict detection is used to determine whether the conclusions of the candidate memory and the verified memory differ when their applicable ranges overlap. The time conflict detection is used to determine whether there is any overlap or contradiction between the candidate memory and the verified memory in the time dimension.
4. The method according to claim 1, characterized in that, The user authorization strength includes memory permission levels and sensitivity levels; Furthermore, based on the completeness of the evidence, the memory conflict penalty, and the strength of user authorization, a comprehensive score is calculated for the candidate memory, including: Based on the extraction quality of the candidate memory, an extraction quality penalty is determined; wherein, the lower the extraction quality, the greater the extraction quality penalty. The memory permission penalty is determined based on the memory permission level, and the sensitivity penalty is determined based on the sensitivity level; wherein, the higher the memory permission level, the smaller the memory permission penalty; and the higher the sensitivity level, the larger the sensitivity penalty. Based on the completeness of the evidence, a penalty for the completeness of the evidence is determined; wherein, the higher the completeness of the evidence, the smaller the penalty for the completeness of the evidence. Based on the sensitivity penalty, the memory access penalty, the evidence completeness penalty, the memory conflict penalty, and the extraction quality penalty, the comprehensive score of the candidate memory is calculated according to the following formula: =1 in, The overall score is as follows. For the aforementioned sensitivity penalty, Penalty for the completeness of the evidence. The memory permission penalty, The penalty for the aforementioned memory conflict, The extraction quality penalty is applied.
5. The method according to claim 4, characterized in that, Based on real-time dialogue questions between the user and the intelligent agent, and verified memories in the memory bank, a context projection is generated, including: Based on the task scope of the real-time dialogue question, determine the memory scope that needs to be invoked; Filter out candidate verified memories that match the memory range and have valid authorization from the memory bank; Calculate the task injection score for each of the selected candidate verified memories; Based on the task injection score, the target verified memory is determined from each of the candidate verified memories; The context projection is generated based on the verified memory of the target.
6. The method according to claim 5, characterized in that, The calculated task injection scores for each candidate verified memory selected include: The task injection score for each candidate verified memory selected is calculated based on the following formula: = in, Inject a score into the task. The overall score is as follows. The correlation between the candidate verified memories and the real-time dialogue question. As a time-sensitive factor, As a penalty for overdue payment, α , β , γ , λ The weighting coefficient is denoted as ; wherein, the more recent the generation time of the candidate verified memory, the higher the time factor, and the expiration penalty is the penalty value imposed on the memory that exceeds the preset validity period, and the longer the time exceeds the preset validity period, the greater the penalty value.
7. The method according to claim 1, characterized in that, The method further includes: In response to each write or state change operation of the memory bank, generate the difference data of the current change; The difference data is appended to the end of the snapshot chain to preserve historical snapshots from being overwritten; and the snapshot chain supports tracing back the historical state of any memory in the memory bank in chronological order.
8. The method according to claim 1, characterized in that, The evidence label also includes at least one of the following: Scope of application is used to limit the types of tasks or project range to which the candidate memory applies; A timestamp is used to record the time when the candidate memory was generated; The confirmation method is used to record how the user confirms the candidate memory. The confirmation method includes explicit command confirmation, implicit inference confirmation, or confirmation after system prompt.
9. The method according to claim 1, characterized in that, The memory state flows between the candidate state, the verified state, the archived state, and the revocation state according to a preset path, the preset path including: After confirmation, the candidate state is transitioned to the verified state. The verified state is migrated to the archived state via the archive command; The verified state is transferred to the revoked state via the revocation command; The archived state is transferred to the revoked state via the revocation command; The revocation state is the final state, and transitioning to other states is prohibited.
10. A smart agent personal memory management system based on evidence binding, characterized in that, include: The memory extraction and evidence binding module is used to extract candidate memories from the dialogue between the user and the intelligent agent, and bind evidence tags to each candidate memory; wherein, the evidence tags include at least the memory source and memory permissions; The comprehensive scoring calculation module is used to determine the evidence completeness, memory conflict penalty, and user authorization strength of the candidate memory based on the evidence tags; and to calculate the comprehensive score of the candidate memory based on the evidence completeness, the memory conflict penalty, and the user authorization strength. The memory storage processing module is used to confirm the memory status of the candidate memory from the candidate state to the verified state and write it into the memory bank if the comprehensive score reaches a preset score threshold and the candidate memory passes the conflict detection; wherein, the memory status includes at least the candidate state, the verified state, the archived state, and the revocation state, and the revocation state indicates that it has been marked as invalid and the content referencing the memory has been notified of invalidity; the memory bank is an append-only snapshot storage; The intelligent agent dialogue module is used to generate a context projection based on real-time dialogue questions between the user and the intelligent agent, as well as verified memories in the memory bank; and to assist the intelligent agent in generating answers based on the context projection.
