Synthesizing Feature Extractors: An Agentic Approach for Algorithm Selection
06:00 · August 19, 2026 · arXiv cs.AI RSS

Algorithm selection for constraint satisfaction problems requires extracting features that capture problem structure. Manually designing feature extractors demands deep domain expertise and quickly becomes a bottleneck when new problem classes appear. We present an automated approach that uses Large Language Models (LLMs) in an agentic check--fix--verify loop to synthesize executable Python scripts that act as interpretable, problem-specific feature extractors. Given a high-level MiniZinc model and an instance, the LLM agent generates code that constructs a typed graph representation and computes structural properties such as graph density, variable clustering, and constraint tightness. We evaluate our approach on three combinatorial problems (vehicle routing, car sequencing, fixed-length error-correcting codes) with a portfolio of five state-of-the-art solvers. The synthesized extractors yield algorithm selectors that consistently outperform both expert-curated mzn2feat features (up to $8.3$ percentage points (pp) test-set accuracy on FLECC) and the best transformer-based trans2feat variants. In the meanwhile, the synthesized feature extractors remain inspectable.
Summary
The article presents an automated framework that employs large language models inside an agentic check–fix–verify loop to generate executable Python feature extractors directly from MiniZinc problem descriptions. Rather than relying on hand-crafted extractors or opaque neural embeddings, the method produces explicit scripts that first translate a given instance into a typed graph representation and then compute named structural metrics such as graph density, variable clustering, and constraint tightness. These interpretable features feed into algorithm-selection pipelines for constraint satisfaction problems, where solver performance can vary by orders of magnitude across instances.
Evaluation covers three combinatorial domains—vehicle routing, car sequencing, and fixed-length error-correcting codes—each paired with a portfolio of five established solvers. Selectors trained on the synthesized features consistently surpass both the established expert-curated mzn2feat extractor and the strongest transformer-based trans2feat variants, with the largest recorded gain reaching 8.3 percentage points in test-set accuracy on the FLECC benchmark. Because the generated extractors remain readable Python programs, domain experts can inspect, validate, or refine the chosen structural properties without reverse-engineering latent representations.
The approach addresses the long-standing bottleneck of manual feature engineering for new problem classes while preserving the transparency required for practical deployment. Code, data, and the full reproducibility archive accompany the work.
Why it matters
High technical depth, novelty in LLM-driven program synthesis for optimization, strong reproducibility, and direct applicability to Dutch researchers in combinatorial optimization, constraint programming, and LLM-augmented AI pipelines.





