pymol
Skill0 starsChanged 26 days agoApache-2.0View on GitHub
Visualize, analyze, and render protein and molecular structures using PyMOL. Use when the user wants to create images of protein structures, perform structural alignments or superposition, measure distances or contacts, highlight binding sites or active site residues, color by B-factor/pLDDT, or analyze protein-ligand interactions. Do not use for docking, molecular dynamics, or sequence-only analysis.
3 other projects use a version of this, 2 of them edited.
Adopted by
Most recently taken up by
- 1stANUNNAKI/majlisedited, first seen Nov 8, 2026
- google-deepmind/science-skillsword for word, first seen Jul 1, 2026
- uppifyagency/boilerplate-saas-2026edited, first seen Jun 2, 2026
Other versions3 projects use a version of this.
Word for word · 1
- google-deepmind/science-skills★ 3.4k100% same
Edited · 2
- 1stANUNNAKI/majlis★ 295% same
- uppifyagency/boilerplate-saas-2026★ 198% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository40 other files it gives its agents.
- vector-geneSkill
- alphafold-database-fetch-and-analyzeSkill
- alphagenome-atlas-website-linksSkill
- alphagenome-single-variant-analysisSkill
- alphagenome-variant-impact-scoreSkill
- chembl-databaseSkill
- clinical-trials-databaseSkill
- clinvar-databaseSkill
- credentialsSkill
- dbsnp-databaseSkill
- embl-ebi-olsSkill
- encode-ccres-databaseSkill
- ensembl-databaseSkill
- foldseek-structural-searchSkill
- gnomad-databaseSkill
- gtex-databaseSkill
- human-protein-atlas-databaseSkill
- interpro-databaseSkill
- jaspar-databaseSkill
- literature-search-arxivSkill
- literature-search-biorxivSkill
- literature-search-europepmcSkill
- literature-search-openalexSkill
- ncbi-sequence-fetchSkill
- openfda-databaseSkill
- opentargets-databaseSkill
- pdb-databaseSkill
- predictingthepastSkill
- protein-sequence-msaSkill
- protein-sequence-similarity-searchSkill
- pubchem-databaseSkill
- pubmed-databaseSkill
- quickgo-databaseSkill
- reactome-databaseSkill
- string-databaseSkill
- ucsc-conservation-and-tfbsSkill
- unibind-databaseSkill
- uniprot-databaseSkill
- uvSkill
- workflow-skill-creatorSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 4 are distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 16
uv: Read the uv skill and follow its Setup instructions to ensure uv is installed and on PATH. - Very specific: line 18
User Notification: If .licenses/pymol_LICENSE.txt does not already exist in the workspace root directory then (1) prominently notify the …
- Very specific: line 25
All PyMOL commands run on the host via uv with OSMesa software rendering — no GPU, display, or X server is needed.
- Very specific: line 39
Ensure that uv is installed on the host system.
- Distinctive: line 46
Always run PyMOL scripts from the user's project directory.
- Very specific: line 47
Software rendering only: Use cmd.png() for output. Never use cmd.draw() or cmd.ray() with hardware acceleration — OSMesa does not support …
- Very specific: line 55
Init boilerplate is mandatory: Every PyMOL script must begin with the initialization sequence.
- Distinctive: line 60
Pre-Flight File Check: Before writing the PyMOL script or running it, you MUST verify that the requested structure file actually exists on …
- Very specific: line 63
Verify Structure Load: After loading a structure with cmd.load(), always verify it succeeded by checking cmd.count_atoms("all").
- Distinctive: line 70
Notification: If this skill is used, ensure this is mentioned in the output.
- Distinctive: line 75
Ensure structure files are downloaded to a directory in the user's project.
- Very specific: line 76
Write a PyMOL Python script (e.g., render.py) with the required init boilerplate and PEP 0723 header.
- Very specific: line 78
Run it via uv run: bash uv run render.py
- Very specific: line 149
If the user wants modifications, load the saved .pse in a new script and re-run.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
PyMOL
Prerequisites
uv: Read theuvskill and follow its Setup instructions to ensureuvis installed and on PATH.- User Notification: If .licenses/pymol_LICENSE.txt does not already exist in the workspace root directory then (1) prominently notify the user to check the license at https://www.pymol.org/, then (2) create the file recording the notification text and timestamp.
Overview
All PyMOL commands run on the host via uv with OSMesa software rendering — no
GPU, display, or X server is needed. Structure files must be downloaded to the
host before running PyMOL.
Do NOT use when:
- The user wants to run AlphaFold predictions.
- The user wants docking or molecular dynamics simulations.
- The user only has a sequence and no structure file — fetch the structure first. Check if any other installed skills can retrieve structures from the PDB or AlphaFold Database before proceeding.
Setup (Agent Instructions)
Ensure that uv is installed on the host system. The PyMOL scripts use PEP 0723
headers to declare their dependencies, and uv run will automatically handle
installing them (including pymol-open-source-whl) when the script is executed.
Core Rules
- Output paths must be absolute or relative to the user's project root. Always run PyMOL scripts from the user's project directory.
- Software rendering only. Use
cmd.png()for output. Never usecmd.draw()orcmd.ray()with hardware acceleration — OSMesa does not support it. Set environment variablePYOPENGL_PLATFORM=osmesafor headless rendering. - Always save a
.psesession file alongside any PNG output. This lets the user open the session in their local PyMOL for further inspection. - Always call
cmd.quit()at the end of every PyMOL script. Omitting it causes the process to stop responding. - Init boilerplate is mandatory. Every PyMOL script must begin with the
initialization sequence.
from pymol import cmdmust come afterfinish_launching(), not before. - See references/PYMOL_REFERENCE.md for selection syntax, common commands, and gotchas.
- Pre-Flight File Check: Before writing the PyMOL script or running it, you MUST verify that the requested structure file actually exists on the host machine.
- Verify Structure Load: After loading a structure with
cmd.load(), always verify it succeeded by checkingcmd.count_atoms("all"). If the result is 0, print an error to stdout and callcmd.quit()immediately. - Auto-detect Alpha-Carbon Trace: For a cartoon representation your
PyMOL scripts should automatically detect if the structure is an
alpha-carbon trace (
cmd.count_atoms("name CA") == cmd.count_atoms("all")), then you MUST follow the Alpha carbon trace cartoon recipe. - Notification: If this skill is used, ensure this is mentioned in the output.
Quick Start
- Ensure structure files are downloaded to a directory in the user's project.
- Write a PyMOL Python script (e.g.,
render.py) with the required init boilerplate and PEP 0723 header. - Run it via
uv run:bash uv run render.py
Minimal example script (render.py)
# /// script
# requires-python = ">=3.10, <3.13"
# dependencies = [
# "pymol-open-source-whl",
# ]
# ///
import os
import sys
# Set environment variable for headless rendering
os.environ["PYOPENGL_PLATFORM"] = "osmesa"
import pymol # pytype: disable=import-error
pymol.pymol_argv = ["pymol", "-cq"]
pymol.finish_launching()
from pymol import cmd # pytype: disable=import-error
cmd.load("AF-P00520-F1-model_v4.cif", "structure")
cmd.show("cartoon")
cmd.color("green", "ss h")
cmd.color("yellow", "ss s")
cmd.color("gray", "ss l+''")
cmd.orient()
cmd.set("ray_opaque_background", 1)
cmd.png("output/render.png", width=1200, height=900, dpi=150)
cmd.save("output/session.pse")
cmd.quit()Common Recipes
See references/RECIPES.md for complete, copy-paste ready recipes. Available recipes:
- Cartoon with secondary structure coloring — basic helix/sheet/loop coloring
- Alpha carbon trace cartoon — force cartoon representation for CA-only structures
- B-factor (pLDDT) coloring — continuous spectrum coloring by B-factor
- AlphaFold pLDDT coloring — canonical threshold-based confidence colors
- Highlight specific residues — show active site or key residues as sticks
- Surface rendering — transparent surface over cartoon
- Electrostatic surface rendering — vacuum electrostatics (qualitative)
- Multi-chain complex colors — automatic per-chain coloring
- B-factor putty analysis — tube width proportional to flexibility
- Cavity and pocket visualization — surface cavity detection with ligand focus
- Multi-structure batch rendering — render a directory of structures
- Measure distance between residues — CA–CA distance with labels
- Zoom into binding pocket — simple pocket focus
- Protein-ligand interaction — ligand isolation, styled rendering, polar contacts
- Two-structure superposition with RMSD — align/cealign with auto-fallback
- In silico mutagenesis — mutate residues with the mutagenesis wizard
- Load and modify an existing session — re-open a
.psefile
Interpreting Output
- The
output/directory contains PNG images and a.psesession file. - Any measurements or metrics (distances, RMSD, atom counts) are printed to stdout by the PyMOL script. Report these values to the user.
- Present PNG images to the user and describe the visualization.
- Tell the user they can open the
.psefile in their local PyMOL to further explore, rotate, or modify the visualization. - If the user wants modifications, load the saved
.psein a new script and re-run. - Large sessions with surfaces can exceed the
--max_output_mblimit (default 500 MB). Increase it with--max_output_mb=1000if needed.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

