Skip to content

fix(honcho): align honcho_search retrieval with observation direction#5658

Closed
Gabrielgvl wants to merge 1 commit into
NousResearch:mainfrom
Gabrielgvl:fix/honcho-search-directional-target
Closed

fix(honcho): align honcho_search retrieval with observation direction#5658
Gabrielgvl wants to merge 1 commit into
NousResearch:mainfrom
Gabrielgvl:fix/honcho-search-directional-target

Conversation

@Gabrielgvl

Copy link
Copy Markdown

Summary

Fix honcho_search returning empty results when conclusions are stored in directional observation mode.

Root cause: retrieval queried the user peer's self-context, while conclusions are typically written as assistant -> user in directional mode.

Changes

  • plugins/memory/honcho/session.py
    • add target_id support to _fetch_peer_context(...)
    • pass target= to peer.context(...) when querying observer->observed context
    • update search_context(...) to select retrieval direction by observation mode:
      • directional (_ai_observe_others=True): assistant -> user
      • unified (_ai_observe_others=False): user self-context
  • tests/honcho_plugin/test_session.py
    • update existing search-context test for assistant-perspective query with target
    • add unified-mode regression test

Validation

  • python -m pytest tests/honcho_plugin/test_session.py -q -> 34 passed
  • python -m pytest tests/honcho_plugin -q -> 124 passed

Notes

This keeps read semantics aligned with write semantics from create_conclusion(...) across observation modes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant