Skip to content

Add StrategyHook hook on robinhood#1115

Merged
marktoda merged 1 commit into
mainfrom
hooks/robinhood/0xc8fe3570f110d092e86393c095c6998a8d5a6544
Jul 21, 2026
Merged

Add StrategyHook hook on robinhood#1115
marktoda merged 1 commit into
mainfrom
hooks/robinhood/0xc8fe3570f110d092e86393c095c6998a8d5a6544

Conversation

@hooklist-generator

Copy link
Copy Markdown
Contributor

Summary

A multi-strategy hook that collects a time-decaying swap fee via afterSwapReturnsDelta, splitting proceeds between an ops wallet and fee collector. Pools are owner-initialized and mapped to configurable strategies; exact-output swaps revert.

Flags

Flag Value
beforeInitialize true
afterInitialize false
beforeAddLiquidity false
afterAddLiquidity true
beforeRemoveLiquidity false
afterRemoveLiquidity true
beforeSwap false
afterSwap true
beforeDonate false
afterDonate false
beforeSwapReturnsDelta false
afterSwapReturnsDelta true
afterAddLiquidityReturnsDelta false
afterRemoveLiquidityReturnsDelta false

Properties

Property Value
dynamicFee false
upgradeable false
requiresCustomSwapData false
vanillaSwap false
swapAccess none

Warnings

  • Submitter did not provide a description. Using AI-generated description.

Closes #1108

@vercel

vercel Bot commented Jul 20, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hooklist Ready Ready Preview, Comment Jul 20, 2026 2:41pm

Request Review

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review: hooks/robinhood/0xc8fe3570f110d092e86393c095c6998a8d5a6544.json

Address Flags

Address 0xc8fe3570f110d092e86393c095c6998a8d5a6544 — lowest 14 bits: 0x6544 & 0x3FFF = 0x2544 = 10 0101 0100 0100 binary.

All 14 flag bits match the JSON and match getHookPermissions() in the source:

  • beforeInitialize = true (bit 13 = 1) ✓
  • afterAddLiquidity = true (bit 10 = 1) ✓
  • afterRemoveLiquidity = true (bit 8 = 1) ✓
  • afterSwap = true (bit 6 = 1) ✓
  • afterSwapReturnsDelta = true (bit 2 = 1) ✓
  • All other flags = false ✓

Chain & Metadata

  • chainId: 4663 matches chains.json entry for robinhood
  • name: "StrategyHook" matches source_meta.json (contractName: "StrategyHook") and the contract declaration contract StrategyHook
  • verifiedSource: true confirmed by source_meta.json ("verified": true) ✓
  • No promotional, audit, or endorsement language in name or description ✓

Properties

  • dynamicFee: false — Correct. The hook has no beforeSwap flag and never calls poolManager.updateDynamicLPFee(). Fees collected in afterSwap are an additional hook fee via afterSwapReturnsDelta, not a dynamic LP fee override.

  • upgradeable: false — Correct. source_meta.json shows proxy: false. Contract is a standard BaseHook + Ownable with no proxy, delegatecall, mutable implementation pointer, or SELFDESTRUCT.

  • requiresCustomSwapData: false — Correct. _afterSwap ignores the bytes calldata (hookData) parameter entirely; swaps proceed without it.

  • vanillaSwap: false — Correct. afterSwapReturnsDelta is true, so this must be false per spec. Confirmed: _afterSwap returns a non-zero int128 fee delta that modifies the effective swap output.

  • swapAccess: "none" — Correct. There is no beforeSwap hook. _afterSwap contains no access-control gate (no allowlist, temporal, or governance check). feeExemptSwappers only waives the fee; it does not block or gate swap execution.

Description Accuracy

"A multi-strategy hook that collects a time-decaying swap fee via afterSwapReturnsDelta, splitting proceeds between an ops wallet and fee collector. Pools are owner-initialized and mapped to configurable strategies; exact-output swaps revert."

All claims substantiated:

  • Multi-strategy: mapping(uint256 => StrategyConfig) public strategies with multiple IDs ✓
  • Time-decaying fee via afterSwapReturnsDelta: _feeBps() decays from startingFeeBps toward restingFeeBps based on block.timestamp - launchTimestamp, collected via int128 return in _afterSwap
  • Split between ops wallet and fee collector: explicit opsAmount / collectorAmount split logic ✓
  • Owner-initialized pools: _beforeInitialize enforces if (sender != owner()) revert NotOwner()
  • Exact-output reverts: if (params.amountSpecified > 0) revert ExactOutputNotAllowed()

All checks pass.

@marktoda marktoda left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bot review verified. StrategyHook (robinhood). Flags: beforeInitialize, afterAdd/RemoveLiquidity, afterSwap, afterSwapReturnsDelta. LGTM.

@marktoda
marktoda merged commit cf7f8eb into main Jul 21, 2026
7 checks passed
@marktoda
marktoda deleted the hooks/robinhood/0xc8fe3570f110d092e86393c095c6998a8d5a6544 branch July 21, 2026 16:24
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.

hook: StrategyHook on Robinhood Chain

1 participant