Query editor
-- Q3: Morpho Vault Net Flow — Curator Intelligence-- Net deposits minus withdrawals per token per day on Morpho Blue (Ethereum).-- Context: MetaMorpho curators (Gauntlet, Steakhouse, MEV Capital, Re7) manage risk policy.-- Sustained outflow + redemption queue anomaly = pre-exit signal (docs Chapter 5).WITH flows AS (SELECTDATE_TRUNC('day', block_time) AS day,symbol,transaction_type,SUM(amount_usd) AS flow_usdFROM lending.supplyWHERE blockchain = 'ethereum'AND project = 'morpho'AND block_time >= NOW() - INTERVAL '60' DAYAND symbol IN ('USDC','USDT','WETH','wstETH','weETH','USDe','sUSDe','DAI','USDS','crvUSD','cbETH','rETH')GROUP BY 1, 2, 3)SELECTday,symbol,ROUND(SUM(CASE WHEN transaction_type = 'deposit' THEN flow_usd ELSE 0 END) / 1e6, 2) AS deposits_usd_m,ROUND(SUM(CASE WHEN transaction_type IN ('withdrawal','deposit_liquidation') THEN flow_usd ELSE 0 END) / 1e6, 2) AS outflows_usd_m,ROUND(SUM(CASEWHEN transaction_type = 'deposit' THEN flow_usdWHEN transaction_type IN ('withdrawal','deposit_liquidation') THEN -flow_usdELSE 0END) / 1e6, 2) AS net_flow_usd_mFROM flowsGROUP BY 1, 2ORDER BY 1 DESC, net_flow_usd_m DESC