{
  "slug": "csv-type-inferrer",
  "name": "gizza-ai/csv-type-inferrer",
  "version": "0.1.0",
  "title": "CSV Type Inferrer — detect delimiter, header & column data types — gizza.ai",
  "description": "Paste CSV and get a JSON schema: auto-detected delimiter, header row, and per-column types (int, float, bool, date, datetime, string). Runs in your browser.",
  "tags": [
    "csv type inference",
    "detect csv delimiter",
    "csv schema",
    "infer column types",
    "csv to json",
    "csv header detection",
    "csv data types"
  ],
  "category": "data",
  "urls": {
    "page": "https://gizza.ai/tools/csv-type-inferrer/",
    "markdown": "https://gizza.ai/tools/csv-type-inferrer/index.md",
    "descriptor": "https://gizza.ai/tools/csv-type-inferrer/tool.json",
    "deep_link_example": "https://gizza.ai/tools/csv-type-inferrer/?data=id%2Cname%2Cactive%2Cjoined%2Cscore%0A1%2CAlice%2Ctrue%2C2021-05-01%2C9.5%0A2%2CBob%2Cfalse%2C2022-11-30%2C7&delimiter=auto&headers=auto&null_tokens=NA%2CN%2FA%2CNULL%2Cnull%2CNone%2Cnan&date_detection=true&output=both"
  },
  "cli": "gizza tool csv-type-inferrer \"id,name,active,joined,score\n1,Alice,true,2021-05-01,9.5\n2,Bob,false,2022-11-30,7\"",
  "tool": {
    "description": "Sniff a CSV's delimiter/quote dialect, detect whether the first row is a header, infer a type for every column (int, float, bool, date, datetime, string, or empty), and emit a JSON report plus typed JSON records. delimiter='auto' (default) sniffs comma/semicolon/tab/pipe; headers='auto' (default) detects the header row; null_tokens lists strings treated as missing (default 'NA,N/A,NULL,null,None,nan'); date_detection=true (default) recognizes common date/datetime formats; output='both' (default) returns the schema and the type-coerced records, 'schema' just the report, 'records' just the array. Zero-padded integers like '007' stay strings to preserve codes; whitespace around cells is trimmed.",
    "parameters": {
      "additionalProperties": false,
      "properties": {
        "data": {
          "description": "The CSV text to analyze (paste the file contents, including the header row if there is one).",
          "type": "string"
        },
        "date_detection": {
          "default": true,
          "description": "Recognize date columns (YYYY-MM-DD, MM/DD/YYYY, DD/MM/YYYY and dash/slash variants) and datetime columns (YYYY-MM-DD[ T]HH:MM:SS, optional Z). Default true; set false to keep such columns as strings.",
          "type": "boolean"
        },
        "delimiter": {
          "default": "auto",
          "description": "Field delimiter. 'auto' (default) sniffs it from the data by testing comma, semicolon, tab and pipe for the most consistent column count; otherwise force one of comma, tab, semicolon, pipe.",
          "enum": [
            "auto",
            "comma",
            "tab",
            "semicolon",
            "pipe"
          ],
          "type": "string"
        },
        "headers": {
          "default": "auto",
          "description": "Whether the first row holds column names. 'auto' (default) detects it (a text first row over typed data rows = header); 'present' forces the first row to be names; 'absent' generates column_1, column_2, ... and treats every row as data.",
          "enum": [
            "auto",
            "present",
            "absent"
          ],
          "type": "string"
        },
        "null_tokens": {
          "default": "NA,N/A,NULL,null,None,nan",
          "description": "Comma-separated tokens (in addition to the empty string) treated as missing/null when inferring types, e.g. 'NA,N/A,NULL'. Matching is exact and case-sensitive.",
          "type": "string"
        },
        "output": {
          "default": "both",
          "description": "What to emit. 'both' (default) = a schema report (dialect + per-column types/counts) plus the typed records; 'schema' = the report only; 'records' = just the array of type-coerced JSON objects.",
          "enum": [
            "both",
            "schema",
            "records"
          ],
          "type": "string"
        }
      },
      "required": [
        "data"
      ],
      "type": "object"
    }
  }
}