container
Structured data — JSON, CSV, query strings, key-value pairs
3 categories, 12 types: 10 a sibling in its category also accepts, 12 accepted by another category's rule, 1 that decompose into parts.
The 3 container categories
Each category's lookup value, against every other category's rule
Where container categories overlap
Each type's lookup value, against every other category's rule
Which container type is it?
7 of 12 container types in 2 categories accept it, and read it 2 ways.
| Type | Category | Reads it as |
|---|---|---|
HTML Content html | object | Hello world |
Comma-Separated Values (Simple) comma_separated | array | <p>Hello world</p> |
Pipe-Separated Values pipe_separated | array | <p>Hello world</p> |
Semicolon-Separated Values semicolon_separated | array | <p>Hello world</p> |
Whitespace-Separated Values whitespace_separated | array | <p>Hello world</p> |
CSV Record csv | object | <p>Hello world</p> |
XML Document xml | object | <p>Hello world</p> |
What the engine extracts
- object1 of 7tag_count · text_content
Use it
One value from each category, each inferred on its own
CLI · DuckDB
$ for v in '<p>Hello world</p>' 'apple,banana,cherry' 'name=John&age=30&city=NewYork'; do finetype infer -i "$v"; done
SELECT v, ft_infer(v) FROM (VALUES ('<p>Hello world</p>'), ('apple,banana,cherry'), ('name=John&age=30&city=NewYork')) t(v);