--- license: mit tags: - mev - blockchain - solana - llm - finance - gpt-oss - 20b - lora datasets: - custom metrics: - accuracy model-index: - name: almev results: - task: type: text-generation name: MEV Detection & Analysis metrics: - name: MEV Detection Accuracy type: accuracy value: 0.993 base_model: gpt-oss-20b --- # ALMEV - GPT-OSS-20B Fine-tuned for MEV Detection ## 🚀 20B Parameter LLM Specialized for Maximum Extractable Value This is the full GPT-OSS-20B model (13GB) enhanced with LoRA adapters specifically trained for MEV detection on Solana blockchain. ### Model Architecture - **Base Model**: GPT-OSS-20B (13GB quantized) - **Total Parameters**: 20 billion + 315K MEV adapter - **Adapter Type**: LoRA (Low-Rank Adaptation) - **Training Method**: Multi-task learning with regularization - **Validation Accuracy**: 99.3% ### Training Details - **Dataset**: 700,805 Solana transactions - **MEV Types Detected**: - Arbitrage opportunities - Sandwich attacks - Liquidation events - Front-running patterns - **Training Hardware**: Apple M4 Max (MPS) - **Optimization**: AdamW with weight decay ### Model Components | Component | Description | Size | |-----------|-------------|------| | Base Model | GPT-OSS-20B (quantized) | 13GB | | MEV Adapter | LoRA fine-tuning weights | 1.2MB | | Total Size | Full model | ~13GB | ### Usage #### With Ollama ```bash # Install the model ollama pull zpphxd/almev # Run interactive session ollama run zpphxd/almev ``` #### Example Prompts ``` "Analyze this transaction for MEV opportunities: {tx_data}" "What profit can be extracted from this arbitrage?" "Identify sandwich attack patterns in these transactions" ``` #### Python Integration ```python import ollama client = ollama.Client() response = client.generate( model='zpphxd/almev', prompt='Analyze MEV opportunity: compute=500000, fee=20000' ) print(response['response']) ``` ### Performance Metrics | Metric | Value | |--------|-------| | MEV Detection Accuracy | 99.3% | | Inference Speed | ~100ms per transaction | | False Positive Rate | <2% | | Profit Prediction R² | 0.89 | ### Capabilities ✅ **Real-time MEV Detection** - Identifies profitable opportunities in <100ms - Supports high-frequency analysis ✅ **Multi-type Classification** - Arbitrage detection with profit estimation - Sandwich attack pattern recognition - Liquidation opportunity spotting - Front-running vulnerability analysis ✅ **Profit Optimization** - Estimates extractable value - Suggests optimal execution timing - Provides confidence scores ### Files Included - `adapter_model.bin` - LoRA adapter weights (1.2MB) - `config.json` - Model configuration - `README.md` - This documentation - `Modelfile` - Ollama configuration ### Installation & Setup 1. **For Ollama Users**: ```bash ollama create almev -f Modelfile ``` 2. **For Direct Usage**: - Requires base model: gpt-oss:20b - Apply adapter weights using provided config ### Citation If you use this model in your research or applications: ```bibtex @misc{almev2024, author = {zpphxd}, title = {ALMEV: 20B Parameter LLM for MEV Detection}, year = {2024}, publisher = {Hugging Face}, url = {https://huggingface.co/zpphxd/almev} } ``` ### License MIT License - Commercial use permitted ### Disclaimer This model is for research and educational purposes. Always verify MEV opportunities independently before executing trades.