Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问许可证需确认审计异常

pymolpymol 控制

Agent Skill

pymol 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

917

周安装

39

GitHub Stars

公开资料未说明

下载量

321
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:pymol(pymol 控制)
来源仓库:https://github.com/aminoanalytica/amina-skills
仓库路径:skills/pymol
安装命令:
npx skills add https://github.com/aminoanalytica/amina-skills --skill pymol
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/aminoanalytica/amina-skills --skill pymol

简介

pymol 用于控制 PyMOL 分子可视化软件,支持蛋白质和小分子的渲染与交互。

  • 适合在 Codex、Claude、Cursor、Gemini CLI 中进行结构分析和图像生成任务。
  • 可加载 PDB 文件、设置视图参数、执行光线追踪输出高质量图片。
  • 安装方式:npx skills add https://github.com/aminoanalytica/amina-skills --skill pymol。
  • 需提前安装 PyMOL 并配置 claudemol 套接字连接。

SKILL.md

PyMOL: Molecular Visualization via claudemol

Summary

This skill enables Claude Code to control PyMOL molecular visualization software through the claudemol socket interface. It supports:

  • Setup: Cross-platform installation of claudemol and PyMOL
  • Visualization: Rendering proteins, small molecules, and complexes
  • Publication figures: Ray-traced high-resolution images
  • Interactive control: Send PyMOL commands programmatically

Applicable Scenarios

Task CategoryExamples
SetupInstall PyMOL, configure claudemol, verify connection
Structure LoadingLoad PDB files, fetch from RCSB, open local structures
RepresentationsCartoon, surface, sticks, spheres, ribbons, lines
ColoringColor by chain, spectrum, B-factor, custom colors
SelectionsSelect residues, chains, ligands, binding sites
CameraOrient view, zoom, rotate, save viewpoints
Ray TracingHigh-quality renders, publication figures
ExportSave images (PNG), sessions (PSE), movies

Setup Instructions

Quick Setup (All Platforms)

Run the automated setup script:

python /path/to/skills/pymol/scripts/setup_pymol.py

Manual Setup

1. Install claudemol

pip install claudemol

2. Install PyMOL

macOS (Recommended):

brew install pymol

Windows/Linux (Headless):

pip install pymol-open-source

Windows (Licensed PyMOL): Connect to existing PyMOL installation - see references/troubleshooting.md

3. Configure PyMOL

claudemol setup

This adds the socket plugin to PyMOL's startup.

4. Launch and Verify

  1. Start PyMOL normally
  2. Check that port 9880 is listening: lsof -i:9880 # macOS/Linux netstat -an | findstr 9880 # Windows

Socket Communication

claudemol communicates with PyMOL via a TCP socket on port 9880.

Basic Pattern

import socket
import json

def send_pymol_command(code: str, host: str = 'localhost', port: int = 9880) -> dict:
    """Send a command to PyMOL via claudemol socket."""
    sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    sock.settimeout(30)
    try:
        sock.connect((host, port))
        message = json.dumps({"code": code})
        sock.sendall(message.encode('utf-8'))
        response = sock.recv(65536)
        return json.loads(response.decode('utf-8'))
    finally:
        sock.close()

Multi-Command Example

commands = """
cmd.load('1ubq.pdb')
cmd.show('cartoon')
cmd.color('cyan', 'all')
cmd.orient()
"""
result = send_pymol_command(commands)

Quick Reference

Loading Structures

# From local file
cmd.load('/path/to/structure.pdb')
cmd.load('/path/to/structure.cif')

# From RCSB PDB
cmd.fetch('1ubq')
cmd.fetch('6lu7', type='cif')

Representations

# Show representations
cmd.show('cartoon', 'all')
cmd.show('surface', 'chain A')
cmd.show('sticks', 'resn LIG')
cmd.show('spheres', 'name CA')

# Hide representations
cmd.hide('lines', 'all')
cmd.hide('everything', 'solvent')

Coloring

# Color by chain (automatic colors)
cmd.util.cbc()

# Spectrum coloring (rainbow N to C)
cmd.spectrum('count', 'rainbow', 'all')

# Specific colors
cmd.color('red', 'chain A')
cmd.color('blue', 'resn LIG')
cmd.color('green', 'resi 50-100')

# B-factor coloring
cmd.spectrum('b', 'blue_white_red', 'all')

Selections

# Create named selections
cmd.select('binding_site', 'byres resn LIG around 5')
cmd.select('active_site', 'resi 145+41+166 and chain A')
cmd.select('interface', 'chain A within 4 of chain B')

# Selection algebra
cmd.select('no_water', 'all and not solvent')

View and Camera

# Orient and zoom
cmd.orient()
cmd.zoom('all')
cmd.zoom('chain A', buffer=5)
cmd.center('resn LIG')

# Set specific view
cmd.set_view([...])  # 18-element matrix

# Store and recall views
cmd.view('view1', 'store')
cmd.view('view1', 'recall')

Ray Tracing and Export

# Basic ray trace
cmd.ray(1920, 1080)
cmd.png('/path/to/output.png')

# Publication quality
cmd.set('ray_trace_mode', 1)
cmd.set('ray_shadows', 'on')
cmd.set('antialias', 2)
cmd.ray(2400, 2400)
cmd.png('/path/to/figure.png', dpi=300)

Visualization Workflows

See references/visualization.md for complete workflows:

  • Basic protein visualization
  • Cartoon with chain coloring
  • Surface with transparency
  • Ligand binding site
  • Domain highlighting
  • Publication-quality figures

Command Reference

See references/commands.md for complete command documentation:

  • All cmd.* functions
  • Selection syntax
  • Setting parameters
  • Color palettes

Troubleshooting

See references/troubleshooting.md for platform-specific issues:

  • macOS GLUT errors
  • Windows headless mode
  • Connection refused errors
  • Display problems

Common Issues

IssueResolution
Connection refusedEnsure PyMOL is running with claudemol plugin loaded
Port 9880 in useKill other processes or change port
No GUI (Windows pip)Use headless mode or licensed PyMOL
GLUT missing (macOS)Install via Homebrew instead of pip
Slow ray tracingReduce resolution or simplify scene

External Resources

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

32.26%
按下载量换算104

Claude

32.2%
按下载量换算103

Cursor

17.64%
按下载量换算57

Gemini CLI

9.18%
按下载量换算29

安全审计

Gen Agent Trust Hub

未通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills