GLM 5 on Mac M3: Performance Observations for Agentic Coding

Performance Benchmarks and Limitations
A developer tested GLM 5 using MLX 4-bit quantization on a Mac M3 with 512GB RAM for agentic coding tasks. The model is described as "quite usable" with context kept below approximately 50,000 tokens, though significantly slower than API-based solutions like Claude, particularly during prompt processing.
Performance degrades substantially when context exceeds 50k tokens. In one test processing 65k tokens, the first half completed in 8 minutes (67 tokens/second), while the second half took 18 additional minutes, resulting in an overall rate of 41 tokens/second. Token generation remains faster, estimated at 12-20 tokens/second at larger context sizes.
Workflow Observations
The user notes that Opencode (the agentic coding system) handles multi-file code generation efficiently once a plan is created, outputting "thousands of tokens of code across multiple files in just a few minutes with reasoning in between." Prompt processing typically takes "a couple minutes" to read a few hundred lines of code per file, with about 10 minutes total spread across planning sessions.
Compaction in Opencode "does take a while as it likes to basically just reprocess the whole context." With a 50k token context limit, compaction takes approximately 5 minutes.
Technical Setup and Future Expectations
The test was conducted using LM Studio, which may not provide the latest runtime optimizations. The user suggests that "MLX or even GGUF may get faster prompt processing as the runtimes are updated for GLM 5, but it will likely not get a TON faster than this."
The setup is not recommended for tasks requiring 70k+ tokens in context due to both context size limitations and "unbearable slowness" that occurs after exceeding certain thresholds during prompt processing.
📖 Read the full source: r/LocalLLaMA
👀 See Also

Claude-ETA Plugin Adds Task Timing and Repair Loop Detection to Claude Code
Claude-ETA is a Claude Code plugin that times tasks, learns your actual velocity, and feeds real data back into Claude before it responds. It also detects repair loops by fingerprinting error content and intervenes after three identical failures.

Apideck CLI: A Low-Context Alternative to MCP for AI Agents
Apideck CLI is an AI-agent interface that uses ~80 tokens for its agent prompt instead of tens of thousands for tool schemas, addressing MCP's context window consumption problem. Benchmarks show MCP can cost 4 to 32× more tokens than CLI for identical operations.

sandboxd: Open-Source Tool to Run Multiple Claude Code Agents in Isolated Containers
sandboxd is an open-source (MIT) tool that runs each Claude Code project in its own Docker container with isolated workspace, Claude Code session, and preview URL. It supports parallel agents, auto-sleep, and keeps API keys out of containers.

claude-real-video: Free Tool to Make Claude Watch Videos with Perception Layer
claude-real-video adds a local perception layer so Claude sees camera moves, pacing, gestures, and voice emotion. Demo watches NVIDIA GTC 2026 keynote and narrates screen action. Free version available.