BioMed Skill Creator
A meta-skill for creating and improving skills in the OpenBioMed biomedical toolkit.
Overview
This skill guides you through creating biomedical skills with interactive validation. Biomedical workflows require domain-specific validation with real data before finalization.
Workflow:
1. Capture Intent → 2. Design Workflow → 3. Interactive Validation → 4. Finalize → 5. Evaluate
↑ ↓
└──────────────────── Iterate if needed ←─────────────────────┘
Step 1: Capture Intent
Ask clarifying questions:
- What biomedical task should this skill perform?
- What inputs will users provide? (molecule name/SMILES, protein ID, text)
- What outputs should the skill produce? (reports, files, predictions, visualizations)
- Are there edge cases or constraints?
Input Types
| Input Type |
Factory Method |
Example |
| Molecule |
Molecule.from_smiles() |
"CC(=O)OC1=CC=CC=C1C(=O)O" |
| Protein |
Protein.from_fasta() |
"MKFLILLFNILCLFPVLAADNH..." |
| Pocket |
Pocket.from_protein_ref_ligand() |
Protein + reference ligand |
| Text |
Text.from_str() |
"What is this molecule?" |
Step 2: Design Workflow
Identify tools and steps. See references/tools_reference.md for available tools.
Common Workflow Patterns
| Pattern |
Tools Flow |
| Drug-likeness |
molecule_name_request → molecule_qed/sa/logp/lipinski → summarize |
| Protein Mutation |
protein_uniprot_request → mutation_explanation → protein_folding → visualize |
| Structure-Based Design |
protein_pdb_request → extract_molecules → structure_based_drug_design → docking |
| Molecule Q&A |
molecule_name_request → molecule_question_answering → format |
Basic Workflow Code Pattern
from open_biomed.tools.tool_registry import TOOLS
# Get entity
tool = TOOLS["tool_name"]
result, message = tool.run(parameter=value)
entity = result.get("protein") or result.get("molecule")
# Process with other tools
another_tool = TOOLS["another_tool"]
output, msg = another_tool.run(entity=entity)
Step 3: Interactive Validation (CRITICAL)
Execute ONE step at a time and check with user before proceeding.
After designing the workflow, ask:
"Please provide an example input and I'll run through each step showing results."
For Each Step
- Execute the step using OpenBioMed tools
- Display results with standardized format (see
references/validation_template.md)
- Ask for feedback: "Is this result satisfactory? (yes/proceed/modify/skip)"
Handling Errors
When a step fails:
- Explain the error clearly
- Propose alternatives (fallback tools, web search, skip)
- Ask user to decide
After All Steps
Present summary and ask:
"Do you want to:
- Proceed with this workflow?
- Modify and re-validate?
- Try different input?"
Step 4: Finalize the Skill
Once approved, create the skill files:
Directory Structure
skill-name/
├── SKILL.md # Main skill definition (< 200 lines)
├── examples/ # Runnable example scripts
│ └── basic_example.py
└── references/ # Detailed documentation
├── advanced.md
└── troubleshooting.md
SKILL.md Template
See references/skill_template.md for the full structure. Key sections:
---
name: skill-name
description: >
[One-line summary of what the skill does].
Use this skill when:
(1) [Use case 1],
(2) [Use case 2],
(3) [Use case 3].
license: [MIT|Apache-2.0|BSD-3-Clause|GPL-3.0]
category: [category from list below]
tags: [tag1, tag2, tag3]
---
# Skill Title
## When to Use
## Workflow (keep code snippets < 20 lines)
## Expected Outputs
## Error Handling
License Selection
Before finalizing SKILL.md, ask the user to choose a license:
"What license should this skill use?
- MIT (Recommended) - Permissive, allows commercial use
- Apache-2.0 - Permissive with patent grant
- BSD-3-Clause - Permissive, no endorsement clause
- GPL-3.0 - Copyleft, derivatives must be open source"
Default to MIT if user doesn't specify.
Category Options
| Category |
Description |
drug-discovery |
Drug design, molecule generation, lead optimization, virtual screening |
admet-prediction |
Absorption, distribution, metabolism, excretion, toxicity prediction |
protein-engineering |
Protein design, stability optimization, function prediction |
protein-structure |
Structure prediction, folding, conformational analysis |
mutation-analysis |
Mutation effect prediction, variant annotation, engineering |
antibody-design |
Antibody/nanobody design, affinity maturation, epitope prediction |
immunology |
Immunogenicity prediction, vaccine design, immune profiling |
single-cell |
Single-cell analysis, cell annotation, spatial transcriptomics |
genomics |
Gene analysis, variant calling, regulatory element prediction |
transcriptomics |
RNA-seq analysis, expression profiling, differential expression |
metabolomics |
Metabolite identification, pathway analysis, metabolic modeling |
proteomics |
Protein identification, PTM analysis, protein-protein interactions |
pathway-analysis |
Pathway enrichment, network analysis, systems biology |
bioactivity-prediction |
Activity prediction, target identification, bioassay analysis |
binding-affinity |
Docking, binding prediction, protein-ligand interactions |
molecular-dynamics |
MD simulation, conformational sampling, free energy calculation |
chemical-synthesis |
Retrosynthesis, reaction prediction, synthesis planning |
safety-toxicology |
Toxicity prediction, safety assessment, off-target effects |
clinical-translational |
Biomarker discovery, patient stratification, drug repurposing |
bioimaging |
Medical imaging analysis, cell segmentation, image-based profiling |
knowledge-retrieval |
Literature mining, database queries, knowledge graphs |
multi-modal-reasoning |
Cross-modal tasks, text-based molecule/protein tasks, QA |
visualization |
Molecular visualization, structure rendering, report generation |
utilities |
Meta-skills, workflow automation, helper tools, evaluation |
Writing Guidelines
- Keep SKILL.md under 200 lines - Move long code to
examples/ or references/
- Code snippets < 20 lines - Link to full examples
- Include interpretation - What do scores/outputs mean?
- Handle errors - What if tools/APIs fail?
Step 5: Evaluate the Skill
Run evaluation to ensure quality. See references/evaluation_reference.md for details.
- Create 2-3 test cases with realistic prompts
- Run grader - Compare with-skill vs baseline agents
- Analyze results - Identify patterns and issues
- Iterate if needed
Quick Reference
See references/quick_reference.md for:
- Workflow patterns summary
- Input type reference
- Score interpretation tables
- Evaluation checklist
Communication Style
Adapt to user's familiarity:
- Expert: Use technical terms (ADMET, TPSA, RMSD)
- Intermediate: Brief explanations
- Beginner: Analogies, explain why metrics matter
Checklist
Before finalizing:
1---2name: biomed-skill-creator3description: Create new biomedical skills or improve existing ones for the OpenBioMed toolkit. Use this skill when: (1) Creating a new skill from scratch, (2) Capturing a workflow as a reusable skill, (3) Automating a biomedical task, (4) Improving an existing skill. This skill guides through an interactive process: define intent → design workflow → validate with real data → iterate → evaluate.4license: MIT5---67# BioMed Skill Creator89A meta-skill for creating and improving skills in the OpenBioMed biomedical toolkit.1011## Overview1213This skill guides you through creating biomedical skills with **interactive validation**. Biomedical workflows require domain-specific validation with real data before finalization.1415**Workflow:**16```171. Capture Intent → 2. Design Workflow → 3. Interactive Validation → 4. Finalize → 5. Evaluate18 ↑ ↓19 └──────────────────── Iterate if needed ←─────────────────────┘20```2122## Step 1: Capture Intent2324Ask clarifying questions:251. **What biomedical task should this skill perform?**262. **What inputs will users provide?** (molecule name/SMILES, protein ID, text)273. **What outputs should the skill produce?** (reports, files, predictions, visualizations)284. **Are there edge cases or constraints?**2930### Input Types3132| Input Type | Factory Method | Example |33|------------|----------------|---------|34| Molecule | `Molecule.from_smiles()` | `"CC(=O)OC1=CC=CC=C1C(=O)O"` |35| Protein | `Protein.from_fasta()` | `"MKFLILLFNILCLFPVLAADNH..."` |36| Pocket | `Pocket.from_protein_ref_ligand()` | Protein + reference ligand |37| Text | `Text.from_str()` | `"What is this molecule?"` |3839## Step 2: Design Workflow4041Identify tools and steps. See `references/tools_reference.md` for available tools.4243### Common Workflow Patterns4445| Pattern | Tools Flow |46|---------|-----------|47| Drug-likeness | `molecule_name_request` → `molecule_qed/sa/logp/lipinski` → summarize |48| Protein Mutation | `protein_uniprot_request` → `mutation_explanation` → `protein_folding` → visualize |49| Structure-Based Design | `protein_pdb_request` → `extract_molecules` → `structure_based_drug_design` → docking |50| Molecule Q&A | `molecule_name_request` → `molecule_question_answering` → format |5152### Basic Workflow Code Pattern5354```python55from open_biomed.tools.tool_registry import TOOLS5657# Get entity58tool = TOOLS["tool_name"]59result, message = tool.run(parameter=value)60entity = result.get("protein") or result.get("molecule")6162# Process with other tools63another_tool = TOOLS["another_tool"]64output, msg = another_tool.run(entity=entity)65```6667## Step 3: Interactive Validation (CRITICAL)6869**Execute ONE step at a time and check with user before proceeding.**7071After designing the workflow, ask:72> "Please provide an example input and I'll run through each step showing results."7374### For Each Step75761. **Execute** the step using OpenBioMed tools772. **Display results** with standardized format (see `references/validation_template.md`)783. **Ask for feedback**: "Is this result satisfactory? (yes/proceed/modify/skip)"7980### Handling Errors8182When a step fails:831. Explain the error clearly842. Propose alternatives (fallback tools, web search, skip)853. Ask user to decide8687### After All Steps8889Present summary and ask:90> "Do you want to:91> 1. **Proceed** with this workflow?92> 2. **Modify** and re-validate?93> 3. **Try different input**?"9495## Step 4: Finalize the Skill9697Once approved, create the skill files:9899### Directory Structure100101```102skill-name/103├── SKILL.md # Main skill definition (< 200 lines)104├── examples/ # Runnable example scripts105│ └── basic_example.py106└── references/ # Detailed documentation107 ├── advanced.md108 └── troubleshooting.md109```110111### SKILL.md Template112113See `references/skill_template.md` for the full structure. Key sections:114115```markdown116---117name: skill-name118description: >119 [One-line summary of what the skill does].120 Use this skill when:121 (1) [Use case 1],122 (2) [Use case 2],123 (3) [Use case 3].124license: [MIT|Apache-2.0|BSD-3-Clause|GPL-3.0]125category: [category from list below]126tags: [tag1, tag2, tag3]127---128129# Skill Title130131## When to Use132## Workflow (keep code snippets < 20 lines)133## Expected Outputs134## Error Handling135```136137### License Selection138139Before finalizing SKILL.md, ask the user to choose a license:140141> "What license should this skill use?142> 1. **MIT** (Recommended) - Permissive, allows commercial use143> 2. **Apache-2.0** - Permissive with patent grant144> 3. **BSD-3-Clause** - Permissive, no endorsement clause145> 4. **GPL-3.0** - Copyleft, derivatives must be open source"146147Default to **MIT** if user doesn't specify.148149### Category Options150151| Category | Description |152|----------|-------------|153| `drug-discovery` | Drug design, molecule generation, lead optimization, virtual screening |154| `admet-prediction` | Absorption, distribution, metabolism, excretion, toxicity prediction |155| `protein-engineering` | Protein design, stability optimization, function prediction |156| `protein-structure` | Structure prediction, folding, conformational analysis |157| `mutation-analysis` | Mutation effect prediction, variant annotation, engineering |158| `antibody-design` | Antibody/nanobody design, affinity maturation, epitope prediction |159| `immunology` | Immunogenicity prediction, vaccine design, immune profiling |160| `single-cell` | Single-cell analysis, cell annotation, spatial transcriptomics |161| `genomics` | Gene analysis, variant calling, regulatory element prediction |162| `transcriptomics` | RNA-seq analysis, expression profiling, differential expression |163| `metabolomics` | Metabolite identification, pathway analysis, metabolic modeling |164| `proteomics` | Protein identification, PTM analysis, protein-protein interactions |165| `pathway-analysis` | Pathway enrichment, network analysis, systems biology |166| `bioactivity-prediction` | Activity prediction, target identification, bioassay analysis |167| `binding-affinity` | Docking, binding prediction, protein-ligand interactions |168| `molecular-dynamics` | MD simulation, conformational sampling, free energy calculation |169| `chemical-synthesis` | Retrosynthesis, reaction prediction, synthesis planning |170| `safety-toxicology` | Toxicity prediction, safety assessment, off-target effects |171| `clinical-translational` | Biomarker discovery, patient stratification, drug repurposing |172| `bioimaging` | Medical imaging analysis, cell segmentation, image-based profiling |173| `knowledge-retrieval` | Literature mining, database queries, knowledge graphs |174| `multi-modal-reasoning` | Cross-modal tasks, text-based molecule/protein tasks, QA |175| `visualization` | Molecular visualization, structure rendering, report generation |176| `utilities` | Meta-skills, workflow automation, helper tools, evaluation |177178### Writing Guidelines1791801. **Keep SKILL.md under 200 lines** - Move long code to `examples/` or `references/`1812. **Code snippets < 20 lines** - Link to full examples1823. **Include interpretation** - What do scores/outputs mean?1834. **Handle errors** - What if tools/APIs fail?184185## Step 5: Evaluate the Skill186187Run evaluation to ensure quality. See `references/evaluation_reference.md` for details.1881891. **Create 2-3 test cases** with realistic prompts1902. **Run grader** - Compare with-skill vs baseline agents1913. **Analyze results** - Identify patterns and issues1924. **Iterate** if needed193194## Quick Reference195196See `references/quick_reference.md` for:197- Workflow patterns summary198- Input type reference199- Score interpretation tables200- Evaluation checklist201202## Communication Style203204Adapt to user's familiarity:205- **Expert**: Use technical terms (ADMET, TPSA, RMSD)206- **Intermediate**: Brief explanations207- **Beginner**: Analogies, explain why metrics matter208209## Checklist210211Before finalizing:212- [ ] Workflow validated with real input213- [ ] User approved the workflow214- [ ] SKILL.md under 200 lines215- [ ] Long code in examples/216- [ ] Error handling documented217- [ ] Test cases created and graded