Hugging Face

Get Hugging Face dataset statistics

Get per-column statistics of a Hugging Face dataset split.

GET/v1/hugging-face/datasets/{owner}/{name}/statistics
1credit
x-api-keystringheader

API key (`sfk_...`)

Parameters
4
ownerstringrequiredpath

Owner of the repository: a user or organization name.

pattern: ^[A-Za-z0-9][A-Za-z0-9._-]{0,95}$

namestringrequiredpath

Repository name, without the owner.

pattern: ^[A-Za-z0-9][A-Za-z0-9._-]{0,95}$

configstringoptionalquery

Subset (config) name, e.g. `plain_text`. Default: the dataset's first subset. An unknown name is refused with a 400.

min 1 chars · max 200 chars

splitstringoptionalquery

Split name, e.g. `train`. Default: the subset's first split. An unknown name is refused with a 400.

min 1 chars · max 200 chars

Response fields
15

Endpoint-specific response payload.

datalookupStatus
string

Whether the item was found. `restricted` means it exists but its content is gated.

one of: found, not_found, restricted

dataavailable
boolean

Whether Hugging Face computed statistics for this split.

dataconfig
stringnullable

Subset the statistics are for.

datasplit
stringnullable

Split the statistics are for.

datanumExamples
integernullable

Rows counted.

dataisPartial
booleannullable

Whether only part of the split was counted.

One entry per column.

datacolumns[]name
string

Column name.

datacolumns[]type
string

Statistics kind: `int`, `float`, `string_label`, `string_text`, `class_label`, `bool` and more.

datacolumns[]statistics
object

Counts, minimum, maximum, mean, histogram or label frequencies, depending on the type.

Metadata describing the request and billing outcome.

metarequestId
string

Unique request identifier for tracing this API call.

min 1 chars

metacreditsCharged
integer

Credits charged for this request.

≥ 0

metaversion
string

Public API version that served the response.

one of: v1

Code example

curl "https://api.socialfetch.dev/v1/hugging-face/datasets/stanfordnlp/imdb/statistics" \
  -H "x-api-key: YOUR_API_KEY"

Responses

Dataset statistics.