← Back to home

Blocksight

Blocksight is an AI-powered analytics platform for Web3 communities.

Problem Statement

Blocksight is a tool for DAOs and Web3 projects that need to better understand their token holders and community members. While many blockchain tools focus on trading and finance, Blocksight provides actionable insights into community behaviour. It transforms raw on-chain data into a comprehensive analytics dashboard. Key features include a proprietary "Activity Index" to score wallet engagement, a "Token Concentration Analysis" using the Gini Coefficient to show wealth distribution, in-depth transaction pattern analysis, and a full suite of NFT analytics including adoption metrics, spam filtering, and collection diversity. The platform also includes a Natural Language Query interface where users can ask questions in plain English, which are then converted to SQL queries to provide precise, data-backed answers

Solution

Blocksight operates through a multi-stage process that begins with user input on the frontend, fetches raw data via a backend service, performs complex analysis directly in the browser, and leverages a separate AI service for natural language queries.The process begins on the 'Deep Dive Analytics' page, as seen inapps/web/app/analytics/page.tsx, where a user provides a list of Ethereum addresses by either pasting them into a textarea or uploading a CSV file. The frontend performs an initial client-side validation using theethers.isAddressfunction. Upon clicking 'Start Fetching,' the application navigates to the/data-fetchingpage, passing the addresses and selected network as URL parameters. This page then initiates parallel API calls to the Python FastAPI backend for each address. Each call to the/api/v1/wallet/{address}/fullendpoint, defined inapps/service/api/routes/wallet_routes.py, triggers thewallet_service, which uses the Alchemy SDK to retrieve comprehensive on-chain data, including token balances, asset transfers, and NFT holdings. While this happens, the frontend displays individual progress bars for each wallet, updating the UI to show which are loading, completed, or have encountered an error.Once all the raw data is returned to the frontend, it is stored in a React Context via theResultsProvider. The dashboard page then performs a series of complex, in-browser computations to generate insights. This includes calculating a proprietary Activity Index score for each wallet using thecalculateActivityIndexfunction indataAggregation.ts, which weighs recent transactions more heavily. ThetransactionAnalysis.tsmodule aggregates raw transactions to build timelines, analyze patterns like incoming versus outgoing volume, and estimate gas spending. For multi-wallet analysis, thetokenDistribution.tsmodule computes advanced economic metrics like the Gini Coefficient and Herfindahl-Hirschman Index to measure wealth concentration. Finally, thenftAnalysis.tsmodule processes NFT data to generate adoption metrics, filter spam, and analyze collection diversity.For direct inquiries, Blocksight offers an AI-powered Natural Language Query feature. On the 'AI' tab, a user types a question into theQueryInterface.tsxcomponent. This question is sent to the/api/v1/queryendpoint on the FastAPI backend. There, thenl_query_service.pyuses LangChain and the Google Gemini model to translate the plain English question into a valid PostgreSQL query, using the database schema for context. This SQL query is then executed against our indexed blockchain database. The raw results are sent back to the Gemini model, which synthesizes the data into a clear, human-readable answer. The backend returns the original question, the generated SQL, the raw data, and the final natural language answer, all of which are displayed to the user.

Hackathon

ETHOnline 2025

2025

Contributors