<?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>Forem: Praveen</title>
    <description>The latest articles on Forem by Praveen (@pn_28428886923dfc665).</description>
    <link>https://forem.com/pn_28428886923dfc665</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%2F3940098%2F8a7a4942-5b0d-4847-9a7a-2eaf76d0ce30.png</url>
      <title>Forem: Praveen</title>
      <link>https://forem.com/pn_28428886923dfc665</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/pn_28428886923dfc665"/>
    <language>en</language>
    <item>
      <title>Why AI provenance tools fail when their layers disagree</title>
      <dc:creator>Praveen</dc:creator>
      <pubDate>Sun, 24 May 2026 05:05:12 +0000</pubDate>
      <link>https://forem.com/pn_28428886923dfc665/why-ai-provenance-tools-fail-when-their-layers-disagree-306j</link>
      <guid>https://forem.com/pn_28428886923dfc665/why-ai-provenance-tools-fail-when-their-layers-disagree-306j</guid>
      <description>&lt;p&gt;Most people think the hard part of an AI provenance tool is capturing the prompt or parsing the model output. That is only the first layer of the problem. The more serious failure appears after the system has multiple moving parts: an editor extension, a backend, and an assistant-facing API all trying to describe the same event.&lt;/p&gt;

&lt;p&gt;That is where trust starts to break.&lt;/p&gt;

&lt;p&gt;A provenance system is supposed to answer a simple question: what happened to this change, and how did it get here? But once the extension, backend, and MCP server all participate in that answer, any mismatch in response shape, error handling, or mode-specific behavior becomes user-visible. A redirect that is helpful during setup can become opaque during login. A workspace response that is technically correct can still be formatted incorrectly for the MCP layer. A Lite-only feature gate can look like an authentication failure if the error mapping is too generic. None of those are parsing bugs. They are consistency bugs.&lt;/p&gt;

&lt;p&gt;This is why contract drift matters so much in AI infrastructure tools. The system is not just moving data. It is narrating reality across surfaces. If one surface says “setup needed,” another says “login failed,” and a third says “feature unavailable,” the user no longer knows which layer to believe.&lt;/p&gt;

&lt;p&gt;In LineageLens, the recent fixes were all about reducing that kind of ambiguity. Fresh installs now get a real auth response instead of an opaque redirect. The MCP server matches the workspace response shape that the backend actually returns. Lite-mode 403s surface the backend’s upgrade message instead of a misleading auth template. Ingest warnings and duplicate storage status now reach the user instead of disappearing silently. Even the token lifecycle became more robust by supporting refresh before falling back to password re-login.&lt;/p&gt;

&lt;p&gt;That is the practical lesson: once a product spans multiple clients, you need contract discipline at the boundaries. Not just tests for the core logic, but tests for the truth that each layer tells the next one.&lt;/p&gt;

&lt;p&gt;For AI provenance tools, that truth is the product. If the extension, backend, and MCP server disagree, the audit trail becomes noisy instead of useful. And if the audit trail is noisy, the whole category loses value.&lt;/p&gt;

&lt;p&gt;The fix is not glamorous. It is boundary work: stable payloads, mode-aware errors, better token handling, and fewer assumptions about what another layer “probably meant.” But that is exactly the kind of work that makes a provenance system trustworthy.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>devops</category>
      <category>opensource</category>
      <category>security</category>
    </item>
    <item>
      <title>Title: LineageLens: A "Git Blame" for AI-Generated Code</title>
      <dc:creator>Praveen</dc:creator>
      <pubDate>Sat, 23 May 2026 05:58:45 +0000</pubDate>
      <link>https://forem.com/pn_28428886923dfc665/title-lineagelens-a-git-blame-for-ai-generated-code-1lod</link>
      <guid>https://forem.com/pn_28428886923dfc665/title-lineagelens-a-git-blame-for-ai-generated-code-1lod</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/github-2026-05-21"&gt;GitHub Finish-Up-A-Thon Challenge&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

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

&lt;p&gt;When an engineer uses an AI agent in the terminal to write or refactor code, git simply records the engineer as the author. The context of &lt;em&gt;which prompt&lt;/em&gt; generated it, &lt;em&gt;which model&lt;/em&gt; was used, and &lt;em&gt;how many iterations&lt;/em&gt; it took is completely lost the moment the terminal session ends. &lt;/p&gt;

&lt;p&gt;I built &lt;strong&gt;LineageLens&lt;/strong&gt; to fix this. It is an open-source, self-hosted proxy (running on port 8788) that intercepts AI dev tool traffic. It parses the native AI tool calls and logs the exact prompt, model, and applied edit to a local database, creating a searchable audit trail and dashboard for AI-generated code.&lt;/p&gt;

&lt;h2&gt;
  
  
  Demo
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;GitHub Repository:&lt;/strong&gt; &lt;a href="https://github.com/karnati-praveen/lineagelens" rel="noopener noreferrer"&gt;karnati-praveen/lineagelens&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;VS Code Extension:&lt;/strong&gt; &lt;a href="https://marketplace.visualstudio.com/items?itemName=karnatipraveen.lineagelens" rel="noopener noreferrer"&gt;LineageLens Marketplace&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The Comeback Story
&lt;/h2&gt;

&lt;p&gt;The initial prototype of LineageLens was a massive headache. It relied heavily on brittle regex text-scraping to pull code blocks out of standard LLM markdown responses. It broke constantly, and the project stalled because it couldn't tell if a developer actually &lt;em&gt;accepted&lt;/em&gt; the AI's suggestion or rejected it.&lt;/p&gt;

&lt;p&gt;For this challenge, I completely ripped out the regex engine and started over. I built native protocol adapters that parse Anthropic’s &lt;code&gt;tool_use&lt;/code&gt; blocks and OpenAI’s &lt;code&gt;apply_patch&lt;/code&gt; DSL directly from the API streams. More importantly, I introduced a state machine. It now correlates an AI's &lt;em&gt;proposed&lt;/em&gt; edit with the next turn's &lt;code&gt;tool_result&lt;/code&gt; to definitively track if the code was &lt;strong&gt;applied, rejected, or errored&lt;/strong&gt;. It transformed the project from a noisy text logger into a highly accurate governance tool.&lt;/p&gt;

&lt;h2&gt;
  
  
  My Experience with GitHub Copilot
&lt;/h2&gt;

&lt;p&gt;Rebuilding the core engine required handling complex, fragmented Server-Sent Events (SSE) and assembling streaming JSON payloads for the tool calls. GitHub Copilot was instrumental in accelerating this refactor. It helped quickly scaffold the FastAPI endpoints, write the tedious string-parsing logic for the proxy stream interception, and auto-complete the SQLAlchemy models needed for the new state-machine database architecture. It turned weeks of manual API debugging into just a few days of rapid implementation.&lt;/p&gt;

</description>
      <category>devchallenge</category>
      <category>githubchallenge</category>
      <category>ai</category>
      <category>opensource</category>
    </item>
    <item>
      <title>The "Ghost in the Repo": Why AI Agents break Git Blame</title>
      <dc:creator>Praveen</dc:creator>
      <pubDate>Fri, 22 May 2026 04:48:23 +0000</pubDate>
      <link>https://forem.com/pn_28428886923dfc665/the-ghost-in-the-repo-why-ai-agents-break-git-blame-3e6o</link>
      <guid>https://forem.com/pn_28428886923dfc665/the-ghost-in-the-repo-why-ai-agents-break-git-blame-3e6o</guid>
      <description>&lt;p&gt;For the last 15 years, &lt;code&gt;git blame&lt;/code&gt; has been the ultimate source of truth for software engineering. If a production bug surfaces, or a security auditor asks why a specific database query was written a certain way, &lt;code&gt;git blame&lt;/code&gt; tells you exactly who to ask.&lt;/p&gt;

&lt;p&gt;With the rapid adoption of agentic CLI tools like Claude Code, OpenAI Codex, and Aider, that source of truth is silently breaking.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Context Collapse
&lt;/h3&gt;

&lt;p&gt;When you use an AI agent to write code, the workflow looks like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;You open the terminal and type: &lt;em&gt;"Add a JWT verification middleware, skip checking the expiration for now."&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;The AI uses a tool (like Anthropic's &lt;code&gt;tool_use&lt;/code&gt; or OpenAI's &lt;code&gt;apply_patch&lt;/code&gt;) to edit &lt;code&gt;auth.py&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;You review the diff in your terminal, hit 'y' to accept, and commit the code.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Here is the problem: &lt;strong&gt;Git only records Step 3.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The most critical piece of context—the intent (&lt;em&gt;"skip checking the expiration"&lt;/em&gt;), the model used (&lt;em&gt;claude-3-5-sonnet&lt;/em&gt;), and the fact that an AI generated it—evaporates the moment you close the terminal. We are filling our repositories with "Ghosts"—code that looks like it was written by a human, but lacks any human architectural intent.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why this is a Security Nightmare
&lt;/h3&gt;

&lt;p&gt;If you are a solo developer, this is just annoying. If you are an engineering manager or a CISO, this is a massive compliance blindspot. &lt;/p&gt;

&lt;p&gt;When a vulnerability scanner flags that JWT middleware three months from now, the reviewing engineer will see your name on the commit. They will assume you had a specific, undocumented business reason for skipping the expiration check. They won't know it was a hallucinated shortcut taken by an AI model. &lt;/p&gt;

&lt;h3&gt;
  
  
  Fixing it at the Proxy Layer
&lt;/h3&gt;

&lt;p&gt;To solve this for my own workflows, I realized that scraping text or using git hooks wouldn't work. By the time code hits git, it's too late. The provenance is gone.&lt;/p&gt;

&lt;p&gt;I recently open-sourced &lt;strong&gt;LineageLens&lt;/strong&gt;, a self-hosted intercepting proxy designed specifically for AI agents. Instead of looking at git, it sits between your terminal and the AI provider. &lt;/p&gt;

&lt;p&gt;Because it intercepts the raw API traffic, it can parse the actual structured tool calls. It builds a state machine to track when an AI &lt;em&gt;proposes&lt;/em&gt; an edit, and correlates it with the subsequent &lt;code&gt;tool_result&lt;/code&gt; to confirm if the developer actually &lt;em&gt;applied&lt;/em&gt; it. &lt;/p&gt;

&lt;p&gt;The result is a local, searchable audit trail that answers: &lt;em&gt;"Which code in our repo was AI-generated, by which model, with what exact prompt?"&lt;/em&gt; If you are interested in how the proxy parses these agentic protocols, or if you want to run the single-container SQLite version to track your own AI usage this weekend, the repo is live here: &lt;a href="https://github.com/karnati-praveen/lineagelens" rel="noopener noreferrer"&gt;LineageLens on GitHub&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Are you currently tracking AI provenance in your repos, or are you flying blind? Let me know in the comments.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>devops</category>
      <category>opensource</category>
      <category>security</category>
    </item>
  </channel>
</rss>
