Skill
mantle-portfolio-analyst
When to use
What it does
by mantle-xyzยทv1.0.0
Install
git clone https://github.com/mantle-xyz/mantle-skillsBuild deterministic, read-only wallet analysis on Mantle. Enumerate balances, DeFi positions (Aave V3 lending, V3 LP, Merchant Moe LB LP), and allowances, then highlight approval risk in a structured report.
CRITICAL: Steps 4 through 9 are ALL MANDATORY and MUST be executed in exact order. Do NOT skip, reorder, or merge any step. Do NOT proceed to step N+1 until step N has returned a result. Every step must produce a tool call โ if you find yourself writing the report without having executed all steps, STOP and go back to the first missed step.
wallet_addressnetwork (mainnet or sepolia)mantle-cli registry validate <address> --jsonmantle-cli chain info --jsonmantle-cli chain status --jsonmantle://registry/tokensmantle://registry/protocolsmantle-cli account balance <address> --json.mantle-cli account token-balances <address> --tokens <list> --json.
partial: true, note which tokens had errors but still proceed with the successful results.mantle-cli aave positions --user <address> --json.
at_risk or liquidatable positions prominently.mantle-cli lp positions --owner <address> --json.
mantle-cli lp lb-positions --owner <address> --json.
mantle-cli account allowances <owner> --pairs <token:spender,...> --json.mantle-cli token info <token> --json for that token and keep missing fields as unknown when unresolved.low: allowance is zero, or tightly bounded and clearly below wallet balance/expected use.medium: allowance is non-zero and larger than immediate expected use, but still bounded.high: allowance is very large relative to expected use, or intentionally broad with unclear user intent.critical: is_unlimited=true from tool output, or allowance equals/near-max integer (value >= 2^255).unknown unless verified from mantle://registry/protocols or user-confirmed.high and critical approvals at top of summary.mantle-cli aave positions returns partial: true, note which reserves had errors and state that per-reserve breakdowns may be incomplete while aggregate USD totals (from getUserAccountData) remain accurate.mantle-cli aave positions returns possible_missing_reserves: true, warn that Aave governance may have added new reserves not yet tracked by this tool. Aggregate USD totals are still accurate.collateral_enabled field. If any position has supplied > 0 but collateral_enabled: false:
mantle-cli aave markets --json to check the reserve's ltv_bps field.ltv_bps is 0 (known examples: sUSDe, FBTC, syrupUSDT, wrsETH on Mantle), classify as informational โ this asset cannot be collateral by governance design, not a user error. Do NOT suggest set-collateral.ltv_bps > 0, flag as collateral warning โ the user has deposited tokens but they are NOT counting toward borrowing capacity. This can cause borrow failures. Suggest checking set-collateral.mantle-cli lp lb-positions returns positions, note the coverage: "known_pairs_only" and scan_radius limitations. Explicitly state that positions in distant bins or unlisted pairs are NOT checked.mantle-cli lp lb-positions returns total_positions: 0, do NOT conclude the wallet has no LB exposure โ only state that no positions were found within the scan range.mantle-cli account balance (step 4)mantle-cli account token-balances (step 5)mantle-cli aave positions (step 6)mantle-cli lp positions (step 7)mantle-cli lp lb-positions (step 8)mantle-cli account allowances (step 9)mantle-cli read-only commands only for this skill (mantle-cli account balance, mantle-cli account token-balances, mantle-cli account allowances, mantle-cli aave positions, mantle-cli aave markets, mantle-cli lp positions, mantle-cli lp lb-positions, mantle-cli token info, chain/address validation helpers). Do NOT enable or connect to the MCP server.eth_*) as if they are callable tools in this workflow.0x0000...0000), stop and return an error message explaining the issue -- do not proceed with queries against an invalid address.unknown and continue.raw and normalized values in output. Prefer normalized values from tool responses; convert manually only when decimals are explicitly known. If decimals are unavailable, keep raw only and lower confidence.partial flags and per-entry error fields.Always use this exact report structure, even when the user query is scoped to a specific token, spender, or subset. Omit sections only if they are genuinely empty (e.g., no allowances found), but keep all section headers. For scoped queries, populate only the relevant entries within each section and note the applied filter in the summary.
Mantle Portfolio Report
- wallet:
- network:
- chain_id:
- collected_at_utc:
Native Balance
- MNT:
Token Balances
- token: <symbol_or_label>
address:
balance_raw:
decimals:
balance_normalized:
Aave V3 Positions
- health_factor:
- health_status: no_debt | safe | moderate | at_risk | liquidatable
- total_collateral_usd:
- total_debt_usd:
- available_borrows_usd:
- positions:
- symbol:
supplied:
borrowed:
collateral_enabled: true | false | null (null = could not read)
- collateral_warnings: # flag any position where supplied > 0 but collateral_enabled = false
V3 LP Positions (Agni / Fluxion)
- total_positions:
- positions:
- provider:
pool:
token0/token1:
liquidity:
in_range:
Merchant Moe LB Positions
- total_positions:
- positions:
- pair:
token_x/token_y:
bins_with_liquidity:
Allowance Exposure
- token:
spender:
allowance_raw:
allowance_normalized:
risk_level: low | medium | high | critical
rationale:
Summary
- tokens_with_balance:
- aave_health_status:
- v3_lp_positions:
- lb_positions:
- allowances_checked:
- unlimited_or_near_unlimited_count:
- key_risks:
- confidence:
references/rpc-readonly-workflow.mdreferences/allowance-risk-rules.md