|
Download benchmarks/prompt_optimization/README.md from JustinTX/sky2: direct link, hf CLI and curl.
- Browser
- Download file 1.25 kB
-
https://huggingface.co/JustinTX/sky2/resolve/main/benchmarks/prompt_optimization/README.md
- Command line
-
hf download hf://JustinTX/sky2/benchmarks/prompt_optimization/README.md
-
curl -L -o README.md https://huggingface.co/JustinTX/sky2/resolve/main/benchmarks/prompt_optimization/README.md
1.25 kB
Prompt Optimization Benchmark
Evolves plain-text LLM instruction prompts using SkyDiscover's evolutionary search.
How It Works
- Start with a seed prompt (e.g., a one-line instruction)
- Evaluate the prompt by running it on a QA task and measuring exact-match accuracy
- Use an LLM to rewrite the prompt guided by performance feedback and context from other candidates
- Repeat — the population of prompts improves over generations
Key config: language: text and diff_based_generation: false — prompts are fully rewritten each iteration (not diffed like code).
Benchmarks
| Task | Dataset | Metric | Dir |
|---|---|---|---|
| Multi-hop QA | HotPotQA | Exact match accuracy (0–1) | hotpot_qa/ |
Quick Start
cd benchmarks/prompt_optimization/hotpot_qa
# Install deps
pip install dspy litellm bm25s pystemmer datasets diskcache ujson
# Set API key
export OPENAI_API_KEY=...
# Run (first run downloads ~1.3GB of data)
uv run skydiscover-run initial_prompt.txt evaluator.py -c config_adaevolve.yaml -i 100 # AdaEvolve
uv run skydiscover-run initial_prompt.txt evaluator.py -c config_evox.yaml -i 100 # EvoX
See hotpot_qa/README.md for full details.