feat: Add wishful.explore() for multi-variant generation + documentation overhaul#6
Merged
pyros-projects merged 8 commits intomainfrom Nov 25, 2025
Merged
Conversation
Previously, __wishful_source__ was only attached to functions after selection via wrap_with_metadata(). This meant benchmark functions couldn't access the source code during evaluation. The fix attaches __wishful_source__ immediately after compilation, enabling LLM-as-Judge patterns where the benchmark inspects generated code quality. Also adds examples/13_explore_advanced.py demonstrating: - LLM-as-Judge scoring - Code golf (shortest implementation) - Self-improving loops - Multi-objective optimization - Real-world regex challenges
- Add 'Going Deeper: LLMs Judging LLMs' section to README - Add 'Advanced: LLMs Judging LLMs' section to explore.mdx - Update project structure to include 13_explore_advanced.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
✨ Overview
This PR introduces
wishful.explore()- a powerful new feature that generates multiple implementation variants, tests them, and caches the winner. Plus a comprehensive documentation overhaul.🔍 New Feature:
wishful.explore()Generate multiple variants of a function and automatically select the best one:
Key Features
test=)benchmark=,optimize="fastest").wishful/{cache_dir}/_explore/for analysis__wishful_metadata__and__wishful_source__Selection Strategies
first_passing(default): Return first variant that passes the testfastest/best_score: Benchmark all variants, return highest scorer📚 Documentation Overhaul
examples/12_explore.py: Basic explore usageexamples/13_explore_advanced.py: Advanced patterns (LLM-as-judge, code golf, self-improving loops)🔧 Technical Changes
New Module:
src/wishful/explore/Other Changes
agenerate_module_code)test_explore.py🗑️ Removed
docs/CHANGELOG.md(outdated)docs/ideas/advanced_context_discovery.md(moved to internal docs)📊 Stats