Fill-Mask
Transformers
PyTorch
ablang2-paired
biology
protein
antibody
ablang
chemistry
oas
cdr
ablang2 hf implementation
roberta
ESM
ablang2
antibody-design
custom_code
Instructions to use hemantn/ablang2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use hemantn/ablang2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="hemantn/ablang2", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("hemantn/ablang2", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
𧬠AbLang2 Sequence Restorer - Hugging Face Spaces
This is a Gradio web application that provides the AbLang2 sequence restoration utility through Hugging Face Spaces.
π― What it does
The AbLang2 Sequence Restorer allows you to:
- Restore masked residues (*) in antibody sequences
- Work with paired sequences (heavy and light chains)
- Handle single chains (heavy or light chain only)
- Use alignment for variable missing lengths
π How to use
- Enter sequences: Provide heavy chain, light chain, or both sequences
- Mask residues: Use
*to indicate residues you want to restore - Choose alignment: Enable "Use Alignment" for variable missing lengths
- Get results: Click "Restore Sequences" to get the restored antibody sequences
π Example Usage
Example 1: Both chains with masked residues
- Heavy Chain:
EVQ***SGGEVKKPGASVKVSCRASGYTFRNYGLTWVRQAPGQGLEWMGWISAYNGNTNYAQKFQGRVTLTTDTSTSTAYMELRSLRSDDTAVYFCAR**PGHGAAFMDVWGTGTTVTVSS - Light Chain:
DIQLTQSPLSLPVTLGQPASISCRSS*SLEASDTNIYLSWFQQRPGQSPRRLIYKI*NRDSGVPDRFSGSGSGTHFTLRISRVEADDVAVYYCMQGTHWPPAFGQGTKVDIK
Example 2: Heavy chain only
- Heavy Chain:
EVQLVESGGGLVQPGGSLRLSCAASGFTFSSYAMGWVRQAPGKGLEWVSAISGSGGSTYYADSVKGRFTISRDNSKNTLYLQMNSLRAEDTAVYYCARDY**GMDVWGQGTTVTVSS - Light Chain: (leave empty)
π§ Technical Details
- Model: AbLang2 from Hugging Face Hub (
hemantn/ablang2) - Framework: Gradio for the web interface
- Backend: PyTorch with Transformers library
- Processing: Automatic GPU acceleration when available
π Related Resources
- Original AbLang2: https://github.com/TobiasHeOl/AbLang2
- Model Repository: https://huggingface.co/hemantn/ablang2
- Full Documentation: See the main README.md for comprehensive usage examples
π€ Citation
If you use this tool in your research, please cite the original AbLang2 paper:
@article{Olsen2024,
title={Addressing the antibody germline bias and its effect on language models for improved antibody design},
author={Tobias H. Olsen, Iain H. Moal and Charlotte M. Deane},
journal={bioRxiv},
doi={https://doi.org/10.1101/2024.02.02.578678},
year={2024}
}