SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2506.12860 · 2025

QFFT, Question-Free Fine-Tuning for Adaptive Reasoning

arXiv · PDF · Open in the Atlas

Code that ran

14 of 14 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 1 honoured the contract we drafted, 3 violated it and 7 have no contract verdict; 3 failures of our instrument; 0 no recorded run), measured 2026-11-24; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2506.12860.json · badge: /api/ran/2506.12860.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
lwl-cpu/question-free-fine-tuning canonical (classifier label)
classifier basis not recorded on the link
14 ran · 0 no recorded run
FunctionStatusWhere it lives
check_sympy_equivalence Ran
ran, violated the contract we drafted
lwl-cpu/question-free-fine-tuning/eval/utils/math_normalization.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from gair-nlp/weak-to-strong-reasoning, is pointer only (licence: NONE) · get_code("33973ae45a70d4fe")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from gair-nlp/weak-to-strong-reasoning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

choice_answer_clean Ran
ran; our contract draft was wrong, not the code
lwl-cpu/question-free-fine-tuning/eval/utils/grader.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from QwenLM/Qwen2.5-Math, is pointer only (licence: NONE) · get_code("809c0178a7ae90ff")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from QwenLM/Qwen2.5-Math, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

contains_wait Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/utils/analysis_difficulty.py
code served (permissive licence) · get_code("b123cac6601e152a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import re

def contains_wait(response):
    """Check if response contains the word 'wait' (case-insensitive)."""
    return bool(re.search('\\bwait\\b', response.lower(), re.IGNORECASE))

ARGS = {
    "response": "Please wait for the response"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
extract_multi_choice_answer Ran
ran; our contract draft was wrong, not the code
lwl-cpu/question-free-fine-tuning/eval/utils/parser.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from QwenLM/Qwen2.5-Math, is pointer only (licence: NONE) · get_code("ed2f4689128f9885")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from QwenLM/Qwen2.5-Math, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

extract_question Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/utils/analysis_difficulty.py
code served (permissive licence) · get_code("3bf1dc9721e95221")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import re

def extract_question(problem):
    """Extract question text between <|im_start|>user
 and <|im_end|>
, or return problem if no markers."""
    if '<|im_start|>' in problem:
        pattern = '<\\|im_start\\|>user\\n(.*?)<\\|im_end\\|>\\n'
        match = re.search(pattern, problem, re.DOTALL)
        if match:
            return match.group(1).strip()
        return ''
    else:
        return problem


# Test case 1: problem with markers
problem_with_markers = '<|im_start|>user\nWhat is the capital of France?\n<|im_end|>\n'

# Test case 2: problem without markers
problem_without_markers = 'What is the capital of France?'

ARGS = {
    'problem': problem_with_markers
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_conversation_prompt_by_messages Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/eval_tp.py
code served (permissive licence) · get_code("9c58d0990f07be11")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

class MockTokenizer:
    def apply_chat_template(self, messages, tokenize=False, add_generation_prompt=False):
        # Simulate a chat template output
        result = "[SYSTEM] System message [USER] User message [ASSISTANT] <think>\nThinking process\n</think> Response"
        return result

tokenizer = MockTokenizer()

messages = [
    {"role": "system", "content": "You are a helpful assistant."},
    {"role": "user", "content": "What is 2+2?"},
]

ARGS = {
    "tokenizer": tokenizer,
    "messages": messages,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_three_prompt Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/eval_tp.py
code served (permissive licence) · get_code("e458dae2ed344834")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os
import tempfile
import shutil

# Create a temporary directory structure for prompts
temp_dir = tempfile.mkdtemp()
prompts_dir = os.path.join(temp_dir, 'prompts')
os.makedirs(prompts_dir, exist_ok=True)

# Create subdirectories for different prompt types
prompt_type_dir = os.path.join(prompts_dir, 'test_type')
os.makedirs(prompt_type_dir, exist_ok=True)

# Create a prompt file with the required attributes
prompt_file_path = os.path.join(prompt_type_dir, 'test_data.py')
with open(prompt_file_path, 'w') as f:
    f.write("""
system_prompt = "You are a helpful assistant."
few_shot_prompt = "Example 1: Question -> Answer"
question_format = "Q: {question}\\nA:"
""")

# Change to temp directory so relative path works
original_cwd = os.getcwd()
os.chdir(temp_dir)

try:
    ARGS = {
        'prompt_type': 'test_type',
        'data_name': 'test_data'
    }
finally:
    # Note: In actual execution, you'd want to manage cleanup
    # For this setup, the temp directory persists for the function call
    pass
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
is_digit Ran
ran, violated the contract we drafted
lwl-cpu/question-free-fine-tuning/eval/utils/grader.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from QwenLM/Qwen2.5-Math, is pointer only (licence: NONE) · get_code("fb37d3c84b18e368")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from QwenLM/Qwen2.5-Math, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

is_integer Ran
ran, violated the contract we drafted
lwl-cpu/question-free-fine-tuning/eval/utils/math_normalization.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from gair-nlp/weak-to-strong-reasoning, is pointer only (licence: NONE) · get_code("b804c6d0a0ddb922")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from gair-nlp/weak-to-strong-reasoning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

load_math_test_levels Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/utils/analysis_difficulty.py
code served (permissive licence) · get_code("41c9b27031e839a7")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import json
import tempfile
import os

# Create a temporary JSONL file with math test data
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.jsonl', encoding='utf-8')
temp_file_path = temp_file.name

try:
    # Write sample JSONL data
    test_data = [
        {'problem': 'What is 2+2?', 'level': 1},
        {'problem': 'Solve x^2 = 4', 'level': 2},
        {'problem': 'Integrate sin(x) dx', 'level': 3},
        {'problem': 'Find eigenvalues of [[1,2],[3,4]]', 'level': 4},
    ]
    
    for item in test_data:
        temp_file.write(json.dumps(item) + '\n')
    
    temp_file.close()
    
    ARGS = {
        'file_path': temp_file_path
    }

finally:
    # Clean up will happen after execution
    pass
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
major_vote_accuracy Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/analysis/cal_all_cli.py
code served (permissive licence) · get_code("85f17e50933711f8")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import random

# Set seed for reproducibility
random.seed(0)

# Create a list of generated answers with some duplicates to ensure voting works
generated_answers = [
    "Paris",
    "Paris", 
    "Paris",
    "London",
    "London",
    "Berlin",
    "Madrid",
    "Rome",
    "Amsterdam",
    "Vienna",
    "Prague",
    "Warsaw"
]

# Create a gold answer
gold_answer = "Paris"

# Define the arguments dict
ARGS = {
    "generated_answers": generated_answers,
    "gold_answer": gold_answer,
    "k": 4,
    "num_samples": 10
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
normalize_final_answer Ran
ran; our contract draft was wrong, not the code
lwl-cpu/question-free-fine-tuning/eval/utils/math_normalization.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from gair-nlp/weak-to-strong-reasoning, is pointer only (licence: NONE) · get_code("31ee6b861ee71ef7")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from gair-nlp/weak-to-strong-reasoning, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

parse_digits Ran
ran, honoured the contract we drafted
lwl-cpu/question-free-fine-tuning/eval/utils/grader.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from QwenLM/Qwen2.5-Math, is pointer only (licence: NONE) · get_code("7d4b7f8c3875b126")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from QwenLM/Qwen2.5-Math, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

parse_list Ran
ran on a synthesized input
lwl-cpu/question-free-fine-tuning/eval/eval_tp.py
code served (permissive licence) · get_code("c5b5032445c33c60")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

def parse_list(arg):
    return arg.split(',')

ARGS = {
    'arg': 'hello,world,test'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block

Also present in other papers' code

Of 14 samples lifted from this paper's linked repositories, 14 carry a function identity and 0 do not. Of the 14 distinct functions with an identity, 7 are also present in other papers whose code we hold (7 with at least one paper dated earlier, 0 the same month, 4 later) and 7 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
is_digit 18 other papers
11 dated earlier, 6 later, 1 undated
2405.14365 (2024-05)
JiuZhang3.0: Efficiently Improving Mathematical Reasoning by Training Small Data Synthesis Models
2410.07985 (2024-10)
Omni-MATH: A Universal Olympiad Level Mathematic Benchmark For Large Language Models
2502.06703 (2025-02)
Can 1B LLM Surpass 405B LLM? Rethinking Compute-Optimal Test-Time Scaling
and 15 more not named here
parse_digits 18 other papers
11 dated earlier, 6 later, 1 undated
2405.14365 (2024-05)
JiuZhang3.0: Efficiently Improving Mathematical Reasoning by Training Small Data Synthesis Models
2410.07985 (2024-10)
Omni-MATH: A Universal Olympiad Level Mathematic Benchmark For Large Language Models
2502.06703 (2025-02)
Can 1B LLM Surpass 405B LLM? Rethinking Compute-Optimal Test-Time Scaling
and 15 more not named here
choice_answer_clean 15 other papers
10 dated earlier, 4 later, 1 undated
2410.07985 (2024-10)
Omni-MATH: A Universal Olympiad Level Mathematic Benchmark For Large Language Models
2502.06703 (2025-02)
Can 1B LLM Surpass 405B LLM? Rethinking Compute-Optimal Test-Time Scaling
2502.06773 (2025-02)
On the Emergence of Thinking in LLMs I: Searching for the Right Intuition
and 12 more not named here
extract_multi_choice_answer 12 other papers
8 dated earlier, 3 later, 1 undated
2405.14365 (2024-05)
JiuZhang3.0: Efficiently Improving Mathematical Reasoning by Training Small Data Synthesis Models
2408.03314 (2024-08)
Scaling LLM Test-Time Compute Optimally can be More Effective than Scaling Model Parameters
2410.07985 (2024-10)
Omni-MATH: A Universal Olympiad Level Mathematic Benchmark For Large Language Models
and 9 more not named here
check_sympy_equivalence 2 other papers
2 dated earlier
2407.13647 (2024-07)
Weak-to-Strong Reasoning
2505.15404 (2025-05)
How Should We Enhance the Safety of Large Reasoning Models: An Empirical Study
is_integer 2 other papers
2 dated earlier
2407.13647 (2024-07)
Weak-to-Strong Reasoning
2505.15404 (2025-05)
How Should We Enhance the Safety of Large Reasoning Models: An Empirical Study
normalize_final_answer 2 other papers
2 dated earlier
2407.13647 (2024-07)
Weak-to-Strong Reasoning
2505.15404 (2025-05)
How Should We Enhance the Safety of Large Reasoning Models: An Empirical Study

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-24.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Recent advancements in Long Chain-of-Thought (CoT) reasoning models have improved performance on complex tasks, but they suffer from overthinking, which generates redundant reasoning steps, especially for simple questions. This paper revisits the reasoning patterns of Long and Short CoT models, observing that the Short CoT patterns offer concise reasoning efficiently, while the Long CoT patterns excel in challenging scenarios where the Short CoT patterns struggle. To enable models to leverage both patterns, we propose Question-Free Fine-Tuning (QFFT), a fine-tuning approach that removes the input question during training and learns exclusively from Long CoT responses. This approach enables the model to adaptively employ both reasoning patterns: it prioritizes the Short CoT patterns and activates the Long CoT patterns only when necessary. Experiments on various mathematical datasets demonstrate that QFFT reduces average response length by more than 50\%, while achieving performance comparable to Supervised Fine-Tuning (SFT). Additionally, QFFT exhibits superior performance compared to SFT in noisy, out-of-domain, and low-resource scenarios.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2506.12860")
get_code_for_paper("2506.12860")
have("2506.12860")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2506.12860.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2506.12860.svg)](https://syntology.ai/paper/2506.12860)

Connect an agent — have() is free.