Core Concept

Code Balance. Lines Added, Lines Removed.

Lines removed as a share of lines added. It shows whether a contributor deletes code as well as adds it, not why.

What You'll See

Key capabilities and insights available in this lens.

Read With Review Activity

The contributor card shows commits, merged PRs, and reviews next to Code Balance. Engineers who only write but never review create knowledge silos.

Additions & Deletions

Track lines added vs. removed. Engineers who can delete code effectively are often more valuable than those who only add.

Balance Rating

Each contributor receives one of four ratings: excellent at 90% or above, good from 70% up to but not including 90%, decent from 50% up to but not including 70%, and needs improvement below 50%. Quick visibility into team health.

Team Patterns

Compare addition and deletion patterns with Commons Impact and Bus Factor before changing team responsibilities.

Imbalance Alerts

Get flagged when contributors are significantly out of balance. Catch problems before they lead to quality issues or burnout.

Net Code Impact

Track net lines of code over time. A contributor with high additions but low deletions may be adding complexity without refactoring.

How Code Balance is calculated

Code Balance compares the lines a contributor removed with the lines they added over the same period. A high score means they deleted nearly as many lines as they added. A low score means the codebase grew through their changes. The number does not say why code was added or removed.

Formula

Code Balance = min(lines removed / lines added, 1) × 100%

  • The score is capped at 100%. Removing more than you add does not score higher; it shows up as a negative net line change.
  • A contributor who added no lines in the period scores 0%, because there is nothing to balance.
  • Net lines = lines added - lines removed. It is shown next to the percentage on every contributor card.
  • Each contributor also gets one of four ratings: excellent at 90% or above, good from 70% up to but not including 90%, decent from 50% up to but not including 70%, and needs improvement below 50%.
  • The rating uses the exact ratio before rounding. A ratio of 0.895 displays as 90% but is rated good, because it is below 0.9.
Sample People Lens values from the Connectory demo dashboard.
ContributorLines addedLines removedNet linesCode BalanceRating
illia2,5472,529+1899%excellent
gael4,1203,890+23094%excellent
sarah1,8901,650+24087%good
marcus3,200890+2,31028%needs improvement
priya3,1002,950+15095%excellent
ryan1,8001,000+80056%decent

How to read the numbers

  • Near 100% means additions and deletions almost cancel out. In the sample, illia added 2,547 lines and removed 2,529, so Code Balance is 99% with a net change of +18 lines: steady work that replaces code rather than piling it up.
  • A low percentage with a large positive net means the codebase is growing through this person. In the sample, marcus added 3,200 lines and removed 890, so Code Balance is 28% with a net change of +2,310 lines. That is expected while building something new, and worth a conversation if it persists.
  • A middle score means a contributor removed some code while still growing the codebase. In the sample, ryan added 1,800 lines and removed 1,000, so Code Balance is 56% with a net change of +800 lines, which is rated decent.
  • Look at the trend, not a single period. Pair the score with review counts on the same card: a contributor with low balance and few reviews may be working in isolation.
  • Treat it as a prompt for a conversation. Code Balance says nothing about the quality or difficulty of the work on its own.

Frequently asked questions

How is Code Balance calculated?

Code Balance divides the lines a contributor removed by the lines they added in the same period and shows the result as a percentage, capped at 100%. A contributor who added no lines scores 0%. The dashboard also shows the raw additions, deletions, and net line change so you can see the numbers behind the percentage.

Is a low Code Balance score bad?

Not on its own. A contributor building a new service will add far more than they remove. A low score is a prompt to look at the work: if it stays low across many periods while the codebase grows, ask whether old code is being refactored or left in place next to new code.

What do the Code Balance ratings mean?

There are four ratings: excellent at 90% or above, good from 70% up to but not including 90%, decent from 50% up to but not including 70%, and needs improvement below 50%. The rating uses the exact ratio before rounding, so a contributor whose score displays as 90% can still be rated good if the exact ratio is just under 0.9.

Can Code Balance go above 100%?

No. Removing more lines than you add is capped at 100%. The net line figure shows the difference, so a large cleanup appears as a negative net change rather than a score above 100%.

Want to see this in your org?

Get early access to the full Organization Dashboard.