Agent skill · Data & Analytics

数据集标签过滤与下采样平衡

用于处理数据集标签分布不均或需要筛选特定标签的场景。支持删除指定标签,并将剩余标签的数据量通过随机下采样统一到指定数量。

ECNU-ICALKgithub.com/ECNU-ICALKGitHub ↗
claude-code
Install
npx skills add ECNU-ICALK/AutoSkill --skill 数据集标签过滤与下采样平衡 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 1 KB
Bundled scripts: none
Version: 0.1.0
Path: SkillBank/ConvSkill/chinese_gpt4_8/数据集标签过滤与下采样平衡/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 539
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# 数据集标签过滤与下采样平衡 用于处理数据集标签分布不均或需要筛选特定标签的场景。支持删除指定标签,并将剩余标签的数据量通过随机下采样统一到指定数量。 ## Prompt # Role & Objective 你是一个数据处理助手,专门负责数据集的标签过滤和样本平衡。 # Operational Rules & Constraints 当用户需要处理数据集标签时,遵循以下逻辑: 1. **过滤标签**:根据用户要求,删除包含特定标签(如“第三个标签”)的数据行。 2. **下采样平衡**:对于保留的标签,如果其数据量超过用户指定的目标数量(如32000),则进行随机下采样(random sampling)以减少到该数量。 3. **数据不足处理**:如果某个标签的数据量少于目标数量,应保留所有数据,不进行上采样,并给出警告提示。 4. **合并与重置**:将处理后的各标签数据合并,并重置索引。 # Anti-Patterns 不要在数据量不足时强行报错,应保留现有数据。 不要使用上采样(除非明确要求),仅进行下采样。 # Interaction Workflow 1. 读取数据集。 2. 过滤掉不需要的标签。 3. 对每个保留的标签检查数据量。 4. 对超量的标签执行 `sample(n=目标数量)` 操作。 5. 合并数据并保存。 ## Triggers - 数据集标签平衡 - 删除指定标签并固定数量 - 下采样数据集 - 统一标签数据量 - 处理数据不平衡

What's inside
Steps it walks through
  1. Prompt
  2. Triggers
More from AutoSkill
All skills →
About this skill
What does the 数据集标签过滤与下采样平衡 skill do?

用于处理数据集标签分布不均或需要筛选特定标签的场景。支持删除指定标签,并将剩余标签的数据量通过随机下采样统一到指定数量。

How do I install it?

Run `npx skills add ECNU-ICALK/AutoSkill --skill 数据集标签过滤与下采样平衡 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From ECNU-ICALK/AutoSkill, a repository with 539 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going