mirror of
https://github.com/sudoxreboot/groqd
synced 2026-04-14 11:36:49 +00:00
Use user/global fallback for device memory
This commit is contained in:
parent
a849a21c75
commit
dd0407410f
1 changed files with 0 additions and 4 deletions
|
|
@ -264,8 +264,6 @@ class GroqdConversationEntity(
|
||||||
if memory_scope == "device":
|
if memory_scope == "device":
|
||||||
if user_input.device_id:
|
if user_input.device_id:
|
||||||
memory_key = f"device:{user_input.device_id}"
|
memory_key = f"device:{user_input.device_id}"
|
||||||
elif user_input.conversation_id:
|
|
||||||
memory_key = f"conv:{user_input.conversation_id}"
|
|
||||||
elif user_input.context and user_input.context.user_id:
|
elif user_input.context and user_input.context.user_id:
|
||||||
memory_key = f"user:{user_input.context.user_id}"
|
memory_key = f"user:{user_input.context.user_id}"
|
||||||
else:
|
else:
|
||||||
|
|
@ -273,8 +271,6 @@ class GroqdConversationEntity(
|
||||||
elif memory_scope == "user":
|
elif memory_scope == "user":
|
||||||
if user_input.context and user_input.context.user_id:
|
if user_input.context and user_input.context.user_id:
|
||||||
memory_key = f"user:{user_input.context.user_id}"
|
memory_key = f"user:{user_input.context.user_id}"
|
||||||
elif user_input.conversation_id:
|
|
||||||
memory_key = f"conv:{user_input.conversation_id}"
|
|
||||||
else:
|
else:
|
||||||
memory_key = "global"
|
memory_key = "global"
|
||||||
elif memory_scope == "global":
|
elif memory_scope == "global":
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue