The Algorithm Engineering Group at Heidelberg University has released Agentic Algorithm Engineering (AAE), a new skill for Claude Code and Codex that enforces a scientific method on autonomous code optimization. Instead of letting agents blindly tweak parameters, AAE requires a falsifiable hypothesis before every experiment, ensuring that every accepted change is backed by data and correctness checks.
The Scientific Cycle
AAE structures the agent's workflow into a strict loop: Design, Analyze, Implement, and Experiment. During the Design phase, the agent must formulate a specific prediction, such as 'changing X will improve the metric by Z.' Before any code is touched, the Analyze phase requires profiling to predict the direction and size of the effect. Only after this theoretical groundwork does the agent implement a minimal Git commit, immediately validating it against agreed-upon correctness assertions like bit-identical outputs.
Verifiable Results and Patches
The tool doesn't just optimize; it documents the entire trajectory. Each accepted change results in a numbered Git patch in a patches/ directory, complete with the original hypothesis and measurement data. For the KaHIP kaffpa session, the team reported 122 experiments and 69 hypotheses, resulting in 41 accepted patches and a total 3.9x speedup. The final output includes a PDF report with one page per tested hypothesis, detailing the intuition, prediction, measurements, and final verdict.
Shared Knowledge and Integration
AAE integrates a shared knowledge base where sessions contribute optimization techniques and experiment results, allowing future agents to learn from past successes. The tool is available via the Claude Code marketplace or through a script for Codex users. A quick-start example is provided for users to test the workflow on a slow but correct shortest-path program, demonstrating the 10-minute setup process.
Key Takeaways
- AAE enforces falsifiable hypotheses before code changes, reducing hallucinated optimizations.
- The tool generates reviewable Git patches and PDF reports for every successful experiment.
- Results from the KaHIP session showed a 3.9x speedup across 41 accepted patches.
- A shared knowledge base allows agents to leverage insights from previous optimization sessions.
The Bottom Line
Finally, an agent that acts like a scientist instead of a monkey with a keyboard. This isn't just prompt engineering; it's algorithm engineering with receipts. If you're tired of black-box AI refactors that break production, this Heidelberg release is the sanity check your workflow needs. The requirement for a falsifiable hypothesis before execution is a game-changer for trustworthy autonomous coding.