dkAmulet/sql-query-optimizer
0
1name: sql-query-optimizer2version: "1.0.0"3description: "An RL environment where AI agents learn to rewrite slow SQL queries for correctness, performance, and style against a live SQLite e-commerce database."4 5tags:6 - sql7 - database8 - optimization9 - real-world10 - code-improvement11 12observation_space:13 type: object14 properties:15 task_id:16 type: string17 task_name:18 type: string19 difficulty:20 type: string21 description:22 type: string23 schema_ddl:24 type: string25 slow_query:26 type: string27 current_query:28 type: string29 step_number:30 type: integer31 max_steps:32 type: integer33 last_feedback:34 type: string35 last_reward:36 type: number37 38action_space:39 type: object40 properties:41 optimized_query:42 type: string43 44reward_range:45 - 0.046 - 1.047 48tasks:49 - id: select_star_removal50 name: "SELECT * Elimination"51 difficulty: easy52 max_steps: 553 description: "Rewrite SELECT * to return only required columns (user_id, username, email) for all active users."54 55 - id: subquery_to_join56 name: "Correlated Subquery to JOIN"57 difficulty: medium58 max_steps: 659 description: "Convert an IN (SELECT ...) subquery to an explicit JOIN returning delivered orders from active USA customers."60 61 - id: aggregation_optimization62 name: "Aggregation Optimization"63 difficulty: hard64 max_steps: 865 description: "Replace correlated subqueries in the SELECT list with JOIN and GROUP BY to compute per-category revenue efficiently."66 