L’interface est localisée ; les présentations et documents des Skills sont traduits automatiquement par IA dans votre langue. Le code, les commandes, chemins et termes techniques restent en version originale, et le document de l’auteur fait foi.
Explorer les Skills
Développement · SKILL.md

expert-cache

expert-cache

Debug and extend mixtral-offloading's MoE expert cache, storage wrapper, and sparse routing internals.

Independent GitHub snapshot · Automated classification · Original documentation governs

Documentation de la Skill

GitHub

name: expert-cache description: "Debug and extend mixtral-offloading's MoE expert cache, storage wrapper, and sparse routing internals." metadata: disco-role: operating disable-model-invocation: true license: MIT

Expert Cache

Use this sub-skill when the task is about expert offloading internals rather than simply running the demo: ExpertCache, MixtralExpertWrapper, SparseMoeWrapper, expert UIDs, LRU eviction groups, pinned offload storage, or cache-capacity errors.

Read this when

  • The user sees Cache is full, No evictable experts, already loading experts, duplicate expert UID assertions, or eviction-group assertions.
  • The task is to change offloading policy, add prefetching, debug storage movement, or inspect sparse MoE routing.
  • The user wants to understand how offload_per_layer becomes main_size and offload_size inside ExpertCache.

Route map

  1. Read references/expert-cache-api.md for ExpertInfo, EvictionGroupInfo, ExpertCache, and method invariants.
  2. Read references/storage-and-routing.md for MixtralExpertWrapper storage replacement and SparseMoeWrapper.forward routing flow.
  3. Use scripts/inspect_cache_plan.py to compute cache capacities and example expert UIDs without loading model weights.
  4. Read references/troubleshooting.md for capacity, reentrancy, storage, pinned-memory, and routing-shape failures.

What this sub-skill owns

  • Expert-cache capacity and eviction invariants.
  • Expert UID layout and eviction-group behavior.
  • Storage wrapping and state-dict storage hooks.
  • Sparse MoE top-k routing through cached experts.

What to route elsewhere

Safe verification

Most cache internals require real MixtralExpertWrapper objects backed by CUDA UntypedStorage. For safe planning, use the bundled script and source/API reasoning. Do not construct the full cache with dummy objects unless their storage type, size, and device match the expected wrapper invariants.

Skills enregistrées