Skip to main content
A Markdown file in a software project should connect to repository reality — files, commands, packages, APIs, configs, tests, and versioned facts — or at least acknowledge that it doesn’t.

Formula

Components

  • Repo link density — relative repo links per 100 words.
  • Path resolution rate — how many path-like tokens resolve to actual files.
  • Code example density — labelled code-fence count per 100 words.
  • Identifier density — identifier-like tokens (CamelCase, snake_case, dotted paths) per word.
  • Version fact density — version pins, semver, dates, hash references per word.

Bands

How downstream metrics use it

  • Filler / Lazy Risk consumes 1 − RepositoryGroundingScore as one of its sub-scores.
  • The PR comment surfaces a 🔴 callout when grounding crosses a band downward.

References

  • Pirolli, P. & Card, S. (1999). Information Foraging. Psychological Review 106(4): 643–675 — underpins the “scent” intuition behind link-density and identifier-density. DOI.
  • Spence, R. (1999). A framework for navigation. International Journal of Human-Computer Studies 51(5): 919–945 — navigation framework that motivates resolved-link weighting. DOI.

See also