GitHub user coderplay added a comment to the discussion: Short-Term Memory 
Design

A few more questions:

1. This design uses whether the memory is keyed as the criterion to distinguish 
short-term vs. long-term memory, but this is confusing. Even keyed state in 
Flink is permanently persisted.

2.  Short-term memory is mainly used to synthesize context for LLM models, and 
this context is typically in natural language format. Thus, the most common 
memory types are str, list[str]. Supporting deeply nested object memory 
structures feels like over-engineering, right?

3. Why does memory have to be stored as MapState? When Flink stores MapState in 
StateBackends, it uses a three-level hierarchy:
  * The input stream key, which defines task parallelism.
  * The MapStateDescriptor name, which defines the map state's name.
  * The key within the MapState.
Using the StateDescriptor name alone should be sufficient to distinguish 
different memory entries, correct? Additionally, ListStateDescriptor can 
directly support list-type state.

GitHub link: 
https://github.com/apache/flink-agents/discussions/40#discussioncomment-13726836

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: [email protected]

Reply via email to