lookup_dataset
Retrieve detailed dataset information including required parameters, schema, and example queries to ensure correct usage before querying. Essential for datasets like 'balances' that need specific inputs such as 'address'.
Instructions
Look up a specific dataset and return detailed information about it. IMPORTANT: Always use this
function before querying a new dataset to understand its required parameters and schema.
The returned information includes:
1. Required parameters for the dataset (IMPORTANT for datasets like 'balances' that need an address)
2. Schema details showing available columns and data types
3. Example queries for the dataset
When the dataset requires specific parameters like 'address' (for 'balances'),
ALWAYS use the 'contract' parameter in query_dataset() to pass these values.
Example:
For 'balances' dataset, lookup_dataset('balances') will show it requires an 'address' parameter.
You should then query it using:
query_dataset('balances', blocks='1000:1010', contract='0x1234...')
Args:
name: The name of the dataset to look up
sample_start_block: Optional start block for sample data (integer)
sample_end_block: Optional end block for sample data (integer)
use_latest_sample: If True, use the latest block for sample data
sample_blocks_from_latest: Number of blocks before the latest to include in sample
Returns:
Detailed information about the dataset including schema and available fields
Input Schema
Name | Required | Description | Default |
---|---|---|---|
name | Yes | ||
sample_blocks_from_latest | No | ||
sample_end_block | No | ||
sample_start_block | No | ||
use_latest_sample | No |
Input Schema (JSON Schema)
{
"properties": {
"name": {
"title": "Name",
"type": "string"
},
"sample_blocks_from_latest": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Sample Blocks From Latest"
},
"sample_end_block": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Sample End Block"
},
"sample_start_block": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Sample Start Block"
},
"use_latest_sample": {
"default": false,
"title": "Use Latest Sample",
"type": "boolean"
}
},
"required": [
"name"
],
"title": "lookup_datasetArguments",
"type": "object"
}