> ## Documentation Index
> Fetch the complete documentation index at: https://proto.evodesign.org/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# IgLM Antibody Language Model

> IgLM antibody language model for full-length chain generation from a prompt

![IgLM Antibody Language Model](https://proto-bio.github.io/proto-assets/images/generator/iglm/hero.png)

> [!NOTE]
>
> **License:** IgLM is licensed under Custom (JHU Academic Software License Agreement) and has restrictions around commercial use and may require explicit attribution when utilized. Please refer to [the license](https://github.com/Graylab/IgLM/blob/main/LICENSE.md) for full terms.

This generator is open source. Any third-party models, product names, or trademarks referenced are the property of their respective owners, and Proto is not affiliated with them.

***

&#x20;Tools Used Tools Used  Source Source  Cite Cite

![](https://proto-bio.github.io/proto-assets/images/tool/iglm/social.png)

&#x20;Go to Tool Page

[Open](https://proto.evodesign.org/docs/tools/causal-models/iglm.md)

![Proto](https://mintcdn.com/bio-pro/cMLt8hAqaP9M3LKy/assets/logo/logo-light.svg?fit=max\&auto=format\&n=cMLt8hAqaP9M3LKy\&q=85\&s=f5e5dfd1b8f9b9db3a0be0e2eb01f678)

evo-design/proto-language

&#x20;View source

[Open](https://github.com/evo-design/proto-language/blob/1a97e675c7e5e4ae0e92be91b1bb7b49f1331104/proto_language/generator/iglm_generator.py#L189)

@articleshuai2023iglm

```bibtex theme={null}
@article{shuai2023iglm,
  title={IgLM: Infilling language modeling for antibody sequence design},
  author={Shuai, Richard W and Ruffolo, Jeffrey A and Gray, Jeffrey J},
  journal={Cell Systems},
  volume={14},
  number={11},
  pages={979--989.e4},
  year={2023},
  publisher={Elsevier},
  doi={10.1016/j.cels.2023.10.001}
}
```

&#x20;Copy citation

Generator contributors[![](https://avatars.githubusercontent.com/u/61667248?v=4\&s=64)adititm](https://github.com/adititm)[![](https://avatars.githubusercontent.com/u/21143637?v=4\&s=64)bviggiano](https://github.com/bviggiano)
Antibody chain generator using IgLM full-length sampling.

Each proposal gets one prompt (a single prompt is replicated across proposals) and is
overwritten with one IgLM chain continuing it under the configured chain and species
tokens. IgLM chooses the chain length; the segment's length is not a budget, only the
length below which the generator base class warns that a chain came out short.

## API Reference

ConfigIgLMGeneratorConfig[ Source](https://github.com/evo-design/proto-language/blob/1a97e675c7e5e4ae0e92be91b1bb7b49f1331104/proto_language/generator/iglm_generator.py#L120)

Configuration object for IgLMGenerator.

**prompts** `List[string]`

N-terminal prefixes to continue; an empty string generates from conditioning alone

**prepend\_prompt** `boolean` (default: True)

Whether to prepend prompt to generation

**model\_checkpoint** `enum` (default: IgLM)

IgLM weights variant; 'IgLM' is 13M parameters, 'IgLM-S' is 1.4M

Options: `IgLM`, `IgLM-S`

**chain** `enum` (default: heavy)

Chain-type conditioning token for IgLM.

Options: `heavy`, `light`

**species** `enum` (default: human)

Species-of-origin conditioning token for IgLM.

Options: `human`, `mouse`, `rat`, `rabbit`, `rhesus`, `camel`

**temperature** `number` (default: 1.0)

Sharpness of sampling. Below 1 favors high-probability residues; above 1 adds diversity.

**top\_p** `number` (default: 1.0)

Nucleus sampling cumulative probability cutoff. 1.0 disables nucleus sampling.

**max\_length** `integer` (default: 150)

IgLM token budget per generation, including conditioning and format tokens.

**batch\_size** `integer` (default: 1)

Candidate sequences IgLM draws per GPU forward pass

**device** `string` (default: cuda)

GPU device to run IgLM on (e.g. 'cuda' or 'cuda:0').

## Usage

```python python icon="python" theme={null}
>>> from proto_language.core import Segment
>>> from proto_language.generator import IgLMGenerator, IgLMGeneratorConfig
>>> gen = IgLMGenerator(IgLMGeneratorConfig(prompts="QVQ", chain="heavy", species="camel"))
>>> segment = Segment(length=110, sequence_type="protein")
>>> gen.assign(segment)
>>> gen.sample()  # one camel heavy chain starting QVQ per proposal
```

## Metadata

| Property | Value |
| - | - |
| Key | `iglm` |
| Class | `IgLMGenerator` |
| Category | `autoregressive` |
| Input Type | `prompt` |
| Uses GPU | `True` |
| Supported Sequence Types | `protein` |
| Allows Empty Start | `False` |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.