Skip to content

Commit

Permalink
Add Jupyter Notebooks documentation to the Hub (#1282)
Browse files Browse the repository at this point in the history
* Add Jupyter Notebooks documentation to the Hub

* Update Google Colab link in notebooks.md

* Update docs/hub/notebooks.md

Co-authored-by: Julien Chaumond <[email protected]>

---------

Co-authored-by: Julien Chaumond <[email protected]>
  • Loading branch information
davanstrien and julien-c authored May 1, 2024
1 parent 7d764b4 commit b8ae409
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/hub/_toctree.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
title: "How-to: Build a Discussion bot based on BLOOM"
- local: webhooks-guide-metadata-review
title: "How-to: Create automatic metadata quality reports"
- local: notebooks
title: Notebooks
- local: repositories-recommendations
title: Repository size recommendations
- local: repositories-next-steps
Expand Down
15 changes: 15 additions & 0 deletions docs/hub/notebooks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Jupyter Notebooks on the Hugging Face Hub

[Jupyter notebooks](https://jupyter.org/) are a very popular format for sharing code and data analysis for machine learning and data science. They are interactive documents that can contain code, visualizations, and text.

## Rendering Jupyter notebooks on the Hub

Under the hood, Jupyter Notebook files (usually shared with a `.ipynb` extension) are JSON files. While viewing these files directly is possible, it's not a format intended to be read by humans. The Hub has rendering support for notebooks hosted on the Hub. This means that notebooks are displayed in a human-readable format.

![Before and after notebook rendering](https://huggingface.co/blog/assets/135_notebooks-hub/before_after_notebook_rendering.png)

Notebooks will be rendered when included in any type of repository on the Hub. This includes models, datasets, and Spaces.

## Launch in Google Colab

[Google Colab](https://colab.google/) is a free Jupyter Notebook environment that requires no setup and runs entirely in the cloud. It's a great way to run Jupyter Notebooks without having to install anything on your local machine. Notebooks hosted on the Hub are automatically given a "launch in Google Colab" button. This allows you to open the notebook in Colab with a single click.

0 comments on commit b8ae409

Please sign in to comment.