Skip to content
Back to skills

Generative Latent Mir

ASecurity

Score latent replay candidates with KL drift, entropy confidence penalties, and diversity filtering for MIR.

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
tools

Works with

  • cli

Security analysis

A100/100

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill generative_latent_mir --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Generative Latent Mir?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Generative Latent Mir
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-generative-latent-mir/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-generative-latent-mir)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
---
name: generative_latent_mir
description: Score latent replay candidates with KL drift, entropy confidence penalties, and diversity filtering for MIR.
---

# Generative and Latent MIR

Use this skill when MIR must operate over generated samples, compressed memories, or a deterministic latent proxy rather than raw replay examples. It captures the paper's generative MIR mechanism without requiring a VAE for small validation tests.

## Inputs
- Latent candidate ids and vectors.
- Pre-update and virtual-update class probability distributions for each candidate.
- Entropy weight, diversity distance threshold, and replay budget.
- Optional nearest-neighbor mapping from latent points to stored compressed examples.

## Outputs
- KL, entropy, and combined score per candidate.
- A diversity-filtered ranked selection.
- Mechanism diagnostics showing KL drift and entropy confidence were evaluated.

## Workflow
1. Normalize candidate probability vectors with small numerical smoothing.
2. Compute `KL(y_pre || y_hat)` for prediction drift after the virtual classifier update.
3. Compute entropy of `y_pre` and subtract `entropy_weight * entropy`.
4. Sort candidates by descending score.
5. Apply greedy diversity filtering by Euclidean distance in latent space.
6. Return selected candidates and diagnostics for recovery logging.

## Validation
Run the included tests or `validate_skill_tree.py --run-tests`. Tests cover KL ranking, entropy penalties, smoothing, and diversity filtering using standard-library numeric fixtures.

## Limitations
This helper validates the latent MIR objective and selection contract. It does not train an encoder, decoder, or VAE; a full neural implementation should provide probability vectors and latent candidates from the model stack while preserving the same output schema.

Validation note: the diversity smoke test intentionally verifies that near-duplicate latent candidates can be suppressed while a distant interfered candidate remains selected.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…