<?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: shashank budem</title>
    <description>The latest articles on DEV Community by shashank budem (@shashank_budem_83f714ee61).</description>
    <link>https://dev.to/shashank_budem_83f714ee61</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%2F4196860%2F4ea3ff30-4271-473b-9a17-d60998f538c4.png</url>
      <title>DEV Community: shashank budem</title>
      <link>https://dev.to/shashank_budem_83f714ee61</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/shashank_budem_83f714ee61"/>
    <language>en</language>
    <item>
      <title>Code Déjà Vu: a git hook that remembers the code I forgot I wrote</title>
      <dc:creator>shashank budem</dc:creator>
      <pubDate>Tue, 20 Oct 2026 23:18:56 +0000</pubDate>
      <link>https://dev.to/shashank_budem_83f714ee61/code-deja-vu-a-git-hook-that-remembers-the-code-i-forgot-i-wrote-395e</link>
      <guid>https://dev.to/shashank_budem_83f714ee61/code-deja-vu-a-git-hook-that-remembers-the-code-i-forgot-i-wrote-395e</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/hacktoberfest-week3-2026-10-19"&gt;Hacktoberfest Open-Source AI Challenge Week 3: Slow and Steady&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;I have written the same byte-size formatter four times. Same project, four files: two functions called &lt;code&gt;formatBytes&lt;/code&gt;, a &lt;code&gt;formatByteSize&lt;/code&gt; that rounds megabytes to one decimal, and a &lt;code&gt;formatPreviewBytes&lt;/code&gt; that is character-for-character one of the &lt;code&gt;formatBytes&lt;/code&gt;, renamed. I found this out this week. It is not the worst thing I found.&lt;/p&gt;

&lt;p&gt;So for Sloth Week I built the laziest tool I could think of: one that makes me write &lt;em&gt;less&lt;/em&gt; code by remembering what I already wrote.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Built
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Code Déjà Vu&lt;/strong&gt; is a git pre-commit hook. When you commit a function that already exists somewhere in your repos (any repo, any name, copied or rewritten from scratch), it tells you before the duplicate lands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"add helpers"&lt;/span&gt;
déjà vu: humanFileSize &lt;span class="o"&gt;(&lt;/span&gt;src/files.ts:1&lt;span class="o"&gt;)&lt;/span&gt;
   already &lt;span class="k"&gt;in &lt;/span&gt;arivu-agent/src/tools/registry.ts:1567 as formatByteSize &lt;span class="o"&gt;(&lt;/span&gt;similarity 0.96&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;It also lets you find your own code by describing it, because I never remember what I named things:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$ dejavu search "sort states by an indicator, lower is better"
0.88  ranked                     Bharath Choropleth/examples/observatory/react/src/App.tsx:109
0.85  ranked                     Bharath Choropleth/examples/observatory/js/app.js:75
0.79  trend                      Bharath Choropleth/examples/soc-dashboard/src/feeds.ts:260
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;(Yes, that's the same function in two example apps. It finds my duplicates even when I'm only searching.)&lt;/p&gt;

&lt;p&gt;Everything runs on my laptop with &lt;strong&gt;EmbeddingGemma 2&lt;/strong&gt;, an open-weight embedding model. No code leaves the machine, it works offline, and it costs nothing per commit.&lt;/p&gt;

&lt;p&gt;The hook never blocks a commit. It warns and gets out of the way. A hook that blocks you once is a hook you uninstall.&lt;/p&gt;
&lt;h2&gt;
  
  
  Demo
&lt;/h2&gt;

&lt;p&gt;A fresh scratch repo with the hook installed. I commit three small helpers: a file-size formatter, an abort-signal forwarder, and a leap-year check.&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;dejavu install-hook
installed …/dejavu-demo/.git/hooks/pre-commit

&lt;span class="nv"&gt;$ &lt;/span&gt;git add src
&lt;span class="nv"&gt;$ DEJAVU_SECOND_OPINION&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;1 &lt;span class="nv"&gt;DEJAVU_DECIDER_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;http://127.0.0.1:11435 git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"add helpers"&lt;/span&gt;
déjà vu: forwardCancellation &lt;span class="o"&gt;(&lt;/span&gt;src/abort.ts:1&lt;span class="o"&gt;)&lt;/span&gt;
   already &lt;span class="k"&gt;in &lt;/span&gt;arivu-agent/src/agent/OpenAICompatibleChatClient.ts:979 as linkAbortSignal &lt;span class="o"&gt;(&lt;/span&gt;similarity 0.93, second opinion 97% same&lt;span class="o"&gt;)&lt;/span&gt;
déjà vu: humanFileSize &lt;span class="o"&gt;(&lt;/span&gt;src/files.ts:1&lt;span class="o"&gt;)&lt;/span&gt;
   already &lt;span class="k"&gt;in &lt;/span&gt;arivu-agent/src/tools/registry.ts:1567 as formatByteSize &lt;span class="o"&gt;(&lt;/span&gt;similarity 0.96&lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;[&lt;/span&gt;main 7db292a] add helpers
 3 files changed, 24 insertions&lt;span class="o"&gt;(&lt;/span&gt;+&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;humanFileSize&lt;/code&gt; would have been my fifth byte formatter. Caught with similarity alone.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;forwardCancellation&lt;/code&gt; is a from-scratch rewrite of a helper in my coding agent, Arivu. Similarity alone only rated it a "similar" hint (0.93). I'd switched on the optional second opinion (the env vars point it at a local Ollama running Perplexity's decision model), and that upgraded it. This commit took about 5 s because Ollama had to load the model first; warm, a check is well under a second.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;isLeapYear&lt;/code&gt; really was new, so the hook stayed quiet.&lt;/li&gt;
&lt;li&gt;The commit still went through. Warnings never block.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Then the boring commits, which matter just as much for a hook you leave on forever:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$ &lt;/span&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"docs"&lt;/span&gt;              &lt;span class="c"&gt;# docs only: 0.20 s, silent&lt;/span&gt;
&lt;span class="nv"&gt;$ &lt;/span&gt;git commit &lt;span class="nt"&gt;-m&lt;/span&gt; &lt;span class="s2"&gt;"tweak isLeapYear"&lt;/span&gt;  &lt;span class="c"&gt;# edited an existing function: 0.38 s, silent (no self-match)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h2&gt;
  
  
  Code
&lt;/h2&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://assets.dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/shashankbudem" rel="noopener noreferrer"&gt;
        shashankbudem
      &lt;/a&gt; / &lt;a href="https://github.com/shashankbudem/code-dejavu" rel="noopener noreferrer"&gt;
        code-dejavu
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      A git pre-commit hook that warns when the function you're committing already exists in your repos. Runs locally on EmbeddingGemma 2.
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Code Déjà Vu&lt;/h1&gt;
&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;The laziest code is code you've already written.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Code Déjà Vu is a git pre-commit hook that notices when the function you're about to commit already exists somewhere in
your repos, under any name, in any of them. It also lets you find your own code by describing it. Everything runs on your
laptop with &lt;a href="https://huggingface.co/google/embeddinggemma-2" rel="nofollow noopener noreferrer"&gt;EmbeddingGemma 2&lt;/a&gt;, an open-weight model. Your code never
leaves the machine.&lt;/p&gt;
&lt;p&gt;With the optional second opinion switched on (see below):&lt;/p&gt;
&lt;div class="snippet-clipboard-content notranslate position-relative overflow-auto"&gt;&lt;pre class="notranslate"&gt;&lt;code&gt;$ DEJAVU_SECOND_OPINION=1 DEJAVU_DECIDER_URL=http://127.0.0.1:11435 git commit -m "add helpers"
déjà vu: forwardCancellation (src/abort.ts:1)
   already in arivu-agent/src/agent/OpenAICompatibleChatClient.ts:979 as linkAbortSignal (similarity 0.93, second opinion 97% same)
déjà vu: humanFileSize (src/files.ts:1)
   already in arivu-agent/src/tools/registry.ts:1567 as formatByteSize (similarity 0.96)
[main 7db292a] add helpers
 3 files changed, 24 insertions(+)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
&lt;p&gt;Without the second opinion, &lt;code&gt;forwardCancellation&lt;/code&gt; (a from-scratch rewrite) shows as a gentler &lt;code&gt;similar:&lt;/code&gt; hint at 0.93
instead. The third new function in that commit, &lt;code&gt;isLeapYear&lt;/code&gt;, really was…&lt;/p&gt;&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/shashankbudem/code-dejavu" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;About 400 lines of Python for the tool itself, plus the evaluation scripts I used to tune it (&lt;code&gt;eval/&lt;/code&gt;).&lt;/p&gt;

&lt;h2&gt;
  
  
  How I Built It
&lt;/h2&gt;

&lt;p&gt;I built this with Claude Code as my pair programmer: I made the calls (what to build, which models to try, what to keep and what to cut), and the agent did most of the typing, the labelling and the benchmark runs.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Find every function.&lt;/strong&gt; tree-sitter parses TypeScript, JavaScript, Python and Rust and pulls out every function of five or more lines. Across 10 of my repos that was &lt;strong&gt;5,094 functions&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Catch exact copies without any AI.&lt;/strong&gt; Each function body gets fingerprinted with comments and whitespace stripped. &lt;strong&gt;2,451 of my 5,094 functions were verbatim copies&lt;/strong&gt; of another one, mostly from forking my coding-agent project into experiments. A hash catches all of them instantly, so the model never has to.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Catch near-copies and rewrites with EmbeddingGemma 2.&lt;/strong&gt; New or changed functions are embedded and compared with the index of everything else. Two details mattered:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Matryoshka dimensions.&lt;/strong&gt; EmbeddingGemma 2 is trained so the first 256 of its 768 numbers still work on their own. The index is a third of the size, and it did slightly &lt;em&gt;better&lt;/em&gt; on my duplicate test than the full vector.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Task prompts.&lt;/strong&gt; The same model embeds code for duplicate checks (&lt;code&gt;task: sentence similarity&lt;/code&gt;) and for search (&lt;code&gt;task: code retrieval&lt;/code&gt;). For duplicates, the similarity prompt clearly beat a document-style prompt in my tests.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Similarity of 0.946 or above is a &lt;strong&gt;déjà vu&lt;/strong&gt; warning. Between 0.91 and 0.946 is a gentler &lt;strong&gt;similar&lt;/strong&gt; hint.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Check only what changed.&lt;/strong&gt; Functions whose fingerprint is unchanged since the last commit, including moved ones, are skipped. The files being committed are excluded from the comparison, so editing a function never matches its own old version. A docs-only commit never even loads the model.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Stay out of the way.&lt;/strong&gt; Importing PyTorch and loading the model takes about 13 seconds, which is fine once but terrible on every commit. So &lt;code&gt;dejavu serve&lt;/code&gt; keeps the model warm in the background (local only). With it running, checking a commit takes about 0.3 s and a search about 0.2 s. Without it, everything still works, just slower.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why EmbeddingGemma 2
&lt;/h3&gt;

&lt;p&gt;I didn't pick it on vibes. I pulled the official MTEB results for six open embedding models on the same 12 code tasks. On the task that matters here, finding code that does the same thing as other code, &lt;strong&gt;EmbeddingGemma 2 scored 96.6, the best of all six&lt;/strong&gt;, ahead of models 13× its size (Qwen3-Embedding 4B: 95.6, Perplexity's pplx-embed 4B: 92.3). It's also small enough to index thousands of functions on a fanless MacBook Air.&lt;/p&gt;

&lt;h3&gt;
  
  
  How I tuned it: on my own mess
&lt;/h3&gt;

&lt;p&gt;Pairs from my own repos were labelled by hand (well, by my agent's hand: it read each pair in full before labelling it):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What&lt;/th&gt;
&lt;th&gt;Result&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;19 copies that drifted apart&lt;/td&gt;
&lt;td&gt;18 warnings, 1 hint&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;9 from-scratch rewrites&lt;/td&gt;
&lt;td&gt;5 warnings, 4 hints; a function doing the same job ranked &lt;strong&gt;first 9/9 times&lt;/strong&gt; out of 2,643&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;25 look-alikes that do different things&lt;/td&gt;
&lt;td&gt;2 false warnings, 11 hints&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Simulated hook over 381 functions from my standalone repos&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;1 warning, and it was real&lt;/strong&gt;: &lt;code&gt;escapeHtml&lt;/code&gt;, written separately in two different projects&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;22 "describe it" searches&lt;/td&gt;
&lt;td&gt;right function first 18–19 times; keyword matching (grep-style): 2&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Honest caveats: the cutoffs were picked on the same small set they're scored on, the rewrites were written while looking at the originals, and every repo is mine. It's a careful first measurement, not a benchmark.&lt;/p&gt;

&lt;h3&gt;
  
  
  The judge bake-off (and why the embedding won)
&lt;/h3&gt;

&lt;p&gt;Similarity scores get fuzzy in the 0.91–0.95 range, where a real rewrite and a look-alike can score the same. So I asked: would a second model, a "judge" that answers &lt;em&gt;"are these the same function?"&lt;/em&gt;, do better?&lt;/p&gt;

&lt;p&gt;I tested four open models as judges on the same 113 pairs. &lt;strong&gt;The keep rule was written down before the new ones ran&lt;/strong&gt;, so nobody could move the goalposts afterwards.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Judge&lt;/th&gt;
&lt;th&gt;Borderline cases (0.5 = coin flip)&lt;/th&gt;
&lt;th&gt;Calls random pairs "the same"&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;EmbeddingGemma 2 alone&lt;/td&gt;
&lt;td&gt;0.72&lt;/td&gt;
&lt;td&gt;—&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Laya (decision model)&lt;/td&gt;
&lt;td&gt;0.40&lt;/td&gt;
&lt;td&gt;98%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;CoREB (code-search reranker)&lt;/td&gt;
&lt;td&gt;0.41&lt;/td&gt;
&lt;td&gt;0%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Clef Flash (Cloudflare decision model)&lt;/td&gt;
&lt;td&gt;0.85&lt;/td&gt;
&lt;td&gt;0%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;strong&gt;pplx-decider-flash&lt;/strong&gt; (Perplexity decision model)&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;0.98&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;0%&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The borderline column rests on just 25 pairs, so its error bars are wide (the embedding's 95% range is 0.49–0.92). Read it as a direction, not a leaderboard.&lt;/p&gt;

&lt;p&gt;None passed the keep rule. Two things surprised me:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Decision models answer exactly the question you ask.&lt;/strong&gt; pplx-decider-flash was brilliant at the borderline cases, but asked &lt;em&gt;"do these implement the same behaviour?"&lt;/em&gt;, it said &lt;strong&gt;no&lt;/strong&gt; to a copy that had gained two extra options. Used as a veto, it threw away 13 of 19 real copies. Fair: they &lt;em&gt;don't&lt;/em&gt; do exactly the same thing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Always sanity-check a judge first.&lt;/strong&gt; Before each full run, I fed every judge an identical pair and an unrelated pair. CoREB said &lt;code&gt;add(a, b)&lt;/code&gt; and an unrelated config reader were &lt;strong&gt;99.8% the same&lt;/strong&gt;. The cause was its model card: the example prompt leaves out an empty &lt;code&gt;&amp;lt;think&amp;gt;&amp;lt;/think&amp;gt;&lt;/code&gt; block its base model expects. One missing line, and every answer was "yes".&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;pplx-decider-flash still earned a job: an &lt;strong&gt;optional second opinion that can only upgrade&lt;/strong&gt; a borderline hint to a warning, never cancel one. In that role it upgraded all 4 hinted rewrites. Its one false upgrade was a test mock, and the tool doesn't index test files. (I designed that rule &lt;em&gt;after&lt;/em&gt; seeing the bake-off, so treat it as promising, not proven.) Running it through Ollama's new MLX runner at 8-bit gave the same answers as the original on 113/113 pairs, about 3× faster.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Does Open Innovation Matter?
&lt;/h2&gt;

&lt;p&gt;For this tool it isn't a nice-to-have. It's the whole thing.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;My code can't leave my laptop.&lt;/strong&gt; Lots of developers can't send their employer's code, or their private repos, to a cloud API just to ask "have I written this before?". A local model can read all of it, offline, on every commit.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It's free to run constantly.&lt;/strong&gt; A hook runs on every commit, forever. Per-call pricing would turn "check every function" into "check sometimes".&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;I could test instead of trust.&lt;/strong&gt; Open weights let me run four judges on my own labelled code, catch a model-card bug, and verify that an 8-bit MLX build answers like the original. With a closed API, I'd have had to take the vendor's word for all of it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;I could swap pieces freely.&lt;/strong&gt; Embedder, judge and runtime (PyTorch, then Ollama MLX) all changed during the week, and nothing else had to.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Lazy Payoff
&lt;/h2&gt;

&lt;p&gt;The first run over my own 10 repos turned up:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Four byte-size formatters&lt;/strong&gt; inside Arivu alone, one of them an identical copy under a new name.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;escapeHtml&lt;/code&gt; written twice&lt;/strong&gt;, separately, in two unrelated projects.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The same &lt;code&gt;ranked()&lt;/code&gt; helper&lt;/strong&gt; in both the React and plain-JS versions of my Bharat Choropleth examples.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;2,451 verbatim copies&lt;/strong&gt; in total, mostly between my coding agent and its experimental forks.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Not all of them are mistakes: the forks and the standalone example apps are copies on purpose. But four byte formatters in one project definitely were, and each of those is a function I wrote, tested and now maintain more than once.&lt;/p&gt;

&lt;p&gt;And the cost of being lazy this way:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What&lt;/th&gt;
&lt;th&gt;Time&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Indexing 4,782 functions, once&lt;/td&gt;
&lt;td&gt;~11 min on a fanless MacBook Air (later runs only embed new code)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Commit that adds functions, model warm&lt;/td&gt;
&lt;td&gt;~0.3 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Docs-only commit&lt;/td&gt;
&lt;td&gt;~0.2 s&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Search&lt;/td&gt;
&lt;td&gt;~0.2 s&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h2&gt;
  
  
  Prize Categories
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Best Use of Gemma&lt;/strong&gt;: EmbeddingGemma 2 runs locally and does all the work: duplicate detection, search, and the Matryoshka-shrunk index.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>devchallenge</category>
      <category>hf26challenge</category>
      <category>opensource</category>
      <category>ai</category>
    </item>
  </channel>
</rss>
