Add prefetch settings as environment variables for installation prompts #3
+6
-2
@@ -6,6 +6,8 @@ Config via environment variables:
|
|||||||
MEM0_BASE_URL — Local Mem0 server URL (required, e.g., http://localhost:8000)
|
MEM0_BASE_URL — Local Mem0 server URL (required, e.g., http://localhost:8000)
|
||||||
MEM0_USER_ID — User identifier for memory scoping (default: hermes-user)
|
MEM0_USER_ID — User identifier for memory scoping (default: hermes-user)
|
||||||
MEM0_AGENT_ID — Agent identifier (default: hermes)
|
MEM0_AGENT_ID — Agent identifier (default: hermes)
|
||||||
|
MEM0_PREFETCH_LIMIT — Max memories to prefetch (default: 3)
|
||||||
|
MEM0_PREFETCH_SCORE_THRESHOLD — Min similarity score % to include memory (default: 60)
|
||||||
|
|
||||||
Or via $HERMES_HOME/mem0-local.json.
|
Or via $HERMES_HOME/mem0-local.json.
|
||||||
"""
|
"""
|
||||||
@@ -46,8 +48,10 @@ def _load_config() -> dict:
|
|||||||
"agent_id": os.environ.get("MEM0_AGENT_ID", "hermes"),
|
"agent_id": os.environ.get("MEM0_AGENT_ID", "hermes"),
|
||||||
"rerank": True,
|
"rerank": True,
|
||||||
"timeout": 10.0,
|
"timeout": 10.0,
|
||||||
"prefetch_limit": 3,
|
"prefetch_limit": int(os.environ.get("MEM0_PREFETCH_LIMIT", "3")),
|
||||||
"prefetch_score_threshold": 60,
|
"prefetch_score_threshold": int(
|
||||||
|
os.environ.get("MEM0_PREFETCH_SCORE_THRESHOLD", "60")
|
||||||
|
),
|
||||||
}
|
}
|
||||||
|
|
||||||
config_path = get_hermes_home() / "mem0-local.json"
|
config_path = get_hermes_home() / "mem0-local.json"
|
||||||
|
|||||||
@@ -10,6 +10,10 @@ requires_env:
|
|||||||
url: "https://github.com/mem0ai/mem0"
|
url: "https://github.com/mem0ai/mem0"
|
||||||
- name: MEM0_USER_ID
|
- name: MEM0_USER_ID
|
||||||
description: "User identifier for memory scoping (default: hermes-user)"
|
description: "User identifier for memory scoping (default: hermes-user)"
|
||||||
|
- name: MEM0_PREFETCH_LIMIT
|
||||||
|
description: "Max memories to prefetch before LLM call (default: 3)"
|
||||||
|
- name: MEM0_PREFETCH_SCORE_THRESHOLD
|
||||||
|
description: "Min similarity score % to include memory 0-100 (default: 60)"
|
||||||
|
|
||||||
provides_tools:
|
provides_tools:
|
||||||
- mem0_profile
|
- mem0_profile
|
||||||
|
|||||||
Reference in New Issue
Block a user