What’s New in V2
Provider-Based Architecture
V2 introduces a flexible provider-based system for vector and graph storage, giving you the freedom to choose and switch between different backends:- Vector Providers: pgvector (more coming soon)
- Graph Providers: Neo4j (more coming soon)
Massive Performance Improvements
By migrating embeddings to pgvector, we’ve achieved significant performance gains:- Query Response Time: Reduced from ~26 seconds to ~1 second
- 26x faster embedding retrieval for memory operations
- Improved overall system responsiveness
Migration Steps
Warning: This migration process involves database operations that will temporarily take your CORE instance offline. Make sure to plan accordingly and inform your users if applicable.
Prerequisites
- Docker installed and running
- Access to your CORE instance
- Sufficient disk space for database dump
Step 1: Backup Your Database
First, create a complete backup of your existing database:Step 2: Remove Old PostgreSQL Volume
Stop the PostgreSQL container:
Note: If you’re using a different volume name, you can list all volumes with docker volume ls to find the correct one.
Step 3: Update Configuration Files
Pull the latestdocker-compose.yaml from the repository or update your existing file to include the new PostgreSQL 18 with pgvector support.
Add the following environment variables to your .env file:
Step 4: Start PostgreSQL Container
Start the PostgreSQL container with the new configuration:docker logs core-postgres).
Step 5: Restore Database
Drop the existing database (if it exists) and create a fresh one:Step 6: Start CORE Application
Start all CORE services:Step 7: Automatic Embedding Migration
When CORE starts for the first time after the migration, it will automatically:- Detect embeddings stored in Neo4j
- Migrate them to pgvector for each user
- Update all references to use the new vector storage
Rollback
If you encounter issues, you can rollback by:- Stopping all containers:
docker-compose down - Restoring the old volume or reverting configuration changes
- Using your
database_dump.sqlbackup to restore the previous state
Troubleshooting
Migration Takes Too Long
The embedding migration time depends on the amount of data stored. For large datasets, this process may take several minutes. Monitor the logs to ensure progress is being made.Connection Errors
If you encounter connection errors after migration:- Verify PostgreSQL is running:
docker ps | grep postgres - Check PostgreSQL logs:
docker logs core-postgres - Ensure environment variables are correctly set in
.env
Support
If you encounter issues during migration:- Check the GitHub Issues for similar problems
- Join our community discussions
