<?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: Zohair</title>
    <description>The latest articles on DEV Community by Zohair (@zoh007).</description>
    <link>https://dev.to/zoh007</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%2F4056826%2Fb277df6f-1cdb-413e-8cc2-f5ce13732998.png</url>
      <title>DEV Community: Zohair</title>
      <link>https://dev.to/zoh007</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/zoh007"/>
    <language>en</language>
    <item>
      <title>Why I Stopped Using LLM-as-a-Judge (And What I Use Instead)</title>
      <dc:creator>Zohair</dc:creator>
      <pubDate>Tue, 04 Aug 2026 10:45:03 +0000</pubDate>
      <link>https://dev.to/zoh007/why-i-stopped-using-llm-as-a-judge-and-what-i-use-instead-3hf</link>
      <guid>https://dev.to/zoh007/why-i-stopped-using-llm-as-a-judge-and-what-i-use-instead-3hf</guid>
      <description>&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.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3bpkrr3de3p15lu8sb56.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.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3bpkrr3de3p15lu8sb56.png" alt=" " width="800" height="350"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Six months ago I was running evals on a coding Q&amp;amp;A dataset and my OpenAI bill hit $47 before I finished my test run. I wasn't doing anything exotic — just asking GPT-4 to score 500 model responses on a rubric. That's the hidden cost of LLM-as-a-Judge: every evaluation call is itself an API call, which means the more you evaluate, the more you pay.&lt;/p&gt;

&lt;p&gt;I spent a weekend building an alternative. The idea was simple: train a local binary classifier using Sentence Transformers and logistic regression to separate "good" from "bad" responses. No API. No cloud. No credit card. The result was a tool that runs at ~8ms per sample and costs $0 to operate indefinitely. It hit 75% accuracy on coding Q&amp;amp;A out of the box. Not perfect — but good enough to catch regressions, and fast enough to run in CI on every commit.&lt;/p&gt;

&lt;p&gt;Here's the full story of how it works, where it breaks, and when you should (and shouldn't) use it instead of GPT-4-based eval.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The Problem with LLM-as-a-Judge in 2026&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;1. Cost compounding: eval calls multiply with dataset size and iteration count&lt;/li&gt;
&lt;li&gt;2. Latency kills CI: 2-5 second API latency per sample = minutes for a 1,000-sample suite&lt;/li&gt;
&lt;li&gt;3. Bias and instability: 2026 research showing LLM judges are prompt-sensitive, exhibit taxonomic bias, and can flip scores with minor prompt rewording&lt;/li&gt;
&lt;li&gt;4. Lock-in: if the model changes upstream (GPT-4 → GPT-5), your eval scores drift even if your app didn't change&lt;/li&gt;
&lt;li&gt;5. The OpenAI-acquires-Promptfoo moment: what it means for "neutral" open-source eval&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;The Architecture of LLM Judge&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;1. Step 1: embed query + response pairs using sentence-transformers (all-MiniLM-L6-v2)&lt;/li&gt;
&lt;li&gt;2. Step 2: train a logistic regression classifier on labeled good/bad examples&lt;/li&gt;
&lt;li&gt;3. Step 3: at eval time, embed and classify — no network call, no API key&lt;/li&gt;
&lt;li&gt;4. Why logistic regression (not a neural classifier): interpretability, speed, no GPU required, works with small label sets&lt;/li&gt;
&lt;li&gt;5. Code snippet: full training loop in ~20 lines of Python&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;Benchmark: 75% Accuracy on Coding Q&amp;amp;A&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;1. Dataset description: coding question + model answer pairs, human-labeled&lt;/li&gt;
&lt;li&gt;2. How accuracy compares to random (50%) and human-agreement ceiling (~85%)&lt;/li&gt;
&lt;li&gt;3. Where the model is wrong: ambiguous cases, style vs. correctness confusion, edge cases in multi-step reasoning&lt;/li&gt;
&lt;li&gt;4. Honest take: this is not a replacement for human review on ambiguous cases — it's a regression detector&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;When to Use It (And When Not To)&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Use it: CI smoke tests, catching obvious regressions, high-volume eval where API cost is prohibitive, air-gapped / local-first environments, early-stage projects without budget&lt;/li&gt;
&lt;li&gt;Don't use it: nuanced long-form eval, multi-modal, tasks requiring domain expertise to label, when you need explainability on individual failures (logistic regression gives a score, not a reason)&lt;/li&gt;
&lt;li&gt;Hybrid approach: use LLM Judge for volume, LLM-as-a-judge for spot-checks on borderline cases&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;How to Extend It to Your Domain&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;1. Labeling your own dataset: minimum viable label set (~100–200 examples), how to use weak supervision to bootstrap&lt;/li&gt;
&lt;li&gt;2. Swapping the embedding model: when to use domain-specific embeddings (legal, medical, code-specific)&lt;/li&gt;
&lt;li&gt;3. Adding multi-class scoring: extending from binary (good/bad) to rubric-based (0–3)&lt;/li&gt;
&lt;li&gt;4. Integration patterns: pytest plugin, pre-commit hook, GitHub Actions step&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;What's Next&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;1. Pre-trained domain packs (coding, customer support, RAG faithfulness)&lt;/li&gt;
&lt;li&gt;2. LangChain / LlamaIndex integration&lt;/li&gt;
&lt;li&gt;3. Active learning loop: flag low-confidence samples for human review, retrain&lt;/li&gt;
&lt;li&gt;4. Link to GitHub: github.com/Zoh007/llm-judge — PRs and issues welcome&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;What's your current eval setup? Are you paying for API-based eval, running something local, or just skipping evals entirely? I'm curious what's actually working for people in production.&lt;/p&gt;

</description>
      <category>llm</category>
      <category>python</category>
      <category>opensource</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>The Promptfoo Acquisition Made Me Realize I Was Evaluating LLMs on Easy Mode</title>
      <dc:creator>Zohair</dc:creator>
      <pubDate>Mon, 03 Aug 2026 23:04:01 +0000</pubDate>
      <link>https://dev.to/zoh007/the-promptfoo-acquisition-made-me-realize-i-was-evaluating-llms-on-easy-mode-9jh</link>
      <guid>https://dev.to/zoh007/the-promptfoo-acquisition-made-me-realize-i-was-evaluating-llms-on-easy-mode-9jh</guid>
      <description>&lt;p&gt;In March 2026, OpenAI acquired Promptfoo — the tool that 350,000 developers use to evaluate and red-team OpenAI's own models.&lt;/p&gt;

&lt;p&gt;I don't think that makes Promptfoo suddenly useless. But it made me ask a question I should have asked earlier: who is the eval tool accountable to?&lt;/p&gt;

&lt;p&gt;Most LLM eval frameworks — DeepEval, Ragas, LangSmith — have something in common. They all route scoring through an LLM API call. That means your eval pipeline has at least three dependencies you don't control: the tool vendor, the judge model vendor, and whatever pricing changes either of them makes next quarter.&lt;/p&gt;

&lt;p&gt;When I started building LLM Judge, I wasn't thinking about vendor independence. I was thinking about cost. I was running evaluations on a coding Q&amp;amp;A dataset, and every DeepEval run was making LLM API calls I hadn't budgeted for. It added up fast.&lt;/p&gt;

&lt;p&gt;So I tried something simpler: train a classifier. Sentence Transformers to embed the responses, logistic regression to classify quality. The result: 75% accuracy on coding Q&amp;amp;A, ~8ms per sample, $0 per run, runs fully offline.&lt;/p&gt;

&lt;p&gt;It's not magic. It won't replace human review for high-stakes decisions. But for fast feedback loops in CI/CD — the place where LLM eval matters most — it's surprisingly good.&lt;/p&gt;

&lt;p&gt;What this approach gives you:&lt;/p&gt;

&lt;p&gt;No API key required. Ship to air-gapped environments, run in restricted CI, deploy anywhere Python runs.&lt;br&gt;
No vendor lock-in. You own the model. You trained it. No one can deprecate it out from under you.&lt;br&gt;
Speed that fits CI. 8ms/sample means you can eval 1,000 outputs in under 10 seconds.&lt;br&gt;
Customizable to your domain. Fine-tune on your data and your definitions of "good."&lt;/p&gt;

&lt;p&gt;The tradeoff: you need labeled training data. If you have zero examples, start with a small hand-labeled set. 50–100 examples is enough to get a useful baseline classifier.&lt;/p&gt;

&lt;p&gt;How to get started:&lt;/p&gt;

&lt;p&gt;pip install llm-judge&lt;/p&gt;

&lt;p&gt;Then train on your data and run evals locally. No signup. No API key. No monthly bill.&lt;/p&gt;

&lt;p&gt;The Promptfoo situation is a useful reminder: the best eval tool is one you understand, own, and can run independently of whoever built the model you're testing.&lt;/p&gt;

&lt;p&gt;→ github.com/Zoh007/llm-judge&lt;/p&gt;

&lt;p&gt;What's your current eval setup? Especially curious if anyone's moved away from API-dependent evals — drop a comment.&lt;/p&gt;

</description>
      <category>llm</category>
      <category>python</category>
      <category>opensource</category>
      <category>machinelearning</category>
    </item>
    <item>
      <title>How I Built a No-Execution LLM Eval Judge (75% Accuracy, No API Calls)</title>
      <dc:creator>Zohair</dc:creator>
      <pubDate>Fri, 31 Jul 2026 15:01:50 +0000</pubDate>
      <link>https://dev.to/zoh007/how-i-built-a-no-execution-llm-eval-judge-75-accuracy-no-api-calls-4lna</link>
      <guid>https://dev.to/zoh007/how-i-built-a-no-execution-llm-eval-judge-75-accuracy-no-api-calls-4lna</guid>
      <description>&lt;p&gt;Evaluating LLM outputs is one of those problems that sounds simple until you actually try to do it at scale.&lt;/p&gt;

&lt;p&gt;Most approaches fall into three buckets:&lt;/p&gt;

&lt;p&gt;Run the code — works for coding tasks but requires a sandbox, is slow, and breaks on edge cases constantly.&lt;/p&gt;

&lt;p&gt;GPT-4 as a judge — surprisingly effective but costs money, adds latency, and feels wrong to use one LLM to evaluate another.&lt;/p&gt;

&lt;p&gt;Manual review — fine for 50 samples. Completely falls apart at 1,500+.&lt;/p&gt;

&lt;p&gt;I wanted something different. Fast, local, no API calls, no execution environment, no cost per eval. So I built LLM Judge.&lt;/p&gt;

&lt;p&gt;How it works&lt;/p&gt;

&lt;p&gt;The core insight is simple: semantic similarity between a model output and a reference answer is a surprisingly strong signal for correctness — especially for coding questions where there's usually one right approach.&lt;/p&gt;

&lt;p&gt;Here's the pipeline:&lt;/p&gt;

&lt;p&gt;Model output + Reference answer&lt;br&gt;
          ↓&lt;br&gt;
Sentence Transformers (all-MiniLM-L6-v2)&lt;br&gt;
          ↓&lt;br&gt;
Cosine similarity score&lt;br&gt;
          ↓&lt;br&gt;
Logistic regression classifier&lt;br&gt;
          ↓&lt;br&gt;
Correct / Partially correct / Incorrect + calibrated confidence score&lt;/p&gt;

&lt;p&gt;I trained the logistic regression on a merged Hugging Face coding Q&amp;amp;A dataset, validated on 1,500+ labeled submissions.&lt;/p&gt;

&lt;p&gt;Results&lt;br&gt;
~75% accuracy on held-out coding Q&amp;amp;A split&lt;br&gt;
~58% agreement with human judges on 1,500+ labeled submissions&lt;br&gt;
Runs entirely locally — no API calls, no sandbox&lt;br&gt;
Fast enough for batch evaluation at scale&lt;/p&gt;

&lt;p&gt;The 58% human agreement number is the interesting one. Human judges disagree with each other more than you'd expect on coding questions — so 58% agreement with humans is actually competitive with inter-human agreement on ambiguous cases.&lt;/p&gt;

&lt;p&gt;What I built&lt;/p&gt;

&lt;p&gt;Three interfaces for different use cases:&lt;/p&gt;

&lt;p&gt;CLI batch scoring — point it at a CSV of model outputs and reference answers, get scores back:&lt;/p&gt;

&lt;p&gt;bash&lt;br&gt;
python evaluate_csv.py --input outputs.csv --output scores.csv&lt;/p&gt;

&lt;p&gt;Training your own judge:&lt;/p&gt;

&lt;p&gt;bash&lt;br&gt;
python train_judge.py --dataset your_dataset.csv&lt;/p&gt;

&lt;p&gt;Streamlit UI — visual interface with calibrated scores and 3-tier feedback for each eval:&lt;/p&gt;

&lt;p&gt;bash&lt;br&gt;
streamlit run app.py&lt;br&gt;
Stack&lt;br&gt;
Python&lt;br&gt;
Sentence Transformers&lt;br&gt;
Scikit-Learn&lt;br&gt;
Streamlit&lt;br&gt;
Pandas&lt;br&gt;
What's next&lt;/p&gt;

&lt;p&gt;The open source version handles local evaluation. I'm building a hosted API version next — upload your dataset, get scores back via API, no setup required. If that's something you'd use, let me know in the comments.&lt;/p&gt;

&lt;p&gt;Try it&lt;/p&gt;

&lt;p&gt;GitHub: &lt;a href="https://github.com/Zoh007/RAG_PRAC" rel="noopener noreferrer"&gt;https://github.com/Zoh007/RAG_PRAC&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Would love feedback from anyone doing LLM evaluation at scale — especially curious:&lt;/p&gt;

&lt;p&gt;Is 75% accuracy good enough for production eval pipelines?&lt;br&gt;
What edge cases do you run into that simple similarity scoring misses?&lt;br&gt;
Would a hosted API be worth paying for or would you always self-host?&lt;/p&gt;

</description>
      <category>llm</category>
      <category>machinelearning</category>
      <category>python</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
