研究人员成功训练了一个40亿参数的开源语言模型,使其能够生成比PostgreSQL默认查询计划快81%的数据库查询执行方案1。该模型在Join Order Benchmark的113条查询上实现了1.81倍的几何平均加速和44.7%的总延迟降低1。
这项工作采用了监督微调与强化学习相结合的方法1。研究人员通过GPT-6 Astra生成420条演示轨迹进行离线策略蒸馏1,并设计了自定义GRPO变体以应对测量噪声1。模型使用仅含21.2百万个可训练参数的LoRA微调方案1。为解决Linux页面缓存噪声问题,研究团队将shared_buffers从128MB提升至2GB,使得无操作误导率下降了4倍1。整个项目的总训练成本约为1200美元,其中包括Lambda H100节点租赁成本800美元和OpenAI API成本400美元1。这一成果证明了小型开源模型在特定领域任务上的可行性,同时支持最多3次尝试采样以获得最佳查询计划结果1。
Researchers have successfully trained a 4-billion-parameter open-source language model to generate database query execution plans that significantly outperform PostgreSQL's default optimizer.1 The fine-tuned model achieved a geometric mean speedup of 1.81 times and reduced total latency by 44.7% across 113 join-intensive queries from the Join Order Benchmark.1
The approach combined supervised fine-tuning and reinforcement learning techniques to adapt the small model for query optimization tasks.1 Researchers used GPT-6 Astra to generate 420 demonstration trajectories for offline policy distillation, then implemented a custom GRPO variant to handle measurement noise in query execution environments.1 The training process required only 21.2 million trainable parameters through LoRA adaptation of the base 4B model, keeping computational requirements minimal.1
The entire training pipeline cost approximately $1,200, comprising $800 in Lambda H100 node rental fees and $400 in OpenAI API costs.1 The researchers addressed a critical challenge involving Linux page cache interference by increasing PostgreSQL's shared_buffers from 128MB to 2GB, which reduced misleading results from no-op queries by a factor of four.1 Results were validated across the 113 queries using up to three sampling attempts to select the best outcome.1
评论
还没有评论,欢迎留下第一条。