Agentic Workflows for Crypto Research

insights.glassnodePublicado em 2026-04-01Última atualização em 2026-04-01

Resumo

AI coding agents are transforming crypto research by automating data analysis through natural language. This article demonstrates using an agent (like Claude Code) with the Glassnode CLI to test a hypothesis: whether extreme Bitcoin exchange inflows predict 7-day price drawdowns. The agent autonomously discovers metrics, fetches data, performs statistical analysis, and generates insights. Results show a moderate association—spike days saw ~1.9% greater drawdowns—though the sample is small. A follow-up prompt produces visualizations for validation. The workflow allows rapid iteration and is applicable to various research questions using Glassnode data, requiring only an API key and an AI agent.

AI coding agents are changing the way analysts and researchers interact with data. Instead of writing scripts line by line, you provide a hypothesis or research question to an AI agent and – it writes the code, fetches the data, runs the analysis, and returns results.

In this article we present a step-by-step real-world example: Asking an AI agent to download data via the Glassnode CLI, run a statistical analysis, and generate publication-ready charts, all from natural-language prompts.

What you will need

  1. Access to an AI agent

We use Claude Code in this walkthrough, but any agent able to execute Python and shell commands will work, including ChatGPT's Codex, Cursor, Github Copilot, Google Gemini CLI, OpenClaw, or similar tools.

  1. The Glassnode CLI (gn)

A command-line interface for the Glassnode API. Install it and configure your API key by following the Glassnode CLI docs. An API key is required.

The prompt

We will evaluate the following hypothesis: Extreme BTC exchange inflow events are predictive of 7-day forward drawdowns. To do that, we will instruct Claude Code using the following prompt:

Using the Glassnode CLI, download BTC daily exchange inflows and closing price for the last year. Analyze whether inflow spikes (days with inflows > 2 standard deviations above the mean) predict drawdowns in the following 7 days. Show me a summary with statistics and results.

That's it. One sentence describing the question, and another sentence defining the methodology. The agent takes it from there.

A simple prompt for the AI agent

What the agent does

Behind the scenes, the agent executes a sequence of steps:

  1. Discovers the right metrics by running gn metric list and gn metric describe to find the correct metric paths and valid parameters.
  2. Downloads the data via gn metric get, saving CSV files for both exchange inflows (transactions/transfers_volume_to_exchanges_sum) and closing price (market/price_usd_close).
  3. Writes and runs a Python analysis that computes the spike threshold, identifies spike days, calculates forward 7-day max drawdowns, and compares spike days to normal days.

The agent comes back with a readable summary:

While this is just an illustrative example, our experiment does reveal a moderate association between exchange inflow spikes and subsequent drawdowns. Spike days see roughly 1.9 percentage points more drawdown on average. That said, with only 10 spike days in the sample and the effect concentrated in two volatile periods, the signal is suggestive rather than statistically robust. A rigorous backtest would need to account for overlapping windows, control for volatility regimes, use point-in-time data, and validate out-of-sample.

Visualizing the results

Visualizing the data is a good way to validate whether the numbers hold up. In this process, a simple follow-up prompt is enough:

Create a visualization that shows the data as a timeseries.

From here, you can keep iterating: adjust the chart, refine the analysis, or take the research in a different direction, all through natural language conversation.

The AI-generated visualisation of Glassnode data

Get started with AI Crypto Research on Glassnode Data

The Glassnode CLI requires an API key, available to Glassnode Professional subscribers.

  1. Install the Glassnode CLI and configure your API key. See documentation
  2. Open your preferred AI coding agent (Claude Code, Codex, Cursor, Gemini CLI, OpenClaw, etc.)
  3. Start prompting. Try questions such as:
    • "Download ETH staking deposits for the last 6 months and plot the trend"
    • "Compare BTC and ETH exchange netflows over the last 90 days"
    • "Find which metric has the highest correlation with BTC 30-day returns"

The Glassnode CLI allows agents to discover and retrieve metric data without requiring manual API lookup or writing boilerplate code. Combined with an AI coding agent, the Glassnode CLI turns a research question into results in minutes.

Perguntas relacionadas

QWhat is the main advantage of using AI coding agents for crypto research as described in the article?

AThe main advantage is that AI coding agents automate the entire research workflow, allowing analysts to provide a natural-language hypothesis or research question, and the agent handles writing the code, fetching data, running analysis, and returning results, significantly speeding up the process.

QWhich specific AI agent is used in the walkthrough example for analyzing BTC exchange inflows?

AThe walkthrough uses Claude Code, but it notes that any AI agent capable of executing Python and shell commands, such as ChatGPT's Codex, Cursor, GitHub Copilot, Google Gemini CLI, or OpenClaw, would work.

QWhat hypothesis is tested in the example prompt given to the AI agent?

AThe hypothesis tested is: 'Extreme BTC exchange inflow events (days with inflows > 2 standard deviations above the mean) are predictive of 7-day forward drawdowns.'

QWhat are the key steps the AI agent performs behind the scenes after receiving the prompt?

AThe agent discovers the right metrics using Glassnode CLI commands, downloads the data (exchange inflows and closing price), writes and runs a Python analysis to compute spike thresholds and drawdowns, and returns a statistical comparison and summary.

QWhat is required to use the Glassnode CLI for AI-assisted research as mentioned in the article?

ATo use the Glassnode CLI, you need an API key, which is available to Glassnode Professional subscribers, and you must install and configure the CLI tool following the documentation.

Leituras Relacionadas

a16z Crypto Partner: Cash Flow is the Moat

Cash Flow as the Moat: A Playbook for Crypto Founders Historically, the most enduring businesses have been built by positioning themselves within the "flow of funds"—facilitating the creation and transfer of value in a network and extracting a portion of it. Cryptocurrency is the first modern technology natively built for this purpose. For startups, failing to architect products and businesses to leverage these principles means missing a major opportunity. Blockchains are inherently network businesses. Each transaction settles on a shared ledger, and every new participant strengthens the underlying network for all. Well-designed network tokens amplify this by aligning users, developers, and validators around growing the network, with value flowing back to contributors in a transparent feedback loop. This model is not new; companies from railroads and Standard Oil to Google, Meta, and AWS have thrived by inserting themselves into critical flows of value (goods, attention, compute). Financial markets make it even clearer: firms like Visa and major market makers generate immense revenue not by predicting markets but by being in the path of transactions. The combination of fund flow and network effects creates one of the most durable business structures. The high margins in traditional finance (payments, custody, lending, FX) represent prime targets. Crypto founders have the opportunity to build the next version—programmable, instant, global, and natively in the flow of funds. The frontier extends beyond finance to areas like computing/GPUs, AI training data, energy, robotics, and space—markets without entrenched intermediaries, ripe for building new, efficient value rails on programmable infrastructure. Founders should ask: Are you in the flow of funds today? Does your revenue scale 10x with the value of activity on your platform? Where in your target market are profit margins highest relative to value created? The opportunity is clear: embed your startup into the new flows of value and let the network effects accumulate.

marsbitHá 4m

a16z Crypto Partner: Cash Flow is the Moat

marsbitHá 4m

a16z Crypto Partner: Cash Flow is the Moat

Title: a16z Crypto Partner: Cash Flow Is the Moat Summary: Historically, many of the best businesses were built by positioning themselves within the "flow of funds"—facilitating the creation and transfer of value within a network and taking a cut. The more value flows through, the larger the business grows. Cryptocurrency is the first modern technology natively built for this purpose. If a startup hasn't architected its product and business to benefit from these principles, it's missing a major opportunity. Thanks to stablecoins, capital and value now move at internet speed—globally settled, 24/7, with end-to-end programmability. Blockchains are inherently network businesses. Each transaction settles on a shared ledger, and every new participant strengthens the same underlying network. Network tokens amplify this effect. A well-designed token aligns all participants—users, developers, suppliers, validators, the protocol—around a single goal: growing the network. Participants are paid proportionally to their contributions, creating a transparent feedback loop between value flowing in the system and value accumulating to those building it. This model isn't new; crypto simply makes it more accessible and scalable for startups. The pattern is consistent: find where value flows and position yourself in the middle. Examples range from railroads (earning from freight) and Standard Oil to Google, Meta, and AWS (earning from attention, commerce, and compute flows, respectively). Financial markets make this even clearer. Visa's net income stems from its position in the $15.7 trillion payment flow. Major market makers profit from being in the flow of every order. This combination of fund flow and network effects creates one of the most durable business structures. Jeff Bezos's adage "your margin is my opportunity" applies perfectly here, especially to traditional finance—a massive pool of profit extraction. Crypto founders have the chance to build the next version: programmable, instant, global, and natively in the flow of funds. The frontier extends beyond finance to areas like compute/GPUs, memory chips, AI training data, energy, robotics, space, and rare earth metals—all domains where global value can flow at unprecedented scale on new, programmable infrastructure. Founders should ask: Are you currently in the flow of funds? Does your revenue scale 10x if the value of activity on your product grows 10x? Where in your target market is profit extraction highest relative to value created? The opportunity is there. Seize it, integrate into the new flow, and let the network effects accumulate.

链捕手Há 10m

a16z Crypto Partner: Cash Flow is the Moat

链捕手Há 10m

RWA First Stock's Major Acquisition: Why Buy a 'Traditional' Mortgage Company?

On June 10th, Figure Technology Solutions (Nasdaq: FIGR), a blockchain-native capital markets firm, announced a $717 million acquisition of Kiavi, a leading non-bank lender for residential real estate investors. The deal involves Figure acquiring Kiavi's technology and operations for approximately $538 million, while forming a joint venture with alternative asset manager Sixth Street to purchase Kiavi's existing loan portfolio. Sixth Street also provided a $3 billion forward purchase commitment. This acquisition marks a strategic shift for Figure, known as the "RWA (Real World Asset) first stock," allowing it to expand significantly into the larger market of first-lien mortgages. Kiavi specializes in non-qualified mortgage (Non-QM) loans, such as short-term fix-and-flip (RTL) and rental property (DSCR) loans—a segment traditionally underserved by major banks. The move is expected to increase Figure's first-lien loan origination to over $7 billion annually, aiming for these to constitute about 40% of its business by 2027. Both companies leverage AI for underwriting: Kiavi uses proprietary models to value renovated properties and automate document processing, dominating the fix-and-flip lending space. Figure plans to integrate these assets onto its blockchain platform, Provenance, using its new 'Adaptor' product to standardize and tokenize the loans for institutional investors on its Democratized Prime marketplace. While the integration poses challenges—including merging different asset types, interest rate sensitivity of Kiavi's loans, and post-IPO execution risks—Figure projects the deal to be accretive to earnings with a cash payback period under four years. The transaction is seen as a major step in scaling blockchain-based capital markets, moving RWA tokenization from concept validation toward large-scale operation.

Foresight NewsHá 37m

RWA First Stock's Major Acquisition: Why Buy a 'Traditional' Mortgage Company?

Foresight NewsHá 37m

Trading

Spot
Futuros
活动图片