CLI

Readable text output:

evidence-fetcher "retrieval augmented generation evaluation"

JSON output:

evidence-fetcher "retrieval augmented generation evaluation" --format json

Use --limit to control the maximum number of results.

Interactive relevance feedback

evidence-fetcher "retrieval augmented generation evaluation" --interactive

Interactive mode performs the same initial search, then lets you mark displayed results, request a local rerank, or explicitly expand retrieval with a refined query. Ordinary text and JSON commands are unchanged and remain non-interactive. Interactive mode is text-only; combining --interactive with --format json is rejected.

Supported interactive commands:

more 1 3
less 4
irrelevant 5
unsure 2
show        # or rerank
expand
help        # or ?
done        # or quit, q, exit

Result numbers are presentation-only positions in the currently displayed list. Feedback is stored against each evidence URL, and after show the same number may refer to a different result.

The interactive prompt shows the number of displayed results and accumulated feedback items, for example [10 results, 2 feedback items] >.

show reranks only the current candidate set using accumulated feedback. expand builds a deterministic lexical query from the original query and feedback-marked evidence, performs one additional Brave retrieval, merges any new URLs into the session, preserves accumulated feedback, and reranks the expanded candidate set. Expansion is always user-triggered; feedback commands do not automatically run new searches.

Example session:

$ evidence-fetcher "retrieval augmented generation evaluation" --interactive
Interactive relevance feedback. Type 'help' for commands.
1. Result title
   https://example.com/page
   Short snippet...
[10 results, 0 feedback items] > more 1
recorded more: 1 (1 feedback item total)
[10 results, 1 feedback item] > irrelevant 3
recorded irrelevant: 3 (2 feedback items total)
[10 results, 2 feedback items] > show
Updated ranking from accumulated feedback:
1. Result title
   https://example.com/page
   Short snippet...
[10 results, 2 feedback items] > expand
Searching with refined query:
retrieval augmented generation evaluation benchmark faithfulness
Added 4 new results.
Updated ranking:
1. Result title
   https://example.com/page
   Short snippet...
[14 results, 2 feedback items] > done