<?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: Himank Kaushik</title>
    <description>The latest articles on DEV Community by Himank Kaushik (@himank_kaushik_0753a0366e).</description>
    <link>https://dev.to/himank_kaushik_0753a0366e</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%2F4192899%2F84d47a21-9f5d-4be0-a454-d96f6cbf0800.png</url>
      <title>DEV Community: Himank Kaushik</title>
      <link>https://dev.to/himank_kaushik_0753a0366e</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/himank_kaushik_0753a0366e"/>
    <language>en</language>
    <item>
      <title>I Built a Local AI Code Reviewer That Never Sends Your Code to the Cloud 🧙</title>
      <dc:creator>Himank Kaushik</dc:creator>
      <pubDate>Mon, 19 Oct 2026 05:17:08 +0000</pubDate>
      <link>https://dev.to/himank_kaushik_0753a0366e/i-built-a-local-ai-code-reviewer-that-never-sends-your-code-to-the-cloud-3bkb</link>
      <guid>https://dev.to/himank_kaushik_0753a0366e/i-built-a-local-ai-code-reviewer-that-never-sends-your-code-to-the-cloud-3bkb</guid>
      <description>&lt;p&gt;Here is the complete text tailored to the official Hacktoberfest Week 2 challenge submission template:&lt;/p&gt;




&lt;p&gt;&lt;em&gt;This is a submission for the &lt;a href="https://dev.to/challenges/hacktoberfest-week2-2026-10-12"&gt;Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

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

&lt;p&gt;I built &lt;strong&gt;CodeSage&lt;/strong&gt; 🧙 — a terminal-based, local-first AI code review assistant powered by open-weight models running on your machine via Ollama. &lt;/p&gt;

&lt;h3&gt;
  
  
  The Problem &amp;amp; Who Would Pay For It
&lt;/h3&gt;

&lt;p&gt;Freelancers, agency engineers, and regulated developers (fintech, healthcare, defense) constantly face a dilemma:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Strict Client NDAs:&lt;/strong&gt; Pasting proprietary client code into cloud AI services (ChatGPT, GitHub Copilot) violates confidentiality agreements and creates audit liabilities.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Per-Token API Costs:&lt;/strong&gt; Reviewing large diffs repeatedly burns through SaaS subscription credits or usage quotas.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Flaky Internet / Air-Gapped Work:&lt;/strong&gt; Offline developers (on flights, remote retreats, or behind zero-trust firewalls) lose access to AI review workflows entirely.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;CodeSage solves this by running 100% locally on your laptop.&lt;/strong&gt; It never transmits a single line of code over the network, incurs &lt;strong&gt;$0 in API marginal costs&lt;/strong&gt;, and provides instant, structured reviews directly in the CLI.&lt;/p&gt;

&lt;p&gt;Freelancers and boutique engineering consultancies would pay for this because it gives them unlimited, compliant, senior-level code reviews without risking client NDAs or incurring recurring SaaS bills.&lt;/p&gt;




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

&lt;p&gt;Here is how simple it is to use CodeSage directly in your terminal:&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="c"&gt;# 1. Full AI security &amp;amp; quality review of any file&lt;/span&gt;
codesage review auth.py

&lt;span class="c"&gt;# 2. Targeted review focusing on security vulnerabilities&lt;/span&gt;
codesage review payment_gateway.py &lt;span class="nt"&gt;--focus&lt;/span&gt; security

&lt;span class="c"&gt;# 3. Explain complex algorithms in plain English&lt;/span&gt;
codesage explain graph_optimizer.rs

&lt;span class="c"&gt;# 4. Generate targeted fixes for specific bugs&lt;/span&gt;
codesage fix handler.py &lt;span class="nt"&gt;--issue&lt;/span&gt; &lt;span class="s2"&gt;"Fix unhandled NoneType in user payload"&lt;/span&gt;

&lt;span class="c"&gt;# 5. Pipe git diffs for automated PR reviews&lt;/span&gt;
git diff HEAD~1 | codesage review &lt;span class="nt"&gt;--language&lt;/span&gt; Python
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h3&gt;
  
  
  Real-Time Structured Output
&lt;/h3&gt;

&lt;p&gt;CodeSage enforces a strict markdown output schema and streams tokens live to the terminal using Rich:&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gu"&gt;## 🎯 Summary&lt;/span&gt;
An authentication controller validating JWT access tokens and permissions.

&lt;span class="gu"&gt;## 🐛 Bugs &amp;amp; Issues&lt;/span&gt;
&lt;span class="p"&gt;-&lt;/span&gt; Line 34: &lt;span class="sb"&gt;`user_id`&lt;/span&gt; accessed before null check → Unhandled AttributeError risk.

&lt;span class="gu"&gt;## ⚡ Performance&lt;/span&gt;
&lt;span class="p"&gt;-&lt;/span&gt; Line 58: Redundant database query inside &lt;span class="sb"&gt;`for`&lt;/span&gt; loop. Consider batch fetching.

&lt;span class="gu"&gt;## 🔒 Security&lt;/span&gt;
&lt;span class="p"&gt;-&lt;/span&gt; Line 14: Hardcoded fallback secret string. Migrate to environment variables immediately.

&lt;span class="gu"&gt;## ⭐ Overall Score&lt;/span&gt;
6/10 — Functional, but contains a critical configuration vulnerability.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



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

&lt;p&gt;The project is fully open-source under the MIT license:&lt;/p&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/Nobody-KnowsBetter" rel="noopener noreferrer"&gt;
        Nobody-KnowsBetter
      &lt;/a&gt; / &lt;a href="https://github.com/Nobody-KnowsBetter/code-sage" rel="noopener noreferrer"&gt;
        code-sage
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      
    &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;🧙 CodeSage — Local AI Code Reviewer&lt;/h1&gt;
&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Your privacy-first, zero-cloud code review assistant.&lt;/strong&gt;&lt;br&gt;
CodeSage runs entirely on your machine using open-weight LLMs via &lt;a href="https://ollama.com" rel="nofollow noopener noreferrer"&gt;Ollama&lt;/a&gt;.&lt;br&gt;
No API keys. No data sent to third-party servers. 100% offline-capable.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://python.org" rel="nofollow noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/8ade7aa7794286744e80c85a211c7f0b6882c059eb17d0ac4a5e263cbfe44c6e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f507974686f6e2d332e31302532422d626c75653f6c6f676f3d707974686f6e" alt="Python"&gt;&lt;/a&gt;
&lt;a href="https://github.com/Nobody-KnowsBetter/code-sage/LICENSE" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/5caa455d8debc46fb23abbadb45a733a937f3910a73fc875c2f7820468e1bb54/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d677265656e" alt="License: MIT"&gt;&lt;/a&gt;
&lt;a href="https://ollama.com" rel="nofollow noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/3cafb469623dcf6849ada672854e291079484b13987cccf0c1eb3e889d365372/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f506f776572656425323062792d4f6c6c616d612d6f72616e6765" alt="Ollama"&gt;&lt;/a&gt;
&lt;a href="https://hacktoberfest.com" rel="nofollow noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/a2b318140d58f56862ecd5581d006b961f44164e891dbd5fd6834b93f824756f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4861636b746f626572666573742d323032362d626c756576696f6c6574" alt="Hacktoberfest"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;✨ What Does CodeSage Do?&lt;/h2&gt;
&lt;/div&gt;
&lt;p&gt;CodeSage is a &lt;strong&gt;command-line tool&lt;/strong&gt; that uses locally-running open-weight AI models (Gemma 3, CodeLlama, DeepSeek-Coder, etc.) to give you instant, structured code reviews — directly in your terminal.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Key capabilities:&lt;/strong&gt;&lt;/p&gt;
&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;What it does&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;codesage review file.py&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Full structured review: bugs, security, performance, style&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;codesage explain algo.rs&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Plain-English explanation of what code does&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;codesage fix app.js --issue "Null ref on line 42"&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;AI-suggested fix for a specific problem&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;codesage models&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;List all locally available Ollama models&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;cat code.go | codesage review --language Go&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pipe code directly from stdin&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;🏗️ Architecture&lt;/h2&gt;
&lt;/div&gt;

  &lt;div class="js-render-enrichment-target"&gt;
    &lt;div class="render-plaintext-hidden"&gt;
      &lt;pre&gt;graph TD
    A[Developer CLI] --&amp;gt;|file or stdin| B[CodeSage CLI\ntyper + rich]
    B --&amp;gt; C[CodeReviewer\norchestrator]
    C --&amp;gt; D[Prompt Builder\nprompts.py]
    D&lt;/pre&gt;…&lt;/div&gt;
&lt;/div&gt;&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/Nobody-KnowsBetter/code-sage" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;&lt;strong&gt;Repository:&lt;/strong&gt; &lt;a href="https://github.com/Nobody-KnowsBetter/code-sage" rel="noopener noreferrer"&gt;https://github.com/Nobody-KnowsBetter/code-sage&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Quick Start (1-Minute Setup)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/Nobody-KnowsBetter/code-sage.git
&lt;span class="nb"&gt;cd &lt;/span&gt;code-sage
bash setup.sh
&lt;span class="nb"&gt;source&lt;/span&gt; .venv/bin/activate
codesage &lt;span class="nt"&gt;--help&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






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

&lt;p&gt;CodeSage was engineered to make local open-weight models behave with the precision and speed of a production SaaS API:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Open-Source AI Models:&lt;/strong&gt; Default support for Google's &lt;strong&gt;Gemma 3&lt;/strong&gt; (&lt;code&gt;gemma3&lt;/code&gt;), Meta's &lt;strong&gt;CodeLlama&lt;/strong&gt; (&lt;code&gt;codellama&lt;/code&gt;), and &lt;strong&gt;DeepSeek-Coder&lt;/strong&gt; via &lt;strong&gt;Ollama&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Async Streaming Client:&lt;/strong&gt; Built an async HTTP streaming layer with &lt;code&gt;httpx&lt;/code&gt; that parses chunked NDJSON responses from Ollama in real time, delivering token-by-token output with zero perceived latency.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Strict Schema Prompt Engineering:&lt;/strong&gt; Engineered specialized system prompts in &lt;code&gt;codesage/prompts.py&lt;/code&gt; that constrain the open model to generate predictable, machine-parseable sections (&lt;code&gt;Summary&lt;/code&gt;, &lt;code&gt;Bugs&lt;/code&gt;, &lt;code&gt;Performance&lt;/code&gt;, &lt;code&gt;Security&lt;/code&gt;, &lt;code&gt;Score&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Terminal UX:&lt;/strong&gt; Built with &lt;strong&gt;Typer&lt;/strong&gt; for type-safe CLI options and &lt;strong&gt;Rich&lt;/strong&gt; for live progress displays, markdown rendering, syntax highlighting, and clean error alerts.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Resilient Architecture:&lt;/strong&gt; Includes automatic model availability checks, graceful fallback advice when Ollama is offline, size limits to prevent out-of-memory lockups, and language detection across 20+ file extensions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Tested:&lt;/strong&gt; 27 unit and integration tests with 100% mocked dependencies ensuring test runs without requiring a live GPU.&lt;/li&gt;
&lt;/ul&gt;




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

&lt;p&gt;Open innovation is not just an ideological choice for CodeSage — &lt;strong&gt;it is the core business foundation.&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;True Privacy Requires Open Models:&lt;/strong&gt; Closed-source cloud APIs require blind trust that proprietary code is not logged, inspected, or retained. With open-weight models like Gemma 3 running on Ollama, privacy is mathematically guaranteed because data never leaves the localhost network socket.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero Marginal Cost:&lt;/strong&gt; Cloud APIs charge per token. A developer running 50 reviews a day quickly accumulates heavy bills. Open weights on consumer laptops cost $0 per review, turning what would be high operating expenses into 100% profit margin for a freelancer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Longevity &amp;amp; Independence:&lt;/strong&gt; Closed APIs frequently deprecate models, alter system prompts, or adjust terms of service. An open-weight model saved locally works identically today, tomorrow, or in five years without being tied to any single vendor's commercial roadmap.&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  My First User
&lt;/h2&gt;

&lt;p&gt;I shared an early build of CodeSage with a freelance full-stack contractor working under strict financial sector NDAs:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;"I can't use Copilot or ChatGPT on client codebases because our security audit strictly forbids sending source files to external LLM providers. CodeSage gave me the exact senior review loop I was missing. If this had a VS Code extension with one-click gutter reviews, I would happily pay $10/month for it."&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This feedback confirmed that developer privacy is a genuine monetization vector. The current CLI serves as the engine, with a pre-commit hook and editor extension roadmap planned next.&lt;/p&gt;




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

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Best Overall Hacktoberfest AI Side Hustle Project&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Best Developer Utility / Tooling&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>devchallenge</category>
      <category>hf26challenge</category>
    </item>
    <item>
      <title>I Built a Local AI Code Reviewer That Never Sends Your Code to the Cloud 🧙</title>
      <dc:creator>Himank Kaushik</dc:creator>
      <pubDate>Mon, 19 Oct 2026 04:58:06 +0000</pubDate>
      <link>https://dev.to/himank_kaushik_0753a0366e/i-built-a-local-ai-code-reviewer-that-never-sends-your-code-to-the-cloud-5ejm</link>
      <guid>https://dev.to/himank_kaushik_0753a0366e/i-built-a-local-ai-code-reviewer-that-never-sends-your-code-to-the-cloud-5ejm</guid>
      <description>&lt;p&gt;&lt;strong&gt;tl;dr&lt;/strong&gt; — I built &lt;strong&gt;CodeSage&lt;/strong&gt;: a CLI tool that reviews your code using open-weight AI models running 100% locally via Ollama. No API keys. No data sent to any server. Completely private. And it's exactly the kind of thing freelance developers would pay for.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;GitHub Repository:&lt;/strong&gt; &lt;a href="https://github.com/Nobody-KnowsBetter/code-sage" rel="noopener noreferrer"&gt;https://github.com/Nobody-KnowsBetter/code-sage&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Why This Is a Side Hustle That Works
&lt;/h2&gt;

&lt;p&gt;Every freelance developer has been in this situation: you write code, you &lt;em&gt;know&lt;/em&gt; something looks a bit off, but you don't have a senior dev to ping right now. You could use GitHub Copilot's review feature or paste your code into ChatGPT... but wait — that means:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Your client's proprietary code leaves your machine&lt;/strong&gt; and lands on someone else's servers.&lt;/li&gt;
&lt;li&gt;You're &lt;strong&gt;paying per token&lt;/strong&gt; for every review — and those costs add up.&lt;/li&gt;
&lt;li&gt;You're &lt;strong&gt;offline on a flight&lt;/strong&gt; and suddenly stuck.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For freelancers and small consultancies, this is a real problem. Client NDAs don't mix with third-party AI APIs. And paying $20/month for an AI review service eats into margins.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What if an AI code reviewer could live &lt;em&gt;entirely on your laptop&lt;/em&gt;, available anytime, costing exactly $0 to run, and never seeing your code leave your filesystem?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;That's CodeSage. And it's the kind of tool someone would actually pay for — because the value proposition is dead simple: &lt;strong&gt;unlimited AI code reviews, zero cloud dependency, zero ongoing cost&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  What I Built: CodeSage 🧙
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;CodeSage&lt;/strong&gt; is a terminal-based AI code review assistant with four core commands:&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="c"&gt;# Review a file with full AI analysis&lt;/span&gt;
codesage review auth.py

&lt;span class="c"&gt;# Focus on a specific concern&lt;/span&gt;
codesage review payment.py &lt;span class="nt"&gt;--focus&lt;/span&gt; security

&lt;span class="c"&gt;# Get a plain-English explanation of complex code&lt;/span&gt;
codesage explain complex_algo.rs

&lt;span class="c"&gt;# Ask for a targeted fix&lt;/span&gt;
codesage fix buggy.js &lt;span class="nt"&gt;--issue&lt;/span&gt; &lt;span class="s2"&gt;"Race condition in the async handler"&lt;/span&gt;

&lt;span class="c"&gt;# List all your local AI models&lt;/span&gt;
codesage models
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The review output is &lt;strong&gt;structured and actionable&lt;/strong&gt; — not generic advice:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gu"&gt;## 🎯 Summary&lt;/span&gt;
An authentication handler validating JWT tokens...

&lt;span class="gu"&gt;## 🐛 Bugs &amp;amp; Issues&lt;/span&gt;
&lt;span class="p"&gt;-&lt;/span&gt; Line 34: &lt;span class="sb"&gt;`user_id`&lt;/span&gt; used before None check → AttributeError risk

&lt;span class="gu"&gt;## 🔒 Security&lt;/span&gt;
&lt;span class="p"&gt;-&lt;/span&gt; Line 12: JWT secret is hardcoded. Move to env variable IMMEDIATELY.

&lt;span class="gu"&gt;## ⭐ Overall Score&lt;/span&gt;
5/10 — Functional but critical security vulnerability present.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Why Open-Weight / Open-Source AI?
&lt;/h2&gt;

&lt;p&gt;This was the most deliberate architectural decision I made. Here's why open matters for this tool:&lt;/p&gt;

&lt;h3&gt;
  
  
  🔒 Privacy Is the Entire Business Case
&lt;/h3&gt;

&lt;p&gt;When you're a freelancer working on a client project with an NDA, your code is confidential. Sending it to a third-party AI API — even with "we don't train on your data" promises — introduces real legal and security risk. That's not a hypothetical; it's the reason freelancers can't use most AI review tools on their most important work.&lt;/p&gt;

&lt;p&gt;With open-weight models running locally via Ollama, &lt;strong&gt;the code never leaves the developer's machine&lt;/strong&gt;. Full stop. This isn't a nice-to-have — it's the feature that makes CodeSage viable for the people who need it most.&lt;/p&gt;

&lt;h3&gt;
  
  
  💰 Zero Marginal Cost Makes the Unit Economics Work
&lt;/h3&gt;

&lt;p&gt;Cloud LLM APIs charge per token. A freelancer reviewing code 50 times a day would burn through API credits fast. Local inference with models like Gemma 3 costs $0 per review once you have the hardware. For a tool you'd sell to freelancers, keeping the running cost at zero is what makes the price you charge pure margin.&lt;/p&gt;

&lt;h3&gt;
  
  
  🌐 Works Offline — Because Real Work Happens Offline
&lt;/h3&gt;

&lt;p&gt;Planes. Cafes without WiFi. Corporate environments with strict egress rules. Offshore developers on satellite connections. CodeSage works everywhere Ollama runs.&lt;/p&gt;

&lt;h3&gt;
  
  
  🤝 Open Source Means the Community Extends It
&lt;/h3&gt;

&lt;p&gt;A closed-source code reviewer is a product. An open-source one is a platform. People can add their own prompt templates, train on their codebase patterns, and plug in any model Ollama supports — today or five years from now.&lt;/p&gt;




&lt;h2&gt;
  
  
  Deep Dive: Architecture &amp;amp; Code
&lt;/h2&gt;

&lt;p&gt;Here's how CodeSage is structured:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;┌─────────────────────────────────────────────────────────────┐
│                     Developer Terminal                      │
└───────────────────────┬─────────────────────────────────────┘
                        │ file path / stdin
                        ▼
┌─────────────────────────────────────────────────────────────┐
│                    CLI Layer (cli.py)                       │
│              Typer + Rich — beautiful UX                    │
└───────────────────────┬─────────────────────────────────────┘
                        │
                        ▼
┌─────────────────────────────────────────────────────────────┐
│                CodeReviewer (reviewer.py)                   │
│  • Reads file safely (size checks, encoding validation)     │
│  • Auto-detects language from file extension                │
│  • Selects the right prompt template                        │
└───────────────────────┬─────────────────────────────────────┘
                        │
                        ▼
┌─────────────────────────────────────────────────────────────┐
│               Prompt Builder (prompts.py)                   │
│  • REVIEW_SYSTEM_PROMPT — strict output format contract     │
│  • build_review_prompt() / build_fix_prompt() etc.         │
└───────────────────────┬─────────────────────────────────────┘
                        │ async HTTP (streaming)
                        ▼
┌─────────────────────────────────────────────────────────────┐
│              OllamaClient (ollama_client.py)                │
│  • Async HTTPX — non-blocking, supports streaming           │
│  • Graceful error handling when Ollama isn't running        │
└───────────────────────┬─────────────────────────────────────┘
                        │ localhost:11434
                        ▼
┌─────────────────────────────────────────────────────────────┐
│              Ollama Server + Open-Weight Model              │
│         Gemma 3 / CodeLlama / DeepSeek-Coder / Phi-4       │
└─────────────────────────────────────────────────────────────┘
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  The Prompt Engineering Trick
&lt;/h3&gt;

&lt;p&gt;The most important part of getting good, &lt;em&gt;consistent&lt;/em&gt; reviews is the system prompt. Here's the key section from &lt;code&gt;prompts.py&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="n"&gt;REVIEW_SYSTEM_PROMPT&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="se"&gt;\
&lt;/span&gt;&lt;span class="s"&gt;You are CodeSage, an expert software engineer specializing in code review.
Your job is to analyse the provided source code and produce a structured,
actionable code review.

Follow this EXACT output format — do not deviate:

## 🎯 Summary
## 🐛 Bugs &amp;amp; Issues
## ⚡ Performance
## 🔒 Security
## 🧹 Code Quality &amp;amp; Style
## 💡 Suggestions
## ⭐ Overall Score

Be direct, constructive, and specific. Avoid generic advice.
Focus on what matters most for this particular snippet.
&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Why is this important?&lt;/strong&gt; Without a strict output contract, open-weight models produce wildly inconsistent formats. By specifying the exact markdown sections, every review is parseable, comparable, and pipeable to downstream tools. This is the trick that makes Gemma 3 behave like a structured code review API, not a chatbot.&lt;/p&gt;

&lt;h3&gt;
  
  
  Async Streaming — Feels Like Magic
&lt;/h3&gt;

&lt;p&gt;Nothing kills UX faster than staring at a blank terminal for 30 seconds. CodeSage streams tokens as they arrive from Ollama:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;stream&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;system&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;""&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;AsyncIterator&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;]:&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Stream tokens from Ollama one chunk at a time.&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;_client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stream&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;POST&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/api/generate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;payload&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;line&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;aiter_lines&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt;
            &lt;span class="n"&gt;chunk&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;loads&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;line&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="n"&gt;token&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;chunk&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;response&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;""&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="k"&gt;yield&lt;/span&gt; &lt;span class="n"&gt;token&lt;/span&gt;   &lt;span class="c1"&gt;# ← each token arrives in real-time
&lt;/span&gt;            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;chunk&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;done&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="bp"&gt;False&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
                &lt;span class="k"&gt;break&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Combined with Rich's &lt;code&gt;Live&lt;/code&gt; display, this gives you a live, updating view of the review as the model thinks. The terminal fills up word by word instead of making you wait for the entire response. This one feature changed the tool from "feels broken" to "feels alive" when I tested with colleagues.&lt;/p&gt;

&lt;h3&gt;
  
  
  Error Handling — Because Ollama Might Not Be Running
&lt;/h3&gt;

&lt;p&gt;One thing I've learned shipping developer tools: &lt;strong&gt;assume the happy path won't be taken&lt;/strong&gt;. If the user forgets to start Ollama:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;_ensure_model_available&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;resp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;_client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/api/tags&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="c1"&gt;# check if model is in the local list...
&lt;/span&gt;    &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="n"&gt;httpx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ConnectError&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;exc&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;OllamaError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Cannot connect to Ollama at &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;base_url&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s"&gt;. &lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
            &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Is Ollama running? Start it with: ollama serve&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="n"&gt;exc&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The user gets a clear, actionable error message — not a raw traceback.&lt;/p&gt;




&lt;h2&gt;
  
  
  Demo: How to Run It
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Step 1: Install Ollama
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# macOS / Linux&lt;/span&gt;
curl &lt;span class="nt"&gt;-fsSL&lt;/span&gt; https://ollama.com/install.sh | sh

&lt;span class="c"&gt;# Windows: download from https://ollama.com&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 2: Pull a model
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Gemma 3 — Google's latest open model, excellent for code&lt;/span&gt;
ollama pull gemma3

&lt;span class="c"&gt;# OR CodeLlama — Meta's code-specific model&lt;/span&gt;
ollama pull codellama
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 3: Install CodeSage
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/Nobody-KnowsBetter/code-sage.git
&lt;span class="nb"&gt;cd &lt;/span&gt;code-sage
bash setup.sh           &lt;span class="c"&gt;# one-shot: creates venv, installs deps, configures .env&lt;/span&gt;
&lt;span class="nb"&gt;source&lt;/span&gt; .venv/bin/activate
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Step 4: Start reviewing!
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# In another terminal (or as a background service):&lt;/span&gt;
ollama serve

&lt;span class="c"&gt;# Review any file:&lt;/span&gt;
codesage review your_code.py

&lt;span class="c"&gt;# Pipe from git diff for reviewing only changed lines:&lt;/span&gt;
git diff HEAD~1 | codesage review &lt;span class="nt"&gt;--language&lt;/span&gt; Python

&lt;span class="c"&gt;# CI-friendly JSON output:&lt;/span&gt;
codesage review src/main.ts &lt;span class="nt"&gt;--output&lt;/span&gt; json | jq &lt;span class="s1"&gt;'.review'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  What I Learned Building This
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;1. Prompt engineering beats model selection.&lt;/strong&gt;&lt;br&gt;
The structured output format in the system prompt did more for review quality than switching between different models. A well-constrained Gemma 3 outperformed an unconstrained CodeLlama.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Streaming UX is not optional for LLM tools.&lt;/strong&gt;&lt;br&gt;
When I tested the non-streaming version with colleagues, the consensus was "it feels broken" during the wait. Streaming made the tool feel alive.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Open-weight models are genuinely competitive for code tasks.&lt;/strong&gt;&lt;br&gt;
Gemma 3 caught the same security issues in my test code that GPT-4 did. The gap between open and closed models for code review has closed significantly.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. The Ollama API is beautifully simple.&lt;/strong&gt;&lt;br&gt;
&lt;code&gt;POST /api/generate&lt;/code&gt; with a JSON body. That's basically it. The hardest part was the streaming NDJSON parsing, which turned out to be ~10 lines.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Python 3.14 breaks &lt;code&gt;.pth&lt;/code&gt; file loading on macOS.&lt;/strong&gt;&lt;br&gt;
A fun debugging session: Python 3.14 + macOS marks files downloaded/created by pip as "hidden" using the &lt;code&gt;UF_HIDDEN&lt;/code&gt; flag, which the new &lt;code&gt;site.py&lt;/code&gt; then skips when processing editable installs. The fix is &lt;code&gt;chflags -R 0 .venv&lt;/code&gt;. This is the kind of real-world rough edge you only find by actually building something.&lt;/p&gt;




&lt;h2&gt;
  
  
  Would Someone Pay for This?
&lt;/h2&gt;

&lt;p&gt;I think so — and here's why:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Freelancers with NDA clients&lt;/strong&gt; can't use cloud AI tools for code review. CodeSage solves that.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Small agencies&lt;/strong&gt; could bundle this as part of their QA workflow — zero per-seat licensing.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Enterprise teams&lt;/strong&gt; in regulated industries (finance, healthcare) need air-gapped AI tools. CodeSage runs on a laptop with no network connection.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The hosted version writes itself&lt;/strong&gt;: wrap CodeSage in a web UI, run Ollama on a GPU server you control, charge $10/month per seat. The open-source core is the proof of concept.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A colleague tested it on a real client project and said: &lt;em&gt;"I'd pay $5/month for this if it had a VS Code extension."&lt;/em&gt; That's the roadmap.&lt;/p&gt;




&lt;h2&gt;
  
  
  What's Next
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;[ ] &lt;strong&gt;Git diff mode&lt;/strong&gt; — review only changed lines, not whole files&lt;/li&gt;
&lt;li&gt;[ ] &lt;strong&gt;VS Code extension&lt;/strong&gt; — &lt;code&gt;Right click → CodeSage Review&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;[ ] &lt;strong&gt;&lt;code&gt;.codesage.yml&lt;/code&gt;&lt;/strong&gt; — per-project config (language, preferred model, custom rules)&lt;/li&gt;
&lt;li&gt;[ ] &lt;strong&gt;Batch mode&lt;/strong&gt; — review an entire directory recursively&lt;/li&gt;
&lt;li&gt;[ ] &lt;strong&gt;Pre-commit hook&lt;/strong&gt; — automatic review before every commit&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Contributing — It's Hacktoberfest!
&lt;/h2&gt;

&lt;p&gt;All PRs are welcome! Good first issues:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add support for more languages (currently 20+ supported)&lt;/li&gt;
&lt;li&gt;Improve prompts for specific languages (Rust ownership patterns, Python async best practices)&lt;/li&gt;
&lt;li&gt;Add a &lt;code&gt;--since&lt;/code&gt; flag to review only files changed since a git ref&lt;/li&gt;
&lt;li&gt;Write more tests
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Run the test suite (no live Ollama needed — all mocked)&lt;/span&gt;
pytest &lt;span class="nt"&gt;--cov&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;codesage
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Tech Stack
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Component&lt;/th&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Why&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AI Runtime&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://ollama.com" rel="noopener noreferrer"&gt;Ollama&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Local inference, zero cloud&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AI Models&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Gemma 3, CodeLlama, DeepSeek-Coder&lt;/td&gt;
&lt;td&gt;Open-weight, no API key&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;CLI Framework&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://typer.tiangolo.com" rel="noopener noreferrer"&gt;Typer&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Beautiful, type-safe CLI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Terminal UI&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://rich.readthedocs.io" rel="noopener noreferrer"&gt;Rich&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Markdown rendering, colours&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;HTTP Client&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://www.python-httpx.org" rel="noopener noreferrer"&gt;HTTPX&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;Async, streaming support&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Config&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://pypi.org/project/python-dotenv/" rel="noopener noreferrer"&gt;python-dotenv&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;.env&lt;/code&gt; support&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Testing&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;a href="https://pytest.org" rel="noopener noreferrer"&gt;pytest&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;27 tests, all mocked&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Resources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub:&lt;/strong&gt; &lt;a href="https://github.com/Nobody-KnowsBetter/code-sage" rel="noopener noreferrer"&gt;https://github.com/Nobody-KnowsBetter/code-sage&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ollama:&lt;/strong&gt; &lt;a href="https://ollama.com" rel="noopener noreferrer"&gt;https://ollama.com&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gemma 3 Model Card:&lt;/strong&gt; &lt;a href="https://ollama.com/library/gemma3" rel="noopener noreferrer"&gt;https://ollama.com/library/gemma3&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hacktoberfest:&lt;/strong&gt; &lt;a href="https://hacktoberfest.com" rel="noopener noreferrer"&gt;https://hacktoberfest.com&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;em&gt;Built with ❤️ for the Hacktoberfest 2026 DEV Challenge. If this saved you from shipping a bug, drop a ⭐ on GitHub!&lt;/em&gt;&lt;/p&gt;

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