Skip to content
Preview.smi@modelscript/smiles 10 diagnostic rules
Parser WASM GLR
Diagnostics 10 rules
DAE Arena Lowering
Simulation Co-sim / Export
Projections SBML, OWL2
Live ExampleAnalgesicLibrary.smi

OpenSMILES Molecular Library & Lipinski Profile

Canonical OpenSMILES chemical structure table with aromaticity, stereochemistry, and molecular property checks.

Playground
Source (4 lines)
1CC(=O)Oc1ccccc1C(=O)O	Aspirin
2CC(=O)Nc1ccc(O)cc1	Paracetamol
3CC(C)Cc1ccc(cc1)[C@@H](C)C(=O)O	Dexibuprofen
4CN1C=NC2=C1C(=O)N(C(=O)N2C)C	Caffeine
SMILES Molecular Graph & Valence Topology
parse graph descriptors «chemical graph» OpenSMILES «parameters» CC(=O)Oc1ccccc1C(=O)O Aspirin (MW = 180.16) «huckel 4n+2» Valence & Rings «model» ring = 6-membered chiral = R/S verified «admet profile» Lipinski Ro5 «verification» LogP = 1.19 HBD = 1, HBA = 4
Drag to pan · Click % to reset

SMILES & MDL Molfile Molecular Graphs (.smi, .smarts, .mol, .sdf) ​

@modelscript/smiles (languages/smiles) provides zero-regex native WebAssembly GLR parsing, organic valence and Hückel 4n+2 aromaticity verification, Joback & Reid (1987) group-contribution thermodynamic and critical property estimation, DAEBuilder lowering, and Aspen Plus / Modelica projections for OpenSMILES, SMARTS, and MDL Molfile V2000 / Structure-Data File (.sdf) molecular specifications.


Supported Extensions & Standards ​

ExtensionFormatDescription
.smi, .smilesOpenSMILESLine notation encoding molecular graphs, ring closures, branches, stereochemistry (@/@@), and aromatic atoms
.smartsSMARTSSubstructure query patterns for functional-group matching
.mol, .sdfMDL V2000 / SDF2D/3D atomic coordinate tables, bond orders, and associated structure-data property tags (> <Property>)

Key Capabilities ​

1. Molecular Graph Topology & Valence Verification ​

  • Constructs typed molecular graphs with implicit/explicit hydrogen counting, ring-closure matching (including %nn two-digit rings), disconnected salts/mixtures (.), formal charges, isotopes, and Kekulé/aromatic conjugation.

2. Joback & Reid Group-Contribution Property Estimator ​

  • Automatically decomposes molecular graphs into functional groups (-CH3, -CH2-, >C=O, -OH, -COOH, -NH2, aromatic ring carbons, halogens) to estimate pure-component physical properties:
    • Normal boiling point Tb and freezing point Tm (K)
    • Critical temperature Tc (K), critical pressure Pc (bar), and critical molar volume Vc (cm3/mol)
    • Standard enthalpy of formation ΔHf∘ and Gibbs energy of formation ΔGf∘ (kJ/mol)
    • Ideal-gas heat capacity polynomial Cp∘(T)=A+BT+CT2+DT3 and Lee-Kesler acentric factor ω.

3. Aspen Plus, Modelica & DAE Lowering ​

  • Projects estimated critical and thermochemical parameters directly into Aspen Plus pure-component property cards (smilesToAspen), Modelica media records (smilesToModelica), and @modelscript/runtime's DAEBuilder.

Pre-Flight Diagnostics ​

10 rules9 error1 warning

CodeRuleSeverityMessage
M9301unclosed-ring-digiterrorRing closure digit '<ringId>' in '<moleculeName>' has no matching closing bond.
M9302unbalanced-branch-parenthesiserrorBranch parenthesis in '<moleculeName>' is unbalanced.
M9303valence-exceedederrorAtom '<element>' (index '<atomIndex>') in '<moleculeName>' has bond order sum '<actualValence>' exceeding maximum allowed valence '<maxValence>'.
M9304invalid-aromatic-kekule-ringerrorAromatic ring in '<moleculeName>' violates Hückel's 4n+2 pi-electron rule or cannot be Kekulized.
M9305unknown-chemical-elementerrorAtomic symbol '<symbol>' in '<moleculeName>' is not a valid IUPAC element.
M9306conflicting-ring-bond-ordererrorRing closure '<ringId>' in '<moleculeName>' specifies conflicting bond orders at opening and closing atoms.
M9307self-loop-bonderrorBond in '<moleculeName>' connects atom '<atomIndex>' to itself.
M9308duplicate-atom-bonderrorMultiple bonds declared between identical atom pair ('<atomA>', '<atomB>') in '<moleculeName>'.
M9309invalid-tetrahedral-chiralitywarningChiral center '<atomIndex>' in '<moleculeName>' has fewer than 4 distinct substituents.
M9310empty-molecular-grapherrorMolecule entry '<moleculeName>' contains zero atoms.

Generated from languages/smiles/src/errors.ts. All languages →


CLI Usage ​

bash
# Validate ring closures, atomic valences, and Hückel aromaticity
msx lint DrugLibrary.smi

# Parse SMILES or SDF molecular structure files
msx parse Aspirin.smi

Open-Core under the GNU AGPL v3 License; Enterprise Edition (ee/) under the ModelScript Enterprise License. • Pricing • Trademark Policy