* fix(memory): keep sample import backups unique per run * docs(memory): clarify backup retention and align script format --------- Co-authored-by: Kiko0301 <191240073+Kiko0301@users.noreply.github.com>
3.2 KiB
Memory Settings Review
Use this when reviewing the Memory Settings add/edit flow locally with the fewest possible manual steps.
Quick Review
-
Start DeerFlow locally using any working development setup you already use.
Examples:
make devor
make docker-startIf you already have DeerFlow running locally, you can reuse that existing setup.
-
Open
Settings > Memory.Default local URLs:
- App:
http://localhost:2026 - Local frontend-only fallback:
http://localhost:3000
- App:
-
Click Import memory and select:
backend/docs/memory-settings-sample.jsonThe browser imports the fixture into the currently signed-in user's memory.
Bulk Local Review
To replace memory for every registered user in a disposable review environment:
cd backend
uv run python ../scripts/load_memory_sample.py --all-users
This command:
- supports SQLite and PostgreSQL registered-user databases;
- creates a unique timestamped backup directory under
.deer-flow/memory-sample-backups/before replacing memory, even when imports start in the same second; - imports through the configured memory storage provider; and
- rejects
database.backend: memory, which has no persistent user registry.
Bulk loading replaces every registered user's memory. Do not run it against an environment containing memory you need to preserve. Backups accumulate until removed manually. On POSIX, each new backup directory is private to the creating OS user (mode 0700); restoring as another user may require adjusting permissions. Pass --no-backup only when losing the existing memory is acceptable.
Minimal Manual Test
- Click
Add fact. - Create a new fact with:
- Content:
Reviewer-added memory fact - Category:
testing - Confidence:
0.88
- Content:
- Confirm the new fact appears immediately and shows
Manualas the source. - Edit the sample fact
This sample fact is intended for edit testing.and change it to:- Content:
This sample fact was edited during manual review. - Category:
testing - Confidence:
0.91
- Content:
- Confirm the edited fact updates immediately.
- Refresh the page and confirm both the newly added fact and the edited fact still persist.
Optional Sanity Checks
- Search
Reviewer-addedand confirm the new fact is matched. - Search
workflowand confirm category text is searchable. - Switch between
All,Facts, andSummaries. - Delete the disposable sample fact
Delete fact testing can target this disposable sample entry.and confirm the list updates immediately. - Clear all memory and confirm the page enters the empty state.
Fixture Files
- Sample fixture:
backend/docs/memory-settings-sample.json - Per-user file-storage target:
backend/.deer-flow/users/{user_id}/memory.json - Bulk backups:
backend/.deer-flow/memory-sample-backups/{timestamp}-{unique-suffix}/{user_id}.json
For an explicit one-file copy, pass --target PATH to the loader. Its sidecar backup is {target.name}.bak-{timestamp}-{unique-suffix} beside the target; repeated imports never reuse a backup path. There is no implicit target because authenticated sessions use different per-user paths.