bioRxivBioinformaticsPreprint
Self-Contemplating In-Context Learning Enhances T Cell Receptor Generation for Novel Epitopes
Abstract
Computational design of T cell receptors (TCRs) that bind to epitopes holds the potential to revolutionize targeted immunotherapy. However, computational design of TCRs for novel epitopes is challenging due to the scarcity of training data, and the absence of known cognate TCRs for novel epitopes. In this study, we aim to generate high-quality cognate TCRs particularly for novel epitopes with no known cognate TCRs, a problem that remains under-explored in the field. We propose to incorporate in-context learning, successfully used with large language models to perform new generative tasks, to the task of TCR generation for novel epitopes. By providing cognate TCRs as additional context, we enhance the models ability to generate high-quality TCRs for novel epitopes. We first unlock the power of in-context learning by training a model to generate new TCRs based on both a target epitope and a small set of its cognate TCRs, so-called in-context training (ICT). We then self-generate its own TCR contexts based on a target epitope, as novel epitopes lack known binding TCRs, and use it as an inference prompt, referred to as self-contemplation prompting (SCP). Our experiments first demonstrate that aligning training and inference distribution by ICT is critical for effectively leveraging context TCRs. Subsequently, we show that providing context TCRs significantly improves TCR generation for novel epitopes. Furthermore, we show TCR generation using SCP-synthesized context TCRs achieves performance comparable to, and sometimes surpassing, ground-truth context TCRs, especially when combined with refined prompt selection based on binding affinity and authenticity metrics.
- research focus: drug response / drug discovery
- research focus: protein design
- approach: machine learning (classical)
- Citations
- 1
Reproducibility ledger
Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.
Sign in to file a reproducibility report.
Related papers
- De novo generation of T-cell receptors with desired epitope-binding property by leveraging a pre-trained large language model
Jiannan Yang, Bing He, … Jianhua Yao·bioRxiv·Oct 18, 2023
- TcrDesign: De novo design of epitope specific full-length T cell receptors
Kaixuan Diao, Jing Chen, … Xue-Song Liu·Science China Life SciencesPeer-reviewed·Apr 28, 2026
- Repertoire-level generation of T-cell epitopes with a large-scale generative transformer
Minuk Ma, Wilson Tu, … Jiarui Ding·bioRxiv·Jan 13, 2025
- GRATCR: epitope-specific T cell receptor sequence generation with data-efficient pre-trained models
Zhenghong Zhou, Junwei Chen, … Yi Xiong·IEEE Journal of Biomedical and Health InformaticsPeer-reviewed·Feb 10, 2025
- Engineering Endogenous T Cell Receptors to Recognize Cancer Neoantigens Using a Hybrid Physics-AI Approach
Jeffrey K. Weber, Gyanu Parajuli, … Timothy An-thy Chan·bioRxiv·May 19, 2026
- Generative design of antigen-specific T-cell receptor sequences with a conditional diffusion model
Yumeng Zhang, Wenhua Liang, … Jiangning Song·bioRxiv·Jul 1, 2026