Papers › MAGMA -- Multimodal Augmentation of Generative Models through Adapter-based Finetuning

MAGMA -- Multimodal Augmentation of Generative Models through Adapter-based Finetuning

9 Dec 2021arXiv:2112.05253archive 2025-07-28

Constantin Eichenberg, Sidney Black, Samuel Weinbach, Letitia Parcalabescu, Anette Frank

Large-scale pretraining is fast becoming the norm in Vision-Language (VL) modeling. However, prevailing VL approaches are limited by the requirement for labeled data and the use of complex multi-step pretraining objectives. We present MAGMA - a simple method for augmenting generative language models with additional modalities using adapter-based finetuning. Building on Frozen, we train a series of VL models that autoregressively generate text from arbitrary combinations of visual and textual input. The pretraining is entirely end-to-end using a single language modeling objective, simplifying optimization compared to previous approaches. Importantly, the language model weights remain unchanged during training, allowing for transfer of encyclopedic knowledge and in-context learning abilities from language pretraining. MAGMA outperforms Frozen on open-ended generative tasks, achieving state of the art results on the OKVQA benchmark and competitive results on a range of other popular VL benchmarks, while pretraining on 0.2% of the number of samples used to train SimVLM.

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="2112.05253")

Code

Syntology Ran 10 of 15 code samples harvested from 1 repository linked to this paper; 5 have no recorded run. Of those that ran: 10 ran with no contract checked.

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

Aleph-Alpha/magma officialmentioned in papermentioned on GitHubpytorch report

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

15 samples harvested; 10 ran; 0 honoured the contract we drafted; 5 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.

10ran
5unverified

Licence: 0 of the 15 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 Aleph-Alpha/magma. “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.

eval_step Aleph-Alpha/magma/magma/train_loop.py official repository ran MIT (permissive) · 5efa2a11277a7471 · report
get_transforms Aleph-Alpha/magma/magma/transforms.py official repository ran MIT (permissive) · b28f8eba1c7bc3ab · report
load_config Aleph-Alpha/magma/magma/config.py official repository ran MIT (permissive) · ace12fad87592626 · report
load_model Aleph-Alpha/magma/magma/utils.py official repository ran MIT (permissive) · cda91d1c99cf9e9c · report
nfresnet50 Aleph-Alpha/magma/magma/image_encoders.py official repository ran MIT (permissive) · 628f0fcc54199efc · report
pad_to_size Aleph-Alpha/magma/magma/transforms.py official repository ran MIT (permissive) · e82e4764f914492f · report
pad_to_size_tensor Aleph-Alpha/magma/magma/transforms.py official repository ran fingerprinted MIT (permissive) · d3af6b05f019b479 · report
reduce_losses Aleph-Alpha/magma/magma/utils.py official repository ran fingerprinted MIT (permissive) · 4f70ab2c3e38d976 · report
remove_tokens_after_eos Aleph-Alpha/magma/magma/sampling.py official repository ran MIT (permissive) · ba246ce8c9917aba · report
top_k_filter Aleph-Alpha/magma/magma/sampling.py official repository ran fingerprinted MIT (permissive) · aa8cc3e8f125148a · report
get_gptj Aleph-Alpha/magma/magma/language_model.py official repository unverified MIT (permissive) · d4435db67cbbf30d · report
get_tokenizer Aleph-Alpha/magma/magma/utils.py official repository unverified MIT (permissive) · f057466b39aff113 · report
save_to_jsons Aleph-Alpha/magma/magma/datasets/convert_datasets.py official repository unverified MIT (permissive) · b92f1cee291214f5 · report
train_step Aleph-Alpha/magma/magma/train_loop.py official repository unverified MIT (permissive) · 5c7e7dc9d5bdc305 · report
train_step_classification Aleph-Alpha/magma/magma/train_loop.py official repository unverified MIT (permissive) · a2d4cd1429030731 · report

Tasks

In-Context LearningLanguage ModelingLanguage Modelling

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

SimVLM

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