IQ GPT

IQ GPT is an AI-powered assistant for blockchain knowledge developed by IQ.wiki, the largest blockchain encyclopedia.

IQ GPT was launched in 2023 by IQ.wiki to help users access real-time and reliable crypto information from a wide range of sources. It caters to various use cases, including learning, development, and trading activities. IQ GPT streamlines research processes, filters out irrelevant data, and offers contextually specific content for users seeking accurate and up-to-date information in the blockchain domain.

IQ GPT is powered by the IQ token and pulls data from various sources such as IQ.wiki's extensive database, DeFiLlama, Frax Docs, Binance Academy, DeFi Protocol Documentations, The Associated Press News, CoinGecko, Flywheel DeFi, BlockBeats, InvestHK and CoinNess. On October 12, 2023, the BrainDAO team introduced IQ GPT chat functionalities. The AI assistant was enhanced with the ability to conduct conversations, allowing for interactive dialogues with users, including asking follow-up questions. A new chat history feature was also added, enabling users to organize their interactions by creating distinct categories such as trading and researching. In late 2023, the BrainDAO team introduced the IQ GPT Chat, designed to support Telegram and Discord communities involved in cryptocurrency, DeFi, NFTs, and related topics. According to IQ v3, released on November 1, 2023, the team's vision is to build a version of IQ GPT Chat for dapps and websites like decentralized exchanges, DeFi applications, cryptocurrency projects, NFT projects, data platforms, and more.

Overview of IQ GPT Integrations

  1. IQ.wiki - IQ.wiki, formerly known as Everipedia, is the largest blockchain and cryptocurrency encyclopedia globally. IQ GPT integrates IQ.wiki's extensive database to provide high-quality responses to millions of potential prompts about crypto and blockchain-related topics. Example prompts:

"Who created Cardano?" "What NFT-based games have Yuga Labs released?"

  1. CoinGecko - CoinGecko is a cryptocurrency data aggregation and tracking website that offers a comprehensive overview of digital currencies and market analytics. IQ GPT utilizes CoinGecko's premium market data APIs to provide up-to-date and accurate information about cryptocurrencies, NFT projects, and exchanges. Example prompts: "What is the current price of Ethereum?" "Create a list of the tokens that saw the greatest increase in price this year with over $100 million market cap"

  2. Flywheel DeFi - Flywheel DeFi is a platform that focuses on creating high-quality DeFi content with a particular emphasis on Frax Finance. IQ GPT pulls reliable source data from Flywheel DeFi's articles revolving around DeFi projects. Example prompts: "What is frax?" "What is barbell investment theory?"

  3. InvestHK - InvestHK (Invest Hong Kong) is the department of the Hong Kong SAR Government responsible for Foreign Direct Investment. IQ GPT leverages InvestHK's data to provide information and support for overseas businesses looking to set up and expand in Hong Kong. Example prompts: "What did Phillips Auctioneers Ltd announced?" "What is the summary of seminar conducted by ​Invest Hong Kong (InvestHK) and Xinjiang government?"

  4. CoinNess - CoinNess is a crypto and blockchain information platform that delivers real-time coverage and insights into the crypto and blockchain worlds. IQ GPT uses CoinNess data to provide users with instant and comprehensive information about cryptocurrency markets and events. Example prompts: "What is Viver?" "What did Puzzle Monsters win?"

  5. DeFiLlama - DefiLlama is an aggregator of Total Value Locked (TVL) in the decentralized finance (DeFi) field. Its data is open-source and overseen by a team of contributors representing numerous protocols. DeFi Llama offers data on cryptocurrencies, encompassing current price levels, along with Total Value Locked (TVL) information for various DeFi sectors such as decentralized exchanges (DEXs), lending protocols, yield farming operations, staking pools, DeFi insurance, and other related products.

Example prompts:

"Which protocol has the highest TVL 7 days change ?"

"List 5 protocols with highest 7 day changes in a table"

"Total Deposits on Polygon PoS Bridge"

  1. Etherscan - Etherscan plugin is basically blockchain explorer which helps to get wallets balance, transactions, details about the blocks in blockchain, details about contracts, address logs, also information about gas data. Etc

example prompts:

"What is the contract ABI for Tether?"

"What block was mined yesterday at 2:30pm?"

Technical Background

To facilitate the answer-generation process, we maintain a map of tools that are passed to the agent. This dynamic tool management allows us to select tools based on the user's preferences and debug options efficiently. We basically have 2 major tools Vector Query tool and Coingecko Tool. And langchain's calculator tool.

Vector Query Tool

Vector Query Tool enables users to retrieve answers from indexed partner sources. This tool plays a crucial role in providing contextually relevant information to users.

Goals for this tool

  1. Top 5 Results: The Vector Query Tool is designed to accept user prompts and return the top 5 results from indexed sources. These results include the source name and source URL.

  2. DebugOptions Filtering: It selectively returns results only from sources that align with the user's specified debug options.

How it works

  1. User Prompt: The tool begins by taking in a user prompt.

  2. Source Selection: It searches the vector database, considering the user's debug options, to retrieve data from selected sources.

  3. Top 5 Results: The tool compiles the top 5 results and passes them to the agent as tool output, contributing to the final answer generation process.

Coingecko Tool

Coingecko Tool is instrumental in answering crypto market-related prompts based on real-time data. This tool provides users with up-to-date information about cryptocurrency markets.

Goals for this tool

  1. Endpoint Selection: The Coingecko Tool is designed to understand user questions and select the most appropriate endpoint for answering the prompt. It constructs valid Coingecko API endpoints based on the user's input.

  2. Data Retrieval: It can call various Coingecko API endpoints to gather relevant data and return it as the final response.

  3. Data Filtering: To prevent max token limit errors from LLM, the tool ensures that it only returns the necessary data required for the answer, even when dealing with large datasets.

How it works

  1. Endpoint Selection System: This system is responsible for choosing the best endpoint to answer the prompts based on tool input. It narrows down the options from around 30 endpoints to a more manageable number.

  2. Dynamic Functions Generation: To support different sets of 10 endpoints and provide input parameters for the selected endpoint, this system dynamically generates functions JSON, ensuring flexibility in endpoint selection.

  3. Enums System: For input parameters that require selection from a list of values, the Enums System ensures that LLM selects values correctly from the list, reducing the chances of errors.

  4. Data Filtering System: This system filters the data retrieved from Coingecko API to return only the essential information, adapting to the specific requirements of different endpoints.

  5. Function Wrapping System: Some endpoints require complex data filtering, and the Function Wrapping System wraps these endpoints with functions that include filtering in the final endpoint selection step. This approach streamlines the process for challenging data sets.

Endpoint and example prompts

We use x endpoints provided by coingecko api. The following are the endpoints(paths) and example prompt which the endpoint is suitable and selected to answer the prompt

  1. /simple/price : This endpoint allows you to retrieve the current price of one or more cryptocurrencies in a specified target currency from Coingecko. Example prompts - "What is price of IQ Token"

  2. /simple/token_price/ : This endpoint enables you to fetch the current price of a specific token with a contract address Example prompts - "what is price of token with contract address 0x579CEa1889991f68aCc35Ff5c3dd0621fF29b0C9"

  3. /simple/supported_vs_currencies : This endpoint enables you to get the supported currencies in IQ GPT Example prompts - "What are the supported currencies in IQ GPT?"

  4. /coins/list/new : This endpoint enables you to get list of newly added coins Example prompts - "List newly added coins to coingecko"

  5. /coins/markets : This endpoint enables you to get all coins market data. But practically using this endpoint is not possible because the response schema has lot of fields which LLM cant handle and throws token max error

  6. /coins/{id} : This endpoint enables you to get detailed information about a specific cryptocurrency based on its unique id. Example prompts : "Give me details information about IQ Token" (Remember to set the sources to only Coingecko in debug panel since remaining sources will have information about cryptocurrency but that is static)

  7. /coins/{id}/history : This endpoint enables you to get the price of cryptocurrency at a point of date in history Example prompts : "What is price of IQ Token on 28 July 2023"

  8. /coins/{id}/contract/{contract_address} : This endpoint enables you to get the details about the contract address Example prompts : "contract details for contract address 0x579CEa1889991f68aCc35Ff5c3dd0621fF29b0C9"

  9. /coins/{id}/ohlc : This endpoint enables you to get the open, high, low, close of any listed cryptocurrency Example prompts : "Give ohlc of IQ Token"

  10. /asset_platforms : This endpoints get you all the asset platforms listed on coingecko Example prompts : "List all the asset platforms in coingecko"

  11. /coins/categories : This endpoint gives all the categories of the coins listed in coingecko Example prompts : "List all the categories for the coins listed in coingecko"

  12. /exchanges : This endpoints gives you all the listed endpoints in coingecko Example prompts : "Give all the exchanges listed in coingecko"

  13. /exchanges/{id}/volume_chart: This endpoint allows you to retrieve volume chart data (in BTC) for a given exchange. Example prompts : "Give me volume chart of binance for past 7 days" (But practically using this endpoint is not possible because the response schema has lot of fields which LLM cant handle and throws token max error)

  14. /search/trending : endpoint provides a list of the top trending search coins on CoinGecko in the last 24 hours Example prompts : "What are trending coins on coingecko"

  15. /companies/public_treasury/{coin_id} : This endpoint allows you to retrieve data about public companie's Bitcoin or Ethereum holdings Example prompts : "How much public companies are holding in ethereum?"

Function Wrapper/Custom Endpoints with example prompts

  1. coin_market_chart : This function wrapper enables you to fetch historical market prices and data for a specific cryptocurrency Example prompts : "What is the average price of bitcoin between 28 july 2023 and 29 August 2023"

  2. get_multi_exchange_prices_for_coin : This function wrapper helps you to fetch prices from an exchange for multiple coin ids Example prompts : "What is price of ethereum in binance and upbit ? What is the price difference between both exchanges?"

  3. get_volume_by_range_exchange : This function wrapper helps you to get the trading volume of exchange between given time range(upto 31 days) Example prompts : "List the trading volume of Binance between 28-07-203 to 3-08-2023"

Etherscan Tool

The Etherscan Tool serves as a comprehensive gateway to blockchain data, specifically for the Ethereum network. By leveraging the capabilities of the Etherscan API, this tool facilitates access to a wide array of information related to Ethereum blockchain activities. This includes, but is not limited to, wallet balances, transaction histories, block details, smart contract specifications, address logs, and gas usage data. It is an invaluable resource for users seeking detailed insights into Ethereum blockchain operations.

Goals for this tool

  1. Endpoint Selection: The primary objective of the Etherscan Tool is to interpret user inquiries accurately and to identify the most suitable API endpoint to fetch the requested data. It dynamically constructs valid Etherscan API endpoint URLs based on user inputs, ensuring a seamless and effective data retrieval process.

  2. Data Retrieval: Through the invocation of various Etherscan API endpoints, this tool is adept at collecting essential blockchain-related information. It can efficiently pull data pertaining to specific addresses, transactions, blocks, contracts, and other relevant blockchain entities.

  3. Data Filtering: Given the vast amount of data available on the blockchain, the Etherscan Tool employs sophisticated data filtering mechanisms to streamline the response. It is designed to avoid overwhelming users or hitting maximum token limits by returning only the data that is critical to the user's query, thus optimizing both performance and usability.

This workflow of this tool is exactly similar to that of Coingecko tool mentioned above

Function Wrappers with example prompts

  1. get_address_balance - This endpoint allows you to get the balance of a wallet address or multiple wallet addresses.

Example prompts: "What is the balance of 0xc890f24BC128815cF60A0f44a0dE4aDbE3CE5d66?" "What is the balance of 0xc890f24BC128815cF60A0f44a0dE4aDbE3CE5d66 and 0x7a5142eF66F0A4f5fE7b7635c8f85716f947c453?"

  1. get_transactions - This endpoint allows you to get a list of transactions via the Etherscan Ethereum blockchain explorer

Example prompts: ”What are the transactions done with 0xc890f24BC128815cF60A0f44a0dE4aDbE3CE5d66?” "What are some internal transactions done on 0xc890f24BC128815cF60A0f44a0dE4aDbE3CE5d66?” “ What are the internal transactions between 13481773 and 13491773 ?” "What are the ERC20 Token transfer events on 0x4e83362442b8d1bec281594cea3050c8eb01311c?"

  1. get_mined_blocks - This endpoint allows you to get a list of blocks that were validated (mined) by an address

Example prompts: "What are the blocks mined by 0x9dd134d14d1e65f84b706d6f205cd5b1cd03a46b?"

  1. get_contract - This endpoint allows you to get data from a verified smart contract.

Example prompts: "What is the contract ABI for Tether?” ”What's the source code for 0x4c64e17009D04a5Fc281BF4B5E220Fa1b4D725E6 ?” "Who created the IQ contract and what was the hash?" "Who created the IQ, Aave and Frax contracts?"

  1. get_transaction_status - This endpoint allows you to to check the status code of a contract or transaction execution

Example prompts: "What is the status of this contract's execution 0x643167FB2Ea084D28A1Ad096B06A03BE61E6C640?"

  1. get_block_data - This endpoint allows you to to get data about a block.

Example prompts: "What are the block and uncle block rewards of 2165403?" "What's the time remaining till block 19275900 is mined?" "What block was mined yesterday at 2:30pm?" "What is the number of the most recent block on the ethereum blockchain?"

  1. get_address_logs - This endpoint allows you to get event logs on the blockchain to output as JSON.

Example prompts: "What are the event logs on 0xbd3531da5cf5857e7cfaa92426877b022e612cf8?"

  1. get_gas_data - This endpoint allows you to get data about gas prices and transaction confirmation on the Ethereum blockchain

Example prompts: "What's the current gas price?" "How much would it take to confirm a transaction given a gas fee of 2000000000 wei" "What's the current gas price I need for my transaction to get completed quickly ?"

  1. get_token_data - This endpoint allows you to get data about tokens on the Ethereum blockchain

Example prompts: "How much of this token 0x57d90b64a1a57749b0f932f1a3395792e12e7055 is in circulation?" "What is the balance for IQ token on this adress 0xaCa39B187352D9805DECEd6E73A3d72ABf86E7A0 ?"

  1. get_ether_data - This endpoint allows you to get data and statistics about Ether

Example prompts: "What is the total amount of Ethereum in circulation?" "How many ethereum nodes are there?"

Debank Tool

The Debank API provides a comprehensive suite of endpoints for accessing decentralized finance (DeFi) data across various blockchain ecosystems. Designed to offer deep insights into DeFi protocols, tokens, liquidity pools, user portfolios, and blockchain-specific information, it serves as an essential tool for developers, analysts, investors, and researchers in the DeFi space. With its extensive coverage, the Debank API facilitates a deeper understanding and analysis of the dynamic DeFi market.

Goals for this tool

  1. Endpoint Selection: The DebankTool is designed to understand user questions and select the most appropriate endpoint for answering the prompt. It constructs valid Debank API endpoints based on the user's input.

  2. Data Retrieval: It can call various Debank API endpoints to gather relevant data and return it as the final response.

  3. Data Filtering: To prevent max token limit errors from LLM, the tool ensures that it only returns the necessary data required for the answer, even when dealing with large datasets.

The workflow of the Debank tool is similar to that of the CoinGecko tool mentioned above.

Endpoint and example prompts

We use 34 endpoints provided by debank api. The following are the endpoints(paths) and example prompt which the endpoint is suitable and selected to answer the prompt.

  1. /chain: This endpoint allows you to fetch detailed information about a specific blockchain chain Example prompts: "Give a detailed information about the Ethereum chain?"

  2. chain/list: This endpoint provides a comprehensive list of all blockchain chains supported by the Debank API Example prompts: "Give a list of 5 chains on debank supported on blockchain"

  3. /protocol: This endpoint fetches detailed information for a specified DeFi protocol. Example prompts: "What is the total TVL of Compound protocol on Ethereum Chain?"

  4. /protocol/all_list: This endpoint allows fetching a comprehensive list of DeFi protocols available across one or more specified blockchain chains. It provides essential information about each protocol. Example prompts: "Give a mini list of protocols available on ethereum chain"

  5. /protocols/top_holders: This endpoint fetches a list of the top holders within a specified DeFi protocol, ranked by their holdings. Example prompts: "Give a list of the top holders available on ethereum chain"

  6. /pool: This endpoint provides detailed information about a specified liquidity pool. Example prompts: "Give detailed information about the liquidity pool with ID '0x00000000219ab540356cbb839cbe05303d7705fa' on Ethereum"

  7. /token: This endpoint fetches comprehensive details about a specified token. Example prompts: "What are the details of the token with contract address '0xcfeaead4947f0705a14ec42ac3d44129e1ef3ed5' on Ethereum"

  8. /token/list_by_ids: This endpoint provides detailed information for a list of tokens specified by their addresses, across a given chain. Example prompts: "Give me details about the token with id 0xdac17f958d2ee523a2206206994597c13d831ec7 on ethereum chain"

  9. /token/top_holders: This endpoint fetches the top holders of a specified token. Example prompts: "What is the address top holders of the ethereum token"

  10. /user/used_chain_list: This endpoint returns a list of blockchain chains that a user has interacted with. Example prompts: "What are the chains the user with the address 0xcfeaead4947f0705a14ec42ac3d44129e1ef3ed5 has interacted with"

  11. /user/chain_balance: This endpoint returns a list of blockchain chains that a user has interacted with. Example prompts: "What is the balance of the user with the address 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 in usd"

  12. /user/protocol: Returns detailed information about one user's positions within a specified protocol. Example prompts: "Give a detailed information of this user address 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on protocol bsc_bdollar"

  13. /user/complex_protocol_list:Fetches detailed information about a user's engagements across various protocols on a specified chain. Example prompts: "Give a detailed information of this user address 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the following protocols eth, bsc"

  14. /user/all_complex_protocol_list:Provides a comprehensive overview of a user's investments and positions across all supported chains and protocols. Example prompts: "Give a detailed information of this user address 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the following protocols eth, bsc"

  15. /user/simple_protocol_list:Returns a list of protocols along with the user's asset balances within them on a specified chain. Example prompts: "What's the balance of 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 in 5 protocols under ethereum chain"

  16. /user/all_simple_protocol_list:Fetches balances and positions for a user across all protocols and supported chains. Example prompts: "What's the balance of 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 in all protocols under ethereum chain"

  17. /user/token:Fetches the balance of a specified token held by a user. Example prompts: "What's the total balance of token with address 0xdac17f958d2ee523a2206206994597c13d831ec7 is held by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on ethereum chain"

  18. /user/token_list:Fetches the balance of a specified token held by a user. Example prompts: "List the tokens that are held by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on ethereum chain"

  19. /user/all_token_list:Returns a list of tokens held by the user on the specified chain. Example prompts: "List the tokens that are held by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on 5 different chain"

  20. /user/nft_list:Fetches a list of NFTs owned by the user on the specified chain. Example prompts: "List 5 nfts that 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 holds on eth chain"

  21. /user/all_nft_list:Provides an aggregate list of NFTs held by the user across all supported chains. Example prompts: "What nfts are held by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on eth chain"

  22. /user/history_list:Fetches a list of past transactions made by the user on a specified chain. Example prompts: "Provide a list of details of recent transactions made three days ago by the user 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the Ethereum chain."

  23. /user/all_history_list:Provides a comprehensive overview of a user's transaction history across all supported chains. Example prompts: "List all details of transactions made by the user 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the Ethereum chain."

  24. /user/token_authorized_list:Fetches a list of tokens for which the user has granted spending approvals on a specified chain. Example prompts: "List approved tokens by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the Ethereum chain."

  25. /user/nft_authorized_list:Provides details on NFTs for which the user has given spending permissions. Example prompts: "List authorized nfts by 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on the Ethereum chain."

  26. /user/total_balance:Calculates and returns the total USD value of a user's assets across all supported chains. Example prompts: "What's the balance of 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 in the following protocols eth, bsc, xdai"

  27. /user/chain_net_curve:Displays the changes in the total USD value of a user's assets on a specified chain over the past 24 hours. Example prompts: "What's the total asset in the last 24 hours for 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on etehereum chain"

  28. /user/total_net_curve: Provides a 24-hour snapshot of the total USD value of a user's assets across all supported chains. Example prompts: "What's the total asset in the last 24 hours for 0x5853ed4f26a3fcea565b3fbc698bb19cdf6deb85 on 5 chains"

  29. /collection/nft_list:This endpoint allows you to fetch a list of NFTs belonging to a specific collection by specifying the contract address of the NFT. Example prompts: "List 20 nfts under the collection for the contract address 0x495f947276749ce646f68ac8c248420045cb7b5e in ethereum chain"

  30. /wallet/gas_market:This endpoint fetches current gas prices for a specified blockchain chain, returning prices for different transaction speed levels such as slow, normal, and fast. Example prompts: "Current gas prices for Ethereum, including transaction speed?"

For more information on IQ GPT see the IQ GPT wiki page on IQ.wiki. For early access to IQ GPT, you need to maintain a HiIQ balance of 100,000 HiIQ. Your HiIQ balance is based on the amount of IQ you’ve staked in addition to the amount of time you’ve locked your IQ which naturally decreases over time. Therefore we recommend having over 100,000 HiIQ for example if you lock 100,000 IQ for 2 years you would have 200,000 HiIQ. It would take 2 years for your HiIQ balance to drop to 100,000 HiIQ allowing you to use IQ GPT for 2 years.

In addition to early access to IQ GPT, IQ stakers will also in the future have access to premium features. Stakers earn IQ tokens and have a say in governance with their voting power based on their HiIQ balance. To learn how to stake IQ check out the HiIQ guide. If you haven’t staked IQ you can sign up for the waitlist using this form.

Last updated