twa: The World Avatar Python package for dynamic knowledge graphs and its application in reticular chemistry
The open-source Python package ‘twa’ streamlines knowledge-graph-driven chemical data integration and workflow automation, unifying fragmented data and expanding the OntoMOPs knowledge graph with 799 new MOPs. It is available via ‘pip install twa’. Data-driven discovery is crucial in scientific domains, yet the lack of standardised data management hinders reproducibility. In chemical science, this is exacerbated by fragmented data formats. The World Avatar (TWA) addresses these challenges via a dynamic knowledge graph historically provided in Java-based toolkits. We present twa, an open-source Python package that lowers the barrier to semantic data management. Its object-graph mapper (OGM) synchronises Python class hierarchies with RDF knowledge graphs, streamlining ontology-driven data integration and automated workflows. We demonstrate twa's capacity to unify fragmented chemical data and accelerate research through use cases in molecular design and AI-assisted synthesis protocol extraction for metal–organic polyhedra (MOPs). Our approach expands the existing OntoMOPs knowledge graph by adding 799 new MOPs derived from combinatorial assembly models. By abstracting complex SPARQL queries behind a user-friendly interface, twa fosters transparent, reproducible knowledge-driven discovery. The package is freely available via pip install twa or https://pypi.org/project/twa/.
Publication Details
- Journal
- Apollo (University of Cambridge)
- Published
- 2025-06-30
- DOI
- https://doi.org/10.17863/cam.119519
- Primary Topic
- Amazonian Archaeology and Ethnohistory
- Type
- article
- Field-Weighted Citation Impact
- 0.00