← 返回 Skills 市场
tianxingleo

Huggingface Trends

作者 tianxingleo · GitHub ↗ · v1.0.0
cross-platform ⚠ suspicious
1252
总下载
1
收藏
5
当前安装
1
版本数
在 OpenClaw 中安装
/install huggingface-trends
功能描述
Monitor and fetch trending models from Hugging Face with support for filtering by task, library, and popularity metrics. Use when users want to check trending AI models, compare model popularity, or explore popular models by task or library. Supports export to JSON and formatted output.
使用说明 (SKILL.md)

Hugging Face Trending Models

Quick Start

Fetch the top trending models:

scripts/hf_trends.py -n 10 -p http://172.28.96.1:10808

Core Features

Fetch Trending Models

Basic usage:

# Get top 10 trending models
scripts/hf_trends.py -n 10 -p http://172.28.96.1:10808

# Get top 5 most liked models
scripts/hf_trends.py -n 5 -s likes -p http://172.28.96.1:10808

# Get most downloaded models
scripts/hf_trends.py -n 10 -s downloads -p http://172.28.96.1:10808

Filter by Task

Filter models by specific AI tasks:

# Text generation models
scripts/hf_trends.py -n 10 -t text-generation -p http://172.28.96.1:10808

# Image classification models
scripts/hf_trends.py -n 10 -t image-classification -p http://172.28.96.1:10808

# Translation models
scripts/hf_trends.py -n 10 -t translation -p http://172.28.96.1:10808

Common task filters:

  • text-generation - Large language models
  • image-classification - Vision models
  • image-to-text - Multimodal models
  • translation - Machine translation
  • summarization - Text summarization
  • question-answering - QA models

Filter by Library

Filter by ML framework:

# PyTorch models only
scripts/hf_trends.py -n 10 -l pytorch -p http://172.28.96.1:10808

# TensorFlow models only
scripts/hf_trends.py -n 10 -l tensorflow -p http://172.28.96.1:10808

# JAX models
scripts/hf_trends.py -n 10 -l jax -p http://172.28.96.1:10808

Export to JSON

Save results for further analysis:

# Export to JSON file
scripts/hf_trends.py -n 10 -j trending_models.json -p http://172.28.96.1:10808

# Export with specific filters
scripts/hf_trends.py -n 20 -t text-generation -j text_models.json -p http://172.28.96.1:10808

Proxy Configuration

The script requires an HTTP proxy to access Hugging Face API (network restrictions).

Use the -p flag:

scripts/hf_trends.py -p http://172.28.96.1:10808

For most WSL2 environments with v2rayN:

  • Proxy URL: http://172.28.96.1:10808
  • Or use dynamic IP: http://$(ip route show | grep default | awk '{print $3}'):10808

Command-Line Options

Flag Long Form Description Default
-n --limit Number of models to fetch 10
-s --sort Sort by: trending, likes, downloads, created trending
-t --task Filter by task/pipeline None
-l --library Filter by library (pytorch, tensorflow, jax) None
-j --json Export results to JSON file None
-p --proxy Proxy URL for HTTP requests None

Output Format

The script displays models in a structured format:

🤖 Hugging Face 热门模型 (5 个)
============================================================
1. moonshotai/Kimi-K2.5
   ⭐ 2.0K likes   📥 647.6K downloads
   📊 Task: image-text-to-text   📚 Library: transformers
   📅 Created: 2026-01-01   Updated: N/A
...

Model Information

Each model entry includes:

  • Model ID: Full Hugging Face model name
  • Likes: Number of likes (popularity metric)
  • Downloads: Total download count
  • Task: Primary task/pipeline (e.g., text-generation)
  • Library: ML framework (transformers, pytorch, tensorflow)
  • Created/Updated: Date information

Use Cases

Daily Monitoring

Check trending models daily for new releases:

# Create cron job for daily monitoring
0 9 * * * cd /home/ltx/.openclaw/workspace && \
  /home/ltx/.openclaw/workspace/skills/huggingface-trends/scripts/hf_trends.py \
  -n 20 -p http://172.28.96.1:10808 >> /tmp/hf-trends.log 2>&1

Task-Specific Research

Explore popular models for specific AI tasks:

# Research trending text generation models
scripts/hf_trends.py -n 15 -t text-generation -s likes -p http://172.28.96.1:10808

# Find popular image-to-text models
scripts/hf_trends.py -n 15 -t image-to-text -s downloads -p http://172.28.96.1:10808

Framework-Specific Analysis

Compare models by ML framework:

# Compare PyTorch vs TensorFlow popularity
scripts/hf_trends.py -n 20 -l pytorch -j pytorch_models.json -p http://172.28.96.1:10808
scripts/hf_trends.py -n 20 -l tensorflow -j tensorflow_models.json -p http://172.28.96.1:10808

Integration with OpenClaw

Use within OpenClaw sessions:

# Fetch trending models programmatically
from skills.huggingface-trends.scripts import hf_trends

fetcher = hf_trends.HuggingFaceTrends(proxy="http://172.28.96.1:10808")
models = fetcher.fetch_trending_models(limit=10)

# Format for display
output = fetcher.format_models(models)
print(output)

Troubleshooting

Network Errors

Problem: "Network is unreachable" or connection errors

Solution: Ensure proxy is specified with -p flag:

scripts/hf_trends.py -p http://172.28.96.1:10808

Check if v2rayN proxy is running on Windows.

Empty Results

Problem: "No models found"

Solution: Try different filters or increase limit:

scripts/hf_trends.py -n 50 -p http://172.28.96.1:10808

Dependencies Missing

Problem: "requests package not installed"

Solution: Install required dependencies:

pip install requests

Technical Notes

  • API Limitation: Hugging Face's public API doesn't provide a dedicated trending endpoint without authentication. The script fetches recent models and sorts by popularity metrics.
  • Proxy Requirement: Due to network restrictions, all requests must go through a proxy. The script supports HTTP proxy configuration.
  • Rate Limits: The public API has rate limits. Avoid making too many requests in quick succession.
  • Data Freshness: Models are fetched from the Hugging Face API. Recent changes may take time to reflect.

Reference

See Hugging Face API Documentation for more details on model metadata and available filters.

安全使用建议
This skill appears coherent and low-risk for its stated purpose, but review these practical points before installing or running it: 1) Inspect the included script (already provided) to confirm it meets your expectations — it only performs GET requests to Hugging Face and writes JSON if requested. 2) Do not blindly use the example proxy (http://172.28.96.1:10808); verify you control or trust any proxy you configure, since traffic will route through it. 3) The SKILL.md shows a cron example with a specific home path (/home/ltx/...); adjust paths to your environment and avoid running scheduled jobs as root. 4) Install dependencies (pip install requests) in a virtualenv if you prefer containment. 5) If your environment has strict network policies, confirm that outgoing HTTPS to huggingface.co (or the chosen proxy) is permitted. 6) If you need higher assurance, run the script in a sandboxed environment first to observe network behavior.
功能分析
Type: OpenClaw Skill Name: huggingface-trends Version: 1.0.0 The skill is classified as suspicious due to a critical arbitrary file write vulnerability in `scripts/hf_trends.py` where the `output_file` parameter for JSON export is not sanitized, allowing for potential path traversal. Additionally, the `SKILL.md` explicitly instructs the AI agent to set up a cron job for daily monitoring, which, while used for a benign purpose in this context, demonstrates a persistence capability that could be exploited. There is no clear evidence of intentional malicious activity like data exfiltration to external C2 servers or unauthorized remote code execution.
能力评估
Purpose & Capability
Name/description match the included script and SKILL.md: the Python script calls the Hugging Face /models API, sorts/filter results, formats output, and can export JSON. No unrelated binaries or credentials are requested.
Instruction Scope
Runtime instructions only call the included script and show examples (including cron and programmatic usage). Examples reference a local proxy (http://172.28.96.1:10808) and a user-specific path (/home/ltx/...) — these are environment-specific examples, not required operations. The SKILL.md does show shell snippets (e.g., using ip route/awk) to construct a proxy URL; those are examples and not embedded backdoor behavior, but they would execute on the host if a user ran them.
Install Mechanism
No install spec; this is instruction-only with an included Python script. The only dependency is the requests package (the SKILL.md tells users to pip install requests). No downloads from remote URLs or archive extraction are used.
Credentials
The skill requires no environment variables, credentials, or config paths. Network access is needed to call the Hugging Face API and an optional HTTP proxy can be supplied; this is proportionate to the stated functionality.
Persistence & Privilege
The skill is not forced-always and does not modify other skills or system-wide settings. The cron example in SKILL.md is user-provided guidance only and not an automatic action by the skill.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install huggingface-trends
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /huggingface-trends 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of huggingface-trends. - Fetches trending Hugging Face models with filters for task (e.g., text-generation), library (e.g., pytorch), and sort order (trending, likes, downloads). - Supports exporting results to JSON and displaying in a structured, formatted output. - Requires HTTP proxy configuration for Hugging Face API access, suitable for constrained network environments. - Provides command-line and Python API usage for daily monitoring or research. - Includes troubleshooting tips and use cases for model discovery and comparison.
元数据
Slug huggingface-trends
版本 1.0.0
许可证
累计安装 5
当前安装数 5
历史版本数 1
常见问题

Huggingface Trends 是什么?

Monitor and fetch trending models from Hugging Face with support for filtering by task, library, and popularity metrics. Use when users want to check trending AI models, compare model popularity, or explore popular models by task or library. Supports export to JSON and formatted output. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 1252 次。

如何安装 Huggingface Trends?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install huggingface-trends」即可一键安装,无需额外配置。

Huggingface Trends 是免费的吗?

是的,Huggingface Trends 完全免费(开源免费),可自由下载、安装和使用。

Huggingface Trends 支持哪些平台?

Huggingface Trends 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Huggingface Trends?

由 tianxingleo(@tianxingleo)开发并维护,当前版本 v1.0.0。

💬 留言讨论