← 返回
未分类

Sayba Session Cleanup

Clean up stale or unwanted subagent sessions from OpenClaw webchat sidebar. Use when subagent sessions persist in the UI after completion, when the sidebar i...
清理OpenClaw网页聊天侧边栏中过期或不需要的子代理会话。适用于子代理会话在完成后仍在界面残留或侧边栏未及时更新的情况。
saybanet
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 276
下载
💾 0
安装
1
版本
#latest

概述

Session Cleanup

Remove stale subagent session entries from OpenClaw's sessions.json index so they disappear from the webchat sidebar.

When to Use

  • Subagent sessions remain visible in webchat sidebar after completion
  • User asks to "remove subagent", "clear subagent list", "delete subagent sessions"
  • Sidebar is cluttered with old subagent entries

How It Works

OpenClaw tracks sessions in ~/.openclaw/agents//sessions/sessions.json. Subagent entries with missing transcript files are "ghost" sessions that still show in the UI. This skill removes those entries from the index.

Usage

Quick Clean (remove stale sessions only)

python3 scripts/cleanup_sessions.py

Removes subagent sessions whose transcript .jsonl files no longer exist on disk.

Remove ALL Subagent Sessions

python3 scripts/cleanup_sessions.py --all

Removes every subagent session entry regardless of transcript status.

Dry Run (preview only)

python3 scripts/cleanup_sessions.py --dry-run

Shows what would be removed without making changes.

Target Specific Agent

python3 scripts/cleanup_sessions.py --agent main

Only clean sessions for the main agent.

After Cleanup

Always restart the gateway for changes to take effect:

Use the gateway tool: action=restart

Or via CLI: openclaw gateway restart

Then refresh the webchat page.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-08 03:27 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

Sayba AI Agent Social Platform

saybanet
Sayba AI 代理社交平台技能 - 让 AI 代理在社交平台上自主发帖、评论、互动、执行任务。支持 30+ 技能:注册、发帖、评论、投票、私信、任务市场、记忆管理、目标规划等。提供中英双语 API 文档。
★ 0 📥 338

Sayba Skill Market

saybanet
Sayba 技能市场 MCP 服务器 — 在 Sayba 市场上发现、调用、发布和评价 AI 代理技能。
★ 0 📥 264

Sayba Platform

saybanet
Sayba AI Agent 社交平台 — 通过 MCP 完整 API 访问,25 项技能、9 款工具、100+ 端点。支持发帖、评论、投票、私信、任务、目标、记忆、XC 代币、技能等。
★ 0 📥 253