AsmRAG achieves 96% detection F1 using retrieval-augmented assembly analysis
AsmRAG attains 96% detection F1 and 95% family attribution F1, remaining robust to metamorphic obfuscation
Security & privacy arXiv 25 Apr 2026 Method Prototype evidence
Published as “AsmRAG: LLM-Driven Malware Detection by Retrieving Functionally Similar Assembly Code”
Why it matters
Provides SOC analysts with concrete, function-level forensic evidence, improving interpretability and resilience to obfuscation.
Summary
AsmRAG achieves a detection F1-score of 96% (and 96.5% accuracy) on a 40k-binary real-world dataset, outperforming EMBER and ResNeXt+ baselines; the evidence comes from multiple runs on a chronologically split test set and shows robustness to syntactic obfuscation.
What they found 2
- Detection F1-score of 96% and family attribution F1-score of 95% on a curated 40k-binary dataset.
“Testing on a curated dataset of 40k binaries shows AsmRAG reaching a detection F1-score of 96% alongside a family attribution F1-score of 95%.”
- AsmRAG attains 96.5% accuracy (±0.2) on the held-out test set, surpassing EMBER and ResNeXt+.
“AsmRAG (Ours) 96.5% ± 0.2”
What’s new here 4
- Reforms malware detection as a semantic retrieval task over assembly functions rather than global statistical classification.
- Uses a code-specialized LLM (Qwen3-Embedding) to generate dense embeddings of raw assembly, preserving register and immediate details.
- Introduces Density-Weighted Anchor Selection to isolate the most representative malicious function and provide forensic explanations.
- Applies Semantic Library Filtering in the same embedding space to remove benign boilerplate without heavy canonicalization.