Skip to content

GammaStrategies/agent-skills

Repository files navigation

Gamma Agent Skills

Production-ready agent skills for building rebalance, swap, and withdrawal strategies for Gamma's Uniswap V4 MultiPositionManager vaults.

Install

List available skills:

npx skills add GammaStrategies/agent-skills --list

Interactive install with agent picker:

npx skills add GammaStrategies/agent-skills --skill gamma-strategy-builder -g

Install non-interactively (CI/copy-paste):

npx skills add GammaStrategies/agent-skills --skill gamma-strategy-builder -g -y

Install for specific agents:

npx skills add GammaStrategies/agent-skills --skill gamma-strategy-builder -a codex -a openclaw -g -y

Skills Primer (How Agents Use Skills)

Skills are runtime instruction modules for agents, not model training.

  1. Repo exposes one or more skills/<name>/SKILL.md files.
  2. Installer links selected skills to selected agents (codex, openclaw, etc.).
  3. /skills in the agent UI shows linked skills available to that agent.
  4. Skill triggers when user prompt explicitly names it or matches description.
  5. Agent loads SKILL.md first, then optional references/ and scripts/ as needed.

Agent-selection UX behavior:

  1. If you omit -a and omit -y, installer prompts with a multi-select agent picker.
  2. If you pass -a ..., install is scoped to those agents.
  3. If you pass -y, prompts are skipped.

Skills

gamma-strategy-builder

Build RebalanceParams, RebalanceSwapParams, and withdrawal parameters for EOA relayer bots operating Gamma MultiPositionManager vaults.

Covers:

  • Strategy selection (singleUniform, gaussian, uniform, triangle, camel, exponential)
  • Sentinel values (type(int24).max for current-tick centering, 0,0 weights for proportional mode)
  • Aggregator swap construction (KyberSwap, Odos, 0x, ParaSwap)
  • Withdrawal strategies (withdraw, withdrawCustom)
  • SimpleLens preview calls for outMin/inMin slippage arrays
  • EOA relayer trigger patterns (tick delta, direction-only, cooldown, circuit breaker, ratio-based)
  • Bundled helper script to emit normalized --strategy-json payloads for gamma-openclaw start
  • Bundled helper script to emit normalized --swap-json payloads for gamma-openclaw deploy --swap
  • Bundled helper script to emit normalized withdrawCustom JSON payloads with offline scaffold or optional SimpleLens preview

Skill Docs

  • Skill catalog: AVAILABLE_SKILLS.md

OpenClaw CLI (Rebalancer-First Flow)

Install local CLI deps:

npm install

Run onboarding:

npm exec gamma-openclaw init

init assumes manager is already deployed from frontend and asks for:

  • chain + rpc
  • existing MultiPositionManager address
  • bot key setup

Health check:

npm exec gamma-openclaw doctor

Preflight checks (contracts, aggregators, roles):

npm exec gamma-openclaw prepare

Deploy manager (dry-run simulation):

npm exec gamma-openclaw deploy --dry-run

Deploy manager (send transaction):

npm exec gamma-openclaw deploy

Start scaffold runner:

npm exec gamma-openclaw start

Generate strategy file with interactive wizard:

npm exec gamma-openclaw -- strategy wizard

Generate from intent prompt, save, and run one cycle:

npm exec gamma-openclaw -- strategy wizard --prompt "single uniform +/-5% around current price, rebalance up only" --run

Sweep native gas token from bot wallet:

npm exec gamma-openclaw -- sweep-native --to 0xYourEOA --dry-run
npm exec gamma-openclaw -- sweep-native --to 0xYourEOA

Typical lifecycle:

  1. Deploy/fund manager on frontend.
  2. Run init to configure bot + manager.
  3. Fund bot gas.
  4. Grant grantRelayerRole(bot) from manager owner.
  5. Run doctor, prepare, then start.

Smoke test script (recommended before live):

./scripts/smoke-test.sh --manager 0xYourVaultAddress

Systemd template for production runs:

  • templates/systemd/gamma-openclaw.service

Contract and Protocol References

All contract ABIs, parameter guides, and protocol documentation are bundled under each skill's references/ directory. See skills/gamma-strategy-builder/references/ for:

  • rebalance-params.mdRebalanceParams field-by-field guide
  • rebalance-swap-params.mdSwapParams construction and aggregator flow
  • strategies.md — strategy contract behavior
  • sentinel-values.md — special values and validation rules
  • withdrawal-strategies.md — withdrawal flows and previews
  • registry-defaults.md — chain defaults and registry structure

Chain Defaults

Gamma-provided chain defaults are stored in registry/networks.v1.json. Registry contract keys cover: factory, deployers, lenses, relayer factory, pool manager, and state view.

About

No description, website, or topics provided.

Resources

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors