Query editor
-- Robinhood Chain Discovery v2A.2-- DIRECT infrastructure / label audit---- Purpose:-- 1. Reconstruct the ERC-4337-aware attribution universe.-- 2. Take the highest-activity DIRECT addresses.-- 3. Enrich them with Dune address/owner labels.---- NO PnL.-- NO scoring.-- NO automatic rejection from activity level alone.WITH userops AS (SELECTtx_hash,"index" AS userop_evt_index,VARBINARY_SUBSTRING(topic2, 13, 20) AS smart_accountFROM robinhood.logsWHERE block_date >= CURRENT_DATE - INTERVAL '30' DAYAND block_date < CURRENT_DATEAND topic0 =0x49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f),userop_bounds AS (SELECTtx_hash,smart_account,userop_evt_index,LAG(userop_evt_index, 1, -1) OVER (PARTITION BY tx_hashORDER BY userop_evt_index) AS previous_userop_evt_indexFROM userops),aa_txs AS (SELECT DISTINCT tx_hashFROM userops),aa_submitters AS (SELECT DISTINCTt.tx_fromFROM dex.trades tINNER JOIN aa_txs aON t.tx_hash = a.tx_hashWHERE t.blockchain = 'robinhood'AND t.block_date >= CURRENT_DATE - INTERVAL '30' DAYAND t.block_date < CURRENT_DATE),trades AS (SELECTt.tx_hash,t.evt_index,t.block_time,t.tx_from,t.project,t.version,