Install any skill in seconds. Free to start, no credit card required.
Get Started Free →xuzhougeng/fair-esm2
Embed proteins with Meta AI's ESM-2 (`fair-esm` package).
Passed 18 of 20 test cases with the skill, and 11 of 20 without it.
and 7 more in the full report
8 fixed12 passed either way2 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 6 test cases the skill fixed. Same model, same prompt, with and without the skill.
When retrieving contact predictions from an ESM-2 forward pass for a single sequence of length L (with batch size 1), what is the shape of the output tensor stored under the 'contacts' key after indexing the batch?
| Checked | Without skill | With skill |
|---|---|---|
| The output contact tensor shape is specified as (L, L) for a single sequence. | Missed | Passed |
The instructions your model reads when the skill loads.
ESM-2 code and weights are MIT (Meta AI, github.com/facebookresearch/esm).
Package disambiguation.
pip install fair-esmgives youimport esmwithesm.pretrained.*(ESM-1/2). Biohub's github.com/Biohub/esm fork (MIT) gives youfrom esm.models.esmfold2 import ESMFold2InputBuilder— see theesmfold2skill. Both share theesmnamespace but are different libraries. This skill covers fair-esm (the Meta package).
| Requirement | Minimum | Recommended |
|---|---|---|
| Python | 3.8+ | 3.11 |
| CUDA | 11.7+ | 12.x |
| GPU VRAM | 8 GB (8M), 16 GB (650M) | 24 GB+ (650M / 3B) |
import torch, esm
model, alphabet = esm.pretrained.esm2_t33_650M_UR50D()
model = model.eval().cuda()
bc = alphabet.get_batch_converter()
_, _, toks = bc([("ubq", "MQIFVKTLTGKTITLEVEPSDTIENVK")])
with torch.no_grad():
out = model(toks.cuda(), repr_layers=[33])
emb = out["representations"][33] # (1, L+2, 1280) — includes BOS/EOS
seq_emb = emb[0, 1:-1].mean(0) # per-sequence mean
with torch.no_grad():
test cases passed, vs 11 / 20 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.