<?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: Frank man Video</title>
    <description>The latest articles on DEV Community by Frank man Video (@frank_manvideo_6288cb2f1).</description>
    <link>https://dev.to/frank_manvideo_6288cb2f1</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%2F4063124%2Fbdffb6c1-4013-434c-b74f-00dde3093a12.png</url>
      <title>DEV Community: Frank man Video</title>
      <link>https://dev.to/frank_manvideo_6288cb2f1</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/frank_manvideo_6288cb2f1"/>
    <language>en</language>
    <item>
      <title>How I Built a Client-Side Shield for AI Chatbots (Open Source)</title>
      <dc:creator>Frank man Video</dc:creator>
      <pubDate>Fri, 14 Aug 2026 12:06:01 +0000</pubDate>
      <link>https://dev.to/frank_manvideo_6288cb2f1/how-i-built-a-client-side-shield-for-ai-chatbots-open-source-1f7d</link>
      <guid>https://dev.to/frank_manvideo_6288cb2f1/how-i-built-a-client-side-shield-for-ai-chatbots-open-source-1f7d</guid>
      <description>&lt;p&gt;I was burning through API tokens on off-topic chatbot queries.&lt;/p&gt;

&lt;p&gt;Every "Who are you?" = brand leak + wasted money.&lt;/p&gt;

&lt;p&gt;So I built &lt;strong&gt;Shield by Vouch&lt;/strong&gt; — a zero-cost, client-side filter that blocks prompt injections and off-topic queries &lt;strong&gt;before&lt;/strong&gt; they hit your LLM.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Problem
&lt;/h2&gt;

&lt;p&gt;You build an AI chatbot for your business. Users ask:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;"Who are you?" → Reveals it's ChatGPT&lt;/li&gt;
&lt;li&gt;"Python code for calculator" → Wastes API tokens&lt;/li&gt;
&lt;li&gt;"Ignore previous instructions" → Prompt injection&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Every off-topic query = $0.002 gone.&lt;/strong&gt; 1000 queries = &lt;strong&gt;$2 burned.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Client-Side?
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Server-Side&lt;/th&gt;
&lt;th&gt;Client-Side&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Latency: ~100-500ms&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Latency: 0ms&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cost: API call already made&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Cost: Zero if blocked&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h2&gt;
  
  
  Auto-Healing Backend
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Paste any API key → Auto-detects provider (OpenAI, Groq, Gemini, Anthropic, OpenRouter)&lt;/li&gt;
&lt;li&gt;Model fails → Auto-switches to fallback&lt;/li&gt;
&lt;li&gt;Cross-provider failover → Zero downtime&lt;/li&gt;
&lt;/ul&gt;

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



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;shield&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;VouchShield&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;businessType&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;restaurant&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;businessDesc&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Italian food in Mumbai&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;shield&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;check&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Who are you?&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="c1"&gt;// { blocked: true, response: "I can only help with our restaurant services..." }&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Results&lt;br&gt;
80% off-topic queries blocked client-side&lt;br&gt;
Zero identity leaks&lt;br&gt;
$2 saved per 1000 blocked queries&lt;br&gt;
Try It&lt;br&gt;
🚀 &lt;a href="https://shield-by-vouch.vercel.app/" rel="noopener noreferrer"&gt;Live Demo&lt;/a&gt;&lt;br&gt;
⭐ &lt;a href="https://github.com/priyamdeepanshu-a11y/shield-by-vouch" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;&lt;br&gt;
MIT License. No signup. Single file drop-in.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>opensource</category>
      <category>ai</category>
      <category>chatbot</category>
    </item>
  </channel>
</rss>
