Skip to content

feat: first-class session search and recall #197

@furukama

Description

@furukama

Summary

HybridClaw already stores canonical session history, compacts older turns into semantic memory, and can export sessions, but it does not have a first-class user-facing way to search past conversations and pull relevant past context back into the current turn.

Why

This is one of the highest-leverage missing features for a multi-channel personal agent. Users need to be able to find old conversations, inspect the matching turn or session, and explicitly recall that material into the active session without manual export/import work.

Proposed scope

  • Add a user-facing session search surface in TUI, web chat, and gateway commands.
  • Support both keyword search and semantic search over older compacted memory.
  • Return session id, channel/source, timestamp, short preview, and match reason.
  • Add a recall action that injects a selected past turn/session summary into the current turn as explicit retrieved context.
  • Keep recall operator-controlled and visible in the prompt/audit trail.

Candidate UX

  • /session search <query> or !claw session search <query>
  • /session recall <sessionId>
  • web chat search panel with a "Use in this chat" action
  • optional @session:<id> inline context reference

Implementation notes

  • Build on existing session persistence, compaction, and semantic memory instead of introducing a parallel memory store.
  • Preserve source attribution for recalled material.
  • Avoid silently expanding prompts with old content; recall should be explicit.
  • Respect channel/session privacy boundaries when exposing search results.

Acceptance criteria

  • Users can search past sessions from at least one interactive surface.
  • Search results include enough metadata to identify the right conversation.
  • Users can pull a selected result into the current turn in a structured, auditable way.
  • Recalled context is clearly marked in transcripts and does not mutate original history.
  • Tests cover search matching, permission/boundary behavior, and recall prompt injection.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions