Token导航 LogoToken导航TokenDH.com
研究检索敏感数据clawhub未标认证来源可访问clear审计通过

hugging-face-clihugging face CLI 搜索

Agent Skill

hugging-face-cli 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

9,596

周安装

392

GitHub Stars

1

下载量

3,105
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:hugging-face-cli(hugging face CLI 搜索)
来源仓库:https://github.com/yevhendiachenko0/hugging-face-cli
安装命令:
openclaw skills install hugging-face-cli
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install hugging-face-cli

简介

通过 hf CLI 管理 Hugging Face Hub。在使用 HF AI 模型、数据集、空间或存储库时使用。

SKILL.md

name
hugging-face-cli
description
Manage Hugging Face Hub via hf CLI. Use when working with HF AI models, datasets, spaces, or repos.
user-invocable
true
metadata
openclaw
emoji
\F917
version
1.1.0
homepage
https://huggingface.co
primaryEnv
HF_TOKEN
requires
env
[HF_TOKEN]
bins
[hf]

Hugging Face CLI

Hugging Face (https://huggingface.co) is the leading platform for sharing and collaborating on AI models, datasets, and spaces. This skill enables interaction with the Hub through the official hf CLI.

Installation

Check if hf is available by running hf version. If not installed:

pip install -U "huggingface_hub[cli]"
# or
brew install hf

If the options above do not work, follow the official installation guide.

After installation, run hf version to verify. If the command is not found, run source ~/.bashrc (or source ~/.zshrc for zsh) to reload the PATH, then try again.

Authentication

A Hugging Face User Access Token is required. The token is provided via the HF_TOKEN environment variable.

If authentication fails or the token is missing, instruct the user to:

  1. Go to https://huggingface.co/settings/tokens
  2. Create a new token — there are two permission levels:

- Read (safer): sufficient for searching, downloading models/datasets, listing repos, browsing papers, and most read-only operations. Choose this if you only need to explore and download. - Write (less safe, broader access): required for creating/deleting repos, uploading files, managing discussions, deploying endpoints, and running jobs. Example 3 (create a repo and upload weights) requires a write token.

  1. Set it as an environment variable: export HF_TOKEN="hf_..." (add to shell profile for persistence)

Important: Do NOT run hf auth login interactively — it requires terminal input. Instead, use the environment variable directly. The hf CLI automatically picks up HF_TOKEN from the environment for all commands. To verify authentication, run:

hf auth whoami

Key Commands

TaskCommand
Check current userhf auth whoami
Download fileshf download <repo_id> [files...] [--local-dir <path>]
Download specific revision`hf download <repo_id> --revision <branch\tag\commit>`
Download with filtershf download <repo_id> --include "*.safetensors" --exclude "*.bin"
Upload fileshf upload <repo_id> <local_path> [path_in_repo]
Upload as PRhf upload <repo_id> <local_path> [path_in_repo] --create-pr
Upload (private repo)hf upload <repo_id> <local_path> [path_in_repo] --private
Upload large folderhf upload-large-folder <repo_id> <local_path>
Create a repo`hf repos create <name> [--repo-type model\dataset\space] [--private]`
Delete a repohf repos delete <repo_id>
Delete files from repohf repos delete-files <repo_id> <path>...
Duplicate a repo`hf repos duplicate <repo_id> [--type model\dataset\space]`
Repo settings`hf repos settings <repo_id> [--private\--public]`
Manage branches`hf repos branch create\delete <repo_id> <branch>`
Manage tags`hf repos tag create\delete <repo_id> <tag>`
List modelshf models ls [--search <query>] [--sort downloads] [--limit N]
Model infohf models info <repo_id>
List datasetshf datasets ls [--search <query>]
Dataset infohf datasets info <repo_id>
Run SQL on datahf datasets sql "<SQL>"
List spaceshf spaces ls [--search <query>]
Space infohf spaces info <repo_id>
Space dev modehf spaces dev-mode <repo_id>
List papershf papers ls [--limit N]
List collectionshf collections ls [--owner <user>] [--sort trending]
Create collectionhf collections create "<title>"
Collection infohf collections info <collection_slug>
Add to collectionhf collections add-item <collection_slug> <repo_id> <type>
Delete collectionhf collections delete <collection_slug>
Run a cloud jobhf jobs run <docker_image> <command>
List jobshf jobs ps
Job logshf jobs logs <job_id>
Cancel a jobhf jobs cancel <job_id>
Job hardwarehf jobs hardware
Deploy endpointhf endpoints deploy <name> --repo <repo_id> --framework <fw> --accelerator <hw> ...
List endpointshf endpoints ls
Endpoint infohf endpoints describe <name>
Pause/resume endpoint`hf endpoints pause\resume <name>`
Delete endpointhf endpoints delete <name>
List discussionshf discussions ls <repo_id>
Create discussionhf discussions create <repo_id> --title "<title>"
Comment on discussionhf discussions comment <repo_id> <num> --body "<text>"
Close discussionhf discussions close <repo_id> <num>
Merge PRhf discussions merge <repo_id> <num>
Manage cachehf cache ls, hf cache rm <id>, hf cache prune
Delete bucket / fileshf buckets delete <user>/<bucket>, hf buckets rm <user>/<bucket>/<path>
Sync to buckethf sync <local_path> hf://buckets/<user>/<bucket>
Print environmenthf env

End-to-End Examples

Example 1: Explore trending models, pick one, and preview a download

hf models ls --sort trending_score --limit 5
hf models info openai-community/gpt2
hf download --dry-run openai-community/gpt2 config.json tokenizer.json
hf download openai-community/gpt2 config.json tokenizer.json --local-dir ./gpt2

Example 2: Browse today's papers and find related datasets

hf papers ls --limit 5
hf datasets ls --search "code" --sort downloads --limit 5
hf datasets info bigcode/the-stack

Example 3: Create a private model repo and upload weights

hf repos create my-fine-tuned-model --private
# create returns <your-username>/my-fine-tuned-model — use that full ID below
hf upload <username>/my-fine-tuned-model ./output --commit-message "Add fine-tuned weights"
hf repos tag create <username>/my-fine-tuned-model v1.0 -m "Initial release"

Further Reference

Reference version: hf CLI v1.x

For the full list of commands and options, use built-in help:

hf --help
hf <command> --help
  • Full documentation: https://huggingface.co/docs/huggingface_hub/guides/cli
  • CLI reference: https://huggingface.co/docs/huggingface_hub/package_reference/cli

Safety Rules

  • Destructive commands require explicit user confirmation. Before running any of the following, describe what will happen and ask the user to confirm:

- hf repos delete — permanently deletes a repository - hf repos delete-files — deletes files from a repository - hf buckets delete / hf buckets rm — deletes buckets or bucket files - hf discussions close / hf discussions merge — closes or merges PRs/discussions - hf collections delete — permanently deletes a collection - hf endpoints delete — permanently deletes an Inference Endpoint - hf jobs cancel — cancels a running compute job - Any command with --delete flag (e.g., sync with deletion) - hf cache rm / hf cache prune — removes cached data from disk (re-downloadable, but may waste bandwidth)

  • Never expose or log the HF_TOKEN value. Do not include it in command output or commit it to files.
  • When uploading, warn the user if the target repo is public and the upload may contain sensitive data.

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

87.87%
按下载量换算2,728

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills