Label Studio 1.12.0 🚀Automate & Evaluate Labeling Predictions Using LLMs & ML Models
Guide

Kickstart your Label Studio Annotation Project on Hugging Face Spaces

Chris Hoge

Head of Community

Introduction

We’re thrilled to announce that the official Label Studio template in Hugging Face Spaces now supports persistent storage! The Label Studio Space is a hosted installation of the Open Source edition of Label Studio that gives you a collaborative environment to label, explore, and optimize datasets without leaving Hugging Face.

In the initial release of the Label Studio space, users faced a data persistence limitation. Previously, storage on a Space was not guaranteed to persist past a restart, requiring users to configure external storage and database connections to create a complete Label Studio environment.

Now, with just a few quick configuration changes, you can transform your Label Studio space from a demonstration environment into a compact production working space for your annotation and labeling projects, all within Hugging Face. Persistent storage in your Label Studio Space makes it even easier for you to start collaborating with other data scientists and subject matter experts on annotation projects.

You can enable persistent storage in your own Label Studio Space with four easy steps.

1. Copy the Label Studio HF Space

Make a copy of the space using either the “Clone repository” option in the Label Studio Space or the Label Studio template from the Hugging Face “Create a new Space” page.

Clone the Label Studio Space

2. Secure your Label Studio Space

The remainder of the configuration can be done entirely through the settings panel for the Label Studio Space.

Accessing the Settings in Your Label Studio Space

Begin with configuring your Label Studio Space for secure logins. By default, Label Studio Spaces allows anyone to create an account. This step needs to be done before the permanent database is initialized. Note that any accounts created before turning off public signups will still exist in your environment.

Configuring Variables and Secrets in Hugging Face Spaces

To enable secure logins, you will need to disable signups without links by setting the following variable in your space:

ENV LABEL_STUDIO_DISABLE_SIGNUP_WITHOUT_LINK=true

The Disable Signup Without Link Setting

Then set your default username and password as secrets in the space:

ENV LABEL_STUDIO_USERNAME=$USER_EMAIL
ENV LABEL_STUDIO_PASSWORD=$USER_PASSWORD

The Label Studio Username Default Secret

The Default Label Studio Password Secret

3. Choose and Configure the Storage Tier

With your user settings configured, you must select a storage tier for your Space. Note that this is a paid feature for Hugging Face Spaces.

Selecting a Persistent Storage Tier in Spaces

Once the persistent storage is enabled, you must edit two variables in your Space to tell Label Studio how to use the storage. The first tells Label Studio to use the persistent storage to host the SQLite database and the local media storage. The second removes the “ephemeral storage warning” from the Label Studio Interface.

ENV LABEL_STUDIO_BASE_DATA_DIR=/data
ENV STORAGE_PERSISTENCE=1

The Label Studio Base Data Dir Setting for Persistent Storage

The Label Studio Storage Persistence Setting to Remove Warning

Confirm that your variables and secrets are set correctly, and restart the space.

Variables and Secrets Configured for Label Studio in Spaces

4. Celebrate! 🎉

Congratulations! You’re now running your instance of Label Studio with persistent storage in Hugging Face Spaces. Check out the Getting Started with Hugging Face Spaces Tutorial to learn how to work with your new Label Studio instance. For a deeper dive into using machine learning integrations, read the follow-up Introduction to Machine Learning with Label Studio Tutorial.

We think that Hugging Face with Label Studio is an excellent way for you to get started with the platform, but if you need more advanced options like role-based access for labeling teams, annotator agreement matrices, advanced support for active learning, or professional support, check out the Label Studio Enterprise Free Trial.

Label Studio has an active community, and the team would love to hear how you’re using Label Studio for your machine learning and annotation projects. Join us on the Label Studio Slack to catch up on the latest news, get help with your projects, and connect with other data professionals.

Happy Labeling!

Related Content

  • Strategies for Evaluating LLMs

    Sure, benchmarks are cool, but they don’t give you the feel or the intuition of how a model actually works. To get that, you’ve got to hack around with the model and throw real-world prompts at it — like you’d do in day-to-day tasks.

    Label Studio Team

    April 23, 2024

  • A Step-by-Step Guide to Preparing Data for Labeling

    In the world of machine learning, data labeling plays a central role in training accurate and reliable models, and properly preparing your data for labeling sets the foundation for the success of your machine learning projects.

    Label Studio Team

    March 6, 2024

  • Interactive Data Labeling with LLMs and Label Studio’s Prompt Interface

    Learn how to build a prompt-centric workflow in Label Studio, which combines real-time prompt engineering with data labeling. The goal of this prompter is to make working with data and LLMs seamless and dynamic.

    Jimmy Whitaker

    Data Scientist in Residence at HumanSignal