← 返回 Skills 市场
bbniao100

brand-sentinel

作者 bbniao100 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
74
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install brand-sentinel
功能描述
品牌舆情哨兵:搜索公开平台的品牌相关信息,自动去重和时效过滤,输出结构化结果供 LLM 做风险分级和预警。 触发场景:监控某品牌/产品的公开舆情、搜索负面信息并按时间筛选、定时巡查品牌口碑、竞品舆情对比。 关键词:品牌监控、舆情搜索、负面信息、口碑巡查、舆情预警、品牌声誉、sentinel、舆情哨兵。 不做的事:...
使用说明 (SKILL.md)

brand-sentinel — 品牌舆情哨兵

搜索公开平台的品牌相关信息 → 去重 → 时效过滤 → 输出结构化结果。

核心脚本

scripts/sentinel.py — 纯 Python(无第三方依赖),调用 AutoGLM Web Search API。

依赖

  • Python 3.10+
  • 本地 AutoGLM Token 服务运行中(http://127.0.0.1:18432/get_token
  • certifi 包(SSL 证书,通常已预装)

用法

命令行

# 基本用法
python3 scripts/sentinel.py --brand "特斯拉" --keywords "刹车失灵,自燃" --hours 48

# JSON 输出(供 LLM 消费)
python3 scripts/sentinel.py --brand "瑞幸咖啡" --keywords "食品安全,蟑螂" --hours 24 --output json

# 配置文件模式
python3 scripts/sentinel.py --config references/config-example.json

参数

参数 必填 说明
--brand 是* 品牌名,如 "特斯拉"
--keywords 是* 逗号分隔的关键词,如 "刹车失灵,自燃"
--hours 时效窗口(小时),默认 48
--output text(默认)或 json
--config 是* JSON 配置文件路径(替代上方参数)

* --brand+--keywords--config 二选一。

配置文件格式

references/config-example.json

{
  "brand": "品牌名",
  "keywords": ["关键词1", "关键词2"],
  "hours": 48,
  "output": "json"
}

输出结构

JSON 模式

{
  "brand": "特斯拉",
  "run_time": "2026-04-14 19:00:00",
  "time_window_hours": 48,
  "keywords": ["刹车失灵", "自燃"],
  "stats": {
    "raw_count": 85,
    "kept_count": 62,
    "expired_count": 8,
    "no_date_count": 15
  },
  "items": [
    {
      "title": "页面标题",
      "url": "页面链接",
      "snippet": "摘要内容",
      "date_status": "recent|expired|unknown",
      "parsed_date": "2026-04-14|null"
    }
  ]
}

字段说明

  • date_status:
    • recent — 解析到日期且在时效窗口内 ✅
    • expired — 解析到日期但超出时效窗口(已被过滤掉)
    • unknown — 未解析到日期(搜索词含"最新"限定,大概率近期,默认保留)
  • parsed_date — 从标题/摘要提取的日期,解析失败为 null

工作流程

  1. 构建搜索词 — 对每个关键词自动生成 3 种变体:原始词、+ 最新+ 当前年月
  2. 批量搜索 — 调用 autoglm-websearch,每个词间隔 0.3s
  3. URL 去重 — 同一 URL 只保留首次出现
  4. 日期解析 — 从标题+摘要中提取日期(支持"2026年4月14日"、"3天前"、"昨天"等中文格式)
  5. 时效过滤 — 超出时间窗口的结果丢弃,无日期的默认保留
  6. 输出 — text 或 json 格式

典型 Agent 工作流

用户: "帮我看看特斯拉最近有什么负面新闻"

1. Agent 调用 sentinel.py:
   python3 scripts/sentinel.py --brand "特斯拉" --keywords "刹车失灵,自燃,自动驾驶事故,降价维权" --hours 48 --output json

2. Agent 读取 JSON 输出,用 LLM 判断:
   - 哪些是真正的负面/危机
   - 风险分级(普通/关注/严重/危机)
   - 是否需要预警

3. Agent 生成人类可读的摘要推送给用户

注意事项

  • 搜索 API 有速率限制,关键词数量建议 ≤10 组(每组会生成 3 个变体,共 30 次搜索)
  • 日期解析基于正则匹配,覆盖率约 60-70%,未解析到的默认保留
  • 搜索词加"最新"限定可提升近期结果命中率,但不能保证 100% 时效性
  • 如需跨次运行去重,Agent 可自行维护 URL 集合
安全使用建议
This skill appears coherent for brand monitoring, but check two things before installing: (1) the script expects a local token service at http://127.0.0.1:18432/get_token — only run this skill if you know and trust that local service (it supplies the Bearer token used to call the remote search API); (2) the repo contains a hardcoded APP_ID/APP_KEY — treat these as public/stale secrets unless you can verify their provenance. Run the script in an isolated environment if unsure, inspect or replace the token provider with one you control, and avoid supplying any unrelated system credentials. If you need stronger assurance, request the author/source and confirm the intended AutoGLM endpoint and key lifecycle.
功能分析
Type: OpenClaw Skill Name: brand-sentinel Version: 1.0.0 The script `scripts/sentinel.py` contains hardcoded API credentials (`APP_KEY`) and relies on an unauthenticated local service (`127.0.0.1:18432`) for token retrieval, which are significant security vulnerabilities. While the code logic is consistent with the stated brand monitoring purpose and no evidence of intentional data exfiltration or malicious execution was found, the inclusion of static secrets and reliance on local network services represent high-risk development practices.
能力评估
Purpose & Capability
The name/description (brand monitoring, de-duplication, time filtering, JSON output) matches the implementation: scripts/sentinel.py calls a web-search API, builds queries, deduplicates URLs, parses dates and emits structured JSON/text. No unrelated binaries, env vars, or config paths are requested.
Instruction Scope
SKILL.md simply instructs the agent to run scripts/sentinel.py or provide a config file. The runtime instructions and the script do not ask the agent to read arbitrary system files or exfiltrate unrelated data. The only runtime network interactions are to a web-search API and a local token service as documented.
Install Mechanism
There is no install spec (instruction-only with an included script). The Python script has no third‑party install step other than optional certifi. No downloads from untrusted URLs or archive extraction are present.
Credentials
The skill does not request environment variables, which is proportional. Two items deserve attention: (1) the script requires a local AutoGLM token service at http://127.0.0.1:18432/get_token — this is an explicit runtime dependency and the token service must be trusted (it provides an Authorization Bearer token used for remote searches); (2) the script contains hardcoded APP_ID and APP_KEY values. Hardcoded keys in shipped code are a maintenance/security smell (they may be public or stale) but are coherent with the code's authentication scheme.
Persistence & Privilege
The skill does not request persistent/always-on inclusion and does not modify other skills or system-wide agent settings. It runs only when invoked.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install brand-sentinel
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /brand-sentinel 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
首版:品牌舆情搜索+去重+时效过滤
元数据
Slug brand-sentinel
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

brand-sentinel 是什么?

品牌舆情哨兵:搜索公开平台的品牌相关信息,自动去重和时效过滤,输出结构化结果供 LLM 做风险分级和预警。 触发场景:监控某品牌/产品的公开舆情、搜索负面信息并按时间筛选、定时巡查品牌口碑、竞品舆情对比。 关键词:品牌监控、舆情搜索、负面信息、口碑巡查、舆情预警、品牌声誉、sentinel、舆情哨兵。 不做的事:... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 74 次。

如何安装 brand-sentinel?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install brand-sentinel」即可一键安装,无需额外配置。

brand-sentinel 是免费的吗?

是的,brand-sentinel 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

brand-sentinel 支持哪些平台?

brand-sentinel 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 brand-sentinel?

由 bbniao100(@bbniao100)开发并维护,当前版本 v1.0.0。

💬 留言讨论