aave
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAave V3 Yield Farming
Aave V3 收益耕作
Supply tokens into Aave V3 lending pools to earn yield, withdraw at any time, and view positions across multiple chains.
Supported Networks: Ethereum, Arbitrum, Base, Optimism, Polygon, Avalanche.
将代币存入Aave V3借贷池以赚取收益,可随时提取,并跨多条链查看持仓情况。
支持网络:Ethereum、Arbitrum、Base、Optimism、Polygon、Avalanche。
Runtime Mode
运行模式
This skill is script-only. It does not register tools.
aave_*Call via Python exports:
aave_positions(chain)aave_supply(chain, token, amount)aave_withdraw(chain, token, amount=0, max=False)
Imports:
from skills.aave.exports import aave_positions, aave_supply, aave_withdrawWallet dependency is runtime-only via .
core.wallet_runtime本Skill仅为脚本模式,不会注册工具。
aave_*通过Python导出调用:
aave_positions(chain)aave_supply(chain, token, amount)aave_withdraw(chain, token, amount=0, max=False)
导入方式:
from skills.aave.exports import aave_positions, aave_supply, aave_withdraw钱包依赖仅在运行时通过加载。
core.wallet_runtimePrerequisites
前置条件
Before supply/withdraw, wallet policy must allow the transaction path.
在进行存入/提取操作前,钱包策略必须允许该交易路径。
Supported Tokens by Chain
各链支持的代币
| Chain | USDC | USDT | DAI | WETH | WBTC |
|---|---|---|---|---|---|
| Ethereum | yes | yes | yes | yes | yes |
| Arbitrum | yes | yes | yes | yes | yes |
| Polygon | yes | yes | yes | yes | yes |
| Optimism | yes | yes | yes | yes | yes |
| Avalanche | yes | yes | yes | yes | yes |
| Base | yes | — | yes | yes | — |
| 链 | USDC | USDT | DAI | WETH | WBTC |
|---|---|---|---|---|---|
| Ethereum | 是 | 是 | 是 | 是 | 是 |
| Arbitrum | 是 | 是 | 是 | 是 | 是 |
| Polygon | 是 | 是 | 是 | 是 | 是 |
| Optimism | 是 | 是 | 是 | 是 | 是 |
| Avalanche | 是 | 是 | 是 | 是 | 是 |
| Base | 是 | — | 是 | 是 | — |
Script Examples
脚本示例
Read positions:
python
import asyncio
from skills.aave.exports import aave_positions
async def main():
result = await aave_positions(chain="arbitrum")
print(result)
asyncio.run(main())Supply 100 USDC:
python
import asyncio
from skills.aave.exports import aave_supply
async def main():
result = await aave_supply(chain="arbitrum", token="USDC", amount=100)
print(result)
asyncio.run(main())Withdraw partial / all:
python
import asyncio
from skills.aave.exports import aave_withdraw
async def main():
part = await aave_withdraw(chain="arbitrum", token="USDC", amount=50)
print(part)
full = await aave_withdraw(chain="arbitrum", token="USDC", max=True)
print(full)
asyncio.run(main())查看持仓:
python
import asyncio
from skills.aave.exports import aave_positions
async def main():
result = await aave_positions(chain="arbitrum")
print(result)
asyncio.run(main())存入100 USDC:
python
import asyncio
from skills.aave.exports import aave_supply
async def main():
result = await aave_supply(chain="arbitrum", token="USDC", amount=100)
print(result)
asyncio.run(main())部分提取/全部提取:
python
import asyncio
from skills.aave.exports import aave_withdraw
async def main():
part = await aave_withdraw(chain="arbitrum", token="USDC", amount=50)
print(part)
full = await aave_withdraw(chain="arbitrum", token="USDC", max=True)
print(full)
asyncio.run(main())Error Handling
错误处理
| Error | Cause | Solution |
|---|---|---|
| Invalid chain name | Use: ethereum, arbitrum, base, optimism, polygon, avalanche |
| Token not available on that chain | Check supported tokens table |
| Not enough tokens in wallet | Check wallet balance before supply |
| Zero or negative amount | Use a positive number |
| Wallet policy blocks transaction | Update wallet policy |
| Local dev environment | Supply/withdraw require deployed env with wallet |
| 错误 | 原因 | 解决方案 |
|---|---|---|
| 链名称无效 | 使用以下合法链名:ethereum、arbitrum、base、optimism、polygon、avalanche |
| 该链不支持该代币 | 查看支持代币表格 |
| 钱包中代币余额不足 | 存入前检查钱包余额 |
| 金额为零或负数 | 使用正数金额 |
| 钱包策略阻止交易 | 更新钱包策略 |
| 本地开发环境 | 存入/提取操作需要部署带有钱包的环境 |