knowledge_set_retention
Set an automatic data retention policy for project memory. Sessions older than the specified TTL days are automatically archived, with a minimum of 7 days when enabled.
Instructions
Set an automatic data retention policy (TTL) for a project's memory. Entries older than ttl_days will be soft-deleted (archived) automatically on every server startup and every 12 hours while running.
Use cases:
Set
ttl_days: 90to auto-expire sessions older than 3 monthsSet
ttl_days: 0to disable auto-expiry (default)
Note: Rollup/compaction entries are never expired — only raw sessions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project | Yes | Project to set retention policy for. | |
| ttl_days | Yes | Entries older than this many days are auto-expired. Set to 0 to disable. Minimum: 7 days when enabled. |