CG

Web3 AI Chatbot & LLM

Updated May 29, 2026, 12:30 PM

Web3 AI Chatbot & LLM

Web3 AI Chatbot & LLM

A crypto-native large language model with live on-chain data, Nansen Smart Money insights, token analytics, and support for 33+ blockchains. This is the most versatile and cost-effective product in the ChainGPT suite.

Key Facts

EndpointPOST /chat/stream
Modelgeneral_assistant
Cost0.5 credits per request (1.0 with chat history enabled)
SDK@chaingpt/generalchat
Chains33+ supported blockchains
ResponseServer-Sent Events (streaming) or buffered

What It Does

  • Answers general crypto and blockchain questions with current data
  • Retrieves live on-chain information (balances, transactions, contract state)
  • Provides Nansen Smart Money tracking and wallet analytics
  • Delivers token analytics including price, volume, market cap, and holder distribution
  • Supports conversational context via chat history

Parameters

ParameterTypeRequiredDescription
modelstringYesMust be "general_assistant"
questionstringYesThe user's question or prompt
chatHistorystringNo"on" or "off" (string, not boolean). Enables conversational memory. Doubles cost to 1.0 credits. Default: "off"
sdkUniqueIdstringNoUnique session identifier for maintaining chat history across requests
useCustomContextbooleanNoEnable custom context injection
contextInjectionstringNoCustom context to inject into the prompt. Requires useCustomContext: true

Quick Start -- JavaScript

Install the SDK:

npm install @chaingpt/generalchat

Buffered Response

import { GeneralChat } from "@chaingpt/generalchat";

const client = new GeneralChat({
  apiKey: process.env.CHAINGPT_API_KEY,
});

const response = await client.createChatMessage({
  model: "general_assistant",
  question: "What is the current price of ETH and its 24h volume?",
  chatHistory: "off",
});

console.log(response.data.bot);

Streaming Response

import { GeneralChat } from "@chaingpt/generalchat";

const client = new GeneralChat({
  apiKey: process.env.CHAINGPT_API_KEY,
});

const stream = await client.createChatMessageStream({
  model: "general_assistant",
  question: "Explain how Uniswap V3 concentrated liquidity works",
  chatHistory: "off",
});

stream.on("data", (chunk) => {
  process.stdout.write(chunk.toString());
});

stream.on("end", () => {
  console.log("\n[Stream complete]");
});

With Chat History

const response = await client.createChatMessage({
  model: "general_assistant",
  question: "Now compare that to SushiSwap's approach",
  chatHistory: "on",
  sdkUniqueId: "session-abc-123",
});

Quick Start -- Python

pip install chaingpt

Buffered Response

from chaingpt.client import ChainGPTClient

client = ChainGPTClient(api_key="YOUR_API_KEY")

response = client.chat.create(
    model="general_assistant",
    question="What are the top 5 DeFi protocols by TVL?",
    chat_history="off",
)

print(response["data"]["bot"])

Streaming Response

from chaingpt.client import ChainGPTClient

client = ChainGPTClient(api_key="YOUR_API_KEY")

for chunk in client.chat.create_stream(
    model="general_assistant",
    question="Summarize today's major crypto market movements",
    chat_history="off",
):
    print(chunk, end="", flush=True)

Tips

  • Use chatHistory: "off" for one-shot questions to save credits.
  • Use sdkUniqueId to maintain separate conversation threads for different users or sessions.
  • Combine with the Crypto News product by injecting recent headlines via contextInjection for AI-analyzed market summaries.
  • The LLM already has access to live on-chain data -- you do not need to fetch and inject chain data manually.
View original source