Skip to content

Knowtation data model

Dataset metadata, data dictionaries, proposals and runs for Knowtation. This file is the single source of truth; Pydantic classes are generated from it (see model/regenerate.py).

URI: https://gitlab.tarkam.org/tarkam/knowtation/schema

Name: knowtation

Classes

Class Description
CodeAttribute
CodeValue
Dataset Level 1
DictionaryVersion An immutable snapshot of a reviewed dataset description
Element Level 2
EntityLink Level 5 (later)
FieldGroup Elements that are one variable spread over several columns
LLMUsage What a run's LLM calls used
MediaFacet
Overlap Observed evidence that a column's values are keys of another resource's colum...
Proposal One suggested value for one property of a dataset, resource or element
QualitativeFacet
Relationship
Resource One file, table, feed, document, media item or layer
RuleSetRef One rule set used by a run
Run How a result was produced, so it can be reproduced
SpatialFacet
Statistics
TemporalFacet
TextFacet
VocabularyLink Level 4 (later)

Slots

Slot Description
aggregation How the measure combines over time or space
attributes Other facts about the code, from its lookup table (region, income group…)
author
bbox minx, miny, maxx, maxy
cached_calls Batches answered from the cache
calls Calls sent to the provider
captured_at
citation How to cite the data, as one reference
code
code_list What each code in the values means (code → meaning)
codebook
codec
codes The lookup rows of the codes used (capped)
concept_uri
confidence
consent_notes
content
cost_usd Estimated cost in US dollars; empty when the model's price is unknown
count
created_at
creators The people and organisations who made the data, one per line as 'Name; ORCID;...
crs
data_type The type of the values
dataset_hash
description One or two sentences saying what the thing is or what the values mean
distinct Distinct values in the column
distinct_count
distinct_estimated The distinct count is an estimate (a column with over 100,000 different value...
doi The data's DOI, without https://doi
duration_s
element
elements
encoding
end
entity_uri
error
examples
feature_count
field_groups
finished_at
format
from_element
geometry_type
hash
height
human_verified
id
input_tokens
keywords Words that help people find the data, edited as a comma-separated list
kind
language ISO 639-1 code
length
licence The licence the data is published under, ideally an SPDX id
llm_model
llm_usage LLM calls, tokens and estimated cost of the run
location File path or URL
match_type
matched Distinct values found among the keys
max
mean
meaning
media
members
min
missing_count
missing_values
name
names_similar The two column names are the same apart from case and punctuation
note
number
output_tokens
overlaps Observed: columns of this resource whose values are keys of another resource
parent
passages Documentation passages rules couldn't settle, kept (at most 8 KB) for an LLM ...
path
pattern For example pop_{year}
patterns Value shapes, for example 999-AA
policy_hash
policy_id
policy_version
prompt_version
property
provenance Where the value comes from
publisher The organisation responsible for the data
qualitative
rationale
raw_score
references The lookup column whose keys this element's values are: #<column...
relationships
required
resolution ISO 8601 duration, for example P1D or PT15M
resources
role Whether the file holds data or explains another file's codes (a lookup table)
row_count
rule_set_hash
rule_set_id
rule_set_version
rule_sets Every rule set the run used, in order (core first)
sampled_rows When the file was too large to read whole: the rows read
saved_input_tokens Tokens the cached answers cost when first asked
saved_output_tokens
sections
settings JSON-encoded run settings
sha256
size_bytes
skipped_calls Batches not asked because of the cost cap
source Where the dataset came from (path, URL or service)
source_id
source_kind
source_version
spatial
speakers
standard A recognised standard, for example gtfs
start
started_at
statistics
status
structure How a table is laid out: wide, long series, events or indicator
target Id of the dataset, resource or element
temporal
text
time_zone
title A short, human-readable name
to_element
unique
unit The unit of a measure, as a short symbol
unit_from Id of another element that holds the unit
unmatched_examples Up to ten values not found
value
varying What changes across members, for example year
version
warnings
width

Enumerations

Enumeration Description
Aggregation How a measure's values combine over time or space
ConfidenceBand How confident an inferred or declared value is; the thresholds come from the ...
DataType The type of an element's values
DocumentFormat Data dictionary documents for people
ElementRole What part an element plays in the data
ExportProfile Standards Knowtation can export a dataset to, each checked by a validator
MatchType
ProposalSource
Provenance Where a value comes from
RelationshipKind
ResourceKind The kind of a resource
ResourceRole
ResourceStatus
ReviewStatus
RunStatus
TableStructure How a table is laid out

Types

Type Description
Boolean A binary (true or false) value
Curie a compact URI
Date a date (year, month and day) in an idealized calendar
DateOrDatetime Either a date or a datetime
Datetime The combination of a date and time
Decimal A real number with arbitrary precision that conforms to the xsd:decimal speci...
Double A real number that conforms to the xsd:double specification
Float A real number that conforms to the xsd:float specification
Integer An integer
Jsonpath A string encoding a JSON Path
Jsonpointer A string encoding a JSON Pointer
Ncname Prefix part of CURIE
Nodeidentifier A URI, CURIE or BNODE that represents a node in a model
Objectidentifier A URI or CURIE that represents an object in the model
Sparqlpath A string encoding a SPARQL Property Path
String A character string
Time A time object represents a (local) time of day, independent of any particular...
Uri a complete URI
Uriorcurie a URI or a CURIE

Subsets

Subset Description