<?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: JonyT</title>
    <description>The latest articles on Forem by JonyT (@khaitrang1995).</description>
    <link>https://forem.com/khaitrang1995</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%2F3871196%2F69b1d991-9d0b-45d4-b937-408e0fd8ea11.jpeg</url>
      <title>Forem: JonyT</title>
      <link>https://forem.com/khaitrang1995</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/khaitrang1995"/>
    <language>en</language>
    <item>
      <title>Stop your AI Coding Agent from making the same mistake twice</title>
      <dc:creator>JonyT</dc:creator>
      <pubDate>Thu, 07 May 2026 13:01:26 +0000</pubDate>
      <link>https://forem.com/khaitrang1995/stop-your-ai-coding-agent-from-making-the-same-mistake-twice-blh</link>
      <guid>https://forem.com/khaitrang1995/stop-your-ai-coding-agent-from-making-the-same-mistake-twice-blh</guid>
      <description>&lt;p&gt;Building TechSphereX Studio: Giving AI Agents a Memory&lt;br&gt;
Have you ever found yourself correcting GitHub Copilot or Cursor for the exact same bug or architectural pattern you fixed last week?&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%2Fic7riv7tiyby5v3dlpoz.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%2Fic7riv7tiyby5v3dlpoz.png" alt=" " width="800" height="552"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As AI agents become more integrated into our workflows, they often lack the "institutional memory" of our specific team's codebase, security standards, and past hard-learned lessons.&lt;/p&gt;

&lt;p&gt;That’s why I built TechSphereX Studio — an AI Experience Engine that intercepts AI actions and provides real-time, context-aware suggestions.&lt;/p&gt;
&lt;h2&gt;
  
  
  ✨ What is TechSphereX Studio?
&lt;/h2&gt;

&lt;p&gt;It is a self-learning system designed to act as a bridge between your AI agent and your team's accumulated knowledge base.&lt;/p&gt;
&lt;h3&gt;
  
  
  The 3-Layer Intercept Pipeline:
&lt;/h3&gt;

&lt;p&gt;L1 (Read-only Filter): Instantly skips non-destructive actions like ls or cat (&amp;lt; 1ms).&lt;/p&gt;

&lt;p&gt;L2 (Semantic Search): Uses vector embeddings (Qdrant) to find relevant past "experiences" (&amp;lt; 50ms).&lt;/p&gt;

&lt;p&gt;L3 (LLM Anti-Noise): A local LLM (via Ollama) filters out irrelevant results to ensure high-quality suggestions (&amp;lt; 500ms).&lt;/p&gt;
&lt;h3&gt;
  
  
  🛠 The "Polyglot" Tech Stack
&lt;/h3&gt;

&lt;p&gt;One of the most exciting parts of this project was working across multiple languages in a single monorepo:&lt;/p&gt;

&lt;p&gt;🐍 Python (FastAPI + Qdrant): The core engine handling the AI pipeline and vector database.&lt;/p&gt;

&lt;p&gt;🦀 Rust (Tauri 2.0): Powering a high-performance native desktop dashboard.&lt;/p&gt;

&lt;p&gt;⚛️ React 19 + Vite 6: A modern UI for managing "experiences" and viewing KPIs.&lt;/p&gt;

&lt;p&gt;📘 TypeScript: Used for the VS Code Extension, CLI tool, and shared SDK.&lt;/p&gt;
&lt;h3&gt;
  
  
  🏗 Architecture at a Glance
&lt;/h3&gt;

&lt;p&gt;The system is designed to be modular. Whether you are using the VS Code Extension, the CLI, or the Desktop App, everything communicates with the central FastAPI engine.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;graph TD
    EXT["VS Code Extension"] --&amp;gt; API["FastAPI Core"]
    CLI["CLI Tool"] --&amp;gt; API
    DESK["Tauri Desktop"] --&amp;gt; API
    API --&amp;gt; QDRANT[("Qdrant Vector DB")]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🚀 How it works with your AI Agent
&lt;/h3&gt;

&lt;p&gt;Once you start the engine and configure your agent (Copilot, Cursor, Gemini, or Claude), the magic happens:&lt;/p&gt;

&lt;p&gt;You: "Create a database connection."&lt;/p&gt;

&lt;p&gt;Agent: Queries TechSphereX POST /api/intercept.&lt;/p&gt;

&lt;p&gt;Engine: Returns suggestions like "⚠️ CRITICAL: Use Singleton Pattern for DB connections."&lt;/p&gt;

&lt;p&gt;Agent: Writes the code correctly the first time. ✅&lt;/p&gt;

&lt;p&gt;🛡 Overcoming Challenges: The Windows Defender Issue&lt;br&gt;
Bundling a Python AI engine into a Windows .exe using PyInstaller came with a surprise: False Positives. Because the bootloader extracts files to %TEMP% and contains ML libraries like PyTorch, some AVs flag it. I’ve documented my mitigation steps (disabling UPX, adding PE metadata) in the README to help others facing the same struggle!&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%2F9f2sbmsavqlbjvirkcd5.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%2F9f2sbmsavqlbjvirkcd5.png" alt=" " width="800" height="559"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  📂 Open Source &amp;amp; Future
&lt;/h3&gt;

&lt;p&gt;This project is currently in v0.1 and is fully open-source. Upcoming features include:&lt;/p&gt;

&lt;p&gt;Team sync for cloud experience sharing.&lt;/p&gt;

&lt;p&gt;Native hooks for Copilot PreToolUse/PostToolUse.&lt;/p&gt;

&lt;p&gt;JetBrains plugin support.&lt;/p&gt;

&lt;p&gt;Check out the repo here: &lt;a href="https://github.com/KhaiTrang1995/techspherex-studio" rel="noopener noreferrer"&gt;https://github.com/KhaiTrang1995/techspherex-studio&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I'd love to hear your thoughts! How are you managing "knowledge" with your AI agents?&lt;/p&gt;

&lt;h1&gt;
  
  
  AI #OpenSource #Python #Rust #TypeScript #Productivity
&lt;/h1&gt;

</description>
      <category>ai</category>
      <category>agents</category>
      <category>agentskills</category>
      <category>claude</category>
    </item>
  </channel>
</rss>
