fr3k-behemoth
v3.6.1
Published
π BEHEMOTH Cosmic Trading - Ultra-high performance crypto trading MCP server
Downloads
127
Maintainers
Readme
π BEHEMOTH Crypto MCP Server
Ultra-High Performance MCP Server for Crypto Trading Intelligence
BEHEMOTH is a comprehensive Model Context Protocol (MCP) server that provides AI assistants with access to advanced crypto trading tools, technical analysis, market data, and DeFi analytics. Built for maximum performance and reliability.
β¨ Features
- π 20 Specialized Tools - Complete crypto trading toolkit
- π 210+ Operations - Extensive functionality coverage
- π Safe Simulation Mode - Works without API keys for testing
- π€ AI-Optimized - Designed specifically for AI assistant integration
- β‘ High Performance - Optimized for real-time trading operations
- π‘οΈ Secure - Encrypted API key storage and validation
π οΈ Quick Start
Installation
npm install -g fr3k-behemothBasic Usage
# Start the server
fr3k-behemoth
# Or run directly
npx fr3k-behemothAI Integration
BEHEMOTH is designed to work seamlessly with AI assistants that support MCP. Once configured, your AI can access all trading tools automatically.
π Complete Tool Reference
π Exchange Operations
exchange - Direct exchange interactions
Operations:
ticker- Get real-time price dataorder- Place/cancel ordersmarket- Orderbook and market datawallet- Account balance information
Examples:
// Get BTC/USDT ticker
{
"name": "exchange",
"arguments": {
"operation": "ticker",
"exchange": "bybit",
"symbol": "BTCUSDT"
}
}
// Place a limit order
{
"name": "exchange",
"arguments": {
"operation": "order",
"exchange": "binance",
"symbol": "ETHUSDT",
"params": {
"side": "buy",
"orderType": "limit",
"price": "2000",
"qty": "1.0"
}
}
}π Technical Analysis
technical - Advanced technical indicators and patterns
Operations:
indicator- RSI, MACD, Bollinger Bands, EMA, SMA, Stochastic, ATR, ADXpattern- Candlestick patterns and chart analysisvolume- Volume analysis and flow detection
Examples:
// Calculate RSI
{
"name": "technical",
"arguments": {
"operation": "indicator",
"type": "RSI",
"data": [50000, 50100, 49900, 50200, 49800],
"params": { "period": 14 }
}
}
// Detect patterns
{
"name": "technical",
"arguments": {
"operation": "pattern",
"data": [[50000, 50100, 49900], [50200, 50300, 50100]],
"params": { "type": "candlestick" }
}
}π Cosmic Analysis
cosmic - Astrological and quantum market analysis
Operations:
analysis- Planetary alignments and lunar phasesquantum- Quantum coherence analysismoon- Moon phase calculationsplanetary- Planetary influence analysis
Examples:
// Get cosmic analysis
{
"name": "cosmic",
"arguments": {
"operation": "analysis",
"symbol": "BTCUSDT"
}
}π’ Sentiment Analysis
sentiment - Market sentiment and social analysis
Operations:
- Social media sentiment analysis
- News sentiment tracking
- Fear & Greed Index integration
Example:
{
"name": "sentiment",
"arguments": {
"symbol": "BTCUSDT",
"sources": ["social", "news"]
}
}βοΈ On-Chain Analysis
onchain - Blockchain metrics and whale tracking
Operations:
whale- Large transaction trackingvolume- On-chain volume analysisholders- Token holder analysis
Example:
{
"name": "onchain",
"arguments": {
"metric": "whale",
"chain": "eth",
"address": "0x123..."
}
}π Strategy Execution
strategy - Automated trading strategies
Operations:
scalping- High-frequency scalpingswing- Swing trading strategiesarbitrage- Cross-exchange arbitragegrid- Grid trading systemsdca- Dollar-cost averaging
Example:
{
"name": "strategy",
"arguments": {
"type": "scalping",
"params": {
"symbol": "BTCUSDT",
"timeframe": "1m",
"profitTarget": 0.5,
"stopLoss": 0.3
}
}
}π€ AI/ML Analysis
ai - Machine learning predictions and analysis
Operations:
predict- Price predictions using LSTM/Transformer/GANanalyze- Feature importance and clusteringanomaly- Anomaly detection
Examples:
// LSTM prediction
{
"name": "ai",
"arguments": {
"operation": "predict",
"model": "lstm",
"data": {
"prices": [50000, 50100, 50200, 49900, 50200]
}
}
}
// Anomaly detection
{
"name": "ai",
"arguments": {
"operation": "anomaly",
"data": {
"prices": [50000, 50100, 50200],
"volumes": [1000, 1200, 800]
}
}
}βοΈ Risk Management
risk - Portfolio risk analysis and management
Operations:
sharpe- Sharpe ratio calculationvar- Value at Risk analysiscorrelation- Asset correlation analysisstress_test- Portfolio stress testing
Example:
{
"name": "risk",
"arguments": {
"operation": "sharpe",
"portfolio": {
"BTC": 0.5,
"ETH": 0.3,
"USDT": 0.2
},
"returns": [0.05, 0.03, -0.02, 0.08]
}
}π§ System Operations
system - System monitoring and diagnostics
Operations:
monitor- System performance metricshealth- Component health checksperformance- Response time analysis
Example:
{
"name": "system",
"arguments": {
"operation": "monitor"
}
}π¦ DeFi Analysis
defi - Decentralized Finance analytics
Operations:
tvl- Total Value Locked analysisyield- Yield farming opportunitiesliquidity- Pool liquidity analysis
Example:
{
"name": "defi",
"arguments": {
"protocol": "uniswap",
"operation": "tvl",
"chain": "eth"
}
}π Web3 Operations
web3 - Web3 and blockchain interactions
Operations:
gas- Gas price optimizationnft- NFT market analysiscontract- Smart contract analysis
Example:
{
"name": "web3",
"arguments": {
"operation": "gas",
"chain": "eth"
}
}π‘ Real-Time Data
realtime - Live market data streaming
Operations:
price- Real-time price feedsvolume- Live volume analysisorderbook- Dynamic orderbook updates
Example:
{
"name": "realtime",
"arguments": {
"operation": "price",
"symbol": "BTCUSDT",
"exchange": "bybit"
}
}π§ FR3K Operations
fr3k - Advanced FR3K-specific features
Operations:
status- System status and configurationevolve- System evolution and upgradesconfig- Configuration management
Example:
{
"name": "fr3k",
"arguments": {
"operation": "status"
}
}π― Smart Orders
smartorder - Advanced order types
Operations:
limit- Standard limit ordersstop- Stop-loss orderstrailing- Trailing stop ordersiceberg- Iceberg orderstwap- Time-weighted average price
Example:
{
"name": "smartorder",
"arguments": {
"type": "trailing",
"side": "sell",
"symbol": "BTCUSDT",
"amount": 0.1,
"params": {
"trailPercent": 2.0
}
}
}π Backtesting
backtest - Strategy backtesting engine
Operations:
- Full strategy backtesting with historical data
- Performance metrics calculation
- Risk analysis and optimization
Example:
{
"name": "backtest",
"arguments": {
"strategy": "scalping",
"period": "1y",
"params": {
"symbol": "BTCUSDT",
"initialCapital": 10000
}
}
}π¨ Alert System
alert - Intelligent alert management
Operations:
- Price alerts
- Technical indicator alerts
- Volume spike alerts
- Custom condition alerts
Example:
{
"name": "alert",
"arguments": {
"type": "price",
"condition": "BTCUSDT > 60000",
"action": "notify"
}
}β‘ Arbitrage Engine
arbitrage - Cross-exchange arbitrage detection
Operations:
- Cross-exchange price differences
- Triangular arbitrage opportunities
- Statistical arbitrage signals
Example:
{
"name": "arbitrage",
"arguments": {
"mode": "cross-exchange",
"minProfit": 0.1,
"execute": false
}
}π§ Liquidity Analysis
liquidity - DeFi liquidity optimization
Operations:
- Pool analysis and optimization
- Impermanent loss calculations
- Optimal range suggestions
Example:
{
"name": "liquidity",
"arguments": {
"operation": "analyze",
"pool": "ETH-USDC",
"params": {
"fee_tier": 0.3
}
}
}ποΈ BEHEMOTH Control
behemoth - Master control interface
Operations:
status- Complete system statusstats- System statisticsconfig- Configuration managementreset- System resetevolve- Consciousness evolution
Example:
{
"name": "behemoth",
"arguments": {
"command": "status"
}
}π API Key Setup
Automatic Setup
fr3k-behemoth setupManual Configuration
BEHEMOTH supports multiple exchanges:
- Bybit (V5 API - Unified Account)
- Binance (Spot & Futures)
- Bitget (Spot & Futures)
API keys are encrypted and stored securely in ~/.fr3k-behemoth/exchange-keys.json.
Environment Variables
You can also set API keys via environment variables:
export BYBIT_API_KEY="your_api_key"
export BYBIT_API_SECRET="your_api_secret"
export BINANCE_API_KEY="your_api_key"
export BINANCE_API_SECRET="your_api_secret"π€ AI Integration Guide
MCP Configuration
Add BEHEMOTH to your AI assistant's MCP configuration:
{
"mcpServers": {
"fr3k-behemoth": {
"command": "npx",
"args": ["fr3k-behemoth"],
"env": {
"LOG_LEVEL": "info"
}
}
}
}Claude Desktop Integration
For Claude Desktop, add to your claude_desktop_config.json:
{
"mcpServers": {
"fr3k-behemoth": {
"command": "npx",
"args": ["fr3k-behemoth"]
}
}
}Usage with AI Assistants
Once configured, your AI assistant can use natural language to access BEHEMOTH tools:
"Analyze the current BTC/USDT technical indicators"
"Execute a scalping strategy on ETH/USDT"
"Check for arbitrage opportunities"
"Get the current system status"π§ Configuration
Environment Variables
LOG_LEVEL- Set logging level (error, warn, info, debug)BEHEMOTH_MODE- Operation mode (production, testnet, simulation)
Configuration File
Create ~/.fr3k-behemoth/behemoth-config.json:
{
"mode": "production",
"exchanges": ["bybit", "binance"],
"risk_limits": {
"max_position": 10000,
"max_leverage": 10
}
}π Response Format
All tools return standardized JSON responses:
{
"result": {
"content": [
{
"type": "text",
"text": "{\"success\": true, \"data\": {...}}"
}
]
},
"jsonrpc": "2.0",
"id": 1
}π¨ Error Handling
BEHEMOTH provides comprehensive error handling:
- API Errors - Exchange API failures
- Network Errors - Connection issues
- Validation Errors - Invalid parameters
- Rate Limit Errors - Exchange rate limiting
All errors include detailed error messages and recovery suggestions.
π Security
- API keys are encrypted using AES-256-CBC
- No sensitive data is logged
- Secure key derivation using PBKDF2
- Automatic key rotation support
π Performance
- Sub-millisecond response times for local operations
- Optimized API calls with intelligent caching
- Parallel processing for multiple operations
- Memory efficient with automatic cleanup
π Troubleshooting
Common Issues
Server won't start:
# Check Node.js version
node --version # Requires v16+
# Clear cache
rm -rf ~/.fr3k-behemothAPI connection fails:
# Reconfigure API keys
fr3k-behemoth setup
# Check API key permissions
# Ensure Unified Trading Account for BybitTools return simulation data:
- This is normal when no API keys are configured
- Configure keys to get live data
Debug Mode
Enable detailed logging:
LOG_LEVEL=debug fr3k-behemothπ Advanced Usage
Custom Strategies
Create custom trading strategies using the strategy framework:
{
"name": "strategy",
"arguments": {
"type": "custom",
"params": {
"entry_conditions": ["RSI < 30", "volume > average"],
"exit_conditions": ["RSI > 70", "profit > 2%"],
"risk_management": {
"stop_loss": 1.0,
"take_profit": 3.0
}
}
}
}Batch Operations
Execute multiple operations in sequence:
// First get market data
{
"name": "exchange",
"arguments": {
"operation": "ticker",
"symbol": "BTCUSDT"
}
}
// Then analyze technically
{
"name": "technical",
"arguments": {
"operation": "indicator",
"type": "RSI",
"data": [/* price data */]
}
}π€ Contributing
BEHEMOTH is an open-source project. Contributions welcome!
- Fork the repository
- Create a feature branch
- Add tests for new functionality
- Submit a pull request
π License
MIT License - see LICENSE file for details.
π Support
- Documentation: This README and inline code comments
- Issues: GitHub Issues for bug reports
- Discussions: GitHub Discussions for questions
π What's Next
- AI Agent Integration - Direct AI agent control
- Multi-Exchange Arbitrage - Advanced arbitrage strategies
- DeFi Yield Optimization - Automated yield farming
- Quantum Computing - Quantum-enhanced analysis
- Cross-Chain Operations - Multi-chain DeFi operations
Built with β€οΈ for the crypto trading community
BEHEMOTH: Where AI meets Crypto Trading Intelligence π
