harb/onchain/analysis/README.md

28 lines
978 B
Markdown
Raw Normal View History

# KRAIKEN Liquidity Analysis
2025-07-06 11:20:35 +02:00
Quick analysis tools for testing the three-position anti-arbitrage strategy.
2025-07-06 11:20:35 +02:00
## Usage
2025-07-06 11:20:35 +02:00
1. **Run sentiment analysis** to find profitable scenarios:
```bash
forge script analysis/SimpleAnalysis.s.sol:SimpleAnalysis -s "runSentimentFuzzingAnalysis()" --ffi --via-ir
```
2025-07-06 11:20:35 +02:00
2. **Start visualization server**:
```bash
./view-scenarios.sh
```
2025-07-06 11:20:35 +02:00
3. **View results** at `http://localhost:8001/scenario-visualizer.html`
2025-07-06 11:20:35 +02:00
## Files
2025-07-06 11:20:35 +02:00
- `SimpleAnalysis.s.sol` - Main analysis script with sentiment fuzzing
- `scenario-visualizer.html` - Web-based position visualization
- `view-scenarios.sh` - HTTP server launcher
- `profitable_scenario.csv` - Generated results (if profitable scenarios found)
2025-07-06 11:20:35 +02:00
## Analysis Output
2025-07-06 11:20:35 +02:00
The sentiment analysis tests bull/neutral/bear market conditions and generates CSV data for any profitable trading scenarios found. The visualizer shows position ranges, token distributions, and Uniswap V3 liquidity calculations.