mlsanityData to 7 Oct 2026

Technical Report: Full-Stack Fine-Tuning for the Q Programming Language

arXiv 2508.06813 ↗First posted 9 Aug 2025cs.LG cs.PLcited by 0

Not on the map. Why?

Abstract (arXiv)

Even though large language models are becoming increasingly capable, it is still unreasonable to expect them to excel at tasks that are under-represented on the Internet. Leveraging LLMs for specialized applications, particularly in niche programming languages and private domains, remains challenging and largely unsolved. In this work, we address this gap by presenting a comprehensive, open-source approach for adapting LLMs to the Q programming language, a popular tool in quantitative finance that is much less present on the Internet compared to Python, C, Java, and other ``mainstream" languages and is therefore not a strong suit of general-purpose AI models. We introduce a new Leetcode style evaluation dataset for Q, benchmark major frontier models on the dataset, then do pretraining, supervised fine tuning, and reinforcement learning to train a suite of reasoning and non-reasoning models based on the Qwen-2.5 series, spanning five parameter sizes (1.5B, 3B, 7B, 14B, 32B). Our best model achieves a pass@1 accuracy of 59 percent on our Q benchmark, surpassing the best-performing frontier model, Claude Opus-4 by 29.5 percent. Additionally, all models, even our 1.5B model, outperform GPT-4.1 on this task. In addition to releasing models, code, and data, we provide a detailed blueprint for dataset construction, model pretraining, supervised fine-tuning, and reinforcement learning. Our methodology is broadly applicable, and we discuss how these techniques can be extended to other tasks, including those where evaluation may rely on soft or subjective signals.

Key facts. No citing papers in the map yet (data through 7 Oct 2026). First posted on arXiv 9 Aug 2025.

Builds on

0 of 0 references.

No references here yet.

Built on by

Not cited yet.

Similar, not cited

Close in wording, no citation either way

  1. 2025LLMs Meet Finance: Fine-Tuning Foundation Models for the Open FinLLM Leaderboard
  2. 2026QuantEval: A Benchmark for Financial Quantitative Tasks in Large Language Models
  3. 2024Mixing It Up: The Cocktail Effect of Multi-Task Fine-Tuning on LLM Performance -- A Case Study in Finance
  4. 2026QuantCode Model: Specializing Language Models for Executable Algorithmic Trading Code
  5. 2024SNFinLLM: Systematic and Nuanced Financial Domain Adaptation of Chinese Large Language Models
  6. 2023DISC-FinLLM: A Chinese Financial Large Language Model based on Multiple Experts Fine-tuning
  7. 2025FEVO: Financial Knowledge Expansion and Reasoning Evolution for Large Language Models
  8. 2024The Ultimate Guide to Fine-Tuning LLMs from Basics to Breakthroughs: An Exhaustive Review of Technologies, Research, Best Practices, Applied Research Challenges and Opportunities