The goal of Mol* (/'mol-star/) is to provide a technology stack that serves as a basis for the next-generation data delivery and analysis tools for (not only) macromolecular structure data. Mol* development was jointly initiated by PDBe and RCSB PDB to combine and build on the strengths of LiteMol (developed by PDBe) and NGL (developed by RCSB PDB) viewers.
When using Mol*, please cite:
David Sehnal, Sebastian Bittrich, Mandar Deshpande, Radka Svobodová, Karel Berka, Václav Bazgier, Sameer Velankar, Stephen K Burley, Jaroslav Koča, Alexander S Rose: Mol* Viewer: modern web app for 3D visualization and analysis of large biomolecular structures, Nucleic Acids Research, 2021; https://doi.org/10.1093/nar/gkab314.
-
The pdbe-molstar library is the Mol* implementation used by EMBL-EBI data resources such as PDBe, PDBe-KB and AlphaFold DB. This implementation can be used as a JS plugin and a Web component and supports property/attribute-based easy customisation. It provides helper methods to facilitate programmatic interactions between the web application and the 3D viewer. It also provides a superposition view for overlaying all the observed ligand molecules on representative protein conformations.
-
rcsb-molstar is the Mol* plugin used by RCSB PDB. The project provides additional presets for the visualization of structure alignments and structure motifs such as ligand binding sites. Furthermore, rcsb-molstar allows to interactively add or hide of (parts of) chains, as seen in the 3D Protein Feature View.
The v6 prototype separates code into pnpm workspace packages:
packages/{core,io,model,graphics}own the shared library layers.packages/plugin/{core,ui,headless}own plugin runtime, React UI and Node capture.packages/mvs/{builder,runtime}separate standalone MVS construction from plugin loading.extensions/,apps/,examples/,servers/andcli/own their dependencies and builds.distributions/molstar/assembles the classic and browser ESM distribution.smoke/checks isolated package consumers and browser rendering.
See the workspace guide for package APIs, ESM consumption, versioning, commands and the implementation plan.
This project builds on experience from previous solutions:
- LiteMol Suite
- WebChemistry
- NGL Viewer
- MMTF
- MolQL
- PDB Component Library
- And many others (list will be continuously expanded).
Use Node 22+ and the pnpm version specified in package.json.
pnpm install
pnpm build
pnpm dev # all apps and browser examples
pnpm dev:apps # all apps
pnpm dev:apps -- viewer # selected app
pnpm dev:examples # all browser examples
pnpm dev:examples -- basic-wrapper # selected exampleRun pnpm check:workspace, pnpm test and pnpm --dir smoke smoke to check package boundaries, existing behavior and
packed ESM consumers. The smoke browser requires Chromium. Native GL is opt-in: pnpm native:install installs it
separately, and pnpm test:native runs the native tests. For capture, use
pnpm native:run -- pnpm --dir smoke smoke:headless.
Serve distributions/molstar/ to access build/viewer/ and build/mvs-stories/. Browser ESM entry points are under
build/esm/. Use node scripts/clean.js --all for a clean rebuild. Detailed commands and code ownership are in the
workspace guide.
Code generators are compiled under their owning cli/<name>/lib/ directories. For example:
node cli/cifschema/lib/index.js -mip @molstar/core/data -o packages/io/src/reader/cif/schema/mmcif.ts -p mmCIF
node cli/lipid-params/lib/index.js -o packages/model/src/model/structure/model/types/lipids.ts
node cli/syminfo/lib/index.js
node cli/cif2bcif/lib/index.js input.cif output.bcifTo get syntax highlighting for shader files add the following to Visual Code's settings files and make sure relevant extensions are installed in the editor.
"files.associations": {
"*.glsl.ts": "glsl",
"*.frag.ts": "glsl",
"*.vert.ts": "glsl"
},
npm version prerelease # assumes the current version ends with '-dev.X'
npm publish --tag next
npm version 0.X.0 # provide valid semver string
npm publish
To prepare apps and demos for https://molstar.org deploy, run:
npm run test
npm run deploy:local
To commit these changes remotely to the molstar/molstar.github.io repo:
npm run deploy:remote
Just open an issue or make a pull request. All contributions are welcome.
Funding sources include but are not limited to:
- RCSB PDB funding by a grant [DBI-1338415; PI: SK Burley] from the NSF, the NIH, and the US DoE
- PDBe, EMBL-EBI
- CEITEC
- EntosAI