Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -147,3 +147,5 @@ testSQL.py
/static/
/templates/
.idea/
/sboannotator.dmg
/src/ml_sbo/models/stage1_80_stage2_10/pytorch_model.bin
93 changes: 41 additions & 52 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,75 +11,64 @@
[![PyPI downloads](https://img.shields.io/pypi/dm/SBOannotator.svg)](https://pypistats.org/packages/SBOannotator)
[![DOI](https://img.shields.io/badge/DOI-10.1093%2Fbioinformatics%2Fbtad437-blue.svg?style=plastic)](https://doi.org/10.1093/bioinformatics/btad437)

Developers : [Nantia Leonidou](https://github.com/NantiaL) & Elisabeth Fritze
Developers : [Nantia Leonidou](https://github.com/NantiaL) & Elisabeth Fritze& Jiahui Hu
___________________________________________________________________________________________________________

### How to cite the SBOannotator?

The SBOannotator is described in this article: https://doi.org/10.1093/bioinformatics/btad437

### Overview
SBOannotator is the first standalone tool that automatically assigns SBO terms to multiple entities of a given SBML model.
The main focus lies on the reactions, as the correct assignment of precise SBO annotations requires their extensive classification.
Our implementation does not consider only top-level terms but examines the functionality of the underlying enzymes to
allocate precise and highly specific ontology terms to biochemical reactions.
Transport reactions are examined separately and are classified based on the mechanism of molecule transport.
Pseudo-reactions that serve modeling purposes are given reasonable terms to distinguish between biomass production and the
import or export of metabolites. Finally, other model entities, such as metabolites and genes, are annotated with appropriate terms.
Including SBO annotations in the models will enhance the reproducibility, usability, and analysis of biochemical networks.
This project transforms SBOannotator from a static, hard-coded tool into a dynamic, intelligent system for annotating Systems Biology Ontology (SBO) terms in SBML models. The enhanced system integrates real-time SBO term retrieval, multiple enzymology data sources, and LLM-assisted annotation—significantly improving accuracy and usability while preserving the core rule-based strengths. A standalone desktop GUI with interactive visualization makes powerful annotation capabilities accessible to a broader community of systems biology researchers.
The system delivers three key innovations:
- Automated GitHub integration for real-time SBO file updates;
- A three-layer rule-based annotation workflow based on 4 database(bigg, kegg, reactome, seed);
- A finetuned LLM achieving 94% accuracy to predict SBO terms within 42 candidates for EC number .

### Web Application
Web application hosted at [TueVis](https://tuevis.cs.uni-tuebingen.de/sboannotator/) is accessible and ready to use at [sbo-annotator-tuevis.cs.uni-tuebingen.de/](https://sbo-annotator-tuevis.cs.uni-tuebingen.de/)
### Input data
+ an SBML document
+ a sbo terms (.json or obo)(optional)

### Installation
```
pip install SBOannotator
```

### Prerequisites
### Outputs
+ Rule Based Enhanced Annotated libSBML model
+ LLM Annototed libSBML model
+ Uptodate SBO terms (.json)

### Usage with terminal
This tool has the following dependencies:

python >=3.8.5
**Python** >= 3.9.6

Packages:
* sqlite3
* libsbml
* collections
* requests
* json
* time
**Packages:**
- sqlite3
- libsbml
- collections
- requests
- json
- time

### Input data
+ `doc`: an SBML document
+ `model_libsbml`: SBML model of interest
+ `modelType`: type of modelling framework (see below)
+ `database_name`: name of imported database, without extension
+ `new_filename`: file name for output model

Types of modelling framework accepted:
- constraint-based
- logical
- continuous
- discrete
- hybrid
- logical
**Trained Model (423MB):**
- Download pretrained model: https://drive.google.com/file/d/1Kypb5YmLKUbFY9tZuzk0p1Mn_FWaD0g_/view?usp=drive_link
- Place the downloaded file at: `src/ml_sbo/models/stage1_80_stage2_10/pytorch_model.bin`

### Outputs
+ `model_libsbml`: Annotated libSBML model
**Run**
- `pip install -r requirements.txt`
- `python main.py` in the command line within the project folder. If ERROR occurs, check the current version of Python:

- `python --version`
- `conda install python>=3.9.6`

### Usage
To run SBOannotator use the `__main__.py` script and modify the parameters in the `readSBML` and `sbo_annotator`
functions as wished.

Alternatively run `python __main__.py` in the command line within the project folder.
### Desktop App

If ERROR occurs, check the current version of Python:
1. macOS: Download the DMG
https://drive.google.com/file/d/1Ltm2nsFXpuVh7wgmQAY9Jg67EPJEooHW/view?usp=drive_link

- `python --version'`
- `conda install python>=3.8.5`
2. Open the `.dmg`, then drag the app into **Applications**.
3. First launch: if Gatekeeper blocks the app, remove the quarantine attribute in Terminal:
```bash
sudo xattr -r -d com.apple.quarantine "/Applications/main.app"

### Exemplary models and results
The folder `models/BiGG_Models` contains all the tested models as they were downloaded from
The folder `models/Customer_Models` contains a models as it were downloaded from
the BiGG database.
The annotated models after using the SBOannotator are listed in the folder named `models/Annotated_Models`.
The annotated models after using the Rule based SBOannotator and target reaction filtered for llm are listed in the folder named `models/Enhanced_Annotated_Models`.
The annotated models after using the LLM recommendationi are listed in the models/LLM_Annotated_Models
Loading