{"_id":"@anjuvenu2005/impact-analyzer","name":"@anjuvenu2005/impact-analyzer","dist-tags":{"latest":"3.0.0"},"versions":{"3.0.0":{"name":"@anjuvenu2005/impact-analyzer","version":"3.0.0","description":"Diff-aware and simulation-first CLI for dependency impact analysis","main":"src/cli/index.js","type":"commonjs","engines":{"node":">=18"},"bin":{"impact-analyzer":"src/cli/index.js"},"scripts":{"analyze":"node src/cli/index.js analyze","check":"node src/cli/index.js check","graph":"node src/cli/index.js graph","focus":"node src/cli/index.js focus","metrics":"node src/cli/index.js metrics","smoke":"node src/cli/index.js --help > /dev/null","pack:dry-run":"npm pack --dry-run"},"keywords":["impact-analysis","change-impact","dependency-graph","git","cli","devtools","engineering-productivity"],"author":{"name":"Anjana Venugopalan"},"license":"MIT","publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/anjuvenuDev/impact-analyzer.git"},"homepage":"https://github.com/anjuvenuDev/impact-analyzer#readme","bugs":{"url":"https://github.com/anjuvenuDev/impact-analyzer/issues"},"dependencies":{"@babel/parser":"^7.28.0","chalk":"^4.1.2","commander":"^12.1.0"},"_id":"@anjuvenu2005/impact-analyzer@3.0.0","gitHead":"7d859843ac9d5891a9905b9ba44973b7a678ac7f","_nodeVersion":"20.20.2","_npmVersion":"10.8.2","dist":{"integrity":"sha512-twcxsG2KiLaAiAMGeQZrnVWy50R+RyGiXMNt3nYM8OS0rjXGyRl2fVjt95XbbNhmojt2UYJclLRpyzXWvjUbIA==","shasum":"cd4a7ea4e27c84469fc6c3ac28cc7ec59477a838","tarball":"https://registry.npmjs.org/@anjuvenu2005/impact-analyzer/-/impact-analyzer-3.0.0.tgz","fileCount":23,"unpackedSize":73499,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCHzCfr6YUGpu/fsnr94QDZjLVOqSCoCHytK8nG3qXJLQIgb70ps8SR+eaCjEMaUZqIWGCD3V41FZhxcP2ucF8r+Sw="}]},"_npmUser":{"name":"anjuvenu2005","email":"anjuvenu2005@gmail.com"},"directories":{},"maintainers":[{"name":"anjuvenu2005","email":"anjuvenu2005@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/impact-analyzer_3.0.0_1776359751352_0.42066205857482775"},"_hasShrinkwrap":false}},"time":{"created":"2026-04-16T17:15:51.170Z","3.0.0":"2026-04-16T17:15:51.507Z","modified":"2026-04-16T17:15:51.775Z"},"maintainers":[{"name":"anjuvenu2005","email":"anjuvenu2005@gmail.com"}],"description":"Diff-aware and simulation-first CLI for dependency impact analysis","homepage":"https://github.com/anjuvenuDev/impact-analyzer#readme","keywords":["impact-analysis","change-impact","dependency-graph","git","cli","devtools","engineering-productivity"],"repository":{"type":"git","url":"git+https://github.com/anjuvenuDev/impact-analyzer.git"},"author":{"name":"Anjana Venugopalan"},"bugs":{"url":"https://github.com/anjuvenuDev/impact-analyzer/issues"},"license":"MIT","readme":"# Code Impact Analyzer\n\nDeveloper-first CLI to predict blast radius from real diffs or simulated file changes.\n\nIt builds a dependency graph, traverses reverse dependencies, scores impacted files, and explains why each file is affected.\n\n## Features\n\n- Diff-aware analysis (`HEAD~1`, staged, commit range)\n- Simulation mode before making changes (`check`)\n- Impact scoring with risk levels (`HIGH`, `MEDIUM`, `LOW`)\n- Explainability (`--why`) and source-line insights (`--code`)\n- Policy gates for CI (`criticalPaths`, risk threshold, owners)\n- Incremental cache for faster repeated runs\n- Forecast/validation loop with precision/recall/F1 metrics\n\n## Install\n\n```bash\nnpm install\n```\n\n## Quickstart\n\n```bash\n# Simulate impact before editing code\nimpact-analyzer check src/auth.ts --why\n\n# Analyze actual repo changes\nimpact-analyzer analyze --staged --why\n\n# Export machine-readable artifacts\nimpact-analyzer analyze --export output --output both\n```\n\n## Commands\n\n```bash\nimpact-analyzer analyze [--commit <ref> | --staged] [options]\nimpact-analyzer check <file...> [--targets <csv>] [options]\nimpact-analyzer graph [file] [--depth <n>]\nimpact-analyzer focus <file>\nimpact-analyzer interactive\nimpact-analyzer metrics\n```\n\nCommon options:\n\n- `--output cli|json|both`\n- `--report-file <path>`\n- `--export [dir]`\n- `--why`\n- `--code`\n- `--depth <n>` / `--max-depth <n>`\n- `--risk HIGH|MEDIUM|LOW`\n- `--fast`\n- `--record-forecast`\n- `--validate-latest`\n- `--ci`\n- `--ci-threshold <risk>`\n- `--no-cache`\n- `--cache-file <path>`\n\n## Config\n\nCreate `impact.config.json` in target repo root:\n\n```json\n{\n  \"ignore\": [\"node_modules\", \".git\", \"tests\"],\n  \"extensions\": [\".js\", \".ts\", \".jsx\", \".tsx\"],\n  \"cache\": {\n    \"enabled\": true,\n    \"file\": \".impact-cache.json\"\n  },\n  \"policies\": {\n    \"criticalPaths\": [\"src/payments/**\", \"src/auth/**\"],\n    \"owners\": {\n      \"src/auth/**\": \"@security-team\",\n      \"src/**\": \"@app-team\"\n    },\n    \"ci\": {\n      \"failOnRisk\": \"HIGH\",\n      \"failOnCritical\": true\n    }\n  },\n  \"validation\": {\n    \"forecastsFile\": \".impact-forecasts.jsonl\",\n    \"metricsFile\": \".impact-validation.jsonl\"\n  }\n}\n```\n\n## Create Repo and Push\n\n```bash\ncd /home/anj/impact-analyzer\ngit init\ngit add .\ngit commit -m \"feat: production-ready code impact analyzer\"\ngit branch -M main\ngit remote add origin <YOUR_GITHUB_REPO_URL>\ngit push -u origin main\n```\n\n## Deployment\n\n### CI\n\n`/.github/workflows/ci.yml` runs:\n\n- dependency install\n- syntax check\n- smoke test\n- package dry-run\n\n### NPM Publish\n\n`/.github/workflows/publish-npm.yml` publishes on GitHub Release or manual dispatch.\n\nRequired GitHub repo secret:\n\n- `NPM_TOKEN` (from npm access token)\n\nOptional release flow:\n\n```bash\nnpm version patch\ngit push --follow-tags\n# create GitHub Release for the new tag\n```\n\n## Architecture\n\n- `src/cli`: command orchestration\n- `src/git`: git integration\n- `src/scanner`: file discovery\n- `src/resolution`: ts/js alias + workspace resolver\n- `src/parser`: AST-first dependency extraction\n- `src/cache`: incremental parse cache\n- `src/graph`: dependency and reverse graph\n- `src/analysis`: impact traversal + scoring\n- `src/policy`: ownership and CI policy evaluation\n- `src/metrics`: forecast validation metrics\n- `src/output`: CLI and JSON formatting\n\n## License\n\nMIT\n","readmeFilename":"README.md","_rev":"1-64a75e7872c6db929a6320de7f260001"}