Papers › Language Adaptation on a Tight Academic Compute Budget: Tokenizer Swapping Works and...

Language Adaptation on a Tight Academic Compute Budget: Tokenizer Swapping Works and Pure bfloat16 Is Enough

28 Aug 2024arXiv:2408.15793archive 2025-07-28

Konstantin Dobler, Gerard de Melo

We investigate continued pretraining of LLMs for language adaptation on a tight academic budget: a setting in which only a few GPUs can be used in parallel, for a heavily constrained duration. We focus on adapting Mistral-7B to German or Arabic and evaluate several techniques to improve efficiency and effectiveness in this setting. Our German models adapted on this tight compute budget underperform compared to the base Mistral-7B, while our Arabic models outperform several baselines, showing that for sufficiently well-represented languages, continued pretraining for specialization is not always helpful. Our main findings focus on training precision and tokenizer swapping. Our results show that pure bfloat16 training is a viable alternative to mixed-precision training, while being much faster when only using a few GPUs. Swapping the tokenizer for a specialized one yields more efficient tokenization and is competitive with the original tokenizer, which already contains some German tokens, but did not significantly increase performance for German. Code and model weights are available at on GitHub.

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2408.15793")

Code

Syntology Ran 13 of 19 code samples harvested from 1 repository linked to this paper; 6 have no recorded run. Of those that ran: 1 ran · honoured contract; 1 ran · our draft was wrong; 11 ran with no contract checked.

By repository: official repository: 19 samples from 1 repository, 13 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

19 samples harvested; 13 ran; 1 honoured the contract we drafted; 6 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

1ran · honoured contract
1ran · our draft was wrong
11ran
6unverified

Licence: 0 of the 19 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from konstantinjdobler/tight-budget-llm-adaptation. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

clean_name konstantinjdobler/tight-budget-llm-adaptation/dlib/checkpointing.py official repository ran fingerprinted MIT (permissive) · 66d977e369c51487 · report
clean_name konstantinjdobler/tight-budget-llm-adaptation/dlib/model_profiling.py official repository ran fingerprinted MIT (permissive) · 6918de657eafc50f · report
find_multiple konstantinjdobler/tight-budget-llm-adaptation/dlib/utils.py official repository ran fingerprinted MIT (permissive) · b25892e03bf1cf0a · report
flops_per_param konstantinjdobler/tight-budget-llm-adaptation/dlib/speed_monitor.py official repository ran fingerprinted MIT (permissive) · 76c1f0017f2562ed · report
format_elapsed_time konstantinjdobler/tight-budget-llm-adaptation/dlib/utils.py official repository ran fingerprinted MIT (permissive) · 5d606d4fab8d2be4 · report
get_lr_with_cosine_schedule konstantinjdobler/tight-budget-llm-adaptation/dlib/lr_schedules.py official repository ran MIT (permissive) · f188d07e3a737f21 · report
get_max_seqlen_in_batch konstantinjdobler/tight-budget-llm-adaptation/helpers/mokey_patch_fa_packing.py official repository ran MIT (permissive) · d4a53ff33a6fcd12 · report
get_optimizer konstantinjdobler/tight-budget-llm-adaptation/dlib/get_optimizer.py official repository ran MIT (permissive) · 34c25d7be7a8152e · report
get_unpad_data konstantinjdobler/tight-budget-llm-adaptation/helpers/mokey_patch_fa_packing.py official repository ran MIT (permissive) · 6167fdcdd4d5d961 · report
hex2dec konstantinjdobler/tight-budget-llm-adaptation/helpers/smart_heuristics.py official repository ran · honoured contract fingerprinted MIT (permissive) · 74b4020b7c03984e · report
log_model_stats_to_wandb konstantinjdobler/tight-budget-llm-adaptation/dlib/model_profiling.py official repository ran MIT (permissive) · 2e6b7b3694e81d06 · report
num_parameters konstantinjdobler/tight-budget-llm-adaptation/dlib/utils.py official repository ran MIT (permissive) · 5109370b9cf73f69 · report
top_script konstantinjdobler/tight-budget-llm-adaptation/helpers/smart_heuristics.py official repository ran · our draft was wrong MIT (permissive) · 8e6d49aaf98611d9 · report
estimate_flops konstantinjdobler/tight-budget-llm-adaptation/dlib/speed_monitor.py official repository unverified MIT (permissive) · 0eb4b83e52cb9d84 · report
get_flops_available konstantinjdobler/tight-budget-llm-adaptation/dlib/speed_monitor.py official repository unverified MIT (permissive) · ad0d4ccf7268fb64 · report
get_ord2script konstantinjdobler/tight-budget-llm-adaptation/helpers/smart_heuristics.py official repository unverified MIT (permissive) · e8e4a9db7236b331 · report
monkey_patched_mistral_forward_for_pretraining_with_attn_mask_fix konstantinjdobler/tight-budget-llm-adaptation/helpers/mokey_patch_fa_packing.py official repository unverified MIT (permissive) · 5d646da0f559c685 · report
my_modded_dist_save konstantinjdobler/tight-budget-llm-adaptation/dlib/checkpointing.py official repository unverified MIT (permissive) · 077df7ccd5f734f7 · report
sharded_calculate_and_log_stats konstantinjdobler/tight-budget-llm-adaptation/dlib/model_profiling.py official repository unverified MIT (permissive) · 8df89d90dd3e4c21 · report

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

BASEFocus

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections