Skip to content
Enrique Tomás Martínez Beltrán
HomeResearchPublicationsTopicsTeachingBlog
Contact
EN/ES
HomeResearchPublicationsTopicsTeachingBlogContact
EN/ES

Enrique Tomás Martínez Beltrán

Postdoctoral research in AI, cybersecurity and federated learning, spanning threat analysis, closed-loop cyberdefense and trustworthy decentralized learning.

  • Privacy Policy
  • Terms of Service
  • Accessibility Statement
  • Google Scholaropens in a new tab
  • ORCIDopens in a new tab
  • LinkedInopens in a new tab
  • GitHubopens in a new tab
All profiles
  • ResearchGateopens in a new tab
  • Scopusopens in a new tab
  • DBLPopens in a new tab
  • Web of Scienceopens in a new tab

Enrique Tomás Martínez Beltrán. All rights reserved.

Back to top

This site loads optional analytics from Google and external analytics providers only if you accept. You can decline and continue using the site normally.

  1. Home
  2. Research Notes on Federated Learning, Cybersecurity and Cyberdefense
  3. Mixture of Experts in LLMs: Capacity Through Selective Routing
Mixture of ExpertsMoELLMsConditional ComputationTrustworthy AI

Mixture of Experts in LLMs: Capacity Through Selective Routing

Why sparse activation changes scaling, specialization and systems engineering

Enrique Tomás Martínez Beltrán

Postdoctoral Researcher in Computer Science

August 13, 202610 min read
  • LinkedInopens in a new tab
  • Xopens in a new tab
Mixture of Experts in LLMs: Capacity Through Selective Routing

Mixture-of-Experts models increase representational capacity without evaluating every expert for every token. A router selects a small subset of expert feed-forward networks, and their outputs are combined before the next transformer block.

The promise is conditional computation. The cost is systems complexity.

1. Sparse routing

For token representation hth_tht​ and experts E1,…,EmE_1,\ldots,E_mE1​,…,Em​, a top-kkk router can be written as:

gt=TopK⁡(Wrht),yt=∑i∈gtαt,iEi(ht).g_t = \operatorname{TopK}(W_r h_t), \qquad y_t = \sum_{i\in g_t} \alpha_{t,i}E_i(h_t).gt​=TopK(Wr​ht​),yt​=i∈gt​∑​αt,i​Ei​(ht​).

Only selected experts process the token, but all expert parameters still need to be stored, synchronized or available to the serving system.

2. Why load balance matters

If the router sends too many tokens to one expert, that expert becomes a bottleneck while other capacity is idle. If tokens are dropped because an expert reaches its capacity, quality can degrade in ways that are hard to attribute to the language model itself.

Balancing losses, capacity factors and routing noise are engineering controls, not decorative training details. They affect throughput, specialization and reproducibility.

3. Specialization is not automatically expertise

An expert may specialize by language, topic, syntax or a hidden artifact of the data. Inspecting routing patterns can reveal useful structure, but a high routing concentration does not prove that the expert learned a meaningful concept.

Evaluation should compare dense and sparse models under matched active computation, memory, communication and latency budgets.

4. Security and reliability questions

Routing can become a new attack surface. An adversarial input might target a congested expert, exploit a weak expert or create uneven resource use. Logs should expose routing load, dropped tokens, expert availability and changes after adaptation.

MoE is therefore not only a model architecture. It is a distributed service with a scheduler inside the forward pass.

This note is an original systems synthesis of MoE language-model design.

Further reading

  • Switch Transformers: Scaling to Trillion Parameter Models with Simple and Efficient Sparsity
  • Efficient Large Scale Language Modeling with Mixtures of Experts

Related Research

Large Language Models for Cybersecurity: A Careful Starting Point

August 13, 2026

Large Language Models for Cybersecurity: A Careful Starting Point

A practical map of LLM roles in cyberdefense, from threat-intelligence support to alert triage and explanation, with explicit limits and controls.

Autonomous Cyberdefense Needs More Than an LLM

August 13, 2026

Autonomous Cyberdefense Needs More Than an LLM

How to frame autonomous cyberdefense as a bounded control loop with evidence, policies, recovery paths and accountable human intervention.