Documentation Index
Fetch the complete documentation index at: https://mintlify.com/basicmachines-co/basic-memory/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Basic Memory Cloud uses rclone bisync for bidirectional file synchronization between your local filesystem and cloud storage. This enables:- Two-way sync: changes in either location are propagated to the other
- Conflict detection and resolution
- Integrity verification with checksums
- Incremental sync (only changed files)
- Dry-run preview before syncing
Initial Setup
Step 1: Install and Configure rclone
Run the cloud setup wizard to install rclone and configure credentials:- Downloads and installs rclone (if not present)
- Fetches your tenant information from the cloud API
- Generates scoped S3 credentials for sync
- Configures the rclone remote named
basicmemory-cloud
Step 2: Configure Project Sync
Each project needs a local sync path configured:Option A: Create New Project with Sync
Option B: Configure Existing Project
- Verifies the project exists in the cloud
- Creates the local directory if needed
- Updates project configuration with sync path
- Creates the project in local database for MCP access
The local sync path should be a dedicated directory for the project. Don’t use your default Basic Memory directory (
~/basic-memory) unless that’s specifically what you want to sync.Sync Operations
Bidirectional Sync (bisync)
The primary sync operation for two-way synchronization:Command Options
| Option | Description |
|---|---|
--name | Project name to sync (required) |
--resync | Force new baseline (first sync or after conflicts) |
--dry-run | Preview changes without applying them |
--verbose | Show detailed output including file-by-file operations |
First Sync: Resync Required
The first sync for a project requires--resync to establish a baseline:
- rclone scans both local and cloud directories
- Creates a baseline snapshot of all files
- Stores metadata in
~/.cache/basic-memory/bisync/research/ - Synchronizes any differences (usually cloud → local on first sync)
- Marks the project as initialized in config
Incremental Syncs
After the initial resync, subsequent syncs are incremental:- rclone compares current state against baseline
- Identifies changes in both local and cloud
- Propagates changes bidirectionally
- Detects and reports conflicts
- Updates baseline with new state
One-Way Sync (local → cloud)
For scenarios where you want to force the cloud to match local:Integrity Check
Verify file integrity between local and cloud without syncing:Conflict Resolution
Understanding Conflicts
A conflict occurs when the same file is modified in both locations between syncs:Resolving Conflicts
Step 1: Review Changes Check what changed locally and in the cloud before resolving. Step 2: Backup Important Changes If you have important local changes, back them up:Strategy A: Cloud Wins (Download latest)
Strategy B: Local Wins (Upload latest)
Strategy C: Manual Merge
- Manually reconcile conflicting files
- Run resync to establish new baseline:
Preventing Conflicts
- Sync frequently: Run
bisyncregularly on each device - Sync before major changes: Always sync before editing many files
- Use snapshots: Create snapshots before risky operations
- Avoid simultaneous edits: Don’t edit the same files on multiple devices simultaneously
Sync State Management
Bisync State Files
Bisync stores state in~/.cache/basic-memory/bisync/<project>/:
Resetting Bisync State
If bisync gets into an inconsistent state, reset it:--resync on next sync.
When to Reset State
- Persistent conflict errors that won’t resolve
- After manually modifying many files on both sides
- When cloud path changes (different workspace/bucket)
- After restoring from snapshot
Ignore Patterns
.bmignore File
Basic Memory uses.bmignore (gitignore-style syntax) to exclude files from sync:
Location: ~/.basic-memory/.bmignore
Default patterns:
Editing Ignore Patterns
- Edit
~/.basic-memory/.bmignorewith your preferred editor - Add patterns using gitignore syntax:
- The patterns automatically convert to rclone filter format on next sync
The
.bmignore.rclone file is auto-generated from .bmignore. Edit .bmignore, not the .rclone file.Database Synchronization
After file sync completes, Basic Memory triggers a database sync:- Files sync via rclone bisync
- CLI calls cloud API:
POST /api/projects/{id}/sync - Cloud server indexes new/changed files into SQLite database
- Knowledge graph updates with new entities and relations
Database sync happens automatically after successful file sync. You don’t need to trigger it manually.
Sync Workflows
Daily Sync Routine
Multi-Device Workflow
On Device A:Pre-Deployment Sync
Before deploying changes or major edits:Troubleshooting
Sync Fails: rclone Not Found
Sync Fails: Credentials Invalid
Sync Fails: Permission Denied
Sync Fails: Path Not Found
Files Not Syncing
-
Check if files are ignored:
-
Run sync with verbose output:
-
Verify files exist locally:
Persistent Conflicts
If conflicts won’t resolve:Performance Optimization
Large Projects
For projects with many files:- Use ignore patterns to exclude unnecessary files
- Sync regularly for smaller incremental updates
- Enable verbose output only when debugging
- Consider multiple smaller projects instead of one giant project
Network Optimization
- Sync during off-peak hours for large transfers
- Use wired connection for initial resync
- Monitor bandwidth with
--verboseflag
Next Steps
Project Management
Advanced cloud project configuration
Snapshots
Create and restore from snapshots
Authentication
Manage cloud credentials