# Hugging Face Trending AI Models & Datasets Scraper 🤗⚡ (`environmental_audio/huggingface-trending-scraper`) Actor

Scrape trending AI models and datasets on Hugging Face. Extract model ID, author, stars/likes, downloads, trending score, pipeline tags, licenses, and direct URLs without API tokens.

- **URL**: https://apify.com/environmental_audio/huggingface-trending-scraper.md
- **Developed by:** [Rahul Kasturiya](https://apify.com/environmental_audio) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 trending model / datasets

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Hugging Face Trending AI Models & Datasets Scraper 🤗⚡

Monitor and extract trending AI models, open-source weights, and datasets directly from **Hugging Face**.

Track the latest LLMs, image generation models, speech models, and fine-tuning datasets as they surge in popularity.

***

### 🌟 Features

- **Models & Datasets:** Switch seamlessly between scraping trending AI models or datasets.
- **Multiple Ranking Metrics:** Rank by **Trending Score**, **Most Likes/Stars**, **Total Downloads**, or **Recently Updated**.
- **Task & Tag Filtering:** Filter by pipeline tag (`text-generation`, `image-to-text`, `automatic-speech-recognition`, `text-to-image`) or search keywords (e.g. `deepseek`, `qwen`, `whisper`).
- **Rich Metadata Extracted:** Model ID, author/organization, direct URL, likes, download volume, trending score, pipeline tag, license, gated/private status, and commit SHA.
- **Fast & Token-Free:** Requires zero Hugging Face API keys or login credentials.

***

### 📥 Input Parameters

| Parameter | Type | Required | Description | Default |
| :--- | :--- | :--- | :--- | :--- |
| `itemType` | String (select) | No | Scrape `models` or `datasets`. | `models` |
| `sort` | String (select) | No | `trendingScore`, `likes`, `downloads`, or `lastModified`. | `trendingScore` |
| `searchQuery` | String | No | Search query to filter items (e.g. `deepseek`, `qwen`). | `""` |
| `pipelineTag` | String | No | Filter by Hugging Face task tag (e.g. `text-generation`). | `""` |
| `limit` | Number | No | Total number of items to return (1-200). | `50` |

***

### 📤 Sample Output JSON

```json
{
  "id": "Qwen/Qwen3.8-27B",
  "itemType": "Model",
  "author": "Qwen",
  "url": "https://huggingface.co/Qwen/Qwen3.8-27B",
  "likes": 4210,
  "downloads": 185420,
  "trendingScore": 3120,
  "pipelineTag": "text-generation",
  "license": "apache-2.0",
  "tags": [
    "transformers",
    "safetensors",
    "text-generation",
    "conversational"
  ],
  "private": false,
  "gated": false,
  "lastModified": "2026-11-10T12:00:00.000Z",
  "sha": "e9a8f7c6b5a4..."
}
```

***

### 💡 Use Cases

- **AI Market Intelligence:** Track which model architectures (e.g. DeepSeek, Qwen, Mistral, LLaMA) are gaining traction in the open-source community.
- **Automated AI Newsletters & Bots:** Build automated digests of daily top 10 trending models and datasets.
- **Model Registry Syncing:** Continuously monitor new fine-tunes and checkpoint releases for your AI applications.
- **Benchmark & Research Tracking:** Identify high-download datasets for evaluation and training pipelines.

# Actor input Schema

## `itemType` (type: `string`):

Choose whether to scrape AI models or datasets.

## `sort` (type: `string`):

Sort items by trending score, total likes/stars, total downloads, or recent updates.

## `searchQuery` (type: `string`):

Optional search query to filter models or datasets (e.g. 'deepseek', 'qwen', 'whisper', 'vision'). Leave blank for all.

## `pipelineTag` (type: `string`):

Optional Hugging Face task tag (e.g. 'text-generation', 'image-to-text', 'automatic-speech-recognition', 'text-to-image').

## `limit` (type: `integer`):

Total number of models or datasets to scrape (default: 50, max: 200).

## Actor input object example

```json
{
  "itemType": "models",
  "sort": "trendingScore",
  "searchQuery": "deepseek",
  "limit": 25
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "itemType": "models",
    "sort": "trendingScore",
    "searchQuery": "deepseek",
    "limit": 25
};

// Run the Actor and wait for it to finish
const run = await client.actor("environmental_audio/huggingface-trending-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "itemType": "models",
    "sort": "trendingScore",
    "searchQuery": "deepseek",
    "limit": 25,
}

# Run the Actor and wait for it to finish
run = client.actor("environmental_audio/huggingface-trending-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "itemType": "models",
  "sort": "trendingScore",
  "searchQuery": "deepseek",
  "limit": 25
}' |
apify call environmental_audio/huggingface-trending-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,environmental_audio/huggingface-trending-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/TkfxDfhN4kqYaQEU3/builds/KvMKgjKkOs4oUiEBh/openapi.json
