refactor(honcho): rename recallMode "auto" to "hybrid"

Matches the mental model: hybrid = context + tools,
context = context only, tools = tools only.
This commit is contained in:
Erosika 2026-03-09 17:46:51 -04:00
parent 6782249df9
commit c1228e9a4a
4 changed files with 10 additions and 10 deletions

View file

@ -147,13 +147,13 @@ def cmd_setup(args) -> None:
cfg["writeFrequency"] = new_wf if new_wf in ("async", "turn", "session") else "async"
# Recall mode
current_recall = cfg.get("recallMode", "auto")
current_recall = cfg.get("recallMode", "hybrid")
print(f"\n Recall mode options:")
print(" auto — pre-warmed context + memory tools available (default)")
print(" hybrid — pre-warmed context + memory tools available (default)")
print(" context — pre-warmed context only, memory tools suppressed")
print(" tools — no pre-loaded context, rely on tool calls only")
new_recall = _prompt("Recall mode", default=current_recall)
if new_recall in ("auto", "context", "tools"):
if new_recall in ("hybrid", "context", "tools"):
cfg["recallMode"] = new_recall
# Session strategy

View file

@ -90,10 +90,10 @@ class HonchoClientConfig:
# Max chars of dialectic result to inject into Hermes system prompt
dialectic_max_chars: int = 600
# Recall mode: how memory retrieval works when Honcho is active.
# "auto" — pre-warmed context + memory tools available (model decides)
# "hybrid" — pre-warmed context + memory tools available (model decides)
# "context" — pre-warmed context only, honcho memory tools removed
# "tools" — no pre-loaded context, rely on tool calls only
recall_mode: str = "auto"
recall_mode: str = "hybrid"
# Session resolution
session_strategy: str = "per-session"
session_peer_prefix: bool = False
@ -199,7 +199,7 @@ class HonchoClientConfig:
recall_mode=(
host_block.get("recallMode")
or raw.get("recallMode")
or "auto"
or "hybrid"
),
session_strategy=raw.get("sessionStrategy", "per-session"),
session_peer_prefix=raw.get("sessionPeerPrefix", False),

View file

@ -1580,7 +1580,7 @@ class AIAgent:
hcfg = self._honcho_config
mode = hcfg.memory_mode if hcfg else "hybrid"
freq = hcfg.write_frequency if hcfg else "async"
recall_mode = hcfg.recall_mode if hcfg else "auto"
recall_mode = hcfg.recall_mode if hcfg else "hybrid"
honcho_block = (
"# Honcho memory integration\n"
f"Active. Session: {self._honcho_session_key}. "
@ -3382,7 +3382,7 @@ class AIAgent:
# Honcho: read cached context from last turn's background fetch (non-blocking),
# then fire both fetches for next turn. Skip in "tools" mode (no context injection).
self._honcho_context = ""
_recall_mode = (self._honcho_config.recall_mode if self._honcho_config else "auto")
_recall_mode = (self._honcho_config.recall_mode if self._honcho_config else "hybrid")
if self._honcho and self._honcho_session_key and not conversation_history and _recall_mode != "tools":
try:
self._honcho_context = self._honcho_prefetch(user_message)

View file

@ -26,7 +26,7 @@ class TestHonchoClientConfigDefaults:
assert config.enabled is False
assert config.save_messages is True
assert config.session_strategy == "per-session"
assert config.recall_mode == "auto"
assert config.recall_mode == "hybrid"
assert config.session_peer_prefix is False
assert config.linked_hosts == []
assert config.sessions == {}
@ -168,7 +168,7 @@ class TestFromGlobalConfig:
config_file = tmp_path / "config.json"
config_file.write_text(json.dumps({"apiKey": "key"}))
config = HonchoClientConfig.from_global_config(config_path=config_file)
assert config.recall_mode == "auto"
assert config.recall_mode == "hybrid"
def test_corrupt_config_falls_back_to_env(self, tmp_path):
config_file = tmp_path / "config.json"