Files that change together
list_coupled_filesIdentify which files usually change together to predict what an edit will drag along. Ranks co-change pairs by shared commit count, up to 50, with configurable support and confidence.
Instructions
Lists file pairs that keep landing in the same commits over the churn window, strongest first, at most 50. Use it before editing a file to learn what an edit drags along. Use list_duplicate_functions for copied code rather than co-change. It reads git log once per call, not the scored run. An empty list means no pair cleared both thresholds, not a missing run. A pair must clear both thresholds: min_support 5 needs five shared commits, min_confidence 0.5 means the rarer file moved with its partner half the time. repo defaults to the server's own root.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| repo | No | path to the scored repo's root (default: the repo the server was started in) | |
| min_support | No | minimum shared commits before a pair counts (default 5) | |
| min_confidence | No | minimum P(pair changes together), 0 to 1 (default 0.5) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pairs | No | pairs clearing both thresholds, ordered by support x confidence descending, at most 50 | |
| schema | No | payload schema version, 1 | |
| window_months | No | months of git history the pairs were counted over (the config's churn_window_months) |