Skip to main content
Glama

Detectar patrón de series periódicas en un dataset

detect_series_pattern
Read-only

Compares the two newest periodic files in a dataset to determine whether its series is cumulative (newest file suffices) or incremental (combine all files).

Instructions

Tell whether a dataset's periodic files are cumulative (newest file suffices) or incremental (combine all) by comparing period values in the two newest files. Heuristic over up to 500 rows each.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "dataset_id": "<dataset_id>"
    },
    "name": "detect_series_pattern"
  }
}

Input Schema

NameRequiredDescriptionDefault
formatNotext summary (default) or json structured result.text
sourceNoCKAN portal; nacional (default), cuenca, latacunga or iadb.nacional
dataset_idYesThe dataset ID or slug
resource_id_newNoOptional -- newer resource ID to compare (auto-detected from the dataset's periodic-name group if omitted)
resource_id_oldNoOptional -- older resource ID to compare (auto-detected if omitted).

Output Schema

NameRequiredDescriptionDefault
sourceNo
metadatosYes
url_fuenteNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.15.0
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "metadatos": {
      +      "properties": {
      +        "contrato": {
      +          "const": "ecudatamcp.response.v1"
      +        }
      +      },
      +      "required": [
      +        "contrato"
      +      ],
      +      "type": "object"
      +    },
      +    "source": {},
      +    "url_fuente": {}
      +  },
      +  "required": [
      +    "metadatos"
      +  ],
      +  "type": "object"
      +}
  2. Changed1 schema field changedv0.13.0
    • changedOutput schema / (root)
      Previous value: -{
      -  "additionalProperties": true,
      -  "type": "object"
      -}New value: +null
  3. Changed5 schema fields changedv0.10.0
    • addedInput schema / properties / dataset_id / description
      Added value: +"The dataset ID or slug"
    • addedInput schema / properties / format / description
      Added value: +"text summary (default) or json structured result."
    • addedInput schema / properties / resource_id_new / description
      Added value: +"Optional -- newer resource ID to compare (auto-detected from the dataset's periodic-name group if omitted)"
    • addedInput schema / properties / resource_id_old / description
      Added value: +"Optional -- older resource ID to compare (auto-detected if omitted)."
    • addedInput schema / properties / source / description
      Added value: +"CKAN portal; nacional (default), cuenca, latacunga or iadb."
  4. Changed7 schema fields changedv0.8.14
    • removedInput schema / properties / dataset_id / title
      Removed value: -"Dataset Id"
    • removedInput schema / properties / format / title
      Removed value: -"Format"
    • removedInput schema / properties / resource_id_new / title
      Removed value: -"Resource Id New"
    • removedInput schema / properties / resource_id_old / title
      Removed value: -"Resource Id Old"
    • removedInput schema / properties / source / title
      Removed value: -"Source"
    • removedInput schema / title
      Removed value: -"detect_series_patternArguments"
    • removedOutput schema / title
      Removed value: -"detect_series_patternDictOutput"
  5. First observedv0.8.12

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, non-destructive, openWorld), so credit goes to what the text adds: it discloses that the answer is a heuristic sampled from up to 500 rows per file, which tells the agent the result can be approximate on large resources. It does not say what happens when fewer than two periodic files exist or how confident the verdict is, but the sampling caveat is meaningful beyond the annotations.

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?

Two sentences, zero filler: the first front-loads the decision being made and the mechanism, the second states the sampling bound. Nothing is repeated from the title or schema.

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

Completeness4/5

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

With annotations, a full output schema, and complete parameter documentation, the description only needs to convey the semantics and its reliability, which it does. The remaining gap is edge-case behavior (single-file or non-periodic datasets) and whether the verdict is a boolean or a label, which may be covered by the output schema.

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

Parameters3/5

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

Schema description coverage is 100% and both enums (format, source) are documented in-schema, so the baseline is 3. The description adds only oblique context, namely that comparison targets the two newest files, which hints at why resource_id_new/old are optional, but it gives no guidance on when to override the auto-detection.

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

Purpose4/5

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

States a specific determination: whether a dataset's periodic files are cumulative (newest suffices) or incremental (combine all), and how it decides this (comparing period values in the two newest files). The name alone (detect_series_pattern) is vague, but the description resolves it fully. It does not explicitly contrast with any sibling, though none of the listed siblings appear to overlap.

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

Usage Guidelines3/5

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

Usage is implied by the outcome: this is the step that tells you whether to download only the newest file or combine all of them. There is no explicit 'use this when' statement, no prerequisites, and no named alternative or exclusion, leaving the agent to infer the call site.

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

Deploy Server

Other Tools