This commit is contained in:
Timothy Jaeryang Baek
2026-06-29 21:31:49 -05:00
parent 651a02ed2f
commit 4067e357b2
5 changed files with 18 additions and 1 deletions
+2
View File
@@ -394,6 +394,7 @@ CODE_EXECUTION_JUPYTER_TIMEOUT = int(os.getenv('CODE_EXECUTION_JUPYTER_TIMEOUT',
ENABLE_CODE_INTERPRETER = os.getenv('ENABLE_CODE_INTERPRETER', 'True').lower() == 'true'
ENABLE_MEMORIES = os.getenv('ENABLE_MEMORIES', 'True').lower() == 'true'
ENABLE_MEMORY_SYSTEM_CONTEXT = os.getenv('ENABLE_MEMORY_SYSTEM_CONTEXT', 'True').lower() == 'true'
ENABLE_MEMORY_BACKGROUND_REVIEW = os.getenv('ENABLE_MEMORY_BACKGROUND_REVIEW', 'False').lower() == 'true'
MEMORIES_REVIEW_INTERVAL_TURNS = int(os.getenv('MEMORIES_REVIEW_INTERVAL_TURNS', '10'))
MEMORIES_USER_CHAR_LIMIT = int(os.getenv('MEMORIES_USER_CHAR_LIMIT', '2000'))
@@ -2741,6 +2742,7 @@ DEFAULT_CONFIG = {
'code_execution.jupyter.timeout': CODE_EXECUTION_JUPYTER_TIMEOUT,
'code_interpreter.enable': ENABLE_CODE_INTERPRETER,
'memories.enable': ENABLE_MEMORIES,
'memories.system_context.enable': ENABLE_MEMORY_SYSTEM_CONTEXT,
'memories.background_review.enable': ENABLE_MEMORY_BACKGROUND_REVIEW,
'memories.review_interval_turns': MEMORIES_REVIEW_INTERVAL_TURNS,
'memories.user_char_limit': MEMORIES_USER_CHAR_LIMIT,
+2
View File
@@ -105,6 +105,7 @@ ADMIN_CONFIG_KEYS = {
'ENABLE_CHANNELS': 'channels.enable',
'ENABLE_CALENDAR': 'calendar.enable',
'ENABLE_MEMORIES': 'memories.enable',
'ENABLE_MEMORY_SYSTEM_CONTEXT': 'memories.system_context.enable',
'ENABLE_NOTES': 'notes.enable',
'ENABLE_USER_WEBHOOKS': 'ui.enable_user_webhooks',
'ENABLE_USER_STATUS': 'users.enable_status',
@@ -1142,6 +1143,7 @@ class AdminConfig(BaseModel):
ENABLE_CHANNELS: bool
ENABLE_CALENDAR: bool
ENABLE_MEMORIES: bool
ENABLE_MEMORY_SYSTEM_CONTEXT: bool
ENABLE_NOTES: bool
ENABLE_USER_WEBHOOKS: bool
ENABLE_USER_STATUS: bool
+1 -1
View File
@@ -2427,7 +2427,7 @@ async def process_chat_payload(request, form_data, user, metadata, model):
form_data['messages'],
)
if 'memory' in features and features['memory']:
if 'memory' in features and features['memory'] and await Config.get('memories.system_context.enable'):
form_data = await add_memory_context(request, form_data, user, model)
if 'web_search' in features and features['web_search']: