# Dataset constraint checker

- Human page: https://happytails.ai/en/data-tools/dataset-constraint-checker/
- Markdown: https://happytails.ai/en/data-tools/dataset-constraint-checker.md
- Structured JSON: https://happytails.ai/agents/en/data-tools/dataset-constraint-checker/index.json
- Visibility: public

## Tool capabilities

| Property | Value |
| --- | --- |
| Tool ID | `dataset-constraint-checker` |
| Category | data-tools |
| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |
| Browser execution | Use the visible action or interactive controls. |
| Browser processing | Browser; see tool notes for network behavior. |
| HTTP API | Not callable through HTTP. |
| Browser-agent interface | run_current_tool |

### Implementation notes

Runs locally on your device. CSV requires unique nonempty headers. Up to 1,000,000 characters, 10,000 data records and 100,000 cells across inputs, with 100 columns. Quoted multiline cells are supported. Each JSON settings field is limited to 100,000 characters. Output files are bounded to 4,000,000 characters. Diagnostic reports contain at most 500 findings and disclose the omitted count. Select 1 to 10 distinct UTF-8 CSV files. Up to 4,000,000 bytes total; aggregate CSV limits still apply. Each unique rule checks the union of its selected tables, including duplicates within a source. Range bounds are inclusive. Files are read sequentially and long checks yield so you can cancel.

### Inputs and settings

No free-text input is required. Use the file inputs and/or settings below.

Accepted browser files: `.csv,.tsv,text/csv`. Multiple files are supported.

Browser file-input limit: 4000000 bytes in total. HTTP limits can differ.

| Setting | Meaning | Control type | Default | Constraints |
| --- | --- | --- | --- | --- |
| `separator` | Input CSV separator | select | "," | Allowed: ,, ;, 	 |
| `rules` | Table constraints (JSON) | textarea | "[\n  {\n    \"type\": \"unique\",\n    \"tables\": [\n      \"first.csv\",\n      \"second.csv\"\n    ],\n    \"columns\": [\n      \"id\"\n    ]\n  },\n  {\n    \"type\": \"range\",\n    \"tables\": [\n      \"first.csv\",\n      \"second.csv\"\n    ],\n    \"column\": \"amount\",\n    \"min\": \"0\",\n    \"max\": \"10000\"\n  }\n]" |  |

### Browser-agent workflow

1. Open the human page in a browser that supports WebMCP.
2. Discover the interface exposed by that page; use its actual schema.
3. Select files on the page first when the tool requires files.
4. Call `run_current_tool` with valid input and settings.
5. Inspect the returned result or error and the displayed output. Retrieve files from the displayed download links.

Calls do not automatically copy or download results. Browser permissions still apply. Interface availability alone is not proof of successful execution.

### Planning specification

Unique rules span the union of the selected tables, including duplicate records in a single source. Range bounds are inclusive decimal strings. skipEmpty is optional and defaults to false. Reports omit source cell values. Up to 1,000,000 characters, 10,000 data records, 100 columns and 100,000 cells across the sources. Files for multi-source tools are limited to 4,000,000 bytes total. Reports retain at most 500 diagnostic findings and state any omitted count. CSV and JSON outputs are limited to 4,000,000 characters.

This describes intended requirements. Use the implementation notes, interface schema and observed output to determine current support.

### Complete machine-readable capability record

```json
{
  "id": "dataset-constraint-checker",
  "category": "data-tools",
  "built": true,
  "requirements": "Unique rules span the union of the selected tables, including duplicate records in a single source. Range bounds are inclusive decimal strings. skipEmpty is optional and defaults to false. Reports omit source cell values. Up to 1,000,000 characters, 10,000 data records, 100 columns and 100,000 cells across the sources. Files for multi-source tools are limited to 4,000,000 bytes total. Reports retain at most 500 diagnostic findings and state any omitted count. CSV and JSON outputs are limited to 4,000,000 characters.",
  "implementation": {
    "fields": [
      {
        "key": "separator",
        "label": "Input CSV separator",
        "value": ",",
        "type": "select",
        "values": [
          ",",
          ";",
          "\t"
        ]
      },
      {
        "key": "rules",
        "label": "Table constraints (JSON)",
        "value": "[\n  {\n    \"type\": \"unique\",\n    \"tables\": [\n      \"first.csv\",\n      \"second.csv\"\n    ],\n    \"columns\": [\n      \"id\"\n    ]\n  },\n  {\n    \"type\": \"range\",\n    \"tables\": [\n      \"first.csv\",\n      \"second.csv\"\n    ],\n    \"column\": \"amount\",\n    \"min\": \"0\",\n    \"max\": \"10000\"\n  }\n]",
        "type": "textarea",
        "help": "Select tables by their exact uploaded filenames. unique accepts columns (an array); range accepts one column and min and/or max decimal strings. skipEmpty defaults to false."
      }
    ],
    "live": false,
    "presentation": "metrics",
    "note": "Runs locally on your device. CSV requires unique nonempty headers. Up to 1,000,000 characters, 10,000 data records and 100,000 cells across inputs, with 100 columns. Quoted multiline cells are supported. Each JSON settings field is limited to 100,000 characters. Output files are bounded to 4,000,000 characters. Diagnostic reports contain at most 500 findings and disclose the omitted count. Select 1 to 10 distinct UTF-8 CSV files. Up to 4,000,000 bytes total; aggregate CSV limits still apply. Each unique rule checks the union of its selected tables, including duplicates within a source. Range bounds are inclusive. Files are read sequentially and long checks yield so you can cancel.",
    "files": true,
    "multiple": true,
    "input": false,
    "accept": ".csv,.tsv,text/csv",
    "maxFileBytes": 4000000,
    "experience": {
      "automatic": false,
      "single": false,
      "inputMaxLength": 1000000,
      "inputMode": "text",
      "label": "Your text",
      "placeholder": "Type or paste your input…",
      "help": "Up to 1,000,000 characters. Review the settings before running.",
      "action": null
    },
    "mode": "explicit",
    "interactive": false
  },
  "execution": "Browser interface",
  "api": null,
  "browser_agent": {
    "supported": true,
    "name": "run_current_tool",
    "discovery": "WebMCP on the human page in a supporting browser",
    "verification": "See audit/API-AUDIT.md; availability is not verification"
  }
}
```

## Page guide

Check unique keys and numeric ranges across a collection of CSV exports.

How can we improve this tool?

Report a problem or share an idea.

Please leave out private information. Your message and the tool name go to our team via PostHog.

### How to use Dataset constraint checker

1. Choose up to 10 CSV files with distinct filenames.
2. Write unique or range rules using the exact uploaded filenames and headers.
3. Run the checks and download the violations report.

## Useful next steps

- [Referential integrity checker](https://happytails.ai/en/data-tools/referential-integrity-checker/) ([Markdown](https://happytails.ai/en/data-tools/referential-integrity-checker.md))

- [CSV schema validator](https://happytails.ai/en/data-tools/csv-schema-validator/) ([Markdown](https://happytails.ai/en/data-tools/csv-schema-validator.md))

## Prepare the source

Choose up to 10 CSV files with distinct filenames.

### Choose the matching rules

Write unique or range rules using the exact uploaded filenames and headers.

### Review and keep the result

Run the checks and download the violations report. Unique rules span the union of the selected tables, including duplicate records in a single source. Range bounds are inclusive decimal strings. skipEmpty is optional and defaults to false. Reports omit source cell values.
