Language support

Two different mechanisms build the context, and they do not cover the same set of languages. The difference matters, so it is spelled out here rather than discovered.

The two mechanisms#

MechanismCoverageWhat it gives you
Chunking (Tree-sitter) 300+ grammars, detected from the file path A changed line expands to the whole function containing it
Caller search 18 file extensions, listed below The functions elsewhere in the repo that call a changed function

Extensions the caller search covers#

.py   .js   .jsx  .ts   .tsx  .go
.java .rb   .rs   .c    .h    .cpp
.hpp  .cs   .php  .kt   .swift .scala
If your language is not in that list, the reviewer still parses your changed functions and reviews them — but it will not find callers in other files, which means the cross-file contract break is exactly the class of bug it stops catching for you. That is the headline capability, so know it up front.

What degrades, and how#

  • No grammar for the language: chunking returns nothing for that file and the reviewer sees the raw diff without enclosing functions. The review still runs.
  • A file that fails to parse: same — that one file degrades, the rest of the review is unaffected. Nothing crashes over one bad file.
  • Extension outside the caller list: no caller context, so no signature-change promotion for that language.
  • A language whose functions don't start with def, function, func or fn: no callee context. A Java or C# method is not found by its definition line, so the reviewer sees what the changed code calls only if the code is written that way.
  • ripgrep missing: no degradation at all. A pure-Python walk applies the same skip list, the same extension filter and the same size cap, and returns the same hits.

Directories never searched#

Regardless of language, the caller search skips .git, node_modules, vendor, .venv, venv, __pycache__, dist, build, .mypy_cache and .pytest_cache, and ignores files over 2 MB. Third-party code should not consume a review's context budget, and a finding raised against vendored code is a finding nobody in your repository can act on.

Findings the parser proves#

For one kind of bug the reviewer does not need a model's opinion. When a Python function's signature changes, each place that calls it is parsed and tested against the new parameter list. A call that can no longer bind — a missing required argument, one too many, an unknown keyword — and that could have bound to the old signature is a break this change caused. It is reported on the changed signature with the evidence attached, and it skips the second model, because there is nothing left to ask. Nothing is executed: the code is only parsed.

It is deliberately quiet. A call is only judged when it can be tied to the function it names:

  • the repository defines that name exactly once;
  • a call from another file imports the name from the changed file's module;
  • a method is only checked against self.name(...) in its own file;
  • a call using *args or **kwargs, a decorated function, and a call that was already wrong before the change are all skipped.

Python only. In any other language the model proposes and the second model decides, as before.

Adding a language#

The caller list is one set in src/groundtruth_review/context_engine/callers.py. Adding an extension there is a one-line change, and both search paths read the same constant, so they cannot fall out of step. A pull request adding your language is welcome; a case in cases/ exercising it is even more welcome.