v0.0.18
What's Changed
Changed
- DB read paths now hydrate
Candidate.content—ls,glob,delete,move,tree, andlexical_searchalways populatecontenton the candidates they emit. The underlyingselect(self._model)was already pulling the column over the wire; theinclude_content=Falsedefault onto_candidatewas discarding it during projection. Removed the parameter entirely so every read-path projection returns content, eliminating the redundant follow-upread(...)round trip when a downstream stage needs the content. - MSSQL
_grep_impl,_glob_impl, and_lexical_search_impldelegate to the base class whencandidatesis supplied — Once the candidate set has been transferred to Python (and now carries content), there is nothing left for SQL Server to do. The base class runs the regex via_collect_line_matchesand BM25 viaBM25Scorerover the in-memory content with zero round trips. Full-tree pushdowns (CONTAINSTABLE,REGEXP_LIKE) are unchanged for the no-candidates path. - MSSQL
_glob_implno-candidates branch —SELECT path, kind, contentinstead ofSELECT path, kind, so glob results carry content directly out of the pushdown. - MSSQL
_lexical_search_implno-candidates branch — Follows theCONTAINSTABLEpushdown with one small batchedSELECT path, content WHERE path IN (top_k)so the top-k results return hydrated.kis bounded (default 15), so the second round trip is tiny. - Base
_lexical_search_impl— Threads content through_LexicalDocinto the result candidates (previously dropped during result construction). - Base
_glob_implupstream-candidates branch — Preserves prior content and metrics viaCandidate.model_copy(...)instead of constructing a freshCandidatethat drops them. _read_impl— Skips theSELECTfor already-hydrated candidates and only fetches the gaps. Makesread(candidates=...)cheap when content is already on the candidates from a prior stage.
Removed
include_contentparameter onGroverObjectBase.to_candidate— Always populates content now. The 5 callers that explicitly passedinclude_content=True(_write_impl,_read_impl, bulk write) drop the redundant kwarg.- MSSQL
_grep_with_candidate_chunkshelper — Dead after the candidates path delegates to the base class.
Fixed
glob | grepon MSSQL drops from three round trips to one — Previously the executor pre-hydrated content viaread(...), then MSSQL_grep_implignored the hydrated content and re-queried withREGEXP_LIKEagainst the same paths. Now glob returns hydrated content directly and grep runs the regex in Python on the in-memory candidates.
Full Changelog: v0.0.17...v0.0.18