Command Palette

Search for a command to run...

UnylyUnyly
Back to skills

jf-smart-store-inspection

FreeRuns bundled scriptsNot checked

杰峰蜂云智慧巡店部署与AI巡检运营技能。通过工作流完成门店创建、监控设备接入(GB28181/ONVIF+自研NVR/杰峰自研IPC)、AI巡检算法查询、AI巡检计划配置(离岗/工服/跌倒/客流/安全帽/视频质量诊断等)、检测区域画框、计划启停与巡检记录聚合,并生成含抓拍图墙的HTML分析报告。当用户提到智慧巡店、A…

jftechby jftech403 installs in other catalogs

About this skill

杰峰智慧巡店部署技能

1. 技能描述

本技能覆盖蜂云 SaaS「智慧巡店」行业方案的完整接入与AI巡检运营,与 jf-store-traffic(精准客流)、jf-store-plate-recognition(车牌识别)共用同一套开放平台签名与门店/设备管理骨架,专注 AI巡检计划 与 巡检记录 的全生命周期:

  • 门店管理 -- 创建 / 修改 / 删除门店(/rtc/store/*)
  • 设备管理 -- 添加 / 删除杰峰IPC(/rtc/device/addJfIpc、/rtc/device/delete)
  • AI巡检算法目录 -- 分页查询已授权的算法及默认参数(aiPatrolAlgorithmPageQuery)
  • AI巡检计划 -- 新增 / 编辑 / 分页查询 / 详情 / 启用 / 停用 / 删除(aiPatrolAddOrEdit、aiPatrolPageQuery、aiPatrolDetail、aiPatrolStartAndStop、aiPatrolDelete)
  • AI巡检记录 -- 分页查询巡检触发记录(含抓拍图 cloudPictureUrl)、按设备/算法/日期聚合、HTML 可视化报告(aiPatrolRecordPageQuery)
  • 交互式区域画框 -- 基于设备快照绘制 includeAreas 多边形,8192 相对坐标输出
  • 有状态会话模型 -- session.json 自动串联 store → device → patrolPlan

字段级 API 细节(请求/响应字段、状态码、算法目录字段含义)集中在 references/api-reference.md,需要时再读取。

数据消费方式: AI巡检记录通过 aiPatrolRecordPageQuery 主动分页拉取(不依赖回调),本技能 patrol-report 命令一次性抓取时间区间内所有记录并聚合成 HTML 报告。

2. 前置条件

2.1 服务开通

  • 智慧巡店订阅:5 店免费,超出 ¥25/店/月,按门店数计费(不含摄像头路数)。开通入口:企业管理 → 企业套餐。
  • AI算法授权:AI巡检依赖算法中心的对应算法授权(离岗检测 / 工服检测 / 电动车检测 / 跌倒检测 / 未戴安全帽 / 视频质量诊断 / 客流检测 等),按算法计费。
  • 摄像头接入:门店摄像头需支持 GB28181 / ONVIF+杰峰自研NVR / 杰峰自研IPC,并归属到门店节点。

2.2 环境变量

变量名 必填 说明 默认值
JF_UUID 是 开放平台用户 uuid -
JF_APP_KEY 是 应用 appKey -
JF_APP_SECRET 是 应用 appSecret -
JF_MOVE_CARD 否 签名移位取模基数 2
JF_ENDPOINT 否 API 域名 api-cn.jftechws.com

签名算法:md5(merge(uuid+appKey+appSecret+timeMillis, shift(...))),timeMillis 为 7 位计数器 + 13 位毫秒时间戳,由 scripts/crypto.py 实时生成。

2.3 Python 依赖

pip install requests
# 可选:仅当需要从直播流抓帧做画框配置时
pip install av -i https://pypi.tuna.tsinghua.edu.cn/simple

3. API 接口总览

功能 接口地址(https://Endpoint/gwp/v3 前缀) 脚本命令
创建门店 POST /rtc/store/create create-store
修改门店 POST /rtc/store/edit edit-store
删除门店 POST /rtc/store/delete delete-store
添加设备(杰峰IPC) POST /rtc/device/addJfIpc add-device
删除设备 POST /rtc/device/delete delete-device
AI巡检算法目录 POST /rtc/device/aiPatrolAlgorithmPageQuery list-algorithms
AI巡检计划新增/编辑 POST /rtc/device/aiPatrolAddOrEdit create-plan / edit-plan
AI巡检计划分页查询 POST /rtc/device/aiPatrolPageQuery list-plans
AI巡检计划详情 POST /rtc/device/aiPatrolDetail/{batchNumber} plan-detail
AI巡检计划启停 POST /rtc/device/aiPatrolStartAndStop start-plan / stop-plan
AI巡检计划删除 POST /rtc/device/aiPatrolDelete/{batchNumber} delete-plan
AI巡检记录分页 POST /rtc/device/aiPatrolRecordPageQuery list-records / patrol-report
设备快照(直播抽帧) POST /rtc/device/token + /rtc/device/login/{token} + /rtc/device/livestream/{token} snapshot

请求头(uuid、appKey、timeMillis、signature、X-Request-Id、Content-Type)由脚本自动处理。

4. 工作流 1:从零部署 AI 巡检

1. 初始化会话
   python scripts/smart_store_inspection.py --session ./session init

2. 创建门店
   python scripts/smart_store_inspection.py --session ./session create-store \
     --store-name "XX旗舰店" --address "XX市XX路XX号" --longitude 120.123456 --latitude 30.123456

3. 添加设备(deviceNetworkType=0 已配网,1 未配网;device-username 默认 admin)
   python scripts/smart_store_inspection.py --session ./session add-device \
     --sn "JFIPCXXXXXXXX" --network-type 0 --device-name "收银台摄像头"

4. 查看已授权的AI算法目录,选定 algorithmId
   python scripts/smart_store_inspection.py --session ./session list-algorithms
   python scripts/smart_store_inspection.py --session ./session list-algorithms --name "离岗"

5. 创建AI巡检计划(一个设备 × 一个算法)
   python scripts/smart_store_inspection.py --session ./session create-plan \
     --plan-name "收银台离岗巡检" \
     --time-type 0 --time-cycle "0" \
     --detail-time "09:00-12:00,14:00-18:00" \
     --algorithm-id 1001 --threshold 0.85 \
     --step 5 --duration-time 60
   # patrolRange 自动取会话中 device.id;如指定其他设备用 --patrol-range

6. (可选)绘制 includeAreas 检测区域
   python scripts/smart_store_inspection.py --session ./session snapshot
   python scripts/smart_store_inspection.py --session ./session generate-config-page --snapshot ./session/snapshot.jpg
   # 浏览器打开 config_tool.html → 绘制多边形 → 生成配置 JSON → 下载 plan_config.json
   python scripts/smart_store_inspection.py --session ./session edit-plan --from-file plan_config.json

7. 确认部署状态
   python scripts/smart_store_inspection.py --session ./session status

timeType / timeCycle / detailTime 规则:

timeType timeCycle 含义 示例
0(每天) 固定 "0" "0"
1(每周) 星期数字,逗号分隔(1-7) "1,3,5" = 周一三五
2(每月) 日期数字,逗号分隔(1-31) "1,15,28" = 每月 1/15/28 号

detailTime 格式 HH:MM-HH:MM,HH:MM-HH:MM,最多 5 段,不允许重合、不允许跨天。

5. 工作流 2:查询/管理 AI 巡检计划

# 分页查询全部计划
python scripts/smart_store_inspection.py --session ./session list-plans

# 过滤:按计划名 / 状态(1=运行中 2=暂停中)
python scripts/smart_store_inspection.py --session ./s
Full SKILL.md on ClawHub

Install jf-smart-store-inspection in Claude Code & Claude Desktop

Sign up to install this skill

Create a free account to reveal the install command and save the skill to your library.

  • Reveal the one-line install command
  • Save skills to your synced library
  • Get notified when skills update
Sign up freeI already have an account

Allowed tools

Tools this skill is permitted to call.

No restriction — this skill can use any tool.

FAQ

What does the jf-smart-store-inspection skill do?

杰峰蜂云智慧巡店部署与AI巡检运营技能。通过工作流完成门店创建、监控设备接入(GB28181/ONVIF+自研NVR/杰峰自研IPC)、AI巡检算法查询、AI巡检计划配置(离岗/工服/跌倒/客流/安全帽/视频质量诊断等)、检测区域画框、计划启停与巡检记录聚合,并生成含抓拍图墙的HTML分析报告。当用户提到智慧巡店、AI巡检、门店巡检、巡检计划、巡检记录、离岗检测、工服检测、跌倒检测、抓拍图墙、连锁门店巡检、smart store inspection、AI patrol 时使用此技能。

How do I install the jf-smart-store-inspection skill?

Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.

Does the jf-smart-store-inspection skill run scripts?

Yes, this skill bundles executable scripts. Review the source before installing.

Related skills

Compare jf-smart-store-inspection with