Coldtea has released PR Lens, a tool that automatically generates animated architecture and data-flow diagrams for pull requests. The project addresses a growing pain point for developers working with AI coding agents: the inability to quickly understand complex, machine-generated diffs. Instead of parsing thousands of lines of code, developers can view a visual representation of the change, posted directly as a comment in the PR.

Visualizing the Blast Radius

PR Lens uses a custom renderer to create diagrams that highlight the specific components touched by a code change. The visual language is strict: green indicates new code, amber marks modifications, and red signals deletions. This 'architecture blast radius' view allows reviewers to see how a change interacts with the surrounding system, including the calls between components, without needing to trace every function manually.

Integration with Coding Agents

The tool is designed to work seamlessly with local coding agents. By installing the agent skill via npx skills add coldteadotai/pr-lens, agents can draw diagrams of their own changes before a pull request is even opened. This allows developers to review the agent's logic visually while the code is still being written. The agent validates its own diagram output against a schema, ensuring the visual representation matches the actual code diff.

Hall of Fame and Compatibility

To demonstrate its scalability, Coldtea processed historic pull requests from major open-source projects like React, Node.js, and Kubernetes. The tool successfully visualized massive changes, such as the introduction of React Hooks and the Node.js fetch implementation, maintaining clarity even with dozens of files and thousands of lines added. PR Lens supports GitHub, GitLab, and Bitbucket, with configuration options for CI/CD pipelines and local CLI usage.

Key Takeaways

  • PR Lens converts code diffs into animated data-flow and architecture diagrams automatically.
  • It integrates with coding agents, allowing them to visualize and validate their own changes.
  • The tool supports GitHub, GitLab, and Bitbucket, with MIT licensing for open-source use.
  • Visual cues (green, amber, red) instantly communicate new, changed, and removed code components.

The Bottom Line

If you're trusting AI agents to write code, you need to trust them to explain it. PR Lens bridges that gap by making the invisible logic of agent-generated diffs visible, interactive, and instantly understandable.