Trace C# symbol usage with a Roslyn-backed index
Graphify C# helps agents map real C# usages, including overrides and implementations, from compiler-resolved project data.
- What they did
- A custom-built agent was set up with Graphify C#, a .NET global tool that can be run on a solution or project file. The tool reads the code through MSBuild, then asks Roslyn to resolve symbols and assemble a JSON graph of nodes and edges for calls, references, implements, inherits, and overrides. A companion skill file guides Codex or Claude Code on rebuilding the index and traversing those relationships, and an optional watcher can keep the data fresh.
- How it went
- In the README’s sample, an internal method turned up with only one caller that Roslyn could prove, and that caller was a test. That shows how test-only use can be uncovered. The tool does not account for reflection, dependency injection, or dynamic invocation, and it does not report any benchmark numbers.
- Tips
- A symbol with no inbound edges only has no observed static references, so treat deletion as a judgment call. The local machine still needs the right SDKs, packages, and MSBuild inputs available.
Try it yourself with Claude Code
I have a C# codebase at [path]. Build a usage graph for [symbol] using the compiler’s semantic information instead of text matching. Include callers, references, interface implementations, base-type links, and overrides, and show the file and line for each match grouped by project. Do not edit anything. If the index needs to be rebuilt or refreshed, do that first. Before any action that would delete, send, submit, or otherwise make a permanent change, stop and ask me to approve it. When you finish, explain briefly how you verified the matches were compiler-accurate.
Fill in the [brackets]. Agents can make mistakes, so review anything before it is sent, paid or deleted.
Get 3 agent uses like this every morning
With the day's top AI news. Free, and one click to unsubscribe.
Related agent uses
Re-check implementation against re-derived user goals
Have an agent reconstruct the user’s requirements from all messages, then audit the code and tests against that list before changing anything.
Turn tickets into code changes and draft the PR
Stripe uses in-house coding agents to carry tasks from ticket to reviewable code, then humans check the result.
Coordinate fix-and-review loops with a lead agent
A lead agent managed implementation and review between two subagents, only involving the human when a choice fell outside its authority or reviews kept failing.
Send blocked jobs to whichever model can handle them
A commenter used a shared policy file and SQL task board to move rejected tasks from a local model to another model.
Build an AArch64 JIT path for an emulator
An overnight agent swarm added AArch64 CPU support with JIT to kwemu.
Run QA agents to search your app for bugs
Give an agent your app and test rules, and let it probe flows, file reproducible bugs, and flag risky fixes for review.