Guide · Agent skill
How to use the Hugging Face Datasets Explorer agent skill
Updated · written with AI from the project's own documentation and checked against our catalogue data
The huggingface-datasets skill teaches an AI agent to query Hugging Face's Dataset Viewer web API so it can explore public datasets without downloading them first. It is useful for data analysts, developers and researchers who want to check a dataset's structure, preview rows or pull a small sample. After reading this guide you will know how to install the skill, how to phrase requests so the agent uses it, and which safety points to check before uploading anything.
Quick start
- 1Download the ZIP. Download the huggingface-datasets skill ZIP from this page.
- 2Unzip into a skills folder. Unzip it into ~/.claude/skills/ for personal use or into .claude/skills/ inside a project.
- 3Or upload in the Claude apps. Go to Settings → Capabilities → Skills and upload the ZIP.
- 4Name the dataset. Ask for a dataset in namespace/repo form, such as stanfordnlp/imdb.
- 5Ask for splits and a preview. Request the splits, then a small sample of rows from one split.
- 6Add a token only if needed. Set HF_TOKEN for gated or private datasets and for any upload.
What is an agent skill and what does this one do?
An agent skill is a folder of instructions, centred on a SKILL.md file, that an AI agent can load when a task matches the skill's description. This one, from the huggingface/skills repository, is licensed under Apache-2.0 and contains only SKILL.md.
Once installed, the agent can check whether a dataset is available, list its subsets and splits, preview the first rows, page through rows, run text search or row filters, look up size totals and column statistics, and find links to the underlying parquet files. The skill is designed for read-only exploration and extraction.
- Validate that a dataset is available
- List configs (subsets) and splits
- Preview first rows and paginate with offset and length (length max 100)
- Search string columns and filter with predicates
- Get size totals, column statistics and parquet file links
Install the huggingface-datasets skill
Download the skill ZIP from this page and unzip it into one of two locations. For a personal install available in every project, use ~/.claude/skills/. For a single project, put it in the project's .claude/skills/ folder.
In the Claude apps you can instead upload the ZIP under Settings → Capabilities → Skills.
- Personal: unzip into ~/.claude/skills/
- Project only: unzip into .claude/skills/ inside your project
- Claude apps: Settings → Capabilities → Skills, then upload the ZIP
How to trigger the skill with natural requests
You do not need a special command. Describe what you want in plain language that mentions Hugging Face datasets, and the agent can pick up the skill when the request matches its description. Naming a dataset in the form namespace/repo, such as stanfordnlp/imdb, helps the agent build the right calls.
Good requests say what you want to know: whether the dataset exists, its splits, a few sample rows, how many rows it has, or which rows contain a word.
- Is the stanfordnlp/imdb dataset on Hugging Face valid and what splits does it have?
- Show me the first rows of the train split of stanfordnlp/imdb.
- How many rows are in the train split, and what are the column statistics?
- Search the imdb dataset for rows containing the word 'refund' in a string column.
Example: paging through a dataset
The skill uses the Dataset Viewer's /rows endpoint with offset (0-based) and length (max 100). The agent reads fields such as num_rows_total, num_rows_per_page and partial to decide whether to keep going.
The commands below are the pagination pattern from the skill, which you can run yourself to see the raw output.
curl "https://datasets-server.huggingface.co/rows?dataset=stanfordnlp/imdb&config=plain_text&split=train&offset=0&length=100"
curl "https://datasets-server.huggingface.co/rows?dataset=stanfordnlp/imdb&config=plain_text&split=train&offset=100&length=100"What the skill needs and what it can touch
The skill needs network access to datasets-server.huggingface.co. A Hugging Face token (HF_TOKEN) is only needed for gated or private datasets and for uploads. The skill's own files include no scripts, so it runs no code of its own, but the agent does make network requests.
Uploading is the one write action. The skill covers uploading parquet files or agent session traces to a Hugging Face dataset repo, which writes to the Hub. The optional upload flow uses npx with @huggingface/hub. For parquet and SQL work the skill points to a separate hf-cli skill.
- Network: datasets-server.huggingface.co
- HF_TOKEN: only for gated/private datasets and uploads
- Optional: npx with @huggingface/hub for the CLI upload flow
- Optional: hf-cli skill for parquet URL discovery and SQL
Safety notes before uploading agent traces
Agent session traces from Claude Code, Codex or Pi Agent can contain prompts, file paths, tool outputs, secrets or personal data. The skill says to default to private dataset repos and to keep the raw .jsonl files nested by project or working directory rather than dumped at the root.
Check what a session contains before any upload, and use the --private flag or create the repo as private first.
- Create the repo as private unless you have reviewed the content
- Nest uploads by project or cwd, for example codex/<project-or-cwd>
- Keep raw .jsonl files; do not edit them first
hf repos create <namespace>/<repo> --type dataset --private --exist-ok
hf upload <namespace>/<repo> ~/.codex/sessions codex/<project-or-cwd> --type datasetTips for better results
Name the dataset and split explicitly, because config and split are needed for preview, rows, search and filter calls. Ask for small samples first; the row length limit is 100 per request.
If a dataset is gated or private, make sure HF_TOKEN is set before asking. The skill sends it as a Bearer authorization header.
- Start with a validity check, then splits, then a small preview
- Ask for size or statistics before pulling many rows
- Use filters and search for targeted questions rather than paging everything
What people use it for
- Checking whether a public dataset exists and which splits it contains before downloading it
- Previewing rows and column names to decide if a dataset fits a research question
- Searching string columns for specific terms or filtering rows by a predicate
- Getting size totals and column statistics before planning a training or analysis run
- Uploading parquet files to a dataset repo and verifying they appear in the Dataset Viewer
Frequently asked questions
Is the huggingface-datasets skill free to use?
The skill is licensed under Apache-2.0, as stated on this page. The Dataset Viewer calls it describes are read-only, and the source does not list any charges for them.
What do I need to install the huggingface-datasets skill?
Download the ZIP and unzip it into ~/.claude/skills/ or a project's .claude/skills/ folder, or upload it in the Claude apps under Settings → Capabilities → Skills. Network access to datasets-server.huggingface.co is needed when the agent runs queries.
Do I need a Hugging Face token?
Not for public datasets. The skill says HF_TOKEN is required only for gated or private datasets and for uploads, and it is sent as a Bearer authorization header.
Does the skill download entire datasets?
No. It is built around previews, paging with length up to 100, search, filters and metadata, so the agent can inspect a dataset without downloading it. It can also return links to parquet files.
Can the skill run SQL or process local files?
Not directly. For parquet URL discovery and SQL the skill points to the separate hf-cli skill, so use that for heavier local or SQL work.
Is it safe to upload agent session traces with this skill?
Traces can contain secrets, file paths or personal data, so the skill recommends private dataset repos and nesting raw .jsonl files by project. Review content before uploading, because uploads write to the Hugging Face Hub.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
Use this skill if you want an AI agent to inspect public Hugging Face datasets quickly, such as checking splits, previewing rows or getting column statistics, without downloading them. Pick something else if you need heavy local processing or SQL, where the separate hf-cli skill fits better, or if you plan to upload sensitive content without reviewing it first.
Download the skill