Curation of a database for Antimicrobial Resistance Genes from African metagenomes, protein language modeling, and machine learning for functional landscape analysis
# AfriARM
Curation of a database for Antimicrobial Resistance Genes from African metagenomes, protein language modeling, and machine learning for functional landscape analysis. A preprint of this work is available here
doi.org
This repository contains scripts used to curate the Afri-ARM database, a harmonized collection of antimicrobial resistance gene (ARG) detections from African whole-genome shotgun metagenomes.
## Overview
Raw metagenomic reads were downloaded from the European Nucleotide Archive (ENA) and uniformly screened against the **Comprehensive Antibiotic Resistance Database (CARD)** using **DIAMOND BLASTX**. All samples were processed using identical thresholds and resource-conservative settings to ensure reproducibility across environments with limited computational capacity. Fasta sequences were used for embeddings and machine learning.
## Workflow
1. Download paired-end metagenomic reads from ENA (SRA accessions)
2. Translate and align reads against CARD protein sequences using DIAMOND
3. Filter alignments by identity and e-value
4. Aggregate ARG hits across samples into a master table
5. Construct a non-redundant FASTA of detected ARG proteins
6. Generate protein embeddings with ESM-2 protein language model and compare to reference ARGs from the Comprehensive Antibiotic Resistance Database (CARD)
7. Implement a protein sequence–based machine learning workflow to distinguish antibiotic resistance gene (ARG) proteins from non-ARG proteins using physicochemical and amino acid composition features
## Key Outputs
- `results/afriarm_arg_hits.tsv`
Master table of ARG detections across samples
- `metadata/afriarm_metadata_clean.tsv`
Harmonized sample metadata (country, source, host, site)
- `results/afriarm_reference_subset.fasta`
CARD protein sequences detected in African metagenomes
- `embeddings/africa_embeddings.npy`
NumPy array data storing numerical vector representations of ARG proteins from African ARGs for down …