hfskill

Manage Hugging Face Spaces via CLI with the huggingface_hub API.

Updated Nov 3, 2025
One-click install
npx skills add https://github.com/joshhu/hfskill --skill hfskill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: hfskill
Source: https://github.com/joshhu/hfskill/tree/main
Command: npx skills add https://github.com/joshhu/hfskill --skill hfskill

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires huggingface_hub, requests, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Managing Hugging Face Spaces manually is tedious and error-prone; this skill provides a unified CLI to list, inspect, and control Spaces efficiently.

Core Features & Use Cases

  • List and filter Spaces by author or keyword to discover relevant Spaces
  • Retrieve detailed Space metadata and runtime status to monitor health
  • Restart or pause Space runtimes and quickly respond to issues
  • Use case: a Space operator monitors a production Space and restarts it when runtime signals an issue

Quick Start

Install dependencies and run python3 scripts/space_operations.py list to begin discovering available Spaces

Frequently Asked Questions about hfskill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate Hugging Face Spaces management from the command line?

You can automate Hugging Face Spaces management via a unified CLI that lists, inspects, and controls Space runtimes. It requires a valid HF token for write operations and uses the huggingface_hub API to interact with Spaces.

How do I check the runtime status of my Hugging Face Spaces?

To check the runtime status of your Hugging Face Spaces, you can retrieve detailed Space metadata and runtime status using this CLI. This allows Space operators to monitor health and quickly respond to runtime issues.

Can I restart or pause a Hugging Face Space runtime using a CLI?

Yes, you can restart or pause a Hugging Face Space runtime using this CLI. It enables operators to quickly respond to issues by controlling Space runtimes directly via the huggingface_hub API.

Do I need an HF token to manage Spaces with this CLI?

Yes, you need a valid HF token to manage Spaces with this CLI. A token is explicitly required for write operations such as restarting or pausing Space runtimes via the huggingface_hub API.

What is the best way to list and filter Hugging Face Spaces by author?

The best way to list and filter Hugging Face Spaces by author or keyword is through this CLI's list feature. It allows you to discover relevant Spaces efficiently by passing arguments to the space_operations.py script.

Why does my Hugging Face Space management script need the requests library?

Your Hugging Face Space management script needs the requests library alongside huggingface_hub to facilitate API interactions. These dependencies enable the CLI to execute network requests for retrieving metadata and controlling runtimes.