Overview
The Strategy Sentinel Agent is an autonomous agent that monitors and manages vault strategies. It provides comprehensive tools for reading strategy state, managing risk, rebalancing allocations, and executing administrative operations.Agent Responsibilities
- Monitor strategy health and vault state
- Detect and mitigate liquidation risks
- Manage leverage strategy parameters
- Rebalance portfolio allocations
- Harvest yield from strategies
- Make price-based decisions using real market data
Agent Tools
Read & Monitoring Tools
get_vault_state
Reads the vault’s global state including total assets, supply, and managed balance.string
Total assets in vault (raw 18 decimals)
string
Total share supply (raw 18 decimals)
string
Total managed assets across all strategies (raw 18 decimals)
string
Human-readable total assets
string
Human-readable total supply
string
Human-readable total managed
get_strategy_states
Fetches strategy addresses, their balances, and target BPS allocations from the Strategy Router.string
Strategy contract address
string
Strategy balance (raw 18 decimals)
string
Target allocation in basis points (10000 = 100%)
string
Human-readable balance
string
Target allocation as percentage
get_leverage_strategy_state
Gets comprehensive state of the leverage strategy including deposited amount, borrowed WETH, LTV, and pause status.string
Total LINK deposited (raw 18 decimals)
string
Total WETH borrowed (raw 18 decimals)
string
Net exposure (raw 18 decimals)
string
Loan-to-value ratio (raw 18 decimals)
boolean
Whether strategy is paused
string
Maximum leverage loop iterations (1-6)
string
Borrow factor in basis points
string
Human-readable deposited amount
string
Human-readable borrowed WETH
string
Human-readable net exposure
number
LTV as decimal (e.g., 0.65 = 65%)
boolean
Pause status
number
Max depth as number
number
Borrow factor as percentage
get_token_prices
Fetches real-time LINK and WETH prices from CoinGecko API.string
LINK price in USD (scaled by 1e18)
string
WETH price in USD (scaled by 1e18)
string
How many LINK equal 1 WETH (scaled by 1e18)
string
Human-readable LINK price
string
Human-readable WETH price
string
Human-readable LINK/WETH ratio
string
24-hour LINK price change
string
24-hour WETH price change
string
Human-readable price ratio interpretation
string
Data source
get_user_balances
Fetches vault share balance and withdrawable amount for a specific user.string
required
User wallet address
User’s share balance (raw 18 decimals)
string
Withdrawable LINK amount (raw 18 decimals)
Human-readable shares
string
Human-readable withdrawable amount
get_vault_apy
Calculates the vault APY based on TVL growth over time.number
APY as decimal
string
Human-readable APY percentage
number
Current total value locked
number
TVL growth since last measurement
number
Time elapsed in seconds
Vault Management Tools
vault_deposit
Deposit LINK into vault (admin operation).string
required
Amount of LINK to deposit (human-readable)
string
Transaction hash
vault_withdraw
Withdraw shares from vault (admin operation).Number of shares to withdraw
string
Transaction hash
rebalance_vault
Triggers vault rebalance to reallocate funds according to target weights.string
Transaction hash
Rebalancing should be called after updating strategy target weights to execute the allocation changes.
harvest_strategy
Calls harvestAll() to collect yield from all strategies and return it to the vault.string
Transaction hash
Risk Management Tools
check_liquidation_risk
Checks leverage strategy liquidation risk based on current LTV.number
Current loan-to-value ratio
boolean
Whether LTV is safe (< 70%)
boolean
Whether LTV is in warning range (70-80%)
boolean
Whether LTV is critical (>= 80%)
auto_deleverage
Repay debt to reduce liquidation risk.string
Transaction hash
Strategy Configuration Tools
update_strategy_target_weights
Updates target allocation weights for strategies in basis points (10000 = 100%).number
required
Target weight for leverage strategy (0-10000)
number
required
Target weight for Aave strategy (0-10000)
string
Transaction hash
object
New weight configuration
The two weights must sum to exactly 10000 (100%). After updating weights, call
rebalance_vault to execute the reallocation.toggle_leverage_strategy_pause
Pauses or unpauses the leverage strategy.string
Transaction hash
boolean
New pause state
string
Status description (“paused” or “active”)
update_leverage_params
Updates leverage strategy parameters for fine-tuning risk exposure.number
required
Maximum leverage loop iterations (1-6)
number
required
Borrow factor in basis points (0-8000, e.g., 6000 = 60%)
string
Transaction hash
object
New parameter configuration
- maxDepth: Controls how many times the strategy loops to build leverage. Higher = more leverage, more gas.
- borrowFactor: Percentage of collateral to borrow in each loop. Higher = more aggressive leverage.
Risk Management Strategy
The Strategy Sentinel Agent follows a rule-based risk management approach:LTV Thresholds
- Safe: LTV < 70% - Normal operations
- Warning: LTV 70-80% - Monitor closely, consider reducing leverage
- Critical: LTV >= 80% - Immediate deleveraging required
Price-Based Decisions
The agent uses real-time price data from CoinGecko to make informed decisions:1
Fetch prices
Call
get_token_prices to get current LINK/WETH prices2
Assess volatility
Check 24h price changes to determine market volatility
3
Evaluate risk
If price volatility > 10% or prices dropping rapidly:
- Pause leverage strategy (
toggle_leverage_strategy_pause) - Reduce leverage params (
update_leverage_params) - Adjust target weights (
update_strategy_target_weights)
4
Execute changes
Call
rebalance_vault to apply allocation changesTarget Weight Management
Default allocation:- Leverage Strategy: 80% (8000 BPS)
- Aave Strategy: 20% (2000 BPS)
- Market volatility (reduce leverage allocation during high volatility)
- Price trends (shift to safer strategies when prices are declining)
- LTV levels (reduce leverage allocation if LTV is consistently high)
Example: Complete Risk Mitigation Flow
Best Practices
- Always check prices before decisions: Use
get_token_pricesto inform risk management - Monitor LTV regularly: Call
check_liquidation_riskfrequently - Gradual adjustments: Make incremental changes to leverage params rather than drastic shifts
- Rebalance after weight changes: Always call
rebalance_vaultafter updating target weights - Harvest regularly: Call
harvest_strategyperiodically to compound returns - Emergency pause: Use
toggle_leverage_strategy_pauseimmediately if LTV exceeds 80%