Galapagos 🐢
LLM-driven evolutionary search. One loop. Swappable slots.
Docs · Quickstart · Concepts · The Hub · Examples
Any LLM × 10 scaffolds × 945 tasks. One component vocabulary. One leaderboard.
Galapagos is a user-friendly, open-source platform for LLM-driven evolutionary search on scientific-discovery and optimization tasks. Load an evolutionary-search scaffold and an evaluation task in a few lines, point them at any LLM, and let the loop evolve solutions that maximize a metric — circle packings, function minimizers, GPU kernels, algorithms, prompts, and more.
import galapagos as gx
model = gx.GalapagosModel.from_card(name="openai/gpt-5.5", host="openrouter")
scaffold = gx.GalapagosScaffold.from_card(name="openevolve", model=model)
task = gx.GalapagosTask.from_card(name="circle_packing")
result = scaffold.run(task=task)
print(result.best_score, result.summary)
That's the whole loop: pick a method, pick a task, point at a model, run.
Set host to any OpenAI-compatible provider — openrouter (default), openai, anthropic, gemini, azure, vllm, or litellm — and export a key. No provider key? The claude_code scaffold runs the whole loop through a local Claude Code CLI session, billed to your Claude subscription instead.
Cards: the protocol
After AlphaEvolve, LLM-evolution methods exploded — OpenEvolve, ShinkaEvolve, GEPA, AdaEvolve, EvoX, Meta-Harness, and more. Each is structurally the same loop (select → prompt → propose → evaluate → repeat), but each shipped as an incompatible codebase with a bespoke harness, so published numbers were never apples-to-apples. Galapagos unifies them behind one component vocabulary and one leaderboard. (Why Galapagos.)
What makes that work is the card: a versioned YAML, modeled on the model & dataset cards of the Hugging Face Hub. A card is the single source of truth shared by the local library and the live Hub — the same YAML loads a method on your laptop and lists it in the registry. There are four kinds:
| Card kind | Describes | Publish it to… |
|---|---|---|
| Scaffold card | an evolutionary-search method (its six components) | share your method |
| Task card | an evaluation task + its scorer | share your benchmark |
| Model card | an LLM backend + host | share a model config |
| Verification card | a discovery — best solution + trajectory | submit a result |
Learn the protocol in Concepts › Cards.
Install
Published on PyPI as open-galapagos (the bare galapagos name is an unrelated 2019 stub) — you still import galapagos:
pip install open-galapagos # core: openai, pyyaml, pydantic, rich, python-dotenv
pip install "open-galapagos[math]" # numpy/scipy for numeric tasks
pip install "open-galapagos[all]" # every general-purpose extra (math + algotune + frontiercs)
Or an editable checkout for development: pip install -e ".[all]".
Full walkthrough: docs/content/installation.md.
Quickstart
Three cards and one call. Loaded by name, they're pulled straight from the registry — the same names you'd browse on the Hub:
import galapagos as gx
model = gx.GalapagosModel.from_card(name="openai/gpt-5.5", host="openrouter")
scaffold = gx.GalapagosScaffold.from_card(name="openevolve", model=model)
task = gx.GalapagosTask.from_card(name="circle_packing")
result = scaffold.run(task=task)
print(result.best_score, result.summary)
Set host to one of openai, openrouter (default), anthropic, gemini, azure, vllm, or litellm, and export OPENAI_API_KEY (or the provider's own key) first. Don't want to use a provider key? The claude_code and claude_code_docker scaffolds run the loop through a local Claude Code CLI session, billed to your Claude subscription instead.
More in the quickstart guide.
The six components
Every method in Galapagos — yours included — is a composition of six components over the unit of evolution, the Genome (content, scores, metadata, artifacts).
| # | Component | Role | Built-ins |
|---|---|---|---|
| 1 | Population |
the store of evolved genomes (add / query / best) | InMemoryPopulation, IslandPopulation |
| 2 | SelectionPolicy |
picks the parent + inspirations each step | ExploreExploitPolicy, UCBBanditPolicy, IdentityPolicy |
| 3 | PromptBuilder |
renders the prompt — pure formatting, no selection | DefaultPromptBuilder |
| 4 | Proposer |
the variation operator that produces a new genome | DiffProposer, CrossoverProposer |
| 5 | Evaluator |
the pure scorer (supplied by the task) | SubprocessEvaluator |
| 6 | Memory |
optional free-form knowledge (read / write) | NullMemory, ScratchpadMemory |
The loop, in one sentence: select parents from the Population → build a prompt from them and Memory → propose a new candidate → evaluate it → add the scored Genome back to the Population → observe; repeat until the budget (max_iterations / target_score / max_usd / patience / wallclock_s) is hit.
Swap any slot. Keep the rest. That's a new method.
Deep dive: Concepts › Overview · Components · Genome · Models.
Build your own
Each slot takes an instance, a "module.Class" path, or a .py file — so a new method is usually a few keyword arguments, not a new codebase.
from galapagos.components import (
IslandPopulation, ExploreExploitPolicy, DefaultPromptBuilder, DiffProposer, NullMemory,
)
scaffold = gx.GalapagosScaffold.from_card(
population=IslandPopulation(num_islands=3),
selection_policy=ExploreExploitPolicy(seed=0),
prompt_builder=DefaultPromptBuilder(),
proposer=DiffProposer(),
memory=NullMemory(),
model=gx.load_model("openai/gpt-5.5", host="openrouter"),
)
When your method works, write it as a scaffold card and submit it. Guides: run a scaffold · custom scaffold · custom task.
Runnable now
10 bundled scaffolds, all runnable:
adaevolve beam_search best_of_n best_of_n_attempts claude_code claude_code_docker evox meta_harness openevolve topk
945 bundled tasks across many benchmark suites — symbolic regression (241), FrontierCS (188), AlgoTune (154), GPU MODE kernels (47), AlphaEvolve math discovery (46), ALE-Bench (40), Open Problems single-cell (15), and more (what each needs). Quickstart-ready examples: circle_packing, function_minimization, playground_sphere.
Browse the registry from Python:
gx.available_scaffolds() # every scaffold card
gx.available_tasks() # every task card
gx.registered_scaffolds() # the runnable subset (all 10)
Reference: API · scaffolds · tasks.
CLI
galapagos run --scaffold openevolve --task circle_packing --proposer.model_name openai/gpt-5.5 --general.max_iterations 20
galapagos run --scaffold openevolve --task circle_packing --resume runs/prev # continue from a checkpoint
galapagos scaffold list # the scaffold catalog (all runnable)
galapagos task list # the task catalog
galapagos submit --card card.yaml --dry-run # validate + preview the bundle (drop --dry-run to upload)
The Hub
The Hub (under hub/) turns cards into a community platform. Three pieces:
- Registry — browse and load scaffold cards, task cards, and model cards.
- Leaderboard — per-task rankings of scaffold × model runs, so every published number is apples-to-apples.
- Verification — submit a discovery as a
VerificationCard(best solution + trajectory) for expert review. Status flowsunverified → under_review → verified.
Read more: docs/content/hub.md · submitting to the Hub.
Examples
The examples/ folder carries a worked scaffold card — shinkaevolve/ — showing how a published method (ShinkaEvolve) is expressed as a card.yaml + README.md you can load by path or submit to the Hub. For end-to-end walkthroughs, start with the Quickstart and the guides above.
Documentation
| Quickstart | Installation |
| Why Galapagos | Concepts: overview |
| Components · Genome | Cards · Models |
| Run a scaffold | Custom scaffold |
| Custom task | Submit to the Hub |
| API reference | Scaffolds · Tasks |
Full site: open-galapagos.com.
Contributing
Contributions are first-class: a new method is a scaffold card, a new benchmark is a task card, a new result is a verification card. See docs/content/contributing.md, validate any card with galapagos submit --card card.yaml, and open a PR. Issues and discussion are welcome.
License
Galapagos is released under the Apache-2.0 license.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file open_galapagos-0.4.0.tar.gz.
File metadata
- Download URL: open_galapagos-0.4.0.tar.gz
- Upload date:
- Size: 4.5 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9e15bcaabf5e8fbb6920a68a176ac1e9466eb9a93e96052cfdc683bdb05ccc27
|
|
| MD5 |
ea08efc299e760fb1c09333dafdbb3b7
|
|
| BLAKE2b-256 |
30c036bff1a7ba3a6329eaa35d6b50bb6c873e4cd941175faee54ed2b935d82f
|
File details
Details for the file open_galapagos-0.4.0-py3-none-any.whl.
File metadata
- Download URL: open_galapagos-0.4.0-py3-none-any.whl
- Upload date:
- Size: 9.4 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ece93444ebf5900dbbbd941b44113458af6bb2acc6b05db7501f7d2d6b338a73
|
|
| MD5 |
1d48c2f5aac9e26a79e66b7776a43c58
|
|
| BLAKE2b-256 |
73b1a5b5d95a0f964f2462312b38390ee250dfcea2117b16a4c0de81bb92e4d8
|