analyzing-liquidity-pools
Evaluate pool performance metrics and calculate impermanent loss for DEX liquidity providers.
Install
mkdir -p .claude/skills/analyzing-liquidity-pools && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/4699" && unzip -o skill.zip -d .claude/skills/analyzing-liquidity-pools && rm skill.zipInstalls to .claude/skills/analyzing-liquidity-pools
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Analyze DEX liquidity pools for TVL, volume, fees, impermanent loss,Key capabilities
- →Calculate TVL and trading volume
- →Estimate impermanent loss for price changes
- →Compare pool profitability across protocols
- →Project LP returns with fee APR
- →Export analysis to JSON or CSV
How it works
It queries subgraph data and uses internal scripts to calculate financial metrics like impermanent loss and fee APR for specific liquidity pools.
Inputs & outputs
When to use analyzing-liquidity-pools
- →Calculate impermanent loss for liquidity positions
- →Analyze pool TVL and volume trends
- →Compare liquidity pool profitability
- →Estimate APR for liquidity providers
About this skill
Analyzing Liquidity Pools
Overview
Analyze DEX liquidity pools across Uniswap, Curve, and Balancer to evaluate TVL, trading volume, fee income, and impermanent loss risk. Compare pools across protocols and chains to identify optimal LP opportunities.
Prerequisites
- Python 3.8+ installed
- Internet access for subgraph/API queries
- Understanding of liquidity providing concepts (IL, fee tiers, TVL)
Instructions
-
Analyze a specific pool by address or token pair:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --pool 0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640 python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --pair ETH/USDC --protocol uniswap-v3 -
Calculate impermanent loss for a price change:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --il-calc --entry-price 2000 --current-price 3000 # 2000/3000 = ETH price at entry/now in USDProject IL for various scenarios:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --il-scenarios --token-pair ETH/USDC -
Estimate LP returns with fee APR and position projections:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --pool [address] --detailed python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --pool [address] --position 10000 # 10000 = LP position size in USD -
Compare pools across protocols or fee tiers:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --compare --pair ETH/USDC --protocols uniswap-v3,curve,balancer python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --compare --pair ETH/USDC --fee-tiers 0.05,0.30,1.00 -
Export results to JSON or CSV:
python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --pool [address] --format json --output pool_analysis.json python ${CLAUDE_SKILL_DIR}/scripts/pool_analyzer.py --compare --pair ETH/USDC --format csv --output pools.csv
Output
Pool analysis reports include chain, TVL, 24h volume, fee tier, fee APR, volume/TVL ratio, and token composition with current price. Impermanent loss reports show IL percentage, dollar impact, HODL vs LP value comparison, and breakeven analysis with days-to-recover based on fee income.
See ${CLAUDE_SKILL_DIR}/references/implementation.md for detailed output format examples.
Error Handling
| Error | Cause | Fix |
|---|---|---|
| Pool not found | Wrong address or chain | Verify address and target chain |
| Subgraph timeout | API latency or downtime | Uses cached data with warning |
| Invalid pair | Unsupported protocol | Check supported protocols list |
Examples
Analyze top ETH/USDC pool - Full TVL, volume, and fee breakdown on Uniswap V3:
python pool_analyzer.py --pair ETH/USDC --protocol uniswap-v3 --chain ethereum
Calculate IL for 2x price increase - See dollar impact vs holding:
python pool_analyzer.py --il-calc --entry-price 100 --current-price 200 # 100/200 = token price at entry/now in USD
Compare Uniswap fee tiers - Find optimal fee tier for ETH/USDC:
python pool_analyzer.py --compare --pair ETH/USDC --fee-tiers 0.05,0.30,1.00
Export all ETH pairs - Dump pool data for further analysis:
python pool_analyzer.py --token ETH --format json --output eth_pools.json
Resources
- The Graph: https://thegraph.com/ - Subgraph queries
- Uniswap Info: https://info.uniswap.org/ - Pool explorer
- DeFiLlama: https://defillama.com/ - TVL data
${CLAUDE_SKILL_DIR}/references/implementation.md- Detailed output formats, configuration, cross-protocol comparison guide
When not to use it
- →When analyzing non-DEX liquidity pools
- →When the protocol is not supported by the analyzer
Prerequisites
Limitations
- →Subgraph timeouts may occur due to API latency
- →Requires specific protocol support
How it compares
It provides automated calculation of complex LP metrics compared to manual spreadsheet tracking of pool performance.
Compared to similar skills
analyzing-liquidity-pools side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| analyzing-liquidity-pools (this skill) | 1 | 27d | Review | Intermediate |
| quant-analyst | 103 | 2mo | No flags | Advanced |
| stock-analyzer | 71 | 2mo | Review | Beginner |
| creating-financial-models | 36 | 8mo | Review | Advanced |
Try saying
Example prompts that trigger this skill in your AI assistant.
More by jeremylongshore
View all by jeremylongshore →You might also like
quant-analyst
zenobi-us
Expert quantitative analyst specializing in financial modeling, algorithmic trading, and risk analytics. Masters statistical methods, derivatives pricing, and high-frequency trading with focus on mathematical rigor, performance optimization, and profitable strategy development.
stock-analyzer
FrancyJGLisboa
Provides comprehensive technical analysis for stocks and ETFs using RSI, MACD, Bollinger Bands, and other indicators. Activates when user requests stock analysis, technical indicators, trading signals, or market data for specific ticker symbols.
creating-financial-models
anthropics
This skill provides an advanced financial modeling suite with DCF analysis, sensitivity testing, Monte Carlo simulations, and scenario planning for investment decisions
reconciliation
anthropics
Reconcile accounts by comparing GL balances to subledgers, bank statements, or third-party data. Use when performing bank reconciliations, GL-to-subledger recs, intercompany reconciliations, or identifying and categorizing reconciling items.
analyzing-financial-statements
anthropics
This skill calculates key financial ratios and metrics from financial statement data for investment analysis
us-stock-analysis
tradermonty
Comprehensive US stock analysis including fundamental analysis (financial metrics, business quality, valuation), technical analysis (indicators, chart patterns, support/resistance), stock comparisons, and investment report generation. Use when user requests analysis of US stock tickers (e.g., "analyze AAPL", "compare TSLA vs NVDA", "give me a report on Microsoft"), evaluation of financial metrics, technical chart analysis, or investment recommendations for American stocks.