visual-file-sorter

自动遍历下载文件夹或桌面,利用视觉模型“看”文件内容并重命名,最后归档到指定分类目录。

3,891 stars

Best use case

visual-file-sorter is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

自动遍历下载文件夹或桌面,利用视觉模型“看”文件内容并重命名,最后归档到指定分类目录。

Teams using visual-file-sorter should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/visual-file-sorter/SKILL.md --create-dirs "https://raw.githubusercontent.com/openclaw/skills/main/skills/anotherj1/visual-file-sorter/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/visual-file-sorter/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How visual-file-sorter Compares

Feature / Agentvisual-file-sorterStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

自动遍历下载文件夹或桌面,利用视觉模型“看”文件内容并重命名,最后归档到指定分类目录。

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# 视觉系文件分类大师 (Visual File Sorter)

## 🎯 核心目标
你的任务是作为一个本地数字管家,自动清理用户杂乱的“下载 (Downloads)”或“桌面 (Desktop)”文件夹。你需要完全模拟人类“双击打开 -> 查阅内容 -> 总结命名 -> 拖拽归档”的物理工作流。

## 💡 触发条件
当用户发送类似以下指令时触发此工作流:
* “帮我整理一下下载文件夹”
* “归档桌面上的杂乱文件”
* “执行桌面清理”



## 📋 执行步骤

### 第一步:获取待处理队列
1. 使用终端工具列出目标文件夹(默认 `~/Downloads`)中的所有文件。
2. 自动过滤并跳过系统隐藏文件(如 `.DS_Store`)和正在下载的临时文件(如 `.crdownload`, `.part`)。

### 第二步:模拟人类视觉阅读(核心循环)
针对队列中的每一个文件,严格执行以下动作:
1. **打开文件:** 使用操作系统的默认程序或命令(如 Mac 的 `open`,Windows 的 `start`)打开该文件。
2. **视觉抓取:** 等待 1-2 秒确保软件 UI 渲染完成。使用你的**屏幕视觉能力 (Computer Use - Vision)** 截取当前屏幕,阅读并理解文件内容。
3. **内容提炼:** 在后台分析该文件是什么(如:餐饮发票、租房合同、搞笑表情包、技术 PDF)。提取关键元数据(如发票日期、公司名称、主要内容)。
4. **关闭窗口:** 模拟按下关闭快捷键(如 `Cmd+W` 或 `Alt+F4`),退出预览界面。

### 第三步:智能重命名
基于上一步的视觉分析结果,按以下规则生成新的文件名,并使用 Shell 命令执行重命名:
* **财务报销类(发票/收据):** `[YYYY-MM]_发票_[公司或摘要].[扩展名]`
* **工作/正式文档:** `[YYYY-MM-DD]_[文档核心主题].[扩展名]`
* **图片/多媒体素材:** `[画面内容描述].[扩展名]`
* *异常处理:如果内容无法识别或受密码保护,保留原文件名,并在前缀加上 `未分类_`。*

### 第四步:物理归档
检查目标归档目录 `~/Documents/Sorted/` 是否存在,如果不存在则自动创建。随后将重命名后的文件移动到以下对应的子文件夹中:
* `.../Sorted/财务账单/`
* `.../Sorted/工作文档/`
* `.../Sorted/图片素材/`
* `.../Sorted/其他未分类/`

## ⚠️ 安全与操作红线
1. **禁止删除:** 你仅拥有重命名和移动的权限。无论文件看起来多么像“垃圾文件”,绝对不允许执行 `rm` 或将其移入回收站。
2. **扩展名保护:** 严禁修改文件的后缀名(扩展名),哪怕你认为它是一个伪装的文件,也只能修改 `.` 之前的文件名部分。
3. **隐私隔离:** 视觉识别必须依赖本地或默认的视觉大模型通道,不得擅自编写脚本将截图或文本内容发送到未授权的第三方外部 API。

Related Skills

filesystem

3891
from openclaw/skills

Advanced filesystem operations for listing files, searching content, batch processing, and directory analysis. Supports recursive search, file type filtering, size analysis, and batch operations like copy/move/delete. Use when you need to: list directory contents, search for files by name or content, analyze directory structures, perform batch file operations, or analyze file sizes and distribution.

General Utilities

file-organizer-skill

3891
from openclaw/skills

Organize files in directories by grouping them into folders based on their extensions or date. Includes Dry-Run, Recursive, and Undo capabilities.

General Utilities

3d-wordcloud-visualizer

3891
from openclaw/skills

3D 词云可视化工具 - 将对话历史或其他文本数据自动转换为炫酷的 3D 地球词云,支持多格式文件导入(JSON/MD/TXT),自动中文分词和词频统计,生成 TOP30 高频词的 3D 可视化效果

Data Visualization

visual-explainer

3891
from openclaw/skills

Generate beautiful, self-contained HTML pages that visually explain systems, code changes, plans, and data. Use when the user asks for a diagram, architecture overview, diff review, plan review, project recap, comparison table, or any visual explanation of technical concepts. Also use proactively when you are about to render a complex ASCII table (4+ rows or 3+ columns) — present it as a styled HTML page instead.

visual-note-card

3891
from openclaw/skills

Generate professional Chinese visual note cards (视觉笔记卡片/信息图) as single-page HTML infographics with automatic PNG export. Use this skill whenever the user asks to create a visual note, knowledge card, infographic, one-pager summary, visual summary, 知识卡片, 视觉笔记, 信息图, 一页纸总结, or any poster-style knowledge visualization. Also trigger when the user wants to summarize an article, blog post, book chapter, or concept into a structured visual card format, or when they reference an existing visual note and ask to create one in the same style. This skill produces both a self-contained HTML file and a high-quality PNG image, ready for sharing on social media or printing.

visual-muse

3891
from openclaw/skills

ComfyUI 图像生成工坊 — 用自然语言描述需求,自动生成高质量 AI 图片。支持 SDXL/Flux 多模型、风格模板自动匹配、批量生成、质量评分。说「画一张图」即可触发。

file-upload

3891
from openclaw/skills

上传文件到内部 BS3 存储(免签名)。Use when user asks to upload files, images, documents to storage, or get a shareable URL for a file.

hinge-profile-optimizer

3891
from openclaw/skills

Comprehensive, research-backed Hinge dating profile optimization. Use when someone wants to improve their Hinge profile, audit an existing profile, write better prompts/captions, select and order photos strategically, or understand why they're not getting quality matches. This is the thorough process (~45 mins) - discovery interview, honest market math, photo strategy, copy creation, settings cleanup, and implementation support. Grounded in peer-reviewed behavioral research, platform data, and signaling theory.

mermaid-visualizer

3891
from openclaw/skills

Transform text content into professional Mermaid diagrams for presentations and documentation. Use when users ask to visualize concepts, create flowcharts, or make diagrams from text. Supports process flows, system architectures, comparisons, mindmaps, and more with built-in syntax error prevention.

static-files

3891
from openclaw/skills

Host static files on subdomains with optional authentication. Use when you need to serve HTML, images, CSS, JS, or any static content on a dedicated subdomain. Supports file upload, basic auth, quota management, and automatic SSL via Caddy. Commands include sf sites (create/list/delete), sf upload (files/directories), sf files (list/delete).

Twitter/X Profile Scraper

3891
from openclaw/skills

A browser-based Twitter/X profile discovery and scraping tool.

TikTok Profile Scraper

3891
from openclaw/skills

A browser-based TikTok profile discovery and scraping tool.