What is Memory?
Memory is Ziet’s built-in durable storage system that persists data across actions, agent steps, and even failures. It provides:- Durable storage - Data persists even if agent steps fail
- Key-value storage - Store and retrieve by unique keys
- Semantic search - Find data by meaning, not just exact matches
- Metadata filtering - Tag and filter entries
- Automatic scoping - Data is isolated per run by default
- Cross-agent sharing - Agents can hand off and share memory
Core Operations
add()
Store data in memory:Semantic label for easy retrieval. Always provide a descriptive key.
Any JSON-serializable data (dict, list, str, int, bool, etc.)
Additional tags for filtering and organization.
entry_id (string) - Unique identifier for the stored entry
Example:
get()
Retrieve the most recent value for a key:The key to retrieve
None if key doesn’t exist
Example:
search()
Semantic or filtered search across all memories:Natural language or keyword query. Searches across both values and keys.
Filter by metadata fields
Maximum number of results to return
remove()
Delete entries by entry_id or key:Specific entry to remove
Remove all entries with this key
Usage Patterns
Share Data Between Actions
Store data in one action, retrieve in another:Store Intermediate Results
Actions automatically store progress in memory:Semantic Search for Context
Find relevant information from past actions:Metadata for Organization
Tag and filter entries:Clean Up Temporary Data
Remove data you don’t need anymore:Deduplication
Avoid processing the same data twice:Memory Durability & Agent Handoffs
Durable Across Failures
Memory persists even when agent steps fail:Shared Across Agent Handoffs
When agents hand off to each other, memory is preserved and shared:Best Practices
Use descriptive keys
Use descriptive keys
Make keys self-documenting✅ Good❌ Bad
Add metadata for filtering
Add metadata for filtering
Tag entries for easy retrieval and organization
Clean up temporary data
Clean up temporary data
Remove data you don’t need to keep
Avoid storing large objects
Avoid storing large objects
Keep memory entries reasonably sized✅ Good: Store summaries or references❌ Bad: Store entire large objects
Use semantic search effectively
Use semantic search effectively
Write natural queries for better results✅ Good: Natural language❌ Bad: Single keywords (use exact key instead)
Limitations
Current limitations:
- Max entry size: 6MB per entry
- Max entries per run: 10,000 entries
- Retention: Data retained for 30 days after run completion
- Search results: Limited to 100 results per query
- Cross-run memory: Not yet available (coming soon)