TopRank Skills

Home / Claw Skills / Surveillance / session-health-monitor
Official OpenClaw rules 36%

session-health-monitor

Context window health monitoring for OpenClaw agents — threshold warnings via Telegram, pre-compaction snapshots, and memory rotation.

Stars

0

Installs

0

Status

ACTIVE

Visibility

PUBLIC

安装方式

直接复制以下提示词,发送给你的 AI 助手即可完成安装。

请先检查是否已安装 SkillHub 商店,若未安装,请根据 https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/skillhub.md 安装 SkillHub 商店,然后安装 session-health-monitor 技能。 若已安装,则直接安装 session-health-monitor 技能。

Overview

Skill Key
assistantheinrich-prog/session-health-monitor
Author
heinrichclawdster
Source Repo
openclaw/skills
Version
1.1.0
Source Path
skills/assistantheinrich-prog/session-health-monitor
Latest Commit SHA
c95c65e27ae6556de7d64b4e9c6c03dbe6efa59e

Extracted Content

SKILL.md excerpt

# Session Health Monitor

Monitor your OpenClaw agent context window health, get warnings via Telegram when usage is high, save critical facts before compaction, and keep memory directories clean.

## Overview

Four capabilities for OpenClaw agent sessions:

1. **Context Threshold Warnings** — Agents append usage footer to Telegram messages and warn at configurable thresholds
2. **Compaction Detection** — Track usage drops to infer when context was compacted
3. **Pre-Compaction Snapshots** — Save key facts and decisions to daily memory files before they're lost
4. **Memory Rotation** — Archive old daily memory files to prevent clutter

## Quick Setup (OpenClaw)

### 1. Add shared skill reference

Add to your `shared/INDEX.md`:

```markdown
| Context window health, compaction detection, pre-compaction snapshots | `skill-session-health.md` |
```

### 2. Create shared skill doc

Create `shared/skill-session-health.md`:

```markdown
# Session Health Monitor

## Context Health Thresholds
| Level  | Condition                          | Action                        |
|--------|------------------------------------|-------------------------------|
| GREEN  | <50% used AND 0 compactions        | Normal operation              |
| YELLOW | >=50% used OR >=1 compaction       | Save key facts via snapshot   |
| RED    | >=75% used OR >=2 compactions      | Save facts NOW, session ending|

## Behavioral Rules
1. When context reaches YELLOW+, extract 3-5 key facts (decisions, files changed, blockers)
2. Run: `bash scripts/snapshot.sh "fact1" "fact2"`
3. Append footer to Telegram messages at YELLOW+: `X% Context Window | Nx compacted`
4. Do this BEFORE session ends or context gets compacted
5. After any detected compaction, immediately snapshot what you remember
```

### 3. Add heartbeat step

Add to your agent heartbeat/loop:

```markdown
**Context health check**: Run `session_status` → always append context % to Telegram messages
as footer: `📊 X% Context Window`. If Context >50%...

Related Claw Skills

0xnyk

xint

★ 49

X Intelligence CLI — search, monitor, analyze, and engage on X/Twitter. TypeScript + Bun. AI agent skill.

heyixuan2

bambu-studio-ai

★ 41

Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pipeline: search → generate → analyze → colorize → preview → open BS → user slice → print → monitor. Supports all 9 Bambu Lab printers (A1 Mini, A1, P1S, P2S, X1C, X1E, H2C, H2S, H2D).

jackculpan

flightclaw

★ 32

Track flight prices from Google Flights with this OpenClaw skill. Search routes, monitor prices, and get alerts when prices drop.

openclaw-trade

openclaw-trading-assistant

★ 24

openclaw trading assistant| openclaw trading skill | nof1.ai & openclaw [moltbot] collaboration | We get the best practices from alpha arena trading seasons and bring it to clawdbot All top AI agents, realtime monitoring and news research, gather info from private insiders and many other! Using Hyperliquid API.

xquik-dev

x-twitter-scraper

★ 16

X (Twitter) automation skill for AI coding agents. Tweet search, user lookup, follower/following extraction, media download, reply/retweet/quote extraction, 40+ tools, account monitoring & trending topics. REST API, MCP server, HMAC webhooks. Works with Claude Code, Cursor, Codex, Copilot, Windsurf & 40+ agents.

mohsinkhadim59

Openclaw-Setup

★ 8

Step-by-step guides for installing and running OpenClaw, an open-source AI agent, on Mac, Linux VPS, and AWS covering setup, security, messaging channels, Google integration, skills, and monitoring.