Token导航 LogoToken导航TokenDH.com
研究检索敏感数据clawhub未标认证来源可访问clear审计提醒

cyber-memory网络记忆

Agent Skill

cyber-memory 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

2,845

周安装

114

GitHub Stars

公开资料未说明

下载量

921
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:cyber-memory(网络记忆)
来源仓库:https://github.com/witnesssun/cyber-memory
安装命令:
openclaw skills install cyber-memory
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install cyber-memory

简介

五层记忆系统,通过本地 LLM (Ollama) 自动提取事实。在本地处理会话记录 — 无需外部 API。

SKILL.md

name
cyber-memory
version
1.0.2
description
Five-layer memory system with automatic fact extraction via local LLM (Ollama). Processes session transcripts locally — no external API required.
author
CyberSun
keywords
[memory, long-term-memory, ai-agent, openclaw, fact-extraction, knowledge-graph, vector-search, hooks, ollama, local-llm]
metadata
openclaw
emoji
🧠
requires
config

Memory Architecture 🧠

A complete memory system for OpenClaw agents. Five layers of storage, automatic fact extraction via local LLM, hybrid search, and behavioral rules that prevent context loss.

🔒 Local-first by default — all fact extraction runs on your local Ollama instance. No data leaves your machine.

🔒 Privacy & Data Handling

This skill includes a hook (memory-flush) that:

  • Reads session transcripts from disk (~/.openclaw/agents/*/sessions/*.jsonl)
  • Processes content locally via Ollama (default) — no data leaves your machine
  • No external API key required — works out of the box with local LLM

What is processed: Recent user/assistant messages (last 30 messages, each truncated to 500 chars). Where it runs: Local Ollama endpoint (http://localhost:11434/v1/chat/completions by default). What is saved locally: Extracted facts as Markdown files in workspace/memory/.

Optional: You can configure an external OpenAI-compatible API by setting baseUrl and apiKey in the hook config, but local Ollama is the default and recommended setup.

Architecture

🔥 Hot    → SESSION-STATE.md (WAL protocol, survives compaction)
🌤 Warm   → memory/YYYY-MM-DD.md (daily event summaries)
🧊 Cold   → MEMORY.md (decisions, preferences, rules — always loaded)
🕸 Graph  → memory/ontology/ (entity relationships)
📚 Learn  → .learnings/ (errors, best practices)

Automation

MechanismTriggerWhat it does
session-memory (built-in)/new /resetSaves conversation to memory/
memory-flush (this skill)Compaction + /newLLM extracts structured facts (local Ollama)
command-logger (built-in)Any commandAudit log
session indexingAutomaticHistorical sessions searchable

Search

  • Vector: any OpenAI-compatible embedding provider (Ollama, OpenAI, etc.)
  • Keyword: SQLite FTS5 (BM25)
  • Hybrid: weighted vector + keyword fusion
  • Scope: MEMORY.md + daily logs + session transcripts + SESSION-STATE.md

Setup

1. Prerequisites

Install Ollama and pull a chat model:

# Install Ollama (https://ollama.ai)
ollama pull qwen2.5:7b   # or any chat model you prefer
ollama serve              # ensure Ollama is running on localhost:11434

2. Enable Built-in Hooks

openclaw hooks enable session-memory
openclaw hooks enable command-logger

3. Install Memory-Flush Hook

Copy the hooks/memory-flush/ directory to ~/.openclaw/hooks/:

cp -r hooks/memory-flush ~/.openclaw/hooks/
openclaw hooks enable memory-flush

4. Configure Fact Extraction (Optional)

By default, the hook uses local Ollama — no configuration needed. To customize:

{
  hooks: {
    internal: {
      enabled: true,
      entries: {
        "memory-flush": {
          enabled: true,
          extractionModel: "qwen2.5:7b",           // Ollama model name
          baseUrl: "http://localhost:11434/v1/chat/completions"  // Ollama endpoint
        }
      }
    }
  }
}

Works with any OpenAI-compatible API (Ollama, LM Studio, vLLM, etc.). Set baseUrl and apiKey to use an external provider.

5. Enable Session Indexing

{
  agents: {
    defaults: {
      memorySearch: {
        provider: "local",  // or "openai", "ollama", "gemini", "voyage", etc.
        experimental: {
          sessionMemory: true
        },
        sources: ["memory", "sessions"],
        extraPaths: ["SESSION-STATE.md"]
      }
    }
  }
}

6. Restart Gateway

openclaw gateway restart

Agent Behavioral Rules

Add these rules to your AGENTS.md:

Memory Writing

  • Important info → MEMORY.md immediately (decisions, preferences, rules)
  • Daily summaries → memory/YYYY-MM-DD.md (event summaries, no raw tool output)
  • Cron report details → skip (already delivered elsewhere)
  • Critical info zero loss — important things must go to MEMORY.md, not just daily logs

Memory Searching

  • Check MEMORY.md + today/yesterday logs at session start
  • Use memory_search for historical queries
  • Ontology queries (relationships, "who is responsible for X") → use ontology skill

Sub-agent Context Injection

When spawning sub-agents, inject relevant context from MEMORY.md:

[Key context from memory, max 500 words]

---

[Actual task]

File Structure

workspace/
├── AGENTS.md              # Behavioral rules (loaded every session)
├── SOUL.md                # Agent personality
├── USER.md                # User preferences
├── TOOLS.md               # Tool notes (keep lean, <2KB)
├── MEMORY.md              # Long-term curated memory
├── SESSION-STATE.md       # Hot working memory (WAL)
├── memory/
│   ├── YYYY-MM-DD.md      # Daily logs (summaries only)
│   ├── YYYY-MM-DD-facts-* # Auto-extracted facts
│   ├── YYYY-MM-DD-compact # Pre-compaction snapshots
│   └── ontology/
│       ├── graph.jsonl    # Knowledge graph
│       └── schema.yaml    # Entity type definitions
├── .learnings/
│   ├── LEARNINGS.md       # Best practices
│   ├── ERRORS.md          # Error log
│   └── FEATURE_REQUESTS.md
└── hooks/
    └── memory-flush/
        ├── HOOK.md
        └── handler.ts     # LLM fact extraction (local Ollama default)

What Gets Loaded When

FileWhen
AGENTS.md, SOUL.md, USER.md, TOOLS.mdEvery session start
MEMORY.mdDM session start
memory/today + yesterdayEvery session start
SESSION-STATE.mdVia memory_search (indexed)
Other memory filesVia memory_search on demand

Token Optimization

  • Keep TOOLS.md lean (<2KB), move detailed configs to tools/ subdirectory
  • Daily logs: event summaries, not raw tool output
  • Fact extraction: 30 messages → ~10 facts (16:1 compression)

Troubleshooting

Facts not extracted? Check Ollama is running (ollama serve) and the model is available (ollama list).

Session search not working? Verify experimental.sessionMemory: true and sources: ["memory", "sessions"].

Hook not loading? Run openclaw hooks list --verbose and check for errors.

Want to use external API? Set baseUrl and apiKey in the hook config to use OpenAI or any compatible provider.

License

MIT

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

91.93%
按下载量换算847

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

可疑

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills