Community Strata patch makes DeepSeek V4.1 agent sessions start 20x faster on a gaming GPU
A r/LocalLLaMA user patched Strata's DeepSeek engine so DeepSeek V4.1 Flash at 1M context on an RX 9070 XT with 64 GB RAM reaches first token far faster in agent sessions. A 'KV splice' removes per-session lines (working directory, date, CLAUDE.md) from the…
Why it matters
It pinpoints why per-session text in coding-agent system prompts defeats prefix caching, a cost every local agent setup pays.
What happened
1 min readA r/LocalLLaMA user patched Strata's DeepSeek engine so DeepSeek V4.1 Flash at 1M context on an RX 9070 XT with 64 GB RAM reaches first token far faster in agent sessions. A 'KV splice' removes per-session lines (working directory, date, CLAUDE.md) from the cached prefix instead of re-reading a ~37K-token system prompt, and prompt reading routes only to experts already in VRAM or RAM. It is tested on HIP only and posted as an unmerged branch.
Our analysis
The diagnosis is the most useful part: agents like OpenCode and Claude Code place volatile per-session text in the system prompt, which breaks prefix caching. Both fixes are approximate — spliced tokens were computed with the removed text in context, and substitute expert routing changes outputs slightly — with only one coding-suite run as evidence. The post also takes a jab at OpenAI's CEO over DRAM allocation, which is commentary rather than substance. Worth watching if it gets merged upstream; experimental for now.