Strands Decider: Why Not an Encoder?
Recorded: Oct. 14, 2026, 5:09 p.m.
| Original | Summarized |
Strands Decider: Why Not an Encoder? - Marc's Blog Marc's Blog About Me I am an engineer at Amazon Web Services (AWS) in Seattle, where I work on agentic AI, especially safety and policy for agentic AI. Before that, I worked on EC2, EBS, databases, serverless, and serverless databases. All opinions are my own. Is this blog written by AI? Strands Decider: Why Not an Encoder? As I admitted in my last post, I am very much not an expert model developer. What follows is likely to be, at least partially, inaccurate. I have tried to be careful and quantitative, to partially balance a lack of deep expertise. v19 is the final design for Qwen3.5-based strands-decider (check out the previous post and strands-decider README for the details). I also measured frozen ModernBERT and ettin-encoder-1b, but found that they under-performed T5Gemma parameter-for-parameter, and so didn’t invest time in training them. b2 does very well here, beating v19 on JevBench accuracy and Brier, and on JF100 Brier at the same accuracy. This is good, but recall that b2 has ~8B total parameters compared to v19’s 2B, and so is not an apples-to-apples comparison. The encoder-only models win handily on latency, with a median of around 35ms compared to v19’s 65ms. The encoder-decoder models are slowest. With half the latency and similar performance, this is looking like a big win for e1b. But thing get a little more complicated when we dive into the data. Here, we see that e1b wins handily at lower prompt lengths, but scales worse as the prompt grows. This is consistent with the great median performance. Whether this matters depends on the workload mix: both JF100 and JevBench trend small, to e1b’s benefit. The scaling difference here comes down to the compute costs of the two models: e1b has 26 full attention layers with the associated quadratic compute cost, while 75% of v19’s layers are Gated DeltaNet with linear compute cost. These layers have a higher fixed cost, but better asymptotic cost, leading to the higher latency floor2. Evaluation set Held-out short tasks MuSiQue ContractNLI BoardgameQA HotpotQA (held out) Generated, v16’s Generated, v18’s Adequacy, HelpSteer2 Adequacy, generated, balanced Where does that leave us on the encoders vs decoders question? Not very much closer to the truth, I fear. This experiment is hopelessly confounded, changing architectures, base models, instruction tuning vs base, and other variables. But we have learned some interesting things. Neither seems like a slam-dunk winner for this kind of work at this size. Some decoder ideas sneaking back in. Decoders do the same trick (KV cache and prefix cache) for the same reasons. Certain not for the first time memoizing incremental results has helped performance. « Back to the blog index Similar Posts 28 Sep 2026 » Small Decisions: Engineering a Leading Model Marc Brooker RSS This work is licensed under a Creative Commons Attribution 4.0 International License. |
Marc Brooker investigates the architectural choice between a decoder and an encoder design for language models, examining why a model like strands-decider was developed as a decoder rather than an encoder, given the hypothesis that bidirectional token representation might offer an advantage over causal representations. To test this, the author compared five different designs, including v19, an encoder-decoder design (b1 and b2), an encoder-only design (e1a), and a latency-optimized encoder-only version with a masked state cache (e1b). The comparison also included frozen models like ModernBERT. In terms of accuracy and calibration, the results were mixed. The encoder-decoder model b2 performed very well, surpassing v19 on JevBench accuracy and Brier scores, and achieving similar accuracy while also beating v19 on JF100 Brier. However, the comparison between v19 and e1b was more nuanced: e1b slightly outperformed v19 on JevBench accuracy while exhibiting worse calibration, tying on calibration for JF100 performance. The author suggests that this indicates no clear advantage for encoders in this specific task, acknowledging that the experiment is heavily confounded by variations in architecture, base models, and tuning methods. When analyzing latency, the encoder-only models demonstrated a significant advantage, achieving a median latency of approximately 35ms compared to v19’s 65ms. This suggests that encoder-only approaches are highly beneficial for speed. Specifically, e1b offered half the latency with comparable performance. The scaling behavior was complicated by the underlying computational costs; e1b, with its 26 full attention layers, incurred a quadratic compute cost, whereas v19 utilized Gated DeltaNet layers with a more linear compute cost, leading to a higher latency floor despite better asymptotic cost in the decoder structure. Further analysis focused on the encoder-only candidate, e1a, which, without the masked state cache of e1b, generally performed better than v19 across the evaluation sets, winning most tasks, although it performed worse on JevBench and JF100. This outcome leads the author to question whether attending to the state information bidirectionally imposes a limitation. Ultimately, the experiment does not provide a definitive answer regarding the superiority of encoders over decoders, but it highlights the complex trade-offs between representational capabilities, accuracy, calibration, and computational efficiency in large language model design. |