Skip to content

About

An Improved Predictive Metagenomic Pipeline for Antimicrobial Resistance in Klebsiella pneumoniae using Machine Learning

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

114 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Project Logo

Bash R Version Conda Python License: MIT

Docker Automated build Platform


PredKlebAMR_v2: A Hybrid Decentralized Metagenomic Framework for Same-Day Prediction of Meropenem-resistant Klebsiella pneumoniae in Lower Respiratory Tract Infections


📋 Table of Content

🎀 Overview

PredKlebAMR_v2 is an end-to-end diagnostic pipeline that pairs an Edge Node (a local edge-computing pipeline) with a Cloud Node (a cloud-hosted machine learning (ML) framework). The Cloud Node has previously been developed as PredKlebAMR-v1.

💢 Key Features:

  • Input: Raw sputum/saliva metagenomic reads directly from an Oxford Nanopore sequencer.
  • Output: High-accuracy phenotypic predictions of meropenem-resistance in Klebsiella pneumoniae genomes.
  • Execution Time: Fully optimized to complete execution within an 1-to-2 hour runtime window.

🔄 Workflow

workflow

🛠️ Pipeline Architecture

The Edge Node standardizes five (5) sequential computational phases locally on your hardware:

  1. Quality Control: Filters low-accuracy or short reads via chopper.
  2. Host Depletion: Minimizes host background by aligning and stripping human DNA reads with minimap2 and samtools.
  3. Adaptive Sub-Sampling: Normalizes sequencing depth to the validated Limit of Detection (LoD) using seqtk.
  4. Taxonomic Extraction: Isolates target pathogen reads (Klebsiella pneumoniae, TaxID 573) using Kraken2.
  5. Pathogen Assembly: Assembles high-fidelity contigs locally via Raven without exposing raw patient data.

💻 System Requirements

  • RAM: Minimum 16 GB recommended.
  • Disk Space: At least 15 GB of free drive space.
  • OS: Linux (Ubuntu recommended), macOS, or Windows (via WSL2).
  • Software: Docker Desktop (must be running prior to starting the application).
  • Browser: Modern browser (Chrome, Firefox, or Edge). For WSL2 users, wslu is recommended for automatic browser launching.

👨🏽‍💻Pipeline Usage

PredKlebAMR-v2 offers users two (2) options:

  1. An Application (Interactive Dashboard), where users simply click and upload their metagenomic files (raw fastq).
  2. A Command-line interface, where users can run the pipeline locally on their PCs via the master (bash) script.

⚙️Installation & Setup for the Application

  1. Install Docker Desktop: Download and install Docker Desktop for your operating system:
  2. Start Docker Desktop and wait until the status indicator in the bottom corner turns green (Engine running).
  3. Download PredKlebAMR-v2: Clone or download this repository to your local computer:
    git clone https://github.com/omicscodeathon/predklebamr2.git
    cd PredKlebAMR/PredKlebAMR-v2_pipeline_(Docker)
    
    

🚀Quick Start Launch Guides

Choose the launch method suited to your environment:

Option A: Windows (One-Click)

  1. Ensure Docker Desktop is active.
  2. Double-click launch_predklebamr.bat.
  3. Open Docker Desktop, navigate to Containers, and click the blue port link (8080:3838) next to predklebamr_app.

Option B: macOS (One-Click)

  1. Ensure Docker Desktop is active.
  2. Double-click launch_predklebamr.command.
    • (Note: If prompted about permissions on first run, open Terminal once and run chmod +x launch_predklebamr.command).
  3. Access the dashboard via Docker Desktop or open Safari/Chrome to http://localhost:8080.

Option C: Run the Application on Windows without Docker (One-Click)

  1. Navigate to the PredKlebAMR-v2 directory.
    cd PredKlebAMR/PredKlebAMR_v2_pipeline
  2. Double-click launch_predklebamr.bat.

🖥️ Using the Application

  1. Upload Input Data: Select or drag and drop your raw Nanopore sequencing read file (.fastq, .fq, or .fastq.gz) into the Metagenome Input field.
  2. Start Analysis: Click the gold START EDGE NODE PIPELINE button.
  3. Monitor Live Status:
    • The Execution Monitor displays real-time progress percentages across QC, depletion, extraction, and assembly.
    • Switch to the Live Terminal Console tab to view standard log outputs directly.
  4. Assembly Handoff: Once assembly finishes, the output FASTA is automatically staged for the downstream prediction engine.

🖲️ App Demo:

A four-minute demonstration showing how to use the tool:

optimized_predklebamr-v2_size.mp4

Option D: Run Locally on CLI

To run PredKlebAMR-v2 script manually from any terminal (Command-Line Interface) without using Docker or the Application:

  1. Clone the Repository
git clone https://github.com/omicscodeathon/predklebamr2.git
cd scripts/bash_scripts
  1. Conda Environment: Ensure you have Miniconda installed.

  2. Run the Pipeline

The master script dynamically handles environment creation & activation, multi-step pipeline execution, and Cloud Node (web dashboard) launching.

Execute the pipeline on your clinical sequence file, for example:

chmod +x edge_node.sh
./edge_node.sh  ERR2868205.fastq.gz

Upon successful assembly, your default browser will open automatically to the PredKlebAMR Dashboard to evaluate the output assembly.

📚Citations

If you use this tool, please acknowledge the foundational resources:

  • PredKlebAMR-v1: Babajide, A.A., Mordecai, J., Gyasi, K. et al. "PredKlebAMR: A machine learning framework prioritizing sensitivity in Klebsiella pneumoniae resistance profiling." Sci Rep (2026). https://doi.org/10.1038/s41598-026-74806-8
  • Kleborate: Lam MMC, et al. (2021). "A genomic surveillance framework and tool for Klebsiella pneumoniae and its complex." Nature Communications, 12(1).

🤝Acknowledgement

This project was supported by:

⚖️License

This project is open-source and available under the MIT License.

📞Contact

For questions, contributions, or collaborations, please open an issue or contact the project lead at James Mordecai or the project co-lead at Abiola Babajide

Team

  1. James Mordecai - Microbiology | Bioinformatics - Microbial Bioinformatician, Bash scripter, Statistical (R) analyst, Bio-illustrator, Writer - King Fahd University of Petroleum and Minerals (KFUPM), Saudi Arabia
  2. Abiola Babajide - Microbiology | Data Science | Pharmacology - Writer (Manuscript, GitHub), AL & ML enthusiast - University of the Western Cape, South Africa
  3. Chijioke Christopher Uhegwu - Member - Bioinformatics and Genomics Research Unit, Genomac Institute, Ogbomoso, Nigeria
  4. Kafilat T. Salvador-Oke - Member - Antimicrobial Research Unit, Pharmaceutical Sciences Department, School of Health Sciences, University of KwaZulu-Natal, South Africa
  5. Soufiana Traore - Member - African Center of Excellence in Bioinformatics and Data Science (ACE-B), University of Sciences, Techniques, and Technologies of Bamako, Mali
  6. Edgar Sungwacha - Member - School of Biomedical Sciences, College of Health Sciences, Jomo Kenyatta University of Agriculture and Technology (JKUAT), Kenya
  7. Yasmine Machreki - Member - Laboratory of Analysis, Treatment and Valorization of Environmental Pollutants and Products. Faculty of Pharmacy of Monastir, Tunisia
  8. Emmanuel Gyamerah - Member - University of Ghana Medical Centre Ltd. Accra, Ghana
  9. Shuaib Usman Karuma - Member - Department of Medical Biochemistry, College of Health Science, University of Abuja, Nigeria
  10. Olaitan I. Awe - Member - Institute of Genomic Medical Research (IGMR), United States

About

An Improved Predictive Metagenomic Pipeline for Antimicrobial Resistance in Klebsiella pneumoniae using Machine Learning

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages