LM Studio and OpenCode: local coding setup with Qwen
Learn to connect LM Studio to OpenCode, choose Qwen models for your memory budget, and test a React notes app that still needs fixes.
Player not loading? Watch on YouTube
Philip walks through a local AI coding setup with LM Studio as the model server and OpenCode as the terminal coding assistant. He installs the tools on macOS, downloads a model, enables the server, and connects OpenCode through a JSON configuration with the server URL and exact model identifier. He also explains that OpenCode's context setting should match LM Studio's configured window; it does not override the server's limit.
The model discussion covers parameter counts, quantization, and GGUF versus MLX, which he recommends for Apple silicon. His suggested minimum for agentic coding is 24 GB of dedicated GPU memory or 32 GB of Apple unified memory. These are his workflow recommendations, rather than universal requirements to run models locally.
He presents Qwen 2.5 Coder 32B at four-bit quantization as an option occupying roughly 18 GB, but reports trouble getting it to edit files through tools. His preferred Qwen3 Coder Next configuration has 80 billion parameters and occupies about 45 GB at four-bit quantization.
The practical test asks for a React notes app. Philip reports about three minutes of generation and an extra instruction to use Vite. The resulting app can create and delete notes, but editing fails. He values offline operation and keeping prompts on the machine, while preferring cloud frontier models for difficult coding tasks.