chai1
できること
このスキルは、タンパク質、RNA、DNA、低分子の複合体を予測するオープンなモデルの Chai-1 を実行する方法を説明します。抗体、バインダー、リガンドの研究のためのものです。
使う場面
- ✓研究者が、FASTA ファイルから抗体と抗原の複合体を予測したいとき。
- ✓科学者が、タンパク質とリガンドの予測を確かめるための二つ目のモデルを求めているとき。
- ✓チームが、GPU で複合体の予測をバッチで実行するとき。
スキルのリンク
https://github.com/aipoch/open-science/blob/main/resources/skills/chai1/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“この FASTA ファイルから、この抗体と抗原の複合体を予測し、結果を順位付けしてください。”
毎週5つの新しいスキル。1分で読めます。
仕組み
エージェントは、各鎖またはリガンドを記した FASTA ファイルを書き、リサイクルとサンプリングの設定で Chai-1 を実行し、ランキングのスコアを読みます。出力には、信頼度の指標付きの構造ファイルが含まれます。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
Chai-1
Chai-1 is an all-atom diffusion co-folder in the same family as Boltz-2 and
AlphaFold3: a multi-entity FASTA in, mmCIF plus pTM/ipTM/pLDDT out, with
protein, RNA, DNA, and SMILES-ligand chains all first-class. It and boltz
cover the same surface; running both and keeping designs that pass either is a
common consensus filter, and Chai's Python entry point makes it the easier of
the two to embed in a loop. Code and weights are Apache-2.0 — commercial use
including drug discovery is explicitly permitted
(github.com/chaidiscovery/chai-lab).
Running it
from pathlib import Path
from chai_lab.chai1 import run_inference
Path("complex.fasta").write_text("""
>protein|name=target
MVTPEGNVSLVDESLLVGVTDEDRAVRS...
>protein|name=binder
AIQRTPKIQVYSRHPAENG...
>ligand|name=cofactor
CCCCCCCCCCCCCC(=O)O
""".strip())
candidates = run_inference(
fasta_file=Path("complex.fasta"),
output_dir=Path("out/"),
num_trunk_recycles=3,
num_diffn_timesteps=200,
seed=42,
device="cuda:0",
use_esm_embeddings=True,
)
print([rd.aggregate_score.item() for rd in candidates.ranking_data])
The FASTA header is >{entity_type}|name={id} with entity_type ∈
{protein, rna, dna, ligand}; ligand records carry a SMILES string as
the sequence body, and modified residues are written inline as
...AAK(SEP)AAG.... From the shell the same job is chai-lab fold complex.fasta out/ --use-msa-server. Without --use-msa-server (or
use_msa_server=True in Python) the model runs on ESM embeddings alone, which
is faster but typically a few ipTM points behind the MSA-backed run.
output_dir receives pred.model_idx_{0..4}.cif plus a matching
scores.model_idx_{N}.npz per sample with aggregate_score, ptm, iptm,
per_chain_ptm, and clash flags. Rank by aggregate_score; treat iptm >
0.5 as a soft pass for an interface. The function refuses a non-empty output_dir, so
clear or rotate it between calls.
Unset CHAI_DOWNLOADS_DIR fails mid-run with PermissionError on a read-only image
Chai downloads ~5 GB on the first inference call (not at install time),
including its own traced ESM2-3B for the embedding path. If
CHAI_DOWNLOADS_DIR is unset, the default is inside site-packages: on a
read-only image that fails with a confusing PermissionError mid-run, and on
a writable one it silently re-downloads ~5 GB into the container on every cold
start. Export the variable to a persisted volume so the download happens once.
No-MSA mode still loads a 3 B-parameter ESM — same VRAM, not less
use_esm_embeddings=True without an MSA still loads a 3-billion-parameter
language model into GPU memory alongside the trunk; it removes the MSA-server
round-trip, not the VRAM cost. If you OOM, drop num_diffn_timesteps or fold
fewer chains per call rather than expecting the no-MSA mode to fit a smaller
card.
Errors worth recognizing
| You see | It means / do this |
|---|---|
PermissionError under site-packages/chai_lab/... |
CHAI_DOWNLOADS_DIR not set on a read-only image — export it to a writable path or the pre-populated mount. |
RuntimeError: CUDA out of memory during ESM embedding |
The traced ESM2-3B is loading alongside the trunk — use an 80 GB tier or split chains across calls. |
Next: filter survivors on confidence/clash metrics or feed them back to
proteinmpnn for the next design round.
よくある質問
ライセンスは何ですか?
コードと重みは Apache 2.0 で、商用利用が認められているとされています。
リガンドを含められますか?
はい。リガンドは FASTA ファイルの中に SMILES 文字列として与えます。
ループで使えますか?
はい。Python の入口がバッチのループで実行しやすいとされています。
詳細
作者による元の説明
Structure prediction for protein, nucleic-acid, and small-molecule complexes with the Chai-1 foundation model (Chai Discovery 2024, github.com/chaidiscovery/chai-lab). Reach for this skill to predict an antibody-antigen or protein-ligand complex from a single FASTA, to re-fold designed binders as an AlphaFold-multimer alternative, or to drive co-folding from Python for batched campaigns on a GPU.
repo: aipoch/open-science
人気
- GitHubのスター
- 5.4k
- ランキング
- #14852
- ライセンス
- Apache-2.0
- 更新日
- 2026/11/2
コメント
- …
このリポジトリの他のスキル
alphafold2
5.4kエージェントが、ColabFold のランナーを使い AlphaFold2 で、アミノ酸配列からタンパク質の立体構造を予測できるよう支援します。タンパク質の複合体にも対応します。
boltz
5.4kエージェントが、オープンソースの Boltz-2 モデルを使い、タンパク質、DNA、RNA、低分子の複合体の構造を予測できるよう支援します。任意で結合親和性の推定も行います。
borzoi
5.4kエージェントが、DNA の配列から発現やアクセシビリティなどのゲノム全体の活性トラックを予測し、予測される効果で変異を比べられるよう支援します。
compute-env-setup
5.4kエージェントが、Open Science の SSH 計算ホストで再利用できるソフトウェア環境を準備し、リモートのジョブが必要なパッケージを読み込めるよう支援します。