Algorithm Selection with Zero Domain Knowledge via Text Embeddings
Organizations: Algorithms and Complexity Group TU Wien, Vienna, Austria
Abstract
We propose ZeroFolio, a feature-free approach to algorithm selection that uses pretrained text embeddings instead of hand-crafted instance features. It reads the raw instance file as plain text, embeds it with a pretrained embedding model, and selects an algorithm via weighted k-nearest neighbors. Our approach is based on the observation that pretrained embeddings can distinguish problem instances without any domain knowledge or task-specific training. ZeroFolio applies to any problem domain with text-based instance formats. We evaluate our approach on 11 ASlib scenarios spanning 7 domains (SAT, MaxSAT, QBF, ASP, CSP, MIP, and graph problems). ZeroFolio outperforms a random forest trained on hand-crafted features in 9 of 11 scenarios, often substantially, and in 8 of them with every serialization seed. It wins 8 of 11 scenarios against a per-scenario-tuned random forest. On the three scenarios with published AutoFolio results from the 2015 ICON Challenge, ZeroFolio comes within a small margin of AutoFolio without any per-scenario tuning. Our ablation study on SAT12-ALL shows that inverse-distance weighting and line shuffling improve performance. We further analyze the sensitivity of our approach to the serialization seed. On the SAT12-ALL scenario, where the random forest is stronger, both methods can be combined via soft voting to achieve further improvements.
Figures & tables
| Scenario | Domain | Inst. | Algo. | Cutoff (s) | Format |
|---|---|---|---|---|---|
| SAT12-ALL | SAT | 1367 | 31 | 1200 | CNF |
| SAT03-16_INDU | SAT | 1887 | 10 | 5000 | CNF |
| MAXSAT12-PMS | MaxSAT | 875 | 6 | 2100 | WCNF |
| MAXSAT-PMS-2016 | MaxSAT | 450 | 19 | 1800 | WCNF |
| MAXSAT-WPMS-2016 | MaxSAT | 630 | 18 | 1800 | WCNF |
| QBF-2016 | QBF | 825 | 24 | 1800 | QDIMACS |
| Gap% | ||||||||
|---|---|---|---|---|---|---|---|---|
| Scenario | SBS | RF | RF t | AF ⋆ | ZF | VBS | RF | ZF |
| SAT12-ALL | 3066 | 956 | 952 | 1066 | 1158 | 271 | 75 | 68 |
| SAT03-16_INDU | 10097 | 9504 | 9500 | – | 9292 | 7152 | 20 | 27 |
| MAXSAT12-PMS | 4899 | 3729 | 3733 | 3559 | 3756 | 3131 | 66 | 65 |
| MAXSAT-PMS-2016 | 2965 | 3203 | 3211 | – | 2338 | 1833 | 21 | 55 |
| MAXSAT-WPMS-2016 | 3893 | 3590 | 3526 | – | 3379 | 2630 | 24 | 41 |
| Dimension | Variant | PAR10 |
| Standard configuration | 1122 | |
| Naive baseline (raw + cosine + uniform) | 1495 | |
| Serialization | raw (no shuffle) | 1217 |
| Distance | cosine | 1098 |
| Weighting | uniform | 1497 |
| 1010 | ||
| Cosine | Uniform wt. | ||||
|---|---|---|---|---|---|
| Scenario | Std | PAR10 | PAR10 | ||
| SAT12-ALL | 1122 | 1098 | 1497 | ||
| QBF-2016 | 1979 | 1959 | 2220 | ||
| ASP-POTASSCO | 539 | 539 | 526 | ||
| CSP-MZN-2013 | 4524 | 4524 | 4528 | ||
| Scenario | RF | Gem. 2 | Gem. 1 | OAI | Qwen3 |
|---|---|---|---|---|---|
| SAT12-ALL | 956 | 1122 | 1126 | 1226 | 1537 |
| SAT03-16_INDU | 9504 | 9270 | 9318 | 9282 | 9709 |
| MAXSAT12-PMS | 3729 | 3684 | 3709 | 3635 | 3806 |
| MAXSAT-PMS-2016 | 3203 | 2319 | 2324 | 2478 | 2640 |
| MAXSAT-WPMS-2016 | 3590 | 3378 | 3457 | 3542 | 3859 |
| QBF-2016 | 2494 | 1979 | 2217 | 2566 | 3178 |