Skip to content
AI-generated research idea🟠Medium💡Moderate InnovationNo close match found

Fixed-Size Key-Value Prefix Compression for Multi-Expert Soft Prompts

Compress multi-expert soft-prompt sequences into fixed-size key-value cache prefixes to decouple inference memory footprint from the number of active domain experts.

Time

several weeks

Compute level

Multiple GPUs

Resources

1-2 GPUs (e.g. RTX 4090 or A100), public math/code/instruction benchmarks

What the paper used

Distillation of 256-vector soft prompts on Qwen3-4B and GPT-OSS-20B backbones using Muon optimizer for 200 updates with batch size 64; serving benchmarked on single NVIDIA B200 GPU.

Prerequisites

transformer architectures, soft prompt tuning, KV cache attention

Scope

new model architecture

The Gap

In Section 2.2 and Section 5, CSPD concatenates continuous soft-prompt embedding vectors directly into the input system message prefix. Each soft prompt adds 256 vector positions to the context, causing linear growth in KV-cache size and attention computation as more experts are composed.

“Each prompt adds 256 positions to the context, so attention and KV-cache costs grow with the number of composed experts.”
From the paper, Section 5, page 13. Matched against the PDF text.

Limitation

Scaling CSPD to dozens of domain experts severely increases context memory footprint and attention overhead during prefill and generation.

Proposed Solution

Train a lightweight cross-attention encoder or KV-cache compression module that maps concatenated multi-prompt sequences into a fixed-length set of key-value vectors (e.g., 64 positions). Use a distillation loss between the uncompressed multi-prompt KV-cache attention outputs and the compressed KV-cache attention outputs across sample outputs to preserve performance while fixing context length.

The paper’s authors list this direction as future work, so they may already be pursuing it.

Why This Matters

Successfully compressing multi-expert soft prompts would allow scaling CSPD to hundreds of modular domain experts without context length degradation or memory explosion.

How to Get Started

How to test it: Test whether a compressed 64-token KV prefix matches uncompressed 4-prompt CSPD (1024 tokens) on AIME24, LCB v5, GPQA, and IFBench average score within 0.5 percentage points. Baseline is standard concatenated CSPD. Stop if compressed KV score drops more than 2 percentage points.

  1. Download released CSPD checkpoints and Qwen3-4B-Base backbone from GitHub repository.
  2. Implement a prefix compression module that projects concatenated KV-caches of 4 prompts down to 64 key-value slots.
  3. Train the compressor module on multi-domain distillation datasets using KL divergence loss against uncompressed CSPD output distributions.
  4. Evaluate aggregate benchmarks (AIME24, LiveCodeBench, GPQA, IFBench) and benchmark KV-cache memory saving during SGLang inference.

Suggested by AI. Adapt it to your setup.

Has This Been Done?

No close match in 10 results

Papers like KV-Kaizen and TraceKV explore KV cache compression and policy preservation, while PERSOMA and InfoPrompt examine soft prompt tuning and adapters. However, none of the listed results combine distillation-based KV cache compression specifically for multi-expert soft prompts into a fixed-length prefix.

We searched OpenAlex and arXiv for “soft prompt compression KV cache prefix distillation multi expert” and “Fixed-Size Key-Value Prefix Compression for Multi-Expert Soft Prompts” and an AI compared the idea with the top 10 results. A small search can miss relevant work.

Source Paper

Composable Soft-Prompt Distillation of RL Experts: Toward Continual Post-Training

Zhen Zhang, Changyi Yang, Xuehai He +25 more · 2026

This paper presents Composable Soft-Prompt Distillation (CSPD), a method for continual post-training of large language models that keeps the base pre-RL model frozen and distills each post-RL domain expert into an independent soft prompt. At inference, these soft prompts are concatenated directly in the system prompt without joint training or modifying model weights. CSPD recovers over 90% of teacher gains across math, code, and agent benchmarks, matches multi-teacher on-policy distillation in-domain, and provides superior out-of-domain generalization with minimal serving overhead.

Related Ideas

Is this a good idea?

Share onXLinkedIn