35 matches across 1 files for func main lang:Go path:processor/history_coupling.go lang:Go lang:Go lang:Go lang:Go lang:Go
snippet_mode: auto · sorted by relevance
processor/history_coupling.go GO 35 matches · showing 5 view file →
68// 100%; multiplied by high test-file complexity that buries the real work.
69// Volume keeps the heavyweight couplings on top and matches --hotspots.
70func (c CouplingCount) WeightedScore() float64 {
71 return float64(c.Shared) * float64(min(c.ComplexityA, c.ComplexityB))
72}
· · ·
75// co-change first, then degree, then path. Shared by the raw sort and used as
76// the tiebreak under weighted ranking.
77func lessCouplingRaw(a, b CouplingCount) bool {
78 if a.Shared != b.Shared {
79 return a.Shared > b.Shared
· · ·
91// when the Cognitive global is on (matching --hotspots), cyclomatic otherwise.
92// A path absent from HEAD contributes zero, so it can never lift a pair's score.
93func headComplexity(head HeadSnapshot, path string) int64 {
94 hf, ok := head.Files[path]
95 if !ok {
· · ·
106// for the human-facing table only; the raw counts sit beside it so the number
107// is never a black box. Returns 0 when the union is empty.
108func (c CouplingCount) Degree() float64 {
109 union := c.CommitsA + c.CommitsB - c.Shared
110 if union <= 0 {
· · ·
140type pairKey struct{ a, b string }
141
142func newCouplingObserver() *couplingObserver {
143 return &couplingObserver{
144 maxFilesPerCommit: CouplingMaxFilesPerCommit,
+ 30 more matches in this file
Search syntax
auth loginboth terms (AND is implicit)
auth OR logineither term
NOT path:vendorexclude matches
"exact phrase"quoted exact match
/func\s+Test/regex
handler~1fuzzy (Levenshtein 1)
file:*_test.gofilename glob
path:pkg/auth/**full path glob
lang:golanguage filter

Search any public repo from your terminal

This page calls POST /api/v1/code_search. Same tool, available over MCP for Claude/Cursor/Copilot.