Skip to main content
     ░█████╗░███████╗██████╗░███████╗██████╗░██████╗░██╗░░░██╗░██████╗
     ██╔══██╗██╔════╝██╔══██╗██╔════╝██╔══██╗██╔══██╗██║░░░██║██╔════╝
     ██║░░╚═╝█████╗░░██████╔╝█████╗░░██████╦╝██████╔╝██║░░░██║╚█████╗░
     ██║░░██╗██╔══╝░░██╔══██╗██╔══╝░░██╔══██╗██╔══██╗██║░░░██║░╚═══██╗
     ╚█████╔╝███████╗██║░░██║███████╗██████╦╝██║░░██║╚██████╔╝██████╔╝
     ░╚════╝░╚══════╝╚═╝░░╚═╝╚══════╝╚═════╝░╚═╝░░╚═╝░╚═════╝░╚═════╝░

     ─────╮    ╭──╮         ╭──╮    ╭──╮         ╭──╮    ╭─────
          │    │  │         │  │    │  │         │  │    │
     ─────╯────╯  ╰─────────╯  ╰────╯  ╰─────────╯  ╰────╯─────

              ██████╗░██╗░░░██╗██╗░░░░░░██████╗███████╗
              ██╔══██╗██║░░░██║██║░░░░░██╔════╝██╔════╝
              ██████╔╝██║░░░██║██║░░░░░╚█████╗░█████╗░░
              ██╔═══╝░██║░░░██║██║░░░░░░╚═══██╗██╔══╝░░
              ██║░░░░░╚██████╔╝███████╗██████╔╝███████╗
              ╚═╝░░░░░░╚═════╝░╚══════╝╚═════╝░╚══════╝

          crypto intelligence for AI agents · x402 micropayments

LangChain Cerebrus Pulse

LangChain tools for Cerebrus Pulse — real-time crypto intelligence for AI agents. 50+ Hyperliquid perpetuals, paid per call in USDC over x402.

Install

pip install langchain-cerebrus-pulse          # tools; paid ones report the price instead of paying
pip install "langchain-cerebrus-pulse[pay]"   # + automatic payment in USDC on Base
pip install "langchain-cerebrus-pulse[svm]"   # + automatic payment in USDC on Solana too

Requires langchain-core 1.x and the cerebrus-pulse SDK 0.4.

Quick Start

Build one CerebrusPulse client and hand it to every tool. With a wallet key it pays for paid tools automatically, and all tools share its spend limits.

import os
from cerebrus_pulse import CerebrusPulse
from langchain_cerebrus_pulse import (
    CerebrusListCoinsTool,
    CerebrusPulseTool,
    CerebrusSentimentTool,
    CerebrusFundingTool,
    CerebrusBundleTool,
    CerebrusScreenerTool,
    CerebrusOITool,
    CerebrusSpreadTool,
    CerebrusCorrelationTool,
    CerebrusLiquidationsTool,
    CerebrusStressTool,
    CerebrusCexDexTool,
    CerebrusBasisTool,
    CerebrusDepegTool,
)

# A dedicated, low-balance Base wallet holding a little USDC. Omit wallet_key
# and paid tools return the API's price and payee instead of data.
client = CerebrusPulse(
    wallet_key=os.environ["CEREBRUS_WALLET_KEY"],
    max_payment_usd="0.10",  # most one call may cost
    max_spend_usd="1.00",    # most this client may spend in total
)

tools = [
    tool(client=client)
    for tool in (
        CerebrusListCoinsTool, CerebrusPulseTool, CerebrusScreenerTool,
        CerebrusLiquidationsTool, CerebrusStressTool, CerebrusCexDexTool,
        CerebrusBasisTool, CerebrusDepegTool, CerebrusSentimentTool,
        CerebrusFundingTool, CerebrusOITool, CerebrusSpreadTool,
        CerebrusCorrelationTool, CerebrusBundleTool,
    )
]

The spend limits also read CEREBRUS_MAX_PAYMENT_USD, CEREBRUS_MAX_SPEND_USD and CEREBRUS_ALLOWED_PAYTO; payments only go to the API's published payee. See the SDK README for Solana and the full list.

With a LangChain Agent

from langchain.agents import create_agent

agent = create_agent(
    "openai:gpt-4o",  # any chat model that supports tool calling
    tools=tools,
    system_prompt="You are a crypto analyst with access to real-time Hyperliquid data via Cerebrus Pulse.",
)

result = agent.invoke({
    "messages": [
        {"role": "user", "content": "Where are the BTC liquidation clusters and what's the cascade risk?"}
    ]
})
print(result["messages"][-1].content)
print(f"Spent: ${client.spent_usd}")

When a paid tool cannot pay, it returns JSON the model can read: {"error": ..., "payment_required": true, "price_usd": "0.03", "payment_terms": [...]}. A refusal by the spend limits adds a reason, and nothing is signed.

Available Tools (14)

Prices are indicative, per call, in USDC, as the API published them on 2026-09-24. The API sets the price: its 402 terms say what is charged, and the client's max_payment_usd caps what is paid.

Tool Price Description
CerebrusListCoinsTool Free List 50+ available Hyperliquid perpetuals
CerebrusPulseTool $0.025 Technical analysis (RSI, EMAs, Bollinger, trend, regime, confluence)
CerebrusScreenerTool $0.06 Scan 50+ coins: signals, trends, vol regime, confluence
CerebrusLiquidationsTool $0.03 Liquidation heatmap by leverage tier with cascade risk
CerebrusStressTool $0.02 Cross-chain market stress index (8 chains)
CerebrusCexDexTool $0.02 CEX-DEX price divergence (Coinbase vs Chainlink/Uniswap)
CerebrusBasisTool $0.02 Chainlink basis: HL perp oracle vs Chainlink spot
CerebrusDepegTool $0.01 USDC collateral health via Chainlink oracle
CerebrusSentimentTool $0.01 Market sentiment as a bucketed label (very_bearish … very_bullish)
CerebrusFundingTool $0.01 Funding rate: current, average, min, max, annualized
CerebrusOITool $0.015 Open interest: delta, percentile, trend, divergence
CerebrusSpreadTool $0.015 Spread: slippage estimates at various sizes, liquidity score
CerebrusCorrelationTool $0.05 BTC-alt correlation matrix with regime classification
CerebrusBundleTool $0.05 Pulse, sentiment and funding in one call

Disclaimer

Cerebrus Pulse provides market data and technical indicators for informational purposes only. Nothing provided by these tools or the underlying API constitutes financial advice, investment advice, or trading advice. AI-generated analysis, signals, and sentiment labels are algorithmic outputs — not recommendations to buy, sell, or hold any asset. Cryptocurrency trading involves substantial risk of loss. You are solely responsible for your own trading decisions.

License

MIT

Release files for langchain-cerebrus-pulse 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for langchain-cerebrus-pulse 0.4.0
File Size Uploaded
langchain_cerebrus_pulse-0.4.0.tar.gz 12.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for langchain-cerebrus-pulse 0.4.0
File Interpreter ABI Platform
langchain_cerebrus_pulse-0.4.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.6 kB

Release files / langchain_cerebrus_pulse-0.4.0.tar.gz

Download URL langchain_cerebrus_pulse-0.4.0.tar.gz
Size 12.6 kB
Tags Source
SHA-256 checksum
How to use checksums
42bf64944038a5b7542512254aaf2711fdb4ac66db649145ea7579be9557a2c6
BLAKE2b-256 checksum
How to use checksums
00050cfc88502c38ae1564fd9b6c05e258fb498113de778fa3780a21939bee49
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 26, 2026.

Transparency log

Release files / langchain_cerebrus_pulse-0.4.0-py3-none-any.whl

Download URL langchain_cerebrus_pulse-0.4.0-py3-none-any.whl
Size 8.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f8fce479daa14539b959f590a6af1df450a1eb1da4904c882b6c14b8db539cb6
BLAKE2b-256 checksum
How to use checksums
cafc4996985bbe87cf4ceb5fcf0e201cdc03de17d8c7ddcbf964f0dc6033695e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 26, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page