distribution-search

Find probability distributions satisfying KL divergence, entropy, and moment constraints via numerical optimization.

Updated Feb 24, 2026
One-click install
npx skills add https://github.com/Zurybr/lefarma-skills --skill distribution-search
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: distribution-search
Source: https://github.com/Zurybr/lefarma-skills/tree/main/letta/benchmarks/trajectory-only/distribution-search
Command: npx skills add https://github.com/Zurybr/lefarma-skills --skill distribution-search

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires numpy, scipy, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides systematic approaches for finding probability distributions that meet specific statistical constraints, such as target KL divergence values, specified entropy, or moment constraints.

Core Features & Use Cases

  • Constraint Satisfaction: Find distributions that satisfy KL divergence targets (forward or backward), entropy requirements, or moment conditions.
  • Numerical Optimization: Utilizes various optimization strategies to search for distribution parameters.
  • Use Case: You need to construct a discrete probability distribution that has a specific KL divergence from a uniform distribution while also meeting a target entropy value.

Quick Start

Use the distribution-search skill to find a probability distribution that satisfies a forward KL divergence of 0.5 and a backward KL divergence of 0.3.

Frequently Asked Questions about distribution-search

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I find a probability distribution that satisfies specific KL divergence and entropy constraints?

To find a probability distribution meeting specific KL divergence and entropy constraints, you need numerical optimization techniques. This approach searches for distribution parameters that simultaneously satisfy multiple statistical criteria using rigorous mathematical analysis.

What is the best way to construct a discrete distribution with target moment conditions?

Constructing a discrete distribution with target moment conditions requires identifying parameters that adhere to precise statistical criteria. Numerical optimization searches parameter spaces to find distributions meeting your specified moment constraints, ensuring reliable results through mathematical verification.

Can I search for distributions that meet both forward and backward KL divergence targets?

Yes, you can search for distributions meeting both forward and backward KL divergence targets. The numerical optimization approach handles multiple simultaneous constraints, finding distribution parameters that satisfy diverse statistical requirements through efficient parameterization and rigorous verification.

Does this numerical search approach work with continuous probability distributions?

Yes, this numerical search approach facilitates construction of both discrete and continuous probability distributions. Using mathematical analysis and efficient parameterization, it identifies distribution parameters meeting your specified statistical constraints across different distribution types.

What statistical constraints can I specify when searching for probability distributions?

You can specify KL divergence targets (forward or backward), entropy requirements, and moment conditions as statistical constraints. The numerical optimization methods search for distribution parameters satisfying these precise criteria while maintaining mathematical rigor throughout the process.

Do I need numpy and scipy to perform numerical optimization for distribution parameter searches?

Yes, numpy and scipy are required dependencies for performing numerical optimization to search for distribution parameters. These libraries provide the mathematical foundations and optimization routines needed to identify probability distributions meeting your specified statistical constraints.