AGENT SKILL

inverse-folding

Use ESM-IF1 for fixed-backbone protein inverse design, sequence log-likelihood scoring, multichain conditioning, coordinate extraction, and structure encoder representations.

License 许可
MIT
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
inverse-folding
license
MIT
metadata
{ "disco-role": "operating" }
description
Use ESM-IF1 for fixed-backbone protein inverse design, sequence log-likelihood scoring, multichain conditioning, coordinate extraction, and structure encoder representations.
disable-model-invocation
true

02 资源文件 5

03 SKILL.md 正文

Inverse Folding

Use this sub-skill when a task needs ESM-IF1 to design or score protein sequences from known backbone coordinates. It covers fixed-backbone sequence sampling, single-chain and multichain complex conditioning, PDB/mmCIF coordinate extraction, missing-coordinate handling, conditional log-likelihood scoring, and encoder representations.

When To Use

  • Sample candidate amino-acid sequences for a PDB or mmCIF backbone with esm.pretrained.esm_if1_gvp4_t16_142M_UR50() and model.sample(...).
  • Score one or more sequences against a structure with score_sequence(...) or score_sequence_in_complex(...).
  • Condition target-chain design on all chains in a complex with --multichain-backbone or multichain_util APIs.
  • Extract N/CA/C backbone coordinates and native sequences from PDB/mmCIF files.
  • Obtain structure-conditioned encoder representations from ESM-IF1.

Route Elsewhere

  • Use the sibling structure-prediction sub-skill for ESMFold forward folding from sequence to structure.
  • Use the sibling model-embeddings sub-skill for generic protein language-model embeddings that do not use backbone coordinates.
  • Use the sibling variant-effect-prediction sub-skill for mutation scoring without a structure-conditioned inverse-folding model.

Start Here

  1. Confirm the environment has PyTorch plus inverse-folding optional dependencies, especially torch-geometric and a compatible biotite API.
  2. Validate the structure suffix is .pdb or .cif, choose the target chain ID, and decide whether to condition on only the target chain or the whole complex.
  3. For CLI-style work, use the bundled dry-run helper in scripts/inverse_folding_cli_helper.py to construct safe commands before running downloads or GPU jobs.
  4. For API work, load model, alphabet = esm.pretrained.esm_if1_gvp4_t16_142M_UR50() and call model.eval() before sampling or scoring.
  5. Inspect sampled FASTA output for long amino-acid repeats and inspect scoring CSV output for sequence length mismatches or missing-coordinate effects.

References

  • references/workflows.md gives task recipes for sampling, scoring, multichain conditioning, encoder outputs, and diagnostic workflows.
  • references/api-reference.md lists the supported ESM-IF1 loader and inverse-folding APIs.
  • references/data-formats.md describes coordinate tensors, PDB/mmCIF requirements, FASTA input/output, CSV scoring output, and missing-coordinate conventions.
  • references/troubleshooting.md maps common dependency, data, runtime, and biological-quality failures to fixes.

Bundled Helper

Use scripts/inverse_folding_cli_helper.py for self-contained command construction and input validation:

python scripts/inverse_folding_cli_helper.py sample structure.pdb --chain C --outpath designs.fasta
python scripts/inverse_folding_cli_helper.py score structure.pdb variants.fasta --chain C --outpath scores.csv --multichain-backbone

The helper prints a dry-run command by default. Add --execute only when the environment is ready for model loading, potential torch hub downloads, and a long CPU/GPU run.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351