Join the conversation

Join the community of Machine Learners and AI enthusiasts.

Sign Up
codelionΒ 
posted an update 1 day ago
Post
730
Adaptive Classifier: Dynamic Text Classification with Strategic Learning

New text classification system that learns continuously without catastrophic forgetting. Achieved 22.2% robustness improvement on adversarial datasets while maintaining clean data performance.

🎯 THE PROBLEM
Traditional classifiers require complete retraining when adding new classes. Expensive and time-consuming, especially with adversarial users trying to game the system.

πŸš€ KEY INNOVATIONS
β€’ Hybrid memory-neural architecture (prototype-based + neural adaptation)
β€’ Strategic classification using game theory to predict and defend against manipulation
β€’ Elastic Weight Consolidation prevents catastrophic forgetting

πŸ“Š RESULTS
Tested on AI-Secure/adv_glue dataset:
β€’ Clean data: 80.0% β†’ 82.2% (+2.2%)
β€’ Manipulated data: 60.0% β†’ 82.2% (+22.2%)
β€’ Zero performance drop under adversarial attacks

πŸ”¬ APPLICATIONS
β€’ Hallucination detection: 80.7% recall for RAG safety
β€’ LLM routing: 26.6% cost optimization improvement
β€’ Content moderation: Robust against gaming attempts

βš™οΈ USAGE
pip install adaptive-classifier

from adaptive_classifier import AdaptiveClassifier
classifier = AdaptiveClassifier("bert-base-uncased")
classifier.add_examples(texts, labels)
predictions = classifier.predict("New text")

πŸ”— RESOURCES
Blog: https://huggingface.co/blog/codelion/adaptive-classifier
Code: https://github.com/codelion/adaptive-classifier
Models: adaptive-classifier

Available models: llm-hallucination-detector, llm-config-optimizer, llm-router

Works with any HuggingFace transformer. Fully open source and production-ready!
In this post