Qwen3.5-4B-GLB-3D-Coder · Sirpi tune (MLX 4-bit)
A LoRA fine-tune of ccore/Qwen3.5-4B-GLB-3D-Coder (itself based on Qwen/Qwen3.5-4B) that writes one standalone Three.js HTML file per request, with an Export GLB button. It adds better FDM 3D-printing output (real millimetre sizes, one fused piece, a flat base) and writes about half as much code per asset, so each asset finishes in roughly half the time.
Weights are 4-bit MLX for Apple silicon (about 2.4 GB).
Use it in Sirpi (Mac app)
Sirpi (சிற்பி, "sculptor" in Tamil) is a free, open-source macOS app built around this model. It downloads the model on first launch and runs it inside the app on the GPU, so nothing leaves your Mac.
- Describe an object or attach a picture; Sirpi asks a few follow-up questions, then writes and previews it live.
- Game assets (GLB for Godot and other engines), 3D prints (real size in mm) or whole scenes.
- Click a part of the model and say what to change; every asset keeps one conversation of versions.
- Prepares, checks and slices prints for Bambu Lab printers (overhangs, bridges, supports, AMS filament) and sends them over the local network.
- Can also use coding agents you already have (Claude Code, Kimi Code, Codex, Gemini CLI and others) or cloud APIs.
Download Sirpi for macOS (Apple silicon, macOS 27 or later).
All credit for the underlying model goes to CCORE and the Qwen team. This is an independent tune, not an official release of either.
What changed
Self-distillation with verification, no outside data:
- The base model wrote 3 answers each for 146 game-asset prompts and 6 each for 96 print prompts (1,014 answers).
- Every answer was run in a headless browser and checked: page loads, no script errors, GLB exports. Print answers were also scored for size accuracy, a single connected piece, closed surfaces and a flat base.
- The best passing answer per prompt was kept (129 training, 12 validation examples).
- LoRA on every linear layer (rank 16, scale 8, lr 5e-5 cosine, 258 iterations, prompt masked), fused into the bf16 weights, then quantized to 4-bit (group size 64).
Evaluation
50 held-out prompts (30 game, 20 print), one sample each, temperature 0.8, both models at 4-bit MLX.
| Print prompts (20) | Base | This model |
|---|---|---|
| Works end to end (loads, no errors, valid GLB) | 55% | 80% |
| GLB exported | 60% | 85% |
| Print score (0-100, failures count as 0) | 39.1 | 55.0 |
| Size within 30% of the request | 10% | 40% |
| Single connected piece | 45% | 55% |
| Closed surfaces (avg) | 0.97 | 0.90 |
| Avg output tokens | 12,786 | 5,233 |
| Game prompts (30) | Base | This model |
|---|---|---|
| Works end to end | 63% | 70% |
| No script errors | 80% | 70% |
| Avg output tokens | 12,550 | 6,337 |
Generation speed per token is unchanged (about 150 tokens/s batched on an M-series Mac); assets finish faster because they are shorter. 14 prompts that failed before now work; 7 that worked before now fail. With one sample per prompt these numbers are noisy, so treat them as a direction rather than a precise measure.
Known weakness: game assets have script errors a little more often than with the base model. Retry, or feed the error back to the model.
How to use
pip install mlx-lm
mlx_lm.generate --model Chandrasekar/Qwen3.5-4B-GLB-3D-Coder-Sirpi-MLX-4bit \
--temp 0.8 --top-p 0.95 --top-k 40 --max-tokens 16000 \
--system-prompt "<one of the prompts below>" --prompt "Create a phone stand that holds a phone at 60 degrees, 80 mm wide."
Save the HTML, open it in a browser and click Export GLB.
Settings: temperature 0.8, top-k 40, top-p 0.95, min-p 0.
System prompt: game assets (same as the base model)
Create game assets for the Godot editor, which uses GLB files. Create whatever the user requests as a good-quality low-poly asset using only Three.js in one complete standalone HTML file. The HTML must show the asset and include an Export GLB button that downloads a working GLB. If the requested asset needs animation, add it and include the animation in the exported GLB; otherwise make it static.
System prompt: 3D printing
Create objects for FDM 3D printing (Bambu Lab printer, 256 mm build plate) using only Three.js in one complete standalone HTML file. Model the requested object at its real size in millimetres (1 unit = 1 mm) as one solid, watertight piece: parts must overlap so they fuse, nothing may float, it must stand on a flat base resting on y = 0, walls must be at least 2 mm thick, and overhangs should stay under 45 degrees where possible. The HTML must show the object, state its size in mm, and include an Export GLB button that downloads a working GLB of the object only.
License and credits
Apache 2.0, the same as the base model (see LICENSE).
- Base model: ccore/Qwen3.5-4B-GLB-3D-Coder by CCORE (November 2, 2026 checkpoint).
- Foundation model: Qwen/Qwen3.5-4B by the Qwen team.
- Fine-tuning done with mlx-lm.
