Remove the fuzzy subcommand#36
Merged
Merged
Conversation
why: `agentgrep fuzzy` filtered stdin lines — it ignored `--agent` and never read a store — so it sat outside agentgrep's prompt/history search scope and only approximated fzf (it scored with rapidfuzz rather than fzf's own algorithm). Removing it keeps the CLI focused on agent-history search; pipe through `fzf` directly for that workflow. what: - Delete src/agentgrep/fuzzy.py and the whole fuzzy CLI surface: the subparser, FuzzyArgs/_build_fuzzy_args, the FuzzyAlgo/FuzzyTiebreak literals, the dispatch branch, FUZZY_DESCRIPTION, and the render helpers (run_fuzzy_command/fuzzy_filter_lines/_apply_field_selection). - Delete tests/test_fuzzy.py and tests/test_cli_fuzzy.py; drop fuzzy from the deferred-import, root-help, and --ui-overlay tests. - Remove the fuzzy CLI doc page, its grid card and toctree entry, and the --ui overlay mention on the TUI page. - rapidfuzz stays — `search` ranking still uses it; the MCP surface is unaffected (no fuzzy tool).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Removes
agentgrep fuzzy. It was afzf --filter-shaped filter over stdin —run_fuzzy_commandreadsys.stdinand ignored--agent, so it never touched a Codex / Claude / Cursor / Gemini / Grok store. That placed it outside agentgrep's "search local AI-agent prompts and history" scope, and it only approximated fzf (scoring via rapidfuzz rather than fzf's ownFuzzyMatchV1/FuzzyMatchV2), so--algo/--tiebreaknever matched fzf's behavior.Removed across code and docs:
src/agentgrep/fuzzy.py, thefuzzysubparser +FuzzyArgs+_build_fuzzy_args+ theFuzzyAlgo/FuzzyTiebreakliterals + dispatch +FUZZY_DESCRIPTION, therun_fuzzy_command/fuzzy_filter_lines/_apply_field_selectionrender helpers, the two fuzzy test files, and the fuzzy CLI doc page / grid card / toctree entry / TUI overlay mention.grepandfindare unaffected and stay regex-by-default (that path runs through ripgrep).rapidfuzzstays —searchranking still uses it. No MCP tool exposed fuzzy, so the MCP surface is unchanged.Closes #35. Re-adding
fuzzywith a faithful fzf port is tracked in #34.Test plan
ruff check,ruff format,ty check,py.test --reruns 0(814 passed),just build-docs.agentgrep fuzzy foonow exits 2 (invalid choice: 'fuzzy');agentgrep --helplists{grep,find,ui,search};grep/find/search/uiand thegrep --ui/find --uioverlays still work.rgconfirms noFuzzyArgs/run_fuzzy_command/agentgrep.fuzzysymbols remain insrc/ortests/.