npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@evidtrail/metrics

v1.1.1

Published

Deterministic rapid-retouch, trend, cohort, and outcome metrics for evidtrail. An auditable ledger of AI provenance and change signals for your git repositories — honest about what git can and cannot prove.

Readme

@evidtrail/metrics

Deterministic metric calculation for versioned evidtrail repository snapshots.

What it calculates

  • Repository change signals — fixed-horizon rapid retouch at 7, 30, and 90 days. Files without a complete observation window stay visible as tooRecent; rapid retouch is a file-level churn signal, not proof of a defect, wasted work, or causality.
  • Trend — repository change signals over monthly or quarterly periods. Every period uses the same observation window; immature periods are reported but excluded from comparisons.
  • Evidence coverage and autonomy cohorts — declared, inferred, and missing provenance, plus optional comparisons by autonomy mode. Cohort comparisons are withheld when the evidence cannot support an honest comparison; defaultMode is a prior for cohort membership, never evidence.
  • Line survival — optional git blame input reports attribution for lines alive in the sampled tree. The surviving-line share is exact for that input; the derived survival rate is explicitly approximate because deleted lines are unavailable to blame.
  • Outcome correlation — git-visible reverts and hotfix-pattern commits, expressed against each cohort's authored-commit base rate. The results are descriptive, not causal, and do not include incidents or external security findings.
  • PR acceptance — optional forge PR input reports merged versus closed-unmerged PRs, including attribution and autonomy breakdowns. It is absent when no PR stream is supplied, never silently zero.

For why evidtrail does not calculate Merge Ratio from Git history, see Why there is no Merge Ratio in the repository README.

Usage

import { calculateMetrics } from '@evidtrail/metrics';

const metrics = calculateMetrics(commitStream);
const retouch30 = metrics.repo.persistence.rapidRetouch.find((r) => r.windowDays === 30);
console.log(`30-day rapid retouch: ${retouch30?.rate ?? 'unavailable'}`);
console.log(`Evidence coverage: ${metrics.attribution.coverage}`);

Pass blameStream from evidtrail blame or prStream from evidtrail fetch-prs to calculate the corresponding optional metrics. See the root README for the metric contracts, caveats, and CLI workflow.