Agentic Optimization Loop

•
154
•

Automates the iterative optimization of code complexity and SQL performance through a verifiable evaluator-optimizer loop that guarantees behavioral correctness.

The Optimize Loop skill implements a rigorous agentic workflow designed to minimize specific technical costs—such as cyclomatic complexity in code or execution latency in SQL queries—while strictly maintaining behavioral integrity. By applying focused, single-step changes and verifying them against a non-negotiable correctness gate (like a test suite or result-set hash), it ensures that every optimization is safe and measurable. This skill is ideal for developers refactoring legacy code or tuning database performance, as it autonomously snapshots files, benchmarks improvements, and maintains a detailed ledger of every attempt until it reaches a performance plateau or a predefined iteration budget.

Características Principales

01Lexicographic metric minimization focusing on complexity, nesting, and LOC
02Strict correctness gates to ensure zero behavioral regressions during optimization
03154 GitHub stars
04Autonomous snapshot-and-revert workflow for safe, hands-off execution
05Automated SQL performance tuning with result-set hash verification
06Detailed ledger logging for tracking iteration status, metrics, and change descriptions

Casos de Uso

01Refactoring complex Python modules to reduce nesting and improve maintainability without breaking tests
02Automated code cleanup to remove redundancy and dead code under a hard correctness bound
03Optimizing slow SQL queries through index testing and query rewriting while ensuring identical result sets