GhostSwitch

Experiment

Small model. Expert answers.

An AI assistant that runs entirely on your computer. It keeps one Qwen3.5 model in memory and, for each message, attaches the LoRA expert that fits: code, finance, law, math, Verilog, CAD and two dozen more. Then plain code checks the answer before you see it.

The GhostSwitch chat: a Python question answered by the coding expert, with the response details panel open
A coding question routed to coding_expert. Every answer shows its route, speed, tokens and checks.

How it works

One base model stays loaded. A 30–330 MB adapter is attached only for the request that needs it, so a library of one expert or a thousand needs the same memory: the base model plus at most 512 MB of recently used adapters.

1 · ROUTE

Pick the expert

Short model calls walk a tree of fields and choose among the experts you turned on, or the plain base model.

2 · ATTACH

Swap the adapter

The LoRA goes onto the model already in memory in 0.1–0.3 s. No reload.

3 · GENERATE

Answer

Optionally with web search and cited sources, and step-by-step thinking when the task needs it.

4 · CHECK

Verify in code

Arithmetic, JSON fields and citations are checked by code, not by another model. A failed check means a retry.

Request, route, attach the expert, generate, check: accept, retry with the same expert up to four times, or fail

Measured, not assumed

An adapter that sounds good on its model card does not always beat the model it was trained on. 13 of the 9B experts each got 60 questions from a public benchmark of their field, and the bare base model got the same 60. Experts that are no better are blocked from routing.

ExpertBenchmarkBaseExpertpVerdict
codingHumanEval+76.7%88.3%0.039Verified
legal contractsLegalBench CUAD76.7%83.3%0.125Leaning better
privacy / PIIGretel PII, F175.3%78.3%0.180Leaning better
software engineeringHumanEval+76.7%81.7%0.508Undecided
financeFinQA61.7%66.7%0.549Undecided
reasoningGSM8K, no thinking88.3%90.0%1.000Undecided
DeltaCoderHumanEval+76.7%78.3%1.000Blocked
text-to-SQLGretel, run in SQLite58.3%58.3%1.000Blocked
medicalMedQA66.7%65.0%1.000Blocked
pentestpentesting-eval88.3%86.7%1.000Blocked
IaC securityTerraform S3 MCQ53.3%51.7%1.000Blocked
entity extractionCoNLL-2003, F167.4%67.2%0.720Blocked
CWE classificationCTI-Bench56.7%51.7%0.508Blocked

Qwen3.5-9B Q4_K_M, answer checks and thinking off for both sides, paired sign test. 60 questions detect differences of about 10 points, so “undecided” means undecided. Every answer is in the evaluation dataset.

Install

One command installs GhostSwitch and opens it in your browser. It brings its own Python and needs no administrator rights. On first run it checks your hardware, recommends Qwen3.5-9B or 4B and downloads it.

macOS (Apple Silicon) and Linux
curl -fsSL https://raw.githubusercontent.com/hiddenway/GhostSwitch/main/install.sh | sh
Windows 10 or 11, in PowerShell
irm https://raw.githubusercontent.com/hiddenway/GhostSwitch/main/install.ps1 | iex

16 GB of memory

Qwen3.5-9B with 27 experts. 8 GB is enough for the 4B model with 6 experts.

MLX or llama.cpp

MLX on Apple Silicon; llama.cpp with CUDA on NVIDIA, or on the CPU, on Linux and Windows.

OpenAI-compatible API

Streaming, function tools, images and files at /v1/chat/completions. Works as a model in OpenCode.

Private by default

Chats stay on your computer. It goes online only to download models and experts, and for web search if you turn it on.

GhostSwitch is an experiment. So far one expert is measurably better than the base model, routing is slow and sometimes picks the wrong expert, and the API may change. On an M1 Pro the 9B model writes 13–18 tokens per second, so a full answer with routing and thinking takes about a minute. Do not rely on its answers for medical, legal, financial or security decisions.