Skip to content

[ Feature Request ]: Event-Driven Memory (Selective Storage of Meaningful Messages) #3

@sobowalebukola

Description

@sobowalebukola

Currently, the memory layer stores data more uniformly, which can lead to noisy context and unnecessary persistence of low-value interactions. This feature proposes an event-driven memory pipeline that selectively persists only “meaningful” user events (e.g., goals, preferences, commitments, corrections, achievements) based on heuristic or model-based signals.

Motivation

  • Reduces memory bloat and storage overhead

  • Keeps user memory more relevant, concise, and high-value

  • Improves personalization without degrading context with trivial chats

  • Aligns with real-world memory patterns (event-based rather than every utterance)

Proposed Behaviour

The system should:

  • Process each message through an event classifier

  • Decide whether it should be saved, discarded, or summarized

  • Optionally create state updates (overwrite old info instead of accumulating)

Examples of “meaningful events”:

User expresses long-term preference (“I prefer dark mode”)

User sets a goal (“Remind me to study Rust this month”)

User corrects facts (“My role is actually backend engineer”)

User shares achievements or milestones

User updates personal profile info

Technical Notes / Implementation Ideas

  • Implement a lightweight classifier (rules + LLM or embedding similarity)

  • Add memory entry metadata (weight, type, expiry, source)

  • Store only high-weight events

  • Consider TTL for certain memory types

  • Add hooks so devs can customize “event” categories

Potential Challenges

  • Defining the signal for “meaningful”

  • Updating existing stored knowledge without duplicating

  • Balancing privacy with persistence

  • Preventing accidental storage of highly personal or sensitive info

Acceptance Criteria

  • Low-value messages are not stored by default

  • Significant user info persists reliably across sessions

  • Memory size growth slows or stabilises

Additional Context

This feature aligns with feedback around improving personalization while avoiding “creepy” over-storage, as well as better mirroring human memory patterns.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions