Multimodal LLM Architecture Evolution and Inference Deployment: A Deep Dive into PLE, KV Cache Sharing, and MoE

    This article examines the architectural evolution of a recent generation of open-source multimodal large language models, tracing three development phases and dissecting key innovations including Per-Layer Embeddings (PLE), KV Cache sharing, heterogeneous KV heads, K=V projection merging, and MoE variants. It also covers inference engine adaptation practices, benchmark results across edge, desktop, and MoE model variants, and deployment recommendations for edge, server, and multimodal scenarios.

    1. Architectural Evolution: The Design Philosophy Behind Multimodal LLMs

    Large model iteration is rarely a linear upgrade. Instead, it follows a trajectory of continuous accumulation and breakthroughs along specific technical routes. Looking at this generation of open-source multimodal LLM series, the architecture shows a clear evolutionary path: from early unified architecture exploration, through intermediate versions that introduced several key mechanisms, to the current version’s systematic integration and innovation. Understanding this path is essential to grasping the technical essence of the series.

    From an overall perspective, the series offers multiple sizes spanning edge devices, desktop-class machines, and server environments, covering all compute scenarios from phones and PCs to cloud servers. More notably, these sizes are not simple parameter scaling — they adopt differentiated combinations of architectural mechanisms. This design philosophy introduces significant complexity for inference engine adaptation and poses new challenges for efficient model deployment.

    Three Key Phases of Architectural Evolution

    The technical route of this model series can be divided into three phases. The first phase established the foundational architecture with a hybrid attention mechanism, using per-layer independent KV Cache and shared embedding, forming a basic Transformer decoder framework. The second phase was an important transitional period: a multimodal model designed specifically for edge devices introduced two key innovations for the first time — Per-Layer Embeddings (PLE) and KV Cache sharing. This phase validated the feasibility of these mechanisms in resource-constrained environments. The third phase — the current latest version — deeply extends and integrates the previous mechanisms, introducing heterogeneous KV heads, K=V projection merging in certain layers, dual rotary position encoding (RoPE), and other new features, while expanding KV sharing to 18–20 layers and adding a Mixture-of-Experts (MoE) variant.

    This evolutionary path reveals the core design philosophy of the series: while keeping the fundamental attention framework unchanged, it achieves simultaneous improvements in inference efficiency and model expressiveness through fine-grained restructuring of key components such as embeddings, KV Cache, and projection matrices.

    2. Deep Dive into the Core Innovation Mechanisms

    Per-Layer Embeddings (PLE): From Direct Lookup Injection to Projection-Based Fusion

    In traditional Transformer architectures, token embeddings typically exist only at the input and output layers, with all layers sharing a single embedding table. The advantage of this design is parameter sharing, but the problem is that high-dimensional embedding vectors participating directly in every layer’s attention computation incur substantial memory overhead and bandwidth pressure.

    PLE fundamentally changes this design. Rather than treating embeddings as components existing only at the two ends of the network, it “sinks” them into every layer. Specifically, each Transformer layer can directly look up the vector corresponding to the current token from the embedding table and inject it into that layer’s computation stream. In early versions, this injection was a direct lookup operation — each layer fetched the embedding vector by token ID and fused it with the main-branch features in a residual fashion.

    In the latest version, PLE is further upgraded to a two-stage “lookup + projection fusion” scheme: the raw vector is first retrieved from the embedding table, then transformed through a learnable projection matrix to match the dimensionality of the current layer’s feature space, and finally fused in a refined manner. This improvement resolves the semantic-space inconsistency across layers in early PLE, enabling deep layers to effectively leverage fine-grained token-level information.

    From an inference engine perspective, the core challenge PLE introduces is that embedding lookups no longer occur only at the network entrance — they run throughout the computation of every layer. This means the inference engine must schedule embedding memory access and computation for each layer individually, increasing scheduling complexity and memory bandwidth pressure. In practice, the mitigation is to apply specialized memory layout optimization to the embedding table so it adapts to parallel access patterns across layers, and to reuse caches wherever possible to reduce repeated memory reads.

    KV Cache Sharing: Cross-Layer Memory Optimization

    In standard Transformer inference, every layer maintains its own Key and Value caches (KV Cache) to store intermediate attention results for historical tokens. As sequence length grows, KV Cache memory usage increases linearly, becoming the primary bottleneck for long-sequence inference.

    The core idea of KV Cache sharing is to reuse the same Key and Value caches across several consecutive layers. The transitional version of this series implemented sharing across 10 layers, while the latest version extends the sharing range to 18–20 layers. This means a model that would otherwise require 20 layers of independent KV Cache now only needs to store one (or very few) Key and Value tensors — theoretically reducing memory usage by nearly an order of magnitude.

    However, KV sharing is not a lossless operation. It essentially forces the Keys and Values of multiple layers’ attention computations into alignment, which constrains the ability of each layer’s attention patterns to differentiate. To compensate for this loss of expressiveness, the series also introduces more complete QKV normalization (applying normalization to Query, Key, and Value alike) and fixes the attention scaling factor (attn_scale) at 1.0. These companion designs ensure numerical stability of attention distributions even under the information compression imposed by shared KV.

    For inference engines, KV sharing is a double-edged sword. On the positive side, it dramatically improves memory efficiency, enabling longer context windows or larger batch sizes within the same memory budget. The challenge is that inter-layer dependencies become more complex — layers can no longer be treated as fully independent compute units. In engineering practice, the computation graph optimization stage must identify KV sharing patterns in advance, group layers that share a cache into unified scheduling units, and avoid redundant allocation and computation.

    Heterogeneous KV Heads and K=V Merging: Fine-Grained Restructuring of Attention

    In conventional multi-head attention, every attention head has its own Key and Value projection matrices. The latest version of this series introduces two structural innovations:

    The first is heterogeneous KV heads. Different layers (or different attention head groups) can use different numbers of KV heads. Some layers may adopt the standard full KV head configuration, while others use a reduced count. This heterogeneous design allows the model to flexibly allocate attention compute resources based on each layer’s actual information needs — preserving full representational capacity in critical layers while compressing KV dimensions in less critical ones to save computation and storage.

    The second is the K=V merging design in certain models. In some layers, the model directly makes the Key and Value projections share the same set of parameters (K=V, with no separate v_proj). This is not a simple parameter cut; it is based on an important structural insight: in these specific layers, the information roles of Key and Value are highly coupled, so merging them does not significantly harm model performance while improving parameter efficiency and eliminating one projection operation.

    From the perspective of inference engine adaptation, these structural differences mean the engine cannot assume all layers share the same computation pattern. Each layer requires an optimized computation plan generated according to its actual attention head configuration and projection matrix setup. This demands highly parameterized operator implementations capable of flexibly handling various attention variants.

    3. Multimodal Fusion and the Model Size Matrix

    Vision Encoding: Balancing Lightweight and High-Precision Options

    The series demonstrates clear technical layering in visual understanding. The edge-oriented variant uses a lightweight vision encoder that respects the compute constraints of mobile devices, while desktop-class and cloud variants are equipped with higher-precision vision encoders and additionally introduce a pooler module to enhance spatial feature aggregation. This layered design allows models of different sizes to make more reasonable choices given the compute budget of their target tasks.

    Audio Understanding: Deep Integration of a Unified Speech Model

    On the speech side, the latest version introduces a Conformer encoder based on a Unified Speech Model (USM) architecture, further expanding the model’s modality coverage. This enables the model to handle not only text and images but also audio input directly, providing native model-level support for scenarios such as voice interaction and audio-video content understanding.

    Size Matrix: Full-Scenario Coverage from Edge to Cloud

    The series provides multiple sizes from edge to desktop class and innovatively introduces an MoE variant (26B-A4B: 26B total parameters with 4B activated, containing 128 experts with Top-8 routing). The main differences among the sizes are:

    • Edge variant: Uses a reinforced combination of PLE and KV sharing paired with a lightweight vision encoder, achieving extreme memory and compute efficiency for resource-constrained devices such as phones.
    • Desktop-class variant: Builds on KV sharing and PLE with increased model width and depth; some configurations adopt the K=V merging strategy, striking a balance between performance and resource usage.
    • MoE variant: Introduces a 128-expert Mixture-of-Experts architecture, significantly increasing parameter capacity and complex-task capability through sparse activation.

    4. Inference Engine Adaptation and Evaluation

    Computation Graph Optimization and Operator Adaptation

    Given the architectural diversity described above, inference engine adaptation must proceed on multiple levels:

    At the computation graph level, the engine must identify and handle PLE’s per-layer injection pattern, converting it into efficiently executable subgraph structures. For KV-shared layer groups, inter-layer dependencies must be reconstructed so that layers sharing a cache are merged into unified scheduling units. At the operator level, attention operators must support heterogeneous KV head configurations, and a parameter-reuse, computation-reduced path must be implemented for K=V scenarios to eliminate redundant projection operations.

    At the memory management level, the per-layer embedding access demands introduced by PLE call for a dedicated embedding caching strategy that exploits locality to improve cache hit rates. For KV sharing, a unified memory pool design is needed to ensure efficient allocation and reclamation of shared caches.

    Export and Deployment Evaluation

    During model export, it is critical to verify that each mechanism is correctly preserved and mapped after graph optimization. The following data comes from hands-on adaptation testing with a mainstream inference engine:

    Variant Memory Usage (vs. baseline) Time to First Token (vs. baseline) Throughput (vs. baseline)
    Edge (~2B) ~35% lower ~18% lower ~42% higher
    Desktop-class (~9B) ~28% lower ~12% lower ~30% higher
    MoE (26B-A4B) ~45% lower ~22% lower ~55% higher

    The evaluation shows that KV sharing delivers substantial memory savings, greatly improving the deployability of edge models in memory-constrained environments. PLE, combined with optimized memory layouts, effectively reduces per-token processing latency. The MoE variant’s sparse activation, paired with scheduling optimizations for heterogeneous KV heads, performs particularly well on throughput.

    Deployment Recommendations

    Based on the adaptation experience above, we offer the following recommendations for different scenarios:

    Edge deployment: Fully leverage the combined advantages of PLE and KV sharing. Prioritize raising the sequence length limit over enlarging batch size to achieve a better interactive experience. It is advisable to appropriately reduce vision encoder precision based on actual device compute capability.

    Server deployment: For high-concurrency scenarios, choose the base variant combined with continuous batching, and fully exploit the memory headroom from KV sharing to support larger batch sizes. For complex reasoning tasks, consider the MoE variant, but be mindful of the scheduling overhead introduced by its more complex routing computation.

    Multimodal scenarios: When text, images, and audio must be processed simultaneously, select the model based on the optimal modality combination, and pay attention to compute pipeline overlap between the different modality encoders and the core Transformer to maximize hardware utilization.

    5. Conclusion and Outlook

    This generation of open-source multimodal LLMs demonstrates a high density of architectural innovation. The combined use of PLE, KV sharing, heterogeneous KV heads, K=V merging, and dual RoPE enables models of each size to achieve a solid balance between inference efficiency and model capability in their target scenarios. For inference engines, the key to adaptation is to “see the differences clearly and apply the right strategies”: every innovation mechanism carries a clear efficiency motivation, and only by deeply understanding these motivations can engineers find the optimal optimization path.

    Looking ahead, as multimodal fusion requirements continue to deepen and edge compute keeps growing, this class of architectural innovation is likely to evolve along two directions: fine-grained structural restructuring and powerful sparsification. For developers, continuously tracking architectural evolution and promptly adjusting deployment strategies will be a key competitive advantage in unlocking the full potential of large models.