dptech-corp/molparser/molparser-visual-ocsr
Claude Code and agent skill by dptech-corp/molparser
- community
Checking that the SKILL.md file is still in the repository.
Use for MolParser visual OCSR workflows that parse molecule images or PDFs into E-SMILES/SMILES with MolDet detection and MolParser recognition models.
Install
npx vskill@latest install dptech-corp/molparser/molparser-visual-ocsrSKILL.md
MolParser Visual OCSR Skill
Use this skill when extracting molecular structures from images, PDFs, URLs, or mixed input lists with molparser.MolParser.
Workflow
- Use
molparser/models/config.yamldefaults or pass a custom YAML path toMolParser. - Prefer
device="auto"unless CPU/GPU must be forced. - For PIL images, image paths, or image URLs:
- Use
rec_only=Truewhen the image is already a single molecule crop. - Use
rec_only=Falsewhen detection is needed; this usesmoldet_v2_yolo11n_640_general.pt.
- For PDF paths or PDF URLs:
rec_onlyis ignored; render pages withpypdfium2atpdf_dpi=300.- Detect molecules with
moldet_v2_yolo11n_960_doc.pt.
- Recognize crops with the MolParser recognition model, then normalize with
postprocess_caption. - Use batch defaults unless memory requires tuning: MolDet batch size is 8, MolParser OCSR batch size is 16.
- Multi-image inputs are batched together; PDF page detections are cropped first, then molecule crops are batched together for recognition.
- Use
moldet.expand_pxfor detector box expansion andmolparser.padding_pxfor recognition input padding; defaults areexpand_px=2andpadding_px=0, and both can be overridden inparse(...).
Minimal Example
For high-throughput molecule crops:
Output Fields
Each result includes source, input_index, page_index, bbox, confidence, raw_caption, caption, smi, esmi, cxsmiles, markush, sru, and groups.
- All parse methods return
list[MolParserResult]. - Single image with
rec_only=True: one whole-image result;bbox,confidence, andpage_indexareNone. - Image with
rec_only=False: one result per detected molecule; no detections returns an empty list. - PDF input: one result per detected molecule on rendered PDF pages;
page_index,bbox, andconfidenceare populated. - List input: flat result list; use
input_indexto map each result back to the original list item.
Use esmi for downstream tasks that need E-SMILES 2.0 annotations, including axial chirality; smi does not preserve every extension. For token definitions, classification flags, and index handling, read `molparser-extended-smiles/SKILL.md`. An <x> record alone does not set markush. sru is reserved for a symbolic whole-molecule repeat count, not local repeats or numeric counts/ranges.
License Notes
MolDetv2 weights are non-commercial according to their model card. The PyTorch detection path uses Ultralytics YOLO; closed-source, private, SaaS, internal business, or commercial usage may require AGPL-3.0 compliance or an Ultralytics Enterprise license.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/molparser-visual-ocsr/SKILL.md
Popularity
- Repository stars
- 32
- Repository forks
- 1
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/dptech-corp/molparser/molparser-visual-ocsr)