<?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: Taric</title>
    <description>The latest articles on DEV Community by Taric (@taricsa).</description>
    <link>https://dev.to/taricsa</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F437473%2Ff9efa37f-8fb4-4f4b-803c-e38ab7958f90.png</url>
      <title>DEV Community: Taric</title>
      <link>https://dev.to/taricsa</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/taricsa"/>
    <language>en</language>
    <item>
      <title>My code graph lost to grep: three benchmarks and what broke along the way</title>
      <dc:creator>Taric</dc:creator>
      <pubDate>Tue, 01 Dec 2026 14:31:00 +0000</pubDate>
      <link>https://dev.to/taricsa/my-code-graph-lost-to-grep-three-benchmarks-and-what-broke-along-the-way-bm5</link>
      <guid>https://dev.to/taricsa/my-code-graph-lost-to-grep-three-benchmarks-and-what-broke-along-the-way-bm5</guid>
      <description>&lt;p&gt;My code context tool lost to grep on its first benchmark. It needed 16,486 estimated tokens to answer eight questions about my Swift app. Grep, with commands written by someone who already knew the answers, needed 13,125.&lt;/p&gt;

&lt;p&gt;The tool is Synapse. I built it to cut the tokens my LLMs spent finding code, first when they reviewed my work and later when they wrote it. I tried Graphify first (version 0.9.45). On my Swift app, the savings were small, so I wrote my own. Synapse indexes a repository with tree-sitter, stores a code graph in an embedded database on your machine, and serves ranked context to an IDE or agent over the Model Context Protocol (MCP).&lt;/p&gt;

&lt;p&gt;Three benchmarks across ten repositories exposed flaws in the tool, flaws in my answer keys, and the limits of what I can claim.&lt;/p&gt;

&lt;p&gt;How I measured&lt;/p&gt;

&lt;p&gt;Every benchmark uses the same protocol.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Each question has a hand-written answer key. An answer is complete when the tool’s output includes every expected item.&lt;/li&gt;
&lt;li&gt;Each question is answered three ways: grep, git, and file reads; Graphify 0.9.45 in code-only mode with no LLM; and Synapse. The command sequence is fixed and runs the way an agent would. Failed attempts are kept, so they cost tokens too.&lt;/li&gt;
&lt;li&gt;Tokens are characters divided by 4, counted over each command and its full output. I used no tokenizer and no live agent, so every figure is an estimate, and repeat runs give byte-identical results.&lt;/li&gt;
&lt;li&gt;When a graph tool’s answer is incomplete, I add the grep cost, because an agent would still have to finish the job.&lt;/li&gt;
&lt;li&gt;I wrote the grep commands knowing the answer. They target the right file, the right line range, and the right git pipeline. That favors grep on targeting, though not always on output size, as the caller's question shows.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Everything ran on an Apple M5 Pro with 24 GB of RAM.&lt;/p&gt;

&lt;p&gt;My own mistakes are part of the result. The first version of the key for “which files are affected if the Temperature type changes” listed 21 files. Two of them mention Temperature only in doc comments, and grep had matched those. I cut the key to 19 files for every tool.&lt;/p&gt;

&lt;p&gt;Round 1: one Swift app, 8 questions&lt;/p&gt;

&lt;p&gt;The test repo is a private Swift and SwiftUI app with 134 Swift files and 358 commits. Results, as complete answers and estimated tokens to answer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;grep and git: 8 of 8, 13,125 tokens&lt;/li&gt;
&lt;li&gt;Graphify 0.9.45, code-only: 3 of 8, 14,724 tokens&lt;/li&gt;
&lt;li&gt;Synapse, first run: 3 of 8, 16,486 tokens&lt;/li&gt;
&lt;li&gt;Synapse, after the fixes: 7 of 8, 5,159 tokens&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The first run was bad for specific reasons. Synapse had no conformance edges, no type-usage edges, and no impact, dependency, or path queries. I added them and ran the same questions against the same keys. The questions were written before those fixes and did not change afterward, but the same person wrote the questions and the fixes.&lt;/p&gt;

&lt;p&gt;The result shows where a graph pays off and where it does not. Finding the callers of a function across files cost grep 5,713 tokens, because my command printed 30 lines of context around each match. Synapse needed 218. Finding a type’s dependencies cost grep 4,751 and Synapse 324. But grep was cheaper on three of the eight questions: which docs mention a name (17 tokens against 45), which files a type change affects (285 against 1,341), and the files that change with the most-changed file (138 against 549, using a well-built git log).&lt;/p&gt;

&lt;p&gt;Synapse also missed one question: what a function does and who calls it, because it has no type inference. A call through a property typed as a protocol stays unresolved when several types implement the method.&lt;/p&gt;

&lt;p&gt;Graphify answered three of eight at default settings. Its method names are not qualified by type, so lookups by name often failed and cost extra calls. In code-only mode, it skips docs and git history. Its doc answers require LLM extraction, which I didn't use. That is a limit of this setup, not of the tool.&lt;/p&gt;

&lt;p&gt;The first run was on commit 7438375 and the fixed run on commit bcdf410, both before the v0.5.0 release. The result was unchanged at 7 of 8 when I re-checked it on commit 99e6f00, which is included in v0.5.0.&lt;/p&gt;

&lt;p&gt;Round 2: 60 questions on 9 repos&lt;/p&gt;

&lt;p&gt;The Swift result was one repo in one language, so I widened the test: 60 questions across 9 private repos in JavaScript, TypeScript, React, Python, and Next.js. The question subjects came from fixed rules, the same in every repo, so none were hand-picked. For example, the caller's question uses the most-called unique function.&lt;/p&gt;

&lt;p&gt;Outside Swift, Synapse ranked last on completeness in its first run. Results, as complete answers and estimated tokens to answer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;grep and git: 60 of 60, 221,856 tokens&lt;/li&gt;
&lt;li&gt;Graphify 0.9.45, code-only: 32 of 60, 116,050 tokens&lt;/li&gt;
&lt;li&gt;Synapse, first run: 24 of 60, 135,196 tokens&lt;/li&gt;
&lt;li&gt;Synapse, after the fixes shipped in v0.5.0: 53 of 60, 21,848 tokens&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Read the grep figure with one caution. Callers' questions account for about 90% of it (198,800 of 221,856 tokens). In the Swift test, the grep callers command printed 30 lines of context around each match, and I have not checked whether the same holds here. I have not measured a plain-grep version in either test.&lt;/p&gt;

&lt;p&gt;The first run exposed three gaps. Type edges existed only for Swift, so Synapse answered 0 of 9 type-impact questions and 0 of 3 inheritance questions. It dropped calls made inside anonymous callbacks, such as Express route handlers, so it found complete caller lists in only 5 of 9 repos. And import edges pointed at unresolved placeholders, so it answered 0 of 9 file-dependency questions. It was strongest on docs (8 of 8) and git history (5 of 9), where Graphify in code-only mode answered none.&lt;/p&gt;

&lt;p&gt;I fixed all three and reran the same questions with the same keys. The fixes also cut indexing time: a faster git history walk took one repo from 17.35s to 4.05s, and the 8-service workspace from 49.6s to 22.8s.&lt;/p&gt;

&lt;p&gt;Seven questions are still incomplete:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Four co-change questions. This is by design: Synapse weights recent history (a 90-day half-life over the last 500 multi-file commits), and my key counts all non-merge history.&lt;/li&gt;
&lt;li&gt;One explain question, where one callee is a local helper defined inside the function.&lt;/li&gt;
&lt;li&gt;Two path questions, and these are my mistakes. My rule required only that the middle function’s file call the target. In both repos, the middle function itself doesn't, so the chain in my key doesn't exist. In one repo, Synapse’s answer of “no path” is correct. In the other, the real chain runs through a returned closure and a separate helper. I left the keys frozen, scored every tool against them, and recorded the errors on the benchmark page.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I also wrote these fixes after seeing these questions, so I still need to run a repo I didn't tune against. The first run was on commit bcdf410 and the fixed run on commit d94e09f. The 53 of 60 was unchanged when I re-checked on commit 99e6f00, which is included in v0.5.0.&lt;/p&gt;

&lt;p&gt;Round 3: questions across services&lt;/p&gt;

&lt;p&gt;Eight of the ten repos are services that call each other over HTTP. The answer keys came from the company’s service manifest, generated from Terraform, which lists which service calls which, by env var and path prefix. I asked eight questions, such as which services call one service’s API, and which repos are affected if its API changes.&lt;/p&gt;

&lt;p&gt;Neither graph tool could answer them. Grep, with the env var names known from the manifest, answered 8 of 8 for 557 tokens. Graphify answered 1 of 8. Its merge command combined the per-repo graphs and added no cross-repo edges. Indexing one folder that held all 8 repos produced 259 cross-repo edges, 155 of them between two services, and none of those 155 matched a real service call. They were name collisions: common method names, a script entry point named run(), class names that exist in two repos, and npm packages that two repos both declare. Synapse answered 0 of 8, because it linked repos only through OpenAPI, GraphQL, or Protobuf files, and none of these repos has one.&lt;/p&gt;

&lt;p&gt;So I built HTTP linking. Synapse now reads server routes (Express, Hono, FastAPI, Flask, and Next.js) and client calls (fetch, axios, got, ky, httpx, and requests, including calls through wrapper functions). It records each URL as a base plus a path and matches only the path. In the workspace’s synapse.yaml, each service can declare the env vars other services use to reach it, and an optional gateway prefix to strip. Without declarations, a call links only when exactly one other service has a unique match on at least two specific path segments. Ties are left unlinked, and so are calls that also match the caller’s own routes. I chose that rule because a wrong link is worse than a missing one.&lt;/p&gt;

&lt;p&gt;Results, as complete answers and estimated tokens to answer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;grep and git, env var names known: 8 of 8, 557 tokens&lt;/li&gt;
&lt;li&gt;Graphify 0.9.45, code-only, merged graphs: 1 of 8, 10,792 tokens.&lt;/li&gt;
&lt;li&gt;Synapse, first run: 0 of 8, not applicable&lt;/li&gt;
&lt;li&gt;Synapse, env vars declared in synapse.yaml: 8 of 8, 1,570 tokens.&lt;/li&gt;
&lt;li&gt;Synapse, nothing declared: 3 of 8, 1,437 tokens.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Read the two Synapse results together. The declared run used env var names and gateway prefixes taken from the same service manifest as the answer keys. So 8 of 8 shows what the tool does when it is configured correctly, not what it finds unaided. The inference-only run uses no declarations and gets 3 of 8. Grep is cheaper here because its commands already knew the env var names. Synapse’s use is finding links without that knowledge.&lt;/p&gt;

&lt;p&gt;On precision, a random sample of 30 of the 144 cross-repo endpoint links, each checked by reading the client and route code, was 30 of 30 correct at the route level. An earlier sample, during review, found one miss: a router imported by name whose mount was not followed. I fixed it before merging. The manifest lists 23 service calls, and 22 are visible in code. I found all 20 service pairs that call each other in code, with no extras.&lt;/p&gt;

&lt;p&gt;Recall is the weaker number. Of 1,154 client calls found, 161 are linked: 99 through a declared variable and 62 by inference. Most of the rest are calls to external APIs, tests calling their own service, or calls whose base or path is built in another file, but I have not measured that split. Pub/Sub and cron callers are not linked, and frontends that choose a service by a base key link only by inference.&lt;/p&gt;

&lt;p&gt;The first run was on commit bcdf410, and the HTTP linking runs on commit 99e6f00, which is included in v0.5.0. Repeated runs gave byte-identical results.&lt;/p&gt;

&lt;p&gt;What I did not measure&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No live agents. The command sequences are scripted, and a real agent might choose better or worse queries.&lt;/li&gt;
&lt;li&gt;No exact tokenizer. Every token figure is an estimate.&lt;/li&gt;
&lt;li&gt;All ten repos come from one company and share conventions.&lt;/li&gt;
&lt;li&gt;No runtime traces.&lt;/li&gt;
&lt;li&gt;Not independent. I wrote the questions, the answer keys, and the fixes. An independent task set would be a better test.&lt;/li&gt;
&lt;li&gt;The declared 8 of 8 in Round 3 uses the same manifest as the answer keys.&lt;/li&gt;
&lt;li&gt;Grep’s token cost includes generous context in at least one command, and I have not measured a plain-grep version.&lt;/li&gt;
&lt;li&gt;Go, Java, Kotlin, Ruby, PHP, C, C++, and C# are not benchmarked. Type edges exist only for Swift, JavaScript, TypeScript, and Python.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Held-out result&lt;/p&gt;

&lt;p&gt;This has not been done yet. It is next: the same fixed question rules, run on repos I did not tune against, ideally public ones so anyone can reproduce the numbers.&lt;/p&gt;

&lt;p&gt;Try it and tell me what breaks.&lt;/p&gt;

&lt;p&gt;Synapse v0.5.0 is a public beta, open source under Apache-2.0. Install it with brew install keelwright-hq/synapse/synapse, or go install github.com/keelwright-hq/synapse/cmd/&lt;a href="mailto:synapse@latest"&gt;synapse@latest&lt;/a&gt;. The repository is at &lt;a href="https://github.com/keelwright-hq/synapse" rel="noopener noreferrer"&gt;https://github.com/keelwright-hq/synapse&lt;/a&gt;, and a short video showing how it works is at &lt;a href="https://youtu.be/cndM2GSzFpc" rel="noopener noreferrer"&gt;https://youtu.be/cndM2GSzFpc&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I am looking for testers on real codebases, especially multi-repo ones and Go, Java, or C# repos. If it misses something or links to the wrong service, open an issue: &lt;a href="https://github.com/keelwright-hq/synapse/issues" rel="noopener noreferrer"&gt;https://github.com/keelwright-hq/synapse/issues&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;To rerun the protocol, the runner, the question types, and a small public fixture with synthetic tasks are here: &lt;a href="https://github.com/keelwright-hq/synapse/tree/main/bench/harness" rel="noopener noreferrer"&gt;https://github.com/keelwright-hq/synapse/tree/main/bench/harness&lt;/a&gt;. The numbers in this article came from private repos, so you can't reproduce them from that folder, and the cross-service round has no fixture yet. The task files for these private repos contain real names, so we haven't published them.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>opensource</category>
      <category>go</category>
      <category>programming</category>
    </item>
    <item>
      <title>Moving Repository from Bitbucket to GitHub</title>
      <dc:creator>Taric</dc:creator>
      <pubDate>Tue, 01 Jun 2021 04:00:16 +0000</pubDate>
      <link>https://dev.to/taricsa/moving-repository-from-bitbucket-to-github-34n9</link>
      <guid>https://dev.to/taricsa/moving-repository-from-bitbucket-to-github-34n9</guid>
      <description>&lt;p&gt;I’m working as a Volunteer in a new product/project, ProInstinct, and we needed to move our repositories from Bitbucket (private) to Github (private). Why did we need to move?&lt;/p&gt;

&lt;p&gt;Very simple, our team of volunteer developers has grown, and Bitbucket only allows five free members on the team. With the recent move by Github to allow free private repositories and unlimited members, the decision to change was straightforward.&lt;/p&gt;

&lt;p&gt;I was a bit uncertain about the sequence of git commands that I should perform without having any problem. After brief research and a few tests with a dummy repository (always test with dummy code first), I realize that it is relatively safe and comfortable.&lt;/p&gt;

&lt;p&gt;The first step to ensure that you do not lose all or part of your hard work is to merge all branches. You should have only one branch, master, to do this migration. Clone the repository to your hard drive.&lt;/p&gt;

&lt;p&gt;You probably already have your GitHub account, now create your new repository on Github, and save the URL, and follow these steps:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cd $repository&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git remote rename origin bitbucket&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git remote add origin https://github.com/{new repository}.git&lt;/code&gt;&lt;br&gt;
&lt;code&gt;git push origin master&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;This process can take a while; it will depend on the amount of file and size and your internet connection. Once the process is finished, check that your code is all in our repository. Once you are satisfied with sending to GitHub, you can delete the old remote by issuing:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;git remote rm bitbucket&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;I spent more time researching and studying how to transfer than doing. Do not forget the most sensitive part of this process are the branches; if you have several branches, the transfer will become more laborious.&lt;/p&gt;

&lt;p&gt;But for a single branch, it is straightforward in the end.&lt;/p&gt;

</description>
      <category>github</category>
      <category>bitbucket</category>
      <category>repository</category>
    </item>
  </channel>
</rss>
