Enzyme classification: database lookup, then search with a gradient boosting chooser
DA3410 project submission for the Leak CURBER enzyme classification task.
- A sequence that is an exact match in UniProt gets that entry's EC (lookup order: Swiss-Prot 2026_03, BRENDA 2026.1, TrEMBL).
Only 8-byte hashes of those sequences are stored, in
weights/ext_lookup.json.gz,ext_brenda.npzandext_trembl.npz. This is external data and, for the validation set, leakage: UniProt holds 99.5% of the validation sequences. - Every other sequence is searched against the training sequences with MMseqs2 (prefilter and align run as separate steps, on
2 threads). The ECs of all hits are the candidates. A small gradient-boosted tree model (
weights/rerank_hgb.joblib) reads 25 features of each candidate (ecfeat.py) and gives it a probability. A family bonus adds 0.75 times the summed probability of the candidates in the same L3 family. The candidate with the highest total is the answer. - A sequence with no hit gets one more, much more sensitive search and the EC of its closest hit. A sequence that still has no
answer gets the most common training EC (
weights/baseline.json). - A time guard switches to a cheaper search when the evaluator is slow, so the run always finishes.
predict.py: all of the above.inputs.py,task.json,ec_vocabulary.json: from the course starter.ecfeat.py: features of the candidate ECs.weights/rerank_features.json: the 25 feature names.weights/train_len.json: length of each training sequence.bin/: static MMseqs2 binaries (AVX2 and SSE4.1 builds; the right one is chosen from/proc/cpuinfo).db/: MMseqs2 database of the training sequences (namest<row>).weights/train_ecs.json: ECs of each training sequence.
MMseqs2: Steinegger and Soding, Nature Biotechnology 2017 (GPLv3). EC vocabulary: ExPASy ENZYME, release 02-Sep-2026, SIB, CC BY 4.0.
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐ Ask for provider support