Compute blast radius — what breaks if a given file or function changes. Uses reverse-reachability BFS on call graph and dependency graph, enriched with LLM-powered domain classification to detect cross-domain impact.
Three usage modes:
With diff — upload a unified diff (git diff output) alongside the repo zip.
Changed files are automatically extracted as targets. Best for CI/CD pipelines.
With targets — specify files or file:function pairs via query parameter. Best for ad-hoc analysis of specific functions.
Neither — analyzes the entire codebase and returns a global coupling/risk map with the most critical files ranked by dependent count.
CI Integration (GitHub Actions):
run: |
git diff origin/main...HEAD > changes.diff
git archive --format=zip HEAD -o repo.zip
curl -s -X POST "$SUPERMODEL_API_URL/v1/analysis/impact" \
-H "Idempotency-Key: ${{ github.run_id }}-impact" \
-H "X-Api-Key: ${{ secrets.SUPERMODEL_API_KEY }}" \
-F "[email protected];type=application/zip" \
-F "[email protected];type=text/plain" \
-o impact.json
CI Integration (GitLab CI):
script:
- git diff origin/main...HEAD > changes.diff
- git archive --format=zip HEAD -o repo.zip
- >-
curl -s -X POST "$SUPERMODEL_API_URL/v1/analysis/impact"
-H "Idempotency-Key: $CI_PIPELINE_IID-impact"
-H "X-Api-Key: $SUPERMODEL_API_KEY"
-F "[email protected];type=application/zip"
-F "[email protected];type=text/plain"
-o impact.json
Standalone usage (no CI):
-H 'Idempotency-Key: my-key' -H 'X-Api-Key: ...' \
-F '[email protected];type=application/zip'
# Analyze from a diff git diff main > changes.diff && git archive --format=zip HEAD -o repo.zip curl -X POST '.../v1/analysis/impact' \
-H 'Idempotency-Key: my-key' -H 'X-Api-Key: ...' \
-F '[email protected];type=application/zip' \
-F '[email protected];type=text/plain'
# Global coupling map (no targets, no diff) curl -X POST '.../v1/analysis/impact' \
-H 'Idempotency-Key: my-key' -H 'X-Api-Key: ...' \
-F '[email protected];type=application/zip'
API key issued by the control plane for accessing data plane resources.
Unique identifier for this request for idempotency and tracing.
Comma-separated list of file paths or file:functionName pairs to analyze. If omitted, analyzes all files and returns a global coupling/risk map. Examples: 'src/services/billing.ts', 'src/services/billing.ts:calculateTotal,src/auth/login.ts'.
Zipped repository archive containing the code to analyze.
Optional unified diff (output of git diff). When provided, changed files are automatically extracted and used as analysis targets. This is the recommended input for CI/CD pipelines. If both diff and targets are provided, the targets from both are merged.
Impact analysis (job completed)
Async response envelope for impact analysis operations.
Current status of the job.
pending, processing, completed, failed Unique identifier for the job.
Recommended seconds to wait before polling again.
Error message (present when status is failed).
The result (present when status is completed).