npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

tp-image-collector

v2.5.1

Published

MCP 图片采集工具 - 采集网页上的图片并保存到桌面

Readme

tp-image-collector

基于 MCP (Model Context Protocol) 的网页图片采集工具。

功能特点

  • 🌐 一键采集 - 输入网址即可自动采集页面所有图片
  • 🖼️ 多格式支持 - 支持 JPG、PNG、WEBP、AVIF、GIF 五种格式
  • 📁 自动分类 - 图片按格式自动分类存放到子目录
  • 🔍 智能过滤 - 自动过滤 50x50 以下的小图(图标、占位符等)
  • 📊 实时预览 - 采集完成后弹窗显示明细列表,支持按类型筛选
  • 📂 自动打开 - 采集完成自动打开保存目录

快速开始

安装依赖

cd src/tp-image-collector
npm install
npx playwright install chromium

编译运行

npm run build
npm start

配置

Claude Desktop

编辑 %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "tp-image-collector": {
      "command": "node",
      "args": ["E:/mcp/3d66.mcp/src/tp-image-collector/build/index.js"]
    }
  }
}

Claude Code CLI

claude mcp add --scope user tp-image-collector node E:/mcp/3d66.mcp/src/tp-image-collector/build/index.js

注意:将路径替换为你的实际项目路径

使用方法

对 Claude 说:

采集图片 https://example.com/gallery

请打开这个网址,采集图片:https://example.com/

采集流程

  1. 启动浏览器访问目标网页
  2. 显示"采集中"弹窗
  3. 提取页面所有图片链接和尺寸
  4. 过滤小图,保留有效图片
  5. 在桌面创建 图片采集_域名_时间戳 目录
  6. 按类型分类下载到子目录(jpg/、png/、webp/、avif/、gif/)
  7. 显示采集结果明细(支持 Tab 筛选)
  8. 自动打开保存目录

项目结构

tp-image-collector/
├── src/
│   ├── index.ts      # MCP 服务入口
│   ├── collector.ts  # 采集核心逻辑
│   ├── download.ts   # 下载功能
│   ├── overlay.ts    # 页面弹窗模板
│   └── utils.ts      # 工具函数
├── build/            # 编译输出
├── package.json
└── tsconfig.json

技术栈

注意事项

  • 浏览器以可见窗口模式运行,采集完成后不会自动关闭
  • 图片保留原始文件名,重名文件自动添加后缀
  • 单张图片下载超时 10 秒,失败不影响整体流程
  • 保存路径:{用户桌面}/图片采集_域名_时间戳/

许可证

MIT