NSFW 检测与成人内容过滤 - Openclaw Skills

作者:互联网

2026-04-17

AI教程

什么是 NSFW 检测技能?

NSFW 检测技能提供了一套强大的工具,旨在通过识别不当或成人内容来维护数字安全。该 Openclaw 技能集利用本地 ONNX 模型进行高性能图像分类,并结合域名信誉数据库,在不牺牲隐私的情况下阻止访问有害网站。

通过集成这些工具,开发者可以为用户构建更安全的环境,通过上下文感知过滤保护儿童和敏感工作流免受显性内容侵害。该系统设计为本地运行,确保敏感数据永远不会离开宿主环境,同时在各类显性图像检测中保持高准确度。

下载入口:https://github.com/openclaw/skills/tree/main/skills/raghulpasupathi/nsfw-detection

安装与下载

1. ClawHub CLI

从源直接安装技能的最快方式。

npx clawhub@latest install nsfw-detection

2. 手动安装

将技能文件夹复制到以下位置之一

全局模式 ~/.openclaw/skills/ 工作区 /skills/

优先级:工作区 > 本地 > 内置

3. 提示词安装

将此提示词复制到 OpenClaw 即可自动安装。

请帮我使用 Clawhub 安装 nsfw-detection。如果尚未安装 Clawhub,请先安装(npm i -g clawhub)。

NSFW 检测技能 应用场景

  • 在 Web 应用中自动拦截瑟琴和显性图像。
  • 域名级预过滤,防止访问已知的成人网站。
  • 通过严格的安全分级保护儿童和未成年人免受有害网络内容侵害。
  • 为社区平台和论坛提供 AI 辅助的内容审核。
  • 根据特定用户年龄组实施分级安全水平(严格、平衡、宽松)。
NSFW 检测技能 工作原理
  1. 系统启动域名信誉检查,在进行视觉分析之前快速识别并拦截已知的成人 URL。
  2. 如果 URL 通过检查,图像检测技能将获取视觉内容,并通过本地 ONNX 模型进行处理。
  3. 模型进行多类别分类,对瑟琴、变态(hentai)或暗示性主题进行评分。
  4. 上下文感知逻辑根据配置设置对医疗或艺术内容应用例外处理。
  5. 该技能向宿主应用程序返回置信度分数和建议操作,以完成审核工作流。

NSFW 检测技能 配置指南

通过 npm

安装视觉检测和信誉检查所需的特定包:

npm install @clawhub/nsfw-detector
npm install @clawhub/url-reputation

通过 ClawHub

您也可以直接通过 Openclaw Skills 仓库集成完整的检测套件:

https://clawhub.ai/raghulpasupathi/nsfw-detection

NSFW 检测技能 数据架构与分类体系

属性 类型 描述
isNSFW 布尔值 指示内容是否超过安全阈值。
confidence 浮点数 检测的概率分数(0.0 到 1.0)。
categories 对象 瑟琴、性感、变态和绘画的详细细分。
action 字符串 建议的处理指令(例如 'block'、'warn')。
contextAware 布尔值 系统是否考虑了医疗或艺术例外情况。

NSFW Detection Skills

Skills for detecting adult/inappropriate content.

Essential Skills

1. NSFW Detector Pro

Skill ID: nsfw-detector-pro

Purpose: Advanced NSFW content detection

Features:

  • Multi-category classification (porn, sexy, hentai, drawings)
  • Confidence scoring (0-100%)
  • Skin tone detection
  • Context awareness (medical, art exceptions)
  • Local ONNX model (no external API)

Installation:

npm install @clawhub/nsfw-detector

Configuration:

{
  "skill": "nsfw-detector-pro",
  "settings": {
    "categories": ["porn", "sexy", "hentai"],
    "threshold": 0.7,
    "contextAware": true,
    "allowArt": true,
    "allowMedical": true,
    "localModel": true
  }
}

Usage:

import { detectNSFW } from '@clawhub/nsfw-detector';

const result = await detectNSFW(imageUrl);
// {
//   isNSFW: true,
//   confidence: 0.92,
//   categories: { porn: 0.92, sexy: 0.15 },
//   action: 'block'
// }

Accuracy: 92-95% on explicit content, 75-80% on suggestive

Use Cases:

  • Block pornography and explicit imagery
  • Filter adult websites
  • Protect children online

Troubleshooting:

  • False positives on art? Enable allowArt
  • Medical images blocked? Enable allowMedical
  • Increase threshold for fewer false positives

Related Skills: url-reputation, content-blur


2. URL Reputation Checker

Skill ID: url-reputation

Purpose: Check if domains are adult/inappropriate sites

Features:

  • Domain reputation database
  • Adult site detection
  • Phishing/malware detection
  • Cached lookups

Installation:

npm install @clawhub/url-reputation

Use Cases:

  • Block adult websites by domain
  • Fast pre-filtering before image analysis
  • Supplement visual detection

Installation

Via ClawHub

https://clawhub.ai/raghulpasupathi/nsfw-detection

Via npm

npm install @raghulpasupathi/nsfw-detection

Configuration Examples

Child Protection (Strict)

{
  "nsfw-detector-pro": {
    "threshold": 0.3,
    "blockAll": true,
    "allowArt": false,
    "allowMedical": false,
    "allowOverride": false
  }
}

Teen Protection (Balanced)

{
  "nsfw-detector-pro": {
    "threshold": 0.7,
    "allowArt": true,
    "allowMedical": true,
    "allowOverride": false
  }
}

Adult Filtering (Lenient)

{
  "nsfw-detector-pro": {
    "threshold": 0.9,
    "warnOnly": true,
    "allowOverride": true
  }
}

For violence detection, see VIOLENCE_DETECTION.md.

相关推荐