当前位置: 首页 > Skill >

SysClaw Reporting

SysClaw Reporting

SysClaw Reporting

Report system issues and submit resource requests to SysClaw via the cross-agent communication system. Use when an agent needs to report an error, warning, o...

4.0.0 2026.11.23 528
获取Skill文件查看使用说明
作 者:陆宁 许可证: 更新时间:2026.11.23
本文目录展开

SysClaw Reporting (Client)

Report issues and submit requests to SysClaw. This is the client-side skill — it covers how to communicate with SysClaw, not how SysClaw processes requests.

Prerequisites

1. Install Python dependency

pip3 install psycopg2-binary

2. Set environment variables

Set these before running scripts. All scripts use a fallback chain: script-specific vars → SYSCLAW_DB_* → defaults.

# Shared connection settings (used by all scripts as fallback)
export SYSCLAW_DB_HOST="<your-db-host>"        # Ask your SysClaw operator
export SYSCLAW_DB_PORT="5432"
export SYSCLAW_DB_NAME="system_comm"
export SYSCLAW_DB_USER="<your-agent-role>"     # e.g., jobagent, pmagent, researcher_agent
export SYSCLAW_DB_PASSWORD="<your-db-password>"

You can also set per-script overrides (ISSUE_DB_*, REQUEST_DB_*) if different scripts need different credentials, but in most cases the shared SYSCLAW_DB_* vars are sufficient.

Ask your SysClaw operator for the correct host address and your agent credentials.

Report an Issue

For errors, warnings, and problems that need attention:

scripts/report-issue.sh <source> <severity> <title> [category] [details] [source_host]

Severity: info | warning | critical Categories: disk | service | error | resource | network | config | other

Examples:

scripts/report-issue.sh jobhunter warning "Disk usage above 80%" disk "df shows 82% on /data" srv-prod-01
scripts/report-issue.sh pmagent critical "API endpoint returning 500" service "5 consecutive failures" srv-prod-02

source_host (6th argument, optional): Identifies which machine this report originates from. Defaults to the current hostname if omitted.

Request Something from SysClaw

For software installs, access requests, configuration changes, and more:

scripts/request-resource.sh <source> <type> <action> <target> <justification> [urgency] [payload] [source_host]

Types: access | software | resource | config | service | deployment | info Actions: install | remove | create | modify | restart | grant | check | deploy Urgency: low | normal | urgent (default: normal) Payload: Valid JSON string (optional). Validated before submission.

Examples

scripts/request-resource.sh jobhunter software install nginx '{"version":"latest"}' normal
scripts/request-resource.sh pmagent access grant /var/data/pm '{"level":"read"}'
scripts/request-resource.sh researcher info check disk_usage

What Happens Next

  1. Your request is submitted and SysClaw is automatically notified
  2. SysClaw assesses and processes the request (typically within 15 minutes)
  3. SysClaw executes approved actions — you don't need to do anything after approval
  4. You receive a notification with the result (e.g., "DONE: nginx installed and running")

Verdicts:

  • approved + DONE — SysClaw completed the work, see notification for details
  • denied — see notification for reason
  • escalated — human operator reviewing, you'll be notified when decided

Check Notifications

Check for responses from SysClaw:

scripts/check-notifications.sh <your-agent-name>        # View unread
scripts/check-notifications.sh <your-agent-name> yes    # View and mark as read

Workflow:

  1. Run check-notifications.sh at session start or after submitting a request
  2. Read the results — SysClaw has already done the work for approved requests
  3. Mark as read when done

Automatic Notification Checking

Set up a cron job so responses are ready when your session starts:

# Create wrapper script
cat > /usr/local/bin/check-sysclaw-notifications.sh << 'SCRIPT'
#!/bin/bash
export SYSCLAW_DB_HOST="<db-host>"
export SYSCLAW_DB_PORT="5432"
export SYSCLAW_DB_NAME="system_comm"
export SYSCLAW_DB_USER="<your-role>"
export SYSCLAW_DB_PASSWORD="<your-password>"
bash "<skill-path>/scripts/check-notifications.sh" <your-agent-name> > "<workspace>/memory/notifications.md" 2>/dev/null
SCRIPT
chmod +x /usr/local/bin/check-sysclaw-notifications.sh

# Add to crontab
(crontab -l 2>/dev/null; echo "*/15 * * * * /usr/local/bin/check-sysclaw-notifications.sh") | crontab -

Then at session start: cat memory/notifications.md

Direct SQL (Alternative to Scripts)

If you prefer direct database access:

-- Report issue
INSERT INTO issues (source, severity, category, title, details, source_host)
VALUES ('jobhunter', 'warning', 'disk', 'Disk usage high', 'Partition at 85%', 'srv-prod-01');

-- Submit request
INSERT INTO agent_requests (requesting_agent, request_type, action, target, justification, urgency, payload, source_host)
VALUES ('pmagent', 'software', 'install', 'nginx', 'Need web server', 'normal', '{"version":"latest"}'::jsonb, 'srv-prod-02');

-- Notify SysClaw (after submitting request)
INSERT INTO notifications (recipient, sender, related_request, message, urgency)
VALUES ('sysclaw', 'pmagent', <request_id>, 'New software request: install nginx', 'normal');

-- Check responses
SELECT * FROM notifications WHERE recipient = 'pmagent' AND read = FALSE;

Do not set verdict, security_assessment, resolved_at, or resolved_by — SysClaw manages these.

Post-Install

  1. TOOLS.md — Add DB host, user, and connection details
  2. Set up notification cron job — See "Automatic Notification Checking" above
  3. Test:
    scripts/report-issue.sh <your-source> info "SysClaw reporting skill installed - test"
    

Technical Notes

  • Scripts use Python psycopg2 with parameterized queries (no SQL injection risk)
  • JSON payloads are validated with json.loads() before database insertion
  • Connection retry: 3 attempts with exponential backoff (1s, 2s, 4s) on initial connection failure
  • Mid-session reconnect: If the connection drops between queries, scripts reconnect and retry once automatically
  • Connection timeout is 10 seconds per attempt (override with PGCONNECT_TIMEOUT)
  • All scripts exit non-zero on failure with descriptive error messages

推荐文章

更多
PHP时间戳与日期字符串相互转换方法详解

本文介绍PHP中时间数值(Unix时间戳)与日期字符串之间的相互转换方法。通过strtotime和date函数,实现将当前时间、指定日期转换为时间戳,以及将时间戳格式化为可读的日期时间字符串,并提供相关在线计算工具推荐。

2025.11.30 1,034
PHP日期转时间戳时区偏差怎么解决

在 PHP 中将日期字符串转换为时间戳时,若未显式指定时区,默认使用脚本配置的 date.timezone 或系统时区。当服务器时区与业务逻辑预期(如 UTC )不一致时,会产生偏差。解决核心是确保输入字符串携带明确时区信息,或在转换前统一设置时区上下文。

2026.10.24 1,031
PHP跨域配置:怎么安全地允许指定域名而非使用通配符

在 PHP 中安全地允许指定域名跨域,核心是解析请求头中的 Origin ,验证其是否在白名单内,然后动态设置 Access-Control-Allow-Origin 响应头。不要使用通配符 * ,也不要硬编码单一域名。

2025.03.29 1,018
JavaScript中利用replace结合正则实现replaceAll效果

JavaScript原生仅支持replace()进行单次或全局替换,缺乏类似Java的replaceAll()便捷方法。本文总结四种在JS中实现全量替换的方案:使用带g标志的正则、带gm标志的正则、扩展String原型以及split后join。通过对比代码示例,展示各方法的实现细节与适用场景,帮助开发者根据需求选择最优解。

2025.04.29 1,017
OpenAI的Jalapeno芯片未落地,教你分辨300兆瓦算力消息

OpenAI计划在SB Energy租赁的数据中心部署约300兆瓦自研Jalapeno推理芯片,但目前双方仍处于洽谈阶段,交易细节与上线时间表均未公布。本文带你按报道原文核实项目所处阶段,厘清芯片发布、电力功率与实际推理算力的边界,并将融资意向与签约、开工、投运节点分开追踪,避免误将规划容量计入现有算力。

2026.12.02 1,013
PHP实现基础文件上传:HTML表单与$_FILES处理流程

在 HTML 表单中设置 enctype="multipart/form-data" ,并在 PHP 后端通过 $_FILES 数组接收文件,调用 move_uploaded_file() 将临时文件移动到目标目录即可完成上传。

2026.09.07 1,013
Skill 文件
  • SKILL.md
    • SysClaw Reporting (Client)
    • Prerequisites
      • 1. Install Python dependency
      • 2. Set environment variables
    • Report an Issue
    • Request Something from SysClaw
      • Examples
    • What Happens Next
    • Check Notifications
    • Automatic Notification Checking
    • Direct SQL (Alternative to Scripts)
    • Post-Install
    • Technical Notes
  • 项目或源文件

相关 Skill

更多
Agent Communication Agent Communication 标准化跨 Agent 通信协议,用于向其他 Agent询问、协作或委托任务。
ClawChat - P2P Agent Communication ClawChat - P2P Agent Communication OpenClaw 代理之间的加密点对点消息传递,支持跨机器直连、多身份和原生唤醒。
cerbug45 - Encrypted Agent Communication cerbug45 - Encrypted Agent Communication 使 AI 代理能够通过加密消息安全通信。支持信息交换、任务协调、数据共享和跨会话协作。提供端到端加密、消息队列和代理身份验证功能。
service-qa-coach service-qa-coach Review support quality for chat, email, phone, social DM, or marketplace service teams. Use when a team needs a QA scorecard, failure-mode analysis, coaching plan, calibration checklist, or service-improvement brief without live ticketing, CRM, or contact-center system access.
高中数学作业批改助手 高中数学作业批改助手 >图片识别 直接读取学生手写作答照片,识别公式、符号、步骤 🧮 自动推导 根据题目自动生成参考答案和评分细则,无需教师预设 📊 逐步给分 每个关键步骤独立评分,体现过程分 📝 结构化报告 输出含识别内容、参考答案、逐步评分、改进建议的完整报告 🗂 批量批改 支持一次性批改多道题,最终汇总得分表