Skip to content

Remove the fuzzy subcommand #35

@tony

Description

@tony

Summary

agentgrep fuzzy is a fzf --filter-shaped filter that scores stdin lines — it does not read any Codex / Claude / Cursor / Gemini / Grok store, and the --agent flag it accepts is ignored. That puts it outside agentgrep's scope ("read-only search over local AI-agent prompts and history") and duplicates fzf.

It also doesn't reproduce fzf: the scorer wraps rapidfuzz (WRatio / partial_ratio), so --algo v1|v2 and --tiebreak approximate but don't match fzf's real FuzzyMatchV1 / FuzzyMatchV2 and tiebreak criteria — we advertise fzf parity we don't deliver.

Remove the subcommand for now to keep the CLI focused on agent-history search. Re-adding it with a faithful fzf port is tracked in #34. This mirrors the scope-tightening in #33. Breaking changefuzzy shipped in 0.1.0a5.

Scope (self-contained)

  • Delete src/agentgrep/fuzzy.py (rapidfuzz wrapper: rank_lines, fuzzy_score, extended_match, resolve_case_sensitivity).
  • Remove the fuzzy subparser, FuzzyArgs, _build_fuzzy_args, and the FuzzyAlgo / FuzzyTiebreak literals from cli/parser.py; drop the dispatch branch, FUZZY_DESCRIPTION, and re-exports in __init__.py.
  • Remove run_fuzzy_command / fuzzy_filter_lines / _apply_field_selection from cli/render.py.
  • Delete tests/test_fuzzy.py and tests/test_cli_fuzzy.py.
  • Delete docs/cli/fuzzy.md and the fuzzy card in docs/cli/index.md.
  • rapidfuzz stayssearch ranking (ranking.py) still uses it. No MCP tool exposes fuzzy, so the MCP surface is unaffected.

Acceptance criteria

  • agentgrep fuzzy … exits as an unknown subcommand; search / grep / find / ui unchanged.
  • ### Breaking changes CHANGES entry; full gate green (ruff / ty / pytest / docs).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions