wenjin272 commented on code in PR #784:
URL: https://github.com/apache/flink-agents/pull/784#discussion_r3370626209


##########
docs/content/docs/development/memory/sensory_and_short_term_memory.md:
##########
@@ -263,4 +266,56 @@ Sensory Memory is automatically cleared by the framework 
after each agent run co
 
 {{< hint info >}}
 During execution, sensory memory data is checkpointed by Flink for fault 
tolerance. However, once the run completes, all sensory memory is cleared and 
will not be available in subsequent runs.
-{{< /hint >}}
\ No newline at end of file
+{{< /hint >}}
+
+### Short-Term Memory
+
+Short-term memory can be configured with a time-to-live (TTL) so that older 
state expires automatically. This is useful for agents that may run for a long 
time: if the agent only needs recent memories, expiring historical data 
directly keeps the stored state focused on the latest context and avoids 
retaining stale information.
+
+Set `short-term-memory.state-ttl.ms` to a value greater than 0 in milliseconds 
to enable TTL. You can also configure how the TTL is refreshed and whether 
expired state can be returned before Flink cleans it up:
+
+- `short-term-memory.state-ttl.update-type`: controls whether TTL is refreshed 
on create/write or on read/write.

Review Comment:
   I believe the literals themselves, along with a single line of additional 
explanation, are sufficient; therefore, I agree with keeping it brief.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to