Agent skill

genetic-algorithms

Genetic Algorithms for AI optimization - EvoPrompt, hyperparameter tuning, evolutionary strategies.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill genetic-algorithms --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 4 KB
Bundled scripts: none
Path: skills/ai-ml/genetic-algorithms/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Skill: Genetic Algorithms ## Contexto Algoritmos genéticos para optimización de prompts, hyperparámetros, y búsqueda en espacios complejos donde gradientes no existen. ## Cuándo Usar - Optimizar prompts automáticamente - Tuning de hyperparámetros (learning rate, batch size, etc.) - Búsqueda en espacios discretos/no diferenciables - Cuando necesitás múltiples soluciones (no solo una) ## Reglas Críticas 1. **Fitness rápido** - Evaluación debe ser eficiente 2. **Seeds diversos** - Población inicial variada 3. **Elitismo** - Siempre preservar mejores individuos 4. **Stopping criterio** - Definir cuándo parar ## Procedimiento ### 1. Definir Representación Genética ```python # Para prompts: texto gene = "Step by step, analyze..." # Para hyperparams: dict gene = {"lr": 0.001, "batch": 32} ``` ### 2. Crear Función de Fitness ```python def fitness(gene) -> float: """Evaluar calidad del gene. Mayor = mejor.""" result = test_gene(gene) return accuracy(result) ``` ### 3. Implementar Operadores ```python # Crossover def crossover(p1, p2): point = random.randint(1, len(p1)-1) return p1[:point] + p2[point:] # Mutation def mutate(gene, rate=0.1): if random.random() < rate: return apply_mutation(

What's inside
Steps it walks through
  1. Contexto
  2. Cuándo Usar
  3. Reglas Críticas
  4. Procedimiento
  5. 1. Definir Representación Genética
  6. 2. Crear Función de Fitness
  7. 3. Implementar Operadores
  8. 4. Ejecutar Loop Evolutivo
  9. Ejemplo Completo (EvoPrompt)
  10. Best Practices
  11. Recursos Relacionados
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the genetic-algorithms skill do?

Genetic Algorithms for AI optimization - EvoPrompt, hyperparameter tuning, evolutionary strategies.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill genetic-algorithms --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going