MCP (Model Context Protocol) server exposing smiles2iupac as tools. Lets MCP-aware LLM clients (Claude Desktop, Cursor, Cline, Continue, etc.) call the SMILES to IUPAC name conversion pipeline as tools.
Four well-defined chemistry tools with strong descriptions (150-250 chars each) and complete JSON Schema input parameters. All tools have type definitions and parameter descriptions. Tool names are clear action verbs (smiles_to_iupac, iupac_to_smiles, classify_smiles, enrich_smiles). Output schemas are documented in descriptions but not formally declared in a separate schema field. Error handling guidance is present in descriptions but not structured as recovery patterns. No tool annotations (readOnlyHint, destructiveHint) despite all being read-only operations.
Classify a SMILES without naming it — pre-flight inspection. Useful for routing: tells you whether the input is a single molecule, a salt (and which component is the parent), a mixture, a reaction (which we reject), or polymer notation (also rejected). Pure RDKit, no network. Args: smiles: SMILES string to inspect. Returns: Dict with: kind (molecule|salt|mixture|reaction|polymer|empty), parent_smiles, counterions list, components list, warnings list.
Structural metadata for a SMILES without IUPAC naming. Pure RDKit — no PubChem, no OPSIN, no network calls. Returns InChI, InChIKey (the universal cross-database identifier), Hill-notation molecular formula, average molecular weight, and optionally an SVG. Args: smiles: SMILES string. Salts/mixtures pass through unchanged (this tool doesn't strip counter-ions — use classify_smiles or smiles_to_iupac for that). include_svg: If True, include a 300x300 structure SVG. Returns: Dict with: smiles (input), canonical_smiles, inchi, inchikey, formula, mol_weight, structure_svg (only if requested). Raises: Returns an error dict if SMILES is unparseable.
Reverse lookup — chemical name to canonical SMILES. Tries OPSIN first (rigorous IUPAC parser, no network call, stereo-aware). Falls back to PubChem's name index for common names like "aspirin" or "caffeine" that aren't formal IUPAC. Args: name: Chemical name. IUPAC ("(2S)-2-aminopropanoic acid"), common ("aspirin"), or trivial — both paths are tried. use_pubchem: If False, only OPSIN is used (offline mode). Returns: Dict with: name (echo), smiles (RDKit-canonical) or None, source (opsin|pubchem|none).
No tool annotations (readOnlyHint, destructiveHint, idempotentHint) despite all four tools being read-only, safe operations. Agents cannot infer safety properties without explicit hints.
Output schemas documented only in prose descriptions, not as formal JSON Schema objects. LLMs cannot parse unstructured text to understand return field types and structure.
Error handling returns error dicts but lacks structured recovery guidance. Descriptions mention 'error' field but do not specify error codes, categories (retryable/user-fixable/fatal), or next-step guidance.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | C | 62 | 2026-07-28+ | v2 |
Convert a SMILES chemical structure to its IUPAC name. Args: smiles: SMILES string (e.g. "CCO", "CC(=O)Oc1ccccc1C(=O)O"). Handles salts (strips counter-ions, names the parent), mixtures (names the largest component), and stereochemistry. Reactions (>>) and polymer/wildcard SMILES are rejected with a clear error. include_svg: If True, include a structure SVG render in the result. Off by default (~2KB per call). fetch_synonyms: If True, include common-name synonyms from PubChem. Off by default (extra request per call). Returns: Result dict with: name, confidence (0-1), source (pubchem|cache|none), canonical_smiles, inchi, inchikey, formula, mol_weight, kind (molecule|salt|mixture|...), warnings, trace (step-by-step pipeline reasoning), pubchem_url (one-click verify link), error.
Parameter 'use_pubchem' in iupac_to_smiles defaults to true but lacks explanation of what happens when false (offline mode). Agents may not understand the trade-off.
No pagination or result-limiting parameters despite tools potentially returning large lists (e.g., synonyms in smiles_to_iupac, components in classify_smiles). Could exhaust context window.