input-data-formats
Author, validate, and debug Chai FASTA input records for proteins, ligands, DNA, RNA, modified residues, entity names, and chain naming.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- input-data-formats
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Author, validate, and debug Chai FASTA input records for proteins, ligands, DNA, RNA, modified residues, entity names, and chain naming.
- disable-model-invocation
- true
02 资源文件 4
- 参考文档references/api-reference.md6.2 KB
- 参考文档references/fasta-and-entities.md6.7 KB
- 参考文档references/troubleshooting.md5.4 KB
- 脚本scripts/validate_chai_fasta.py7.5 KB
03 SKILL.md 正文
Input Data Formats
Use this sub-skill when an agent needs to create or repair Chai input FASTA records before folding. It covers entity headers, sequences, ligand SMILES, modified residues, entity names, and the chain-name consequences of fasta_names_as_cif_chains / entity_name_as_subchain.
Route First
- Need to run
chai-lab foldorchai_lab.chai1.run_inferenceafter the FASTA is valid? Use../cli-inference/SKILL.md. - Need
.aligned.pqt, A3M conversion, MSA server, or template hit files? Use../msa-templates/SKILL.md. - Need contact/pocket/covalent restraint CSVs or glycan bond details? Use
../restraints-glycans/SKILL.md. - Need only basic
glycan|nameFASTA routing? This sub-skill covers the header; glycan string semantics belong to../restraints-glycans/SKILL.md.
Fast Authoring Rules
- Write one FASTA record per Chai entity:
>protein|name,>protein|name=receptor,>ligand|name=atp,>dna|name=primer,>rna|name=guide, or>glycan|name=n_linked. - Always provide an entity name; Chai rejects headers without a label and inference requires names to be unique.
- Use explicit entity types instead of relying on sequence heuristics; short
A/C/G/Trecords are ambiguous across DNA, RNA, and protein. - Encode modified polymer residues as bracketed multi-character residue names, such as
AAA(SEP)AAAor(MSE)G, not as unbracketed three-letter text. - Encode ligands as SMILES strings; use bracketed ions such as
[Mg+2]or[Zn+2], because bare ion text can pass header parsing but fail ligand tokenization. - Preserve entity order intentionally: automatic chain IDs are assigned from the accepted chain order, while
fasta_names_as_cif_chains=Trueuses entity names as parsing/output chain IDs.
Validate Before Folding
Run the bundled helper before expensive inference:
python scripts/validate_chai_fasta.py input.fasta
python scripts/validate_chai_fasta.py --tokenize --entity-names-as-subchains input.fasta
The first command checks Chai header parsing, required names, duplicate names, type heuristics, and polymer modified-residue syntax. The optional tokenization check catches malformed SMILES and chain-name issues that only appear when Chai builds chains.
References
references/fasta-and-entities.md— format grammar, entity tables, naming rules, and chain-name implications.references/api-reference.md— validation and parsing APIs useful for scripts and diagnostics.references/troubleshooting.md— common parser, sequence, ligand, duplicate-name, and chain-name failures.
04 同仓库更多 Skills
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.
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.
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.
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.
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.
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).