Automate My Old Jobs

Principal Consultant

Possible Futures, LLC · LLM_tuning_demonstration + llm-eval-gate · Build time: 1.2 hrs (Colab T4 run + eval gate)

Clients want proof before investing in fine-tuning: does LoRA actually move the needle on domain tasks, can we trust the eval gate, and at what volume does self-hosting beat an API?

What the machine does, and what stays human

Automated by LLM_tuning_demonstration + llm-eval-gate

  • Real Colab Tesla T4 4-bit NF4 QLoRA run (Qwen/Qwen2.5-1.5B-Instruct, 600 train / 100 val / 100 held-out PubMedQA test, 6.64 GB VRAM, 10.3 min) with full JSON results committed.
  • Paired CI regression gates (llm-eval-gate): Cohen's κ judge calibration, exact McNemar + bootstrap 95% CIs, hard safety/schema gates.
  • Monthly-volume build-vs-buy TCO modeling across frontier API, mid-tier API+RAG, and amortized self-hosted 8B fine-tune.

Stays human

  • Labeling the initial human gold set and defining business error-cost asymmetry.
  • Schema design calls (e.g., ordering rationale before verdict after error analysis) and class-imbalance strategy.
  • Compliance (HIPAA/GxP), data-residency, and final go/no-go capital allocation with the client.

Results

Colab T4 QLoRA (PubMedQA, N=100)Strict JSON verdict acc 58.0% → 68.0% (+10.0 pp) · Macro-F1 0.389 → 0.477 · JSON validity 98% → 100% · Val loss 2.037 → 1.522
Paired McNemar & Throughput17 improved vs. 7 regressed (exact McNemar p=0.0639 at N=100) · 96.3 → 44.9 tok/s unmerged PEFT (proving merge necessity)
Judge Calibration Audit (llm-eval-gate)Rejects lenient judge (κ=0.500, +15 pp bias); approves calibrated judge (κ=0.867, 0 pp bias)
Build-vs-Buy CrossoverMid-tier API wins 10k–250k req/mo ($10–$260/mo); self-hosted fine-tune wins ≥1M req/mo ($950 vs $1,040–$5,200/mo)

Where it fails