Papers › Transformer-based World Models Are Happy With 100k Interactions

Transformer-based World Models Are Happy With 100k Interactions

13 Mar 2023arXiv:2303.07109archive 2025-07-28

Jan Robine, Marc Höftmann, Tobias Uelwer, Stefan Harmeling

Deep neural networks have been successful in many reinforcement learning settings. However, compared to human learners they are overly data hungry. To build a sample-efficient world model, we apply a transformer to real-world episodes in an autoregressive manner: not only the compact latent states and the taken actions but also the experienced or predicted rewards are fed into the transformer, so that it can attend flexibly to all three modalities at different time steps. The transformer allows our world model to access previous states directly, instead of viewing them through a compressed recurrent state. By utilizing the Transformer-XL architecture, it is able to learn long-term dependencies while staying computationally efficient. Our transformer-based world model (TWM) generates meaningful, new experience, which is used to train a policy that outperforms previous model-free and model-based reinforcement learning algorithms on the Atari 100k benchmark.

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

Code

Syntology Ran 16 of 25 code samples harvested from 1 repository linked to this paper; 9 have no recorded run. Of those that ran: 1 ran · honoured contract; 1 ran · violated contract; 7 ran · our draft was wrong; 1 ran · fixture could not drive it; 6 ran with no contract checked.

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

jrobine/twm officialmentioned in paperpytorch 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

25 samples harvested; 16 ran; 1 honoured the contract we drafted; 9 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 · violated contract
7ran · our draft was wrong
1ran · fixture could not drive it
6ran
9unverified

Licence: 0 of the 25 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 jrobine/twm. “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.

AdamOptim jrobine/twm/twm/world_model.py official repository ran MIT (permissive) · 006d91bc0bd061db · report
PositionalEncoding jrobine/twm/twm/world_model.py official repository ran fingerprinted MIT (permissive) · e1c8c42def7db040 · report
RelativeMultiheadSelfAttention jrobine/twm/twm/world_model.py official repository ran MIT (permissive) · ea267d5f625dc1ca · report
TransformerXLDecoder jrobine/twm/twm/world_model.py official repository ran MIT (permissive) · 425555f50f17e87d · report
TransformerXLDecoderLayer jrobine/twm/twm/world_model.py official repository ran MIT (permissive) · fdc181c488b365db · report
_MultilayerModule jrobine/twm/twm/world_model.py official repository ran MIT (permissive) · 8cfa03dabb18e3af · report
_calculate_gain jrobine/twm/twm/world_model.py official repository ran · honoured contract MIT (permissive) · d25a054b95990a84 · report
_get_initializer jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · a7250d5b635dd398 · report
combine_metrics jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · ab154d639b4e4ae3 · report
get_activation jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · 5439c3b62dbdc1fc · report
get_norm_1d jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · 4e5362cab16fd0f9 · report
get_norm_2d jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · 84eae076a18b163d · report
init_ jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · fd4dd5bdc9742fc0 · report
same_batch_shape jrobine/twm/twm/world_model.py official repository ran · violated contract MIT (permissive) · 7e4ce9c6f41f3336 · report
same_batch_shape_time_offset jrobine/twm/twm/world_model.py official repository ran · fixture could not drive it fingerprinted MIT (permissive) · 165f8bc0355a9865 · report
update_metrics jrobine/twm/twm/world_model.py official repository ran · our draft was wrong MIT (permissive) · 6f69e804fca3263d · report
CNN jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 173854afd0798188 · report
DynamicsModel jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · c61718d72bba4f72 · report
MLP jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 103a05c5c1b23236 · report
ObservationModel jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 430454696696dc84 · report
PredictionNet jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 34a08d167acd0d24 · report
TransposeCNN jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 82ffe40472f6c427 · report
WorldModel jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · dd79139c2de865e1 · report
_kaiming_uniform_ jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 426051c1e209bfef · report
check_no_grad jrobine/twm/twm/world_model.py official repository unverified MIT (permissive) · 862742223d0ec96a · report

Tasks

Model-based Reinforcement LearningReinforcement LearningReinforcement Learning (RL)reinforcement-learning

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Methods

AdamAdaptive Input RepresentationsAdaptive SoftmaxAttentionCosine AnnealingDense ConnectionsDropoutLayer NormalizationLinear LayerLinear Warmup With Cosine AnnealingMulti-Head AttentionReLUResidual ConnectionSoftmaxTransformer-XLVariational Dropout

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