Search and recall
Hansard search is the direct path to a known conversation or topic. It searches the normalized archive and can narrow results with structured metadata.
Search in the app
Section titled “Search in the app”Open Conversations and select the search icon beside the conversation count. Enter a distinctive phrase from the request, response, or tool output; the result list replaces the ordinary recent-session tree while the query is active. Select a result to open its transcript, tool calls, files, commits, and recorded provenance in the conversation pane.
For a broad archive, open Filter & sort beside the search icon. Source limits the originating harness, Model limits recorded model IDs, Time sets a recent window, Include controls agent, SDK, and web conversations, and Folder narrows the project path. These filters combine with the search text. Use Reset filters when an expected conversation is absent before concluding that it was never imported.
The archive search and the transcript finder have different scopes. The sidebar search finds conversations across Hansard; after opening one result, the conversation’s find control searches only that transcript. The terminal commands below expose the same archive for scripts and agent integrations.
List recent sessions
Section titled “List recent sessions”Run history without a query to list recent archived sessions:
hansard historyThe same archive is available through the Conversations view in hansard app
or hansard web.
Search by text
Section titled “Search by text”Pass a phrase and an optional time window:
hansard history "authentication migration" --since 90d --limit 10Search terms do not need to reproduce a title exactly. Use selective terms that are likely to appear in the prompt, response, or canonical tool events.
Narrow the result set
Section titled “Narrow the result set”Filters can be used independently or combined:
hansard history --repo github.com/acme/widgets --provider codex-clihansard history "cache invalidation" --tool apply_patchhansard history --command "git commit" --since 30d| Option | Purpose |
|---|---|
--repo <repo-or-path> |
Match a repository, archive scope, working directory, or displayed path. |
--provider <provider-or-alias> |
Match a provider or source alias such as codex-cli. |
--tool <name> |
Match the normalized tool name recorded for a session. |
--command <head> |
Match a parsed shell command head such as git commit. |
--since <window> |
Limit results to a date window such as 30d or 90d. |
--limit <count> |
Cap the number of returned sessions. |
--include-subagents |
Include linked child/subagent runs hidden from the default conversation list. |
--no-web-chats |
Exclude non-repository web-chat imports. |
--json |
Return machine-readable results. |
Read the selected session safely
Section titled “Read the selected session safely”Full conversation output can exceed an agent harness limit. Start with a bounded latest window:
hansard show <session-id> --json --msg-limit 20For continuation work, also read the beginning of the conversation to recover the original objective and constraints:
hansard show <session-id> --json --msg-offset 0 --msg-limit 8When --msg-offset is omitted from a windowed JSON request, Hansard returns the
latest messages. Windowed output omits the full Markdown and event copies and
bounds large tool output while retaining tool-call arguments.
Search coverage
Section titled “Search coverage”Normal search uses the canonical archive index. --markdown-fallback is a
recovery option for legacy archives that are missing canonical events; it is not
the normal search mode. A search miss means that no match was found in the
selected archive coverage, not that the event could never have happened.