<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: James Chahwan</title>
    <description>The latest articles on DEV Community by James Chahwan (@aessthesthethiccs).</description>
    <link>https://dev.to/aessthesthethiccs</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3876800%2F42df8439-cff5-4855-9b10-423cf270fec8.jpg</url>
      <title>DEV Community: James Chahwan</title>
      <link>https://dev.to/aessthesthethiccs</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/aessthesthethiccs"/>
    <language>en</language>
    <item>
      <title>Your LLM already thinks in graphs. Your codebase is a graph. Connect them.</title>
      <dc:creator>James Chahwan</dc:creator>
      <pubDate>Mon, 13 Apr 2026 14:44:48 +0000</pubDate>
      <link>https://dev.to/aessthesthethiccs/your-llm-already-thinks-in-graphs-your-codebase-is-a-graph-connect-them-28k1</link>
      <guid>https://dev.to/aessthesthethiccs/your-llm-already-thinks-in-graphs-your-codebase-is-a-graph-connect-them-28k1</guid>
      <description>&lt;p&gt;Your LLM already thinks in graphs. Your codebase is a graph. Connect them.                                                                                          &lt;/p&gt;

&lt;p&gt;Every time an LLM works on your code it burns most of its context figuring out where things are. Grep, read wrong file, grep again, read another wrong file.&lt;br&gt;&lt;br&gt;
  Eventually finds the bug. 80k tokens later.                                                                                                                         &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh1i6r56rf88595n30j2p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh1i6r56rf88595n30j2p.png" alt="Terminal showing repo-graph comparison: 75k tokens without vs 30k tokens with repo-graph for the same bug fix" width="800" height="48"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The fix is always in like 3 files. The other 12 were orientation.                                                                                                   &lt;/p&gt;

&lt;p&gt;Your codebase is already a graph. Functions call functions, routes point to handlers, services import services, frontend HTTP calls hit backend endpoints. The&lt;br&gt;&lt;br&gt;
  structure is right there.                                                           &lt;/p&gt;

&lt;p&gt;LLMs are neural networks. They process relationships between things. That's literally what they do.                                                                 &lt;/p&gt;

&lt;p&gt;But we make them grep through files like it's 2004. Read a file, hope it's relevant, read another one. No structure, no map, just vibes and keyword matching. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmhrniyptjmhypmple64w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmhrniyptjmhypmple64w.png" alt="repo-graph ASCII output showing GET /groups route connected to GetGroupsByClaimsHandler with tier labels" width="800" height="947"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;repo-graph scans your codebase once. Extracts the graph that already exists. Entities, relationships, feature flows. Serves it over MCP. Now the LLM traverses the&lt;br&gt;&lt;br&gt;
  structure instead of brute-forcing the filesystem.                                  &lt;/p&gt;

&lt;p&gt;Same bug fix on a Go + Angular monorepo. Same model, same prompt, fresh context, no hints.                                                                          &lt;/p&gt;

&lt;p&gt;Without repo-graph: 75,308 tokens. 4 minutes 36 seconds. About 15 files explored.                                                                                   &lt;/p&gt;

&lt;p&gt;With repo-graph: 29,838 tokens. 30 seconds. 2 files read.   &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmdathp7dqw3704y4czj3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmdathp7dqw3704y4czj3.png" alt="Comparison table showing 2.5x fewer tokens and 9x faster with repo-graph installed" width="780" height="237"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Without it greps for keywords, reads files, greps more, reads more, eventually narrows down. With it calls flow("groups"), gets the exact handler function and file,&lt;br&gt;
   reads it, fixes it.&lt;/p&gt;

&lt;p&gt;It extracts modules, functions, routes, services, components and how they connect. Auto-generates feature flows by tracing from route entry points through handler&lt;br&gt;&lt;br&gt;
  chains. Cross-stack linking matches frontend HTTP calls to backend routes automatically.                                                                          &lt;/p&gt;

&lt;p&gt;13 languages out of the box. Regex heuristics, not AST. No build step. One dependency. Adding a new language is one file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  pip &lt;span class="nb"&gt;install &lt;/span&gt;mcp-repo-graph
  repo-graph-init &lt;span class="nt"&gt;--repo&lt;/span&gt; /path/to/your/project
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Code is a graph. LLMs process graphs. repo-graph connects the two. A few hundred tokens to query the structure vs thousands to explore the filesystem.              &lt;/p&gt;

</description>
      <category>mcp</category>
      <category>ai</category>
      <category>devtools</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
