fix(app): memory config initialization for end users
- Add memory_config_id extraction and assignment when creating new end users in public share chat - Introduce get_or_create_end_user_with_config method to handle memory config setup in single transaction - Add batch_update_memory_config_id_by_app method for bulk updating end user memory configs - Rename _update_endusers_memory_config_by_workspace to _update_endusers_memory_config_by_app for correct scope - Update app publish flow to use app_id instead of workspace_id for memory config updates - Remove unused actual_end_user_id variable in langchain_agent - Ensures end users are properly associated with memory configs on creation and during app updates
This commit is contained in:
@@ -329,7 +329,6 @@ class LangChainAgent:
|
||||
db.close()
|
||||
except Exception as e:
|
||||
logger.warning(f"Failed to get db session: {e}")
|
||||
actual_end_user_id = end_user_id if end_user_id is not None else "unknown"
|
||||
logger.info(f'写入类型{storage_type, str(end_user_id), message, str(user_rag_memory_id)}')
|
||||
print(f'写入类型{storage_type, str(end_user_id), message, str(user_rag_memory_id)}')
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user