Introduction
The Unified Memory System is a core component of Vibing AI that provides persistent storage and cross-application context awareness. It enables applications to share information while maintaining strict privacy controls and purpose-bound permissions.Overview
The Unified Memory System serves as the central knowledge repository for the Vibing AI platform, enabling:- Continuous context across multiple conversations and applications
- Semantic search and retrieval based on meaning, not just keywords
- Structured data with schema validation for type safety
- Permission-controlled access with purpose binding and time limits
- Historical versioning for auditing and recovery
Memory Architecture
The memory system is organized hierarchically with different scopes designed for specific use cases:Global Memory
Persistent across all contexts and available platform-wide:- User profile and preferences
- Long-term knowledge and history
- Cross-project information
memory:read:global;purpose=user_preferences;ttl=session
Workspace Memory
Shared across a collection of projects within a workspace:- Workspace configuration
- Team members and access rights
- High-level objectives and resources
memory:write:workspace:{id};purpose=team_collaboration;ttl=30d
Project Memory
Associated with a specific project context:- Project-specific content and assets
- Project history and versions
- Specialized knowledge for the project domain
memory:read:project:{id};purpose=content_generation;ttl=1h
Session Memory
Limited to the current interaction session:- Short-term conversation context
- Temporary data and calculations
- Ephemeral states
memory:read:session;purpose=conversation_context;ttl=30m
Private Memory
Isolated to a specific offering with no cross-application sharing:- Offering-specific data
- User settings for the offering
- Processing history
memory:write:private:{offering_id};purpose=feature_personalization;ttl=90d
Key Features
Vectorized Memory
Content is stored with semantic embeddings that enable retrieval based on meaning rather than exact matching:Structured Records
Typed data storage with schema validation ensures data integrity:Permission System
Granular access controls ensure data is only accessed with appropriate permissions:Temporal Management
Historical versioning and time-based constraints protect data integrity:Notification System
Event-based triggers for memory changes enable reactive behavior:Using the Unified Memory System
Basic Operations
Advanced Queries
Memory Hooks (React)
Best Practices
1. Use Appropriate Scopes
Choose the most appropriate memory scope for your data. Don’t store data in global memory if it only belongs to a specific project or session.2. Clear Purpose Declarations
Always specify a clear, accurate purpose when requesting memory permissions. This helps users understand why data access is needed.3. Minimal TTL Durations
Request the shortest time-to-live (TTL) duration necessary for your use case. This enhances security and privacy.4. Structured Data
Use schemas for structured data to ensure type safety and consistency.5. Memory Cleanup
Clean up temporary data when it’s no longer needed to prevent memory bloat.Security Considerations
The Unified Memory System implements several security measures:- Encryption: All memory data is encrypted at rest and in transit
- Permission Enforcement: Strict permission checking before any memory access
- Audit Logging: Comprehensive logs of all memory operations
- Data Isolation: Clear boundaries between different memory scopes
- Automatic Expiration: Time-limited permissions with automatic revocation
Next Steps
- Learn about Permission Model for securing memory access
- Explore Vibing Super Agent integration with memory
- Understand Interface Surfaces for presenting memory data
- Review the Memory API Reference for detailed method specifications