atlas

Research map / Large language models / Agents, code and math

Number Cookbook: Number Understanding of Language Models and How to Improve It

ICLR 2025 · Large language models › Agents, code and math · approach: Mathematical and structural reasoning benchmarks · 2 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Introduces the NUPA Test, a 41-task benchmark of number understanding and processing across four number formats, evaluates frontier LLMs, and studies tokenizers, positional encodings, data formats, finetuning, and rule-following CoT for improving NUPA.

Problem

LLMs make basic numerical errors (e.g., comparing 9.11 and 9.9) and reasoning benchmarks conflate numerical processing with reasoning, so the basic number understanding and processing ability (NUPA) is poorly measured and improved.

Approach

A systematic benchmark that crosses four number representations (integer, float, fraction, scientific notation) with 17 education-derived tasks to form 41 tasks, with digit-level metrics (digit match, dlength), used to test pretraining tricks, finetuning, and CoT for NUPA.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Fine-tune LLaMA 3.1-8B with RF-CoT rather than directly generating answersLLaMA 3.1-8B · Add Float, 5 digitsexact match: 0.78 -> 1.00 ±.00Helped
Fine-tune LLaMA 3.1-8B with RF-CoT rather than directly generating answersLLaMA 3.1-8B · Multiply Fraction, 2 digitsexact match: 0.50{ $\pm$.02} -> 0.93 ±.01Helped
Fine-tune LLaMA 3.1-8B with RF-CoT rather than directly generating answersLLaMA 3.1-8B · Max Scientific, 38 digitsexact match: 0.98{ $\pm$.01} -> 1.00 ±.00; 0.96 -> 1.00 ±.00Mixed
Fine-tune LLaMA 3.1-8B with RF-CoT rather than directly generating answersLLaMA 3.1-8B · Mod Integer, 6 digitsexact match: 0.08{ $\pm$.02} -> 0.67 ±.05Helped
Use RF-CoT instead of direct answer generationLLaMA 3.1-8B · NUPA Testsec / sample: 0.371 -> 5.625Hurt
Use one-digit instead of two- or three-digit tokenization0.9B models trained on integer addition, float addition, and integer multiplication · NUPA Test, in-domain and out-of-domainexact matchHelped
Increase tokenizer digit width from one digit to two or three digitsNUPA models · NUPA Testexact matchHurt
Use random tokenization instead of standard tokenizationnumber-domain models · Length generalizationexact matchMixed
Use Alibi or NoPE instead of RoPE100M models · Integer addition, float addition, fraction multiplication, scientific notation additionexact matchHelped
Use reverse formatting, zero padding, or both instead of vanilla number formattingmodels trained on integer and float addition · Length generalizationexact matchHelped
Add index hints to number digitsmodels trained on NUPA tasks · NUPA Testexact matchNo clear effect
Finetune LLaMA 3.1-8B on a mixed set of NUPA tasksLLaMA 3.1-8B · NUPA Testexact matchHelped

Surprising findings

Limitations

Experimental setup

Datasets: NUPA Test generated training and validation sets

Benchmarks: NUPA Test

Metrics: exact match digit match dlength

Baselines: GPT-4o GPT-4o-mini Llama-3.1-8B Llama-3.1-70B Qwen2-7B Qwen2-72B Mixtral-8x7B Llama-2-7b

Builds on: rule-following chain-of-thought random tokenizer LoRA

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy