Skip to content

Add uniswap-v3-lp-base skill#332

Open
0xdeployer wants to merge 1 commit intomainfrom
add-uniswap-v3-lp-base
Open

Add uniswap-v3-lp-base skill#332
0xdeployer wants to merge 1 commit intomainfrom
add-uniswap-v3-lp-base

Conversation

@0xdeployer
Copy link
Copy Markdown
Contributor

Summary

Adds a new skill uniswap-v3-lp-base that provides an end-to-end, token-agnostic workflow for opening, monitoring, and rebalancing concentrated-liquidity Uniswap V3 positions on Base.

What it covers

  • Open: pool selection across fee tiers, slot0/tickSpacing reads, tick math for ±P% symmetric ranges, approvals, and the full NonfungiblePositionManager.mint call with the tuple signature needed for write_contract.
  • Monitor: positions(tokenId) + slot0() pattern to determine in/out of range.
  • Rebalance: the full decreaseLiquidity → collect → swap → mint cycle.
  • Automations — both types:
    • Time-based hourly watchdog (notification-only, cheap, catches drift)
    • Price-triggered rebalance commands (one per range edge, only fires on real movement)
    • Every automation command is written in imperative "right now" form so it can be executed directly by the agent when the trigger fires.

Design choices

  • Token-agnostic: no hardcoded tokens. Works for BNKR/WETH, any Clanker/WETH, any ERC-20/ERC-20 pair on Base.
  • User-specific state lives outside the skill: all positions are persisted to the user's memory file at /.memory/project_uniswap_v3_positions.md. The skill defines the schema and reads/writes the file — it never inlines wallet-specific data.
  • Both automation types included, because they serve different roles (drift detection vs. trigger-based action).

Files

  • uniswap-v3-lp-base/SKILL.md — single file, no references needed.

Testing

  • Drafted while opening a real BNKR/WETH ±25% position on the 1% pool (tokenId 5017957). Pool selection, tick math, and the mint tuple signature all verified against live on-chain state.
  • Both automation types set up and active using the documented command templates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant