anomalyco / anomalyco/opencode

[FEATURE]: Search across my message history to quickly locate past conversations/content ("find what I told opencode before")

Open
#41,354 9 comments 1 reaction 1 assignee View on GitHub

@Hona is already working on this.

Since Aug 9, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

Problem

Over time I have hundreds of sessions across many projects. When I remember that "I told opencode something important a while ago" (a requirement, a decision, a constraint, a command I typed), there is currently no way to find it:

  • The TUI/Desktop session list only shows sessions by title/project — no content search.
  • Ctrl+F inside a session (#19143) only searches the currently open session — it cannot find that phrase I typed three weeks ago in another project.
  • The only workaround is recalling the approximate session/title, then scrolling through it manually. For long-running threads this is extremely inefficient; for forgotten sessions it's often impossible.

This is especially painful for agent-driven work: users increasingly delegate multi-day tasks, and "what did I tell the agent earlier" becomes a recurring lookup need.

Feature request

Add a content search across the user's message history:

  1. Scope: search my (user) messages — preferably all sessions, with per-project filtering (project:name, date range).
  2. Trigger: a search entry from the session list / project page (e.g. a search box or a /search command in the TUI); shortcut in Desktop.
  3. Result view: list of matches with session title, project, timestamp, and the surrounding message snippet; clicking a result opens that session (optionally scrolled to the matched message — which is exactly what #19101-style in-session find would then support).
  4. Constraints: search user messages by default; option to include assistant messages/tool calls; fuzzy match would beat SQL-like exact match for human recall.

Relationship to existing issue

  • #19101 covers in-session Find (Cmd/Ctrl+F) — complementary, not overlapping: that's "find in the session I'm looking at", this is "find which session contains it" (session discovery by content). Implementing this makes #19101 more useful and vice versa.

Environment

  • OpenCode Desktop 1.18.15 + CLI, Windows 11
  • Many projects/sessions accumulated daily; data presumably already stored in local session store (opencode.*.dat), so a local index/search over it should be feasible without server-side changes.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.