Visualize every PR as a 3D dependency graph. See blast radius, trace imports, and understand the impact of changes — automatically.
Free for open source. No account required.
Add this to .github/workflows/codelayers.yml — that's it:
name: CodeLayers
on:
pull_request:
jobs:
visualize:
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: codelayers-ai/codelayers-action@v1No API key. No sign-up. Every PR gets a comment with an interactive 3D visualization link.
For private repositories, add an API key:
- uses: codelayers-ai/codelayers-action@v1
with:
api_key: ${{ secrets.CODELAYERS_API_KEY }}How to get an API key
brew install codelayers-ai/tap/codelayers
codelayers login
codelayers api-keys create "GitHub CI"Add the key as a repository secret named CODELAYERS_API_KEY. Requires a CodeLayers Pro subscription.
Every PR comment includes a link to an interactive 3D visualization:
- Blast radius — changed files in red, affected dependencies in orange/yellow gradient by distance
- Dependency graph — click any file to see its imports and dependents
- Code metrics — LOC, complexity, and entry points per file
- Language breakdown — top languages in the codebase at a glance
Open source repos get a public explore link. Private repos get a zero-knowledge encrypted link (code is encrypted client-side, the server never sees it).
| Input | Required | Default | Description |
|---|---|---|---|
api_key |
No | API key for private repos. Not needed for public repos. | |
base_branch |
No | auto-detect | Base branch to compare against |
expires_days |
No | 7 |
Days until visualization link expires |
max_views |
No | unlimited | Maximum number of views (private repos only) |
comment |
No | true |
Post/update PR comment |
link_to_pr |
No | true |
Link visualization to GitHub repo/PR metadata |
| Output | Description |
|---|---|
share_url |
Visualization URL |
share_id |
Share/explore ID (UUID) |
node_count |
Number of nodes in the graph |
file_count |
Number of files in the graph |
changed_file_count |
Number of files changed in the PR |
blast_radius_count |
Total files affected by changes (via dependency graph) |
- Parses your codebase with tree-sitter (10 languages)
- Builds a dependency graph (functions, classes, imports, calls)
- Computes blast radius from PR changes
- Posts a comment with the visualization link
For private repos, code is encrypted client-side with a random key. The key lives in the URL fragment and is never sent to the server.
- uses: codelayers-ai/codelayers-action@v1
id: codelayers
- name: Custom comment
run: |
echo "Share URL: ${{ steps.codelayers.outputs.share_url }}"
echo "Changed files: ${{ steps.codelayers.outputs.changed_file_count }}"
echo "Blast radius: ${{ steps.codelayers.outputs.blast_radius_count }}"Rust, TypeScript/JavaScript, Python, Java, Go, C++, C#, Ruby, PHP, Swift