Updated 2023-03-15
    with bot_tx as (
    select
    from_address as address,
    date_trunc('minute', block_timestamp) as minute,
    count(tx_hash) as tx_count
    from gnosis.core.fact_transactions
    group by address, minute
    having tx_count > 2
    ),

    bots as (
    select
    concat('Bots') as category,
    count(distinct(address)) as wallets
    from bot_tx
    ),

    total as (
    select
    count(distinct(from_address)) as wallets
    from gnosis.core.fact_transactions
    ),

    regular as (
    select
    concat('Regular Wallets') as category,
    total.wallets - bots.wallets as wallets
    from total
    join bots
    )

    select *
    from regular
    union
    select *
    from bots
    Run a query to Download Data