Skip to content

[P14] Implement implicit_coupling tool #4

@four-bytes-robby

Description

@four-bytes-robby

Goal

Detect files that always change together in the same commit — hidden dependencies invisible in code.

Parameters

  • threshold (number, optional, default: 0.8) — minimum co-commit rate
  • since (string, optional) — time window filter

Implementation

  • Parse all commits, extract file lists per commit
  • Build co-occurrence matrix for file pairs
  • Compute coupling strength = co-commits / max(individual commits)
  • Return pairs above threshold, ranked by strength
  • Cap at reasonable limit (e.g., top 50 pairs)

Tests

  • Test with known coupled file pairs
  • Verify threshold filtering
  • Test empty repo edge case

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions