Clawdbot Logs Litiao
v1.0.0Analyze Clawdbot logs and diagnostics. Use when the user asks about bot performance, response times, errors, session stats, token usage, API costs, or wants...
MIT-0
Security Scan
OpenClaw
Benign
high confidencePurpose & Capability
Name/description align with requested actions: the SKILL.md and included scripts only read clawdbot journals, user systemd service status, and files under ~/.clawdbot to report response times, errors, token usage and costs. One minor mismatch: SKILL.md uses common system tools (journalctl, systemctl, jq, grep, tail) but the skill declares no required binaries—this is an omission but not a functional incoherence.
Instruction Scope
Instructions and scripts explicitly read sensitive local data (session JSON/JSONL containing full conversation history, token/cost info) and the user journal for the clawdbot service. All referenced paths and commands are within the expected scope for diagnostics; there are no steps that transmit data externally. Users should be aware that running this skill exposes local conversation contents to whoever or whatever is invoking the skill.
Install Mechanism
Instruction-only skill with two small shell scripts included. No install spec, no downloads, and nothing is written to disk beyond running the provided scripts. This is low-risk from an installation perspective.
Credentials
The skill requests no environment variables or credentials, which is appropriate. However it reads files in $HOME and queries the user journal/systemd user service; access to these filesystem and journal entries grants visibility into sensitive conversation content and token/cost data—this is expected for a diagnostics tool but worth highlighting.
Persistence & Privilege
always is false and there is no install-time privilege escalation or modification of other skills or system-wide config. The skill does not request persistent platform privileges beyond being invoked.
Assessment
This skill appears to do exactly what it claims: read Clawdbot journals and session files and summarize performance and cost data. Before installing or running it, remember: (1) it reads local session files (~/.clawdbot/...) that contain full conversation history, tokens, and cost information — treat that as highly sensitive; only run the skill on a trusted machine and avoid exposing its output to untrusted parties; (2) it relies on common system tools (journalctl, systemctl, jq, grep, tail) though they are not declared as required—ensure those binaries exist and are the expected versions; (3) there is a minor metadata mismatch (ownerId differs in _meta.json vs registry metadata) — likely benign but worth noting. If you want extra assurance, inspect the session files yourself before running or run the scripts with limited privileges / under a non-privileged account.Like a lobster shell, security has layers — review code before you run it.
latest
License
MIT-0
Free to use, modify, and redistribute. No attribution required.
SKILL.md
Clawdbot Logs & Diagnostics
Analyze Clawdbot performance, errors, and session data.
Quick Commands
Response Times (last N messages)
scripts/response-times.sh [count]
Recent Errors
journalctl --user -u clawdbot-gateway.service --no-pager --since "1 hour ago" | grep -iE "(error|fail|invalid)" | tail -20
Session Stats
scripts/session-stats.sh
Gateway Status
systemctl --user status clawdbot-gateway.service --no-pager
Config Validation
cat ~/.clawdbot/clawdbot.json | jq . > /dev/null && echo "Config valid" || echo "Config invalid"
Log Sources
| Source | Location | Contains |
|---|---|---|
| Journal | journalctl --user -u clawdbot-gateway.service | Session state, errors, tool exec |
| Daily log | /tmp/clawdbot/clawdbot-YYYY-MM-DD.log | Detailed JSON logs |
| Session file | ~/.clawdbot/agents/main/sessions/*.jsonl | Full conversation, token usage, costs |
| Sessions meta | ~/.clawdbot/agents/main/sessions/sessions.json | Current session state, model info |
Common Diagnostics
Slow Responses
- Check response times:
scripts/response-times.sh 20 - Check token count in sessions.json:
jq '.["agent:main:main"].totalTokens' ~/.clawdbot/agents/main/sessions/sessions.json - If tokens > 30000, run
/compactin Telegram or start new session
Config Errors
journalctl --user -u clawdbot-gateway.service --no-pager --since "10 minutes ago" | grep -i "invalid config"
API Costs (from session)
scripts/session-stats.sh
Useful Patterns
Filter journal by category
# Session state changes
journalctl --user -u clawdbot-gateway.service | grep "session state"
# Tool execution
journalctl --user -u clawdbot-gateway.service | grep "\[tools\]"
# Telegram activity
journalctl --user -u clawdbot-gateway.service | grep "\[telegram\]"
Parse session file for recent messages
tail -20 ~/.clawdbot/agents/main/sessions/*.jsonl | jq -r 'select(.message.role=="user") | .message.content[0].text' 2>/dev/null | tail -10
Files
4 totalSelect a file
Select a file to preview.
Comments
Loading comments…
