{"_id":"contextlevy","_rev":"7-d8ebaa35ab4dc98146122fc471770e14","name":"contextlevy","dist-tags":{"latest":"2.5.1"},"versions":{"2.2.0":{"name":"contextlevy","version":"2.2.0","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"unloopedmido"},"license":"MIT","_id":"contextlevy@2.2.0","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/unloopedmido/contextlevy#readme","bugs":{"url":"https://github.com/unloopedmido/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"0f29f3d2b29722c8d4eeca4402b5e412ed03abc3","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.2.0.tgz","fileCount":21,"integrity":"sha512-i9Eq0IpMVsINfOpdvSXtyBRkgdPZ6am678UhQQJVgerdcorL4JDqAOoBu6bPmxtEOXw1gnPBrHfYSy64ZxePnw==","signatures":[{"sig":"MEYCIQD9eqIs/aZOiNtWaW8cJNHfLqt5Cr7+kZicQ+f9F69DOQIhAJ5x/4zV40yWmXR8jAdmJzNmcK3IEyi3Sg2Pv9uYaisx","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":77737},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"696bab986b069106ad825195697a0687a4d2adb8","scripts":{"all":"npm run typecheck && npm run test && npm run build","test":"vitest run","build":"npm run build:action && npm run build:cli","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","build:action":"ncc build src/index.ts -o dist --license licenses.txt"},"_npmUser":{"name":"nonlooped","email":"cored.developments@gmail.com"},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/unloopedmido/contextlevy.git","type":"git"},"_npmVersion":"11.13.0","description":"Estimate AI agent context overhead from git diffs — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.16.0","dependencies":{"yaml":"^2.8.0","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^1.11.1","@octokit/rest":"^21.1.1","@actions/github":"^6.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.2.0_1779657914631_0.5142174927043528","host":"s3://npm-registry-packages-npm-production"}},"2.2.1":{"name":"contextlevy","version":"2.2.1","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"unloopedmido"},"license":"MIT","_id":"contextlevy@2.2.1","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/unloopedmido/contextlevy#readme","bugs":{"url":"https://github.com/unloopedmido/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"be4406e62cf2642995e2b151d73a6aee45b687b1","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.2.1.tgz","fileCount":22,"integrity":"sha512-pCqh7F3uSrQ4RIBiht0PdncTSee7qU4bcSF0tBZakz7b+xKIEcfB30AciiF32nFCUBp5o67qpWVuzPgR169FRw==","signatures":[{"sig":"MEQCIF9DeD3j+9viodRvN4pvbeEAv7Sekq9THzLNayJ2UMC3AiAUBvhCLVTYI5s47AkRg6VBTr81yv4/w4OCxyZraEh/kA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":87866},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"92c19a9072873442b36563006731a27758e912f8","scripts":{"all":"npm run typecheck && npm run test && npm run build","test":"vitest run","build":"npm run build:action && npm run build:cli","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","build:action":"ncc build src/index.ts -o dist --license licenses.txt"},"_npmUser":{"name":"nonlooped","email":"cored.developments@gmail.com"},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/unloopedmido/contextlevy.git","type":"git"},"_npmVersion":"11.13.0","description":"Estimate AI agent context overhead from git diffs — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.16.0","dependencies":{"yaml":"^2.8.0","chalk":"^4.1.2","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^1.11.1","@octokit/rest":"^21.1.1","@actions/github":"^6.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.2.1_1779658233230_0.46847672635534443","host":"s3://npm-registry-packages-npm-production"}},"2.2.2":{"name":"contextlevy","version":"2.2.2","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"unloopedmido"},"license":"MIT","_id":"contextlevy@2.2.2","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/unloopedmido/contextlevy#readme","bugs":{"url":"https://github.com/unloopedmido/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"5c1d31fa5ea4d5aae2f14874c98a842860897596","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.2.2.tgz","fileCount":22,"integrity":"sha512-WR+k5rhId7gLqgd6kwQOniVxXv9XFL/xedvW5WPFIFwZZz4wSMUKPTTuS1Sz8mSBSwCvd1Ra488zvtkAsVCsEg==","signatures":[{"sig":"MEUCIQDbq+48EZx4Yyl+rIzW6RlvZNX95IQwT/ik4CaiYzHPAgIgc6sHniM8Ba7OAnK9I1/vukRvm2xUtEywUjJi9G8HAYI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/contextlevy@2.2.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":88272},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"eb6fceae303167a212e35c1b7200dfda0dac1e57","scripts":{"all":"npm run typecheck && npm run test && npm run build","test":"vitest run","build":"npm run build:action && npm run build:cli","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","build:action":"ncc build src/index.ts -o dist --license licenses.txt"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:a48b4823-236c-499b-8bed-5d1eb2341bd9"}},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/unloopedmido/contextlevy.git","type":"git"},"_npmVersion":"11.15.0","description":"Estimate AI agent context overhead from git diffs — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.15.0","dependencies":{"yaml":"^2.8.0","chalk":"^4.1.2","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^1.11.1","@octokit/rest":"^21.1.1","@actions/github":"^6.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.2.2_1779658684079_0.5583732716655894","host":"s3://npm-registry-packages-npm-production"}},"2.3.0":{"name":"contextlevy","version":"2.3.0","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"unloopedmido"},"license":"MIT","_id":"contextlevy@2.3.0","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/unloopedmido/contextlevy#readme","bugs":{"url":"https://github.com/unloopedmido/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"e5dbfe9b19c926f9c574ea5c3ae15f4421b957bf","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.3.0.tgz","fileCount":27,"integrity":"sha512-XyDySu7ndwoaStGn/eeEjJTCRdKNBaCX5HZ+gZyMug3F62XoA9PwXKduQF3SYtd2lDia5Kn3GCPqG2l9DCkTxQ==","signatures":[{"sig":"MEYCIQCbZfHaFeYAK1KGo0mYLxb8YW2XAD+qCu36XWoW78jmbQIhANfU20Pw1BMGkMo5DQIbqmj8n0UP4iD469hVK0AFjhdU","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/contextlevy@2.3.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":77289},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"165460d82ae42e4ed68def1eafdfff6f8808bfbd","scripts":{"all":"npm run check && npm run build","lint":"biome lint --write .","test":"vitest run","build":"npm run build:action && npm run build:cli","check":"npm run check:biome && npm run typecheck && npm test","format":"biome format --write .","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","check:biome":"biome ci .","build:action":"ncc build src/index.ts -o dist --license licenses.txt"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:a48b4823-236c-499b-8bed-5d1eb2341bd9"}},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/unloopedmido/contextlevy.git","type":"git"},"_npmVersion":"11.15.0","description":"Estimate AI agent context overhead from git diffs — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.15.0","dependencies":{"yaml":"^2.8.0","chalk":"^4.1.2","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^1.11.1","@octokit/rest":"^21.1.1","@biomejs/biome":"2.4.15","@actions/github":"^6.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.3.0_1779670526964_0.3709834326920516","host":"s3://npm-registry-packages-npm-production"}},"2.4.0":{"name":"contextlevy","version":"2.4.0","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"unloopedmido"},"license":"MIT","_id":"contextlevy@2.4.0","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/unloopedmido/contextlevy#readme","bugs":{"url":"https://github.com/unloopedmido/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"cefb943de399808ad8abb9fa2b42ea7c1b0a9524","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.4.0.tgz","fileCount":31,"integrity":"sha512-bN+t5LlS3pTdIKauX2c6WaJ0nbwMqJsxSboh+nx+VI2ruA1uV2z6M37JOfmIszVrE8VqSsF57WPAtz/YQOsQrQ==","signatures":[{"sig":"MEUCIQCYkC8+PxgI1+tAxWNnmC+lu81SROGmI5dlJ0/bnsJLmAIgBuTJ2jm1lR40AulX2AG30Ycd0lIKX9Jrm0t8fWFVz5E=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/contextlevy@2.4.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":95902},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"de84d1659a88a5d3f9594e73a94f287fb85bf564","scripts":{"all":"npm run check && npm run build","lint":"biome lint --write .","test":"vitest run","build":"npm run build:action && npm run build:cli","check":"npm run check:biome && npm run typecheck && npm test && npm run check:fallow","format":"biome format --write .","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","check:biome":"biome ci .","build:action":"ncc build src/index.ts -o dist --license licenses.txt","check:fallow":"fallow dead-code"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:a48b4823-236c-499b-8bed-5d1eb2341bd9"}},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/unloopedmido/contextlevy.git","type":"git"},"_npmVersion":"11.15.0","description":"Repo hygiene linter for agent-heavy teams — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.15.0","dependencies":{"yaml":"^2.8.0","chalk":"^4.1.2","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"fallow":"^2.80.0","vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^1.11.1","@octokit/rest":"^21.1.1","@biomejs/biome":"2.4.15","@actions/github":"^6.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.4.0_1779742781114_0.135804919740933","host":"s3://npm-registry-packages-npm-production"}},"2.5.0":{"name":"contextlevy","version":"2.5.0","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"author":{"name":"nonlooped"},"license":"MIT","_id":"contextlevy@2.5.0","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"homepage":"https://github.com/nonlooped/contextlevy#readme","bugs":{"url":"https://github.com/nonlooped/contextlevy/issues"},"bin":{"contextlevy":"bin/contextlevy.js"},"dist":{"shasum":"337f24a41d0a929641ae149eb315ec1991d6252e","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.5.0.tgz","fileCount":43,"integrity":"sha512-W7kMDuzaqYmf+JoFMeFb1WLhsiRRw5pFeYDIZIfFA739f3WJPU3XYQXH955WzvjqjfsBtU89jVurQ1rrHUqNcA==","signatures":[{"sig":"MEQCIDQfsJfkto9ZrLzbaA+zlyRxRA94UZgNyvd3MwQs4pLtAiA1i1YJ0O3CesXQzB5Xx2JFt5J407Fd4v45htep3Kuwag==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/contextlevy@2.5.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":149243},"main":"lib/cli/index.js","engines":{"node":">=20"},"gitHead":"e9e1eb804c8d49c2d30b9588cd2c1bca3029c627","scripts":{"all":"npm run check && npm run build","lint":"biome lint --write .","test":"vitest run","build":"npm run build:action && npm run build:cli","check":"npm run check:biome && npm run typecheck && npm test && npm run check:fallow","format":"biome format --write .","prepack":"npm run build:cli","build:cli":"tsc -p tsconfig.cli.json","typecheck":"tsc --noEmit","pack:check":"npm pack --dry-run","test:watch":"vitest","check:biome":"biome ci .","build:action":"ncc build src/index.ts -o dist --license licenses.txt","check:fallow":"npm run build:cli && fallow dead-code"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4590d019-af47-4baf-9998-2d6b794d1f0e"}},"overrides":{"undici":"^6.25.0"},"repository":{"url":"git+https://github.com/nonlooped/contextlevy.git","type":"git"},"_npmVersion":"11.17.0","description":"Repo hygiene linter for agent-heavy teams — local CLI and GitHub Action","directories":{},"_nodeVersion":"24.16.0","dependencies":{"yaml":"^2.8.0","picocolors":"^1.1.1","js-tiktoken":"^1.0.21"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"fallow":"^2.80.0","vitest":"^4.1.7","typescript":"^6.0.3","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@actions/core":"^2.0.3","@octokit/rest":"^21.1.1","@biomejs/biome":"2.4.16","@actions/github":"^8.0.1","@octokit/auth-app":"^7.1.5","@vitest/coverage-v8":"^4.1.7"},"_npmOperationalInternal":{"tmp":"tmp/contextlevy_2.5.0_1781493599681_0.7739790875929398","host":"s3://npm-registry-packages-npm-production"}},"2.5.1":{"name":"contextlevy","version":"2.5.1","description":"Repo hygiene linter for agent-heavy teams — local CLI and GitHub Action","license":"MIT","author":{"name":"nonlooped"},"repository":{"type":"git","url":"git+https://github.com/nonlooped/contextlevy.git"},"homepage":"https://github.com/nonlooped/contextlevy#readme","bugs":{"url":"https://github.com/nonlooped/contextlevy/issues"},"keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"engines":{"node":">=20"},"main":"lib/cli/index.js","bin":{"contextlevy":"bin/contextlevy.js"},"scripts":{"build":"npm run build:action && npm run build:cli","build:action":"ncc build src/index.ts -o dist --license licenses.txt","build:cli":"tsc -p tsconfig.cli.json","prepack":"npm run build:cli","pack:check":"npm pack --dry-run","format":"biome format --write .","lint":"biome lint --write .","check:biome":"biome ci .","check":"npm run check:biome && npm run typecheck && npm test && npm run check:fallow","check:fallow":"npm run build:cli && fallow dead-code","test":"vitest run","test:watch":"vitest","typecheck":"tsc --noEmit","all":"npm run check && npm run build"},"dependencies":{"picocolors":"^1.1.1","js-tiktoken":"^1.0.21","yaml":"^2.8.0"},"devDependencies":{"@actions/core":"^2.0.3","@actions/github":"^8.0.1","@biomejs/biome":"2.4.16","@octokit/auth-app":"^7.1.5","@octokit/rest":"^21.1.1","@types/node":"^25.9.1","@vercel/ncc":"^0.38.4","@vitest/coverage-v8":"^4.1.7","fallow":"^2.80.0","typescript":"^6.0.3","vitest":"^4.1.7"},"overrides":{"undici":"^6.25.0"},"publishConfig":{"access":"public"},"gitHead":"8966e8c9345fb4ef67f02e6ff3f53875116a2992","_id":"contextlevy@2.5.1","_nodeVersion":"24.16.0","_npmVersion":"11.17.0","dist":{"integrity":"sha512-VKJ9fq+7WJSdhOD+/g7Bmq/+/YCzFngpqWODL7mIcs33foDOXkRibOteP1CHxLE7K6LG5v2+UgxhJbyQ+enwRw==","shasum":"54f1bdac6b7fc0e694bdbaba5a2df3e312ba66aa","tarball":"https://registry.npmjs.org/contextlevy/-/contextlevy-2.5.1.tgz","fileCount":43,"unpackedSize":149318,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/contextlevy@2.5.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIAbSm+Gk+v8bQ6qCRabHnEsultnHcX+IGD8iqDWNKnfuAiEApbL4Em0lSRNBjOryvuQlxgOK95VLr9wrqueHZ44HoE8="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:4590d019-af47-4baf-9998-2d6b794d1f0e"}},"directories":{},"maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/contextlevy_2.5.1_1781494912700_0.22708423271544498"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-24T21:25:14.459Z","modified":"2026-06-15T03:41:53.150Z","2.2.0":"2026-05-24T21:25:14.867Z","2.2.1":"2026-05-24T21:30:33.368Z","2.2.2":"2026-05-24T21:38:04.229Z","2.3.0":"2026-05-25T00:55:27.109Z","2.4.0":"2026-05-25T20:59:41.254Z","2.5.0":"2026-06-15T03:19:59.804Z","2.5.1":"2026-06-15T03:41:52.874Z"},"bugs":{"url":"https://github.com/nonlooped/contextlevy/issues"},"author":{"name":"nonlooped"},"license":"MIT","homepage":"https://github.com/nonlooped/contextlevy#readme","keywords":["ai","cli","context","cursor","diff","github-actions","llm","tokens"],"repository":{"type":"git","url":"git+https://github.com/nonlooped/contextlevy.git"},"description":"Repo hygiene linter for agent-heavy teams — local CLI and GitHub Action","maintainers":[{"name":"nonlooped","email":"cored.developments@gmail.com"}],"readme":"<p align=\"center\">\n  <img src=\".github/assets/Cover.png\" alt=\"ContextLevy\">\n</p>\n\n<p align=\"center\">\n  <strong>Repo hygiene linter for agent-heavy teams.</strong>\n</p>\n\n<p align=\"center\">\n  ContextLevy flags pull requests that will make coding-agent review noisy — generated output, coverage, build artifacts, lockfile churn, and agent instruction changes — before that noise becomes repo debt.\n</p>\n\n<p align=\"center\">\n  <a href=\"https://github.com/apps/contextlevy/installations/new\">\n    <img alt=\"Add ContextLevy to your repository\" src=\"https://img.shields.io/badge/Add%20to%20repository-Install-24292e?style=for-the-badge&logo=github&logoColor=white\">\n  </a>\n</p>\n\n<p align=\"center\">\n  <a href=\"https://github.com/nonlooped/contextlevy/actions/workflows/ci.yml\">\n    <img alt=\"CI\" src=\"https://img.shields.io/github/actions/workflow/status/nonlooped/contextlevy/ci.yml?branch=main&label=CI\">\n  </a>\n  <a href=\"https://github.com/nonlooped/contextlevy/releases\">\n    <img alt=\"Latest release\" src=\"https://img.shields.io/github/v/release/nonlooped/contextlevy?label=release\">\n  </a>\n  <a href=\"https://github.com/nonlooped/contextlevy/blob/main/LICENSE\">\n    <img alt=\"License\" src=\"https://img.shields.io/github/license/nonlooped/contextlevy\">\n  </a>\n  <img alt=\"Coverage\" src=\"https://img.shields.io/badge/coverage-%E2%89%A570%25-brightgreen\">\n  <img alt=\"PRs welcome\" src=\"https://img.shields.io/badge/PRs-welcome-brightgreen\">\n  <img alt=\"No LLM calls\" src=\"https://img.shields.io/badge/LLM%20calls-none-blue\">\n</p>\n\n---\n\n## Before / after\n\n| Before ContextLevy | After ContextLevy |\n| --- | --- |\n| A PR silently adds ~90k tokens of coverage, generated clients, and build output | Reviewers see exactly which files caused the bloat and what to remove |\n| Lockfile churn dominates diffs with no agent-cost signal | ContextLevy flags lockfiles, estimates token weight, and suggests review focus |\n| Agent instruction files change behavior without visibility | High-signal agent config changes appear in the PR thread |\n\n## Who is this for?\n\n| Use ContextLevy if… | Maybe skip it if… |\n| --- | --- |\n| Your team uses Cursor, Codex, or Claude Code heavily | Your repo rarely uses AI agents |\n| PRs often include generated output or coverage artifacts | You already have strict artifact hygiene and pre-commit gates |\n| You want advisory PR comments before merge | You need exact tokenizer-accurate billing from your provider |\n| You care about repo-level context debt, not just session tuning | You only need per-session context packs (see [ctx](https://github.com/forjd/ctx)) |\n\nSee [docs/EXAMPLES.md](docs/EXAMPLES.md) for benchmark tables, monorepo recipes, and output usage.\n\n**Live demo:** [open example PR](https://github.com/nonlooped/contextlevy/pull/17) — ContextLevy commenting on intentional high-context fixtures ([details](examples/README.md)).\n\n## Why ContextLevy?\n\nAI coding agents are extremely sensitive to noisy repository context. A single PR can add generated clients, coverage, build output, lockfile churn, snapshots, logs, vendored files, and agent instruction dumps — bloating every future AI-assisted session without breaking your app.\n\n**ContextLevy catches that before it becomes repo debt.** It scans diffs, estimates context weight, classifies risky files, and leaves a focused PR comment.\n\nSee [docs/COMPARISON.md](docs/COMPARISON.md) for how ContextLevy compares to bundle tools, [ctx](https://github.com/forjd/ctx), and agent session tools.\n\n![ContextLevy PR comment example](.github/assets/PR-Example.png)\n\n## What it catches\n\n| Risk            | Examples                                            | Why it matters                                         |\n| --------------- | --------------------------------------------------- | ------------------------------------------------------ |\n| Generated code  | `generated/client.ts`, `schema.graphql`, SDK output | Often huge, repetitive, and better regenerated locally |\n| Coverage output | `coverage/lcov.info`, `htmlcov/`                    | High token cost with almost zero agent value           |\n| Build artifacts | `dist/`, `build/`, `.next/`, compiled bundles       | Frequently duplicated from source                      |\n| Logs and dumps  | `*.log`, traces, debug output                       | Noisy context that agents over-read                    |\n| Lockfile churn  | `package-lock.json`, `pnpm-lock.yaml`, `yarn.lock`  | Can dominate diffs in dependency PRs                   |\n| Snapshots       | `__snapshots__/`, large fixture files               | Useful sometimes, expensive always                     |\n| Agent files     | `.agents/`, `AGENTS.md`, instruction packs          | Can silently steer future agent behavior               |\n\n## Privacy model\n\nContextLevy is intentionally boring:\n\n* **No LLM calls**\n* **No code upload**\n* **No external analysis service**\n* **No telemetry required**\n\nIt only uses GitHub pull request metadata and diff patches available inside the workflow. Token and cost numbers are estimates, not billing-grade accounting.\n\n## Quick start\n\n```bash\n# Scan your diff locally (no config required)\nnpx contextlevy check --base main\n\n# Baseline repo context debt before opening a PR\nnpx contextlevy scan\n\n# Scaffold config + optional workflow\nnpx contextlevy init\nnpx contextlevy init --workflow --mode strict\nnpx contextlevy init --full\n```\n\nSee [docs/QUICKSTART.md](docs/QUICKSTART.md) for modes, allowlists, and pre-push hooks.\n\n### GitHub Action (optional)\n\nAfter `contextlevy init --workflow`, or add manually:\n\nInstall the [ContextLevy GitHub App](https://github.com/apps/contextlevy) for best comment attribution (optional — `GITHUB_TOKEN` works for many repos).\n\n#### 1. Install the ContextLevy GitHub App\n\nInstall the app on your repository. Grant:\n\n| Permission    |       Access |\n| ------------- | -----------: |\n| Contents      |         Read |\n| Pull requests | Read & write |\n| Issues        | Read & write |\n\nThe published app posts PR comments with its own identity — no repository secrets required. After changing app permissions, accept the updated installation request on the repository.\n\n#### 2. Add the workflow\n\nCreate `.github/workflows/contextlevy.yml`:\n\n```yaml\nname: ContextLevy\n\non:\n  pull_request:\n    types: [opened, synchronize, reopened]\n\npermissions:\n  contents: read\n  pull-requests: write\n  issues: write\n  checks: write\n  security-events: write\n\njobs:\n  contextlevy:\n    name: Check repo context hygiene\n    runs-on: ubuntu-latest\n\n    steps:\n      - uses: actions/checkout@v6\n\n      - uses: nonlooped/contextlevy@v2\n        with:\n          github-token: ${{ github.token }}\n```\n\nThat is the full setup. ContextLevy reads your PR diff, estimates context weight, posts PR comments, and can publish a **Check Run** and **SARIF** report for branch protection and Code Scanning.\n\nAdd `contextlevy.config.yml` to tune thresholds, ignore paths, and fail modes — see [docs/CONFIG.md](docs/CONFIG.md).\n\n### Simple mode: `GITHUB_TOKEN` only\n\nWorks for many internal PRs without installing the app. Fork PRs may be read-only — see [docs/ACTION.md](docs/ACTION.md#fork-pull-requests).\n\n> **Maintainers and contributors only:** To test with a self-hosted GitHub App in a private fork, see [CONTRIBUTING.md — Self-hosted GitHub App](CONTRIBUTING.md#self-hosted-github-app-maintainers-and-contributors-only).\n\n## Local CLI\n\n`check` is the recommended command (`diff` is an alias):\n\n```bash\nnpm install -g contextlevy\ncontextlevy scan\ncontextlevy check --base main\ncontextlevy fix --write\ncontextlevy badge --style debt\ncontextlevy hook install\ncontextlevy init --full\n```\n\nSee [docs/CLI.md](docs/CLI.md) for `scan`, `fix`, `badge`, `hook install`, exit codes, and pre-push hook recipes.\n\n### Agent skills\n\nTeach coding agents how to set up and use ContextLevy:\n\n```bash\nnpx skills add nonlooped/contextlevy\n```\n\nThe interactive wizard lists every skill in [.agents/skills/](.agents/skills/) — pick `contextlevy` (GitHub Action), `contextlevy-cli` (local CLI), or both.\n\nSkill sources: [.agents/skills/contextlevy/SKILL.md](.agents/skills/contextlevy/SKILL.md) · [.agents/skills/contextlevy-cli/SKILL.md](.agents/skills/contextlevy-cli/SKILL.md)\n\n## Documentation\n\n| Doc | Description |\n| --- | --- |\n| [docs/QUICKSTART.md](docs/QUICKSTART.md) | 60-second local setup, modes, allowlists |\n| [docs/CONFIG.md](docs/CONFIG.md) | Config paths, options, severity, estimation, recipes |\n| [docs/ACTION.md](docs/ACTION.md) | Action inputs, outputs, job summary, fork PRs |\n| [docs/CLI.md](docs/CLI.md) | Local CLI install, flags, exit codes, hooks |\n| [docs/EXAMPLES.md](docs/EXAMPLES.md) | Benchmark tables, monorepo recipes, output usage |\n| [docs/COMPARISON.md](docs/COMPARISON.md) | vs bundle tools, ctx, session tools, `.gitattributes` |\n| [docs/TROUBLESHOOTING.md](docs/TROUBLESHOOTING.md) | Permissions, missing comments, bad estimates |\n| [docs/DEVELOPMENT.md](docs/DEVELOPMENT.md) | Build, test, release, trusted publishing |\n| [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) | Pipeline, module map, dependency rules |\n| [CONTRIBUTING.md](CONTRIBUTING.md) | Contributor setup and PR expectations |\n| [SECURITY.md](SECURITY.md) | Security policy and fork PR permissions |\n\n## Security\n\nContextLevy is a pull request analysis tool. It does not execute changed code and does not send repository contents to an LLM or third-party API.\n\nPlease report security issues privately through GitHub Security Advisories instead of opening a public issue.\n\n## License\n\nMIT\n","readmeFilename":"README.md"}