-
Notifications
You must be signed in to change notification settings - Fork 657
Fix llm optimization #178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Fix llm optimization #178
Conversation
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
Renamed the example directory from 'llm_prompt_optimazation' to 'llm_prompt_optimization' for correct spelling and consistency. Updated all example files, added HuggingFace dataset support, new configuration files, and improved documentation. The new example supports prompt evolution for any HuggingFace dataset with custom templates and cascading evaluation. Removed the old example files and replaced them with the new structure.
Updated the evaluator to automatically match prompt files with their corresponding dataset configuration using a naming convention. Added emotion classification benchmark files (`emotion_prompt.txt`, `emotion_prompt_dataset.yaml`) and a wrapper script (`run_evolution.sh`) for easier execution. Deprecated and removed old example files, and improved documentation in the README to reflect the new workflow and dataset handling.
Introduces GSM8K prompt and dataset configuration files for grade school math problem evaluation. Updates evaluator.py to support GSM8K answer extraction and adjusts evaluation logic for numeric answers. Modifies config.yaml for new optimal parameters and documents GSM8K support in the README.
Adds a check to avoid re-migrating already migrated programs in the ProgramDatabase migration logic. This prevents exponential duplication of identical programs, conserves computational resources, and maintains diversity in the MAP-Elites + Island hybrid architecture. Also updates config.yaml to adjust LLM temperature and selection ratios for improved optimization.
When initializing an empty island, a new copy of the best program is now created with a unique ID, rather than reusing the same program instance. This prevents a program from being assigned to multiple islands and ensures correct lineage tracking. Additional tests were added to verify correct migration behavior, unique program assignment per island, and proper handling of empty island initialization.
Introduces a `calculate_prompt_features` function in the evaluator to bin prompts by length and reasoning strategy, returning these as features for MAP-Elites optimization. Updates config.yaml to specify these features and their binning. Evaluator now returns these features alongside the combined score in both evaluation stages.
Updated the evaluator to prioritize 'combined_score' when checking thresholds for consistency with evolution, falling back to averaging metrics if not present. Increased evaluator timeout and cascade threshold in the config, and switched to using max_tokens from config in prompt evaluation. Also updated the LLM model name in the config.
wangcheng0825
pushed a commit
to wangcheng0825/openevolve
that referenced
this pull request
Sep 15, 2025
…-llm-optimization Fix llm optimization
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.
No description provided.