Search

PythonReactSEOPDF
OpenClaw

channel-activity

Multi-channel short-term memory for AI assistants

eightroad0 source installs☆ 0 Repository starsv3.0.0

Installation

Follow the repository instructions for this skill and your agent. Review the files and dependencies before adding it to your workflow.

SkillHub CLI

skillhub install eightroad/channel-activity-yanyue

Inspect the source and compatibility requirements, then follow its installation steps.

Give your agent the source link and ask it to inspect instructions and dependencies before explaining the installation steps.

View source ↗Guides

Skill instructions

Channel Activity

Record and query activities from different channels with 30-minute TTL.

Install

npx clawhub@latest install channel-activity

Usage

from channel_activity import ChannelActivity

ca = ChannelActivity()
ca.record("feishu", "Task request")
summary = ca.get_context_summary(channel="qq")

Features

  • Multi-channel support (Feishu, QQ, etc.)
  • 30-minute TTL with auto cleanup
  • Smart summarization (50 chars/message)
  • Cross-channel query

License

MIT

Source information

Source
github
Repository
openclaw/skills
Path
skills/eightroad/channel-activity-yanyue
Version
3.0.0
Commit
ebf75f9b96c18accb2788ef4fbedd627a0225ec6
Classification source
rules
Status
active
Visibility
public

These signals come from indexed source analysis and may lag behind changes. Check the current source files.

README

短期记忆 Skill

📝 概述

名称: short-term-memory
版本: 1.0.0
作者: 炎月
创建时间: 2026-03-08

功能: 1分钟临时记忆缓存,用于多通道信息整合


🎯 核心特性

✨ 主要功能
  • 临时缓存: 1分钟TTL(可配置)
  • 多通道支持: 飞书、QQ、其他通道统一管理
  • 自动清理: 过期内容自动删除
  • 上下文整合: 多通道信息可合并处理
  • 升级机制: 重要内容可升级为长期记忆
🧠 记忆体系定位
感觉记忆(毫秒级)
    ↓
短期记忆(1分钟)← 本skill
    ↓
长期记忆(永久)← MEMORY.md

⚙️ 配置

{
  "ttl_seconds": 60,           // 过期时间
  "max_entries": 50,            // 最大条目数
  "cleanup_interval_seconds": 10,  // 清理间隔
  "auto_cleanup": true,         // 自动清理
  "upgrade_to_long_term": true  // 支持升级为长期记忆
}

📖 使用方法

1. 写入短期记忆
from short_term_memory import ShortTermMemory

stm = ShortTermMemory()

# 写入记忆
entry_id = stm.write(
    content="星之君说:记住要完成X任务",
    channel="feishu",
    user_id="ou_472d0b86d66dd43850b6d7c249c76d28",
    context={
        "type": "task",
        "priority": "high"
    }
)
2. 读取短期记忆
# 读取所有未过期记忆
entries = stm.read()

# 按通道过滤
feishu_entries = stm.read(channel="feishu")

# 按用户过滤
user_entries = stm.read(user_id="ou_472d0b86d66dd43850b6d7c249c76d28")
3. 查询短期记忆
# 文本查询
results = stm.query("任务", limit=5)
4. 升级为长期记忆
# 升级重要内容
stm.upgrade_to_long_term(entry_id)

🎬 使用场景

场景1: 跨通道任务跟踪
13:40 飞书: "帮我记住X任务"
    → stm.write("X任务", "feishu", user_id)

13:45 QQ: "X任务进度怎么样了?"
    → stm.read(user_id)
    → 返回: "您刚才在飞书提到X任务,我正在处理..."
场景2: 多通道信息整合
13:40 飞书: "项目A需要处理"
13:42 QQ: "项目B也要做"
    → stm.read()
    → 整合: [项目A + 项目B]
    → 主动汇报: "发现两个项目任务,是否需要整合处理?"
场景3: 临时讨论记录
快速讨论,不需要永...

Extracted content

SKILL.md
# Channel Activity

Record and query activities from different channels with 30-minute TTL.

## Install

```bash
npx clawhub@latest install channel-activity
```

## Usage

```python
from channel_activity import ChannelActivity

ca = ChannelActivity()
ca.record("feishu", "Task request")
summary = ca.get_context_summary(channel="qq")
```

## Features

- Multi-channel support (Feishu, QQ, etc.)
- 30-minute TTL with auto cleanup
- Smart summarization (50 chars/message)
- Cross-channel query

## License

MIT
README
# 短期记忆 Skill

## 📝 概述

**名称**: short-term-memory  
**版本**: 1.0.0  
**作者**: 炎月  
**创建时间**: 2026-03-08

**功能**: 1分钟临时记忆缓存,用于多通道信息整合

---

## 🎯 核心特性

### ✨ 主要功能
- **临时缓存**: 1分钟TTL(可配置)
- **多通道支持**: 飞书、QQ、其他通道统一管理
- **自动清理**: 过期内容自动删除
- **上下文整合**: 多通道信息可合并处理
- **升级机制**: 重要内容可升级为长期记忆

### 🧠 记忆体系定位

```
感觉记忆(毫秒级)
    ↓
短期记忆(1分钟)← 本skill
    ↓
长期记忆(永久)← MEMORY.md
```

---

## ⚙️ 配置

```json
{
  "ttl_seconds": 60,           // 过期时间
  "max_entries": 50,            // 最大条目数
  "cleanup_interval_seconds": 10,  // 清理间隔
  "auto_cleanup": true,         // 自动清理
  "upgrade_to_long_term": true  // 支持升级为长期记忆
}
```

---

## 📖 使用方法

### 1. 写入短期记忆

```python
from short_term_memory import ShortTermMemory

stm = ShortTermMemory()

# 写入记忆
entry_id = stm.write(
    content="星之君说:记住要完成X任务",
    channel="feishu",
    user_id="ou_472d0b86d66dd43850b6d7c249c76d28",
    context={
        "type": "task",
        "priority": "high"
    }
)
```

### 2. 读取短期记忆

```python
# 读取所有未过期记忆
entries = stm.read()

# 按通道过滤
feishu_entries = stm.read(channel="feishu")

# 按用户过滤
user_entries = stm.read(user_id="ou_472d0b86d66dd43850b6d7c249c76d28")
```

### 3. 查询短期记忆

```python
# 文本查询
results = stm.query("任务", limit=5)
```

### 4. 升级为长期记忆

```python
# 升级重要内容
stm.upgrade_to_long_term(entry_id)
```

---

## 🎬 使用场景

### 场景1: 跨通道任务跟踪

```
13:40 飞书: "帮我记住X任务"
    → stm.write("X任务", "feishu", user_id)

13:45 QQ: "X任务进度怎么样了?"
    → stm.read(user_id)
    → 返回: "您刚才在飞书提到X任务,我正在处理..."
```

### 场景2: 多通道信息整合

```
13:40 飞书: "项目A需要处理"
13:42 QQ: "项目B也要做"
    → stm.read()
    → 整合: [项目A + 项目B]
    → 主动汇报: "发现两个项目任务,是否需要整合处理?"
```

### 场景3: 临时讨论记录

```
快速讨论,不需要永...

Related skills

OpenClaw

13-Day Sprint Method

galizki

Productivity system based on Maya calendar with 13 natural tones for project management and personal development

OpenClaw

1password

daggerkun007

Set up and use 1Password CLI (op). Use when installing the CLI, enabling desktop app integration, signing in (single or multi-account), or reading/injecting/running secrets via op.