vibesketch.document.monomers

Peptide modifications beyond RDKit’s HELM library, from a curated table (#98).

RDKit reads HELM peptides built from its own monomer library, which has the acetyl (ac) and amide (am) caps but lacks other common modifications, such as N-methyl amino acids and phosphorylated residues. This table adds a few, by the symbols of the Pistoia Alliance HELM core monomer library (github.com/PistoiaHELM/HELMMonomerSets), so HELM written by other programs reads here. Only the symbols are taken from that library, no structures: each modification is made on the standard residue RDKit builds, by its PDB atom name, and tested against a hand-written structure. A HELM that RDKit cannot read because of them may also carry the caps, which are then made here the same way.

The table grows on demand, each entry with its test (maintainer decision, 2026-10-24).

Module Attributes

MODIFIED

The modified residues, by their HELM core library symbol.

CAPS

N-acetyl first in the chain, C-terminal amide last, and what a figure prints in place of H- and -OH.

Functions

curated_peptide(helm)

The molecule of a one-chain peptide HELM using curated monomers, or None.

Classes

Modification(residue, change, printed)

A standard residue and what is changed on it.

Exceptions

MonomerRefused

The HELM uses a curated monomer where it cannot stand.

vibesketch.document.monomers.CAPS = {'ac': 'Ac', 'am': 'NH2'}

N-acetyl first in the chain, C-terminal amide last, and what a figure prints in place of H- and -OH.

Type:

The terminal caps

vibesketch.document.monomers.MODIFIED: dict[str, Modification] = {'Ser_PO3H2': Modification(residue='S', change='phospho', printed='Ser(PO3H2)'), 'Thr_PO3H2': Modification(residue='T', change='phospho', printed='Thr(PO3H2)'), 'Tyr_PO3H2': Modification(residue='Y', change='phospho', printed='Tyr(PO3H2)'), 'meA': Modification(residue='A', change='methyl', printed='MeAla'), 'meF': Modification(residue='F', change='methyl', printed='MePhe'), 'meG': Modification(residue='G', change='methyl', printed='Sar'), 'meH': Modification(residue='H', change='methyl', printed='MeHis'), 'meL': Modification(residue='L', change='methyl', printed='MeLeu'), 'meW': Modification(residue='W', change='methyl', printed='MeTrp')}

The modified residues, by their HELM core library symbol.

class vibesketch.document.monomers.Modification(residue, change, printed)[source]

Bases: object

A standard residue and what is changed on it.

Parameters:
  • residue (str)

  • change (Literal['methyl', 'phospho'])

  • printed (str)

residue: str

The residue’s one-letter code.

change: Literal['methyl', 'phospho']

A methyl on the backbone nitrogen, or a phosphate on the side-chain hydroxyl.

printed: str

IUPAC-IUB JCBN 1983 symbols, a substituent on the side chain in parentheses and an N-methyl as Me before the symbol.

Type:

How a figure prints it

exception vibesketch.document.monomers.MonomerRefused[source]

Bases: ValueError

The HELM uses a curated monomer where it cannot stand.

vibesketch.document.monomers.curated_peptide(helm)[source]

The molecule of a one-chain peptide HELM using curated monomers, or None.

None when the HELM uses none of them, so RDKit’s own reading stands. Refuses a cap anywhere but its end of the chain and links to a cap.

Parameters:

helm (str)

Return type:

Any | None