Skip to main content
Glama

Convert to Parquet

convert_to_parquet

Convert a messy data file into clean, typed, zstd-compressed Parquet.

Use this first for any CSV/TSV, JSON/NDJSON, Excel, SPSS, Stata or SAS file, or a digital PDF with tables. It detects the format, encoding and delimiter; skips title rows; repairs broken JSON; pulls tables out of PDFs (merging tables that continue across pages); infers int/float/bool/date/timestamp columns (including 1.234,56 and $1,234 formats) while keeping IDs with leading zeros as text; normalizes column names to snake_case; keeps SPSS/Stata/SAS variable and value labels; and can validate against an expected_schema.

Returns an artifact_id (pass it to inspect_parquet / preview_parquet / query_parquet), a download link, and a per-column report: type, null count, values that did not fit the chosen type, and warnings. Price: $0.02 USDC per successful call, paid via x402.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "convert_to_parquet"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoPublic http(s) URL of the input file. Preferred for anything over ~3 MB.
optionsNo
filenameNoOriginal filename, e.g. 'survey.sav'. The extension helps format detection.
artifact_idNoartifact_id returned by an earlier convert_to_parquet call: converts that stored Parquet file again, with these options (an expected_schema, say).
content_base64NoThe file's raw bytes, base64-encoded (standard or URL-safe alphabet, '=' padding optional). Small files only (under ~3 MB).

Output Schema

NameRequiredDescriptionDefault
hintNoPointer to premium features (local mode only).
reportYes
artifactYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations only cover read-only/open-world/destructive/idempotent flags, but the description adds what the annotations cannot: per-call pricing ($0.02 USDC via x402), a full list of automatic transformations (format/encoding/delimiter detection, title-row skipping, broken-JSON repair, cross-page PDF table merging, leading-zero ID preservation), and the return shape (artifact_id, download link, per-column type/null/reject report). This is exactly the behavioral context an agent needs before spending money on a call.

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

Conciseness5/5

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

Front-loaded with the one-line purpose, then a single dense "what it detects/handles" clause, then the return values and price. No filler, no restatement of the title, and the cost — the most decision-relevant fact — is placed last so it is not buried.

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?

For a five-input, many-option conversion tool with an output schema, the description covers the decision inputs (which file types, auto-detection behavior, cost), the outputs (artifact_id and its consumers), and the extension points (expected_schema, re-conversion from artifact_id). Nothing an agent needs in order to invoke it correctly is missing.

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

Parameters4/5

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

Schema coverage is already 80%, so the baseline is 3; the description adds meaning on top by explaining that expected_schema validation is optional, that type inference can keep IDs as text, and that numeric/date parsing handles locale forms like 1.234,56 and $1,234. It does not enumerate the other options (sheet, pdf_pages, value_labels, row_group_size), so it stops short of a 5.

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?

States a specific verb and resource ("Convert a messy data file into clean, typed, zstd-compressed Parquet") and immediately scopes it to concrete input families (CSV/TSV, JSON/NDJSON, Excel, SPSS, Stata, SAS, digital PDF). An agent can distinguish this from inspect_parquet/preview_parquet/query_parquet, which the description positions as downstream consumers.

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?

Explicit routing guidance: "Use this first for any CSV/TSV, JSON/NDJSON, Excel, SPSS, Stata or SAS file, or a digital PDF with tables," with the artifact_id handoff naming the three follow-up tools. It lacks an explicit when-not-to-use clause (e.g., non-tabular or scanned PDFs), which keeps it short of a 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.