fix(config): recognize memory nudge interval

This commit is contained in:
MindDragonLabs
2026-08-20 10:52:45 +05:30
committed by kshitij
parent fb96247eaf
commit 5c03fbedc6
3 changed files with 11 additions and 5 deletions
-5
View File
@@ -833,11 +833,6 @@ memory:
# every N user turns. Set to 0 to disable. Only active when memory is enabled.
nudge_interval: 10 # Nudge every 10 user turns (0 = disabled)
# Memory flush: give the agent one turn to save memories before context is
# lost (compression, /new, /reset, exit). Set to 0 to disable.
# For exit/reset, only fires if the session had at least this many user turns.
flush_min_turns: 6 # Min user turns to trigger flush on exit/reset (0 = disabled)
# =============================================================================
# Session Reset Policy (Messaging Platforms)
# =============================================================================
+4
View File
@@ -1865,6 +1865,10 @@ DEFAULT_CONFIG = {
"write_approval": False,
"memory_char_limit": 2200, # ~800 tokens at 2.75 chars/token
"user_char_limit": 1375, # ~500 tokens at 2.75 chars/token
# Periodic built-in memory review. External providers with automatic
# turn/session extraction can set this to 0 and keep the small local
# store reserved for explicit high-frequency operational facts.
"nudge_interval": 10,
# External memory provider plugin (empty = built-in only).
# Set to a provider name to activate: "openviking", "mem0",
# "hindsight", "holographic", "retaindb", "byterover".
@@ -111,6 +111,13 @@ class TestConfigYamlRouting:
assert "not a recognized config key" not in capsys.readouterr().out
assert "script_timeout_seconds: 600" in _read_config(_isolated_hermes_home)
def test_memory_nudge_interval_is_recognized(self, _isolated_hermes_home, capsys):
"""The documented background-memory review interval is runtime config."""
set_config_value("memory.nudge_interval", "0")
assert "not a recognized config key" not in capsys.readouterr().out
assert "nudge_interval: 0" in _read_config(_isolated_hermes_home)
def test_terminal_docker_cwd_mount_flag_goes_to_config_and_env(self, _isolated_hermes_home):
set_config_value("terminal.docker_mount_cwd_to_workspace", "true")
config = _read_config(_isolated_hermes_home)