← ClaudeAtlas

image-auditlisted

自动化图片内容审核工作流。支持鉴黄、政治、暴恐识别,自动压缩图片并批量调用审核服务, 以表格汇总结果。Use when auditing images, checking image content, scanning photos for inappropriate material.
xiaowu89/skill-function · ★ 3 · AI & Automation · score 63
Install: claude install-skill xiaowu89/skill-function
# Image Content Moderation Audit images for adult, political, and violent content using the nx-mcp-audit MCP service. ## 配置 在项目根目录创建 `.mcp.json`: ```json { "mcpServers": { "nx-mcp-audit": { "type": "url", "url": "https://mcp.api-inference.modelscope.net/da16b3f65bdb4e/mcp", "env": { "NX_API_KEY": "你的 API Key" } } } } ``` 查找顺序:项目根目录 → 用户家目录。提取 `url` → `MCP_URL`,`env.NX_API_KEY` → `API_KEY`。 Skill 直连 MCP 端点,**无需重启 Claude Code**。 > **No API Key?** 请联系服务提供商获取。 ## 审核流程 ### 步骤 1:检查配置(缺少则立即停止) ```bash cat .mcp.json 2>/dev/null || cat ~/.mcp.json 2>/dev/null ``` - 找到 → 记录 `url` 和 `NX_API_KEY`,继续步骤 2 - 找不到 → 询问用户是否已有 API Key: - **有 Key**:帮用户创建 `~/.mcp.json`(用户家目录),全局和项目安装都通用 - **没有 Key**:告知联系服务提供商获取,等用户拿到后回来配置 > ⚠️ 配置缺失时不要安装 sharp 或继续后续步骤,先解决配置再往下走。 ### 步骤 2:安装 sharp + 执行审核(一次 Bash 调用,纯内存,零文件) 替换 `PIC_DIR`、`MCP_URL`、`API_KEY` 后执行: ```bash NODE_PATH=$(npm root -g) node -e "require('sharp')" 2>/dev/null || npm install -g sharp NODE_PATH=$(npm root -g) node << 'AUDITEOF' const fs=require('fs'),path=require('path'),sharp=require('sharp'); const PIC_DIR='<目标图片目录绝对路径>'; const MCP_URL='<从.mcp.json读取的url>'; const API_KEY='<从.mcp.json读取的NX_API_KEY>'; (async()=>{ const exts=['.png','.jpg','.jpeg','.webp','.bmp','.tga']; const imgs=fs.readdirSync(PIC_DIR).filter(f=>exts.includes(path.extname(f).toLowerCase())).sort(); const origTotal=imgs.reduce((s,f)=>s+fs.statSync(path.join(PIC_DIR,f)).size,0); console.log(`共 ${imgs.length} 张,总 ${(