Skip to main content
Glama

tealflow_get_dataset_info

Read-onlyIdempotent

Inspect dataset files to reveal columns, data types, row counts, and sample values without loading full data. Ideal for verifying structure and compatibility before building Teal applications.

Instructions

Get detailed information about a dataset file including columns, types, and row count.

This tool reads a dataset file (.rds or .csv) and returns comprehensive metadata about its structure without loading the entire dataset into memory. It's useful for understanding the contents of a dataset before using it in a Teal application.

IMPORTANT: This tool requires an absolute path to the dataset file. Relative paths will not work correctly due to MCP server/client working directory differences.

Args: file_path (str): Absolute path to the dataset file (.rds or .csv). Example: '/home/user/data/ADSL.Rds' or 'C:\Users\user\data\ADSL.csv'. include_sample_values (bool, optional): Whether to include sample values (first 5 unique values) for each column. Useful for understanding data content. Defaults to True. response_format (str, optional): Output format - 'markdown' for human-readable or 'json' for machine-readable. Defaults to 'markdown'.

Returns: str: Dataset information with columns, types, and metadata

Markdown format includes:
- File path and basic statistics (rows, columns, file size)
- Table of columns with names and types
- If include_sample_values=True: Detailed view with sample values for each column

JSON format includes:
- file_path: Path to the dataset
- row_count: Number of rows
- column_count: Number of columns
- file_size_bytes: File size in bytes
- columns: Array of column objects with name, type, and optional sample_values

Column Type Mapping: - For RDS files: R types (integer, numeric, character, logical, category, POSIXct) - For CSV files: Pandas-derived types (integer, numeric, character, logical, datetime) - category: R factors or categorical data - character: String/text data - integer: Whole numbers - numeric: Decimal numbers - logical: Boolean values - POSIXct/datetime: Date and time values

Examples: - Get basic info: file_path="/home/user/data/ADSL.Rds" - Get with samples: file_path="/home/user/data/ADSL.Rds", include_sample_values=True - Get JSON format: file_path="/home/user/data/ADSL.csv", response_format="json"

Common Errors: - FileNotFoundError: File not found at the specified path - ValueError: Unsupported file format (only .rds and .csv are supported) - ValueError: Invalid or corrupted dataset file

Use Cases: - Verify dataset structure before creating Teal app - Understand available columns for module configuration - Check data types to ensure compatibility with module requirements - Inspect sample values to understand data content - Validate dataset after loading from external sources

Note: This tool reads only the dataset structure, not the full data, making it efficient even for large datasets. For RDS files, it uses pyreadr. For CSV files, it uses pandas.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_pathYes
response_formatNomarkdown
include_sample_valuesNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (readOnlyHint, idempotentHint, destructiveHint), the description discloses critical behaviors: it requires an absolute path, reads only structure without loading the full dataset, uses pyreadr for RDS and pandas for CSV, and supports markdown or JSON response formats. It also lists common errors. This adds significant value beyond the annotations and is fully consistent with them.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long but well-structured with clear sections (IMPORTANT, Args, Returns, Column Type Mapping, Examples, Common Errors, Use Cases, Note). Each section adds useful information without redundancy. It is slightly verbose, but the structure helps an agent parse it efficiently, and every sentence serves a purpose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is complete for a tool of this complexity: it covers parameters, return formats, type mappings, examples, errors, use cases, and performance characteristics. Given that an output schema exists, the detailed return format explanation is extra helpful. The description leaves no significant gaps for an agent to correctly select and invoke this tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description carries the full burden for parameter explanations. It thoroughly explains file_path with absolute path requirement and examples, include_sample_values with its default and purpose, and response_format with 'markdown' vs 'json' options. It also includes examples of parameter combinations, fully compensating for the lack of schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Get detailed information about a dataset file including columns, types, and row count.' It clearly focuses on inspecting a single dataset file, which distinguishes it from sibling tools like tealflow_list_datasets and tealflow_discover_datasets that handle dataset discovery and listing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context on when to use the tool: 'useful for understanding the contents of a dataset before using it in a Teal application.' The 'Use Cases' section further elaborates on specific scenarios. It does not explicitly mention alternatives or when not to use it, but the differentiation from siblings and the practical use cases provide solid guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Appsilon/TealFlowMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server