Add dataset upload guide for LLMs (experimental guide)#1830
Merged
Conversation
- Add new guide specifically designed to help LLMs assist users with dataset uploads - Covers decision workflow, built-in loaders, custom format conversion, and validation - Includes practical examples for various data types and upload scenarios - Add entry to table of contents under Datasets section
- Add commands for LLMs to request when they don't have direct file access - Includes tree/find commands for structure, du/ls for sizes, head for data preview - Helps LLMs guide users on web interfaces (Claude, ChatGPT browser) - Placed early in guide for immediate visibility
- Remove unintended changes from other work - Keep only the addition of datasets-upload-guide-llm entry
- Add structured YAML block with Hub constraints for LLM parsing - Helps prevent hallucination of limits by providing exact values - Include comments explaining each limit - Keep human-readable summary alongside machine format
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
lhoestq
reviewed
Jul 9, 2025
Member
Author
|
Thanks for the feedback @lhoestq! I've addressed the technical issues:
Regarding the toctree placement: I initially placed it at the same level as "Uploading Datasets" for better discoverability by LLM agents (as you mentioned, SEO for LLM agents), but I'm happy to move it as a subsection under "Uploading Datasets" if that's preferred. What do you think would be best? |
julien-c
reviewed
Jul 9, 2025
julien-c
left a comment
Member
There was a problem hiding this comment.
cool idea. I think it's a "Resource" in MCP speak no? https://modelcontextprotocol.io/docs/concepts/resources
(cc @evalstate too)
Co-authored-by: Julien Chaumond <julien@huggingface.co>
lhoestq
approved these changes
Jul 10, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
This PR introduces an experimental guide tailored to help LLMs assist users in uploading datasets to the Hugging Face Hub in a format compatible with the Hub. The goal is to be an llms.txt file, but focused less on the datasets library and more on "how do I get this dataset onto the Hub in the most optimal format"
The primary use case is researchers or practitioners who have existing datasets (research data, domain-specific collections, etc.) that aren't in native Hub formats. They can provide this guide to an LLM (Claude Code, Cursor, or other AI coding assistants) along with a pointer to their local dataset. While advanced agents may handle much of the conversion automatically, even basic LLM + prompting workflows benefit from this structured guidance.
This is a proof of concept to test whether we should consider adding more LLM-focused documentation to the Hub docs for datasets. The guide is structured to work well with LLM context windows and provides a decision-tree approach that LLMs can follow to give users optimal upload recommendations.
Motivation
Without dedicated guidance, LLMs may recommend outdated or suboptimal approaches for dataset uploads based on their training data. This guide ensures LLMs have access to current best practices, including:
upload_large_folderfor large datasetsWhat's included
New guide:
datasets-upload-guide-llm.mdcovering:Note: This is experimental, and we can iterate on the format based on feedback and more real-world testing with LLMs. We may not want to merge this straight away (or at all), but I think it could be nice to start pointing people to this guide.
I also have a relatively good agent-based approach for end-to-end conversion of existing datasets to hub-compatible formats. I think it makes sense to start with this approach first, so we can get some sense of how well a more minimal approach like this can work for helping people with this.
cc @lhoestq @julien-c for viz.