Running Gemma 4 Directly Inside Godot
toxicdog · reddit · 2026-07-13
The author successfully ran `gemma-4-E2B-it-Q4_K_M.gguf` directly within a Godot 4.7 project, aiming to prove that local LLM execution is possible inside the engine **without relying on llama.cpp, Python, external servers, or GDExtension**. The implementation breaks down as follows: - **Vulkan compute shaders** handle the model computation. - **GDScript** manages GGUF loading, tokenization, sampling, the KV cache, and the chat UI. Currently, the experiment is restricted to this specific model. It runs about **10 times slower** than llama.cpp with CUDA, and the author explicitly labels it as a proof-of-concept. Nevertheless, it proves that a fully local LLM inference pipeline can be constructed using Godot alone.
More from coding & agent
- Autoresearch proposes packaging ML runs as studies with questions, analysis, and code diffs — morgymcg · 2026-07-21
- CHAP defines approvals, handoffs, and audit logs for human-agent workflows — DeliveryTechnical199 · 2026-07-21
- The author says Codex reached 20x and is now debugging spec decoding on a hybrid parallel setup — TheZachMueller · 2026-07-21
- Axcess adds an MCP connector for WCAG accessibility checks that scanners miss — modelcontextprotocol · 2026-07-21
- X post asks whether Cursor Composer, built on Kimi models, would also be banned — max_paperclips · 2026-07-21
- A developer’s Codex usage is draining pooled enterprise credits at a small company — Distinct_Relation_62 · 2026-07-21