Skip to content

feat(compat): export minimal Python AlphaEvolve bundles - #529

Merged
codelion merged 1 commit into
algorithmicsuperintelligence:mainfrom
Yushu-Li:feat/alphaevolve-export-bundle
Oct 22, 2026
Merged

codelion merged 1 commit into
algorithmicsuperintelligence:mainfrom
Yushu-Li:feat/alphaevolve-export-bundle

Conversation

@Yushu-Li

Copy link
Copy Markdown
Contributor

OpenEvolve's reverse evaluator and configuration helpers currently need to be
wired together by hand. Add an opt-in export_to_alphaevolve API and
python -m openevolve.compat.alphaevolve_bundle command that package an existing
single-file Python seed and synchronous evaluator into a directory with an
explicit local check.

The bundle contains byte-preserved sources, a reverse-adapter entry point,
experiment.json, evaluation.json, check.py, installation/integration
instructions and an optional explicitly supplied requirements file. Export
validates inputs without importing or executing the sources, rejects existing
destinations and detectable local-module dependencies, and cleans up its newly
created output on write failures. It reuses the merged config/evaluator helpers,
including explicit model remapping and warnings for omitted OpenEvolve settings.

The check works after moving the bundle and from an unrelated working directory.
It prints the evaluation as JSON, redirects Python-level evaluator stdout to
stderr and returns a nonzero status for adapter-reported failures or ordinary
import/contract errors. Dependencies must be installed in the target environment;
they are not inferred or vendored. Evaluators must capture their own subprocess
output to preserve machine-readable stdout.

Validation:

  • Full offline unit suite: 791 tests passed, including 20 new bundle tests.
  • Unchanged function_minimization and circle_packing sources exported through
    the CLI, relocated, checked successfully and verified byte for byte.
  • Exported configs/results validated against the real upstream SDK models, and
    each exported callable executed through its actual AlphaEvolveExperiment
    evaluator wrapper with a typed AlphaEvolveProgram candidate. SDK source
    revision: 674dd5e558e917320c251c085e47fae33e1bbcff.
  • Network/credential guards around the real-example subprocesses recorded zero
    socket/HTTP requests and zero credential lookups. No managed-service run.
  • Black, isort, Python 3.10 syntax parsing and the CI-pinned Frame scan passed.

Partial follow-up to #468, building on #526 and #527. This deliberately does not
provide a Google client/controller runner, an SDK shim, dependency discovery,
sandboxing or a claim of equivalent search behavior. It adds no base dependencies
and leaves the default evolution path unchanged.

Implemented with AI coding assistance and checked with the tests and real SDK
validation described above.

@Yushu-Li

Copy link
Copy Markdown
Contributor Author

The minimal single-file Python export path now works end to end offline:

OpenEvolve seed + evaluator + config → exported bundle → relocated check.py → real AlphaEvolve SDK validation

Both unchanged function_minimization and circle_packing examples pass the relocated local check. The real SDK accepts the generated configuration and evaluation results, including evaluation through its actual experiment wrapper. GitHub unit tests and the Frame security scan are green; the integration job is still running.

This is a minimal, offline-validated slice of #468. The target environment still needs OpenEvolve and evaluator dependencies; managed-service authentication and client/controller execution remain follow-ups. No Google Cloud experiment has been run.

@codelion
codelion merged commit 515d1bc into algorithmicsuperintelligence:main Oct 22, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants