You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/memory_creator.rs
+11-50Lines changed: 11 additions & 50 deletions
Original file line number
Diff line number
Diff line change
@@ -7,12 +7,8 @@ use r2d2_sqlite::SqliteConnectionManager;
7
7
use serde::{Deserialize,Serialize};
8
8
use serde_rusqlite::from_row;
9
9
use std::{collections::HashMap, sync::Arc};
10
-
use wb_sqlite::InsertSync;
11
10
12
-
usecrate::{
13
-
config::Config,
14
-
database::{Memory,User},
15
-
};
11
+
usecrate::{config::Config, database::User};
16
12
17
13
/// JSON response structure for memory creation
18
14
#[derive(Debug,Serialize,Deserialize)]
@@ -58,45 +54,21 @@ Respond ONLY with valid JSON in this exact format:
58
54
IMPORTANT GUIDELINES:
59
55
- Only create memories if there's meaningful information from THIS conversation
60
56
- Each user should have AT MOST ONE memory entry per unique "key" category
61
-
- The "key" should be a broad category like "preferences", "hobbies", "work", "personality", "relationships", "recent_activity"
57
+
- The "key" should be a broad category like "preferences", "hobbies", "work", "personality", "relationships", "recent_activity" but can be anything like outside_hobbies could work too
62
58
- The "content" should combine ALL related facts for that category into ONE comprehensive entry
63
59
- Use exact usernames as they appear in the conversation
64
60
- If there's nothing meaningful to remember, return an empty memories array
65
61
66
-
EXAMPLE - CORRECT (combining multiple facts under one key):
0 commit comments