A Pi extension that replaces the built-in find and grep tools with FFF — a Rust search engine called through the Node SDK (@ff-labs/fff-node) via C FFI. No subprocess per call. Pre-indexed filesystem. Frecency-ranked results. Git-aware. Adds multi_grep for OR-logic multi-pattern search.
The extension's value is not in calling FFF. It is in what happens between the raw FFF result and the text the agent sees. The output formatter, fallback engine, and auto-enrichment logic are where the token savings come from.
Pi's built-in tools spawn fd (find) and rg (grep) as subprocesses. Every call starts from scratch — no index, no ranking, no memory of previous searches. Results come back as flat text sorted by filesystem order.