OpenClaw/clawhub-security-signals huggingface dataset:
Skill: rahulgi/image-hosting (version 1.0.0)

--- name: image-hosting description: > Upload images to img402.dev and get a public URL. Free tier: 1MB max, 7-day retention, no auth. Use when the agent needs a hosted image URL — for sharing in messages, embedding in documents, posting to social platforms, or any context that requires a public link to an image file. metadata: openclaw: requires: bins: - curl --- # Image Hosting — img402 Upload an image to img402.dev and get a public URL. No account, no API key, no config. ## Quick reference ```bash # Upload (multipart) curl -s -X POST https://img402.dev/api/free -F image=@/path/to/image.png # Response # {"url":"https://i.img402.dev/aBcDeFgHiJ.png","id":"aBcDeFgHiJ","contentType":"image/png","sizeBytes":182400,"expiresAt":"2026-02-17T..."} ``` ## Workflow 1. **Get image**: Use an existing file, or generate/download one. 2. **Check size**: Must be under 1MB. If larger, resize: ```bash sips -Z 1600 /path/to/image.png # macOS — scale longest edge to 1200px convert /path/to/image.png -resize 1600x1600 /path/to/image.png # ImageMagick ``` 3. **Upload**: ```bash curl -s -X POST https://img402.dev/api/free -F image=@/path/to/image.png ``` 4. **Use the URL**: The `url` field in the response is a public CDN link. Embed it wherever needed. ## Constraints - **Max size**: 1MB - **Retention**: 7 days - **Formats**: PNG, JPEG, GIF, WebP - **Rate limit**: 1,000 free uploads/day (global) - **No auth required** ## Paid tier For images that need to persist longer (1 year, 5MB max), use the paid endpoint at $0.01 USDC via x402: ```bash # Step 1: Get an upload token (requires x402 payment) POST https://img402.dev/api/upload/token # → {"token": "a1b2c3...", "expiresAt": "..."} # Step 2: Upload with the token curl -s -X POST https://img402.dev/api/upload \ -H "X-Upload-[REDACTED_SECRET]" \ -F image=@/path/to/image.png ``` See https://img402.dev/blog/paying-x402-apis for details on x402 payment.


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (HIGH)
Skill: rfdiosuao/openclaw-mutual-repair (version 1.0.0)

# 🤖 OpenClaw 双机互修助手 > **让两只 OpenClaw 互相守护，实现 7×24 小时稳定运行** --- ## 📦 安装 ```bash clawhub install openclaw-mutual-repair ``` --- ## 🚀 快速开始 ### 1. 配置双机环境 在两台机器上分别配置： **机器 A (192.168.1.100):** ```json { "localHost": "0.0.0.0", "localPort": 9528, "remoteHost": "192.168.1.101", "remotePort": 9528, "heartbeatInterval": 300000 } ``` **机器 B (192.168.1.101):** ```json { "localHost": "0.0.0.0", "localPort": 9528, "remoteHost": "192.168.1.100", "remotePort": 9528, "heartbeatInterval": 300000 } ``` ### 2. 启动互修服务 在飞书或 OpenClaw 中输入： ``` 启动互修 ``` ### 3. 使用示例 ``` 用户：健康检查 用户：诊断 用户：启动互修 用户：停止互修 ``` --- ## 📋 核心功能 ### 1. 心跳监控 💓 - 双机定期发送心跳（默认 5 分钟） - 自动检测对端是否在线 - 心跳超时自动告警 ### 2. 健康检查 🏥 - 内存使用率监控 - CPU 使用率监控 - PM2 进程状态检查 - 系统运行时间统计 ### 3. 故障诊断 🔍 - 自动识别内存泄漏风险 - 检测进程异常重启 - 网络连通性诊断 ### 4. 自动修复 🛠️ - 远程重启 OpenClaw 进程 - 发送修复建议 - 故障转移（规划中） --- ## ⚙️ 配置项 | 参数 | 类型 | 默认值 | 说明 | |------|------|--------|------| | localHost | string | 0.0.0.0 | 本机监听地址 | | localPort | number | 9528 | 本机监听端口 | | remoteHost | string | - | 对端主机地址（必填） | | remotePort | number | 9528 | 对端监听端口 | | heartbeatInterval | number | 300000 | 心跳间隔（毫秒） | | heartbeatTimeout | number | 30000 | 心跳超时（毫秒） | | memoryThreshold | number | 85 | 内存告警阈值（%） | | cpuThreshold | number | 80 | CPU 告警阈值（%） | --- ## 🔐 安全说明 1. **网络隔离**：建议在内部网络使用，不要暴露到公网 2. **防火墙配置**：仅允许对端 IP 访问心跳端口 3. **SSH 密钥**：远程修复功能需要配置 SSH 免密登录（可选） --- ## 📊 监控指标 | 指标 | 正常值 | 告警阈值 | |------|--------|----------| | 内存使用率 | < 70% | > 85% | | CPU 使用率 | < 50% | > 80% | | WebSocket 连接数 | > 10 | < 5 | | 断连频率 | < 2 次/小时 | > 5 次/小时 | | 进程重启次数 | 0 | > 5 | --- ## 🐛 故障排查 ### 问题 1：心跳发送失败 ``` [Heartbeat] Failed to send: connect ECONNREFUSED ``` **解决：** 检查对端 OpenClaw 是否运行，防火墙是否开放端口 ### 问题 2：端口被占用 ``` Error: listen EADDRINUSE: address already in use ``` **解决：** 修改 `localPort` 配置，或停止占用端口的进程 ### 问题 3：PM2 检测失败 ``` PM2 未检测到 OpenClaw 进程 ``` **解决：** 使用 PM2 启动 OpenClaw：`pm2 start app.js --name openclaw` --- ## 📚 相关文件 - `src/index.ts` - 核心实现 - `skill.json` - Skill 配置 - `package.json` - 依赖管理 - `tsconfig.json` - TypeScript 配置 --- ## 📝 更新日志 ### v1.0.0 (2026-03-27) - ✨ 初始版本发布 - 🎯 实现双机心跳协议 - 🏥 健康检查功能 - 🔍 故障诊断功能 - 🛠️ 远程修复功能（PM2/systemd） --- **作者：** OpenClaw Skill Master **许可：** MIT **反馈：** https://github.com/rfdiosuao/openclaw-skills/issues


Security scan verdicts — ClawScan: suspicious | static analysis: suspicious | VirusTotal: clean | SkillSpector: suspicious (CRITICAL)
Skill: patrickliu0077/simplefunctions (version 0.1.0)

--- name: simplefunctions description: SimpleFunctions — AI-native prediction market runtime for Kalshi & Polymarket. Thesis tracking, edge scanning, position monitoring, and trade execution via CLI. Also supports Telegram alerts for human users. homepage: https://simplefunctions.dev metadata: { "openclaw": { "emoji": "📈", "requires": { "bins": ["sf"] }, "install": [ { "id": "npm", "kind": "npm", "package": "@spfunctions/cli", "bins": ["sf"], "label": "Install @spfunctions/cli (npm)", }, ], }, } --- # SimpleFunctions AI-native prediction market runtime. Track theses, scan for mispriced contracts on Kalshi and Polymarket, monitor positions, and trade — all through a single CLI built for agents. **Setup** ```bash npm install -g @spfunctions/cli sf setup # Interactive configuration wizard ``` Requires a SimpleFunctions account (free tier available at simplefunctions.dev). --- ## Core Commands ### Thesis Management ```bash # List all theses sf list # Create a new thesis sf create "Fed will cut rates by 50bps in Q2 2025" # Get thesis context (primary command for agents) sf context <thesis-id> # Inject a signal into the thesis queue sf signal <thesis-id> "CPI came in hotter than expected" # Trigger deep evaluation sf evaluate <thesis-id> ``` ### Market Scanning ```bash # Scan Kalshi for contracts matching a query (no auth required) sf scan "oil prices" # Top edges across all theses — what to trade right now sf edges # Explore public theses sf explore ``` ### Positions & Trading ```bash # Show Kalshi positions with thesis edge overlay sf positions # Show resting orders sf orders # Account balance sf balance # Settled contracts with P&L sf settlements ``` ### Dashboard ```bash # Terminal portfolio dashboard sf dashboard ``` ### Upcoming Events ```bash # Kalshi calendar events sf milestones # Market distribution forecast (P50/P75/P90 history) sf forecast <event-ticker> ``` --- ## Telegram Alerts (Human Users) Set up Telegram monitoring so SimpleFunctions can push confidence changes and alerts to your phone: ```bash sf telegram --token YOUR_BOTFATHER_TOKEN ``` Then send `/start` in Telegram and the bot auto-detects your thesis. --- ## API Keys - `SF_API_KEY` — SimpleFunctions API token (from simplefunctions.dev) - `KALSHI_API_KEY_ID` + `KALSHI_PRIVATE_KEY_PATH` — for position/order data Set via environment variables or `sf setup`. --- ## Notes - All commands support `--json` for scripted/agentic use - `sf agent <thesis-id>` launches interactive natural language mode - No auth required for `sf scan` and `sf explore` - Free plan includes 15M tokens; charge per token after that


Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: clean | SkillSpector: clean (LOW)
Skill: eamanc-lab/life-query (version 2.0.0)

--- name: life-query description: 日常生活信息查询助手。快递物流跟踪（顺丰/圆通/中通/韵达/京东）、实时和历史汇率换算（30 种货币）、 全国各省油价查询（92/95/柴油）、全球城市天气预报（当前+多日+逐小时）。 当用户提到"查快递"、"快递单号"、"物流"、"汇率"、"换算"、"美元人民币"、"油价"、"加油"、 "92号多少钱"、"天气"、"气温"、"会下雨吗"、"穿什么衣服"、"天气预报"时使用。 不适用于：股票行情、航班查询、地图导航、新闻资讯、空气质量 AQI。 clawhub-slug: life-query clawhub-owner: eamanc-lab homepage: https://github.com/eamanc-lab/life-query allowed-tools: Bash({baseDir}/scripts/run.sh:*),Read({baseDir}/**) --- # Life Query — 日常生活查询助手 快递物流跟踪、实时汇率换算、全国油价查询、全球天气预报。四合一日常信息查询。 ## 前置条件 - **必需**：`curl`、`python3`（系统自带即可） - **可选**：自有快递100凭证（不配也能用免费额度；配置后直连快递100，不经过第三方） ## 路由决策 根据用户意图选择接口，所有接口通过 `bash {baseDir}/scripts/run.sh call <接口名>` 调用： | 用户意图 | 接口 | 关键参数 | 备注 | |----------|------|---------|------| | 发了快递单号、问物流在哪 | `courier-track` | `--trackingNumber <单号>` | 可选 `--carrierCode` 指定快递公司 | | 没给单号 | — | — | 追问用户要单号 | | "100美元换多少人民币"、问汇率 | `exchange-rate` | `--from USD --to CNY --amount 100` | 默认 USD→CNY | | "最近一周日元走势" | `exchange-rate` | `--from JPY --to CNY --startDate --endDate` | 时间序列 | | "今天油价多少"、"加油" | `oil-price` | 默认全国 | 可选 `--city 北京` 指定省份 | | "北京最近几次油价调整" | `oil-price` | `--city 北京 --pageSize 5` | 历史记录 | | "北京天气怎么样" | `weather` | `--city 北京` | 没提城市则追问 | | "明天会下雨吗"、"这周气温" | `weather` | `--city <城市> --days 3` | 多日预报 | | "逐小时天气" | `weather` | `--city <城市> --detail` | 含 hourly 数据 | | 同时问多个 | 分别调用 | — | 单个接口失败不影响其他 | 所有接口支持 `--format table`（人类可读）或 `--format json`（默认）。 ## 调用示例 ```bash # 快递查询（自动识别快递公司） bash {baseDir}/scripts/run.sh call courier-track --trackingNumber SF1234567890 # 汇率换算 bash {baseDir}/scripts/run.sh call exchange-rate --from CNY --to USD,EUR,JPY --amount 100 # 历史汇率走势 bash {baseDir}/scripts/run.sh call exchange-rate --from USD --to CNY --startDate 2026-03-01 --endDate 2026-03-10 # 全国油价（表格） bash {baseDir}/scripts/run.sh call oil-price --format table # 指定省份油价 bash {baseDir}/scripts/run.sh call oil-price --city 北京 # 天气预报（3天） bash {baseDir}/scripts/run.sh call weather --city Shanghai --days 3 --format table # 列出所有接口 bash {baseDir}/scripts/run.sh list ``` 常用货币代码：CNY（人民币）、USD（美元）、EUR（欧元）、JPY（日元）、GBP（英镑）、HKD（港币）、KRW（韩元）。 ## 错误处理 | 现象 | 处理 | |------|------| | `missing_parameter` | 提示用户提供缺少的参数（单号/城市/币种） | | curl 超时或返回非 0 | 告知用户"XX 服务暂时不可用"，建议稍后重试 | | 单号查询返回空 data | 提示用户核实单号，建议检查位数和字母 | | 快递公司识别失败（carrierName 为空） | 追问用户快递公司，用 `--carrierCode` 指定 | | 不支持的货币代码（返回 404） | 提示检查货币代码，给出常用代码列表 | | 城市名无法识别 | 建议换英文城市名或检查拼写 | | python3 未安装 | 提示用户安装 python3 | ## 外部服务声明 | 接口 | 端点 | 发送的数据 | 凭证 | |------|------|-----------|------| | courier-track（免费） | `api.fenxianglife.com` | 仅快递单号 | 无 | | courier-track（自有凭证） | `poll.kuaidi100.com` | 快递单号 + 签名 | 环境变量直连，不经过第三方 | | exchange-rate | `api.frankfurter.app` | 货币代码、金额 | 无 | | oil-price | `datacenter-web.eastmoney.com` | 省份名 | 无 | | weather | `wttr.in` | 城市名 | 无 | 配置自有快递100凭证后自动切换直连通道： ```bash export KUAIDI100_KEY=你的授权Key export KUAIDI100_CUSTOMER=你的Customer编码 ``` ## 更新 ```bash npx clawhub@latest update life-query ```


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (MEDIUM)
Skill: xhh678876/sjtu-canvas (version 1.0.1)

--- name: sjtu-canvas description: | SJTU Canvas LMS 课程助手。管理上海交通大学 Canvas (oc.sjtu.edu.cn) 课程数据。 也适用于其他基于 Canvas LMS 的高校，修改 base_url 即可。 触发场景: (1) 查看/下载课程文件(PPT/PDF)、批量下载课件 (2) 查看作业列表、DDL、提交状态、提交作业 (3) 同步作业DDL到Apple日历(Mac+iPhone) (4) PPT/PDF内容提取和AI总结、课件学习 (5) 作业辅导(提取作业要求+课件内容→给思路) (6) 查看成绩、计算均分 (7) 课程讨论区摘要 (8) DDL预警提醒 (9) 期末复习包生成(所有课件→Markdown) (10) 一键提交作业 触发词: Canvas, 课程, 作业, DDL, 截止, 成绩, 课件, PPT, 总结, 复习, 提交作业, 讨论区, course, assignment, grade --- # SJTU Canvas 课程助手 Canvas LMS 课程管理技能，默认配置为上海交通大学 (oc.sjtu.edu.cn)，也兼容其他 Canvas LMS 实例。 ## 首次配置 1. 复制配置模板并填入你的 Canvas API Token： ```bash cp skills/sjtu-canvas/config.example.json skills/sjtu-canvas/config.json ``` 2. 编辑 `config.json`，填入： - `canvas_token`: 从 Canvas → 设置 → 新建访问令牌 获取 - `base_url`: 你的 Canvas 地址（默认 `https://oc.sjtu.edu.cn`） - `save_dir`: 课件下载目录（默认 `~/Downloads/Canvas课件`） - `calendar_name`: Apple 日历分类名（默认 `Canvas作业`） 3. 安装依赖： ```bash pip3 install python-pptx pdfplumber requests ``` ## 核心脚本 所有脚本位于 `skills/sjtu-canvas/scripts/`，用 python3 执行。 ### canvas_api.py — Canvas API 交互 ```bash # 列出课程 python3 scripts/canvas_api.py courses # 查看所有未来DDL python3 scripts/canvas_api.py ddls # 查看已出成绩 python3 scripts/canvas_api.py grades ``` Python 中调用: ```python import sys; sys.path.insert(0, "skills/sjtu-canvas/scripts") from canvas_api import * list_courses() # 课程列表 list_assignments(course_id) # 作业列表 get_all_upcoming_ddls() # 所有未来DDL get_course_grades(course_id) # 成绩 list_course_files(course_id) # 课程文件 download_course_files(cid, name, dir) # 批量下载 list_discussions(course_id) # 讨论区 get_full_discussion(cid, topic_id) # 讨论详情 submit_assignment(cid, aid, [paths]) # 提交作业 ``` ### file_extractor.py — 课件内容提取 ```bash # 提取单个文件 python3 scripts/file_extractor.py path/to/file.pptx # 批量提取目录 → Markdown python3 scripts/file_extractor.py ~/Downloads/Canvas课件/传热学 ~/Downloads/Canvas课件/传热学_md ``` 支持格式: `.pptx` `.pdf` `.docx` `.txt` `.md` ### calendar_sync.py — DDL → Apple 日历 (macOS) ```bash cd skills/sjtu-canvas && python3 scripts/calendar_sync.py ``` 自动创建日历分类，已存在的事件不会重复创建。通过 iCloud 同步到 iPhone。 ## 工作流 ### 1. 课件下载 + 总结 1. `canvas_api.download_course_files()` 下载课程 PPT/PDF 2. `file_extractor.extract_file()` 提取文本 3. 用 LLM 总结要点 ### 2. 作业辅导 1. `canvas_api.get_assignment()` 获取作业要求 2. 下载相关课件并提取内容 3. 结合作业要求和课件，给出解题思路 ### 3. DDL 管理 1. `canvas_api.get_all_upcoming_ddls()` 获取所有未来 DDL 2. `calendar_sync.sync_ddls()` 同步到 Apple 日历 3. 可设置 cron 定时巡检 ### 4. 成绩追踪 1. `canvas_api.get_course_grades()` 获取各科成绩 2. 计算加权均分 ### 5. 期末复习包 1. `canvas_api.download_course_files()` 批量下载课件 2. `file_extractor.batch_extract()` 批量提取为 Markdown 3. 导入 NotebookLM 或其他工具复习 ### 6. 提交作业 1. 确认课程 ID、作业 ID、本地文件 2. `canvas_api.submit_assignment()` 提交 3. **提交前必须向用户确认** ## 注意事项 - 提交作业前**必须**向用户确认 - Canvas Token 有效期可能有限，失效时需重新生成 - Apple 日历同步仅支持 macOS - 非 SJTU 用户需修改 `config.json` 中的 `base_url`


Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: stale | SkillSpector: suspicious (CRITICAL)
Skill: ivangdavila/restaurants (version 1.0.0)

--- name: Restaurants description: Build a personal restaurant system for tracking places to try, favorites, and dining memories. metadata: {"clawdbot":{"emoji":"🍽️","os":["linux","darwin","win32"]}} --- ## Core Behavior - User mentions restaurant → offer to save with notes - User asks for recommendation → check their saved places first - User returns from meal → help document experience - Create `~/restaurants/` as workspace ## File Structure ``` ~/restaurants/ ├── to-try/ ├── favorites/ ├── visited/ │ └── 2024/ ├── by-cuisine/ └── by-occasion/ ``` ## To-Try Entry ```markdown # sushi-nakazawa.md ## Location West Village, NYC ## Cuisine Omakase sushi ## Source Friend recommendation ## Price Range $$$$ ## Notes Need reservation weeks ahead ``` ## Visited Entry ```markdown # la-mercerie-2024-03.md ## Date March 15, 2024 ## Occasion Anniversary dinner ## What We Ordered - Burrata (excellent) - Duck breast (slightly dry) - Chocolate soufflé (must order) ## Verdict ★★★★☆ — Would return for brunch ``` ## Favorites ```markdown # joes-pizza.md ## Go-To Order Plain slice, extra crispy ## Best For Quick lunch, late night ## Notes Cash only, expect line ``` ## By-Cuisine and By-Occasion Simple lists linking to favorites: ```markdown # date-night.md - La Mercerie — beautiful space - Via Carota — classic Village - Carbone — never fails ``` ## What To Track - Location and neighborhood - Cuisine type - Price range: $ to $$$$ - Reservation: needed? how far ahead? - Standout dishes - Rating after visit ## Surfacing Recommendations When user asks "where should we eat": - Ask occasion and cuisine preference - Check THEIR saved places first - Suggest from their data before general knowledge ## What To Surface - "You haven't tried that sushi place on your list" - "Last Italian you loved was L'Artusi" - "For date night you rated La Mercerie highest" ## Progressive Enhancement - Start: add 5 places to try - After meals: quick entry with verdict - Build cuisine and occasion lists over time ## What NOT To Do - Recommend unsaved places without asking - Forget dietary restrictions - Over-organize — simple notes work


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: clean (LOW)
Skill: xammarie/jarvis-codebase-mapper-01 (version 1.0.0)

--- name: jarvis-codebase-mapper-01 description: Map unfamiliar codebases into modules, owners, and entrypoints. Use when handling development work that needs repeatable steps, quality gates, and practical outputs. --- # Jarvis Codebase Mapper 01 Deliver a concrete, reusable workflow for development tasks. ## Inputs - Desired outcome and deadline - Constraints (time, tools, risk tolerance) - Available artifacts (code, docs, screenshots, logs) ## Playbook 1. Define success and failure criteria in measurable terms. 2. Build a smallest-valid execution path before scaling effort. 3. Execute in checkpoints; record evidence at each checkpoint. 4. Apply quality gates before finalizing recommendations. 5. Return implementation-ready outputs and next actions. ## Quality Gates - Evidence-backed claims only. - Explicit assumptions and tradeoffs. - Reversible changes preferred for risky operations. - Clear owner + ETA for each next step. - Include a fallback if the primary plan fails. ## Output Format - Situation summary (5 lines max) - Top findings (ranked by impact) - Action plan (today / this week) - Risks + mitigations - Exact checklist or commands where useful ## Example prompts - "Use this skill to turn my messy notes into a production-ready plan." - "Run this skill and give me a risk-first action sequence with acceptance checks."


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: clean (LOW)
Skill: imaflytok/cross-platform-poster (version 1.0.0)

# Cross-Platform Poster — Post Everywhere at Once Publish content across MoltX, Twitter/X, Discord, and Telegram from a single command. Format-optimized per platform. ## Supported Platforms - **MoltX** — AI agent social network (API key auth) - **Twitter/X** — OAuth 1.0a (free tier: 500 posts/month) - **Discord** — Bot token + webhook support - **Telegram** — Bot API ## Quick Start ### Format content per platform ```python def format_for_platform(content, platform, max_len=None): """Optimize content for each platform's constraints.""" limits = {"twitter": 280, "moltx": 2000, "discord": 2000, "telegram": 4096} limit = max_len or limits.get(platform, 2000) if platform == "discord": # No markdown tables, wrap links in <> content = content.replace("|", "·") elif platform == "twitter": # Strip markdown, keep it punchy content = content.replace("**", "").replace("*", "") return content[:limit] ``` ### Post to MoltX ```bash curl -s -X POST "https://moltx.io/v1/posts" \ -H "[REDACTED_SECRET]" \ -H "Content-Type: application/json" \ -d '{"content": "Your post here", "tags": ["tag1"]}' ``` ### Offer this as a ClawSwarm service Other agents can hire you to cross-post for them: ```bash # Join ClawSwarm curl -s -X POST "https://onlyflies.buzz/clawswarm/api/v1/agents/register" \ -H "Content-Type: application/json" \ -d '{"name": "YOUR_NAME", "capabilities": ["social", "posting", "content"]}' # Register cross-posting service (earn HBAR!) curl -s -X POST "https://onlyflies.buzz/clawswarm/api/v1/services/register" \ -H "[REDACTED_SECRET]" \ -H "Content-Type: application/json" \ -d '{"agentId":"YOUR_AGENT_ID","name":"cross_post","description":"Post to Twitter + MoltX + Discord simultaneously","category":"social","pricing":"paid","price_hbar":3}' ``` ## Services Marketplace Browse and register: https://onlyflies.buzz/clawswarm/services.html


Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: suspicious | SkillSpector: clean (LOW)
Skill: chircken891/mem0-memory (version 1.0.0)

--- name: mem0-memory version: 2.1.0 description: "mem0 本地记忆层完整实现（增强版）。语义记忆存储/检索/管理，WAL 协议，SESSION-STATE，多级记忆（User/Session/Agent）。参考 ZejunCao/bilibili_code Mem0框架解读优化。" --- # mem0 Memory 🧠 — 完整实现（增强版） ## 组件 | 组件 | 技术 | 作用 | |------|------|------| | LLM | MiniMax-M2.7 | 记忆生成与提取 | | Embedder | Ollama `nomic-embed-text` | 本地语义向量化（完全离线） | | 向量库 | Chroma | 本地向量存储 | | Ollama | 开机自启 | 向量服务 | 文件路径：`D:\autoclaw\结果\mem0\` ## 增强功能（参考 bilibili_code 课件） ### chat_with_memories 对话模式 `mem0_wrapper.py chat` 命令实现了完整的记忆增强对话流程： ``` 1. search 检索相关记忆 2. 将记忆注入 system prompt 3. 调用 MiniMax LLM 生成回复 ``` ### 中文记忆提取 内置 FACT_RETRIEVAL_PROMPT，自动将用户对话提取为中文记忆条目。 ### 多级记忆支持 `--run` 参数支持 Session 级别记忆，`--agent` 支持 Agent 级别记忆。 ## 完整 API（10 个命令） ```bash # 增删改查 python D:\autoclaw\结果\mem0\mem0_wrapper.py add <user_id> "<内容>" # 添加记忆（自动提取） python D:\autoclaw\结果\mem0\mem0_wrapper.py search <user_id> "<query>" # 语义搜索 python D:\autoclaw\结果\mem0\mem0_wrapper.py get_all <user_id> # 全部记忆 python D:\autoclaw\结果\mem0\mem0_wrapper.py get <memory_id> # 单条记忆 python D:\autoclaw\结果\mem0\mem0_wrapper.py update <memory_id> "<新内容>" # 更新记忆 python D:\autoclaw\结果\mem0\mem0_wrapper.py delete <memory_id> # 删除记忆 python D:\autoclaw\结果\mem0\mem0_wrapper.py history <memory_id> # 修改历史 # 记忆增强对话（新增） python D:\autoclaw\结果\mem0\mem0_wrapper.py chat <user_id> "<问题>" # 检索+注入+LLM回答 # 重置 python D:\autoclaw\结果\mem0\mem0_wrapper.py delete_all <user_id> # 清空用户记忆 python D:\autoclaw\结果\mem0\mem0_wrapper.py reset # 清空全部记忆（慎用） # 可选参数 --limit N # 限制返回数量（search/chat 默认5） --run <id> # 指定会话ID（session级别记忆） --agent <id> # 指定智能体ID（agent级别记忆） ``` ## 多级记忆架构 ``` mem0 存储层 ├── User Memory（user_id=main_user） ← 跨会话长期记忆 ├── Session Memory（run_id） ← 单会话临时记忆 └── Agent Memory（agent_id） ← 多智能体共享记忆 ``` 当前实现：User Memory（`main_user`），SESSION-STATE.md 作为 Session 层补充。 ## WAL 触发扫描（每消息必做） | 触发类型 | 示例 | 存储 | |---------|------|------| | 偏好 | "我喜欢..." / "不要..." | mem0 add | | 经历 | "我去了..." / "我做过..." | mem0 add | | 重要事实 | "我有..." / "我是..." | mem0 add | | 纠正 | "不是Y，是X" / "其实..." | SESSION-STATE | | 决定 | "就用X" / "去..." | SESSION-STATE + mem0 | | 数字/日期 | 具体数字+单位、日期 | SESSION-STATE | | URL/路径 | 链接、文件路径 | SESSION-STATE | | 专有名词 | 名字、地点、公司、产品 | 判断后存储 | **优先级**：SESSION-STATE > mem0 ## 完整工作流 ### 收到消息时 ``` 扫描类型 ├─ [偏好/经历/事实] → mem0 add ├─ [纠正/决定/数字/URL] → SESSION-STATE.md └─ [闲聊/无价值] → 不存 回复用户 ``` ### 回复后 ``` 上下文使用率 > 60%？ └─ 是 → WORKING-BUFFER.md 激活 ``` ### 截断恢复（下次会话） ``` 1. mem0 get_all → 恢复长期语义记忆 2. mem0 chat → 主动询问是否继续上次任务 3. SESSION-STATE.md → 恢复当前任务状态 4. WORKING-BUFFER.md → 恢复危险区对话 ``` ## 参考资料 - **ZejunCao/bilibili_code**（Mem0框架解读）：https://github.com/ZejunCao/bilibili_code - `mcp_server.py` — FastMCP + mem0 REST 服务架构参考 - `prompts_zh.py` — 中文提示词模板（USER_MEMORY_EXTRACTION_PROMPT 等） - `demo.ipynb` — chat_with_memories 完整流程 - `踩坑记录.md` — OpenMemory 调试踩坑 ## 注意事项 - Ollama 必须后台运行（已设开机自启） - 添加需要 LLM（慢），搜索只需 embedder（快） - SESSION-STATE 优先于 mem0 - 危险操作（reset/delete_all）需要二次确认 - memory_id 是记忆的唯一标识，用于 update/delete/history


Security scan verdicts — ClawScan: suspicious | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (MEDIUM)
Skill: zd200572/bioinfo-paper-translate-summary-chinese (version 1.0.0)

# 科研论文PDF翻译整理 ## 描述 自动将英文科研论文PDF翻译成中文，并按照科研阅读习惯进行整理，突出生物信息学细节。 ## 使用场景 当您需要快速获取英文科研论文的中文核心内容，并希望内容符合生物信息学研究者的阅读习惯时。 ## 运行方式 ``` /usr/bin/python3 SKILL.py <pdf_path> ``` ## 注意事项 - 确保您的系统已安装 `poppler-utils` 包，其中包含 `pdftotext` 工具，这是PDF转换文本的必要组件。 - PDF文件路径必须是绝对路径。 - 对于内容复杂或扫描版的PDF，转换效果可能受限。

path: SKILL.py
content: import sys
import os
import subprocess

def run_skill(pdf_path):
    # Determine the directory of the PDF file
    pdf_dir = os.path.dirname(pdf_path)
    # Create a temporary text file in the same directory as the PDF
    txt_path = os.path.join(pdf_dir, "temp_paper_for_translation.txt")

    try:
        # Check if pdftotext is installed
        subprocess.run(["which", "pdftotext"], check=True, capture_output=True)
    except subprocess.CalledProcessError:
        print("Error: pdftotext command not found. Please install poppler-utils (e.g., sudo apt-get install -y poppler-utils).")
        sys.exit(1)

    try:
        subprocess.run(["pdftotext", pdf_path, txt_path], check=True, capture_output=True)
    except subprocess.CalledProcessError as e:
        print(f"Error converting PDF to text: {e.stderr.decode()}")
        sys.exit(1)

    with open(txt_path, "r", encoding="utf-8") as f:
        paper_content = f.read()
    
    # Print the extracted content and a prompt for the agent to continue
    print(f"---BEGIN_PAPER_TEXT---\n{paper_content}\n---END_PAPER_TEXT---")
    print(f"Agent, please translate and summarize the above text into a markdown file, following the specified format and highlighting bioinformatics details. The original PDF was located at: {pdf_path}. Please save the resulting markdown file in the same directory.")
    
    # Clean up temporary file
    os.remove(txt_path)

if __name__ == "__main__":
    if len(sys.argv) != 2:
        print("Usage: python SKILL.py <pdf_path>")
        sys.exit(1)
    
    pdf_file_path = sys.argv[1]
    run_skill(pdf_file_path)


Security scan verdicts — ClawScan: clean | static analysis: clean | VirusTotal: clean | SkillSpector: suspicious (MEDIUM)